@likec4/diagram 1.44.0 → 1.46.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (270) hide show
  1. package/bundle/index.js +18847 -17876
  2. package/dist/LikeC4Diagram.d.ts +1 -1
  3. package/dist/LikeC4Diagram.js +15 -12
  4. package/dist/LikeC4Diagram.props.d.ts +13 -20
  5. package/dist/LikeC4ProjectsProvider.js +8 -4
  6. package/dist/LikeC4Styles.js +0 -3
  7. package/dist/LikeC4View.d.ts +3 -3
  8. package/dist/LikeC4View.js +8 -8
  9. package/dist/ReactLikeC4.d.ts +3 -6
  10. package/dist/StaticLikeC4Diagram.js +0 -2
  11. package/dist/base/Base.d.ts +1 -1
  12. package/dist/base/updateEdges.js +25 -15
  13. package/dist/base/updateNodes.d.ts +14 -0
  14. package/dist/base/updateNodes.js +51 -18
  15. package/dist/base-primitives/Markdown.d.ts +30 -4
  16. package/dist/base-primitives/Markdown.js +3 -2
  17. package/dist/base-primitives/NodeHandles.d.ts +2 -1
  18. package/dist/base-primitives/NodeHandles.js +22 -18
  19. package/dist/base-primitives/compound/CompoundActionButton.d.ts +3 -2
  20. package/dist/base-primitives/compound/CompoundActionButton.js +1 -1
  21. package/dist/base-primitives/compound/CompoundDetailsButton.d.ts +3 -2
  22. package/dist/base-primitives/compound/CompoundDetailsButton.js +1 -1
  23. package/dist/base-primitives/edge/EdgeActionButton.d.ts +3 -2
  24. package/dist/base-primitives/edge/EdgeActionButton.js +1 -1
  25. package/dist/base-primitives/edge/EdgeContainer.d.ts +1 -1
  26. package/dist/base-primitives/edge/EdgeContainer.js +6 -4
  27. package/dist/base-primitives/edge/EdgeLabel.d.ts +2 -2
  28. package/dist/base-primitives/edge/EdgeLabel.js +16 -16
  29. package/dist/base-primitives/edge/EdgeLabelContainer.d.ts +1 -1
  30. package/dist/base-primitives/edge/EdgeLabelContainer.js +5 -4
  31. package/dist/base-primitives/edge/EdgePath.js +27 -12
  32. package/dist/base-primitives/element/ElementActionButtons.d.ts +3 -2
  33. package/dist/base-primitives/element/ElementActionButtons.js +3 -3
  34. package/dist/base-primitives/element/ElementData.d.ts +3 -3
  35. package/dist/base-primitives/element/ElementData.js +13 -7
  36. package/dist/base-primitives/element/ElementDetailsButton.d.ts +3 -2
  37. package/dist/base-primitives/element/ElementDetailsButton.js +4 -1
  38. package/dist/base-primitives/element/ElementShape.js +5 -5
  39. package/dist/base-primitives/element/ElementTags.d.ts +6 -4
  40. package/dist/components/ErrorFallback.js +1 -1
  41. package/dist/components/Link.js +2 -2
  42. package/dist/context/DiagramEventHandlers.js +0 -1
  43. package/dist/context/DiagramFeatures.d.ts +2 -1
  44. package/dist/context/DiagramFeatures.js +1 -0
  45. package/dist/context/EnsureMantine.js +2 -1
  46. package/dist/context/IconRenderer.js +6 -6
  47. package/dist/context/TagStylesContext.js +1 -1
  48. package/dist/custom/hooks.d.ts +2 -2
  49. package/dist/custom/index.js +1 -1
  50. package/dist/editor/LikeC4EditorProvider.d.ts +22 -0
  51. package/dist/editor/LikeC4EditorProvider.js +12 -0
  52. package/dist/editor/__tests__/fixture.d.ts +205 -0
  53. package/dist/editor/applyChangesToManualLayout.d.ts +8 -0
  54. package/dist/editor/applyChangesToManualLayout.js +182 -0
  55. package/dist/editor/editorActor.actions.d.ts +201 -0
  56. package/dist/editor/editorActor.actions.js +149 -0
  57. package/dist/editor/editorActor.d.ts +653 -0
  58. package/dist/editor/editorActor.js +324 -0
  59. package/dist/editor/hotkeyActor.d.ts +7 -0
  60. package/dist/editor/hotkeyActor.js +19 -0
  61. package/dist/editor/index.d.ts +3 -2
  62. package/dist/editor/useEditorActorLogic.d.ts +565 -0
  63. package/dist/editor/useEditorActorLogic.js +54 -0
  64. package/dist/hooks/index.d.ts +2 -1
  65. package/dist/hooks/safeContext.d.ts +3 -2
  66. package/dist/hooks/safeContext.js +7 -4
  67. package/dist/hooks/useDiagram.d.ts +4 -2
  68. package/dist/hooks/useDiagram.js +19 -8
  69. package/dist/hooks/useDiagramCompareLayout.d.ts +8 -0
  70. package/dist/hooks/useDiagramCompareLayout.js +29 -4
  71. package/dist/hooks/useLikeC4Project.d.ts +6 -1
  72. package/dist/hooks/useLikeC4Project.js +14 -2
  73. package/dist/hooks/useMediaPrint.d.ts +6 -0
  74. package/dist/index.d.ts +1 -0
  75. package/dist/index.js +1 -0
  76. package/dist/likec4diagram/DiagramXYFlow.js +11 -7
  77. package/dist/likec4diagram/custom/edges/EdgeDrifts.d.ts +6 -0
  78. package/dist/likec4diagram/custom/edges/EdgeDrifts.js +34 -0
  79. package/dist/likec4diagram/custom/edges/RelationshipEdge.js +90 -54
  80. package/dist/likec4diagram/custom/edges/SequenceStepEdge.js +3 -1
  81. package/dist/likec4diagram/custom/edges/edges.css.d.ts +0 -1
  82. package/dist/likec4diagram/custom/edges/edges.css.js +30 -24
  83. package/dist/likec4diagram/custom/edges/useControlPoints.js +5 -5
  84. package/dist/likec4diagram/custom/edges/useRelationshipEdgePath.js +5 -5
  85. package/dist/likec4diagram/custom/nodes/ElementActions.js +2 -2
  86. package/dist/likec4diagram/custom/nodes/NodeDrifts.d.ts +6 -0
  87. package/dist/likec4diagram/custom/nodes/{ElementNodeDrifts.js → NodeDrifts.js} +12 -13
  88. package/dist/likec4diagram/custom/nodes/SequenceActorNode.js +4 -2
  89. package/dist/likec4diagram/custom/nodes/index.d.ts +1 -0
  90. package/dist/likec4diagram/custom/nodes/nodes.js +61 -23
  91. package/dist/likec4diagram/custom/nodes/toolbar/ElementToolbar.js +2 -2
  92. package/dist/likec4diagram/custom/nodes/toolbar/_shared.js +2 -2
  93. package/dist/likec4diagram/relationship-popover/RelationshipPopover.js +128 -15
  94. package/dist/likec4diagram/relationship-popover/actor.d.ts +1 -1
  95. package/dist/likec4diagram/state/DiagramActorProvider.d.ts +2 -2
  96. package/dist/likec4diagram/state/DiagramActorProvider.js +63 -72
  97. package/dist/likec4diagram/state/assign.d.ts +14 -7
  98. package/dist/likec4diagram/state/assign.js +28 -200
  99. package/dist/likec4diagram/state/createViewChange.js +23 -30
  100. package/dist/likec4diagram/state/diagram-api.d.ts +20 -6
  101. package/dist/likec4diagram/state/diagram-api.js +58 -52
  102. package/dist/likec4diagram/state/hotkeyActor.d.ts +1 -8
  103. package/dist/likec4diagram/state/hotkeyActor.js +13 -17
  104. package/dist/likec4diagram/state/machine.actions.d.ts +1127 -864
  105. package/dist/likec4diagram/state/machine.actions.js +316 -296
  106. package/dist/likec4diagram/state/machine.actions.layout.d.ts +641 -0
  107. package/dist/likec4diagram/state/machine.actions.layout.js +141 -0
  108. package/dist/likec4diagram/state/machine.d.ts +18 -3712
  109. package/dist/likec4diagram/state/machine.js +64 -73
  110. package/dist/likec4diagram/state/machine.setup.d.ts +80 -26
  111. package/dist/likec4diagram/state/machine.setup.js +44 -7
  112. package/dist/likec4diagram/state/machine.state.initializing.d.ts +58 -17
  113. package/dist/likec4diagram/state/machine.state.initializing.js +14 -14
  114. package/dist/likec4diagram/state/machine.state.navigating.d.ts +5 -108
  115. package/dist/likec4diagram/state/machine.state.navigating.js +187 -35
  116. package/dist/likec4diagram/state/machine.state.ready.d.ts +2997 -2598
  117. package/dist/likec4diagram/state/machine.state.ready.focused.d.ts +710 -0
  118. package/dist/likec4diagram/state/machine.state.ready.focused.js +98 -0
  119. package/dist/likec4diagram/state/machine.state.ready.idle.d.ts +540 -0
  120. package/dist/likec4diagram/state/machine.state.ready.idle.js +105 -0
  121. package/dist/likec4diagram/state/machine.state.ready.js +95 -347
  122. package/dist/likec4diagram/state/machine.state.ready.printing.d.ts +140 -0
  123. package/dist/likec4diagram/state/machine.state.ready.printing.js +40 -0
  124. package/dist/likec4diagram/state/machine.state.ready.walkthrough.d.ts +684 -0
  125. package/dist/likec4diagram/state/machine.state.ready.walkthrough.js +190 -0
  126. package/dist/likec4diagram/state/mediaPrintActor.d.ts +12 -0
  127. package/dist/likec4diagram/state/mediaPrintActor.js +18 -0
  128. package/dist/likec4diagram/state/types.d.ts +11 -9
  129. package/dist/likec4diagram/state/utils.d.ts +44 -5
  130. package/dist/likec4diagram/state/utils.js +62 -6
  131. package/dist/likec4diagram/types.d.ts +8 -13
  132. package/dist/likec4diagram/ui/notation/NotationPanel.css.js +5 -2
  133. package/dist/likec4diagram/ui/notation/NotationPanel.js +3 -3
  134. package/dist/likec4diagram/useLayoutConstraints.js +104 -103
  135. package/dist/likec4diagram/xyflow-diagram/diagram-view.js +12 -15
  136. package/dist/likec4diagram/xyflow-sequence/sequence-layout.js +11 -8
  137. package/dist/navigationpanel/NavigationPanel.js +11 -10
  138. package/dist/navigationpanel/NavigationPanelDropdown.js +7 -7
  139. package/dist/navigationpanel/_common.js +1 -1
  140. package/dist/navigationpanel/actor.d.ts +4 -204
  141. package/dist/navigationpanel/actor.js +1 -1
  142. package/dist/navigationpanel/comparepanel/CompareActionsMenu.d.ts +3 -1
  143. package/dist/navigationpanel/comparepanel/CompareActionsMenu.js +40 -14
  144. package/dist/navigationpanel/comparepanel/ComparePanelControls.js +6 -4
  145. package/dist/navigationpanel/comparepanel/LayoutTypeSwitcher.js +2 -2
  146. package/dist/navigationpanel/controls/DetailsControls.js +2 -2
  147. package/dist/navigationpanel/controls/LayoutWarning.js +2 -1
  148. package/dist/navigationpanel/controls/NavigationButtons.js +2 -2
  149. package/dist/navigationpanel/controls/OpenSource.js +1 -1
  150. package/dist/navigationpanel/controls/SearchControl.js +2 -2
  151. package/dist/navigationpanel/controls/ToggleReadonly.js +32 -19
  152. package/dist/navigationpanel/dropdown/ProjectsMenu.js +1 -1
  153. package/dist/navigationpanel/editorpanel/CenterCamera.js +1 -1
  154. package/dist/navigationpanel/editorpanel/ChangeAutoLayoutButton.js +1 -1
  155. package/dist/navigationpanel/editorpanel/ManualLayoutToolsButton.js +9 -9
  156. package/dist/navigationpanel/editorpanel/ToggleReadonly.js +1 -1
  157. package/dist/navigationpanel/walkthrough/ActiveWalkthroughControls.js +3 -3
  158. package/dist/navigationpanel/walkthrough/DynamicViewControls.d.ts +9 -9
  159. package/dist/navigationpanel/walkthrough/DynamicViewControls.js +1 -1
  160. package/dist/navigationpanel/walkthrough/WalkthroughPanel.js +4 -3
  161. package/dist/overlays/Overlays.js +24 -12
  162. package/dist/overlays/element-details/ElementDetailsCard.css.js +3 -3
  163. package/dist/overlays/element-details/ElementDetailsCard.js +4 -4
  164. package/dist/overlays/element-details/MetadataValue.d.ts +2 -1
  165. package/dist/overlays/element-details/MetadataValue.js +4 -6
  166. package/dist/overlays/element-details/TabPanelDeployments.js +3 -3
  167. package/dist/overlays/element-details/TabPanelRelationships.js +12 -7
  168. package/dist/overlays/element-details/TabPanelStructure.js +1 -1
  169. package/dist/overlays/element-details/actor.d.ts +8 -83
  170. package/dist/overlays/element-details/actor.js +0 -8
  171. package/dist/overlays/overlay/Overlay.js +10 -10
  172. package/dist/overlays/overlaysActor.d.ts +7 -392
  173. package/dist/overlays/overlaysActor.js +73 -49
  174. package/dist/overlays/relationship-details/RelationshipDetails.js +3 -3
  175. package/dist/overlays/relationship-details/SelectEdge.js +2 -2
  176. package/dist/overlays/relationship-details/_types.d.ts +3 -4
  177. package/dist/overlays/relationship-details/actor.d.ts +6 -562
  178. package/dist/overlays/relationship-details/actor.js +1 -0
  179. package/dist/overlays/relationship-details/custom/ElementActions.js +3 -3
  180. package/dist/overlays/relationship-details/layout-to-xyflow.js +3 -5
  181. package/dist/overlays/relationship-details/layout.d.ts +3 -3
  182. package/dist/overlays/relationship-details/layout.js +4 -4
  183. package/dist/overlays/relationships-browser/RelationshipsBrowser.js +3 -3
  184. package/dist/overlays/relationships-browser/SelectElement.js +2 -2
  185. package/dist/overlays/relationships-browser/_types.d.ts +2 -3
  186. package/dist/overlays/relationships-browser/actor.d.ts +7 -739
  187. package/dist/overlays/relationships-browser/custom/ElementActions.js +3 -3
  188. package/dist/overlays/relationships-browser/layout.d.ts +2 -2
  189. package/dist/overlays/relationships-browser/layout.js +3 -3
  190. package/dist/overlays/relationships-browser/useViewToNodesEdges.js +0 -3
  191. package/dist/overlays/types.d.ts +12 -13
  192. package/dist/search/components/ElementsColumn.js +7 -3
  193. package/dist/search/components/PickView.js +3 -1
  194. package/dist/search/components/SearchByTags.js +1 -1
  195. package/dist/search/components/SearchInput.js +1 -1
  196. package/dist/search/components/ViewsColum.d.ts +3 -1
  197. package/dist/search/components/ViewsColum.js +13 -7
  198. package/dist/search/components/_shared.css.d.ts +1 -1
  199. package/dist/search/searchActor.d.ts +3 -66
  200. package/dist/shadowroot/ShadowRoot.d.ts +5 -7
  201. package/dist/shadowroot/ShadowRoot.js +7 -5
  202. package/dist/shadowroot/styles.css.js +6 -1
  203. package/dist/styles.css2.js +1 -1
  204. package/dist/utils/index.d.ts +2 -2
  205. package/dist/utils/view-bounds.js +7 -6
  206. package/dist/utils/xyflow.d.ts +6 -5
  207. package/dist/utils/xyflow.js +26 -57
  208. package/package.json +24 -23
  209. package/panda.buildinfo.json +65 -71
  210. package/styles-min.css +1 -1
  211. package/styles.css +1 -1
  212. package/dist/base-primitives/edge/edge.css.d.ts +0 -4
  213. package/dist/base-primitives/edge/edge.css.js +0 -71
  214. package/dist/editor/LikeC4EditorContext.d.ts +0 -21
  215. package/dist/likec4diagram/custom/nodes/ElementNodeDrifts.d.ts +0 -4
  216. package/dist/likec4diagram/state/syncManualLayoutActor.d.ts +0 -280
  217. package/dist/likec4diagram/state/syncManualLayoutActor.js +0 -248
  218. package/dist/utils/vector.d.ts +0 -81
  219. package/dist/utils/vector.js +0 -120
  220. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/createReactComponent.js +0 -0
  221. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/defaultAttributes.js +0 -0
  222. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconAlertTriangle.js +0 -0
  223. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowDownRight.js +0 -0
  224. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowLeft.js +0 -0
  225. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js +0 -0
  226. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconBolt.js +0 -0
  227. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconBrowser.js +0 -0
  228. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js +0 -0
  229. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronDown.js +0 -0
  230. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js +0 -0
  231. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js +0 -0
  232. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconCopy.js +0 -0
  233. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconCylinder.js +0 -0
  234. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconDeviceMobile.js +0 -0
  235. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconDirectionSignFilled.js +0 -0
  236. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconExternalLink.js +0 -0
  237. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js +0 -0
  238. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconFocusCentered.js +0 -0
  239. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconFolderFilled.js +0 -0
  240. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconHelpCircle.js +0 -0
  241. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconId.js +0 -0
  242. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconInfoCircle.js +0 -0
  243. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignBottom.js +0 -0
  244. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignCenter.js +0 -0
  245. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignLeft.js +0 -0
  246. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignMiddle.js +0 -0
  247. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignRight.js +0 -0
  248. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignTop.js +0 -0
  249. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutBoardSplit.js +0 -0
  250. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutCollage.js +0 -0
  251. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutDashboard.js +0 -0
  252. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLink.js +0 -0
  253. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLock.js +0 -0
  254. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconLockOpen2.js +0 -0
  255. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerPlayFilled.js +0 -0
  256. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipBackFilled.js +0 -0
  257. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipForwardFilled.js +0 -0
  258. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerStopFilled.js +0 -0
  259. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconRectangularPrism.js +0 -0
  260. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconReorder.js +0 -0
  261. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconRouteOff.js +0 -0
  262. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.js +0 -0
  263. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js +0 -0
  264. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconStack2.js +0 -0
  265. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconStarFilled.js +0 -0
  266. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconTarget.js +0 -0
  267. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js +0 -0
  268. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconUser.js +0 -0
  269. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconX.js +0 -0
  270. /package/dist/node_modules/.pnpm/{@tabler_icons-react@3.35.0_react@19.2.0 → @tabler_icons-react@3.35.0_react@19.2.1}/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js +0 -0
