@loopstack/loopstack-studio 0.25.1 → 0.26.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 (1691) hide show
  1. package/dist/_virtual/rolldown_runtime.js +20 -0
  2. package/dist/api/auth.js +2 -4
  3. package/dist/api/client.js +7 -9
  4. package/dist/api/config.js +2 -4
  5. package/dist/api/dashboard.js +2 -4
  6. package/dist/api/documents.js +2 -4
  7. package/dist/api/environments.js +4 -0
  8. package/dist/api/index.js +23 -21
  9. package/dist/api/processor.js +2 -4
  10. package/dist/api/secrets.js +2 -4
  11. package/dist/api/workflows.js +2 -4
  12. package/dist/api/workspaces.js +2 -4
  13. package/dist/app/EnvironmentEmbedRoot.js +41 -24
  14. package/dist/components/ai-elements/code-block.js +71 -53
  15. package/dist/components/ai-elements/message.js +82 -41
  16. package/dist/components/ai-elements/prompt-input.js +253 -162
  17. package/dist/components/ai-elements/reasoning.js +116 -78
  18. package/dist/components/ai-elements/shimmer.js +35 -23
  19. package/dist/components/ai-elements/sources.js +58 -29
  20. package/dist/components/data-table/ConfirmDialog.js +30 -14
  21. package/dist/components/data-table/DataList.js +200 -138
  22. package/dist/components/data-table/DataTable.js +236 -168
  23. package/dist/components/data-table/DataTableBatchAction.js +27 -18
  24. package/dist/components/data-table/DataTableFilters.js +78 -53
  25. package/dist/components/data-table/DataTablePagination.js +104 -72
  26. package/dist/components/data-table/DataTableToolbar.js +65 -53
  27. package/dist/components/dynamic-form/ArrayController.js +103 -85
  28. package/dist/components/dynamic-form/CodeContent.js +36 -28
  29. package/dist/components/dynamic-form/Form.js +56 -43
  30. package/dist/components/dynamic-form/FormBody.js +10 -12
  31. package/dist/components/dynamic-form/FormElement.js +41 -31
  32. package/dist/components/dynamic-form/FormElementHeader.js +20 -12
  33. package/dist/components/dynamic-form/InputController.js +38 -36
  34. package/dist/components/dynamic-form/MarkdownContent.js +74 -53
  35. package/dist/components/dynamic-form/MermaidDiagram.js +24 -22
  36. package/dist/components/dynamic-form/ObjectController.js +32 -24
  37. package/dist/components/dynamic-form/fields/BaseFieldWrapper.js +47 -35
  38. package/dist/components/dynamic-form/fields/CheckboxField.js +48 -39
  39. package/dist/components/dynamic-form/fields/CodeViewField.js +50 -42
  40. package/dist/components/dynamic-form/fields/InputField.js +90 -62
  41. package/dist/components/dynamic-form/fields/MarkdownViewField.js +19 -16
  42. package/dist/components/dynamic-form/fields/RadioField.js +62 -46
  43. package/dist/components/dynamic-form/fields/SelectField.js +58 -40
  44. package/dist/components/dynamic-form/fields/SliderField.js +100 -94
  45. package/dist/components/dynamic-form/fields/SwitchField.js +61 -42
  46. package/dist/components/dynamic-form/fields/TextareaField.js +72 -53
  47. package/dist/components/dynamic-form/fields/utils/text-validation-utils.js +2 -4
  48. package/dist/components/dynamic-form/hooks/useArrayDefaultValue.js +5 -6
  49. package/dist/components/dynamic-form/hooks/useFieldConfig.js +20 -19
  50. package/dist/components/dynamic-form/hooks/useMergeParentKey.js +2 -4
  51. package/dist/components/dynamic-form/hooks/useSortPropertyNames.js +2 -4
  52. package/dist/components/feedback/ErrorAlert.js +17 -11
  53. package/dist/components/feedback/ErrorBoundary.js +14 -16
  54. package/dist/components/feedback/ErrorSnackbar.js +30 -13
  55. package/dist/components/feedback/LoadingCentered.js +28 -15
  56. package/dist/components/feedback/Snackbar.js +44 -43
  57. package/dist/components/feedback/index.js +5 -5
  58. package/dist/components/index.js +47 -47
  59. package/dist/components/layout/MainLayout.js +25 -17
  60. package/dist/components/layout/StudioSidebar.js +203 -140
  61. package/dist/components/lists/CustomListView.js +74 -49
  62. package/dist/components/lists/ListView.js +102 -66
  63. package/dist/components/loopstack-elements/link.js +104 -65
  64. package/dist/components/loopstack-elements/tool.js +142 -70
  65. package/dist/components/messages/CompletionMessagePaper.js +85 -53
  66. package/dist/components/page/PageBreadcrumbs.js +83 -64
  67. package/dist/components/ui/DiscordLogo.js +22 -16
  68. package/dist/components/ui/GoogleLogo.js +44 -40
  69. package/dist/components/ui/accordion.js +52 -31
  70. package/dist/components/ui/alert-dialog.js +109 -59
  71. package/dist/components/ui/alert.js +36 -22
  72. package/dist/components/ui/avatar.js +35 -21
  73. package/dist/components/ui/badge.js +17 -13
  74. package/dist/components/ui/breadcrumb.js +82 -46
  75. package/dist/components/ui/button-group.js +5 -5
  76. package/dist/components/ui/button.js +21 -17
  77. package/dist/components/ui/card.js +74 -40
  78. package/dist/components/ui/checkbox.js +23 -17
  79. package/dist/components/ui/collapsible.js +25 -17
  80. package/dist/components/ui/command.js +2 -1
  81. package/dist/components/ui/context-menu.js +52 -32
  82. package/dist/components/ui/dialog.js +107 -62
  83. package/dist/components/ui/drawer.js +99 -54
  84. package/dist/components/ui/dropdown-menu.js +159 -91
  85. package/dist/components/ui/hover-card.js +2 -1
  86. package/dist/components/ui/input-group.js +56 -36
  87. package/dist/components/ui/input.js +15 -11
  88. package/dist/components/ui/label.js +15 -11
  89. package/dist/components/ui/popover.js +38 -25
  90. package/dist/components/ui/radio-group.js +33 -22
  91. package/dist/components/ui/scroll-area.js +43 -28
  92. package/dist/components/ui/select.js +134 -73
  93. package/dist/components/ui/separator.js +17 -13
  94. package/dist/components/ui/sheet.js +105 -60
  95. package/dist/components/ui/sidebar.js +451 -269
  96. package/dist/components/ui/skeleton.js +14 -10
  97. package/dist/components/ui/slider.js +41 -32
  98. package/dist/components/ui/switch.js +21 -15
  99. package/dist/components/ui/table.js +85 -46
  100. package/dist/components/ui/tabs.js +45 -26
  101. package/dist/components/ui/textarea.js +14 -10
  102. package/dist/components/ui/tooltip.js +41 -26
  103. package/dist/components/ui-widgets/UiActions.js +37 -30
  104. package/dist/components/ui-widgets/UiWidget.js +46 -34
  105. package/dist/components/ui-widgets/widgets/AiPromptInput.js +42 -28
  106. package/dist/components/ui-widgets/widgets/ButtonFullWidth.js +21 -16
  107. package/dist/components/ui-widgets/widgets/SandboxRun.js +28 -19
  108. package/dist/components/ui-widgets/widgets/SubmitButton.js +20 -15
  109. package/dist/events/api-client-events.js +2 -4
  110. package/dist/events/sse-client-events.js +2 -4
  111. package/dist/features/code-explorer/CodeExplorer.js +2 -1
  112. package/dist/features/code-explorer/components/CodeExplorerTree.js +3 -2
  113. package/dist/features/code-explorer/components/CodeExplorerTreeNode.js +29 -31
  114. package/dist/features/code-explorer/components/FileContentViewer.js +148 -108
  115. package/dist/features/code-explorer/components/FileTabsBar.js +2 -1
  116. package/dist/features/code-explorer/components/FileTabsBarBase.js +169 -134
  117. package/dist/features/code-explorer/index.js +1 -1
  118. package/dist/features/code-explorer/providers/CodeExplorerProvider.js +4 -4
  119. package/dist/features/code-explorer/utils/fileIcons.js +39 -41
  120. package/dist/features/dashboard/Dashboard.js +121 -79
  121. package/dist/features/dashboard/RunItem.js +70 -50
  122. package/dist/features/dashboard/RunList.js +28 -17
  123. package/dist/features/debug/components/ConfigFlowViewer.js +67 -49
  124. package/dist/features/debug/components/WorkflowDebugHeader.js +46 -30
  125. package/dist/features/debug/components/WorkflowDebugLegend.js +68 -56
  126. package/dist/features/debug/components/WorkflowFlowViewer.js +96 -76
  127. package/dist/features/debug/components/workflow-flow/StateNode.js +102 -73
  128. package/dist/features/debug/components/workflow-flow/WorkflowGraph.js +40 -35
  129. package/dist/features/debug/components/workflow-flow/WorkflowTransitionEdge.js +94 -61
  130. package/dist/features/debug/index.js +3 -3
  131. package/dist/features/debug/lib/edge-paths.js +31 -33
  132. package/dist/features/debug/lib/flow-utils.js +145 -147
  133. package/dist/features/documents/DocumentRenderer.js +73 -68
  134. package/dist/features/documents/components/DocumentItem.js +24 -21
  135. package/dist/features/documents/components/DocumentList.js +45 -39
  136. package/dist/features/documents/components/DocumentMetadataPills.js +59 -44
  137. package/dist/features/documents/document-details/DocumentDetails.js +413 -298
  138. package/dist/features/documents/document-details/PromptDetails.js +142 -105
  139. package/dist/features/documents/index.js +4 -4
  140. package/dist/features/documents/renderers/AiMessage.js +48 -39
  141. package/dist/features/documents/renderers/AiMessageContent.js +164 -108
  142. package/dist/features/documents/renderers/ChoicesRenderer.js +89 -77
  143. package/dist/features/documents/renderers/ClaudeMessage.js +91 -74
  144. package/dist/features/documents/renderers/ConfirmPromptRenderer.js +53 -44
  145. package/dist/features/documents/renderers/DocumentDebugRenderer.js +30 -26
  146. package/dist/features/documents/renderers/DocumentFormRenderer.js +85 -69
  147. package/dist/features/documents/renderers/DocumentMessageRenderer.js +9 -10
  148. package/dist/features/documents/renderers/ErrorMessageRenderer.js +13 -11
  149. package/dist/features/documents/renderers/LinkMessageRenderer.js +14 -15
  150. package/dist/features/documents/renderers/MarkdownMessageRenderer.js +10 -8
  151. package/dist/features/documents/renderers/PlainMessageRenderer.js +9 -7
  152. package/dist/features/documents/renderers/TextPromptRenderer.js +54 -45
  153. package/dist/features/documents/renderers/useDocumentTransition.js +33 -30
  154. package/dist/features/feature-registry/FeatureRegistryProvider.js +17 -0
  155. package/dist/features/feature-registry/index.js +1 -0
  156. package/dist/features/file-explorer/api/files.js +7 -0
  157. package/dist/features/file-explorer/components/FileExplorerPanel.js +95 -0
  158. package/dist/features/file-explorer/components/FileTabsBar.js +18 -0
  159. package/dist/features/file-explorer/components/FileTree.js +90 -0
  160. package/dist/features/file-explorer/file-explorer-feature.js +12 -0
  161. package/dist/features/file-explorer/hooks/useFileExplorer.js +44 -0
  162. package/dist/features/file-explorer/index.js +2 -0
  163. package/dist/features/file-explorer/providers/FileExplorerProvider.js +112 -0
  164. package/dist/features/health/LocalHealthCheck.js +53 -54
  165. package/dist/features/health/index.js +1 -1
  166. package/dist/features/oauth/OAuthCallbackPage.js +2 -2
  167. package/dist/features/oauth/OAuthPromptRenderer.js +235 -156
  168. package/dist/features/oauth/index.js +2 -2
  169. package/dist/features/oauth/useOAuthPopup.js +71 -52
  170. package/dist/features/runs/Runs.js +187 -145
  171. package/dist/features/secrets/components/WorkbenchSecretsPanel.js +178 -0
  172. package/dist/features/secrets/index.js +1 -0
  173. package/dist/features/secrets/renderers/SecretInputRenderer.js +87 -0
  174. package/dist/features/secrets/secrets-feature.js +14 -0
  175. package/dist/features/workbench/Workbench.js +50 -74
  176. package/dist/features/workbench/WorkflowItem.js +68 -49
  177. package/dist/features/workbench/WorkflowList.js +127 -49
  178. package/dist/features/workbench/components/NewRunDialog.js +309 -212
  179. package/dist/features/workbench/components/SidebarPanel.js +155 -0
  180. package/dist/features/workbench/components/WorkbenchEnvironmentPanel.js +82 -0
  181. package/dist/features/workbench/components/WorkbenchIconSidebar.js +137 -51
  182. package/dist/features/workbench/components/WorkbenchPreviewPanel.js +134 -123
  183. package/dist/features/workbench/components/WorkbenchRunsPanel.js +32 -0
  184. package/dist/features/workbench/components/WorkbenchSettingsModal.js +60 -49
  185. package/dist/features/workbench/components/WorkbenchSidebarShell.js +80 -0
  186. package/dist/features/workbench/components/WorkflowForms.js +23 -17
  187. package/dist/features/workbench/components/WorkflowHistoryItem.js +122 -96
  188. package/dist/features/workbench/components/WorkflowHistoryList.js +54 -31
  189. package/dist/features/workbench/components/buttons/WorkflowButtons.js +99 -70
  190. package/dist/features/workbench/hooks/useAutoScrollBottom.js +25 -21
  191. package/dist/features/workbench/hooks/useScrollToListItem.js +21 -20
  192. package/dist/features/workbench/hooks/useWorkflowData.js +44 -31
  193. package/dist/features/workbench/hooks/useWorkflowListState.js +12 -13
  194. package/dist/features/workbench/index.js +8 -7
  195. package/dist/features/workbench/providers/ScrollProvider.js +19 -15
  196. package/dist/features/workbench/providers/WorkbenchLayoutProvider.js +75 -78
  197. package/dist/features/workspaces/Workspaces.js +226 -161
  198. package/dist/features/workspaces/components/CreateWorkspace.js +194 -137
  199. package/dist/features/workspaces/components/EnvironmentSlotSelector.js +75 -60
  200. package/dist/features/workspaces/components/ExecutionTimeline.js +185 -143
  201. package/dist/features/workspaces/components/NewWorkflowRunDialog.js +26 -18
  202. package/dist/features/workspaces/components/WorkflowRunForm.js +133 -85
  203. package/dist/features/workspaces/components/WorkspaceHomePage.js +81 -60
  204. package/dist/features/workspaces/components/workflow-form/ArgumentsView.js +69 -52
  205. package/dist/features/workspaces/components/workflow-form/HeaderSection.js +41 -27
  206. package/dist/features/workspaces/components/workflow-form/SelectionView.js +103 -64
  207. package/dist/features/workspaces/index.js +3 -3
  208. package/dist/frontend/studio/node_modules/@dagrejs/dagre/dist/dagre.esm.js +1968 -0
  209. package/dist/hooks/index.js +6 -6
  210. package/dist/hooks/query-keys.js +31 -33
  211. package/dist/hooks/use-mobile.js +11 -12
  212. package/dist/hooks/useApi.js +14 -16
  213. package/dist/hooks/useAuth.js +53 -38
  214. package/dist/hooks/useConfig.js +37 -26
  215. package/dist/hooks/useDashboard.js +15 -12
  216. package/dist/hooks/useDebounce.js +11 -12
  217. package/dist/hooks/useDocuments.js +35 -23
  218. package/dist/hooks/useEnvironmentPreviewUrl.js +13 -0
  219. package/dist/hooks/useEnvironments.js +8 -0
  220. package/dist/hooks/useFiles.js +2 -1
  221. package/dist/hooks/useProcessor.js +17 -14
  222. package/dist/hooks/useSecrets.js +64 -45
  223. package/dist/hooks/useWorkflows.js +163 -109
  224. package/dist/hooks/useWorkspaces.js +125 -83
  225. package/dist/index.d.ts +1395 -0
  226. package/dist/index.js +87 -80
  227. package/dist/lib/requireParam.js +2 -4
  228. package/dist/lib/utils.js +5 -7
  229. package/dist/loopstack-studio.css +1 -1
  230. package/dist/node_modules/@braintree/sanitize-url/dist/constants.js +4 -6
  231. package/dist/node_modules/@braintree/sanitize-url/dist/index.js +6 -8
  232. package/dist/node_modules/@chevrotain/gast/lib/src/helpers.js +17 -19
  233. package/dist/node_modules/@chevrotain/gast/lib/src/model.js +71 -73
  234. package/dist/node_modules/@chevrotain/gast/lib/src/visitor.js +13 -16
  235. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/api.js +2 -2
  236. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/base-regexp-visitor.js +2 -4
  237. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/character-classes.js +34 -36
  238. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/regexp-parser.js +110 -138
  239. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/utils.js +11 -13
  240. package/dist/node_modules/@chevrotain/utils/lib/src/print.js +3 -5
  241. package/dist/node_modules/@chevrotain/utils/lib/src/timer.js +2 -4
  242. package/dist/node_modules/@chevrotain/utils/lib/src/to-fast-properties.js +2 -4
  243. package/dist/node_modules/@iconify/utils/lib/customisations/defaults.js +6 -8
  244. package/dist/node_modules/@iconify/utils/lib/icon/defaults.js +8 -10
  245. package/dist/node_modules/@iconify/utils/lib/icon/merge.js +6 -8
  246. package/dist/node_modules/@iconify/utils/lib/icon/name.js +6 -8
  247. package/dist/node_modules/@iconify/utils/lib/icon/transformations.js +2 -4
  248. package/dist/node_modules/@iconify/utils/lib/icon-set/get-icon.js +10 -12
  249. package/dist/node_modules/@iconify/utils/lib/icon-set/tree.js +2 -4
  250. package/dist/node_modules/@iconify/utils/lib/svg/build.js +18 -20
  251. package/dist/node_modules/@iconify/utils/lib/svg/defs.js +6 -8
  252. package/dist/node_modules/@iconify/utils/lib/svg/html.js +2 -4
  253. package/dist/node_modules/@iconify/utils/lib/svg/id.js +8 -10
  254. package/dist/node_modules/@iconify/utils/lib/svg/size.js +5 -7
  255. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/architecture-YZFGNWBL.js +2 -2
  256. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-2KRD3SAO.js +17 -20
  257. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-67CJDMHE.js +17 -20
  258. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-7N4EOEYR.js +23 -28
  259. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-AA7GKIK3.js +21 -26
  260. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-CIAEETIT.js +17 -20
  261. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-FOC6F5B3.js +17 -20
  262. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-K5T4RW27.js +425 -436
  263. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-KGLVRYIC.js +17 -20
  264. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-LIHQZDEY.js +38 -45
  265. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-ORNJ4GCN.js +22 -27
  266. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/gitGraph-7Q5UKJZL.js +2 -2
  267. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-OMHHGYJF.js +2 -2
  268. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-4T2RLAQJ.js +2 -2
  269. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-ZZUOXDRM.js +2 -2
  270. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-PYXPWWZC.js +2 -2
  271. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treeView-SZITEDCU.js +2 -2
  272. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-W4RFUUIX.js +2 -2
  273. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-RL74JXVD.js +2 -2
  274. package/dist/node_modules/@mermaid-js/parser/dist/mermaid-parser.core.js +52 -56
  275. package/dist/node_modules/@shikijs/core/dist/index.js +575 -577
  276. package/dist/node_modules/@shikijs/engine-oniguruma/dist/index.js +157 -159
  277. package/dist/node_modules/@shikijs/engine-oniguruma/dist/wasm-inlined.js +2 -4
  278. package/dist/node_modules/@shikijs/langs/dist/abap.js +2 -3
  279. package/dist/node_modules/@shikijs/langs/dist/actionscript-3.js +2 -3
  280. package/dist/node_modules/@shikijs/langs/dist/ada.js +2 -3
  281. package/dist/node_modules/@shikijs/langs/dist/angular-expression.js +2 -3
  282. package/dist/node_modules/@shikijs/langs/dist/angular-html.js +13 -15
  283. package/dist/node_modules/@shikijs/langs/dist/angular-inline-style.js +3 -5
  284. package/dist/node_modules/@shikijs/langs/dist/angular-inline-template.js +7 -9
  285. package/dist/node_modules/@shikijs/langs/dist/angular-let-declaration.js +3 -5
  286. package/dist/node_modules/@shikijs/langs/dist/angular-template-blocks.js +7 -9
  287. package/dist/node_modules/@shikijs/langs/dist/angular-template.js +3 -5
  288. package/dist/node_modules/@shikijs/langs/dist/angular-ts.js +15 -17
  289. package/dist/node_modules/@shikijs/langs/dist/apache.js +2 -3
  290. package/dist/node_modules/@shikijs/langs/dist/apex.js +2 -3
  291. package/dist/node_modules/@shikijs/langs/dist/apl.js +13 -15
  292. package/dist/node_modules/@shikijs/langs/dist/applescript.js +2 -3
  293. package/dist/node_modules/@shikijs/langs/dist/ara.js +2 -3
  294. package/dist/node_modules/@shikijs/langs/dist/asciidoc.js +2 -3
  295. package/dist/node_modules/@shikijs/langs/dist/asm.js +2 -3
  296. package/dist/node_modules/@shikijs/langs/dist/astro.js +15 -17
  297. package/dist/node_modules/@shikijs/langs/dist/awk.js +2 -3
  298. package/dist/node_modules/@shikijs/langs/dist/ballerina.js +2 -3
  299. package/dist/node_modules/@shikijs/langs/dist/bat.js +2 -3
  300. package/dist/node_modules/@shikijs/langs/dist/beancount.js +2 -3
  301. package/dist/node_modules/@shikijs/langs/dist/berry.js +2 -3
  302. package/dist/node_modules/@shikijs/langs/dist/bibtex.js +2 -3
  303. package/dist/node_modules/@shikijs/langs/dist/bicep.js +2 -3
  304. package/dist/node_modules/@shikijs/langs/dist/bird2.js +2 -3
  305. package/dist/node_modules/@shikijs/langs/dist/blade.js +17 -19
  306. package/dist/node_modules/@shikijs/langs/dist/bsl.js +3 -5
  307. package/dist/node_modules/@shikijs/langs/dist/c.js +2 -3
  308. package/dist/node_modules/@shikijs/langs/dist/c3.js +2 -3
  309. package/dist/node_modules/@shikijs/langs/dist/cadence.js +2 -3
  310. package/dist/node_modules/@shikijs/langs/dist/cairo.js +3 -5
  311. package/dist/node_modules/@shikijs/langs/dist/clarity.js +2 -3
  312. package/dist/node_modules/@shikijs/langs/dist/clojure.js +2 -3
  313. package/dist/node_modules/@shikijs/langs/dist/cmake.js +2 -3
  314. package/dist/node_modules/@shikijs/langs/dist/cobol.js +7 -9
  315. package/dist/node_modules/@shikijs/langs/dist/codeowners.js +2 -3
  316. package/dist/node_modules/@shikijs/langs/dist/codeql.js +2 -3
  317. package/dist/node_modules/@shikijs/langs/dist/coffee.js +3 -5
  318. package/dist/node_modules/@shikijs/langs/dist/common-lisp.js +2 -3
  319. package/dist/node_modules/@shikijs/langs/dist/coq.js +2 -3
  320. package/dist/node_modules/@shikijs/langs/dist/cpp-macro.js +9 -11
  321. package/dist/node_modules/@shikijs/langs/dist/cpp.js +11 -13
  322. package/dist/node_modules/@shikijs/langs/dist/crystal.js +15 -17
  323. package/dist/node_modules/@shikijs/langs/dist/csharp.js +2 -3
  324. package/dist/node_modules/@shikijs/langs/dist/css.js +2 -3
  325. package/dist/node_modules/@shikijs/langs/dist/csv.js +2 -3
  326. package/dist/node_modules/@shikijs/langs/dist/cue.js +2 -3
  327. package/dist/node_modules/@shikijs/langs/dist/cypher.js +2 -3
  328. package/dist/node_modules/@shikijs/langs/dist/d.js +2 -3
  329. package/dist/node_modules/@shikijs/langs/dist/dart.js +2 -3
  330. package/dist/node_modules/@shikijs/langs/dist/dax.js +2 -3
  331. package/dist/node_modules/@shikijs/langs/dist/desktop.js +2 -3
  332. package/dist/node_modules/@shikijs/langs/dist/diff.js +2 -3
  333. package/dist/node_modules/@shikijs/langs/dist/docker.js +2 -3
  334. package/dist/node_modules/@shikijs/langs/dist/dotenv.js +2 -3
  335. package/dist/node_modules/@shikijs/langs/dist/dream-maker.js +2 -3
  336. package/dist/node_modules/@shikijs/langs/dist/edge.js +9 -11
  337. package/dist/node_modules/@shikijs/langs/dist/elixir.js +3 -5
  338. package/dist/node_modules/@shikijs/langs/dist/elm.js +3 -5
  339. package/dist/node_modules/@shikijs/langs/dist/emacs-lisp.js +2 -3
  340. package/dist/node_modules/@shikijs/langs/dist/erb.js +7 -9
  341. package/dist/node_modules/@shikijs/langs/dist/erlang.js +3 -5
  342. package/dist/node_modules/@shikijs/langs/dist/es-tag-css.js +9 -11
  343. package/dist/node_modules/@shikijs/langs/dist/es-tag-glsl.js +9 -11
  344. package/dist/node_modules/@shikijs/langs/dist/es-tag-html.js +9 -11
  345. package/dist/node_modules/@shikijs/langs/dist/es-tag-sql.js +7 -9
  346. package/dist/node_modules/@shikijs/langs/dist/es-tag-xml.js +3 -5
  347. package/dist/node_modules/@shikijs/langs/dist/fennel.js +2 -3
  348. package/dist/node_modules/@shikijs/langs/dist/fish.js +2 -3
  349. package/dist/node_modules/@shikijs/langs/dist/fluent.js +2 -3
  350. package/dist/node_modules/@shikijs/langs/dist/fortran-fixed-form.js +3 -5
  351. package/dist/node_modules/@shikijs/langs/dist/fortran-free-form.js +2 -3
  352. package/dist/node_modules/@shikijs/langs/dist/fsharp.js +3 -5
  353. package/dist/node_modules/@shikijs/langs/dist/gdresource.js +7 -9
  354. package/dist/node_modules/@shikijs/langs/dist/gdscript.js +2 -3
  355. package/dist/node_modules/@shikijs/langs/dist/gdshader.js +2 -3
  356. package/dist/node_modules/@shikijs/langs/dist/genie.js +2 -3
  357. package/dist/node_modules/@shikijs/langs/dist/gherkin.js +2 -3
  358. package/dist/node_modules/@shikijs/langs/dist/git-commit.js +3 -5
  359. package/dist/node_modules/@shikijs/langs/dist/git-rebase.js +3 -5
  360. package/dist/node_modules/@shikijs/langs/dist/gleam.js +2 -3
  361. package/dist/node_modules/@shikijs/langs/dist/glimmer-js.js +11 -13
  362. package/dist/node_modules/@shikijs/langs/dist/glimmer-ts.js +11 -13
  363. package/dist/node_modules/@shikijs/langs/dist/glsl.js +3 -5
  364. package/dist/node_modules/@shikijs/langs/dist/gn.js +2 -3
  365. package/dist/node_modules/@shikijs/langs/dist/gnuplot.js +2 -3
  366. package/dist/node_modules/@shikijs/langs/dist/go.js +2 -3
  367. package/dist/node_modules/@shikijs/langs/dist/graphql.js +11 -13
  368. package/dist/node_modules/@shikijs/langs/dist/groovy.js +2 -3
  369. package/dist/node_modules/@shikijs/langs/dist/hack.js +7 -9
  370. package/dist/node_modules/@shikijs/langs/dist/haml.js +7 -9
  371. package/dist/node_modules/@shikijs/langs/dist/handlebars.js +11 -13
  372. package/dist/node_modules/@shikijs/langs/dist/haskell.js +2 -3
  373. package/dist/node_modules/@shikijs/langs/dist/haxe.js +2 -3
  374. package/dist/node_modules/@shikijs/langs/dist/hcl.js +2 -3
  375. package/dist/node_modules/@shikijs/langs/dist/hjson.js +2 -3
  376. package/dist/node_modules/@shikijs/langs/dist/hlsl.js +2 -3
  377. package/dist/node_modules/@shikijs/langs/dist/html-derivative.js +3 -5
  378. package/dist/node_modules/@shikijs/langs/dist/html.js +7 -9
  379. package/dist/node_modules/@shikijs/langs/dist/http.js +11 -13
  380. package/dist/node_modules/@shikijs/langs/dist/hurl.js +9 -11
  381. package/dist/node_modules/@shikijs/langs/dist/hxml.js +3 -5
  382. package/dist/node_modules/@shikijs/langs/dist/hy.js +2 -3
  383. package/dist/node_modules/@shikijs/langs/dist/imba.js +2 -3
  384. package/dist/node_modules/@shikijs/langs/dist/ini.js +2 -3
  385. package/dist/node_modules/@shikijs/langs/dist/java.js +2 -3
  386. package/dist/node_modules/@shikijs/langs/dist/javascript.js +2 -3
  387. package/dist/node_modules/@shikijs/langs/dist/jinja-html.js +3 -5
  388. package/dist/node_modules/@shikijs/langs/dist/jinja.js +3 -5
  389. package/dist/node_modules/@shikijs/langs/dist/jison.js +3 -5
  390. package/dist/node_modules/@shikijs/langs/dist/json.js +2 -3
  391. package/dist/node_modules/@shikijs/langs/dist/json5.js +2 -3
  392. package/dist/node_modules/@shikijs/langs/dist/jsonc.js +2 -3
  393. package/dist/node_modules/@shikijs/langs/dist/jsonl.js +2 -3
  394. package/dist/node_modules/@shikijs/langs/dist/jsonnet.js +2 -3
  395. package/dist/node_modules/@shikijs/langs/dist/jssm.js +2 -3
  396. package/dist/node_modules/@shikijs/langs/dist/jsx.js +2 -3
  397. package/dist/node_modules/@shikijs/langs/dist/julia.js +13 -15
  398. package/dist/node_modules/@shikijs/langs/dist/just.js +15 -17
  399. package/dist/node_modules/@shikijs/langs/dist/kdl.js +2 -3
  400. package/dist/node_modules/@shikijs/langs/dist/kotlin.js +2 -3
  401. package/dist/node_modules/@shikijs/langs/dist/kusto.js +2 -3
  402. package/dist/node_modules/@shikijs/langs/dist/latex.js +3 -5
  403. package/dist/node_modules/@shikijs/langs/dist/lean.js +2 -3
  404. package/dist/node_modules/@shikijs/langs/dist/less.js +2 -3
  405. package/dist/node_modules/@shikijs/langs/dist/liquid.js +11 -13
  406. package/dist/node_modules/@shikijs/langs/dist/llvm.js +2 -3
  407. package/dist/node_modules/@shikijs/langs/dist/log.js +2 -3
  408. package/dist/node_modules/@shikijs/langs/dist/logo.js +2 -3
  409. package/dist/node_modules/@shikijs/langs/dist/lua.js +3 -5
  410. package/dist/node_modules/@shikijs/langs/dist/luau.js +2 -3
  411. package/dist/node_modules/@shikijs/langs/dist/make.js +2 -3
  412. package/dist/node_modules/@shikijs/langs/dist/markdown-nix.js +2 -3
  413. package/dist/node_modules/@shikijs/langs/dist/markdown-vue.js +2 -3
  414. package/dist/node_modules/@shikijs/langs/dist/markdown.js +2 -3
  415. package/dist/node_modules/@shikijs/langs/dist/marko.js +11 -13
  416. package/dist/node_modules/@shikijs/langs/dist/matlab.js +2 -3
  417. package/dist/node_modules/@shikijs/langs/dist/mdc.js +9 -11
  418. package/dist/node_modules/@shikijs/langs/dist/mdx.js +2 -3
  419. package/dist/node_modules/@shikijs/langs/dist/mermaid.js +2 -3
  420. package/dist/node_modules/@shikijs/langs/dist/mipsasm.js +2 -3
  421. package/dist/node_modules/@shikijs/langs/dist/mojo.js +2 -3
  422. package/dist/node_modules/@shikijs/langs/dist/moonbit.js +2 -3
  423. package/dist/node_modules/@shikijs/langs/dist/move.js +2 -3
  424. package/dist/node_modules/@shikijs/langs/dist/narrat.js +2 -3
  425. package/dist/node_modules/@shikijs/langs/dist/nextflow-groovy.js +2 -3
  426. package/dist/node_modules/@shikijs/langs/dist/nextflow.js +3 -5
  427. package/dist/node_modules/@shikijs/langs/dist/nginx.js +3 -5
  428. package/dist/node_modules/@shikijs/langs/dist/nim.js +17 -19
  429. package/dist/node_modules/@shikijs/langs/dist/nix.js +3 -5
  430. package/dist/node_modules/@shikijs/langs/dist/nushell.js +2 -3
  431. package/dist/node_modules/@shikijs/langs/dist/objective-c.js +2 -3
  432. package/dist/node_modules/@shikijs/langs/dist/objective-cpp.js +2 -3
  433. package/dist/node_modules/@shikijs/langs/dist/ocaml.js +2 -3
  434. package/dist/node_modules/@shikijs/langs/dist/odin.js +2 -3
  435. package/dist/node_modules/@shikijs/langs/dist/openscad.js +2 -3
  436. package/dist/node_modules/@shikijs/langs/dist/pascal.js +2 -3
  437. package/dist/node_modules/@shikijs/langs/dist/perl.js +13 -15
  438. package/dist/node_modules/@shikijs/langs/dist/php.js +15 -17
  439. package/dist/node_modules/@shikijs/langs/dist/pkl.js +2 -3
  440. package/dist/node_modules/@shikijs/langs/dist/plsql.js +2 -3
  441. package/dist/node_modules/@shikijs/langs/dist/po.js +2 -3
  442. package/dist/node_modules/@shikijs/langs/dist/polar.js +2 -3
  443. package/dist/node_modules/@shikijs/langs/dist/postcss.js +2 -3
  444. package/dist/node_modules/@shikijs/langs/dist/powerquery.js +2 -3
  445. package/dist/node_modules/@shikijs/langs/dist/powershell.js +2 -3
  446. package/dist/node_modules/@shikijs/langs/dist/prisma.js +2 -3
  447. package/dist/node_modules/@shikijs/langs/dist/prolog.js +2 -3
  448. package/dist/node_modules/@shikijs/langs/dist/proto.js +2 -3
  449. package/dist/node_modules/@shikijs/langs/dist/pug.js +9 -11
  450. package/dist/node_modules/@shikijs/langs/dist/puppet.js +2 -3
  451. package/dist/node_modules/@shikijs/langs/dist/purescript.js +2 -3
  452. package/dist/node_modules/@shikijs/langs/dist/python.js +2 -3
  453. package/dist/node_modules/@shikijs/langs/dist/qml.js +3 -5
  454. package/dist/node_modules/@shikijs/langs/dist/qmldir.js +2 -3
  455. package/dist/node_modules/@shikijs/langs/dist/qss.js +2 -3
  456. package/dist/node_modules/@shikijs/langs/dist/r.js +2 -3
  457. package/dist/node_modules/@shikijs/langs/dist/racket.js +2 -3
  458. package/dist/node_modules/@shikijs/langs/dist/raku.js +2 -3
  459. package/dist/node_modules/@shikijs/langs/dist/razor.js +7 -9
  460. package/dist/node_modules/@shikijs/langs/dist/reg.js +2 -3
  461. package/dist/node_modules/@shikijs/langs/dist/regexp.js +2 -3
  462. package/dist/node_modules/@shikijs/langs/dist/rel.js +2 -3
  463. package/dist/node_modules/@shikijs/langs/dist/riscv.js +2 -3
  464. package/dist/node_modules/@shikijs/langs/dist/ron.js +2 -3
  465. package/dist/node_modules/@shikijs/langs/dist/rosmsg.js +2 -3
  466. package/dist/node_modules/@shikijs/langs/dist/rst.js +19 -21
  467. package/dist/node_modules/@shikijs/langs/dist/ruby.js +27 -29
  468. package/dist/node_modules/@shikijs/langs/dist/rust.js +2 -3
  469. package/dist/node_modules/@shikijs/langs/dist/sas.js +3 -5
  470. package/dist/node_modules/@shikijs/langs/dist/sass.js +2 -3
  471. package/dist/node_modules/@shikijs/langs/dist/scala.js +2 -3
  472. package/dist/node_modules/@shikijs/langs/dist/scheme.js +2 -3
  473. package/dist/node_modules/@shikijs/langs/dist/scss.js +3 -5
  474. package/dist/node_modules/@shikijs/langs/dist/sdbl.js +2 -3
  475. package/dist/node_modules/@shikijs/langs/dist/shaderlab.js +3 -5
  476. package/dist/node_modules/@shikijs/langs/dist/shellscript.js +2 -3
  477. package/dist/node_modules/@shikijs/langs/dist/shellsession.js +3 -5
  478. package/dist/node_modules/@shikijs/langs/dist/smalltalk.js +2 -3
  479. package/dist/node_modules/@shikijs/langs/dist/solidity.js +2 -3
  480. package/dist/node_modules/@shikijs/langs/dist/soy.js +3 -5
  481. package/dist/node_modules/@shikijs/langs/dist/sparql.js +3 -5
  482. package/dist/node_modules/@shikijs/langs/dist/splunk.js +2 -3
  483. package/dist/node_modules/@shikijs/langs/dist/sql.js +2 -3
  484. package/dist/node_modules/@shikijs/langs/dist/ssh-config.js +2 -3
  485. package/dist/node_modules/@shikijs/langs/dist/stata.js +3 -5
  486. package/dist/node_modules/@shikijs/langs/dist/stylus.js +2 -3
  487. package/dist/node_modules/@shikijs/langs/dist/surrealql.js +3 -5
  488. package/dist/node_modules/@shikijs/langs/dist/svelte.js +11 -13
  489. package/dist/node_modules/@shikijs/langs/dist/swift.js +2 -3
  490. package/dist/node_modules/@shikijs/langs/dist/system-verilog.js +2 -3
  491. package/dist/node_modules/@shikijs/langs/dist/systemd.js +2 -3
  492. package/dist/node_modules/@shikijs/langs/dist/talonscript.js +2 -3
  493. package/dist/node_modules/@shikijs/langs/dist/tasl.js +2 -3
  494. package/dist/node_modules/@shikijs/langs/dist/tcl.js +2 -3
  495. package/dist/node_modules/@shikijs/langs/dist/templ.js +9 -11
  496. package/dist/node_modules/@shikijs/langs/dist/terraform.js +2 -3
  497. package/dist/node_modules/@shikijs/langs/dist/tex.js +3 -5
  498. package/dist/node_modules/@shikijs/langs/dist/toml.js +2 -3
  499. package/dist/node_modules/@shikijs/langs/dist/ts-tags.js +15 -17
  500. package/dist/node_modules/@shikijs/langs/dist/tsv.js +2 -3
  501. package/dist/node_modules/@shikijs/langs/dist/tsx.js +2 -3
  502. package/dist/node_modules/@shikijs/langs/dist/turtle.js +2 -3
  503. package/dist/node_modules/@shikijs/langs/dist/twig.js +15 -17
  504. package/dist/node_modules/@shikijs/langs/dist/typescript.js +2 -3
  505. package/dist/node_modules/@shikijs/langs/dist/typespec.js +2 -3
  506. package/dist/node_modules/@shikijs/langs/dist/typst.js +2 -3
  507. package/dist/node_modules/@shikijs/langs/dist/v.js +2 -3
  508. package/dist/node_modules/@shikijs/langs/dist/vala.js +2 -3
  509. package/dist/node_modules/@shikijs/langs/dist/vb.js +2 -3
  510. package/dist/node_modules/@shikijs/langs/dist/verilog.js +2 -3
  511. package/dist/node_modules/@shikijs/langs/dist/vhdl.js +2 -3
  512. package/dist/node_modules/@shikijs/langs/dist/viml.js +2 -3
  513. package/dist/node_modules/@shikijs/langs/dist/vue-directives.js +2 -3
  514. package/dist/node_modules/@shikijs/langs/dist/vue-html.js +3 -5
  515. package/dist/node_modules/@shikijs/langs/dist/vue-interpolations.js +2 -3
  516. package/dist/node_modules/@shikijs/langs/dist/vue-sfc-style-variable-injection.js +3 -5
  517. package/dist/node_modules/@shikijs/langs/dist/vue-vine.js +15 -17
  518. package/dist/node_modules/@shikijs/langs/dist/vue.js +23 -25
  519. package/dist/node_modules/@shikijs/langs/dist/vyper.js +2 -3
  520. package/dist/node_modules/@shikijs/langs/dist/wasm.js +2 -3
  521. package/dist/node_modules/@shikijs/langs/dist/wenyan.js +2 -3
  522. package/dist/node_modules/@shikijs/langs/dist/wgsl.js +2 -3
  523. package/dist/node_modules/@shikijs/langs/dist/wikitext.js +2 -3
  524. package/dist/node_modules/@shikijs/langs/dist/wit.js +2 -3
  525. package/dist/node_modules/@shikijs/langs/dist/wolfram.js +2 -3
  526. package/dist/node_modules/@shikijs/langs/dist/xml.js +3 -5
  527. package/dist/node_modules/@shikijs/langs/dist/xsl.js +3 -5
  528. package/dist/node_modules/@shikijs/langs/dist/yaml.js +2 -3
  529. package/dist/node_modules/@shikijs/langs/dist/zenscript.js +2 -3
  530. package/dist/node_modules/@shikijs/langs/dist/zig.js +2 -3
  531. package/dist/node_modules/@shikijs/primitive/dist/index.js +319 -321
  532. package/dist/node_modules/@shikijs/themes/dist/andromeeda.js +2 -4
  533. package/dist/node_modules/@shikijs/themes/dist/aurora-x.js +2 -4
  534. package/dist/node_modules/@shikijs/themes/dist/ayu-dark.js +2 -4
  535. package/dist/node_modules/@shikijs/themes/dist/ayu-light.js +2 -4
  536. package/dist/node_modules/@shikijs/themes/dist/ayu-mirage.js +2 -4
  537. package/dist/node_modules/@shikijs/themes/dist/catppuccin-frappe.js +2 -4
  538. package/dist/node_modules/@shikijs/themes/dist/catppuccin-latte.js +2 -4
  539. package/dist/node_modules/@shikijs/themes/dist/catppuccin-macchiato.js +2 -4
  540. package/dist/node_modules/@shikijs/themes/dist/catppuccin-mocha.js +2 -4
  541. package/dist/node_modules/@shikijs/themes/dist/dark-plus.js +2 -4
  542. package/dist/node_modules/@shikijs/themes/dist/dracula-soft.js +2 -4
  543. package/dist/node_modules/@shikijs/themes/dist/dracula.js +2 -4
  544. package/dist/node_modules/@shikijs/themes/dist/everforest-dark.js +2 -4
  545. package/dist/node_modules/@shikijs/themes/dist/everforest-light.js +2 -4
  546. package/dist/node_modules/@shikijs/themes/dist/github-dark-default.js +2 -4
  547. package/dist/node_modules/@shikijs/themes/dist/github-dark-dimmed.js +2 -4
  548. package/dist/node_modules/@shikijs/themes/dist/github-dark-high-contrast.js +2 -4
  549. package/dist/node_modules/@shikijs/themes/dist/github-dark.js +2 -4
  550. package/dist/node_modules/@shikijs/themes/dist/github-light-default.js +2 -4
  551. package/dist/node_modules/@shikijs/themes/dist/github-light-high-contrast.js +2 -4
  552. package/dist/node_modules/@shikijs/themes/dist/github-light.js +2 -4
  553. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-hard.js +2 -4
  554. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-medium.js +2 -4
  555. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-soft.js +2 -4
  556. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-hard.js +2 -4
  557. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-medium.js +2 -4
  558. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-soft.js +2 -4
  559. package/dist/node_modules/@shikijs/themes/dist/horizon-bright.js +2 -4
  560. package/dist/node_modules/@shikijs/themes/dist/horizon.js +2 -4
  561. package/dist/node_modules/@shikijs/themes/dist/houston.js +2 -4
  562. package/dist/node_modules/@shikijs/themes/dist/kanagawa-dragon.js +2 -4
  563. package/dist/node_modules/@shikijs/themes/dist/kanagawa-lotus.js +2 -4
  564. package/dist/node_modules/@shikijs/themes/dist/kanagawa-wave.js +2 -4
  565. package/dist/node_modules/@shikijs/themes/dist/laserwave.js +2 -4
  566. package/dist/node_modules/@shikijs/themes/dist/light-plus.js +2 -4
  567. package/dist/node_modules/@shikijs/themes/dist/material-theme-darker.js +2 -4
  568. package/dist/node_modules/@shikijs/themes/dist/material-theme-lighter.js +2 -4
  569. package/dist/node_modules/@shikijs/themes/dist/material-theme-ocean.js +2 -4
  570. package/dist/node_modules/@shikijs/themes/dist/material-theme-palenight.js +2 -4
  571. package/dist/node_modules/@shikijs/themes/dist/material-theme.js +2 -4
  572. package/dist/node_modules/@shikijs/themes/dist/min-dark.js +2 -4
  573. package/dist/node_modules/@shikijs/themes/dist/min-light.js +2 -4
  574. package/dist/node_modules/@shikijs/themes/dist/monokai.js +2 -4
  575. package/dist/node_modules/@shikijs/themes/dist/night-owl-light.js +2 -4
  576. package/dist/node_modules/@shikijs/themes/dist/night-owl.js +2 -4
  577. package/dist/node_modules/@shikijs/themes/dist/nord.js +2 -4
  578. package/dist/node_modules/@shikijs/themes/dist/one-dark-pro.js +2 -4
  579. package/dist/node_modules/@shikijs/themes/dist/one-light.js +2 -4
  580. package/dist/node_modules/@shikijs/themes/dist/plastic.js +2 -4
  581. package/dist/node_modules/@shikijs/themes/dist/poimandres.js +2 -4
  582. package/dist/node_modules/@shikijs/themes/dist/red.js +2 -4
  583. package/dist/node_modules/@shikijs/themes/dist/rose-pine-dawn.js +2 -4
  584. package/dist/node_modules/@shikijs/themes/dist/rose-pine-moon.js +2 -4
  585. package/dist/node_modules/@shikijs/themes/dist/rose-pine.js +2 -4
  586. package/dist/node_modules/@shikijs/themes/dist/slack-dark.js +2 -4
  587. package/dist/node_modules/@shikijs/themes/dist/slack-ochin.js +2 -4
  588. package/dist/node_modules/@shikijs/themes/dist/snazzy-light.js +2 -4
  589. package/dist/node_modules/@shikijs/themes/dist/solarized-dark.js +2 -4
  590. package/dist/node_modules/@shikijs/themes/dist/solarized-light.js +2 -4
  591. package/dist/node_modules/@shikijs/themes/dist/synthwave-84.js +2 -4
  592. package/dist/node_modules/@shikijs/themes/dist/tokyo-night.js +2 -4
  593. package/dist/node_modules/@shikijs/themes/dist/vesper.js +2 -4
  594. package/dist/node_modules/@shikijs/themes/dist/vitesse-black.js +2 -4
  595. package/dist/node_modules/@shikijs/themes/dist/vitesse-dark.js +2 -4
  596. package/dist/node_modules/@shikijs/themes/dist/vitesse-light.js +2 -4
  597. package/dist/node_modules/@shikijs/types/dist/index.js +2 -4
  598. package/dist/node_modules/@shikijs/vscode-textmate/dist/index.js +947 -949
  599. package/dist/node_modules/@ungap/structured-clone/esm/deserialize.js +30 -30
  600. package/dist/node_modules/@ungap/structured-clone/esm/index.js +4 -6
  601. package/dist/node_modules/@ungap/structured-clone/esm/serialize.js +64 -64
  602. package/dist/node_modules/@ungap/structured-clone/esm/types.js +2 -0
  603. package/dist/node_modules/@upsetjs/venn.js/build/venn.esm.js +693 -695
  604. package/dist/node_modules/@xyflow/react/dist/esm/index.js +881 -883
  605. package/dist/node_modules/@xyflow/system/dist/esm/index.js +1221 -1223
  606. package/dist/node_modules/bail/index.js +2 -4
  607. package/dist/node_modules/ccount/index.js +2 -4
  608. package/dist/node_modules/character-entities-html4/index.js +2 -4
  609. package/dist/node_modules/character-entities-legacy/index.js +2 -4
  610. package/dist/node_modules/chevrotain/lib/src/api.js +10 -10
  611. package/dist/node_modules/chevrotain/lib/src/lang/lang_extensions.js +4 -6
  612. package/dist/node_modules/chevrotain/lib/src/parse/constants.js +2 -4
  613. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst.js +9 -11
  614. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst_visitor.js +15 -17
  615. package/dist/node_modules/chevrotain/lib/src/parse/errors_public.js +17 -19
  616. package/dist/node_modules/chevrotain/lib/src/parse/exceptions_public.js +24 -26
  617. package/dist/node_modules/chevrotain/lib/src/parse/grammar/checks.js +201 -203
  618. package/dist/node_modules/chevrotain/lib/src/parse/grammar/first.js +16 -18
  619. package/dist/node_modules/chevrotain/lib/src/parse/grammar/follow.js +17 -19
  620. package/dist/node_modules/chevrotain/lib/src/parse/grammar/gast/gast_resolver_public.js +12 -14
  621. package/dist/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js +140 -142
  622. package/dist/node_modules/chevrotain/lib/src/parse/grammar/keys.js +4 -5
  623. package/dist/node_modules/chevrotain/lib/src/parse/grammar/llk_lookahead.js +25 -27
  624. package/dist/node_modules/chevrotain/lib/src/parse/grammar/lookahead.js +149 -151
  625. package/dist/node_modules/chevrotain/lib/src/parse/grammar/resolver.js +14 -16
  626. package/dist/node_modules/chevrotain/lib/src/parse/grammar/rest.js +38 -40
  627. package/dist/node_modules/chevrotain/lib/src/parse/parser/parser.js +64 -65
  628. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/error_handler.js +11 -13
  629. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/gast_recorder.js +101 -103
  630. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/lexer_adapter.js +5 -7
  631. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/looksahead.js +45 -47
  632. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/perf_tracer.js +6 -8
  633. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_api.js +73 -75
  634. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_engine.js +180 -182
  635. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recoverable.js +23 -24
  636. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/tree_builder.js +26 -28
  637. package/dist/node_modules/chevrotain/lib/src/parse/parser/utils/apply_mixins.js +2 -4
  638. package/dist/node_modules/chevrotain/lib/src/scan/lexer.js +246 -246
  639. package/dist/node_modules/chevrotain/lib/src/scan/lexer_errors_public.js +2 -4
  640. package/dist/node_modules/chevrotain/lib/src/scan/lexer_public.js +31 -33
  641. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp.js +64 -67
  642. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp_parser.js +10 -12
  643. package/dist/node_modules/chevrotain/lib/src/scan/tokens.js +35 -36
  644. package/dist/node_modules/chevrotain/lib/src/scan/tokens_public.js +26 -28
  645. package/dist/node_modules/chevrotain-allstar/lib/all-star-lookahead.js +240 -242
  646. package/dist/node_modules/chevrotain-allstar/lib/atn.js +133 -134
  647. package/dist/node_modules/chevrotain-allstar/lib/dfa.js +10 -11
  648. package/dist/node_modules/chevrotain-allstar/lib/index.js +1 -1
  649. package/dist/node_modules/classcat/index.js +3 -5
  650. package/dist/node_modules/comma-separated-tokens/index.js +3 -5
  651. package/dist/node_modules/cose-base/cose-base.js +21 -21
  652. package/dist/node_modules/cytoscape/dist/cytoscape.esm.js +7940 -7937
  653. package/dist/node_modules/cytoscape-cose-bilkent/cytoscape-cose-bilkent.js +6 -8
  654. package/dist/node_modules/cytoscape-fcose/cytoscape-fcose.js +6 -8
  655. package/dist/node_modules/cytoscape-fcose/node_modules/cose-base/cose-base.js +20 -20
  656. package/dist/node_modules/cytoscape-fcose/node_modules/layout-base/layout-base.js +4 -6
  657. package/dist/node_modules/d3/src/index.js +95 -95
  658. package/dist/node_modules/d3-array/src/ascending.js +2 -4
  659. package/dist/node_modules/d3-array/src/bisect.js +8 -8
  660. package/dist/node_modules/d3-array/src/bisector.js +6 -8
  661. package/dist/node_modules/d3-array/src/descending.js +2 -4
  662. package/dist/node_modules/d3-array/src/max.js +2 -4
  663. package/dist/node_modules/d3-array/src/min.js +2 -4
  664. package/dist/node_modules/d3-array/src/number.js +2 -4
  665. package/dist/node_modules/d3-array/src/range.js +2 -4
  666. package/dist/node_modules/d3-array/src/ticks.js +11 -13
  667. package/dist/node_modules/d3-axis/src/axis.js +46 -48
  668. package/dist/node_modules/d3-axis/src/identity.js +2 -4
  669. package/dist/node_modules/d3-brush/src/brush.js +4 -6
  670. package/dist/node_modules/d3-color/src/color.js +84 -86
  671. package/dist/node_modules/d3-color/src/define.js +3 -5
  672. package/dist/node_modules/d3-color/src/lab.js +43 -45
  673. package/dist/node_modules/d3-color/src/math.js +2 -4
  674. package/dist/node_modules/d3-dispatch/src/dispatch.js +17 -18
  675. package/dist/node_modules/d3-drag/src/constant.js +2 -4
  676. package/dist/node_modules/d3-drag/src/drag.js +75 -77
  677. package/dist/node_modules/d3-drag/src/event.js +3 -5
  678. package/dist/node_modules/d3-drag/src/nodrag.js +9 -11
  679. package/dist/node_modules/d3-drag/src/noevent.js +4 -6
  680. package/dist/node_modules/d3-ease/src/cubic.js +2 -4
  681. package/dist/node_modules/d3-format/src/defaultLocale.js +6 -8
  682. package/dist/node_modules/d3-format/src/exponent.js +4 -6
  683. package/dist/node_modules/d3-format/src/formatDecimal.js +3 -5
  684. package/dist/node_modules/d3-format/src/formatGroup.js +2 -4
  685. package/dist/node_modules/d3-format/src/formatNumerals.js +2 -4
  686. package/dist/node_modules/d3-format/src/formatPrefixAuto.js +8 -10
  687. package/dist/node_modules/d3-format/src/formatRounded.js +4 -6
  688. package/dist/node_modules/d3-format/src/formatSpecifier.js +8 -10
  689. package/dist/node_modules/d3-format/src/formatTrim.js +2 -4
  690. package/dist/node_modules/d3-format/src/formatTypes.js +13 -15
  691. package/dist/node_modules/d3-format/src/identity.js +2 -4
  692. package/dist/node_modules/d3-format/src/locale.js +31 -33
  693. package/dist/node_modules/d3-format/src/precisionFixed.js +4 -6
  694. package/dist/node_modules/d3-format/src/precisionPrefix.js +4 -6
  695. package/dist/node_modules/d3-format/src/precisionRound.js +4 -6
  696. package/dist/node_modules/d3-hierarchy/src/accessors.js +2 -4
  697. package/dist/node_modules/d3-hierarchy/src/constant.js +3 -5
  698. package/dist/node_modules/d3-hierarchy/src/hierarchy/ancestors.js +2 -4
  699. package/dist/node_modules/d3-hierarchy/src/hierarchy/count.js +4 -6
  700. package/dist/node_modules/d3-hierarchy/src/hierarchy/descendants.js +2 -4
  701. package/dist/node_modules/d3-hierarchy/src/hierarchy/each.js +2 -4
  702. package/dist/node_modules/d3-hierarchy/src/hierarchy/eachAfter.js +2 -4
  703. package/dist/node_modules/d3-hierarchy/src/hierarchy/eachBefore.js +2 -4
  704. package/dist/node_modules/d3-hierarchy/src/hierarchy/find.js +2 -4
  705. package/dist/node_modules/d3-hierarchy/src/hierarchy/index.js +44 -46
  706. package/dist/node_modules/d3-hierarchy/src/hierarchy/iterator.js +2 -4
  707. package/dist/node_modules/d3-hierarchy/src/hierarchy/leaves.js +2 -4
  708. package/dist/node_modules/d3-hierarchy/src/hierarchy/links.js +2 -4
  709. package/dist/node_modules/d3-hierarchy/src/hierarchy/path.js +4 -6
  710. package/dist/node_modules/d3-hierarchy/src/hierarchy/sort.js +2 -4
  711. package/dist/node_modules/d3-hierarchy/src/hierarchy/sum.js +2 -4
  712. package/dist/node_modules/d3-hierarchy/src/treemap/dice.js +2 -4
  713. package/dist/node_modules/d3-hierarchy/src/treemap/index.js +14 -16
  714. package/dist/node_modules/d3-hierarchy/src/treemap/round.js +2 -4
  715. package/dist/node_modules/d3-hierarchy/src/treemap/slice.js +2 -4
  716. package/dist/node_modules/d3-hierarchy/src/treemap/squarify.js +9 -11
  717. package/dist/node_modules/d3-interpolate/src/array.js +4 -6
  718. package/dist/node_modules/d3-interpolate/src/basis.js +4 -6
  719. package/dist/node_modules/d3-interpolate/src/basisClosed.js +4 -6
  720. package/dist/node_modules/d3-interpolate/src/color.js +17 -19
  721. package/dist/node_modules/d3-interpolate/src/constant.js +2 -4
  722. package/dist/node_modules/d3-interpolate/src/date.js +2 -4
  723. package/dist/node_modules/d3-interpolate/src/hcl.js +6 -8
  724. package/dist/node_modules/d3-interpolate/src/number.js +2 -4
  725. package/dist/node_modules/d3-interpolate/src/numberArray.js +3 -5
  726. package/dist/node_modules/d3-interpolate/src/object.js +4 -6
  727. package/dist/node_modules/d3-interpolate/src/rgb.js +9 -11
  728. package/dist/node_modules/d3-interpolate/src/round.js +2 -4
  729. package/dist/node_modules/d3-interpolate/src/string.js +14 -16
  730. package/dist/node_modules/d3-interpolate/src/transform/decompose.js +5 -7
  731. package/dist/node_modules/d3-interpolate/src/transform/index.js +11 -13
  732. package/dist/node_modules/d3-interpolate/src/transform/parse.js +8 -10
  733. package/dist/node_modules/d3-interpolate/src/value.js +12 -14
  734. package/dist/node_modules/d3-interpolate/src/zoom.js +11 -13
  735. package/dist/node_modules/d3-path/src/path.js +14 -16
  736. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/max.js +2 -4
  737. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/min.js +2 -4
  738. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/sum.js +2 -4
  739. package/dist/node_modules/d3-sankey/node_modules/d3-path/src/path.js +12 -13
  740. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/array.js +2 -4
  741. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/constant.js +2 -4
  742. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/link/index.js +17 -19
  743. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/point.js +3 -5
  744. package/dist/node_modules/d3-sankey/src/align.js +10 -12
  745. package/dist/node_modules/d3-sankey/src/constant.js +2 -4
  746. package/dist/node_modules/d3-sankey/src/sankey.js +168 -170
  747. package/dist/node_modules/d3-sankey/src/sankeyLinkHorizontal.js +6 -8
  748. package/dist/node_modules/d3-scale/src/band.js +9 -11
  749. package/dist/node_modules/d3-scale/src/constant.js +2 -4
  750. package/dist/node_modules/d3-scale/src/continuous.js +47 -49
  751. package/dist/node_modules/d3-scale/src/init.js +2 -4
  752. package/dist/node_modules/d3-scale/src/linear.js +13 -15
  753. package/dist/node_modules/d3-scale/src/nice.js +2 -4
  754. package/dist/node_modules/d3-scale/src/number.js +2 -4
  755. package/dist/node_modules/d3-scale/src/ordinal.js +16 -18
  756. package/dist/node_modules/d3-scale/src/tickFormat.js +14 -16
  757. package/dist/node_modules/d3-scale/src/time.js +34 -36
  758. package/dist/node_modules/d3-scale-chromatic/src/categorical/Tableau10.js +3 -5
  759. package/dist/node_modules/d3-scale-chromatic/src/colors.js +2 -4
  760. package/dist/node_modules/d3-selection/src/array.js +2 -4
  761. package/dist/node_modules/d3-selection/src/constant.js +2 -4
  762. package/dist/node_modules/d3-selection/src/creator.js +10 -12
  763. package/dist/node_modules/d3-selection/src/matcher.js +3 -5
  764. package/dist/node_modules/d3-selection/src/namespace.js +5 -7
  765. package/dist/node_modules/d3-selection/src/namespaces.js +3 -5
  766. package/dist/node_modules/d3-selection/src/pointer.js +4 -6
  767. package/dist/node_modules/d3-selection/src/select.js +4 -6
  768. package/dist/node_modules/d3-selection/src/selection/append.js +4 -6
  769. package/dist/node_modules/d3-selection/src/selection/attr.js +17 -19
  770. package/dist/node_modules/d3-selection/src/selection/call.js +2 -4
  771. package/dist/node_modules/d3-selection/src/selection/classed.js +23 -25
  772. package/dist/node_modules/d3-selection/src/selection/clone.js +5 -7
  773. package/dist/node_modules/d3-selection/src/selection/data.js +16 -18
  774. package/dist/node_modules/d3-selection/src/selection/datum.js +2 -4
  775. package/dist/node_modules/d3-selection/src/selection/dispatch.js +10 -12
  776. package/dist/node_modules/d3-selection/src/selection/each.js +2 -4
  777. package/dist/node_modules/d3-selection/src/selection/empty.js +2 -4
  778. package/dist/node_modules/d3-selection/src/selection/enter.js +11 -13
  779. package/dist/node_modules/d3-selection/src/selection/exit.js +5 -7
  780. package/dist/node_modules/d3-selection/src/selection/filter.js +6 -8
  781. package/dist/node_modules/d3-selection/src/selection/html.js +6 -8
  782. package/dist/node_modules/d3-selection/src/selection/index.js +79 -80
  783. package/dist/node_modules/d3-selection/src/selection/insert.js +6 -8
  784. package/dist/node_modules/d3-selection/src/selection/iterator.js +2 -4
  785. package/dist/node_modules/d3-selection/src/selection/join.js +2 -4
  786. package/dist/node_modules/d3-selection/src/selection/lower.js +4 -6
  787. package/dist/node_modules/d3-selection/src/selection/merge.js +4 -6
  788. package/dist/node_modules/d3-selection/src/selection/node.js +2 -4
  789. package/dist/node_modules/d3-selection/src/selection/nodes.js +2 -4
  790. package/dist/node_modules/d3-selection/src/selection/on.js +9 -11
  791. package/dist/node_modules/d3-selection/src/selection/order.js +2 -4
  792. package/dist/node_modules/d3-selection/src/selection/property.js +6 -8
  793. package/dist/node_modules/d3-selection/src/selection/raise.js +4 -6
  794. package/dist/node_modules/d3-selection/src/selection/remove.js +4 -6
  795. package/dist/node_modules/d3-selection/src/selection/select.js +6 -8
  796. package/dist/node_modules/d3-selection/src/selection/selectAll.js +9 -11
  797. package/dist/node_modules/d3-selection/src/selection/selectChild.js +8 -10
  798. package/dist/node_modules/d3-selection/src/selection/selectChildren.js +8 -10
  799. package/dist/node_modules/d3-selection/src/selection/size.js +2 -4
  800. package/dist/node_modules/d3-selection/src/selection/sort.js +6 -8
  801. package/dist/node_modules/d3-selection/src/selection/sparse.js +2 -4
  802. package/dist/node_modules/d3-selection/src/selection/style.js +12 -14
  803. package/dist/node_modules/d3-selection/src/selection/text.js +6 -8
  804. package/dist/node_modules/d3-selection/src/selector.js +4 -6
  805. package/dist/node_modules/d3-selection/src/selectorAll.js +4 -6
  806. package/dist/node_modules/d3-selection/src/sourceEvent.js +2 -4
  807. package/dist/node_modules/d3-selection/src/window.js +2 -4
  808. package/dist/node_modules/d3-shape/src/arc.js +36 -38
  809. package/dist/node_modules/d3-shape/src/array.js +2 -3
  810. package/dist/node_modules/d3-shape/src/constant.js +2 -4
  811. package/dist/node_modules/d3-shape/src/curve/basis.js +8 -10
  812. package/dist/node_modules/d3-shape/src/curve/basisClosed.js +16 -18
  813. package/dist/node_modules/d3-shape/src/curve/basisOpen.js +7 -9
  814. package/dist/node_modules/d3-shape/src/curve/bump.js +13 -15
  815. package/dist/node_modules/d3-shape/src/curve/bundle.js +7 -9
  816. package/dist/node_modules/d3-shape/src/curve/cardinal.js +8 -10
  817. package/dist/node_modules/d3-shape/src/curve/cardinalClosed.js +10 -12
  818. package/dist/node_modules/d3-shape/src/curve/cardinalOpen.js +7 -9
  819. package/dist/node_modules/d3-shape/src/curve/catmullRom.js +17 -19
  820. package/dist/node_modules/d3-shape/src/curve/catmullRomClosed.js +11 -13
  821. package/dist/node_modules/d3-shape/src/curve/catmullRomOpen.js +8 -10
  822. package/dist/node_modules/d3-shape/src/curve/linear.js +5 -7
  823. package/dist/node_modules/d3-shape/src/curve/linearClosed.js +10 -12
  824. package/dist/node_modules/d3-shape/src/curve/monotone.js +21 -23
  825. package/dist/node_modules/d3-shape/src/curve/natural.js +7 -9
  826. package/dist/node_modules/d3-shape/src/curve/step.js +17 -19
  827. package/dist/node_modules/d3-shape/src/descending.js +2 -4
  828. package/dist/node_modules/d3-shape/src/identity.js +2 -4
  829. package/dist/node_modules/d3-shape/src/line.js +17 -19
  830. package/dist/node_modules/d3-shape/src/math.js +6 -8
  831. package/dist/node_modules/d3-shape/src/noop.js +2 -4
  832. package/dist/node_modules/d3-shape/src/path.js +4 -6
  833. package/dist/node_modules/d3-shape/src/pie.js +13 -15
  834. package/dist/node_modules/d3-shape/src/point.js +3 -5
  835. package/dist/node_modules/d3-time/src/day.js +15 -17
  836. package/dist/node_modules/d3-time/src/duration.js +2 -4
  837. package/dist/node_modules/d3-time/src/hour.js +14 -16
  838. package/dist/node_modules/d3-time/src/interval.js +5 -7
  839. package/dist/node_modules/d3-time/src/millisecond.js +5 -7
  840. package/dist/node_modules/d3-time/src/minute.js +14 -16
  841. package/dist/node_modules/d3-time/src/month.js +12 -14
  842. package/dist/node_modules/d3-time/src/second.js +7 -9
  843. package/dist/node_modules/d3-time/src/ticks.js +64 -66
  844. package/dist/node_modules/d3-time/src/week.js +19 -21
  845. package/dist/node_modules/d3-time/src/year.js +8 -10
  846. package/dist/node_modules/d3-time-format/src/defaultLocale.js +6 -8
  847. package/dist/node_modules/d3-time-format/src/locale.js +344 -346
  848. package/dist/node_modules/d3-timer/src/timeout.js +4 -6
  849. package/dist/node_modules/d3-timer/src/timer.js +31 -33
  850. package/dist/node_modules/d3-transition/src/index.js +2 -2
  851. package/dist/node_modules/d3-transition/src/interrupt.js +3 -4
  852. package/dist/node_modules/d3-transition/src/selection/index.js +4 -5
  853. package/dist/node_modules/d3-transition/src/selection/interrupt.js +4 -6
  854. package/dist/node_modules/d3-transition/src/selection/transition.js +14 -16
  855. package/dist/node_modules/d3-transition/src/transition/attr.js +26 -28
  856. package/dist/node_modules/d3-transition/src/transition/attrTween.js +11 -13
  857. package/dist/node_modules/d3-transition/src/transition/delay.js +9 -11
  858. package/dist/node_modules/d3-transition/src/transition/duration.js +9 -11
  859. package/dist/node_modules/d3-transition/src/transition/ease.js +6 -8
  860. package/dist/node_modules/d3-transition/src/transition/easeVarying.js +6 -8
  861. package/dist/node_modules/d3-transition/src/transition/end.js +4 -6
  862. package/dist/node_modules/d3-transition/src/transition/filter.js +6 -8
  863. package/dist/node_modules/d3-transition/src/transition/index.js +61 -63
  864. package/dist/node_modules/d3-transition/src/transition/interpolate.js +7 -9
  865. package/dist/node_modules/d3-transition/src/transition/merge.js +4 -6
  866. package/dist/node_modules/d3-transition/src/transition/on.js +7 -9
  867. package/dist/node_modules/d3-transition/src/transition/remove.js +4 -6
  868. package/dist/node_modules/d3-transition/src/transition/schedule.js +18 -20
  869. package/dist/node_modules/d3-transition/src/transition/select.js +8 -10
  870. package/dist/node_modules/d3-transition/src/transition/selectAll.js +8 -10
  871. package/dist/node_modules/d3-transition/src/transition/selection.js +5 -7
  872. package/dist/node_modules/d3-transition/src/transition/style.js +19 -21
  873. package/dist/node_modules/d3-transition/src/transition/styleTween.js +6 -8
  874. package/dist/node_modules/d3-transition/src/transition/text.js +6 -8
  875. package/dist/node_modules/d3-transition/src/transition/textTween.js +6 -8
  876. package/dist/node_modules/d3-transition/src/transition/transition.js +8 -10
  877. package/dist/node_modules/d3-transition/src/transition/tween.js +12 -14
  878. package/dist/node_modules/d3-zoom/src/constant.js +2 -4
  879. package/dist/node_modules/d3-zoom/src/event.js +2 -4
  880. package/dist/node_modules/d3-zoom/src/index.js +2 -2
  881. package/dist/node_modules/d3-zoom/src/noevent.js +3 -5
  882. package/dist/node_modules/d3-zoom/src/transform.js +10 -12
  883. package/dist/node_modules/d3-zoom/src/zoom.js +114 -116
  884. package/dist/node_modules/dagre-d3-es/src/dagre/acyclic.js +12 -14
  885. package/dist/node_modules/dagre-d3-es/src/dagre/add-border-segments.js +9 -11
  886. package/dist/node_modules/dagre-d3-es/src/dagre/coordinate-system.js +34 -36
  887. package/dist/node_modules/dagre-d3-es/src/dagre/data/list.js +7 -9
  888. package/dist/node_modules/dagre-d3-es/src/dagre/greedy-fas.js +49 -51
  889. package/dist/node_modules/dagre-d3-es/src/dagre/index.js +2 -2
  890. package/dist/node_modules/dagre-d3-es/src/dagre/layout.js +163 -165
  891. package/dist/node_modules/dagre-d3-es/src/dagre/nesting-graph.js +43 -45
  892. package/dist/node_modules/dagre-d3-es/src/dagre/normalize.js +10 -12
  893. package/dist/node_modules/dagre-d3-es/src/dagre/order/add-subgraph-constraints.js +4 -6
  894. package/dist/node_modules/dagre-d3-es/src/dagre/order/barycenter.js +6 -8
  895. package/dist/node_modules/dagre-d3-es/src/dagre/order/build-layer-graph.js +12 -14
  896. package/dist/node_modules/dagre-d3-es/src/dagre/order/cross-count.js +20 -22
  897. package/dist/node_modules/dagre-d3-es/src/dagre/order/index.js +34 -36
  898. package/dist/node_modules/dagre-d3-es/src/dagre/order/init-order.js +13 -15
  899. package/dist/node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js +30 -32
  900. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js +28 -30
  901. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort.js +18 -20
  902. package/dist/node_modules/dagre-d3-es/src/dagre/parent-dummy-chains.js +10 -12
  903. package/dist/node_modules/dagre-d3-es/src/dagre/position/bk.js +148 -150
  904. package/dist/node_modules/dagre-d3-es/src/dagre/position/index.js +18 -20
  905. package/dist/node_modules/dagre-d3-es/src/dagre/rank/feasible-tree.js +17 -19
  906. package/dist/node_modules/dagre-d3-es/src/dagre/rank/index.js +14 -16
  907. package/dist/node_modules/dagre-d3-es/src/dagre/rank/network-simplex.js +63 -64
  908. package/dist/node_modules/dagre-d3-es/src/dagre/rank/util.js +8 -10
  909. package/dist/node_modules/dagre-d3-es/src/dagre/util.js +82 -84
  910. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/dfs.js +13 -15
  911. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/dijkstra.js +2 -3
  912. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/floyd-warshall.js +2 -3
  913. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/index.js +3 -3
  914. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/postorder.js +4 -6
  915. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/preorder.js +4 -6
  916. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/topsort.js +11 -13
  917. package/dist/node_modules/dagre-d3-es/src/graphlib/graph.js +129 -131
  918. package/dist/node_modules/dagre-d3-es/src/graphlib/index.js +1 -1
  919. package/dist/node_modules/dagre-d3-es/src/graphlib/json.js +16 -18
  920. package/dist/node_modules/dayjs/dayjs.min.js +4 -6
  921. package/dist/node_modules/dayjs/plugin/advancedFormat.js +4 -6
  922. package/dist/node_modules/dayjs/plugin/customParseFormat.js +4 -6
  923. package/dist/node_modules/dayjs/plugin/duration.js +4 -6
  924. package/dist/node_modules/dayjs/plugin/isoWeek.js +4 -6
  925. package/dist/node_modules/decode-named-character-reference/index.dom.js +5 -7
  926. package/dist/node_modules/devlop/lib/default.js +2 -4
  927. package/dist/node_modules/dompurify/dist/purify.es.js +180 -182
  928. package/dist/node_modules/entities/dist/esm/decode-codepoint.js +4 -6
  929. package/dist/node_modules/entities/dist/esm/decode.js +85 -87
  930. package/dist/node_modules/entities/dist/esm/generated/decode-data-html.js +2 -4
  931. package/dist/node_modules/estree-util-is-identifier-name/lib/index.js +4 -6
  932. package/dist/node_modules/extend/index.js +6 -9
  933. package/dist/node_modules/hast-util-from-dom/lib/index.js +30 -32
  934. package/dist/node_modules/hast-util-from-html-isomorphic/lib/browser.js +8 -10
  935. package/dist/node_modules/hast-util-from-parse5/lib/index.js +80 -82
  936. package/dist/node_modules/hast-util-is-element/lib/index.js +15 -17
  937. package/dist/node_modules/hast-util-parse-selector/lib/index.js +5 -7
  938. package/dist/node_modules/hast-util-raw/lib/index.js +134 -136
  939. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.js +21 -23
  940. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.js +3 -5
  941. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/foreign-content.js +89 -89
  942. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/html.js +249 -250
  943. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.js +4 -6
  944. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/unicode.js +14 -14
  945. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/index.js +4 -4
  946. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/formatting-element-list.js +15 -17
  947. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.js +1495 -1497
  948. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.js +146 -148
  949. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.js +19 -20
  950. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.js +798 -800
  951. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.js +31 -33
  952. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.js +8 -10
  953. package/dist/node_modules/hast-util-sanitize/lib/index.js +104 -106
  954. package/dist/node_modules/hast-util-sanitize/lib/schema.js +11 -12
  955. package/dist/node_modules/hast-util-to-html/lib/handle/comment.js +7 -9
  956. package/dist/node_modules/hast-util-to-html/lib/handle/doctype.js +2 -4
  957. package/dist/node_modules/hast-util-to-html/lib/handle/element.js +23 -25
  958. package/dist/node_modules/hast-util-to-html/lib/handle/index.js +21 -22
  959. package/dist/node_modules/hast-util-to-html/lib/handle/raw.js +4 -6
  960. package/dist/node_modules/hast-util-to-html/lib/handle/root.js +2 -4
  961. package/dist/node_modules/hast-util-to-html/lib/handle/text.js +5 -7
  962. package/dist/node_modules/hast-util-to-html/lib/index.js +36 -38
  963. package/dist/node_modules/hast-util-to-html/lib/omission/closing.js +68 -70
  964. package/dist/node_modules/hast-util-to-html/lib/omission/omission.js +4 -6
  965. package/dist/node_modules/hast-util-to-html/lib/omission/opening.js +30 -32
  966. package/dist/node_modules/hast-util-to-html/lib/omission/util/siblings.js +9 -10
  967. package/dist/node_modules/hast-util-to-jsx-runtime/lib/index.js +190 -192
  968. package/dist/node_modules/hast-util-to-parse5/lib/index.js +69 -71
  969. package/dist/node_modules/hast-util-to-text/lib/index.js +59 -61
  970. package/dist/node_modules/hast-util-whitespace/lib/index.js +6 -8
  971. package/dist/node_modules/hastscript/lib/create-h.js +24 -26
  972. package/dist/node_modules/hastscript/lib/index.js +5 -7
  973. package/dist/node_modules/hastscript/lib/svg-case-sensitive-tag-names.js +2 -4
  974. package/dist/node_modules/html-url-attributes/lib/index.js +2 -4
  975. package/dist/node_modules/html-void-elements/index.js +2 -4
  976. package/dist/node_modules/inline-style-parser/cjs/index.js +4 -6
  977. package/dist/node_modules/internmap/src/index.js +20 -22
  978. package/dist/node_modules/katex/dist/katex.js +2307 -2301
  979. package/dist/node_modules/khroma/dist/channels/index.js +21 -23
  980. package/dist/node_modules/khroma/dist/channels/reusable.js +3 -5
  981. package/dist/node_modules/khroma/dist/channels/type.js +5 -7
  982. package/dist/node_modules/khroma/dist/color/hex.js +8 -10
  983. package/dist/node_modules/khroma/dist/color/hsl.js +17 -19
  984. package/dist/node_modules/khroma/dist/color/index.js +15 -17
  985. package/dist/node_modules/khroma/dist/color/keyword.js +8 -10
  986. package/dist/node_modules/khroma/dist/color/rgb.js +12 -14
  987. package/dist/node_modules/khroma/dist/constants.js +5 -7
  988. package/dist/node_modules/khroma/dist/methods/adjust.js +6 -8
  989. package/dist/node_modules/khroma/dist/methods/adjust_channel.js +6 -8
  990. package/dist/node_modules/khroma/dist/methods/change.js +7 -9
  991. package/dist/node_modules/khroma/dist/methods/channel.js +4 -6
  992. package/dist/node_modules/khroma/dist/methods/darken.js +3 -5
  993. package/dist/node_modules/khroma/dist/methods/invert.js +6 -8
  994. package/dist/node_modules/khroma/dist/methods/is_dark.js +3 -5
  995. package/dist/node_modules/khroma/dist/methods/is_light.js +3 -5
  996. package/dist/node_modules/khroma/dist/methods/lighten.js +3 -5
  997. package/dist/node_modules/khroma/dist/methods/luminance.js +6 -8
  998. package/dist/node_modules/khroma/dist/methods/mix.js +6 -8
  999. package/dist/node_modules/khroma/dist/methods/rgba.js +13 -15
  1000. package/dist/node_modules/khroma/dist/methods/transparentize.js +3 -5
  1001. package/dist/node_modules/khroma/dist/utils/channel.js +6 -8
  1002. package/dist/node_modules/khroma/dist/utils/index.js +8 -10
  1003. package/dist/node_modules/khroma/dist/utils/lang.js +2 -4
  1004. package/dist/node_modules/khroma/dist/utils/unit.js +2 -4
  1005. package/dist/node_modules/langium/lib/default-module.js +64 -66
  1006. package/dist/node_modules/langium/lib/dependency-injection.js +39 -37
  1007. package/dist/node_modules/langium/lib/documentation/comment-provider.js +5 -7
  1008. package/dist/node_modules/langium/lib/documentation/documentation-provider.js +6 -8
  1009. package/dist/node_modules/langium/lib/documentation/jsdoc.js +202 -204
  1010. package/dist/node_modules/langium/lib/index.js +182 -0
  1011. package/dist/node_modules/langium/lib/languages/generated/ast.js +534 -343
  1012. package/dist/node_modules/langium/lib/languages/grammar-config.js +8 -10
  1013. package/dist/node_modules/langium/lib/parser/async-parser.js +76 -4
  1014. package/dist/node_modules/langium/lib/parser/completion-parser-builder.js +6 -8
  1015. package/dist/node_modules/langium/lib/parser/cst-node-builder.js +54 -56
  1016. package/dist/node_modules/langium/lib/parser/indentation-aware.js +141 -0
  1017. package/dist/node_modules/langium/lib/parser/langium-parser-builder.js +7 -9
  1018. package/dist/node_modules/langium/lib/parser/langium-parser.js +188 -190
  1019. package/dist/node_modules/langium/lib/parser/lexer.js +25 -25
  1020. package/dist/node_modules/langium/lib/parser/parser-builder-base.js +203 -204
  1021. package/dist/node_modules/langium/lib/parser/token-builder.js +30 -32
  1022. package/dist/node_modules/langium/lib/parser/value-converter.js +15 -17
  1023. package/dist/node_modules/langium/lib/references/linker.js +103 -104
  1024. package/dist/node_modules/langium/lib/references/name-provider.js +7 -9
  1025. package/dist/node_modules/langium/lib/references/references.js +51 -53
  1026. package/dist/node_modules/langium/lib/references/scope-computation.js +12 -14
  1027. package/dist/node_modules/langium/lib/references/scope-provider.js +11 -13
  1028. package/dist/node_modules/langium/lib/references/scope.js +56 -27
  1029. package/dist/node_modules/langium/lib/serializer/hydrator.js +69 -71
  1030. package/dist/node_modules/langium/lib/serializer/json-serializer.js +21 -23
  1031. package/dist/node_modules/langium/lib/service-registry.js +5 -7
  1032. package/dist/node_modules/langium/lib/syntax-tree.js +31 -33
  1033. package/dist/node_modules/langium/lib/utils/ast-utils.js +112 -77
  1034. package/dist/node_modules/langium/lib/utils/caching.js +42 -33
  1035. package/dist/node_modules/langium/lib/utils/cancellation.js +5 -7
  1036. package/dist/node_modules/langium/lib/utils/collections.js +33 -35
  1037. package/dist/node_modules/langium/lib/utils/cst-utils.js +161 -46
  1038. package/dist/node_modules/langium/lib/utils/disposable.js +3 -5
  1039. package/dist/node_modules/langium/lib/utils/errors.js +9 -8
  1040. package/dist/node_modules/langium/lib/utils/event.js +5 -7
  1041. package/dist/node_modules/langium/lib/utils/grammar-loader.js +14 -16
  1042. package/dist/node_modules/langium/lib/utils/grammar-utils.js +249 -172
  1043. package/dist/node_modules/langium/lib/utils/index.js +53 -0
  1044. package/dist/node_modules/langium/lib/utils/promise-utils.js +19 -18
  1045. package/dist/node_modules/langium/lib/utils/regexp-utils.js +76 -53
  1046. package/dist/node_modules/langium/lib/utils/stream.js +153 -155
  1047. package/dist/node_modules/langium/lib/utils/uri-utils.js +12 -14
  1048. package/dist/node_modules/langium/lib/validation/document-validator.js +103 -104
  1049. package/dist/node_modules/langium/lib/validation/validation-registry.js +14 -15
  1050. package/dist/node_modules/langium/lib/workspace/ast-descriptions.js +17 -19
  1051. package/dist/node_modules/langium/lib/workspace/ast-node-locator.js +2 -4
  1052. package/dist/node_modules/langium/lib/workspace/configuration.js +5 -7
  1053. package/dist/node_modules/langium/lib/workspace/document-builder.js +134 -131
  1054. package/dist/node_modules/langium/lib/workspace/documents.js +83 -85
  1055. package/dist/node_modules/langium/lib/workspace/file-system-provider.js +4 -5
  1056. package/dist/node_modules/langium/lib/workspace/index-manager.js +14 -16
  1057. package/dist/node_modules/langium/lib/workspace/profiler.js +89 -0
  1058. package/dist/node_modules/langium/lib/workspace/workspace-lock.js +9 -11
  1059. package/dist/node_modules/langium/lib/workspace/workspace-manager.js +33 -35
  1060. package/dist/node_modules/layout-base/layout-base.js +4 -6
  1061. package/dist/node_modules/lodash/_Symbol.js +7 -0
  1062. package/dist/node_modules/lodash/_baseGetTag.js +13 -0
  1063. package/dist/node_modules/lodash/_baseTrim.js +11 -0
  1064. package/dist/node_modules/lodash/_freeGlobal.js +6 -0
  1065. package/dist/node_modules/lodash/_getRawTag.js +17 -0
  1066. package/dist/node_modules/lodash/_objectToString.js +10 -0
  1067. package/dist/node_modules/lodash/_root.js +8 -0
  1068. package/dist/node_modules/lodash/_trimmedEndIndex.js +11 -0
  1069. package/dist/{frontend/studio/node_modules → node_modules}/lodash/debounce.js +8 -10
  1070. package/dist/node_modules/lodash/isObject.js +10 -0
  1071. package/dist/node_modules/lodash/isObjectLike.js +9 -0
  1072. package/dist/node_modules/lodash/isSymbol.js +12 -0
  1073. package/dist/node_modules/lodash/now.js +10 -0
  1074. package/dist/node_modules/lodash/toNumber.js +22 -0
  1075. package/dist/node_modules/lodash-es/_DataView.js +4 -6
  1076. package/dist/node_modules/lodash-es/_Hash.js +13 -14
  1077. package/dist/node_modules/lodash-es/_ListCache.js +13 -14
  1078. package/dist/node_modules/lodash-es/_Map.js +4 -6
  1079. package/dist/node_modules/lodash-es/_MapCache.js +13 -14
  1080. package/dist/node_modules/lodash-es/_Promise.js +4 -6
  1081. package/dist/node_modules/lodash-es/_Set.js +4 -6
  1082. package/dist/node_modules/lodash-es/_SetCache.js +9 -10
  1083. package/dist/node_modules/lodash-es/_Stack.js +11 -12
  1084. package/dist/node_modules/lodash-es/_Symbol.js +3 -5
  1085. package/dist/node_modules/lodash-es/_Uint8Array.js +3 -5
  1086. package/dist/node_modules/lodash-es/_WeakMap.js +4 -6
  1087. package/dist/node_modules/lodash-es/_apply.js +3 -4
  1088. package/dist/node_modules/lodash-es/_arrayEach.js +3 -4
  1089. package/dist/node_modules/lodash-es/_arrayFilter.js +3 -4
  1090. package/dist/node_modules/lodash-es/_arrayIncludes.js +5 -6
  1091. package/dist/node_modules/lodash-es/_arrayIncludesWith.js +3 -4
  1092. package/dist/node_modules/lodash-es/_arrayLikeKeys.js +12 -13
  1093. package/dist/node_modules/lodash-es/_arrayMap.js +3 -4
  1094. package/dist/node_modules/lodash-es/_arrayPush.js +3 -4
  1095. package/dist/node_modules/lodash-es/_arrayReduce.js +3 -4
  1096. package/dist/node_modules/lodash-es/_arraySome.js +3 -4
  1097. package/dist/node_modules/lodash-es/_asciiSize.js +3 -5
  1098. package/dist/node_modules/lodash-es/_assignMergeValue.js +6 -7
  1099. package/dist/node_modules/lodash-es/_assignValue.js +7 -8
  1100. package/dist/node_modules/lodash-es/_assocIndexOf.js +5 -6
  1101. package/dist/node_modules/lodash-es/_baseAssign.js +6 -7
  1102. package/dist/node_modules/lodash-es/_baseAssignIn.js +6 -7
  1103. package/dist/node_modules/lodash-es/_baseAssignValue.js +5 -6
  1104. package/dist/node_modules/lodash-es/_baseClone.js +50 -51
  1105. package/dist/node_modules/lodash-es/_baseCreate.js +5 -7
  1106. package/dist/node_modules/lodash-es/_baseEach.js +4 -6
  1107. package/dist/node_modules/lodash-es/_baseExtremum.js +5 -6
  1108. package/dist/node_modules/lodash-es/_baseFilter.js +5 -6
  1109. package/dist/node_modules/lodash-es/_baseFindIndex.js +3 -4
  1110. package/dist/node_modules/lodash-es/_baseFlatten.js +7 -8
  1111. package/dist/node_modules/lodash-es/_baseFor.js +3 -5
  1112. package/dist/node_modules/lodash-es/_baseForOwn.js +6 -7
  1113. package/dist/node_modules/lodash-es/_baseGet.js +7 -8
  1114. package/dist/node_modules/lodash-es/_baseGetAllKeys.js +6 -7
  1115. package/dist/node_modules/lodash-es/_baseGetTag.js +8 -9
  1116. package/dist/node_modules/lodash-es/_baseGt.js +3 -4
  1117. package/dist/node_modules/lodash-es/_baseHas.js +5 -6
  1118. package/dist/node_modules/lodash-es/_baseHasIn.js +3 -4
  1119. package/dist/node_modules/lodash-es/_baseIndexOf.js +7 -8
  1120. package/dist/node_modules/lodash-es/_baseIsArguments.js +7 -8
  1121. package/dist/node_modules/lodash-es/_baseIsEqual.js +6 -7
  1122. package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +22 -23
  1123. package/dist/node_modules/lodash-es/_baseIsMap.js +7 -8
  1124. package/dist/node_modules/lodash-es/_baseIsMatch.js +8 -9
  1125. package/dist/node_modules/lodash-es/_baseIsNaN.js +3 -4
  1126. package/dist/node_modules/lodash-es/_baseIsNative.js +9 -10
  1127. package/dist/node_modules/lodash-es/_baseIsSet.js +7 -8
  1128. package/dist/node_modules/lodash-es/_baseIsTypedArray.js +9 -10
  1129. package/dist/node_modules/lodash-es/_baseIteratee.js +9 -10
  1130. package/dist/node_modules/lodash-es/_baseKeys.js +8 -9
  1131. package/dist/node_modules/lodash-es/_baseKeysIn.js +10 -11
  1132. package/dist/node_modules/lodash-es/_baseLt.js +3 -4
  1133. package/dist/node_modules/lodash-es/_baseMap.js +7 -8
  1134. package/dist/node_modules/lodash-es/_baseMatches.js +9 -10
  1135. package/dist/node_modules/lodash-es/_baseMatchesProperty.js +14 -15
  1136. package/dist/node_modules/lodash-es/_baseMerge.js +15 -16
  1137. package/dist/node_modules/lodash-es/_baseMergeDeep.js +23 -24
  1138. package/dist/node_modules/lodash-es/_baseOrderBy.js +22 -23
  1139. package/dist/node_modules/lodash-es/_basePick.js +7 -8
  1140. package/dist/node_modules/lodash-es/_basePickBy.js +8 -9
  1141. package/dist/node_modules/lodash-es/_baseProperty.js +3 -4
  1142. package/dist/node_modules/lodash-es/_basePropertyDeep.js +5 -6
  1143. package/dist/node_modules/lodash-es/_baseRange.js +5 -6
  1144. package/dist/node_modules/lodash-es/_baseReduce.js +3 -4
  1145. package/dist/node_modules/lodash-es/_baseRest.js +7 -8
  1146. package/dist/node_modules/lodash-es/_baseSet.js +13 -14
  1147. package/dist/node_modules/lodash-es/_baseSetToString.js +8 -10
  1148. package/dist/node_modules/lodash-es/_baseSortBy.js +3 -4
  1149. package/dist/node_modules/lodash-es/_baseTimes.js +3 -4
  1150. package/dist/node_modules/lodash-es/_baseToString.js +12 -13
  1151. package/dist/node_modules/lodash-es/_baseTrim.js +6 -7
  1152. package/dist/node_modules/lodash-es/_baseUnary.js +3 -4
  1153. package/dist/node_modules/lodash-es/_baseUniq.js +16 -17
  1154. package/dist/node_modules/lodash-es/_baseValues.js +5 -6
  1155. package/dist/node_modules/lodash-es/_baseZipObject.js +3 -4
  1156. package/dist/node_modules/lodash-es/_cacheHas.js +3 -4
  1157. package/dist/node_modules/lodash-es/_castFunction.js +5 -6
  1158. package/dist/node_modules/lodash-es/_castPath.js +8 -9
  1159. package/dist/node_modules/lodash-es/_cloneArrayBuffer.js +5 -6
  1160. package/dist/node_modules/lodash-es/_cloneBuffer.js +8 -9
  1161. package/dist/node_modules/lodash-es/_cloneDataView.js +5 -6
  1162. package/dist/node_modules/lodash-es/_cloneRegExp.js +5 -6
  1163. package/dist/node_modules/lodash-es/_cloneSymbol.js +6 -7
  1164. package/dist/node_modules/lodash-es/_cloneTypedArray.js +5 -6
  1165. package/dist/node_modules/lodash-es/_compareAscending.js +5 -6
  1166. package/dist/node_modules/lodash-es/_compareMultiple.js +5 -6
  1167. package/dist/node_modules/lodash-es/_copyArray.js +3 -4
  1168. package/dist/node_modules/lodash-es/_copyObject.js +6 -7
  1169. package/dist/node_modules/lodash-es/_copySymbols.js +6 -7
  1170. package/dist/node_modules/lodash-es/_copySymbolsIn.js +6 -7
  1171. package/dist/node_modules/lodash-es/_coreJsData.js +3 -5
  1172. package/dist/node_modules/lodash-es/_createAssigner.js +7 -8
  1173. package/dist/node_modules/lodash-es/_createBaseEach.js +5 -6
  1174. package/dist/node_modules/lodash-es/_createBaseFor.js +3 -4
  1175. package/dist/node_modules/lodash-es/_createFind.js +9 -10
  1176. package/dist/node_modules/lodash-es/_createRange.js +7 -8
  1177. package/dist/node_modules/lodash-es/_createSet.js +7 -9
  1178. package/dist/node_modules/lodash-es/_defineProperty.js +4 -6
  1179. package/dist/node_modules/lodash-es/_equalArrays.js +11 -12
  1180. package/dist/node_modules/lodash-es/_equalByTag.js +28 -29
  1181. package/dist/node_modules/lodash-es/_equalObjects.js +8 -9
  1182. package/dist/node_modules/lodash-es/_flatRest.js +7 -8
  1183. package/dist/node_modules/lodash-es/_freeGlobal.js +2 -4
  1184. package/dist/node_modules/lodash-es/_getAllKeys.js +7 -8
  1185. package/dist/node_modules/lodash-es/_getAllKeysIn.js +7 -8
  1186. package/dist/node_modules/lodash-es/_getMapData.js +5 -6
  1187. package/dist/node_modules/lodash-es/_getMatchData.js +7 -8
  1188. package/dist/node_modules/lodash-es/_getNative.js +7 -8
  1189. package/dist/node_modules/lodash-es/_getPrototype.js +3 -5
  1190. package/dist/node_modules/lodash-es/_getRawTag.js +9 -10
  1191. package/dist/node_modules/lodash-es/_getSymbols.js +7 -9
  1192. package/dist/node_modules/lodash-es/_getSymbolsIn.js +8 -10
  1193. package/dist/node_modules/lodash-es/_getTag.js +19 -21
  1194. package/dist/node_modules/lodash-es/_getValue.js +3 -4
  1195. package/dist/node_modules/lodash-es/_hasPath.js +12 -13
  1196. package/dist/node_modules/lodash-es/_hasUnicode.js +5 -6
  1197. package/dist/node_modules/lodash-es/_hashClear.js +5 -6
  1198. package/dist/node_modules/lodash-es/_hashDelete.js +4 -5
  1199. package/dist/node_modules/lodash-es/_hashGet.js +8 -9
  1200. package/dist/node_modules/lodash-es/_hashHas.js +6 -7
  1201. package/dist/node_modules/lodash-es/_hashSet.js +6 -7
  1202. package/dist/node_modules/lodash-es/_initCloneArray.js +5 -6
  1203. package/dist/node_modules/lodash-es/_initCloneByTag.js +28 -29
  1204. package/dist/node_modules/lodash-es/_initCloneObject.js +7 -8
  1205. package/dist/node_modules/lodash-es/_isFlattenable.js +8 -9
  1206. package/dist/node_modules/lodash-es/_isIndex.js +5 -6
  1207. package/dist/node_modules/lodash-es/_isIterateeCall.js +9 -10
  1208. package/dist/node_modules/lodash-es/_isKey.js +8 -9
  1209. package/dist/node_modules/lodash-es/_isKeyable.js +3 -4
  1210. package/dist/node_modules/lodash-es/_isMasked.js +8 -9
  1211. package/dist/node_modules/lodash-es/_isPrototype.js +5 -6
  1212. package/dist/node_modules/lodash-es/_isStrictComparable.js +5 -6
  1213. package/dist/node_modules/lodash-es/_listCacheClear.js +3 -4
  1214. package/dist/node_modules/lodash-es/_listCacheDelete.js +7 -8
  1215. package/dist/node_modules/lodash-es/_listCacheGet.js +5 -6
  1216. package/dist/node_modules/lodash-es/_listCacheHas.js +5 -6
  1217. package/dist/node_modules/lodash-es/_listCacheSet.js +5 -6
  1218. package/dist/node_modules/lodash-es/_mapCacheClear.js +9 -10
  1219. package/dist/node_modules/lodash-es/_mapCacheDelete.js +6 -7
  1220. package/dist/node_modules/lodash-es/_mapCacheGet.js +5 -6
  1221. package/dist/node_modules/lodash-es/_mapCacheHas.js +5 -6
  1222. package/dist/node_modules/lodash-es/_mapCacheSet.js +5 -6
  1223. package/dist/node_modules/lodash-es/_mapToArray.js +3 -4
  1224. package/dist/node_modules/lodash-es/_matchesStrictComparable.js +3 -4
  1225. package/dist/node_modules/lodash-es/_memoizeCapped.js +7 -8
  1226. package/dist/node_modules/lodash-es/_nativeCreate.js +3 -5
  1227. package/dist/node_modules/lodash-es/_nativeKeys.js +3 -5
  1228. package/dist/node_modules/lodash-es/_nativeKeysIn.js +3 -4
  1229. package/dist/node_modules/lodash-es/_nodeUtil.js +4 -6
  1230. package/dist/node_modules/lodash-es/_objectToString.js +5 -6
  1231. package/dist/node_modules/lodash-es/_overArg.js +3 -4
  1232. package/dist/node_modules/lodash-es/_overRest.js +8 -9
  1233. package/dist/node_modules/lodash-es/_root.js +3 -5
  1234. package/dist/node_modules/lodash-es/_safeGet.js +3 -4
  1235. package/dist/node_modules/lodash-es/_setCacheAdd.js +5 -6
  1236. package/dist/node_modules/lodash-es/_setCacheHas.js +3 -4
  1237. package/dist/node_modules/lodash-es/_setToArray.js +3 -4
  1238. package/dist/node_modules/lodash-es/_setToString.js +4 -6
  1239. package/dist/node_modules/lodash-es/_shortOut.js +6 -7
  1240. package/dist/node_modules/lodash-es/_stackClear.js +5 -6
  1241. package/dist/node_modules/lodash-es/_stackDelete.js +3 -4
  1242. package/dist/node_modules/lodash-es/_stackGet.js +3 -4
  1243. package/dist/node_modules/lodash-es/_stackHas.js +3 -4
  1244. package/dist/node_modules/lodash-es/_stackSet.js +10 -11
  1245. package/dist/node_modules/lodash-es/_strictIndexOf.js +3 -4
  1246. package/dist/node_modules/lodash-es/_stringSize.js +7 -8
  1247. package/dist/node_modules/lodash-es/_stringToPath.js +5 -7
  1248. package/dist/node_modules/lodash-es/_toKey.js +7 -8
  1249. package/dist/node_modules/lodash-es/_toSource.js +7 -8
  1250. package/dist/node_modules/lodash-es/_trimmedEndIndex.js +5 -6
  1251. package/dist/node_modules/lodash-es/_unicodeSize.js +16 -17
  1252. package/dist/node_modules/lodash-es/clone.js +6 -7
  1253. package/dist/node_modules/lodash-es/cloneDeep.js +6 -7
  1254. package/dist/node_modules/lodash-es/constant.js +3 -4
  1255. package/dist/node_modules/lodash-es/defaults.js +11 -13
  1256. package/dist/node_modules/lodash-es/eq.js +3 -4
  1257. package/dist/node_modules/lodash-es/filter.js +8 -9
  1258. package/dist/node_modules/lodash-es/find.js +4 -6
  1259. package/dist/node_modules/lodash-es/findIndex.js +9 -10
  1260. package/dist/node_modules/lodash-es/flatMap.js +6 -7
  1261. package/dist/node_modules/lodash-es/flatten.js +5 -6
  1262. package/dist/node_modules/lodash-es/forEach.js +8 -9
  1263. package/dist/node_modules/lodash-es/forIn.js +7 -8
  1264. package/dist/node_modules/lodash-es/forOwn.js +6 -7
  1265. package/dist/node_modules/lodash-es/get.js +5 -6
  1266. package/dist/node_modules/lodash-es/has.js +6 -7
  1267. package/dist/node_modules/lodash-es/hasIn.js +6 -7
  1268. package/dist/node_modules/lodash-es/identity.js +3 -4
  1269. package/dist/node_modules/lodash-es/isArguments.js +6 -8
  1270. package/dist/node_modules/lodash-es/isArray.js +2 -4
  1271. package/dist/node_modules/lodash-es/isArrayLike.js +6 -7
  1272. package/dist/node_modules/lodash-es/isArrayLikeObject.js +6 -7
  1273. package/dist/node_modules/lodash-es/isBuffer.js +4 -6
  1274. package/dist/node_modules/lodash-es/isEmpty.js +17 -18
  1275. package/dist/node_modules/lodash-es/isFunction.js +9 -10
  1276. package/dist/node_modules/lodash-es/isLength.js +5 -6
  1277. package/dist/node_modules/lodash-es/isMap.js +5 -7
  1278. package/dist/node_modules/lodash-es/isObject.js +3 -4
  1279. package/dist/node_modules/lodash-es/isObjectLike.js +3 -4
  1280. package/dist/node_modules/lodash-es/isPlainObject.js +12 -13
  1281. package/dist/node_modules/lodash-es/isSet.js +5 -7
  1282. package/dist/node_modules/lodash-es/isString.js +8 -9
  1283. package/dist/node_modules/lodash-es/isSymbol.js +7 -8
  1284. package/dist/node_modules/lodash-es/isTypedArray.js +5 -7
  1285. package/dist/node_modules/lodash-es/isUndefined.js +3 -4
  1286. package/dist/node_modules/lodash-es/keys.js +7 -8
  1287. package/dist/node_modules/lodash-es/keysIn.js +7 -8
  1288. package/dist/node_modules/lodash-es/last.js +3 -4
  1289. package/dist/node_modules/lodash-es/map.js +8 -9
  1290. package/dist/node_modules/lodash-es/mapValues.js +8 -9
  1291. package/dist/node_modules/lodash-es/max.js +7 -8
  1292. package/dist/node_modules/lodash-es/memoize.js +8 -9
  1293. package/dist/node_modules/lodash-es/merge.js +5 -7
  1294. package/dist/node_modules/lodash-es/min.js +7 -8
  1295. package/dist/node_modules/lodash-es/minBy.js +7 -8
  1296. package/dist/node_modules/lodash-es/noop.js +3 -4
  1297. package/dist/node_modules/lodash-es/now.js +4 -6
  1298. package/dist/node_modules/lodash-es/pick.js +5 -7
  1299. package/dist/node_modules/lodash-es/property.js +8 -9
  1300. package/dist/node_modules/lodash-es/range.js +3 -5
  1301. package/dist/node_modules/lodash-es/reduce.js +10 -11
  1302. package/dist/node_modules/lodash-es/size.js +12 -13
  1303. package/dist/node_modules/lodash-es/sortBy.js +7 -9
  1304. package/dist/node_modules/lodash-es/stubArray.js +3 -4
  1305. package/dist/node_modules/lodash-es/stubFalse.js +3 -4
  1306. package/dist/node_modules/lodash-es/toFinite.js +6 -7
  1307. package/dist/node_modules/lodash-es/toInteger.js +5 -6
  1308. package/dist/node_modules/lodash-es/toNumber.js +13 -14
  1309. package/dist/node_modules/lodash-es/toPlainObject.js +6 -7
  1310. package/dist/node_modules/lodash-es/toString.js +5 -6
  1311. package/dist/node_modules/lodash-es/union.js +7 -9
  1312. package/dist/node_modules/lodash-es/uniqBy.js +6 -7
  1313. package/dist/node_modules/lodash-es/uniqueId.js +7 -8
  1314. package/dist/node_modules/lodash-es/values.js +6 -7
  1315. package/dist/node_modules/lodash-es/zipObject.js +6 -7
  1316. package/dist/node_modules/longest-streak/index.js +2 -4
  1317. package/dist/node_modules/markdown-table/index.js +9 -11
  1318. package/dist/node_modules/marked/lib/marked.esm.js +685 -687
  1319. package/dist/node_modules/mdast-util-find-and-replace/lib/index.js +12 -14
  1320. package/dist/node_modules/mdast-util-find-and-replace/node_modules/escape-string-regexp/index.js +2 -4
  1321. package/dist/node_modules/mdast-util-from-markdown/lib/index.js +180 -182
  1322. package/dist/node_modules/mdast-util-gfm/lib/index.js +18 -20
  1323. package/dist/node_modules/mdast-util-gfm-autolink-literal/lib/index.js +67 -69
  1324. package/dist/node_modules/mdast-util-gfm-footnote/lib/index.js +45 -47
  1325. package/dist/node_modules/mdast-util-gfm-strikethrough/lib/index.js +13 -15
  1326. package/dist/node_modules/mdast-util-gfm-table/lib/index.js +28 -30
  1327. package/dist/node_modules/mdast-util-gfm-task-list-item/lib/index.js +14 -16
  1328. package/dist/node_modules/mdast-util-math/lib/index.js +13 -15
  1329. package/dist/node_modules/mdast-util-phrasing/lib/index.js +3 -5
  1330. package/dist/node_modules/mdast-util-to-hast/lib/footer.js +9 -11
  1331. package/dist/node_modules/mdast-util-to-hast/lib/handlers/blockquote.js +2 -4
  1332. package/dist/node_modules/mdast-util-to-hast/lib/handlers/break.js +2 -4
  1333. package/dist/node_modules/mdast-util-to-hast/lib/handlers/code.js +2 -4
  1334. package/dist/node_modules/mdast-util-to-hast/lib/handlers/delete.js +2 -4
  1335. package/dist/node_modules/mdast-util-to-hast/lib/handlers/emphasis.js +2 -4
  1336. package/dist/node_modules/mdast-util-to-hast/lib/handlers/footnote-reference.js +4 -6
  1337. package/dist/node_modules/mdast-util-to-hast/lib/handlers/heading.js +2 -4
  1338. package/dist/node_modules/mdast-util-to-hast/lib/handlers/html.js +2 -4
  1339. package/dist/node_modules/mdast-util-to-hast/lib/handlers/image-reference.js +6 -8
  1340. package/dist/node_modules/mdast-util-to-hast/lib/handlers/image.js +4 -6
  1341. package/dist/node_modules/mdast-util-to-hast/lib/handlers/index.js +53 -55
  1342. package/dist/node_modules/mdast-util-to-hast/lib/handlers/inline-code.js +2 -4
  1343. package/dist/node_modules/mdast-util-to-hast/lib/handlers/link-reference.js +6 -8
  1344. package/dist/node_modules/mdast-util-to-hast/lib/handlers/link.js +4 -6
  1345. package/dist/node_modules/mdast-util-to-hast/lib/handlers/list-item.js +13 -15
  1346. package/dist/node_modules/mdast-util-to-hast/lib/handlers/list.js +2 -4
  1347. package/dist/node_modules/mdast-util-to-hast/lib/handlers/paragraph.js +2 -4
  1348. package/dist/node_modules/mdast-util-to-hast/lib/handlers/root.js +2 -4
  1349. package/dist/node_modules/mdast-util-to-hast/lib/handlers/strong.js +2 -4
  1350. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table-cell.js +2 -4
  1351. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table-row.js +2 -4
  1352. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table.js +4 -6
  1353. package/dist/node_modules/mdast-util-to-hast/lib/handlers/text.js +4 -6
  1354. package/dist/node_modules/mdast-util-to-hast/lib/handlers/thematic-break.js +2 -4
  1355. package/dist/node_modules/mdast-util-to-hast/lib/index.js +6 -8
  1356. package/dist/node_modules/mdast-util-to-hast/lib/revert.js +2 -4
  1357. package/dist/node_modules/mdast-util-to-hast/lib/state.js +59 -61
  1358. package/dist/node_modules/mdast-util-to-markdown/lib/handle/blockquote.js +4 -6
  1359. package/dist/node_modules/mdast-util-to-markdown/lib/handle/break.js +4 -6
  1360. package/dist/node_modules/mdast-util-to-markdown/lib/handle/code.js +16 -18
  1361. package/dist/node_modules/mdast-util-to-markdown/lib/handle/definition.js +4 -6
  1362. package/dist/node_modules/mdast-util-to-markdown/lib/handle/emphasis.js +12 -14
  1363. package/dist/node_modules/mdast-util-to-markdown/lib/handle/heading.js +6 -8
  1364. package/dist/node_modules/mdast-util-to-markdown/lib/handle/html.js +4 -6
  1365. package/dist/node_modules/mdast-util-to-markdown/lib/handle/image-reference.js +4 -6
  1366. package/dist/node_modules/mdast-util-to-markdown/lib/handle/image.js +6 -8
  1367. package/dist/node_modules/mdast-util-to-markdown/lib/handle/index.js +41 -43
  1368. package/dist/node_modules/mdast-util-to-markdown/lib/handle/inline-code.js +5 -7
  1369. package/dist/node_modules/mdast-util-to-markdown/lib/handle/link-reference.js +4 -6
  1370. package/dist/node_modules/mdast-util-to-markdown/lib/handle/link.js +9 -11
  1371. package/dist/node_modules/mdast-util-to-markdown/lib/handle/list-item.js +5 -7
  1372. package/dist/node_modules/mdast-util-to-markdown/lib/handle/list.js +10 -12
  1373. package/dist/node_modules/mdast-util-to-markdown/lib/handle/paragraph.js +2 -4
  1374. package/dist/node_modules/mdast-util-to-markdown/lib/handle/root.js +4 -6
  1375. package/dist/node_modules/mdast-util-to-markdown/lib/handle/strong.js +12 -14
  1376. package/dist/node_modules/mdast-util-to-markdown/lib/handle/text.js +2 -4
  1377. package/dist/node_modules/mdast-util-to-markdown/lib/handle/thematic-break.js +5 -7
  1378. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet-ordered.js +2 -4
  1379. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet-other.js +4 -6
  1380. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet.js +2 -4
  1381. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-emphasis.js +2 -4
  1382. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-fence.js +2 -4
  1383. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-list-item-indent.js +2 -4
  1384. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-quote.js +2 -4
  1385. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-rule-repetition.js +2 -4
  1386. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-rule.js +2 -4
  1387. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-strong.js +2 -4
  1388. package/dist/node_modules/mdast-util-to-markdown/lib/util/encode-character-reference.js +2 -4
  1389. package/dist/node_modules/mdast-util-to-markdown/lib/util/encode-info.js +4 -6
  1390. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-code-as-indented.js +2 -4
  1391. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-heading-as-setext.js +7 -8
  1392. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-link-as-autolink.js +4 -6
  1393. package/dist/node_modules/mdast-util-to-markdown/lib/util/pattern-in-scope.js +4 -6
  1394. package/dist/node_modules/mdast-util-to-string/lib/index.js +12 -14
  1395. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/architectureDiagram-Q4EWVU46.js +374 -378
  1396. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/blockDiagram-DXYQGD6D.js +1347 -1349
  1397. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/c4Diagram-AHTNJAMY.js +549 -555
  1398. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-336JU56O.js +38 -40
  1399. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-426QAEUC.js +7 -9
  1400. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-4BX2VUAB.js +4 -6
  1401. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-4TB4RGXK.js +198 -204
  1402. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-55IACEB6.js +5 -7
  1403. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-5FUZZQ4R.js +2345 -2347
  1404. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-5PVQY5BW.js +253 -257
  1405. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-AGHRB4JF.js +20 -22
  1406. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-BSJP7CBP.js +35 -37
  1407. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-EDXVE4YY.js +15 -17
  1408. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ENJZ2VHE.js +344 -346
  1409. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-FMBD7UC4.js +3 -5
  1410. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ICPOFSXX.js +718 -746
  1411. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-OYMX7WX6.js +588 -594
  1412. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-QZHKN3VN.js +4 -8
  1413. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-U2HBQHQK.js +204 -206
  1414. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-X2U36JSP.js +37 -39
  1415. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-XPW4576I.js +891 -893
  1416. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-YZCP3GAM.js +37 -39
  1417. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ZZ45TVLE.js +13 -15
  1418. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-6PBFFD2Q.js +9 -11
  1419. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-v2-HSJHXN6E.js +9 -11
  1420. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/cose-bilkent-S5V4N54A.js +114 -116
  1421. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/dagre-KV5264BT.js +188 -190
  1422. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-5BDNPKRD.js +70 -72
  1423. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-G4DWMVQ6.js +185 -189
  1424. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-MMDJMWI5.js +154 -156
  1425. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-TYMM5635.js +72 -76
  1426. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/erDiagram-SMLLAGMA.js +75 -79
  1427. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/flowDiagram-DWJPFMVM.js +896 -900
  1428. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ganttDiagram-T4ZO3ILL.js +685 -687
  1429. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/gitGraphDiagram-UUTBAWPF.js +569 -571
  1430. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/infoDiagram-42DDH7IO.js +15 -17
  1431. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ishikawaDiagram-UXIWVN3A.js +304 -308
  1432. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/journeyDiagram-VCZTEJTY.js +377 -379
  1433. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/kanban-definition-6JOO6SKY.js +114 -116
  1434. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/mindmap-definition-QFDTVHPH.js +87 -91
  1435. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/pieDiagram-DEJITSTG.js +94 -96
  1436. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/quadrantDiagram-34T5L4WZ.js +273 -279
  1437. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/requirementDiagram-MS252O5E.js +59 -63
  1438. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sankeyDiagram-XADWPNL6.js +202 -212
  1439. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-FGHM5R23.js +564 -568
  1440. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-FHFEXIEX.js +155 -157
  1441. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-v2-QKLJ7IA2.js +9 -11
  1442. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/timeline-definition-GMOUNBTQ.js +559 -561
  1443. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/vennDiagram-DHZGUBPP.js +370 -372
  1444. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-NUSXRM2D.js +450 -454
  1445. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/xychartDiagram-5P7HB3ND.js +658 -680
  1446. package/dist/node_modules/mermaid/dist/mermaid.core.js +430 -434
  1447. package/dist/node_modules/micromark/lib/constructs.js +79 -80
  1448. package/dist/node_modules/micromark/lib/create-tokenizer.js +12 -14
  1449. package/dist/node_modules/micromark/lib/initialize/content.js +7 -9
  1450. package/dist/node_modules/micromark/lib/initialize/document.js +14 -15
  1451. package/dist/node_modules/micromark/lib/initialize/flow.js +7 -9
  1452. package/dist/node_modules/micromark/lib/initialize/text.js +6 -8
  1453. package/dist/node_modules/micromark/lib/parse.js +18 -20
  1454. package/dist/node_modules/micromark/lib/postprocess.js +4 -6
  1455. package/dist/node_modules/micromark/lib/preprocess.js +4 -6
  1456. package/dist/node_modules/micromark-core-commonmark/lib/attention.js +18 -20
  1457. package/dist/node_modules/micromark-core-commonmark/lib/autolink.js +15 -17
  1458. package/dist/node_modules/micromark-core-commonmark/lib/blank-line.js +9 -11
  1459. package/dist/node_modules/micromark-core-commonmark/lib/block-quote.js +13 -15
  1460. package/dist/node_modules/micromark-core-commonmark/lib/character-escape.js +6 -8
  1461. package/dist/node_modules/micromark-core-commonmark/lib/character-reference.js +14 -16
  1462. package/dist/node_modules/micromark-core-commonmark/lib/code-fenced.js +21 -22
  1463. package/dist/node_modules/micromark-core-commonmark/lib/code-indented.js +15 -16
  1464. package/dist/node_modules/micromark-core-commonmark/lib/code-text.js +11 -13
  1465. package/dist/node_modules/micromark-core-commonmark/lib/content.js +17 -18
  1466. package/dist/node_modules/micromark-core-commonmark/lib/definition.js +29 -30
  1467. package/dist/node_modules/micromark-core-commonmark/lib/hard-break-escape.js +6 -8
  1468. package/dist/node_modules/micromark-core-commonmark/lib/heading-atx.js +13 -15
  1469. package/dist/node_modules/micromark-core-commonmark/lib/html-flow.js +67 -68
  1470. package/dist/node_modules/micromark-core-commonmark/lib/html-text.js +64 -66
  1471. package/dist/node_modules/micromark-core-commonmark/lib/label-end.js +111 -112
  1472. package/dist/node_modules/micromark-core-commonmark/lib/label-start-image.js +6 -8
  1473. package/dist/node_modules/micromark-core-commonmark/lib/label-start-link.js +6 -8
  1474. package/dist/node_modules/micromark-core-commonmark/lib/line-ending.js +6 -8
  1475. package/dist/node_modules/micromark-core-commonmark/lib/list.js +31 -32
  1476. package/dist/node_modules/micromark-core-commonmark/lib/setext-underline.js +10 -12
  1477. package/dist/node_modules/micromark-core-commonmark/lib/thematic-break.js +9 -11
  1478. package/dist/node_modules/micromark-extension-gfm/index.js +14 -16
  1479. package/dist/node_modules/micromark-extension-gfm-autolink-literal/lib/syntax.js +120 -122
  1480. package/dist/node_modules/micromark-extension-gfm-footnote/lib/syntax.js +31 -33
  1481. package/dist/node_modules/micromark-extension-gfm-strikethrough/lib/syntax.js +9 -11
  1482. package/dist/node_modules/micromark-extension-gfm-table/lib/edit-map.js +4 -6
  1483. package/dist/node_modules/micromark-extension-gfm-table/lib/infer.js +2 -4
  1484. package/dist/node_modules/micromark-extension-gfm-table/lib/syntax.js +34 -36
  1485. package/dist/node_modules/micromark-extension-gfm-task-list-item/lib/syntax.js +18 -20
  1486. package/dist/node_modules/micromark-extension-math/lib/math-flow.js +20 -21
  1487. package/dist/node_modules/micromark-extension-math/lib/math-text.js +9 -11
  1488. package/dist/node_modules/micromark-extension-math/lib/syntax.js +6 -8
  1489. package/dist/node_modules/micromark-factory-destination/index.js +8 -10
  1490. package/dist/node_modules/micromark-factory-label/index.js +5 -7
  1491. package/dist/node_modules/micromark-factory-space/index.js +5 -7
  1492. package/dist/node_modules/micromark-factory-title/index.js +6 -8
  1493. package/dist/node_modules/micromark-factory-whitespace/index.js +5 -7
  1494. package/dist/node_modules/micromark-util-character/index.js +12 -14
  1495. package/dist/node_modules/micromark-util-chunked/index.js +4 -6
  1496. package/dist/node_modules/micromark-util-classify-character/index.js +5 -7
  1497. package/dist/node_modules/micromark-util-combine-extensions/index.js +11 -13
  1498. package/dist/node_modules/micromark-util-decode-numeric-character-reference/index.js +2 -4
  1499. package/dist/node_modules/micromark-util-decode-string/index.js +9 -11
  1500. package/dist/node_modules/micromark-util-html-tag-name/index.js +2 -4
  1501. package/dist/node_modules/micromark-util-normalize-identifier/index.js +2 -4
  1502. package/dist/node_modules/micromark-util-resolve-all/index.js +2 -4
  1503. package/dist/node_modules/micromark-util-sanitize-uri/index.js +4 -6
  1504. package/dist/node_modules/micromark-util-subtokenize/index.js +8 -10
  1505. package/dist/node_modules/micromark-util-subtokenize/lib/splice-buffer.js +8 -10
  1506. package/dist/node_modules/motion/dist/es/react.js +2 -2
  1507. package/dist/node_modules/nanoid/index.browser.js +4 -6
  1508. package/dist/node_modules/nanoid/url-alphabet/index.js +2 -4
  1509. package/dist/node_modules/property-information/index.js +23 -25
  1510. package/dist/node_modules/property-information/lib/aria.js +39 -41
  1511. package/dist/node_modules/property-information/lib/find.js +16 -18
  1512. package/dist/node_modules/property-information/lib/hast-to-react.js +2 -4
  1513. package/dist/node_modules/property-information/lib/html.js +94 -96
  1514. package/dist/node_modules/property-information/lib/normalize.js +2 -4
  1515. package/dist/node_modules/property-information/lib/svg.js +77 -79
  1516. package/dist/node_modules/property-information/lib/util/case-insensitive-transform.js +4 -6
  1517. package/dist/node_modules/property-information/lib/util/case-sensitive-transform.js +2 -4
  1518. package/dist/node_modules/property-information/lib/util/create.js +8 -10
  1519. package/dist/node_modules/property-information/lib/util/defined-info.js +11 -13
  1520. package/dist/node_modules/property-information/lib/util/info.js +3 -5
  1521. package/dist/node_modules/property-information/lib/util/merge.js +4 -6
  1522. package/dist/node_modules/property-information/lib/util/schema.js +3 -5
  1523. package/dist/node_modules/property-information/lib/util/types.js +14 -15
  1524. package/dist/node_modules/property-information/lib/xlink.js +3 -5
  1525. package/dist/node_modules/property-information/lib/xml.js +3 -5
  1526. package/dist/node_modules/property-information/lib/xmlns.js +5 -7
  1527. package/dist/node_modules/rehype-harden/dist/index.js +45 -47
  1528. package/dist/node_modules/rehype-katex/lib/index.js +23 -25
  1529. package/dist/node_modules/rehype-raw/lib/index.js +4 -6
  1530. package/dist/node_modules/rehype-sanitize/lib/index.js +4 -6
  1531. package/dist/node_modules/remark-gfm/lib/index.js +7 -9
  1532. package/dist/node_modules/remark-math/lib/index.js +7 -9
  1533. package/dist/node_modules/remark-parse/lib/index.js +4 -6
  1534. package/dist/node_modules/remark-rehype/lib/index.js +5 -7
  1535. package/dist/node_modules/remend/dist/index.js +324 -326
  1536. package/dist/node_modules/roughjs/bundled/rough.esm.js +875 -877
  1537. package/dist/node_modules/shiki/dist/bundle-full.js +12 -13
  1538. package/dist/node_modules/shiki/dist/chunk-CtajNgzt.js +8 -10
  1539. package/dist/node_modules/shiki/dist/engine-oniguruma.js +5 -7
  1540. package/dist/node_modules/shiki/dist/langs-bundle-full-DfKZStlK.js +5 -7
  1541. package/dist/node_modules/shiki/dist/themes.js +3 -5
  1542. package/dist/node_modules/shiki/dist/wasm.js +2 -2
  1543. package/dist/node_modules/space-separated-tokens/index.js +3 -5
  1544. package/dist/node_modules/streamdown/dist/chunk-BO2N2NFS.js +699 -701
  1545. package/dist/node_modules/streamdown/dist/highlighted-body-OFNGDK62.js +8 -10
  1546. package/dist/node_modules/streamdown/dist/index.js +1 -1
  1547. package/dist/node_modules/streamdown/dist/mermaid-GHXKKRXX.js +2 -2
  1548. package/dist/node_modules/streamdown/node_modules/marked/lib/marked.esm.js +712 -709
  1549. package/dist/node_modules/stringify-entities/lib/constant/dangerous.js +2 -4
  1550. package/dist/node_modules/stringify-entities/lib/core.js +16 -18
  1551. package/dist/node_modules/stringify-entities/lib/index.js +5 -7
  1552. package/dist/node_modules/stringify-entities/lib/util/format-smart.js +8 -10
  1553. package/dist/node_modules/stringify-entities/lib/util/to-decimal.js +4 -6
  1554. package/dist/node_modules/stringify-entities/lib/util/to-hexadecimal.js +4 -6
  1555. package/dist/node_modules/stringify-entities/lib/util/to-named.js +12 -14
  1556. package/dist/node_modules/style-to-js/cjs/index.js +7 -9
  1557. package/dist/node_modules/style-to-js/cjs/utilities.js +4 -6
  1558. package/dist/node_modules/style-to-object/cjs/index.js +6 -8
  1559. package/dist/node_modules/stylis/src/Enum.js +2 -4
  1560. package/dist/node_modules/stylis/src/Parser.js +36 -38
  1561. package/dist/node_modules/stylis/src/Serializer.js +15 -17
  1562. package/dist/node_modules/stylis/src/Tokenizer.js +51 -53
  1563. package/dist/node_modules/stylis/src/Utility.js +15 -17
  1564. package/dist/node_modules/trim-lines/index.js +8 -10
  1565. package/dist/node_modules/trough/lib/index.js +4 -6
  1566. package/dist/node_modules/ts-dedent/esm/index.js +2 -4
  1567. package/dist/node_modules/unified/lib/callable-instance.js +2 -4
  1568. package/dist/node_modules/unified/lib/index.js +101 -102
  1569. package/dist/node_modules/unified/node_modules/is-plain-obj/index.js +2 -4
  1570. package/dist/node_modules/unist-util-find-after/lib/index.js +4 -6
  1571. package/dist/node_modules/unist-util-is/lib/index.js +29 -31
  1572. package/dist/node_modules/unist-util-position/lib/index.js +5 -7
  1573. package/dist/node_modules/unist-util-stringify-position/lib/index.js +8 -10
  1574. package/dist/node_modules/unist-util-visit/lib/index.js +4 -6
  1575. package/dist/node_modules/unist-util-visit-parents/lib/color.js +2 -4
  1576. package/dist/node_modules/unist-util-visit-parents/lib/index.js +20 -21
  1577. package/dist/node_modules/uuid/dist/esm-browser/native.js +2 -3
  1578. package/dist/node_modules/uuid/dist/esm-browser/rng.js +6 -8
  1579. package/dist/node_modules/uuid/dist/esm-browser/stringify.js +5 -7
  1580. package/dist/node_modules/uuid/dist/esm-browser/v4.js +9 -10
  1581. package/dist/node_modules/vaul/dist/index.js +274 -276
  1582. package/dist/node_modules/vfile/lib/index.js +42 -44
  1583. package/dist/node_modules/vfile/lib/minpath.browser.js +20 -22
  1584. package/dist/node_modules/vfile/lib/minproc.browser.js +3 -5
  1585. package/dist/node_modules/vfile/lib/minurl.browser.js +6 -8
  1586. package/dist/node_modules/vfile/lib/minurl.shared.js +2 -4
  1587. package/dist/node_modules/vfile-location/lib/index.js +5 -7
  1588. package/dist/node_modules/vfile-message/lib/index.js +5 -7
  1589. package/dist/node_modules/vscode-jsonrpc/browser.js +6 -8
  1590. package/dist/node_modules/vscode-jsonrpc/lib/browser/main.js +9 -11
  1591. package/dist/node_modules/vscode-jsonrpc/lib/browser/ril.js +6 -8
  1592. package/dist/node_modules/vscode-jsonrpc/lib/common/api.js +26 -28
  1593. package/dist/node_modules/vscode-jsonrpc/lib/common/cancellation.js +15 -17
  1594. package/dist/node_modules/vscode-jsonrpc/lib/common/connection.js +11 -13
  1595. package/dist/node_modules/vscode-jsonrpc/lib/common/disposable.js +4 -6
  1596. package/dist/node_modules/vscode-jsonrpc/lib/common/events.js +6 -8
  1597. package/dist/node_modules/vscode-jsonrpc/lib/common/is.js +4 -6
  1598. package/dist/node_modules/vscode-jsonrpc/lib/common/linkedMap.js +4 -6
  1599. package/dist/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js +4 -6
  1600. package/dist/node_modules/vscode-jsonrpc/lib/common/messageReader.js +9 -11
  1601. package/dist/node_modules/vscode-jsonrpc/lib/common/messageWriter.js +29 -31
  1602. package/dist/node_modules/vscode-jsonrpc/lib/common/messages.js +6 -8
  1603. package/dist/node_modules/vscode-jsonrpc/lib/common/ral.js +4 -6
  1604. package/dist/node_modules/vscode-jsonrpc/lib/common/semaphore.js +6 -8
  1605. package/dist/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js +6 -8
  1606. package/dist/node_modules/vscode-languageserver-protocol/lib/browser/main.js +8 -10
  1607. package/dist/node_modules/vscode-languageserver-protocol/lib/common/api.js +21 -23
  1608. package/dist/node_modules/vscode-languageserver-protocol/lib/common/connection.js +6 -8
  1609. package/dist/node_modules/vscode-languageserver-protocol/lib/common/messages.js +6 -8
  1610. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js +6 -8
  1611. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js +6 -8
  1612. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js +6 -8
  1613. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js +6 -8
  1614. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js +12 -14
  1615. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js +6 -8
  1616. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js +6 -8
  1617. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js +6 -8
  1618. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js +6 -8
  1619. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js +6 -8
  1620. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js +6 -8
  1621. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.js +53 -55
  1622. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js +6 -8
  1623. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js +6 -8
  1624. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js +8 -10
  1625. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js +10 -12
  1626. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js +6 -8
  1627. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js +6 -8
  1628. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js +6 -8
  1629. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js +6 -8
  1630. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js +6 -8
  1631. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js +6 -8
  1632. package/dist/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js +4 -6
  1633. package/dist/node_modules/vscode-languageserver-textdocument/lib/esm/main.js +19 -21
  1634. package/dist/node_modules/vscode-languageserver-types/lib/esm/main.js +847 -849
  1635. package/dist/node_modules/vscode-uri/lib/esm/index.js +4 -6
  1636. package/dist/node_modules/web-namespaces/index.js +2 -4
  1637. package/dist/node_modules/zwitch/index.js +5 -7
  1638. package/dist/packages/contracts/dist/enums/index.js +12 -14
  1639. package/dist/packages/contracts/dist/enums/registry.enum.js +4 -6
  1640. package/dist/packages/contracts/dist/enums/sort-order.enum.js +4 -6
  1641. package/dist/packages/contracts/dist/enums/user-type.enum.js +4 -6
  1642. package/dist/packages/contracts/dist/enums/workflow-state.enum.js +4 -6
  1643. package/dist/pages/DashboardPage.js +78 -59
  1644. package/dist/pages/DebugPage.js +17 -12
  1645. package/dist/pages/DebugWorkflowDetailsPage.js +105 -91
  1646. package/dist/pages/DebugWorkflowsPage.js +162 -125
  1647. package/dist/pages/EmbedWorkbenchPage.js +63 -48
  1648. package/dist/pages/PreviewWorkbenchPage.js +370 -271
  1649. package/dist/pages/RunsListPage.js +46 -43
  1650. package/dist/pages/RunsPage.js +33 -31
  1651. package/dist/pages/StudioLandingPage.js +132 -97
  1652. package/dist/pages/WorkbenchPage.js +65 -57
  1653. package/dist/pages/WorkflowDebugPage.js +96 -74
  1654. package/dist/pages/WorkspacePage.js +88 -72
  1655. package/dist/pages/WorkspaceRunsPage.js +75 -43
  1656. package/dist/pages/WorkspacesPage.js +17 -22
  1657. package/dist/providers/ComponentOverridesProvider.js +12 -9
  1658. package/dist/providers/InvalidationEventsProvider.js +35 -33
  1659. package/dist/providers/QueryProvider.js +18 -14
  1660. package/dist/providers/SseProvider.js +29 -28
  1661. package/dist/providers/StudioPreferencesProvider.js +54 -0
  1662. package/dist/providers/StudioProvider.js +19 -14
  1663. package/dist/routing/LocalRouter.js +9 -6
  1664. package/dist/services/createApiClient.js +5 -7
  1665. package/dist/services/eventEmitter.js +2 -3
  1666. package/dist/services/index.js +2 -2
  1667. package/dist/types/ai.types.js +5 -7
  1668. package/package.json +8 -8
  1669. package/dist/_virtual/_rolldown/runtime.js +0 -20
  1670. package/dist/features/documents/renderers/SecretInputRenderer.js +0 -89
  1671. package/dist/features/workbench/components/RemoteFileTabsBar.js +0 -19
  1672. package/dist/features/workbench/components/RemoteFileTree.js +0 -59
  1673. package/dist/features/workbench/components/WorkbenchFilesPanel.js +0 -56
  1674. package/dist/features/workbench/components/WorkbenchFloatingPanel.js +0 -40
  1675. package/dist/features/workbench/components/WorkbenchFlowPanel.js +0 -38
  1676. package/dist/features/workbench/components/WorkbenchSecretsPanel.js +0 -153
  1677. package/dist/features/workbench/providers/RemoteFileExplorerProvider.js +0 -145
  1678. package/dist/frontend/studio/node_modules/lodash/_Symbol.js +0 -9
  1679. package/dist/frontend/studio/node_modules/lodash/_baseGetTag.js +0 -15
  1680. package/dist/frontend/studio/node_modules/lodash/_baseTrim.js +0 -13
  1681. package/dist/frontend/studio/node_modules/lodash/_freeGlobal.js +0 -8
  1682. package/dist/frontend/studio/node_modules/lodash/_getRawTag.js +0 -19
  1683. package/dist/frontend/studio/node_modules/lodash/_objectToString.js +0 -12
  1684. package/dist/frontend/studio/node_modules/lodash/_root.js +0 -10
  1685. package/dist/frontend/studio/node_modules/lodash/_trimmedEndIndex.js +0 -13
  1686. package/dist/frontend/studio/node_modules/lodash/isObject.js +0 -12
  1687. package/dist/frontend/studio/node_modules/lodash/isObjectLike.js +0 -11
  1688. package/dist/frontend/studio/node_modules/lodash/isSymbol.js +0 -14
  1689. package/dist/frontend/studio/node_modules/lodash/now.js +0 -12
  1690. package/dist/frontend/studio/node_modules/lodash/toNumber.js +0 -24
  1691. package/dist/node_modules/@dagrejs/dagre/dist/dagre.esm.js +0 -1867
