hexagon-editor 0.1.0-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (308) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +105 -0
  3. package/THIRD_PARTY_NOTICES.md +29 -0
  4. package/dist/MarkdownEditor.vue.d.ts +926 -0
  5. package/dist/MarkdownEditor.vue.d.ts.map +1 -0
  6. package/dist/MarkdownEditorLinkForm-mq-BVYM_.js +338 -0
  7. package/dist/MarkdownEditorLinkForm.css +1 -0
  8. package/dist/abnfDiagram-N423BO3Z-DCf6sPky.js +87 -0
  9. package/dist/arc-y6UeoJpJ.js +83 -0
  10. package/dist/architectureDiagram-T3A2C74G-Cc3_3-cI.js +4778 -0
  11. package/dist/base-Bnv2-Te4.js +13338 -0
  12. package/dist/base.css +1 -0
  13. package/dist/blockDiagram-VBNYF7ZC-DWVLZwXY.js +2419 -0
  14. package/dist/c4Diagram-5PPSVZJV-CaIN7qay.js +1577 -0
  15. package/dist/channel-BwXGcavV.js +5 -0
  16. package/dist/chunk-2GRJ4B5K-O75udjPr.js +68 -0
  17. package/dist/chunk-2Q5K7J3B-CySL0lOA.js +15 -0
  18. package/dist/chunk-5RXB4S5H-BKPnLCOJ.js +1408 -0
  19. package/dist/chunk-5VM5RSS4--it1VJIv.js +19 -0
  20. package/dist/chunk-6Q2QTUOP-DNiML-50.js +664 -0
  21. package/dist/chunk-GF5L2VYU-z7A-k0-V.js +1533 -0
  22. package/dist/chunk-JWPE2WC7-DAjx3Kjr.js +8 -0
  23. package/dist/chunk-KBJHAD2P-D4R1VW0r.js +19 -0
  24. package/dist/chunk-RYQCIY6F-DmJAYxq8.js +313 -0
  25. package/dist/chunk-XXDRQBXY-CK913N-t.js +8 -0
  26. package/dist/classDiagram-JCYQIIEL-Djipq_HJ.js +16 -0
  27. package/dist/classDiagram-v2-OCEON4UE-Djipq_HJ.js +16 -0
  28. package/dist/classname.d.ts +13 -0
  29. package/dist/classname.d.ts.map +1 -0
  30. package/dist/classname.js +17 -0
  31. package/dist/components/MarkdownEditorFloatingMenus.vue.d.ts +48 -0
  32. package/dist/components/MarkdownEditorFloatingMenus.vue.d.ts.map +1 -0
  33. package/dist/components/MarkdownEditorImageActions.vue.d.ts +20 -0
  34. package/dist/components/MarkdownEditorImageActions.vue.d.ts.map +1 -0
  35. package/dist/components/MarkdownEditorToolbar.vue.d.ts +62 -0
  36. package/dist/components/MarkdownEditorToolbar.vue.d.ts.map +1 -0
  37. package/dist/components/MarkdownEditorToolbarIcon.vue.d.ts +26 -0
  38. package/dist/components/MarkdownEditorToolbarIcon.vue.d.ts.map +1 -0
  39. package/dist/composables/useFloatingPanel.d.ts +13 -0
  40. package/dist/composables/useFloatingPanel.d.ts.map +1 -0
  41. package/dist/composables/useMarkdownEditorValue.d.ts +19 -0
  42. package/dist/composables/useMarkdownEditorValue.d.ts.map +1 -0
  43. package/dist/configure.d.ts +15 -0
  44. package/dist/configure.d.ts.map +1 -0
  45. package/dist/configure.js +19 -0
  46. package/dist/core/actions.d.ts +16 -0
  47. package/dist/core/actions.d.ts.map +1 -0
  48. package/dist/core/basic-editor-atomic-source.d.ts +9 -0
  49. package/dist/core/basic-editor-atomic-source.d.ts.map +1 -0
  50. package/dist/core/basic-editor-command-helpers.d.ts +11 -0
  51. package/dist/core/basic-editor-command-helpers.d.ts.map +1 -0
  52. package/dist/core/basic-editor-markdown.d.ts +7 -0
  53. package/dist/core/basic-editor-markdown.d.ts.map +1 -0
  54. package/dist/core/basic-editor-renderers.d.ts +6 -0
  55. package/dist/core/basic-editor-renderers.d.ts.map +1 -0
  56. package/dist/core/basic-editor-runtime-plugins.d.ts +7 -0
  57. package/dist/core/basic-editor-runtime-plugins.d.ts.map +1 -0
  58. package/dist/core/basic-editor-selection.d.ts +6 -0
  59. package/dist/core/basic-editor-selection.d.ts.map +1 -0
  60. package/dist/core/basic-editor-table-controls.d.ts +3 -0
  61. package/dist/core/basic-editor-table-controls.d.ts.map +1 -0
  62. package/dist/core/basic-editor-table-popover.d.ts +5 -0
  63. package/dist/core/basic-editor-table-popover.d.ts.map +1 -0
  64. package/dist/core/basic-editor-types.d.ts +96 -0
  65. package/dist/core/basic-editor-types.d.ts.map +1 -0
  66. package/dist/core/basic-editor.d.ts +14 -0
  67. package/dist/core/basic-editor.d.ts.map +1 -0
  68. package/dist/core/content-handler.d.ts +21 -0
  69. package/dist/core/content-handler.d.ts.map +1 -0
  70. package/dist/core/editor-instance.d.ts +38 -0
  71. package/dist/core/editor-instance.d.ts.map +1 -0
  72. package/dist/core/events.d.ts +22 -0
  73. package/dist/core/events.d.ts.map +1 -0
  74. package/dist/core/extension-builder.d.ts +86 -0
  75. package/dist/core/extension-builder.d.ts.map +1 -0
  76. package/dist/core/extensions-manager.d.ts +36 -0
  77. package/dist/core/extensions-manager.d.ts.map +1 -0
  78. package/dist/core/index.d.ts +30 -0
  79. package/dist/core/index.d.ts.map +1 -0
  80. package/dist/core/lists.d.ts +18 -0
  81. package/dist/core/lists.d.ts.map +1 -0
  82. package/dist/core/logger.d.ts +46 -0
  83. package/dist/core/logger.d.ts.map +1 -0
  84. package/dist/core/markdown-parser.d.ts +60 -0
  85. package/dist/core/markdown-parser.d.ts.map +1 -0
  86. package/dist/core/markdown.d.ts +23 -0
  87. package/dist/core/markdown.d.ts.map +1 -0
  88. package/dist/core/markup-editor.d.ts +22 -0
  89. package/dist/core/markup-editor.d.ts.map +1 -0
  90. package/dist/core/optional-renderers.d.ts +9 -0
  91. package/dist/core/optional-renderers.d.ts.map +1 -0
  92. package/dist/core/registries.d.ts +50 -0
  93. package/dist/core/registries.d.ts.map +1 -0
  94. package/dist/core/schema-dynamic-modifier.d.ts +13 -0
  95. package/dist/core/schema-dynamic-modifier.d.ts.map +1 -0
  96. package/dist/core/vue-renderer.d.ts +40 -0
  97. package/dist/core/vue-renderer.d.ts.map +1 -0
  98. package/dist/core.js +46 -0
  99. package/dist/cose-bilkent-JH36ORCC-CXuKFbXy.js +2608 -0
  100. package/dist/cynefin-VYW2F7L2-Bkk-F_Js.js +23766 -0
  101. package/dist/cynefinDiagram-MW4NZA55-DwOK40hm.js +299 -0
  102. package/dist/cytoscape.esm-3W4EOjxC.js +18756 -0
  103. package/dist/dagre-VZM6K2ZE-0VsGm8Ag.js +340 -0
  104. package/dist/defaultLocale-BgPVtth8.js +171 -0
  105. package/dist/diagram-7IWD3JNH-BrApu1hz.js +350 -0
  106. package/dist/diagram-B4RE2ZJO-CVXoBg2r.js +461 -0
  107. package/dist/diagram-LBJQPF4R-Dp0eSz2L.js +142 -0
  108. package/dist/diagram-Q27KOJAE-DWIltqIH.js +528 -0
  109. package/dist/diagram-UB23O5K3-B7z2Lj3K.js +219 -0
  110. package/dist/directives.d.ts +10 -0
  111. package/dist/directives.d.ts.map +1 -0
  112. package/dist/ebnfDiagram-BXEA7PRR-CYgE6z_2.js +109 -0
  113. package/dist/erDiagram-JOGREHBK-D3QWrPo-.js +910 -0
  114. package/dist/extensions/additional/folding-heading.d.ts +11 -0
  115. package/dist/extensions/additional/folding-heading.d.ts.map +1 -0
  116. package/dist/extensions/additional/math.d.ts +36 -0
  117. package/dist/extensions/additional/math.d.ts.map +1 -0
  118. package/dist/extensions/additional/mermaid.d.ts +21 -0
  119. package/dist/extensions/additional/mermaid.d.ts.map +1 -0
  120. package/dist/extensions/additional/quote-link.d.ts +19 -0
  121. package/dist/extensions/additional/quote-link.d.ts.map +1 -0
  122. package/dist/extensions/additional/yfm-html-block.d.ts +21 -0
  123. package/dist/extensions/additional/yfm-html-block.d.ts.map +1 -0
  124. package/dist/extensions/base.d.ts +9 -0
  125. package/dist/extensions/base.d.ts.map +1 -0
  126. package/dist/extensions/behavior/clicks-on-edges.d.ts +12 -0
  127. package/dist/extensions/behavior/clicks-on-edges.d.ts.map +1 -0
  128. package/dist/extensions/behavior/clipboard.d.ts +6 -0
  129. package/dist/extensions/behavior/clipboard.d.ts.map +1 -0
  130. package/dist/extensions/behavior/cursor.d.ts +29 -0
  131. package/dist/extensions/behavior/cursor.d.ts.map +1 -0
  132. package/dist/extensions/behavior/editor-mode-keymap.d.ts +8 -0
  133. package/dist/extensions/behavior/editor-mode-keymap.d.ts.map +1 -0
  134. package/dist/extensions/behavior/history.d.ts +21 -0
  135. package/dist/extensions/behavior/history.d.ts.map +1 -0
  136. package/dist/extensions/behavior/placeholder.d.ts +11 -0
  137. package/dist/extensions/behavior/placeholder.d.ts.map +1 -0
  138. package/dist/extensions/behavior/resizable.d.ts +4 -0
  139. package/dist/extensions/behavior/resizable.d.ts.map +1 -0
  140. package/dist/extensions/behavior/selection-commands.d.ts +24 -0
  141. package/dist/extensions/behavior/selection-commands.d.ts.map +1 -0
  142. package/dist/extensions/behavior/selection-context.d.ts +9 -0
  143. package/dist/extensions/behavior/selection-context.d.ts.map +1 -0
  144. package/dist/extensions/behavior/selection.d.ts +12 -0
  145. package/dist/extensions/behavior/selection.d.ts.map +1 -0
  146. package/dist/extensions/index.d.ts +34 -0
  147. package/dist/extensions/index.d.ts.map +1 -0
  148. package/dist/extensions/markdown/blockquote-specs.d.ts +15 -0
  149. package/dist/extensions/markdown/blockquote-specs.d.ts.map +1 -0
  150. package/dist/extensions/markdown/blockquote.d.ts +14 -0
  151. package/dist/extensions/markdown/blockquote.d.ts.map +1 -0
  152. package/dist/extensions/markdown/bold-specs.d.ts +12 -0
  153. package/dist/extensions/markdown/bold-specs.d.ts.map +1 -0
  154. package/dist/extensions/markdown/bold.d.ts +17 -0
  155. package/dist/extensions/markdown/bold.d.ts.map +1 -0
  156. package/dist/extensions/markdown/breaks-specs.d.ts +22 -0
  157. package/dist/extensions/markdown/breaks-specs.d.ts.map +1 -0
  158. package/dist/extensions/markdown/breaks.d.ts +11 -0
  159. package/dist/extensions/markdown/breaks.d.ts.map +1 -0
  160. package/dist/extensions/markdown/code-block-specs.d.ts +14 -0
  161. package/dist/extensions/markdown/code-block-specs.d.ts.map +1 -0
  162. package/dist/extensions/markdown/code-block.d.ts +14 -0
  163. package/dist/extensions/markdown/code-block.d.ts.map +1 -0
  164. package/dist/extensions/markdown/code-specs.d.ts +9 -0
  165. package/dist/extensions/markdown/code-specs.d.ts.map +1 -0
  166. package/dist/extensions/markdown/code.d.ts +11 -0
  167. package/dist/extensions/markdown/code.d.ts.map +1 -0
  168. package/dist/extensions/markdown/deflist-specs.d.ts +16 -0
  169. package/dist/extensions/markdown/deflist-specs.d.ts.map +1 -0
  170. package/dist/extensions/markdown/deflist.d.ts +14 -0
  171. package/dist/extensions/markdown/deflist.d.ts.map +1 -0
  172. package/dist/extensions/markdown/heading-specs.d.ts +11 -0
  173. package/dist/extensions/markdown/heading-specs.d.ts.map +1 -0
  174. package/dist/extensions/markdown/heading.d.ts +17 -0
  175. package/dist/extensions/markdown/heading.d.ts.map +1 -0
  176. package/dist/extensions/markdown/horizontal-rule-specs.d.ts +10 -0
  177. package/dist/extensions/markdown/horizontal-rule-specs.d.ts.map +1 -0
  178. package/dist/extensions/markdown/horizontal-rule.d.ts +8 -0
  179. package/dist/extensions/markdown/horizontal-rule.d.ts.map +1 -0
  180. package/dist/extensions/markdown/html.d.ts +15 -0
  181. package/dist/extensions/markdown/html.d.ts.map +1 -0
  182. package/dist/extensions/markdown/image.d.ts +39 -0
  183. package/dist/extensions/markdown/image.d.ts.map +1 -0
  184. package/dist/extensions/markdown/italic-specs.d.ts +12 -0
  185. package/dist/extensions/markdown/italic-specs.d.ts.map +1 -0
  186. package/dist/extensions/markdown/italic.d.ts +11 -0
  187. package/dist/extensions/markdown/italic.d.ts.map +1 -0
  188. package/dist/extensions/markdown/link-specs.d.ts +19 -0
  189. package/dist/extensions/markdown/link-specs.d.ts.map +1 -0
  190. package/dist/extensions/markdown/link.d.ts +21 -0
  191. package/dist/extensions/markdown/link.d.ts.map +1 -0
  192. package/dist/extensions/markdown/list-specs.d.ts +6 -0
  193. package/dist/extensions/markdown/list-specs.d.ts.map +1 -0
  194. package/dist/extensions/markdown/lists.d.ts +18 -0
  195. package/dist/extensions/markdown/lists.d.ts.map +1 -0
  196. package/dist/extensions/markdown/mark.d.ts +12 -0
  197. package/dist/extensions/markdown/mark.d.ts.map +1 -0
  198. package/dist/extensions/markdown/strike.d.ts +12 -0
  199. package/dist/extensions/markdown/strike.d.ts.map +1 -0
  200. package/dist/extensions/markdown/subscript.d.ts +12 -0
  201. package/dist/extensions/markdown/subscript.d.ts.map +1 -0
  202. package/dist/extensions/markdown/table-actions.d.ts +14 -0
  203. package/dist/extensions/markdown/table-actions.d.ts.map +1 -0
  204. package/dist/extensions/markdown/table-specs.d.ts +25 -0
  205. package/dist/extensions/markdown/table-specs.d.ts.map +1 -0
  206. package/dist/extensions/markdown/table.d.ts +6 -0
  207. package/dist/extensions/markdown/table.d.ts.map +1 -0
  208. package/dist/extensions/markdown/underline.d.ts +12 -0
  209. package/dist/extensions/markdown/underline.d.ts.map +1 -0
  210. package/dist/extensions/specs.d.ts +13 -0
  211. package/dist/extensions/specs.d.ts.map +1 -0
  212. package/dist/extensions.js +247 -0
  213. package/dist/flowDiagram-UKHOOZJN-CfjPcHNW.js +1638 -0
  214. package/dist/forms/MarkdownEditorForm.vue.d.ts +37 -0
  215. package/dist/forms/MarkdownEditorForm.vue.d.ts.map +1 -0
  216. package/dist/forms/MarkdownEditorImageForm.vue.d.ts +131 -0
  217. package/dist/forms/MarkdownEditorImageForm.vue.d.ts.map +1 -0
  218. package/dist/forms/MarkdownEditorLinkForm.vue.d.ts +119 -0
  219. package/dist/forms/MarkdownEditorLinkForm.vue.d.ts.map +1 -0
  220. package/dist/forms/MarkdownEditorTextInput.vue.d.ts +39 -0
  221. package/dist/forms/MarkdownEditorTextInput.vue.d.ts.map +1 -0
  222. package/dist/forms/index.d.ts +7 -0
  223. package/dist/forms/index.d.ts.map +1 -0
  224. package/dist/forms.js +7 -0
  225. package/dist/full-C-o2lPBX.js +16 -0
  226. package/dist/full-specs-Cl-ODShc.js +10 -0
  227. package/dist/ganttDiagram-PKOTCBZU-ECmaWI-9.js +2711 -0
  228. package/dist/gitGraphDiagram-DS77QQ5N-DgG1RGJ8.js +815 -0
  229. package/dist/graph-DAHC4kPm.js +1545 -0
  230. package/dist/heading-specs-D7Bj4aIM.js +489 -0
  231. package/dist/i18n/index.d.ts +70 -0
  232. package/dist/i18n/index.d.ts.map +1 -0
  233. package/dist/i18n.js +132 -0
  234. package/dist/index-CqpK5VVw.js +149 -0
  235. package/dist/index-uerphigI.js +82 -0
  236. package/dist/index.css +1 -0
  237. package/dist/index.d.ts +87 -0
  238. package/dist/index.d.ts.map +1 -0
  239. package/dist/index.js +1293 -0
  240. package/dist/infoDiagram-6WML65LV-B1Yl3nZV.js +24 -0
  241. package/dist/init-DjUOC4st.js +16 -0
  242. package/dist/ishikawaDiagram-WSZJBQD7-4sngaB5o.js +621 -0
  243. package/dist/journeyDiagram-NVQOT4AX-B_6AmR_j.js +834 -0
  244. package/dist/kanban-definition-27J2QSJJ-B8BO9o8J.js +724 -0
  245. package/dist/katex-ByXcxnHy.js +14436 -0
  246. package/dist/katex-DoRnZ_sp.js +11682 -0
  247. package/dist/layout-DBbo_M5I.js +1519 -0
  248. package/dist/linear-BEdRfKba.js +259 -0
  249. package/dist/map-DRdzG8Ho.js +224 -0
  250. package/dist/mermaid.core-CR0bA2Wa.js +16496 -0
  251. package/dist/mindmap-definition-FAOFIHXS-DnPz807N.js +827 -0
  252. package/dist/optional-renderers-BalvqqvY.js +11 -0
  253. package/dist/ordinal-B6-f3MAq.js +61 -0
  254. package/dist/pegDiagram-VL7TDLO6-csGWlzs8.js +95 -0
  255. package/dist/pieDiagram-7S7Q4E2Y-Bqs8j5FX.js +207 -0
  256. package/dist/presets/commonmark-specs.d.ts +9 -0
  257. package/dist/presets/commonmark-specs.d.ts.map +1 -0
  258. package/dist/presets/commonmark.d.ts +26 -0
  259. package/dist/presets/commonmark.d.ts.map +1 -0
  260. package/dist/presets/default.d.ts +6 -0
  261. package/dist/presets/default.d.ts.map +1 -0
  262. package/dist/presets/full-specs.d.ts +6 -0
  263. package/dist/presets/full-specs.d.ts.map +1 -0
  264. package/dist/presets/full.d.ts +17 -0
  265. package/dist/presets/full.d.ts.map +1 -0
  266. package/dist/presets/index.d.ts +13 -0
  267. package/dist/presets/index.d.ts.map +1 -0
  268. package/dist/presets/zero.d.ts +8 -0
  269. package/dist/presets/zero.d.ts.map +1 -0
  270. package/dist/presets.js +10 -0
  271. package/dist/public-types.d.ts +96 -0
  272. package/dist/public-types.d.ts.map +1 -0
  273. package/dist/quadrantDiagram-CIZ2JOQS-jzP4lRrY.js +1023 -0
  274. package/dist/railroadDiagram-AXF67PYL-BSCyR24u.js +77 -0
  275. package/dist/renderer/MarkdownRenderer.vue.d.ts +10 -0
  276. package/dist/renderer/MarkdownRenderer.vue.d.ts.map +1 -0
  277. package/dist/renderer/index.d.ts +3 -0
  278. package/dist/renderer/index.d.ts.map +1 -0
  279. package/dist/renderer/markdown.d.ts +2 -0
  280. package/dist/renderer/markdown.d.ts.map +1 -0
  281. package/dist/renderer/mermaid-runtime.d.ts +4 -0
  282. package/dist/renderer/mermaid-runtime.d.ts.map +1 -0
  283. package/dist/renderer.js +258 -0
  284. package/dist/requirementDiagram-LRYGKXZP-DmEkLYqX.js +882 -0
  285. package/dist/sankeyDiagram-W5VNT64P-CYvRYMTh.js +847 -0
  286. package/dist/schema-dynamic-modifier-Dhf0m6tE.js +21514 -0
  287. package/dist/schema-dynamic-modifier.css +1 -0
  288. package/dist/sequenceDiagram-SI44F4Z6-CyWbDtPA.js +2888 -0
  289. package/dist/sizeCapture-X5ZJPWSS-xKhYCY84.js +46 -0
  290. package/dist/specs.js +127 -0
  291. package/dist/stateDiagram-OKZ733FA-DP44R2Dd.js +263 -0
  292. package/dist/stateDiagram-v2-UEYNNEHI-BvlOisND.js +16 -0
  293. package/dist/swimlanes-SLNWSIFB-BKFp8twH.js +5332 -0
  294. package/dist/swimlanesDiagram-ULZ7WXOC-CTvIFuHq.js +13 -0
  295. package/dist/timeline-definition-Z64GVDOM-B4137uIl.js +1055 -0
  296. package/dist/toolbar/config.d.ts +45 -0
  297. package/dist/toolbar/config.d.ts.map +1 -0
  298. package/dist/toolbar/index.d.ts +3 -0
  299. package/dist/toolbar/index.d.ts.map +1 -0
  300. package/dist/toolbar.js +100 -0
  301. package/dist/use-markdown-editor.d.ts +14 -0
  302. package/dist/use-markdown-editor.d.ts.map +1 -0
  303. package/dist/vennDiagram-T6HMQDX7-CPs8gXjx.js +1578 -0
  304. package/dist/version.d.ts +3 -0
  305. package/dist/version.d.ts.map +1 -0
  306. package/dist/wardleyDiagram-T6FBY63Y-BYp13hbI.js +675 -0
  307. package/dist/xychartDiagram-ELKLHX3M-DTT37K2u.js +1388 -0
  308. package/package.json +110 -0
