@loopstack/loopstack-studio 0.25.0 → 0.25.1

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 (1746) hide show
  1. package/dist/_virtual/_rolldown/runtime.js +20 -0
  2. package/dist/api/auth.js +4 -2
  3. package/dist/api/client.js +9 -7
  4. package/dist/api/config.js +4 -2
  5. package/dist/api/dashboard.js +4 -2
  6. package/dist/api/documents.js +4 -2
  7. package/dist/api/index.js +21 -19
  8. package/dist/api/processor.js +4 -2
  9. package/dist/api/secrets.js +4 -2
  10. package/dist/api/workflows.js +4 -2
  11. package/dist/api/workspaces.js +4 -2
  12. package/dist/app/EnvironmentEmbedRoot.js +24 -31
  13. package/dist/components/ai-elements/code-block.js +53 -71
  14. package/dist/components/ai-elements/message.js +41 -82
  15. package/dist/components/ai-elements/prompt-input.js +162 -253
  16. package/dist/components/ai-elements/reasoning.js +78 -116
  17. package/dist/components/ai-elements/shimmer.js +23 -35
  18. package/dist/components/ai-elements/sources.js +29 -58
  19. package/dist/components/data-table/ConfirmDialog.js +14 -30
  20. package/dist/components/data-table/DataList.js +138 -198
  21. package/dist/components/data-table/DataTable.js +168 -234
  22. package/dist/components/data-table/DataTableBatchAction.js +18 -27
  23. package/dist/components/data-table/DataTableFilters.js +53 -78
  24. package/dist/components/data-table/DataTablePagination.js +72 -104
  25. package/dist/components/data-table/DataTableToolbar.js +53 -65
  26. package/dist/components/dynamic-form/ArrayController.js +85 -103
  27. package/dist/components/dynamic-form/CodeContent.js +28 -36
  28. package/dist/components/dynamic-form/Form.js +43 -56
  29. package/dist/components/dynamic-form/FormBody.js +12 -10
  30. package/dist/components/dynamic-form/FormElement.js +31 -41
  31. package/dist/components/dynamic-form/FormElementHeader.js +12 -20
  32. package/dist/components/dynamic-form/InputController.js +36 -38
  33. package/dist/components/dynamic-form/MarkdownContent.js +53 -74
  34. package/dist/components/dynamic-form/MermaidDiagram.js +22 -24
  35. package/dist/components/dynamic-form/ObjectController.js +24 -32
  36. package/dist/components/dynamic-form/fields/BaseFieldWrapper.js +35 -47
  37. package/dist/components/dynamic-form/fields/CheckboxField.js +39 -48
  38. package/dist/components/dynamic-form/fields/CodeViewField.js +42 -50
  39. package/dist/components/dynamic-form/fields/InputField.js +62 -90
  40. package/dist/components/dynamic-form/fields/MarkdownViewField.js +16 -19
  41. package/dist/components/dynamic-form/fields/RadioField.js +46 -62
  42. package/dist/components/dynamic-form/fields/SelectField.js +40 -58
  43. package/dist/components/dynamic-form/fields/SliderField.js +94 -100
  44. package/dist/components/dynamic-form/fields/SwitchField.js +42 -61
  45. package/dist/components/dynamic-form/fields/TextareaField.js +53 -72
  46. package/dist/components/dynamic-form/fields/utils/text-validation-utils.js +4 -2
  47. package/dist/components/dynamic-form/hooks/useArrayDefaultValue.js +6 -5
  48. package/dist/components/dynamic-form/hooks/useFieldConfig.js +19 -20
  49. package/dist/components/dynamic-form/hooks/useMergeParentKey.js +4 -2
  50. package/dist/components/dynamic-form/hooks/useSortPropertyNames.js +4 -2
  51. package/dist/components/feedback/ErrorAlert.js +11 -17
  52. package/dist/components/feedback/ErrorBoundary.js +16 -14
  53. package/dist/components/feedback/ErrorSnackbar.js +13 -30
  54. package/dist/components/feedback/LoadingCentered.js +15 -28
  55. package/dist/components/feedback/Snackbar.js +43 -44
  56. package/dist/components/feedback/index.js +5 -5
  57. package/dist/components/index.js +47 -47
  58. package/dist/components/layout/MainLayout.js +17 -25
  59. package/dist/components/layout/StudioSidebar.js +132 -202
  60. package/dist/components/lists/CustomListView.js +49 -74
  61. package/dist/components/lists/ListView.js +66 -102
  62. package/dist/components/loopstack-elements/link.js +65 -104
  63. package/dist/components/loopstack-elements/tool.js +70 -142
  64. package/dist/components/messages/CompletionMessagePaper.js +53 -85
  65. package/dist/components/page/PageBreadcrumbs.js +64 -83
  66. package/dist/components/ui/DiscordLogo.js +16 -22
  67. package/dist/components/ui/GoogleLogo.js +40 -44
  68. package/dist/components/ui/accordion.js +31 -52
  69. package/dist/components/ui/alert-dialog.js +59 -109
  70. package/dist/components/ui/alert.js +22 -36
  71. package/dist/components/ui/avatar.js +21 -35
  72. package/dist/components/ui/badge.js +13 -17
  73. package/dist/components/ui/breadcrumb.js +46 -82
  74. package/dist/components/ui/button-group.js +5 -5
  75. package/dist/components/ui/button.js +17 -21
  76. package/dist/components/ui/card.js +40 -74
  77. package/dist/components/ui/checkbox.js +17 -23
  78. package/dist/components/ui/collapsible.js +17 -25
  79. package/dist/components/ui/command.js +1 -2
  80. package/dist/components/ui/context-menu.js +32 -52
  81. package/dist/components/ui/dialog.js +62 -107
  82. package/dist/components/ui/drawer.js +54 -99
  83. package/dist/components/ui/dropdown-menu.js +91 -159
  84. package/dist/components/ui/hover-card.js +1 -2
  85. package/dist/components/ui/input-group.js +36 -56
  86. package/dist/components/ui/input.js +11 -15
  87. package/dist/components/ui/label.js +11 -15
  88. package/dist/components/ui/popover.js +25 -38
  89. package/dist/components/ui/radio-group.js +22 -33
  90. package/dist/components/ui/scroll-area.js +28 -43
  91. package/dist/components/ui/select.js +73 -134
  92. package/dist/components/ui/separator.js +13 -17
  93. package/dist/components/ui/sheet.js +60 -105
  94. package/dist/components/ui/sidebar.js +269 -451
  95. package/dist/components/ui/skeleton.js +10 -14
  96. package/dist/components/ui/slider.js +17 -15
  97. package/dist/components/ui/switch.js +15 -21
  98. package/dist/components/ui/table.js +46 -85
  99. package/dist/components/ui/tabs.js +26 -45
  100. package/dist/components/ui/textarea.js +10 -14
  101. package/dist/components/ui/tooltip.js +26 -41
  102. package/dist/components/ui-widgets/UiActions.js +30 -37
  103. package/dist/components/ui-widgets/UiWidget.js +34 -46
  104. package/dist/components/ui-widgets/widgets/AiPromptInput.js +28 -42
  105. package/dist/components/ui-widgets/widgets/ButtonFullWidth.js +16 -21
  106. package/dist/components/ui-widgets/widgets/SandboxRun.js +19 -26
  107. package/dist/components/ui-widgets/widgets/SubmitButton.js +15 -20
  108. package/dist/events/api-client-events.js +4 -2
  109. package/dist/events/sse-client-events.js +4 -2
  110. package/dist/features/code-explorer/CodeExplorer.js +1 -2
  111. package/dist/features/code-explorer/components/CodeExplorerTree.js +2 -2
  112. package/dist/features/code-explorer/components/CodeExplorerTreeNode.js +31 -29
  113. package/dist/features/code-explorer/components/FileContentViewer.js +108 -148
  114. package/dist/features/code-explorer/components/FileTabsBar.js +1 -2
  115. package/dist/features/code-explorer/components/FileTabsBarBase.js +134 -169
  116. package/dist/features/code-explorer/index.js +1 -1
  117. package/dist/features/code-explorer/providers/CodeExplorerProvider.js +4 -4
  118. package/dist/features/code-explorer/utils/fileIcons.js +41 -39
  119. package/dist/features/dashboard/Dashboard.js +79 -121
  120. package/dist/features/dashboard/RunItem.js +50 -68
  121. package/dist/features/dashboard/RunList.js +17 -28
  122. package/dist/features/debug/components/ConfigFlowViewer.js +49 -67
  123. package/dist/features/debug/components/WorkflowDebugHeader.js +30 -46
  124. package/dist/features/debug/components/WorkflowDebugLegend.js +56 -68
  125. package/dist/features/debug/components/WorkflowFlowViewer.js +76 -96
  126. package/dist/features/debug/components/workflow-flow/StateNode.js +73 -102
  127. package/dist/features/debug/components/workflow-flow/WorkflowGraph.js +35 -40
  128. package/dist/features/debug/components/workflow-flow/WorkflowTransitionEdge.js +61 -94
  129. package/dist/features/debug/index.js +3 -3
  130. package/dist/features/debug/lib/edge-paths.js +33 -31
  131. package/dist/features/debug/lib/flow-utils.js +147 -145
  132. package/dist/features/documents/DocumentRenderer.js +73 -77
  133. package/dist/features/documents/components/DocumentItem.js +21 -24
  134. package/dist/features/documents/components/DocumentList.js +39 -45
  135. package/dist/features/documents/components/DocumentMetadataPills.js +44 -59
  136. package/dist/features/documents/document-details/DocumentDetails.js +298 -413
  137. package/dist/features/documents/document-details/PromptDetails.js +105 -142
  138. package/dist/features/documents/index.js +4 -4
  139. package/dist/features/documents/renderers/AiMessage.js +39 -48
  140. package/dist/features/documents/renderers/AiMessageContent.js +108 -164
  141. package/dist/features/documents/renderers/ChoicesRenderer.js +77 -89
  142. package/dist/features/documents/renderers/ClaudeMessage.js +74 -91
  143. package/dist/features/documents/renderers/ConfirmPromptRenderer.js +44 -53
  144. package/dist/features/documents/renderers/DocumentDebugRenderer.js +26 -30
  145. package/dist/features/documents/renderers/DocumentFormRenderer.js +69 -85
  146. package/dist/features/documents/renderers/DocumentMessageRenderer.js +10 -9
  147. package/dist/features/documents/renderers/ErrorMessageRenderer.js +11 -13
  148. package/dist/features/documents/renderers/LinkMessageRenderer.js +15 -14
  149. package/dist/features/documents/renderers/MarkdownMessageRenderer.js +8 -10
  150. package/dist/features/documents/renderers/PlainMessageRenderer.js +7 -9
  151. package/dist/features/documents/renderers/SecretInputRenderer.js +37 -35
  152. package/dist/features/documents/renderers/TextPromptRenderer.js +45 -54
  153. package/dist/features/documents/renderers/useDocumentTransition.js +9 -7
  154. package/dist/features/health/LocalHealthCheck.js +54 -53
  155. package/dist/features/health/index.js +1 -1
  156. package/dist/features/oauth/OAuthCallbackPage.js +2 -2
  157. package/dist/features/oauth/OAuthPromptRenderer.js +148 -197
  158. package/dist/features/oauth/index.js +2 -2
  159. package/dist/features/oauth/useOAuthPopup.js +52 -71
  160. package/dist/features/runs/Runs.js +145 -187
  161. package/dist/features/workbench/Workbench.js +72 -98
  162. package/dist/features/workbench/WorkflowItem.js +49 -68
  163. package/dist/features/workbench/WorkflowList.js +51 -66
  164. package/dist/features/workbench/components/NewRunDialog.js +212 -309
  165. package/dist/features/workbench/components/RemoteFileTabsBar.js +18 -17
  166. package/dist/features/workbench/components/RemoteFileTree.js +54 -85
  167. package/dist/features/workbench/components/WorkbenchFilesPanel.js +52 -63
  168. package/dist/features/workbench/components/WorkbenchFloatingPanel.js +34 -51
  169. package/dist/features/workbench/components/WorkbenchFlowPanel.js +35 -44
  170. package/dist/features/workbench/components/WorkbenchIconSidebar.js +50 -68
  171. package/dist/features/workbench/components/WorkbenchPreviewPanel.js +51 -49
  172. package/dist/features/workbench/components/WorkbenchSecretsPanel.js +143 -172
  173. package/dist/features/workbench/components/WorkbenchSettingsModal.js +49 -60
  174. package/dist/features/workbench/components/WorkflowForms.js +17 -23
  175. package/dist/features/workbench/components/WorkflowHistoryItem.js +96 -122
  176. package/dist/features/workbench/components/WorkflowHistoryList.js +31 -54
  177. package/dist/features/workbench/components/buttons/WorkflowButtons.js +70 -99
  178. package/dist/features/workbench/hooks/useAutoScrollBottom.js +21 -25
  179. package/dist/features/workbench/hooks/useScrollToListItem.js +20 -21
  180. package/dist/features/workbench/hooks/useWorkflowData.js +31 -44
  181. package/dist/features/workbench/hooks/useWorkflowListState.js +13 -12
  182. package/dist/features/workbench/index.js +7 -7
  183. package/dist/features/workbench/providers/RemoteFileExplorerProvider.js +123 -138
  184. package/dist/features/workbench/providers/ScrollProvider.js +15 -19
  185. package/dist/features/workbench/providers/WorkbenchLayoutProvider.js +76 -75
  186. package/dist/features/workspaces/Workspaces.js +161 -226
  187. package/dist/features/workspaces/components/CreateWorkspace.js +137 -194
  188. package/dist/features/workspaces/components/EnvironmentSlotSelector.js +27 -25
  189. package/dist/features/workspaces/components/ExecutionTimeline.js +143 -185
  190. package/dist/features/workspaces/components/NewWorkflowRunDialog.js +18 -26
  191. package/dist/features/workspaces/components/WorkflowRunForm.js +85 -133
  192. package/dist/features/workspaces/components/WorkspaceHomePage.js +59 -80
  193. package/dist/features/workspaces/components/workflow-form/ArgumentsView.js +52 -69
  194. package/dist/features/workspaces/components/workflow-form/HeaderSection.js +27 -41
  195. package/dist/features/workspaces/components/workflow-form/SelectionView.js +64 -103
  196. package/dist/features/workspaces/index.js +3 -3
  197. package/dist/frontend/studio/node_modules/lodash/_Symbol.js +9 -0
  198. package/dist/frontend/studio/node_modules/lodash/_baseGetTag.js +15 -0
  199. package/dist/frontend/studio/node_modules/lodash/_baseTrim.js +13 -0
  200. package/dist/frontend/studio/node_modules/lodash/_freeGlobal.js +8 -0
  201. package/dist/frontend/studio/node_modules/lodash/_getRawTag.js +19 -0
  202. package/dist/frontend/studio/node_modules/lodash/_objectToString.js +12 -0
  203. package/dist/frontend/studio/node_modules/lodash/_root.js +10 -0
  204. package/dist/frontend/studio/node_modules/lodash/_trimmedEndIndex.js +13 -0
  205. package/dist/{node_modules → frontend/studio/node_modules}/lodash/debounce.js +10 -8
  206. package/dist/frontend/studio/node_modules/lodash/isObject.js +12 -0
  207. package/dist/frontend/studio/node_modules/lodash/isObjectLike.js +11 -0
  208. package/dist/frontend/studio/node_modules/lodash/isSymbol.js +14 -0
  209. package/dist/frontend/studio/node_modules/lodash/now.js +12 -0
  210. package/dist/frontend/studio/node_modules/lodash/toNumber.js +24 -0
  211. package/dist/hooks/index.js +6 -6
  212. package/dist/hooks/query-keys.js +33 -31
  213. package/dist/hooks/use-mobile.js +12 -11
  214. package/dist/hooks/useApi.js +16 -14
  215. package/dist/hooks/useAuth.js +38 -53
  216. package/dist/hooks/useConfig.js +26 -37
  217. package/dist/hooks/useDashboard.js +12 -15
  218. package/dist/hooks/useDebounce.js +12 -11
  219. package/dist/hooks/useDocuments.js +23 -35
  220. package/dist/hooks/useFiles.js +1 -2
  221. package/dist/hooks/useProcessor.js +14 -17
  222. package/dist/hooks/useSecrets.js +45 -64
  223. package/dist/hooks/useWorkflows.js +109 -161
  224. package/dist/hooks/useWorkspaces.js +83 -123
  225. package/dist/index.d.ts +0 -1304
  226. package/dist/index.js +80 -80
  227. package/dist/lib/requireParam.js +4 -2
  228. package/dist/lib/utils.js +7 -5
  229. package/dist/loopstack-studio.css +1 -1
  230. package/dist/node_modules/@braintree/sanitize-url/dist/constants.js +6 -4
  231. package/dist/node_modules/@braintree/sanitize-url/dist/index.js +8 -6
  232. package/dist/node_modules/@chevrotain/gast/lib/src/helpers.js +19 -20
  233. package/dist/node_modules/@chevrotain/gast/lib/src/model.js +87 -88
  234. package/dist/node_modules/@chevrotain/gast/lib/src/visitor.js +16 -13
  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 +4 -2
  237. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/character-classes.js +36 -34
  238. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/regexp-parser.js +138 -110
  239. package/dist/node_modules/@chevrotain/regexp-to-ast/lib/src/utils.js +13 -11
  240. package/dist/node_modules/@chevrotain/utils/lib/src/print.js +5 -3
  241. package/dist/node_modules/@chevrotain/utils/lib/src/timer.js +4 -2
  242. package/dist/node_modules/@chevrotain/utils/lib/src/to-fast-properties.js +4 -2
  243. package/dist/node_modules/@dagrejs/dagre/dist/dagre.esm.js +1812 -1913
  244. package/dist/node_modules/@iconify/utils/lib/customisations/defaults.js +8 -6
  245. package/dist/node_modules/@iconify/utils/lib/icon/defaults.js +10 -8
  246. package/dist/node_modules/@iconify/utils/lib/icon/merge.js +8 -6
  247. package/dist/node_modules/@iconify/utils/lib/icon/name.js +8 -6
  248. package/dist/node_modules/@iconify/utils/lib/icon/transformations.js +4 -2
  249. package/dist/node_modules/@iconify/utils/lib/icon-set/get-icon.js +12 -10
  250. package/dist/node_modules/@iconify/utils/lib/icon-set/tree.js +4 -2
  251. package/dist/node_modules/@iconify/utils/lib/svg/build.js +20 -18
  252. package/dist/node_modules/@iconify/utils/lib/svg/defs.js +8 -6
  253. package/dist/node_modules/@iconify/utils/lib/svg/html.js +4 -2
  254. package/dist/node_modules/@iconify/utils/lib/svg/id.js +10 -8
  255. package/dist/node_modules/@iconify/utils/lib/svg/size.js +7 -5
  256. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/architecture-YZFGNWBL.js +3 -0
  257. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-2KRD3SAO.js +26 -0
  258. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-67CJDMHE.js +26 -0
  259. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-7N4EOEYR.js +38 -0
  260. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-AA7GKIK3.js +33 -0
  261. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-CIAEETIT.js +26 -0
  262. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-FOC6F5B3.js +26 -0
  263. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-K5T4RW27.js +1208 -0
  264. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-KGLVRYIC.js +26 -0
  265. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-LIHQZDEY.js +67 -0
  266. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-ORNJ4GCN.js +34 -0
  267. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/gitGraph-7Q5UKJZL.js +3 -0
  268. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-OMHHGYJF.js +3 -0
  269. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-4T2RLAQJ.js +3 -0
  270. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-ZZUOXDRM.js +3 -0
  271. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-PYXPWWZC.js +3 -0
  272. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treeView-SZITEDCU.js +3 -0
  273. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-W4RFUUIX.js +3 -0
  274. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/wardley-RL74JXVD.js +3 -0
  275. package/dist/node_modules/@mermaid-js/parser/dist/mermaid-parser.core.js +59 -45
  276. package/dist/node_modules/@shikijs/core/dist/index.js +583 -1119
  277. package/dist/node_modules/@shikijs/engine-oniguruma/dist/index.js +163 -148
  278. package/dist/node_modules/@shikijs/engine-oniguruma/dist/wasm-inlined.js +4 -2
  279. package/dist/node_modules/@shikijs/langs/dist/abap.js +3 -2
  280. package/dist/node_modules/@shikijs/langs/dist/actionscript-3.js +3 -2
  281. package/dist/node_modules/@shikijs/langs/dist/ada.js +3 -2
  282. package/dist/node_modules/@shikijs/langs/dist/angular-expression.js +3 -2
  283. package/dist/node_modules/@shikijs/langs/dist/angular-html.js +15 -13
  284. package/dist/node_modules/@shikijs/langs/dist/angular-inline-style.js +5 -3
  285. package/dist/node_modules/@shikijs/langs/dist/angular-inline-template.js +9 -7
  286. package/dist/node_modules/@shikijs/langs/dist/angular-let-declaration.js +5 -3
  287. package/dist/node_modules/@shikijs/langs/dist/angular-template-blocks.js +9 -7
  288. package/dist/node_modules/@shikijs/langs/dist/angular-template.js +5 -3
  289. package/dist/node_modules/@shikijs/langs/dist/angular-ts.js +17 -15
  290. package/dist/node_modules/@shikijs/langs/dist/apache.js +3 -2
  291. package/dist/node_modules/@shikijs/langs/dist/apex.js +3 -2
  292. package/dist/node_modules/@shikijs/langs/dist/apl.js +15 -13
  293. package/dist/node_modules/@shikijs/langs/dist/applescript.js +3 -2
  294. package/dist/node_modules/@shikijs/langs/dist/ara.js +3 -2
  295. package/dist/node_modules/@shikijs/langs/dist/asciidoc.js +3 -2
  296. package/dist/node_modules/@shikijs/langs/dist/asm.js +3 -2
  297. package/dist/node_modules/@shikijs/langs/dist/astro.js +17 -15
  298. package/dist/node_modules/@shikijs/langs/dist/awk.js +3 -2
  299. package/dist/node_modules/@shikijs/langs/dist/ballerina.js +3 -2
  300. package/dist/node_modules/@shikijs/langs/dist/bat.js +3 -2
  301. package/dist/node_modules/@shikijs/langs/dist/beancount.js +3 -2
  302. package/dist/node_modules/@shikijs/langs/dist/berry.js +3 -2
  303. package/dist/node_modules/@shikijs/langs/dist/bibtex.js +3 -2
  304. package/dist/node_modules/@shikijs/langs/dist/bicep.js +3 -2
  305. package/dist/node_modules/@shikijs/langs/dist/bird2.js +3 -2
  306. package/dist/node_modules/@shikijs/langs/dist/blade.js +19 -17
  307. package/dist/node_modules/@shikijs/langs/dist/bsl.js +5 -3
  308. package/dist/node_modules/@shikijs/langs/dist/c.js +3 -2
  309. package/dist/node_modules/@shikijs/langs/dist/c3.js +3 -2
  310. package/dist/node_modules/@shikijs/langs/dist/cadence.js +3 -2
  311. package/dist/node_modules/@shikijs/langs/dist/cairo.js +5 -3
  312. package/dist/node_modules/@shikijs/langs/dist/clarity.js +3 -2
  313. package/dist/node_modules/@shikijs/langs/dist/clojure.js +3 -2
  314. package/dist/node_modules/@shikijs/langs/dist/cmake.js +3 -2
  315. package/dist/node_modules/@shikijs/langs/dist/cobol.js +9 -7
  316. package/dist/node_modules/@shikijs/langs/dist/codeowners.js +3 -2
  317. package/dist/node_modules/@shikijs/langs/dist/codeql.js +3 -2
  318. package/dist/node_modules/@shikijs/langs/dist/coffee.js +5 -3
  319. package/dist/node_modules/@shikijs/langs/dist/common-lisp.js +3 -2
  320. package/dist/node_modules/@shikijs/langs/dist/coq.js +3 -2
  321. package/dist/node_modules/@shikijs/langs/dist/cpp-macro.js +11 -9
  322. package/dist/node_modules/@shikijs/langs/dist/cpp.js +13 -11
  323. package/dist/node_modules/@shikijs/langs/dist/crystal.js +17 -15
  324. package/dist/node_modules/@shikijs/langs/dist/csharp.js +3 -2
  325. package/dist/node_modules/@shikijs/langs/dist/css.js +3 -2
  326. package/dist/node_modules/@shikijs/langs/dist/csv.js +3 -2
  327. package/dist/node_modules/@shikijs/langs/dist/cue.js +3 -2
  328. package/dist/node_modules/@shikijs/langs/dist/cypher.js +3 -2
  329. package/dist/node_modules/@shikijs/langs/dist/d.js +3 -2
  330. package/dist/node_modules/@shikijs/langs/dist/dart.js +3 -2
  331. package/dist/node_modules/@shikijs/langs/dist/dax.js +3 -2
  332. package/dist/node_modules/@shikijs/langs/dist/desktop.js +3 -2
  333. package/dist/node_modules/@shikijs/langs/dist/diff.js +3 -2
  334. package/dist/node_modules/@shikijs/langs/dist/docker.js +3 -2
  335. package/dist/node_modules/@shikijs/langs/dist/dotenv.js +3 -2
  336. package/dist/node_modules/@shikijs/langs/dist/dream-maker.js +3 -2
  337. package/dist/node_modules/@shikijs/langs/dist/edge.js +11 -9
  338. package/dist/node_modules/@shikijs/langs/dist/elixir.js +5 -3
  339. package/dist/node_modules/@shikijs/langs/dist/elm.js +5 -3
  340. package/dist/node_modules/@shikijs/langs/dist/emacs-lisp.js +3 -2
  341. package/dist/node_modules/@shikijs/langs/dist/erb.js +9 -7
  342. package/dist/node_modules/@shikijs/langs/dist/erlang.js +5 -3
  343. package/dist/node_modules/@shikijs/langs/dist/es-tag-css.js +11 -9
  344. package/dist/node_modules/@shikijs/langs/dist/es-tag-glsl.js +11 -9
  345. package/dist/node_modules/@shikijs/langs/dist/es-tag-html.js +11 -9
  346. package/dist/node_modules/@shikijs/langs/dist/es-tag-sql.js +9 -7
  347. package/dist/node_modules/@shikijs/langs/dist/es-tag-xml.js +5 -3
  348. package/dist/node_modules/@shikijs/langs/dist/fennel.js +3 -2
  349. package/dist/node_modules/@shikijs/langs/dist/fish.js +3 -2
  350. package/dist/node_modules/@shikijs/langs/dist/fluent.js +3 -2
  351. package/dist/node_modules/@shikijs/langs/dist/fortran-fixed-form.js +5 -3
  352. package/dist/node_modules/@shikijs/langs/dist/fortran-free-form.js +3 -2
  353. package/dist/node_modules/@shikijs/langs/dist/fsharp.js +5 -3
  354. package/dist/node_modules/@shikijs/langs/dist/gdresource.js +9 -7
  355. package/dist/node_modules/@shikijs/langs/dist/gdscript.js +3 -2
  356. package/dist/node_modules/@shikijs/langs/dist/gdshader.js +3 -2
  357. package/dist/node_modules/@shikijs/langs/dist/genie.js +3 -2
  358. package/dist/node_modules/@shikijs/langs/dist/gherkin.js +3 -2
  359. package/dist/node_modules/@shikijs/langs/dist/git-commit.js +5 -3
  360. package/dist/node_modules/@shikijs/langs/dist/git-rebase.js +5 -3
  361. package/dist/node_modules/@shikijs/langs/dist/gleam.js +3 -2
  362. package/dist/node_modules/@shikijs/langs/dist/glimmer-js.js +13 -11
  363. package/dist/node_modules/@shikijs/langs/dist/glimmer-ts.js +13 -11
  364. package/dist/node_modules/@shikijs/langs/dist/glsl.js +5 -3
  365. package/dist/node_modules/@shikijs/langs/dist/gn.js +3 -2
  366. package/dist/node_modules/@shikijs/langs/dist/gnuplot.js +3 -2
  367. package/dist/node_modules/@shikijs/langs/dist/go.js +3 -2
  368. package/dist/node_modules/@shikijs/langs/dist/graphql.js +13 -11
  369. package/dist/node_modules/@shikijs/langs/dist/groovy.js +3 -2
  370. package/dist/node_modules/@shikijs/langs/dist/hack.js +9 -7
  371. package/dist/node_modules/@shikijs/langs/dist/haml.js +9 -7
  372. package/dist/node_modules/@shikijs/langs/dist/handlebars.js +13 -11
  373. package/dist/node_modules/@shikijs/langs/dist/haskell.js +3 -2
  374. package/dist/node_modules/@shikijs/langs/dist/haxe.js +3 -2
  375. package/dist/node_modules/@shikijs/langs/dist/hcl.js +3 -2
  376. package/dist/node_modules/@shikijs/langs/dist/hjson.js +3 -2
  377. package/dist/node_modules/@shikijs/langs/dist/hlsl.js +3 -2
  378. package/dist/node_modules/@shikijs/langs/dist/html-derivative.js +5 -3
  379. package/dist/node_modules/@shikijs/langs/dist/html.js +9 -7
  380. package/dist/node_modules/@shikijs/langs/dist/http.js +13 -11
  381. package/dist/node_modules/@shikijs/langs/dist/hurl.js +11 -9
  382. package/dist/node_modules/@shikijs/langs/dist/hxml.js +5 -3
  383. package/dist/node_modules/@shikijs/langs/dist/hy.js +3 -2
  384. package/dist/node_modules/@shikijs/langs/dist/imba.js +3 -2
  385. package/dist/node_modules/@shikijs/langs/dist/ini.js +3 -2
  386. package/dist/node_modules/@shikijs/langs/dist/java.js +3 -2
  387. package/dist/node_modules/@shikijs/langs/dist/javascript.js +3 -2
  388. package/dist/node_modules/@shikijs/langs/dist/jinja-html.js +5 -3
  389. package/dist/node_modules/@shikijs/langs/dist/jinja.js +5 -3
  390. package/dist/node_modules/@shikijs/langs/dist/jison.js +5 -3
  391. package/dist/node_modules/@shikijs/langs/dist/json.js +3 -2
  392. package/dist/node_modules/@shikijs/langs/dist/json5.js +3 -2
  393. package/dist/node_modules/@shikijs/langs/dist/jsonc.js +3 -2
  394. package/dist/node_modules/@shikijs/langs/dist/jsonl.js +3 -2
  395. package/dist/node_modules/@shikijs/langs/dist/jsonnet.js +3 -2
  396. package/dist/node_modules/@shikijs/langs/dist/jssm.js +3 -2
  397. package/dist/node_modules/@shikijs/langs/dist/jsx.js +3 -2
  398. package/dist/node_modules/@shikijs/langs/dist/julia.js +15 -13
  399. package/dist/node_modules/@shikijs/langs/dist/just.js +17 -15
  400. package/dist/node_modules/@shikijs/langs/dist/kdl.js +3 -2
  401. package/dist/node_modules/@shikijs/langs/dist/kotlin.js +3 -2
  402. package/dist/node_modules/@shikijs/langs/dist/kusto.js +3 -2
  403. package/dist/node_modules/@shikijs/langs/dist/latex.js +5 -3
  404. package/dist/node_modules/@shikijs/langs/dist/lean.js +3 -2
  405. package/dist/node_modules/@shikijs/langs/dist/less.js +3 -2
  406. package/dist/node_modules/@shikijs/langs/dist/liquid.js +13 -11
  407. package/dist/node_modules/@shikijs/langs/dist/llvm.js +3 -2
  408. package/dist/node_modules/@shikijs/langs/dist/log.js +3 -2
  409. package/dist/node_modules/@shikijs/langs/dist/logo.js +3 -2
  410. package/dist/node_modules/@shikijs/langs/dist/lua.js +5 -3
  411. package/dist/node_modules/@shikijs/langs/dist/luau.js +3 -2
  412. package/dist/node_modules/@shikijs/langs/dist/make.js +3 -2
  413. package/dist/node_modules/@shikijs/langs/dist/markdown-nix.js +3 -2
  414. package/dist/node_modules/@shikijs/langs/dist/markdown-vue.js +3 -2
  415. package/dist/node_modules/@shikijs/langs/dist/markdown.js +3 -2
  416. package/dist/node_modules/@shikijs/langs/dist/marko.js +13 -11
  417. package/dist/node_modules/@shikijs/langs/dist/matlab.js +3 -2
  418. package/dist/node_modules/@shikijs/langs/dist/mdc.js +11 -9
  419. package/dist/node_modules/@shikijs/langs/dist/mdx.js +3 -2
  420. package/dist/node_modules/@shikijs/langs/dist/mermaid.js +3 -2
  421. package/dist/node_modules/@shikijs/langs/dist/mipsasm.js +3 -2
  422. package/dist/node_modules/@shikijs/langs/dist/mojo.js +3 -2
  423. package/dist/node_modules/@shikijs/langs/dist/moonbit.js +3 -2
  424. package/dist/node_modules/@shikijs/langs/dist/move.js +3 -2
  425. package/dist/node_modules/@shikijs/langs/dist/narrat.js +3 -2
  426. package/dist/node_modules/@shikijs/langs/dist/nextflow-groovy.js +3 -2
  427. package/dist/node_modules/@shikijs/langs/dist/nextflow.js +5 -3
  428. package/dist/node_modules/@shikijs/langs/dist/nginx.js +5 -3
  429. package/dist/node_modules/@shikijs/langs/dist/nim.js +19 -17
  430. package/dist/node_modules/@shikijs/langs/dist/nix.js +5 -3
  431. package/dist/node_modules/@shikijs/langs/dist/nushell.js +3 -2
  432. package/dist/node_modules/@shikijs/langs/dist/objective-c.js +3 -2
  433. package/dist/node_modules/@shikijs/langs/dist/objective-cpp.js +3 -2
  434. package/dist/node_modules/@shikijs/langs/dist/ocaml.js +3 -2
  435. package/dist/node_modules/@shikijs/langs/dist/odin.js +3 -2
  436. package/dist/node_modules/@shikijs/langs/dist/openscad.js +3 -2
  437. package/dist/node_modules/@shikijs/langs/dist/pascal.js +3 -2
  438. package/dist/node_modules/@shikijs/langs/dist/perl.js +15 -13
  439. package/dist/node_modules/@shikijs/langs/dist/php.js +17 -15
  440. package/dist/node_modules/@shikijs/langs/dist/pkl.js +3 -2
  441. package/dist/node_modules/@shikijs/langs/dist/plsql.js +3 -2
  442. package/dist/node_modules/@shikijs/langs/dist/po.js +3 -2
  443. package/dist/node_modules/@shikijs/langs/dist/polar.js +3 -2
  444. package/dist/node_modules/@shikijs/langs/dist/postcss.js +3 -2
  445. package/dist/node_modules/@shikijs/langs/dist/powerquery.js +3 -2
  446. package/dist/node_modules/@shikijs/langs/dist/powershell.js +3 -2
  447. package/dist/node_modules/@shikijs/langs/dist/prisma.js +3 -2
  448. package/dist/node_modules/@shikijs/langs/dist/prolog.js +3 -2
  449. package/dist/node_modules/@shikijs/langs/dist/proto.js +3 -2
  450. package/dist/node_modules/@shikijs/langs/dist/pug.js +11 -9
  451. package/dist/node_modules/@shikijs/langs/dist/puppet.js +3 -2
  452. package/dist/node_modules/@shikijs/langs/dist/purescript.js +3 -2
  453. package/dist/node_modules/@shikijs/langs/dist/python.js +3 -2
  454. package/dist/node_modules/@shikijs/langs/dist/qml.js +5 -3
  455. package/dist/node_modules/@shikijs/langs/dist/qmldir.js +3 -2
  456. package/dist/node_modules/@shikijs/langs/dist/qss.js +3 -2
  457. package/dist/node_modules/@shikijs/langs/dist/r.js +3 -2
  458. package/dist/node_modules/@shikijs/langs/dist/racket.js +3 -2
  459. package/dist/node_modules/@shikijs/langs/dist/raku.js +3 -2
  460. package/dist/node_modules/@shikijs/langs/dist/razor.js +9 -7
  461. package/dist/node_modules/@shikijs/langs/dist/reg.js +3 -2
  462. package/dist/node_modules/@shikijs/langs/dist/regexp.js +3 -2
  463. package/dist/node_modules/@shikijs/langs/dist/rel.js +3 -2
  464. package/dist/node_modules/@shikijs/langs/dist/riscv.js +3 -2
  465. package/dist/node_modules/@shikijs/langs/dist/ron.js +3 -2
  466. package/dist/node_modules/@shikijs/langs/dist/rosmsg.js +3 -2
  467. package/dist/node_modules/@shikijs/langs/dist/rst.js +21 -19
  468. package/dist/node_modules/@shikijs/langs/dist/ruby.js +29 -27
  469. package/dist/node_modules/@shikijs/langs/dist/rust.js +3 -2
  470. package/dist/node_modules/@shikijs/langs/dist/sas.js +5 -3
  471. package/dist/node_modules/@shikijs/langs/dist/sass.js +3 -2
  472. package/dist/node_modules/@shikijs/langs/dist/scala.js +3 -2
  473. package/dist/node_modules/@shikijs/langs/dist/scheme.js +3 -2
  474. package/dist/node_modules/@shikijs/langs/dist/scss.js +5 -3
  475. package/dist/node_modules/@shikijs/langs/dist/sdbl.js +3 -2
  476. package/dist/node_modules/@shikijs/langs/dist/shaderlab.js +5 -3
  477. package/dist/node_modules/@shikijs/langs/dist/shellscript.js +3 -2
  478. package/dist/node_modules/@shikijs/langs/dist/shellsession.js +5 -3
  479. package/dist/node_modules/@shikijs/langs/dist/smalltalk.js +3 -2
  480. package/dist/node_modules/@shikijs/langs/dist/solidity.js +3 -2
  481. package/dist/node_modules/@shikijs/langs/dist/soy.js +5 -3
  482. package/dist/node_modules/@shikijs/langs/dist/sparql.js +5 -3
  483. package/dist/node_modules/@shikijs/langs/dist/splunk.js +3 -2
  484. package/dist/node_modules/@shikijs/langs/dist/sql.js +3 -2
  485. package/dist/node_modules/@shikijs/langs/dist/ssh-config.js +3 -2
  486. package/dist/node_modules/@shikijs/langs/dist/stata.js +5 -3
  487. package/dist/node_modules/@shikijs/langs/dist/stylus.js +3 -2
  488. package/dist/node_modules/@shikijs/langs/dist/surrealql.js +5 -3
  489. package/dist/node_modules/@shikijs/langs/dist/svelte.js +13 -11
  490. package/dist/node_modules/@shikijs/langs/dist/swift.js +3 -2
  491. package/dist/node_modules/@shikijs/langs/dist/system-verilog.js +3 -2
  492. package/dist/node_modules/@shikijs/langs/dist/systemd.js +3 -2
  493. package/dist/node_modules/@shikijs/langs/dist/talonscript.js +3 -2
  494. package/dist/node_modules/@shikijs/langs/dist/tasl.js +3 -2
  495. package/dist/node_modules/@shikijs/langs/dist/tcl.js +3 -2
  496. package/dist/node_modules/@shikijs/langs/dist/templ.js +11 -9
  497. package/dist/node_modules/@shikijs/langs/dist/terraform.js +3 -2
  498. package/dist/node_modules/@shikijs/langs/dist/tex.js +5 -3
  499. package/dist/node_modules/@shikijs/langs/dist/toml.js +3 -2
  500. package/dist/node_modules/@shikijs/langs/dist/ts-tags.js +17 -15
  501. package/dist/node_modules/@shikijs/langs/dist/tsv.js +3 -2
  502. package/dist/node_modules/@shikijs/langs/dist/tsx.js +3 -2
  503. package/dist/node_modules/@shikijs/langs/dist/turtle.js +3 -2
  504. package/dist/node_modules/@shikijs/langs/dist/twig.js +17 -15
  505. package/dist/node_modules/@shikijs/langs/dist/typescript.js +3 -2
  506. package/dist/node_modules/@shikijs/langs/dist/typespec.js +3 -2
  507. package/dist/node_modules/@shikijs/langs/dist/typst.js +3 -2
  508. package/dist/node_modules/@shikijs/langs/dist/v.js +3 -2
  509. package/dist/node_modules/@shikijs/langs/dist/vala.js +3 -2
  510. package/dist/node_modules/@shikijs/langs/dist/vb.js +3 -2
  511. package/dist/node_modules/@shikijs/langs/dist/verilog.js +3 -2
  512. package/dist/node_modules/@shikijs/langs/dist/vhdl.js +3 -2
  513. package/dist/node_modules/@shikijs/langs/dist/viml.js +3 -2
  514. package/dist/node_modules/@shikijs/langs/dist/vue-directives.js +3 -2
  515. package/dist/node_modules/@shikijs/langs/dist/vue-html.js +5 -3
  516. package/dist/node_modules/@shikijs/langs/dist/vue-interpolations.js +3 -2
  517. package/dist/node_modules/@shikijs/langs/dist/vue-sfc-style-variable-injection.js +5 -3
  518. package/dist/node_modules/@shikijs/langs/dist/vue-vine.js +17 -15
  519. package/dist/node_modules/@shikijs/langs/dist/vue.js +25 -23
  520. package/dist/node_modules/@shikijs/langs/dist/vyper.js +3 -2
  521. package/dist/node_modules/@shikijs/langs/dist/wasm.js +3 -2
  522. package/dist/node_modules/@shikijs/langs/dist/wenyan.js +3 -2
  523. package/dist/node_modules/@shikijs/langs/dist/wgsl.js +3 -2
  524. package/dist/node_modules/@shikijs/langs/dist/wikitext.js +3 -2
  525. package/dist/node_modules/@shikijs/langs/dist/wit.js +3 -2
  526. package/dist/node_modules/@shikijs/langs/dist/wolfram.js +3 -2
  527. package/dist/node_modules/@shikijs/langs/dist/xml.js +5 -3
  528. package/dist/node_modules/@shikijs/langs/dist/xsl.js +5 -3
  529. package/dist/node_modules/@shikijs/langs/dist/yaml.js +3 -2
  530. package/dist/node_modules/@shikijs/langs/dist/zenscript.js +3 -2
  531. package/dist/node_modules/@shikijs/langs/dist/zig.js +3 -2
  532. package/dist/node_modules/@shikijs/primitive/dist/index.js +540 -0
  533. package/dist/node_modules/@shikijs/themes/dist/andromeeda.js +4 -2
  534. package/dist/node_modules/@shikijs/themes/dist/aurora-x.js +4 -2
  535. package/dist/node_modules/@shikijs/themes/dist/ayu-dark.js +4 -2
  536. package/dist/node_modules/@shikijs/themes/dist/ayu-light.js +4 -2
  537. package/dist/node_modules/@shikijs/themes/dist/ayu-mirage.js +4 -2
  538. package/dist/node_modules/@shikijs/themes/dist/catppuccin-frappe.js +4 -2
  539. package/dist/node_modules/@shikijs/themes/dist/catppuccin-latte.js +4 -2
  540. package/dist/node_modules/@shikijs/themes/dist/catppuccin-macchiato.js +4 -2
  541. package/dist/node_modules/@shikijs/themes/dist/catppuccin-mocha.js +4 -2
  542. package/dist/node_modules/@shikijs/themes/dist/dark-plus.js +4 -2
  543. package/dist/node_modules/@shikijs/themes/dist/dracula-soft.js +4 -2
  544. package/dist/node_modules/@shikijs/themes/dist/dracula.js +4 -2
  545. package/dist/node_modules/@shikijs/themes/dist/everforest-dark.js +4 -2
  546. package/dist/node_modules/@shikijs/themes/dist/everforest-light.js +4 -2
  547. package/dist/node_modules/@shikijs/themes/dist/github-dark-default.js +4 -2
  548. package/dist/node_modules/@shikijs/themes/dist/github-dark-dimmed.js +4 -2
  549. package/dist/node_modules/@shikijs/themes/dist/github-dark-high-contrast.js +4 -2
  550. package/dist/node_modules/@shikijs/themes/dist/github-dark.js +4 -2
  551. package/dist/node_modules/@shikijs/themes/dist/github-light-default.js +4 -2
  552. package/dist/node_modules/@shikijs/themes/dist/github-light-high-contrast.js +4 -2
  553. package/dist/node_modules/@shikijs/themes/dist/github-light.js +4 -2
  554. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-hard.js +4 -2
  555. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-medium.js +4 -2
  556. package/dist/node_modules/@shikijs/themes/dist/gruvbox-dark-soft.js +4 -2
  557. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-hard.js +4 -2
  558. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-medium.js +4 -2
  559. package/dist/node_modules/@shikijs/themes/dist/gruvbox-light-soft.js +4 -2
  560. package/dist/node_modules/@shikijs/themes/dist/horizon-bright.js +4 -2
  561. package/dist/node_modules/@shikijs/themes/dist/horizon.js +4 -2
  562. package/dist/node_modules/@shikijs/themes/dist/houston.js +4 -2
  563. package/dist/node_modules/@shikijs/themes/dist/kanagawa-dragon.js +4 -2
  564. package/dist/node_modules/@shikijs/themes/dist/kanagawa-lotus.js +4 -2
  565. package/dist/node_modules/@shikijs/themes/dist/kanagawa-wave.js +4 -2
  566. package/dist/node_modules/@shikijs/themes/dist/laserwave.js +4 -2
  567. package/dist/node_modules/@shikijs/themes/dist/light-plus.js +4 -2
  568. package/dist/node_modules/@shikijs/themes/dist/material-theme-darker.js +4 -2
  569. package/dist/node_modules/@shikijs/themes/dist/material-theme-lighter.js +4 -2
  570. package/dist/node_modules/@shikijs/themes/dist/material-theme-ocean.js +4 -2
  571. package/dist/node_modules/@shikijs/themes/dist/material-theme-palenight.js +4 -2
  572. package/dist/node_modules/@shikijs/themes/dist/material-theme.js +4 -2
  573. package/dist/node_modules/@shikijs/themes/dist/min-dark.js +4 -2
  574. package/dist/node_modules/@shikijs/themes/dist/min-light.js +4 -2
  575. package/dist/node_modules/@shikijs/themes/dist/monokai.js +4 -2
  576. package/dist/node_modules/@shikijs/themes/dist/night-owl-light.js +4 -2
  577. package/dist/node_modules/@shikijs/themes/dist/night-owl.js +4 -2
  578. package/dist/node_modules/@shikijs/themes/dist/nord.js +4 -2
  579. package/dist/node_modules/@shikijs/themes/dist/one-dark-pro.js +4 -2
  580. package/dist/node_modules/@shikijs/themes/dist/one-light.js +4 -2
  581. package/dist/node_modules/@shikijs/themes/dist/plastic.js +4 -2
  582. package/dist/node_modules/@shikijs/themes/dist/poimandres.js +4 -2
  583. package/dist/node_modules/@shikijs/themes/dist/red.js +4 -2
  584. package/dist/node_modules/@shikijs/themes/dist/rose-pine-dawn.js +4 -2
  585. package/dist/node_modules/@shikijs/themes/dist/rose-pine-moon.js +4 -2
  586. package/dist/node_modules/@shikijs/themes/dist/rose-pine.js +4 -2
  587. package/dist/node_modules/@shikijs/themes/dist/slack-dark.js +4 -2
  588. package/dist/node_modules/@shikijs/themes/dist/slack-ochin.js +4 -2
  589. package/dist/node_modules/@shikijs/themes/dist/snazzy-light.js +4 -2
  590. package/dist/node_modules/@shikijs/themes/dist/solarized-dark.js +4 -2
  591. package/dist/node_modules/@shikijs/themes/dist/solarized-light.js +4 -2
  592. package/dist/node_modules/@shikijs/themes/dist/synthwave-84.js +4 -2
  593. package/dist/node_modules/@shikijs/themes/dist/tokyo-night.js +4 -2
  594. package/dist/node_modules/@shikijs/themes/dist/vesper.js +4 -2
  595. package/dist/node_modules/@shikijs/themes/dist/vitesse-black.js +4 -2
  596. package/dist/node_modules/@shikijs/themes/dist/vitesse-dark.js +4 -2
  597. package/dist/node_modules/@shikijs/themes/dist/vitesse-light.js +4 -2
  598. package/dist/node_modules/@shikijs/types/dist/index.js +4 -2
  599. package/dist/node_modules/@shikijs/vscode-textmate/dist/index.js +949 -947
  600. package/dist/node_modules/@ungap/structured-clone/esm/deserialize.js +30 -30
  601. package/dist/node_modules/@ungap/structured-clone/esm/index.js +6 -4
  602. package/dist/node_modules/@ungap/structured-clone/esm/serialize.js +64 -64
  603. package/dist/node_modules/@upsetjs/venn.js/build/venn.esm.js +905 -0
  604. package/dist/node_modules/@xyflow/react/dist/esm/index.js +904 -901
  605. package/dist/node_modules/@xyflow/system/dist/esm/index.js +1226 -1222
  606. package/dist/node_modules/bail/index.js +4 -2
  607. package/dist/node_modules/ccount/index.js +4 -2
  608. package/dist/node_modules/character-entities-html4/index.js +4 -2
  609. package/dist/node_modules/character-entities-legacy/index.js +4 -2
  610. package/dist/node_modules/chevrotain/lib/src/api.js +10 -10
  611. package/dist/node_modules/chevrotain/lib/src/lang/lang_extensions.js +6 -4
  612. package/dist/node_modules/chevrotain/lib/src/parse/constants.js +4 -2
  613. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst.js +11 -9
  614. package/dist/node_modules/chevrotain/lib/src/parse/cst/cst_visitor.js +38 -45
  615. package/dist/node_modules/chevrotain/lib/src/parse/errors_public.js +35 -36
  616. package/dist/node_modules/chevrotain/lib/src/parse/exceptions_public.js +26 -25
  617. package/dist/node_modules/chevrotain/lib/src/parse/grammar/checks.js +204 -226
  618. package/dist/node_modules/chevrotain/lib/src/parse/grammar/first.js +18 -18
  619. package/dist/node_modules/chevrotain/lib/src/parse/grammar/follow.js +20 -19
  620. package/dist/node_modules/chevrotain/lib/src/parse/grammar/gast/gast_resolver_public.js +14 -13
  621. package/dist/node_modules/chevrotain/lib/src/parse/grammar/interpreter.js +195 -200
  622. package/dist/node_modules/chevrotain/lib/src/parse/grammar/keys.js +5 -4
  623. package/dist/node_modules/chevrotain/lib/src/parse/grammar/llk_lookahead.js +28 -28
  624. package/dist/node_modules/chevrotain/lib/src/parse/grammar/lookahead.js +165 -170
  625. package/dist/node_modules/chevrotain/lib/src/parse/grammar/resolver.js +17 -17
  626. package/dist/node_modules/chevrotain/lib/src/parse/grammar/rest.js +50 -50
  627. package/dist/node_modules/chevrotain/lib/src/parse/parser/parser.js +76 -83
  628. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/error_handler.js +21 -21
  629. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/gast_recorder.js +117 -121
  630. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/lexer_adapter.js +12 -6
  631. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/looksahead.js +51 -51
  632. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/perf_tracer.js +15 -14
  633. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_api.js +81 -80
  634. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recognizer_engine.js +229 -217
  635. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/recoverable.js +87 -86
  636. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/tree_builder.js +36 -44
  637. package/dist/node_modules/chevrotain/lib/src/parse/parser/utils/apply_mixins.js +4 -2
  638. package/dist/node_modules/chevrotain/lib/src/scan/lexer.js +287 -309
  639. package/dist/node_modules/chevrotain/lib/src/scan/lexer_errors_public.js +4 -2
  640. package/dist/node_modules/chevrotain/lib/src/scan/lexer_public.js +115 -126
  641. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp.js +73 -70
  642. package/dist/node_modules/chevrotain/lib/src/scan/reg_exp_parser.js +12 -10
  643. package/dist/node_modules/chevrotain/lib/src/scan/tokens.js +45 -54
  644. package/dist/node_modules/chevrotain/lib/src/scan/tokens_public.js +29 -30
  645. package/dist/node_modules/chevrotain-allstar/lib/all-star-lookahead.js +242 -240
  646. package/dist/node_modules/chevrotain-allstar/lib/atn.js +134 -133
  647. package/dist/node_modules/chevrotain-allstar/lib/dfa.js +11 -10
  648. package/dist/node_modules/chevrotain-allstar/lib/index.js +1 -1
  649. package/dist/node_modules/classcat/index.js +5 -3
  650. package/dist/node_modules/comma-separated-tokens/index.js +5 -3
  651. package/dist/node_modules/cose-base/cose-base.js +21 -21
  652. package/dist/node_modules/cytoscape/dist/cytoscape.esm.js +7935 -7935
  653. package/dist/node_modules/cytoscape-cose-bilkent/cytoscape-cose-bilkent.js +8 -6
  654. package/dist/node_modules/cytoscape-fcose/cytoscape-fcose.js +8 -6
  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 +6 -4
  657. package/dist/node_modules/d3/src/index.js +95 -95
  658. package/dist/node_modules/d3-array/src/ascending.js +4 -2
  659. package/dist/node_modules/d3-array/src/bisect.js +8 -8
  660. package/dist/node_modules/d3-array/src/bisector.js +8 -6
  661. package/dist/node_modules/d3-array/src/descending.js +4 -2
  662. package/dist/node_modules/d3-array/src/max.js +4 -2
  663. package/dist/node_modules/d3-array/src/min.js +4 -2
  664. package/dist/node_modules/d3-array/src/number.js +4 -2
  665. package/dist/node_modules/d3-array/src/range.js +4 -2
  666. package/dist/node_modules/d3-array/src/ticks.js +13 -11
  667. package/dist/node_modules/d3-axis/src/axis.js +48 -46
  668. package/dist/node_modules/d3-axis/src/identity.js +4 -2
  669. package/dist/node_modules/d3-brush/src/brush.js +6 -4
  670. package/dist/node_modules/d3-color/src/color.js +86 -84
  671. package/dist/node_modules/d3-color/src/define.js +5 -3
  672. package/dist/node_modules/d3-color/src/lab.js +45 -43
  673. package/dist/node_modules/d3-color/src/math.js +4 -2
  674. package/dist/node_modules/d3-dispatch/src/dispatch.js +18 -17
  675. package/dist/node_modules/d3-drag/src/constant.js +4 -2
  676. package/dist/node_modules/d3-drag/src/drag.js +77 -75
  677. package/dist/node_modules/d3-drag/src/event.js +5 -3
  678. package/dist/node_modules/d3-drag/src/nodrag.js +11 -9
  679. package/dist/node_modules/d3-drag/src/noevent.js +6 -4
  680. package/dist/node_modules/d3-ease/src/cubic.js +4 -2
  681. package/dist/node_modules/d3-format/src/defaultLocale.js +8 -6
  682. package/dist/node_modules/d3-format/src/exponent.js +6 -4
  683. package/dist/node_modules/d3-format/src/formatDecimal.js +5 -3
  684. package/dist/node_modules/d3-format/src/formatGroup.js +4 -2
  685. package/dist/node_modules/d3-format/src/formatNumerals.js +4 -2
  686. package/dist/node_modules/d3-format/src/formatPrefixAuto.js +10 -8
  687. package/dist/node_modules/d3-format/src/formatRounded.js +6 -4
  688. package/dist/node_modules/d3-format/src/formatSpecifier.js +10 -8
  689. package/dist/node_modules/d3-format/src/formatTrim.js +4 -2
  690. package/dist/node_modules/d3-format/src/formatTypes.js +15 -13
  691. package/dist/node_modules/d3-format/src/identity.js +4 -2
  692. package/dist/node_modules/d3-format/src/locale.js +33 -31
  693. package/dist/node_modules/d3-format/src/precisionFixed.js +6 -4
  694. package/dist/node_modules/d3-format/src/precisionPrefix.js +6 -4
  695. package/dist/node_modules/d3-format/src/precisionRound.js +6 -4
  696. package/dist/node_modules/d3-hierarchy/src/accessors.js +4 -2
  697. package/dist/node_modules/d3-hierarchy/src/constant.js +5 -3
  698. package/dist/node_modules/d3-hierarchy/src/hierarchy/ancestors.js +4 -2
  699. package/dist/node_modules/d3-hierarchy/src/hierarchy/count.js +6 -4
  700. package/dist/node_modules/d3-hierarchy/src/hierarchy/descendants.js +4 -2
  701. package/dist/node_modules/d3-hierarchy/src/hierarchy/each.js +4 -2
  702. package/dist/node_modules/d3-hierarchy/src/hierarchy/eachAfter.js +4 -2
  703. package/dist/node_modules/d3-hierarchy/src/hierarchy/eachBefore.js +4 -2
  704. package/dist/node_modules/d3-hierarchy/src/hierarchy/find.js +4 -2
  705. package/dist/node_modules/d3-hierarchy/src/hierarchy/index.js +46 -44
  706. package/dist/node_modules/d3-hierarchy/src/hierarchy/iterator.js +4 -2
  707. package/dist/node_modules/d3-hierarchy/src/hierarchy/leaves.js +4 -2
  708. package/dist/node_modules/d3-hierarchy/src/hierarchy/links.js +4 -2
  709. package/dist/node_modules/d3-hierarchy/src/hierarchy/path.js +6 -4
  710. package/dist/node_modules/d3-hierarchy/src/hierarchy/sort.js +4 -2
  711. package/dist/node_modules/d3-hierarchy/src/hierarchy/sum.js +4 -2
  712. package/dist/node_modules/d3-hierarchy/src/treemap/dice.js +4 -2
  713. package/dist/node_modules/d3-hierarchy/src/treemap/index.js +16 -14
  714. package/dist/node_modules/d3-hierarchy/src/treemap/round.js +4 -2
  715. package/dist/node_modules/d3-hierarchy/src/treemap/slice.js +4 -2
  716. package/dist/node_modules/d3-hierarchy/src/treemap/squarify.js +11 -9
  717. package/dist/node_modules/d3-interpolate/src/array.js +6 -4
  718. package/dist/node_modules/d3-interpolate/src/basis.js +6 -4
  719. package/dist/node_modules/d3-interpolate/src/basisClosed.js +6 -4
  720. package/dist/node_modules/d3-interpolate/src/color.js +19 -17
  721. package/dist/node_modules/d3-interpolate/src/constant.js +4 -2
  722. package/dist/node_modules/d3-interpolate/src/date.js +4 -2
  723. package/dist/node_modules/d3-interpolate/src/hcl.js +8 -6
  724. package/dist/node_modules/d3-interpolate/src/number.js +4 -2
  725. package/dist/node_modules/d3-interpolate/src/numberArray.js +5 -3
  726. package/dist/node_modules/d3-interpolate/src/object.js +6 -4
  727. package/dist/node_modules/d3-interpolate/src/rgb.js +11 -9
  728. package/dist/node_modules/d3-interpolate/src/round.js +4 -2
  729. package/dist/node_modules/d3-interpolate/src/string.js +16 -14
  730. package/dist/node_modules/d3-interpolate/src/transform/decompose.js +7 -5
  731. package/dist/node_modules/d3-interpolate/src/transform/index.js +13 -11
  732. package/dist/node_modules/d3-interpolate/src/transform/parse.js +10 -8
  733. package/dist/node_modules/d3-interpolate/src/value.js +14 -12
  734. package/dist/node_modules/d3-interpolate/src/zoom.js +13 -11
  735. package/dist/node_modules/d3-path/src/path.js +16 -14
  736. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/max.js +4 -2
  737. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/min.js +4 -2
  738. package/dist/node_modules/d3-sankey/node_modules/d3-array/src/sum.js +4 -2
  739. package/dist/node_modules/d3-sankey/node_modules/d3-path/src/path.js +13 -12
  740. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/array.js +4 -2
  741. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/constant.js +4 -2
  742. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/link/index.js +19 -17
  743. package/dist/node_modules/d3-sankey/node_modules/d3-shape/src/point.js +5 -3
  744. package/dist/node_modules/d3-sankey/src/align.js +12 -10
  745. package/dist/node_modules/d3-sankey/src/constant.js +4 -2
  746. package/dist/node_modules/d3-sankey/src/sankey.js +170 -168
  747. package/dist/node_modules/d3-sankey/src/sankeyLinkHorizontal.js +8 -6
  748. package/dist/node_modules/d3-scale/src/band.js +11 -9
  749. package/dist/node_modules/d3-scale/src/constant.js +4 -2
  750. package/dist/node_modules/d3-scale/src/continuous.js +49 -47
  751. package/dist/node_modules/d3-scale/src/init.js +4 -2
  752. package/dist/node_modules/d3-scale/src/linear.js +15 -13
  753. package/dist/node_modules/d3-scale/src/nice.js +4 -2
  754. package/dist/node_modules/d3-scale/src/number.js +4 -2
  755. package/dist/node_modules/d3-scale/src/ordinal.js +18 -16
  756. package/dist/node_modules/d3-scale/src/tickFormat.js +16 -14
  757. package/dist/node_modules/d3-scale/src/time.js +36 -34
  758. package/dist/node_modules/d3-scale-chromatic/src/categorical/Tableau10.js +5 -3
  759. package/dist/node_modules/d3-scale-chromatic/src/colors.js +4 -2
  760. package/dist/node_modules/d3-selection/src/array.js +4 -2
  761. package/dist/node_modules/d3-selection/src/constant.js +4 -2
  762. package/dist/node_modules/d3-selection/src/creator.js +12 -10
  763. package/dist/node_modules/d3-selection/src/matcher.js +5 -3
  764. package/dist/node_modules/d3-selection/src/namespace.js +7 -5
  765. package/dist/node_modules/d3-selection/src/namespaces.js +5 -3
  766. package/dist/node_modules/d3-selection/src/pointer.js +6 -4
  767. package/dist/node_modules/d3-selection/src/select.js +6 -4
  768. package/dist/node_modules/d3-selection/src/selection/append.js +6 -4
  769. package/dist/node_modules/d3-selection/src/selection/attr.js +19 -17
  770. package/dist/node_modules/d3-selection/src/selection/call.js +4 -2
  771. package/dist/node_modules/d3-selection/src/selection/classed.js +25 -23
  772. package/dist/node_modules/d3-selection/src/selection/clone.js +7 -5
  773. package/dist/node_modules/d3-selection/src/selection/data.js +18 -16
  774. package/dist/node_modules/d3-selection/src/selection/datum.js +4 -2
  775. package/dist/node_modules/d3-selection/src/selection/dispatch.js +12 -10
  776. package/dist/node_modules/d3-selection/src/selection/each.js +4 -2
  777. package/dist/node_modules/d3-selection/src/selection/empty.js +4 -2
  778. package/dist/node_modules/d3-selection/src/selection/enter.js +13 -11
  779. package/dist/node_modules/d3-selection/src/selection/exit.js +7 -5
  780. package/dist/node_modules/d3-selection/src/selection/filter.js +8 -6
  781. package/dist/node_modules/d3-selection/src/selection/html.js +8 -6
  782. package/dist/node_modules/d3-selection/src/selection/index.js +80 -79
  783. package/dist/node_modules/d3-selection/src/selection/insert.js +8 -6
  784. package/dist/node_modules/d3-selection/src/selection/iterator.js +4 -2
  785. package/dist/node_modules/d3-selection/src/selection/join.js +4 -2
  786. package/dist/node_modules/d3-selection/src/selection/lower.js +6 -4
  787. package/dist/node_modules/d3-selection/src/selection/merge.js +6 -4
  788. package/dist/node_modules/d3-selection/src/selection/node.js +4 -2
  789. package/dist/node_modules/d3-selection/src/selection/nodes.js +4 -2
  790. package/dist/node_modules/d3-selection/src/selection/on.js +11 -9
  791. package/dist/node_modules/d3-selection/src/selection/order.js +4 -2
  792. package/dist/node_modules/d3-selection/src/selection/property.js +8 -6
  793. package/dist/node_modules/d3-selection/src/selection/raise.js +6 -4
  794. package/dist/node_modules/d3-selection/src/selection/remove.js +6 -4
  795. package/dist/node_modules/d3-selection/src/selection/select.js +8 -6
  796. package/dist/node_modules/d3-selection/src/selection/selectAll.js +11 -9
  797. package/dist/node_modules/d3-selection/src/selection/selectChild.js +10 -8
  798. package/dist/node_modules/d3-selection/src/selection/selectChildren.js +10 -8
  799. package/dist/node_modules/d3-selection/src/selection/size.js +4 -2
  800. package/dist/node_modules/d3-selection/src/selection/sort.js +8 -6
  801. package/dist/node_modules/d3-selection/src/selection/sparse.js +4 -2
  802. package/dist/node_modules/d3-selection/src/selection/style.js +14 -12
  803. package/dist/node_modules/d3-selection/src/selection/text.js +8 -6
  804. package/dist/node_modules/d3-selection/src/selector.js +6 -4
  805. package/dist/node_modules/d3-selection/src/selectorAll.js +6 -4
  806. package/dist/node_modules/d3-selection/src/sourceEvent.js +4 -2
  807. package/dist/node_modules/d3-selection/src/window.js +4 -2
  808. package/dist/node_modules/d3-shape/src/arc.js +38 -36
  809. package/dist/node_modules/d3-shape/src/array.js +3 -2
  810. package/dist/node_modules/d3-shape/src/constant.js +4 -2
  811. package/dist/node_modules/d3-shape/src/curve/basis.js +10 -8
  812. package/dist/node_modules/d3-shape/src/curve/basisClosed.js +18 -16
  813. package/dist/node_modules/d3-shape/src/curve/basisOpen.js +9 -7
  814. package/dist/node_modules/d3-shape/src/curve/bump.js +15 -13
  815. package/dist/node_modules/d3-shape/src/curve/bundle.js +9 -7
  816. package/dist/node_modules/d3-shape/src/curve/cardinal.js +10 -8
  817. package/dist/node_modules/d3-shape/src/curve/cardinalClosed.js +12 -10
  818. package/dist/node_modules/d3-shape/src/curve/cardinalOpen.js +9 -7
  819. package/dist/node_modules/d3-shape/src/curve/catmullRom.js +19 -17
  820. package/dist/node_modules/d3-shape/src/curve/catmullRomClosed.js +13 -11
  821. package/dist/node_modules/d3-shape/src/curve/catmullRomOpen.js +10 -8
  822. package/dist/node_modules/d3-shape/src/curve/linear.js +7 -5
  823. package/dist/node_modules/d3-shape/src/curve/linearClosed.js +12 -10
  824. package/dist/node_modules/d3-shape/src/curve/monotone.js +23 -21
  825. package/dist/node_modules/d3-shape/src/curve/natural.js +9 -7
  826. package/dist/node_modules/d3-shape/src/curve/step.js +19 -17
  827. package/dist/node_modules/d3-shape/src/descending.js +4 -2
  828. package/dist/node_modules/d3-shape/src/identity.js +4 -2
  829. package/dist/node_modules/d3-shape/src/line.js +19 -17
  830. package/dist/node_modules/d3-shape/src/math.js +8 -6
  831. package/dist/node_modules/d3-shape/src/noop.js +4 -2
  832. package/dist/node_modules/d3-shape/src/path.js +6 -4
  833. package/dist/node_modules/d3-shape/src/pie.js +15 -13
  834. package/dist/node_modules/d3-shape/src/point.js +5 -3
  835. package/dist/node_modules/d3-time/src/day.js +17 -15
  836. package/dist/node_modules/d3-time/src/duration.js +4 -2
  837. package/dist/node_modules/d3-time/src/hour.js +16 -14
  838. package/dist/node_modules/d3-time/src/interval.js +7 -5
  839. package/dist/node_modules/d3-time/src/millisecond.js +7 -5
  840. package/dist/node_modules/d3-time/src/minute.js +16 -14
  841. package/dist/node_modules/d3-time/src/month.js +14 -12
  842. package/dist/node_modules/d3-time/src/second.js +9 -7
  843. package/dist/node_modules/d3-time/src/ticks.js +66 -64
  844. package/dist/node_modules/d3-time/src/week.js +21 -19
  845. package/dist/node_modules/d3-time/src/year.js +10 -8
  846. package/dist/node_modules/d3-time-format/src/defaultLocale.js +8 -6
  847. package/dist/node_modules/d3-time-format/src/locale.js +346 -344
  848. package/dist/node_modules/d3-timer/src/timeout.js +6 -4
  849. package/dist/node_modules/d3-timer/src/timer.js +33 -31
  850. package/dist/node_modules/d3-transition/src/index.js +2 -2
  851. package/dist/node_modules/d3-transition/src/interrupt.js +4 -3
  852. package/dist/node_modules/d3-transition/src/selection/index.js +5 -4
  853. package/dist/node_modules/d3-transition/src/selection/interrupt.js +6 -4
  854. package/dist/node_modules/d3-transition/src/selection/transition.js +16 -14
  855. package/dist/node_modules/d3-transition/src/transition/attr.js +28 -26
  856. package/dist/node_modules/d3-transition/src/transition/attrTween.js +13 -11
  857. package/dist/node_modules/d3-transition/src/transition/delay.js +11 -9
  858. package/dist/node_modules/d3-transition/src/transition/duration.js +11 -9
  859. package/dist/node_modules/d3-transition/src/transition/ease.js +8 -6
  860. package/dist/node_modules/d3-transition/src/transition/easeVarying.js +8 -6
  861. package/dist/node_modules/d3-transition/src/transition/end.js +6 -4
  862. package/dist/node_modules/d3-transition/src/transition/filter.js +8 -6
  863. package/dist/node_modules/d3-transition/src/transition/index.js +63 -61
  864. package/dist/node_modules/d3-transition/src/transition/interpolate.js +9 -7
  865. package/dist/node_modules/d3-transition/src/transition/merge.js +6 -4
  866. package/dist/node_modules/d3-transition/src/transition/on.js +9 -7
  867. package/dist/node_modules/d3-transition/src/transition/remove.js +6 -4
  868. package/dist/node_modules/d3-transition/src/transition/schedule.js +20 -18
  869. package/dist/node_modules/d3-transition/src/transition/select.js +10 -8
  870. package/dist/node_modules/d3-transition/src/transition/selectAll.js +10 -8
  871. package/dist/node_modules/d3-transition/src/transition/selection.js +7 -5
  872. package/dist/node_modules/d3-transition/src/transition/style.js +21 -19
  873. package/dist/node_modules/d3-transition/src/transition/styleTween.js +8 -6
  874. package/dist/node_modules/d3-transition/src/transition/text.js +8 -6
  875. package/dist/node_modules/d3-transition/src/transition/textTween.js +8 -6
  876. package/dist/node_modules/d3-transition/src/transition/transition.js +10 -8
  877. package/dist/node_modules/d3-transition/src/transition/tween.js +14 -12
  878. package/dist/node_modules/d3-zoom/src/constant.js +4 -2
  879. package/dist/node_modules/d3-zoom/src/event.js +4 -2
  880. package/dist/node_modules/d3-zoom/src/index.js +2 -2
  881. package/dist/node_modules/d3-zoom/src/noevent.js +5 -3
  882. package/dist/node_modules/d3-zoom/src/transform.js +12 -10
  883. package/dist/node_modules/d3-zoom/src/zoom.js +116 -114
  884. package/dist/node_modules/dagre-d3-es/src/dagre/acyclic.js +14 -12
  885. package/dist/node_modules/dagre-d3-es/src/dagre/add-border-segments.js +11 -9
  886. package/dist/node_modules/dagre-d3-es/src/dagre/coordinate-system.js +36 -34
  887. package/dist/node_modules/dagre-d3-es/src/dagre/data/list.js +9 -7
  888. package/dist/node_modules/dagre-d3-es/src/dagre/greedy-fas.js +51 -49
  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 +165 -163
  891. package/dist/node_modules/dagre-d3-es/src/dagre/nesting-graph.js +45 -43
  892. package/dist/node_modules/dagre-d3-es/src/dagre/normalize.js +12 -10
  893. package/dist/node_modules/dagre-d3-es/src/dagre/order/add-subgraph-constraints.js +6 -4
  894. package/dist/node_modules/dagre-d3-es/src/dagre/order/barycenter.js +8 -6
  895. package/dist/node_modules/dagre-d3-es/src/dagre/order/build-layer-graph.js +14 -12
  896. package/dist/node_modules/dagre-d3-es/src/dagre/order/cross-count.js +22 -20
  897. package/dist/node_modules/dagre-d3-es/src/dagre/order/index.js +36 -34
  898. package/dist/node_modules/dagre-d3-es/src/dagre/order/init-order.js +16 -14
  899. package/dist/node_modules/dagre-d3-es/src/dagre/order/resolve-conflicts.js +32 -30
  900. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort-subgraph.js +30 -28
  901. package/dist/node_modules/dagre-d3-es/src/dagre/order/sort.js +20 -18
  902. package/dist/node_modules/dagre-d3-es/src/dagre/parent-dummy-chains.js +12 -10
  903. package/dist/node_modules/dagre-d3-es/src/dagre/position/bk.js +150 -148
  904. package/dist/node_modules/dagre-d3-es/src/dagre/position/index.js +20 -18
  905. package/dist/node_modules/dagre-d3-es/src/dagre/rank/feasible-tree.js +19 -17
  906. package/dist/node_modules/dagre-d3-es/src/dagre/rank/index.js +16 -14
  907. package/dist/node_modules/dagre-d3-es/src/dagre/rank/network-simplex.js +64 -63
  908. package/dist/node_modules/dagre-d3-es/src/dagre/rank/util.js +15 -13
  909. package/dist/node_modules/dagre-d3-es/src/dagre/util.js +84 -82
  910. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/dfs.js +15 -13
  911. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/dijkstra.js +3 -2
  912. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/floyd-warshall.js +3 -2
  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 +6 -4
  915. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/preorder.js +6 -4
  916. package/dist/node_modules/dagre-d3-es/src/graphlib/alg/topsort.js +13 -11
  917. package/dist/node_modules/dagre-d3-es/src/graphlib/graph.js +131 -129
  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 +23 -21
  920. package/dist/node_modules/dayjs/dayjs.min.js +6 -4
  921. package/dist/node_modules/dayjs/plugin/advancedFormat.js +6 -4
  922. package/dist/node_modules/dayjs/plugin/customParseFormat.js +6 -4
  923. package/dist/node_modules/dayjs/plugin/duration.js +6 -4
  924. package/dist/node_modules/dayjs/plugin/isoWeek.js +6 -4
  925. package/dist/node_modules/decode-named-character-reference/index.dom.js +7 -5
  926. package/dist/node_modules/devlop/lib/default.js +4 -2
  927. package/dist/node_modules/dompurify/dist/purify.es.js +203 -201
  928. package/dist/node_modules/entities/dist/esm/decode-codepoint.js +6 -4
  929. package/dist/node_modules/entities/dist/esm/decode.js +87 -85
  930. package/dist/node_modules/entities/dist/esm/generated/decode-data-html.js +4 -2
  931. package/dist/node_modules/estree-util-is-identifier-name/lib/index.js +6 -4
  932. package/dist/node_modules/extend/index.js +9 -6
  933. package/dist/node_modules/hast-util-from-dom/lib/index.js +32 -30
  934. package/dist/node_modules/hast-util-from-html-isomorphic/lib/browser.js +10 -8
  935. package/dist/node_modules/hast-util-from-parse5/lib/index.js +82 -80
  936. package/dist/node_modules/hast-util-is-element/lib/index.js +17 -15
  937. package/dist/node_modules/hast-util-parse-selector/lib/index.js +7 -5
  938. package/dist/node_modules/hast-util-raw/lib/index.js +136 -134
  939. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/doctype.js +23 -21
  940. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/error-codes.js +5 -3
  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 +250 -249
  943. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/common/token.js +6 -4
  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 +17 -15
  947. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/index.js +1497 -1495
  948. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/parser/open-element-stack.js +148 -146
  949. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/serializer/index.js +20 -19
  950. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/index.js +800 -798
  951. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tokenizer/preprocessor.js +33 -31
  952. package/dist/node_modules/hast-util-raw/node_modules/parse5/dist/tree-adapters/default.js +10 -8
  953. package/dist/node_modules/hast-util-sanitize/lib/index.js +106 -104
  954. package/dist/node_modules/hast-util-sanitize/lib/schema.js +12 -11
  955. package/dist/node_modules/hast-util-to-html/lib/handle/comment.js +9 -7
  956. package/dist/node_modules/hast-util-to-html/lib/handle/doctype.js +4 -2
  957. package/dist/node_modules/hast-util-to-html/lib/handle/element.js +25 -23
  958. package/dist/node_modules/hast-util-to-html/lib/handle/index.js +22 -21
  959. package/dist/node_modules/hast-util-to-html/lib/handle/raw.js +6 -4
  960. package/dist/node_modules/hast-util-to-html/lib/handle/root.js +4 -2
  961. package/dist/node_modules/hast-util-to-html/lib/handle/text.js +7 -5
  962. package/dist/node_modules/hast-util-to-html/lib/index.js +38 -36
  963. package/dist/node_modules/hast-util-to-html/lib/omission/closing.js +70 -68
  964. package/dist/node_modules/hast-util-to-html/lib/omission/omission.js +6 -4
  965. package/dist/node_modules/hast-util-to-html/lib/omission/opening.js +32 -30
  966. package/dist/node_modules/hast-util-to-html/lib/omission/util/siblings.js +10 -9
  967. package/dist/node_modules/hast-util-to-jsx-runtime/lib/index.js +192 -190
  968. package/dist/node_modules/hast-util-to-parse5/lib/index.js +71 -69
  969. package/dist/node_modules/hast-util-to-text/lib/index.js +61 -59
  970. package/dist/node_modules/hast-util-whitespace/lib/index.js +8 -6
  971. package/dist/node_modules/hastscript/lib/create-h.js +26 -24
  972. package/dist/node_modules/hastscript/lib/index.js +7 -5
  973. package/dist/node_modules/hastscript/lib/svg-case-sensitive-tag-names.js +4 -2
  974. package/dist/node_modules/html-url-attributes/lib/index.js +4 -2
  975. package/dist/node_modules/html-void-elements/index.js +4 -2
  976. package/dist/node_modules/inline-style-parser/cjs/index.js +6 -4
  977. package/dist/node_modules/internmap/src/index.js +22 -20
  978. package/dist/node_modules/katex/dist/katex.js +2914 -2873
  979. package/dist/node_modules/khroma/dist/channels/index.js +23 -21
  980. package/dist/node_modules/khroma/dist/channels/reusable.js +5 -3
  981. package/dist/node_modules/khroma/dist/channels/type.js +7 -5
  982. package/dist/node_modules/khroma/dist/color/hex.js +10 -8
  983. package/dist/node_modules/khroma/dist/color/hsl.js +19 -17
  984. package/dist/node_modules/khroma/dist/color/index.js +17 -15
  985. package/dist/node_modules/khroma/dist/color/keyword.js +10 -8
  986. package/dist/node_modules/khroma/dist/color/rgb.js +14 -12
  987. package/dist/node_modules/khroma/dist/constants.js +7 -5
  988. package/dist/node_modules/khroma/dist/methods/adjust.js +8 -6
  989. package/dist/node_modules/khroma/dist/methods/adjust_channel.js +8 -6
  990. package/dist/node_modules/khroma/dist/methods/change.js +9 -7
  991. package/dist/node_modules/khroma/dist/methods/channel.js +6 -4
  992. package/dist/node_modules/khroma/dist/methods/darken.js +5 -3
  993. package/dist/node_modules/khroma/dist/methods/invert.js +8 -6
  994. package/dist/node_modules/khroma/dist/methods/is_dark.js +5 -3
  995. package/dist/node_modules/khroma/dist/methods/is_light.js +5 -3
  996. package/dist/node_modules/khroma/dist/methods/lighten.js +5 -3
  997. package/dist/node_modules/khroma/dist/methods/luminance.js +8 -6
  998. package/dist/node_modules/khroma/dist/methods/mix.js +8 -6
  999. package/dist/node_modules/khroma/dist/methods/rgba.js +15 -13
  1000. package/dist/node_modules/khroma/dist/methods/transparentize.js +5 -0
  1001. package/dist/node_modules/khroma/dist/utils/channel.js +8 -6
  1002. package/dist/node_modules/khroma/dist/utils/index.js +10 -8
  1003. package/dist/node_modules/khroma/dist/utils/lang.js +4 -2
  1004. package/dist/node_modules/khroma/dist/utils/unit.js +4 -2
  1005. package/dist/node_modules/langium/lib/default-module.js +66 -64
  1006. package/dist/node_modules/langium/lib/dependency-injection.js +37 -39
  1007. package/dist/node_modules/langium/lib/documentation/comment-provider.js +7 -5
  1008. package/dist/node_modules/langium/lib/documentation/documentation-provider.js +8 -6
  1009. package/dist/node_modules/langium/lib/documentation/jsdoc.js +204 -202
  1010. package/dist/node_modules/langium/lib/languages/generated/ast.js +343 -534
  1011. package/dist/node_modules/langium/lib/languages/grammar-config.js +10 -8
  1012. package/dist/node_modules/langium/lib/parser/async-parser.js +4 -76
  1013. package/dist/node_modules/langium/lib/parser/completion-parser-builder.js +8 -6
  1014. package/dist/node_modules/langium/lib/parser/cst-node-builder.js +56 -54
  1015. package/dist/node_modules/langium/lib/parser/langium-parser-builder.js +9 -7
  1016. package/dist/node_modules/langium/lib/parser/langium-parser.js +190 -188
  1017. package/dist/node_modules/langium/lib/parser/lexer.js +25 -25
  1018. package/dist/node_modules/langium/lib/parser/parser-builder-base.js +204 -203
  1019. package/dist/node_modules/langium/lib/parser/token-builder.js +32 -30
  1020. package/dist/node_modules/langium/lib/parser/value-converter.js +17 -15
  1021. package/dist/node_modules/langium/lib/references/linker.js +104 -103
  1022. package/dist/node_modules/langium/lib/references/name-provider.js +9 -7
  1023. package/dist/node_modules/langium/lib/references/references.js +53 -51
  1024. package/dist/node_modules/langium/lib/references/scope-computation.js +14 -12
  1025. package/dist/node_modules/langium/lib/references/scope-provider.js +13 -11
  1026. package/dist/node_modules/langium/lib/references/scope.js +27 -56
  1027. package/dist/node_modules/langium/lib/serializer/hydrator.js +71 -69
  1028. package/dist/node_modules/langium/lib/serializer/json-serializer.js +23 -21
  1029. package/dist/node_modules/langium/lib/service-registry.js +7 -5
  1030. package/dist/node_modules/langium/lib/syntax-tree.js +33 -31
  1031. package/dist/node_modules/langium/lib/utils/ast-utils.js +77 -112
  1032. package/dist/node_modules/langium/lib/utils/caching.js +33 -42
  1033. package/dist/node_modules/langium/lib/utils/cancellation.js +7 -5
  1034. package/dist/node_modules/langium/lib/utils/collections.js +35 -33
  1035. package/dist/node_modules/langium/lib/utils/cst-utils.js +46 -161
  1036. package/dist/node_modules/langium/lib/utils/disposable.js +5 -3
  1037. package/dist/node_modules/langium/lib/utils/errors.js +8 -9
  1038. package/dist/node_modules/langium/lib/utils/event.js +7 -5
  1039. package/dist/node_modules/langium/lib/utils/grammar-loader.js +16 -14
  1040. package/dist/node_modules/langium/lib/utils/grammar-utils.js +172 -249
  1041. package/dist/node_modules/langium/lib/utils/promise-utils.js +18 -19
  1042. package/dist/node_modules/langium/lib/utils/regexp-utils.js +53 -76
  1043. package/dist/node_modules/langium/lib/utils/stream.js +155 -153
  1044. package/dist/node_modules/langium/lib/utils/uri-utils.js +14 -12
  1045. package/dist/node_modules/langium/lib/validation/document-validator.js +104 -103
  1046. package/dist/node_modules/langium/lib/validation/validation-registry.js +15 -14
  1047. package/dist/node_modules/langium/lib/workspace/ast-descriptions.js +19 -17
  1048. package/dist/node_modules/langium/lib/workspace/ast-node-locator.js +4 -2
  1049. package/dist/node_modules/langium/lib/workspace/configuration.js +7 -5
  1050. package/dist/node_modules/langium/lib/workspace/document-builder.js +131 -134
  1051. package/dist/node_modules/langium/lib/workspace/documents.js +85 -83
  1052. package/dist/node_modules/langium/lib/workspace/file-system-provider.js +5 -4
  1053. package/dist/node_modules/langium/lib/workspace/index-manager.js +16 -14
  1054. package/dist/node_modules/langium/lib/workspace/workspace-lock.js +11 -9
  1055. package/dist/node_modules/langium/lib/workspace/workspace-manager.js +35 -33
  1056. package/dist/node_modules/layout-base/layout-base.js +6 -4
  1057. package/dist/node_modules/lodash-es/_DataView.js +6 -4
  1058. package/dist/node_modules/lodash-es/_Hash.js +14 -13
  1059. package/dist/node_modules/lodash-es/_ListCache.js +14 -13
  1060. package/dist/node_modules/lodash-es/_Map.js +6 -4
  1061. package/dist/node_modules/lodash-es/_MapCache.js +14 -13
  1062. package/dist/node_modules/lodash-es/_Promise.js +6 -4
  1063. package/dist/node_modules/lodash-es/_Set.js +6 -4
  1064. package/dist/node_modules/lodash-es/_SetCache.js +10 -9
  1065. package/dist/node_modules/lodash-es/_Stack.js +12 -11
  1066. package/dist/node_modules/lodash-es/_Symbol.js +5 -3
  1067. package/dist/node_modules/lodash-es/_Uint8Array.js +5 -3
  1068. package/dist/node_modules/lodash-es/_WeakMap.js +6 -4
  1069. package/dist/node_modules/lodash-es/_apply.js +4 -3
  1070. package/dist/node_modules/lodash-es/_arrayEach.js +4 -3
  1071. package/dist/node_modules/lodash-es/_arrayFilter.js +4 -3
  1072. package/dist/node_modules/lodash-es/_arrayIncludes.js +6 -5
  1073. package/dist/node_modules/lodash-es/_arrayIncludesWith.js +4 -3
  1074. package/dist/node_modules/lodash-es/_arrayLikeKeys.js +13 -12
  1075. package/dist/node_modules/lodash-es/_arrayMap.js +4 -3
  1076. package/dist/node_modules/lodash-es/_arrayPush.js +4 -3
  1077. package/dist/node_modules/lodash-es/_arrayReduce.js +4 -3
  1078. package/dist/node_modules/lodash-es/_arraySome.js +4 -3
  1079. package/dist/node_modules/lodash-es/_asciiSize.js +5 -3
  1080. package/dist/node_modules/lodash-es/_assignMergeValue.js +7 -6
  1081. package/dist/node_modules/lodash-es/_assignValue.js +8 -7
  1082. package/dist/node_modules/lodash-es/_assocIndexOf.js +6 -5
  1083. package/dist/node_modules/lodash-es/_baseAssign.js +7 -6
  1084. package/dist/node_modules/lodash-es/_baseAssignIn.js +7 -6
  1085. package/dist/node_modules/lodash-es/_baseAssignValue.js +6 -5
  1086. package/dist/node_modules/lodash-es/_baseClone.js +51 -50
  1087. package/dist/node_modules/lodash-es/_baseCreate.js +7 -5
  1088. package/dist/node_modules/lodash-es/_baseEach.js +6 -4
  1089. package/dist/node_modules/lodash-es/_baseExtremum.js +6 -5
  1090. package/dist/node_modules/lodash-es/_baseFilter.js +6 -5
  1091. package/dist/node_modules/lodash-es/_baseFindIndex.js +4 -3
  1092. package/dist/node_modules/lodash-es/_baseFlatten.js +8 -7
  1093. package/dist/node_modules/lodash-es/_baseFor.js +5 -3
  1094. package/dist/node_modules/lodash-es/_baseForOwn.js +7 -6
  1095. package/dist/node_modules/lodash-es/_baseGet.js +8 -7
  1096. package/dist/node_modules/lodash-es/_baseGetAllKeys.js +7 -6
  1097. package/dist/node_modules/lodash-es/_baseGetTag.js +9 -8
  1098. package/dist/node_modules/lodash-es/_baseGt.js +4 -3
  1099. package/dist/node_modules/lodash-es/_baseHas.js +6 -5
  1100. package/dist/node_modules/lodash-es/_baseHasIn.js +4 -3
  1101. package/dist/node_modules/lodash-es/_baseIndexOf.js +8 -7
  1102. package/dist/node_modules/lodash-es/_baseIsArguments.js +8 -7
  1103. package/dist/node_modules/lodash-es/_baseIsEqual.js +7 -6
  1104. package/dist/node_modules/lodash-es/_baseIsEqualDeep.js +23 -22
  1105. package/dist/node_modules/lodash-es/_baseIsMap.js +8 -7
  1106. package/dist/node_modules/lodash-es/_baseIsMatch.js +9 -8
  1107. package/dist/node_modules/lodash-es/_baseIsNaN.js +4 -3
  1108. package/dist/node_modules/lodash-es/_baseIsNative.js +10 -9
  1109. package/dist/node_modules/lodash-es/_baseIsSet.js +8 -7
  1110. package/dist/node_modules/lodash-es/_baseIsTypedArray.js +10 -9
  1111. package/dist/node_modules/lodash-es/_baseIteratee.js +10 -9
  1112. package/dist/node_modules/lodash-es/_baseKeys.js +9 -8
  1113. package/dist/node_modules/lodash-es/_baseKeysIn.js +11 -10
  1114. package/dist/node_modules/lodash-es/_baseLt.js +4 -3
  1115. package/dist/node_modules/lodash-es/_baseMap.js +8 -7
  1116. package/dist/node_modules/lodash-es/_baseMatches.js +10 -9
  1117. package/dist/node_modules/lodash-es/_baseMatchesProperty.js +15 -14
  1118. package/dist/node_modules/lodash-es/_baseMerge.js +16 -15
  1119. package/dist/node_modules/lodash-es/_baseMergeDeep.js +24 -23
  1120. package/dist/node_modules/lodash-es/_baseOrderBy.js +23 -22
  1121. package/dist/node_modules/lodash-es/_basePick.js +8 -7
  1122. package/dist/node_modules/lodash-es/_basePickBy.js +9 -8
  1123. package/dist/node_modules/lodash-es/_baseProperty.js +4 -3
  1124. package/dist/node_modules/lodash-es/_basePropertyDeep.js +6 -5
  1125. package/dist/node_modules/lodash-es/_baseRange.js +6 -5
  1126. package/dist/node_modules/lodash-es/_baseReduce.js +4 -3
  1127. package/dist/node_modules/lodash-es/_baseRest.js +8 -7
  1128. package/dist/node_modules/lodash-es/_baseSet.js +14 -13
  1129. package/dist/node_modules/lodash-es/_baseSetToString.js +10 -8
  1130. package/dist/node_modules/lodash-es/_baseSortBy.js +4 -3
  1131. package/dist/node_modules/lodash-es/_baseTimes.js +4 -3
  1132. package/dist/node_modules/lodash-es/_baseToString.js +13 -12
  1133. package/dist/node_modules/lodash-es/_baseTrim.js +7 -6
  1134. package/dist/node_modules/lodash-es/_baseUnary.js +4 -3
  1135. package/dist/node_modules/lodash-es/_baseUniq.js +17 -16
  1136. package/dist/node_modules/lodash-es/_baseValues.js +6 -5
  1137. package/dist/node_modules/lodash-es/_baseZipObject.js +4 -3
  1138. package/dist/node_modules/lodash-es/_cacheHas.js +4 -3
  1139. package/dist/node_modules/lodash-es/_castFunction.js +6 -5
  1140. package/dist/node_modules/lodash-es/_castPath.js +9 -8
  1141. package/dist/node_modules/lodash-es/_cloneArrayBuffer.js +6 -5
  1142. package/dist/node_modules/lodash-es/_cloneBuffer.js +9 -8
  1143. package/dist/node_modules/lodash-es/_cloneDataView.js +6 -5
  1144. package/dist/node_modules/lodash-es/_cloneRegExp.js +6 -5
  1145. package/dist/node_modules/lodash-es/_cloneSymbol.js +7 -6
  1146. package/dist/node_modules/lodash-es/_cloneTypedArray.js +6 -5
  1147. package/dist/node_modules/lodash-es/_compareAscending.js +6 -5
  1148. package/dist/node_modules/lodash-es/_compareMultiple.js +6 -5
  1149. package/dist/node_modules/lodash-es/_copyArray.js +4 -3
  1150. package/dist/node_modules/lodash-es/_copyObject.js +7 -6
  1151. package/dist/node_modules/lodash-es/_copySymbols.js +7 -6
  1152. package/dist/node_modules/lodash-es/_copySymbolsIn.js +7 -6
  1153. package/dist/node_modules/lodash-es/_coreJsData.js +5 -3
  1154. package/dist/node_modules/lodash-es/_createAssigner.js +8 -7
  1155. package/dist/node_modules/lodash-es/_createBaseEach.js +6 -5
  1156. package/dist/node_modules/lodash-es/_createBaseFor.js +4 -3
  1157. package/dist/node_modules/lodash-es/_createFind.js +10 -9
  1158. package/dist/node_modules/lodash-es/_createRange.js +8 -7
  1159. package/dist/node_modules/lodash-es/_createSet.js +9 -7
  1160. package/dist/node_modules/lodash-es/_defineProperty.js +6 -4
  1161. package/dist/node_modules/lodash-es/_equalArrays.js +12 -11
  1162. package/dist/node_modules/lodash-es/_equalByTag.js +29 -28
  1163. package/dist/node_modules/lodash-es/_equalObjects.js +9 -8
  1164. package/dist/node_modules/lodash-es/_flatRest.js +8 -7
  1165. package/dist/node_modules/lodash-es/_freeGlobal.js +4 -2
  1166. package/dist/node_modules/lodash-es/_getAllKeys.js +8 -7
  1167. package/dist/node_modules/lodash-es/_getAllKeysIn.js +8 -7
  1168. package/dist/node_modules/lodash-es/_getMapData.js +6 -5
  1169. package/dist/node_modules/lodash-es/_getMatchData.js +8 -7
  1170. package/dist/node_modules/lodash-es/_getNative.js +8 -7
  1171. package/dist/node_modules/lodash-es/_getPrototype.js +5 -3
  1172. package/dist/node_modules/lodash-es/_getRawTag.js +10 -9
  1173. package/dist/node_modules/lodash-es/_getSymbols.js +9 -7
  1174. package/dist/node_modules/lodash-es/_getSymbolsIn.js +10 -8
  1175. package/dist/node_modules/lodash-es/_getTag.js +21 -19
  1176. package/dist/node_modules/lodash-es/_getValue.js +4 -3
  1177. package/dist/node_modules/lodash-es/_hasPath.js +13 -12
  1178. package/dist/node_modules/lodash-es/_hasUnicode.js +6 -5
  1179. package/dist/node_modules/lodash-es/_hashClear.js +6 -5
  1180. package/dist/node_modules/lodash-es/_hashDelete.js +5 -4
  1181. package/dist/node_modules/lodash-es/_hashGet.js +9 -8
  1182. package/dist/node_modules/lodash-es/_hashHas.js +7 -6
  1183. package/dist/node_modules/lodash-es/_hashSet.js +7 -6
  1184. package/dist/node_modules/lodash-es/_initCloneArray.js +6 -5
  1185. package/dist/node_modules/lodash-es/_initCloneByTag.js +29 -28
  1186. package/dist/node_modules/lodash-es/_initCloneObject.js +8 -7
  1187. package/dist/node_modules/lodash-es/_isFlattenable.js +9 -8
  1188. package/dist/node_modules/lodash-es/_isIndex.js +6 -5
  1189. package/dist/node_modules/lodash-es/_isIterateeCall.js +10 -9
  1190. package/dist/node_modules/lodash-es/_isKey.js +9 -8
  1191. package/dist/node_modules/lodash-es/_isKeyable.js +4 -3
  1192. package/dist/node_modules/lodash-es/_isMasked.js +9 -8
  1193. package/dist/node_modules/lodash-es/_isPrototype.js +6 -5
  1194. package/dist/node_modules/lodash-es/_isStrictComparable.js +6 -5
  1195. package/dist/node_modules/lodash-es/_listCacheClear.js +4 -3
  1196. package/dist/node_modules/lodash-es/_listCacheDelete.js +8 -7
  1197. package/dist/node_modules/lodash-es/_listCacheGet.js +6 -5
  1198. package/dist/node_modules/lodash-es/_listCacheHas.js +6 -5
  1199. package/dist/node_modules/lodash-es/_listCacheSet.js +6 -5
  1200. package/dist/node_modules/lodash-es/_mapCacheClear.js +10 -9
  1201. package/dist/node_modules/lodash-es/_mapCacheDelete.js +7 -6
  1202. package/dist/node_modules/lodash-es/_mapCacheGet.js +6 -5
  1203. package/dist/node_modules/lodash-es/_mapCacheHas.js +6 -5
  1204. package/dist/node_modules/lodash-es/_mapCacheSet.js +6 -5
  1205. package/dist/node_modules/lodash-es/_mapToArray.js +4 -3
  1206. package/dist/node_modules/lodash-es/_matchesStrictComparable.js +4 -3
  1207. package/dist/node_modules/lodash-es/_memoizeCapped.js +8 -7
  1208. package/dist/node_modules/lodash-es/_nativeCreate.js +5 -3
  1209. package/dist/node_modules/lodash-es/_nativeKeys.js +5 -3
  1210. package/dist/node_modules/lodash-es/_nativeKeysIn.js +4 -3
  1211. package/dist/node_modules/lodash-es/_nodeUtil.js +6 -4
  1212. package/dist/node_modules/lodash-es/_objectToString.js +6 -5
  1213. package/dist/node_modules/lodash-es/_overArg.js +4 -3
  1214. package/dist/node_modules/lodash-es/_overRest.js +9 -8
  1215. package/dist/node_modules/lodash-es/_root.js +5 -3
  1216. package/dist/node_modules/lodash-es/_safeGet.js +4 -3
  1217. package/dist/node_modules/lodash-es/_setCacheAdd.js +6 -5
  1218. package/dist/node_modules/lodash-es/_setCacheHas.js +4 -3
  1219. package/dist/node_modules/lodash-es/_setToArray.js +4 -3
  1220. package/dist/node_modules/lodash-es/_setToString.js +6 -4
  1221. package/dist/node_modules/lodash-es/_shortOut.js +7 -6
  1222. package/dist/node_modules/lodash-es/_stackClear.js +6 -5
  1223. package/dist/node_modules/lodash-es/_stackDelete.js +4 -3
  1224. package/dist/node_modules/lodash-es/_stackGet.js +4 -3
  1225. package/dist/node_modules/lodash-es/_stackHas.js +4 -3
  1226. package/dist/node_modules/lodash-es/_stackSet.js +11 -10
  1227. package/dist/node_modules/lodash-es/_strictIndexOf.js +4 -3
  1228. package/dist/node_modules/lodash-es/_stringSize.js +8 -7
  1229. package/dist/node_modules/lodash-es/_stringToPath.js +7 -5
  1230. package/dist/node_modules/lodash-es/_toKey.js +8 -7
  1231. package/dist/node_modules/lodash-es/_toSource.js +8 -7
  1232. package/dist/node_modules/lodash-es/_trimmedEndIndex.js +6 -5
  1233. package/dist/node_modules/lodash-es/_unicodeSize.js +17 -16
  1234. package/dist/node_modules/lodash-es/clone.js +7 -6
  1235. package/dist/node_modules/lodash-es/cloneDeep.js +7 -6
  1236. package/dist/node_modules/lodash-es/constant.js +4 -3
  1237. package/dist/node_modules/lodash-es/defaults.js +13 -11
  1238. package/dist/node_modules/lodash-es/eq.js +4 -3
  1239. package/dist/node_modules/lodash-es/filter.js +9 -8
  1240. package/dist/node_modules/lodash-es/find.js +6 -4
  1241. package/dist/node_modules/lodash-es/findIndex.js +10 -9
  1242. package/dist/node_modules/lodash-es/flatMap.js +7 -6
  1243. package/dist/node_modules/lodash-es/flatten.js +6 -5
  1244. package/dist/node_modules/lodash-es/forEach.js +9 -8
  1245. package/dist/node_modules/lodash-es/forIn.js +8 -7
  1246. package/dist/node_modules/lodash-es/forOwn.js +7 -6
  1247. package/dist/node_modules/lodash-es/get.js +6 -5
  1248. package/dist/node_modules/lodash-es/has.js +7 -6
  1249. package/dist/node_modules/lodash-es/hasIn.js +7 -6
  1250. package/dist/node_modules/lodash-es/identity.js +4 -3
  1251. package/dist/node_modules/lodash-es/isArguments.js +8 -6
  1252. package/dist/node_modules/lodash-es/isArray.js +4 -2
  1253. package/dist/node_modules/lodash-es/isArrayLike.js +7 -6
  1254. package/dist/node_modules/lodash-es/isArrayLikeObject.js +7 -6
  1255. package/dist/node_modules/lodash-es/isBuffer.js +6 -4
  1256. package/dist/node_modules/lodash-es/isEmpty.js +18 -17
  1257. package/dist/node_modules/lodash-es/isFunction.js +10 -9
  1258. package/dist/node_modules/lodash-es/isLength.js +6 -5
  1259. package/dist/node_modules/lodash-es/isMap.js +7 -5
  1260. package/dist/node_modules/lodash-es/isObject.js +4 -3
  1261. package/dist/node_modules/lodash-es/isObjectLike.js +4 -3
  1262. package/dist/node_modules/lodash-es/isPlainObject.js +13 -12
  1263. package/dist/node_modules/lodash-es/isSet.js +7 -5
  1264. package/dist/node_modules/lodash-es/isString.js +9 -8
  1265. package/dist/node_modules/lodash-es/isSymbol.js +8 -7
  1266. package/dist/node_modules/lodash-es/isTypedArray.js +7 -5
  1267. package/dist/node_modules/lodash-es/isUndefined.js +4 -3
  1268. package/dist/node_modules/lodash-es/keys.js +8 -7
  1269. package/dist/node_modules/lodash-es/keysIn.js +8 -7
  1270. package/dist/node_modules/lodash-es/last.js +4 -3
  1271. package/dist/node_modules/lodash-es/map.js +9 -8
  1272. package/dist/node_modules/lodash-es/mapValues.js +9 -8
  1273. package/dist/node_modules/lodash-es/max.js +8 -7
  1274. package/dist/node_modules/lodash-es/memoize.js +9 -8
  1275. package/dist/node_modules/lodash-es/merge.js +7 -5
  1276. package/dist/node_modules/lodash-es/min.js +8 -7
  1277. package/dist/node_modules/lodash-es/minBy.js +8 -7
  1278. package/dist/node_modules/lodash-es/noop.js +4 -3
  1279. package/dist/node_modules/lodash-es/now.js +6 -4
  1280. package/dist/node_modules/lodash-es/pick.js +7 -5
  1281. package/dist/node_modules/lodash-es/property.js +9 -8
  1282. package/dist/node_modules/lodash-es/range.js +5 -3
  1283. package/dist/node_modules/lodash-es/reduce.js +11 -10
  1284. package/dist/node_modules/lodash-es/size.js +13 -12
  1285. package/dist/node_modules/lodash-es/sortBy.js +9 -7
  1286. package/dist/node_modules/lodash-es/stubArray.js +4 -3
  1287. package/dist/node_modules/lodash-es/stubFalse.js +4 -3
  1288. package/dist/node_modules/lodash-es/toFinite.js +7 -6
  1289. package/dist/node_modules/lodash-es/toInteger.js +6 -5
  1290. package/dist/node_modules/lodash-es/toNumber.js +14 -13
  1291. package/dist/node_modules/lodash-es/toPlainObject.js +7 -6
  1292. package/dist/node_modules/lodash-es/toString.js +6 -5
  1293. package/dist/node_modules/lodash-es/union.js +9 -7
  1294. package/dist/node_modules/lodash-es/uniqBy.js +7 -6
  1295. package/dist/node_modules/lodash-es/uniqueId.js +8 -7
  1296. package/dist/node_modules/lodash-es/values.js +7 -6
  1297. package/dist/node_modules/lodash-es/zipObject.js +7 -6
  1298. package/dist/node_modules/longest-streak/index.js +4 -2
  1299. package/dist/node_modules/markdown-table/index.js +11 -9
  1300. package/dist/node_modules/marked/lib/marked.esm.js +687 -685
  1301. package/dist/node_modules/mdast-util-find-and-replace/lib/index.js +14 -12
  1302. package/dist/node_modules/mdast-util-find-and-replace/node_modules/escape-string-regexp/index.js +4 -2
  1303. package/dist/node_modules/mdast-util-from-markdown/lib/index.js +182 -180
  1304. package/dist/node_modules/mdast-util-gfm/lib/index.js +20 -18
  1305. package/dist/node_modules/mdast-util-gfm-autolink-literal/lib/index.js +69 -67
  1306. package/dist/node_modules/mdast-util-gfm-footnote/lib/index.js +47 -45
  1307. package/dist/node_modules/mdast-util-gfm-strikethrough/lib/index.js +15 -13
  1308. package/dist/node_modules/mdast-util-gfm-table/lib/index.js +30 -28
  1309. package/dist/node_modules/mdast-util-gfm-task-list-item/lib/index.js +16 -14
  1310. package/dist/node_modules/mdast-util-math/lib/index.js +15 -13
  1311. package/dist/node_modules/mdast-util-phrasing/lib/index.js +5 -3
  1312. package/dist/node_modules/mdast-util-to-hast/lib/footer.js +11 -9
  1313. package/dist/node_modules/mdast-util-to-hast/lib/handlers/blockquote.js +4 -2
  1314. package/dist/node_modules/mdast-util-to-hast/lib/handlers/break.js +4 -2
  1315. package/dist/node_modules/mdast-util-to-hast/lib/handlers/code.js +4 -2
  1316. package/dist/node_modules/mdast-util-to-hast/lib/handlers/delete.js +4 -2
  1317. package/dist/node_modules/mdast-util-to-hast/lib/handlers/emphasis.js +4 -2
  1318. package/dist/node_modules/mdast-util-to-hast/lib/handlers/footnote-reference.js +6 -4
  1319. package/dist/node_modules/mdast-util-to-hast/lib/handlers/heading.js +4 -2
  1320. package/dist/node_modules/mdast-util-to-hast/lib/handlers/html.js +4 -2
  1321. package/dist/node_modules/mdast-util-to-hast/lib/handlers/image-reference.js +8 -6
  1322. package/dist/node_modules/mdast-util-to-hast/lib/handlers/image.js +6 -4
  1323. package/dist/node_modules/mdast-util-to-hast/lib/handlers/index.js +55 -53
  1324. package/dist/node_modules/mdast-util-to-hast/lib/handlers/inline-code.js +4 -2
  1325. package/dist/node_modules/mdast-util-to-hast/lib/handlers/link-reference.js +8 -6
  1326. package/dist/node_modules/mdast-util-to-hast/lib/handlers/link.js +6 -4
  1327. package/dist/node_modules/mdast-util-to-hast/lib/handlers/list-item.js +15 -13
  1328. package/dist/node_modules/mdast-util-to-hast/lib/handlers/list.js +4 -2
  1329. package/dist/node_modules/mdast-util-to-hast/lib/handlers/paragraph.js +4 -2
  1330. package/dist/node_modules/mdast-util-to-hast/lib/handlers/root.js +4 -2
  1331. package/dist/node_modules/mdast-util-to-hast/lib/handlers/strong.js +4 -2
  1332. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table-cell.js +4 -2
  1333. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table-row.js +4 -2
  1334. package/dist/node_modules/mdast-util-to-hast/lib/handlers/table.js +6 -4
  1335. package/dist/node_modules/mdast-util-to-hast/lib/handlers/text.js +6 -4
  1336. package/dist/node_modules/mdast-util-to-hast/lib/handlers/thematic-break.js +4 -2
  1337. package/dist/node_modules/mdast-util-to-hast/lib/index.js +8 -6
  1338. package/dist/node_modules/mdast-util-to-hast/lib/revert.js +4 -2
  1339. package/dist/node_modules/mdast-util-to-hast/lib/state.js +61 -59
  1340. package/dist/node_modules/mdast-util-to-markdown/lib/handle/blockquote.js +6 -4
  1341. package/dist/node_modules/mdast-util-to-markdown/lib/handle/break.js +6 -4
  1342. package/dist/node_modules/mdast-util-to-markdown/lib/handle/code.js +18 -16
  1343. package/dist/node_modules/mdast-util-to-markdown/lib/handle/definition.js +6 -4
  1344. package/dist/node_modules/mdast-util-to-markdown/lib/handle/emphasis.js +14 -12
  1345. package/dist/node_modules/mdast-util-to-markdown/lib/handle/heading.js +8 -6
  1346. package/dist/node_modules/mdast-util-to-markdown/lib/handle/html.js +6 -4
  1347. package/dist/node_modules/mdast-util-to-markdown/lib/handle/image-reference.js +6 -4
  1348. package/dist/node_modules/mdast-util-to-markdown/lib/handle/image.js +8 -6
  1349. package/dist/node_modules/mdast-util-to-markdown/lib/handle/index.js +43 -41
  1350. package/dist/node_modules/mdast-util-to-markdown/lib/handle/inline-code.js +7 -5
  1351. package/dist/node_modules/mdast-util-to-markdown/lib/handle/link-reference.js +6 -4
  1352. package/dist/node_modules/mdast-util-to-markdown/lib/handle/link.js +11 -9
  1353. package/dist/node_modules/mdast-util-to-markdown/lib/handle/list-item.js +7 -5
  1354. package/dist/node_modules/mdast-util-to-markdown/lib/handle/list.js +12 -10
  1355. package/dist/node_modules/mdast-util-to-markdown/lib/handle/paragraph.js +4 -2
  1356. package/dist/node_modules/mdast-util-to-markdown/lib/handle/root.js +6 -4
  1357. package/dist/node_modules/mdast-util-to-markdown/lib/handle/strong.js +14 -12
  1358. package/dist/node_modules/mdast-util-to-markdown/lib/handle/text.js +4 -2
  1359. package/dist/node_modules/mdast-util-to-markdown/lib/handle/thematic-break.js +7 -5
  1360. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet-ordered.js +4 -2
  1361. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet-other.js +6 -4
  1362. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-bullet.js +4 -2
  1363. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-emphasis.js +4 -2
  1364. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-fence.js +4 -2
  1365. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-list-item-indent.js +4 -2
  1366. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-quote.js +4 -2
  1367. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-rule-repetition.js +4 -2
  1368. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-rule.js +4 -2
  1369. package/dist/node_modules/mdast-util-to-markdown/lib/util/check-strong.js +4 -2
  1370. package/dist/node_modules/mdast-util-to-markdown/lib/util/encode-character-reference.js +4 -2
  1371. package/dist/node_modules/mdast-util-to-markdown/lib/util/encode-info.js +6 -4
  1372. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-code-as-indented.js +4 -2
  1373. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-heading-as-setext.js +8 -7
  1374. package/dist/node_modules/mdast-util-to-markdown/lib/util/format-link-as-autolink.js +6 -4
  1375. package/dist/node_modules/mdast-util-to-markdown/lib/util/pattern-in-scope.js +6 -4
  1376. package/dist/node_modules/mdast-util-to-string/lib/index.js +14 -12
  1377. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/architectureDiagram-Q4EWVU46.js +695 -0
  1378. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/blockDiagram-DXYQGD6D.js +3038 -0
  1379. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{c4Diagram-YG6GDRKO.js → c4Diagram-AHTNJAMY.js} +581 -573
  1380. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-336JU56O.js +49 -0
  1381. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-426QAEUC.js +11 -0
  1382. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-4BX2VUAB.js +6 -4
  1383. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{chunk-B4BG7PRW.js → chunk-4TB4RGXK.js} +590 -444
  1384. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-55IACEB6.js +7 -5
  1385. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-5FUZZQ4R.js +3640 -0
  1386. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-5PVQY5BW.js +342 -0
  1387. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-AGHRB4JF.js +22 -20
  1388. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-BSJP7CBP.js +82 -0
  1389. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-EDXVE4YY.js +25 -0
  1390. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ENJZ2VHE.js +570 -0
  1391. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-FMBD7UC4.js +5 -3
  1392. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ICPOFSXX.js +2348 -0
  1393. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-OYMX7WX6.js +2014 -0
  1394. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-QZHKN3VN.js +8 -4
  1395. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-U2HBQHQK.js +274 -0
  1396. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-X2U36JSP.js +67 -0
  1397. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-XPW4576I.js +1146 -0
  1398. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-YZCP3GAM.js +62 -0
  1399. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ZZ45TVLE.js +32 -0
  1400. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-6PBFFD2Q.js +29 -0
  1401. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-v2-HSJHXN6E.js +29 -0
  1402. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/cose-bilkent-S5V4N54A.js +116 -114
  1403. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/dagre-KV5264BT.js +265 -0
  1404. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-5BDNPKRD.js +101 -0
  1405. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-G4DWMVQ6.js +284 -0
  1406. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-MMDJMWI5.js +213 -0
  1407. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-TYMM5635.js +133 -0
  1408. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{erDiagram-Q2GNP2WA.js → erDiagram-SMLLAGMA.js} +549 -445
  1409. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{flowDiagram-NV44I4VS.js → flowDiagram-DWJPFMVM.js} +1366 -1345
  1410. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ganttDiagram-T4ZO3ILL.js +1720 -0
  1411. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/gitGraphDiagram-UUTBAWPF.js +730 -0
  1412. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/infoDiagram-42DDH7IO.js +19 -0
  1413. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ishikawaDiagram-UXIWVN3A.js +718 -0
  1414. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/journeyDiagram-VCZTEJTY.js +885 -0
  1415. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{kanban-definition-3W4ZIXB7.js → kanban-definition-6JOO6SKY.js} +124 -118
  1416. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{mindmap-definition-VGOIOE7T.js → mindmap-definition-QFDTVHPH.js} +172 -122
  1417. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/pieDiagram-DEJITSTG.js +119 -0
  1418. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{quadrantDiagram-AYHSOK5B.js → quadrantDiagram-34T5L4WZ.js} +279 -273
  1419. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/{requirementDiagram-UZGBJVZJ.js → requirementDiagram-MS252O5E.js} +100 -66
  1420. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sankeyDiagram-XADWPNL6.js +529 -0
  1421. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-FGHM5R23.js +4159 -0
  1422. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-FHFEXIEX.js +222 -0
  1423. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-v2-QKLJ7IA2.js +27 -0
  1424. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/timeline-definition-GMOUNBTQ.js +1073 -0
  1425. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/vennDiagram-DHZGUBPP.js +961 -0
  1426. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/wardleyDiagram-NUSXRM2D.js +578 -0
  1427. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/xychartDiagram-5P7HB3ND.js +2000 -0
  1428. package/dist/node_modules/mermaid/dist/mermaid.core.js +492 -445
  1429. package/dist/node_modules/micromark/lib/constructs.js +80 -79
  1430. package/dist/node_modules/micromark/lib/create-tokenizer.js +14 -12
  1431. package/dist/node_modules/micromark/lib/initialize/content.js +9 -7
  1432. package/dist/node_modules/micromark/lib/initialize/document.js +15 -14
  1433. package/dist/node_modules/micromark/lib/initialize/flow.js +9 -7
  1434. package/dist/node_modules/micromark/lib/initialize/text.js +8 -6
  1435. package/dist/node_modules/micromark/lib/parse.js +20 -18
  1436. package/dist/node_modules/micromark/lib/postprocess.js +6 -4
  1437. package/dist/node_modules/micromark/lib/preprocess.js +6 -4
  1438. package/dist/node_modules/micromark-core-commonmark/lib/attention.js +20 -18
  1439. package/dist/node_modules/micromark-core-commonmark/lib/autolink.js +17 -15
  1440. package/dist/node_modules/micromark-core-commonmark/lib/blank-line.js +11 -9
  1441. package/dist/node_modules/micromark-core-commonmark/lib/block-quote.js +15 -13
  1442. package/dist/node_modules/micromark-core-commonmark/lib/character-escape.js +8 -6
  1443. package/dist/node_modules/micromark-core-commonmark/lib/character-reference.js +16 -14
  1444. package/dist/node_modules/micromark-core-commonmark/lib/code-fenced.js +22 -21
  1445. package/dist/node_modules/micromark-core-commonmark/lib/code-indented.js +16 -15
  1446. package/dist/node_modules/micromark-core-commonmark/lib/code-text.js +13 -11
  1447. package/dist/node_modules/micromark-core-commonmark/lib/content.js +18 -17
  1448. package/dist/node_modules/micromark-core-commonmark/lib/definition.js +30 -29
  1449. package/dist/node_modules/micromark-core-commonmark/lib/hard-break-escape.js +8 -6
  1450. package/dist/node_modules/micromark-core-commonmark/lib/heading-atx.js +15 -13
  1451. package/dist/node_modules/micromark-core-commonmark/lib/html-flow.js +68 -67
  1452. package/dist/node_modules/micromark-core-commonmark/lib/html-text.js +66 -64
  1453. package/dist/node_modules/micromark-core-commonmark/lib/label-end.js +112 -111
  1454. package/dist/node_modules/micromark-core-commonmark/lib/label-start-image.js +8 -6
  1455. package/dist/node_modules/micromark-core-commonmark/lib/label-start-link.js +8 -6
  1456. package/dist/node_modules/micromark-core-commonmark/lib/line-ending.js +8 -6
  1457. package/dist/node_modules/micromark-core-commonmark/lib/list.js +32 -31
  1458. package/dist/node_modules/micromark-core-commonmark/lib/setext-underline.js +12 -10
  1459. package/dist/node_modules/micromark-core-commonmark/lib/thematic-break.js +11 -9
  1460. package/dist/node_modules/micromark-extension-gfm/index.js +16 -14
  1461. package/dist/node_modules/micromark-extension-gfm-autolink-literal/lib/syntax.js +122 -120
  1462. package/dist/node_modules/micromark-extension-gfm-footnote/lib/syntax.js +33 -31
  1463. package/dist/node_modules/micromark-extension-gfm-strikethrough/lib/syntax.js +11 -9
  1464. package/dist/node_modules/micromark-extension-gfm-table/lib/edit-map.js +6 -4
  1465. package/dist/node_modules/micromark-extension-gfm-table/lib/infer.js +4 -2
  1466. package/dist/node_modules/micromark-extension-gfm-table/lib/syntax.js +36 -34
  1467. package/dist/node_modules/micromark-extension-gfm-task-list-item/lib/syntax.js +20 -18
  1468. package/dist/node_modules/micromark-extension-math/lib/math-flow.js +21 -20
  1469. package/dist/node_modules/micromark-extension-math/lib/math-text.js +11 -9
  1470. package/dist/node_modules/micromark-extension-math/lib/syntax.js +8 -6
  1471. package/dist/node_modules/micromark-factory-destination/index.js +10 -8
  1472. package/dist/node_modules/micromark-factory-label/index.js +7 -5
  1473. package/dist/node_modules/micromark-factory-space/index.js +7 -5
  1474. package/dist/node_modules/micromark-factory-title/index.js +8 -6
  1475. package/dist/node_modules/micromark-factory-whitespace/index.js +7 -5
  1476. package/dist/node_modules/micromark-util-character/index.js +14 -12
  1477. package/dist/node_modules/micromark-util-chunked/index.js +6 -4
  1478. package/dist/node_modules/micromark-util-classify-character/index.js +7 -5
  1479. package/dist/node_modules/micromark-util-combine-extensions/index.js +13 -11
  1480. package/dist/node_modules/micromark-util-decode-numeric-character-reference/index.js +4 -2
  1481. package/dist/node_modules/micromark-util-decode-string/index.js +11 -9
  1482. package/dist/node_modules/micromark-util-html-tag-name/index.js +4 -2
  1483. package/dist/node_modules/micromark-util-normalize-identifier/index.js +4 -2
  1484. package/dist/node_modules/micromark-util-resolve-all/index.js +4 -2
  1485. package/dist/node_modules/micromark-util-sanitize-uri/index.js +6 -4
  1486. package/dist/node_modules/micromark-util-subtokenize/index.js +10 -8
  1487. package/dist/node_modules/micromark-util-subtokenize/lib/splice-buffer.js +10 -8
  1488. package/dist/node_modules/motion/dist/es/react.js +2 -2
  1489. package/dist/node_modules/nanoid/index.browser.js +6 -4
  1490. package/dist/node_modules/nanoid/url-alphabet/index.js +4 -2
  1491. package/dist/node_modules/property-information/index.js +25 -23
  1492. package/dist/node_modules/property-information/lib/aria.js +41 -39
  1493. package/dist/node_modules/property-information/lib/find.js +18 -16
  1494. package/dist/node_modules/property-information/lib/hast-to-react.js +4 -2
  1495. package/dist/node_modules/property-information/lib/html.js +96 -94
  1496. package/dist/node_modules/property-information/lib/normalize.js +4 -2
  1497. package/dist/node_modules/property-information/lib/svg.js +79 -77
  1498. package/dist/node_modules/property-information/lib/util/case-insensitive-transform.js +6 -4
  1499. package/dist/node_modules/property-information/lib/util/case-sensitive-transform.js +4 -2
  1500. package/dist/node_modules/property-information/lib/util/create.js +10 -8
  1501. package/dist/node_modules/property-information/lib/util/defined-info.js +13 -11
  1502. package/dist/node_modules/property-information/lib/util/info.js +5 -3
  1503. package/dist/node_modules/property-information/lib/util/merge.js +6 -4
  1504. package/dist/node_modules/property-information/lib/util/schema.js +5 -3
  1505. package/dist/node_modules/property-information/lib/util/types.js +15 -14
  1506. package/dist/node_modules/property-information/lib/xlink.js +5 -3
  1507. package/dist/node_modules/property-information/lib/xml.js +5 -3
  1508. package/dist/node_modules/property-information/lib/xmlns.js +7 -5
  1509. package/dist/node_modules/rehype-harden/dist/index.js +47 -45
  1510. package/dist/node_modules/rehype-katex/lib/index.js +25 -23
  1511. package/dist/node_modules/rehype-raw/lib/index.js +6 -4
  1512. package/dist/node_modules/rehype-sanitize/lib/index.js +6 -4
  1513. package/dist/node_modules/remark-gfm/lib/index.js +9 -7
  1514. package/dist/node_modules/remark-math/lib/index.js +9 -7
  1515. package/dist/node_modules/remark-parse/lib/index.js +6 -4
  1516. package/dist/node_modules/remark-rehype/lib/index.js +7 -5
  1517. package/dist/node_modules/remend/dist/index.js +368 -297
  1518. package/dist/node_modules/roughjs/bundled/rough.esm.js +877 -875
  1519. package/dist/node_modules/shiki/dist/bundle-full.js +13 -11
  1520. package/dist/node_modules/shiki/dist/chunk-CtajNgzt.js +17 -0
  1521. package/dist/node_modules/shiki/dist/engine-oniguruma.js +7 -0
  1522. package/dist/node_modules/shiki/dist/{langs.js → langs-bundle-full-DfKZStlK.js} +8 -6
  1523. package/dist/node_modules/shiki/dist/themes.js +6 -4
  1524. package/dist/node_modules/shiki/dist/wasm.js +2 -2
  1525. package/dist/node_modules/space-separated-tokens/index.js +5 -3
  1526. package/dist/node_modules/streamdown/dist/chunk-BO2N2NFS.js +2500 -0
  1527. package/dist/node_modules/streamdown/dist/highlighted-body-OFNGDK62.js +37 -0
  1528. package/dist/node_modules/streamdown/dist/index.js +1 -1
  1529. package/dist/node_modules/streamdown/dist/mermaid-GHXKKRXX.js +3 -0
  1530. package/dist/node_modules/streamdown/node_modules/marked/lib/marked.esm.js +701 -699
  1531. package/dist/node_modules/stringify-entities/lib/constant/dangerous.js +4 -2
  1532. package/dist/node_modules/stringify-entities/lib/core.js +18 -16
  1533. package/dist/node_modules/stringify-entities/lib/index.js +7 -5
  1534. package/dist/node_modules/stringify-entities/lib/util/format-smart.js +10 -8
  1535. package/dist/node_modules/stringify-entities/lib/util/to-decimal.js +6 -4
  1536. package/dist/node_modules/stringify-entities/lib/util/to-hexadecimal.js +6 -4
  1537. package/dist/node_modules/stringify-entities/lib/util/to-named.js +14 -12
  1538. package/dist/node_modules/style-to-js/cjs/index.js +9 -7
  1539. package/dist/node_modules/style-to-js/cjs/utilities.js +6 -4
  1540. package/dist/node_modules/style-to-object/cjs/index.js +8 -6
  1541. package/dist/node_modules/stylis/src/Enum.js +4 -2
  1542. package/dist/node_modules/stylis/src/Parser.js +38 -36
  1543. package/dist/node_modules/stylis/src/Serializer.js +17 -15
  1544. package/dist/node_modules/stylis/src/Tokenizer.js +53 -51
  1545. package/dist/node_modules/stylis/src/Utility.js +17 -15
  1546. package/dist/node_modules/trim-lines/index.js +10 -8
  1547. package/dist/node_modules/trough/lib/index.js +6 -4
  1548. package/dist/node_modules/ts-dedent/esm/index.js +4 -2
  1549. package/dist/node_modules/unified/lib/callable-instance.js +4 -2
  1550. package/dist/node_modules/unified/lib/index.js +102 -101
  1551. package/dist/node_modules/unified/node_modules/is-plain-obj/index.js +4 -2
  1552. package/dist/node_modules/unist-util-find-after/lib/index.js +6 -4
  1553. package/dist/node_modules/unist-util-is/lib/index.js +31 -29
  1554. package/dist/node_modules/unist-util-position/lib/index.js +7 -5
  1555. package/dist/node_modules/unist-util-stringify-position/lib/index.js +10 -8
  1556. package/dist/node_modules/unist-util-visit/lib/index.js +6 -4
  1557. package/dist/node_modules/unist-util-visit-parents/lib/color.js +4 -2
  1558. package/dist/node_modules/unist-util-visit-parents/lib/index.js +21 -20
  1559. package/dist/node_modules/uuid/dist/esm-browser/native.js +3 -2
  1560. package/dist/node_modules/uuid/dist/esm-browser/rng.js +8 -6
  1561. package/dist/node_modules/uuid/dist/esm-browser/stringify.js +7 -5
  1562. package/dist/node_modules/uuid/dist/esm-browser/v4.js +10 -9
  1563. package/dist/node_modules/vaul/dist/index.js +276 -274
  1564. package/dist/node_modules/vfile/lib/index.js +44 -42
  1565. package/dist/node_modules/vfile/lib/minpath.browser.js +22 -20
  1566. package/dist/node_modules/vfile/lib/minproc.browser.js +5 -3
  1567. package/dist/node_modules/vfile/lib/minurl.browser.js +8 -6
  1568. package/dist/node_modules/vfile/lib/minurl.shared.js +4 -2
  1569. package/dist/node_modules/vfile-location/lib/index.js +7 -5
  1570. package/dist/node_modules/vfile-message/lib/index.js +7 -5
  1571. package/dist/node_modules/vscode-jsonrpc/browser.js +8 -6
  1572. package/dist/node_modules/vscode-jsonrpc/lib/browser/main.js +11 -9
  1573. package/dist/node_modules/vscode-jsonrpc/lib/browser/ril.js +8 -6
  1574. package/dist/node_modules/vscode-jsonrpc/lib/common/api.js +28 -26
  1575. package/dist/node_modules/vscode-jsonrpc/lib/common/cancellation.js +17 -15
  1576. package/dist/node_modules/vscode-jsonrpc/lib/common/connection.js +13 -11
  1577. package/dist/node_modules/vscode-jsonrpc/lib/common/disposable.js +6 -4
  1578. package/dist/node_modules/vscode-jsonrpc/lib/common/events.js +8 -6
  1579. package/dist/node_modules/vscode-jsonrpc/lib/common/is.js +6 -4
  1580. package/dist/node_modules/vscode-jsonrpc/lib/common/linkedMap.js +6 -4
  1581. package/dist/node_modules/vscode-jsonrpc/lib/common/messageBuffer.js +6 -4
  1582. package/dist/node_modules/vscode-jsonrpc/lib/common/messageReader.js +11 -9
  1583. package/dist/node_modules/vscode-jsonrpc/lib/common/messageWriter.js +31 -29
  1584. package/dist/node_modules/vscode-jsonrpc/lib/common/messages.js +8 -6
  1585. package/dist/node_modules/vscode-jsonrpc/lib/common/ral.js +6 -4
  1586. package/dist/node_modules/vscode-jsonrpc/lib/common/semaphore.js +8 -6
  1587. package/dist/node_modules/vscode-jsonrpc/lib/common/sharedArrayCancellation.js +8 -6
  1588. package/dist/node_modules/vscode-languageserver-protocol/lib/browser/main.js +10 -8
  1589. package/dist/node_modules/vscode-languageserver-protocol/lib/common/api.js +23 -21
  1590. package/dist/node_modules/vscode-languageserver-protocol/lib/common/connection.js +8 -6
  1591. package/dist/node_modules/vscode-languageserver-protocol/lib/common/messages.js +8 -6
  1592. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.callHierarchy.js +8 -6
  1593. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.colorProvider.js +8 -6
  1594. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.configuration.js +8 -6
  1595. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.declaration.js +8 -6
  1596. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.diagnostic.js +14 -12
  1597. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.fileOperations.js +8 -6
  1598. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.foldingRange.js +8 -6
  1599. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.implementation.js +8 -6
  1600. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlayHint.js +8 -6
  1601. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineCompletion.js +8 -6
  1602. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.inlineValue.js +8 -6
  1603. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.js +55 -53
  1604. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.linkedEditingRange.js +8 -6
  1605. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.moniker.js +8 -6
  1606. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.notebook.js +10 -8
  1607. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.progress.js +12 -10
  1608. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.selectionRange.js +8 -6
  1609. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.semanticTokens.js +8 -6
  1610. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.showDocument.js +8 -6
  1611. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeDefinition.js +8 -6
  1612. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.typeHierarchy.js +8 -6
  1613. package/dist/node_modules/vscode-languageserver-protocol/lib/common/protocol.workspaceFolder.js +8 -6
  1614. package/dist/node_modules/vscode-languageserver-protocol/lib/common/utils/is.js +6 -4
  1615. package/dist/node_modules/vscode-languageserver-textdocument/lib/esm/main.js +21 -19
  1616. package/dist/node_modules/vscode-languageserver-types/lib/esm/main.js +849 -847
  1617. package/dist/node_modules/vscode-uri/lib/esm/index.js +6 -4
  1618. package/dist/node_modules/web-namespaces/index.js +4 -2
  1619. package/dist/node_modules/zwitch/index.js +7 -5
  1620. package/dist/packages/contracts/dist/enums/index.js +14 -12
  1621. package/dist/packages/contracts/dist/enums/registry.enum.js +6 -4
  1622. package/dist/packages/contracts/dist/enums/sort-order.enum.js +6 -4
  1623. package/dist/packages/contracts/dist/enums/user-type.enum.js +6 -4
  1624. package/dist/packages/contracts/dist/enums/workflow-state.enum.js +6 -4
  1625. package/dist/pages/DashboardPage.js +55 -99
  1626. package/dist/pages/DebugPage.js +12 -17
  1627. package/dist/pages/DebugWorkflowDetailsPage.js +91 -119
  1628. package/dist/pages/DebugWorkflowsPage.js +39 -37
  1629. package/dist/pages/EmbedWorkbenchPage.js +48 -62
  1630. package/dist/pages/PreviewWorkbenchPage.js +243 -324
  1631. package/dist/pages/RunsListPage.js +44 -61
  1632. package/dist/pages/RunsPage.js +31 -48
  1633. package/dist/pages/StudioLandingPage.js +97 -132
  1634. package/dist/pages/WorkbenchPage.js +56 -86
  1635. package/dist/pages/WorkflowDebugPage.js +74 -110
  1636. package/dist/pages/WorkspacePage.js +72 -115
  1637. package/dist/pages/WorkspaceRunsPage.js +43 -70
  1638. package/dist/pages/WorkspacesPage.js +24 -35
  1639. package/dist/providers/ComponentOverridesProvider.js +9 -12
  1640. package/dist/providers/InvalidationEventsProvider.js +33 -35
  1641. package/dist/providers/QueryProvider.js +14 -18
  1642. package/dist/providers/SseProvider.js +28 -29
  1643. package/dist/providers/StudioProvider.js +14 -19
  1644. package/dist/routing/LocalRouter.js +6 -9
  1645. package/dist/services/createApiClient.js +7 -5
  1646. package/dist/services/eventEmitter.js +3 -2
  1647. package/dist/services/index.js +2 -2
  1648. package/dist/types/ai.types.js +7 -5
  1649. package/package.json +33 -33
  1650. package/dist/_virtual/rolldown_runtime.js +0 -20
  1651. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/architecture-7HQA4BMR.js +0 -3
  1652. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-4F5CHEZ2.js +0 -23
  1653. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-B2363JML.js +0 -60
  1654. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-FRFDVMJY.js +0 -23
  1655. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-PL6DKKU2.js +0 -28
  1656. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-SJTYNZTY.js +0 -23
  1657. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-TCCFYFTB.js +0 -787
  1658. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-TQ3KTPDO.js +0 -23
  1659. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/chunk-UMXZTB3W.js +0 -30
  1660. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/gitGraph-G5XIXVHT.js +0 -3
  1661. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/info-VBDWY6EO.js +0 -3
  1662. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/packet-DYOGHKS2.js +0 -3
  1663. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/pie-VRWISCQL.js +0 -3
  1664. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/radar-ZZBFDIW7.js +0 -3
  1665. package/dist/node_modules/@mermaid-js/parser/dist/chunks/mermaid-parser.core/treemap-GDKQZRPO.js +0 -3
  1666. package/dist/node_modules/@ungap/structured-clone/esm/types.js +0 -2
  1667. package/dist/node_modules/chevrotain/lib/src/parse/parser/traits/context_assist.js +0 -16
  1668. package/dist/node_modules/langium/lib/index.js +0 -182
  1669. package/dist/node_modules/langium/lib/parser/indentation-aware.js +0 -141
  1670. package/dist/node_modules/langium/lib/utils/index.js +0 -53
  1671. package/dist/node_modules/langium/lib/workspace/profiler.js +0 -89
  1672. package/dist/node_modules/lodash/_Symbol.js +0 -7
  1673. package/dist/node_modules/lodash/_baseGetTag.js +0 -13
  1674. package/dist/node_modules/lodash/_baseTrim.js +0 -11
  1675. package/dist/node_modules/lodash/_freeGlobal.js +0 -6
  1676. package/dist/node_modules/lodash/_getRawTag.js +0 -17
  1677. package/dist/node_modules/lodash/_objectToString.js +0 -10
  1678. package/dist/node_modules/lodash/_root.js +0 -8
  1679. package/dist/node_modules/lodash/_trimmedEndIndex.js +0 -11
  1680. package/dist/node_modules/lodash/isObject.js +0 -10
  1681. package/dist/node_modules/lodash/isObjectLike.js +0 -9
  1682. package/dist/node_modules/lodash/isSymbol.js +0 -12
  1683. package/dist/node_modules/lodash/now.js +0 -10
  1684. package/dist/node_modules/lodash/toNumber.js +0 -22
  1685. package/dist/node_modules/lodash-es/_arrayAggregator.js +0 -9
  1686. package/dist/node_modules/lodash-es/_arrayEvery.js +0 -6
  1687. package/dist/node_modules/lodash-es/_baseAggregator.js +0 -8
  1688. package/dist/node_modules/lodash-es/_baseDifference.js +0 -22
  1689. package/dist/node_modules/lodash-es/_baseEvery.js +0 -9
  1690. package/dist/node_modules/lodash-es/_baseIsRegExp.js +0 -8
  1691. package/dist/node_modules/lodash-es/_baseSlice.js +0 -8
  1692. package/dist/node_modules/lodash-es/_baseSome.js +0 -9
  1693. package/dist/node_modules/lodash-es/_createAggregator.js +0 -12
  1694. package/dist/node_modules/lodash-es/assign.js +0 -14
  1695. package/dist/node_modules/lodash-es/compact.js +0 -9
  1696. package/dist/node_modules/lodash-es/difference.js +0 -8
  1697. package/dist/node_modules/lodash-es/drop.js +0 -8
  1698. package/dist/node_modules/lodash-es/dropRight.js +0 -8
  1699. package/dist/node_modules/lodash-es/every.js +0 -11
  1700. package/dist/node_modules/lodash-es/groupBy.js +0 -6
  1701. package/dist/node_modules/lodash-es/head.js +0 -5
  1702. package/dist/node_modules/lodash-es/includes.js +0 -13
  1703. package/dist/node_modules/lodash-es/indexOf.js +0 -11
  1704. package/dist/node_modules/lodash-es/isRegExp.js +0 -5
  1705. package/dist/node_modules/lodash-es/negate.js +0 -16
  1706. package/dist/node_modules/lodash-es/pickBy.js +0 -15
  1707. package/dist/node_modules/lodash-es/reject.js +0 -10
  1708. package/dist/node_modules/lodash-es/some.js +0 -11
  1709. package/dist/node_modules/lodash-es/uniq.js +0 -6
  1710. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/architectureDiagram-VXUJARFQ.js +0 -673
  1711. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/blockDiagram-VD42YOAC.js +0 -3010
  1712. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ABZYJK2D.js +0 -1547
  1713. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-ATLVNIR6.js +0 -65
  1714. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-CVBHYZKI.js +0 -10
  1715. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-DI55MBZ5.js +0 -1994
  1716. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-DR5Q36YT.js +0 -135
  1717. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-EXTU4WIE.js +0 -9
  1718. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-HN2XXSSU.js +0 -74
  1719. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-JA3XYJ7Z.js +0 -247
  1720. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-JZLCHNYA.js +0 -3516
  1721. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-MI3HLSF2.js +0 -1140
  1722. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-N4CR4FBY.js +0 -39
  1723. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-QN33PNHL.js +0 -23
  1724. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-QXUST7PY.js +0 -497
  1725. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-S3R3BYOJ.js +0 -338
  1726. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/chunk-TZMSLE5B.js +0 -55
  1727. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-2ON5EDUG.js +0 -26
  1728. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/classDiagram-v2-WZHVMYZB.js +0 -26
  1729. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/dagre-6UL2VRFP.js +0 -263
  1730. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-PSM6KHXK.js +0 -283
  1731. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-QEK2KX5R.js +0 -211
  1732. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/diagram-S2PKOQOG.js +0 -129
  1733. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/ganttDiagram-JELNMOA3.js +0 -1688
  1734. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/gitGraphDiagram-V2S2FVAM.js +0 -621
  1735. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/infoDiagram-HS3SLOUP.js +0 -18
  1736. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/journeyDiagram-XKPGCS4Q.js +0 -883
  1737. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/pieDiagram-ADFJNKIX.js +0 -117
  1738. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sankeyDiagram-TZEHDZUN.js +0 -519
  1739. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/sequenceDiagram-WL72ISMW.js +0 -3560
  1740. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-FKZM4ZOC.js +0 -220
  1741. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/stateDiagram-v2-4FDKWEC3.js +0 -25
  1742. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/timeline-definition-IT6M3QCI.js +0 -833
  1743. package/dist/node_modules/mermaid/dist/chunks/mermaid.core/xychartDiagram-PRI3JC2R.js +0 -1975
  1744. package/dist/node_modules/streamdown/dist/chunk-RLXIAIE6.js +0 -2189
  1745. package/dist/node_modules/streamdown/dist/highlighted-body-B3W2YXNL.js +0 -33
  1746. package/dist/node_modules/streamdown/dist/mermaid-3ZIDBTTL.js +0 -3
@@ -1,3516 +0,0 @@
1
- import { __name, log } from "./chunk-AGHRB4JF.js";
2
- import { common_default, defaultConfig_default, evaluate, getConfig, getConfig2, hasKatex, parseGenericTypes, renderKatexSanitized, sanitizeText, sanitizeText3 } from "./chunk-ABZYJK2D.js";
3
- import select_default from "../../../../d3-selection/src/select.js";
4
- import "../../../../d3/src/index.js";
5
- import { getSubGraphTitleMargins } from "./chunk-CVBHYZKI.js";
6
- import { compileStyles, solidStateFill, styles2String, userNodeOverrides } from "./chunk-ATLVNIR6.js";
7
- import { calculateTextWidth, decodeEntities, handleUndefinedAttr, parseFontSize } from "./chunk-S3R3BYOJ.js";
8
- import { createText, getIconSVG } from "./chunk-JA3XYJ7Z.js";
9
- import { at } from "../../../../roughjs/bundled/rough.esm.js";
10
- var labelHelper = /* @__PURE__ */ __name(async (l, u, p) => {
11
- let h, g = u.useHtmlLabels || evaluate(getConfig2()?.htmlLabels);
12
- h = p || "node default";
13
- let _ = l.insert("g").attr("class", h).attr("id", u.domId || u.id), y = _.insert("g").attr("class", "label").attr("style", handleUndefinedAttr(u.labelStyle)), x;
14
- x = u.label === void 0 ? "" : typeof u.label == "string" ? u.label : u.label[0];
15
- let S = await createText(y, sanitizeText(decodeEntities(x), getConfig2()), {
16
- useHtmlLabels: g,
17
- width: u.width || getConfig2().flowchart?.wrappingWidth,
18
- cssClasses: "markdown-node-label",
19
- style: u.labelStyle,
20
- addSvgBackground: !!u.icon || !!u.img
21
- }), C = S.getBBox(), w = (u?.padding ?? 0) / 2;
22
- if (g) {
23
- let l = S.children[0], u = select_default(S), f = l.getElementsByTagName("img");
24
- if (f) {
25
- let l = x.replace(/<img[^>]*>/g, "").trim() === "";
26
- await Promise.all([...f].map((u) => new Promise((f) => {
27
- function p() {
28
- if (u.style.display = "flex", u.style.flexDirection = "column", l) {
29
- let [e = defaultConfig_default.fontSize] = parseFontSize(getConfig2().fontSize ? getConfig2().fontSize : window.getComputedStyle(document.body).fontSize), l = e * 5 + "px";
30
- u.style.minWidth = l, u.style.maxWidth = l;
31
- } else u.style.width = "100%";
32
- f(u);
33
- }
34
- __name(p, "setupImage"), setTimeout(() => {
35
- u.complete && p();
36
- }), u.addEventListener("error", p), u.addEventListener("load", p);
37
- })));
38
- }
39
- C = l.getBoundingClientRect(), u.attr("width", C.width), u.attr("height", C.height);
40
- }
41
- return g ? y.attr("transform", "translate(" + -C.width / 2 + ", " + -C.height / 2 + ")") : y.attr("transform", "translate(0, " + -C.height / 2 + ")"), u.centerLabel && y.attr("transform", "translate(" + -C.width / 2 + ", " + -C.height / 2 + ")"), y.insert("rect", ":first-child"), {
42
- shapeSvg: _,
43
- bbox: C,
44
- halfPadding: w,
45
- label: y
46
- };
47
- }, "labelHelper"), insertLabel = /* @__PURE__ */ __name(async (e, l, u) => {
48
- let d = u.useHtmlLabels || evaluate(getConfig2()?.flowchart?.htmlLabels), p = e.insert("g").attr("class", "label").attr("style", u.labelStyle || ""), h = await createText(p, sanitizeText(decodeEntities(l), getConfig2()), {
49
- useHtmlLabels: d,
50
- width: u.width || getConfig2()?.flowchart?.wrappingWidth,
51
- style: u.labelStyle,
52
- addSvgBackground: !!u.icon || !!u.img
53
- }), g = h.getBBox(), _ = u.padding / 2;
54
- if (evaluate(getConfig2()?.flowchart?.htmlLabels)) {
55
- let e = h.children[0], l = select_default(h);
56
- g = e.getBoundingClientRect(), l.attr("width", g.width), l.attr("height", g.height);
57
- }
58
- return d ? p.attr("transform", "translate(" + -g.width / 2 + ", " + -g.height / 2 + ")") : p.attr("transform", "translate(0, " + -g.height / 2 + ")"), u.centerLabel && p.attr("transform", "translate(" + -g.width / 2 + ", " + -g.height / 2 + ")"), p.insert("rect", ":first-child"), {
59
- shapeSvg: e,
60
- bbox: g,
61
- halfPadding: _,
62
- label: p
63
- };
64
- }, "insertLabel"), updateNodeBounds = /* @__PURE__ */ __name((e, l) => {
65
- let u = l.node().getBBox();
66
- e.width = u.width, e.height = u.height;
67
- }, "updateNodeBounds"), getNodeClasses = /* @__PURE__ */ __name((e, l) => (e.look === "handDrawn" ? "rough-node" : "node") + " " + e.cssClasses + " " + (l || ""), "getNodeClasses");
68
- function createPathFromPoints(e) {
69
- let l = e.map((e, l) => `${l === 0 ? "M" : "L"}${e.x},${e.y}`);
70
- return l.push("Z"), l.join(" ");
71
- }
72
- __name(createPathFromPoints, "createPathFromPoints");
73
- function generateFullSineWavePoints(e, l, u, d, f, p) {
74
- let m = [], h = u - e, g = d - l, _ = h / p, v = 2 * Math.PI / _, y = l + g / 2;
75
- for (let l = 0; l <= 50; l++) {
76
- let u = e + l / 50 * h, d = y + f * Math.sin(v * (u - e));
77
- m.push({
78
- x: u,
79
- y: d
80
- });
81
- }
82
- return m;
83
- }
84
- __name(generateFullSineWavePoints, "generateFullSineWavePoints");
85
- function generateCirclePoints(e, l, u, d, f, p) {
86
- let m = [], h = f * Math.PI / 180, g = (p * Math.PI / 180 - h) / (d - 1);
87
- for (let f = 0; f < d; f++) {
88
- let d = h + f * g, p = e + u * Math.cos(d), _ = l + u * Math.sin(d);
89
- m.push({
90
- x: -p,
91
- y: -_
92
- });
93
- }
94
- return m;
95
- }
96
- __name(generateCirclePoints, "generateCirclePoints");
97
- var intersect_rect_default = /* @__PURE__ */ __name((e, l) => {
98
- var u = e.x, d = e.y, f = l.x - u, p = l.y - d, m = e.width / 2, h = e.height / 2, g, _;
99
- return Math.abs(p) * m > Math.abs(f) * h ? (p < 0 && (h = -h), g = p === 0 ? 0 : h * f / p, _ = h) : (f < 0 && (m = -m), g = m, _ = f === 0 ? 0 : m * p / f), {
100
- x: u + g,
101
- y: d + _
102
- };
103
- }, "intersectRect");
104
- function applyStyle(e, l) {
105
- l && e.attr("style", l);
106
- }
107
- __name(applyStyle, "applyStyle");
108
- async function addHtmlLabel(e) {
109
- let l = select_default(document.createElementNS("http://www.w3.org/2000/svg", "foreignObject")), d = l.append("xhtml:div"), f = getConfig2(), p = e.label;
110
- e.label && hasKatex(e.label) && (p = await renderKatexSanitized(e.label.replace(common_default.lineBreakRegex, "\n"), f));
111
- let g = "<span class=\"" + (e.isNode ? "nodeLabel" : "edgeLabel") + "\" " + (e.labelStyle ? "style=\"" + e.labelStyle + "\"" : "") + ">" + p + "</span>";
112
- return d.html(sanitizeText(g, f)), applyStyle(d, e.labelStyle), d.style("display", "inline-block"), d.style("padding-right", "1px"), d.style("white-space", "nowrap"), d.attr("xmlns", "http://www.w3.org/1999/xhtml"), l.node();
113
- }
114
- __name(addHtmlLabel, "addHtmlLabel");
115
- var createLabel_default = /* @__PURE__ */ __name(async (e, u, d, p) => {
116
- let h = e || "";
117
- if (typeof h == "object" && (h = h[0]), evaluate(getConfig2().flowchart.htmlLabels)) return h = h.replace(/\\n|\n/g, "<br />"), log.info("vertexText" + h), await addHtmlLabel({
118
- isNode: p,
119
- label: decodeEntities(h).replace(/fa[blrs]?:fa-[\w-]+/g, (e) => `<i class='${e.replace(":", " ")}'></i>`),
120
- labelStyle: u && u.replace("fill:", "color:")
121
- });
122
- {
123
- let e = document.createElementNS("http://www.w3.org/2000/svg", "text");
124
- e.setAttribute("style", u.replace("color:", "fill:"));
125
- let l = [];
126
- l = typeof h == "string" ? h.split(/\\n|\n|<br\s*\/?>/gi) : Array.isArray(h) ? h : [];
127
- for (let u of l) {
128
- let l = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
129
- l.setAttributeNS("http://www.w3.org/XML/1998/namespace", "xml:space", "preserve"), l.setAttribute("dy", "1em"), l.setAttribute("x", "0"), d ? l.setAttribute("class", "title-row") : l.setAttribute("class", "row"), l.textContent = u.trim(), e.appendChild(l);
130
- }
131
- return e;
132
- }
133
- }, "createLabel"), createRoundedRectPathD = /* @__PURE__ */ __name((e, l, u, d, f) => [
134
- "M",
135
- e + f,
136
- l,
137
- "H",
138
- e + u - f,
139
- "A",
140
- f,
141
- f,
142
- 0,
143
- 0,
144
- 1,
145
- e + u,
146
- l + f,
147
- "V",
148
- l + d - f,
149
- "A",
150
- f,
151
- f,
152
- 0,
153
- 0,
154
- 1,
155
- e + u - f,
156
- l + d,
157
- "H",
158
- e + f,
159
- "A",
160
- f,
161
- f,
162
- 0,
163
- 0,
164
- 1,
165
- e,
166
- l + d - f,
167
- "V",
168
- l + f,
169
- "A",
170
- f,
171
- f,
172
- 0,
173
- 0,
174
- 1,
175
- e + f,
176
- l,
177
- "Z"
178
- ].join(" "), "createRoundedRectPathD"), rect = /* @__PURE__ */ __name(async (e, u) => {
179
- log.info("Creating subgraph rect for ", u.id, u);
180
- let d = getConfig2(), { themeVariables: p, handDrawnSeed: h } = d, { clusterBkg: g, clusterBorder: _ } = p, { labelStyles: v, nodeStyles: y, borderStyles: S, backgroundStyles: C } = styles2String(u), E = e.insert("g").attr("class", "cluster " + u.cssClasses).attr("id", u.id).attr("data-look", u.look), D = evaluate(d.flowchart.htmlLabels), O = E.insert("g").attr("class", "cluster-label "), k = await createText(O, u.label, {
181
- style: u.labelStyle,
182
- useHtmlLabels: D,
183
- isNode: !0
184
- }), j = k.getBBox();
185
- if (evaluate(d.flowchart.htmlLabels)) {
186
- let e = k.children[0], l = select_default(k);
187
- j = e.getBoundingClientRect(), l.attr("width", j.width), l.attr("height", j.height);
188
- }
189
- let M = u.width <= j.width + u.padding ? j.width + u.padding : u.width;
190
- u.width <= j.width + u.padding ? u.diff = (M - u.width) / 2 - u.padding : u.diff = -u.padding;
191
- let N = u.height, P = u.x - M / 2, F = u.y - N / 2;
192
- log.trace("Data ", u, JSON.stringify(u));
193
- let I;
194
- if (u.look === "handDrawn") {
195
- let e = at.svg(E), d = userNodeOverrides(u, {
196
- roughness: .7,
197
- fill: g,
198
- stroke: _,
199
- fillWeight: 3,
200
- seed: h
201
- }), f = e.path(createRoundedRectPathD(P, F, M, N, 0), d);
202
- I = E.insert(() => (log.debug("Rough node insert CXC", f), f), ":first-child"), I.select("path:nth-child(2)").attr("style", S.join(";")), I.select("path").attr("style", C.join(";").replace("fill", "stroke"));
203
- } else I = E.insert("rect", ":first-child"), I.attr("style", y).attr("rx", u.rx).attr("ry", u.ry).attr("x", P).attr("y", F).attr("width", M).attr("height", N);
204
- let { subGraphTitleTopMargin: L } = getSubGraphTitleMargins(d);
205
- if (O.attr("transform", `translate(${u.x - j.width / 2}, ${u.y - u.height / 2 + L})`), v) {
206
- let e = O.select("span");
207
- e && e.attr("style", v);
208
- }
209
- let R = I.node().getBBox();
210
- return u.offsetX = 0, u.width = R.width, u.height = R.height, u.offsetY = j.height - u.padding / 2, u.intersect = function(e) {
211
- return intersect_rect_default(u, e);
212
- }, {
213
- cluster: E,
214
- labelBBox: j
215
- };
216
- }, "rect"), shapes = {
217
- rect,
218
- squareRect: rect,
219
- roundedWithTitle: /* @__PURE__ */ __name(async (e, l) => {
220
- let u = getConfig2(), { themeVariables: d, handDrawnSeed: p } = u, { altBackground: h, compositeBackground: g, compositeTitleBackground: _, nodeBorder: v } = d, y = e.insert("g").attr("class", l.cssClasses).attr("id", l.id).attr("data-id", l.id).attr("data-look", l.look), x = y.insert("g", ":first-child"), S = y.insert("g").attr("class", "cluster-label"), C = y.append("rect"), w = S.node().appendChild(await createLabel_default(l.label, l.labelStyle, void 0, !0)), T = w.getBBox();
221
- if (evaluate(u.flowchart.htmlLabels)) {
222
- let e = w.children[0], l = select_default(w);
223
- T = e.getBoundingClientRect(), l.attr("width", T.width), l.attr("height", T.height);
224
- }
225
- let E = 0 * l.padding, D = E / 2, O = (l.width <= T.width + l.padding ? T.width + l.padding : l.width) + E;
226
- l.width <= T.width + l.padding ? l.diff = (O - l.width) / 2 - l.padding : l.diff = -l.padding;
227
- let k = l.height + E, A = l.height + E - T.height - 6, j = l.x - O / 2, M = l.y - k / 2;
228
- l.width = O;
229
- let N = l.y - l.height / 2 - D + T.height + 2, P;
230
- if (l.look === "handDrawn") {
231
- let e = l.cssClasses.includes("statediagram-cluster-alt"), u = at.svg(y), d = l.rx || l.ry ? u.path(createRoundedRectPathD(j, M, O, k, 10), {
232
- roughness: .7,
233
- fill: _,
234
- fillStyle: "solid",
235
- stroke: v,
236
- seed: p
237
- }) : u.rectangle(j, M, O, k, { seed: p });
238
- P = y.insert(() => d, ":first-child");
239
- let f = u.rectangle(j, N, O, A, {
240
- fill: e ? h : g,
241
- fillStyle: e ? "hachure" : "solid",
242
- stroke: v,
243
- seed: p
244
- });
245
- P = y.insert(() => d, ":first-child"), C = y.insert(() => f);
246
- } else P = x.insert("rect", ":first-child"), P.attr("class", "outer").attr("x", j).attr("y", M).attr("width", O).attr("height", k).attr("data-look", l.look), C.attr("class", "inner").attr("x", j).attr("y", N).attr("width", O).attr("height", A);
247
- return S.attr("transform", `translate(${l.x - T.width / 2}, ${M + 1 - (evaluate(u.flowchart.htmlLabels) ? 0 : 3)})`), l.height = P.node().getBBox().height, l.offsetX = 0, l.offsetY = T.height - l.padding / 2, l.labelBBox = T, l.intersect = function(e) {
248
- return intersect_rect_default(l, e);
249
- }, {
250
- cluster: y,
251
- labelBBox: T
252
- };
253
- }, "roundedWithTitle"),
254
- noteGroup: /* @__PURE__ */ __name((e, l) => {
255
- let u = e.insert("g").attr("class", "note-cluster").attr("id", l.id), d = u.insert("rect", ":first-child"), f = 0 * l.padding, p = f / 2;
256
- d.attr("rx", l.rx).attr("ry", l.ry).attr("x", l.x - l.width / 2 - p).attr("y", l.y - l.height / 2 - p).attr("width", l.width + f).attr("height", l.height + f).attr("fill", "none");
257
- let m = d.node().getBBox();
258
- return l.width = m.width, l.height = m.height, l.intersect = function(e) {
259
- return intersect_rect_default(l, e);
260
- }, {
261
- cluster: u,
262
- labelBBox: {
263
- width: 0,
264
- height: 0
265
- }
266
- };
267
- }, "noteGroup"),
268
- divider: /* @__PURE__ */ __name((e, l) => {
269
- let { themeVariables: u, handDrawnSeed: d } = getConfig2(), { nodeBorder: f } = u, p = e.insert("g").attr("class", l.cssClasses).attr("id", l.id).attr("data-look", l.look), h = p.insert("g", ":first-child"), g = 0 * l.padding, _ = l.width + g;
270
- l.diff = -l.padding;
271
- let v = l.height + g, y = l.x - _ / 2, b = l.y - v / 2;
272
- l.width = _;
273
- let x;
274
- if (l.look === "handDrawn") {
275
- let e = at.svg(p).rectangle(y, b, _, v, {
276
- fill: "lightgrey",
277
- roughness: .5,
278
- strokeLineDash: [5],
279
- stroke: f,
280
- seed: d
281
- });
282
- x = p.insert(() => e, ":first-child");
283
- } else x = h.insert("rect", ":first-child"), x.attr("class", "divider").attr("x", y).attr("y", b).attr("width", _).attr("height", v).attr("data-look", l.look);
284
- return l.height = x.node().getBBox().height, l.offsetX = 0, l.offsetY = 0, l.intersect = function(e) {
285
- return intersect_rect_default(l, e);
286
- }, {
287
- cluster: p,
288
- labelBBox: {}
289
- };
290
- }, "divider"),
291
- kanbanSection: /* @__PURE__ */ __name(async (e, u) => {
292
- log.info("Creating subgraph rect for ", u.id, u);
293
- let d = getConfig2(), { themeVariables: p, handDrawnSeed: h } = d, { clusterBkg: g, clusterBorder: _ } = p, { labelStyles: v, nodeStyles: y, borderStyles: S, backgroundStyles: C } = styles2String(u), E = e.insert("g").attr("class", "cluster " + u.cssClasses).attr("id", u.id).attr("data-look", u.look), D = evaluate(d.flowchart.htmlLabels), O = E.insert("g").attr("class", "cluster-label "), k = await createText(O, u.label, {
294
- style: u.labelStyle,
295
- useHtmlLabels: D,
296
- isNode: !0,
297
- width: u.width
298
- }), j = k.getBBox();
299
- if (evaluate(d.flowchart.htmlLabels)) {
300
- let e = k.children[0], l = select_default(k);
301
- j = e.getBoundingClientRect(), l.attr("width", j.width), l.attr("height", j.height);
302
- }
303
- let M = u.width <= j.width + u.padding ? j.width + u.padding : u.width;
304
- u.width <= j.width + u.padding ? u.diff = (M - u.width) / 2 - u.padding : u.diff = -u.padding;
305
- let N = u.height, P = u.x - M / 2, F = u.y - N / 2;
306
- log.trace("Data ", u, JSON.stringify(u));
307
- let I;
308
- if (u.look === "handDrawn") {
309
- let e = at.svg(E), d = userNodeOverrides(u, {
310
- roughness: .7,
311
- fill: g,
312
- stroke: _,
313
- fillWeight: 4,
314
- seed: h
315
- }), f = e.path(createRoundedRectPathD(P, F, M, N, u.rx), d);
316
- I = E.insert(() => (log.debug("Rough node insert CXC", f), f), ":first-child"), I.select("path:nth-child(2)").attr("style", S.join(";")), I.select("path").attr("style", C.join(";").replace("fill", "stroke"));
317
- } else I = E.insert("rect", ":first-child"), I.attr("style", y).attr("rx", u.rx).attr("ry", u.ry).attr("x", P).attr("y", F).attr("width", M).attr("height", N);
318
- let { subGraphTitleTopMargin: L } = getSubGraphTitleMargins(d);
319
- if (O.attr("transform", `translate(${u.x - j.width / 2}, ${u.y - u.height / 2 + L})`), v) {
320
- let e = O.select("span");
321
- e && e.attr("style", v);
322
- }
323
- let R = I.node().getBBox();
324
- return u.offsetX = 0, u.width = R.width, u.height = R.height, u.offsetY = j.height - u.padding / 2, u.intersect = function(e) {
325
- return intersect_rect_default(u, e);
326
- }, {
327
- cluster: E,
328
- labelBBox: j
329
- };
330
- }, "kanbanSection")
331
- }, clusterElems = /* @__PURE__ */ new Map(), insertCluster = /* @__PURE__ */ __name(async (e, l) => {
332
- let u = await shapes[l.shape || "rect"](e, l);
333
- return clusterElems.set(l.id, u), u;
334
- }, "insertCluster"), clear = /* @__PURE__ */ __name(() => {
335
- clusterElems = /* @__PURE__ */ new Map();
336
- }, "clear");
337
- function intersectNode(e, l) {
338
- return e.intersect(l);
339
- }
340
- __name(intersectNode, "intersectNode");
341
- var intersect_node_default = intersectNode;
342
- function intersectEllipse(e, l, u, d) {
343
- var f = e.x, p = e.y, m = f - d.x, h = p - d.y, g = Math.sqrt(l * l * h * h + u * u * m * m), _ = Math.abs(l * u * m / g);
344
- d.x < f && (_ = -_);
345
- var v = Math.abs(l * u * h / g);
346
- return d.y < p && (v = -v), {
347
- x: f + _,
348
- y: p + v
349
- };
350
- }
351
- __name(intersectEllipse, "intersectEllipse");
352
- var intersect_ellipse_default = intersectEllipse;
353
- function intersectCircle(e, l, u) {
354
- return intersect_ellipse_default(e, l, l, u);
355
- }
356
- __name(intersectCircle, "intersectCircle");
357
- var intersect_circle_default = intersectCircle;
358
- function intersectLine(e, l, u, d) {
359
- {
360
- let f = l.y - e.y, p = e.x - l.x, m = l.x * e.y - e.x * l.y, h = f * u.x + p * u.y + m, g = f * d.x + p * d.y + m, _ = 1e-6;
361
- if (h !== 0 && g !== 0 && sameSign(h, g)) return;
362
- let v = d.y - u.y, y = u.x - d.x, b = d.x * u.y - u.x * d.y, x = v * e.x + y * e.y + b, S = v * l.x + y * l.y + b;
363
- if (Math.abs(x) < _ && Math.abs(S) < _ && sameSign(x, S)) return;
364
- let C = f * y - v * p;
365
- if (C === 0) return;
366
- let w = Math.abs(C / 2), T = p * b - y * m, E = T < 0 ? (T - w) / C : (T + w) / C;
367
- return T = v * m - f * b, {
368
- x: E,
369
- y: T < 0 ? (T - w) / C : (T + w) / C
370
- };
371
- }
372
- }
373
- __name(intersectLine, "intersectLine");
374
- function sameSign(e, l) {
375
- return e * l > 0;
376
- }
377
- __name(sameSign, "sameSign");
378
- var intersect_line_default = intersectLine;
379
- function intersectPolygon(e, l, u) {
380
- let d = e.x, f = e.y, p = [], m = Infinity, h = Infinity;
381
- typeof l.forEach == "function" ? l.forEach(function(e) {
382
- m = Math.min(m, e.x), h = Math.min(h, e.y);
383
- }) : (m = Math.min(m, l.x), h = Math.min(h, l.y));
384
- let g = d - e.width / 2 - m, _ = f - e.height / 2 - h;
385
- for (let d = 0; d < l.length; d++) {
386
- let f = l[d], m = l[d < l.length - 1 ? d + 1 : 0], h = intersect_line_default(e, u, {
387
- x: g + f.x,
388
- y: _ + f.y
389
- }, {
390
- x: g + m.x,
391
- y: _ + m.y
392
- });
393
- h && p.push(h);
394
- }
395
- return p.length ? (p.length > 1 && p.sort(function(e, l) {
396
- let d = e.x - u.x, f = e.y - u.y, p = Math.sqrt(d * d + f * f), m = l.x - u.x, h = l.y - u.y, g = Math.sqrt(m * m + h * h);
397
- return p < g ? -1 : p === g ? 0 : 1;
398
- }), p[0]) : e;
399
- }
400
- __name(intersectPolygon, "intersectPolygon");
401
- var intersect_default = {
402
- node: intersect_node_default,
403
- circle: intersect_circle_default,
404
- ellipse: intersect_ellipse_default,
405
- polygon: intersectPolygon,
406
- rect: intersect_rect_default
407
- };
408
- function anchor(e, u) {
409
- let { labelStyles: d } = styles2String(u);
410
- u.labelStyle = d;
411
- let f = getNodeClasses(u), p = f;
412
- f || (p = "anchor");
413
- let m = e.insert("g").attr("class", p).attr("id", u.domId || u.id), { cssStyles: h } = u, g = at.svg(m), _ = userNodeOverrides(u, {
414
- fill: "black",
415
- stroke: "none",
416
- fillStyle: "solid"
417
- });
418
- u.look !== "handDrawn" && (_.roughness = 0);
419
- let v = g.circle(0, 0, 2, _), y = m.insert(() => v, ":first-child");
420
- return y.attr("class", "anchor").attr("style", handleUndefinedAttr(h)), updateNodeBounds(u, y), u.intersect = function(e) {
421
- return log.info("Circle intersect", u, 1, e), intersect_default.circle(u, 1, e);
422
- }, m;
423
- }
424
- __name(anchor, "anchor");
425
- function generateArcPoints(e, l, u, d, f, p, m) {
426
- let h = (e + u) / 2, g = (l + d) / 2, _ = Math.atan2(d - l, u - e), v = (u - e) / 2, y = (d - l) / 2, b = v / f, x = y / p, S = Math.sqrt(b ** 2 + x ** 2);
427
- if (S > 1) throw Error("The given radii are too small to create an arc between the points.");
428
- let C = Math.sqrt(1 - S ** 2), w = h + C * p * Math.sin(_) * (m ? -1 : 1), T = g - C * f * Math.cos(_) * (m ? -1 : 1), E = Math.atan2((l - T) / p, (e - w) / f), D = Math.atan2((d - T) / p, (u - w) / f) - E;
429
- m && D < 0 && (D += 2 * Math.PI), !m && D > 0 && (D -= 2 * Math.PI);
430
- let O = [];
431
- for (let e = 0; e < 20; e++) {
432
- let l = E + e / 19 * D, u = w + f * Math.cos(l), d = T + p * Math.sin(l);
433
- O.push({
434
- x: u,
435
- y: d
436
- });
437
- }
438
- return O;
439
- }
440
- __name(generateArcPoints, "generateArcPoints");
441
- async function bowTieRect(e, l) {
442
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
443
- l.labelStyle = u;
444
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.width + l.padding + 20, h = p.height + l.padding, g = h / 2, _ = g / (2.5 + h / 50), { cssStyles: v } = l, y = [
445
- {
446
- x: m / 2,
447
- y: -h / 2
448
- },
449
- {
450
- x: -m / 2,
451
- y: -h / 2
452
- },
453
- ...generateArcPoints(-m / 2, -h / 2, -m / 2, h / 2, _, g, !1),
454
- {
455
- x: m / 2,
456
- y: h / 2
457
- },
458
- ...generateArcPoints(m / 2, h / 2, m / 2, -h / 2, _, g, !0)
459
- ], b = at.svg(f), x = userNodeOverrides(l, {});
460
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
461
- let S = createPathFromPoints(y), C = b.path(S, x), E = f.insert(() => C, ":first-child");
462
- return E.attr("class", "basic label-container"), v && l.look !== "handDrawn" && E.selectAll("path").attr("style", v), d && l.look !== "handDrawn" && E.selectAll("path").attr("style", d), E.attr("transform", `translate(${_ / 2}, 0)`), updateNodeBounds(l, E), l.intersect = function(e) {
463
- return intersect_default.polygon(l, y, e);
464
- }, f;
465
- }
466
- __name(bowTieRect, "bowTieRect");
467
- function insertPolygonShape(e, l, u, d) {
468
- return e.insert("polygon", ":first-child").attr("points", d.map(function(e) {
469
- return e.x + "," + e.y;
470
- }).join(" ")).attr("class", "label-container").attr("transform", "translate(" + -l / 2 + "," + u / 2 + ")");
471
- }
472
- __name(insertPolygonShape, "insertPolygonShape");
473
- async function card(e, l) {
474
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
475
- l.labelStyle = u;
476
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.height + l.padding, h = p.width + l.padding + 12, g = h, _ = -m, v = [
477
- {
478
- x: 12,
479
- y: _
480
- },
481
- {
482
- x: g,
483
- y: _
484
- },
485
- {
486
- x: g,
487
- y: 0
488
- },
489
- {
490
- x: 0,
491
- y: 0
492
- },
493
- {
494
- x: 0,
495
- y: _ + 12
496
- },
497
- {
498
- x: 12,
499
- y: _
500
- }
501
- ], y, { cssStyles: b } = l;
502
- if (l.look === "handDrawn") {
503
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createPathFromPoints(v), p = e.path(d, u);
504
- y = f.insert(() => p, ":first-child").attr("transform", `translate(${-h / 2}, ${m / 2})`), b && y.attr("style", b);
505
- } else y = insertPolygonShape(f, h, m, v);
506
- return d && y.attr("style", d), updateNodeBounds(l, y), l.intersect = function(e) {
507
- return intersect_default.polygon(l, v, e);
508
- }, f;
509
- }
510
- __name(card, "card");
511
- function choice(e, l) {
512
- let { nodeStyles: u } = styles2String(l);
513
- l.label = "";
514
- let d = e.insert("g").attr("class", getNodeClasses(l)).attr("id", l.domId ?? l.id), { cssStyles: f } = l, p = Math.max(28, l.width ?? 0), m = [
515
- {
516
- x: 0,
517
- y: p / 2
518
- },
519
- {
520
- x: p / 2,
521
- y: 0
522
- },
523
- {
524
- x: 0,
525
- y: -p / 2
526
- },
527
- {
528
- x: -p / 2,
529
- y: 0
530
- }
531
- ], h = at.svg(d), g = userNodeOverrides(l, {});
532
- l.look !== "handDrawn" && (g.roughness = 0, g.fillStyle = "solid");
533
- let _ = createPathFromPoints(m), v = h.path(_, g), y = d.insert(() => v, ":first-child");
534
- return f && l.look !== "handDrawn" && y.selectAll("path").attr("style", f), u && l.look !== "handDrawn" && y.selectAll("path").attr("style", u), l.width = 28, l.height = 28, l.intersect = function(e) {
535
- return intersect_default.polygon(l, m, e);
536
- }, d;
537
- }
538
- __name(choice, "choice");
539
- async function circle(e, u, d) {
540
- let { labelStyles: f, nodeStyles: p } = styles2String(u);
541
- u.labelStyle = f;
542
- let { shapeSvg: m, bbox: h, halfPadding: g } = await labelHelper(e, u, getNodeClasses(u)), _ = d?.padding ?? g, v = h.width / 2 + _, y, { cssStyles: b } = u;
543
- if (u.look === "handDrawn") {
544
- let e = at.svg(m), l = userNodeOverrides(u, {}), d = e.circle(0, 0, v * 2, l);
545
- y = m.insert(() => d, ":first-child"), y.attr("class", "basic label-container").attr("style", handleUndefinedAttr(b));
546
- } else y = m.insert("circle", ":first-child").attr("class", "basic label-container").attr("style", p).attr("r", v).attr("cx", 0).attr("cy", 0);
547
- return updateNodeBounds(u, y), u.calcIntersect = function(e, l) {
548
- let u = e.width / 2;
549
- return intersect_default.circle(e, u, l);
550
- }, u.intersect = function(e) {
551
- return log.info("Circle intersect", u, v, e), intersect_default.circle(u, v, e);
552
- }, m;
553
- }
554
- __name(circle, "circle");
555
- function createLine(e) {
556
- let l = Math.cos(Math.PI / 4), u = Math.sin(Math.PI / 4), d = e * 2, f = {
557
- x: d / 2 * l,
558
- y: d / 2 * u
559
- }, p = {
560
- x: -(d / 2) * l,
561
- y: d / 2 * u
562
- }, m = {
563
- x: -(d / 2) * l,
564
- y: -(d / 2) * u
565
- }, h = {
566
- x: d / 2 * l,
567
- y: -(d / 2) * u
568
- };
569
- return `M ${p.x},${p.y} L ${h.x},${h.y}
570
- M ${f.x},${f.y} L ${m.x},${m.y}`;
571
- }
572
- __name(createLine, "createLine");
573
- function crossedCircle(e, u) {
574
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
575
- u.labelStyle = d, u.label = "";
576
- let p = e.insert("g").attr("class", getNodeClasses(u)).attr("id", u.domId ?? u.id), m = Math.max(30, u?.width ?? 0), { cssStyles: h } = u, g = at.svg(p), _ = userNodeOverrides(u, {});
577
- u.look !== "handDrawn" && (_.roughness = 0, _.fillStyle = "solid");
578
- let v = g.circle(0, 0, m * 2, _), y = createLine(m), b = g.path(y, _), x = p.insert(() => v, ":first-child");
579
- return x.insert(() => b), h && u.look !== "handDrawn" && x.selectAll("path").attr("style", h), f && u.look !== "handDrawn" && x.selectAll("path").attr("style", f), updateNodeBounds(u, x), u.intersect = function(e) {
580
- return log.info("crossedCircle intersect", u, {
581
- radius: m,
582
- point: e
583
- }), intersect_default.circle(u, m, e);
584
- }, p;
585
- }
586
- __name(crossedCircle, "crossedCircle");
587
- function generateCirclePoints2(e, l, u, d = 100, f = 0, p = 180) {
588
- let m = [], h = f * Math.PI / 180, g = (p * Math.PI / 180 - h) / (d - 1);
589
- for (let f = 0; f < d; f++) {
590
- let d = h + f * g, p = e + u * Math.cos(d), _ = l + u * Math.sin(d);
591
- m.push({
592
- x: -p,
593
- y: -_
594
- });
595
- }
596
- return m;
597
- }
598
- __name(generateCirclePoints2, "generateCirclePoints");
599
- async function curlyBraceLeft(e, l) {
600
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
601
- l.labelStyle = u;
602
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = p.width + (l.padding ?? 0), g = p.height + (l.padding ?? 0), _ = Math.max(5, g * .1), { cssStyles: v } = l, y = [
603
- ...generateCirclePoints2(h / 2, -g / 2, _, 30, -90, 0),
604
- {
605
- x: -h / 2 - _,
606
- y: _
607
- },
608
- ...generateCirclePoints2(h / 2 + _ * 2, -_, _, 20, -180, -270),
609
- ...generateCirclePoints2(h / 2 + _ * 2, _, _, 20, -90, -180),
610
- {
611
- x: -h / 2 - _,
612
- y: -g / 2
613
- },
614
- ...generateCirclePoints2(h / 2, g / 2, _, 20, 0, 90)
615
- ], b = [
616
- {
617
- x: h / 2,
618
- y: -g / 2 - _
619
- },
620
- {
621
- x: -h / 2,
622
- y: -g / 2 - _
623
- },
624
- ...generateCirclePoints2(h / 2, -g / 2, _, 20, -90, 0),
625
- {
626
- x: -h / 2 - _,
627
- y: -_
628
- },
629
- ...generateCirclePoints2(h / 2 + h * .1, -_, _, 20, -180, -270),
630
- ...generateCirclePoints2(h / 2 + h * .1, _, _, 20, -90, -180),
631
- {
632
- x: -h / 2 - _,
633
- y: g / 2
634
- },
635
- ...generateCirclePoints2(h / 2, g / 2, _, 20, 0, 90),
636
- {
637
- x: -h / 2,
638
- y: g / 2 + _
639
- },
640
- {
641
- x: h / 2,
642
- y: g / 2 + _
643
- }
644
- ], x = at.svg(f), S = userNodeOverrides(l, { fill: "none" });
645
- l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
646
- let C = createPathFromPoints(y).replace("Z", ""), E = x.path(C, S), D = createPathFromPoints(b), O = x.path(D, { ...S }), k = f.insert("g", ":first-child");
647
- return k.insert(() => O, ":first-child").attr("stroke-opacity", 0), k.insert(() => E, ":first-child"), k.attr("class", "text"), v && l.look !== "handDrawn" && k.selectAll("path").attr("style", v), d && l.look !== "handDrawn" && k.selectAll("path").attr("style", d), k.attr("transform", `translate(${_}, 0)`), m.attr("transform", `translate(${-h / 2 + _ - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, k), l.intersect = function(e) {
648
- return intersect_default.polygon(l, b, e);
649
- }, f;
650
- }
651
- __name(curlyBraceLeft, "curlyBraceLeft");
652
- function generateCirclePoints3(e, l, u, d = 100, f = 0, p = 180) {
653
- let m = [], h = f * Math.PI / 180, g = (p * Math.PI / 180 - h) / (d - 1);
654
- for (let f = 0; f < d; f++) {
655
- let d = h + f * g, p = e + u * Math.cos(d), _ = l + u * Math.sin(d);
656
- m.push({
657
- x: p,
658
- y: _
659
- });
660
- }
661
- return m;
662
- }
663
- __name(generateCirclePoints3, "generateCirclePoints");
664
- async function curlyBraceRight(e, l) {
665
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
666
- l.labelStyle = u;
667
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = p.width + (l.padding ?? 0), g = p.height + (l.padding ?? 0), _ = Math.max(5, g * .1), { cssStyles: v } = l, y = [
668
- ...generateCirclePoints3(h / 2, -g / 2, _, 20, -90, 0),
669
- {
670
- x: h / 2 + _,
671
- y: -_
672
- },
673
- ...generateCirclePoints3(h / 2 + _ * 2, -_, _, 20, -180, -270),
674
- ...generateCirclePoints3(h / 2 + _ * 2, _, _, 20, -90, -180),
675
- {
676
- x: h / 2 + _,
677
- y: g / 2
678
- },
679
- ...generateCirclePoints3(h / 2, g / 2, _, 20, 0, 90)
680
- ], b = [
681
- {
682
- x: -h / 2,
683
- y: -g / 2 - _
684
- },
685
- {
686
- x: h / 2,
687
- y: -g / 2 - _
688
- },
689
- ...generateCirclePoints3(h / 2, -g / 2, _, 20, -90, 0),
690
- {
691
- x: h / 2 + _,
692
- y: -_
693
- },
694
- ...generateCirclePoints3(h / 2 + _ * 2, -_, _, 20, -180, -270),
695
- ...generateCirclePoints3(h / 2 + _ * 2, _, _, 20, -90, -180),
696
- {
697
- x: h / 2 + _,
698
- y: g / 2
699
- },
700
- ...generateCirclePoints3(h / 2, g / 2, _, 20, 0, 90),
701
- {
702
- x: h / 2,
703
- y: g / 2 + _
704
- },
705
- {
706
- x: -h / 2,
707
- y: g / 2 + _
708
- }
709
- ], x = at.svg(f), S = userNodeOverrides(l, { fill: "none" });
710
- l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
711
- let C = createPathFromPoints(y).replace("Z", ""), E = x.path(C, S), D = createPathFromPoints(b), O = x.path(D, { ...S }), k = f.insert("g", ":first-child");
712
- return k.insert(() => O, ":first-child").attr("stroke-opacity", 0), k.insert(() => E, ":first-child"), k.attr("class", "text"), v && l.look !== "handDrawn" && k.selectAll("path").attr("style", v), d && l.look !== "handDrawn" && k.selectAll("path").attr("style", d), k.attr("transform", `translate(${-_}, 0)`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) / 2 - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, k), l.intersect = function(e) {
713
- return intersect_default.polygon(l, b, e);
714
- }, f;
715
- }
716
- __name(curlyBraceRight, "curlyBraceRight");
717
- function generateCirclePoints4(e, l, u, d = 100, f = 0, p = 180) {
718
- let m = [], h = f * Math.PI / 180, g = (p * Math.PI / 180 - h) / (d - 1);
719
- for (let f = 0; f < d; f++) {
720
- let d = h + f * g, p = e + u * Math.cos(d), _ = l + u * Math.sin(d);
721
- m.push({
722
- x: -p,
723
- y: -_
724
- });
725
- }
726
- return m;
727
- }
728
- __name(generateCirclePoints4, "generateCirclePoints");
729
- async function curlyBraces(e, l) {
730
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
731
- l.labelStyle = u;
732
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = p.width + (l.padding ?? 0), g = p.height + (l.padding ?? 0), _ = Math.max(5, g * .1), { cssStyles: v } = l, y = [
733
- ...generateCirclePoints4(h / 2, -g / 2, _, 30, -90, 0),
734
- {
735
- x: -h / 2 - _,
736
- y: _
737
- },
738
- ...generateCirclePoints4(h / 2 + _ * 2, -_, _, 20, -180, -270),
739
- ...generateCirclePoints4(h / 2 + _ * 2, _, _, 20, -90, -180),
740
- {
741
- x: -h / 2 - _,
742
- y: -g / 2
743
- },
744
- ...generateCirclePoints4(h / 2, g / 2, _, 20, 0, 90)
745
- ], b = [
746
- ...generateCirclePoints4(-h / 2 + _ + _ / 2, -g / 2, _, 20, -90, -180),
747
- {
748
- x: h / 2 - _ / 2,
749
- y: _
750
- },
751
- ...generateCirclePoints4(-h / 2 - _ / 2, -_, _, 20, 0, 90),
752
- ...generateCirclePoints4(-h / 2 - _ / 2, _, _, 20, -90, 0),
753
- {
754
- x: h / 2 - _ / 2,
755
- y: -_
756
- },
757
- ...generateCirclePoints4(-h / 2 + _ + _ / 2, g / 2, _, 30, -180, -270)
758
- ], x = [
759
- {
760
- x: h / 2,
761
- y: -g / 2 - _
762
- },
763
- {
764
- x: -h / 2,
765
- y: -g / 2 - _
766
- },
767
- ...generateCirclePoints4(h / 2, -g / 2, _, 20, -90, 0),
768
- {
769
- x: -h / 2 - _,
770
- y: -_
771
- },
772
- ...generateCirclePoints4(h / 2 + _ * 2, -_, _, 20, -180, -270),
773
- ...generateCirclePoints4(h / 2 + _ * 2, _, _, 20, -90, -180),
774
- {
775
- x: -h / 2 - _,
776
- y: g / 2
777
- },
778
- ...generateCirclePoints4(h / 2, g / 2, _, 20, 0, 90),
779
- {
780
- x: -h / 2,
781
- y: g / 2 + _
782
- },
783
- {
784
- x: h / 2 - _ - _ / 2,
785
- y: g / 2 + _
786
- },
787
- ...generateCirclePoints4(-h / 2 + _ + _ / 2, -g / 2, _, 20, -90, -180),
788
- {
789
- x: h / 2 - _ / 2,
790
- y: _
791
- },
792
- ...generateCirclePoints4(-h / 2 - _ / 2, -_, _, 20, 0, 90),
793
- ...generateCirclePoints4(-h / 2 - _ / 2, _, _, 20, -90, 0),
794
- {
795
- x: h / 2 - _ / 2,
796
- y: -_
797
- },
798
- ...generateCirclePoints4(-h / 2 + _ + _ / 2, g / 2, _, 30, -180, -270)
799
- ], S = at.svg(f), C = userNodeOverrides(l, { fill: "none" });
800
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
801
- let E = createPathFromPoints(y).replace("Z", ""), D = S.path(E, C), O = createPathFromPoints(b).replace("Z", ""), k = S.path(O, C), A = createPathFromPoints(x), j = S.path(A, { ...C }), N = f.insert("g", ":first-child");
802
- return N.insert(() => j, ":first-child").attr("stroke-opacity", 0), N.insert(() => D, ":first-child"), N.insert(() => k, ":first-child"), N.attr("class", "text"), v && l.look !== "handDrawn" && N.selectAll("path").attr("style", v), d && l.look !== "handDrawn" && N.selectAll("path").attr("style", d), N.attr("transform", `translate(${_ - _ / 4}, 0)`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) / 2 - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, N), l.intersect = function(e) {
803
- return intersect_default.polygon(l, x, e);
804
- }, f;
805
- }
806
- __name(curlyBraces, "curlyBraces");
807
- async function curvedTrapezoid(e, l) {
808
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
809
- l.labelStyle = u;
810
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(80, (p.width + (l.padding ?? 0) * 2) * 1.25, l?.width ?? 0), h = Math.max(20, p.height + (l.padding ?? 0) * 2, l?.height ?? 0), g = h / 2, { cssStyles: _ } = l, v = at.svg(f), y = userNodeOverrides(l, {});
811
- l.look !== "handDrawn" && (y.roughness = 0, y.fillStyle = "solid");
812
- let b = m, x = h, S = b - g, C = x / 4, E = [
813
- {
814
- x: S,
815
- y: 0
816
- },
817
- {
818
- x: C,
819
- y: 0
820
- },
821
- {
822
- x: 0,
823
- y: x / 2
824
- },
825
- {
826
- x: C,
827
- y: x
828
- },
829
- {
830
- x: S,
831
- y: x
832
- },
833
- ...generateCirclePoints(-S, -x / 2, g, 50, 270, 90)
834
- ], D = createPathFromPoints(E), O = v.path(D, y), k = f.insert(() => O, ":first-child");
835
- return k.attr("class", "basic label-container"), _ && l.look !== "handDrawn" && k.selectChildren("path").attr("style", _), d && l.look !== "handDrawn" && k.selectChildren("path").attr("style", d), k.attr("transform", `translate(${-m / 2}, ${-h / 2})`), updateNodeBounds(l, k), l.intersect = function(e) {
836
- return intersect_default.polygon(l, E, e);
837
- }, f;
838
- }
839
- __name(curvedTrapezoid, "curvedTrapezoid");
840
- var createCylinderPathD = /* @__PURE__ */ __name((e, l, u, d, f, p) => [
841
- `M${e},${l + p}`,
842
- `a${f},${p} 0,0,0 ${u},0`,
843
- `a${f},${p} 0,0,0 ${-u},0`,
844
- `l0,${d}`,
845
- `a${f},${p} 0,0,0 ${u},0`,
846
- `l0,${-d}`
847
- ].join(" "), "createCylinderPathD"), createOuterCylinderPathD = /* @__PURE__ */ __name((e, l, u, d, f, p) => [
848
- `M${e},${l + p}`,
849
- `M${e + u},${l + p}`,
850
- `a${f},${p} 0,0,0 ${-u},0`,
851
- `l0,${d}`,
852
- `a${f},${p} 0,0,0 ${u},0`,
853
- `l0,${-d}`
854
- ].join(" "), "createOuterCylinderPathD"), createInnerCylinderPathD = /* @__PURE__ */ __name((e, l, u, d, f, p) => [`M${e - u / 2},${-d / 2}`, `a${f},${p} 0,0,0 ${u},0`].join(" "), "createInnerCylinderPathD");
855
- async function cylinder(e, l) {
856
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
857
- l.labelStyle = u;
858
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + l.padding, l.width ?? 0), g = h / 2, _ = g / (2.5 + h / 50), v = Math.max(p.height + _ + l.padding, l.height ?? 0), y, { cssStyles: b } = l;
859
- if (l.look === "handDrawn") {
860
- let e = at.svg(f), u = createOuterCylinderPathD(0, 0, h, v, g, _), d = createInnerCylinderPathD(0, _, h, v, g, _), p = e.path(u, userNodeOverrides(l, {})), m = e.path(d, userNodeOverrides(l, { fill: "none" }));
861
- y = f.insert(() => m, ":first-child"), y = f.insert(() => p, ":first-child"), y.attr("class", "basic label-container"), b && y.attr("style", b);
862
- } else {
863
- let e = createCylinderPathD(0, 0, h, v, g, _);
864
- y = f.insert("path", ":first-child").attr("d", e).attr("class", "basic label-container").attr("style", handleUndefinedAttr(b)).attr("style", d);
865
- }
866
- return y.attr("label-offset-y", _), y.attr("transform", `translate(${-h / 2}, ${-(v / 2 + _)})`), updateNodeBounds(l, y), m.attr("transform", `translate(${-(p.width / 2) - (p.x - (p.left ?? 0))}, ${-(p.height / 2) + (l.padding ?? 0) / 1.5 - (p.y - (p.top ?? 0))})`), l.intersect = function(e) {
867
- let u = intersect_default.rect(l, e), d = u.x - (l.x ?? 0);
868
- if (g != 0 && (Math.abs(d) < (l.width ?? 0) / 2 || Math.abs(d) == (l.width ?? 0) / 2 && Math.abs(u.y - (l.y ?? 0)) > (l.height ?? 0) / 2 - _)) {
869
- let f = _ * _ * (1 - d * d / (g * g));
870
- f > 0 && (f = Math.sqrt(f)), f = _ - f, e.y - (l.y ?? 0) > 0 && (f = -f), u.y += f;
871
- }
872
- return u;
873
- }, f;
874
- }
875
- __name(cylinder, "cylinder");
876
- async function dividedRectangle(e, l) {
877
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
878
- l.labelStyle = u;
879
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = p.width + l.padding, g = p.height + l.padding, _ = g * .2, v = -h / 2, y = -g / 2 - _ / 2, { cssStyles: b } = l, x = at.svg(f), S = userNodeOverrides(l, {});
880
- l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
881
- let C = [
882
- {
883
- x: v,
884
- y: y + _
885
- },
886
- {
887
- x: -v,
888
- y: y + _
889
- },
890
- {
891
- x: -v,
892
- y: -y
893
- },
894
- {
895
- x: v,
896
- y: -y
897
- },
898
- {
899
- x: v,
900
- y
901
- },
902
- {
903
- x: -v,
904
- y
905
- },
906
- {
907
- x: -v,
908
- y: y + _
909
- }
910
- ], E = x.polygon(C.map((e) => [e.x, e.y]), S), D = f.insert(() => E, ":first-child");
911
- return D.attr("class", "basic label-container"), b && l.look !== "handDrawn" && D.selectAll("path").attr("style", b), d && l.look !== "handDrawn" && D.selectAll("path").attr("style", d), m.attr("transform", `translate(${v + (l.padding ?? 0) / 2 - (p.x - (p.left ?? 0))}, ${y + _ + (l.padding ?? 0) / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, D), l.intersect = function(e) {
912
- return intersect_default.rect(l, e);
913
- }, f;
914
- }
915
- __name(dividedRectangle, "dividedRectangle");
916
- async function doublecircle(e, u) {
917
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
918
- u.labelStyle = d;
919
- let { shapeSvg: p, bbox: m, halfPadding: h } = await labelHelper(e, u, getNodeClasses(u)), g = m.width / 2 + h + 5, _ = m.width / 2 + h, v, { cssStyles: y } = u;
920
- if (u.look === "handDrawn") {
921
- let e = at.svg(p), l = userNodeOverrides(u, {
922
- roughness: .2,
923
- strokeWidth: 2.5
924
- }), d = userNodeOverrides(u, {
925
- roughness: .2,
926
- strokeWidth: 1.5
927
- }), f = e.circle(0, 0, g * 2, l), m = e.circle(0, 0, _ * 2, d);
928
- v = p.insert("g", ":first-child"), v.attr("class", handleUndefinedAttr(u.cssClasses)).attr("style", handleUndefinedAttr(y)), v.node()?.appendChild(f), v.node()?.appendChild(m);
929
- } else {
930
- v = p.insert("g", ":first-child");
931
- let e = v.insert("circle", ":first-child"), l = v.insert("circle");
932
- v.attr("class", "basic label-container").attr("style", f), e.attr("class", "outer-circle").attr("style", f).attr("r", g).attr("cx", 0).attr("cy", 0), l.attr("class", "inner-circle").attr("style", f).attr("r", _).attr("cx", 0).attr("cy", 0);
933
- }
934
- return updateNodeBounds(u, v), u.intersect = function(e) {
935
- return log.info("DoubleCircle intersect", u, g, e), intersect_default.circle(u, g, e);
936
- }, p;
937
- }
938
- __name(doublecircle, "doublecircle");
939
- function filledCircle(e, u, { config: { themeVariables: d } }) {
940
- let { labelStyles: f, nodeStyles: p } = styles2String(u);
941
- u.label = "", u.labelStyle = f;
942
- let m = e.insert("g").attr("class", getNodeClasses(u)).attr("id", u.domId ?? u.id), { cssStyles: h } = u, g = at.svg(m), { nodeBorder: _ } = d, v = userNodeOverrides(u, { fillStyle: "solid" });
943
- u.look !== "handDrawn" && (v.roughness = 0);
944
- let y = g.circle(0, 0, 14, v), b = m.insert(() => y, ":first-child");
945
- return b.selectAll("path").attr("style", `fill: ${_} !important;`), h && h.length > 0 && u.look !== "handDrawn" && b.selectAll("path").attr("style", h), p && u.look !== "handDrawn" && b.selectAll("path").attr("style", p), updateNodeBounds(u, b), u.intersect = function(e) {
946
- return log.info("filledCircle intersect", u, {
947
- radius: 7,
948
- point: e
949
- }), intersect_default.circle(u, 7, e);
950
- }, m;
951
- }
952
- __name(filledCircle, "filledCircle");
953
- async function flippedTriangle(e, u) {
954
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
955
- u.labelStyle = d;
956
- let { shapeSvg: p, bbox: m, label: h } = await labelHelper(e, u, getNodeClasses(u)), g = m.width + (u.padding ?? 0), _ = g + m.height, v = g + m.height, y = [
957
- {
958
- x: 0,
959
- y: -_
960
- },
961
- {
962
- x: v,
963
- y: -_
964
- },
965
- {
966
- x: v / 2,
967
- y: 0
968
- }
969
- ], { cssStyles: b } = u, x = at.svg(p), S = userNodeOverrides(u, {});
970
- u.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
971
- let C = createPathFromPoints(y), E = x.path(C, S), D = p.insert(() => E, ":first-child").attr("transform", `translate(${-_ / 2}, ${_ / 2})`);
972
- return b && u.look !== "handDrawn" && D.selectChildren("path").attr("style", b), f && u.look !== "handDrawn" && D.selectChildren("path").attr("style", f), u.width = g, u.height = _, updateNodeBounds(u, D), h.attr("transform", `translate(${-m.width / 2 - (m.x - (m.left ?? 0))}, ${-_ / 2 + (u.padding ?? 0) / 2 + (m.y - (m.top ?? 0))})`), u.intersect = function(e) {
973
- return log.info("Triangle intersect", u, y, e), intersect_default.polygon(u, y, e);
974
- }, p;
975
- }
976
- __name(flippedTriangle, "flippedTriangle");
977
- function forkJoin(e, l, { dir: u, config: { state: d, themeVariables: f } }) {
978
- let { nodeStyles: p } = styles2String(l);
979
- l.label = "";
980
- let m = e.insert("g").attr("class", getNodeClasses(l)).attr("id", l.domId ?? l.id), { cssStyles: h } = l, g = Math.max(70, l?.width ?? 0), _ = Math.max(10, l?.height ?? 0);
981
- u === "LR" && (g = Math.max(10, l?.width ?? 0), _ = Math.max(70, l?.height ?? 0));
982
- let v = -1 * g / 2, y = -1 * _ / 2, b = at.svg(m), x = userNodeOverrides(l, {
983
- stroke: f.lineColor,
984
- fill: f.lineColor
985
- });
986
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
987
- let S = b.rectangle(v, y, g, _, x), C = m.insert(() => S, ":first-child");
988
- h && l.look !== "handDrawn" && C.selectAll("path").attr("style", h), p && l.look !== "handDrawn" && C.selectAll("path").attr("style", p), updateNodeBounds(l, C);
989
- let E = d?.padding ?? 0;
990
- return l.width && l.height && (l.width += E / 2 || 0, l.height += E / 2 || 0), l.intersect = function(e) {
991
- return intersect_default.rect(l, e);
992
- }, m;
993
- }
994
- __name(forkJoin, "forkJoin");
995
- async function halfRoundedRectangle(e, u) {
996
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
997
- u.labelStyle = d;
998
- let { shapeSvg: p, bbox: m } = await labelHelper(e, u, getNodeClasses(u)), h = Math.max(80, m.width + (u.padding ?? 0) * 2, u?.width ?? 0), g = Math.max(50, m.height + (u.padding ?? 0) * 2, u?.height ?? 0), _ = g / 2, { cssStyles: v } = u, y = at.svg(p), b = userNodeOverrides(u, {});
999
- u.look !== "handDrawn" && (b.roughness = 0, b.fillStyle = "solid");
1000
- let x = [
1001
- {
1002
- x: -h / 2,
1003
- y: -g / 2
1004
- },
1005
- {
1006
- x: h / 2 - _,
1007
- y: -g / 2
1008
- },
1009
- ...generateCirclePoints(-h / 2 + _, 0, _, 50, 90, 270),
1010
- {
1011
- x: h / 2 - _,
1012
- y: g / 2
1013
- },
1014
- {
1015
- x: -h / 2,
1016
- y: g / 2
1017
- }
1018
- ], S = createPathFromPoints(x), C = y.path(S, b), E = p.insert(() => C, ":first-child");
1019
- return E.attr("class", "basic label-container"), v && u.look !== "handDrawn" && E.selectChildren("path").attr("style", v), f && u.look !== "handDrawn" && E.selectChildren("path").attr("style", f), updateNodeBounds(u, E), u.intersect = function(e) {
1020
- return log.info("Pill intersect", u, {
1021
- radius: _,
1022
- point: e
1023
- }), intersect_default.polygon(u, x, e);
1024
- }, p;
1025
- }
1026
- __name(halfRoundedRectangle, "halfRoundedRectangle");
1027
- async function hexagon(e, l) {
1028
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1029
- l.labelStyle = u;
1030
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.height + (l.padding ?? 0), h = p.width + (l.padding ?? 0) * 2.5, { cssStyles: g } = l, _ = at.svg(f), v = userNodeOverrides(l, {});
1031
- l.look !== "handDrawn" && (v.roughness = 0, v.fillStyle = "solid");
1032
- let y = h / 2, b = y / 6;
1033
- y += b;
1034
- let x = m / 2, S = x / 2, C = y - S, E = [
1035
- {
1036
- x: -C,
1037
- y: -x
1038
- },
1039
- {
1040
- x: 0,
1041
- y: -x
1042
- },
1043
- {
1044
- x: C,
1045
- y: -x
1046
- },
1047
- {
1048
- x: y,
1049
- y: 0
1050
- },
1051
- {
1052
- x: C,
1053
- y: x
1054
- },
1055
- {
1056
- x: 0,
1057
- y: x
1058
- },
1059
- {
1060
- x: -C,
1061
- y: x
1062
- },
1063
- {
1064
- x: -y,
1065
- y: 0
1066
- }
1067
- ], D = createPathFromPoints(E), O = _.path(D, v), k = f.insert(() => O, ":first-child");
1068
- return k.attr("class", "basic label-container"), g && l.look !== "handDrawn" && k.selectChildren("path").attr("style", g), d && l.look !== "handDrawn" && k.selectChildren("path").attr("style", d), l.width = h, l.height = m, updateNodeBounds(l, k), l.intersect = function(e) {
1069
- return intersect_default.polygon(l, E, e);
1070
- }, f;
1071
- }
1072
- __name(hexagon, "hexagon");
1073
- async function hourglass(e, u) {
1074
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
1075
- u.label = "", u.labelStyle = d;
1076
- let { shapeSvg: p } = await labelHelper(e, u, getNodeClasses(u)), m = Math.max(30, u?.width ?? 0), h = Math.max(30, u?.height ?? 0), { cssStyles: g } = u, _ = at.svg(p), v = userNodeOverrides(u, {});
1077
- u.look !== "handDrawn" && (v.roughness = 0, v.fillStyle = "solid");
1078
- let y = [
1079
- {
1080
- x: 0,
1081
- y: 0
1082
- },
1083
- {
1084
- x: m,
1085
- y: 0
1086
- },
1087
- {
1088
- x: 0,
1089
- y: h
1090
- },
1091
- {
1092
- x: m,
1093
- y: h
1094
- }
1095
- ], b = createPathFromPoints(y), x = _.path(b, v), S = p.insert(() => x, ":first-child");
1096
- return S.attr("class", "basic label-container"), g && u.look !== "handDrawn" && S.selectChildren("path").attr("style", g), f && u.look !== "handDrawn" && S.selectChildren("path").attr("style", f), S.attr("transform", `translate(${-m / 2}, ${-h / 2})`), updateNodeBounds(u, S), u.intersect = function(e) {
1097
- return log.info("Pill intersect", u, { points: y }), intersect_default.polygon(u, y, e);
1098
- }, p;
1099
- }
1100
- __name(hourglass, "hourglass");
1101
- async function icon(e, u, { config: { themeVariables: d, flowchart: f } }) {
1102
- let { labelStyles: p } = styles2String(u);
1103
- u.labelStyle = p;
1104
- let m = u.assetHeight ?? 48, h = u.assetWidth ?? 48, g = Math.max(m, h), _ = f?.wrappingWidth;
1105
- u.width = Math.max(g, _ ?? 0);
1106
- let { shapeSvg: v, bbox: y, label: b } = await labelHelper(e, u, "icon-shape default"), x = u.pos === "t", C = g, E = g, { nodeBorder: D } = d, { stylesMap: O } = compileStyles(u), k = -E / 2, A = -C / 2, N = u.label ? 8 : 0, F = at.svg(v), I = userNodeOverrides(u, {
1107
- stroke: "none",
1108
- fill: "none"
1109
- });
1110
- u.look !== "handDrawn" && (I.roughness = 0, I.fillStyle = "solid");
1111
- let L = F.rectangle(k, A, E, C, I), R = Math.max(E, y.width), z = C + y.height + N, B = F.rectangle(-R / 2, -z / 2, R, z, {
1112
- ...I,
1113
- fill: "transparent",
1114
- stroke: "none"
1115
- }), V = v.insert(() => L, ":first-child"), H = v.insert(() => B);
1116
- if (u.icon) {
1117
- let e = v.append("g");
1118
- e.html(`<g>${await getIconSVG(u.icon, {
1119
- height: g,
1120
- width: g,
1121
- fallbackPrefix: ""
1122
- })}</g>`);
1123
- let l = e.node().getBBox(), d = l.width, f = l.height, p = l.x, m = l.y;
1124
- e.attr("transform", `translate(${-d / 2 - p},${x ? y.height / 2 + N / 2 - f / 2 - m : -y.height / 2 - N / 2 - f / 2 - m})`), e.attr("style", `color: ${O.get("stroke") ?? D};`);
1125
- }
1126
- return b.attr("transform", `translate(${-y.width / 2 - (y.x - (y.left ?? 0))},${x ? -z / 2 : z / 2 - y.height})`), V.attr("transform", `translate(0,${x ? y.height / 2 + N / 2 : -y.height / 2 - N / 2})`), updateNodeBounds(u, H), u.intersect = function(e) {
1127
- if (log.info("iconSquare intersect", u, e), !u.label) return intersect_default.rect(u, e);
1128
- let d = u.x ?? 0, f = u.y ?? 0, p = u.height ?? 0, m = [];
1129
- return m = x ? [
1130
- {
1131
- x: d - y.width / 2,
1132
- y: f - p / 2
1133
- },
1134
- {
1135
- x: d + y.width / 2,
1136
- y: f - p / 2
1137
- },
1138
- {
1139
- x: d + y.width / 2,
1140
- y: f - p / 2 + y.height + N
1141
- },
1142
- {
1143
- x: d + E / 2,
1144
- y: f - p / 2 + y.height + N
1145
- },
1146
- {
1147
- x: d + E / 2,
1148
- y: f + p / 2
1149
- },
1150
- {
1151
- x: d - E / 2,
1152
- y: f + p / 2
1153
- },
1154
- {
1155
- x: d - E / 2,
1156
- y: f - p / 2 + y.height + N
1157
- },
1158
- {
1159
- x: d - y.width / 2,
1160
- y: f - p / 2 + y.height + N
1161
- }
1162
- ] : [
1163
- {
1164
- x: d - E / 2,
1165
- y: f - p / 2
1166
- },
1167
- {
1168
- x: d + E / 2,
1169
- y: f - p / 2
1170
- },
1171
- {
1172
- x: d + E / 2,
1173
- y: f - p / 2 + C
1174
- },
1175
- {
1176
- x: d + y.width / 2,
1177
- y: f - p / 2 + C
1178
- },
1179
- {
1180
- x: d + y.width / 2 / 2,
1181
- y: f + p / 2
1182
- },
1183
- {
1184
- x: d - y.width / 2,
1185
- y: f + p / 2
1186
- },
1187
- {
1188
- x: d - y.width / 2,
1189
- y: f - p / 2 + C
1190
- },
1191
- {
1192
- x: d - E / 2,
1193
- y: f - p / 2 + C
1194
- }
1195
- ], intersect_default.polygon(u, m, e);
1196
- }, v;
1197
- }
1198
- __name(icon, "icon");
1199
- async function iconCircle(e, u, { config: { themeVariables: d, flowchart: f } }) {
1200
- let { labelStyles: p } = styles2String(u);
1201
- u.labelStyle = p;
1202
- let m = u.assetHeight ?? 48, h = u.assetWidth ?? 48, g = Math.max(m, h), _ = f?.wrappingWidth;
1203
- u.width = Math.max(g, _ ?? 0);
1204
- let { shapeSvg: v, bbox: y, label: b } = await labelHelper(e, u, "icon-shape default"), x = u.label ? 8 : 0, C = u.pos === "t", { nodeBorder: E, mainBkg: D } = d, { stylesMap: O } = compileStyles(u), k = at.svg(v), A = userNodeOverrides(u, {});
1205
- u.look !== "handDrawn" && (A.roughness = 0, A.fillStyle = "solid"), A.stroke = O.get("fill") ?? D;
1206
- let N = v.append("g");
1207
- u.icon && N.html(`<g>${await getIconSVG(u.icon, {
1208
- height: g,
1209
- width: g,
1210
- fallbackPrefix: ""
1211
- })}</g>`);
1212
- let F = N.node().getBBox(), I = F.width, L = F.height, R = F.x, z = F.y, B = Math.max(I, L) * Math.SQRT2 + 40, V = k.circle(0, 0, B, A), H = Math.max(B, y.width), U = B + y.height + x, W = k.rectangle(-H / 2, -U / 2, H, U, {
1213
- ...A,
1214
- fill: "transparent",
1215
- stroke: "none"
1216
- }), G = v.insert(() => V, ":first-child"), K = v.insert(() => W);
1217
- return N.attr("transform", `translate(${-I / 2 - R},${C ? y.height / 2 + x / 2 - L / 2 - z : -y.height / 2 - x / 2 - L / 2 - z})`), N.attr("style", `color: ${O.get("stroke") ?? E};`), b.attr("transform", `translate(${-y.width / 2 - (y.x - (y.left ?? 0))},${C ? -U / 2 : U / 2 - y.height})`), G.attr("transform", `translate(0,${C ? y.height / 2 + x / 2 : -y.height / 2 - x / 2})`), updateNodeBounds(u, K), u.intersect = function(e) {
1218
- return log.info("iconSquare intersect", u, e), intersect_default.rect(u, e);
1219
- }, v;
1220
- }
1221
- __name(iconCircle, "iconCircle");
1222
- async function iconRounded(e, u, { config: { themeVariables: d, flowchart: f } }) {
1223
- let { labelStyles: p } = styles2String(u);
1224
- u.labelStyle = p;
1225
- let m = u.assetHeight ?? 48, h = u.assetWidth ?? 48, g = Math.max(m, h), _ = f?.wrappingWidth;
1226
- u.width = Math.max(g, _ ?? 0);
1227
- let { shapeSvg: v, bbox: y, halfPadding: b, label: x } = await labelHelper(e, u, "icon-shape default"), C = u.pos === "t", E = g + b * 2, D = g + b * 2, { nodeBorder: O, mainBkg: k } = d, { stylesMap: A } = compileStyles(u), N = -D / 2, F = -E / 2, I = u.label ? 8 : 0, L = at.svg(v), R = userNodeOverrides(u, {});
1228
- u.look !== "handDrawn" && (R.roughness = 0, R.fillStyle = "solid"), R.stroke = A.get("fill") ?? k;
1229
- let z = L.path(createRoundedRectPathD(N, F, D, E, 5), R), B = Math.max(D, y.width), V = E + y.height + I, H = L.rectangle(-B / 2, -V / 2, B, V, {
1230
- ...R,
1231
- fill: "transparent",
1232
- stroke: "none"
1233
- }), W = v.insert(() => z, ":first-child").attr("class", "icon-shape2"), G = v.insert(() => H);
1234
- if (u.icon) {
1235
- let e = v.append("g");
1236
- e.html(`<g>${await getIconSVG(u.icon, {
1237
- height: g,
1238
- width: g,
1239
- fallbackPrefix: ""
1240
- })}</g>`);
1241
- let l = e.node().getBBox(), d = l.width, f = l.height, p = l.x, m = l.y;
1242
- e.attr("transform", `translate(${-d / 2 - p},${C ? y.height / 2 + I / 2 - f / 2 - m : -y.height / 2 - I / 2 - f / 2 - m})`), e.attr("style", `color: ${A.get("stroke") ?? O};`);
1243
- }
1244
- return x.attr("transform", `translate(${-y.width / 2 - (y.x - (y.left ?? 0))},${C ? -V / 2 : V / 2 - y.height})`), W.attr("transform", `translate(0,${C ? y.height / 2 + I / 2 : -y.height / 2 - I / 2})`), updateNodeBounds(u, G), u.intersect = function(e) {
1245
- if (log.info("iconSquare intersect", u, e), !u.label) return intersect_default.rect(u, e);
1246
- let d = u.x ?? 0, f = u.y ?? 0, p = u.height ?? 0, m = [];
1247
- return m = C ? [
1248
- {
1249
- x: d - y.width / 2,
1250
- y: f - p / 2
1251
- },
1252
- {
1253
- x: d + y.width / 2,
1254
- y: f - p / 2
1255
- },
1256
- {
1257
- x: d + y.width / 2,
1258
- y: f - p / 2 + y.height + I
1259
- },
1260
- {
1261
- x: d + D / 2,
1262
- y: f - p / 2 + y.height + I
1263
- },
1264
- {
1265
- x: d + D / 2,
1266
- y: f + p / 2
1267
- },
1268
- {
1269
- x: d - D / 2,
1270
- y: f + p / 2
1271
- },
1272
- {
1273
- x: d - D / 2,
1274
- y: f - p / 2 + y.height + I
1275
- },
1276
- {
1277
- x: d - y.width / 2,
1278
- y: f - p / 2 + y.height + I
1279
- }
1280
- ] : [
1281
- {
1282
- x: d - D / 2,
1283
- y: f - p / 2
1284
- },
1285
- {
1286
- x: d + D / 2,
1287
- y: f - p / 2
1288
- },
1289
- {
1290
- x: d + D / 2,
1291
- y: f - p / 2 + E
1292
- },
1293
- {
1294
- x: d + y.width / 2,
1295
- y: f - p / 2 + E
1296
- },
1297
- {
1298
- x: d + y.width / 2 / 2,
1299
- y: f + p / 2
1300
- },
1301
- {
1302
- x: d - y.width / 2,
1303
- y: f + p / 2
1304
- },
1305
- {
1306
- x: d - y.width / 2,
1307
- y: f - p / 2 + E
1308
- },
1309
- {
1310
- x: d - D / 2,
1311
- y: f - p / 2 + E
1312
- }
1313
- ], intersect_default.polygon(u, m, e);
1314
- }, v;
1315
- }
1316
- __name(iconRounded, "iconRounded");
1317
- async function iconSquare(e, u, { config: { themeVariables: d, flowchart: f } }) {
1318
- let { labelStyles: p } = styles2String(u);
1319
- u.labelStyle = p;
1320
- let m = u.assetHeight ?? 48, h = u.assetWidth ?? 48, g = Math.max(m, h), _ = f?.wrappingWidth;
1321
- u.width = Math.max(g, _ ?? 0);
1322
- let { shapeSvg: v, bbox: y, halfPadding: b, label: x } = await labelHelper(e, u, "icon-shape default"), C = u.pos === "t", E = g + b * 2, D = g + b * 2, { nodeBorder: O, mainBkg: k } = d, { stylesMap: A } = compileStyles(u), N = -D / 2, F = -E / 2, I = u.label ? 8 : 0, L = at.svg(v), R = userNodeOverrides(u, {});
1323
- u.look !== "handDrawn" && (R.roughness = 0, R.fillStyle = "solid"), R.stroke = A.get("fill") ?? k;
1324
- let z = L.path(createRoundedRectPathD(N, F, D, E, .1), R), B = Math.max(D, y.width), V = E + y.height + I, H = L.rectangle(-B / 2, -V / 2, B, V, {
1325
- ...R,
1326
- fill: "transparent",
1327
- stroke: "none"
1328
- }), W = v.insert(() => z, ":first-child"), G = v.insert(() => H);
1329
- if (u.icon) {
1330
- let e = v.append("g");
1331
- e.html(`<g>${await getIconSVG(u.icon, {
1332
- height: g,
1333
- width: g,
1334
- fallbackPrefix: ""
1335
- })}</g>`);
1336
- let l = e.node().getBBox(), d = l.width, f = l.height, p = l.x, m = l.y;
1337
- e.attr("transform", `translate(${-d / 2 - p},${C ? y.height / 2 + I / 2 - f / 2 - m : -y.height / 2 - I / 2 - f / 2 - m})`), e.attr("style", `color: ${A.get("stroke") ?? O};`);
1338
- }
1339
- return x.attr("transform", `translate(${-y.width / 2 - (y.x - (y.left ?? 0))},${C ? -V / 2 : V / 2 - y.height})`), W.attr("transform", `translate(0,${C ? y.height / 2 + I / 2 : -y.height / 2 - I / 2})`), updateNodeBounds(u, G), u.intersect = function(e) {
1340
- if (log.info("iconSquare intersect", u, e), !u.label) return intersect_default.rect(u, e);
1341
- let d = u.x ?? 0, f = u.y ?? 0, p = u.height ?? 0, m = [];
1342
- return m = C ? [
1343
- {
1344
- x: d - y.width / 2,
1345
- y: f - p / 2
1346
- },
1347
- {
1348
- x: d + y.width / 2,
1349
- y: f - p / 2
1350
- },
1351
- {
1352
- x: d + y.width / 2,
1353
- y: f - p / 2 + y.height + I
1354
- },
1355
- {
1356
- x: d + D / 2,
1357
- y: f - p / 2 + y.height + I
1358
- },
1359
- {
1360
- x: d + D / 2,
1361
- y: f + p / 2
1362
- },
1363
- {
1364
- x: d - D / 2,
1365
- y: f + p / 2
1366
- },
1367
- {
1368
- x: d - D / 2,
1369
- y: f - p / 2 + y.height + I
1370
- },
1371
- {
1372
- x: d - y.width / 2,
1373
- y: f - p / 2 + y.height + I
1374
- }
1375
- ] : [
1376
- {
1377
- x: d - D / 2,
1378
- y: f - p / 2
1379
- },
1380
- {
1381
- x: d + D / 2,
1382
- y: f - p / 2
1383
- },
1384
- {
1385
- x: d + D / 2,
1386
- y: f - p / 2 + E
1387
- },
1388
- {
1389
- x: d + y.width / 2,
1390
- y: f - p / 2 + E
1391
- },
1392
- {
1393
- x: d + y.width / 2 / 2,
1394
- y: f + p / 2
1395
- },
1396
- {
1397
- x: d - y.width / 2,
1398
- y: f + p / 2
1399
- },
1400
- {
1401
- x: d - y.width / 2,
1402
- y: f - p / 2 + E
1403
- },
1404
- {
1405
- x: d - D / 2,
1406
- y: f - p / 2 + E
1407
- }
1408
- ], intersect_default.polygon(u, m, e);
1409
- }, v;
1410
- }
1411
- __name(iconSquare, "iconSquare");
1412
- async function imageSquare(e, u, { config: { flowchart: d } }) {
1413
- let f = new Image();
1414
- f.src = u?.img ?? "", await f.decode();
1415
- let p = Number(f.naturalWidth.toString().replace("px", "")), m = Number(f.naturalHeight.toString().replace("px", ""));
1416
- u.imageAspectRatio = p / m;
1417
- let { labelStyles: h } = styles2String(u);
1418
- u.labelStyle = h;
1419
- let g = d?.wrappingWidth;
1420
- u.defaultWidth = d?.wrappingWidth;
1421
- let _ = Math.max(u.label ? g ?? 0 : 0, u?.assetWidth ?? p), v = u.constraint === "on" && u?.assetHeight ? u.assetHeight * u.imageAspectRatio : _, y = u.constraint === "on" ? v / u.imageAspectRatio : u?.assetHeight ?? m;
1422
- u.width = Math.max(v, g ?? 0);
1423
- let { shapeSvg: b, bbox: x, label: S } = await labelHelper(e, u, "image-shape default"), C = u.pos === "t", E = -v / 2, D = -y / 2, O = u.label ? 8 : 0, k = at.svg(b), A = userNodeOverrides(u, {});
1424
- u.look !== "handDrawn" && (A.roughness = 0, A.fillStyle = "solid");
1425
- let j = k.rectangle(E, D, v, y, A), N = Math.max(v, x.width), F = y + x.height + O, I = k.rectangle(-N / 2, -F / 2, N, F, {
1426
- ...A,
1427
- fill: "none",
1428
- stroke: "none"
1429
- }), L = b.insert(() => j, ":first-child"), R = b.insert(() => I);
1430
- if (u.img) {
1431
- let e = b.append("image");
1432
- e.attr("href", u.img), e.attr("width", v), e.attr("height", y), e.attr("preserveAspectRatio", "none"), e.attr("transform", `translate(${-v / 2},${C ? F / 2 - y : -F / 2})`);
1433
- }
1434
- return S.attr("transform", `translate(${-x.width / 2 - (x.x - (x.left ?? 0))},${C ? -y / 2 - x.height / 2 - O / 2 : y / 2 - x.height / 2 + O / 2})`), L.attr("transform", `translate(0,${C ? x.height / 2 + O / 2 : -x.height / 2 - O / 2})`), updateNodeBounds(u, R), u.intersect = function(e) {
1435
- if (log.info("iconSquare intersect", u, e), !u.label) return intersect_default.rect(u, e);
1436
- let d = u.x ?? 0, f = u.y ?? 0, p = u.height ?? 0, m = [];
1437
- return m = C ? [
1438
- {
1439
- x: d - x.width / 2,
1440
- y: f - p / 2
1441
- },
1442
- {
1443
- x: d + x.width / 2,
1444
- y: f - p / 2
1445
- },
1446
- {
1447
- x: d + x.width / 2,
1448
- y: f - p / 2 + x.height + O
1449
- },
1450
- {
1451
- x: d + v / 2,
1452
- y: f - p / 2 + x.height + O
1453
- },
1454
- {
1455
- x: d + v / 2,
1456
- y: f + p / 2
1457
- },
1458
- {
1459
- x: d - v / 2,
1460
- y: f + p / 2
1461
- },
1462
- {
1463
- x: d - v / 2,
1464
- y: f - p / 2 + x.height + O
1465
- },
1466
- {
1467
- x: d - x.width / 2,
1468
- y: f - p / 2 + x.height + O
1469
- }
1470
- ] : [
1471
- {
1472
- x: d - v / 2,
1473
- y: f - p / 2
1474
- },
1475
- {
1476
- x: d + v / 2,
1477
- y: f - p / 2
1478
- },
1479
- {
1480
- x: d + v / 2,
1481
- y: f - p / 2 + y
1482
- },
1483
- {
1484
- x: d + x.width / 2,
1485
- y: f - p / 2 + y
1486
- },
1487
- {
1488
- x: d + x.width / 2 / 2,
1489
- y: f + p / 2
1490
- },
1491
- {
1492
- x: d - x.width / 2,
1493
- y: f + p / 2
1494
- },
1495
- {
1496
- x: d - x.width / 2,
1497
- y: f - p / 2 + y
1498
- },
1499
- {
1500
- x: d - v / 2,
1501
- y: f - p / 2 + y
1502
- }
1503
- ], intersect_default.polygon(u, m, e);
1504
- }, b;
1505
- }
1506
- __name(imageSquare, "imageSquare");
1507
- async function inv_trapezoid(e, l) {
1508
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1509
- l.labelStyle = u;
1510
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), h = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), g = [
1511
- {
1512
- x: 0,
1513
- y: 0
1514
- },
1515
- {
1516
- x: m,
1517
- y: 0
1518
- },
1519
- {
1520
- x: m + 3 * h / 6,
1521
- y: -h
1522
- },
1523
- {
1524
- x: -3 * h / 6,
1525
- y: -h
1526
- }
1527
- ], _, { cssStyles: v } = l;
1528
- if (l.look === "handDrawn") {
1529
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createPathFromPoints(g), p = e.path(d, u);
1530
- _ = f.insert(() => p, ":first-child").attr("transform", `translate(${-m / 2}, ${h / 2})`), v && _.attr("style", v);
1531
- } else _ = insertPolygonShape(f, m, h, g);
1532
- return d && _.attr("style", d), l.width = m, l.height = h, updateNodeBounds(l, _), l.intersect = function(e) {
1533
- return intersect_default.polygon(l, g, e);
1534
- }, f;
1535
- }
1536
- __name(inv_trapezoid, "inv_trapezoid");
1537
- async function drawRect(e, l, u) {
1538
- let { labelStyles: d, nodeStyles: f } = styles2String(l);
1539
- l.labelStyle = d;
1540
- let { shapeSvg: p, bbox: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(m.width + u.labelPaddingX * 2, l?.width || 0), g = Math.max(m.height + u.labelPaddingY * 2, l?.height || 0), _ = -h / 2, v = -g / 2, y, { rx: b, ry: x } = l, { cssStyles: S } = l;
1541
- if (u?.rx && u.ry && (b = u.rx, x = u.ry), l.look === "handDrawn") {
1542
- let e = at.svg(p), u = userNodeOverrides(l, {}), d = b || x ? e.path(createRoundedRectPathD(_, v, h, g, b || 0), u) : e.rectangle(_, v, h, g, u);
1543
- y = p.insert(() => d, ":first-child"), y.attr("class", "basic label-container").attr("style", handleUndefinedAttr(S));
1544
- } else y = p.insert("rect", ":first-child"), y.attr("class", "basic label-container").attr("style", f).attr("rx", handleUndefinedAttr(b)).attr("ry", handleUndefinedAttr(x)).attr("x", _).attr("y", v).attr("width", h).attr("height", g);
1545
- return updateNodeBounds(l, y), l.calcIntersect = function(e, l) {
1546
- return intersect_default.rect(e, l);
1547
- }, l.intersect = function(e) {
1548
- return intersect_default.rect(l, e);
1549
- }, p;
1550
- }
1551
- __name(drawRect, "drawRect");
1552
- async function labelRect(e, l) {
1553
- let { shapeSvg: u, bbox: d, label: f } = await labelHelper(e, l, "label"), p = u.insert("rect", ":first-child");
1554
- return p.attr("width", .1).attr("height", .1), u.attr("class", "label edgeLabel"), f.attr("transform", `translate(${-(d.width / 2) - (d.x - (d.left ?? 0))}, ${-(d.height / 2) - (d.y - (d.top ?? 0))})`), updateNodeBounds(l, p), l.intersect = function(e) {
1555
- return intersect_default.rect(l, e);
1556
- }, u;
1557
- }
1558
- __name(labelRect, "labelRect");
1559
- async function lean_left(e, l) {
1560
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1561
- l.labelStyle = u;
1562
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + (l.padding ?? 0), l?.width ?? 0), h = Math.max(p.height + (l.padding ?? 0), l?.height ?? 0), g = [
1563
- {
1564
- x: 0,
1565
- y: 0
1566
- },
1567
- {
1568
- x: m + 3 * h / 6,
1569
- y: 0
1570
- },
1571
- {
1572
- x: m,
1573
- y: -h
1574
- },
1575
- {
1576
- x: -(3 * h) / 6,
1577
- y: -h
1578
- }
1579
- ], _, { cssStyles: v } = l;
1580
- if (l.look === "handDrawn") {
1581
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createPathFromPoints(g), p = e.path(d, u);
1582
- _ = f.insert(() => p, ":first-child").attr("transform", `translate(${-m / 2}, ${h / 2})`), v && _.attr("style", v);
1583
- } else _ = insertPolygonShape(f, m, h, g);
1584
- return d && _.attr("style", d), l.width = m, l.height = h, updateNodeBounds(l, _), l.intersect = function(e) {
1585
- return intersect_default.polygon(l, g, e);
1586
- }, f;
1587
- }
1588
- __name(lean_left, "lean_left");
1589
- async function lean_right(e, l) {
1590
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1591
- l.labelStyle = u;
1592
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + (l.padding ?? 0), l?.width ?? 0), h = Math.max(p.height + (l.padding ?? 0), l?.height ?? 0), g = [
1593
- {
1594
- x: -3 * h / 6,
1595
- y: 0
1596
- },
1597
- {
1598
- x: m,
1599
- y: 0
1600
- },
1601
- {
1602
- x: m + 3 * h / 6,
1603
- y: -h
1604
- },
1605
- {
1606
- x: 0,
1607
- y: -h
1608
- }
1609
- ], _, { cssStyles: v } = l;
1610
- if (l.look === "handDrawn") {
1611
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createPathFromPoints(g), p = e.path(d, u);
1612
- _ = f.insert(() => p, ":first-child").attr("transform", `translate(${-m / 2}, ${h / 2})`), v && _.attr("style", v);
1613
- } else _ = insertPolygonShape(f, m, h, g);
1614
- return d && _.attr("style", d), l.width = m, l.height = h, updateNodeBounds(l, _), l.intersect = function(e) {
1615
- return intersect_default.polygon(l, g, e);
1616
- }, f;
1617
- }
1618
- __name(lean_right, "lean_right");
1619
- function lightningBolt(e, u) {
1620
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
1621
- u.label = "", u.labelStyle = d;
1622
- let p = e.insert("g").attr("class", getNodeClasses(u)).attr("id", u.domId ?? u.id), { cssStyles: m } = u, h = Math.max(35, u?.width ?? 0), g = Math.max(35, u?.height ?? 0), _ = [
1623
- {
1624
- x: h,
1625
- y: 0
1626
- },
1627
- {
1628
- x: 0,
1629
- y: g + 7 / 2
1630
- },
1631
- {
1632
- x: h - 14,
1633
- y: g + 7 / 2
1634
- },
1635
- {
1636
- x: 0,
1637
- y: 2 * g
1638
- },
1639
- {
1640
- x: h,
1641
- y: g - 7 / 2
1642
- },
1643
- {
1644
- x: 14,
1645
- y: g - 7 / 2
1646
- }
1647
- ], v = at.svg(p), y = userNodeOverrides(u, {});
1648
- u.look !== "handDrawn" && (y.roughness = 0, y.fillStyle = "solid");
1649
- let b = createPathFromPoints(_), x = v.path(b, y), S = p.insert(() => x, ":first-child");
1650
- return m && u.look !== "handDrawn" && S.selectAll("path").attr("style", m), f && u.look !== "handDrawn" && S.selectAll("path").attr("style", f), S.attr("transform", `translate(-${h / 2},${-g})`), updateNodeBounds(u, S), u.intersect = function(e) {
1651
- return log.info("lightningBolt intersect", u, e), intersect_default.polygon(u, _, e);
1652
- }, p;
1653
- }
1654
- __name(lightningBolt, "lightningBolt");
1655
- var createCylinderPathD2 = /* @__PURE__ */ __name((e, l, u, d, f, p, m) => [
1656
- `M${e},${l + p}`,
1657
- `a${f},${p} 0,0,0 ${u},0`,
1658
- `a${f},${p} 0,0,0 ${-u},0`,
1659
- `l0,${d}`,
1660
- `a${f},${p} 0,0,0 ${u},0`,
1661
- `l0,${-d}`,
1662
- `M${e},${l + p + m}`,
1663
- `a${f},${p} 0,0,0 ${u},0`
1664
- ].join(" "), "createCylinderPathD"), createOuterCylinderPathD2 = /* @__PURE__ */ __name((e, l, u, d, f, p, m) => [
1665
- `M${e},${l + p}`,
1666
- `M${e + u},${l + p}`,
1667
- `a${f},${p} 0,0,0 ${-u},0`,
1668
- `l0,${d}`,
1669
- `a${f},${p} 0,0,0 ${u},0`,
1670
- `l0,${-d}`,
1671
- `M${e},${l + p + m}`,
1672
- `a${f},${p} 0,0,0 ${u},0`
1673
- ].join(" "), "createOuterCylinderPathD"), createInnerCylinderPathD2 = /* @__PURE__ */ __name((e, l, u, d, f, p) => [`M${e - u / 2},${-d / 2}`, `a${f},${p} 0,0,0 ${u},0`].join(" "), "createInnerCylinderPathD");
1674
- async function linedCylinder(e, l) {
1675
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1676
- l.labelStyle = u;
1677
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0), l.width ?? 0), g = h / 2, _ = g / (2.5 + h / 50), v = Math.max(p.height + _ + (l.padding ?? 0), l.height ?? 0), y = v * .1, b, { cssStyles: x } = l;
1678
- if (l.look === "handDrawn") {
1679
- let e = at.svg(f), u = createOuterCylinderPathD2(0, 0, h, v, g, _, y), d = createInnerCylinderPathD2(0, _, h, v, g, _), p = userNodeOverrides(l, {}), m = e.path(u, p), S = e.path(d, p);
1680
- f.insert(() => S, ":first-child").attr("class", "line"), b = f.insert(() => m, ":first-child"), b.attr("class", "basic label-container"), x && b.attr("style", x);
1681
- } else {
1682
- let e = createCylinderPathD2(0, 0, h, v, g, _, y);
1683
- b = f.insert("path", ":first-child").attr("d", e).attr("class", "basic label-container").attr("style", handleUndefinedAttr(x)).attr("style", d);
1684
- }
1685
- return b.attr("label-offset-y", _), b.attr("transform", `translate(${-h / 2}, ${-(v / 2 + _)})`), updateNodeBounds(l, b), m.attr("transform", `translate(${-(p.width / 2) - (p.x - (p.left ?? 0))}, ${-(p.height / 2) + _ - (p.y - (p.top ?? 0))})`), l.intersect = function(e) {
1686
- let u = intersect_default.rect(l, e), d = u.x - (l.x ?? 0);
1687
- if (g != 0 && (Math.abs(d) < (l.width ?? 0) / 2 || Math.abs(d) == (l.width ?? 0) / 2 && Math.abs(u.y - (l.y ?? 0)) > (l.height ?? 0) / 2 - _)) {
1688
- let f = _ * _ * (1 - d * d / (g * g));
1689
- f > 0 && (f = Math.sqrt(f)), f = _ - f, e.y - (l.y ?? 0) > 0 && (f = -f), u.y += f;
1690
- }
1691
- return u;
1692
- }, f;
1693
- }
1694
- __name(linedCylinder, "linedCylinder");
1695
- async function linedWaveEdgedRect(e, l) {
1696
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1697
- l.labelStyle = u;
1698
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = g / 4, v = g + _, { cssStyles: y } = l, b = at.svg(f), x = userNodeOverrides(l, {});
1699
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
1700
- let S = [
1701
- {
1702
- x: -h / 2 - h / 2 * .1,
1703
- y: -v / 2
1704
- },
1705
- {
1706
- x: -h / 2 - h / 2 * .1,
1707
- y: v / 2
1708
- },
1709
- ...generateFullSineWavePoints(-h / 2 - h / 2 * .1, v / 2, h / 2 + h / 2 * .1, v / 2, _, .8),
1710
- {
1711
- x: h / 2 + h / 2 * .1,
1712
- y: -v / 2
1713
- },
1714
- {
1715
- x: -h / 2 - h / 2 * .1,
1716
- y: -v / 2
1717
- },
1718
- {
1719
- x: -h / 2,
1720
- y: -v / 2
1721
- },
1722
- {
1723
- x: -h / 2,
1724
- y: v / 2 * 1.1
1725
- },
1726
- {
1727
- x: -h / 2,
1728
- y: -v / 2
1729
- }
1730
- ], C = b.polygon(S.map((e) => [e.x, e.y]), x), E = f.insert(() => C, ":first-child");
1731
- return E.attr("class", "basic label-container"), y && l.look !== "handDrawn" && E.selectAll("path").attr("style", y), d && l.look !== "handDrawn" && E.selectAll("path").attr("style", d), E.attr("transform", `translate(0,${-_ / 2})`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) + h / 2 * .1 / 2 - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) - _ / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, E), l.intersect = function(e) {
1732
- return intersect_default.polygon(l, S, e);
1733
- }, f;
1734
- }
1735
- __name(linedWaveEdgedRect, "linedWaveEdgedRect");
1736
- async function multiRect(e, l) {
1737
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1738
- l.labelStyle = u;
1739
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = -h / 2, v = -g / 2, { cssStyles: y } = l, b = at.svg(f), x = userNodeOverrides(l, {}), S = [
1740
- {
1741
- x: _ - 5,
1742
- y: v + 5
1743
- },
1744
- {
1745
- x: _ - 5,
1746
- y: v + g + 5
1747
- },
1748
- {
1749
- x: _ + h - 5,
1750
- y: v + g + 5
1751
- },
1752
- {
1753
- x: _ + h - 5,
1754
- y: v + g
1755
- },
1756
- {
1757
- x: _ + h,
1758
- y: v + g
1759
- },
1760
- {
1761
- x: _ + h,
1762
- y: v + g - 5
1763
- },
1764
- {
1765
- x: _ + h + 5,
1766
- y: v + g - 5
1767
- },
1768
- {
1769
- x: _ + h + 5,
1770
- y: v - 5
1771
- },
1772
- {
1773
- x: _ + 5,
1774
- y: v - 5
1775
- },
1776
- {
1777
- x: _ + 5,
1778
- y: v
1779
- },
1780
- {
1781
- x: _,
1782
- y: v
1783
- },
1784
- {
1785
- x: _,
1786
- y: v + 5
1787
- }
1788
- ], C = [
1789
- {
1790
- x: _,
1791
- y: v + 5
1792
- },
1793
- {
1794
- x: _ + h - 5,
1795
- y: v + 5
1796
- },
1797
- {
1798
- x: _ + h - 5,
1799
- y: v + g
1800
- },
1801
- {
1802
- x: _ + h,
1803
- y: v + g
1804
- },
1805
- {
1806
- x: _ + h,
1807
- y: v
1808
- },
1809
- {
1810
- x: _,
1811
- y: v
1812
- }
1813
- ];
1814
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
1815
- let E = createPathFromPoints(S), D = b.path(E, x), O = createPathFromPoints(C), k = b.path(O, {
1816
- ...x,
1817
- fill: "none"
1818
- }), A = f.insert(() => k, ":first-child");
1819
- return A.insert(() => D, ":first-child"), A.attr("class", "basic label-container"), y && l.look !== "handDrawn" && A.selectAll("path").attr("style", y), d && l.look !== "handDrawn" && A.selectAll("path").attr("style", d), m.attr("transform", `translate(${-(p.width / 2) - 5 - (p.x - (p.left ?? 0))}, ${-(p.height / 2) + 5 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, A), l.intersect = function(e) {
1820
- return intersect_default.polygon(l, S, e);
1821
- }, f;
1822
- }
1823
- __name(multiRect, "multiRect");
1824
- async function multiWaveEdgedRectangle(e, l) {
1825
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1826
- l.labelStyle = u;
1827
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = g / 4, v = g + _, y = -h / 2, b = -v / 2, { cssStyles: x } = l, S = generateFullSineWavePoints(y - 5, b + v + 5, y + h - 5, b + v + 5, _, .8), C = S?.[S.length - 1], E = [
1828
- {
1829
- x: y - 5,
1830
- y: b + 5
1831
- },
1832
- {
1833
- x: y - 5,
1834
- y: b + v + 5
1835
- },
1836
- ...S,
1837
- {
1838
- x: y + h - 5,
1839
- y: C.y - 5
1840
- },
1841
- {
1842
- x: y + h,
1843
- y: C.y - 5
1844
- },
1845
- {
1846
- x: y + h,
1847
- y: C.y - 10
1848
- },
1849
- {
1850
- x: y + h + 5,
1851
- y: C.y - 10
1852
- },
1853
- {
1854
- x: y + h + 5,
1855
- y: b - 5
1856
- },
1857
- {
1858
- x: y + 5,
1859
- y: b - 5
1860
- },
1861
- {
1862
- x: y + 5,
1863
- y: b
1864
- },
1865
- {
1866
- x: y,
1867
- y: b
1868
- },
1869
- {
1870
- x: y,
1871
- y: b + 5
1872
- }
1873
- ], D = [
1874
- {
1875
- x: y,
1876
- y: b + 5
1877
- },
1878
- {
1879
- x: y + h - 5,
1880
- y: b + 5
1881
- },
1882
- {
1883
- x: y + h - 5,
1884
- y: C.y - 5
1885
- },
1886
- {
1887
- x: y + h,
1888
- y: C.y - 5
1889
- },
1890
- {
1891
- x: y + h,
1892
- y: b
1893
- },
1894
- {
1895
- x: y,
1896
- y: b
1897
- }
1898
- ], O = at.svg(f), k = userNodeOverrides(l, {});
1899
- l.look !== "handDrawn" && (k.roughness = 0, k.fillStyle = "solid");
1900
- let A = createPathFromPoints(E), j = O.path(A, k), N = createPathFromPoints(D), R = O.path(N, k), z = f.insert(() => j, ":first-child");
1901
- return z.insert(() => R), z.attr("class", "basic label-container"), x && l.look !== "handDrawn" && z.selectAll("path").attr("style", x), d && l.look !== "handDrawn" && z.selectAll("path").attr("style", d), z.attr("transform", `translate(0,${-_ / 2})`), m.attr("transform", `translate(${-(p.width / 2) - 5 - (p.x - (p.left ?? 0))}, ${-(p.height / 2) + 5 - _ / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, z), l.intersect = function(e) {
1902
- return intersect_default.polygon(l, E, e);
1903
- }, f;
1904
- }
1905
- __name(multiWaveEdgedRectangle, "multiWaveEdgedRectangle");
1906
- async function note(e, l, { config: { themeVariables: u } }) {
1907
- let { labelStyles: d, nodeStyles: f } = styles2String(l);
1908
- l.labelStyle = d, l.useHtmlLabels || getConfig().flowchart?.htmlLabels !== !1 || (l.centerLabel = !0);
1909
- let { shapeSvg: m, bbox: h, label: g } = await labelHelper(e, l, getNodeClasses(l)), _ = Math.max(h.width + (l.padding ?? 0) * 2, l?.width ?? 0), v = Math.max(h.height + (l.padding ?? 0) * 2, l?.height ?? 0), y = -_ / 2, b = -v / 2, { cssStyles: x } = l, S = at.svg(m), C = userNodeOverrides(l, {
1910
- fill: u.noteBkgColor,
1911
- stroke: u.noteBorderColor
1912
- });
1913
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
1914
- let E = S.rectangle(y, b, _, v, C), D = m.insert(() => E, ":first-child");
1915
- return D.attr("class", "basic label-container"), x && l.look !== "handDrawn" && D.selectAll("path").attr("style", x), f && l.look !== "handDrawn" && D.selectAll("path").attr("style", f), g.attr("transform", `translate(${-h.width / 2 - (h.x - (h.left ?? 0))}, ${-(h.height / 2) - (h.y - (h.top ?? 0))})`), updateNodeBounds(l, D), l.intersect = function(e) {
1916
- return intersect_default.rect(l, e);
1917
- }, m;
1918
- }
1919
- __name(note, "note");
1920
- var createDecisionBoxPathD = /* @__PURE__ */ __name((e, l, u) => [
1921
- `M${e + u / 2},${l}`,
1922
- `L${e + u},${l - u / 2}`,
1923
- `L${e + u / 2},${l - u}`,
1924
- `L${e},${l - u / 2}`,
1925
- "Z"
1926
- ].join(" "), "createDecisionBoxPathD");
1927
- async function question(e, l) {
1928
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1929
- l.labelStyle = u;
1930
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.width + l.padding + (p.height + l.padding), h = .5, g = [
1931
- {
1932
- x: m / 2,
1933
- y: 0
1934
- },
1935
- {
1936
- x: m,
1937
- y: -m / 2
1938
- },
1939
- {
1940
- x: m / 2,
1941
- y: -m
1942
- },
1943
- {
1944
- x: 0,
1945
- y: -m / 2
1946
- }
1947
- ], _, { cssStyles: v } = l;
1948
- if (l.look === "handDrawn") {
1949
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createDecisionBoxPathD(0, 0, m), p = e.path(d, u);
1950
- _ = f.insert(() => p, ":first-child").attr("transform", `translate(${-m / 2 + h}, ${m / 2})`), v && _.attr("style", v);
1951
- } else _ = insertPolygonShape(f, m, m, g), _.attr("transform", `translate(${-m / 2 + h}, ${m / 2})`);
1952
- return d && _.attr("style", d), updateNodeBounds(l, _), l.calcIntersect = function(e, l) {
1953
- let u = e.width, d = [
1954
- {
1955
- x: u / 2,
1956
- y: 0
1957
- },
1958
- {
1959
- x: u,
1960
- y: -u / 2
1961
- },
1962
- {
1963
- x: u / 2,
1964
- y: -u
1965
- },
1966
- {
1967
- x: 0,
1968
- y: -u / 2
1969
- }
1970
- ], f = intersect_default.polygon(e, d, l);
1971
- return {
1972
- x: f.x - .5,
1973
- y: f.y - .5
1974
- };
1975
- }, l.intersect = function(e) {
1976
- return this.calcIntersect(l, e);
1977
- }, f;
1978
- }
1979
- __name(question, "question");
1980
- async function rect_left_inv_arrow(e, l) {
1981
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
1982
- l.labelStyle = u;
1983
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0), l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0), l?.height ?? 0), _ = -h / 2, v = -g / 2, y = v / 2, b = [
1984
- {
1985
- x: _ + y,
1986
- y: v
1987
- },
1988
- {
1989
- x: _,
1990
- y: 0
1991
- },
1992
- {
1993
- x: _ + y,
1994
- y: -v
1995
- },
1996
- {
1997
- x: -_,
1998
- y: -v
1999
- },
2000
- {
2001
- x: -_,
2002
- y: v
2003
- }
2004
- ], { cssStyles: x } = l, S = at.svg(f), C = userNodeOverrides(l, {});
2005
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
2006
- let E = createPathFromPoints(b), D = S.path(E, C), O = f.insert(() => D, ":first-child");
2007
- return O.attr("class", "basic label-container"), x && l.look !== "handDrawn" && O.selectAll("path").attr("style", x), d && l.look !== "handDrawn" && O.selectAll("path").attr("style", d), O.attr("transform", `translate(${-y / 2},0)`), m.attr("transform", `translate(${-y / 2 - p.width / 2 - (p.x - (p.left ?? 0))}, ${-(p.height / 2) - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, O), l.intersect = function(e) {
2008
- return intersect_default.polygon(l, b, e);
2009
- }, f;
2010
- }
2011
- __name(rect_left_inv_arrow, "rect_left_inv_arrow");
2012
- async function rectWithTitle(e, u) {
2013
- let { labelStyles: d, nodeStyles: p } = styles2String(u);
2014
- u.labelStyle = d;
2015
- let h;
2016
- h = u.cssClasses ? "node " + u.cssClasses : "node default";
2017
- let g = e.insert("g").attr("class", h).attr("id", u.domId || u.id), _ = g.insert("g"), v = g.insert("g").attr("class", "label").attr("style", p), y = u.description, x = u.label, S = v.node().appendChild(await createLabel_default(x, u.labelStyle, !0, !0)), C = {
2018
- width: 0,
2019
- height: 0
2020
- };
2021
- if (evaluate(getConfig2()?.flowchart?.htmlLabels)) {
2022
- let e = S.children[0], l = select_default(S);
2023
- C = e.getBoundingClientRect(), l.attr("width", C.width), l.attr("height", C.height);
2024
- }
2025
- log.info("Text 2", y);
2026
- let E = y || [], D = S.getBBox(), O = v.node().appendChild(await createLabel_default(E.join ? E.join("<br/>") : E, u.labelStyle, !0, !0)), k = O.children[0], A = select_default(O);
2027
- C = k.getBoundingClientRect(), A.attr("width", C.width), A.attr("height", C.height);
2028
- let j = (u.padding || 0) / 2;
2029
- select_default(O).attr("transform", "translate( " + (C.width > D.width ? 0 : (D.width - C.width) / 2) + ", " + (D.height + j + 5) + ")"), select_default(S).attr("transform", "translate( " + (C.width < D.width ? 0 : -(D.width - C.width) / 2) + ", 0)"), C = v.node().getBBox(), v.attr("transform", "translate(" + -C.width / 2 + ", " + (-C.height / 2 - j + 3) + ")");
2030
- let M = C.width + (u.padding || 0), N = C.height + (u.padding || 0), F = -C.width / 2 - j, I = -C.height / 2 - j, L, R;
2031
- if (u.look === "handDrawn") {
2032
- let e = at.svg(g), d = userNodeOverrides(u, {}), f = e.path(createRoundedRectPathD(F, I, M, N, u.rx || 0), d), p = e.line(-C.width / 2 - j, -C.height / 2 - j + D.height + j, C.width / 2 + j, -C.height / 2 - j + D.height + j, d);
2033
- R = g.insert(() => (log.debug("Rough node insert CXC", f), p), ":first-child"), L = g.insert(() => (log.debug("Rough node insert CXC", f), f), ":first-child");
2034
- } else L = _.insert("rect", ":first-child"), R = _.insert("line"), L.attr("class", "outer title-state").attr("style", p).attr("x", -C.width / 2 - j).attr("y", -C.height / 2 - j).attr("width", C.width + (u.padding || 0)).attr("height", C.height + (u.padding || 0)), R.attr("class", "divider").attr("x1", -C.width / 2 - j).attr("x2", C.width / 2 + j).attr("y1", -C.height / 2 - j + D.height + j).attr("y2", -C.height / 2 - j + D.height + j);
2035
- return updateNodeBounds(u, L), u.intersect = function(e) {
2036
- return intersect_default.rect(u, e);
2037
- }, g;
2038
- }
2039
- __name(rectWithTitle, "rectWithTitle");
2040
- function generateArcPoints2(e, l, u, d, f, p, m) {
2041
- let h = (e + u) / 2, g = (l + d) / 2, _ = Math.atan2(d - l, u - e), v = (u - e) / 2, y = (d - l) / 2, b = v / f, x = y / p, S = Math.sqrt(b ** 2 + x ** 2);
2042
- if (S > 1) throw Error("The given radii are too small to create an arc between the points.");
2043
- let C = Math.sqrt(1 - S ** 2), w = h + C * p * Math.sin(_) * (m ? -1 : 1), T = g - C * f * Math.cos(_) * (m ? -1 : 1), E = Math.atan2((l - T) / p, (e - w) / f), D = Math.atan2((d - T) / p, (u - w) / f) - E;
2044
- m && D < 0 && (D += 2 * Math.PI), !m && D > 0 && (D -= 2 * Math.PI);
2045
- let O = [];
2046
- for (let e = 0; e < 20; e++) {
2047
- let l = E + e / 19 * D, u = w + f * Math.cos(l), d = T + p * Math.sin(l);
2048
- O.push({
2049
- x: u,
2050
- y: d
2051
- });
2052
- }
2053
- return O;
2054
- }
2055
- __name(generateArcPoints2, "generateArcPoints");
2056
- async function roundedRect(e, l) {
2057
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2058
- l.labelStyle = u;
2059
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = l?.padding ?? 0, h = l?.padding ?? 0, g = (l?.width ? l?.width : p.width) + m * 2, _ = (l?.height ? l?.height : p.height) + h * 2, v = l.radius || 5, y = l.taper || 5, { cssStyles: b } = l, x = at.svg(f), S = userNodeOverrides(l, {});
2060
- l.stroke && (S.stroke = l.stroke), l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
2061
- let C = [
2062
- {
2063
- x: -g / 2 + y,
2064
- y: -_ / 2
2065
- },
2066
- {
2067
- x: g / 2 - y,
2068
- y: -_ / 2
2069
- },
2070
- ...generateArcPoints2(g / 2 - y, -_ / 2, g / 2, -_ / 2 + y, v, v, !0),
2071
- {
2072
- x: g / 2,
2073
- y: -_ / 2 + y
2074
- },
2075
- {
2076
- x: g / 2,
2077
- y: _ / 2 - y
2078
- },
2079
- ...generateArcPoints2(g / 2, _ / 2 - y, g / 2 - y, _ / 2, v, v, !0),
2080
- {
2081
- x: g / 2 - y,
2082
- y: _ / 2
2083
- },
2084
- {
2085
- x: -g / 2 + y,
2086
- y: _ / 2
2087
- },
2088
- ...generateArcPoints2(-g / 2 + y, _ / 2, -g / 2, _ / 2 - y, v, v, !0),
2089
- {
2090
- x: -g / 2,
2091
- y: _ / 2 - y
2092
- },
2093
- {
2094
- x: -g / 2,
2095
- y: -_ / 2 + y
2096
- },
2097
- ...generateArcPoints2(-g / 2, -_ / 2 + y, -g / 2 + y, -_ / 2, v, v, !0)
2098
- ], E = createPathFromPoints(C), D = x.path(E, S), O = f.insert(() => D, ":first-child");
2099
- return O.attr("class", "basic label-container outer-path"), b && l.look !== "handDrawn" && O.selectChildren("path").attr("style", b), d && l.look !== "handDrawn" && O.selectChildren("path").attr("style", d), updateNodeBounds(l, O), l.intersect = function(e) {
2100
- return intersect_default.polygon(l, C, e);
2101
- }, f;
2102
- }
2103
- __name(roundedRect, "roundedRect");
2104
- async function shadedProcess(e, l) {
2105
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2106
- l.labelStyle = u;
2107
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = l?.padding ?? 0, g = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), _ = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), v = -p.width / 2 - h, y = -p.height / 2 - h, { cssStyles: b } = l, x = at.svg(f), S = userNodeOverrides(l, {});
2108
- l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
2109
- let C = [
2110
- {
2111
- x: v,
2112
- y
2113
- },
2114
- {
2115
- x: v + g + 8,
2116
- y
2117
- },
2118
- {
2119
- x: v + g + 8,
2120
- y: y + _
2121
- },
2122
- {
2123
- x: v - 8,
2124
- y: y + _
2125
- },
2126
- {
2127
- x: v - 8,
2128
- y
2129
- },
2130
- {
2131
- x: v,
2132
- y
2133
- },
2134
- {
2135
- x: v,
2136
- y: y + _
2137
- }
2138
- ], E = x.polygon(C.map((e) => [e.x, e.y]), S), D = f.insert(() => E, ":first-child");
2139
- return D.attr("class", "basic label-container").attr("style", handleUndefinedAttr(b)), d && l.look !== "handDrawn" && D.selectAll("path").attr("style", d), b && l.look !== "handDrawn" && D.selectAll("path").attr("style", d), m.attr("transform", `translate(${-g / 2 + 4 + (l.padding ?? 0) - (p.x - (p.left ?? 0))},${-_ / 2 + (l.padding ?? 0) - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, D), l.intersect = function(e) {
2140
- return intersect_default.rect(l, e);
2141
- }, f;
2142
- }
2143
- __name(shadedProcess, "shadedProcess");
2144
- async function slopedRect(e, l) {
2145
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2146
- l.labelStyle = u;
2147
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = -h / 2, v = -g / 2, { cssStyles: y } = l, b = at.svg(f), x = userNodeOverrides(l, {});
2148
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
2149
- let S = [
2150
- {
2151
- x: _,
2152
- y: v
2153
- },
2154
- {
2155
- x: _,
2156
- y: v + g
2157
- },
2158
- {
2159
- x: _ + h,
2160
- y: v + g
2161
- },
2162
- {
2163
- x: _ + h,
2164
- y: v - g / 2
2165
- }
2166
- ], C = createPathFromPoints(S), E = b.path(C, x), D = f.insert(() => E, ":first-child");
2167
- return D.attr("class", "basic label-container"), y && l.look !== "handDrawn" && D.selectChildren("path").attr("style", y), d && l.look !== "handDrawn" && D.selectChildren("path").attr("style", d), D.attr("transform", `translate(0, ${g / 4})`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) - (p.x - (p.left ?? 0))}, ${-g / 4 + (l.padding ?? 0) - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, D), l.intersect = function(e) {
2168
- return intersect_default.polygon(l, S, e);
2169
- }, f;
2170
- }
2171
- __name(slopedRect, "slopedRect");
2172
- async function squareRect2(e, l) {
2173
- return drawRect(e, l, {
2174
- rx: 0,
2175
- ry: 0,
2176
- classes: "",
2177
- labelPaddingX: l.labelPaddingX ?? (l?.padding || 0) * 2,
2178
- labelPaddingY: (l?.padding || 0) * 1
2179
- });
2180
- }
2181
- __name(squareRect2, "squareRect");
2182
- async function stadium(e, l) {
2183
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2184
- l.labelStyle = u;
2185
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.height + l.padding, h = p.width + m / 4 + l.padding, g = m / 2, { cssStyles: _ } = l, v = at.svg(f), y = userNodeOverrides(l, {});
2186
- l.look !== "handDrawn" && (y.roughness = 0, y.fillStyle = "solid");
2187
- let b = [
2188
- {
2189
- x: -h / 2 + g,
2190
- y: -m / 2
2191
- },
2192
- {
2193
- x: h / 2 - g,
2194
- y: -m / 2
2195
- },
2196
- ...generateCirclePoints(-h / 2 + g, 0, g, 50, 90, 270),
2197
- {
2198
- x: h / 2 - g,
2199
- y: m / 2
2200
- },
2201
- ...generateCirclePoints(h / 2 - g, 0, g, 50, 270, 450)
2202
- ], x = createPathFromPoints(b), S = v.path(x, y), C = f.insert(() => S, ":first-child");
2203
- return C.attr("class", "basic label-container outer-path"), _ && l.look !== "handDrawn" && C.selectChildren("path").attr("style", _), d && l.look !== "handDrawn" && C.selectChildren("path").attr("style", d), updateNodeBounds(l, C), l.intersect = function(e) {
2204
- return intersect_default.polygon(l, b, e);
2205
- }, f;
2206
- }
2207
- __name(stadium, "stadium");
2208
- async function state(e, l) {
2209
- return drawRect(e, l, {
2210
- rx: 5,
2211
- ry: 5,
2212
- classes: "flowchart-node"
2213
- });
2214
- }
2215
- __name(state, "state");
2216
- function stateEnd(e, l, { config: { themeVariables: u } }) {
2217
- let { labelStyles: d, nodeStyles: f } = styles2String(l);
2218
- l.labelStyle = d;
2219
- let { cssStyles: p } = l, { lineColor: m, stateBorder: h, nodeBorder: g } = u, _ = e.insert("g").attr("class", "node default").attr("id", l.domId || l.id), v = at.svg(_), y = userNodeOverrides(l, {});
2220
- l.look !== "handDrawn" && (y.roughness = 0, y.fillStyle = "solid");
2221
- let b = v.circle(0, 0, 14, {
2222
- ...y,
2223
- stroke: m,
2224
- strokeWidth: 2
2225
- }), x = h ?? g, S = v.circle(0, 0, 5, {
2226
- ...y,
2227
- fill: x,
2228
- stroke: x,
2229
- strokeWidth: 2,
2230
- fillStyle: "solid"
2231
- }), C = _.insert(() => b, ":first-child");
2232
- return C.insert(() => S), p && C.selectAll("path").attr("style", p), f && C.selectAll("path").attr("style", f), updateNodeBounds(l, C), l.intersect = function(e) {
2233
- return intersect_default.circle(l, 7, e);
2234
- }, _;
2235
- }
2236
- __name(stateEnd, "stateEnd");
2237
- function stateStart(e, l, { config: { themeVariables: u } }) {
2238
- let { lineColor: d } = u, f = e.insert("g").attr("class", "node default").attr("id", l.domId || l.id), p;
2239
- if (l.look === "handDrawn") {
2240
- let e = at.svg(f).circle(0, 0, 14, solidStateFill(d));
2241
- p = f.insert(() => e), p.attr("class", "state-start").attr("r", 7).attr("width", 14).attr("height", 14);
2242
- } else p = f.insert("circle", ":first-child"), p.attr("class", "state-start").attr("r", 7).attr("width", 14).attr("height", 14);
2243
- return updateNodeBounds(l, p), l.intersect = function(e) {
2244
- return intersect_default.circle(l, 7, e);
2245
- }, f;
2246
- }
2247
- __name(stateStart, "stateStart");
2248
- async function subroutine(e, l) {
2249
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2250
- l.labelStyle = u;
2251
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = (l?.padding || 0) / 2, h = p.width + l.padding, g = p.height + l.padding, _ = -p.width / 2 - m, v = -p.height / 2 - m, y = [
2252
- {
2253
- x: 0,
2254
- y: 0
2255
- },
2256
- {
2257
- x: h,
2258
- y: 0
2259
- },
2260
- {
2261
- x: h,
2262
- y: -g
2263
- },
2264
- {
2265
- x: 0,
2266
- y: -g
2267
- },
2268
- {
2269
- x: 0,
2270
- y: 0
2271
- },
2272
- {
2273
- x: -8,
2274
- y: 0
2275
- },
2276
- {
2277
- x: h + 8,
2278
- y: 0
2279
- },
2280
- {
2281
- x: h + 8,
2282
- y: -g
2283
- },
2284
- {
2285
- x: -8,
2286
- y: -g
2287
- },
2288
- {
2289
- x: -8,
2290
- y: 0
2291
- }
2292
- ];
2293
- if (l.look === "handDrawn") {
2294
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = e.rectangle(_ - 8, v, h + 16, g, u), p = e.line(_, v, _, v + g, u), m = e.line(_ + h, v, _ + h, v + g, u);
2295
- f.insert(() => p, ":first-child"), f.insert(() => m, ":first-child");
2296
- let y = f.insert(() => d, ":first-child"), { cssStyles: b } = l;
2297
- y.attr("class", "basic label-container").attr("style", handleUndefinedAttr(b)), updateNodeBounds(l, y);
2298
- } else {
2299
- let e = insertPolygonShape(f, h, g, y);
2300
- d && e.attr("style", d), updateNodeBounds(l, e);
2301
- }
2302
- return l.intersect = function(e) {
2303
- return intersect_default.polygon(l, y, e);
2304
- }, f;
2305
- }
2306
- __name(subroutine, "subroutine");
2307
- async function taggedRect(e, l) {
2308
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2309
- l.labelStyle = u;
2310
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), h = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), g = -m / 2, _ = -h / 2, v = .2 * h, y = .2 * h, { cssStyles: b } = l, x = at.svg(f), S = userNodeOverrides(l, {}), C = [
2311
- {
2312
- x: g - v / 2,
2313
- y: _
2314
- },
2315
- {
2316
- x: g + m + v / 2,
2317
- y: _
2318
- },
2319
- {
2320
- x: g + m + v / 2,
2321
- y: _ + h
2322
- },
2323
- {
2324
- x: g - v / 2,
2325
- y: _ + h
2326
- }
2327
- ], E = [
2328
- {
2329
- x: g + m - v / 2,
2330
- y: _ + h
2331
- },
2332
- {
2333
- x: g + m + v / 2,
2334
- y: _ + h
2335
- },
2336
- {
2337
- x: g + m + v / 2,
2338
- y: _ + h - y
2339
- }
2340
- ];
2341
- l.look !== "handDrawn" && (S.roughness = 0, S.fillStyle = "solid");
2342
- let D = createPathFromPoints(C), O = x.path(D, S), k = createPathFromPoints(E), A = x.path(k, {
2343
- ...S,
2344
- fillStyle: "solid"
2345
- }), j = f.insert(() => A, ":first-child");
2346
- return j.insert(() => O, ":first-child"), j.attr("class", "basic label-container"), b && l.look !== "handDrawn" && j.selectAll("path").attr("style", b), d && l.look !== "handDrawn" && j.selectAll("path").attr("style", d), updateNodeBounds(l, j), l.intersect = function(e) {
2347
- return intersect_default.polygon(l, C, e);
2348
- }, f;
2349
- }
2350
- __name(taggedRect, "taggedRect");
2351
- async function taggedWaveEdgedRectangle(e, l) {
2352
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2353
- l.labelStyle = u;
2354
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = g / 4, v = .2 * h, y = .2 * g, b = g + _, { cssStyles: x } = l, S = at.svg(f), C = userNodeOverrides(l, {});
2355
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
2356
- let E = [
2357
- {
2358
- x: -h / 2 - h / 2 * .1,
2359
- y: b / 2
2360
- },
2361
- ...generateFullSineWavePoints(-h / 2 - h / 2 * .1, b / 2, h / 2 + h / 2 * .1, b / 2, _, .8),
2362
- {
2363
- x: h / 2 + h / 2 * .1,
2364
- y: -b / 2
2365
- },
2366
- {
2367
- x: -h / 2 - h / 2 * .1,
2368
- y: -b / 2
2369
- }
2370
- ], D = -h / 2 + h / 2 * .1, O = -b / 2 - y * .4, k = [
2371
- {
2372
- x: D + h - v,
2373
- y: (O + g) * 1.4
2374
- },
2375
- {
2376
- x: D + h,
2377
- y: O + g - y
2378
- },
2379
- {
2380
- x: D + h,
2381
- y: (O + g) * .9
2382
- },
2383
- ...generateFullSineWavePoints(D + h, (O + g) * 1.3, D + h - v, (O + g) * 1.5, -g * .03, .5)
2384
- ], A = createPathFromPoints(E), j = S.path(A, C), N = createPathFromPoints(k), R = S.path(N, {
2385
- ...C,
2386
- fillStyle: "solid"
2387
- }), z = f.insert(() => R, ":first-child");
2388
- return z.insert(() => j, ":first-child"), z.attr("class", "basic label-container"), x && l.look !== "handDrawn" && z.selectAll("path").attr("style", x), d && l.look !== "handDrawn" && z.selectAll("path").attr("style", d), z.attr("transform", `translate(0,${-_ / 2})`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) - _ / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, z), l.intersect = function(e) {
2389
- return intersect_default.polygon(l, E, e);
2390
- }, f;
2391
- }
2392
- __name(taggedWaveEdgedRectangle, "taggedWaveEdgedRectangle");
2393
- async function text(e, l) {
2394
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2395
- l.labelStyle = u;
2396
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + l.padding, l?.width || 0), h = Math.max(p.height + l.padding, l?.height || 0), g = -m / 2, _ = -h / 2, v = f.insert("rect", ":first-child");
2397
- return v.attr("class", "text").attr("style", d).attr("rx", 0).attr("ry", 0).attr("x", g).attr("y", _).attr("width", m).attr("height", h), updateNodeBounds(l, v), l.intersect = function(e) {
2398
- return intersect_default.rect(l, e);
2399
- }, f;
2400
- }
2401
- __name(text, "text");
2402
- var createCylinderPathD3 = /* @__PURE__ */ __name((e, l, u, d, f, p) => `M${e},${l}
2403
- a${f},${p} 0,0,1 0,${-d}
2404
- l${u},0
2405
- a${f},${p} 0,0,1 0,${d}
2406
- M${u},${-d}
2407
- a${f},${p} 0,0,0 0,${d}
2408
- l${-u},0`, "createCylinderPathD"), createOuterCylinderPathD3 = /* @__PURE__ */ __name((e, l, u, d, f, p) => [
2409
- `M${e},${l}`,
2410
- `M${e + u},${l}`,
2411
- `a${f},${p} 0,0,0 0,${-d}`,
2412
- `l${-u},0`,
2413
- `a${f},${p} 0,0,0 0,${d}`,
2414
- `l${u},0`
2415
- ].join(" "), "createOuterCylinderPathD"), createInnerCylinderPathD3 = /* @__PURE__ */ __name((e, l, u, d, f, p) => [`M${e + u / 2},${-d / 2}`, `a${f},${p} 0,0,0 0,${d}`].join(" "), "createInnerCylinderPathD");
2416
- async function tiltedCylinder(e, l) {
2417
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2418
- l.labelStyle = u;
2419
- let { shapeSvg: f, bbox: p, label: m, halfPadding: h } = await labelHelper(e, l, getNodeClasses(l)), g = l.look === "neo" ? h * 2 : h, _ = p.height + g, v = _ / 2, y = v / (2.5 + _ / 50), b = p.width + y + g, { cssStyles: x } = l, S;
2420
- if (l.look === "handDrawn") {
2421
- let e = at.svg(f), u = createOuterCylinderPathD3(0, 0, b, _, y, v), d = createInnerCylinderPathD3(0, 0, b, _, y, v), p = e.path(u, userNodeOverrides(l, {})), m = e.path(d, userNodeOverrides(l, { fill: "none" }));
2422
- S = f.insert(() => m, ":first-child"), S = f.insert(() => p, ":first-child"), S.attr("class", "basic label-container"), x && S.attr("style", x);
2423
- } else {
2424
- let e = createCylinderPathD3(0, 0, b, _, y, v);
2425
- S = f.insert("path", ":first-child").attr("d", e).attr("class", "basic label-container").attr("style", handleUndefinedAttr(x)).attr("style", d), S.attr("class", "basic label-container"), x && S.selectAll("path").attr("style", x), d && S.selectAll("path").attr("style", d);
2426
- }
2427
- return S.attr("label-offset-x", y), S.attr("transform", `translate(${-b / 2}, ${_ / 2} )`), m.attr("transform", `translate(${-(p.width / 2) - y - (p.x - (p.left ?? 0))}, ${-(p.height / 2) - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, S), l.intersect = function(e) {
2428
- let u = intersect_default.rect(l, e), d = u.y - (l.y ?? 0);
2429
- if (v != 0 && (Math.abs(d) < (l.height ?? 0) / 2 || Math.abs(d) == (l.height ?? 0) / 2 && Math.abs(u.x - (l.x ?? 0)) > (l.width ?? 0) / 2 - y)) {
2430
- let f = y * y * (1 - d * d / (v * v));
2431
- f != 0 && (f = Math.sqrt(Math.abs(f))), f = y - f, e.x - (l.x ?? 0) > 0 && (f = -f), u.x += f;
2432
- }
2433
- return u;
2434
- }, f;
2435
- }
2436
- __name(tiltedCylinder, "tiltedCylinder");
2437
- async function trapezoid(e, l) {
2438
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2439
- l.labelStyle = u;
2440
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = p.width + l.padding, h = p.height + l.padding, g = [
2441
- {
2442
- x: -3 * h / 6,
2443
- y: 0
2444
- },
2445
- {
2446
- x: m + 3 * h / 6,
2447
- y: 0
2448
- },
2449
- {
2450
- x: m,
2451
- y: -h
2452
- },
2453
- {
2454
- x: 0,
2455
- y: -h
2456
- }
2457
- ], _, { cssStyles: v } = l;
2458
- if (l.look === "handDrawn") {
2459
- let e = at.svg(f), u = userNodeOverrides(l, {}), d = createPathFromPoints(g), p = e.path(d, u);
2460
- _ = f.insert(() => p, ":first-child").attr("transform", `translate(${-m / 2}, ${h / 2})`), v && _.attr("style", v);
2461
- } else _ = insertPolygonShape(f, m, h, g);
2462
- return d && _.attr("style", d), l.width = m, l.height = h, updateNodeBounds(l, _), l.intersect = function(e) {
2463
- return intersect_default.polygon(l, g, e);
2464
- }, f;
2465
- }
2466
- __name(trapezoid, "trapezoid");
2467
- async function trapezoidalPentagon(e, l) {
2468
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2469
- l.labelStyle = u;
2470
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(60, p.width + (l.padding ?? 0) * 2, l?.width ?? 0), h = Math.max(20, p.height + (l.padding ?? 0) * 2, l?.height ?? 0), { cssStyles: g } = l, _ = at.svg(f), v = userNodeOverrides(l, {});
2471
- l.look !== "handDrawn" && (v.roughness = 0, v.fillStyle = "solid");
2472
- let y = [
2473
- {
2474
- x: -m / 2 * .8,
2475
- y: -h / 2
2476
- },
2477
- {
2478
- x: m / 2 * .8,
2479
- y: -h / 2
2480
- },
2481
- {
2482
- x: m / 2,
2483
- y: -h / 2 * .6
2484
- },
2485
- {
2486
- x: m / 2,
2487
- y: h / 2
2488
- },
2489
- {
2490
- x: -m / 2,
2491
- y: h / 2
2492
- },
2493
- {
2494
- x: -m / 2,
2495
- y: -h / 2 * .6
2496
- }
2497
- ], b = createPathFromPoints(y), x = _.path(b, v), S = f.insert(() => x, ":first-child");
2498
- return S.attr("class", "basic label-container"), g && l.look !== "handDrawn" && S.selectChildren("path").attr("style", g), d && l.look !== "handDrawn" && S.selectChildren("path").attr("style", d), updateNodeBounds(l, S), l.intersect = function(e) {
2499
- return intersect_default.polygon(l, y, e);
2500
- }, f;
2501
- }
2502
- __name(trapezoidalPentagon, "trapezoidalPentagon");
2503
- async function triangle(e, u) {
2504
- let { labelStyles: d, nodeStyles: p } = styles2String(u);
2505
- u.labelStyle = d;
2506
- let { shapeSvg: h, bbox: g, label: _ } = await labelHelper(e, u, getNodeClasses(u)), v = evaluate(getConfig2().flowchart?.htmlLabels), y = g.width + (u.padding ?? 0), b = y + g.height, x = y + g.height, S = [
2507
- {
2508
- x: 0,
2509
- y: 0
2510
- },
2511
- {
2512
- x,
2513
- y: 0
2514
- },
2515
- {
2516
- x: x / 2,
2517
- y: -b
2518
- }
2519
- ], { cssStyles: C } = u, E = at.svg(h), D = userNodeOverrides(u, {});
2520
- u.look !== "handDrawn" && (D.roughness = 0, D.fillStyle = "solid");
2521
- let O = createPathFromPoints(S), k = E.path(O, D), A = h.insert(() => k, ":first-child").attr("transform", `translate(${-b / 2}, ${b / 2})`);
2522
- return C && u.look !== "handDrawn" && A.selectChildren("path").attr("style", C), p && u.look !== "handDrawn" && A.selectChildren("path").attr("style", p), u.width = y, u.height = b, updateNodeBounds(u, A), _.attr("transform", `translate(${-g.width / 2 - (g.x - (g.left ?? 0))}, ${b / 2 - (g.height + (u.padding ?? 0) / (v ? 2 : 1) - (g.y - (g.top ?? 0)))})`), u.intersect = function(e) {
2523
- return log.info("Triangle intersect", u, S, e), intersect_default.polygon(u, S, e);
2524
- }, h;
2525
- }
2526
- __name(triangle, "triangle");
2527
- async function waveEdgedRectangle(e, l) {
2528
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2529
- l.labelStyle = u;
2530
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = g / 8, v = g + _, { cssStyles: y } = l, b = 70 - h, x = b > 0 ? b / 2 : 0, S = at.svg(f), C = userNodeOverrides(l, {});
2531
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
2532
- let E = [
2533
- {
2534
- x: -h / 2 - x,
2535
- y: v / 2
2536
- },
2537
- ...generateFullSineWavePoints(-h / 2 - x, v / 2, h / 2 + x, v / 2, _, .8),
2538
- {
2539
- x: h / 2 + x,
2540
- y: -v / 2
2541
- },
2542
- {
2543
- x: -h / 2 - x,
2544
- y: -v / 2
2545
- }
2546
- ], D = createPathFromPoints(E), O = S.path(D, C), k = f.insert(() => O, ":first-child");
2547
- return k.attr("class", "basic label-container"), y && l.look !== "handDrawn" && k.selectAll("path").attr("style", y), d && l.look !== "handDrawn" && k.selectAll("path").attr("style", d), k.attr("transform", `translate(0,${-_ / 2})`), m.attr("transform", `translate(${-h / 2 + (l.padding ?? 0) - (p.x - (p.left ?? 0))},${-g / 2 + (l.padding ?? 0) - _ - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, k), l.intersect = function(e) {
2548
- return intersect_default.polygon(l, E, e);
2549
- }, f;
2550
- }
2551
- __name(waveEdgedRectangle, "waveEdgedRectangle");
2552
- async function waveRectangle(e, l) {
2553
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2554
- l.labelStyle = u;
2555
- let { shapeSvg: f, bbox: p } = await labelHelper(e, l, getNodeClasses(l)), m = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), h = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), g = m / h, _ = m, v = h;
2556
- _ > v * g ? v = _ / g : _ = v * g, _ = Math.max(_, 100), v = Math.max(v, 50);
2557
- let y = Math.min(v * .2, v / 4), b = v + y * 2, { cssStyles: x } = l, S = at.svg(f), C = userNodeOverrides(l, {});
2558
- l.look !== "handDrawn" && (C.roughness = 0, C.fillStyle = "solid");
2559
- let E = [
2560
- {
2561
- x: -_ / 2,
2562
- y: b / 2
2563
- },
2564
- ...generateFullSineWavePoints(-_ / 2, b / 2, _ / 2, b / 2, y, 1),
2565
- {
2566
- x: _ / 2,
2567
- y: -b / 2
2568
- },
2569
- ...generateFullSineWavePoints(_ / 2, -b / 2, -_ / 2, -b / 2, y, -1)
2570
- ], D = createPathFromPoints(E), O = S.path(D, C), k = f.insert(() => O, ":first-child");
2571
- return k.attr("class", "basic label-container"), x && l.look !== "handDrawn" && k.selectAll("path").attr("style", x), d && l.look !== "handDrawn" && k.selectAll("path").attr("style", d), updateNodeBounds(l, k), l.intersect = function(e) {
2572
- return intersect_default.polygon(l, E, e);
2573
- }, f;
2574
- }
2575
- __name(waveRectangle, "waveRectangle");
2576
- async function windowPane(e, l) {
2577
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2578
- l.labelStyle = u;
2579
- let { shapeSvg: f, bbox: p, label: m } = await labelHelper(e, l, getNodeClasses(l)), h = Math.max(p.width + (l.padding ?? 0) * 2, l?.width ?? 0), g = Math.max(p.height + (l.padding ?? 0) * 2, l?.height ?? 0), _ = -h / 2, v = -g / 2, { cssStyles: y } = l, b = at.svg(f), x = userNodeOverrides(l, {}), S = [
2580
- {
2581
- x: _ - 5,
2582
- y: v - 5
2583
- },
2584
- {
2585
- x: _ - 5,
2586
- y: v + g
2587
- },
2588
- {
2589
- x: _ + h,
2590
- y: v + g
2591
- },
2592
- {
2593
- x: _ + h,
2594
- y: v - 5
2595
- }
2596
- ], C = `M${_ - 5},${v - 5} L${_ + h},${v - 5} L${_ + h},${v + g} L${_ - 5},${v + g} L${_ - 5},${v - 5}
2597
- M${_ - 5},${v} L${_ + h},${v}
2598
- M${_},${v - 5} L${_},${v + g}`;
2599
- l.look !== "handDrawn" && (x.roughness = 0, x.fillStyle = "solid");
2600
- let E = b.path(C, x), D = f.insert(() => E, ":first-child");
2601
- return D.attr("transform", `translate(${5 / 2}, ${5 / 2})`), D.attr("class", "basic label-container"), y && l.look !== "handDrawn" && D.selectAll("path").attr("style", y), d && l.look !== "handDrawn" && D.selectAll("path").attr("style", d), m.attr("transform", `translate(${-(p.width / 2) + 5 / 2 - (p.x - (p.left ?? 0))}, ${-(p.height / 2) + 5 / 2 - (p.y - (p.top ?? 0))})`), updateNodeBounds(l, D), l.intersect = function(e) {
2602
- return intersect_default.polygon(l, S, e);
2603
- }, f;
2604
- }
2605
- __name(windowPane, "windowPane");
2606
- async function erBox(e, l) {
2607
- let u = l;
2608
- if (u.alias && (l.label = u.alias), l.look === "handDrawn") {
2609
- let { themeVariables: u } = getConfig(), { background: d } = u;
2610
- await erBox(e, {
2611
- ...l,
2612
- id: l.id + "-background",
2613
- look: "default",
2614
- cssStyles: ["stroke: none", `fill: ${d}`]
2615
- });
2616
- }
2617
- let d = getConfig();
2618
- l.useHtmlLabels = d.htmlLabels;
2619
- let m = d.er?.diagramPadding ?? 10, h = d.er?.entityPadding ?? 6, { cssStyles: g } = l, { labelStyles: _, nodeStyles: v } = styles2String(l);
2620
- if (u.attributes.length === 0 && l.label) {
2621
- let u = {
2622
- rx: 0,
2623
- ry: 0,
2624
- labelPaddingX: m,
2625
- labelPaddingY: m * 1.5,
2626
- classes: ""
2627
- };
2628
- calculateTextWidth(l.label, d) + u.labelPaddingX * 2 < d.er.minEntityWidth && (l.width = d.er.minEntityWidth);
2629
- let p = await drawRect(e, l, u);
2630
- if (!evaluate(d.htmlLabels)) {
2631
- let e = p.select("text"), l = e.node()?.getBBox();
2632
- e.attr("transform", `translate(${-l.width / 2}, 0)`);
2633
- }
2634
- return p;
2635
- }
2636
- d.htmlLabels || (m *= 1.25, h *= 1.25);
2637
- let y = getNodeClasses(l);
2638
- y ||= "node default";
2639
- let x = e.insert("g").attr("class", y).attr("id", l.domId || l.id), S = await addText(x, l.label ?? "", d, 0, 0, ["name"], _);
2640
- S.height += h;
2641
- let C = 0, D = [], O = [], k = 0, A = 0, j = 0, M = 0, N = !0, I = !0;
2642
- for (let e of u.attributes) {
2643
- let l = await addText(x, e.type, d, 0, C, ["attribute-type"], _);
2644
- k = Math.max(k, l.width + m);
2645
- let u = await addText(x, e.name, d, 0, C, ["attribute-name"], _);
2646
- A = Math.max(A, u.width + m);
2647
- let f = await addText(x, e.keys.join(), d, 0, C, ["attribute-keys"], _);
2648
- j = Math.max(j, f.width + m);
2649
- let p = await addText(x, e.comment, d, 0, C, ["attribute-comment"], _);
2650
- M = Math.max(M, p.width + m);
2651
- let g = Math.max(l.height, u.height, f.height, p.height) + h;
2652
- O.push({
2653
- yOffset: C,
2654
- rowHeight: g
2655
- }), C += g;
2656
- }
2657
- let L = 4;
2658
- j <= m && (N = !1, j = 0, L--), M <= m && (I = !1, M = 0, L--);
2659
- let R = x.node().getBBox();
2660
- if (S.width + m * 2 - (k + A + j + M) > 0) {
2661
- let e = S.width + m * 2 - (k + A + j + M);
2662
- k += e / L, A += e / L, j > 0 && (j += e / L), M > 0 && (M += e / L);
2663
- }
2664
- let z = k + A + j + M, B = at.svg(x), V = userNodeOverrides(l, {});
2665
- l.look !== "handDrawn" && (V.roughness = 0, V.fillStyle = "solid");
2666
- let H = 0;
2667
- O.length > 0 && (H = O.reduce((e, l) => e + (l?.rowHeight ?? 0), 0));
2668
- let U = Math.max(R.width + m * 2, l?.width || 0, z), W = Math.max((H ?? 0) + S.height, l?.height || 0), G = -U / 2, K = -W / 2;
2669
- x.selectAll("g:not(:first-child)").each((e, l, u) => {
2670
- let d = select_default(u[l]), f = d.attr("transform"), p = 0, g = 0;
2671
- if (f) {
2672
- let e = RegExp(/translate\(([^,]+),([^)]+)\)/).exec(f);
2673
- e && (p = parseFloat(e[1]), g = parseFloat(e[2]), d.attr("class").includes("attribute-name") ? p += k : d.attr("class").includes("attribute-keys") ? p += k + A : d.attr("class").includes("attribute-comment") && (p += k + A + j));
2674
- }
2675
- d.attr("transform", `translate(${G + m / 2 + p}, ${g + K + S.height + h / 2})`);
2676
- }), x.select(".name").attr("transform", "translate(" + -S.width / 2 + ", " + (K + h / 2) + ")");
2677
- let q = B.rectangle(G, K, U, W, V), J = x.insert(() => q, ":first-child").attr("style", g.join("")), { themeVariables: Y } = getConfig(), { rowEven: X, rowOdd: Z, nodeBorder: Q } = Y;
2678
- D.push(0);
2679
- for (let [e, l] of O.entries()) {
2680
- let u = (e + 1) % 2 == 0 && l.yOffset !== 0, d = B.rectangle(G, S.height + K + l?.yOffset, U, l?.rowHeight, {
2681
- ...V,
2682
- fill: u ? X : Z,
2683
- stroke: Q
2684
- });
2685
- x.insert(() => d, "g.label").attr("style", g.join("")).attr("class", `row-rect-${u ? "even" : "odd"}`);
2686
- }
2687
- let $ = B.line(G, S.height + K, U + G, S.height + K, V);
2688
- x.insert(() => $).attr("class", "divider"), $ = B.line(k + G, S.height + K, k + G, W + K, V), x.insert(() => $).attr("class", "divider"), N && ($ = B.line(k + A + G, S.height + K, k + A + G, W + K, V), x.insert(() => $).attr("class", "divider")), I && ($ = B.line(k + A + j + G, S.height + K, k + A + j + G, W + K, V), x.insert(() => $).attr("class", "divider"));
2689
- for (let e of D) $ = B.line(G, S.height + K + e, U + G, S.height + K + e, V), x.insert(() => $).attr("class", "divider");
2690
- if (updateNodeBounds(l, J), v && l.look !== "handDrawn") {
2691
- let e = v.split(";")?.filter((e) => e.includes("stroke"))?.map((e) => `${e}`).join("; ");
2692
- x.selectAll("path").attr("style", e ?? ""), x.selectAll(".row-rect-even path").attr("style", v);
2693
- }
2694
- return l.intersect = function(e) {
2695
- return intersect_default.rect(l, e);
2696
- }, x;
2697
- }
2698
- __name(erBox, "erBox");
2699
- async function addText(e, l, u, d = 0, p = 0, m = [], h = "") {
2700
- let _ = e.insert("g").attr("class", `label ${m.join(" ")}`).attr("transform", `translate(${d}, ${p})`).attr("style", h);
2701
- l !== parseGenericTypes(l) && (l = parseGenericTypes(l), l = l.replaceAll("<", "&lt;").replaceAll(">", "&gt;"));
2702
- let v = _.node().appendChild(await createText(_, l, {
2703
- width: calculateTextWidth(l, u) + 100,
2704
- style: h,
2705
- useHtmlLabels: u.htmlLabels
2706
- }, u));
2707
- if (l.includes("&lt;") || l.includes("&gt;")) {
2708
- let e = v.children[0];
2709
- for (e.textContent = e.textContent.replaceAll("&lt;", "<").replaceAll("&gt;", ">"); e.childNodes[0];) e = e.childNodes[0], e.textContent = e.textContent.replaceAll("&lt;", "<").replaceAll("&gt;", ">");
2710
- }
2711
- let y = v.getBBox();
2712
- if (evaluate(u.htmlLabels)) {
2713
- let e = v.children[0];
2714
- e.style.textAlign = "start";
2715
- let l = select_default(v);
2716
- y = e.getBoundingClientRect(), l.attr("width", y.width), l.attr("height", y.height);
2717
- }
2718
- return y;
2719
- }
2720
- __name(addText, "addText");
2721
- async function textHelper(e, l, u, d, f = u.class.padding ?? 12) {
2722
- let p = d ? 0 : 3, m = e.insert("g").attr("class", getNodeClasses(l)).attr("id", l.domId || l.id), h = null, g = null, _ = null, v = null, y = 0, b = 0, x = 0;
2723
- if (h = m.insert("g").attr("class", "annotation-group text"), l.annotations.length > 0) {
2724
- let e = l.annotations[0];
2725
- await addText2(h, { text: `\xAB${e}\xBB` }, 0), y = h.node().getBBox().height;
2726
- }
2727
- g = m.insert("g").attr("class", "label-group text"), await addText2(g, l, 0, ["font-weight: bolder"]);
2728
- let S = g.node().getBBox();
2729
- b = S.height, _ = m.insert("g").attr("class", "members-group text");
2730
- let C = 0;
2731
- for (let e of l.members) {
2732
- let l = await addText2(_, e, C, [e.parseClassifier()]);
2733
- C += l + p;
2734
- }
2735
- x = _.node().getBBox().height, x <= 0 && (x = f / 2), v = m.insert("g").attr("class", "methods-group text");
2736
- let w = 0;
2737
- for (let e of l.methods) {
2738
- let l = await addText2(v, e, w, [e.parseClassifier()]);
2739
- w += l + p;
2740
- }
2741
- let T = m.node().getBBox();
2742
- if (h !== null) {
2743
- let e = h.node().getBBox();
2744
- h.attr("transform", `translate(${-e.width / 2})`);
2745
- }
2746
- return g.attr("transform", `translate(${-S.width / 2}, ${y})`), T = m.node().getBBox(), _.attr("transform", `translate(0, ${y + b + f * 2})`), T = m.node().getBBox(), v.attr("transform", `translate(0, ${y + b + (x ? x + f * 4 : f * 2)})`), T = m.node().getBBox(), {
2747
- shapeSvg: m,
2748
- bbox: T
2749
- };
2750
- }
2751
- __name(textHelper, "textHelper");
2752
- async function addText2(l, u, d, m = []) {
2753
- let g = l.insert("g").attr("class", "label").attr("style", m.join("; ")), _ = getConfig(), v = "useHtmlLabels" in u ? u.useHtmlLabels : evaluate(_.htmlLabels) ?? !0, x = "";
2754
- x = "text" in u ? u.text : u.label, !v && x.startsWith("\\") && (x = x.substring(1)), hasKatex(x) && (v = !0);
2755
- let S = await createText(g, sanitizeText3(decodeEntities(x)), {
2756
- width: calculateTextWidth(x, _) + 50,
2757
- classes: "markdown-node-label",
2758
- useHtmlLabels: v
2759
- }, _), C, w = 1;
2760
- if (v) {
2761
- let l = S.children[0], u = select_default(S);
2762
- w = l.innerHTML.split("<br>").length, l.innerHTML.includes("</math>") && (w += l.innerHTML.split("<mrow>").length - 1);
2763
- let d = l.getElementsByTagName("img");
2764
- if (d) {
2765
- let l = x.replace(/<img[^>]*>/g, "").trim() === "";
2766
- await Promise.all([...d].map((u) => new Promise((d) => {
2767
- function f() {
2768
- if (u.style.display = "flex", u.style.flexDirection = "column", l) {
2769
- let e = _.fontSize?.toString() ?? window.getComputedStyle(document.body).fontSize, l = parseInt(e, 10) * 5 + "px";
2770
- u.style.minWidth = l, u.style.maxWidth = l;
2771
- } else u.style.width = "100%";
2772
- d(u);
2773
- }
2774
- __name(f, "setupImage"), setTimeout(() => {
2775
- u.complete && f();
2776
- }), u.addEventListener("error", f), u.addEventListener("load", f);
2777
- })));
2778
- }
2779
- C = l.getBoundingClientRect(), u.attr("width", C.width), u.attr("height", C.height);
2780
- } else {
2781
- m.includes("font-weight: bolder") && select_default(S).selectAll("tspan").attr("font-weight", ""), w = S.children.length;
2782
- let e = S.children[0];
2783
- (S.textContent === "" || S.textContent.includes("&gt")) && (e.textContent = x[0] + x.substring(1).replaceAll("&gt;", ">").replaceAll("&lt;", "<").trim(), x[1] === " " && (e.textContent = e.textContent[0] + " " + e.textContent.substring(1))), e.textContent === "undefined" && (e.textContent = ""), C = S.getBBox();
2784
- }
2785
- return g.attr("transform", "translate(0," + (-C.height / (2 * w) + d) + ")"), C.height;
2786
- }
2787
- __name(addText2, "addText");
2788
- async function classBox(e, l) {
2789
- let u = getConfig2(), d = u.class.padding ?? 12, p = d, h = l.useHtmlLabels ?? evaluate(u.htmlLabels) ?? !0, g = l;
2790
- g.annotations = g.annotations ?? [], g.members = g.members ?? [], g.methods = g.methods ?? [];
2791
- let { shapeSvg: _, bbox: v } = await textHelper(e, l, u, h, p), { labelStyles: y, nodeStyles: x } = styles2String(l);
2792
- l.labelStyle = y, l.cssStyles = g.styles || "";
2793
- let S = g.styles?.join(";") || x || "";
2794
- l.cssStyles ||= S.replaceAll("!important", "").split(";");
2795
- let C = g.members.length === 0 && g.methods.length === 0 && !u.class?.hideEmptyMembersBox, E = at.svg(_), D = userNodeOverrides(l, {});
2796
- l.look !== "handDrawn" && (D.roughness = 0, D.fillStyle = "solid");
2797
- let O = v.width, k = v.height;
2798
- g.members.length === 0 && g.methods.length === 0 ? k += p : g.members.length > 0 && g.methods.length === 0 && (k += p * 2);
2799
- let A = -O / 2, j = -k / 2, M = E.rectangle(A - d, j - d - (C ? d : g.members.length === 0 && g.methods.length === 0 ? -d / 2 : 0), O + 2 * d, k + 2 * d + (C ? d * 2 : g.members.length === 0 && g.methods.length === 0 ? -d : 0), D), N = _.insert(() => M, ":first-child");
2800
- N.attr("class", "basic label-container");
2801
- let F = N.node().getBBox();
2802
- _.selectAll(".text").each((e, l, u) => {
2803
- let f = select_default(u[l]), p = f.attr("transform"), m = 0;
2804
- if (p) {
2805
- let e = RegExp(/translate\(([^,]+),([^)]+)\)/).exec(p);
2806
- e && (m = parseFloat(e[2]));
2807
- }
2808
- let v = m + j + d - (C ? d : g.members.length === 0 && g.methods.length === 0 ? -d / 2 : 0);
2809
- h || (v -= 4);
2810
- let y = A;
2811
- (f.attr("class").includes("label-group") || f.attr("class").includes("annotation-group")) && (y = -f.node()?.getBBox().width / 2 || 0, _.selectAll("text").each(function(e, l, u) {
2812
- window.getComputedStyle(u[l]).textAnchor === "middle" && (y = 0);
2813
- })), f.attr("transform", `translate(${y}, ${v})`);
2814
- });
2815
- let I = _.select(".annotation-group").node().getBBox().height - (C ? d / 2 : 0) || 0, L = _.select(".label-group").node().getBBox().height - (C ? d / 2 : 0) || 0, R = _.select(".members-group").node().getBBox().height - (C ? d / 2 : 0) || 0;
2816
- if (g.members.length > 0 || g.methods.length > 0 || C) {
2817
- let e = E.line(F.x, I + L + j + d, F.x + F.width, I + L + j + d, D);
2818
- _.insert(() => e).attr("class", "divider").attr("style", S);
2819
- }
2820
- if (C || g.members.length > 0 || g.methods.length > 0) {
2821
- let e = E.line(F.x, I + L + R + j + p * 2 + d, F.x + F.width, I + L + R + j + d + p * 2, D);
2822
- _.insert(() => e).attr("class", "divider").attr("style", S);
2823
- }
2824
- if (g.look !== "handDrawn" && _.selectAll("path").attr("style", S), N.select(":nth-child(2)").attr("style", S), _.selectAll(".divider").select("path").attr("style", S), l.labelStyle ? _.selectAll("span").attr("style", l.labelStyle) : _.selectAll("span").attr("style", S), !h) {
2825
- let e = RegExp(/color\s*:\s*([^;]*)/), l = e.exec(S);
2826
- if (l) {
2827
- let e = l[0].replace("color", "fill");
2828
- _.selectAll("tspan").attr("style", e);
2829
- } else if (y) {
2830
- let l = e.exec(y);
2831
- if (l) {
2832
- let e = l[0].replace("color", "fill");
2833
- _.selectAll("tspan").attr("style", e);
2834
- }
2835
- }
2836
- }
2837
- return updateNodeBounds(l, N), l.intersect = function(e) {
2838
- return intersect_default.rect(l, e);
2839
- }, _;
2840
- }
2841
- __name(classBox, "classBox");
2842
- async function requirementBox(e, l) {
2843
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
2844
- l.labelStyle = u;
2845
- let f = l, p = l, m = "verifyMethod" in l, h = getNodeClasses(l), g = e.insert("g").attr("class", h).attr("id", l.domId ?? l.id), _;
2846
- _ = m ? await addText3(g, `&lt;&lt;${f.type}&gt;&gt;`, 0, l.labelStyle) : await addText3(g, "&lt;&lt;Element&gt;&gt;", 0, l.labelStyle);
2847
- let v = _, y = await addText3(g, f.name, v, l.labelStyle + "; font-weight: bold;");
2848
- if (v += y + 20, m) {
2849
- let e = await addText3(g, `${f.requirementId ? `ID: ${f.requirementId}` : ""}`, v, l.labelStyle);
2850
- v += e;
2851
- let u = await addText3(g, `${f.text ? `Text: ${f.text}` : ""}`, v, l.labelStyle);
2852
- v += u;
2853
- let d = await addText3(g, `${f.risk ? `Risk: ${f.risk}` : ""}`, v, l.labelStyle);
2854
- v += d, await addText3(g, `${f.verifyMethod ? `Verification: ${f.verifyMethod}` : ""}`, v, l.labelStyle);
2855
- } else {
2856
- let e = await addText3(g, `${p.type ? `Type: ${p.type}` : ""}`, v, l.labelStyle);
2857
- v += e, await addText3(g, `${p.docRef ? `Doc Ref: ${p.docRef}` : ""}`, v, l.labelStyle);
2858
- }
2859
- let x = (g.node()?.getBBox().width ?? 200) + 20, S = (g.node()?.getBBox().height ?? 200) + 20, C = -x / 2, E = -S / 2, D = at.svg(g), O = userNodeOverrides(l, {});
2860
- l.look !== "handDrawn" && (O.roughness = 0, O.fillStyle = "solid");
2861
- let k = D.rectangle(C, E, x, S, O), A = g.insert(() => k, ":first-child");
2862
- if (A.attr("class", "basic label-container").attr("style", d), g.selectAll(".label").each((e, l, u) => {
2863
- let d = select_default(u[l]), f = d.attr("transform"), p = 0, m = 0;
2864
- if (f) {
2865
- let e = RegExp(/translate\(([^,]+),([^)]+)\)/).exec(f);
2866
- e && (p = parseFloat(e[1]), m = parseFloat(e[2]));
2867
- }
2868
- let h = m - S / 2, g = C + 20 / 2;
2869
- (l === 0 || l === 1) && (g = p), d.attr("transform", `translate(${g}, ${h + 20})`);
2870
- }), v > _ + y + 20) {
2871
- let e = D.line(C, E + _ + y + 20, C + x, E + _ + y + 20, O);
2872
- g.insert(() => e).attr("style", d);
2873
- }
2874
- return updateNodeBounds(l, A), l.intersect = function(e) {
2875
- return intersect_default.rect(l, e);
2876
- }, g;
2877
- }
2878
- __name(requirementBox, "requirementBox");
2879
- async function addText3(e, l, u, d = "") {
2880
- if (l === "") return 0;
2881
- let f = e.insert("g").attr("class", "label").attr("style", d), p = getConfig2(), h = p.htmlLabels ?? !0, g = await createText(f, sanitizeText3(decodeEntities(l)), {
2882
- width: calculateTextWidth(l, p) + 50,
2883
- classes: "markdown-node-label",
2884
- useHtmlLabels: h,
2885
- style: d
2886
- }, p), _;
2887
- if (h) {
2888
- let e = g.children[0], l = select_default(g);
2889
- _ = e.getBoundingClientRect(), l.attr("width", _.width), l.attr("height", _.height);
2890
- } else {
2891
- let e = g.children[0];
2892
- for (let l of e.children) l.textContent = l.textContent.replaceAll("&gt;", ">").replaceAll("&lt;", "<"), d && l.setAttribute("style", d);
2893
- _ = g.getBBox(), _.height += 6;
2894
- }
2895
- return f.attr("transform", `translate(${-_.width / 2},${-_.height / 2 + u})`), _.height;
2896
- }
2897
- __name(addText3, "addText");
2898
- var colorFromPriority = /* @__PURE__ */ __name((e) => {
2899
- switch (e) {
2900
- case "Very High": return "red";
2901
- case "High": return "orange";
2902
- case "Medium": return null;
2903
- case "Low": return "blue";
2904
- case "Very Low": return "lightblue";
2905
- }
2906
- }, "colorFromPriority");
2907
- async function kanbanItem(e, l, { config: u }) {
2908
- let { labelStyles: d, nodeStyles: f } = styles2String(l);
2909
- l.labelStyle = d || "";
2910
- let p = l.width;
2911
- l.width = (l.width ?? 200) - 10;
2912
- let { shapeSvg: m, bbox: h, label: g } = await labelHelper(e, l, getNodeClasses(l)), _ = l.padding || 10, v = "", y;
2913
- "ticket" in l && l.ticket && u?.kanban?.ticketBaseUrl && (v = u?.kanban?.ticketBaseUrl.replace("#TICKET#", l.ticket), y = m.insert("svg:a", ":first-child").attr("class", "kanban-ticket-link").attr("xlink:href", v).attr("target", "_blank"));
2914
- let b = {
2915
- useHtmlLabels: l.useHtmlLabels,
2916
- labelStyle: l.labelStyle || "",
2917
- width: l.width,
2918
- img: l.img,
2919
- padding: l.padding || 8,
2920
- centerLabel: !1
2921
- }, x, S;
2922
- y ? {label: x, bbox: S} = await insertLabel(y, "ticket" in l && l.ticket || "", b) : {label: x, bbox: S} = await insertLabel(m, "ticket" in l && l.ticket || "", b);
2923
- let { label: C, bbox: E } = await insertLabel(m, "assigned" in l && l.assigned || "", b);
2924
- l.width = p;
2925
- let D = l?.width || 0, O = Math.max(S.height, E.height) / 2, k = Math.max(h.height + 20, l?.height || 0) + O, A = -D / 2, j = -k / 2;
2926
- g.attr("transform", "translate(" + (_ - D / 2) + ", " + (-O - h.height / 2) + ")"), x.attr("transform", "translate(" + (_ - D / 2) + ", " + (-O + h.height / 2) + ")"), C.attr("transform", "translate(" + (_ + D / 2 - E.width - 20) + ", " + (-O + h.height / 2) + ")");
2927
- let I, { rx: L, ry: R } = l, { cssStyles: z } = l;
2928
- if (l.look === "handDrawn") {
2929
- let e = at.svg(m), u = userNodeOverrides(l, {}), d = L || R ? e.path(createRoundedRectPathD(A, j, D, k, L || 0), u) : e.rectangle(A, j, D, k, u);
2930
- I = m.insert(() => d, ":first-child"), I.attr("class", "basic label-container").attr("style", z || null);
2931
- } else {
2932
- I = m.insert("rect", ":first-child"), I.attr("class", "basic label-container __APA__").attr("style", f).attr("rx", L ?? 5).attr("ry", R ?? 5).attr("x", A).attr("y", j).attr("width", D).attr("height", k);
2933
- let e = "priority" in l && l.priority;
2934
- if (e) {
2935
- let l = m.append("line"), u = A + 2, d = j + Math.floor((L ?? 0) / 2), f = j + k - Math.floor((L ?? 0) / 2);
2936
- l.attr("x1", u).attr("y1", d).attr("x2", u).attr("y2", f).attr("stroke-width", "4").attr("stroke", colorFromPriority(e));
2937
- }
2938
- }
2939
- return updateNodeBounds(l, I), l.height = k, l.intersect = function(e) {
2940
- return intersect_default.rect(l, e);
2941
- }, m;
2942
- }
2943
- __name(kanbanItem, "kanbanItem");
2944
- async function bang(e, u) {
2945
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
2946
- u.labelStyle = d;
2947
- let { shapeSvg: p, bbox: m, halfPadding: h, label: g } = await labelHelper(e, u, getNodeClasses(u)), _ = m.width + 10 * h, v = m.height + 8 * h, y = .15 * _, { cssStyles: b } = u, x = m.width + 20, S = m.height + 20, C = Math.max(_, x), E = Math.max(v, S);
2948
- g.attr("transform", `translate(${-m.width / 2}, ${-m.height / 2})`);
2949
- let D, k = `M0 0
2950
- a${y},${y} 1 0,0 ${C * .25},${-1 * E * .1}
2951
- a${y},${y} 1 0,0 ${C * .25},0
2952
- a${y},${y} 1 0,0 ${C * .25},0
2953
- a${y},${y} 1 0,0 ${C * .25},${E * .1}
2954
-
2955
- a${y},${y} 1 0,0 ${C * .15},${E * .33}
2956
- a${y * .8},${y * .8} 1 0,0 0,${E * .34}
2957
- a${y},${y} 1 0,0 ${-1 * C * .15},${E * .33}
2958
-
2959
- a${y},${y} 1 0,0 ${-1 * C * .25},${E * .15}
2960
- a${y},${y} 1 0,0 ${-1 * C * .25},0
2961
- a${y},${y} 1 0,0 ${-1 * C * .25},0
2962
- a${y},${y} 1 0,0 ${-1 * C * .25},${-1 * E * .15}
2963
-
2964
- a${y},${y} 1 0,0 ${-1 * C * .1},${-1 * E * .33}
2965
- a${y * .8},${y * .8} 1 0,0 0,${-1 * E * .34}
2966
- a${y},${y} 1 0,0 ${C * .1},${-1 * E * .33}
2967
- H0 V0 Z`;
2968
- if (u.look === "handDrawn") {
2969
- let e = at.svg(p), l = userNodeOverrides(u, {}), d = e.path(k, l);
2970
- D = p.insert(() => d, ":first-child"), D.attr("class", "basic label-container").attr("style", handleUndefinedAttr(b));
2971
- } else D = p.insert("path", ":first-child").attr("class", "basic label-container").attr("style", f).attr("d", k);
2972
- return D.attr("transform", `translate(${-C / 2}, ${-E / 2})`), updateNodeBounds(u, D), u.calcIntersect = function(e, l) {
2973
- return intersect_default.rect(e, l);
2974
- }, u.intersect = function(e) {
2975
- return log.info("Bang intersect", u, e), intersect_default.rect(u, e);
2976
- }, p;
2977
- }
2978
- __name(bang, "bang");
2979
- async function cloud(e, u) {
2980
- let { labelStyles: d, nodeStyles: f } = styles2String(u);
2981
- u.labelStyle = d;
2982
- let { shapeSvg: p, bbox: m, halfPadding: h, label: g } = await labelHelper(e, u, getNodeClasses(u)), _ = m.width + 2 * h, v = m.height + 2 * h, y = .15 * _, b = .25 * _, x = .35 * _, S = .2 * _, { cssStyles: C } = u, E, D = `M0 0
2983
- a${y},${y} 0 0,1 ${_ * .25},${-1 * _ * .1}
2984
- a${x},${x} 1 0,1 ${_ * .4},${-1 * _ * .1}
2985
- a${b},${b} 1 0,1 ${_ * .35},${_ * .2}
2986
-
2987
- a${y},${y} 1 0,1 ${_ * .15},${v * .35}
2988
- a${S},${S} 1 0,1 ${-1 * _ * .15},${v * .65}
2989
-
2990
- a${b},${y} 1 0,1 ${-1 * _ * .25},${_ * .15}
2991
- a${x},${x} 1 0,1 ${-1 * _ * .5},0
2992
- a${y},${y} 1 0,1 ${-1 * _ * .25},${-1 * _ * .15}
2993
-
2994
- a${y},${y} 1 0,1 ${-1 * _ * .1},${-1 * v * .35}
2995
- a${S},${S} 1 0,1 ${_ * .1},${-1 * v * .65}
2996
- H0 V0 Z`;
2997
- if (u.look === "handDrawn") {
2998
- let e = at.svg(p), l = userNodeOverrides(u, {}), d = e.path(D, l);
2999
- E = p.insert(() => d, ":first-child"), E.attr("class", "basic label-container").attr("style", handleUndefinedAttr(C));
3000
- } else E = p.insert("path", ":first-child").attr("class", "basic label-container").attr("style", f).attr("d", D);
3001
- return g.attr("transform", `translate(${-m.width / 2}, ${-m.height / 2})`), E.attr("transform", `translate(${-_ / 2}, ${-v / 2})`), updateNodeBounds(u, E), u.calcIntersect = function(e, l) {
3002
- return intersect_default.rect(e, l);
3003
- }, u.intersect = function(e) {
3004
- return log.info("Cloud intersect", u, e), intersect_default.rect(u, e);
3005
- }, p;
3006
- }
3007
- __name(cloud, "cloud");
3008
- async function defaultMindmapNode(e, l) {
3009
- let { labelStyles: u, nodeStyles: d } = styles2String(l);
3010
- l.labelStyle = u;
3011
- let { shapeSvg: f, bbox: p, halfPadding: m, label: h } = await labelHelper(e, l, getNodeClasses(l)), g = p.width + 8 * m, _ = p.height + 2 * m, v = `
3012
- M${-g / 2} ${_ / 2 - 5}
3013
- v${-_ + 10}
3014
- q0,-5 5,-5
3015
- h${g - 10}
3016
- q5,0 5,5
3017
- v${_ - 10}
3018
- q0,5 -5,5
3019
- h${-g + 10}
3020
- q-5,0 -5,-5
3021
- Z
3022
- `, y = f.append("path").attr("id", "node-" + l.id).attr("class", "node-bkg node-" + l.type).attr("style", d).attr("d", v);
3023
- return f.append("line").attr("class", "node-line-").attr("x1", -g / 2).attr("y1", _ / 2).attr("x2", g / 2).attr("y2", _ / 2), h.attr("transform", `translate(${-p.width / 2}, ${-p.height / 2})`), f.append(() => h.node()), updateNodeBounds(l, y), l.calcIntersect = function(e, l) {
3024
- return intersect_default.rect(e, l);
3025
- }, l.intersect = function(e) {
3026
- return intersect_default.rect(l, e);
3027
- }, f;
3028
- }
3029
- __name(defaultMindmapNode, "defaultMindmapNode");
3030
- async function mindmapCircle(e, l) {
3031
- return circle(e, l, { padding: l.padding ?? 0 });
3032
- }
3033
- __name(mindmapCircle, "mindmapCircle");
3034
- var shapesDefs = [
3035
- {
3036
- semanticName: "Process",
3037
- name: "Rectangle",
3038
- shortName: "rect",
3039
- description: "Standard process shape",
3040
- aliases: [
3041
- "proc",
3042
- "process",
3043
- "rectangle"
3044
- ],
3045
- internalAliases: ["squareRect"],
3046
- handler: squareRect2
3047
- },
3048
- {
3049
- semanticName: "Event",
3050
- name: "Rounded Rectangle",
3051
- shortName: "rounded",
3052
- description: "Represents an event",
3053
- aliases: ["event"],
3054
- internalAliases: ["roundedRect"],
3055
- handler: roundedRect
3056
- },
3057
- {
3058
- semanticName: "Terminal Point",
3059
- name: "Stadium",
3060
- shortName: "stadium",
3061
- description: "Terminal point",
3062
- aliases: ["terminal", "pill"],
3063
- handler: stadium
3064
- },
3065
- {
3066
- semanticName: "Subprocess",
3067
- name: "Framed Rectangle",
3068
- shortName: "fr-rect",
3069
- description: "Subprocess",
3070
- aliases: [
3071
- "subprocess",
3072
- "subproc",
3073
- "framed-rectangle",
3074
- "subroutine"
3075
- ],
3076
- handler: subroutine
3077
- },
3078
- {
3079
- semanticName: "Database",
3080
- name: "Cylinder",
3081
- shortName: "cyl",
3082
- description: "Database storage",
3083
- aliases: [
3084
- "db",
3085
- "database",
3086
- "cylinder"
3087
- ],
3088
- handler: cylinder
3089
- },
3090
- {
3091
- semanticName: "Start",
3092
- name: "Circle",
3093
- shortName: "circle",
3094
- description: "Starting point",
3095
- aliases: ["circ"],
3096
- handler: circle
3097
- },
3098
- {
3099
- semanticName: "Bang",
3100
- name: "Bang",
3101
- shortName: "bang",
3102
- description: "Bang",
3103
- aliases: ["bang"],
3104
- handler: bang
3105
- },
3106
- {
3107
- semanticName: "Cloud",
3108
- name: "Cloud",
3109
- shortName: "cloud",
3110
- description: "cloud",
3111
- aliases: ["cloud"],
3112
- handler: cloud
3113
- },
3114
- {
3115
- semanticName: "Decision",
3116
- name: "Diamond",
3117
- shortName: "diam",
3118
- description: "Decision-making step",
3119
- aliases: [
3120
- "decision",
3121
- "diamond",
3122
- "question"
3123
- ],
3124
- handler: question
3125
- },
3126
- {
3127
- semanticName: "Prepare Conditional",
3128
- name: "Hexagon",
3129
- shortName: "hex",
3130
- description: "Preparation or condition step",
3131
- aliases: ["hexagon", "prepare"],
3132
- handler: hexagon
3133
- },
3134
- {
3135
- semanticName: "Data Input/Output",
3136
- name: "Lean Right",
3137
- shortName: "lean-r",
3138
- description: "Represents input or output",
3139
- aliases: ["lean-right", "in-out"],
3140
- internalAliases: ["lean_right"],
3141
- handler: lean_right
3142
- },
3143
- {
3144
- semanticName: "Data Input/Output",
3145
- name: "Lean Left",
3146
- shortName: "lean-l",
3147
- description: "Represents output or input",
3148
- aliases: ["lean-left", "out-in"],
3149
- internalAliases: ["lean_left"],
3150
- handler: lean_left
3151
- },
3152
- {
3153
- semanticName: "Priority Action",
3154
- name: "Trapezoid Base Bottom",
3155
- shortName: "trap-b",
3156
- description: "Priority action",
3157
- aliases: [
3158
- "priority",
3159
- "trapezoid-bottom",
3160
- "trapezoid"
3161
- ],
3162
- handler: trapezoid
3163
- },
3164
- {
3165
- semanticName: "Manual Operation",
3166
- name: "Trapezoid Base Top",
3167
- shortName: "trap-t",
3168
- description: "Represents a manual task",
3169
- aliases: [
3170
- "manual",
3171
- "trapezoid-top",
3172
- "inv-trapezoid"
3173
- ],
3174
- internalAliases: ["inv_trapezoid"],
3175
- handler: inv_trapezoid
3176
- },
3177
- {
3178
- semanticName: "Stop",
3179
- name: "Double Circle",
3180
- shortName: "dbl-circ",
3181
- description: "Represents a stop point",
3182
- aliases: ["double-circle"],
3183
- internalAliases: ["doublecircle"],
3184
- handler: doublecircle
3185
- },
3186
- {
3187
- semanticName: "Text Block",
3188
- name: "Text Block",
3189
- shortName: "text",
3190
- description: "Text block",
3191
- handler: text
3192
- },
3193
- {
3194
- semanticName: "Card",
3195
- name: "Notched Rectangle",
3196
- shortName: "notch-rect",
3197
- description: "Represents a card",
3198
- aliases: ["card", "notched-rectangle"],
3199
- handler: card
3200
- },
3201
- {
3202
- semanticName: "Lined/Shaded Process",
3203
- name: "Lined Rectangle",
3204
- shortName: "lin-rect",
3205
- description: "Lined process shape",
3206
- aliases: [
3207
- "lined-rectangle",
3208
- "lined-process",
3209
- "lin-proc",
3210
- "shaded-process"
3211
- ],
3212
- handler: shadedProcess
3213
- },
3214
- {
3215
- semanticName: "Start",
3216
- name: "Small Circle",
3217
- shortName: "sm-circ",
3218
- description: "Small starting point",
3219
- aliases: ["start", "small-circle"],
3220
- internalAliases: ["stateStart"],
3221
- handler: stateStart
3222
- },
3223
- {
3224
- semanticName: "Stop",
3225
- name: "Framed Circle",
3226
- shortName: "fr-circ",
3227
- description: "Stop point",
3228
- aliases: ["stop", "framed-circle"],
3229
- internalAliases: ["stateEnd"],
3230
- handler: stateEnd
3231
- },
3232
- {
3233
- semanticName: "Fork/Join",
3234
- name: "Filled Rectangle",
3235
- shortName: "fork",
3236
- description: "Fork or join in process flow",
3237
- aliases: ["join"],
3238
- internalAliases: ["forkJoin"],
3239
- handler: forkJoin
3240
- },
3241
- {
3242
- semanticName: "Collate",
3243
- name: "Hourglass",
3244
- shortName: "hourglass",
3245
- description: "Represents a collate operation",
3246
- aliases: ["hourglass", "collate"],
3247
- handler: hourglass
3248
- },
3249
- {
3250
- semanticName: "Comment",
3251
- name: "Curly Brace",
3252
- shortName: "brace",
3253
- description: "Adds a comment",
3254
- aliases: ["comment", "brace-l"],
3255
- handler: curlyBraceLeft
3256
- },
3257
- {
3258
- semanticName: "Comment Right",
3259
- name: "Curly Brace",
3260
- shortName: "brace-r",
3261
- description: "Adds a comment",
3262
- handler: curlyBraceRight
3263
- },
3264
- {
3265
- semanticName: "Comment with braces on both sides",
3266
- name: "Curly Braces",
3267
- shortName: "braces",
3268
- description: "Adds a comment",
3269
- handler: curlyBraces
3270
- },
3271
- {
3272
- semanticName: "Com Link",
3273
- name: "Lightning Bolt",
3274
- shortName: "bolt",
3275
- description: "Communication link",
3276
- aliases: ["com-link", "lightning-bolt"],
3277
- handler: lightningBolt
3278
- },
3279
- {
3280
- semanticName: "Document",
3281
- name: "Document",
3282
- shortName: "doc",
3283
- description: "Represents a document",
3284
- aliases: ["doc", "document"],
3285
- handler: waveEdgedRectangle
3286
- },
3287
- {
3288
- semanticName: "Delay",
3289
- name: "Half-Rounded Rectangle",
3290
- shortName: "delay",
3291
- description: "Represents a delay",
3292
- aliases: ["half-rounded-rectangle"],
3293
- handler: halfRoundedRectangle
3294
- },
3295
- {
3296
- semanticName: "Direct Access Storage",
3297
- name: "Horizontal Cylinder",
3298
- shortName: "h-cyl",
3299
- description: "Direct access storage",
3300
- aliases: ["das", "horizontal-cylinder"],
3301
- handler: tiltedCylinder
3302
- },
3303
- {
3304
- semanticName: "Disk Storage",
3305
- name: "Lined Cylinder",
3306
- shortName: "lin-cyl",
3307
- description: "Disk storage",
3308
- aliases: ["disk", "lined-cylinder"],
3309
- handler: linedCylinder
3310
- },
3311
- {
3312
- semanticName: "Display",
3313
- name: "Curved Trapezoid",
3314
- shortName: "curv-trap",
3315
- description: "Represents a display",
3316
- aliases: ["curved-trapezoid", "display"],
3317
- handler: curvedTrapezoid
3318
- },
3319
- {
3320
- semanticName: "Divided Process",
3321
- name: "Divided Rectangle",
3322
- shortName: "div-rect",
3323
- description: "Divided process shape",
3324
- aliases: [
3325
- "div-proc",
3326
- "divided-rectangle",
3327
- "divided-process"
3328
- ],
3329
- handler: dividedRectangle
3330
- },
3331
- {
3332
- semanticName: "Extract",
3333
- name: "Triangle",
3334
- shortName: "tri",
3335
- description: "Extraction process",
3336
- aliases: ["extract", "triangle"],
3337
- handler: triangle
3338
- },
3339
- {
3340
- semanticName: "Internal Storage",
3341
- name: "Window Pane",
3342
- shortName: "win-pane",
3343
- description: "Internal storage",
3344
- aliases: ["internal-storage", "window-pane"],
3345
- handler: windowPane
3346
- },
3347
- {
3348
- semanticName: "Junction",
3349
- name: "Filled Circle",
3350
- shortName: "f-circ",
3351
- description: "Junction point",
3352
- aliases: ["junction", "filled-circle"],
3353
- handler: filledCircle
3354
- },
3355
- {
3356
- semanticName: "Loop Limit",
3357
- name: "Trapezoidal Pentagon",
3358
- shortName: "notch-pent",
3359
- description: "Loop limit step",
3360
- aliases: ["loop-limit", "notched-pentagon"],
3361
- handler: trapezoidalPentagon
3362
- },
3363
- {
3364
- semanticName: "Manual File",
3365
- name: "Flipped Triangle",
3366
- shortName: "flip-tri",
3367
- description: "Manual file operation",
3368
- aliases: ["manual-file", "flipped-triangle"],
3369
- handler: flippedTriangle
3370
- },
3371
- {
3372
- semanticName: "Manual Input",
3373
- name: "Sloped Rectangle",
3374
- shortName: "sl-rect",
3375
- description: "Manual input step",
3376
- aliases: ["manual-input", "sloped-rectangle"],
3377
- handler: slopedRect
3378
- },
3379
- {
3380
- semanticName: "Multi-Document",
3381
- name: "Stacked Document",
3382
- shortName: "docs",
3383
- description: "Multiple documents",
3384
- aliases: [
3385
- "documents",
3386
- "st-doc",
3387
- "stacked-document"
3388
- ],
3389
- handler: multiWaveEdgedRectangle
3390
- },
3391
- {
3392
- semanticName: "Multi-Process",
3393
- name: "Stacked Rectangle",
3394
- shortName: "st-rect",
3395
- description: "Multiple processes",
3396
- aliases: [
3397
- "procs",
3398
- "processes",
3399
- "stacked-rectangle"
3400
- ],
3401
- handler: multiRect
3402
- },
3403
- {
3404
- semanticName: "Stored Data",
3405
- name: "Bow Tie Rectangle",
3406
- shortName: "bow-rect",
3407
- description: "Stored data",
3408
- aliases: ["stored-data", "bow-tie-rectangle"],
3409
- handler: bowTieRect
3410
- },
3411
- {
3412
- semanticName: "Summary",
3413
- name: "Crossed Circle",
3414
- shortName: "cross-circ",
3415
- description: "Summary",
3416
- aliases: ["summary", "crossed-circle"],
3417
- handler: crossedCircle
3418
- },
3419
- {
3420
- semanticName: "Tagged Document",
3421
- name: "Tagged Document",
3422
- shortName: "tag-doc",
3423
- description: "Tagged document",
3424
- aliases: ["tag-doc", "tagged-document"],
3425
- handler: taggedWaveEdgedRectangle
3426
- },
3427
- {
3428
- semanticName: "Tagged Process",
3429
- name: "Tagged Rectangle",
3430
- shortName: "tag-rect",
3431
- description: "Tagged process",
3432
- aliases: [
3433
- "tagged-rectangle",
3434
- "tag-proc",
3435
- "tagged-process"
3436
- ],
3437
- handler: taggedRect
3438
- },
3439
- {
3440
- semanticName: "Paper Tape",
3441
- name: "Flag",
3442
- shortName: "flag",
3443
- description: "Paper tape",
3444
- aliases: ["paper-tape"],
3445
- handler: waveRectangle
3446
- },
3447
- {
3448
- semanticName: "Odd",
3449
- name: "Odd",
3450
- shortName: "odd",
3451
- description: "Odd shape",
3452
- internalAliases: ["rect_left_inv_arrow"],
3453
- handler: rect_left_inv_arrow
3454
- },
3455
- {
3456
- semanticName: "Lined Document",
3457
- name: "Lined Document",
3458
- shortName: "lin-doc",
3459
- description: "Lined document",
3460
- aliases: ["lined-document"],
3461
- handler: linedWaveEdgedRect
3462
- }
3463
- ], shapes2 = (/* @__PURE__ */ __name(() => {
3464
- let e = {
3465
- state,
3466
- choice,
3467
- note,
3468
- rectWithTitle,
3469
- labelRect,
3470
- iconSquare,
3471
- iconCircle,
3472
- icon,
3473
- iconRounded,
3474
- imageSquare,
3475
- anchor,
3476
- kanbanItem,
3477
- mindmapCircle,
3478
- defaultMindmapNode,
3479
- classBox,
3480
- erBox,
3481
- requirementBox
3482
- }, l = [...Object.entries(e), ...shapesDefs.flatMap((e) => [
3483
- e.shortName,
3484
- ..."aliases" in e ? e.aliases : [],
3485
- ..."internalAliases" in e ? e.internalAliases : []
3486
- ].map((l) => [l, e.handler]))];
3487
- return Object.fromEntries(l);
3488
- }, "generateShapeMap"))();
3489
- function isValidShape(e) {
3490
- return e in shapes2;
3491
- }
3492
- __name(isValidShape, "isValidShape");
3493
- var nodeElems = /* @__PURE__ */ new Map();
3494
- async function insertNode(e, l, u) {
3495
- let d, f;
3496
- l.shape === "rect" && (l.rx && l.ry ? l.shape = "roundedRect" : l.shape = "squareRect");
3497
- let p = l.shape ? shapes2[l.shape] : void 0;
3498
- if (!p) throw Error(`No such shape: ${l.shape}. Please check your syntax.`);
3499
- if (l.link) {
3500
- let m;
3501
- u.config.securityLevel === "sandbox" ? m = "_top" : l.linkTarget && (m = l.linkTarget || "_blank"), d = e.insert("svg:a").attr("xlink:href", l.link).attr("target", m ?? null), f = await p(d, l, u);
3502
- } else f = await p(e, l, u), d = f;
3503
- return l.tooltip && f.attr("title", l.tooltip), nodeElems.set(l.id, d), l.haveCallback && d.attr("class", d.attr("class") + " clickable"), d;
3504
- }
3505
- __name(insertNode, "insertNode");
3506
- var setNodeElem = /* @__PURE__ */ __name((e, l) => {
3507
- nodeElems.set(l.id, e);
3508
- }, "setNodeElem"), clear2 = /* @__PURE__ */ __name(() => {
3509
- nodeElems.clear();
3510
- }, "clear"), positionNode = /* @__PURE__ */ __name((e) => {
3511
- let u = nodeElems.get(e.id);
3512
- log.trace("Transforming node", e.diff, e, "translate(" + (e.x - e.width / 2 - 5) + ", " + e.width / 2 + ")");
3513
- let d = e.diff || 0;
3514
- return e.clusterNode ? u.attr("transform", "translate(" + (e.x + d - e.width / 2) + ", " + (e.y - e.height / 2 - 8) + ")") : u.attr("transform", "translate(" + e.x + ", " + e.y + ")"), d;
3515
- }, "positionNode");
3516
- export { clear, clear2, createLabel_default, insertCluster, insertNode, isValidShape, labelHelper, positionNode, setNodeElem, updateNodeBounds };