@@ -1,13 +1,12 @@
1
- import e from "../../../../d3-selection/src/select.js";
2
- import t from "../../../../d3-selection/src/pointer.js";
3
- import n from "../../../../d3-drag/src/drag.js";
4
- import r from "../../../../d3-interpolate/src/value.js";
5
- import i from "../../../../d3-interpolate/src/zoom.js";
6
- import a, { identity as o } from "../../../../d3-zoom/src/transform.js";
7
- import s from "../../../../d3-zoom/src/zoom.js";
1
+ import select_default from "../../../../d3-selection/src/select.js";
2
+ import pointer_default from "../../../../d3-selection/src/pointer.js";
3
+ import drag_default from "../../../../d3-drag/src/drag.js";
4
+ import value_default from "../../../../d3-interpolate/src/value.js";
5
+ import zoom_default$1 from "../../../../d3-interpolate/src/zoom.js";
6
+ import transform, { identity } from "../../../../d3-zoom/src/transform.js";
7
+ import zoom_default from "../../../../d3-zoom/src/zoom.js";
8
8
  import "../../../../d3-zoom/src/index.js";
9
- //#region ../../node_modules/@xyflow/system/dist/esm/index.js
10
- var c = {
9
+ var errorMessages = {
11
10
  error001: () => "[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001",
12
11
  error002: () => "It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",
13
12
  error003: (e) => `Node type "${e}" not found. Using fallback type "default".`,
@@ -16,21 +15,21 @@ var c = {
16
15
  error006: () => "Can't create edge. An edge needs a source and a target.",
17
16
  error007: (e) => `The old edge with id=${e} does not exist.`,
18
17
  error009: (e) => `Marker type "${e}" doesn't exist.`,
19
- error008: (e, { id: t, sourceHandle: n, targetHandle: r }) => `Couldn't create edge for ${e} handle id: "${e === "source" ? n : r}", edge id: ${t}.`,
18
+ error008: (e, { id: s, sourceHandle: c, targetHandle: l }) => `Couldn't create edge for ${e} handle id: "${e === "source" ? c : l}", edge id: ${s}.`,
20
19
  error010: () => "Handle: No node id found. Make sure to only use a Handle inside a custom Node.",
21
20
  error011: (e) => `Edge type "${e}" not found. Using fallback type "default".`,
22
21
  error012: (e) => `Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`,
23
22
  error013: (e = "react") => `It seems that you haven't loaded the styles. Please import '@xyflow/${e}/dist/style.css' or base.css to make sure everything is working properly.`,
24
23
  error014: () => "useNodeConnections: No node ID found. Call useNodeConnections inside a custom Node or provide a node ID.",
25
24
  error015: () => "It seems that you are trying to drag a node that is not initialized. Please use onNodesChange as explained in the docs."
26
- }, l = [[-Infinity, -Infinity], [Infinity, Infinity]], u = [
25
+ }, infiniteExtent = [[-Infinity, -Infinity], [Infinity, Infinity]], elementSelectionKeys = [
27
26
  "Enter",
28
27
  " ",
29
28
  "Escape"
30
- ], d = {
29
+ ], defaultAriaLabelConfig = {
31
30
  "node.a11yDescription.default": "Press enter or space to select a node. Press delete to remove it and escape to cancel.",
32
31
  "node.a11yDescription.keyboardDisabled": "Press enter or space to select a node. You can then use the arrow keys to move the node around. Press delete to remove it and escape to cancel.",
33
- "node.a11yDescription.ariaLiveMessage": ({ direction: e, x: t, y: n }) => `Moved selected node ${e}. New position, x: ${t}, y: ${n}`,
32
+ "node.a11yDescription.ariaLiveMessage": ({ direction: e, x: s, y: c }) => `Moved selected node ${e}. New position, x: ${s}, y: ${c}`,
34
33
  "edge.a11yDescription.default": "Press enter or space to select an edge. You can then press delete to remove it or escape to cancel.",
35
34
  "controls.ariaLabel": "Control Panel",
36
35
  "controls.zoomIn.ariaLabel": "Zoom In",
@@ -39,19 +38,19 @@ var c = {
39
38
  "controls.interactive.ariaLabel": "Toggle Interactivity",
40
39
  "minimap.ariaLabel": "Mini Map",
41
40
  "handle.ariaLabel": "Handle"
42
- }, f;
41
+ }, ConnectionMode;
43
42
  (function(e) {
44
43
  e.Strict = "strict", e.Loose = "loose";
45
- })(f ||= {});
46
- var p;
44
+ })(ConnectionMode ||= {});
45
+ var PanOnScrollMode;
47
46
  (function(e) {
48
47
  e.Free = "free", e.Vertical = "vertical", e.Horizontal = "horizontal";
49
- })(p ||= {});
50
- var m;
48
+ })(PanOnScrollMode ||= {});
49
+ var SelectionMode;
51
50
  (function(e) {
52
51
  e.Partial = "partial", e.Full = "full";
53
- })(m ||= {});
54
- var h = {
52
+ })(SelectionMode ||= {});
53
+ var initialConnection = {
55
54
  inProgress: !1,
56
55
  isValid: null,
57
56
  from: null,
@@ -63,41 +62,41 @@ var h = {
63
62
  toPosition: null,
64
63
  toNode: null,
65
64
  pointer: null
66
- }, g;
65
+ }, ConnectionLineType;
67
66
  (function(e) {
68
67
  e.Bezier = "default", e.Straight = "straight", e.Step = "step", e.SmoothStep = "smoothstep", e.SimpleBezier = "simplebezier";
69
- })(g ||= {});
70
- var _;
68
+ })(ConnectionLineType ||= {});
69
+ var MarkerType;
71
70
  (function(e) {
72
71
  e.Arrow = "arrow", e.ArrowClosed = "arrowclosed";
73
- })(_ ||= {});
74
- var v;
72
+ })(MarkerType ||= {});
73
+ var Position;
75
74
  (function(e) {
76
75
  e.Left = "left", e.Top = "top", e.Right = "right", e.Bottom = "bottom";
77
- })(v ||= {});
78
- var y = {
79
- [v.Left]: v.Right,
80
- [v.Right]: v.Left,
81
- [v.Top]: v.Bottom,
82
- [v.Bottom]: v.Top
76
+ })(Position ||= {});
77
+ var oppositePosition = {
78
+ [Position.Left]: Position.Right,
79
+ [Position.Right]: Position.Left,
80
+ [Position.Top]: Position.Bottom,
81
+ [Position.Bottom]: Position.Top
83
82
  };