@@ -1,7 +1,6 @@
1
1
  import { Fqn } from '@likec4/core/types';
2
- import { ActorRefFromLogic, SnapshotFrom, StateMachine, CallbackActorLogic, EventObject, NonReducibleUnknown, Values, MetaObject, ActionFunction, StopAction } from 'xstate';
2
+ import { ActorRef, SnapshotFrom, StateMachine } from 'xstate';
3
3
  import { Overlays } from './types';
4
- import { ElementDetailsLogic } from './element-details/actor';
5
4
  export type OverlayActorEvent = {
6
5
  type: 'open.elementDetails';
7
6
  } & Overlays.ElementDetails.Input | {
@@ -38,397 +37,13 @@ export type OverlayActorEmitedEvent = {
38
37
  } | {
39
38
  type: 'idle';
40
39
  };
41
- declare const _overlaysActorLogic: StateMachine<OverlaysContext, OverlayActorEvent, {
42
- [x: `elementDetails-${number}`]: ActorRefFromLogic< ElementDetailsLogic> | undefined;
43
- [x: `relationshipsBrowser-${number}`]: ActorRefFromLogic<Overlays.RelationshipsBrowser.Logic> | undefined;
44
- [x: `relationshipDetails-${number}`]: ActorRefFromLogic<Overlays.RelationshipDetails.Logic> | undefined;
45
- hotkey?: ActorRefFromLogic< CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>>;
46
- }, Values<{
47
- elementDetails: {
48
- src: "elementDetails";
49
- logic: ElementDetailsLogic;
50
- id: `elementDetails-${number}`;
51
- };
52
- relationshipsBrowser: {
53
- src: "relationshipsBrowser";
54
- logic: Overlays.RelationshipsBrowser.Logic;
55
- id: `relationshipsBrowser-${number}`;
56
- };
57
- relationshipDetails: {
58
- src: "relationshipDetails";
59
- logic: Overlays.RelationshipDetails.Logic;
60
- id: `relationshipDetails-${number}`;
61
- };
62
- hotkey: {
63
- src: "hotkey";
64
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
65
- id: "hotkey";
66
- };
67
- }>, never, Values<{
68
- "has overlays?": {
69
- type: "has overlays?";
70
- params: unknown;
71
- };
72
- "close specific overlay?": {
73
- type: "close specific overlay?";
74
- params: unknown;
75
- };
76
- "last: is relationshipDetails?": {
77
- type: "last: is relationshipDetails?";
78
- params: unknown;
79
- };
80
- "last: is relationshipsBrowser?": {
81
- type: "last: is relationshipsBrowser?";
82
- params: unknown;
83
- };
84
- }>, never, "active" | "idle" | "closing", string, NonReducibleUnknown, NonReducibleUnknown, OverlayActorEmitedEvent, MetaObject, {
85
- readonly id: "overlays";
86
- readonly context: () => {
87
- seq: number;
88
- overlays: never[];
89
- };
90
- readonly initial: "idle";
91
- readonly on: {
92
- readonly 'open.elementDetails': {
93
- readonly actions: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
94
- elementDetails: {
95
- src: "elementDetails";
96
- logic: ElementDetailsLogic;
97
- id: `elementDetails-${number}`;
98
- };
99
- relationshipsBrowser: {
100
- src: "relationshipsBrowser";
101
- logic: Overlays.RelationshipsBrowser.Logic;
102
- id: `relationshipsBrowser-${number}`;
103
- };
104
- relationshipDetails: {
105
- src: "relationshipDetails";
106
- logic: Overlays.RelationshipDetails.Logic;
107
- id: `relationshipDetails-${number}`;
108
- };
109
- hotkey: {
110
- src: "hotkey";
111
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
112
- id: "hotkey";
113
- };
114
- }>, never, Values<{
115
- "has overlays?": {
116
- type: "has overlays?";
117
- params: unknown;
118
- };
119
- "close specific overlay?": {
120
- type: "close specific overlay?";
121
- params: unknown;
122
- };
123
- "last: is relationshipDetails?": {
124
- type: "last: is relationshipDetails?";
125
- params: unknown;
126
- };
127
- "last: is relationshipsBrowser?": {
128
- type: "last: is relationshipsBrowser?";
129
- params: unknown;
130
- };
131
- }>, never, OverlayActorEmitedEvent>;
132
- readonly target: ".active";
133
- readonly reenter: false;
134
- };
135
- readonly 'open.relationshipDetails': {
136
- readonly actions: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
137
- elementDetails: {
138
- src: "elementDetails";
139
- logic: ElementDetailsLogic;
140
- id: `elementDetails-${number}`;
141
- };
142
- relationshipsBrowser: {
143
- src: "relationshipsBrowser";
144
- logic: Overlays.RelationshipsBrowser.Logic;
145
- id: `relationshipsBrowser-${number}`;
146
- };
147
- relationshipDetails: {
148
- src: "relationshipDetails";
149
- logic: Overlays.RelationshipDetails.Logic;
150
- id: `relationshipDetails-${number}`;
151
- };
152
- hotkey: {
153
- src: "hotkey";
154
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
155
- id: "hotkey";
156
- };
157
- }>, never, Values<{
158
- "has overlays?": {
159
- type: "has overlays?";
160
- params: unknown;
161
- };
162
- "close specific overlay?": {
163
- type: "close specific overlay?";
164
- params: unknown;
165
- };
166
- "last: is relationshipDetails?": {
167
- type: "last: is relationshipDetails?";
168
- params: unknown;
169
- };
170
- "last: is relationshipsBrowser?": {
171
- type: "last: is relationshipsBrowser?";
172
- params: unknown;
173
- };
174
- }>, never, OverlayActorEmitedEvent>;
175
- readonly target: ".active";
176
- readonly reenter: false;
177
- };
178
- readonly 'open.relationshipsBrowser': {
179
- readonly actions: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
180
- elementDetails: {
181
- src: "elementDetails";
182
- logic: ElementDetailsLogic;
183
- id: `elementDetails-${number}`;
184
- };
185
- relationshipsBrowser: {
186
- src: "relationshipsBrowser";
187
- logic: Overlays.RelationshipsBrowser.Logic;
188
- id: `relationshipsBrowser-${number}`;
189
- };
190
- relationshipDetails: {
191
- src: "relationshipDetails";
192
- logic: Overlays.RelationshipDetails.Logic;
193
- id: `relationshipDetails-${number}`;
194
- };
195
- hotkey: {
196
- src: "hotkey";
197
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
198
- id: "hotkey";
199
- };
200
- }>, never, Values<{
201
- "has overlays?": {
202
- type: "has overlays?";
203
- params: unknown;
204
- };
205
- "close specific overlay?": {
206
- type: "close specific overlay?";
207
- params: unknown;
208
- };
209
- "last: is relationshipDetails?": {
210
- type: "last: is relationshipDetails?";
211
- params: unknown;
212
- };
213
- "last: is relationshipsBrowser?": {
214
- type: "last: is relationshipsBrowser?";
215
- params: unknown;
216
- };
217
- }>, never, OverlayActorEmitedEvent>;
218
- readonly target: ".active";
219
- readonly reenter: false;
220
- };
221
- };
222
- readonly states: {
223
- readonly idle: {};
224
- readonly active: {
225
- readonly entry: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
226
- elementDetails: {
227
- src: "elementDetails";
228
- logic: ElementDetailsLogic;
229
- id: `elementDetails-${number}`;
230
- };
231
- relationshipsBrowser: {
232
- src: "relationshipsBrowser";
233
- logic: Overlays.RelationshipsBrowser.Logic;
234
- id: `relationshipsBrowser-${number}`;
235
- };
236
- relationshipDetails: {
237
- src: "relationshipDetails";
238
- logic: Overlays.RelationshipDetails.Logic;
239
- id: `relationshipDetails-${number}`;
240
- };
241
- hotkey: {
242
- src: "hotkey";
243
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
244
- id: "hotkey";
245
- };
246
- }>, never, never, never, never>;
247
- readonly exit: StopAction<OverlaysContext, OverlayActorEvent, undefined, OverlayActorEvent>;
248
- readonly on: {
249
- readonly close: readonly [{
250
- readonly guard: "close specific overlay?";
251
- readonly actions: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
252
- elementDetails: {
253
- src: "elementDetails";
254
- logic: ElementDetailsLogic;
255
- id: `elementDetails-${number}`;
256
- };
257
- relationshipsBrowser: {
258
- src: "relationshipsBrowser";
259
- logic: Overlays.RelationshipsBrowser.Logic;
260
- id: `relationshipsBrowser-${number}`;
261
- };
262
- relationshipDetails: {
263
- src: "relationshipDetails";
264
- logic: Overlays.RelationshipDetails.Logic;
265
- id: `relationshipDetails-${number}`;
266
- };
267
- hotkey: {
268
- src: "hotkey";
269
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
270
- id: "hotkey";
271
- };
272
- }>, never, Values<{
273
- "has overlays?": {
274
- type: "has overlays?";
275
- params: unknown;
276
- };
277
- "close specific overlay?": {
278
- type: "close specific overlay?";
279
- params: unknown;
280
- };
281
- "last: is relationshipDetails?": {
282
- type: "last: is relationshipDetails?";
283
- params: unknown;
284
- };
285
- "last: is relationshipsBrowser?": {
286
- type: "last: is relationshipsBrowser?";
287
- params: unknown;
288
- };
289
- }>, never, OverlayActorEmitedEvent>;
290
- readonly target: "closing";
291
- }, {
292
- readonly actions: ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
293
- elementDetails: {
294
- src: "elementDetails";
295
- logic: ElementDetailsLogic;
296
- id: `elementDetails-${number}`;
297
- };
298
- relationshipsBrowser: {
299
- src: "relationshipsBrowser";
300
- logic: Overlays.RelationshipsBrowser.Logic;
301
- id: `relationshipsBrowser-${number}`;
302
- };
303
- relationshipDetails: {
304
- src: "relationshipDetails";
305
- logic: Overlays.RelationshipDetails.Logic;
306
- id: `relationshipDetails-${number}`;
307
- };
308
- hotkey: {
309
- src: "hotkey";
310
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
311
- id: "hotkey";
312
- };
313
- }>, never, Values<{
314
- "has overlays?": {
315
- type: "has overlays?";
316
- params: unknown;
317
- };
318
- "close specific overlay?": {
319
- type: "close specific overlay?";
320
- params: unknown;
321
- };
322
- "last: is relationshipDetails?": {
323
- type: "last: is relationshipDetails?";
324
- params: unknown;
325
- };
326
- "last: is relationshipsBrowser?": {
327
- type: "last: is relationshipsBrowser?";
328
- params: unknown;
329
- };
330
- }>, never, OverlayActorEmitedEvent>;
331
- readonly target: "closing";
332
- }];
333
- readonly 'close.all': {
334
- readonly actions: readonly [ ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
335
- elementDetails: {
336
- src: "elementDetails";
337
- logic: ElementDetailsLogic;
338
- id: `elementDetails-${number}`;
339
- };
340
- relationshipsBrowser: {
341
- src: "relationshipsBrowser";
342
- logic: Overlays.RelationshipsBrowser.Logic;
343
- id: `relationshipsBrowser-${number}`;
344
- };
345
- relationshipDetails: {
346
- src: "relationshipDetails";
347
- logic: Overlays.RelationshipDetails.Logic;
348
- id: `relationshipDetails-${number}`;
349
- };
350
- hotkey: {
351
- src: "hotkey";
352
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
353
- id: "hotkey";
354
- };
355
- }>, never, Values<{
356
- "has overlays?": {
357
- type: "has overlays?";
358
- params: unknown;
359
- };
360
- "close specific overlay?": {
361
- type: "close specific overlay?";
362
- params: unknown;
363
- };
364
- "last: is relationshipDetails?": {
365
- type: "last: is relationshipDetails?";
366
- params: unknown;
367
- };
368
- "last: is relationshipsBrowser?": {
369
- type: "last: is relationshipsBrowser?";
370
- params: unknown;
371
- };
372
- }>, never, OverlayActorEmitedEvent>, StopAction<OverlaysContext, OverlayActorEvent, undefined, OverlayActorEvent>];
373
- readonly target: "idle";
374
- };
375
- };
376
- };
377
- readonly closing: {
378
- readonly always: readonly [{
379
- readonly guard: "has overlays?";
380
- readonly target: "active";
381
- }, {
382
- readonly actions: StopAction<OverlaysContext, OverlayActorEvent, undefined, OverlayActorEvent>;
383
- readonly target: "idle";
384
- }];
385
- };
386
- };
387
- readonly exit: readonly [ StopAction<OverlaysContext, OverlayActorEvent, undefined, OverlayActorEvent>, ActionFunction<OverlaysContext, OverlayActorEvent, OverlayActorEvent, undefined, Values<{
388
- elementDetails: {
389
- src: "elementDetails";
390
- logic: ElementDetailsLogic;
391
- id: `elementDetails-${number}`;
392
- };
393
- relationshipsBrowser: {
394
- src: "relationshipsBrowser";
395
- logic: Overlays.RelationshipsBrowser.Logic;
396
- id: `relationshipsBrowser-${number}`;
397
- };
398
- relationshipDetails: {
399
- src: "relationshipDetails";
400
- logic: Overlays.RelationshipDetails.Logic;
401
- id: `relationshipDetails-${number}`;
402
- };
403
- hotkey: {
404
- src: "hotkey";
405
- logic: CallbackActorLogic<EventObject, NonReducibleUnknown, EventObject>;
406
- id: "hotkey";
407
- };
408
- }>, never, Values<{
409
- "has overlays?": {
410
- type: "has overlays?";
411
- params: unknown;
412
- };
413
- "close specific overlay?": {
414
- type: "close specific overlay?";
415
- params: unknown;
416
- };
417
- "last: is relationshipDetails?": {
418
- type: "last: is relationshipDetails?";
419
- params: unknown;
420
- };
421
- "last: is relationshipsBrowser?": {
422
- type: "last: is relationshipsBrowser?";
423
- params: unknown;
424
- };
425
- }>, never, OverlayActorEmitedEvent>];
426
- }>;
427
- type InferredMachine = typeof _overlaysActorLogic;
428
- export interface OverlaysActorLogic extends InferredMachine {
40
+ export interface OverlaysActorLogic extends StateMachine<OverlaysContext, OverlayActorEvent, {
41
+ [key: `elementDetails-${number}`]: Overlays.ElementDetails.ActorRef | undefined;
42
+ [key: `relationshipDetails-${number}`]: Overlays.RelationshipDetails.ActorRef | undefined;
43
+ [key: `relationshipsBrowser-${number}`]: Overlays.RelationshipsBrowser.ActorRef | undefined;
44
+ }, any, any, any, any, any, never, never, any, OverlayActorEmitedEvent, any, any> {
429
45
  }
430
46
  export declare const overlaysActorLogic: OverlaysActorLogic;
431
47
  export type OverlaysActorSnapshot = SnapshotFrom<OverlaysActorLogic>;
432
- export interface OverlaysActorRef extends ActorRefFromLogic<OverlaysActorLogic> {
48
+ export interface OverlaysActorRef extends ActorRef<OverlaysActorSnapshot, OverlayActorEvent, OverlayActorEmitedEvent> {
433
49
  }
434
- export {};
@@ -4,6 +4,7 @@ import { setup, fromCallback, assertEvent } from 'xstate';
4
4
  import { elementDetailsLogic } from './element-details/actor.js';
5
5
  import { relationshipDetailsLogic } from './relationship-details/actor.js';
6
6
  import { relationshipsBrowserLogic } from './relationships-browser/actor.js';
7
+ import { x as xstateGuards_cjsExports } from '../_virtual/xstate-guards.cjs.js';
7
8
 
8
9
  const hotkeyLogic = fromCallback(({ sendBack }) => {
9
10
  const handler = getHotkeyHandler([
@@ -92,15 +93,16 @@ const openElementDetails = () => machine.enqueueActions(({ context, enqueue, eve
92
93
  const id = `elementDetails-${context.seq}`;
93
94
  enqueue.spawnChild("elementDetails", {
94
95
  id,
95
- input: event
96
+ input: event,
97
+ syncSnapshot: true
96
98
  });
97
99
  enqueue.assign({
98
100
  seq: context.seq + 1,
99
101
  overlays: [
100
102
  ...context.overlays,
101
103
  {
102
- type: "elementDetails",
103
104
  id,
105
+ type: "elementDetails",
104
106
  subject: event.subject
105
107
  }
106
108
  ]
@@ -119,15 +121,16 @@ const openRelationshipDetails = () => machine.enqueueActions(({ context, enqueue
119
121
  const id = `relationshipDetails-${context.seq}`;
120
122
  enqueue.spawnChild("relationshipDetails", {
121
123
  id,
122
- input: event
124
+ input: event,
125
+ syncSnapshot: true
123
126
  });
124
127
  enqueue.assign({
125
128
  seq: context.seq + 1,
126
129
  overlays: [
127
130
  ...context.overlays,
128
131
  {
129
- type: "relationshipDetails",
130
- id
132
+ id,
133
+ type: "relationshipDetails"
131
134
  }
132
135
  ]
133
136
  });
@@ -146,24 +149,50 @@ const openRelationshipsBrowser = () => machine.enqueueActions(({ context, enqueu
146
149
  const id = `relationshipsBrowser-${context.seq}`;
147
150
  enqueue.spawnChild("relationshipsBrowser", {
148
151
  id,
149
- input: event
152
+ input: event,
153
+ syncSnapshot: true
150
154
  });
151
155
  enqueue.assign({
152
156
  seq: context.seq + 1,
153
157
  overlays: [
154
158
  ...context.overlays,
155
159
  {
156
- type: "relationshipsBrowser",
157
160
  id,
161
+ type: "relationshipsBrowser",
158
162
  subject: event.subject
159
163
  }
160
164
  ]
161
165
  });
162
166
  });
167
+ const openOverlay = () => machine.enqueueActions(({ enqueue, event }) => {
168
+ console.log("openOverlay event", event);
169
+ assertEvent(event, [
170
+ "open.elementDetails",
171
+ "open.relationshipDetails",
172
+ "open.relationshipsBrowser"
173
+ ]);
174
+ switch (event.type) {
175
+ case "open.elementDetails":
176
+ enqueue(openElementDetails());
177
+ break;
178
+ case "open.relationshipDetails":
179
+ enqueue(openRelationshipDetails());
180
+ break;
181
+ case "open.relationshipsBrowser":
182
+ enqueue(openRelationshipsBrowser());
183
+ break;
184
+ }
185
+ });
163
186
  const listenToEsc = () => machine.spawnChild("hotkey", {
164
187
  id: "hotkey"
165
188
  });
166
189
  const stopListeningToEsc = () => machine.stopChild("hotkey");
190
+ const checkState = () => machine.enqueueActions(({ enqueue, context }) => {
191
+ if (context.overlays.length === 0) {
192
+ console.log("No overlays left, raising close event");
193
+ enqueue.raise({ type: "close" });
194
+ }
195
+ });
167
196
  const _overlaysActorLogic = machine.createMachine({
168
197
  id: "overlays",
169
198
  context: () => ({
@@ -171,66 +200,61 @@ const _overlaysActorLogic = machine.createMachine({
171
200
  overlays: []
172
201
  }),
173
202
  initial: "idle",
174
- on: {
175
- "open.elementDetails": {
176
- actions: openElementDetails(),
177
- target: ".active",
178
- reenter: false
179
- },
180
- "open.relationshipDetails": {
181
- actions: openRelationshipDetails(),
182
- target: ".active",
183
- reenter: false
184
- },
185
- "open.relationshipsBrowser": {
186
- actions: openRelationshipsBrowser(),
187
- target: ".active",
188
- reenter: false
189
- }
190
- },
191
203
  states: {
192
- idle: {},
204
+ idle: {
205
+ on: {
206
+ "open.*": {
207
+ actions: openOverlay(),
208
+ target: "active"
209
+ }
210
+ }
211
+ },
193
212
  active: {
194
- entry: listenToEsc(),
195
- exit: stopListeningToEsc(),
213
+ entry: [
214
+ listenToEsc()
215
+ ],
216
+ exit: [
217
+ stopListeningToEsc()
218
+ ],
196
219
  on: {
220
+ "open.*": {
221
+ actions: openOverlay()
222
+ },
197
223
  "close": [
224
+ {
225
+ guard: xstateGuards_cjsExports.not("has overlays?"),
226
+ target: "idle"
227
+ },
198
228
  {
199
229
  guard: "close specific overlay?",
200
- actions: closeSpecificOverlay(),
201
- target: "closing"
230
+ actions: [
231
+ closeSpecificOverlay(),
232
+ checkState()
233
+ ]
202
234
  },
203
235
  {
204
- actions: closeLastOverlay(),
205
- target: "closing"
236
+ actions: [
237
+ closeLastOverlay(),
238
+ checkState()
239
+ ]
206
240
  }
207
241
  ],
208
242
  "close.all": {
209
243
  actions: [
210
- closeAllOverlays(),
211
- stopListeningToEsc()
244
+ closeAllOverlays()
212
245
  ],
213
246
  target: "idle"
214
247
  }
215
248
  }
216
249
  },
217
- closing: {
218
- always: [
219
- {
220
- guard: "has overlays?",
221
- target: "active"
222
- },
223
- {
224
- actions: stopListeningToEsc(),
225
- target: "idle"
226
- }
227
- ]
250
+ final: {
251
+ entry: [
252
+ closeAllOverlays(),
253
+ stopListeningToEsc()
254
+ ],
255
+ type: "final"
228
256
  }
229
- },
230
- exit: [
231
- stopListeningToEsc(),
232
- closeAllOverlays()
233
- ]
257
+ }
234
258
  });
235
259
  const overlaysActorLogic = _overlaysActorLogic;
236
260
 
@@ -17,9 +17,9 @@ import { layoutRelationshipDetails } from './layout.js';
17
17
  import { SelectEdge } from './SelectEdge.js';
18
18
  import { RelationshipEdge } from './custom/edgeTypes.js';
19
19
  import { CompoundNode, ElementNode } from './custom/nodeTypes.js';
20
- import IconX from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.0/node_modules/@tabler/icons-react/dist/esm/icons/IconX.js';
21
- import IconChevronLeft from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js';
22
- import IconChevronRight from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js';
20
+ import IconX from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.1/node_modules/@tabler/icons-react/dist/esm/icons/IconX.js';
21
+ import IconChevronLeft from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js';
22
+ import IconChevronRight from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js';
23
23
 
24
24
  const nodeTypes = {
25
25
  element: ElementNode,
@@ -3,8 +3,8 @@ import { Popover, PopoverTarget, Button, Box, Text, ThemeIcon, PopoverDropdown,
3
3
  import { useRef } from 'react';
4
4
  import { useRelationshipDetails } from './hooks.js';
5
5
  import { edgeSource, edgeTarget, scrollArea, edgeGrid, edgeRow, edgeArrow, edgeLabel } from './SelectEdge.css.js';
6
- import IconArrowRight from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.0/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js';
7
- import IconSelector from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.0/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js';
6
+ import IconArrowRight from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.1/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js';
7
+ import IconSelector from '../../node_modules/.pnpm/@tabler_icons-react@3.35.0_react@19.2.1/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js';
8
8
 
9
9
  const SelectEdge = ({
10
10
  edge,
@@ -1,4 +1,4 @@
1
- import { Color, DiagramNode, ExclusiveUnion, Fqn, IconUrl, RelationId, RelationshipArrowType, RelationshipLineType, RichTextOrEmpty, ViewId } from '@likec4/core/types';
1
+ import { Color, DiagramNode, ExclusiveUnion, Fqn, IconUrl, MarkdownOrString, RelationId, RelationshipArrowType, RelationshipLineType, ViewId } from '@likec4/core/types';
2
2
  import { FunctionComponent } from 'react';
3
3
  import { Simplify } from 'type-fest';
4
4
  import { BaseEdge, BaseEdgeData, BaseEdgeProps, BaseNode, BaseNodeData, BaseNodeProps, NonOptional } from '../../base/types';
@@ -11,12 +11,11 @@ export declare namespace RelationshipDetailsTypes {
11
11
  in: string[];
12
12
  out: string[];
13
13
  };
14
- type ElementNodeData = Simplify<BaseNodeData & NonOptional<Pick<DiagramNode, 'id' | 'title' | 'technology' | 'color' | 'shape' | 'width' | 'height' | 'navigateTo' | 'style' | 'tags'>> & {
14
+ type ElementNodeData = Simplify<BaseNodeData & NonOptional<Pick<DiagramNode, 'id' | 'title' | 'technology' | 'description' | 'color' | 'shape' | 'width' | 'height' | 'navigateTo' | 'style' | 'tags'>> & {
15
15
  column: Column;
16
16
  fqn: Fqn;
17
17
  icon: IconUrl;
18
18
  ports: Ports;
19
- description: RichTextOrEmpty;
20
19
  }>;
21
20
  type CompoundNodeData = Simplify<BaseNodeData & NonOptional<Pick<DiagramNode, 'id' | 'title' | 'color' | 'style'>> & {
22
21
  column: Column;
@@ -51,7 +50,7 @@ export declare namespace RelationshipDetailsTypes {
51
50
  line: RelationshipLineType;
52
51
  head?: RelationshipArrowType;
53
52
  tail?: RelationshipArrowType;
54
- description: RichTextOrEmpty;
53
+ description: MarkdownOrString | null;
55
54
  }>;
56
55
  type Edge = BaseEdge<EdgeData, 'relationship'>;
57
56
  type EdgeProps = BaseEdgeProps<Edge>;