Problem
@supermemory/memory-graph currently hardcodes several user-facing labels around source/document nodes and hardcodes the node hover popover stacking level. That forces downstream apps to patch built dist/ output when their product vocabulary or app shell layering differs.
Observed with @supermemory/memory-graph@0.2.3, which is also the current latest npm release.
Concrete examples
In a product where imported context items are called "sources" rather than "documents", these strings need to be configurable instead of fixed:
- Legend group label:
Documents
- Edge label/description:
Document source, Document to memory
- Hover popover fallback type:
document
- Copyable ID label:
Document
- Actions:
View document, Go to document, Next document, Prev memory
The hover popover also uses a fixed high stacking value in the built package, which can sit above host app chrome. Consumers need either a prop/theme token for overlay z-index, or a style/class override path for the popover layer.
Current downstream workaround
A downstream app is carrying a package patch against dist/memory-graph.js and dist/memory-graph.cjs to:
- Rename document-facing copy to source-facing copy.
- Lower the hover popover z-index from
100 to 30 so it stays under the host app shell.
That works as an emergency workaround but is fragile across every package upgrade.
Proposed fix
Expose these as supported component options, for example:
type MemoryGraphLabels = {
documentGroup?: string;
documentTypeFallback?: string;
documentSourceEdge?: string;
documentToMemoryEdge?: string;
memoryCount?: (count: number) => string;
documentIdLabel?: string;
viewDocument?: string;
goToDocument?: string;
nextDocument?: string;
previousDocument?: string;
showMemory?: string;
};
type MemoryGraphLayering = {
hoverPopoverZIndex?: number;
};
Or expose the same control through the existing theme/override surface if that is the preferred API shape.
Expected result
Consumers can configure product vocabulary and host-shell layering without patching generated package output.
Problem
@supermemory/memory-graphcurrently hardcodes several user-facing labels around source/document nodes and hardcodes the node hover popover stacking level. That forces downstream apps to patch builtdist/output when their product vocabulary or app shell layering differs.Observed with
@supermemory/memory-graph@0.2.3, which is also the current latest npm release.Concrete examples
In a product where imported context items are called "sources" rather than "documents", these strings need to be configurable instead of fixed:
DocumentsDocument source,Document to memorydocumentDocumentView document,Go to document,Next document,Prev memoryThe hover popover also uses a fixed high stacking value in the built package, which can sit above host app chrome. Consumers need either a prop/theme token for overlay z-index, or a style/class override path for the popover layer.
Current downstream workaround
A downstream app is carrying a package patch against
dist/memory-graph.jsanddist/memory-graph.cjsto:100to30so it stays under the host app shell.That works as an emergency workaround but is fragile across every package upgrade.
Proposed fix
Expose these as supported component options, for example:
Or expose the same control through the existing theme/override surface if that is the preferred API shape.
Expected result
Consumers can configure product vocabulary and host-shell layering without patching generated package output.