@@ -0,0 +1,827 @@
1
+ import { g as ae } from "./chunk-XXDRQBXY-CK913N-t.js";
2
+ import { s as ce } from "./chunk-KBJHAD2P-D4R1VW0r.js";
3
+ import { _ as h, l as I, u as le, v as he, y as de, B as j, c as P, i as G, b6 as ge, T as ue, U as pe, V as fe } from "./mermaid.core-CR0bA2Wa.js";
4
+ const _ = [];
5
+ for (let t = 0; t < 256; ++t)
6
+ _.push((t + 256).toString(16).slice(1));
7
+ function me(t, e = 0) {
8
+ return (_[t[e + 0]] + _[t[e + 1]] + _[t[e + 2]] + _[t[e + 3]] + "-" + _[t[e + 4]] + _[t[e + 5]] + "-" + _[t[e + 6]] + _[t[e + 7]] + "-" + _[t[e + 8]] + _[t[e + 9]] + "-" + _[t[e + 10]] + _[t[e + 11]] + _[t[e + 12]] + _[t[e + 13]] + _[t[e + 14]] + _[t[e + 15]]).toLowerCase();
9
+ }
10
+ const ye = new Uint8Array(16);
11
+ function Ee() {
12
+ return crypto.getRandomValues(ye);
13
+ }
14
+ function _e(t, e, a) {
15
+ return crypto.randomUUID ? crypto.randomUUID() : be(t);
16
+ }
17
+ function be(t, e, a) {
18
+ t = t || {};
19
+ const l = t.random ?? t.rng?.() ?? Ee();
20
+ if (l.length < 16)
21
+ throw new Error("Random bytes length must be >= 16");
22
+ return l[6] = l[6] & 15 | 64, l[8] = l[8] & 63 | 128, me(l);
23
+ }
24
+ var q = (function() {
25
+ var t = /* @__PURE__ */ h(function(L, s, i, o) {
26
+ for (i = i || {}, o = L.length; o--; i[L[o]] = s) ;
27
+ return i;
28
+ }, "o"), e = [1, 4], a = [1, 13], l = [1, 12], n = [1, 15], d = [1, 16], f = [1, 20], y = [1, 19], E = [6, 7, 8], b = [1, 26], v = [1, 24], R = [1, 25], g = [6, 7, 11], A = [1, 6, 13, 15, 16, 19, 22], J = [1, 33], K = [1, 34], $ = [1, 6, 7, 11, 13, 15, 16, 19, 22], H = {
29
+ trace: /* @__PURE__ */ h(function() {
30
+ }, "trace"),
31
+ yy: {},
32
+ symbols_: { error: 2, start: 3, mindMap: 4, spaceLines: 5, SPACELINE: 6, NL: 7, MINDMAP: 8, document: 9, stop: 10, EOF: 11, statement: 12, SPACELIST: 13, node: 14, ICON: 15, CLASS: 16, nodeWithId: 17, nodeWithoutId: 18, NODE_DSTART: 19, NODE_DESCR: 20, NODE_DEND: 21, NODE_ID: 22, $accept: 0, $end: 1 },
33
+ terminals_: { 2: "error", 6: "SPACELINE", 7: "NL", 8: "MINDMAP", 11: "EOF", 13: "SPACELIST", 15: "ICON", 16: "CLASS", 19: "NODE_DSTART", 20: "NODE_DESCR", 21: "NODE_DEND", 22: "NODE_ID" },
34
+ productions_: [0, [3, 1], [3, 2], [5, 1], [5, 2], [5, 2], [4, 2], [4, 3], [10, 1], [10, 1], [10, 1], [10, 2], [10, 2], [9, 3], [9, 2], [12, 2], [12, 2], [12, 2], [12, 1], [12, 1], [12, 1], [12, 1], [12, 1], [14, 1], [14, 1], [18, 3], [17, 1], [17, 4]],
35
+ performAction: /* @__PURE__ */ h(function(s, i, o, c, p, r, B) {
36
+ var u = r.length - 1;
37
+ switch (p) {
38
+ case 6:
39
+ case 7:
40
+ return c;
41
+ case 8:
42
+ c.getLogger().trace("Stop NL ");
43
+ break;
44
+ case 9:
45
+ c.getLogger().trace("Stop EOF ");
46
+ break;
47
+ case 11:
48
+ c.getLogger().trace("Stop NL2 ");
49
+ break;
50
+ case 12:
51
+ c.getLogger().trace("Stop EOF2 ");
52
+ break;
53
+ case 15:
54
+ c.getLogger().info("Node: ", r[u].id), c.addNode(r[u - 1].length, r[u].id, r[u].descr, r[u].type);
55
+ break;
56
+ case 16:
57
+ c.getLogger().trace("Icon: ", r[u]), c.decorateNode({ icon: r[u] });
58
+ break;
59
+ case 17:
60
+ case 21:
61
+ c.decorateNode({ class: r[u] });
62
+ break;
63
+ case 18:
64
+ c.getLogger().trace("SPACELIST");
65
+ break;
66
+ case 19:
67
+ c.getLogger().trace("Node: ", r[u].id), c.addNode(0, r[u].id, r[u].descr, r[u].type);
68
+ break;
69
+ case 20:
70
+ c.decorateNode({ icon: r[u] });
71
+ break;
72
+ case 25:
73
+ c.getLogger().trace("node found ..", r[u - 2]), this.$ = { id: r[u - 1], descr: r[u - 1], type: c.getType(r[u - 2], r[u]) };
74
+ break;
75
+ case 26:
76
+ this.$ = { id: r[u], descr: r[u], type: c.nodeType.DEFAULT };
77
+ break;
78
+ case 27:
79
+ c.getLogger().trace("node found ..", r[u - 3]), this.$ = { id: r[u - 3], descr: r[u - 1], type: c.getType(r[u - 2], r[u]) };
80
+ break;
81
+ }
82
+ }, "anonymous"),
83
+ table: [{ 3: 1, 4: 2, 5: 3, 6: [1, 5], 8: e }, { 1: [3] }, { 1: [2, 1] }, { 4: 6, 6: [1, 7], 7: [1, 8], 8: e }, { 6: a, 7: [1, 10], 9: 9, 12: 11, 13: l, 14: 14, 15: n, 16: d, 17: 17, 18: 18, 19: f, 22: y }, t(E, [2, 3]), { 1: [2, 2] }, t(E, [2, 4]), t(E, [2, 5]), { 1: [2, 6], 6: a, 12: 21, 13: l, 14: 14, 15: n, 16: d, 17: 17, 18: 18, 19: f, 22: y }, { 6: a, 9: 22, 12: 11, 13: l, 14: 14, 15: n, 16: d, 17: 17, 18: 18, 19: f, 22: y }, { 6: b, 7: v, 10: 23, 11: R }, t(g, [2, 22], { 17: 17, 18: 18, 14: 27, 15: [1, 28], 16: [1, 29], 19: f, 22: y }), t(g, [2, 18]), t(g, [2, 19]), t(g, [2, 20]), t(g, [2, 21]), t(g, [2, 23]), t(g, [2, 24]), t(g, [2, 26], { 19: [1, 30] }), { 20: [1, 31] }, { 6: b, 7: v, 10: 32, 11: R }, { 1: [2, 7], 6: a, 12: 21, 13: l, 14: 14, 15: n, 16: d, 17: 17, 18: 18, 19: f, 22: y }, t(A, [2, 14], { 7: J, 11: K }), t($, [2, 8]), t($, [2, 9]), t($, [2, 10]), t(g, [2, 15]), t(g, [2, 16]), t(g, [2, 17]), { 20: [1, 35] }, { 21: [1, 36] }, t(A, [2, 13], { 7: J, 11: K }), t($, [2, 11]), t($, [2, 12]), { 21: [1, 37] }, t(g, [2, 25]), t(g, [2, 27])],
84
+ defaultActions: { 2: [2, 1], 6: [2, 2] },
85
+ parseError: /* @__PURE__ */ h(function(s, i) {
86
+ if (i.recoverable)
87
+ this.trace(s);
88
+ else {
89
+ var o = new Error(s);
90
+ throw o.hash = i, o;
91
+ }
92
+ }, "parseError"),
93
+ parse: /* @__PURE__ */ h(function(s) {
94
+ var i = this, o = [0], c = [], p = [null], r = [], B = this.table, u = "", U = 0, Q = 0, ie = 2, Z = 1, se = r.slice.call(arguments, 1), m = Object.create(this.lexer), T = { yy: {} };
95
+ for (var W in this.yy)
96
+ Object.prototype.hasOwnProperty.call(this.yy, W) && (T.yy[W] = this.yy[W]);
97
+ m.setInput(s, T.yy), T.yy.lexer = m, T.yy.parser = this, typeof m.yylloc > "u" && (m.yylloc = {});
98
+ var z = m.yylloc;
99
+ r.push(z);
100
+ var re = m.options && m.options.ranges;
101
+ typeof T.yy.parseError == "function" ? this.parseError = T.yy.parseError : this.parseError = Object.getPrototypeOf(this).parseError;
102
+ function oe(S) {
103
+ o.length = o.length - 2 * S, p.length = p.length - S, r.length = r.length - S;
104
+ }
105
+ h(oe, "popStack");
106
+ function ee() {
107
+ var S;
108
+ return S = c.pop() || m.lex() || Z, typeof S != "number" && (S instanceof Array && (c = S, S = c.pop()), S = i.symbols_[S] || S), S;
109
+ }
110
+ h(ee, "lex");
111
+ for (var k, O, x, X, C = {}, V, N, te, F; ; ) {
112
+ if (O = o[o.length - 1], this.defaultActions[O] ? x = this.defaultActions[O] : ((k === null || typeof k > "u") && (k = ee()), x = B[O] && B[O][k]), typeof x > "u" || !x.length || !x[0]) {
113
+ var Y = "";
114
+ F = [];
115
+ for (V in B[O])
116
+ this.terminals_[V] && V > ie && F.push("'" + this.terminals_[V] + "'");
117
+ m.showPosition ? Y = "Parse error on line " + (U + 1) + `:
118
+ ` + m.showPosition() + `
119
+ Expecting ` + F.join(", ") + ", got '" + (this.terminals_[k] || k) + "'" : Y = "Parse error on line " + (U + 1) + ": Unexpected " + (k == Z ? "end of input" : "'" + (this.terminals_[k] || k) + "'"), this.parseError(Y, {
120
+ text: m.match,
121
+ token: this.terminals_[k] || k,
122
+ line: m.yylineno,
123
+ loc: z,
124
+ expected: F
125
+ });
126
+ }
127
+ if (x[0] instanceof Array && x.length > 1)
128
+ throw new Error("Parse Error: multiple actions possible at state: " + O + ", token: " + k);
129
+ switch (x[0]) {
130
+ case 1:
131
+ o.push(k), p.push(m.yytext), r.push(m.yylloc), o.push(x[1]), k = null, Q = m.yyleng, u = m.yytext, U = m.yylineno, z = m.yylloc;
132
+ break;
133
+ case 2:
134
+ if (N = this.productions_[x[1]][1], C.$ = p[p.length - N], C._$ = {
135
+ first_line: r[r.length - (N || 1)].first_line,
136
+ last_line: r[r.length - 1].last_line,
137
+ first_column: r[r.length - (N || 1)].first_column,
138
+ last_column: r[r.length - 1].last_column
139
+ }, re && (C._$.range = [
140
+ r[r.length - (N || 1)].range[0],
141
+ r[r.length - 1].range[1]
142
+ ]), X = this.performAction.apply(C, [
143
+ u,
144
+ Q,
145
+ U,
146
+ T.yy,
147
+ x[1],
148
+ p,
149
+ r
150
+ ].concat(se)), typeof X < "u")
151
+ return X;
152
+ N && (o = o.slice(0, -1 * N * 2), p = p.slice(0, -1 * N), r = r.slice(0, -1 * N)), o.push(this.productions_[x[1]][0]), p.push(C.$), r.push(C._$), te = B[o[o.length - 2]][o[o.length - 1]], o.push(te);
153
+ break;
154
+ case 3:
155
+ return !0;
156
+ }
157
+ }
158
+ return !0;
159
+ }, "parse")
160
+ }, ne = /* @__PURE__ */ (function() {
161
+ var L = {
162
+ EOF: 1,
163
+ parseError: /* @__PURE__ */ h(function(i, o) {
164
+ if (this.yy.parser)
165
+ this.yy.parser.parseError(i, o);
166
+ else
167
+ throw new Error(i);
168
+ }, "parseError"),
169
+ // resets the lexer, sets new input
170
+ setInput: /* @__PURE__ */ h(function(s, i) {
171
+ return this.yy = i || this.yy || {}, this._input = s, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
172
+ first_line: 1,
173
+ first_column: 0,
174
+ last_line: 1,
175
+ last_column: 0
176
+ }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
177
+ }, "setInput"),
178
+ // consumes and returns one char from the input
179
+ input: /* @__PURE__ */ h(function() {
180
+ var s = this._input[0];
181
+ this.yytext += s, this.yyleng++, this.offset++, this.match += s, this.matched += s;
182
+ var i = s.match(/(?:\r\n?|\n).*/g);
183
+ return i ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), s;
184
+ }, "input"),
185
+ // unshifts one char (or a string) into the input
186
+ unput: /* @__PURE__ */ h(function(s) {
187
+ var i = s.length, o = s.split(/(?:\r\n?|\n)/g);
188
+ this._input = s + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - i), this.offset -= i;
189
+ var c = this.match.split(/(?:\r\n?|\n)/g);
190
+ this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), o.length - 1 && (this.yylineno -= o.length - 1);
191
+ var p = this.yylloc.range;
192
+ return this.yylloc = {
193
+ first_line: this.yylloc.first_line,
194
+ last_line: this.yylineno + 1,
195
+ first_column: this.yylloc.first_column,
196
+ last_column: o ? (o.length === c.length ? this.yylloc.first_column : 0) + c[c.length - o.length].length - o[0].length : this.yylloc.first_column - i
197
+ }, this.options.ranges && (this.yylloc.range = [p[0], p[0] + this.yyleng - i]), this.yyleng = this.yytext.length, this;
198
+ }, "unput"),
199
+ // When called from action, caches matched text and appends it on next action
200
+ more: /* @__PURE__ */ h(function() {
201
+ return this._more = !0, this;
202
+ }, "more"),
203
+ // When called from action, signals the lexer that this rule fails to match the input, so the next matching rule (regex) should be tested instead.
204
+ reject: /* @__PURE__ */ h(function() {
205
+ if (this.options.backtrack_lexer)
206
+ this._backtrack = !0;
207
+ else
208
+ return this.parseError("Lexical error on line " + (this.yylineno + 1) + `. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
209
+ ` + this.showPosition(), {
210
+ text: "",
211
+ token: null,
212
+ line: this.yylineno
213
+ });
214
+ return this;
215
+ }, "reject"),
216
+ // retain first n characters of the match
217
+ less: /* @__PURE__ */ h(function(s) {
218
+ this.unput(this.match.slice(s));
219
+ }, "less"),
220
+ // displays already matched input, i.e. for error messages
221
+ pastInput: /* @__PURE__ */ h(function() {
222
+ var s = this.matched.substr(0, this.matched.length - this.match.length);
223
+ return (s.length > 20 ? "..." : "") + s.substr(-20).replace(/\n/g, "");
224
+ }, "pastInput"),
225
+ // displays upcoming input, i.e. for error messages
226
+ upcomingInput: /* @__PURE__ */ h(function() {
227
+ var s = this.match;
228
+ return s.length < 20 && (s += this._input.substr(0, 20 - s.length)), (s.substr(0, 20) + (s.length > 20 ? "..." : "")).replace(/\n/g, "");
229
+ }, "upcomingInput"),
230
+ // displays the character position where the lexing error occurred, i.e. for error messages
231
+ showPosition: /* @__PURE__ */ h(function() {
232
+ var s = this.pastInput(), i = new Array(s.length + 1).join("-");
233
+ return s + this.upcomingInput() + `
234
+ ` + i + "^";
235
+ }, "showPosition"),
236
+ // test the lexed token: return FALSE when not a match, otherwise return token
237
+ test_match: /* @__PURE__ */ h(function(s, i) {
238
+ var o, c, p;
239
+ if (this.options.backtrack_lexer && (p = {
240
+ yylineno: this.yylineno,
241
+ yylloc: {
242
+ first_line: this.yylloc.first_line,
243
+ last_line: this.last_line,
244
+ first_column: this.yylloc.first_column,
245
+ last_column: this.yylloc.last_column
246
+ },
247
+ yytext: this.yytext,
248
+ match: this.match,
249
+ matches: this.matches,
250
+ matched: this.matched,
251
+ yyleng: this.yyleng,
252
+ offset: this.offset,
253
+ _more: this._more,
254
+ _input: this._input,
255
+ yy: this.yy,
256
+ conditionStack: this.conditionStack.slice(0),
257
+ done: this.done
258
+ }, this.options.ranges && (p.yylloc.range = this.yylloc.range.slice(0))), c = s[0].match(/(?:\r\n?|\n).*/g), c && (this.yylineno += c.length), this.yylloc = {
259
+ first_line: this.yylloc.last_line,
260
+ last_line: this.yylineno + 1,
261
+ first_column: this.yylloc.last_column,
262
+ last_column: c ? c[c.length - 1].length - c[c.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + s[0].length
263
+ }, this.yytext += s[0], this.match += s[0], this.matches = s, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(s[0].length), this.matched += s[0], o = this.performAction.call(this, this.yy, this, i, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), o)
264
+ return o;
265
+ if (this._backtrack) {
266
+ for (var r in p)
267
+ this[r] = p[r];
268
+ return !1;
269
+ }
270
+ return !1;
271
+ }, "test_match"),
272
+ // return next match in input
273
+ next: /* @__PURE__ */ h(function() {
274
+ if (this.done)
275
+ return this.EOF;
276
+ this._input || (this.done = !0);
277
+ var s, i, o, c;
278
+ this._more || (this.yytext = "", this.match = "");
279
+ for (var p = this._currentRules(), r = 0; r < p.length; r++)
280
+ if (o = this._input.match(this.rules[p[r]]), o && (!i || o[0].length > i[0].length)) {
281
+ if (i = o, c = r, this.options.backtrack_lexer) {
282
+ if (s = this.test_match(o, p[r]), s !== !1)
283
+ return s;
284
+ if (this._backtrack) {
285
+ i = !1;
286
+ continue;
287
+ } else
288
+ return !1;
289
+ } else if (!this.options.flex)
290
+ break;
291
+ }
292
+ return i ? (s = this.test_match(i, p[c]), s !== !1 ? s : !1) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + `. Unrecognized text.
293
+ ` + this.showPosition(), {
294
+ text: "",
295
+ token: null,
296
+ line: this.yylineno
297
+ });
298
+ }, "next"),
299
+ // return next match that has a token
300
+ lex: /* @__PURE__ */ h(function() {
301
+ var i = this.next();
302
+ return i || this.lex();
303
+ }, "lex"),
304
+ // activates a new lexer condition state (pushes the new lexer condition state onto the condition stack)
305
+ begin: /* @__PURE__ */ h(function(i) {
306
+ this.conditionStack.push(i);
307
+ }, "begin"),
308
+ // pop the previously active lexer condition state off the condition stack
309
+ popState: /* @__PURE__ */ h(function() {
310
+ var i = this.conditionStack.length - 1;
311
+ return i > 0 ? this.conditionStack.pop() : this.conditionStack[0];
312
+ }, "popState"),
313
+ // produce the lexer rule set which is active for the currently active lexer condition state
314
+ _currentRules: /* @__PURE__ */ h(function() {
315
+ return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
316
+ }, "_currentRules"),
317
+ // return the currently active lexer condition state; when an index argument is provided it produces the N-th previous condition state, if available
318
+ topState: /* @__PURE__ */ h(function(i) {
319
+ return i = this.conditionStack.length - 1 - Math.abs(i || 0), i >= 0 ? this.conditionStack[i] : "INITIAL";
320
+ }, "topState"),
321
+ // alias for begin(condition)
322
+ pushState: /* @__PURE__ */ h(function(i) {
323
+ this.begin(i);
324
+ }, "pushState"),
325
+ // return the number of states currently on the stack
326
+ stateStackSize: /* @__PURE__ */ h(function() {
327
+ return this.conditionStack.length;
328
+ }, "stateStackSize"),
329
+ options: { "case-insensitive": !0 },
330
+ performAction: /* @__PURE__ */ h(function(i, o, c, p) {
331
+ switch (c) {
332
+ case 0:
333
+ return i.getLogger().trace("Found comment", o.yytext), 6;
334
+ case 1:
335
+ return 8;
336
+ case 2:
337
+ this.begin("CLASS");
338
+ break;
339
+ case 3:
340
+ return this.popState(), 16;
341
+ case 4:
342
+ this.popState();
343
+ break;
344
+ case 5:
345
+ i.getLogger().trace("Begin icon"), this.begin("ICON");
346
+ break;
347
+ case 6:
348
+ return i.getLogger().trace("SPACELINE"), 6;
349
+ case 7:
350
+ return 7;
351
+ case 8:
352
+ return 15;
353
+ case 9:
354
+ i.getLogger().trace("end icon"), this.popState();
355
+ break;
356
+ case 10:
357
+ return i.getLogger().trace("Exploding node"), this.begin("NODE"), 19;
358
+ case 11:
359
+ return i.getLogger().trace("Cloud"), this.begin("NODE"), 19;
360
+ case 12:
361
+ return i.getLogger().trace("Explosion Bang"), this.begin("NODE"), 19;
362
+ case 13:
363
+ return i.getLogger().trace("Cloud Bang"), this.begin("NODE"), 19;
364
+ case 14:
365
+ return this.begin("NODE"), 19;
366
+ case 15:
367
+ return this.begin("NODE"), 19;
368
+ case 16:
369
+ return this.begin("NODE"), 19;
370
+ case 17:
371
+ return this.begin("NODE"), 19;
372
+ case 18:
373
+ return 13;
374
+ case 19:
375
+ return 22;
376
+ case 20:
377
+ return 11;
378
+ case 21:
379
+ this.begin("NSTR2");
380
+ break;
381
+ case 22:
382
+ return "NODE_DESCR";
383
+ case 23:
384
+ this.popState();
385
+ break;
386
+ case 24:
387
+ i.getLogger().trace("Starting NSTR"), this.begin("NSTR");
388
+ break;
389
+ case 25:
390
+ return i.getLogger().trace("description:", o.yytext), "NODE_DESCR";
391
+ case 26:
392
+ this.popState();
393
+ break;
394
+ case 27:
395
+ return this.popState(), i.getLogger().trace("node end ))"), "NODE_DEND";
396
+ case 28:
397
+ return this.popState(), i.getLogger().trace("node end )"), "NODE_DEND";
398
+ case 29:
399
+ return this.popState(), i.getLogger().trace("node end ...", o.yytext), "NODE_DEND";
400
+ case 30:
401
+ return this.popState(), i.getLogger().trace("node end (("), "NODE_DEND";
402
+ case 31:
403
+ return this.popState(), i.getLogger().trace("node end (-"), "NODE_DEND";
404
+ case 32:
405
+ return this.popState(), i.getLogger().trace("node end (-"), "NODE_DEND";
406
+ case 33:
407
+ return this.popState(), i.getLogger().trace("node end (("), "NODE_DEND";
408
+ case 34:
409
+ return this.popState(), i.getLogger().trace("node end (("), "NODE_DEND";
410
+ case 35:
411
+ return i.getLogger().trace("Long description:", o.yytext), 20;
412
+ case 36:
413
+ return i.getLogger().trace("Long description:", o.yytext), 20;
414
+ }
415
+ }, "anonymous"),
416
+ rules: [/^(?:\s*%%.*)/i, /^(?:mindmap\b)/i, /^(?::::)/i, /^(?:.+)/i, /^(?:\n)/i, /^(?:::icon\()/i, /^(?:[\s]+[\n])/i, /^(?:[\n]+)/i, /^(?:[^\)]+)/i, /^(?:\))/i, /^(?:-\))/i, /^(?:\(-)/i, /^(?:\)\))/i, /^(?:\))/i, /^(?:\(\()/i, /^(?:\{\{)/i, /^(?:\()/i, /^(?:\[)/i, /^(?:[\s]+)/i, /^(?:[^\(\[\n\)\{\}]+)/i, /^(?:$)/i, /^(?:["][`])/i, /^(?:[^`"]+)/i, /^(?:[`]["])/i, /^(?:["])/i, /^(?:[^"]+)/i, /^(?:["])/i, /^(?:[\)]\))/i, /^(?:[\)])/i, /^(?:[\]])/i, /^(?:\}\})/i, /^(?:\(-)/i, /^(?:-\))/i, /^(?:\(\()/i, /^(?:\()/i, /^(?:[^\)\]\(\}]+)/i, /^(?:.+(?!\(\())/i],
417
+ conditions: { CLASS: { rules: [3, 4], inclusive: !1 }, ICON: { rules: [8, 9], inclusive: !1 }, NSTR2: { rules: [22, 23], inclusive: !1 }, NSTR: { rules: [25, 26], inclusive: !1 }, NODE: { rules: [21, 24, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36], inclusive: !1 }, INITIAL: { rules: [0, 1, 2, 5, 6, 7, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20], inclusive: !0 } }
418
+ };
419
+ return L;
420
+ })();
421
+ H.lexer = ne;
422
+ function M() {
423
+ this.yy = {};
424
+ }
425
+ return h(M, "Parser"), M.prototype = H, H.Parser = M, new M();
426
+ })();
427
+ q.parser = q;
428
+ var ke = q, Se = 12, D = {
429
+ DEFAULT: 0,
430
+ NO_BORDER: 0,
431
+ ROUNDED_RECT: 1,
432
+ RECT: 2,
433
+ CIRCLE: 3,
434
+ CLOUD: 4,
435
+ BANG: 5,
436
+ HEXAGON: 6
437
+ }, w, xe = (w = class {
438
+ constructor() {
439
+ this.nodes = [], this.count = 0, this.elements = {}, this.getLogger = this.getLogger.bind(this), this.nodeType = D, this.clear(), this.getType = this.getType.bind(this), this.getElementById = this.getElementById.bind(this), this.getParent = this.getParent.bind(this), this.getMindmap = this.getMindmap.bind(this), this.addNode = this.addNode.bind(this), this.decorateNode = this.decorateNode.bind(this);
440
+ }
441
+ clear() {
442
+ this.nodes = [], this.count = 0, this.elements = {}, this.baseLevel = void 0;
443
+ }
444
+ getParent(e) {
445
+ for (let a = this.nodes.length - 1; a >= 0; a--)
446
+ if (this.nodes[a].level < e)
447
+ return this.nodes[a];
448
+ return null;
449
+ }
450
+ getMindmap() {
451
+ return this.nodes.length > 0 ? this.nodes[0] : null;
452
+ }
453
+ addNode(e, a, l, n) {
454
+ I.info("addNode", e, a, l, n);
455
+ let d = !1;
456
+ this.nodes.length === 0 ? (this.baseLevel = e, e = 0, d = !0) : this.baseLevel !== void 0 && (e = e - this.baseLevel, d = !1);
457
+ const f = P();
458
+ let y = f.mindmap?.padding ?? j.mindmap.padding;
459
+ switch (n) {
460
+ case this.nodeType.ROUNDED_RECT:
461
+ case this.nodeType.RECT:
462
+ case this.nodeType.HEXAGON:
463
+ y *= 2;
464
+ break;
465
+ }
466
+ const E = {
467
+ id: this.count++,
468
+ nodeId: G(a, f),
469
+ level: e,
470
+ descr: G(l, f),
471
+ type: n,
472
+ children: [],
473
+ width: f.mindmap?.maxNodeWidth ?? j.mindmap.maxNodeWidth,
474
+ padding: y,
475
+ isRoot: d
476
+ }, b = this.getParent(e);
477
+ if (b)
478
+ b.children.push(E), this.nodes.push(E);
479
+ else if (d)
480
+ this.nodes.push(E);
481
+ else
482
+ throw new Error(
483
+ `There can be only one root. No parent could be found for ("${E.descr}")`
484
+ );
485
+ }
486
+ getType(e, a) {
487
+ switch (I.debug("In get type", e, a), e) {
488
+ case "[":
489
+ return this.nodeType.RECT;
490
+ case "(":
491
+ return a === ")" ? this.nodeType.ROUNDED_RECT : this.nodeType.CLOUD;
492
+ case "((":
493
+ return this.nodeType.CIRCLE;
494
+ case ")":
495
+ return this.nodeType.CLOUD;
496
+ case "))":
497
+ return this.nodeType.BANG;
498
+ case "{{":
499
+ return this.nodeType.HEXAGON;
500
+ default:
501
+ return this.nodeType.DEFAULT;
502
+ }
503
+ }
504
+ setElementForId(e, a) {
505
+ this.elements[e] = a;
506
+ }
507
+ getElementById(e) {
508
+ return this.elements[e];
509
+ }
510
+ decorateNode(e) {
511
+ if (!e)
512
+ return;
513
+ const a = P(), l = this.nodes[this.nodes.length - 1];
514
+ e.icon && (l.icon = G(e.icon, a)), e.class && (l.class = G(e.class, a));
515
+ }
516
+ type2Str(e) {
517
+ switch (e) {
518
+ case this.nodeType.DEFAULT:
519
+ return "no-border";
520
+ case this.nodeType.RECT:
521
+ return "rect";
522
+ case this.nodeType.ROUNDED_RECT:
523
+ return "rounded-rect";
524
+ case this.nodeType.CIRCLE:
525
+ return "circle";
526
+ case this.nodeType.CLOUD:
527
+ return "cloud";
528
+ case this.nodeType.BANG:
529
+ return "bang";
530
+ case this.nodeType.HEXAGON:
531
+ return "hexgon";
532
+ // cspell: disable-line
533
+ default:
534
+ return "no-border";
535
+ }
536
+ }
537
+ /**
538
+ * Assign section numbers to nodes based on their position relative to root
539
+ * @param node - The mindmap node to process
540
+ * @param sectionNumber - The section number to assign (undefined for root)
541
+ */
542
+ assignSections(e, a) {
543
+ if (e.level === 0 ? e.section = void 0 : e.section = a, e.children)
544
+ for (const [l, n] of e.children.entries()) {
545
+ const d = e.level === 0 ? l % (Se - 1) : a;
546
+ this.assignSections(n, d);
547
+ }
548
+ }
549
+ /**
550
+ * Convert mindmap tree structure to flat array of nodes
551
+ * @param node - The mindmap node to process
552
+ * @param processedNodes - Array to collect processed nodes
553
+ */
554
+ flattenNodes(e, a) {
555
+ const l = P(), n = ["mindmap-node"];
556
+ e.isRoot === !0 ? n.push("section-root", "section--1") : e.section !== void 0 && n.push(`section-${e.section}`), e.class && n.push(e.class);
557
+ const d = n.join(" "), f = /* @__PURE__ */ h((E) => {
558
+ const v = (l.theme?.toLowerCase() ?? "").includes("redux");
559
+ switch (E) {
560
+ case D.CIRCLE:
561
+ return "mindmapCircle";
562
+ case D.RECT:
563
+ return "rect";
564
+ case D.ROUNDED_RECT:
565
+ return "rounded";
566
+ case D.CLOUD:
567
+ return "cloud";
568
+ case D.BANG:
569
+ return "bang";
570
+ case D.HEXAGON:
571
+ return "hexagon";
572
+ case D.DEFAULT:
573
+ return v ? "rounded" : "defaultMindmapNode";
574
+ case D.NO_BORDER:
575
+ default:
576
+ return "rect";
577
+ }
578
+ }, "getShapeFromType"), y = {
579
+ id: e.id.toString(),
580
+ domId: "node_" + e.id.toString(),
581
+ label: e.descr,
582
+ labelType: "markdown",
583
+ isGroup: !1,
584
+ shape: f(e.type),
585
+ width: e.width,
586
+ height: e.height ?? 0,
587
+ padding: e.padding,
588
+ cssClasses: d,
589
+ cssStyles: [],
590
+ look: l.look,
591
+ icon: e.icon,
592
+ x: e.x,
593
+ y: e.y,
594
+ // Mindmap-specific properties
595
+ level: e.level,
596
+ nodeId: e.nodeId,
597
+ type: e.type,
598
+ section: e.section
599
+ };
600
+ if (a.push(y), e.children)
601
+ for (const E of e.children)
602
+ this.flattenNodes(E, a);
603
+ }
604
+ /**
605
+ * Generate edges from parent-child relationships in mindmap tree
606
+ * @param node - The mindmap node to process
607
+ * @param edges - Array to collect edges
608
+ */
609
+ generateEdges(e, a) {
610
+ if (!e.children)
611
+ return;
612
+ const l = P();
613
+ for (const n of e.children) {
614
+ let d = "edge";
615
+ n.section !== void 0 && (d += ` section-edge-${n.section}`);
616
+ const f = e.level + 1;
617
+ d += ` edge-depth-${f}`;
618
+ const y = {
619
+ id: `edge_${e.id}_${n.id}`,
620
+ start: e.id.toString(),
621
+ end: n.id.toString(),
622
+ type: "normal",
623
+ curve: "basis",
624
+ thickness: "normal",
625
+ look: l.look,
626
+ classes: d,
627
+ // Store mindmap-specific data
628
+ depth: e.level,
629
+ section: n.section
630
+ };
631
+ a.push(y), this.generateEdges(n, a);
632
+ }
633
+ }
634
+ /**
635
+ * Get structured data for layout algorithms
636
+ * Following the pattern established by ER diagrams
637
+ * @returns Structured data containing nodes, edges, and config
638
+ */
639
+ getData() {
640
+ const e = this.getMindmap(), a = P(), n = ge().layout !== void 0, d = a;
641
+ if (n || (d.layout = "cose-bilkent"), !e)
642
+ return {
643
+ nodes: [],
644
+ edges: [],
645
+ config: d
646
+ };
647
+ I.debug("getData: mindmapRoot", e, a), this.assignSections(e);
648
+ const f = [], y = [];
649
+ this.flattenNodes(e, f), this.generateEdges(e, y), I.debug(
650
+ `getData: processed ${f.length} nodes and ${y.length} edges`
651
+ );
652
+ const E = /* @__PURE__ */ new Map();
653
+ for (const b of f)
654
+ E.set(b.id, {
655
+ shape: b.shape,
656
+ width: b.width,
657
+ height: b.height,
658
+ padding: b.padding
659
+ });
660
+ return {
661
+ nodes: f,
662
+ edges: y,
663
+ config: d,
664
+ // Store the root node for mindmap-specific layout algorithms
665
+ rootNode: e,
666
+ // Properties required by dagre layout algorithm
667
+ markers: ["point"],
668
+ // Mindmaps don't use markers
669
+ direction: "TB",
670
+ // Top-to-bottom direction for mindmaps
671
+ nodeSpacing: 50,
672
+ // Default spacing between nodes
673
+ rankSpacing: 50,
674
+ // Default spacing between ranks
675
+ // Add shapes for ELK compatibility
676
+ shapes: Object.fromEntries(E),
677
+ // Additional properties that layout algorithms might expect
678
+ type: "mindmap",
679
+ diagramId: "mindmap-" + _e()
680
+ };
681
+ }
682
+ // Expose logger to grammar
683
+ getLogger() {
684
+ return I;
685
+ }
686
+ }, h(w, "MindmapDB"), w), Ne = /* @__PURE__ */ h(async (t, e, a, l) => {
687
+ I.debug(`Rendering mindmap diagram
688
+ ` + t);
689
+ const n = l.db, d = n.getData(), f = ae(e, d.config.securityLevel);
690
+ if (d.type = l.type, d.layoutAlgorithm = le(d.config.layout, {
691
+ fallback: "cose-bilkent"
692
+ }), d.diagramId = e, !n.getMindmap())
693
+ return;
694
+ d.nodes.forEach((g) => {
695
+ g.shape === "rounded" ? (g.radius = 15, g.taper = 15, g.stroke = "none", g.width = 0, g.padding = 15) : g.shape === "circle" ? g.padding = 10 : g.shape === "rect" ? (g.width = 0, g.padding = 10) : g.shape === "hexagon" && (g.width = 0, g.height = 0);
696
+ }), await he(d, f);
697
+ const { themeVariables: E } = de(), { useGradient: b, gradientStart: v, gradientStop: R } = E;
698
+ if (b && v && R) {
699
+ const g = f.attr("id"), A = f.append("defs").append("linearGradient").attr("id", `${g}-gradient`).attr("gradientUnits", "objectBoundingBox").attr("x1", "0%").attr("y1", "0%").attr("x2", "100%").attr("y2", "0%");
700
+ A.append("stop").attr("offset", "0%").attr("stop-color", v).attr("stop-opacity", 1), A.append("stop").attr("offset", "100%").attr("stop-color", R).attr("stop-opacity", 1);
701
+ }
702
+ ce(
703
+ f,
704
+ d.config.mindmap?.padding ?? j.mindmap.padding,
705
+ "mindmapDiagram",
706
+ d.config.mindmap?.useMaxWidth ?? j.mindmap.useMaxWidth
707
+ );
708
+ }, "draw"), De = {
709
+ draw: Ne
710
+ }, Le = /* @__PURE__ */ h((t) => {
711
+ const { theme: e, look: a } = t;
712
+ let l = "";
713
+ for (let n = 0; n < t.THEME_COLOR_LIMIT; n++)
714
+ t["lineColor" + n] = t["lineColor" + n] || t["cScaleInv" + n], ue(t["lineColor" + n]) ? t["lineColor" + n] = pe(t["lineColor" + n], 20) : t["lineColor" + n] = fe(t["lineColor" + n], 20);
715
+ for (let n = 0; n < t.THEME_COLOR_LIMIT; n++) {
716
+ const d = "" + (a === "neo" ? Math.max(10 - (n - 1) * 2, 2) : 17 - 3 * n);
717
+ l += `
718
+ .section-${n - 1} rect, .section-${n - 1} path, .section-${n - 1} circle, .section-${n - 1} polygon, .section-${n - 1} path {
719
+ fill: ${t["cScale" + n]};
720
+ }
721
+ .section-${n - 1} text {
722
+ fill: ${t["cScaleLabel" + n]};
723
+ }
724
+ .section-${n - 1} span {
725
+ color: ${t["cScaleLabel" + n]};
726
+ }
727
+ .node-icon-${n - 1} {
728
+ font-size: 40px;
729
+ color: ${t["cScaleLabel" + n]};
730
+ }
731
+ .section-edge-${n - 1}{
732
+ stroke: ${t["cScale" + n]};
733
+ }
734
+ .edge-depth-${n - 1}{
735
+ stroke-width: ${d};
736
+ }
737
+ .section-${n - 1} line {
738
+ stroke: ${t["cScaleInv" + n]} ;
739
+ stroke-width: 3;
740
+ }
741
+
742
+ .disabled, .disabled circle, .disabled text {
743
+ fill: lightgray;
744
+ }
745
+ .disabled text {
746
+ fill: #efefef;
747
+ }
748
+ [data-look="neo"].mindmap-node.section-${n - 1} rect, [data-look="neo"].mindmap-node.section-${n - 1} path, [data-look="neo"].mindmap-node.section-${n - 1} circle, [data-look="neo"].mindmap-node.section-${n - 1} polygon {
749
+ fill: ${e === "redux" || e === "redux-dark" || e === "neutral" ? t.mainBkg : t["cScale" + n]};
750
+ stroke: ${e === "redux" || e === "redux-dark" ? t.nodeBorder : t["cScale" + n]};
751
+ stroke-width: ${t.strokeWidth ?? 2}px;
752
+ }
753
+ [data-look="neo"].section-edge-${n - 1}{
754
+ stroke: ${e?.includes("redux") || e === "neo-dark" ? t.nodeBorder : t["cScale" + n]};
755
+ }
756
+ [data-look="neo"].mindmap-node.section-${n - 1} text {
757
+ fill: ${e === "redux" || e === "redux-dark" ? t.nodeBorder : t["cScaleLabel" + (e === "neutral" ? 1 : n)]};
758
+ }
759
+ `;
760
+ }
761
+ return l;
762
+ }, "genSections"), ve = /* @__PURE__ */ h((t, e, a) => {
763
+ let l = "";
764
+ for (let n = 0; n < t; n++)
765
+ l += `
766
+ [data-look="neo"].mindmap-node.section-${n - 1} rect, [data-look="neo"].mindmap-node.section-${n - 1} path, [data-look="neo"].mindmap-node.section-${n - 1} circle, [data-look="neo"].mindmap-node.section-${n - 1} polygon {
767
+ stroke: url(${e}-gradient);
768
+ fill: ${a};
769
+ }
770
+ .section-${n - 1} line {
771
+ stroke-width: 0;
772
+ }`;
773
+ return l;
774
+ }, "genGradient"), Te = /* @__PURE__ */ h((t) => {
775
+ const { theme: e } = t, a = t.svgId, l = t.dropShadow ? t.dropShadow.replace("url(#drop-shadow)", `url(${a}-drop-shadow)`) : "none";
776
+ return `
777
+ .edge {
778
+ stroke-width: 3;
779
+ }
780
+ ${Le(t)}
781
+ .section-root rect, .section-root path, .section-root circle, .section-root polygon {
782
+ fill: ${t.git0};
783
+ }
784
+ .section-root text {
785
+ fill: ${t.gitBranchLabel0};
786
+ }
787
+ .section-root span {
788
+ color: ${e?.includes("redux") ? t.nodeBorder : t.gitBranchLabel0};
789
+ }
790
+ .icon-container {
791
+ height:100%;
792
+ display: flex;
793
+ justify-content: center;
794
+ align-items: center;
795
+ }
796
+ .edge {
797
+ fill: none;
798
+ }
799
+ .mindmap-node-label {
800
+ dy: 1em;
801
+ alignment-baseline: middle;
802
+ text-anchor: middle;
803
+ dominant-baseline: middle;
804
+ text-align: center;
805
+ }
806
+ [data-look="neo"].mindmap-node {
807
+ filter: ${l};
808
+ }
809
+ [data-look="neo"].mindmap-node.section-root rect, [data-look="neo"].mindmap-node.section-root path, [data-look="neo"].mindmap-node.section-root circle, [data-look="neo"].mindmap-node.section-root polygon {
810
+ fill: ${e?.includes("redux") ? t.mainBkg : t.git0};
811
+ }
812
+ [data-look="neo"].mindmap-node.section-root .text-inner-tspan {
813
+ fill: ${e?.includes("redux") ? t.nodeBorder : t["cScaleLabel" + (e === "neutral" ? 1 : 0)]};
814
+ }
815
+ ${t.useGradient && a && t.mainBkg ? ve(t.THEME_COLOR_LIMIT, a, t.mainBkg) : ""}
816
+ `;
817
+ }, "getStyles"), Oe = Te, Re = {
818
+ get db() {
819
+ return new xe();
820
+ },
821
+ renderer: De,
822
+ parser: ke,
823
+ styles: Oe
824
+ };
825
+ export {
826
+ Re as diagram
827
+ };