@likec4/diagram 1.34.2 → 1.36.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 (404) hide show
  1. package/bundle/{chunk-Dd7et66b.js → chunk-7MPUJFHj.js} +1102 -1172
  2. package/bundle/custom.js +59 -55
  3. package/bundle/index.js +8918 -5681
  4. package/dist/LikeC4Diagram.js +6 -6
  5. package/dist/LikeC4Diagram.props.d.ts +53 -7
  6. package/dist/LikeC4ModelProvider.d.ts +4 -4
  7. package/dist/LikeC4ProjectsProvider.d.ts +17 -0
  8. package/dist/LikeC4ProjectsProvider.js +22 -0
  9. package/dist/LikeC4Styles.d.ts +1 -0
  10. package/dist/LikeC4Styles.js +94 -0
  11. package/dist/StaticLikeC4Diagram.d.ts +3 -3
  12. package/dist/base/BaseXYFlow.d.ts +2 -2
  13. package/dist/base/BaseXYFlow.js +26 -29
  14. package/dist/base/primitives/MarkdownBlock.d.ts +7 -1
  15. package/dist/base/primitives/MarkdownBlock.js +1 -1
  16. package/dist/base/primitives/compound/CompoundActionButton.js +3 -3
  17. package/dist/base/primitives/compound/CompoundDetailsButton.js +3 -3
  18. package/dist/base/primitives/compound/CompoundNodeContainer.css.js +4 -4
  19. package/dist/base/primitives/compound/CompoundNodeContainer.js +1 -4
  20. package/dist/base/primitives/compound/CompoundTitle.js +9 -8
  21. package/dist/base/primitives/compound/actionbtns.css.js +6 -6
  22. package/dist/base/primitives/edge/EdgeActionButton.js +3 -3
  23. package/dist/base/primitives/edge/EdgeContainer.js +4 -7
  24. package/dist/base/primitives/edge/EdgeLabel.css.d.ts +0 -22
  25. package/dist/base/primitives/edge/EdgeLabel.css.js +6 -84
  26. package/dist/base/primitives/edge/EdgeLabel.js +16 -6
  27. package/dist/base/primitives/edge/EdgeLabelContainer.js +1 -6
  28. package/dist/base/primitives/edge/EdgeMarkers.js +3 -3
  29. package/dist/base/primitives/edge/edge.css.d.ts +0 -2
  30. package/dist/base/primitives/edge/edge.css.js +1 -55
  31. package/dist/base/primitives/element/ElementActionButtons.js +2 -2
  32. package/dist/base/primitives/element/ElementDetailsButton.js +9 -8
  33. package/dist/base/primitives/element/ElementNodeContainer.css.js +4 -4
  34. package/dist/base/primitives/element/ElementNodeContainer.d.ts +3 -3
  35. package/dist/base/primitives/element/ElementNodeContainer.js +1 -4
  36. package/dist/base/primitives/element/ElementShape.css.js +11 -11
  37. package/dist/base/primitives/element/ElementTags.d.ts +1 -0
  38. package/dist/base/primitives/element/ElementTags.js +17 -14
  39. package/dist/base/primitives/element/ElementTitle.js +9 -9
  40. package/dist/bundle/LikeC4View.d.ts +1 -1
  41. package/dist/bundle/LikeC4View.js +10 -4
  42. package/dist/bundle/LikeC4View.props.d.ts +9 -6
  43. package/dist/bundle/ReactLikeC4.d.ts +1 -1
  44. package/dist/bundle/ViewNotFound.js +1 -1
  45. package/dist/bundle/custom.js +1 -0
  46. package/dist/bundle/index.d.ts +2 -1
  47. package/dist/bundle/index.js +2 -0
  48. package/dist/bundle/styles.css.js +1 -1
  49. package/dist/components/ErrorFallback.d.ts +2 -1
  50. package/dist/components/ErrorFallback.js +16 -3
  51. package/dist/components/GithubIcon.d.ts +2 -0
  52. package/dist/components/GithubIcon.js +17 -0
  53. package/dist/components/Link.d.ts +4 -3
  54. package/dist/components/Link.js +86 -89
  55. package/dist/components/NavigationLink.d.ts +6 -0
  56. package/dist/components/NavigationLink.js +25 -0
  57. package/dist/components/SearchControl.css.js +6 -5
  58. package/dist/components/SearchControl.js +1 -1
  59. package/dist/context/ControlsCustomLayout.d.ts +0 -1
  60. package/dist/context/DiagramEventHandlers.d.ts +6 -6
  61. package/dist/context/DiagramEventHandlers.js +4 -7
  62. package/dist/context/DiagramFeatures.d.ts +4 -1
  63. package/dist/context/IconRenderer.js +6 -6
  64. package/dist/custom/customNodes.js +10 -2
  65. package/dist/custom/hooks.d.ts +1 -0
  66. package/dist/custom/index.js +1 -0
  67. package/dist/globals.css.js +3 -0
  68. package/dist/hooks/useDiagram.d.ts +1 -2
  69. package/dist/hooks/useDiagram.js +1 -5
  70. package/dist/hooks/useXYFlow.d.ts +10 -10
  71. package/dist/index.d.ts +1 -0
  72. package/dist/index.js +2 -0
  73. package/dist/likec4diagram/DiagramUI.js +8 -4
  74. package/dist/likec4diagram/DiagramXYFlow.js +1 -1
  75. package/dist/likec4diagram/custom/edges/NotePopover.css.js +2 -2
  76. package/dist/likec4diagram/custom/edges/RelationshipEdge.d.ts +2 -2
  77. package/dist/likec4diagram/custom/edges/RelationshipEdge.js +1 -1
  78. package/dist/likec4diagram/custom/edges/RelationshipsDropdownMenu.css.js +7 -7
  79. package/dist/likec4diagram/custom/edges/RelationshipsDropdownMenu.js +7 -7
  80. package/dist/likec4diagram/custom/edges/edges.css.js +4 -4
  81. package/dist/likec4diagram/custom/index.d.ts +2 -2
  82. package/dist/likec4diagram/custom/nodes/ElementActions.js +2 -2
  83. package/dist/likec4diagram/custom/nodes/toolbar/CompoundToolbar.js +2 -2
  84. package/dist/likec4diagram/custom/nodes/toolbar/ElementToolbar.js +2 -2
  85. package/dist/likec4diagram/custom/nodes/toolbar/_shared.js +2 -2
  86. package/dist/likec4diagram/ui/controls/ChangeAutoLayoutButton.js +1 -1
  87. package/dist/likec4diagram/ui/controls/Controls.js +11 -15
  88. package/dist/likec4diagram/ui/controls/LayoutDriftNotification.js +1 -1
  89. package/dist/likec4diagram/ui/controls/ManualLayoutToolsButton.js +9 -9
  90. package/dist/likec4diagram/ui/controls/NavigationButtons.js +4 -2
  91. package/dist/likec4diagram/ui/controls/ToggleReadonly.js +2 -2
  92. package/dist/likec4diagram/ui/controls/styles.css.js +5 -5
  93. package/dist/likec4diagram/ui/diagram-title/DiagramTitlePanel.js +15 -13
  94. package/dist/likec4diagram/ui/notation/NotationPanel.css.js +11 -11
  95. package/dist/likec4diagram/ui/notation/NotationPanel.js +5 -8
  96. package/dist/likec4diagram/ui/walkthrough/DynamicViewWalkthrough.css.js +10 -10
  97. package/dist/likec4diagram/ui/walkthrough/DynamicViewWalkthrough.js +4 -4
  98. package/dist/likec4model/LikeC4ModelContext.d.ts +4 -1
  99. package/dist/likec4model/LikeC4ModelContext.js +2 -1
  100. package/dist/likec4model/LikeC4ProjectsContext.d.ts +7 -0
  101. package/dist/likec4model/LikeC4ProjectsContext.js +5 -0
  102. package/dist/likec4model/index.d.ts +2 -0
  103. package/dist/likec4model/useCurrentViewModel.d.ts +2 -0
  104. package/dist/likec4model/useCurrentViewModel.js +12 -0
  105. package/dist/likec4model/useLikeC4Model.d.ts +2 -5
  106. package/dist/likec4model/useLikeC4Model.js +10 -16
  107. package/dist/likec4model/useLikeC4Project.d.ts +22 -0
  108. package/dist/likec4model/useLikeC4Project.js +23 -0
  109. package/dist/navigationpanel/NavigationPanel.d.ts +2 -0
  110. package/dist/navigationpanel/NavigationPanel.js +122 -0
  111. package/dist/navigationpanel/NavigationPanelControls.d.ts +1 -0
  112. package/dist/navigationpanel/NavigationPanelControls.js +147 -0
  113. package/dist/navigationpanel/NavigationPanelDropdown.d.ts +1 -0
  114. package/dist/navigationpanel/NavigationPanelDropdown.js +452 -0
  115. package/dist/navigationpanel/_common.d.ts +15 -0
  116. package/dist/navigationpanel/_common.js +72 -0
  117. package/dist/navigationpanel/actor.d.ts +296 -0
  118. package/dist/navigationpanel/actor.js +239 -0
  119. package/dist/navigationpanel/controls/BurgerButton.d.ts +1 -0
  120. package/dist/navigationpanel/controls/BurgerButton.js +34 -0
  121. package/dist/navigationpanel/controls/NavigationButtons.d.ts +1 -0
  122. package/dist/navigationpanel/controls/NavigationButtons.js +57 -0
  123. package/dist/navigationpanel/controls/OpenSource.d.ts +1 -0
  124. package/dist/navigationpanel/controls/OpenSource.js +27 -0
  125. package/dist/navigationpanel/controls/SearchControl.d.ts +1 -0
  126. package/dist/navigationpanel/controls/SearchControl.js +70 -0
  127. package/dist/navigationpanel/controls/ToggleReadonly.d.ts +1 -0
  128. package/dist/navigationpanel/controls/ToggleReadonly.js +69 -0
  129. package/dist/navigationpanel/controls/ViewDetailsCard.d.ts +2 -0
  130. package/dist/navigationpanel/controls/ViewDetailsCard.js +232 -0
  131. package/dist/navigationpanel/controls/index.d.ts +6 -0
  132. package/dist/navigationpanel/dropdown/ProjectsMenu.d.ts +2 -0
  133. package/dist/navigationpanel/dropdown/ProjectsMenu.js +75 -0
  134. package/dist/navigationpanel/editorpanel/CenterCamera.d.ts +1 -0
  135. package/dist/navigationpanel/editorpanel/CenterCamera.js +12 -0
  136. package/dist/navigationpanel/editorpanel/ChangeAutoLayoutButton.d.ts +1 -0
  137. package/dist/navigationpanel/editorpanel/ChangeAutoLayoutButton.js +157 -0
  138. package/dist/navigationpanel/editorpanel/EditorPanel.d.ts +1 -0
  139. package/dist/navigationpanel/editorpanel/EditorPanel.js +48 -0
  140. package/dist/navigationpanel/editorpanel/LayoutDriftNotification.d.ts +1 -0
  141. package/dist/navigationpanel/editorpanel/LayoutDriftNotification.js +56 -0
  142. package/dist/navigationpanel/editorpanel/ManualLayoutToolsButton.d.ts +2 -0
  143. package/dist/navigationpanel/editorpanel/ManualLayoutToolsButton.js +173 -0
  144. package/dist/navigationpanel/editorpanel/_common.d.ts +6 -0
  145. package/dist/navigationpanel/editorpanel/_common.js +14 -0
  146. package/dist/navigationpanel/editorpanel/index.d.ts +1 -0
  147. package/dist/navigationpanel/editorpanel/styles.d.ts +8 -0
  148. package/dist/navigationpanel/editorpanel/styles.js +79 -0
  149. package/dist/navigationpanel/hooks.d.ts +20 -0
  150. package/dist/navigationpanel/hooks.js +38 -0
  151. package/dist/navigationpanel/index.d.ts +1 -0
  152. package/dist/navigationpanel/styles.css.d.ts +16 -0
  153. package/dist/navigationpanel/styles.css.js +30 -0
  154. package/dist/navigationpanel/walkthrough/ActiveWalkthroughControls.d.ts +2 -0
  155. package/dist/navigationpanel/walkthrough/ActiveWalkthroughControls.js +162 -0
  156. package/dist/navigationpanel/walkthrough/index.d.ts +1 -0
  157. package/dist/node_modules/.pnpm/{@tabler_icons-react@3.31.0_react@19.1.0 → @tabler_icons-react@3.34.1_react@19.1.1}/node_modules/@tabler/icons-react/dist/esm/createReactComponent.js +1 -1
  158. package/dist/node_modules/.pnpm/{@tabler_icons-react@3.31.0_react@19.1.0 → @tabler_icons-react@3.34.1_react@19.1.1}/node_modules/@tabler/icons-react/dist/esm/defaultAttributes.js +1 -1
  159. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconAlertTriangle.js +14 -0
  160. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowDownRight.js +14 -0
  161. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowLeft.js +14 -0
  162. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js +14 -0
  163. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconBrowser.js +14 -0
  164. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js +14 -0
  165. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronDown.js +14 -0
  166. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js +14 -0
  167. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js +14 -0
  168. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconCopy.js +14 -0
  169. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconCylinder.js +14 -0
  170. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconDeviceMobile.js +14 -0
  171. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconExternalLink.js +14 -0
  172. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js +14 -0
  173. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFocusCentered.js +14 -0
  174. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFolderFilled.js +14 -0
  175. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconHelpCircle.js +14 -0
  176. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconId.js +14 -0
  177. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconInfoCircle.js +14 -0
  178. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignBottom.js +14 -0
  179. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignCenter.js +14 -0
  180. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignLeft.js +14 -0
  181. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignMiddle.js +14 -0
  182. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignRight.js +14 -0
  183. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignTop.js +14 -0
  184. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutBoardSplit.js +14 -0
  185. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutCollage.js +14 -0
  186. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutDashboard.js +14 -0
  187. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLink.js +14 -0
  188. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLock.js +14 -0
  189. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLockOpen2.js +14 -0
  190. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu.js +14 -0
  191. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu2.js +14 -0
  192. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerPlayFilled.js +14 -0
  193. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipBackFilled.js +14 -0
  194. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipForwardFilled.js +14 -0
  195. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerStopFilled.js +14 -0
  196. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconRectangularPrism.js +14 -0
  197. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconReorder.js +14 -0
  198. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconRouteOff.js +14 -0
  199. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.js +14 -0
  200. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js +14 -0
  201. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconStack2.js +14 -0
  202. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconStarFilled.js +14 -0
  203. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconTarget.js +14 -0
  204. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js +14 -0
  205. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconUser.js +14 -0
  206. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconX.js +14 -0
  207. package/dist/node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js +14 -0
  208. package/dist/overlays/element-details/ElementDetailsCard.css.js +18 -17
  209. package/dist/overlays/element-details/ElementDetailsCard.js +12 -17
  210. package/dist/overlays/element-details/TabPanelDeployments.css.js +5 -4
  211. package/dist/overlays/element-details/TabPanelDeployments.js +3 -3
  212. package/dist/overlays/element-details/TabPanelRelationships.css.js +7 -7
  213. package/dist/overlays/element-details/TabPanelRelationships.js +3 -3
  214. package/dist/overlays/element-details/TabPanelStructure.js +1 -1
  215. package/dist/overlays/overlay/Overlay.css.d.ts +3 -3
  216. package/dist/overlays/overlay/Overlay.css.js +8 -7
  217. package/dist/overlays/relationship-details/RelationshipDetails.js +3 -3
  218. package/dist/overlays/relationship-details/SelectEdge.css.js +8 -8
  219. package/dist/overlays/relationship-details/SelectEdge.js +2 -2
  220. package/dist/overlays/relationship-details/custom/ElementActions.js +3 -3
  221. package/dist/overlays/relationships-browser/RelationshipsBrowser.js +3 -3
  222. package/dist/overlays/relationships-browser/SelectElement.css.js +1 -1
  223. package/dist/overlays/relationships-browser/SelectElement.js +2 -2
  224. package/dist/overlays/relationships-browser/custom/ElementActions.js +3 -3
  225. package/dist/search/Search.js +6 -6
  226. package/dist/search/components/ElementsColumn.css.js +5 -5
  227. package/dist/search/components/ElementsColumn.js +1 -1
  228. package/dist/search/components/PickView.js +1 -1
  229. package/dist/search/components/SearchByTags.js +4 -3
  230. package/dist/search/components/SearchInput.js +1 -1
  231. package/dist/search/components/ViewsColum.js +3 -3
  232. package/dist/search/components/ViewsColumn.css.js +1 -1
  233. package/dist/search/components/_shared.css.js +3 -3
  234. package/dist/search/components/styles.css.js +5 -5
  235. package/dist/state/DiagramActorProvider.d.ts +2 -2
  236. package/dist/state/DiagramActorProvider.js +82 -25
  237. package/dist/state/diagram-machine.d.ts +31 -249
  238. package/dist/state/diagram-machine.js +16 -16
  239. package/dist/styles-min.css +1 -1
  240. package/dist/styles.css +1 -1
  241. package/dist/styles.css2.js +1 -1
  242. package/package.json +20 -17
  243. package/panda.buildinfo.json +368 -404
  244. package/src/LikeC4Diagram.props.ts +53 -5
  245. package/src/LikeC4Diagram.tsx +2 -2
  246. package/src/LikeC4ModelProvider.tsx +6 -6
  247. package/src/LikeC4ProjectsProvider.tsx +41 -0
  248. package/src/LikeC4Styles.tsx +107 -0
  249. package/src/StaticLikeC4Diagram.tsx +3 -3
  250. package/src/base/BaseXYFlow.tsx +28 -33
  251. package/src/base/primitives/MarkdownBlock.tsx +11 -3
  252. package/src/base/primitives/compound/CompoundActionButton.tsx +2 -2
  253. package/src/base/primitives/compound/CompoundDetailsButton.tsx +2 -2
  254. package/src/base/primitives/compound/CompoundNodeContainer.css.ts +4 -13
  255. package/src/base/primitives/compound/CompoundNodeContainer.tsx +0 -3
  256. package/src/base/primitives/compound/CompoundTitle.tsx +8 -8
  257. package/src/base/primitives/compound/actionbtns.css.ts +6 -6
  258. package/src/base/primitives/edge/EdgeActionButton.tsx +2 -2
  259. package/src/base/primitives/edge/EdgeContainer.tsx +3 -6
  260. package/src/base/primitives/edge/EdgeLabel.css.ts +4 -83
  261. package/src/base/primitives/edge/EdgeLabel.tsx +16 -10
  262. package/src/base/primitives/edge/EdgeLabelContainer.tsx +1 -6
  263. package/src/base/primitives/edge/EdgeMarkers.tsx +3 -3
  264. package/src/base/primitives/edge/edge.css.ts +0 -60
  265. package/src/base/primitives/element/ElementActionButtons.tsx +2 -2
  266. package/src/base/primitives/element/ElementDetailsButton.tsx +7 -7
  267. package/src/base/primitives/element/ElementNodeContainer.css.ts +4 -4
  268. package/src/base/primitives/element/ElementNodeContainer.tsx +2 -5
  269. package/src/base/primitives/element/ElementShape.css.ts +11 -11
  270. package/src/base/primitives/element/ElementTags.tsx +17 -14
  271. package/src/base/primitives/element/ElementTitle.tsx +4 -4
  272. package/src/bundle/LikeC4View.props.ts +15 -6
  273. package/src/bundle/LikeC4View.tsx +12 -5
  274. package/src/bundle/ReactLikeC4.tsx +1 -2
  275. package/src/bundle/ViewNotFound.tsx +1 -1
  276. package/src/bundle/index.ts +2 -1
  277. package/src/bundle/styles.css.ts +1 -1
  278. package/src/components/ErrorFallback.tsx +17 -2
  279. package/src/components/GithubIcon.tsx +16 -0
  280. package/src/components/Link.tsx +102 -113
  281. package/src/components/NavigationLink.tsx +32 -0
  282. package/src/components/SearchControl.css.ts +5 -5
  283. package/src/context/ControlsCustomLayout.ts +0 -1
  284. package/src/context/DiagramEventHandlers.tsx +12 -12
  285. package/src/context/DiagramFeatures.tsx +6 -1
  286. package/src/custom/customNodes.tsx +10 -2
  287. package/src/custom/hooks.ts +3 -0
  288. package/src/globals.css +71 -0
  289. package/src/hooks/useDiagram.ts +0 -8
  290. package/src/index.ts +5 -0
  291. package/src/likec4diagram/DiagramUI.tsx +9 -3
  292. package/src/likec4diagram/DiagramXYFlow.tsx +1 -1
  293. package/src/likec4diagram/custom/edges/NotePopover.css.ts +2 -2
  294. package/src/likec4diagram/custom/edges/RelationshipEdge.tsx +1 -1
  295. package/src/likec4diagram/custom/edges/RelationshipsDropdownMenu.css.ts +7 -7
  296. package/src/likec4diagram/custom/edges/RelationshipsDropdownMenu.tsx +3 -3
  297. package/src/likec4diagram/custom/edges/edges.css.ts +4 -4
  298. package/src/likec4diagram/custom/nodes/toolbar/CompoundToolbar.tsx +2 -2
  299. package/src/likec4diagram/ui/controls/Controls.tsx +8 -18
  300. package/src/likec4diagram/ui/controls/NavigationButtons.tsx +2 -0
  301. package/src/likec4diagram/ui/controls/styles.css.ts +5 -5
  302. package/src/likec4diagram/ui/diagram-title/DiagramTitlePanel.tsx +14 -11
  303. package/src/likec4diagram/ui/notation/NotationPanel.css.ts +11 -11
  304. package/src/likec4diagram/ui/notation/NotationPanel.tsx +1 -4
  305. package/src/likec4diagram/ui/walkthrough/DynamicViewWalkthrough.css.ts +10 -10
  306. package/src/likec4model/LikeC4ModelContext.ts +5 -1
  307. package/src/likec4model/LikeC4ProjectsContext.ts +9 -0
  308. package/src/likec4model/index.ts +11 -0
  309. package/src/likec4model/useCurrentViewModel.ts +10 -0
  310. package/src/likec4model/useLikeC4Model.ts +17 -27
  311. package/src/likec4model/useLikeC4Project.ts +61 -0
  312. package/src/navigationpanel/NavigationPanel.tsx +135 -0
  313. package/src/navigationpanel/NavigationPanelControls.tsx +133 -0
  314. package/src/navigationpanel/NavigationPanelDropdown.tsx +539 -0
  315. package/src/navigationpanel/_common.tsx +84 -0
  316. package/src/navigationpanel/actor.ts +320 -0
  317. package/src/navigationpanel/controls/BurgerButton.tsx +30 -0
  318. package/src/navigationpanel/controls/NavigationButtons.tsx +44 -0
  319. package/src/navigationpanel/controls/OpenSource.tsx +28 -0
  320. package/src/navigationpanel/controls/SearchControl.tsx +66 -0
  321. package/src/navigationpanel/controls/ToggleReadonly.tsx +66 -0
  322. package/src/navigationpanel/controls/ViewDetailsCard.tsx +244 -0
  323. package/src/navigationpanel/controls/index.ts +6 -0
  324. package/src/navigationpanel/dropdown/ProjectsMenu.tsx +74 -0
  325. package/src/navigationpanel/editorpanel/CenterCamera.tsx +15 -0
  326. package/src/navigationpanel/editorpanel/ChangeAutoLayoutButton.tsx +199 -0
  327. package/src/navigationpanel/editorpanel/EditorPanel.tsx +49 -0
  328. package/src/navigationpanel/editorpanel/LayoutDriftNotification.tsx +56 -0
  329. package/src/navigationpanel/editorpanel/ManualLayoutToolsButton.tsx +148 -0
  330. package/src/navigationpanel/editorpanel/_common.tsx +14 -0
  331. package/src/navigationpanel/editorpanel/index.ts +1 -0
  332. package/src/navigationpanel/editorpanel/styles.ts +84 -0
  333. package/src/navigationpanel/hooks.tsx +70 -0
  334. package/src/navigationpanel/index.ts +1 -0
  335. package/src/navigationpanel/styles.css.ts +28 -0
  336. package/src/navigationpanel/walkthrough/ActiveWalkthroughControls.tsx +165 -0
  337. package/src/navigationpanel/walkthrough/index.tsx +1 -0
  338. package/src/overlays/element-details/ElementDetailsCard.css.ts +17 -17
  339. package/src/overlays/element-details/ElementDetailsCard.tsx +8 -13
  340. package/src/overlays/element-details/TabPanelDeployments.css.ts +4 -4
  341. package/src/overlays/element-details/TabPanelRelationships.css.ts +7 -7
  342. package/src/overlays/overlay/Overlay.css.ts +7 -7
  343. package/src/overlays/relationship-details/SelectEdge.css.ts +8 -8
  344. package/src/overlays/relationships-browser/SelectElement.css.ts +1 -1
  345. package/src/search/Search.tsx +6 -6
  346. package/src/search/components/ElementsColumn.css.ts +5 -5
  347. package/src/search/components/SearchByTags.tsx +2 -2
  348. package/src/search/components/ViewsColum.tsx +1 -1
  349. package/src/search/components/ViewsColumn.css.ts +1 -1
  350. package/src/search/components/_shared.css.ts +3 -3
  351. package/src/search/components/styles.css.ts +5 -5
  352. package/src/state/DiagramActorProvider.tsx +104 -31
  353. package/src/state/diagram-machine.ts +24 -18
  354. package/dist/LikeC4CustomColors.d.ts +0 -2
  355. package/dist/LikeC4CustomColors.js +0 -45
  356. package/dist/base/primitives/element/ElementTitle.css.d.ts +0 -34
  357. package/dist/base/primitives/element/ElementTitle.css.js +0 -201
  358. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconAlertTriangle.js +0 -13
  359. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowDownRight.js +0 -13
  360. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js +0 -13
  361. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconBrowser.js +0 -13
  362. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js +0 -13
  363. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js +0 -13
  364. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js +0 -13
  365. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconCopy.js +0 -13
  366. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconCylinder.js +0 -13
  367. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconDeviceMobile.js +0 -13
  368. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconExternalLink.js +0 -13
  369. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js +0 -13
  370. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFocusCentered.js +0 -13
  371. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconHelpCircle.js +0 -13
  372. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconId.js +0 -13
  373. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconInfoCircle.js +0 -13
  374. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignBottom.js +0 -13
  375. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignCenter.js +0 -13
  376. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignLeft.js +0 -13
  377. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignMiddle.js +0 -13
  378. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignRight.js +0 -13
  379. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignTop.js +0 -13
  380. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutBoardSplit.js +0 -13
  381. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutCollage.js +0 -13
  382. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutDashboard.js +0 -13
  383. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLock.js +0 -13
  384. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLockOpen2.js +0 -13
  385. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu.js +0 -13
  386. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu2.js +0 -13
  387. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerPlayFilled.js +0 -13
  388. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipBackFilled.js +0 -13
  389. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerSkipForwardFilled.js +0 -13
  390. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconPlayerStopFilled.js +0 -13
  391. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconRectangularPrism.js +0 -13
  392. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconReorder.js +0 -13
  393. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconRouteOff.js +0 -13
  394. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconSearch.js +0 -13
  395. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js +0 -13
  396. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconStack2.js +0 -13
  397. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconTarget.js +0 -13
  398. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js +0 -13
  399. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconUser.js +0 -13
  400. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconX.js +0 -13
  401. package/dist/node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js +0 -13
  402. package/dist/overlays/relationships-browser/custom/nodeTypes.d.ts +0 -45
  403. package/src/LikeC4CustomColors.tsx +0 -85
  404. package/src/base/primitives/element/ElementTitle.css.ts +0 -206
