Skip to content

rune-langium / visual-editor/src / StructureExpansionKey

Interface: StructureExpansionKey ​

Defined in: packages/visual-editor/src/types/structure-view.ts:103

Key used in the expansion map; encodes namespace + type + attribute, plus an optional per-instance discriminator.

Per-instance semantics (Phase 14d, spec 020). Each visible occurrence of a type tracks its own expansion state — matching XmlSpy / Altova UModel / Liquid Studio / Oxygen XML conventions. The instancePath carries the chain of React Flow instance ids of the ancestors leading TO this row's owner (NOT including the owner itself). Two placements of the same type at the same depth produce different instancePaths because their parent instance ids differ (e.g. Trade::buyer::Party vs Trade::seller::Party), so chevrons inside them stay independent.

The separator inside the path uses > (not :) because : is already the field separator and we need to round-trip the path through a single string.

Properties ​

PropertyModifierTypeDescriptionDefined in
attrNamereadonlystring-packages/visual-editor/src/types/structure-view.ts:106
instancePath?readonlyreadonly string[]Chain of React Flow instance ids of ancestors leading to this row's owner, NOT including the owner. Empty/undefined = root-level instance (no ancestors).packages/visual-editor/src/types/structure-view.ts:111
namespaceUrireadonlystring-packages/visual-editor/src/types/structure-view.ts:104
typeIdreadonlystring-packages/visual-editor/src/types/structure-view.ts:105

Core packages released under MIT. Studio app released under FSL-1.1-ALv2.