84
- function b(e) {
83
+ function getConnectionStatus(e) {
85
84
  return e === null ? null : e ? "valid" : "invalid";
86
85
  }
87
- var x = (e) => "id" in e && "source" in e && "target" in e, S = (e) => "id" in e && "position" in e && !("source" in e) && !("target" in e), C = (e) => "id" in e && "internals" in e && !("source" in e) && !("target" in e), w = (e, t = [0, 0]) => {
88
- let { width: n, height: r } = J(e), i = e.origin ?? t, a = n * i[0], o = r * i[1];
86
+ var isEdgeBase = (e) => "id" in e && "source" in e && "target" in e, isNodeBase = (e) => "id" in e && "position" in e && !("source" in e) && !("target" in e), isInternalNodeBase = (e) => "id" in e && "internals" in e && !("source" in e) && !("target" in e), getNodePositionWithOrigin = (e, s = [0, 0]) => {
87
+ let { width: c, height: l } = getNodeDimensions(e), u = e.origin ?? s, d = c * u[0], f = l * u[1];
89
88
  return {
90
- x: e.position.x - a,
91
- y: e.position.y - o
89
+ x: e.position.x - d,
90
+ y: e.position.y - f
92
91
  };
93
- }, T = (e, t = { nodeOrigin: [0, 0] }) => (process.env.NODE_ENV === "development" && !t.nodeLookup && console.warn("Please use `getNodesBounds` from `useReactFlow`/`useSvelteFlow` hook to ensure correct values for sub flows. If not possible, you have to provide a nodeLookup to support sub flows."), e.length === 0 ? {
92
+ }, getNodesBounds = (e, s = { nodeOrigin: [0, 0] }) => (process.env.NODE_ENV === "development" && !s.nodeLookup && console.warn("Please use `getNodesBounds` from `useReactFlow`/`useSvelteFlow` hook to ensure correct values for sub flows. If not possible, you have to provide a nodeLookup to support sub flows."), e.length === 0 ? {
94
93
  x: 0,
95
94
  y: 0,
96
95
  width: 0,
97
96
  height: 0
98
- } : R(e.reduce((e, n) => {
99
- let r = typeof n == "string", i = !t.nodeLookup && !r ? n : void 0;
100
- return t.nodeLookup && (i = r ? t.nodeLookup.get(n) : C(n) ? n : t.nodeLookup.get(n.id)), te(e, i ? ne(i, t.nodeOrigin) : {
97
+ } : boxToRect(e.reduce((e, c) => {
98
+ let l = typeof c == "string", u = !s.nodeLookup && !l ? c : void 0;
99
+ return s.nodeLookup && (u = l ? s.nodeLookup.get(c) : isInternalNodeBase(c) ? c : s.nodeLookup.get(c.id)), getBoundsOfBoxes(e, u ? nodeToBox(u, s.nodeOrigin) : {
101
100
  x: 0,
102
101
  y: 0,
103
102
  x2: 0,
@@ -108,201 +107,201 @@ var x = (e) => "id" in e && "source" in e && "target" in e, S = (e) => "id" in e
108
107
  y: Infinity,
109
108
  x2: -Infinity,
110
109
  y2: -Infinity
111
- }))), E = (e, t = {}) => {
112
- let n = {
110
+ }))), getInternalNodesBounds = (e, s = {}) => {
111
+ let c = {
113
112
  x: Infinity,
114
113
  y: Infinity,
115
114
  x2: -Infinity,
116
115
  y2: -Infinity
117
- }, r = !1;
116
+ }, l = !1;
118
117
  return e.forEach((e) => {
119
- (t.filter === void 0 || t.filter(e)) && (n = te(n, ne(e)), r = !0);
120
- }), r ? R(n) : {
118
+ (s.filter === void 0 || s.filter(e)) && (c = getBoundsOfBoxes(c, nodeToBox(e)), l = !0);
119
+ }), l ? boxToRect(c) : {
121
120
  x: 0,
122
121
  y: 0,
123
122
  width: 0,
124
123
  height: 0
125
124
  };
126
- }, D = (e, t, [n, r, i] = [
125
+ }, getNodesInside = (e, s, [c, l, u] = [
127
126
  0,
128
127
  0,
129
128
  1
130
- ], a = !1, o = !1) => {
131
- let s = {
132
- ...re(t, [
133
- n,
134
- r,
135
- i
129
+ ], d = !1, f = !1) => {
130
+ let p = {
131
+ ...pointToRendererPoint(s, [
132
+ c,
133
+ l,
134
+ u
136
135
  ]),
137
- width: t.width / i,
138
- height: t.height / i
139
- }, c = [];
140
- for (let t of e.values()) {
141
- let { measured: e, selectable: n = !0, hidden: r = !1 } = t;
142
- if (o && !n || r) continue;
143
- let i = e.width ?? t.width ?? t.initialWidth ?? null, l = e.height ?? t.height ?? t.initialHeight ?? null, u = V(s, z(t)), d = (i ?? 0) * (l ?? 0), f = a && u > 0;
144
- (!t.internals.handleBounds || f || u >= d || t.dragging) && c.push(t);
136
+ width: s.width / u,
137
+ height: s.height / u
138
+ }, m = [];
139
+ for (let s of e.values()) {
140
+ let { measured: e, selectable: c = !0, hidden: l = !1 } = s;
141
+ if (f && !c || l) continue;
142
+ let u = e.width ?? s.width ?? s.initialWidth ?? null, h = e.height ?? s.height ?? s.initialHeight ?? null, g = getOverlappingArea(p, nodeToRect(s)), _ = (u ?? 0) * (h ?? 0), v = d && g > 0;
143
+ (!s.internals.handleBounds || v || g >= _ || s.dragging) && m.push(s);
145
144
  }
146
- return c;
147
- }, O = (e, t) => {
148
- let n = /* @__PURE__ */ new Set();
145
+ return m;
146
+ }, getConnectedEdges = (e, s) => {
147
+ let c = /* @__PURE__ */ new Set();
149
148
  return e.forEach((e) => {
150
- n.add(e.id);
151
- }), t.filter((e) => n.has(e.source) || n.has(e.target));
149
+ c.add(e.id);
150
+ }), s.filter((e) => c.has(e.source) || c.has(e.target));
152
151
  };
153
- function k(e, t) {
154
- let n = /* @__PURE__ */ new Map(), r = t?.nodes ? new Set(t.nodes.map((e) => e.id)) : null;
152
+ function getFitViewNodes(e, s) {
153
+ let c = /* @__PURE__ */ new Map(), l = s?.nodes ? new Set(s.nodes.map((e) => e.id)) : null;
155
154
  return e.forEach((e) => {
156
- e.measured.width && e.measured.height && (t?.includeHiddenNodes || !e.hidden) && (!r || r.has(e.id)) && n.set(e.id, e);
157
- }), n;
155
+ e.measured.width && e.measured.height && (s?.includeHiddenNodes || !e.hidden) && (!l || l.has(e.id)) && c.set(e.id, e);
156
+ }), c;
158
157
  }
159
- async function A({ nodes: e, width: t, height: n, panZoom: r, minZoom: i, maxZoom: a }, o) {
158
+ async function fitViewport({ nodes: e, width: s, height: c, panZoom: l, minZoom: u, maxZoom: d }, f) {
160
159
  if (e.size === 0) return Promise.resolve(!0);
161
- let s = se(E(k(e, o)), t, n, o?.minZoom ?? i, o?.maxZoom ?? a, o?.padding ?? .1);
162
- return await r.setViewport(s, {
163
- duration: o?.duration,
164
- ease: o?.ease,
165
- interpolate: o?.interpolate
160
+ let p = getViewportForBounds(getInternalNodesBounds(getFitViewNodes(e, f)), s, c, f?.minZoom ?? u, f?.maxZoom ?? d, f?.padding ?? .1);
161
+ return await l.setViewport(p, {
162
+ duration: f?.duration,
163
+ ease: f?.ease,
164
+ interpolate: f?.interpolate
166
165
  }), Promise.resolve(!0);
167
166
  }
168
- function j({ nodeId: e, nextPosition: t, nodeLookup: n, nodeOrigin: r = [0, 0], nodeExtent: i, onError: a }) {
169
- let o = n.get(e), s = o.parentId ? n.get(o.parentId) : void 0, { x: l, y: u } = s ? s.internals.positionAbsolute : {
167
+ function calculateNodePosition({ nodeId: e, nextPosition: s, nodeLookup: c, nodeOrigin: l = [0, 0], nodeExtent: u, onError: d }) {
168
+ let f = c.get(e), p = f.parentId ? c.get(f.parentId) : void 0, { x: h, y: g } = p ? p.internals.positionAbsolute : {
170
169
  x: 0,
171
170
  y: 0
172
- }, d = o.origin ?? r, f = o.extent || i;
173
- if (o.extent === "parent" && !o.expandParent) if (!s) a?.("005", c.error005());
171
+ }, _ = f.origin ?? l, v = f.extent || u;
172
+ if (f.extent === "parent" && !f.expandParent) if (!p) d?.("005", errorMessages.error005());
174
173
  else {
175
- let e = s.measured.width, t = s.measured.height;
176
- e && t && (f = [[l, u], [l + e, u + t]]);
174
+ let e = p.measured.width, s = p.measured.height;
175
+ e && s && (v = [[h, g], [h + e, g + s]]);
177
176
  }
178
- else s && q(o.extent) && (f = [[o.extent[0][0] + l, o.extent[0][1] + u], [o.extent[1][0] + l, o.extent[1][1] + u]]);
179
- let p = q(f) ? P(t, f, o.measured) : t;
180
- return (o.measured.width === void 0 || o.measured.height === void 0) && a?.("015", c.error015()), {
177
+ else p && isCoordinateExtent(f.extent) && (v = [[f.extent[0][0] + h, f.extent[0][1] + g], [f.extent[1][0] + h, f.extent[1][1] + g]]);
178
+ let y = isCoordinateExtent(v) ? clampPosition(s, v, f.measured) : s;
179
+ return (f.measured.width === void 0 || f.measured.height === void 0) && d?.("015", errorMessages.error015()), {
181
180
  position: {
182
- x: p.x - l + (o.measured.width ?? 0) * d[0],
183
- y: p.y - u + (o.measured.height ?? 0) * d[1]
181
+ x: y.x - h + (f.measured.width ?? 0) * _[0],
182
+ y: y.y - g + (f.measured.height ?? 0) * _[1]
184
183
  },
185
- positionAbsolute: p
184
+ positionAbsolute: y
186
185
  };
187
186
  }
188
- async function M({ nodesToRemove: e = [], edgesToRemove: t = [], nodes: n, edges: r, onBeforeDelete: i }) {
189
- let a = new Set(e.map((e) => e.id)), o = [];
190
- for (let e of n) {
187
+ async function getElementsToRemove({ nodesToRemove: e = [], edgesToRemove: s = [], nodes: c, edges: l, onBeforeDelete: u }) {
188
+ let d = new Set(e.map((e) => e.id)), f = [];
189
+ for (let e of c) {
191
190
  if (e.deletable === !1) continue;
192
- let t = a.has(e.id), n = !t && e.parentId && o.find((t) => t.id === e.parentId);
193
- (t || n) && o.push(e);
191
+ let s = d.has(e.id), c = !s && e.parentId && f.find((s) => s.id === e.parentId);
192
+ (s || c) && f.push(e);
194
193
  }
195
- let s = new Set(t.map((e) => e.id)), c = r.filter((e) => e.deletable !== !1), l = O(o, c);
196
- for (let e of c) s.has(e.id) && !l.find((t) => t.id === e.id) && l.push(e);
197
- if (!i) return {
198
- edges: l,
199
- nodes: o
194
+ let p = new Set(s.map((e) => e.id)), m = l.filter((e) => e.deletable !== !1), h = getConnectedEdges(f, m);
195
+ for (let e of m) p.has(e.id) && !h.find((s) => s.id === e.id) && h.push(e);
196
+ if (!u) return {
197
+ edges: h,
198
+ nodes: f
200
199
  };
201
- let u = await i({
202
- nodes: o,
203
- edges: l
200
+ let g = await u({
201
+ nodes: f,
202
+ edges: h
204
203
  });
205
- return typeof u == "boolean" ? u ? {
206
- edges: l,
207
- nodes: o
204
+ return typeof g == "boolean" ? g ? {
205
+ edges: h,
206
+ nodes: f
208
207
  } : {
209
208
  edges: [],
210
209
  nodes: []
211
- } : u;
210
+ } : g;
212
211
  }
213
- var N = (e, t = 0, n = 1) => Math.min(Math.max(e, t), n), P = (e = {
212
+ var clamp = (e, s = 0, c = 1) => Math.min(Math.max(e, s), c), clampPosition = (e = {
214
213
  x: 0,
215
214
  y: 0
216
- }, t, n) => ({
217
- x: N(e.x, t[0][0], t[1][0] - (n?.width ?? 0)),
218
- y: N(e.y, t[0][1], t[1][1] - (n?.height ?? 0))
215
+ }, s, c) => ({
216
+ x: clamp(e.x, s[0][0], s[1][0] - (c?.width ?? 0)),
217
+ y: clamp(e.y, s[0][1], s[1][1] - (c?.height ?? 0))
219
218
  });
220
- function F(e, t, n) {
221
- let { width: r, height: i } = J(n), { x: a, y: o } = n.internals.positionAbsolute;
222
- return P(e, [[a, o], [a + r, o + i]], t);
223
- }
224
- var I = (e, t, n) => e < t ? N(Math.abs(e - t), 1, t) / t : e > n ? -N(Math.abs(e - n), 1, t) / t : 0, ee = (e, t, n = 15, r = 40) => [I(e.x, r, t.width - r) * n, I(e.y, r, t.height - r) * n], te = (e, t) => ({
225
- x: Math.min(e.x, t.x),
226
- y: Math.min(e.y, t.y),
227
- x2: Math.max(e.x2, t.x2),
228
- y2: Math.max(e.y2, t.y2)
229
- }), L = ({ x: e, y: t, width: n, height: r }) => ({
219
+ function clampPositionToParent(e, s, c) {
220
+ let { width: l, height: u } = getNodeDimensions(c), { x: d, y: f } = c.internals.positionAbsolute;
221
+ return clampPosition(e, [[d, f], [d + l, f + u]], s);
222
+ }
223
+ var calcAutoPanVelocity = (e, s, c) => e < s ? clamp(Math.abs(e - s), 1, s) / s : e > c ? -clamp(Math.abs(e - c), 1, s) / s : 0, calcAutoPan = (e, s, c = 15, l = 40) => [calcAutoPanVelocity(e.x, l, s.width - l) * c, calcAutoPanVelocity(e.y, l, s.height - l) * c], getBoundsOfBoxes = (e, s) => ({
224
+ x: Math.min(e.x, s.x),
225
+ y: Math.min(e.y, s.y),
226
+ x2: Math.max(e.x2, s.x2),
227
+ y2: Math.max(e.y2, s.y2)
228
+ }), rectToBox = ({ x: e, y: s, width: c, height: l }) => ({
230
229
  x: e,
231
- y: t,
232
- x2: e + n,
233
- y2: t + r
234
- }), R = ({ x: e, y: t, x2: n, y2: r }) => ({
230
+ y: s,
231
+ x2: e + c,
232
+ y2: s + l
233
+ }), boxToRect = ({ x: e, y: s, x2: c, y2: l }) => ({
235
234
  x: e,
236
- y: t,
237
- width: n - e,
238
- height: r - t
239
- }), z = (e, t = [0, 0]) => {
240
- let { x: n, y: r } = C(e) ? e.internals.positionAbsolute : w(e, t);
235
+ y: s,
236
+ width: c - e,
237
+ height: l - s
238
+ }), nodeToRect = (e, s = [0, 0]) => {
239
+ let { x: c, y: l } = isInternalNodeBase(e) ? e.internals.positionAbsolute : getNodePositionWithOrigin(e, s);
241
240
  return {
242
- x: n,
243
- y: r,
241
+ x: c,
242
+ y: l,
244
243
  width: e.measured?.width ?? e.width ?? e.initialWidth ?? 0,
245
244
  height: e.measured?.height ?? e.height ?? e.initialHeight ?? 0
246
245
  };
247
- }, ne = (e, t = [0, 0]) => {
248
- let { x: n, y: r } = C(e) ? e.internals.positionAbsolute : w(e, t);
246
+ }, nodeToBox = (e, s = [0, 0]) => {
247
+ let { x: c, y: l } = isInternalNodeBase(e) ? e.internals.positionAbsolute : getNodePositionWithOrigin(e, s);
249
248
  return {
250
- x: n,
251
- y: r,
252
- x2: n + (e.measured?.width ?? e.width ?? e.initialWidth ?? 0),
253
- y2: r + (e.measured?.height ?? e.height ?? e.initialHeight ?? 0)
249
+ x: c,
250
+ y: l,
251
+ x2: c + (e.measured?.width ?? e.width ?? e.initialWidth ?? 0),
252
+ y2: l + (e.measured?.height ?? e.height ?? e.initialHeight ?? 0)
254
253
  };
255
- }, B = (e, t) => R(te(L(e), L(t))), V = (e, t) => {
256
- let n = Math.max(0, Math.min(e.x + e.width, t.x + t.width) - Math.max(e.x, t.x)), r = Math.max(0, Math.min(e.y + e.height, t.y + t.height) - Math.max(e.y, t.y));
257
- return Math.ceil(n * r);
258
- }, H = (e) => U(e.width) && U(e.height) && U(e.x) && U(e.y), U = (e) => !isNaN(e) && isFinite(e), W = (e, t) => {
259
- process.env.NODE_ENV === "development" && console.warn(`[React Flow]: ${t} Help: https://reactflow.dev/error#${e}`);
260
- }, G = (e, t = [1, 1]) => ({
261
- x: t[0] * Math.round(e.x / t[0]),
262
- y: t[1] * Math.round(e.y / t[1])
263
- }), re = ({ x: e, y: t }, [n, r, i], a = !1, o = [1, 1]) => {
264
- let s = {
265
- x: (e - n) / i,
266
- y: (t - r) / i
254
+ }, getBoundsOfRects = (e, s) => boxToRect(getBoundsOfBoxes(rectToBox(e), rectToBox(s))), getOverlappingArea = (e, s) => {
255
+ let c = Math.max(0, Math.min(e.x + e.width, s.x + s.width) - Math.max(e.x, s.x)), l = Math.max(0, Math.min(e.y + e.height, s.y + s.height) - Math.max(e.y, s.y));
256
+ return Math.ceil(c * l);
257
+ }, isRectObject = (e) => isNumeric(e.width) && isNumeric(e.height) && isNumeric(e.x) && isNumeric(e.y), isNumeric = (e) => !isNaN(e) && isFinite(e), devWarn = (e, s) => {
258
+ process.env.NODE_ENV === "development" && console.warn(`[React Flow]: ${s} Help: https://reactflow.dev/error#${e}`);
259
+ }, snapPosition = (e, s = [1, 1]) => ({
260
+ x: s[0] * Math.round(e.x / s[0]),
261
+ y: s[1] * Math.round(e.y / s[1])
262
+ }), pointToRendererPoint = ({ x: e, y: s }, [c, l, u], d = !1, f = [1, 1]) => {
263
+ let p = {
264
+ x: (e - c) / u,
265
+ y: (s - l) / u
267
266
  };
268
- return a ? G(s, o) : s;
269
- }, ie = ({ x: e, y: t }, [n, r, i]) => ({
270
- x: e * i + n,
271
- y: t * i + r
267
+ return d ? snapPosition(p, f) : p;
268
+ }, rendererPointToPoint = ({ x: e, y: s }, [c, l, u]) => ({
269
+ x: e * u + c,
270
+ y: s * u + l
272
271
  });
273
- function K(e, t) {
274
- if (typeof e == "number") return Math.floor((t - t / (1 + e)) * .5);
272
+ function parsePadding(e, s) {
273
+ if (typeof e == "number") return Math.floor((s - s / (1 + e)) * .5);
275
274
  if (typeof e == "string" && e.endsWith("px")) {
276
- let t = parseFloat(e);
277
- if (!Number.isNaN(t)) return Math.floor(t);
275
+ let s = parseFloat(e);
276
+ if (!Number.isNaN(s)) return Math.floor(s);
278
277
  }
279
278
  if (typeof e == "string" && e.endsWith("%")) {
280
- let n = parseFloat(e);
281
- if (!Number.isNaN(n)) return Math.floor(t * n * .01);
279
+ let c = parseFloat(e);
280
+ if (!Number.isNaN(c)) return Math.floor(s * c * .01);
282
281
  }
283
282
  return console.error(`[React Flow] The padding value "${e}" is invalid. Please provide a number or a string with a valid unit (px or %).`), 0;
284
283
  }
285
- function ae(e, t, n) {
284
+ function parsePaddings(e, s, c) {
286
285
  if (typeof e == "string" || typeof e == "number") {
287
- let r = K(e, n), i = K(e, t);
286
+ let l = parsePadding(e, c), u = parsePadding(e, s);
288
287
  return {
289
- top: r,
290
- right: i,
291
- bottom: r,
292
- left: i,
293
- x: i * 2,
294
- y: r * 2
288
+ top: l,
289
+ right: u,
290
+ bottom: l,
291
+ left: u,
292
+ x: u * 2,
293
+ y: l * 2
295
294
  };
296
295
  }
297
296
  if (typeof e == "object") {
298
- let r = K(e.top ?? e.y ?? 0, n), i = K(e.bottom ?? e.y ?? 0, n), a = K(e.left ?? e.x ?? 0, t), o = K(e.right ?? e.x ?? 0, t);
297
+ let l = parsePadding(e.top ?? e.y ?? 0, c), u = parsePadding(e.bottom ?? e.y ?? 0, c), d = parsePadding(e.left ?? e.x ?? 0, s), f = parsePadding(e.right ?? e.x ?? 0, s);
299
298
  return {
300
- top: r,
301
- right: o,
302
- bottom: i,
303
- left: a,
304
- x: a + o,
305
- y: r + i
299
+ top: l,
300
+ right: f,
301
+ bottom: u,
302
+ left: d,
303
+ x: d + f,
304
+ y: l + u
306
305
  };
307
306
  }
308
307
  return {
@@ -314,1197 +313,1197 @@ function ae(e, t, n) {
314
313
  y: 0
315
314
  };
316
315
  }
317
- function oe(e, t, n, r, i, a) {
318
- let { x: o, y: s } = ie(e, [
319
- t,
320
- n,
321
- r
322
- ]), { x: c, y: l } = ie({
316
+ function calculateAppliedPaddings(e, s, c, l, u, d) {
317
+ let { x: f, y: p } = rendererPointToPoint(e, [
318
+ s,
319
+ c,
320
+ l
321
+ ]), { x: m, y: h } = rendererPointToPoint({
323
322
  x: e.x + e.width,
324
323
  y: e.y + e.height
325
324
  }, [
326
- t,
327
- n,
328
- r
329
- ]), u = i - c, d = a - l;
325
+ s,
326
+ c,
327
+ l
328
+ ]), g = u - m, _ = d - h;
330
329
  return {
331
- left: Math.floor(o),
332
- top: Math.floor(s),
333
- right: Math.floor(u),
334
- bottom: Math.floor(d)
330
+ left: Math.floor(f),
331
+ top: Math.floor(p),
332
+ right: Math.floor(g),
333
+ bottom: Math.floor(_)
335
334
  };
336
335
  }
337
- var se = (e, t, n, r, i, a) => {
338
- let o = ae(a, t, n), s = (t - o.x) / e.width, c = (n - o.y) / e.height, l = N(Math.min(s, c), r, i), u = e.x + e.width / 2, d = e.y + e.height / 2, f = t / 2 - u * l, p = n / 2 - d * l, m = oe(e, f, p, l, t, n), h = {
339
- left: Math.min(m.left - o.left, 0),
340
- top: Math.min(m.top - o.top, 0),
341
- right: Math.min(m.right - o.right, 0),
342
- bottom: Math.min(m.bottom - o.bottom, 0)
336
+ var getViewportForBounds = (e, s, c, l, u, d) => {
337
+ let f = parsePaddings(d, s, c), p = (s - f.x) / e.width, m = (c - f.y) / e.height, h = clamp(Math.min(p, m), l, u), g = e.x + e.width / 2, _ = e.y + e.height / 2, v = s / 2 - g * h, y = c / 2 - _ * h, b = calculateAppliedPaddings(e, v, y, h, s, c), x = {
338
+ left: Math.min(b.left - f.left, 0),
339
+ top: Math.min(b.top - f.top, 0),
340
+ right: Math.min(b.right - f.right, 0),
341
+ bottom: Math.min(b.bottom - f.bottom, 0)
343
342
  };
344
343
  return {
345
- x: f - h.left + h.right,
346
- y: p - h.top + h.bottom,
347
- zoom: l
344
+ x: v - x.left + x.right,
345
+ y: y - x.top + x.bottom,
346
+ zoom: h
348
347
  };
349
- }, ce = () => typeof navigator < "u" && navigator?.userAgent?.indexOf("Mac") >= 0;
350
- function q(e) {
348
+ }, isMacOs = () => typeof navigator < "u" && navigator?.userAgent?.indexOf("Mac") >= 0;
349
+ function isCoordinateExtent(e) {
351
350
  return e != null && e !== "parent";
352
351
  }
353
- function J(e) {
352
+ function getNodeDimensions(e) {
354
353
  return {
355
354
  width: e.measured?.width ?? e.width ?? e.initialWidth ?? 0,
356
355
  height: e.measured?.height ?? e.height ?? e.initialHeight ?? 0
357
356
  };
358
357
  }
359
- function le(e) {
358
+ function nodeHasDimensions(e) {
360
359
  return (e.measured?.width ?? e.width ?? e.initialWidth) !== void 0 && (e.measured?.height ?? e.height ?? e.initialHeight) !== void 0;
361
360
  }
362
- function ue(e, t = {
361
+ function evaluateAbsolutePosition(e, s = {
363
362
  width: 0,
364
363
  height: 0
365
- }, n, r, i) {
366
- let a = { ...e }, o = r.get(n);
367
- if (o) {
368
- let e = o.origin || i;
369
- a.x += o.internals.positionAbsolute.x - (t.width ?? 0) * e[0], a.y += o.internals.positionAbsolute.y - (t.height ?? 0) * e[1];
364
+ }, c, l, u) {
365
+ let d = { ...e }, f = l.get(c);
366
+ if (f) {
367
+ let e = f.origin || u;
368
+ d.x += f.internals.positionAbsolute.x - (s.width ?? 0) * e[0], d.y += f.internals.positionAbsolute.y - (s.height ?? 0) * e[1];
370
369
  }
371
- return a;
370
+ return d;
372
371
  }
373
- function de(e, t) {
374
- if (e.size !== t.size) return !1;
375
- for (let n of e) if (!t.has(n)) return !1;
372
+ function areSetsEqual(e, s) {
373
+ if (e.size !== s.size) return !1;
374
+ for (let c of e) if (!s.has(c)) return !1;
376
375
  return !0;
377
376
  }
378
- function fe() {
379
- let e, t;
377
+ function withResolvers() {
378
+ let e, s;
380
379
  return {
381
- promise: new Promise((n, r) => {
382
- e = n, t = r;
380
+ promise: new Promise((c, l) => {
381
+ e = c, s = l;
383
382
  }),
384
383
  resolve: e,
385
- reject: t
384
+ reject: s
386
385
  };
387
386
  }
388
- function pe(e) {
387
+ function mergeAriaLabelConfig(e) {
389
388
  return {
390
- ...d,
389
+ ...defaultAriaLabelConfig,
391
390
  ...e || {}
392
391
  };
393
392
  }
394
- function me(e, { snapGrid: t = [0, 0], snapToGrid: n = !1, transform: r, containerBounds: i }) {
395
- let { x: a, y: o } = Y(e), s = re({
396
- x: a - (i?.left ?? 0),
397
- y: o - (i?.top ?? 0)
398
- }, r), { x: c, y: l } = n ? G(s, t) : s;
393
+ function getPointerPosition(e, { snapGrid: s = [0, 0], snapToGrid: c = !1, transform: l, containerBounds: u }) {
394
+ let { x: d, y: f } = getEventPosition(e), p = pointToRendererPoint({
395
+ x: d - (u?.left ?? 0),
396
+ y: f - (u?.top ?? 0)
397
+ }, l), { x: m, y: h } = c ? snapPosition(p, s) : p;
399
398
  return {
400
- xSnapped: c,
401
- ySnapped: l,
402
- ...s
399
+ xSnapped: m,
400
+ ySnapped: h,
401
+ ...p
403
402
  };
404
403
  }
405
- var he = (e) => ({
404
+ var getDimensions = (e) => ({
406
405
  width: e.offsetWidth,
407
406
  height: e.offsetHeight
408
- }), ge = (e) => e?.getRootNode?.() || window?.document, _e = [
407
+ }), getHostForElement = (e) => e?.getRootNode?.() || window?.document, inputTags = [
409
408
  "INPUT",
410
409
  "SELECT",
411
410
  "TEXTAREA"
412
411
  ];
413
- function ve(e) {
414
- let t = e.composedPath?.()?.[0] || e.target;
415
- return t?.nodeType === 1 ? _e.includes(t.nodeName) || t.hasAttribute("contenteditable") || !!t.closest(".nokey") : !1;
412
+ function isInputDOMNode(e) {
413
+ let s = e.composedPath?.()?.[0] || e.target;
414
+ return s?.nodeType === 1 ? inputTags.includes(s.nodeName) || s.hasAttribute("contenteditable") || !!s.closest(".nokey") : !1;
416
415
  }
417
- var ye = (e) => "clientX" in e, Y = (e, t) => {
418
- let n = ye(e), r = n ? e.clientX : e.touches?.[0].clientX, i = n ? e.clientY : e.touches?.[0].clientY;
416
+ var isMouseEvent = (e) => "clientX" in e, getEventPosition = (e, s) => {
417
+ let c = isMouseEvent(e), l = c ? e.clientX : e.touches?.[0].clientX, u = c ? e.clientY : e.touches?.[0].clientY;
419
418
  return {
420
- x: r - (t?.left ?? 0),
421
- y: i - (t?.top ?? 0)
419
+ x: l - (s?.left ?? 0),
420
+ y: u - (s?.top ?? 0)
422
421
  };
423
- }, be = (e, t, n, r, i) => {
424
- let a = t.querySelectorAll(`.${e}`);
425
- return !a || !a.length ? null : Array.from(a).map((t) => {
426
- let a = t.getBoundingClientRect();
422
+ }, getHandleBounds = (e, s, c, l, u) => {
423
+ let d = s.querySelectorAll(`.${e}`);
424
+ return !d || !d.length ? null : Array.from(d).map((s) => {
425
+ let d = s.getBoundingClientRect();
427
426
  return {
428
- id: t.getAttribute("data-handleid"),
427
+ id: s.getAttribute("data-handleid"),
429
428
  type: e,
430
- nodeId: i,
431
- position: t.getAttribute("data-handlepos"),
432
- x: (a.left - n.left) / r,
433
- y: (a.top - n.top) / r,
434
- ...he(t)
429
+ nodeId: u,
430
+ position: s.getAttribute("data-handlepos"),
431
+ x: (d.left - c.left) / l,
432
+ y: (d.top - c.top) / l,
433
+ ...getDimensions(s)
435
434
  };
436
435
  });
437
436
  };
438
- function xe({ sourceX: e, sourceY: t, targetX: n, targetY: r, sourceControlX: i, sourceControlY: a, targetControlX: o, targetControlY: s }) {
439
- let c = e * .125 + i * .375 + o * .375 + n * .125, l = t * .125 + a * .375 + s * .375 + r * .125;
437
+ function getBezierEdgeCenter({ sourceX: e, sourceY: s, targetX: c, targetY: l, sourceControlX: u, sourceControlY: d, targetControlX: f, targetControlY: p }) {
438
+ let m = e * .125 + u * .375 + f * .375 + c * .125, h = s * .125 + d * .375 + p * .375 + l * .125;
440
439
  return [
441
- c,
442
- l,
443
- Math.abs(c - e),
444
- Math.abs(l - t)
440
+ m,
441
+ h,
442
+ Math.abs(m - e),
443
+ Math.abs(h - s)
445
444
  ];
446
445
  }
447
- function Se(e, t) {
448
- return e >= 0 ? .5 * e : t * 25 * Math.sqrt(-e);
446
+ function calculateControlOffset(e, s) {
447
+ return e >= 0 ? .5 * e : s * 25 * Math.sqrt(-e);
449
448
  }
450
- function Ce({ pos: e, x1: t, y1: n, x2: r, y2: i, c: a }) {
449
+ function getControlWithCurvature({ pos: e, x1: s, y1: c, x2: l, y2: u, c: d }) {
451
450
  switch (e) {
452
- case v.Left: return [t - Se(t - r, a), n];
453
- case v.Right: return [t + Se(r - t, a), n];
454
- case v.Top: return [t, n - Se(n - i, a)];
455
- case v.Bottom: return [t, n + Se(i - n, a)];
451
+ case Position.Left: return [s - calculateControlOffset(s - l, d), c];
452
+ case Position.Right: return [s + calculateControlOffset(l - s, d), c];
453
+ case Position.Top: return [s, c - calculateControlOffset(c - u, d)];
454
+ case Position.Bottom: return [s, c + calculateControlOffset(u - c, d)];
456
455
  }
457
456
  }
458
- function we({ sourceX: e, sourceY: t, sourcePosition: n = v.Bottom, targetX: r, targetY: i, targetPosition: a = v.Top, curvature: o = .25 }) {
459
- let [s, c] = Ce({
460
- pos: n,
457
+ function getBezierPath({ sourceX: e, sourceY: s, sourcePosition: c = Position.Bottom, targetX: l, targetY: u, targetPosition: d = Position.Top, curvature: f = .25 }) {
458
+ let [p, m] = getControlWithCurvature({
459
+ pos: c,
461
460
  x1: e,
462
- y1: t,
463
- x2: r,
464
- y2: i,
465
- c: o
466
- }), [l, u] = Ce({
467
- pos: a,
468
- x1: r,
469
- y1: i,
461
+ y1: s,
462
+ x2: l,
463
+ y2: u,
464
+ c: f
465
+ }), [h, g] = getControlWithCurvature({
466
+ pos: d,
467
+ x1: l,
468
+ y1: u,
470
469
  x2: e,
471
- y2: t,
472
- c: o
473
- }), [d, f, p, m] = xe({
470
+ y2: s,
471
+ c: f
472
+ }), [_, v, y, b] = getBezierEdgeCenter({
474
473
  sourceX: e,
475
- sourceY: t,
476
- targetX: r,
477
- targetY: i,
478
- sourceControlX: s,
479
- sourceControlY: c,
480
- targetControlX: l,
481
- targetControlY: u
474
+ sourceY: s,
475
+ targetX: l,
476
+ targetY: u,
477
+ sourceControlX: p,
478
+ sourceControlY: m,
479
+ targetControlX: h,
480
+ targetControlY: g
482
481
  });
483
482
  return [
484
- `M${e},${t} C${s},${c} ${l},${u} ${r},${i}`,
485
- d,
486
- f,
487
- p,
488
- m
483
+ `M${e},${s} C${p},${m} ${h},${g} ${l},${u}`,
484
+ _,
485
+ v,
486
+ y,
487
+ b
489
488
  ];
490
489
  }
491
- function Te({ sourceX: e, sourceY: t, targetX: n, targetY: r }) {
492
- let i = Math.abs(n - e) / 2, a = n < e ? n + i : n - i, o = Math.abs(r - t) / 2;
490
+ function getEdgeCenter({ sourceX: e, sourceY: s, targetX: c, targetY: l }) {
491
+ let u = Math.abs(c - e) / 2, d = c < e ? c + u : c - u, f = Math.abs(l - s) / 2;
493
492
  return [
494
- a,
495
- r < t ? r + o : r - o,
496
- i,
497
- o
493
+ d,
494
+ l < s ? l + f : l - f,
495
+ u,
496
+ f
498
497
  ];
499
498
  }
500
- function Ee({ sourceNode: e, targetNode: t, selected: n = !1, zIndex: r = 0, elevateOnSelect: i = !1, zIndexMode: a = "basic" }) {
501
- return a === "manual" ? r : (i && n ? r + 1e3 : r) + Math.max(e.parentId || i && e.selected ? e.internals.z : 0, t.parentId || i && t.selected ? t.internals.z : 0);
502
- }
503
- function De({ sourceNode: e, targetNode: t, width: n, height: r, transform: i }) {
504
- let a = te(ne(e), ne(t));
505
- return a.x === a.x2 && (a.x2 += 1), a.y === a.y2 && (a.y2 += 1), V({
506
- x: -i[0] / i[2],
507
- y: -i[1] / i[2],
508
- width: n / i[2],
509
- height: r / i[2]
510
- }, R(a)) > 0;
511
- }
512
- var Oe = ({ source: e, sourceHandle: t, target: n, targetHandle: r }) => `xy-edge__${e}${t || ""}-${n}${r || ""}`, ke = (e, t) => t.some((t) => t.source === e.source && t.target === e.target && (t.sourceHandle === e.sourceHandle || !t.sourceHandle && !e.sourceHandle) && (t.targetHandle === e.targetHandle || !t.targetHandle && !e.targetHandle)), Ae = (e, t, n = {}) => {
513
- if (!e.source || !e.target) return W("006", c.error006()), t;
514
- let r = n.getEdgeId || Oe, i;
515
- return i = x(e) ? { ...e } : {
499
+ function getElevatedEdgeZIndex({ sourceNode: e, targetNode: s, selected: c = !1, zIndex: l = 0, elevateOnSelect: u = !1, zIndexMode: d = "basic" }) {
500
+ return d === "manual" ? l : (u && c ? l + 1e3 : l) + Math.max(e.parentId || u && e.selected ? e.internals.z : 0, s.parentId || u && s.selected ? s.internals.z : 0);
501
+ }
502
+ function isEdgeVisible({ sourceNode: e, targetNode: s, width: c, height: l, transform: u }) {
503
+ let d = getBoundsOfBoxes(nodeToBox(e), nodeToBox(s));
504
+ return d.x === d.x2 && (d.x2 += 1), d.y === d.y2 && (d.y2 += 1), getOverlappingArea({
505
+ x: -u[0] / u[2],
506
+ y: -u[1] / u[2],
507
+ width: c / u[2],
508
+ height: l / u[2]
509
+ }, boxToRect(d)) > 0;
510
+ }
511
+ var getEdgeId = ({ source: e, sourceHandle: s, target: c, targetHandle: l }) => `xy-edge__${e}${s || ""}-${c}${l || ""}`, connectionExists = (e, s) => s.some((s) => s.source === e.source && s.target === e.target && (s.sourceHandle === e.sourceHandle || !s.sourceHandle && !e.sourceHandle) && (s.targetHandle === e.targetHandle || !s.targetHandle && !e.targetHandle)), addEdge = (e, s, c = {}) => {
512
+ if (!e.source || !e.target) return devWarn("006", errorMessages.error006()), s;
513
+ let l = c.getEdgeId || getEdgeId, u;
514
+ return u = isEdgeBase(e) ? { ...e } : {
516
515
  ...e,
517
- id: r(e)
518
- }, ke(i, t) ? t : (i.sourceHandle === null && delete i.sourceHandle, i.targetHandle === null && delete i.targetHandle, t.concat(i));
516
+ id: l(e)
517
+ }, connectionExists(u, s) ? s : (u.sourceHandle === null && delete u.sourceHandle, u.targetHandle === null && delete u.targetHandle, s.concat(u));
519
518
  };
520
- function je({ sourceX: e, sourceY: t, targetX: n, targetY: r }) {
521
- let [i, a, o, s] = Te({
519
+ function getStraightPath({ sourceX: e, sourceY: s, targetX: c, targetY: l }) {
520
+ let [u, d, f, p] = getEdgeCenter({
522
521
  sourceX: e,
523
- sourceY: t,
524
- targetX: n,
525
- targetY: r
522
+ sourceY: s,
523
+ targetX: c,
524
+ targetY: l
526
525
  });
527
526
  return [
528
- `M ${e},${t}L ${n},${r}`,
529
- i,
530
- a,
531
- o,
532
- s
527
+ `M ${e},${s}L ${c},${l}`,
528
+ u,
529
+ d,
530
+ f,
531
+ p
533
532
  ];
534
533
  }
535
- var Me = {
536
- [v.Left]: {
534
+ var handleDirections = {
535
+ [Position.Left]: {
537
536
  x: -1,
538
537
  y: 0
539
538
  },
540
- [v.Right]: {
539
+ [Position.Right]: {
541
540
  x: 1,
542
541
  y: 0
543
542
  },
544
- [v.Top]: {
543
+ [Position.Top]: {
545
544
  x: 0,
546
545
  y: -1
547
546
  },
548
- [v.Bottom]: {
547
+ [Position.Bottom]: {
549
548
  x: 0,
550
549
  y: 1
551
550
  }
552
- }, Ne = ({ source: e, sourcePosition: t = v.Bottom, target: n }) => t === v.Left || t === v.Right ? e.x < n.x ? {
551
+ }, getDirection = ({ source: e, sourcePosition: s = Position.Bottom, target: c }) => s === Position.Left || s === Position.Right ? e.x < c.x ? {
553
552
  x: 1,
554
553
  y: 0
555
554
  } : {
556
555
  x: -1,
557
556
  y: 0
558
- } : e.y < n.y ? {
557
+ } : e.y < c.y ? {
559
558
  x: 0,
560
559
  y: 1
561
560
  } : {
562
561
  x: 0,
563
562
  y: -1
564
- }, Pe = (e, t) => Math.sqrt((t.x - e.x) ** 2 + (t.y - e.y) ** 2);
565
- function Fe({ source: e, sourcePosition: t = v.Bottom, target: n, targetPosition: r = v.Top, center: i, offset: a, stepPosition: o }) {
566
- let s = Me[t], c = Me[r], l = {
567
- x: e.x + s.x * a,
568
- y: e.y + s.y * a
569
- }, u = {
570
- x: n.x + c.x * a,
571
- y: n.y + c.y * a
572
- }, d = Ne({
573
- source: l,
574
- sourcePosition: t,
575
- target: u
576
- }), f = d.x === 0 ? "y" : "x", p = d[f], m = [], h, g, _ = {
563
+ }, distance = (e, s) => Math.sqrt((s.x - e.x) ** 2 + (s.y - e.y) ** 2);
564
+ function getPoints({ source: e, sourcePosition: s = Position.Bottom, target: c, targetPosition: l = Position.Top, center: u, offset: d, stepPosition: f }) {
565
+ let p = handleDirections[s], m = handleDirections[l], h = {
566
+ x: e.x + p.x * d,
567
+ y: e.y + p.y * d
568
+ }, g = {
569
+ x: c.x + m.x * d,
570
+ y: c.y + m.y * d
571
+ }, _ = getDirection({
572
+ source: h,
573
+ sourcePosition: s,
574
+ target: g
575
+ }), v = _.x === 0 ? "y" : "x", y = _[v], b = [], x, S, C = {
577
576
  x: 0,
578
577
  y: 0
579
- }, y = {
578
+ }, T = {
580
579
  x: 0,
581
580
  y: 0
582
- }, [, , b, x] = Te({
581
+ }, [, , E, D] = getEdgeCenter({
583
582
  sourceX: e.x,
584
583
  sourceY: e.y,
585
- targetX: n.x,
586
- targetY: n.y
584
+ targetX: c.x,
585
+ targetY: c.y
587
586
  });
588
- if (s[f] * c[f] === -1) {
589
- f === "x" ? (h = i.x ?? l.x + (u.x - l.x) * o, g = i.y ?? (l.y + u.y) / 2) : (h = i.x ?? (l.x + u.x) / 2, g = i.y ?? l.y + (u.y - l.y) * o);
587
+ if (p[v] * m[v] === -1) {
588
+ v === "x" ? (x = u.x ?? h.x + (g.x - h.x) * f, S = u.y ?? (h.y + g.y) / 2) : (x = u.x ?? (h.x + g.x) / 2, S = u.y ?? h.y + (g.y - h.y) * f);
590
589
  let e = [{
591
- x: h,
592
- y: l.y
590
+ x,
591
+ y: h.y
593
592
  }, {
594
- x: h,
595
- y: u.y
596
- }], t = [{
597
- x: l.x,
598
- y: g
593
+ x,
594
+ y: g.y
595
+ }], s = [{
596
+ x: h.x,
597
+ y: S
599
598
  }, {
600
- x: u.x,
601
- y: g
599
+ x: g.x,
600
+ y: S
602
601
  }];
603
- m = s[f] === p ? f === "x" ? e : t : f === "x" ? t : e;
602
+ b = p[v] === y ? v === "x" ? e : s : v === "x" ? s : e;
604
603
  } else {
605
- let i = [{
606
- x: l.x,
607
- y: u.y
608
- }], o = [{
609
- x: u.x,
610
- y: l.y
604
+ let u = [{
605
+ x: h.x,
606
+ y: g.y
607
+ }], f = [{
608
+ x: g.x,
609
+ y: h.y
611
610
  }];
612
- if (m = f === "x" ? s.x === p ? o : i : s.y === p ? i : o, t === r) {
613
- let t = Math.abs(e[f] - n[f]);
614
- if (t <= a) {
615
- let r = Math.min(a - 1, a - t);
616
- s[f] === p ? _[f] = (l[f] > e[f] ? -1 : 1) * r : y[f] = (u[f] > n[f] ? -1 : 1) * r;
611
+ if (b = v === "x" ? p.x === y ? f : u : p.y === y ? u : f, s === l) {
612
+ let s = Math.abs(e[v] - c[v]);
613
+ if (s <= d) {
614
+ let l = Math.min(d - 1, d - s);
615
+ p[v] === y ? C[v] = (h[v] > e[v] ? -1 : 1) * l : T[v] = (g[v] > c[v] ? -1 : 1) * l;
617
616
  }
618
617
  }
619
- if (t !== r) {
620
- let e = f === "x" ? "y" : "x", t = s[f] === c[e], n = l[e] > u[e], r = l[e] < u[e];
621
- (s[f] === 1 && (!t && n || t && r) || s[f] !== 1 && (!t && r || t && n)) && (m = f === "x" ? i : o);
618
+ if (s !== l) {
619
+ let e = v === "x" ? "y" : "x", s = p[v] === m[e], c = h[e] > g[e], l = h[e] < g[e];
620
+ (p[v] === 1 && (!s && c || s && l) || p[v] !== 1 && (!s && l || s && c)) && (b = v === "x" ? u : f);
622
621
  }
623
- let d = {
624
- x: l.x + _.x,
625
- y: l.y + _.y
626
- }, v = {
627
- x: u.x + y.x,
628
- y: u.y + y.y
622
+ let _ = {
623
+ x: h.x + C.x,
624
+ y: h.y + C.y
625
+ }, w = {
626
+ x: g.x + T.x,
627
+ y: g.y + T.y
629
628
  };
630
- Math.max(Math.abs(d.x - m[0].x), Math.abs(v.x - m[0].x)) >= Math.max(Math.abs(d.y - m[0].y), Math.abs(v.y - m[0].y)) ? (h = (d.x + v.x) / 2, g = m[0].y) : (h = m[0].x, g = (d.y + v.y) / 2);
629
+ Math.max(Math.abs(_.x - b[0].x), Math.abs(w.x - b[0].x)) >= Math.max(Math.abs(_.y - b[0].y), Math.abs(w.y - b[0].y)) ? (x = (_.x + w.x) / 2, S = b[0].y) : (x = b[0].x, S = (_.y + w.y) / 2);
631
630
  }
632
- let S = {
633
- x: l.x + _.x,
634
- y: l.y + _.y
635
- }, C = {
636
- x: u.x + y.x,
637
- y: u.y + y.y
631
+ let O = {
632
+ x: h.x + C.x,
633
+ y: h.y + C.y
634
+ }, k = {
635
+ x: g.x + T.x,
636
+ y: g.y + T.y
638
637
  };
639
638
  return [
640
639
  [
641
640
  e,
642
- ...S.x !== m[0].x || S.y !== m[0].y ? [S] : [],
643
- ...m,
644
- ...C.x !== m[m.length - 1].x || C.y !== m[m.length - 1].y ? [C] : [],
645
- n
641
+ ...O.x !== b[0].x || O.y !== b[0].y ? [O] : [],
642
+ ...b,
643
+ ...k.x !== b[b.length - 1].x || k.y !== b[b.length - 1].y ? [k] : [],
644
+ c
646
645
  ],
647
- h,
648
- g,
649
- b,
650
- x
646
+ x,
647
+ S,
648
+ E,
649
+ D
651
650
  ];
652
651
  }
653
- function Ie(e, t, n, r) {
654
- let i = Math.min(Pe(e, t) / 2, Pe(t, n) / 2, r), { x: a, y: o } = t;
655
- if (e.x === a && a === n.x || e.y === o && o === n.y) return `L${a} ${o}`;
656
- if (e.y === o) {
657
- let t = e.x < n.x ? -1 : 1, r = e.y < n.y ? 1 : -1;
658
- return `L ${a + i * t},${o}Q ${a},${o} ${a},${o + i * r}`;
652
+ function getBend(e, s, c, l) {
653
+ let u = Math.min(distance(e, s) / 2, distance(s, c) / 2, l), { x: d, y: f } = s;
654
+ if (e.x === d && d === c.x || e.y === f && f === c.y) return `L${d} ${f}`;
655
+ if (e.y === f) {
656
+ let s = e.x < c.x ? -1 : 1, l = e.y < c.y ? 1 : -1;
657
+ return `L ${d + u * s},${f}Q ${d},${f} ${d},${f + u * l}`;
659
658
  }
660
- let s = e.x < n.x ? 1 : -1;
661
- return `L ${a},${o + i * (e.y < n.y ? -1 : 1)}Q ${a},${o} ${a + i * s},${o}`;
659
+ let p = e.x < c.x ? 1 : -1;
660
+ return `L ${d},${f + u * (e.y < c.y ? -1 : 1)}Q ${d},${f} ${d + u * p},${f}`;
662
661
  }
663
- function Le({ sourceX: e, sourceY: t, sourcePosition: n = v.Bottom, targetX: r, targetY: i, targetPosition: a = v.Top, borderRadius: o = 5, centerX: s, centerY: c, offset: l = 20, stepPosition: u = .5 }) {
664
- let [d, f, p, m, h] = Fe({
662
+ function getSmoothStepPath({ sourceX: e, sourceY: s, sourcePosition: c = Position.Bottom, targetX: l, targetY: u, targetPosition: d = Position.Top, borderRadius: f = 5, centerX: p, centerY: m, offset: h = 20, stepPosition: g = .5 }) {
663
+ let [_, v, y, b, x] = getPoints({
665
664
  source: {
666
665
  x: e,
667
- y: t
666
+ y: s
668
667
  },
669
- sourcePosition: n,
668
+ sourcePosition: c,
670
669
  target: {
671
- x: r,
672
- y: i
670
+ x: l,
671
+ y: u
673
672
  },
674
- targetPosition: a,
673
+ targetPosition: d,
675
674
  center: {
676
- x: s,
677
- y: c
675
+ x: p,
676
+ y: m
678
677
  },
679
- offset: l,
680
- stepPosition: u
681
- }), g = `M${d[0].x} ${d[0].y}`;
682
- for (let e = 1; e < d.length - 1; e++) g += Ie(d[e - 1], d[e], d[e + 1], o);
683
- return g += `L${d[d.length - 1].x} ${d[d.length - 1].y}`, [
684
- g,
685
- f,
686
- p,
687
- m,
688
- h
678
+ offset: h,
679
+ stepPosition: g
680
+ }), S = `M${_[0].x} ${_[0].y}`;
681
+ for (let e = 1; e < _.length - 1; e++) S += getBend(_[e - 1], _[e], _[e + 1], f);
682
+ return S += `L${_[_.length - 1].x} ${_[_.length - 1].y}`, [
683
+ S,
684
+ v,
685
+ y,
686
+ b,
687
+ x
689
688
  ];
690
689
  }
691
- function Re(e) {
690
+ function isNodeInitialized(e) {
692
691
  return e && !!(e.internals.handleBounds || e.handles?.length) && !!(e.measured.width || e.width || e.initialWidth);
693
692
  }
694
- function ze(e) {
695
- let { sourceNode: t, targetNode: n } = e;
696
- if (!Re(t) || !Re(n)) return null;
697
- let r = t.internals.handleBounds || Be(t.handles), i = n.internals.handleBounds || Be(n.handles), a = Ve(r?.source ?? [], e.sourceHandle), o = Ve(e.connectionMode === f.Strict ? i?.target ?? [] : (i?.target ?? []).concat(i?.source ?? []), e.targetHandle);
698
- if (!a || !o) return e.onError?.("008", c.error008(a ? "target" : "source", {
693
+ function getEdgePosition(e) {
694
+ let { sourceNode: s, targetNode: c } = e;
695
+ if (!isNodeInitialized(s) || !isNodeInitialized(c)) return null;
696
+ let l = s.internals.handleBounds || toHandleBounds(s.handles), u = c.internals.handleBounds || toHandleBounds(c.handles), d = getHandle$1(l?.source ?? [], e.sourceHandle), f = getHandle$1(e.connectionMode === ConnectionMode.Strict ? u?.target ?? [] : (u?.target ?? []).concat(u?.source ?? []), e.targetHandle);
697
+ if (!d || !f) return e.onError?.("008", errorMessages.error008(d ? "target" : "source", {
699
698
  id: e.id,
700
699
  sourceHandle: e.sourceHandle,
701
700
  targetHandle: e.targetHandle
702
701
  })), null;
703
- let s = a?.position || v.Bottom, l = o?.position || v.Top, u = X(t, a, s), d = X(n, o, l);
702
+ let p = d?.position || Position.Bottom, h = f?.position || Position.Top, g = getHandlePosition(s, d, p), _ = getHandlePosition(c, f, h);
704
703
  return {
705
- sourceX: u.x,
706
- sourceY: u.y,
707
- targetX: d.x,
708
- targetY: d.y,
709
- sourcePosition: s,
710
- targetPosition: l
704
+ sourceX: g.x,
705
+ sourceY: g.y,
706
+ targetX: _.x,
707
+ targetY: _.y,
708
+ sourcePosition: p,
709
+ targetPosition: h
711
710
  };
712
711
  }
713
- function Be(e) {
712
+ function toHandleBounds(e) {
714
713
  if (!e) return null;
715
- let t = [], n = [];
716
- for (let r of e) r.width = r.width ?? 1, r.height = r.height ?? 1, r.type === "source" ? t.push(r) : r.type === "target" && n.push(r);
714
+ let s = [], c = [];
715
+ for (let l of e) l.width = l.width ?? 1, l.height = l.height ?? 1, l.type === "source" ? s.push(l) : l.type === "target" && c.push(l);
717
716
  return {
718
- source: t,
719
- target: n
717
+ source: s,
718
+ target: c
720
719
  };
721
720
  }
722
- function X(e, t, n = v.Left, r = !1) {
723
- let i = (t?.x ?? 0) + e.internals.positionAbsolute.x, a = (t?.y ?? 0) + e.internals.positionAbsolute.y, { width: o, height: s } = t ?? J(e);
724
- if (r) return {
725
- x: i + o / 2,
726
- y: a + s / 2
721
+ function getHandlePosition(e, s, c = Position.Left, l = !1) {
722
+ let u = (s?.x ?? 0) + e.internals.positionAbsolute.x, d = (s?.y ?? 0) + e.internals.positionAbsolute.y, { width: f, height: p } = s ?? getNodeDimensions(e);
723
+ if (l) return {
724
+ x: u + f / 2,
725
+ y: d + p / 2
727
726
  };
728
- switch (t?.position ?? n) {
729
- case v.Top: return {
730
- x: i + o / 2,
731
- y: a
727
+ switch (s?.position ?? c) {
728
+ case Position.Top: return {
729
+ x: u + f / 2,
730
+ y: d
732
731
  };
733
- case v.Right: return {
734
- x: i + o,
735
- y: a + s / 2
732
+ case Position.Right: return {
733
+ x: u + f,
734
+ y: d + p / 2
736
735
  };
737
- case v.Bottom: return {
738
- x: i + o / 2,
739
- y: a + s
736
+ case Position.Bottom: return {
737
+ x: u + f / 2,
738
+ y: d + p
740
739
  };
741
- case v.Left: return {
742
- x: i,
743
- y: a + s / 2
740
+ case Position.Left: return {
741
+ x: u,
742
+ y: d + p / 2
744
743
  };
745
744
  }
746
745
  }
747
- function Ve(e, t) {
748
- return e && (t ? e.find((e) => e.id === t) : e[0]) || null;
749
- }
750
- function He(e, t) {
751
- return e ? typeof e == "string" ? e : `${t ? `${t}__` : ""}${Object.keys(e).sort().map((t) => `${t}=${e[t]}`).join("&")}` : "";
752
- }
753
- function Ue(e, { id: t, defaultColor: n, defaultMarkerStart: r, defaultMarkerEnd: i }) {
754
- let a = /* @__PURE__ */ new Set();
755
- return e.reduce((e, o) => ([o.markerStart || r, o.markerEnd || i].forEach((r) => {
756
- if (r && typeof r == "object") {
757
- let i = He(r, t);
758
- a.has(i) || (e.push({
759
- id: i,
760
- color: r.color || n,
761
- ...r
762
- }), a.add(i));
746
+ function getHandle$1(e, s) {
747
+ return e && (s ? e.find((e) => e.id === s) : e[0]) || null;
748
+ }
749
+ function getMarkerId(e, s) {
750
+ return e ? typeof e == "string" ? e : `${s ? `${s}__` : ""}${Object.keys(e).sort().map((s) => `${s}=${e[s]}`).join("&")}` : "";
751
+ }
752
+ function createMarkerIds(e, { id: s, defaultColor: c, defaultMarkerStart: l, defaultMarkerEnd: u }) {
753
+ let d = /* @__PURE__ */ new Set();
754
+ return e.reduce((e, f) => ([f.markerStart || l, f.markerEnd || u].forEach((l) => {
755
+ if (l && typeof l == "object") {
756
+ let u = getMarkerId(l, s);
757
+ d.has(u) || (e.push({
758
+ id: u,
759
+ color: l.color || c,
760
+ ...l
761
+ }), d.add(u));
763
762
  }
764
- }), e), []).sort((e, t) => e.id.localeCompare(t.id));
763
+ }), e), []).sort((e, s) => e.id.localeCompare(s.id));
765
764
  }
766
- var We = 1e3, Ge = 10, Ke = {
765
+ var SELECTED_NODE_Z = 1e3, ROOT_PARENT_Z_INCREMENT = 10, defaultOptions = {
767
766
  nodeOrigin: [0, 0],
768
- nodeExtent: l,
767
+ nodeExtent: infiniteExtent,
769
768
  elevateNodesOnSelect: !0,
770
769
  zIndexMode: "basic",
771
770
  defaults: {}
772
- }, qe = {
773
- ...Ke,
771
+ }, adoptUserNodesDefaultOptions = {
772
+ ...defaultOptions,
774
773
  checkEquality: !0
775
774
  };
776
- function Je(e, t) {
777
- let n = { ...e };
778
- for (let e in t) t[e] !== void 0 && (n[e] = t[e]);
779
- return n;
780
- }
781
- function Ye(e, t, n) {
782
- let r = Je(Ke, n);
783
- for (let n of e.values()) if (n.parentId) et(n, e, t, r);
775
+ function mergeObjects(e, s) {
776
+ let c = { ...e };
777
+ for (let e in s) s[e] !== void 0 && (c[e] = s[e]);
778
+ return c;
779
+ }
780
+ function updateAbsolutePositions(e, s, c) {
781
+ let l = mergeObjects(defaultOptions, c);
782
+ for (let c of e.values()) if (c.parentId) updateChildNode(c, e, s, l);
784
783
  else {
785
- let e = P(w(n, r.nodeOrigin), q(n.extent) ? n.extent : r.nodeExtent, J(n));
786
- n.internals.positionAbsolute = e;
784
+ let e = clampPosition(getNodePositionWithOrigin(c, l.nodeOrigin), isCoordinateExtent(c.extent) ? c.extent : l.nodeExtent, getNodeDimensions(c));
785
+ c.internals.positionAbsolute = e;
787
786
  }
788
787
  }
789
- function Xe(e, t) {
790
- if (!e.handles) return e.measured ? t?.internals.handleBounds : void 0;
791
- let n = [], r = [];
792
- for (let t of e.handles) {
793
- let i = {
794
- id: t.id,
795
- width: t.width ?? 1,
796
- height: t.height ?? 1,
788
+ function parseHandles(e, s) {
789
+ if (!e.handles) return e.measured ? s?.internals.handleBounds : void 0;
790
+ let c = [], l = [];
791
+ for (let s of e.handles) {
792
+ let u = {
793
+ id: s.id,
794
+ width: s.width ?? 1,
795
+ height: s.height ?? 1,
797
796
  nodeId: e.id,
798
- x: t.x,
799
- y: t.y,
800
- position: t.position,
801
- type: t.type
797
+ x: s.x,
798
+ y: s.y,
799
+ position: s.position,
800
+ type: s.type
802
801
  };
803
- t.type === "source" ? n.push(i) : t.type === "target" && r.push(i);
802
+ s.type === "source" ? c.push(u) : s.type === "target" && l.push(u);
804
803
  }
805
804
  return {
806
- source: n,
807
- target: r
805
+ source: c,
806
+ target: l
808
807
  };
809
808
  }
810
- function Ze(e) {
809
+ function isManualZIndexMode(e) {
811
810
  return e === "manual";
812
811
  }
813
- function Qe(e, t, n, r = {}) {
814
- let i = Je(qe, r), a = { i: 0 }, o = new Map(t), s = i?.elevateNodesOnSelect && !Ze(i.zIndexMode) ? We : 0, c = e.length > 0, l = !1;
815
- t.clear(), n.clear();
816
- for (let u of e) {
817
- let e = o.get(u.id);
818
- if (i.checkEquality && u === e?.internals.userNode) t.set(u.id, e);
812
+ function adoptUserNodes(e, s, c, l = {}) {
813
+ let u = mergeObjects(adoptUserNodesDefaultOptions, l), d = { i: 0 }, f = new Map(s), p = u?.elevateNodesOnSelect && !isManualZIndexMode(u.zIndexMode) ? SELECTED_NODE_Z : 0, m = e.length > 0, h = !1;
814
+ s.clear(), c.clear();
815
+ for (let g of e) {
816
+ let e = f.get(g.id);
817
+ if (u.checkEquality && g === e?.internals.userNode) s.set(g.id, e);
819
818
  else {
820
- let n = P(w(u, i.nodeOrigin), q(u.extent) ? u.extent : i.nodeExtent, J(u));
819
+ let c = clampPosition(getNodePositionWithOrigin(g, u.nodeOrigin), isCoordinateExtent(g.extent) ? g.extent : u.nodeExtent, getNodeDimensions(g));
821
820
  e = {
822
- ...i.defaults,
823
- ...u,
821
+ ...u.defaults,
822
+ ...g,
824
823
  measured: {
825
- width: u.measured?.width,
826
- height: u.measured?.height
824
+ width: g.measured?.width,
825
+ height: g.measured?.height
827
826
  },
828
827
  internals: {
829
- positionAbsolute: n,
830
- handleBounds: Xe(u, e),
831
- z: tt(u, s, i.zIndexMode),
832
- userNode: u
828
+ positionAbsolute: c,
829
+ handleBounds: parseHandles(g, e),
830
+ z: calculateZ(g, p, u.zIndexMode),
831
+ userNode: g
833
832
  }
834
- }, t.set(u.id, e);
833
+ }, s.set(g.id, e);
835
834
  }
836
- (e.measured === void 0 || e.measured.width === void 0 || e.measured.height === void 0) && !e.hidden && (c = !1), u.parentId && et(e, t, n, r, a), l ||= u.selected ?? !1;
835
+ (e.measured === void 0 || e.measured.width === void 0 || e.measured.height === void 0) && !e.hidden && (m = !1), g.parentId && updateChildNode(e, s, c, l, d), h ||= g.selected ?? !1;
837
836
  }
838
837
  return {
839
- nodesInitialized: c,
840
- hasSelectedNodes: l
838
+ nodesInitialized: m,
839
+ hasSelectedNodes: h
841
840
  };
842
841
  }
843
- function $e(e, t) {
842
+ function updateParentLookup(e, s) {
844
843
  if (!e.parentId) return;
845
- let n = t.get(e.parentId);
846
- n ? n.set(e.id, e) : t.set(e.parentId, new Map([[e.id, e]]));
844
+ let c = s.get(e.parentId);
845
+ c ? c.set(e.id, e) : s.set(e.parentId, new Map([[e.id, e]]));
847
846
  }
848
- function et(e, t, n, r, i) {
849
- let { elevateNodesOnSelect: a, nodeOrigin: o, nodeExtent: s, zIndexMode: c } = Je(Ke, r), l = e.parentId, u = t.get(l);
850
- if (!u) {
851
- console.warn(`Parent node ${l} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);
847
+ function updateChildNode(e, s, c, l, u) {
848
+ let { elevateNodesOnSelect: d, nodeOrigin: f, nodeExtent: p, zIndexMode: m } = mergeObjects(defaultOptions, l), h = e.parentId, g = s.get(h);
849
+ if (!g) {
850
+ console.warn(`Parent node ${h} not found. Please make sure that parent nodes are in front of their child nodes in the nodes array.`);
852
851
  return;
853
852
  }
854
- $e(e, n), i && !u.parentId && u.internals.rootParentIndex === void 0 && c === "auto" && (u.internals.rootParentIndex = ++i.i, u.internals.z = u.internals.z + i.i * Ge), i && u.internals.rootParentIndex !== void 0 && (i.i = u.internals.rootParentIndex);
855
- let { x: d, y: f, z: p } = nt(e, u, o, s, a && !Ze(c) ? We : 0, c), { positionAbsolute: m } = e.internals, h = d !== m.x || f !== m.y;
856
- (h || p !== e.internals.z) && t.set(e.id, {
853
+ updateParentLookup(e, c), u && !g.parentId && g.internals.rootParentIndex === void 0 && m === "auto" && (g.internals.rootParentIndex = ++u.i, g.internals.z = g.internals.z + u.i * ROOT_PARENT_Z_INCREMENT), u && g.internals.rootParentIndex !== void 0 && (u.i = g.internals.rootParentIndex);
854
+ let { x: _, y: v, z: y } = calculateChildXYZ(e, g, f, p, d && !isManualZIndexMode(m) ? SELECTED_NODE_Z : 0, m), { positionAbsolute: b } = e.internals, x = _ !== b.x || v !== b.y;
855
+ (x || y !== e.internals.z) && s.set(e.id, {
857
856
  ...e,
858
857
  internals: {
859
858
  ...e.internals,
860
- positionAbsolute: h ? {
861
- x: d,
862
- y: f
863
- } : m,
864
- z: p
859
+ positionAbsolute: x ? {
860
+ x: _,
861
+ y: v
862
+ } : b,
863
+ z: y
865
864
  }
866
865
  });
867
866
  }
868
- function tt(e, t, n) {
869
- let r = U(e.zIndex) ? e.zIndex : 0;
870
- return Ze(n) ? r : r + (e.selected ? t : 0);
871
- }
872
- function nt(e, t, n, r, i, a) {
873
- let { x: o, y: s } = t.internals.positionAbsolute, c = J(e), l = w(e, n), u = q(e.extent) ? P(l, e.extent, c) : l, d = P({
874
- x: o + u.x,
875
- y: s + u.y
876
- }, r, c);
877
- e.extent === "parent" && (d = F(d, c, t));
878
- let f = tt(e, i, a), p = t.internals.z ?? 0;
867
+ function calculateZ(e, s, c) {
868
+ let l = isNumeric(e.zIndex) ? e.zIndex : 0;
869
+ return isManualZIndexMode(c) ? l : l + (e.selected ? s : 0);
870
+ }
871
+ function calculateChildXYZ(e, s, c, l, u, d) {
872
+ let { x: f, y: p } = s.internals.positionAbsolute, m = getNodeDimensions(e), h = getNodePositionWithOrigin(e, c), g = isCoordinateExtent(e.extent) ? clampPosition(h, e.extent, m) : h, _ = clampPosition({
873
+ x: f + g.x,
874
+ y: p + g.y
875
+ }, l, m);
876
+ e.extent === "parent" && (_ = clampPositionToParent(_, m, s));
877
+ let v = calculateZ(e, u, d), y = s.internals.z ?? 0;
879
878
  return {
880
- x: d.x,
881
- y: d.y,
882
- z: p >= f ? p + 1 : f
879
+ x: _.x,
880
+ y: _.y,
881
+ z: y >= v ? y + 1 : v
883
882
  };
884
883
  }
885
- function rt(e, t, n, r = [0, 0]) {
886
- let i = [], a = /* @__PURE__ */ new Map();
887
- for (let n of e) {
888
- let e = t.get(n.parentId);
884
+ function handleExpandParent(e, s, c, l = [0, 0]) {
885
+ let u = [], d = /* @__PURE__ */ new Map();
886
+ for (let c of e) {
887
+ let e = s.get(c.parentId);
889
888
  if (!e) continue;
890
- let r = B(a.get(n.parentId)?.expandedRect ?? z(e), n.rect);
891
- a.set(n.parentId, {
892
- expandedRect: r,
889
+ let l = getBoundsOfRects(d.get(c.parentId)?.expandedRect ?? nodeToRect(e), c.rect);
890
+ d.set(c.parentId, {
891
+ expandedRect: l,
893
892
  parent: e
894
893
  });
895
894
  }
896
- return a.size > 0 && a.forEach(({ expandedRect: t, parent: a }, o) => {
897
- let s = a.internals.positionAbsolute, c = J(a), l = a.origin ?? r, u = t.x < s.x ? Math.round(Math.abs(s.x - t.x)) : 0, d = t.y < s.y ? Math.round(Math.abs(s.y - t.y)) : 0, f = Math.max(c.width, Math.round(t.width)), p = Math.max(c.height, Math.round(t.height)), m = (f - c.width) * l[0], h = (p - c.height) * l[1];
898
- (u > 0 || d > 0 || m || h) && (i.push({
899
- id: o,
895
+ return d.size > 0 && d.forEach(({ expandedRect: s, parent: d }, f) => {
896
+ let p = d.internals.positionAbsolute, m = getNodeDimensions(d), h = d.origin ?? l, g = s.x < p.x ? Math.round(Math.abs(p.x - s.x)) : 0, _ = s.y < p.y ? Math.round(Math.abs(p.y - s.y)) : 0, v = Math.max(m.width, Math.round(s.width)), y = Math.max(m.height, Math.round(s.height)), b = (v - m.width) * h[0], x = (y - m.height) * h[1];
897
+ (g > 0 || _ > 0 || b || x) && (u.push({
898
+ id: f,
900
899
  type: "position",
901
900
  position: {
902
- x: a.position.x - u + m,
903
- y: a.position.y - d + h
901
+ x: d.position.x - g + b,
902
+ y: d.position.y - _ + x
904
903
  }
905
- }), n.get(o)?.forEach((t) => {
906
- e.some((e) => e.id === t.id) || i.push({
907
- id: t.id,
904
+ }), c.get(f)?.forEach((s) => {
905
+ e.some((e) => e.id === s.id) || u.push({
906
+ id: s.id,
908
907
  type: "position",
909
908
  position: {
910
- x: t.position.x + u,
911
- y: t.position.y + d
909
+ x: s.position.x + g,
910
+ y: s.position.y + _
912
911
  }
913
912
  });
914
- })), (c.width < t.width || c.height < t.height || u || d) && i.push({
915
- id: o,
913
+ })), (m.width < s.width || m.height < s.height || g || _) && u.push({
914
+ id: f,
916
915
  type: "dimensions",
917
916
  setAttributes: !0,
918
917
  dimensions: {
919
- width: f + (u ? l[0] * u - m : 0),
920
- height: p + (d ? l[1] * d - h : 0)
918
+ width: v + (g ? h[0] * g - b : 0),
919
+ height: y + (_ ? h[1] * _ - x : 0)
921
920
  }
922
921
  });
923
- }), i;
922
+ }), u;
924
923
  }
925
- function it(e, t, n, r, i, a, o) {
926
- let s = r?.querySelector(".xyflow__viewport"), c = !1;
927
- if (!s) return {
924
+ function updateNodeInternals(e, s, c, l, u, d, f) {
925
+ let p = l?.querySelector(".xyflow__viewport"), m = !1;
926
+ if (!p) return {
928
927
  changes: [],
929
- updatedInternals: c
928
+ updatedInternals: m
930
929
  };
931
- let l = [], u = window.getComputedStyle(s), { m22: d } = new window.DOMMatrixReadOnly(u.transform), f = [];
932
- for (let r of e.values()) {
933
- let e = t.get(r.id);
930
+ let h = [], g = window.getComputedStyle(p), { m22: _ } = new window.DOMMatrixReadOnly(g.transform), v = [];
931
+ for (let l of e.values()) {
932
+ let e = s.get(l.id);
934
933
  if (!e) continue;
935
934
  if (e.hidden) {
936
- t.set(e.id, {
935
+ s.set(e.id, {
937
936
  ...e,
938
937
  internals: {
939
938
  ...e.internals,
940
939
  handleBounds: void 0
941
940
  }
942
- }), c = !0;
941
+ }), m = !0;
943
942
  continue;
944
943
  }
945
- let s = he(r.nodeElement), u = e.measured.width !== s.width || e.measured.height !== s.height;
946
- if (s.width && s.height && (u || !e.internals.handleBounds || r.force)) {
947
- let p = r.nodeElement.getBoundingClientRect(), m = q(e.extent) ? e.extent : a, { positionAbsolute: h } = e.internals;
948
- e.parentId && e.extent === "parent" ? h = F(h, s, t.get(e.parentId)) : m && (h = P(h, m, s));
949
- let g = {
944
+ let p = getDimensions(l.nodeElement), g = e.measured.width !== p.width || e.measured.height !== p.height;
945
+ if (p.width && p.height && (g || !e.internals.handleBounds || l.force)) {
946
+ let y = l.nodeElement.getBoundingClientRect(), b = isCoordinateExtent(e.extent) ? e.extent : d, { positionAbsolute: x } = e.internals;
947
+ e.parentId && e.extent === "parent" ? x = clampPositionToParent(x, p, s.get(e.parentId)) : b && (x = clampPosition(x, b, p));
948
+ let S = {
950
949
  ...e,
951
- measured: s,
950
+ measured: p,
952
951
  internals: {
953
952
  ...e.internals,
954
- positionAbsolute: h,
953
+ positionAbsolute: x,
955
954
  handleBounds: {
956
- source: be("source", r.nodeElement, p, d, e.id),
957
- target: be("target", r.nodeElement, p, d, e.id)
955
+ source: getHandleBounds("source", l.nodeElement, y, _, e.id),
956
+ target: getHandleBounds("target", l.nodeElement, y, _, e.id)
958
957
  }
959
958
  }
960
959
  };
961
- t.set(e.id, g), e.parentId && et(g, t, n, {
962
- nodeOrigin: i,
963
- zIndexMode: o
964
- }), c = !0, u && (l.push({
960
+ s.set(e.id, S), e.parentId && updateChildNode(S, s, c, {
961
+ nodeOrigin: u,
962
+ zIndexMode: f
963
+ }), m = !0, g && (h.push({
965
964
  id: e.id,
966
965
  type: "dimensions",
967
- dimensions: s
968
- }), e.expandParent && e.parentId && f.push({
966
+ dimensions: p
967
+ }), e.expandParent && e.parentId && v.push({
969
968
  id: e.id,
970
969
  parentId: e.parentId,
971
- rect: z(g, i)
970
+ rect: nodeToRect(S, u)
972
971
  }));
973
972
  }
974
973
  }
975
- if (f.length > 0) {
976
- let e = rt(f, t, n, i);
977
- l.push(...e);
974
+ if (v.length > 0) {
975
+ let e = handleExpandParent(v, s, c, u);
976
+ h.push(...e);
978
977
  }
979
978
  return {
980
- changes: l,
981
- updatedInternals: c
979
+ changes: h,
980
+ updatedInternals: m
982
981
  };
983
982
  }
984
- async function at({ delta: e, panZoom: t, transform: n, translateExtent: r, width: i, height: a }) {
985
- if (!t || !e.x && !e.y) return Promise.resolve(!1);
986
- let o = await t.setViewportConstrained({
987
- x: n[0] + e.x,
988
- y: n[1] + e.y,
989
- zoom: n[2]
990
- }, [[0, 0], [i, a]], r), s = !!o && (o.x !== n[0] || o.y !== n[1] || o.k !== n[2]);
991
- return Promise.resolve(s);
992
- }
993
- function ot(e, t, n, r, i, a) {
994
- let o = i, s = r.get(o) || /* @__PURE__ */ new Map();
995
- r.set(o, s.set(n, t)), o = `${i}-${e}`;
996
- let c = r.get(o) || /* @__PURE__ */ new Map();
997
- if (r.set(o, c.set(n, t)), a) {
998
- o = `${i}-${e}-${a}`;
999
- let s = r.get(o) || /* @__PURE__ */ new Map();
1000
- r.set(o, s.set(n, t));
983
+ async function panBy({ delta: e, panZoom: s, transform: c, translateExtent: l, width: u, height: d }) {
984
+ if (!s || !e.x && !e.y) return Promise.resolve(!1);
985
+ let f = await s.setViewportConstrained({
986
+ x: c[0] + e.x,
987
+ y: c[1] + e.y,
988
+ zoom: c[2]
989
+ }, [[0, 0], [u, d]], l), p = !!f && (f.x !== c[0] || f.y !== c[1] || f.k !== c[2]);
990
+ return Promise.resolve(p);
991
+ }
992
+ function addConnectionToLookup(e, s, c, l, u, d) {
993
+ let f = u, p = l.get(f) || /* @__PURE__ */ new Map();
994
+ l.set(f, p.set(c, s)), f = `${u}-${e}`;
995
+ let m = l.get(f) || /* @__PURE__ */ new Map();
996
+ if (l.set(f, m.set(c, s)), d) {
997
+ f = `${u}-${e}-${d}`;
998
+ let p = l.get(f) || /* @__PURE__ */ new Map();
999
+ l.set(f, p.set(c, s));
1001
1000
  }
1002
1001
  }
1003
- function st(e, t, n) {
1004
- e.clear(), t.clear();
1005
- for (let r of n) {
1006
- let { source: n, target: i, sourceHandle: a = null, targetHandle: o = null } = r, s = {
1007
- edgeId: r.id,
1008
- source: n,
1009
- target: i,
1010
- sourceHandle: a,
1011
- targetHandle: o
1012
- }, c = `${n}-${a}--${i}-${o}`;
1013
- ot("source", s, `${i}-${o}--${n}-${a}`, e, n, a), ot("target", s, c, e, i, o), t.set(r.id, r);
1002
+ function updateConnectionLookup(e, s, c) {
1003
+ e.clear(), s.clear();
1004
+ for (let l of c) {
1005
+ let { source: c, target: u, sourceHandle: d = null, targetHandle: f = null } = l, p = {
1006
+ edgeId: l.id,
1007
+ source: c,
1008
+ target: u,
1009
+ sourceHandle: d,
1010
+ targetHandle: f
1011
+ }, m = `${c}-${d}--${u}-${f}`;
1012
+ addConnectionToLookup("source", p, `${u}-${f}--${c}-${d}`, e, c, d), addConnectionToLookup("target", p, m, e, u, f), s.set(l.id, l);
1014
1013
  }
1015
1014
  }
1016
- function ct(e, t) {
1015
+ function isParentSelected(e, s) {
1017
1016
  if (!e.parentId) return !1;
1018
- let n = t.get(e.parentId);
1019
- return n ? n.selected ? !0 : ct(n, t) : !1;
1017
+ let c = s.get(e.parentId);
1018
+ return c ? c.selected ? !0 : isParentSelected(c, s) : !1;
1020
1019
  }
1021
- function lt(e, t, n) {
1022
- let r = e;
1020
+ function hasSelector(e, s, c) {
1021
+ let l = e;
1023
1022
  do {
1024
- if (r?.matches?.(t)) return !0;
1025
- if (r === n) return !1;
1026
- r = r?.parentElement;
1027
- } while (r);
1023
+ if (l?.matches?.(s)) return !0;
1024
+ if (l === c) return !1;
1025
+ l = l?.parentElement;
1026
+ } while (l);
1028
1027
  return !1;
1029
1028
  }
1030
- function ut(e, t, n, r) {
1031
- let i = /* @__PURE__ */ new Map();
1032
- for (let [a, o] of e) if ((o.selected || o.id === r) && (!o.parentId || !ct(o, e)) && (o.draggable || t && o.draggable === void 0)) {
1033
- let t = e.get(a);
1034
- t && i.set(a, {
1035
- id: a,
1036
- position: t.position || {
1029
+ function getDragItems(e, s, c, l) {
1030
+ let u = /* @__PURE__ */ new Map();
1031
+ for (let [d, f] of e) if ((f.selected || f.id === l) && (!f.parentId || !isParentSelected(f, e)) && (f.draggable || s && f.draggable === void 0)) {
1032
+ let s = e.get(d);
1033
+ s && u.set(d, {
1034
+ id: d,
1035
+ position: s.position || {
1037
1036
  x: 0,
1038
1037
  y: 0
1039
1038
  },
1040
1039
  distance: {
1041
- x: n.x - t.internals.positionAbsolute.x,
1042
- y: n.y - t.internals.positionAbsolute.y
1040
+ x: c.x - s.internals.positionAbsolute.x,
1041
+ y: c.y - s.internals.positionAbsolute.y
1043
1042
  },
1044
- extent: t.extent,
1045
- parentId: t.parentId,
1046
- origin: t.origin,
1047
- expandParent: t.expandParent,
1048
- internals: { positionAbsolute: t.internals.positionAbsolute || {
1043
+ extent: s.extent,
1044
+ parentId: s.parentId,
1045
+ origin: s.origin,
1046
+ expandParent: s.expandParent,
1047
+ internals: { positionAbsolute: s.internals.positionAbsolute || {
1049
1048
  x: 0,
1050
1049
  y: 0
1051
1050
  } },
1052
1051
  measured: {
1053
- width: t.measured.width ?? 0,
1054
- height: t.measured.height ?? 0
1052
+ width: s.measured.width ?? 0,
1053
+ height: s.measured.height ?? 0
1055
1054
  }
1056
1055
  });
1057
1056
  }
1058
- return i;
1059
- }
1060
- function dt({ nodeId: e, dragItems: t, nodeLookup: n, dragging: r = !0 }) {
1061
- let i = [];
1062
- for (let [e, a] of t) {
1063
- let t = n.get(e)?.internals.userNode;
1064
- t && i.push({
1065
- ...t,
1066
- position: a.position,
1067
- dragging: r
1057
+ return u;
1058
+ }
1059
+ function getEventHandlerParams({ nodeId: e, dragItems: s, nodeLookup: c, dragging: l = !0 }) {
1060
+ let u = [];
1061
+ for (let [e, d] of s) {
1062
+ let s = c.get(e)?.internals.userNode;
1063
+ s && u.push({
1064
+ ...s,
1065
+ position: d.position,
1066
+ dragging: l
1068
1067
  });
1069
1068
  }
1070
- if (!e) return [i[0], i];
1071
- let a = n.get(e)?.internals.userNode;
1072
- return [a ? {
1073
- ...a,
1074
- position: t.get(e)?.position || a.position,
1075
- dragging: r
1076
- } : i[0], i];
1077
- }
1078
- function ft({ dragItems: e, snapGrid: t, x: n, y: r }) {
1079
- let i = e.values().next().value;
1080
- if (!i) return null;
1081
- let a = {
1082
- x: n - i.distance.x,
1083
- y: r - i.distance.y
1084
- }, o = G(a, t);
1069
+ if (!e) return [u[0], u];
1070
+ let d = c.get(e)?.internals.userNode;
1071
+ return [d ? {
1072
+ ...d,
1073
+ position: s.get(e)?.position || d.position,
1074
+ dragging: l
1075
+ } : u[0], u];
1076
+ }
1077
+ function calculateSnapOffset({ dragItems: e, snapGrid: s, x: c, y: l }) {
1078
+ let u = e.values().next().value;
1079
+ if (!u) return null;
1080
+ let d = {
1081
+ x: c - u.distance.x,
1082
+ y: l - u.distance.y
1083
+ }, f = snapPosition(d, s);
1085
1084
  return {
1086
- x: o.x - a.x,
1087
- y: o.y - a.y
1085
+ x: f.x - d.x,
1086
+ y: f.y - d.y
1088
1087
  };
1089
1088
  }
1090
- function pt({ onNodeMouseDown: t, getStoreItems: r, onDragStart: i, onDrag: a, onDragStop: o }) {
1091
- let s = {
1089
+ function XYDrag({ onNodeMouseDown: s, getStoreItems: l, onDragStart: u, onDrag: d, onDragStop: f }) {
1090
+ let p = {
1092
1091
  x: null,
1093
1092
  y: null
1094
- }, c = 0, l = /* @__PURE__ */ new Map(), u = !1, d = {
1093
+ }, m = 0, h = /* @__PURE__ */ new Map(), g = !1, _ = {
1095
1094
  x: 0,
1096
1095
  y: 0
1097
- }, f = null, p = !1, m = null, h = !1, g = !1, _ = null;
1098
- function v({ noDragClassName: v, handleSelector: y, domNode: b, isSelectable: x, nodeId: S, nodeClickDistance: C = 0 }) {
1099
- m = e(b);
1100
- function w({ x: e, y: t }) {
1101
- let { nodeLookup: n, nodeExtent: i, snapGrid: o, snapToGrid: c, nodeOrigin: u, onNodeDrag: d, onSelectionDrag: f, onError: p, updateNodePositions: m } = r();
1102
- s = {
1096
+ }, v = null, y = !1, b = null, x = !1, S = !1, C = null;
1097
+ function w({ noDragClassName: w, handleSelector: T, domNode: E, isSelectable: D, nodeId: O, nodeClickDistance: k = 0 }) {
1098
+ b = select_default(E);
1099
+ function A({ x: e, y: s }) {
1100
+ let { nodeLookup: c, nodeExtent: u, snapGrid: f, snapToGrid: m, nodeOrigin: g, onNodeDrag: _, onSelectionDrag: v, onError: y, updateNodePositions: b } = l();
1101
+ p = {
1103
1102
  x: e,
1104
- y: t
1103
+ y: s
1105
1104
  };
1106
- let h = !1, v = l.size > 1, y = v && i ? L(E(l)) : null, b = v && c ? ft({
1107
- dragItems: l,
1108
- snapGrid: o,
1105
+ let x = !1, w = h.size > 1, T = w && u ? rectToBox(getInternalNodesBounds(h)) : null, E = w && m ? calculateSnapOffset({
1106
+ dragItems: h,
1107
+ snapGrid: f,
1109
1108
  x: e,
1110
- y: t
1109
+ y: s
1111
1110
  }) : null;
1112
- for (let [r, a] of l) {
1113
- if (!n.has(r)) continue;
1114
- let s = {
1115
- x: e - a.distance.x,
1116
- y: t - a.distance.y
1111
+ for (let [l, d] of h) {
1112
+ if (!c.has(l)) continue;
1113
+ let p = {
1114
+ x: e - d.distance.x,
1115
+ y: s - d.distance.y
1117
1116
  };
1118
- c && (s = b ? {
1119
- x: Math.round(s.x + b.x),
1120
- y: Math.round(s.y + b.y)
1121
- } : G(s, o));
1122
- let l = null;
1123
- if (v && i && !a.extent && y) {
1124
- let { positionAbsolute: e } = a.internals, t = e.x - y.x + i[0][0], n = e.x + a.measured.width - y.x2 + i[1][0], r = e.y - y.y + i[0][1], o = e.y + a.measured.height - y.y2 + i[1][1];
1125
- l = [[t, r], [n, o]];
1117
+ m && (p = E ? {
1118
+ x: Math.round(p.x + E.x),
1119
+ y: Math.round(p.y + E.y)
1120
+ } : snapPosition(p, f));
1121
+ let h = null;
1122
+ if (w && u && !d.extent && T) {
1123
+ let { positionAbsolute: e } = d.internals, s = e.x - T.x + u[0][0], c = e.x + d.measured.width - T.x2 + u[1][0], l = e.y - T.y + u[0][1], f = e.y + d.measured.height - T.y2 + u[1][1];
1124
+ h = [[s, l], [c, f]];
1126
1125
  }
1127
- let { position: d, positionAbsolute: f } = j({
1128
- nodeId: r,
1129
- nextPosition: s,
1130
- nodeLookup: n,
1131
- nodeExtent: l || i,
1132
- nodeOrigin: u,
1133
- onError: p
1126
+ let { position: _, positionAbsolute: v } = calculateNodePosition({
1127
+ nodeId: l,
1128
+ nextPosition: p,
1129
+ nodeLookup: c,
1130
+ nodeExtent: h || u,
1131
+ nodeOrigin: g,
1132
+ onError: y
1134
1133
  });
1135
- h = h || a.position.x !== d.x || a.position.y !== d.y, a.position = d, a.internals.positionAbsolute = f;
1134
+ x = x || d.position.x !== _.x || d.position.y !== _.y, d.position = _, d.internals.positionAbsolute = v;
1136
1135
  }
1137
- if (g ||= h, h && (m(l, !0), _ && (a || d || !S && f))) {
1138
- let [e, t] = dt({
1139
- nodeId: S,
1140
- dragItems: l,
1141
- nodeLookup: n
1136
+ if (S ||= x, x && (b(h, !0), C && (d || _ || !O && v))) {
1137
+ let [e, s] = getEventHandlerParams({
1138
+ nodeId: O,
1139
+ dragItems: h,
1140
+ nodeLookup: c
1142
1141
  });
1143
- a?.(_, l, e, t), d?.(_, e, t), S || f?.(_, t);
1142
+ d?.(C, h, e, s), _?.(C, e, s), O || v?.(C, s);
1144
1143
  }
1145
1144
  }
1146
- async function T() {
1147
- if (!f) return;
1148
- let { transform: e, panBy: t, autoPanSpeed: n, autoPanOnNodeDrag: i } = r();
1149
- if (!i) {
1150
- u = !1, cancelAnimationFrame(c);
1145
+ async function j() {
1146
+ if (!v) return;
1147
+ let { transform: e, panBy: s, autoPanSpeed: c, autoPanOnNodeDrag: u } = l();
1148
+ if (!u) {
1149
+ g = !1, cancelAnimationFrame(m);
1151
1150
  return;
1152
1151
  }
1153
- let [a, o] = ee(d, f, n);
1154
- (a !== 0 || o !== 0) && (s.x = (s.x ?? 0) - a / e[2], s.y = (s.y ?? 0) - o / e[2], await t({
1155
- x: a,
1156
- y: o
1157
- }) && w(s)), c = requestAnimationFrame(T);
1152
+ let [d, f] = calcAutoPan(_, v, c);
1153
+ (d !== 0 || f !== 0) && (p.x = (p.x ?? 0) - d / e[2], p.y = (p.y ?? 0) - f / e[2], await s({
1154
+ x: d,
1155
+ y: f
1156
+ }) && A(p)), m = requestAnimationFrame(j);
1158
1157
  }
1159
- function D(e) {
1160
- let { nodeLookup: n, multiSelectionActive: a, nodesDraggable: o, transform: c, snapGrid: u, snapToGrid: d, selectNodesOnDrag: m, onNodeDragStart: h, onSelectionDragStart: g, unselectNodesAndEdges: _ } = r();
1161
- p = !0, (!m || !x) && !a && S && (n.get(S)?.selected || _()), x && m && S && t?.(S);
1162
- let v = me(e.sourceEvent, {
1163
- transform: c,
1164
- snapGrid: u,
1165
- snapToGrid: d,
1166
- containerBounds: f
1158
+ function N(e) {
1159
+ let { nodeLookup: c, multiSelectionActive: d, nodesDraggable: f, transform: m, snapGrid: g, snapToGrid: _, selectNodesOnDrag: b, onNodeDragStart: x, onSelectionDragStart: S, unselectNodesAndEdges: C } = l();
1160
+ y = !0, (!b || !D) && !d && O && (c.get(O)?.selected || C()), D && b && O && s?.(O);
1161
+ let w = getPointerPosition(e.sourceEvent, {
1162
+ transform: m,
1163
+ snapGrid: g,
1164
+ snapToGrid: _,
1165
+ containerBounds: v
1167
1166
  });
1168
- if (s = v, l = ut(n, o, v, S), l.size > 0 && (i || h || !S && g)) {
1169
- let [t, r] = dt({
1170
- nodeId: S,
1171
- dragItems: l,
1172
- nodeLookup: n
1167
+ if (p = w, h = getDragItems(c, f, w, O), h.size > 0 && (u || x || !O && S)) {
1168
+ let [s, l] = getEventHandlerParams({
1169
+ nodeId: O,
1170
+ dragItems: h,
1171
+ nodeLookup: c
1173
1172
  });
1174
- i?.(e.sourceEvent, l, t, r), h?.(e.sourceEvent, t, r), S || g?.(e.sourceEvent, r);
1173
+ u?.(e.sourceEvent, h, s, l), x?.(e.sourceEvent, s, l), O || S?.(e.sourceEvent, l);
1175
1174
  }
1176
1175
  }
1177
- let O = n().clickDistance(C).on("start", (e) => {
1178
- let { domNode: t, nodeDragThreshold: n, transform: i, snapGrid: a, snapToGrid: o } = r();
1179
- f = t?.getBoundingClientRect() || null, h = !1, g = !1, _ = e.sourceEvent, n === 0 && D(e), s = me(e.sourceEvent, {
1180
- transform: i,
1181
- snapGrid: a,
1182
- snapToGrid: o,
1183
- containerBounds: f
1184
- }), d = Y(e.sourceEvent, f);
1176
+ let P = drag_default().clickDistance(k).on("start", (e) => {
1177
+ let { domNode: s, nodeDragThreshold: c, transform: u, snapGrid: d, snapToGrid: f } = l();
1178
+ v = s?.getBoundingClientRect() || null, x = !1, S = !1, C = e.sourceEvent, c === 0 && N(e), p = getPointerPosition(e.sourceEvent, {
1179
+ transform: u,
1180
+ snapGrid: d,
1181
+ snapToGrid: f,
1182
+ containerBounds: v
1183
+ }), _ = getEventPosition(e.sourceEvent, v);
1185
1184
  }).on("drag", (e) => {
1186
- let { autoPanOnNodeDrag: t, transform: n, snapGrid: i, snapToGrid: a, nodeDragThreshold: o, nodeLookup: c } = r(), m = me(e.sourceEvent, {
1187
- transform: n,
1188
- snapGrid: i,
1189
- snapToGrid: a,
1190
- containerBounds: f
1185
+ let { autoPanOnNodeDrag: s, transform: c, snapGrid: u, snapToGrid: d, nodeDragThreshold: f, nodeLookup: m } = l(), b = getPointerPosition(e.sourceEvent, {
1186
+ transform: c,
1187
+ snapGrid: u,
1188
+ snapToGrid: d,
1189
+ containerBounds: v
1191
1190
  });
1192
- if (_ = e.sourceEvent, (e.sourceEvent.type === "touchmove" && e.sourceEvent.touches.length > 1 || S && !c.has(S)) && (h = !0), !h) {
1193
- if (!u && t && p && (u = !0, T()), !p) {
1194
- let t = Y(e.sourceEvent, f), n = t.x - d.x, r = t.y - d.y;
1195
- Math.sqrt(n * n + r * r) > o && D(e);
1191
+ if (C = e.sourceEvent, (e.sourceEvent.type === "touchmove" && e.sourceEvent.touches.length > 1 || O && !m.has(O)) && (x = !0), !x) {
1192
+ if (!g && s && y && (g = !0, j()), !y) {
1193
+ let s = getEventPosition(e.sourceEvent, v), c = s.x - _.x, l = s.y - _.y;
1194
+ Math.sqrt(c * c + l * l) > f && N(e);
1196
1195
  }
1197
- (s.x !== m.xSnapped || s.y !== m.ySnapped) && l && p && (d = Y(e.sourceEvent, f), w(m));
1196
+ (p.x !== b.xSnapped || p.y !== b.ySnapped) && h && y && (_ = getEventPosition(e.sourceEvent, v), A(b));
1198
1197
  }
1199
1198
  }).on("end", (e) => {
1200
- if (!(!p || h) && (u = !1, p = !1, cancelAnimationFrame(c), l.size > 0)) {
1201
- let { nodeLookup: t, updateNodePositions: n, onNodeDragStop: i, onSelectionDragStop: a } = r();
1202
- if (g &&= (n(l, !1), !1), o || i || !S && a) {
1203
- let [n, r] = dt({
1204
- nodeId: S,
1205
- dragItems: l,
1206
- nodeLookup: t,
1199
+ if (!(!y || x) && (g = !1, y = !1, cancelAnimationFrame(m), h.size > 0)) {
1200
+ let { nodeLookup: s, updateNodePositions: c, onNodeDragStop: u, onSelectionDragStop: d } = l();
1201
+ if (S &&= (c(h, !1), !1), f || u || !O && d) {
1202
+ let [c, l] = getEventHandlerParams({
1203
+ nodeId: O,
1204
+ dragItems: h,
1205
+ nodeLookup: s,
1207
1206
  dragging: !1
1208
1207
  });
1209
- o?.(e.sourceEvent, l, n, r), i?.(e.sourceEvent, n, r), S || a?.(e.sourceEvent, r);
1208
+ f?.(e.sourceEvent, h, c, l), u?.(e.sourceEvent, c, l), O || d?.(e.sourceEvent, l);
1210
1209
  }
1211
1210
  }
1212
1211
  }).filter((e) => {
1213
- let t = e.target;
1214
- return !e.button && (!v || !lt(t, `.${v}`, b)) && (!y || lt(t, y, b));
1212
+ let s = e.target;
1213
+ return !e.button && (!w || !hasSelector(s, `.${w}`, E)) && (!T || hasSelector(s, T, E));
1215
1214
  });
1216
- m.call(O);
1215
+ b.call(P);
1217
1216
  }
1218
- function y() {
1219
- m?.on(".drag", null);
1217
+ function T() {
1218
+ b?.on(".drag", null);
1220
1219
  }
1221
1220
  return {
1222
- update: v,
1223
- destroy: y
1221
+ update: w,
1222
+ destroy: T
1224
1223
  };
1225
1224
  }
1226
- function mt(e, t, n) {
1227
- let r = [], i = {
1228
- x: e.x - n,
1229
- y: e.y - n,
1230
- width: n * 2,
1231
- height: n * 2
1225
+ function getNodesWithinDistance(e, s, c) {
1226
+ let l = [], u = {
1227
+ x: e.x - c,
1228
+ y: e.y - c,
1229
+ width: c * 2,
1230
+ height: c * 2
1232
1231
  };
1233
- for (let e of t.values()) V(i, z(e)) > 0 && r.push(e);
1234
- return r;
1235
- }
1236
- var ht = 250;
1237
- function gt(e, t, n, r) {
1238
- let i = [], a = Infinity, o = mt(e, n, t + ht);
1239
- for (let n of o) {
1240
- let o = [...n.internals.handleBounds?.source ?? [], ...n.internals.handleBounds?.target ?? []];
1241
- for (let s of o) {
1242
- if (r.nodeId === s.nodeId && r.type === s.type && r.id === s.id) continue;
1243
- let { x: o, y: c } = X(n, s, s.position, !0), l = Math.sqrt((o - e.x) ** 2 + (c - e.y) ** 2);
1244
- l > t || (l < a ? (i = [{
1245
- ...s,
1246
- x: o,
1247
- y: c
1248
- }], a = l) : l === a && i.push({
1249
- ...s,
1250
- x: o,
1251
- y: c
1232
+ for (let e of s.values()) getOverlappingArea(u, nodeToRect(e)) > 0 && l.push(e);
1233
+ return l;
1234
+ }
1235
+ var ADDITIONAL_DISTANCE = 250;
1236
+ function getClosestHandle(e, s, c, l) {
1237
+ let u = [], d = Infinity, f = getNodesWithinDistance(e, c, s + ADDITIONAL_DISTANCE);
1238
+ for (let c of f) {
1239
+ let f = [...c.internals.handleBounds?.source ?? [], ...c.internals.handleBounds?.target ?? []];
1240
+ for (let p of f) {
1241
+ if (l.nodeId === p.nodeId && l.type === p.type && l.id === p.id) continue;
1242
+ let { x: f, y: m } = getHandlePosition(c, p, p.position, !0), h = Math.sqrt((f - e.x) ** 2 + (m - e.y) ** 2);
1243
+ h > s || (h < d ? (u = [{
1244
+ ...p,
1245
+ x: f,
1246
+ y: m
1247
+ }], d = h) : h === d && u.push({
1248
+ ...p,
1249
+ x: f,
1250
+ y: m
1252
1251
  }));
1253
1252
  }
1254
1253
  }
1255
- if (!i.length) return null;
1256
- if (i.length > 1) {
1257
- let e = r.type === "source" ? "target" : "source";
1258
- return i.find((t) => t.type === e) ?? i[0];
1254
+ if (!u.length) return null;
1255
+ if (u.length > 1) {
1256
+ let e = l.type === "source" ? "target" : "source";
1257
+ return u.find((s) => s.type === e) ?? u[0];
1259
1258
  }
1260
- return i[0];
1261
- }
1262
- function _t(e, t, n, r, i, a = !1) {
1263
- let o = r.get(e);
1264
- if (!o) return null;
1265
- let s = i === "strict" ? o.internals.handleBounds?.[t] : [...o.internals.handleBounds?.source ?? [], ...o.internals.handleBounds?.target ?? []], c = (n ? s?.find((e) => e.id === n) : s?.[0]) ?? null;
1266
- return c && a ? {
1267
- ...c,
1268
- ...X(o, c, c.position, !0)
1269
- } : c;
1270
- }
1271
- function vt(e, t) {
1272
- return e || (t?.classList.contains("target") ? "target" : t?.classList.contains("source") ? "source" : null);
1273
- }
1274
- function yt(e, t) {
1275
- let n = null;
1276
- return t ? n = !0 : e && !t && (n = !1), n;
1277
- }
1278
- var bt = () => !0;
1279
- function xt(e, { connectionMode: t, connectionRadius: n, handleId: r, nodeId: i, edgeUpdaterType: a, isTarget: o, domNode: s, nodeLookup: c, lib: l, autoPanOnConnect: u, flowId: d, panBy: f, cancelConnection: p, onConnectStart: m, onConnect: h, onConnectEnd: g, isValidConnection: _ = bt, onReconnectEnd: b, updateConnection: x, getTransform: S, getFromHandle: C, autoPanSpeed: w, dragThreshold: T = 1, handleDomNode: E }) {
1280
- let D = ge(e.target), O = 0, k, { x: A, y: j } = Y(e), M = vt(a, E), N = s?.getBoundingClientRect(), P = !1;
1281
- if (!N || !M) return;
1282
- let F = _t(i, M, r, c, t);
1283
- if (!F) return;
1284
- let I = Y(e, N), te = !1, L = null, R = !1, z = null;
1285
- function ne() {
1286
- if (!u || !N) return;
1287
- let [e, t] = ee(I, N, w);
1288
- f({
1259
+ return u[0];
1260
+ }
1261
+ function getHandle(e, s, c, l, u, d = !1) {
1262
+ let f = l.get(e);
1263
+ if (!f) return null;
1264
+ let p = u === "strict" ? f.internals.handleBounds?.[s] : [...f.internals.handleBounds?.source ?? [], ...f.internals.handleBounds?.target ?? []], m = (c ? p?.find((e) => e.id === c) : p?.[0]) ?? null;
1265
+ return m && d ? {
1266
+ ...m,
1267
+ ...getHandlePosition(f, m, m.position, !0)
1268
+ } : m;
1269
+ }
1270
+ function getHandleType(e, s) {
1271
+ return e || (s?.classList.contains("target") ? "target" : s?.classList.contains("source") ? "source" : null);
1272
+ }
1273
+ function isConnectionValid(e, s) {
1274
+ let c = null;
1275
+ return s ? c = !0 : e && !s && (c = !1), c;
1276
+ }
1277
+ var alwaysValid = () => !0;
1278
+ function onPointerDown(e, { connectionMode: s, connectionRadius: c, handleId: l, nodeId: u, edgeUpdaterType: d, isTarget: f, domNode: p, nodeLookup: m, lib: h, autoPanOnConnect: g, flowId: _, panBy: v, cancelConnection: y, onConnectStart: b, onConnect: x, onConnectEnd: S, isValidConnection: C = alwaysValid, onReconnectEnd: E, updateConnection: D, getTransform: O, getFromHandle: k, autoPanSpeed: A, dragThreshold: j = 1, handleDomNode: M }) {
1279
+ let N = getHostForElement(e.target), P = 0, F, { x: I, y: L } = getEventPosition(e), R = getHandleType(d, M), z = p?.getBoundingClientRect(), B = !1;
1280
+ if (!z || !R) return;
1281
+ let V = getHandle(u, R, l, m, s);
1282
+ if (!V) return;
1283
+ let H = getEventPosition(e, z), U = !1, W = null, G = !1, K = null;
1284
+ function q() {
1285
+ if (!g || !z) return;
1286
+ let [e, s] = calcAutoPan(H, z, A);
1287
+ v({
1289
1288
  x: e,
1290
- y: t
1291
- }), O = requestAnimationFrame(ne);
1289
+ y: s
1290
+ }), P = requestAnimationFrame(q);
1292
1291
  }
1293
- let B = {
1294
- ...F,
1295
- nodeId: i,
1296
- type: M,
1297
- position: F.position
1298
- }, V = c.get(i), H = {
1292
+ let J = {
1293
+ ...V,
1294
+ nodeId: u,
1295
+ type: R,
1296
+ position: V.position
1297
+ }, Y = m.get(u), X = {
1299
1298
  inProgress: !0,
1300
1299
  isValid: null,
1301
- from: X(V, B, v.Left, !0),
1302
- fromHandle: B,
1303
- fromPosition: B.position,
1304
- fromNode: V,
1305
- to: I,
1300
+ from: getHandlePosition(Y, J, Position.Left, !0),
1301
+ fromHandle: J,
1302
+ fromPosition: J.position,
1303
+ fromNode: Y,
1304
+ to: H,
1306
1305
  toHandle: null,
1307
- toPosition: y[B.position],
1306
+ toPosition: oppositePosition[J.position],
1308
1307
  toNode: null,
1309
- pointer: I
1308
+ pointer: H
1310
1309
  };
1311
- function U() {
1312
- P = !0, x(H), m?.(e, {
1313
- nodeId: i,
1314
- handleId: r,
1315
- handleType: M
1310
+ function Z() {
1311
+ B = !0, D(X), b?.(e, {
1312
+ nodeId: u,
1313
+ handleId: l,
1314
+ handleType: R
1316
1315
  });
1317
1316
  }
1318
- T === 0 && U();
1319
- function W(e) {
1320
- if (!P) {
1321
- let { x: t, y: n } = Y(e), r = t - A, i = n - j;
1322
- if (!(r * r + i * i > T * T)) return;
1323
- U();
1317
+ j === 0 && Z();
1318
+ function Q(e) {
1319
+ if (!B) {
1320
+ let { x: s, y: c } = getEventPosition(e), l = s - I, u = c - L;
1321
+ if (!(l * l + u * u > j * j)) return;
1322
+ Z();
1324
1323
  }
1325
- if (!C() || !B) {
1326
- G(e);
1324
+ if (!k() || !J) {
1325
+ $(e);
1327
1326
  return;
1328
1327
  }
1329
- let a = S();
1330
- I = Y(e, N), k = gt(re(I, a, !1, [1, 1]), n, c, B), te ||= (ne(), !0);
1331
- let s = St(e, {
1332
- handle: k,
1333
- connectionMode: t,
1334
- fromNodeId: i,
1335
- fromHandleId: r,
1336
- fromType: o ? "target" : "source",
1337
- isValidConnection: _,
1338
- doc: D,
1339
- lib: l,
1340
- flowId: d,
1341
- nodeLookup: c
1328
+ let d = O();
1329
+ H = getEventPosition(e, z), F = getClosestHandle(pointToRendererPoint(H, d, !1, [1, 1]), c, m, J), U ||= (q(), !0);
1330
+ let p = isValidHandle(e, {
1331
+ handle: F,
1332
+ connectionMode: s,
1333
+ fromNodeId: u,
1334
+ fromHandleId: l,
1335
+ fromType: f ? "target" : "source",
1336
+ isValidConnection: C,
1337
+ doc: N,
1338
+ lib: h,
1339
+ flowId: _,
1340
+ nodeLookup: m
1342
1341
  });
1343
- z = s.handleDomNode, L = s.connection, R = yt(!!k, s.isValid);
1344
- let u = c.get(i), f = u ? X(u, B, v.Left, !0) : H.from, p = {
1345
- ...H,
1346
- from: f,
1347
- isValid: R,
1348
- to: s.toHandle && R ? ie({
1349
- x: s.toHandle.x,
1350
- y: s.toHandle.y
1351
- }, a) : I,
1352
- toHandle: s.toHandle,
1353
- toPosition: R && s.toHandle ? s.toHandle.position : y[B.position],
1354
- toNode: s.toHandle ? c.get(s.toHandle.nodeId) : null,
1355
- pointer: I
1342
+ K = p.handleDomNode, W = p.connection, G = isConnectionValid(!!F, p.isValid);
1343
+ let g = m.get(u), v = g ? getHandlePosition(g, J, Position.Left, !0) : X.from, y = {
1344
+ ...X,
1345
+ from: v,
1346
+ isValid: G,
1347
+ to: p.toHandle && G ? rendererPointToPoint({
1348
+ x: p.toHandle.x,
1349
+ y: p.toHandle.y
1350
+ }, d) : H,
1351
+ toHandle: p.toHandle,
1352
+ toPosition: G && p.toHandle ? p.toHandle.position : oppositePosition[J.position],
1353
+ toNode: p.toHandle ? m.get(p.toHandle.nodeId) : null,
1354
+ pointer: H
1356
1355
  };
1357
- x(p), H = p;
1356
+ D(y), X = y;
1358
1357
  }
1359
- function G(e) {
1358
+ function $(e) {
1360
1359
  if (!("touches" in e && e.touches.length > 0)) {
1361
- if (P) {
1362
- (k || z) && L && R && h?.(L);
1363
- let { inProgress: t, ...n } = H, r = {
1364
- ...n,
1365
- toPosition: H.toHandle ? H.toPosition : null
1360
+ if (B) {
1361
+ (F || K) && W && G && x?.(W);
1362
+ let { inProgress: s, ...c } = X, l = {
1363
+ ...c,
1364
+ toPosition: X.toHandle ? X.toPosition : null
1366
1365
  };
1367
- g?.(e, r), a && b?.(e, r);
1366
+ S?.(e, l), d && E?.(e, l);
1368
1367
  }
1369
- p(), cancelAnimationFrame(O), te = !1, R = !1, L = null, z = null, D.removeEventListener("mousemove", W), D.removeEventListener("mouseup", G), D.removeEventListener("touchmove", W), D.removeEventListener("touchend", G);
1368
+ y(), cancelAnimationFrame(P), U = !1, G = !1, W = null, K = null, N.removeEventListener("mousemove", Q), N.removeEventListener("mouseup", $), N.removeEventListener("touchmove", Q), N.removeEventListener("touchend", $);
1370
1369
  }
1371
1370
  }
1372
- D.addEventListener("mousemove", W), D.addEventListener("mouseup", G), D.addEventListener("touchmove", W), D.addEventListener("touchend", G);
1371
+ N.addEventListener("mousemove", Q), N.addEventListener("mouseup", $), N.addEventListener("touchmove", Q), N.addEventListener("touchend", $);
1373
1372
  }
1374
- function St(e, { handle: t, connectionMode: n, fromNodeId: r, fromHandleId: i, fromType: a, doc: o, lib: s, flowId: c, isValidConnection: l = bt, nodeLookup: u }) {
1375
- let d = a === "target", p = t ? o.querySelector(`.${s}-flow__handle[data-id="${c}-${t?.nodeId}-${t?.id}-${t?.type}"]`) : null, { x: m, y: h } = Y(e), g = o.elementFromPoint(m, h), _ = g?.classList.contains(`${s}-flow__handle`) ? g : p, v = {
1376
- handleDomNode: _,
1373
+ function isValidHandle(e, { handle: s, connectionMode: c, fromNodeId: l, fromHandleId: u, fromType: d, doc: f, lib: p, flowId: m, isValidConnection: h = alwaysValid, nodeLookup: g }) {
1374
+ let _ = d === "target", y = s ? f.querySelector(`.${p}-flow__handle[data-id="${m}-${s?.nodeId}-${s?.id}-${s?.type}"]`) : null, { x: b, y: x } = getEventPosition(e), S = f.elementFromPoint(b, x), C = S?.classList.contains(`${p}-flow__handle`) ? S : y, w = {
1375
+ handleDomNode: C,
1377
1376
  isValid: !1,
1378
1377
  connection: null,
1379
1378
  toHandle: null
1380
1379
  };
1381
- if (_) {
1382
- let e = vt(void 0, _), t = _.getAttribute("data-nodeid"), a = _.getAttribute("data-handleid"), o = _.classList.contains("connectable"), s = _.classList.contains("connectableend");
1383
- if (!t || !e) return v;
1384
- let c = {
1385
- source: d ? t : r,
1386
- sourceHandle: d ? a : i,
1387
- target: d ? r : t,
1388
- targetHandle: d ? i : a
1380
+ if (C) {
1381
+ let e = getHandleType(void 0, C), s = C.getAttribute("data-nodeid"), d = C.getAttribute("data-handleid"), f = C.classList.contains("connectable"), p = C.classList.contains("connectableend");
1382
+ if (!s || !e) return w;
1383
+ let m = {
1384
+ source: _ ? s : l,
1385
+ sourceHandle: _ ? d : u,
1386
+ target: _ ? l : s,
1387
+ targetHandle: _ ? u : d
1389
1388
  };
1390
- v.connection = c, v.isValid = o && s && (n === f.Strict ? d && e === "source" || !d && e === "target" : t !== r || a !== i) && l(c), v.toHandle = _t(t, e, a, u, n, !0);
1389
+ w.connection = m, w.isValid = f && p && (c === ConnectionMode.Strict ? _ && e === "source" || !_ && e === "target" : s !== l || d !== u) && h(m), w.toHandle = getHandle(s, e, d, g, c, !0);
1391
1390
  }
1392
- return v;
1391
+ return w;
1393
1392
  }
1394
- var Ct = {
1395
- onPointerDown: xt,
1396
- isValid: St
1393
+ var XYHandle = {
1394
+ onPointerDown,
1395
+ isValid: isValidHandle
1397
1396
  };
1398
- function wt({ domNode: n, panZoom: r, getTransform: i, getViewScale: a }) {
1399
- let o = e(n);
1400
- function c({ translateExtent: e, width: t, height: n, zoomStep: c = 1, pannable: l = !0, zoomable: u = !0, inversePan: d = !1 }) {
1401
- let f = (e) => {
1402
- if (e.sourceEvent.type !== "wheel" || !r) return;
1403
- let t = i(), n = e.sourceEvent.ctrlKey && ce() ? 10 : 1, a = -e.sourceEvent.deltaY * (e.sourceEvent.deltaMode === 1 ? .05 : e.sourceEvent.deltaMode ? 1 : .002) * c, o = t[2] * 2 ** (a * n);
1404
- r.scaleTo(o);
1405
- }, p = [0, 0], m = s().on("start", (e) => {
1406
- (e.sourceEvent.type === "mousedown" || e.sourceEvent.type === "touchstart") && (p = [e.sourceEvent.clientX ?? e.sourceEvent.touches[0].clientX, e.sourceEvent.clientY ?? e.sourceEvent.touches[0].clientY]);
1407
- }).on("zoom", l ? (o) => {
1408
- let s = i();
1409
- if (o.sourceEvent.type !== "mousemove" && o.sourceEvent.type !== "touchmove" || !r) return;
1410
- let c = [o.sourceEvent.clientX ?? o.sourceEvent.touches[0].clientX, o.sourceEvent.clientY ?? o.sourceEvent.touches[0].clientY], l = [c[0] - p[0], c[1] - p[1]];
1411
- p = c;
1412
- let u = a() * Math.max(s[2], Math.log(s[2])) * (d ? -1 : 1), f = {
1413
- x: s[0] - l[0] * u,
1414
- y: s[1] - l[1] * u
1415
- }, m = [[0, 0], [t, n]];
1416
- r.setViewportConstrained({
1417
- x: f.x,
1418
- y: f.y,
1419
- zoom: s[2]
1420
- }, m, e);
1421
- } : null).on("zoom.wheel", u ? f : null);
1422
- o.call(m, {});
1397
+ function XYMinimap({ domNode: c, panZoom: l, getTransform: u, getViewScale: d }) {
1398
+ let f = select_default(c);
1399
+ function m({ translateExtent: e, width: s, height: c, zoomStep: m = 1, pannable: h = !0, zoomable: g = !0, inversePan: _ = !1 }) {
1400
+ let v = (e) => {
1401
+ if (e.sourceEvent.type !== "wheel" || !l) return;
1402
+ let s = u(), c = e.sourceEvent.ctrlKey && isMacOs() ? 10 : 1, d = -e.sourceEvent.deltaY * (e.sourceEvent.deltaMode === 1 ? .05 : e.sourceEvent.deltaMode ? 1 : .002) * m, f = s[2] * 2 ** (d * c);
1403
+ l.scaleTo(f);
1404
+ }, y = [0, 0], b = zoom_default().on("start", (e) => {
1405
+ (e.sourceEvent.type === "mousedown" || e.sourceEvent.type === "touchstart") && (y = [e.sourceEvent.clientX ?? e.sourceEvent.touches[0].clientX, e.sourceEvent.clientY ?? e.sourceEvent.touches[0].clientY]);
1406
+ }).on("zoom", h ? (f) => {
1407
+ let p = u();
1408
+ if (f.sourceEvent.type !== "mousemove" && f.sourceEvent.type !== "touchmove" || !l) return;
1409
+ let m = [f.sourceEvent.clientX ?? f.sourceEvent.touches[0].clientX, f.sourceEvent.clientY ?? f.sourceEvent.touches[0].clientY], h = [m[0] - y[0], m[1] - y[1]];
1410
+ y = m;
1411
+ let g = d() * Math.max(p[2], Math.log(p[2])) * (_ ? -1 : 1), v = {
1412
+ x: p[0] - h[0] * g,
1413
+ y: p[1] - h[1] * g
1414
+ }, b = [[0, 0], [s, c]];
1415
+ l.setViewportConstrained({
1416
+ x: v.x,
1417
+ y: v.y,
1418
+ zoom: p[2]
1419
+ }, b, e);
1420
+ } : null).on("zoom.wheel", g ? v : null);
1421
+ f.call(b, {});
1423
1422
  }
1424
- function l() {
1425
- o.on("zoom", null);
1423
+ function h() {
1424
+ f.on("zoom", null);
1426
1425
  }
1427
1426
  return {
1428
- update: c,
1429
- destroy: l,
1430
- pointer: t
1427
+ update: m,
1428
+ destroy: h,
1429
+ pointer: pointer_default
1431
1430
  };
1432
1431
  }
1433
- var Tt = (e) => ({
1432
+ var transformToViewport = (e) => ({
1434
1433
  x: e.x,
1435
1434
  y: e.y,
1436
1435
  zoom: e.k
1437
- }), Et = ({ x: e, y: t, zoom: n }) => o.translate(e, t).scale(n), Z = (e, t) => e.target.closest(`.${t}`), Dt = (e, t) => t === 2 && Array.isArray(e) && e.includes(2), Ot = (e) => ((e *= 2) <= 1 ? e * e * e : (e -= 2) * e * e + 2) / 2, kt = (e, t = 0, n = Ot, r = () => {}) => {
1438
- let i = typeof t == "number" && t > 0;
1439
- return i || r(), i ? e.transition().duration(t).ease(n).on("end", r) : e;
1440
- }, At = (e) => {
1441
- let t = e.ctrlKey && ce() ? 10 : 1;
1442
- return -e.deltaY * (e.deltaMode === 1 ? .05 : e.deltaMode ? 1 : .002) * t;
1436
+ }), viewportToTransform = ({ x: e, y: s, zoom: c }) => identity.translate(e, s).scale(c), isWrappedWithClass = (e, s) => e.target.closest(`.${s}`), isRightClickPan = (e, s) => s === 2 && Array.isArray(e) && e.includes(2), defaultEase = (e) => ((e *= 2) <= 1 ? e * e * e : (e -= 2) * e * e + 2) / 2, getD3Transition = (e, s = 0, c = defaultEase, l = () => {}) => {
1437
+ let u = typeof s == "number" && s > 0;
1438
+ return u || l(), u ? e.transition().duration(s).ease(c).on("end", l) : e;
1439
+ }, wheelDelta = (e) => {
1440
+ let s = e.ctrlKey && isMacOs() ? 10 : 1;
1441
+ return -e.deltaY * (e.deltaMode === 1 ? .05 : e.deltaMode ? 1 : .002) * s;
1443
1442
  };
1444
- function jt({ zoomPanValues: e, noWheelClassName: n, d3Selection: r, d3Zoom: i, panOnScrollMode: a, panOnScrollSpeed: o, zoomOnPinch: s, onPanZoomStart: c, onPanZoom: l, onPanZoomEnd: u }) {
1445
- return (d) => {
1446
- if (Z(d, n)) return d.ctrlKey && d.preventDefault(), !1;
1447
- d.preventDefault(), d.stopImmediatePropagation();
1448
- let f = r.property("__zoom").k || 1;
1449
- if (d.ctrlKey && s) {
1450
- let e = t(d), n = f * 2 ** At(d);
1451
- i.scaleTo(r, n, e, d);
1443
+ function createPanOnScrollHandler({ zoomPanValues: e, noWheelClassName: c, d3Selection: l, d3Zoom: u, panOnScrollMode: d, panOnScrollSpeed: f, zoomOnPinch: p, onPanZoomStart: m, onPanZoom: h, onPanZoomEnd: g }) {
1444
+ return (_) => {
1445
+ if (isWrappedWithClass(_, c)) return _.ctrlKey && _.preventDefault(), !1;
1446
+ _.preventDefault(), _.stopImmediatePropagation();
1447
+ let v = l.property("__zoom").k || 1;
1448
+ if (_.ctrlKey && p) {
1449
+ let e = pointer_default(_), c = v * 2 ** wheelDelta(_);
1450
+ u.scaleTo(l, c, e, _);
1452
1451
  return;
1453
1452
  }
1454
- let m = d.deltaMode === 1 ? 20 : 1, h = a === p.Vertical ? 0 : d.deltaX * m, g = a === p.Horizontal ? 0 : d.deltaY * m;
1455
- !ce() && d.shiftKey && a !== p.Vertical && (h = d.deltaY * m, g = 0), i.translateBy(r, -(h / f) * o, -(g / f) * o, { internal: !0 });
1456
- let _ = Tt(r.property("__zoom"));
1457
- clearTimeout(e.panScrollTimeout), e.isPanScrolling ? (l?.(d, _), e.panScrollTimeout = setTimeout(() => {
1458
- u?.(d, _), e.isPanScrolling = !1;
1459
- }, 150)) : (e.isPanScrolling = !0, c?.(d, _));
1453
+ let b = _.deltaMode === 1 ? 20 : 1, x = d === PanOnScrollMode.Vertical ? 0 : _.deltaX * b, S = d === PanOnScrollMode.Horizontal ? 0 : _.deltaY * b;
1454
+ !isMacOs() && _.shiftKey && d !== PanOnScrollMode.Vertical && (x = _.deltaY * b, S = 0), u.translateBy(l, -(x / v) * f, -(S / v) * f, { internal: !0 });
1455
+ let C = transformToViewport(l.property("__zoom"));
1456
+ clearTimeout(e.panScrollTimeout), e.isPanScrolling ? (h?.(_, C), e.panScrollTimeout = setTimeout(() => {
1457
+ g?.(_, C), e.isPanScrolling = !1;
1458
+ }, 150)) : (e.isPanScrolling = !0, m?.(_, C));
1460
1459
  };
1461
1460
  }
1462
- function Mt({ noWheelClassName: e, preventScrolling: t, d3ZoomHandler: n }) {
1463
- return function(r, i) {
1464
- let a = r.type === "wheel", o = !t && a && !r.ctrlKey, s = Z(r, e);
1465
- if (r.ctrlKey && a && s && r.preventDefault(), o || s) return null;
1466
- r.preventDefault(), n.call(this, r, i);
1461
+ function createZoomOnScrollHandler({ noWheelClassName: e, preventScrolling: s, d3ZoomHandler: c }) {
1462
+ return function(l, u) {
1463
+ let d = l.type === "wheel", f = !s && d && !l.ctrlKey, p = isWrappedWithClass(l, e);
1464
+ if (l.ctrlKey && d && p && l.preventDefault(), f || p) return null;
1465
+ l.preventDefault(), c.call(this, l, u);
1467
1466
  };
1468
1467
  }
1469
- function Nt({ zoomPanValues: e, onDraggingChange: t, onPanZoomStart: n }) {
1470
- return (r) => {
1471
- if (r.sourceEvent?.internal) return;
1472
- let i = Tt(r.transform);
1473
- e.mouseButton = r.sourceEvent?.button || 0, e.isZoomingOrPanning = !0, e.prevViewport = i, r.sourceEvent?.type === "mousedown" && t(!0), n && n?.(r.sourceEvent, i);
1468
+ function createPanZoomStartHandler({ zoomPanValues: e, onDraggingChange: s, onPanZoomStart: c }) {
1469
+ return (l) => {
1470
+ if (l.sourceEvent?.internal) return;
1471
+ let u = transformToViewport(l.transform);
1472
+ e.mouseButton = l.sourceEvent?.button || 0, e.isZoomingOrPanning = !0, e.prevViewport = u, l.sourceEvent?.type === "mousedown" && s(!0), c && c?.(l.sourceEvent, u);
1474
1473
  };
1475
1474
  }
1476
- function Pt({ zoomPanValues: e, panOnDrag: t, onPaneContextMenu: n, onTransformChange: r, onPanZoom: i }) {
1477
- return (a) => {
1478
- e.usedRightMouseButton = !!(n && Dt(t, e.mouseButton ?? 0)), a.sourceEvent?.sync || r([
1479
- a.transform.x,
1480
- a.transform.y,
1481
- a.transform.k
1482
- ]), i && !a.sourceEvent?.internal && i?.(a.sourceEvent, Tt(a.transform));
1475
+ function createPanZoomHandler({ zoomPanValues: e, panOnDrag: s, onPaneContextMenu: c, onTransformChange: l, onPanZoom: u }) {
1476
+ return (d) => {
1477
+ e.usedRightMouseButton = !!(c && isRightClickPan(s, e.mouseButton ?? 0)), d.sourceEvent?.sync || l([
1478
+ d.transform.x,
1479
+ d.transform.y,
1480
+ d.transform.k
1481
+ ]), u && !d.sourceEvent?.internal && u?.(d.sourceEvent, transformToViewport(d.transform));
1483
1482
  };
1484
1483
  }
1485
- function Ft({ zoomPanValues: e, panOnDrag: t, panOnScroll: n, onDraggingChange: r, onPanZoomEnd: i, onPaneContextMenu: a }) {
1486
- return (o) => {
1487
- if (!o.sourceEvent?.internal && (e.isZoomingOrPanning = !1, a && Dt(t, e.mouseButton ?? 0) && !e.usedRightMouseButton && o.sourceEvent && a(o.sourceEvent), e.usedRightMouseButton = !1, r(!1), i)) {
1488
- let t = Tt(o.transform);
1489
- e.prevViewport = t, clearTimeout(e.timerId), e.timerId = setTimeout(() => {
1490
- i?.(o.sourceEvent, t);
1491
- }, n ? 150 : 0);
1484
+ function createPanZoomEndHandler({ zoomPanValues: e, panOnDrag: s, panOnScroll: c, onDraggingChange: l, onPanZoomEnd: u, onPaneContextMenu: d }) {
1485
+ return (f) => {
1486
+ if (!f.sourceEvent?.internal && (e.isZoomingOrPanning = !1, d && isRightClickPan(s, e.mouseButton ?? 0) && !e.usedRightMouseButton && f.sourceEvent && d(f.sourceEvent), e.usedRightMouseButton = !1, l(!1), u)) {
1487
+ let s = transformToViewport(f.transform);
1488
+ e.prevViewport = s, clearTimeout(e.timerId), e.timerId = setTimeout(() => {
1489
+ u?.(f.sourceEvent, s);
1490
+ }, c ? 150 : 0);
1492
1491
  }
1493
1492
  };
1494
1493
  }
1495
- function It({ zoomActivationKeyPressed: e, zoomOnScroll: t, zoomOnPinch: n, panOnDrag: r, panOnScroll: i, zoomOnDoubleClick: a, userSelectionActive: o, noWheelClassName: s, noPanClassName: c, lib: l, connectionInProgress: u }) {
1496
- return (d) => {
1497
- let f = e || t, p = n && d.ctrlKey, m = d.type === "wheel";
1498
- if (d.button === 1 && d.type === "mousedown" && (Z(d, `${l}-flow__node`) || Z(d, `${l}-flow__edge`))) return !0;
1499
- if (!r && !f && !i && !a && !n || o || u && !m || Z(d, s) && m || Z(d, c) && (!m || i && m && !e) || !n && d.ctrlKey && m) return !1;
1500
- if (!n && d.type === "touchstart" && d.touches?.length > 1) return d.preventDefault(), !1;
1501
- if (!f && !i && !p && m || !r && (d.type === "mousedown" || d.type === "touchstart") || Array.isArray(r) && !r.includes(d.button) && d.type === "mousedown") return !1;
1502
- let h = Array.isArray(r) && r.includes(d.button) || !d.button || d.button <= 1;
1503
- return (!d.ctrlKey || m) && h;
1494
+ function createFilter({ zoomActivationKeyPressed: e, zoomOnScroll: s, zoomOnPinch: c, panOnDrag: l, panOnScroll: u, zoomOnDoubleClick: d, userSelectionActive: f, noWheelClassName: p, noPanClassName: m, lib: h, connectionInProgress: g }) {
1495
+ return (_) => {
1496
+ let v = e || s, y = c && _.ctrlKey, b = _.type === "wheel";
1497
+ if (_.button === 1 && _.type === "mousedown" && (isWrappedWithClass(_, `${h}-flow__node`) || isWrappedWithClass(_, `${h}-flow__edge`))) return !0;
1498
+ if (!l && !v && !u && !d && !c || f || g && !b || isWrappedWithClass(_, p) && b || isWrappedWithClass(_, m) && (!b || u && b && !e) || !c && _.ctrlKey && b) return !1;
1499
+ if (!c && _.type === "touchstart" && _.touches?.length > 1) return _.preventDefault(), !1;
1500
+ if (!v && !u && !y && b || !l && (_.type === "mousedown" || _.type === "touchstart") || Array.isArray(l) && !l.includes(_.button) && _.type === "mousedown") return !1;
1501
+ let x = Array.isArray(l) && l.includes(_.button) || !_.button || _.button <= 1;
1502
+ return (!_.ctrlKey || b) && x;
1504
1503
  };
1505
1504
  }
1506
- function Lt({ domNode: t, minZoom: n, maxZoom: o, translateExtent: c, viewport: l, onPanZoom: u, onPanZoomStart: d, onPanZoomEnd: f, onDraggingChange: p }) {
1507
- let m = {
1505
+ function XYPanZoom({ domNode: s, minZoom: c, maxZoom: f, translateExtent: m, viewport: h, onPanZoom: g, onPanZoomStart: _, onPanZoomEnd: v, onDraggingChange: y }) {
1506
+ let b = {
1508
1507
  isZoomingOrPanning: !1,
1509
1508
  usedRightMouseButton: !1,
1510
1509
  prevViewport: {
@@ -1516,98 +1515,98 @@ function Lt({ domNode: t, minZoom: n, maxZoom: o, translateExtent: c, viewport:
1516
1515
  timerId: void 0,
1517
1516
  panScrollTimeout: void 0,
1518
1517
  isPanScrolling: !1
1519
- }, h = t.getBoundingClientRect(), g = s().scaleExtent([n, o]).translateExtent(c), _ = e(t).call(g);
1520
- C({
1521
- x: l.x,
1522
- y: l.y,
1523
- zoom: N(l.zoom, n, o)
1524
- }, [[0, 0], [h.width, h.height]], c);
1525
- let v = _.on("wheel.zoom"), y = _.on("dblclick.zoom");
1526
- g.wheelDelta(At);
1527
- function b(e, t) {
1528
- return _ ? new Promise((n) => {
1529
- g?.interpolate(t?.interpolate === "linear" ? r : i).transform(kt(_, t?.duration, t?.ease, () => n(!0)), e);
1518
+ }, x = s.getBoundingClientRect(), S = zoom_default().scaleExtent([c, f]).translateExtent(m), C = select_default(s).call(S);
1519
+ k({
1520
+ x: h.x,
1521
+ y: h.y,
1522
+ zoom: clamp(h.zoom, c, f)
1523
+ }, [[0, 0], [x.width, x.height]], m);
1524
+ let w = C.on("wheel.zoom"), T = C.on("dblclick.zoom");
1525
+ S.wheelDelta(wheelDelta);
1526
+ function E(e, s) {
1527
+ return C ? new Promise((c) => {
1528
+ S?.interpolate(s?.interpolate === "linear" ? value_default : zoom_default$1).transform(getD3Transition(C, s?.duration, s?.ease, () => c(!0)), e);
1530
1529
  }) : Promise.resolve(!1);
1531
1530
  }
1532
- function x({ noWheelClassName: e, noPanClassName: t, onPaneContextMenu: n, userSelectionActive: r, panOnScroll: i, panOnDrag: a, panOnScrollMode: o, panOnScrollSpeed: s, preventScrolling: c, zoomOnPinch: l, zoomOnScroll: h, zoomOnDoubleClick: b, zoomActivationKeyPressed: x, lib: C, onTransformChange: w, connectionInProgress: T, paneClickDistance: E, selectionOnDrag: D }) {
1533
- r && !m.isZoomingOrPanning && S();
1534
- let O = i && !x && !r;
1535
- g.clickDistance(D ? Infinity : !U(E) || E < 0 ? 0 : E);
1536
- let k = O ? jt({
1537
- zoomPanValues: m,
1531
+ function D({ noWheelClassName: e, noPanClassName: s, onPaneContextMenu: c, userSelectionActive: l, panOnScroll: u, panOnDrag: d, panOnScrollMode: f, panOnScrollSpeed: p, preventScrolling: m, zoomOnPinch: h, zoomOnScroll: x, zoomOnDoubleClick: E, zoomActivationKeyPressed: D, lib: k, onTransformChange: A, connectionInProgress: j, paneClickDistance: M, selectionOnDrag: N }) {
1532
+ l && !b.isZoomingOrPanning && O();
1533
+ let P = u && !D && !l;
1534
+ S.clickDistance(N ? Infinity : !isNumeric(M) || M < 0 ? 0 : M);
1535
+ let F = P ? createPanOnScrollHandler({
1536
+ zoomPanValues: b,
1538
1537
  noWheelClassName: e,
1539
- d3Selection: _,
1540
- d3Zoom: g,
1541
- panOnScrollMode: o,
1542
- panOnScrollSpeed: s,
1543
- zoomOnPinch: l,
1544
- onPanZoomStart: d,
1545
- onPanZoom: u,
1546
- onPanZoomEnd: f
1547
- }) : Mt({
1538
+ d3Selection: C,
1539
+ d3Zoom: S,
1540
+ panOnScrollMode: f,
1541
+ panOnScrollSpeed: p,
1542
+ zoomOnPinch: h,
1543
+ onPanZoomStart: _,
1544
+ onPanZoom: g,
1545
+ onPanZoomEnd: v
1546
+ }) : createZoomOnScrollHandler({
1548
1547
  noWheelClassName: e,
1549
- preventScrolling: c,
1550
- d3ZoomHandler: v
1548
+ preventScrolling: m,
1549
+ d3ZoomHandler: w
1551
1550
  });
1552
- if (_.on("wheel.zoom", k, { passive: !1 }), !r) {
1553
- let e = Nt({
1554
- zoomPanValues: m,
1555
- onDraggingChange: p,
1556
- onPanZoomStart: d
1551
+ if (C.on("wheel.zoom", F, { passive: !1 }), !l) {
1552
+ let e = createPanZoomStartHandler({
1553
+ zoomPanValues: b,
1554
+ onDraggingChange: y,
1555
+ onPanZoomStart: _
1557
1556
  });
1558
- g.on("start", e);
1559
- let t = Pt({
1560
- zoomPanValues: m,
1561
- panOnDrag: a,
1562
- onPaneContextMenu: !!n,
1563
- onPanZoom: u,
1564
- onTransformChange: w
1557
+ S.on("start", e);
1558
+ let s = createPanZoomHandler({
1559
+ zoomPanValues: b,
1560
+ panOnDrag: d,
1561
+ onPaneContextMenu: !!c,
1562
+ onPanZoom: g,
1563
+ onTransformChange: A
1565
1564
  });
1566
- g.on("zoom", t);
1567
- let r = Ft({
1568
- zoomPanValues: m,
1569
- panOnDrag: a,
1570
- panOnScroll: i,
1571
- onPaneContextMenu: n,
1572
- onPanZoomEnd: f,
1573
- onDraggingChange: p
1565
+ S.on("zoom", s);
1566
+ let l = createPanZoomEndHandler({
1567
+ zoomPanValues: b,
1568
+ panOnDrag: d,
1569
+ panOnScroll: u,
1570
+ onPaneContextMenu: c,
1571
+ onPanZoomEnd: v,
1572
+ onDraggingChange: y
1574
1573
  });
1575
- g.on("end", r);
1574
+ S.on("end", l);
1576
1575
  }
1577
- let A = It({
1578
- zoomActivationKeyPressed: x,
1579
- panOnDrag: a,
1580
- zoomOnScroll: h,
1581
- panOnScroll: i,
1582
- zoomOnDoubleClick: b,
1583
- zoomOnPinch: l,
1584
- userSelectionActive: r,
1585
- noPanClassName: t,
1576
+ let I = createFilter({
1577
+ zoomActivationKeyPressed: D,
1578
+ panOnDrag: d,
1579
+ zoomOnScroll: x,
1580
+ panOnScroll: u,
1581
+ zoomOnDoubleClick: E,
1582
+ zoomOnPinch: h,
1583
+ userSelectionActive: l,
1584
+ noPanClassName: s,
1586
1585
  noWheelClassName: e,
1587
- lib: C,
1588
- connectionInProgress: T
1586
+ lib: k,
1587
+ connectionInProgress: j
1589
1588
  });
1590
- g.filter(A), b ? _.on("dblclick.zoom", y) : _.on("dblclick.zoom", null);
1589
+ S.filter(I), E ? C.on("dblclick.zoom", T) : C.on("dblclick.zoom", null);
1591
1590
  }
1592
- function S() {
1593
- g.on("zoom", null);
1591
+ function O() {
1592
+ S.on("zoom", null);
1594
1593
  }
1595
- async function C(e, t, n) {
1596
- let r = Et(e), i = g?.constrain()(r, t, n);
1597
- return i && await b(i), new Promise((e) => e(i));
1594
+ async function k(e, s, c) {
1595
+ let l = viewportToTransform(e), u = S?.constrain()(l, s, c);
1596
+ return u && await E(u), new Promise((e) => e(u));
1598
1597
  }
1599
- async function w(e, t) {
1600
- let n = Et(e);
1601
- return await b(n, t), new Promise((e) => e(n));
1598
+ async function A(e, s) {
1599
+ let c = viewportToTransform(e);
1600
+ return await E(c, s), new Promise((e) => e(c));
1602
1601
  }
1603
- function T(e) {
1604
- if (_) {
1605
- let t = Et(e), n = _.property("__zoom");
1606
- (n.k !== e.zoom || n.x !== e.x || n.y !== e.y) && g?.transform(_, t, null, { sync: !0 });
1602
+ function j(e) {
1603
+ if (C) {
1604
+ let s = viewportToTransform(e), c = C.property("__zoom");
1605
+ (c.k !== e.zoom || c.x !== e.x || c.y !== e.y) && S?.transform(C, s, null, { sync: !0 });
1607
1606
  }
1608
1607
  }
1609
- function E() {
1610
- let e = _ ? a(_.node()) : {
1608
+ function M() {
1609
+ let e = C ? transform(C.node()) : {
1611
1610
  x: 0,
1612
1611
  y: 0,
1613
1612
  k: 1
@@ -1618,49 +1617,49 @@ function Lt({ domNode: t, minZoom: n, maxZoom: o, translateExtent: c, viewport:
1618
1617
  zoom: e.k
1619
1618
  };
1620
1619
  }
1621
- function D(e, t) {
1622
- return _ ? new Promise((n) => {
1623
- g?.interpolate(t?.interpolate === "linear" ? r : i).scaleTo(kt(_, t?.duration, t?.ease, () => n(!0)), e);
1620
+ function N(e, s) {
1621
+ return C ? new Promise((c) => {
1622
+ S?.interpolate(s?.interpolate === "linear" ? value_default : zoom_default$1).scaleTo(getD3Transition(C, s?.duration, s?.ease, () => c(!0)), e);
1624
1623
  }) : Promise.resolve(!1);
1625
1624
  }
1626
- function O(e, t) {
1627
- return _ ? new Promise((n) => {
1628
- g?.interpolate(t?.interpolate === "linear" ? r : i).scaleBy(kt(_, t?.duration, t?.ease, () => n(!0)), e);
1625
+ function P(e, s) {
1626
+ return C ? new Promise((c) => {
1627
+ S?.interpolate(s?.interpolate === "linear" ? value_default : zoom_default$1).scaleBy(getD3Transition(C, s?.duration, s?.ease, () => c(!0)), e);
1629
1628
  }) : Promise.resolve(!1);
1630
1629
  }
1631
- function k(e) {
1632
- g?.scaleExtent(e);
1630
+ function F(e) {
1631
+ S?.scaleExtent(e);
1633
1632
  }
1634
- function A(e) {
1635
- g?.translateExtent(e);
1633
+ function I(e) {
1634
+ S?.translateExtent(e);
1636
1635
  }
1637
- function j(e) {
1638
- let t = !U(e) || e < 0 ? 0 : e;
1639
- g?.clickDistance(t);
1636
+ function L(e) {
1637
+ let s = !isNumeric(e) || e < 0 ? 0 : e;
1638
+ S?.clickDistance(s);
1640
1639
  }
1641
1640
  return {
1642
- update: x,
1643
- destroy: S,
1644
- setViewport: w,
1645
- setViewportConstrained: C,
1646
- getViewport: E,
1647
- scaleTo: D,
1648
- scaleBy: O,
1649
- setScaleExtent: k,
1650
- setTranslateExtent: A,
1651
- syncViewport: T,
1652
- setClickDistance: j
1641
+ update: D,
1642
+ destroy: O,
1643
+ setViewport: A,
1644
+ setViewportConstrained: k,
1645
+ getViewport: M,
1646
+ scaleTo: N,
1647
+ scaleBy: P,
1648
+ setScaleExtent: F,
1649
+ setTranslateExtent: I,
1650
+ syncViewport: j,
1651
+ setClickDistance: L
1653
1652
  };
1654
1653
  }
1655
- var Rt;
1654
+ var ResizeControlVariant;
1656
1655
  (function(e) {
1657
1656
  e.Line = "line", e.Handle = "handle";
1658
- })(Rt ||= {});
1659
- function zt({ width: e, prevWidth: t, height: n, prevHeight: r, affectsX: i, affectsY: a }) {
1660
- let o = e - t, s = n - r, c = [o > 0 ? 1 : o < 0 ? -1 : 0, s > 0 ? 1 : s < 0 ? -1 : 0];
1661
- return o && i && (c[0] *= -1), s && a && (c[1] *= -1), c;
1657
+ })(ResizeControlVariant ||= {});
1658
+ function getResizeDirection({ width: e, prevWidth: s, height: c, prevHeight: l, affectsX: u, affectsY: d }) {
1659
+ let f = e - s, p = c - l, m = [f > 0 ? 1 : f < 0 ? -1 : 0, p > 0 ? 1 : p < 0 ? -1 : 0];
1660
+ return f && u && (m[0] *= -1), p && d && (m[1] *= -1), m;
1662
1661
  }
1663
- function Bt(e) {
1662
+ function getControlDirection(e) {
1664
1663
  return {
1665
1664
  isHorizontal: e.includes("right") || e.includes("left"),
1666
1665
  isVertical: e.includes("bottom") || e.includes("top"),
@@ -1668,82 +1667,82 @@ function Bt(e) {
1668
1667
  affectsY: e.includes("top")
1669
1668
  };
1670
1669
  }
1671
- function Q(e, t) {
1672
- return Math.max(0, t - e);
1670
+ function getLowerExtentClamp(e, s) {
1671
+ return Math.max(0, s - e);
1673
1672
  }
1674
- function $(e, t) {
1675
- return Math.max(0, e - t);
1673
+ function getUpperExtentClamp(e, s) {
1674
+ return Math.max(0, e - s);
1676
1675
  }
1677
- function Vt(e, t, n) {
1678
- return Math.max(0, t - e, e - n);
1676
+ function getSizeClamp(e, s, c) {
1677
+ return Math.max(0, s - e, e - c);
1679
1678
  }
1680
- function Ht(e, t) {
1681
- return e ? !t : t;
1679
+ function xor(e, s) {
1680
+ return e ? !s : s;
1682
1681
  }
1683
- function Ut(e, t, n, r, i, a, o, s) {
1684
- let { affectsX: c, affectsY: l } = t, { isHorizontal: u, isVertical: d } = t, f = u && d, { xSnapped: p, ySnapped: m } = n, { minWidth: h, maxWidth: g, minHeight: _, maxHeight: v } = r, { x: y, y: b, width: x, height: S, aspectRatio: C } = e, w = Math.floor(u ? p - e.pointerX : 0), T = Math.floor(d ? m - e.pointerY : 0), E = x + (c ? -w : w), D = S + (l ? -T : T), O = -a[0] * x, k = -a[1] * S, A = Vt(E, h, g), j = Vt(D, _, v);
1685
- if (o) {
1686
- let e = 0, t = 0;
1687
- c && w < 0 ? e = Q(y + w + O, o[0][0]) : !c && w > 0 && (e = $(y + E + O, o[1][0])), l && T < 0 ? t = Q(b + T + k, o[0][1]) : !l && T > 0 && (t = $(b + D + k, o[1][1])), A = Math.max(A, e), j = Math.max(j, t);
1682
+ function getDimensionsAfterResize(e, s, c, l, u, d, f, p) {
1683
+ let { affectsX: m, affectsY: h } = s, { isHorizontal: g, isVertical: _ } = s, v = g && _, { xSnapped: y, ySnapped: b } = c, { minWidth: x, maxWidth: S, minHeight: C, maxHeight: w } = l, { x: T, y: E, width: D, height: O, aspectRatio: k } = e, A = Math.floor(g ? y - e.pointerX : 0), j = Math.floor(_ ? b - e.pointerY : 0), M = D + (m ? -A : A), N = O + (h ? -j : j), P = -d[0] * D, F = -d[1] * O, I = getSizeClamp(M, x, S), L = getSizeClamp(N, C, w);
1684
+ if (f) {
1685
+ let e = 0, s = 0;
1686
+ m && A < 0 ? e = getLowerExtentClamp(T + A + P, f[0][0]) : !m && A > 0 && (e = getUpperExtentClamp(T + M + P, f[1][0])), h && j < 0 ? s = getLowerExtentClamp(E + j + F, f[0][1]) : !h && j > 0 && (s = getUpperExtentClamp(E + N + F, f[1][1])), I = Math.max(I, e), L = Math.max(L, s);
1688
1687
  }
1689
- if (s) {
1690
- let e = 0, t = 0;
1691
- c && w > 0 ? e = $(y + w, s[0][0]) : !c && w < 0 && (e = Q(y + E, s[1][0])), l && T > 0 ? t = $(b + T, s[0][1]) : !l && T < 0 && (t = Q(b + D, s[1][1])), A = Math.max(A, e), j = Math.max(j, t);
1688
+ if (p) {
1689
+ let e = 0, s = 0;
1690
+ m && A > 0 ? e = getUpperExtentClamp(T + A, p[0][0]) : !m && A < 0 && (e = getLowerExtentClamp(T + M, p[1][0])), h && j > 0 ? s = getUpperExtentClamp(E + j, p[0][1]) : !h && j < 0 && (s = getLowerExtentClamp(E + N, p[1][1])), I = Math.max(I, e), L = Math.max(L, s);
1692
1691
  }
1693
- if (i) {
1694
- if (u) {
1695
- let e = Vt(E / C, _, v) * C;
1696
- if (A = Math.max(A, e), o) {
1692
+ if (u) {
1693
+ if (g) {
1694
+ let e = getSizeClamp(M / k, C, w) * k;
1695
+ if (I = Math.max(I, e), f) {
1697
1696
  let e = 0;
1698
- e = !c && !l || c && !l && f ? $(b + k + E / C, o[1][1]) * C : Q(b + k + (c ? w : -w) / C, o[0][1]) * C, A = Math.max(A, e);
1697
+ e = !m && !h || m && !h && v ? getUpperExtentClamp(E + F + M / k, f[1][1]) * k : getLowerExtentClamp(E + F + (m ? A : -A) / k, f[0][1]) * k, I = Math.max(I, e);
1699
1698
  }
1700
- if (s) {
1699
+ if (p) {
1701
1700
  let e = 0;
1702
- e = !c && !l || c && !l && f ? Q(b + E / C, s[1][1]) * C : $(b + (c ? w : -w) / C, s[0][1]) * C, A = Math.max(A, e);
1701
+ e = !m && !h || m && !h && v ? getLowerExtentClamp(E + M / k, p[1][1]) * k : getUpperExtentClamp(E + (m ? A : -A) / k, p[0][1]) * k, I = Math.max(I, e);
1703
1702
  }
1704
1703
  }
1705
- if (d) {
1706
- let e = Vt(D * C, h, g) / C;
1707
- if (j = Math.max(j, e), o) {
1704
+ if (_) {
1705
+ let e = getSizeClamp(N * k, x, S) / k;
1706
+ if (L = Math.max(L, e), f) {
1708
1707
  let e = 0;
1709
- e = !c && !l || l && !c && f ? $(y + D * C + O, o[1][0]) / C : Q(y + (l ? T : -T) * C + O, o[0][0]) / C, j = Math.max(j, e);
1708
+ e = !m && !h || h && !m && v ? getUpperExtentClamp(T + N * k + P, f[1][0]) / k : getLowerExtentClamp(T + (h ? j : -j) * k + P, f[0][0]) / k, L = Math.max(L, e);
1710
1709
  }
1711
- if (s) {
1710
+ if (p) {
1712
1711
  let e = 0;
1713
- e = !c && !l || l && !c && f ? Q(y + D * C, s[1][0]) / C : $(y + (l ? T : -T) * C, s[0][0]) / C, j = Math.max(j, e);
1712
+ e = !m && !h || h && !m && v ? getLowerExtentClamp(T + N * k, p[1][0]) / k : getUpperExtentClamp(T + (h ? j : -j) * k, p[0][0]) / k, L = Math.max(L, e);
1714
1713
  }
1715
1714
  }
1716
1715
  }
1717
- T += T < 0 ? j : -j, w += w < 0 ? A : -A, i && (f ? E > D * C ? T = (Ht(c, l) ? -w : w) / C : w = (Ht(c, l) ? -T : T) * C : u ? (T = w / C, l = c) : (w = T * C, c = l));
1718
- let M = c ? y + w : y, N = l ? b + T : b;
1716
+ j += j < 0 ? L : -L, A += A < 0 ? I : -I, u && (v ? M > N * k ? j = (xor(m, h) ? -A : A) / k : A = (xor(m, h) ? -j : j) * k : g ? (j = A / k, h = m) : (A = j * k, m = h));
1717
+ let R = m ? T + A : T, z = h ? E + j : E;
1719
1718
  return {
1720
- width: x + (c ? -w : w),
1721
- height: S + (l ? -T : T),
1722
- x: a[0] * w * (c ? -1 : 1) + M,
1723
- y: a[1] * T * (l ? -1 : 1) + N
1719
+ width: D + (m ? -A : A),
1720
+ height: O + (h ? -j : j),
1721
+ x: d[0] * A * (m ? -1 : 1) + R,
1722
+ y: d[1] * j * (h ? -1 : 1) + z
1724
1723
  };
1725
1724
  }
1726
- var Wt = {
1725
+ var initPrevValues = {
1727
1726
  width: 0,
1728
1727
  height: 0,
1729
1728
  x: 0,
1730
1729
  y: 0
1731
- }, Gt = {
1732
- ...Wt,
1730
+ }, initStartValues = {
1731
+ ...initPrevValues,
1733
1732
  pointerX: 0,
1734
1733
  pointerY: 0,
1735
1734
  aspectRatio: 1
1736
1735
  };
1737
- function Kt(e) {
1736
+ function nodeToParentExtent(e) {
1738
1737
  return [[0, 0], [e.measured.width, e.measured.height]];
1739
1738
  }
1740
- function qt(e, t, n) {
1741
- let r = t.position.x + e.position.x, i = t.position.y + e.position.y, a = e.measured.width ?? 0, o = e.measured.height ?? 0, s = n[0] * a, c = n[1] * o;
1742
- return [[r - s, i - c], [r + a - s, i + o - c]];
1739
+ function nodeToChildExtent(e, s, c) {
1740
+ let l = s.position.x + e.position.x, u = s.position.y + e.position.y, d = e.measured.width ?? 0, f = e.measured.height ?? 0, p = c[0] * d, m = c[1] * f;
1741
+ return [[l - p, u - m], [l + d - p, u + f - m]];
1743
1742
  }
1744
- function Jt({ domNode: t, nodeId: r, getStoreItems: i, onChange: a, onEnd: o }) {
1745
- let s = e(t), c = {
1746
- controlDirection: Bt("bottom-right"),
1743
+ function XYResizer({ domNode: s, nodeId: l, getStoreItems: u, onChange: d, onEnd: f }) {
1744
+ let p = select_default(s), m = {
1745
+ controlDirection: getControlDirection("bottom-right"),
1747
1746
  boundaries: {
1748
1747
  minWidth: 0,
1749
1748
  minHeight: 0,
@@ -1753,91 +1752,90 @@ function Jt({ domNode: t, nodeId: r, getStoreItems: i, onChange: a, onEnd: o })
1753
1752
  resizeDirection: void 0,
1754
1753
  keepAspectRatio: !1
1755
1754
  };
1756
- function l({ controlPosition: e, boundaries: t, keepAspectRatio: l, resizeDirection: u, onResizeStart: d, onResize: f, onResizeEnd: p, shouldResize: m }) {
1757
- let h = { ...Wt }, g = { ...Gt };
1758
- c = {
1759
- boundaries: t,
1760
- resizeDirection: u,
1761
- keepAspectRatio: l,
1762
- controlDirection: Bt(e)
1755
+ function h({ controlPosition: e, boundaries: s, keepAspectRatio: h, resizeDirection: g, onResizeStart: _, onResize: v, onResizeEnd: y, shouldResize: b }) {
1756
+ let x = { ...initPrevValues }, S = { ...initStartValues };
1757
+ m = {
1758
+ boundaries: s,
1759
+ resizeDirection: g,
1760
+ keepAspectRatio: h,
1761
+ controlDirection: getControlDirection(e)
1763
1762
  };
1764
- let _, v = null, y = [], b, x, S, C = !1, w = n().on("start", (e) => {
1765
- let { nodeLookup: t, transform: n, snapGrid: a, snapToGrid: o, nodeOrigin: s, paneDomNode: c } = i();
1766
- if (_ = t.get(r), !_) return;
1767
- v = c?.getBoundingClientRect() ?? null;
1768
- let { xSnapped: l, ySnapped: u } = me(e.sourceEvent, {
1769
- transform: n,
1770
- snapGrid: a,
1771
- snapToGrid: o,
1772
- containerBounds: v
1763
+ let C, w = null, T = [], E, D, O, k = !1, A = drag_default().on("start", (e) => {
1764
+ let { nodeLookup: s, transform: c, snapGrid: d, snapToGrid: f, nodeOrigin: p, paneDomNode: m } = u();
1765
+ if (C = s.get(l), !C) return;
1766
+ w = m?.getBoundingClientRect() ?? null;
1767
+ let { xSnapped: h, ySnapped: g } = getPointerPosition(e.sourceEvent, {
1768
+ transform: c,
1769
+ snapGrid: d,
1770
+ snapToGrid: f,
1771
+ containerBounds: w
1773
1772
  });
1774
- h = {
1775
- width: _.measured.width ?? 0,
1776
- height: _.measured.height ?? 0,
1777
- x: _.position.x ?? 0,
1778
- y: _.position.y ?? 0
1779
- }, g = {
1780
- ...h,
1781
- pointerX: l,
1782
- pointerY: u,
1783
- aspectRatio: h.width / h.height
1784
- }, b = void 0, _.parentId && (_.extent === "parent" || _.expandParent) && (b = t.get(_.parentId), x = b && _.extent === "parent" ? Kt(b) : void 0), y = [], S = void 0;
1785
- for (let [e, n] of t) if (n.parentId === r && (y.push({
1773
+ x = {
1774
+ width: C.measured.width ?? 0,
1775
+ height: C.measured.height ?? 0,
1776
+ x: C.position.x ?? 0,
1777
+ y: C.position.y ?? 0
1778
+ }, S = {
1779
+ ...x,
1780
+ pointerX: h,
1781
+ pointerY: g,
1782
+ aspectRatio: x.width / x.height
1783
+ }, E = void 0, C.parentId && (C.extent === "parent" || C.expandParent) && (E = s.get(C.parentId), D = E && C.extent === "parent" ? nodeToParentExtent(E) : void 0), T = [], O = void 0;
1784
+ for (let [e, c] of s) if (c.parentId === l && (T.push({
1786
1785
  id: e,
1787
- position: { ...n.position },
1788
- extent: n.extent
1789
- }), n.extent === "parent" || n.expandParent)) {
1790
- let e = qt(n, _, n.origin ?? s);
1791
- S = S ? [[Math.min(e[0][0], S[0][0]), Math.min(e[0][1], S[0][1])], [Math.max(e[1][0], S[1][0]), Math.max(e[1][1], S[1][1])]] : e;
1786
+ position: { ...c.position },
1787
+ extent: c.extent
1788
+ }), c.extent === "parent" || c.expandParent)) {
1789
+ let e = nodeToChildExtent(c, C, c.origin ?? p);
1790
+ O = O ? [[Math.min(e[0][0], O[0][0]), Math.min(e[0][1], O[0][1])], [Math.max(e[1][0], O[1][0]), Math.max(e[1][1], O[1][1])]] : e;
1792
1791
  }
1793
- d?.(e, { ...h });
1792
+ _?.(e, { ...x });
1794
1793
  }).on("drag", (e) => {
1795
- let { transform: t, snapGrid: n, snapToGrid: r, nodeOrigin: o } = i(), s = me(e.sourceEvent, {
1796
- transform: t,
1797
- snapGrid: n,
1798
- snapToGrid: r,
1799
- containerBounds: v
1800
- }), l = [];
1801
- if (!_) return;
1802
- let { x: u, y: d, width: p, height: w } = h, T = {}, E = _.origin ?? o, { width: D, height: O, x: k, y: A } = Ut(g, c.controlDirection, s, c.boundaries, c.keepAspectRatio, E, x, S), j = D !== p, M = O !== w, N = k !== u && j, P = A !== d && M;
1803
- if (!N && !P && !j && !M) return;
1804
- if ((N || P || E[0] === 1 || E[1] === 1) && (T.x = N ? k : h.x, T.y = P ? A : h.y, h.x = T.x, h.y = T.y, y.length > 0)) {
1805
- let e = k - u, t = A - d;
1806
- for (let n of y) n.position = {
1807
- x: n.position.x - e + E[0] * (D - p),
1808
- y: n.position.y - t + E[1] * (O - w)
1809
- }, l.push(n);
1794
+ let { transform: s, snapGrid: c, snapToGrid: l, nodeOrigin: f } = u(), p = getPointerPosition(e.sourceEvent, {
1795
+ transform: s,
1796
+ snapGrid: c,
1797
+ snapToGrid: l,
1798
+ containerBounds: w
1799
+ }), h = [];
1800
+ if (!C) return;
1801
+ let { x: g, y: _, width: y, height: A } = x, j = {}, M = C.origin ?? f, { width: N, height: P, x: F, y: I } = getDimensionsAfterResize(S, m.controlDirection, p, m.boundaries, m.keepAspectRatio, M, D, O), L = N !== y, R = P !== A, z = F !== g && L, B = I !== _ && R;
1802
+ if (!z && !B && !L && !R) return;
1803
+ if ((z || B || M[0] === 1 || M[1] === 1) && (j.x = z ? F : x.x, j.y = B ? I : x.y, x.x = j.x, x.y = j.y, T.length > 0)) {
1804
+ let e = F - g, s = I - _;
1805
+ for (let c of T) c.position = {
1806
+ x: c.position.x - e + M[0] * (N - y),
1807
+ y: c.position.y - s + M[1] * (P - A)
1808
+ }, h.push(c);
1810
1809
  }
1811
- if ((j || M) && (T.width = j && (!c.resizeDirection || c.resizeDirection === "horizontal") ? D : h.width, T.height = M && (!c.resizeDirection || c.resizeDirection === "vertical") ? O : h.height, h.width = T.width, h.height = T.height), b && _.expandParent) {
1812
- let e = E[0] * (T.width ?? 0);
1813
- T.x && T.x < e && (h.x = e, g.x -= T.x - e);
1814
- let t = E[1] * (T.height ?? 0);
1815
- T.y && T.y < t && (h.y = t, g.y -= T.y - t);
1810
+ if ((L || R) && (j.width = L && (!m.resizeDirection || m.resizeDirection === "horizontal") ? N : x.width, j.height = R && (!m.resizeDirection || m.resizeDirection === "vertical") ? P : x.height, x.width = j.width, x.height = j.height), E && C.expandParent) {
1811
+ let e = M[0] * (j.width ?? 0);
1812
+ j.x && j.x < e && (x.x = e, S.x -= j.x - e);
1813
+ let s = M[1] * (j.height ?? 0);
1814
+ j.y && j.y < s && (x.y = s, S.y -= j.y - s);
1816
1815
  }
1817
- let F = zt({
1818
- width: h.width,
1819
- prevWidth: p,
1820
- height: h.height,
1821
- prevHeight: w,
1822
- affectsX: c.controlDirection.affectsX,
1823
- affectsY: c.controlDirection.affectsY
1824
- }), I = {
1825
- ...h,
1826
- direction: F
1816
+ let V = getResizeDirection({
1817
+ width: x.width,
1818
+ prevWidth: y,
1819
+ height: x.height,
1820
+ prevHeight: A,
1821
+ affectsX: m.controlDirection.affectsX,
1822
+ affectsY: m.controlDirection.affectsY
1823
+ }), H = {
1824
+ ...x,
1825
+ direction: V
1827
1826
  };
1828
- m?.(e, I) !== !1 && (C = !0, f?.(e, I), a(T, l));
1827
+ b?.(e, H) !== !1 && (k = !0, v?.(e, H), d(j, h));
1829
1828
  }).on("end", (e) => {
1830
- C &&= (p?.(e, { ...h }), o?.({ ...h }), !1);
1829
+ k &&= (y?.(e, { ...x }), f?.({ ...x }), !1);
1831
1830
  });
1832
- s.call(w);
1831
+ p.call(A);
1833
1832
  }
1834
- function u() {
1835
- s.on(".drag", null);
1833
+ function g() {
1834
+ p.on(".drag", null);
1836
1835
  }
1837
1836
  return {
1838
- update: l,
1839
- destroy: u
1837
+ update: h,
1838
+ destroy: g
1840
1839
  };
1841
1840
  }
1842
- //#endregion
1843
- export { g as ConnectionLineType, f as ConnectionMode, _ as MarkerType, p as PanOnScrollMode, v as Position, Rt as ResizeControlVariant, m as SelectionMode, pt as XYDrag, Ct as XYHandle, wt as XYMinimap, Lt as XYPanZoom, Jt as XYResizer, Ae as addEdge, Qe as adoptUserNodes, de as areSetsEqual, j as calculateNodePosition, Ue as createMarkerIds, d as defaultAriaLabelConfig, W as devWarn, u as elementSelectionKeys, c as errorMessages, ue as evaluateAbsolutePosition, A as fitViewport, xe as getBezierEdgeCenter, we as getBezierPath, B as getBoundsOfRects, O as getConnectedEdges, b as getConnectionStatus, he as getDimensions, Te as getEdgeCenter, ze as getEdgePosition, M as getElementsToRemove, Ee as getElevatedEdgeZIndex, Y as getEventPosition, X as getHandlePosition, ge as getHostForElement, E as getInternalNodesBounds, He as getMarkerId, J as getNodeDimensions, T as getNodesBounds, D as getNodesInside, V as getOverlappingArea, Le as getSmoothStepPath, je as getStraightPath, se as getViewportForBounds, rt as handleExpandParent, l as infiniteExtent, h as initialConnection, x as isEdgeBase, De as isEdgeVisible, ve as isInputDOMNode, ce as isMacOs, ye as isMouseEvent, S as isNodeBase, U as isNumeric, H as isRectObject, pe as mergeAriaLabelConfig, le as nodeHasDimensions, z as nodeToRect, at as panBy, re as pointToRendererPoint, ie as rendererPointToPoint, G as snapPosition, Ye as updateAbsolutePositions, st as updateConnectionLookup, it as updateNodeInternals, fe as withResolvers };
1841
+ export { ConnectionLineType, ConnectionMode, MarkerType, PanOnScrollMode, Position, ResizeControlVariant, SelectionMode, XYDrag, XYHandle, XYMinimap, XYPanZoom, XYResizer, addEdge, adoptUserNodes, areSetsEqual, calculateNodePosition, createMarkerIds, defaultAriaLabelConfig, devWarn, elementSelectionKeys, errorMessages, evaluateAbsolutePosition, fitViewport, getBezierEdgeCenter, getBezierPath, getBoundsOfRects, getConnectedEdges, getConnectionStatus, getDimensions, getEdgeCenter, getEdgePosition, getElementsToRemove, getElevatedEdgeZIndex, getEventPosition, getHandlePosition, getHostForElement, getInternalNodesBounds, getMarkerId, getNodeDimensions, getNodesBounds, getNodesInside, getOverlappingArea, getSmoothStepPath, getStraightPath, getViewportForBounds, handleExpandParent, infiniteExtent, initialConnection, isEdgeBase, isEdgeVisible, isInputDOMNode, isMacOs, isMouseEvent, isNodeBase, isNumeric, isRectObject, mergeAriaLabelConfig, nodeHasDimensions, nodeToRect, panBy, pointToRendererPoint, rendererPointToPoint, snapPosition, updateAbsolutePositions, updateConnectionLookup, updateNodeInternals, withResolvers };