@@ -0,0 +1,3 @@
1
+ const globalsCss = ".likec4-root{overflow:hidden;position:relative;padding:0;margin:0;width:100%;height:100%;border:0px solid transparent;container-name:likec4-root;container-type:size}.likec4-root .react-flow:is(.not-initialized){opacity:0}:where(.likec4-root .mantine-ActionIcon-icon) .tabler-icon{width:75%;height:75%}.likec4-root :where(.react-flow__node,.react-flow__edge,.likec4-edge-label-container):has([data-likec4-dimmed]){opacity:.25}.likec4-root:not([data-likec4-reduced-graphics]) :where(.react-flow__node,.react-flow__edge,.likec4-edge-label-container):has([data-likec4-dimmed]){filter:grayscale(85%) blur(3px)}.likec4-root:not([data-likec4-reduced-graphics]) :where(.react-flow__node,.react-flow__edge,.likec4-edge-label-container):has([data-likec4-dimmed=true]){transition-property:opacity,filter;transition-timing-function:cubic-bezier(.5,0,.2,1);transition-duration:.6s}[data-mantine-color-scheme=dark] .likec4-root:not([data-likec4-reduced-graphics]) :where(.react-flow__edges,.react-flow__edgelabel-renderer)>svg{mix-blend-mode:plus-lighter}[data-mantine-color-scheme=light] .likec4-root:not([data-likec4-reduced-graphics]) :where(.react-flow__edges,.react-flow__edgelabel-renderer)>svg{mix-blend-mode:screen}.likec4-root :where(.likec4-edge-container,.likec4-edge-label-container){--xy-edge-stroke-width: 3;--xy-edge-stroke: var(--likec4-palette-relation-stroke);--xy-edge-stroke-selected: var(--likec4-palette-relation-stroke-selected);--xy-edge-label-color: var(--likec4-palette-relation-label);--xy-edge-label-background-color: var(--likec4-palette-relation-label-bg)}.likec4-root :where(.likec4-edge-container,.likec4-edge-label-container):is([data-likec4-hovered=true],[data-edge-active=true]){--xy-edge-stroke-width: 4;--xy-edge-stroke: var(--likec4-palette-relation-stroke-selected)}[data-mantine-color-scheme=dark] .likec4-root :where(.likec4-edge-container,.likec4-edge-label-container){--xy-edge-label-background-color: color-mix(in srgb, var(--likec4-palette-relation-label-bg) 50%, transparent)}[data-mantine-color-scheme=light] .likec4-root :where(.likec4-edge-container,.likec4-edge-label-container){--xy-edge-label-color: color-mix(in srgb, var(--likec4-palette-relation-label), rgba(255 255 255 / .85) 40%);--xy-edge-label-background-color: color-mix(in srgb, var(--likec4-palette-relation-label-bg) 60%, transparent)}";
2
+
3
+ export { globalsCss as default };
@@ -5,7 +5,7 @@ import { FeatureName } from '../context/DiagramFeatures';
5
5
  import { OpenSourceParams } from '../LikeC4Diagram.props';
6
6
  import { Types } from '../likec4diagram/types';
7
7
  import { AlignmentMode } from '../state/aligners';
8
- import { DiagramActorEvent, DiagramActorRef, DiagramActorSnapshot, DiagramContext, SyncLayoutActorSnapshot } from '../state/types';
8
+ import { DiagramActorEvent, DiagramActorRef, DiagramActorSnapshot, DiagramContext } from '../state/types';
9
9
  import { useDiagramActorRef } from './safeContext';
10
10
  export { useDiagramActorRef };
11
11
  export interface DiagramApi {
@@ -95,7 +95,6 @@ export interface DiagramApi {
95
95
  */
96
96
  export declare function useDiagram(): DiagramApi;
97
97
  export declare function useDiagramActorSnapshot<T = unknown>(selector: (state: DiagramActorSnapshot) => T, compare?: (a: NoInfer<T>, b: NoInfer<T>) => boolean): T;
98
- export declare function useDiagramSyncLayoutState<T = unknown>(selector: (state: SyncLayoutActorSnapshot) => T, compare?: (a: NoInfer<T>, b: NoInfer<T>) => boolean): T;
99
98
  /**
100
99
  * Read diagram context
101
100
  */
@@ -122,14 +122,10 @@ function useDiagramActorSnapshot(selector, compare = shallowEqual) {
122
122
  const actorRef = useDiagramActorRef();
123
123
  return useSelector(actorRef, useCallbackRef(selector), compare);
124
124
  }
125
- function useDiagramSyncLayoutState(selector, compare = shallowEqual) {
126
- const syncLayoutActorRef = useDiagramActorSnapshot((s) => s.context.syncLayoutActorRef);
127
- return useSelector(syncLayoutActorRef, useCallbackRef(selector), compare);
128
- }
129
125
  function useDiagramContext(selector, compare = shallowEqual, deps) {
130
126
  const actorRef = useDiagramActorRef();
131
127
  const select = useCallback((s) => selector(s.context), deps ?? []);
132
128
  return useSelector(actorRef, select, compare);
133
129
  }
134
130
 
135
- export { useDiagram, useDiagramActorRef, useDiagramActorSnapshot, useDiagramContext, useDiagramSyncLayoutState };
131
+ export { useDiagram, useDiagramActorRef, useDiagramActorSnapshot, useDiagramContext };
@@ -3,7 +3,7 @@ import { Types } from '../likec4diagram/types';
3
3
  import { EdgeMarkerType, HandleType, XYPosition } from '@xyflow/system';
4
4
  import { ReactNode, CSSProperties } from 'react';
5
5
  import { Dimmed } from '../base/types.Base';
6
- import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId } from '@likec4/core';
6
+ import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId, MarkdownOrString } from '@likec4/core';
7
7
  export declare const useXYFlow: () => ReactFlowInstance<Types.Node, {
8
8
  id: string;
9
9
  source: string;
@@ -46,7 +46,7 @@ export declare const useXYFlow: () => ReactFlowInstance<Types.Node, {
46
46
  tail: RelationshipArrowType | undefined;
47
47
  labelBBox: BBox | null | undefined;
48
48
  navigateTo: ViewId<string> | null | undefined;
49
- notes: string | undefined;
49
+ notes: MarkdownOrString | undefined;
50
50
  labelXY: XYPosition | null;
51
51
  controlPoints: XYPosition[] | undefined | null;
52
52
  };
@@ -96,7 +96,7 @@ export declare const useXYStoreApi: () => {
96
96
  tail: RelationshipArrowType | undefined;
97
97
  labelBBox: BBox | null | undefined;
98
98
  navigateTo: ViewId<string> | null | undefined;
99
- notes: string | undefined;
99
+ notes: MarkdownOrString | undefined;
100
100
  labelXY: XYPosition | null;
101
101
  controlPoints: XYPosition[] | undefined | null;
102
102
  };
@@ -143,7 +143,7 @@ export declare const useXYStoreApi: () => {
143
143
  tail: RelationshipArrowType | undefined;
144
144
  labelBBox: BBox | null | undefined;
145
145
  navigateTo: ViewId<string> | null | undefined;
146
- notes: string | undefined;
146
+ notes: MarkdownOrString | undefined;
147
147
  labelXY: XYPosition | null;
148
148
  controlPoints: XYPosition[] | undefined | null;
149
149
  };
@@ -189,7 +189,7 @@ export declare const useXYStoreApi: () => {
189
189
  tail: RelationshipArrowType | undefined;
190
190
  labelBBox: BBox | null | undefined;
191
191
  navigateTo: ViewId<string> | null | undefined;
192
- notes: string | undefined;
192
+ notes: MarkdownOrString | undefined;
193
193
  labelXY: XYPosition | null;
194
194
  controlPoints: XYPosition[] | undefined | null;
195
195
  };
@@ -235,7 +235,7 @@ export declare const useXYStoreApi: () => {
235
235
  tail: RelationshipArrowType | undefined;
236
236
  labelBBox: BBox | null | undefined;
237
237
  navigateTo: ViewId<string> | null | undefined;
238
- notes: string | undefined;
238
+ notes: MarkdownOrString | undefined;
239
239
  labelXY: XYPosition | null;
240
240
  controlPoints: XYPosition[] | undefined | null;
241
241
  };
@@ -281,7 +281,7 @@ export declare const useXYStoreApi: () => {
281
281
  tail: RelationshipArrowType | undefined;
282
282
  labelBBox: BBox | null | undefined;
283
283
  navigateTo: ViewId<string> | null | undefined;
284
- notes: string | undefined;
284
+ notes: MarkdownOrString | undefined;
285
285
  labelXY: XYPosition | null;
286
286
  controlPoints: XYPosition[] | undefined | null;
287
287
  };
@@ -327,7 +327,7 @@ export declare const useXYStoreApi: () => {
327
327
  tail: RelationshipArrowType | undefined;
328
328
  labelBBox: BBox | null | undefined;
329
329
  navigateTo: ViewId<string> | null | undefined;
330
- notes: string | undefined;
330
+ notes: MarkdownOrString | undefined;
331
331
  labelXY: XYPosition | null;
332
332
  controlPoints: XYPosition[] | undefined | null;
333
333
  };
@@ -374,7 +374,7 @@ export declare const useXYStoreApi: () => {
374
374
  tail: RelationshipArrowType | undefined;
375
375
  labelBBox: BBox | null | undefined;
376
376
  navigateTo: ViewId<string> | null | undefined;
377
- notes: string | undefined;
377
+ notes: MarkdownOrString | undefined;
378
378
  labelXY: XYPosition | null;
379
379
  controlPoints: XYPosition[] | undefined | null;
380
380
  };
@@ -420,7 +420,7 @@ export declare const useXYStoreApi: () => {
420
420
  tail: RelationshipArrowType | undefined;
421
421
  labelBBox: BBox | null | undefined;
422
422
  navigateTo: ViewId<string> | null | undefined;
423
- notes: string | undefined;
423
+ notes: MarkdownOrString | undefined;
424
424
  labelXY: XYPosition | null;
425
425
  controlPoints: XYPosition[] | undefined | null;
426
426
  };
package/dist/index.d.ts CHANGED
@@ -4,6 +4,7 @@ export { IconRendererProvider } from './context/IconRenderer';
4
4
  export { LikeC4Diagram, type LikeC4DiagramProps, } from './LikeC4Diagram';
5
5
  export { Overlay, type OverlayProps, } from './overlays/overlay/Overlay';
6
6
  export { LikeC4ModelProvider, type LikeC4ModelProviderProps, } from './LikeC4ModelProvider';
7
+ export { LikeC4ProjectsProvider, type LikeC4ProjectsProviderProps, } from './LikeC4ProjectsProvider';
7
8
  export * from './custom/hooks';
8
9
  export type { ChangeEvent, CustomNodes, DiagramNodeWithNavigate, ElementIconRenderer, LikeC4ColorScheme, LikeC4DiagramEventHandlers, LikeC4DiagramProperties, OnCanvasClick, OnChange, OnEdgeClick, OnNavigateTo, OnNodeClick, OpenSourceParams, PaddingUnit, PaddingWithUnit, WhereOperator, } from './LikeC4Diagram.props';
9
10
  export { StaticLikeC4Diagram, type StaticLikeC4DiagramProps, } from './StaticLikeC4Diagram';
package/dist/index.js CHANGED
@@ -3,6 +3,7 @@ export { IconRendererProvider } from './context/IconRenderer.js';
3
3
  export { LikeC4Diagram } from './LikeC4Diagram.js';
4
4
  export { Overlay } from './overlays/overlay/Overlay.js';
5
5
  export { LikeC4ModelProvider } from './LikeC4ModelProvider.js';
6
+ export { LikeC4ProjectsProvider } from './LikeC4ProjectsProvider.js';
6
7
  export { StaticLikeC4Diagram } from './StaticLikeC4Diagram.js';
7
8
  export { useDiagramEventHandlers } from './context/DiagramEventHandlers.js';
8
9
  export { useEnabledFeatures } from './context/DiagramFeatures.js';
@@ -10,6 +11,7 @@ export { useCurrentViewId } from './hooks/useCurrentViewId.js';
10
11
  export { useDiagram, useDiagramContext } from './hooks/useDiagram.js';
11
12
  export { useDiagramActorRef } from './hooks/safeContext.js';
12
13
  export { useXYFlow, useXYInternalNode, useXYStore, useXYStoreApi } from './hooks/useXYFlow.js';
14
+ export { useCurrentViewModel } from './likec4model/useCurrentViewModel.js';
13
15
  export { useLikeC4Model, useLikeC4Specification, useLikeC4ViewModel } from './likec4model/useLikeC4Model.js';
14
16
  export { useMantinePortalProps } from './hooks/useMantinePortalProps.js';
15
17
  export { useSetState } from './hooks/useSetState.js';
@@ -5,13 +5,15 @@ import { useSearchActorRef } from '../hooks/useSearchActor.js';
5
5
  import { Overlays } from '../overlays/Overlays.js';
6
6
  import { Search } from '../search/Search.js';
7
7
  import { useEnabledFeatures } from '../context/DiagramFeatures.js';
8
+ import { NavigationPanel } from '../navigationpanel/NavigationPanel.js';
8
9
  import { Controls } from './ui/controls/Controls.js';
9
- import { DiagramTitlePanel } from './ui/diagram-title/DiagramTitlePanel.js';
10
10
  import { NotationPanel } from './ui/notation/NotationPanel.js';
11
+ import { DiagramTitlePanel } from './ui/diagram-title/DiagramTitlePanel.js';
11
12
  import { DynamicViewWalkthrough } from './ui/walkthrough/DynamicViewWalkthrough.js';
12
13
 
13
14
  const DiagramUI = memo(() => {
14
15
  const {
16
+ enableControls,
15
17
  enableViewTitle,
16
18
  enableNotations,
17
19
  enableDynamicViewWalkthrough,
@@ -20,11 +22,13 @@ const DiagramUI = memo(() => {
20
22
  const overlaysActorRef = useOverlaysActorRef();
21
23
  const searchActorRef = useSearchActorRef();
22
24
  return /* @__PURE__ */ jsxs(Fragment, { children: [
23
- /* @__PURE__ */ jsx(Controls, {}),
25
+ enableControls === "next" ? /* @__PURE__ */ jsx(NavigationPanel, {}) : /* @__PURE__ */ jsx(Controls, {}),
24
26
  overlaysActorRef && /* @__PURE__ */ jsx(Overlays, { overlaysActorRef }),
25
- enableViewTitle && /* @__PURE__ */ jsx(DiagramTitlePanel, {}),
26
27
  enableNotations && /* @__PURE__ */ jsx(NotationPanel, {}),
27
- enableDynamicViewWalkthrough && /* @__PURE__ */ jsx(DynamicViewWalkthrough, {}),
28
+ enableControls !== "next" && /* @__PURE__ */ jsxs(Fragment, { children: [
29
+ enableViewTitle && /* @__PURE__ */ jsx(DiagramTitlePanel, {}),
30
+ enableDynamicViewWalkthrough && /* @__PURE__ */ jsx(DynamicViewWalkthrough, {})
31
+ ] }),
28
32
  enableSearch && searchActorRef && /* @__PURE__ */ jsx(Search, { searchActorRef })
29
33
  ] });
30
34
  });
@@ -30,7 +30,7 @@ const selectXYProps = (ctx) => ({
30
30
  }
31
31
  }
32
32
  });
33
- const equalsXYProps = (a, b) => a.initialized === b.initialized && a.pannable === b.pannable && a.zoomable === b.zoomable && a.fitViewPadding === b.fitViewPadding && a.enableFitView === b.enableFitView && a.enableReadOnly === b.enableReadOnly && shallowEqual(a.nodes, b.nodes) && shallowEqual(a.edges, b.edges) && shallowEqual(a.viewport ?? null, b.viewport ?? null);
33
+ const equalsXYProps = (a, b) => a.initialized === b.initialized && a.pannable === b.pannable && a.zoomable === b.zoomable && a.enableFitView === b.enableFitView && a.enableReadOnly === b.enableReadOnly && shallowEqual(a.fitViewPadding, b.fitViewPadding) && shallowEqual(a.nodes, b.nodes) && shallowEqual(a.edges, b.edges) && shallowEqual(a.viewport ?? null, b.viewport ?? null);
34
34
  function LikeC4DiagramXYFlow({
35
35
  background = "dots",
36
36
  nodesDraggable = false,
@@ -2,8 +2,8 @@ import { css } from '@likec4/styles/css';
2
2
 
3
3
  const edgeNoteCloseButton = css({
4
4
  position: "absolute",
5
- top: 1,
6
- right: 1,
5
+ top: "[1px]",
6
+ right: "[1px]",
7
7
  zIndex: 9
8
8
  });
9
9
  const edgeNoteText = css({
@@ -1,4 +1,4 @@
1
- import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId } from '@likec4/core';
1
+ import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId, MarkdownOrString } from '@likec4/core';
2
2
  import { XYPosition } from '@xyflow/react';
3
3
  import { FunctionComponent, CSSProperties, ReactNode } from 'react';
4
4
  import { Position } from '@xyflow/system';
@@ -45,7 +45,7 @@ export declare const RelationshipEdge: FunctionComponent<{
45
45
  tail: RelationshipArrowType | undefined;
46
46
  labelBBox: BBox | null | undefined;
47
47
  navigateTo: ViewId<string> | null | undefined;
48
- notes: string | undefined;
48
+ notes: MarkdownOrString | undefined;
49
49
  labelXY: XYPosition | null;
50
50
  controlPoints: XYPosition[] | undefined | null;
51
51
  };
@@ -257,7 +257,7 @@ const RelationshipEdge = customEdge((props) => {
257
257
  if (!isControlPointDragging && !isPanning) {
258
258
  const notes = props.data.notes;
259
259
  if (notes && activeWalkthroughStep === props.id) {
260
- edgeLabel = /* @__PURE__ */ jsx(NotePopover, { notes, children: edgeLabel });
260
+ edgeLabel = /* @__PURE__ */ jsx(NotePopover, { notes: notes.txt ?? notes.md, children: edgeLabel });
261
261
  } else if (enableRelationshipDetails) {
262
262
  edgeLabel = /* @__PURE__ */ jsx(
263
263
  RelationshipsDropdownMenu,
@@ -6,24 +6,24 @@ const menuDropdown = css({
6
6
  maxWidth: "min(90vw, 500px)"
7
7
  });
8
8
  const menuItemRelationship = css({
9
- gap: 4
9
+ gap: "1"
10
10
  });
11
11
  const endpoint = css({
12
12
  display: "block",
13
13
  fontSize: "xxs",
14
14
  fontWeight: 500,
15
15
  whiteSpace: "nowrap",
16
- padding: "2px 4px",
17
- borderRadius: 2,
18
- background: `likec4.palette.fill/30`,
16
+ padding: "[2px 4px]",
17
+ borderRadius: "[2px]",
18
+ background: `var(--likec4-palette-fill)/30`,
19
19
  lineHeight: "[1.11]",
20
20
  mixBlendMode: "hard-light",
21
21
  color: {
22
- _light: `[color-mix(in srgb, {colors.likec4.palette.stroke}, {colors.likec4.mixColor} 60%)]`,
23
- _dark: "likec4.palette.loContrast"
22
+ _light: `[color-mix(in srgb, var(--likec4-palette-stroke), {colors.likec4.mixColor} 60%)]`,
23
+ _dark: "var(--likec4-palette-loContrast)"
24
24
  }
25
25
  // _dark: {
26
- // background: `likec4.palette.fill/60`,
26
+ // background: `var(--likec4-palette-fill)/60`,
27
27
  // },
28
28
  });
29
29
  const title = css({
@@ -1,6 +1,6 @@
1
1
  import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
2
2
  import { nameFromFqn } from '@likec4/core';
3
- import { cx, css } from '@likec4/styles/css';
3
+ import { cx } from '@likec4/styles/css';
4
4
  import { Menu, MenuTarget, MenuDropdown, MenuLabel, MenuDivider, Box, ActionIcon, MenuItem, Stack, Group, Text, TooltipGroup, Space, Tooltip as Tooltip$1 } from '@mantine/core';
5
5
  import { memo, useCallback, Fragment as Fragment$1, forwardRef } from 'react';
6
6
  import { pipe, map, filter, isTruthy, partition } from 'remeda';
@@ -10,12 +10,12 @@ import { findDiagramNode, findDiagramEdge } from '../../../state/utils.js';
10
10
  import { menuDropdown, endpoint, title, menuItemRelationship } from './RelationshipsDropdownMenu.css.js';
11
11
  import { useLikeC4Model } from '../../../likec4model/useLikeC4Model.js';
12
12
  import { useMantinePortalProps } from '../../../hooks/useMantinePortalProps.js';
13
- import IconInfoCircle from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconInfoCircle.js';
13
+ import IconInfoCircle from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconInfoCircle.js';
14
14
  import { useEnabledFeatures, IfEnabled } from '../../../context/DiagramFeatures.js';
15
15
  import { useDiagramEventHandlers } from '../../../context/DiagramEventHandlers.js';
16
- import IconArrowRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js';
17
- import IconZoomScan from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js';
18
- import IconFileSymlink from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
16
+ import IconArrowRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconArrowRight.js';
17
+ import IconZoomScan from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js';
18
+ import IconFileSymlink from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
19
19
 
20
20
  const stopPropagation = (e) => e.stopPropagation();
21
21
  const Tooltip = Tooltip$1.withProps({
@@ -155,9 +155,9 @@ const Relationship = forwardRef(({
155
155
  const links = r.links;
156
156
  return /* @__PURE__ */ jsxs(Stack, { ref, className: cx(menuItemRelationship, className), ...props, children: [
157
157
  /* @__PURE__ */ jsxs(Group, { gap: 4, children: [
158
- /* @__PURE__ */ jsx(Text, { component: "div", className: cx(css({ likec4Palette: sourceNode.color }), endpoint), children: sourceId }),
158
+ /* @__PURE__ */ jsx(Text, { component: "div", "data-likec4-color": sourceNode.color, className: endpoint, children: sourceId }),
159
159
  /* @__PURE__ */ jsx(IconArrowRight, { stroke: 2.5, size: "11px", opacity: 0.65 }),
160
- /* @__PURE__ */ jsx(Text, { component: "div", className: cx(css({ likec4Palette: targetNode.color }), endpoint), children: targetId }),
160
+ /* @__PURE__ */ jsx(Text, { component: "div", "data-likec4-color": targetNode.color, className: endpoint, children: targetId }),
161
161
  (navigateTo || !!onOpenSource) && /* @__PURE__ */ jsxs(TooltipGroup, { openDelay: 100, children: [
162
162
  /* @__PURE__ */ jsx(Space, { w: "xs" }),
163
163
  navigateTo && /* @__PURE__ */ jsx(Tooltip, { label: "Open dynamic view", children: /* @__PURE__ */ jsx(
@@ -5,13 +5,13 @@ const controlPointsContainer = css({
5
5
  overflow: "visible",
6
6
  position: "absolute",
7
7
  pointerEvents: "none",
8
- top: 0,
9
- left: 0,
8
+ top: "0",
9
+ left: "0",
10
10
  mixBlendMode: "normal"
11
11
  });
12
12
  const controlPoint = css({
13
- fill: `likec4.relation.stroke`,
14
- stroke: `likec4.relation.stroke`,
13
+ fill: `var(--likec4-palette-relation-stroke)`,
14
+ stroke: `var(--likec4-palette-relation-stroke)`,
15
15
  fillOpacity: 0.75,
16
16
  strokeWidth: 1,
17
17
  cursor: "grab",
@@ -3,7 +3,7 @@ import { MemoExoticComponent, FunctionComponent, CSSProperties, ReactNode } from
3
3
  import { NodeProps } from '../../base';
4
4
  import { Position, XYPosition } from '@xyflow/system';
5
5
  import { EdgeData, Dimmed } from '../../base/types.Base';
6
- import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId } from '@likec4/core';
6
+ import { EdgeId, NonEmptyArray, Point, Color, RelationshipArrowType, RelationshipLineType, BBox, ViewId, MarkdownOrString } from '@likec4/core';
7
7
  export declare const BuiltinNodes: {
8
8
  element: MemoExoticComponent<(props: NodeProps<Types.ElementNodeData, "element">) => import("react/jsx-runtime").JSX.Element>;
9
9
  deployment: MemoExoticComponent<(props: NodeProps<Types.DeploymentElementNodeData, "deployment">) => import("react/jsx-runtime").JSX.Element>;
@@ -54,7 +54,7 @@ export declare const edgeTypes: {
54
54
  tail: RelationshipArrowType | undefined;
55
55
  labelBBox: BBox | null | undefined;
56
56
  navigateTo: ViewId<string> | null | undefined;
57
- notes: string | undefined;
57
+ notes: MarkdownOrString | undefined;
58
58
  labelXY: XYPosition | null;
59
59
  controlPoints: XYPosition[] | undefined | null;
60
60
  };
@@ -3,8 +3,8 @@ import { hasAtLeast } from '@likec4/core';
3
3
  import { useMemo } from 'react';
4
4
  import { useEnabledFeatures } from '../../../context/DiagramFeatures.js';
5
5
  import { useDiagram } from '../../../hooks/useDiagram.js';
6
- import IconZoomScan from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js';
7
- import IconTransform from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js';
6
+ import IconZoomScan from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconZoomScan.js';
7
+ import IconTransform from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js';
8
8
  import { ElementActionButtons } from '../../../base/primitives/element/ElementActionButtons.js';
9
9
 
10
10
  const ElementActions = ({
@@ -109,8 +109,8 @@ function BorderStyleOption({
109
109
  },
110
110
  styles: {
111
111
  label: {
112
- paddingTop: 2,
113
- paddingBottom: 2
112
+ paddingTop: "0.5",
113
+ paddingBottom: "0.5"
114
114
  }
115
115
  },
116
116
  data: [
@@ -6,8 +6,8 @@ import { stopPropagation } from '../../../../utils/xyflow.js';
6
6
  import { useHandlers, GoToSourceButton, BrowseRelationshipsButton } from './_shared.js';
7
7
  import { ColorButton } from './ColorButton.js';
8
8
  import { Toolbar } from './Toolbar.js';
9
- import IconSelector from '../../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js';
10
- import IconCheck from '../../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js';
9
+ import IconSelector from '../../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconSelector.js';
10
+ import IconCheck from '../../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconCheck.js';
11
11
 
12
12
  function ElementToolbar(props) {
13
13
  const { enableVscode, enableRelationshipBrowser } = useEnabledFeatures();
@@ -6,8 +6,8 @@ import { useState } from 'react';
6
6
  import { keys } from 'remeda';
7
7
  import { useDiagram } from '../../../../hooks/useDiagram.js';
8
8
  import { useDiagramEventHandlers } from '../../../../context/DiagramEventHandlers.js';
9
- import IconFileSymlink from '../../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
10
- import IconTransform from '../../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js';
9
+ import IconFileSymlink from '../../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
10
+ import IconTransform from '../../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconTransform.js';
11
11
 
12
12
  const {
13
13
  primary,
@@ -7,7 +7,7 @@ import { useDiagram, useDiagramContext } from '../../../hooks/useDiagram.js';
7
7
  import { Tooltip, ActionIcon } from './_shared.js';
8
8
  import { autolayoutIndicator, autolayoutButton, spacingSliderBody, spacingSliderThumb } from './styles.css.js';
9
9
  import { useDiagramEventHandlers } from '../../../context/DiagramEventHandlers.js';
10
- import IconLayoutDashboard from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutDashboard.js';
10
+ import IconLayoutDashboard from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutDashboard.js';
11
11
 
12
12
  const selector = (state) => ({
13
13
  viewId: state.view.id,
@@ -1,11 +1,12 @@
1
1
  import { jsx, Fragment, jsxs } from 'react/jsx-runtime';
2
2
  import { cx } from '@likec4/styles/css';
3
- import { ActionIconGroup, Group, Stack, Box, Badge, Loader } from '@mantine/core';
3
+ import { hstack } from '@likec4/styles/patterns';
4
+ import { ActionIconGroup, Stack, Group, Box } from '@mantine/core';
4
5
  import { m, LayoutGroup } from 'motion/react';
5
6
  import { memo } from 'react';
6
7
  import { SearchControl } from '../../../components/SearchControl.js';
7
8
  import { useControlsCustomLayout } from '../../../context/ControlsCustomLayout.js';
8
- import { useDiagramContext, useDiagram, useDiagramSyncLayoutState } from '../../../hooks/useDiagram.js';
9
+ import { useDiagramContext, useDiagram } from '../../../hooks/useDiagram.js';
9
10
  import { Tooltip, ActionIcon } from './_shared.js';
10
11
  import { ChangeAutoLayoutButton } from './ChangeAutoLayoutButton.js';
11
12
  import { LayoutDriftNotification } from './LayoutDriftNotification.js';
@@ -16,9 +17,9 @@ import { ToggleReadonly } from './ToggleReadonly.js';
16
17
  import { useDiagramEventHandlers } from '../../../context/DiagramEventHandlers.js';
17
18
  import { useEnabledFeatures } from '../../../context/DiagramFeatures.js';
18
19
  import { useMantinePortalProps } from '../../../hooks/useMantinePortalProps.js';
19
- import IconFileSymlink from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
20
- import IconFocusCentered from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconFocusCentered.js';
21
- import IconMenu2 from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu2.js';
20
+ import IconFileSymlink from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFileSymlink.js';
21
+ import IconFocusCentered from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconFocusCentered.js';
22
+ import IconMenu2 from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconMenu2.js';
22
23
  import { stopPropagation } from '../../../utils/xyflow.js';
23
24
 
24
25
  const ControlsDefaultLayout = ({
@@ -27,9 +28,8 @@ const ControlsDefaultLayout = ({
27
28
  search,
28
29
  actionsGroup
29
30
  }) => /* @__PURE__ */ jsxs(
30
- Group,
31
+ m.div,
31
32
  {
32
- component: m.div,
33
33
  initial: {
34
34
  opacity: 0.05,
35
35
  translateX: -30,
@@ -45,13 +45,15 @@ const ControlsDefaultLayout = ({
45
45
  translateX: -30,
46
46
  translateY: -10
47
47
  },
48
- align: "flex-start",
49
48
  className: cx(
49
+ hstack({
50
+ gap: "sm",
51
+ alignItems: "flex-start"
52
+ }),
50
53
  "react-flow__panel",
51
54
  panel,
52
55
  "likec4-top-left-panel"
53
56
  ),
54
- gap: "xs",
55
57
  onClick: stopPropagation,
56
58
  children: [
57
59
  /* @__PURE__ */ jsxs(Stack, { align: "flex-start", gap: "xs", children: [
@@ -116,7 +118,6 @@ const Controls = memo(() => {
116
118
  }
117
119
  }
118
120
  ),
119
- syncInProgressBadge: /* @__PURE__ */ jsx(SyncLayoutBadge, {}),
120
121
  actionsGroup: /* @__PURE__ */ jsxs(ActionIconGroup, { className: actionIconGroup, orientation: "vertical", children: [
121
122
  enableVscode && /* @__PURE__ */ jsx(Tooltip, { label: "Open source", ...portalProps, children: /* @__PURE__ */ jsx(
122
123
  ActionIcon,
@@ -149,10 +150,5 @@ const Controls = memo(() => {
149
150
  }
150
151
  ) });
151
152
  });
152
- const SyncLayoutBadge = () => {
153
- const isPending = useDiagramSyncLayoutState((s) => s.hasTag("pending"));
154
- if (!isPending) return null;
155
- return /* @__PURE__ */ jsx(Badge, { color: "pink", radius: "xs", size: "xs", variant: "light", leftSection: /* @__PURE__ */ jsx(Loader, { color: "orange", size: 8 }), children: "Pending..." });
156
- };
157
153
 
158
154
  export { Controls };
@@ -2,7 +2,7 @@ import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { HoverCard, HoverCardTarget, HoverCardDropdown, Notification, Text, Code } from '@mantine/core';
3
3
  import { css } from '@likec4/styles/css';
4
4
  import { ActionIcon } from './_shared.js';
5
- import IconAlertTriangle from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconAlertTriangle.js';
5
+ import IconAlertTriangle from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconAlertTriangle.js';
6
6
 
7
7
  const LayoutDriftNotification = (props) => /* @__PURE__ */ jsxs(
8
8
  HoverCard,
@@ -2,15 +2,15 @@ import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { Popover, PopoverTarget, PopoverDropdown, Group, ActionIconGroup } from '@mantine/core';
3
3
  import { useDiagram } from '../../../hooks/useDiagram.js';
4
4
  import { Tooltip, ActionIcon } from './_shared.js';
5
- import IconLayoutCollage from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutCollage.js';
6
- import IconLayoutBoardSplit from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutBoardSplit.js';
7
- import IconLayoutAlignLeft from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignLeft.js';
8
- import IconLayoutAlignCenter from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignCenter.js';
9
- import IconLayoutAlignRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignRight.js';
10
- import IconLayoutAlignTop from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignTop.js';
11
- import IconLayoutAlignMiddle from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignMiddle.js';
12
- import IconLayoutAlignBottom from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignBottom.js';
13
- import IconRouteOff from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconRouteOff.js';
5
+ import IconLayoutCollage from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutCollage.js';
6
+ import IconLayoutBoardSplit from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutBoardSplit.js';
7
+ import IconLayoutAlignLeft from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignLeft.js';
8
+ import IconLayoutAlignCenter from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignCenter.js';
9
+ import IconLayoutAlignRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignRight.js';
10
+ import IconLayoutAlignTop from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignTop.js';
11
+ import IconLayoutAlignMiddle from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignMiddle.js';
12
+ import IconLayoutAlignBottom from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLayoutAlignBottom.js';
13
+ import IconRouteOff from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconRouteOff.js';
14
14
 
15
15
  const Action = ({
16
16
  label,
@@ -2,8 +2,8 @@ import { jsxs, jsx } from 'react/jsx-runtime';
2
2
  import { AnimatePresence, m } from 'motion/react';
3
3
  import { useDiagram, useDiagramContext } from '../../../hooks/useDiagram.js';
4
4
  import { ActionIcon } from './_shared.js';
5
- import IconChevronLeft from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js';
6
- import IconChevronRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js';
5
+ import IconChevronLeft from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronLeft.js';
6
+ import IconChevronRight from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconChevronRight.js';
7
7
 
8
8
  const NavigationButtons = () => {
9
9
  const diagram = useDiagram();
@@ -18,6 +18,7 @@ const NavigationButtons = () => {
18
18
  hasStepBack && /* @__PURE__ */ jsx(
19
19
  ActionIcon,
20
20
  {
21
+ variant: "subtle",
21
22
  component: m.button,
22
23
  onClick: (e) => {
23
24
  e.stopPropagation();
@@ -37,6 +38,7 @@ const NavigationButtons = () => {
37
38
  hasStepForward && /* @__PURE__ */ jsx(
38
39
  ActionIcon,
39
40
  {
41
+ variant: "subtle",
40
42
  component: m.button,
41
43
  layout: true,
42
44
  initial: { opacity: 0.05, transform: "translateX(10px)" },
@@ -1,8 +1,8 @@
1
1
  import { jsx } from 'react/jsx-runtime';
2
2
  import { useDiagramContext, useDiagram } from '../../../hooks/useDiagram.js';
3
3
  import { Tooltip, ActionIcon } from './_shared.js';
4
- import IconLock from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLock.js';
5
- import IconLockOpen2 from '../../../node_modules/.pnpm/@tabler_icons-react@3.31.0_react@19.1.0/node_modules/@tabler/icons-react/dist/esm/icons/IconLockOpen2.js';
4
+ import IconLock from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLock.js';
5
+ import IconLockOpen2 from '../../../node_modules/.pnpm/@tabler_icons-react@3.34.1_react@19.1.1/node_modules/@tabler/icons-react/dist/esm/icons/IconLockOpen2.js';
6
6
 
7
7
  const selector = (state) => ({
8
8
  visible: state.features.enableReadOnly !== true,
@@ -1,15 +1,15 @@
1
1
  import { css } from '@likec4/styles/css';
2
2
 
3
3
  const navigationButtons = css({
4
- gap: "micro",
4
+ gap: "xxs",
5
5
  _empty: {
6
6
  display: "none"
7
7
  }
8
8
  });
9
9
  const panel = css({
10
- top: "1rem",
11
- left: "1rem",
12
- margin: 0,
10
+ top: "md",
11
+ left: "md",
12
+ margin: "0",
13
13
  pointerEvents: "none",
14
14
  "& :where(button, .action-icon, [role='dialog'])": {
15
15
  pointerEvents: "all"
@@ -43,7 +43,7 @@ const autolayoutButton = css({
43
43
  flex: "1 1 40%",
44
44
  textAlign: "center",
45
45
  fontWeight: 500,
46
- padding: "4px 6px",
46
+ padding: "[4px 6px]",
47
47
  fontSize: "11px",
48
48
  zIndex: 1
49
49
  });