@aiquants/markdown 1.18.0 → 2.0.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 (415) hide show
  1. package/dist/abnfDiagram-VRR7QNED-BBmog1I4.cjs +0 -1
  2. package/dist/abnfDiagram-VRR7QNED-CxfTrgXf.js +0 -1
  3. package/dist/arc-ClGqtl_2.js +0 -1
  4. package/dist/arc-DKsAswGe.cjs +0 -1
  5. package/dist/architectureDiagram-ZJ3FMSHR-BLhnaJyB.cjs +0 -1
  6. package/dist/architectureDiagram-ZJ3FMSHR-Dild3kjN.js +0 -1
  7. package/dist/blockDiagram-677ZJIJ3-D72bpMhN.cjs +0 -1
  8. package/dist/blockDiagram-677ZJIJ3-DD1l8WOn.js +0 -1
  9. package/dist/c4Diagram-LMCZKHZV-BJkJh-kC.js +0 -1
  10. package/dist/c4Diagram-LMCZKHZV-D3d1d4zO.cjs +0 -1
  11. package/dist/channel-DE5LXIMm.cjs +0 -1
  12. package/dist/channel-DaGDswnD.js +0 -1
  13. package/dist/chunk-2Q5K7J3B-BrnUlAaZ.cjs +0 -1
  14. package/dist/chunk-2Q5K7J3B-DejpXtzn.js +0 -1
  15. package/dist/chunk-32BRIVSS-BCAuSjpE.js +0 -1
  16. package/dist/chunk-32BRIVSS-CDxbP_I9.cjs +0 -1
  17. package/dist/chunk-5VM5RSS4-C-cBAbST.cjs +0 -1
  18. package/dist/chunk-5VM5RSS4-DI1kbCYB.js +0 -1
  19. package/dist/chunk-EX3LRPZG-CVTsVkLX.js +0 -1
  20. package/dist/chunk-EX3LRPZG-uKd75-FB.cjs +0 -1
  21. package/dist/chunk-JWPE2WC7-CNFRDah7.cjs +0 -1
  22. package/dist/chunk-JWPE2WC7-Cu3ql0Gi.js +0 -1
  23. package/dist/chunk-MOJQB5TN-BZ0Sok4l.js +0 -1
  24. package/dist/chunk-MOJQB5TN-Bs5Jj3Zh.cjs +0 -1
  25. package/dist/chunk-PUDLZKDR-3RVC5ezN.js +0 -1
  26. package/dist/chunk-PUDLZKDR-DisfuynB.cjs +0 -1
  27. package/dist/chunk-RYQCIY6F-CSpf1fBI.js +0 -1
  28. package/dist/chunk-RYQCIY6F-xFTrTO6v.cjs +0 -1
  29. package/dist/chunk-V7JOEXUC-BnwuCkOT.js +0 -1
  30. package/dist/chunk-V7JOEXUC-BvkxRSjK.cjs +0 -1
  31. package/dist/chunk-VR4S4FIN-DAwCjhU3.cjs +0 -1
  32. package/dist/chunk-VR4S4FIN-DSW2sQDL.js +0 -1
  33. package/dist/chunk-XXDRQBXY-B7vX1DJv.cjs +0 -1
  34. package/dist/chunk-XXDRQBXY-DrE4gFtL.js +0 -1
  35. package/dist/classDiagram-OUVF2IWQ-BxIt89EK.cjs +0 -1
  36. package/dist/classDiagram-OUVF2IWQ-DlER_wIi.js +0 -1
  37. package/dist/classDiagram-v2-EOCWNBFH-BxIt89EK.cjs +0 -1
  38. package/dist/classDiagram-v2-EOCWNBFH-DlER_wIi.js +0 -1
  39. package/dist/cli.d.ts +0 -1
  40. package/dist/components/MarkdownRenderer.d.ts +2 -35
  41. package/dist/components/MarkdownViewer.d.ts +1 -75
  42. package/dist/components/MermaidDiagram.d.ts +3 -9
  43. package/dist/components/NodesRenderer.d.ts +11 -12
  44. package/dist/components/TableOfContents.d.ts +1 -6
  45. package/dist/components/mdastNodes/BlockLinkNode.d.ts +2 -3
  46. package/dist/components/mdastNodes/BlockquoteNode.d.ts +1 -2
  47. package/dist/components/mdastNodes/CodeNode.d.ts +0 -14
  48. package/dist/components/mdastNodes/DeleteNode.d.ts +1 -2
  49. package/dist/components/mdastNodes/EmphasisNode.d.ts +1 -2
  50. package/dist/components/mdastNodes/FootnoteBackLinkNode.d.ts +1 -2
  51. package/dist/components/mdastNodes/HTMLBlockContainerNode.d.ts +2 -12
  52. package/dist/components/mdastNodes/HTMLNode.d.ts +1 -24
  53. package/dist/components/mdastNodes/HeadingNode.d.ts +2 -26
  54. package/dist/components/mdastNodes/ImageNode.d.ts +2 -3
  55. package/dist/components/mdastNodes/InlineCodeNode.d.ts +1 -2
  56. package/dist/components/mdastNodes/InlineMathNode.d.ts +1 -2
  57. package/dist/components/mdastNodes/LinkNode.d.ts +1 -2
  58. package/dist/components/mdastNodes/ListItemNode.d.ts +1 -2
  59. package/dist/components/mdastNodes/ListNode.d.ts +1 -2
  60. package/dist/components/mdastNodes/MarkNode.d.ts +1 -6
  61. package/dist/components/mdastNodes/MathNode.d.ts +1 -7
  62. package/dist/components/mdastNodes/ParagraphNode.d.ts +1 -2
  63. package/dist/components/mdastNodes/RichLinkCard.d.ts +1 -6
  64. package/dist/components/mdastNodes/StrongNode.d.ts +1 -2
  65. package/dist/components/mdastNodes/SubscriptNode.d.ts +1 -6
  66. package/dist/components/mdastNodes/SuperscriptNode.d.ts +1 -6
  67. package/dist/components/mdastNodes/TableNode.d.ts +1 -2
  68. package/dist/components/mdastNodes/TextNode.d.ts +1 -2
  69. package/dist/components/mdastNodes/ThematicBreakNode.d.ts +0 -1
  70. package/dist/components/mdastNodes/TwitterEmbedNode.d.ts +2 -12
  71. package/dist/components/mdastNodes/YouTubeEmbedNode.d.ts +1 -2
  72. package/dist/components/mdastNodes/ZennDetailsNode.d.ts +2 -3
  73. package/dist/components/mdastNodes/ZennMessageNode.d.ts +2 -3
  74. package/dist/components/mermaidInteraction.d.ts +0 -38
  75. package/dist/components/plugins/DifyIFramePlugin.d.ts +0 -25
  76. package/dist/components/plugins/IFramePluginRegistry.d.ts +0 -59
  77. package/dist/components/plugins/index.d.ts +2 -12
  78. package/dist/cose-bilkent-JH36ORCC-BvnlFiZm.js +0 -1
  79. package/dist/cose-bilkent-JH36ORCC-BzL-a0Zv.cjs +0 -1
  80. package/dist/cynefin-VYW2F7L2-Bkk-F_Js.js +0 -1
  81. package/dist/cynefin-VYW2F7L2-MpAliYy9.cjs +0 -1
  82. package/dist/cynefinDiagram-TSTJHNR4-B1lNDIu_.cjs +0 -1
  83. package/dist/cynefinDiagram-TSTJHNR4-CUwuCyMp.js +0 -1
  84. package/dist/cytoscape.esm-D8x1ApSO.cjs +0 -1
  85. package/dist/cytoscape.esm-kVAWcYoG.js +0 -1
  86. package/dist/dagre-VKFMJZFB-COYURQTh.cjs +0 -1
  87. package/dist/dagre-VKFMJZFB-Ct0vbIs9.js +0 -1
  88. package/dist/defaultLocale-BgPVtth8.js +0 -1
  89. package/dist/defaultLocale-C4wbwF1n.cjs +0 -1
  90. package/dist/diagram-FQU43EPY-B5HmiJPw.js +0 -1
  91. package/dist/diagram-FQU43EPY-DkgdwwAT.cjs +0 -1
  92. package/dist/diagram-G47NLZAW-C-nfBNGF.js +0 -1
  93. package/dist/diagram-G47NLZAW-CcXcBx81.cjs +0 -1
  94. package/dist/diagram-NH7WQ7WH-BMYzS0pm.cjs +0 -1
  95. package/dist/diagram-NH7WQ7WH-yu8B8Q4y.js +0 -1
  96. package/dist/diagram-OA4YK3LP-CROsfore.js +0 -1
  97. package/dist/diagram-OA4YK3LP-DSeI6RLe.cjs +0 -1
  98. package/dist/diagram-WEI45ONY-CCJwQ42c.cjs +0 -1
  99. package/dist/diagram-WEI45ONY-DmPpMglv.js +0 -1
  100. package/dist/ebnfDiagram-CCIWWBDH-B2ck9j39.js +0 -1
  101. package/dist/ebnfDiagram-CCIWWBDH-D_nz1FvR.cjs +0 -1
  102. package/dist/erDiagram-Q63AITRT-2r-lfgSt.cjs +0 -1
  103. package/dist/erDiagram-Q63AITRT-BfpyxqAV.js +0 -1
  104. package/dist/extractHeadings-BrLI2qQF.cjs +0 -1
  105. package/dist/extractHeadings-Dgzd324l.js +0 -1
  106. package/dist/flowDiagram-23GEKE2U-D3w55eDA.cjs +0 -1
  107. package/dist/flowDiagram-23GEKE2U-LZTzy0Rx.js +0 -1
  108. package/dist/ganttDiagram-NO4QXBWP-CNhgpKSH.cjs +0 -1
  109. package/dist/ganttDiagram-NO4QXBWP-DR3YQ-Kd.js +0 -1
  110. package/dist/gen/markdown/v1/markdown_connect.d.ts +2 -9
  111. package/dist/gen/markdown/v1/markdown_pb.d.ts +1 -79
  112. package/dist/gitGraphDiagram-IHSO6WYX-CzLNLS8W.js +0 -1
  113. package/dist/gitGraphDiagram-IHSO6WYX-D5IYosEF.cjs +0 -1
  114. package/dist/graph-BgRih2Qv.cjs +0 -1
  115. package/dist/graph-DAHC4kPm.js +0 -1
  116. package/dist/index.cjs +0 -1
  117. package/dist/index.client.cjs +0 -1
  118. package/dist/index.client.d.ts +42 -43
  119. package/dist/index.client.js +0 -1
  120. package/dist/index.d.ts +1 -2
  121. package/dist/index.js +0 -1
  122. package/dist/index.server.cjs +1 -2
  123. package/dist/index.server.d.ts +3 -11
  124. package/dist/index.server.js +151 -255
  125. package/dist/infoDiagram-FWYZ7A6U-CBcx5GhE.js +0 -1
  126. package/dist/infoDiagram-FWYZ7A6U-U2OiliOP.cjs +0 -1
  127. package/dist/init-CHZsXQcr.cjs +0 -1
  128. package/dist/init-DjUOC4st.js +0 -1
  129. package/dist/ishikawaDiagram-FXEZZL3T-CWXT_3xh.js +0 -1
  130. package/dist/ishikawaDiagram-FXEZZL3T-DK3M6wrz.cjs +0 -1
  131. package/dist/journeyDiagram-5HDEW3XC-B-BfhPr4.cjs +0 -1
  132. package/dist/journeyDiagram-5HDEW3XC-DRbAj2Yz.js +0 -1
  133. package/dist/kanban-definition-HUTT4EX6-BvnLv2HN.cjs +0 -1
  134. package/dist/kanban-definition-HUTT4EX6-DtRSv2_P.js +0 -1
  135. package/dist/layout-DBbo_M5I.js +0 -1
  136. package/dist/layout-OMlh6_XH.cjs +0 -1
  137. package/dist/linear-B9JMAP1U.cjs +0 -1
  138. package/dist/linear-HTaGrbQh.js +0 -1
  139. package/dist/map-BvScllSQ.cjs +0 -1
  140. package/dist/map-DRdzG8Ho.js +0 -1
  141. package/dist/mindmap-definition-LN4V7U3C-4cN-VjxO.js +0 -1
  142. package/dist/mindmap-definition-LN4V7U3C-asDDR5DU.cjs +0 -1
  143. package/dist/ordinal-B6-f3MAq.js +0 -1
  144. package/dist/ordinal-CagbB1m8.cjs +0 -1
  145. package/dist/pegDiagram-2B236MQR-C3qJlDiV.cjs +0 -1
  146. package/dist/pegDiagram-2B236MQR-cMLC3Ggy.js +0 -1
  147. package/dist/pieDiagram-ENE6RG2P-D5-meW-_.cjs +0 -1
  148. package/dist/pieDiagram-ENE6RG2P-nk_3VO3x.js +0 -1
  149. package/dist/plugins/createIntentTweetLink.d.ts +0 -1
  150. package/dist/plugins/extractYouTubeVideoId.d.ts +0 -1
  151. package/dist/plugins/fetchSiteMetadata.d.ts +0 -19
  152. package/dist/plugins/remark-auto-heading-id.d.ts +1 -9
  153. package/dist/plugins/remark-block-link-metadata.d.ts +6 -23
  154. package/dist/plugins/remark-block-link.d.ts +4 -4
  155. package/dist/plugins/remark-custom-heading-id.d.ts +1 -16
  156. package/dist/plugins/remark-footnote-back-link.d.ts +4 -4
  157. package/dist/plugins/remark-html-anchor-to-link.d.ts +1 -7
  158. package/dist/plugins/remark-html-in-html.d.ts +1 -9
  159. package/dist/plugins/remark-image-size.d.ts +1 -9
  160. package/dist/plugins/remark-mark.d.ts +4 -12
  161. package/dist/plugins/remark-parent-node.d.ts +1 -6
  162. package/dist/plugins/remark-subscript.d.ts +4 -12
  163. package/dist/plugins/remark-superscript.d.ts +4 -12
  164. package/dist/plugins/remark-table-merge.d.ts +4 -8
  165. package/dist/plugins/remark-twitter-embed.d.ts +4 -5
  166. package/dist/plugins/remark-unwrap-block-html.d.ts +4 -8
  167. package/dist/plugins/remark-youtube-embed.d.ts +4 -4
  168. package/dist/plugins/remark-zenn-message.d.ts +4 -19
  169. package/dist/quadrantDiagram-ABIIQ3AL-CmqrHJ4C.cjs +0 -1
  170. package/dist/quadrantDiagram-ABIIQ3AL-Ctdfu4Qk.js +0 -1
  171. package/dist/railroadDiagram-RFXS5EU6-2rLqmvj_.js +0 -1
  172. package/dist/railroadDiagram-RFXS5EU6-a-pSoUg2.cjs +0 -1
  173. package/dist/remarkProcessor.server.d.ts +0 -40
  174. package/dist/requirementDiagram-TGXJPOKE-BaKLflmx.cjs +0 -1
  175. package/dist/requirementDiagram-TGXJPOKE-BlCu380H.js +0 -1
  176. package/dist/sankeyDiagram-HTMAVEWB-6lNyI55x.js +0 -1
  177. package/dist/sankeyDiagram-HTMAVEWB-DuUzdIP0.cjs +0 -1
  178. package/dist/sequenceDiagram-DBY2YBRQ-B29fl34a.cjs +0 -1
  179. package/dist/sequenceDiagram-DBY2YBRQ-sgwpzZWi.js +0 -1
  180. package/dist/simple-logger-DIfMY3fH.js +0 -1
  181. package/dist/simple-logger-DZxBpX7v.cjs +0 -1
  182. package/dist/sizeCapture-X5ZJPWSS-DAiqtb_j.cjs +0 -1
  183. package/dist/sizeCapture-X5ZJPWSS-DMDy-RCU.js +0 -1
  184. package/dist/stateDiagram-2N3HPSRC-BXIH2aOp.cjs +0 -1
  185. package/dist/stateDiagram-2N3HPSRC-DAN7ei1t.js +0 -1
  186. package/dist/stateDiagram-v2-6OUMAXLB--pCo5CzX.js +0 -1
  187. package/dist/stateDiagram-v2-6OUMAXLB-8XTokhrn.cjs +0 -1
  188. package/dist/swimlanes-5IMT3BWC-B-sXtUgS.js +0 -1
  189. package/dist/swimlanes-5IMT3BWC-BnT290KL.cjs +0 -1
  190. package/dist/swimlanesDiagram-G3AALYLV-CAEjADeH.cjs +0 -1
  191. package/dist/swimlanesDiagram-G3AALYLV-CkxURj6O.js +0 -1
  192. package/dist/test-setup.d.ts +0 -1
  193. package/dist/timeline-definition-FHXFAJF6-D47CoBOm.js +0 -1
  194. package/dist/timeline-definition-FHXFAJF6-Dqdftl5b.cjs +0 -1
  195. package/dist/utils/extractHeadings.d.ts +1 -9
  196. package/dist/utils/getFaviconUrl.d.ts +0 -5
  197. package/dist/utils/headingText.d.ts +1 -6
  198. package/dist/utils/simple-logger.d.ts +0 -63
  199. package/dist/vennDiagram-L72KCM5P-BxjgXNwH.cjs +0 -1
  200. package/dist/vennDiagram-L72KCM5P-DzcOxkzh.js +0 -1
  201. package/dist/wardleyDiagram-EHGQE667-CurWRCjn.cjs +0 -1
  202. package/dist/wardleyDiagram-EHGQE667-tZJBiyrP.js +0 -1
  203. package/dist/xychartDiagram-FW5EYKEG-D0ltrZo8.cjs +0 -1
  204. package/dist/xychartDiagram-FW5EYKEG-DRQ_o9WV.js +0 -1
  205. package/package.json +10 -12
  206. package/dist/abnfDiagram-VRR7QNED-BBmog1I4.cjs.map +0 -1
  207. package/dist/abnfDiagram-VRR7QNED-CxfTrgXf.js.map +0 -1
  208. package/dist/arc-ClGqtl_2.js.map +0 -1
  209. package/dist/arc-DKsAswGe.cjs.map +0 -1
  210. package/dist/architectureDiagram-ZJ3FMSHR-BLhnaJyB.cjs.map +0 -1
  211. package/dist/architectureDiagram-ZJ3FMSHR-Dild3kjN.js.map +0 -1
  212. package/dist/blockDiagram-677ZJIJ3-D72bpMhN.cjs.map +0 -1
  213. package/dist/blockDiagram-677ZJIJ3-DD1l8WOn.js.map +0 -1
  214. package/dist/c4Diagram-LMCZKHZV-BJkJh-kC.js.map +0 -1
  215. package/dist/c4Diagram-LMCZKHZV-D3d1d4zO.cjs.map +0 -1
  216. package/dist/channel-DE5LXIMm.cjs.map +0 -1
  217. package/dist/channel-DaGDswnD.js.map +0 -1
  218. package/dist/chunk-2Q5K7J3B-BrnUlAaZ.cjs.map +0 -1
  219. package/dist/chunk-2Q5K7J3B-DejpXtzn.js.map +0 -1
  220. package/dist/chunk-32BRIVSS-BCAuSjpE.js.map +0 -1
  221. package/dist/chunk-32BRIVSS-CDxbP_I9.cjs.map +0 -1
  222. package/dist/chunk-5VM5RSS4-C-cBAbST.cjs.map +0 -1
  223. package/dist/chunk-5VM5RSS4-DI1kbCYB.js.map +0 -1
  224. package/dist/chunk-EX3LRPZG-CVTsVkLX.js.map +0 -1
  225. package/dist/chunk-EX3LRPZG-uKd75-FB.cjs.map +0 -1
  226. package/dist/chunk-JWPE2WC7-CNFRDah7.cjs.map +0 -1
  227. package/dist/chunk-JWPE2WC7-Cu3ql0Gi.js.map +0 -1
  228. package/dist/chunk-MOJQB5TN-BZ0Sok4l.js.map +0 -1
  229. package/dist/chunk-MOJQB5TN-Bs5Jj3Zh.cjs.map +0 -1
  230. package/dist/chunk-PUDLZKDR-3RVC5ezN.js.map +0 -1
  231. package/dist/chunk-PUDLZKDR-DisfuynB.cjs.map +0 -1
  232. package/dist/chunk-RYQCIY6F-CSpf1fBI.js.map +0 -1
  233. package/dist/chunk-RYQCIY6F-xFTrTO6v.cjs.map +0 -1
  234. package/dist/chunk-V7JOEXUC-BnwuCkOT.js.map +0 -1
  235. package/dist/chunk-V7JOEXUC-BvkxRSjK.cjs.map +0 -1
  236. package/dist/chunk-VR4S4FIN-DAwCjhU3.cjs.map +0 -1
  237. package/dist/chunk-VR4S4FIN-DSW2sQDL.js.map +0 -1
  238. package/dist/chunk-XXDRQBXY-B7vX1DJv.cjs.map +0 -1
  239. package/dist/chunk-XXDRQBXY-DrE4gFtL.js.map +0 -1
  240. package/dist/classDiagram-OUVF2IWQ-BxIt89EK.cjs.map +0 -1
  241. package/dist/classDiagram-OUVF2IWQ-DlER_wIi.js.map +0 -1
  242. package/dist/classDiagram-v2-EOCWNBFH-BxIt89EK.cjs.map +0 -1
  243. package/dist/classDiagram-v2-EOCWNBFH-DlER_wIi.js.map +0 -1
  244. package/dist/cli.d.ts.map +0 -1
  245. package/dist/components/MarkdownRenderer.d.ts.map +0 -1
  246. package/dist/components/MarkdownViewer.d.ts.map +0 -1
  247. package/dist/components/MermaidDiagram.d.ts.map +0 -1
  248. package/dist/components/NodesRenderer.d.ts.map +0 -1
  249. package/dist/components/TableOfContents.d.ts.map +0 -1
  250. package/dist/components/mdastNodes/BlockLinkNode.d.ts.map +0 -1
  251. package/dist/components/mdastNodes/BlockquoteNode.d.ts.map +0 -1
  252. package/dist/components/mdastNodes/CodeNode.d.ts.map +0 -1
  253. package/dist/components/mdastNodes/DeleteNode.d.ts.map +0 -1
  254. package/dist/components/mdastNodes/EmphasisNode.d.ts.map +0 -1
  255. package/dist/components/mdastNodes/FootnoteBackLinkNode.d.ts.map +0 -1
  256. package/dist/components/mdastNodes/HTMLBlockContainerNode.d.ts.map +0 -1
  257. package/dist/components/mdastNodes/HTMLNode.d.ts.map +0 -1
  258. package/dist/components/mdastNodes/HeadingNode.d.ts.map +0 -1
  259. package/dist/components/mdastNodes/ImageNode.d.ts.map +0 -1
  260. package/dist/components/mdastNodes/InlineCodeNode.d.ts.map +0 -1
  261. package/dist/components/mdastNodes/InlineMathNode.d.ts.map +0 -1
  262. package/dist/components/mdastNodes/LinkNode.d.ts.map +0 -1
  263. package/dist/components/mdastNodes/ListItemNode.d.ts.map +0 -1
  264. package/dist/components/mdastNodes/ListNode.d.ts.map +0 -1
  265. package/dist/components/mdastNodes/MarkNode.d.ts.map +0 -1
  266. package/dist/components/mdastNodes/MathNode.d.ts.map +0 -1
  267. package/dist/components/mdastNodes/ParagraphNode.d.ts.map +0 -1
  268. package/dist/components/mdastNodes/RichLinkCard.d.ts.map +0 -1
  269. package/dist/components/mdastNodes/StrongNode.d.ts.map +0 -1
  270. package/dist/components/mdastNodes/SubscriptNode.d.ts.map +0 -1
  271. package/dist/components/mdastNodes/SuperscriptNode.d.ts.map +0 -1
  272. package/dist/components/mdastNodes/TableNode.d.ts.map +0 -1
  273. package/dist/components/mdastNodes/TextNode.d.ts.map +0 -1
  274. package/dist/components/mdastNodes/ThematicBreakNode.d.ts.map +0 -1
  275. package/dist/components/mdastNodes/TwitterEmbedNode.d.ts.map +0 -1
  276. package/dist/components/mdastNodes/YouTubeEmbedNode.d.ts.map +0 -1
  277. package/dist/components/mdastNodes/ZennDetailsNode.d.ts.map +0 -1
  278. package/dist/components/mdastNodes/ZennMessageNode.d.ts.map +0 -1
  279. package/dist/components/mermaidInteraction.d.ts.map +0 -1
  280. package/dist/components/plugins/DifyIFramePlugin.d.ts.map +0 -1
  281. package/dist/components/plugins/IFramePluginRegistry.d.ts.map +0 -1
  282. package/dist/components/plugins/index.d.ts.map +0 -1
  283. package/dist/cose-bilkent-JH36ORCC-BvnlFiZm.js.map +0 -1
  284. package/dist/cose-bilkent-JH36ORCC-BzL-a0Zv.cjs.map +0 -1
  285. package/dist/cynefin-VYW2F7L2-Bkk-F_Js.js.map +0 -1
  286. package/dist/cynefin-VYW2F7L2-MpAliYy9.cjs.map +0 -1
  287. package/dist/cynefinDiagram-TSTJHNR4-B1lNDIu_.cjs.map +0 -1
  288. package/dist/cynefinDiagram-TSTJHNR4-CUwuCyMp.js.map +0 -1
  289. package/dist/cytoscape.esm-D8x1ApSO.cjs.map +0 -1
  290. package/dist/cytoscape.esm-kVAWcYoG.js.map +0 -1
  291. package/dist/dagre-VKFMJZFB-COYURQTh.cjs.map +0 -1
  292. package/dist/dagre-VKFMJZFB-Ct0vbIs9.js.map +0 -1
  293. package/dist/defaultLocale-BgPVtth8.js.map +0 -1
  294. package/dist/defaultLocale-C4wbwF1n.cjs.map +0 -1
  295. package/dist/diagram-FQU43EPY-B5HmiJPw.js.map +0 -1
  296. package/dist/diagram-FQU43EPY-DkgdwwAT.cjs.map +0 -1
  297. package/dist/diagram-G47NLZAW-C-nfBNGF.js.map +0 -1
  298. package/dist/diagram-G47NLZAW-CcXcBx81.cjs.map +0 -1
  299. package/dist/diagram-NH7WQ7WH-BMYzS0pm.cjs.map +0 -1
  300. package/dist/diagram-NH7WQ7WH-yu8B8Q4y.js.map +0 -1
  301. package/dist/diagram-OA4YK3LP-CROsfore.js.map +0 -1
  302. package/dist/diagram-OA4YK3LP-DSeI6RLe.cjs.map +0 -1
  303. package/dist/diagram-WEI45ONY-CCJwQ42c.cjs.map +0 -1
  304. package/dist/diagram-WEI45ONY-DmPpMglv.js.map +0 -1
  305. package/dist/ebnfDiagram-CCIWWBDH-B2ck9j39.js.map +0 -1
  306. package/dist/ebnfDiagram-CCIWWBDH-D_nz1FvR.cjs.map +0 -1
  307. package/dist/erDiagram-Q63AITRT-2r-lfgSt.cjs.map +0 -1
  308. package/dist/erDiagram-Q63AITRT-BfpyxqAV.js.map +0 -1
  309. package/dist/extractHeadings-BrLI2qQF.cjs.map +0 -1
  310. package/dist/extractHeadings-Dgzd324l.js.map +0 -1
  311. package/dist/flowDiagram-23GEKE2U-D3w55eDA.cjs.map +0 -1
  312. package/dist/flowDiagram-23GEKE2U-LZTzy0Rx.js.map +0 -1
  313. package/dist/ganttDiagram-NO4QXBWP-CNhgpKSH.cjs.map +0 -1
  314. package/dist/ganttDiagram-NO4QXBWP-DR3YQ-Kd.js.map +0 -1
  315. package/dist/gen/markdown/v1/markdown_connect.d.ts.map +0 -1
  316. package/dist/gen/markdown/v1/markdown_pb.d.ts.map +0 -1
  317. package/dist/gitGraphDiagram-IHSO6WYX-CzLNLS8W.js.map +0 -1
  318. package/dist/gitGraphDiagram-IHSO6WYX-D5IYosEF.cjs.map +0 -1
  319. package/dist/graph-BgRih2Qv.cjs.map +0 -1
  320. package/dist/graph-DAHC4kPm.js.map +0 -1
  321. package/dist/index.cjs.map +0 -1
  322. package/dist/index.client.cjs.map +0 -1
  323. package/dist/index.client.d.ts.map +0 -1
  324. package/dist/index.client.js.map +0 -1
  325. package/dist/index.d.ts.map +0 -1
  326. package/dist/index.js.map +0 -1
  327. package/dist/index.server.cjs.map +0 -1
  328. package/dist/index.server.d.ts.map +0 -1
  329. package/dist/index.server.js.map +0 -1
  330. package/dist/infoDiagram-FWYZ7A6U-CBcx5GhE.js.map +0 -1
  331. package/dist/infoDiagram-FWYZ7A6U-U2OiliOP.cjs.map +0 -1
  332. package/dist/init-CHZsXQcr.cjs.map +0 -1
  333. package/dist/init-DjUOC4st.js.map +0 -1
  334. package/dist/ishikawaDiagram-FXEZZL3T-CWXT_3xh.js.map +0 -1
  335. package/dist/ishikawaDiagram-FXEZZL3T-DK3M6wrz.cjs.map +0 -1
  336. package/dist/journeyDiagram-5HDEW3XC-B-BfhPr4.cjs.map +0 -1
  337. package/dist/journeyDiagram-5HDEW3XC-DRbAj2Yz.js.map +0 -1
  338. package/dist/kanban-definition-HUTT4EX6-BvnLv2HN.cjs.map +0 -1
  339. package/dist/kanban-definition-HUTT4EX6-DtRSv2_P.js.map +0 -1
  340. package/dist/layout-DBbo_M5I.js.map +0 -1
  341. package/dist/layout-OMlh6_XH.cjs.map +0 -1
  342. package/dist/linear-B9JMAP1U.cjs.map +0 -1
  343. package/dist/linear-HTaGrbQh.js.map +0 -1
  344. package/dist/map-BvScllSQ.cjs.map +0 -1
  345. package/dist/map-DRdzG8Ho.js.map +0 -1
  346. package/dist/mindmap-definition-LN4V7U3C-4cN-VjxO.js.map +0 -1
  347. package/dist/mindmap-definition-LN4V7U3C-asDDR5DU.cjs.map +0 -1
  348. package/dist/ordinal-B6-f3MAq.js.map +0 -1
  349. package/dist/ordinal-CagbB1m8.cjs.map +0 -1
  350. package/dist/pegDiagram-2B236MQR-C3qJlDiV.cjs.map +0 -1
  351. package/dist/pegDiagram-2B236MQR-cMLC3Ggy.js.map +0 -1
  352. package/dist/pieDiagram-ENE6RG2P-D5-meW-_.cjs.map +0 -1
  353. package/dist/pieDiagram-ENE6RG2P-nk_3VO3x.js.map +0 -1
  354. package/dist/plugins/createIntentTweetLink.d.ts.map +0 -1
  355. package/dist/plugins/extractYouTubeVideoId.d.ts.map +0 -1
  356. package/dist/plugins/fetchSiteMetadata.d.ts.map +0 -1
  357. package/dist/plugins/remark-auto-heading-id.d.ts.map +0 -1
  358. package/dist/plugins/remark-block-link-metadata.d.ts.map +0 -1
  359. package/dist/plugins/remark-block-link.d.ts.map +0 -1
  360. package/dist/plugins/remark-custom-heading-id.d.ts.map +0 -1
  361. package/dist/plugins/remark-footnote-back-link.d.ts.map +0 -1
  362. package/dist/plugins/remark-html-anchor-to-link.d.ts.map +0 -1
  363. package/dist/plugins/remark-html-in-html.d.ts.map +0 -1
  364. package/dist/plugins/remark-image-size.d.ts.map +0 -1
  365. package/dist/plugins/remark-import-directive.async.server.d.ts +0 -16
  366. package/dist/plugins/remark-import-directive.async.server.d.ts.map +0 -1
  367. package/dist/plugins/remark-mark.d.ts.map +0 -1
  368. package/dist/plugins/remark-parent-node.d.ts.map +0 -1
  369. package/dist/plugins/remark-resolve-uri.async.d.ts +0 -13
  370. package/dist/plugins/remark-resolve-uri.async.d.ts.map +0 -1
  371. package/dist/plugins/remark-subscript.d.ts.map +0 -1
  372. package/dist/plugins/remark-superscript.d.ts.map +0 -1
  373. package/dist/plugins/remark-table-merge.d.ts.map +0 -1
  374. package/dist/plugins/remark-twitter-embed.d.ts.map +0 -1
  375. package/dist/plugins/remark-unwrap-block-html.d.ts.map +0 -1
  376. package/dist/plugins/remark-youtube-embed.d.ts.map +0 -1
  377. package/dist/plugins/remark-zenn-message.d.ts.map +0 -1
  378. package/dist/plugins/transformUri.async.server.d.ts +0 -13
  379. package/dist/plugins/transformUri.async.server.d.ts.map +0 -1
  380. package/dist/quadrantDiagram-ABIIQ3AL-CmqrHJ4C.cjs.map +0 -1
  381. package/dist/quadrantDiagram-ABIIQ3AL-Ctdfu4Qk.js.map +0 -1
  382. package/dist/railroadDiagram-RFXS5EU6-2rLqmvj_.js.map +0 -1
  383. package/dist/railroadDiagram-RFXS5EU6-a-pSoUg2.cjs.map +0 -1
  384. package/dist/remarkProcessor.server.d.ts.map +0 -1
  385. package/dist/requirementDiagram-TGXJPOKE-BaKLflmx.cjs.map +0 -1
  386. package/dist/requirementDiagram-TGXJPOKE-BlCu380H.js.map +0 -1
  387. package/dist/sankeyDiagram-HTMAVEWB-6lNyI55x.js.map +0 -1
  388. package/dist/sankeyDiagram-HTMAVEWB-DuUzdIP0.cjs.map +0 -1
  389. package/dist/sequenceDiagram-DBY2YBRQ-B29fl34a.cjs.map +0 -1
  390. package/dist/sequenceDiagram-DBY2YBRQ-sgwpzZWi.js.map +0 -1
  391. package/dist/simple-logger-DIfMY3fH.js.map +0 -1
  392. package/dist/simple-logger-DZxBpX7v.cjs.map +0 -1
  393. package/dist/sizeCapture-X5ZJPWSS-DAiqtb_j.cjs.map +0 -1
  394. package/dist/sizeCapture-X5ZJPWSS-DMDy-RCU.js.map +0 -1
  395. package/dist/stateDiagram-2N3HPSRC-BXIH2aOp.cjs.map +0 -1
  396. package/dist/stateDiagram-2N3HPSRC-DAN7ei1t.js.map +0 -1
  397. package/dist/stateDiagram-v2-6OUMAXLB--pCo5CzX.js.map +0 -1
  398. package/dist/stateDiagram-v2-6OUMAXLB-8XTokhrn.cjs.map +0 -1
  399. package/dist/swimlanes-5IMT3BWC-B-sXtUgS.js.map +0 -1
  400. package/dist/swimlanes-5IMT3BWC-BnT290KL.cjs.map +0 -1
  401. package/dist/swimlanesDiagram-G3AALYLV-CAEjADeH.cjs.map +0 -1
  402. package/dist/swimlanesDiagram-G3AALYLV-CkxURj6O.js.map +0 -1
  403. package/dist/test-setup.d.ts.map +0 -1
  404. package/dist/timeline-definition-FHXFAJF6-D47CoBOm.js.map +0 -1
  405. package/dist/timeline-definition-FHXFAJF6-Dqdftl5b.cjs.map +0 -1
  406. package/dist/utils/extractHeadings.d.ts.map +0 -1
  407. package/dist/utils/getFaviconUrl.d.ts.map +0 -1
  408. package/dist/utils/headingText.d.ts.map +0 -1
  409. package/dist/utils/simple-logger.d.ts.map +0 -1
  410. package/dist/vennDiagram-L72KCM5P-BxjgXNwH.cjs.map +0 -1
  411. package/dist/vennDiagram-L72KCM5P-DzcOxkzh.js.map +0 -1
  412. package/dist/wardleyDiagram-EHGQE667-CurWRCjn.cjs.map +0 -1
  413. package/dist/wardleyDiagram-EHGQE667-tZJBiyrP.js.map +0 -1
  414. package/dist/xychartDiagram-FW5EYKEG-D0ltrZo8.cjs.map +0 -1
  415. package/dist/xychartDiagram-FW5EYKEG-DRQ_o9WV.js.map +0 -1
@@ -1,2 +1 @@
1
1
  "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const W=require("./extractHeadings-BrLI2qQF.cjs"),J=require("./cytoscape.esm-D8x1ApSO.cjs");var k={exports:{}},Z={exports:{}},Q={exports:{}},ht=Q.exports,q;function lt(){return q||(q=1,(function(G,b){(function(I,L){G.exports=L()})(ht,function(){return(function(N){var I={};function L(o){if(I[o])return I[o].exports;var e=I[o]={i:o,l:!1,exports:{}};return N[o].call(e.exports,e,e.exports,L),e.l=!0,e.exports}return L.m=N,L.c=I,L.i=function(o){return o},L.d=function(o,e,t){L.o(o,e)||Object.defineProperty(o,e,{configurable:!1,enumerable:!0,get:t})},L.n=function(o){var e=o&&o.__esModule?function(){return o.default}:function(){return o};return L.d(e,"a",e),e},L.o=function(o,e){return Object.prototype.hasOwnProperty.call(o,e)},L.p="",L(L.s=26)})([(function(N,I,L){function o(){}o.QUALITY=1,o.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,o.DEFAULT_INCREMENTAL=!1,o.DEFAULT_ANIMATION_ON_LAYOUT=!0,o.DEFAULT_ANIMATION_DURING_LAYOUT=!1,o.DEFAULT_ANIMATION_PERIOD=50,o.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,o.DEFAULT_GRAPH_MARGIN=15,o.NODE_DIMENSIONS_INCLUDE_LABELS=!1,o.SIMPLE_NODE_SIZE=40,o.SIMPLE_NODE_HALF_SIZE=o.SIMPLE_NODE_SIZE/2,o.EMPTY_COMPOUND_NODE_SIZE=40,o.MIN_EDGE_LENGTH=1,o.WORLD_BOUNDARY=1e6,o.INITIAL_WORLD_BOUNDARY=o.WORLD_BOUNDARY/1e3,o.WORLD_CENTER_X=1200,o.WORLD_CENTER_Y=900,N.exports=o}),(function(N,I,L){var o=L(2),e=L(8),t=L(9);function i(g,n,d){o.call(this,d),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=d,this.bendpoints=[],this.source=g,this.target=n}i.prototype=Object.create(o.prototype);for(var l in o)i[l]=o[l];i.prototype.getSource=function(){return this.source},i.prototype.getTarget=function(){return this.target},i.prototype.isInterGraph=function(){return this.isInterGraph},i.prototype.getLength=function(){return this.length},i.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},i.prototype.getBendpoints=function(){return this.bendpoints},i.prototype.getLca=function(){return this.lca},i.prototype.getSourceInLca=function(){return this.sourceInLca},i.prototype.getTargetInLca=function(){return this.targetInLca},i.prototype.getOtherEnd=function(g){if(this.source===g)return this.target;if(this.target===g)return this.source;throw"Node is not incident with this edge"},i.prototype.getOtherEndInGraph=function(g,n){for(var d=this.getOtherEnd(g),r=n.getGraphManager().getRoot();;){if(d.getOwner()==n)return d;if(d.getOwner()==r)break;d=d.getOwner().getParent()}return null},i.prototype.updateLength=function(){var g=new Array(4);this.isOverlapingSourceAndTarget=e.getIntersection(this.target.getRect(),this.source.getRect(),g),this.isOverlapingSourceAndTarget||(this.lengthX=g[0]-g[2],this.lengthY=g[1]-g[3],Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},i.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1&&(this.lengthX=t.sign(this.lengthX)),Math.abs(this.lengthY)<1&&(this.lengthY=t.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},N.exports=i}),(function(N,I,L){function o(e){this.vGraphObject=e}N.exports=o}),(function(N,I,L){var o=L(2),e=L(10),t=L(13),i=L(0),l=L(16),g=L(4);function n(r,h,a,p){a==null&&p==null&&(p=h),o.call(this,p),r.graphManager!=null&&(r=r.graphManager),this.estimatedSize=e.MIN_VALUE,this.inclusionTreeDepth=e.MAX_VALUE,this.vGraphObject=p,this.edges=[],this.graphManager=r,a!=null&&h!=null?this.rect=new t(h.x,h.y,a.width,a.height):this.rect=new t}n.prototype=Object.create(o.prototype);for(var d in o)n[d]=o[d];n.prototype.getEdges=function(){return this.edges},n.prototype.getChild=function(){return this.child},n.prototype.getOwner=function(){return this.owner},n.prototype.getWidth=function(){return this.rect.width},n.prototype.setWidth=function(r){this.rect.width=r},n.prototype.getHeight=function(){return this.rect.height},n.prototype.setHeight=function(r){this.rect.height=r},n.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},n.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},n.prototype.getCenter=function(){return new g(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},n.prototype.getLocation=function(){return new g(this.rect.x,this.rect.y)},n.prototype.getRect=function(){return this.rect},n.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},n.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},n.prototype.setRect=function(r,h){this.rect.x=r.x,this.rect.y=r.y,this.rect.width=h.width,this.rect.height=h.height},n.prototype.setCenter=function(r,h){this.rect.x=r-this.rect.width/2,this.rect.y=h-this.rect.height/2},n.prototype.setLocation=function(r,h){this.rect.x=r,this.rect.y=h},n.prototype.moveBy=function(r,h){this.rect.x+=r,this.rect.y+=h},n.prototype.getEdgeListToNode=function(r){var h=[],a=this;return a.edges.forEach(function(p){if(p.target==r){if(p.source!=a)throw"Incorrect edge source!";h.push(p)}}),h},n.prototype.getEdgesBetween=function(r){var h=[],a=this;return a.edges.forEach(function(p){if(!(p.source==a||p.target==a))throw"Incorrect edge source and/or target";(p.target==r||p.source==r)&&h.push(p)}),h},n.prototype.getNeighborsList=function(){var r=new Set,h=this;return h.edges.forEach(function(a){if(a.source==h)r.add(a.target);else{if(a.target!=h)throw"Incorrect incidency!";r.add(a.source)}}),r},n.prototype.withChildren=function(){var r=new Set,h,a;if(r.add(this),this.child!=null)for(var p=this.child.getNodes(),v=0;v<p.length;v++)h=p[v],a=h.withChildren(),a.forEach(function(D){r.add(D)});return r},n.prototype.getNoOfChildren=function(){var r=0,h;if(this.child==null)r=1;else for(var a=this.child.getNodes(),p=0;p<a.length;p++)h=a[p],r+=h.getNoOfChildren();return r==0&&(r=1),r},n.prototype.getEstimatedSize=function(){if(this.estimatedSize==e.MIN_VALUE)throw"assert failed";return this.estimatedSize},n.prototype.calcEstimatedSize=function(){return this.child==null?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},n.prototype.scatter=function(){var r,h,a=-i.INITIAL_WORLD_BOUNDARY,p=i.INITIAL_WORLD_BOUNDARY;r=i.WORLD_CENTER_X+l.nextDouble()*(p-a)+a;var v=-i.INITIAL_WORLD_BOUNDARY,D=i.INITIAL_WORLD_BOUNDARY;h=i.WORLD_CENTER_Y+l.nextDouble()*(D-v)+v,this.rect.x=r,this.rect.y=h},n.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var r=this.getChild();if(r.updateBounds(!0),this.rect.x=r.getLeft(),this.rect.y=r.getTop(),this.setWidth(r.getRight()-r.getLeft()),this.setHeight(r.getBottom()-r.getTop()),i.NODE_DIMENSIONS_INCLUDE_LABELS){var h=r.getRight()-r.getLeft(),a=r.getBottom()-r.getTop();this.labelWidth>h&&(this.rect.x-=(this.labelWidth-h)/2,this.setWidth(this.labelWidth)),this.labelHeight>a&&(this.labelPos=="center"?this.rect.y-=(this.labelHeight-a)/2:this.labelPos=="top"&&(this.rect.y-=this.labelHeight-a),this.setHeight(this.labelHeight))}}},n.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==e.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},n.prototype.transform=function(r){var h=this.rect.x;h>i.WORLD_BOUNDARY?h=i.WORLD_BOUNDARY:h<-i.WORLD_BOUNDARY&&(h=-i.WORLD_BOUNDARY);var a=this.rect.y;a>i.WORLD_BOUNDARY?a=i.WORLD_BOUNDARY:a<-i.WORLD_BOUNDARY&&(a=-i.WORLD_BOUNDARY);var p=new g(h,a),v=r.inverseTransformPoint(p);this.setLocation(v.x,v.y)},n.prototype.getLeft=function(){return this.rect.x},n.prototype.getRight=function(){return this.rect.x+this.rect.width},n.prototype.getTop=function(){return this.rect.y},n.prototype.getBottom=function(){return this.rect.y+this.rect.height},n.prototype.getParent=function(){return this.owner==null?null:this.owner.getParent()},N.exports=n}),(function(N,I,L){function o(e,t){e==null&&t==null?(this.x=0,this.y=0):(this.x=e,this.y=t)}o.prototype.getX=function(){return this.x},o.prototype.getY=function(){return this.y},o.prototype.setX=function(e){this.x=e},o.prototype.setY=function(e){this.y=e},o.prototype.getDifference=function(e){return new DimensionD(this.x-e.x,this.y-e.y)},o.prototype.getCopy=function(){return new o(this.x,this.y)},o.prototype.translate=function(e){return this.x+=e.width,this.y+=e.height,this},N.exports=o}),(function(N,I,L){var o=L(2),e=L(10),t=L(0),i=L(6),l=L(3),g=L(1),n=L(13),d=L(12),r=L(11);function h(p,v,D){o.call(this,D),this.estimatedSize=e.MIN_VALUE,this.margin=t.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=p,v!=null&&v instanceof i?this.graphManager=v:v!=null&&v instanceof Layout&&(this.graphManager=v.graphManager)}h.prototype=Object.create(o.prototype);for(var a in o)h[a]=o[a];h.prototype.getNodes=function(){return this.nodes},h.prototype.getEdges=function(){return this.edges},h.prototype.getGraphManager=function(){return this.graphManager},h.prototype.getParent=function(){return this.parent},h.prototype.getLeft=function(){return this.left},h.prototype.getRight=function(){return this.right},h.prototype.getTop=function(){return this.top},h.prototype.getBottom=function(){return this.bottom},h.prototype.isConnected=function(){return this.isConnected},h.prototype.add=function(p,v,D){if(v==null&&D==null){var u=p;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(u)>-1)throw"Node already in graph!";return u.owner=this,this.getNodes().push(u),u}else{var T=p;if(!(this.getNodes().indexOf(v)>-1&&this.getNodes().indexOf(D)>-1))throw"Source or target not in graph!";if(!(v.owner==D.owner&&v.owner==this))throw"Both owners must be this graph!";return v.owner!=D.owner?null:(T.source=v,T.target=D,T.isInterGraph=!1,this.getEdges().push(T),v.edges.push(T),D!=v&&D.edges.push(T),T)}},h.prototype.remove=function(p){var v=p;if(p instanceof l){if(v==null)throw"Node is null!";if(!(v.owner!=null&&v.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";for(var D=v.edges.slice(),u,T=D.length,y=0;y<T;y++)u=D[y],u.isInterGraph?this.graphManager.remove(u):u.source.owner.remove(u);var O=this.nodes.indexOf(v);if(O==-1)throw"Node not in owner node list!";this.nodes.splice(O,1)}else if(p instanceof g){var u=p;if(u==null)throw"Edge is null!";if(!(u.source!=null&&u.target!=null))throw"Source and/or target is null!";if(!(u.source.owner!=null&&u.target.owner!=null&&u.source.owner==this&&u.target.owner==this))throw"Source and/or target owner is invalid!";var s=u.source.edges.indexOf(u),f=u.target.edges.indexOf(u);if(!(s>-1&&f>-1))throw"Source and/or target doesn't know this edge!";u.source.edges.splice(s,1),u.target!=u.source&&u.target.edges.splice(f,1);var O=u.source.owner.getEdges().indexOf(u);if(O==-1)throw"Not in owner's edge list!";u.source.owner.getEdges().splice(O,1)}},h.prototype.updateLeftTop=function(){for(var p=e.MAX_VALUE,v=e.MAX_VALUE,D,u,T,y=this.getNodes(),O=y.length,s=0;s<O;s++){var f=y[s];D=f.getTop(),u=f.getLeft(),p>D&&(p=D),v>u&&(v=u)}return p==e.MAX_VALUE?null:(y[0].getParent().paddingLeft!=null?T=y[0].getParent().paddingLeft:T=this.margin,this.left=v-T,this.top=p-T,new d(this.left,this.top))},h.prototype.updateBounds=function(p){for(var v=e.MAX_VALUE,D=-e.MAX_VALUE,u=e.MAX_VALUE,T=-e.MAX_VALUE,y,O,s,f,c,E=this.nodes,A=E.length,m=0;m<A;m++){var C=E[m];p&&C.child!=null&&C.updateBounds(),y=C.getLeft(),O=C.getRight(),s=C.getTop(),f=C.getBottom(),v>y&&(v=y),D<O&&(D=O),u>s&&(u=s),T<f&&(T=f)}var R=new n(v,u,D-v,T-u);v==e.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),E[0].getParent().paddingLeft!=null?c=E[0].getParent().paddingLeft:c=this.margin,this.left=R.x-c,this.right=R.x+R.width+c,this.top=R.y-c,this.bottom=R.y+R.height+c},h.calculateBounds=function(p){for(var v=e.MAX_VALUE,D=-e.MAX_VALUE,u=e.MAX_VALUE,T=-e.MAX_VALUE,y,O,s,f,c=p.length,E=0;E<c;E++){var A=p[E];y=A.getLeft(),O=A.getRight(),s=A.getTop(),f=A.getBottom(),v>y&&(v=y),D<O&&(D=O),u>s&&(u=s),T<f&&(T=f)}var m=new n(v,u,D-v,T-u);return m},h.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},h.prototype.getEstimatedSize=function(){if(this.estimatedSize==e.MIN_VALUE)throw"assert failed";return this.estimatedSize},h.prototype.calcEstimatedSize=function(){for(var p=0,v=this.nodes,D=v.length,u=0;u<D;u++){var T=v[u];p+=T.calcEstimatedSize()}return p==0?this.estimatedSize=t.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=p/Math.sqrt(this.nodes.length),this.estimatedSize},h.prototype.updateConnected=function(){var p=this;if(this.nodes.length==0){this.isConnected=!0;return}var v=new r,D=new Set,u=this.nodes[0],T,y,O=u.withChildren();for(O.forEach(function(m){v.push(m),D.add(m)});v.length!==0;){u=v.shift(),T=u.getEdges();for(var s=T.length,f=0;f<s;f++){var c=T[f];if(y=c.getOtherEndInGraph(u,this),y!=null&&!D.has(y)){var E=y.withChildren();E.forEach(function(m){v.push(m),D.add(m)})}}}if(this.isConnected=!1,D.size>=this.nodes.length){var A=0;D.forEach(function(m){m.owner==p&&A++}),A==this.nodes.length&&(this.isConnected=!0)}},N.exports=h}),(function(N,I,L){var o,e=L(1);function t(i){o=L(5),this.layout=i,this.graphs=[],this.edges=[]}t.prototype.addRoot=function(){var i=this.layout.newGraph(),l=this.layout.newNode(null),g=this.add(i,l);return this.setRootGraph(g),this.rootGraph},t.prototype.add=function(i,l,g,n,d){if(g==null&&n==null&&d==null){if(i==null)throw"Graph is null!";if(l==null)throw"Parent node is null!";if(this.graphs.indexOf(i)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(i),i.parent!=null)throw"Already has a parent!";if(l.child!=null)throw"Already has a child!";return i.parent=l,l.child=i,i}else{d=g,n=l,g=i;var r=n.getOwner(),h=d.getOwner();if(!(r!=null&&r.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(h!=null&&h.getGraphManager()==this))throw"Target not in this graph mgr!";if(r==h)return g.isInterGraph=!1,r.add(g,n,d);if(g.isInterGraph=!0,g.source=n,g.target=d,this.edges.indexOf(g)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(g),!(g.source!=null&&g.target!=null))throw"Edge source and/or target is null!";if(!(g.source.edges.indexOf(g)==-1&&g.target.edges.indexOf(g)==-1))throw"Edge already in source and/or target incidency list!";return g.source.edges.push(g),g.target.edges.push(g),g}},t.prototype.remove=function(i){if(i instanceof o){var l=i;if(l.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(l==this.rootGraph||l.parent!=null&&l.parent.graphManager==this))throw"Invalid parent node!";var g=[];g=g.concat(l.getEdges());for(var n,d=g.length,r=0;r<d;r++)n=g[r],l.remove(n);var h=[];h=h.concat(l.getNodes());var a;d=h.length;for(var r=0;r<d;r++)a=h[r],l.remove(a);l==this.rootGraph&&this.setRootGraph(null);var p=this.graphs.indexOf(l);this.graphs.splice(p,1),l.parent=null}else if(i instanceof e){if(n=i,n==null)throw"Edge is null!";if(!n.isInterGraph)throw"Not an inter-graph edge!";if(!(n.source!=null&&n.target!=null))throw"Source and/or target is null!";if(!(n.source.edges.indexOf(n)!=-1&&n.target.edges.indexOf(n)!=-1))throw"Source and/or target doesn't know this edge!";var p=n.source.edges.indexOf(n);if(n.source.edges.splice(p,1),p=n.target.edges.indexOf(n),n.target.edges.splice(p,1),!(n.source.owner!=null&&n.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(n.source.owner.getGraphManager().edges.indexOf(n)==-1)throw"Not in owner graph manager's edge list!";var p=n.source.owner.getGraphManager().edges.indexOf(n);n.source.owner.getGraphManager().edges.splice(p,1)}},t.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},t.prototype.getGraphs=function(){return this.graphs},t.prototype.getAllNodes=function(){if(this.allNodes==null){for(var i=[],l=this.getGraphs(),g=l.length,n=0;n<g;n++)i=i.concat(l[n].getNodes());this.allNodes=i}return this.allNodes},t.prototype.resetAllNodes=function(){this.allNodes=null},t.prototype.resetAllEdges=function(){this.allEdges=null},t.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},t.prototype.getAllEdges=function(){if(this.allEdges==null){var i=[],l=this.getGraphs();l.length;for(var g=0;g<l.length;g++)i=i.concat(l[g].getEdges());i=i.concat(this.edges),this.allEdges=i}return this.allEdges},t.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},t.prototype.setAllNodesToApplyGravitation=function(i){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=i},t.prototype.getRoot=function(){return this.rootGraph},t.prototype.setRootGraph=function(i){if(i.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=i,i.parent==null&&(i.parent=this.layout.newNode("Root node"))},t.prototype.getLayout=function(){return this.layout},t.prototype.isOneAncestorOfOther=function(i,l){if(!(i!=null&&l!=null))throw"assert failed";if(i==l)return!0;var g=i.getOwner(),n;do{if(n=g.getParent(),n==null)break;if(n==l)return!0;if(g=n.getOwner(),g==null)break}while(!0);g=l.getOwner();do{if(n=g.getParent(),n==null)break;if(n==i)return!0;if(g=n.getOwner(),g==null)break}while(!0);return!1},t.prototype.calcLowestCommonAncestors=function(){for(var i,l,g,n,d,r=this.getAllEdges(),h=r.length,a=0;a<h;a++){if(i=r[a],l=i.source,g=i.target,i.lca=null,i.sourceInLca=l,i.targetInLca=g,l==g){i.lca=l.getOwner();continue}for(n=l.getOwner();i.lca==null;){for(i.targetInLca=g,d=g.getOwner();i.lca==null;){if(d==n){i.lca=d;break}if(d==this.rootGraph)break;if(i.lca!=null)throw"assert failed";i.targetInLca=d.getParent(),d=i.targetInLca.getOwner()}if(n==this.rootGraph)break;i.lca==null&&(i.sourceInLca=n.getParent(),n=i.sourceInLca.getOwner())}if(i.lca==null)throw"assert failed"}},t.prototype.calcLowestCommonAncestor=function(i,l){if(i==l)return i.getOwner();var g=i.getOwner();do{if(g==null)break;var n=l.getOwner();do{if(n==null)break;if(n==g)return n;n=n.getParent().getOwner()}while(!0);g=g.getParent().getOwner()}while(!0);return g},t.prototype.calcInclusionTreeDepths=function(i,l){i==null&&l==null&&(i=this.rootGraph,l=1);for(var g,n=i.getNodes(),d=n.length,r=0;r<d;r++)g=n[r],g.inclusionTreeDepth=l,g.child!=null&&this.calcInclusionTreeDepths(g.child,l+1)},t.prototype.includesInvalidEdge=function(){for(var i,l=this.edges.length,g=0;g<l;g++)if(i=this.edges[g],this.isOneAncestorOfOther(i.source,i.target))return!0;return!1},N.exports=t}),(function(N,I,L){var o=L(0);function e(){}for(var t in o)e[t]=o[t];e.MAX_ITERATIONS=2500,e.DEFAULT_EDGE_LENGTH=50,e.DEFAULT_SPRING_STRENGTH=.45,e.DEFAULT_REPULSION_STRENGTH=4500,e.DEFAULT_GRAVITY_STRENGTH=.4,e.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,e.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,e.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,e.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,e.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,e.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,e.COOLING_ADAPTATION_FACTOR=.33,e.ADAPTATION_LOWER_NODE_LIMIT=1e3,e.ADAPTATION_UPPER_NODE_LIMIT=5e3,e.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,e.MAX_NODE_DISPLACEMENT=e.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,e.MIN_REPULSION_DIST=e.DEFAULT_EDGE_LENGTH/10,e.CONVERGENCE_CHECK_PERIOD=100,e.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,e.MIN_EDGE_LENGTH=1,e.GRID_CALCULATION_CHECK_PERIOD=10,N.exports=e}),(function(N,I,L){var o=L(12);function e(){}e.calcSeparationAmount=function(t,i,l,g){if(!t.intersects(i))throw"assert failed";var n=new Array(2);this.decideDirectionsForOverlappingNodes(t,i,n),l[0]=Math.min(t.getRight(),i.getRight())-Math.max(t.x,i.x),l[1]=Math.min(t.getBottom(),i.getBottom())-Math.max(t.y,i.y),t.getX()<=i.getX()&&t.getRight()>=i.getRight()?l[0]+=Math.min(i.getX()-t.getX(),t.getRight()-i.getRight()):i.getX()<=t.getX()&&i.getRight()>=t.getRight()&&(l[0]+=Math.min(t.getX()-i.getX(),i.getRight()-t.getRight())),t.getY()<=i.getY()&&t.getBottom()>=i.getBottom()?l[1]+=Math.min(i.getY()-t.getY(),t.getBottom()-i.getBottom()):i.getY()<=t.getY()&&i.getBottom()>=t.getBottom()&&(l[1]+=Math.min(t.getY()-i.getY(),i.getBottom()-t.getBottom()));var d=Math.abs((i.getCenterY()-t.getCenterY())/(i.getCenterX()-t.getCenterX()));i.getCenterY()===t.getCenterY()&&i.getCenterX()===t.getCenterX()&&(d=1);var r=d*l[0],h=l[1]/d;l[0]<h?h=l[0]:r=l[1],l[0]=-1*n[0]*(h/2+g),l[1]=-1*n[1]*(r/2+g)},e.decideDirectionsForOverlappingNodes=function(t,i,l){t.getCenterX()<i.getCenterX()?l[0]=-1:l[0]=1,t.getCenterY()<i.getCenterY()?l[1]=-1:l[1]=1},e.getIntersection2=function(t,i,l){var g=t.getCenterX(),n=t.getCenterY(),d=i.getCenterX(),r=i.getCenterY();if(t.intersects(i))return l[0]=g,l[1]=n,l[2]=d,l[3]=r,!0;var h=t.getX(),a=t.getY(),p=t.getRight(),v=t.getX(),D=t.getBottom(),u=t.getRight(),T=t.getWidthHalf(),y=t.getHeightHalf(),O=i.getX(),s=i.getY(),f=i.getRight(),c=i.getX(),E=i.getBottom(),A=i.getRight(),m=i.getWidthHalf(),C=i.getHeightHalf(),R=!1,M=!1;if(g===d){if(n>r)return l[0]=g,l[1]=a,l[2]=d,l[3]=E,!1;if(n<r)return l[0]=g,l[1]=D,l[2]=d,l[3]=s,!1}else if(n===r){if(g>d)return l[0]=h,l[1]=n,l[2]=f,l[3]=r,!1;if(g<d)return l[0]=p,l[1]=n,l[2]=O,l[3]=r,!1}else{var S=t.height/t.width,_=i.height/i.width,w=(r-n)/(d-g),x=void 0,F=void 0,P=void 0,U=void 0,Y=void 0,X=void 0;if(-S===w?g>d?(l[0]=v,l[1]=D,R=!0):(l[0]=p,l[1]=a,R=!0):S===w&&(g>d?(l[0]=h,l[1]=a,R=!0):(l[0]=u,l[1]=D,R=!0)),-_===w?d>g?(l[2]=c,l[3]=E,M=!0):(l[2]=f,l[3]=s,M=!0):_===w&&(d>g?(l[2]=O,l[3]=s,M=!0):(l[2]=A,l[3]=E,M=!0)),R&&M)return!1;if(g>d?n>r?(x=this.getCardinalDirection(S,w,4),F=this.getCardinalDirection(_,w,2)):(x=this.getCardinalDirection(-S,w,3),F=this.getCardinalDirection(-_,w,1)):n>r?(x=this.getCardinalDirection(-S,w,1),F=this.getCardinalDirection(-_,w,3)):(x=this.getCardinalDirection(S,w,2),F=this.getCardinalDirection(_,w,4)),!R)switch(x){case 1:U=a,P=g+-y/w,l[0]=P,l[1]=U;break;case 2:P=u,U=n+T*w,l[0]=P,l[1]=U;break;case 3:U=D,P=g+y/w,l[0]=P,l[1]=U;break;case 4:P=v,U=n+-T*w,l[0]=P,l[1]=U;break}if(!M)switch(F){case 1:X=s,Y=d+-C/w,l[2]=Y,l[3]=X;break;case 2:Y=A,X=r+m*w,l[2]=Y,l[3]=X;break;case 3:X=E,Y=d+C/w,l[2]=Y,l[3]=X;break;case 4:Y=c,X=r+-m*w,l[2]=Y,l[3]=X;break}}return!1},e.getCardinalDirection=function(t,i,l){return t>i?l:1+l%4},e.getIntersection=function(t,i,l,g){if(g==null)return this.getIntersection2(t,i,l);var n=t.x,d=t.y,r=i.x,h=i.y,a=l.x,p=l.y,v=g.x,D=g.y,u=void 0,T=void 0,y=void 0,O=void 0,s=void 0,f=void 0,c=void 0,E=void 0,A=void 0;return y=h-d,s=n-r,c=r*d-n*h,O=D-p,f=a-v,E=v*p-a*D,A=y*f-O*s,A===0?null:(u=(s*E-f*c)/A,T=(O*c-y*E)/A,new o(u,T))},e.angleOfVector=function(t,i,l,g){var n=void 0;return t!==l?(n=Math.atan((g-i)/(l-t)),l<t?n+=Math.PI:g<i&&(n+=this.TWO_PI)):g<i?n=this.ONE_AND_HALF_PI:n=this.HALF_PI,n},e.doIntersect=function(t,i,l,g){var n=t.x,d=t.y,r=i.x,h=i.y,a=l.x,p=l.y,v=g.x,D=g.y,u=(r-n)*(D-p)-(v-a)*(h-d);if(u===0)return!1;var T=((D-p)*(v-n)+(a-v)*(D-d))/u,y=((d-h)*(v-n)+(r-n)*(D-d))/u;return 0<T&&T<1&&0<y&&y<1},e.HALF_PI=.5*Math.PI,e.ONE_AND_HALF_PI=1.5*Math.PI,e.TWO_PI=2*Math.PI,e.THREE_PI=3*Math.PI,N.exports=e}),(function(N,I,L){function o(){}o.sign=function(e){return e>0?1:e<0?-1:0},o.floor=function(e){return e<0?Math.ceil(e):Math.floor(e)},o.ceil=function(e){return e<0?Math.floor(e):Math.ceil(e)},N.exports=o}),(function(N,I,L){function o(){}o.MAX_VALUE=2147483647,o.MIN_VALUE=-2147483648,N.exports=o}),(function(N,I,L){var o=(function(){function n(d,r){for(var h=0;h<r.length;h++){var a=r[h];a.enumerable=a.enumerable||!1,a.configurable=!0,"value"in a&&(a.writable=!0),Object.defineProperty(d,a.key,a)}}return function(d,r,h){return r&&n(d.prototype,r),h&&n(d,h),d}})();function e(n,d){if(!(n instanceof d))throw new TypeError("Cannot call a class as a function")}var t=function(d){return{value:d,next:null,prev:null}},i=function(d,r,h,a){return d!==null?d.next=r:a.head=r,h!==null?h.prev=r:a.tail=r,r.prev=d,r.next=h,a.length++,r},l=function(d,r){var h=d.prev,a=d.next;return h!==null?h.next=a:r.head=a,a!==null?a.prev=h:r.tail=h,d.prev=d.next=null,r.length--,d},g=(function(){function n(d){var r=this;e(this,n),this.length=0,this.head=null,this.tail=null,d?.forEach(function(h){return r.push(h)})}return o(n,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(r,h){return i(h.prev,t(r),h,this)}},{key:"insertAfter",value:function(r,h){return i(h,t(r),h.next,this)}},{key:"insertNodeBefore",value:function(r,h){return i(h.prev,r,h,this)}},{key:"insertNodeAfter",value:function(r,h){return i(h,r,h.next,this)}},{key:"push",value:function(r){return i(this.tail,t(r),null,this)}},{key:"unshift",value:function(r){return i(null,t(r),this.head,this)}},{key:"remove",value:function(r){return l(r,this)}},{key:"pop",value:function(){return l(this.tail,this).value}},{key:"popNode",value:function(){return l(this.tail,this)}},{key:"shift",value:function(){return l(this.head,this).value}},{key:"shiftNode",value:function(){return l(this.head,this)}},{key:"get_object_at",value:function(r){if(r<=this.length()){for(var h=1,a=this.head;h<r;)a=a.next,h++;return a.value}}},{key:"set_object_at",value:function(r,h){if(r<=this.length()){for(var a=1,p=this.head;a<r;)p=p.next,a++;p.value=h}}}]),n})();N.exports=g}),(function(N,I,L){function o(e,t,i){this.x=null,this.y=null,e==null&&t==null&&i==null?(this.x=0,this.y=0):typeof e=="number"&&typeof t=="number"&&i==null?(this.x=e,this.y=t):e.constructor.name=="Point"&&t==null&&i==null&&(i=e,this.x=i.x,this.y=i.y)}o.prototype.getX=function(){return this.x},o.prototype.getY=function(){return this.y},o.prototype.getLocation=function(){return new o(this.x,this.y)},o.prototype.setLocation=function(e,t,i){e.constructor.name=="Point"&&t==null&&i==null?(i=e,this.setLocation(i.x,i.y)):typeof e=="number"&&typeof t=="number"&&i==null&&(parseInt(e)==e&&parseInt(t)==t?this.move(e,t):(this.x=Math.floor(e+.5),this.y=Math.floor(t+.5)))},o.prototype.move=function(e,t){this.x=e,this.y=t},o.prototype.translate=function(e,t){this.x+=e,this.y+=t},o.prototype.equals=function(e){if(e.constructor.name=="Point"){var t=e;return this.x==t.x&&this.y==t.y}return this==e},o.prototype.toString=function(){return new o().constructor.name+"[x="+this.x+",y="+this.y+"]"},N.exports=o}),(function(N,I,L){function o(e,t,i,l){this.x=0,this.y=0,this.width=0,this.height=0,e!=null&&t!=null&&i!=null&&l!=null&&(this.x=e,this.y=t,this.width=i,this.height=l)}o.prototype.getX=function(){return this.x},o.prototype.setX=function(e){this.x=e},o.prototype.getY=function(){return this.y},o.prototype.setY=function(e){this.y=e},o.prototype.getWidth=function(){return this.width},o.prototype.setWidth=function(e){this.width=e},o.prototype.getHeight=function(){return this.height},o.prototype.setHeight=function(e){this.height=e},o.prototype.getRight=function(){return this.x+this.width},o.prototype.getBottom=function(){return this.y+this.height},o.prototype.intersects=function(e){return!(this.getRight()<e.x||this.getBottom()<e.y||e.getRight()<this.x||e.getBottom()<this.y)},o.prototype.getCenterX=function(){return this.x+this.width/2},o.prototype.getMinX=function(){return this.getX()},o.prototype.getMaxX=function(){return this.getX()+this.width},o.prototype.getCenterY=function(){return this.y+this.height/2},o.prototype.getMinY=function(){return this.getY()},o.prototype.getMaxY=function(){return this.getY()+this.height},o.prototype.getWidthHalf=function(){return this.width/2},o.prototype.getHeightHalf=function(){return this.height/2},N.exports=o}),(function(N,I,L){var o=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function e(){}e.lastID=0,e.createID=function(t){return e.isPrimitive(t)?t:(t.uniqueID!=null||(t.uniqueID=e.getString(),e.lastID++),t.uniqueID)},e.getString=function(t){return t==null&&(t=e.lastID),"Object#"+t},e.isPrimitive=function(t){var i=typeof t>"u"?"undefined":o(t);return t==null||i!="object"&&i!="function"},N.exports=e}),(function(N,I,L){function o(a){if(Array.isArray(a)){for(var p=0,v=Array(a.length);p<a.length;p++)v[p]=a[p];return v}else return Array.from(a)}var e=L(0),t=L(6),i=L(3),l=L(1),g=L(5),n=L(4),d=L(17),r=L(27);function h(a){r.call(this),this.layoutQuality=e.QUALITY,this.createBendsAsNeeded=e.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=e.DEFAULT_INCREMENTAL,this.animationOnLayout=e.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=e.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=e.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=e.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new t(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,a!=null&&(this.isRemoteUse=a)}h.RANDOM_SEED=1,h.prototype=Object.create(r.prototype),h.prototype.getGraphManager=function(){return this.graphManager},h.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},h.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},h.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},h.prototype.newGraphManager=function(){var a=new t(this);return this.graphManager=a,a},h.prototype.newGraph=function(a){return new g(null,this.graphManager,a)},h.prototype.newNode=function(a){return new i(this.graphManager,a)},h.prototype.newEdge=function(a){return new l(null,null,a)},h.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},h.prototype.runLayout=function(){this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters();var a;return this.checkLayoutSuccess()?a=!1:a=this.layout(),e.ANIMATE==="during"?!1:(a&&(this.isSubLayout||this.doPostLayout()),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,a)},h.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},h.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var a=this.graphManager.getAllEdges(),p=0;p<a.length;p++)a[p];for(var v=this.graphManager.getRoot().getNodes(),p=0;p<v.length;p++)v[p];this.update(this.graphManager.getRoot())}},h.prototype.update=function(a){if(a==null)this.update2();else if(a instanceof i){var p=a;if(p.getChild()!=null)for(var v=p.getChild().getNodes(),D=0;D<v.length;D++)update(v[D]);if(p.vGraphObject!=null){var u=p.vGraphObject;u.update(p)}}else if(a instanceof l){var T=a;if(T.vGraphObject!=null){var y=T.vGraphObject;y.update(T)}}else if(a instanceof g){var O=a;if(O.vGraphObject!=null){var s=O.vGraphObject;s.update(O)}}},h.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=e.QUALITY,this.animationDuringLayout=e.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=e.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=e.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=e.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=e.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=e.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},h.prototype.transform=function(a){if(a==null)this.transform(new n(0,0));else{var p=new d,v=this.graphManager.getRoot().updateLeftTop();if(v!=null){p.setWorldOrgX(a.x),p.setWorldOrgY(a.y),p.setDeviceOrgX(v.x),p.setDeviceOrgY(v.y);for(var D=this.getAllNodes(),u,T=0;T<D.length;T++)u=D[T],u.transform(p)}}},h.prototype.positionNodesRandomly=function(a){if(a==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var p,v,D=a.getNodes(),u=0;u<D.length;u++)p=D[u],v=p.getChild(),v==null||v.getNodes().length==0?p.scatter():(this.positionNodesRandomly(v),p.updateBounds())},h.prototype.getFlatForest=function(){for(var a=[],p=!0,v=this.graphManager.getRoot().getNodes(),D=!0,u=0;u<v.length;u++)v[u].getChild()!=null&&(D=!1);if(!D)return a;var T=new Set,y=[],O=new Map,s=[];for(s=s.concat(v);s.length>0&&p;){for(y.push(s[0]);y.length>0&&p;){var f=y[0];y.splice(0,1),T.add(f);for(var c=f.getEdges(),u=0;u<c.length;u++){var E=c[u].getOtherEnd(f);if(O.get(f)!=E)if(!T.has(E))y.push(E),O.set(E,f);else{p=!1;break}}}if(!p)a=[];else{var A=[].concat(o(T));a.push(A);for(var u=0;u<A.length;u++){var m=A[u],C=s.indexOf(m);C>-1&&s.splice(C,1)}T=new Set,O=new Map}}return a},h.prototype.createDummyNodesForBendpoints=function(a){for(var p=[],v=a.source,D=this.graphManager.calcLowestCommonAncestor(a.source,a.target),u=0;u<a.bendpoints.length;u++){var T=this.newNode(null);T.setRect(new Point(0,0),new Dimension(1,1)),D.add(T);var y=this.newEdge(null);this.graphManager.add(y,v,T),p.add(T),v=T}var y=this.newEdge(null);return this.graphManager.add(y,v,a.target),this.edgeToDummyNodes.set(a,p),a.isInterGraph()?this.graphManager.remove(a):D.remove(a),p},h.prototype.createBendpointsFromDummyNodes=function(){var a=[];a=a.concat(this.graphManager.getAllEdges()),a=[].concat(o(this.edgeToDummyNodes.keys())).concat(a);for(var p=0;p<a.length;p++){var v=a[p];if(v.bendpoints.length>0){for(var D=this.edgeToDummyNodes.get(v),u=0;u<D.length;u++){var T=D[u],y=new n(T.getCenterX(),T.getCenterY()),O=v.bendpoints.get(u);O.x=y.x,O.y=y.y,T.getOwner().remove(T)}this.graphManager.add(v,v.source,v.target)}}},h.transform=function(a,p,v,D){if(v!=null&&D!=null){var u=p;if(a<=50){var T=p/v;u-=(p-T)/50*(50-a)}else{var y=p*D;u+=(y-p)/50*(a-50)}return u}else{var O,s;return a<=50?(O=9*p/500,s=p/10):(O=9*p/50,s=-8*p),O*a+s}},h.findCenterOfTree=function(a){var p=[];p=p.concat(a);var v=[],D=new Map,u=!1,T=null;(p.length==1||p.length==2)&&(u=!0,T=p[0]);for(var y=0;y<p.length;y++){var O=p[y],s=O.getNeighborsList().size;D.set(O,O.getNeighborsList().size),s==1&&v.push(O)}var f=[];for(f=f.concat(v);!u;){var c=[];c=c.concat(f),f=[];for(var y=0;y<p.length;y++){var O=p[y],E=p.indexOf(O);E>=0&&p.splice(E,1);var A=O.getNeighborsList();A.forEach(function(R){if(v.indexOf(R)<0){var M=D.get(R),S=M-1;S==1&&f.push(R),D.set(R,S)}})}v=v.concat(f),(p.length==1||p.length==2)&&(u=!0,T=p[0])}return T},h.prototype.setGraphManager=function(a){this.graphManager=a},N.exports=h}),(function(N,I,L){function o(){}o.seed=1,o.x=0,o.nextDouble=function(){return o.x=Math.sin(o.seed++)*1e4,o.x-Math.floor(o.x)},N.exports=o}),(function(N,I,L){var o=L(4);function e(t,i){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}e.prototype.getWorldOrgX=function(){return this.lworldOrgX},e.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},e.prototype.getWorldOrgY=function(){return this.lworldOrgY},e.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},e.prototype.getWorldExtX=function(){return this.lworldExtX},e.prototype.setWorldExtX=function(t){this.lworldExtX=t},e.prototype.getWorldExtY=function(){return this.lworldExtY},e.prototype.setWorldExtY=function(t){this.lworldExtY=t},e.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},e.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},e.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},e.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},e.prototype.getDeviceExtX=function(){return this.ldeviceExtX},e.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},e.prototype.getDeviceExtY=function(){return this.ldeviceExtY},e.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},e.prototype.transformX=function(t){var i=0,l=this.lworldExtX;return l!=0&&(i=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/l),i},e.prototype.transformY=function(t){var i=0,l=this.lworldExtY;return l!=0&&(i=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/l),i},e.prototype.inverseTransformX=function(t){var i=0,l=this.ldeviceExtX;return l!=0&&(i=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/l),i},e.prototype.inverseTransformY=function(t){var i=0,l=this.ldeviceExtY;return l!=0&&(i=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/l),i},e.prototype.inverseTransformPoint=function(t){var i=new o(this.inverseTransformX(t.x),this.inverseTransformY(t.y));return i},N.exports=e}),(function(N,I,L){function o(r){if(Array.isArray(r)){for(var h=0,a=Array(r.length);h<r.length;h++)a[h]=r[h];return a}else return Array.from(r)}var e=L(15),t=L(7),i=L(0),l=L(8),g=L(9);function n(){e.call(this),this.useSmartIdealEdgeLengthCalculation=t.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=t.DEFAULT_EDGE_LENGTH,this.springConstant=t.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=t.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=t.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=t.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*t.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=t.MAX_ITERATIONS}n.prototype=Object.create(e.prototype);for(var d in e)n[d]=e[d];n.prototype.initParameters=function(){e.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=t.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},n.prototype.calcIdealEdgeLengths=function(){for(var r,h,a,p,v,D,u=this.getGraphManager().getAllEdges(),T=0;T<u.length;T++)r=u[T],r.idealLength=this.idealEdgeLength,r.isInterGraph&&(a=r.getSource(),p=r.getTarget(),v=r.getSourceInLca().getEstimatedSize(),D=r.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(r.idealLength+=v+D-2*i.SIMPLE_NODE_SIZE),h=r.getLca().getInclusionTreeDepth(),r.idealLength+=t.DEFAULT_EDGE_LENGTH*t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(a.getInclusionTreeDepth()+p.getInclusionTreeDepth()-2*h))},n.prototype.initSpringEmbedder=function(){var r=this.getAllNodes().length;this.incremental?(r>t.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*t.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(r-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-t.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT_INCREMENTAL):(r>t.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(t.COOLING_ADAPTATION_FACTOR,1-(r-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*(1-t.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},n.prototype.calcSpringForces=function(){for(var r=this.getAllEdges(),h,a=0;a<r.length;a++)h=r[a],this.calcSpringForce(h,h.idealLength)},n.prototype.calcRepulsionForces=function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,a,p,v,D,u=this.getAllNodes(),T;if(this.useFRGridVariant)for(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&r&&this.updateGrid(),T=new Set,a=0;a<u.length;a++)v=u[a],this.calculateRepulsionForceOfANode(v,T,r,h),T.add(v);else for(a=0;a<u.length;a++)for(v=u[a],p=a+1;p<u.length;p++)D=u[p],v.getOwner()==D.getOwner()&&this.calcRepulsionForce(v,D)},n.prototype.calcGravitationalForces=function(){for(var r,h=this.getAllNodesToApplyGravitation(),a=0;a<h.length;a++)r=h[a],this.calcGravitationalForce(r)},n.prototype.moveNodes=function(){for(var r=this.getAllNodes(),h,a=0;a<r.length;a++)h=r[a],h.move()},n.prototype.calcSpringForce=function(r,h){var a=r.getSource(),p=r.getTarget(),v,D,u,T;if(this.uniformLeafNodeSizes&&a.getChild()==null&&p.getChild()==null)r.updateLengthSimple();else if(r.updateLength(),r.isOverlapingSourceAndTarget)return;v=r.getLength(),v!=0&&(D=this.springConstant*(v-h),u=D*(r.lengthX/v),T=D*(r.lengthY/v),a.springForceX+=u,a.springForceY+=T,p.springForceX-=u,p.springForceY-=T)},n.prototype.calcRepulsionForce=function(r,h){var a=r.getRect(),p=h.getRect(),v=new Array(2),D=new Array(4),u,T,y,O,s,f,c;if(a.intersects(p)){l.calcSeparationAmount(a,p,v,t.DEFAULT_EDGE_LENGTH/2),f=2*v[0],c=2*v[1];var E=r.noOfChildren*h.noOfChildren/(r.noOfChildren+h.noOfChildren);r.repulsionForceX-=E*f,r.repulsionForceY-=E*c,h.repulsionForceX+=E*f,h.repulsionForceY+=E*c}else this.uniformLeafNodeSizes&&r.getChild()==null&&h.getChild()==null?(u=p.getCenterX()-a.getCenterX(),T=p.getCenterY()-a.getCenterY()):(l.getIntersection(a,p,D),u=D[2]-D[0],T=D[3]-D[1]),Math.abs(u)<t.MIN_REPULSION_DIST&&(u=g.sign(u)*t.MIN_REPULSION_DIST),Math.abs(T)<t.MIN_REPULSION_DIST&&(T=g.sign(T)*t.MIN_REPULSION_DIST),y=u*u+T*T,O=Math.sqrt(y),s=this.repulsionConstant*r.noOfChildren*h.noOfChildren/y,f=s*u/O,c=s*T/O,r.repulsionForceX-=f,r.repulsionForceY-=c,h.repulsionForceX+=f,h.repulsionForceY+=c},n.prototype.calcGravitationalForce=function(r){var h,a,p,v,D,u,T,y;h=r.getOwner(),a=(h.getRight()+h.getLeft())/2,p=(h.getTop()+h.getBottom())/2,v=r.getCenterX()-a,D=r.getCenterY()-p,u=Math.abs(v)+r.getWidth()/2,T=Math.abs(D)+r.getHeight()/2,r.getOwner()==this.graphManager.getRoot()?(y=h.getEstimatedSize()*this.gravityRangeFactor,(u>y||T>y)&&(r.gravitationForceX=-this.gravityConstant*v,r.gravitationForceY=-this.gravityConstant*D)):(y=h.getEstimatedSize()*this.compoundGravityRangeFactor,(u>y||T>y)&&(r.gravitationForceX=-this.gravityConstant*v*this.compoundGravityConstant,r.gravitationForceY=-this.gravityConstant*D*this.compoundGravityConstant))},n.prototype.isConverged=function(){var r,h=!1;return this.totalIterations>this.maxIterations/3&&(h=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2),r=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,r||h},n.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},n.prototype.calcNoOfChildrenForAllNodes=function(){for(var r,h=this.graphManager.getAllNodes(),a=0;a<h.length;a++)r=h[a],r.noOfChildren=r.getNoOfChildren()},n.prototype.calcGrid=function(r){var h=0,a=0;h=parseInt(Math.ceil((r.getRight()-r.getLeft())/this.repulsionRange)),a=parseInt(Math.ceil((r.getBottom()-r.getTop())/this.repulsionRange));for(var p=new Array(h),v=0;v<h;v++)p[v]=new Array(a);for(var v=0;v<h;v++)for(var D=0;D<a;D++)p[v][D]=new Array;return p},n.prototype.addNodeToGrid=function(r,h,a){var p=0,v=0,D=0,u=0;p=parseInt(Math.floor((r.getRect().x-h)/this.repulsionRange)),v=parseInt(Math.floor((r.getRect().width+r.getRect().x-h)/this.repulsionRange)),D=parseInt(Math.floor((r.getRect().y-a)/this.repulsionRange)),u=parseInt(Math.floor((r.getRect().height+r.getRect().y-a)/this.repulsionRange));for(var T=p;T<=v;T++)for(var y=D;y<=u;y++)this.grid[T][y].push(r),r.setGridCoordinates(p,v,D,u)},n.prototype.updateGrid=function(){var r,h,a=this.getAllNodes();for(this.grid=this.calcGrid(this.graphManager.getRoot()),r=0;r<a.length;r++)h=a[r],this.addNodeToGrid(h,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},n.prototype.calculateRepulsionForceOfANode=function(r,h,a,p){if(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&a||p){var v=new Set;r.surrounding=new Array;for(var D,u=this.grid,T=r.startX-1;T<r.finishX+2;T++)for(var y=r.startY-1;y<r.finishY+2;y++)if(!(T<0||y<0||T>=u.length||y>=u[0].length)){for(var O=0;O<u[T][y].length;O++)if(D=u[T][y][O],!(r.getOwner()!=D.getOwner()||r==D)&&!h.has(D)&&!v.has(D)){var s=Math.abs(r.getCenterX()-D.getCenterX())-(r.getWidth()/2+D.getWidth()/2),f=Math.abs(r.getCenterY()-D.getCenterY())-(r.getHeight()/2+D.getHeight()/2);s<=this.repulsionRange&&f<=this.repulsionRange&&v.add(D)}}r.surrounding=[].concat(o(v))}for(T=0;T<r.surrounding.length;T++)this.calcRepulsionForce(r,r.surrounding[T])},n.prototype.calcRepulsionRange=function(){return 0},N.exports=n}),(function(N,I,L){var o=L(1),e=L(7);function t(l,g,n){o.call(this,l,g,n),this.idealLength=e.DEFAULT_EDGE_LENGTH}t.prototype=Object.create(o.prototype);for(var i in o)t[i]=o[i];N.exports=t}),(function(N,I,L){var o=L(3);function e(i,l,g,n){o.call(this,i,l,g,n),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}e.prototype=Object.create(o.prototype);for(var t in o)e[t]=o[t];e.prototype.setGridCoordinates=function(i,l,g,n){this.startX=i,this.finishX=l,this.startY=g,this.finishY=n},N.exports=e}),(function(N,I,L){function o(e,t){this.width=0,this.height=0,e!==null&&t!==null&&(this.height=t,this.width=e)}o.prototype.getWidth=function(){return this.width},o.prototype.setWidth=function(e){this.width=e},o.prototype.getHeight=function(){return this.height},o.prototype.setHeight=function(e){this.height=e},N.exports=o}),(function(N,I,L){var o=L(14);function e(){this.map={},this.keys=[]}e.prototype.put=function(t,i){var l=o.createID(t);this.contains(l)||(this.map[l]=i,this.keys.push(t))},e.prototype.contains=function(t){return o.createID(t),this.map[t]!=null},e.prototype.get=function(t){var i=o.createID(t);return this.map[i]},e.prototype.keySet=function(){return this.keys},N.exports=e}),(function(N,I,L){var o=L(14);function e(){this.set={}}e.prototype.add=function(t){var i=o.createID(t);this.contains(i)||(this.set[i]=t)},e.prototype.remove=function(t){delete this.set[o.createID(t)]},e.prototype.clear=function(){this.set={}},e.prototype.contains=function(t){return this.set[o.createID(t)]==t},e.prototype.isEmpty=function(){return this.size()===0},e.prototype.size=function(){return Object.keys(this.set).length},e.prototype.addAllTo=function(t){for(var i=Object.keys(this.set),l=i.length,g=0;g<l;g++)t.push(this.set[i[g]])},e.prototype.size=function(){return Object.keys(this.set).length},e.prototype.addAll=function(t){for(var i=t.length,l=0;l<i;l++){var g=t[l];this.add(g)}},N.exports=e}),(function(N,I,L){var o=(function(){function l(g,n){for(var d=0;d<n.length;d++){var r=n[d];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(g,r.key,r)}}return function(g,n,d){return n&&l(g.prototype,n),d&&l(g,d),g}})();function e(l,g){if(!(l instanceof g))throw new TypeError("Cannot call a class as a function")}var t=L(11),i=(function(){function l(g,n){e(this,l),(n!==null||n!==void 0)&&(this.compareFunction=this._defaultCompareFunction);var d=void 0;g instanceof t?d=g.size():d=g.length,this._quicksort(g,0,d-1)}return o(l,[{key:"_quicksort",value:function(n,d,r){if(d<r){var h=this._partition(n,d,r);this._quicksort(n,d,h),this._quicksort(n,h+1,r)}}},{key:"_partition",value:function(n,d,r){for(var h=this._get(n,d),a=d,p=r;;){for(;this.compareFunction(h,this._get(n,p));)p--;for(;this.compareFunction(this._get(n,a),h);)a++;if(a<p)this._swap(n,a,p),a++,p--;else return p}}},{key:"_get",value:function(n,d){return n instanceof t?n.get_object_at(d):n[d]}},{key:"_set",value:function(n,d,r){n instanceof t?n.set_object_at(d,r):n[d]=r}},{key:"_swap",value:function(n,d,r){var h=this._get(n,d);this._set(n,d,this._get(n,r)),this._set(n,r,h)}},{key:"_defaultCompareFunction",value:function(n,d){return d>n}}]),l})();N.exports=i}),(function(N,I,L){var o=(function(){function i(l,g){for(var n=0;n<g.length;n++){var d=g[n];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(l,d.key,d)}}return function(l,g,n){return g&&i(l.prototype,g),n&&i(l,n),l}})();function e(i,l){if(!(i instanceof l))throw new TypeError("Cannot call a class as a function")}var t=(function(){function i(l,g){var n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,d=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,r=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;e(this,i),this.sequence1=l,this.sequence2=g,this.match_score=n,this.mismatch_penalty=d,this.gap_penalty=r,this.iMax=l.length+1,this.jMax=g.length+1,this.grid=new Array(this.iMax);for(var h=0;h<this.iMax;h++){this.grid[h]=new Array(this.jMax);for(var a=0;a<this.jMax;a++)this.grid[h][a]=0}this.tracebackGrid=new Array(this.iMax);for(var p=0;p<this.iMax;p++){this.tracebackGrid[p]=new Array(this.jMax);for(var v=0;v<this.jMax;v++)this.tracebackGrid[p][v]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return o(i,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var g=1;g<this.jMax;g++)this.grid[0][g]=this.grid[0][g-1]+this.gap_penalty,this.tracebackGrid[0][g]=[!1,!1,!0];for(var n=1;n<this.iMax;n++)this.grid[n][0]=this.grid[n-1][0]+this.gap_penalty,this.tracebackGrid[n][0]=[!1,!0,!1];for(var d=1;d<this.iMax;d++)for(var r=1;r<this.jMax;r++){var h=void 0;this.sequence1[d-1]===this.sequence2[r-1]?h=this.grid[d-1][r-1]+this.match_score:h=this.grid[d-1][r-1]+this.mismatch_penalty;var a=this.grid[d-1][r]+this.gap_penalty,p=this.grid[d][r-1]+this.gap_penalty,v=[h,a,p],D=this.arrayAllMaxIndexes(v);this.grid[d][r]=v[D[0]],this.tracebackGrid[d][r]=[D.includes(0),D.includes(1),D.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var g=[];for(g.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});g[0];){var n=g[0],d=this.tracebackGrid[n.pos[0]][n.pos[1]];d[0]&&g.push({pos:[n.pos[0]-1,n.pos[1]-1],seq1:this.sequence1[n.pos[0]-1]+n.seq1,seq2:this.sequence2[n.pos[1]-1]+n.seq2}),d[1]&&g.push({pos:[n.pos[0]-1,n.pos[1]],seq1:this.sequence1[n.pos[0]-1]+n.seq1,seq2:"-"+n.seq2}),d[2]&&g.push({pos:[n.pos[0],n.pos[1]-1],seq1:"-"+n.seq1,seq2:this.sequence2[n.pos[1]-1]+n.seq2}),n.pos[0]===0&&n.pos[1]===0&&this.alignments.push({sequence1:n.seq1,sequence2:n.seq2}),g.shift()}return this.alignments}},{key:"getAllIndexes",value:function(g,n){for(var d=[],r=-1;(r=g.indexOf(n,r+1))!==-1;)d.push(r);return d}},{key:"arrayAllMaxIndexes",value:function(g){return this.getAllIndexes(g,Math.max.apply(null,g))}}]),i})();N.exports=t}),(function(N,I,L){var o=function(){};o.FDLayout=L(18),o.FDLayoutConstants=L(7),o.FDLayoutEdge=L(19),o.FDLayoutNode=L(20),o.DimensionD=L(21),o.HashMap=L(22),o.HashSet=L(23),o.IGeometry=L(8),o.IMath=L(9),o.Integer=L(10),o.Point=L(12),o.PointD=L(4),o.RandomSeed=L(16),o.RectangleD=L(13),o.Transform=L(17),o.UniqueIDGeneretor=L(14),o.Quicksort=L(24),o.LinkedList=L(11),o.LGraphObject=L(2),o.LGraph=L(5),o.LEdge=L(1),o.LGraphManager=L(6),o.LNode=L(3),o.Layout=L(15),o.LayoutConstants=L(0),o.NeedlemanWunsch=L(25),N.exports=o}),(function(N,I,L){function o(){this.listeners=[]}var e=o.prototype;e.addListener=function(t,i){this.listeners.push({event:t,callback:i})},e.removeListener=function(t,i){for(var l=this.listeners.length;l>=0;l--){var g=this.listeners[l];g.event===t&&g.callback===i&&this.listeners.splice(l,1)}},e.emit=function(t,i){for(var l=0;l<this.listeners.length;l++){var g=this.listeners[l];t===g.event&&g.callback(i)}},N.exports=o})])})})(Q)),Q.exports}var gt=Z.exports,j;function ut(){return j||(j=1,(function(G,b){(function(I,L){G.exports=L(lt())})(gt,function(N){return(function(I){var L={};function o(e){if(L[e])return L[e].exports;var t=L[e]={i:e,l:!1,exports:{}};return I[e].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=I,o.c=L,o.i=function(e){return e},o.d=function(e,t,i){o.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o(o.s=7)})([(function(I,L){I.exports=N}),(function(I,L,o){var e=o(0).FDLayoutConstants;function t(){}for(var i in e)t[i]=e[i];t.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,t.DEFAULT_RADIAL_SEPARATION=e.DEFAULT_EDGE_LENGTH,t.DEFAULT_COMPONENT_SEPERATION=60,t.TILE=!0,t.TILING_PADDING_VERTICAL=10,t.TILING_PADDING_HORIZONTAL=10,t.TREE_REDUCTION_ON_INCREMENTAL=!1,I.exports=t}),(function(I,L,o){var e=o(0).FDLayoutEdge;function t(l,g,n){e.call(this,l,g,n)}t.prototype=Object.create(e.prototype);for(var i in e)t[i]=e[i];I.exports=t}),(function(I,L,o){var e=o(0).LGraph;function t(l,g,n){e.call(this,l,g,n)}t.prototype=Object.create(e.prototype);for(var i in e)t[i]=e[i];I.exports=t}),(function(I,L,o){var e=o(0).LGraphManager;function t(l){e.call(this,l)}t.prototype=Object.create(e.prototype);for(var i in e)t[i]=e[i];I.exports=t}),(function(I,L,o){var e=o(0).FDLayoutNode,t=o(0).IMath;function i(g,n,d,r){e.call(this,g,n,d,r)}i.prototype=Object.create(e.prototype);for(var l in e)i[l]=e[l];i.prototype.move=function(){var g=this.graphManager.getLayout();this.displacementX=g.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=g.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>g.coolingFactor*g.maxNodeDisplacement&&(this.displacementX=g.coolingFactor*g.maxNodeDisplacement*t.sign(this.displacementX)),Math.abs(this.displacementY)>g.coolingFactor*g.maxNodeDisplacement&&(this.displacementY=g.coolingFactor*g.maxNodeDisplacement*t.sign(this.displacementY)),this.child==null?this.moveBy(this.displacementX,this.displacementY):this.child.getNodes().length==0?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),g.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},i.prototype.propogateDisplacementToChildren=function(g,n){for(var d=this.getChild().getNodes(),r,h=0;h<d.length;h++)r=d[h],r.getChild()==null?(r.moveBy(g,n),r.displacementX+=g,r.displacementY+=n):r.propogateDisplacementToChildren(g,n)},i.prototype.setPred1=function(g){this.pred1=g},i.prototype.getPred1=function(){return pred1},i.prototype.getPred2=function(){return pred2},i.prototype.setNext=function(g){this.next=g},i.prototype.getNext=function(){return next},i.prototype.setProcessed=function(g){this.processed=g},i.prototype.isProcessed=function(){return processed},I.exports=i}),(function(I,L,o){var e=o(0).FDLayout,t=o(4),i=o(3),l=o(5),g=o(2),n=o(1),d=o(0).FDLayoutConstants,r=o(0).LayoutConstants,h=o(0).Point,a=o(0).PointD,p=o(0).Layout,v=o(0).Integer,D=o(0).IGeometry,u=o(0).LGraph,T=o(0).Transform;function y(){e.call(this),this.toBeTiled={}}y.prototype=Object.create(e.prototype);for(var O in e)y[O]=e[O];y.prototype.newGraphManager=function(){var s=new t(this);return this.graphManager=s,s},y.prototype.newGraph=function(s){return new i(null,this.graphManager,s)},y.prototype.newNode=function(s){return new l(this.graphManager,s)},y.prototype.newEdge=function(s){return new g(null,null,s)},y.prototype.initParameters=function(){e.prototype.initParameters.call(this,arguments),this.isSubLayout||(n.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=n.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=n.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=d.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=d.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=d.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=d.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=d.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=d.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1,this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/d.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=d.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1)},y.prototype.layout=function(){var s=r.DEFAULT_CREATE_BENDS_AS_NEEDED;return s&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},y.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),this.incremental){if(n.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var f=new Set(this.getAllNodes()),c=this.nodesWithGravity.filter(function(m){return f.has(m)});this.graphManager.setAllNodesToApplyGravitation(c)}}else{var s=this.getFlatForest();if(s.length>0)this.positionNodesRadially(s);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var f=new Set(this.getAllNodes()),c=this.nodesWithGravity.filter(function(E){return f.has(E)});this.graphManager.setAllNodesToApplyGravitation(c),this.positionNodesRandomly()}}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},y.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished)if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;if(this.totalIterations%d.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged())if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;this.coolingCycle++,this.layoutQuality==0?this.coolingAdjuster=this.coolingCycle:this.layoutQuality==1&&(this.coolingAdjuster=this.coolingCycle/3),this.coolingFactor=Math.max(this.initialCoolingFactor-Math.pow(this.coolingCycle,Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var s=new Set(this.getAllNodes()),f=this.nodesWithGravity.filter(function(A){return s.has(A)});this.graphManager.setAllNodesToApplyGravitation(f),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=d.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=d.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var c=!this.isTreeGrowing&&!this.isGrowthFinished,E=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(c,E),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},y.prototype.getPositionsData=function(){for(var s=this.graphManager.getAllNodes(),f={},c=0;c<s.length;c++){var E=s[c].rect,A=s[c].id;f[A]={id:A,x:E.getCenterX(),y:E.getCenterY(),w:E.width,h:E.height}}return f},y.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var s=!1;if(d.ANIMATE==="during")this.emit("layoutstarted");else{for(;!s;)s=this.tick();this.graphManager.updateBounds()}},y.prototype.calculateNodesToApplyGravitationTo=function(){var s=[],f,c=this.graphManager.getGraphs(),E=c.length,A;for(A=0;A<E;A++)f=c[A],f.updateConnected(),f.isConnected||(s=s.concat(f.getNodes()));return s},y.prototype.createBendpoints=function(){var s=[];s=s.concat(this.graphManager.getAllEdges());var f=new Set,c;for(c=0;c<s.length;c++){var E=s[c];if(!f.has(E)){var A=E.getSource(),m=E.getTarget();if(A==m)E.getBendpoints().push(new a),E.getBendpoints().push(new a),this.createDummyNodesForBendpoints(E),f.add(E);else{var C=[];if(C=C.concat(A.getEdgeListToNode(m)),C=C.concat(m.getEdgeListToNode(A)),!f.has(C[0])){if(C.length>1){var R;for(R=0;R<C.length;R++){var M=C[R];M.getBendpoints().push(new a),this.createDummyNodesForBendpoints(M)}}C.forEach(function(S){f.add(S)})}}}if(f.size==s.length)break}},y.prototype.positionNodesRadially=function(s){for(var f=new h(0,0),c=Math.ceil(Math.sqrt(s.length)),E=0,A=0,m=0,C=new a(0,0),R=0;R<s.length;R++){R%c==0&&(m=0,A=E,R!=0&&(A+=n.DEFAULT_COMPONENT_SEPERATION),E=0);var M=s[R],S=p.findCenterOfTree(M);f.x=m,f.y=A,C=y.radialLayout(M,S,f),C.y>E&&(E=Math.floor(C.y)),m=Math.floor(C.x+n.DEFAULT_COMPONENT_SEPERATION)}this.transform(new a(r.WORLD_CENTER_X-C.x/2,r.WORLD_CENTER_Y-C.y/2))},y.radialLayout=function(s,f,c){var E=Math.max(this.maxDiagonalInTree(s),n.DEFAULT_RADIAL_SEPARATION);y.branchRadialLayout(f,null,0,359,0,E);var A=u.calculateBounds(s),m=new T;m.setDeviceOrgX(A.getMinX()),m.setDeviceOrgY(A.getMinY()),m.setWorldOrgX(c.x),m.setWorldOrgY(c.y);for(var C=0;C<s.length;C++){var R=s[C];R.transform(m)}var M=new a(A.getMaxX(),A.getMaxY());return m.inverseTransformPoint(M)},y.branchRadialLayout=function(s,f,c,E,A,m){var C=(E-c+1)/2;C<0&&(C+=180);var R=(C+c)%360,M=R*D.TWO_PI/360,S=A*Math.cos(M),_=A*Math.sin(M);s.setCenter(S,_);var w=[];w=w.concat(s.getEdges());var x=w.length;f!=null&&x--;for(var F=0,P=w.length,U,Y=s.getEdgesBetween(f);Y.length>1;){var X=Y[0];Y.splice(0,1);var H=w.indexOf(X);H>=0&&w.splice(H,1),P--,x--}f!=null?U=(w.indexOf(Y[0])+1)%P:U=0;for(var B=Math.abs(E-c)/x,V=U;F!=x;V=++V%P){var $=w[V].getOtherEnd(s);if($!=f){var K=(c+F*B)%360,at=(K+B)%360;y.branchRadialLayout($,s,K,at,A+m,m),F++}}},y.maxDiagonalInTree=function(s){for(var f=v.MIN_VALUE,c=0;c<s.length;c++){var E=s[c],A=E.getDiagonal();A>f&&(f=A)}return f},y.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},y.prototype.groupZeroDegreeMembers=function(){var s=this,f={};this.memberGroups={},this.idToDummyNode={};for(var c=[],E=this.graphManager.getAllNodes(),A=0;A<E.length;A++){var m=E[A],C=m.getParent();this.getNodeDegreeWithChildren(m)===0&&(C.id==null||!this.getToBeTiled(C))&&c.push(m)}for(var A=0;A<c.length;A++){var m=c[A],R=m.getParent().id;typeof f[R]>"u"&&(f[R]=[]),f[R]=f[R].concat(m)}Object.keys(f).forEach(function(M){if(f[M].length>1){var S="DummyCompound_"+M;s.memberGroups[S]=f[M];var _=f[M][0].getParent(),w=new l(s.graphManager);w.id=S,w.paddingLeft=_.paddingLeft||0,w.paddingRight=_.paddingRight||0,w.paddingBottom=_.paddingBottom||0,w.paddingTop=_.paddingTop||0,s.idToDummyNode[S]=w;var x=s.getGraphManager().add(s.newGraph(),w),F=_.getChild();F.add(w);for(var P=0;P<f[M].length;P++){var U=f[M][P];F.remove(U),x.add(U)}}})},y.prototype.clearCompounds=function(){var s={},f={};this.performDFSOnCompounds();for(var c=0;c<this.compoundOrder.length;c++)f[this.compoundOrder[c].id]=this.compoundOrder[c],s[this.compoundOrder[c].id]=[].concat(this.compoundOrder[c].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[c].getChild()),this.compoundOrder[c].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(s,f)},y.prototype.clearZeroDegreeMembers=function(){var s=this,f=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach(function(c){var E=s.idToDummyNode[c];f[c]=s.tileNodes(s.memberGroups[c],E.paddingLeft+E.paddingRight),E.rect.width=f[c].width,E.rect.height=f[c].height})},y.prototype.repopulateCompounds=function(){for(var s=this.compoundOrder.length-1;s>=0;s--){var f=this.compoundOrder[s],c=f.id,E=f.paddingLeft,A=f.paddingTop;this.adjustLocations(this.tiledMemberPack[c],f.rect.x,f.rect.y,E,A)}},y.prototype.repopulateZeroDegreeMembers=function(){var s=this,f=this.tiledZeroDegreePack;Object.keys(f).forEach(function(c){var E=s.idToDummyNode[c],A=E.paddingLeft,m=E.paddingTop;s.adjustLocations(f[c],E.rect.x,E.rect.y,A,m)})},y.prototype.getToBeTiled=function(s){var f=s.id;if(this.toBeTiled[f]!=null)return this.toBeTiled[f];var c=s.getChild();if(c==null)return this.toBeTiled[f]=!1,!1;for(var E=c.getNodes(),A=0;A<E.length;A++){var m=E[A];if(this.getNodeDegree(m)>0)return this.toBeTiled[f]=!1,!1;if(m.getChild()==null){this.toBeTiled[m.id]=!1;continue}if(!this.getToBeTiled(m))return this.toBeTiled[f]=!1,!1}return this.toBeTiled[f]=!0,!0},y.prototype.getNodeDegree=function(s){s.id;for(var f=s.getEdges(),c=0,E=0;E<f.length;E++){var A=f[E];A.getSource().id!==A.getTarget().id&&(c=c+1)}return c},y.prototype.getNodeDegreeWithChildren=function(s){var f=this.getNodeDegree(s);if(s.getChild()==null)return f;for(var c=s.getChild().getNodes(),E=0;E<c.length;E++){var A=c[E];f+=this.getNodeDegreeWithChildren(A)}return f},y.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},y.prototype.fillCompexOrderByDFS=function(s){for(var f=0;f<s.length;f++){var c=s[f];c.getChild()!=null&&this.fillCompexOrderByDFS(c.getChild().getNodes()),this.getToBeTiled(c)&&this.compoundOrder.push(c)}},y.prototype.adjustLocations=function(s,f,c,E,A){f+=E,c+=A;for(var m=f,C=0;C<s.rows.length;C++){var R=s.rows[C];f=m;for(var M=0,S=0;S<R.length;S++){var _=R[S];_.rect.x=f,_.rect.y=c,f+=_.rect.width+s.horizontalPadding,_.rect.height>M&&(M=_.rect.height)}c+=M+s.verticalPadding}},y.prototype.tileCompoundMembers=function(s,f){var c=this;this.tiledMemberPack=[],Object.keys(s).forEach(function(E){var A=f[E];c.tiledMemberPack[E]=c.tileNodes(s[E],A.paddingLeft+A.paddingRight),A.rect.width=c.tiledMemberPack[E].width,A.rect.height=c.tiledMemberPack[E].height})},y.prototype.tileNodes=function(s,f){var c=n.TILING_PADDING_VERTICAL,E=n.TILING_PADDING_HORIZONTAL,A={rows:[],rowWidth:[],rowHeight:[],width:0,height:f,verticalPadding:c,horizontalPadding:E};s.sort(function(R,M){return R.rect.width*R.rect.height>M.rect.width*M.rect.height?-1:R.rect.width*R.rect.height<M.rect.width*M.rect.height?1:0});for(var m=0;m<s.length;m++){var C=s[m];A.rows.length==0?this.insertNodeToRow(A,C,0,f):this.canAddHorizontal(A,C.rect.width,C.rect.height)?this.insertNodeToRow(A,C,this.getShortestRowIndex(A),f):this.insertNodeToRow(A,C,A.rows.length,f),this.shiftToLastRow(A)}return A},y.prototype.insertNodeToRow=function(s,f,c,E){var A=E;if(c==s.rows.length){var m=[];s.rows.push(m),s.rowWidth.push(A),s.rowHeight.push(0)}var C=s.rowWidth[c]+f.rect.width;s.rows[c].length>0&&(C+=s.horizontalPadding),s.rowWidth[c]=C,s.width<C&&(s.width=C);var R=f.rect.height;c>0&&(R+=s.verticalPadding);var M=0;R>s.rowHeight[c]&&(M=s.rowHeight[c],s.rowHeight[c]=R,M=s.rowHeight[c]-M),s.height+=M,s.rows[c].push(f)},y.prototype.getShortestRowIndex=function(s){for(var f=-1,c=Number.MAX_VALUE,E=0;E<s.rows.length;E++)s.rowWidth[E]<c&&(f=E,c=s.rowWidth[E]);return f},y.prototype.getLongestRowIndex=function(s){for(var f=-1,c=Number.MIN_VALUE,E=0;E<s.rows.length;E++)s.rowWidth[E]>c&&(f=E,c=s.rowWidth[E]);return f},y.prototype.canAddHorizontal=function(s,f,c){var E=this.getShortestRowIndex(s);if(E<0)return!0;var A=s.rowWidth[E];if(A+s.horizontalPadding+f<=s.width)return!0;var m=0;s.rowHeight[E]<c&&E>0&&(m=c+s.verticalPadding-s.rowHeight[E]);var C;s.width-A>=f+s.horizontalPadding?C=(s.height+m)/(A+f+s.horizontalPadding):C=(s.height+m)/s.width,m=c+s.verticalPadding;var R;return s.width<f?R=(s.height+m)/f:R=(s.height+m)/s.width,R<1&&(R=1/R),C<1&&(C=1/C),C<R},y.prototype.shiftToLastRow=function(s){var f=this.getLongestRowIndex(s),c=s.rowWidth.length-1,E=s.rows[f],A=E[E.length-1],m=A.width+s.horizontalPadding;if(s.width-s.rowWidth[c]>m&&f!=c){E.splice(-1,1),s.rows[c].push(A),s.rowWidth[f]=s.rowWidth[f]-m,s.rowWidth[c]=s.rowWidth[c]+m,s.width=s.rowWidth[instance.getLongestRowIndex(s)];for(var C=Number.MIN_VALUE,R=0;R<E.length;R++)E[R].height>C&&(C=E[R].height);f>0&&(C+=s.verticalPadding);var M=s.rowHeight[f]+s.rowHeight[c];s.rowHeight[f]=C,s.rowHeight[c]<A.height+s.verticalPadding&&(s.rowHeight[c]=A.height+s.verticalPadding);var S=s.rowHeight[f]+s.rowHeight[c];s.height+=S-M,this.shiftToLastRow(s)}},y.prototype.tilingPreLayout=function(){n.TILE&&(this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers())},y.prototype.tilingPostLayout=function(){n.TILE&&(this.repopulateZeroDegreeMembers(),this.repopulateCompounds())},y.prototype.reduceTrees=function(){for(var s=[],f=!0,c;f;){var E=this.graphManager.getAllNodes(),A=[];f=!1;for(var m=0;m<E.length;m++)c=E[m],c.getEdges().length==1&&!c.getEdges()[0].isInterGraph&&c.getChild()==null&&(A.push([c,c.getEdges()[0],c.getOwner()]),f=!0);if(f==!0){for(var C=[],R=0;R<A.length;R++)A[R][0].getEdges().length==1&&(C.push(A[R]),A[R][0].getOwner().remove(A[R][0]));s.push(C),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=s},y.prototype.growTree=function(s){for(var f=s.length,c=s[f-1],E,A=0;A<c.length;A++)E=c[A],this.findPlaceforPrunedNode(E),E[2].add(E[0]),E[2].add(E[1],E[1].source,E[1].target);s.splice(s.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},y.prototype.findPlaceforPrunedNode=function(s){var f,c,E=s[0];E==s[1].source?c=s[1].target:c=s[1].source;var A=c.startX,m=c.finishX,C=c.startY,R=c.finishY,M=0,S=0,_=0,w=0,x=[M,_,S,w];if(C>0)for(var F=A;F<=m;F++)x[0]+=this.grid[F][C-1].length+this.grid[F][C].length-1;if(m<this.grid.length-1)for(var F=C;F<=R;F++)x[1]+=this.grid[m+1][F].length+this.grid[m][F].length-1;if(R<this.grid[0].length-1)for(var F=A;F<=m;F++)x[2]+=this.grid[F][R+1].length+this.grid[F][R].length-1;if(A>0)for(var F=C;F<=R;F++)x[3]+=this.grid[A-1][F].length+this.grid[A][F].length-1;for(var P=v.MAX_VALUE,U,Y,X=0;X<x.length;X++)x[X]<P?(P=x[X],U=1,Y=X):x[X]==P&&U++;if(U==3&&P==0)x[0]==0&&x[1]==0&&x[2]==0?f=1:x[0]==0&&x[1]==0&&x[3]==0?f=0:x[0]==0&&x[2]==0&&x[3]==0?f=3:x[1]==0&&x[2]==0&&x[3]==0&&(f=2);else if(U==2&&P==0){var H=Math.floor(Math.random()*2);x[0]==0&&x[1]==0?H==0?f=0:f=1:x[0]==0&&x[2]==0?H==0?f=0:f=2:x[0]==0&&x[3]==0?H==0?f=0:f=3:x[1]==0&&x[2]==0?H==0?f=1:f=2:x[1]==0&&x[3]==0?H==0?f=1:f=3:H==0?f=2:f=3}else if(U==4&&P==0){var H=Math.floor(Math.random()*4);f=H}else f=Y;f==0?E.setCenter(c.getCenterX(),c.getCenterY()-c.getHeight()/2-d.DEFAULT_EDGE_LENGTH-E.getHeight()/2):f==1?E.setCenter(c.getCenterX()+c.getWidth()/2+d.DEFAULT_EDGE_LENGTH+E.getWidth()/2,c.getCenterY()):f==2?E.setCenter(c.getCenterX(),c.getCenterY()+c.getHeight()/2+d.DEFAULT_EDGE_LENGTH+E.getHeight()/2):E.setCenter(c.getCenterX()-c.getWidth()/2-d.DEFAULT_EDGE_LENGTH-E.getWidth()/2,c.getCenterY())},I.exports=y}),(function(I,L,o){var e={};e.layoutBase=o(0),e.CoSEConstants=o(1),e.CoSEEdge=o(2),e.CoSEGraph=o(3),e.CoSEGraphManager=o(4),e.CoSELayout=o(6),e.CoSENode=o(5),I.exports=e})])})})(Z)),Z.exports}var ft=k.exports,z;function ct(){return z||(z=1,(function(G,b){(function(I,L){G.exports=L(ut())})(ft,function(N){return(function(I){var L={};function o(e){if(L[e])return L[e].exports;var t=L[e]={i:e,l:!1,exports:{}};return I[e].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=I,o.c=L,o.i=function(e){return e},o.d=function(e,t,i){o.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:i})},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,"a",t),t},o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},o.p="",o(o.s=1)})([(function(I,L){I.exports=N}),(function(I,L,o){var e=o(0).layoutBase.LayoutConstants,t=o(0).layoutBase.FDLayoutConstants,i=o(0).CoSEConstants,l=o(0).CoSELayout,g=o(0).CoSENode,n=o(0).layoutBase.PointD,d=o(0).layoutBase.DimensionD,r={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function h(D,u){var T={};for(var y in D)T[y]=D[y];for(var y in u)T[y]=u[y];return T}function a(D){this.options=h(r,D),p(this.options)}var p=function(u){u.nodeRepulsion!=null&&(i.DEFAULT_REPULSION_STRENGTH=t.DEFAULT_REPULSION_STRENGTH=u.nodeRepulsion),u.idealEdgeLength!=null&&(i.DEFAULT_EDGE_LENGTH=t.DEFAULT_EDGE_LENGTH=u.idealEdgeLength),u.edgeElasticity!=null&&(i.DEFAULT_SPRING_STRENGTH=t.DEFAULT_SPRING_STRENGTH=u.edgeElasticity),u.nestingFactor!=null&&(i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=u.nestingFactor),u.gravity!=null&&(i.DEFAULT_GRAVITY_STRENGTH=t.DEFAULT_GRAVITY_STRENGTH=u.gravity),u.numIter!=null&&(i.MAX_ITERATIONS=t.MAX_ITERATIONS=u.numIter),u.gravityRange!=null&&(i.DEFAULT_GRAVITY_RANGE_FACTOR=t.DEFAULT_GRAVITY_RANGE_FACTOR=u.gravityRange),u.gravityCompound!=null&&(i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH=u.gravityCompound),u.gravityRangeCompound!=null&&(i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=u.gravityRangeCompound),u.initialEnergyOnIncremental!=null&&(i.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.DEFAULT_COOLING_FACTOR_INCREMENTAL=u.initialEnergyOnIncremental),u.quality=="draft"?e.QUALITY=0:u.quality=="proof"?e.QUALITY=2:e.QUALITY=1,i.NODE_DIMENSIONS_INCLUDE_LABELS=t.NODE_DIMENSIONS_INCLUDE_LABELS=e.NODE_DIMENSIONS_INCLUDE_LABELS=u.nodeDimensionsIncludeLabels,i.DEFAULT_INCREMENTAL=t.DEFAULT_INCREMENTAL=e.DEFAULT_INCREMENTAL=!u.randomize,i.ANIMATE=t.ANIMATE=e.ANIMATE=u.animate,i.TILE=u.tile,i.TILING_PADDING_VERTICAL=typeof u.tilingPaddingVertical=="function"?u.tilingPaddingVertical.call():u.tilingPaddingVertical,i.TILING_PADDING_HORIZONTAL=typeof u.tilingPaddingHorizontal=="function"?u.tilingPaddingHorizontal.call():u.tilingPaddingHorizontal};a.prototype.run=function(){var D,u,T=this.options;this.idToLNode={};var y=this.layout=new l,O=this;O.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this});var s=y.newGraphManager();this.gm=s;var f=this.options.eles.nodes(),c=this.options.eles.edges();this.root=s.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(f),y);for(var E=0;E<c.length;E++){var A=c[E],m=this.idToLNode[A.data("source")],C=this.idToLNode[A.data("target")];if(m!==C&&m.getEdgesBetween(C).length==0){var R=s.add(y.newEdge(),m,C);R.id=A.id()}}var M=function(w,x){typeof w=="number"&&(w=x);var F=w.data("id"),P=O.idToLNode[F];return{x:P.getRect().getCenterX(),y:P.getRect().getCenterY()}},S=function _(){for(var w=function(){T.fit&&T.cy.fit(T.eles,T.padding),D||(D=!0,O.cy.one("layoutready",T.ready),O.cy.trigger({type:"layoutready",layout:O}))},x=O.options.refresh,F,P=0;P<x&&!F;P++)F=O.stopped||O.layout.tick();if(F){y.checkLayoutSuccess()&&!y.isSubLayout&&y.doPostLayout(),y.tilingPostLayout&&y.tilingPostLayout(),y.isLayoutFinished=!0,O.options.eles.nodes().positions(M),w(),O.cy.one("layoutstop",O.options.stop),O.cy.trigger({type:"layoutstop",layout:O}),u&&cancelAnimationFrame(u),D=!1;return}var U=O.layout.getPositionsData();T.eles.nodes().positions(function(Y,X){if(typeof Y=="number"&&(Y=X),!Y.isParent()){for(var H=Y.id(),B=U[H],V=Y;B==null&&(B=U[V.data("parent")]||U["DummyCompound_"+V.data("parent")],U[H]=B,V=V.parent()[0],V!=null););return B!=null?{x:B.x,y:B.y}:{x:Y.position("x"),y:Y.position("y")}}}),w(),u=requestAnimationFrame(_)};return y.addListener("layoutstarted",function(){O.options.animate==="during"&&(u=requestAnimationFrame(S))}),y.runLayout(),this.options.animate!=="during"&&(O.options.eles.nodes().not(":parent").layoutPositions(O,O.options,M),D=!1),this},a.prototype.getTopMostNodes=function(D){for(var u={},T=0;T<D.length;T++)u[D[T].id()]=!0;var y=D.filter(function(O,s){typeof O=="number"&&(O=s);for(var f=O.parent()[0];f!=null;){if(u[f.id()])return!1;f=f.parent()[0]}return!0});return y},a.prototype.processChildrenList=function(D,u,T){for(var y=u.length,O=0;O<y;O++){var s=u[O],f=s.children(),c,E=s.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});if(s.outerWidth()!=null&&s.outerHeight()!=null?c=D.add(new g(T.graphManager,new n(s.position("x")-E.w/2,s.position("y")-E.h/2),new d(parseFloat(E.w),parseFloat(E.h)))):c=D.add(new g(this.graphManager)),c.id=s.data("id"),c.paddingLeft=parseInt(s.css("padding")),c.paddingTop=parseInt(s.css("padding")),c.paddingRight=parseInt(s.css("padding")),c.paddingBottom=parseInt(s.css("padding")),this.options.nodeDimensionsIncludeLabels&&s.isParent()){var A=s.boundingBox({includeLabels:!0,includeNodes:!1}).w,m=s.boundingBox({includeLabels:!0,includeNodes:!1}).h,C=s.css("text-halign");c.labelWidth=A,c.labelHeight=m,c.labelPos=C}if(this.idToLNode[s.data("id")]=c,isNaN(c.rect.x)&&(c.rect.x=0),isNaN(c.rect.y)&&(c.rect.y=0),f!=null&&f.length>0){var R;R=T.getGraphManager().add(T.newGraph(),c),this.processChildrenList(R,f,T)}}},a.prototype.stop=function(){return this.stopped=!0,this};var v=function(u){u("layout","cose-bilkent",a)};typeof cytoscape<"u"&&v(cytoscape),I.exports=v})])})})(k)),k.exports}var pt=ct();const dt=W.getDefaultExportFromCjs(pt);J.cytoscape.use(dt);function tt(G,b){G.forEach(N=>{const I={id:N.id,labelText:N.label,height:N.height,width:N.width,padding:N.padding??0};Object.keys(N).forEach(L=>{["id","label","height","width","padding","x","y"].includes(L)||(I[L]=N[L])}),b.add({group:"nodes",data:I,position:{x:N.x??0,y:N.y??0}})})}W.__name(tt,"addNodes");function et(G,b){G.forEach(N=>{const I={id:N.id,source:N.start,target:N.end};Object.keys(N).forEach(L=>{["id","start","end"].includes(L)||(I[L]=N[L])}),b.add({group:"edges",data:I})})}W.__name(et,"addEdges");function rt(G){return new Promise(b=>{const N=W.select("body").append("div").attr("id","cy").attr("style","display:none"),I=J.cytoscape({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});N.remove(),tt(G.nodes,I),et(G.edges,I),I.nodes().forEach(function(o){o.layoutDimensions=()=>{const e=o.data();return{w:e.width,h:e.height}}});const L={name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1};I.layout(L).run(),I.ready(o=>{W.log.info("Cytoscape ready",o),b(I)})})}W.__name(rt,"createCytoscapeInstance");function it(G){return G.nodes().map(b=>{const N=b.data(),I=b.position(),L={id:N.id,x:I.x,y:I.y};return Object.keys(N).forEach(o=>{o!=="id"&&(L[o]=N[o])}),L})}W.__name(it,"extractPositionedNodes");function nt(G){return G.edges().map(b=>{const N=b.data(),I=b._private.rscratch,L={id:N.id,source:N.source,target:N.target,startX:I.startX,startY:I.startY,midX:I.midX,midY:I.midY,endX:I.endX,endY:I.endY};return Object.keys(N).forEach(o=>{["id","source","target"].includes(o)||(L[o]=N[o])}),L})}W.__name(nt,"extractPositionedEdges");async function ot(G,b){W.log.debug("Starting cose-bilkent layout algorithm");try{st(G);const N=await rt(G),I=it(N),L=nt(N);return W.log.debug(`Layout completed: ${I.length} nodes, ${L.length} edges`),{nodes:I,edges:L}}catch(N){throw W.log.error("Error in cose-bilkent layout algorithm:",N),N}}W.__name(ot,"executeCoseBilkentLayout");function st(G){if(!G)throw new Error("Layout data is required");if(!G.config)throw new Error("Configuration is required in layout data");if(!G.rootNode)throw new Error("Root node is required");if(!G.nodes||!Array.isArray(G.nodes))throw new Error("No nodes found in layout data");if(!Array.isArray(G.edges))throw new Error("Edges array is required in layout data");return!0}W.__name(st,"validateLayoutData");var vt=W.__name(async(G,b,{insertCluster:N,insertEdge:I,insertEdgeLabel:L,insertMarkers:o,insertNode:e,log:t,positionEdgeLabel:i},{algorithm:l})=>{const g={},n={},d=b.select("g");o(d,G.markers,G.type,G.diagramId);const r=d.insert("g").attr("class","subgraphs"),h=d.insert("g").attr("class","edgePaths"),a=d.insert("g").attr("class","edgeLabels"),p=d.insert("g").attr("class","nodes");t.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(G.nodes.map(async u=>{if(u.isGroup){const T={...u};n[u.id]=T,g[u.id]=T,await N(r,u)}else{const T={...u};g[u.id]=T;const y=await e(p,u,{config:G.config,dir:G.direction||"TB"}),O=y.node().getBBox();T.width=O.width,T.height=O.height,T.domId=y,t.debug(`Node ${u.id} dimensions: ${O.width}x${O.height}`)}})),t.debug("Running cose-bilkent layout algorithm");const v={...G,nodes:G.nodes.map(u=>{const T=g[u.id];return{...u,width:T.width,height:T.height}})},D=await ot(v,G.config);t.debug("Positioning nodes based on layout results"),D.nodes.forEach(u=>{const T=g[u.id];T?.domId&&(T.domId.attr("transform",`translate(${u.x}, ${u.y})`),T.x=u.x,T.y=u.y,t.debug(`Positioned node ${T.id} at center (${u.x}, ${u.y})`))}),D.edges.forEach(u=>{const T=G.edges.find(y=>y.id===u.id);T&&(T.points=[{x:u.startX,y:u.startY},{x:u.midX,y:u.midY},{x:u.endX,y:u.endY}])}),t.debug("Inserting and positioning edges"),await Promise.all(G.edges.map(async u=>{await L(a,u);const T=g[u.start??""],y=g[u.end??""];if(T&&y){const O=D.edges.find(s=>s.id===u.id);if(O){t.debug("APA01 positionedEdge",O);const s={...u},f=I(h,s,n,G.type,T,y,G.diagramId);i(s,f)}else{const s={...u,points:[{x:T.x||0,y:T.y||0},{x:y.x||0,y:y.y||0}]},f=I(h,s,n,G.type,T,y,G.diagramId);i(s,f)}}})),t.debug("Cose-bilkent rendering completed")},"render"),yt=vt;exports.render=yt;
2
- //# sourceMappingURL=cose-bilkent-JH36ORCC-BzL-a0Zv.cjs.map
@@ -23764,4 +23764,3 @@ export {
23764
23764
  IB as i,
23765
23765
  dK as p
23766
23766
  };
23767
- //# sourceMappingURL=cynefin-VYW2F7L2-Bkk-F_Js.js.map
@@ -164,4 +164,3 @@ ${r}`),this.inline?`{${a}}`:a}},s(Zs,"JSDocTagImpl"),Zs);function RP(t,e,r){if(t
164
164
  `;break;case"r":r+="\r";break;case"t":r+=" ";break;default:r+=i}continue}r+=a}return r},"decodeEscapedString"),So,YU=(So=class extends gr{runConverter(e,r,n){const a=super.runConverter(e,r,n);if(e.name==="TITLE"&&typeof a=="string"){const i=a.trim();if(i.startsWith('"')&&i.endsWith('"')||i.startsWith("'")&&i.endsWith("'"))return O$(i)}return a}runCustomConverter(e,r,n){if(e.name==="PEG_STRING")return O$(r)}},s(So,"RailroadPegValueConverter"),So),jP={parser:{TokenBuilder:s(()=>new HU,"TokenBuilder"),ValueConverter:s(()=>new YU,"ValueConverter")}};function sv(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),OU,jP);return e.ServiceRegistry.register(r),{shared:e,RailroadPeg:r}}s(sv,"createRailroadPegServices");var wo,XU=(wo=class extends Tt{constructor(){super(["treemap"])}},s(wo,"TreemapTokenBuilder"),wo),JU=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,Io,ZU=(Io=class extends gr{runCustomConverter(e,r,n){if(e.name==="NUMBER2")return parseFloat(r.replace(/,/g,""));if(e.name==="SEPARATOR")return r.substring(1,r.length-1);if(e.name==="STRING2")return r.substring(1,r.length-1);if(e.name==="INDENTATION")return r.length;if(e.name==="ClassDef"){if(typeof r!="string")return r;const a=JU.exec(r);if(a)return{$type:"ClassDefStatement",className:a[1],styleText:a[2]||void 0}}}},s(Io,"TreemapValueConverter"),Io);function BP(t){const e=t.validation.TreemapValidator,r=t.validation.ValidationRegistry;if(r){const n={Treemap:e.checkSingleRoot.bind(e)};r.register(n,e)}}s(BP,"registerValidationChecks");var No,QU=(No=class{checkSingleRoot(e,r){let n;for(const a of e.TreemapRows)a.item&&(n===void 0&&a.indent===void 0?n=0:a.indent===void 0?r("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}):n!==void 0&&n>=parseInt(a.indent,10)&&r("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}))}},s(No,"TreemapValidator"),No),UP={parser:{TokenBuilder:s(()=>new XU,"TokenBuilder"),ValueConverter:s(()=>new ZU,"ValueConverter")},validation:{TreemapValidator:s(()=>new QU,"TreemapValidator")}};function KP(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),LU,UP);return e.ServiceRegistry.register(r),BP(r),{shared:e,Treemap:r}}s(KP,"createTreemapServices");var Po,eK=(Po=class extends gr{runCustomConverter(e,r,n){if(e.name.toUpperCase()==="LINK_LABEL")return r.substring(1).trim()}},s(Po,"WardleyValueConverter"),Po),WP={parser:{ValueConverter:s(()=>new eK,"ValueConverter")}};function qP(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),MU,WP);return e.ServiceRegistry.register(r),{shared:e,Wardley:r}}s(qP,"createWardleyServices");var ko,tK=(ko=class extends Tt{constructor(){super(["cynefin-beta"])}},s(ko,"CynefinTokenBuilder"),ko),VP={parser:{TokenBuilder:s(()=>new tK,"TokenBuilder"),ValueConverter:s(()=>new dl,"ValueConverter")}};function HP(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),EU,VP);return e.ServiceRegistry.register(r),{shared:e,Cynefin:r}}s(HP,"createCynefinServices");var Oo,rK=(Oo=class extends Tt{constructor(){super(["gitGraph"])}},s(Oo,"GitGraphTokenBuilder"),Oo),YP={parser:{TokenBuilder:s(()=>new rK,"TokenBuilder"),ValueConverter:s(()=>new dl,"ValueConverter")}};function XP(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),bU,YP);return e.ServiceRegistry.register(r),{shared:e,GitGraph:r}}s(XP,"createGitGraphServices");var Lo,nK=(Lo=class extends Tt{constructor(){super(["info","showInfo"])}},s(Lo,"InfoTokenBuilder"),Lo),JP={parser:{TokenBuilder:s(()=>new nK,"TokenBuilder"),ValueConverter:s(()=>new dl,"ValueConverter")}};function ZP(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),_U,JP);return e.ServiceRegistry.register(r),{shared:e,Info:r}}s(ZP,"createInfoServices");var Do,aK=(Do=class extends Tt{constructor(){super(["packet"])}},s(Do,"PacketTokenBuilder"),Do),QP={parser:{TokenBuilder:s(()=>new aK,"TokenBuilder"),ValueConverter:s(()=>new dl,"ValueConverter")}};function ek(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),SU,QP);return e.ServiceRegistry.register(r),{shared:e,Packet:r}}s(ek,"createPacketServices");var Mo,iK=(Mo=class extends Tt{constructor(){super(["pie","showData"])}},s(Mo,"PieTokenBuilder"),Mo),xo,sK=(xo=class extends gr{runCustomConverter(e,r,n){if(e.name==="PIE_SECTION_LABEL")return r.replace(/"/g,"").trim()}},s(xo,"PieValueConverter"),xo),tk={parser:{TokenBuilder:s(()=>new iK,"TokenBuilder"),ValueConverter:s(()=>new sK,"ValueConverter")}};function rk(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),wU,tk);return e.ServiceRegistry.register(r),{shared:e,Pie:r}}s(rk,"createPieServices");var Go,oK=(Go=class extends gr{runCustomConverter(e,r,n){if(e.name==="INDENTATION")return r?.length||0;if(e.name==="QUOTED_NAME")return r.substring(1,r.length-1);if(e.name==="BARE_NAME")return r.replace(/[\t ]+$/,"");if(e.name==="CLASS_ANNOTATION")return r.trim().substring(3).trim();if(e.name==="ICON_ANNOTATION"){const a=r.trim();return a.substring(5,a.length-1)}if(e.name==="DESC_ANNOTATION")return r.trim().substring(2).trim()}},s(Go,"TreeViewValueConverter"),Go),Fo,lK=(Fo=class extends Tt{constructor(){super(["treeView-beta"])}},s(Fo,"TreeViewTokenBuilder"),Fo),nk={parser:{TokenBuilder:s(()=>new lK,"TokenBuilder"),ValueConverter:s(()=>new oK,"ValueConverter")}};function ak(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),DU,nk);return e.ServiceRegistry.register(r),{shared:e,TreeView:r}}s(ak,"createTreeViewServices");var zo,uK=(zo=class extends Tt{constructor(){super(["architecture"])}},s(zo,"ArchitectureTokenBuilder"),zo),jo,cK=(jo=class extends gr{runCustomConverter(e,r,n){if(e.name==="ARCH_ICON")return r.replace(/[()]/g,"").trim();if(e.name==="ARCH_TEXT_ICON")return r.replace(/["()]/g,"");if(e.name==="ARCH_TITLE"){let a=r.replace(/^\[|]$/g,"").trim();return(a.startsWith('"')&&a.endsWith('"')||a.startsWith("'")&&a.endsWith("'"))&&(a=a.slice(1,-1),a=a.replace(/\\"/g,'"').replace(/\\'/g,"'")),a.trim()}}},s(jo,"ArchitectureValueConverter"),jo),ik={parser:{TokenBuilder:s(()=>new uK,"TokenBuilder"),ValueConverter:s(()=>new cK,"ValueConverter")}};function sk(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),AU,ik);return e.ServiceRegistry.register(r),{shared:e,Architecture:r}}s(sk,"createArchitectureServices");var Bo,fK=(Bo=class extends Tt{constructor(){super(["eventmodeling"])}},s(Bo,"EventModelingTokenBuilder"),Bo),L$=new Set(["cmd","command"]),D$=new Set(["evt","event"]),gp=new Set(["rmo","readmodel"]),M$=new Set(["pcr","processor"]),x$=new Set(["ui"]);function ok(t){const e=t.validation.EventModelingValidator,r=t.validation.ValidationRegistry;if(r){const n={EmTimeFrame:e.checkSourceFrameTypes.bind(e),EmResetFrame:e.checkSourceFrameTypes.bind(e)};r.register(n,e)}}s(ok,"registerValidationChecks");var Uo,dK=(Uo=class{checkSourceFrameTypes(e,r){e.sourceFrames.length!==0&&(L$.has(e.modelEntityType)?this.validateSources(e,new Set([...x$,...M$]),"command","ui or processor",r):D$.has(e.modelEntityType)?this.validateSources(e,L$,"event","command",r):gp.has(e.modelEntityType)?this.validateSources(e,D$,"read model","event",r):M$.has(e.modelEntityType)?this.validateSources(e,gp,"processor","read model",r):x$.has(e.modelEntityType)&&this.validateSources(e,gp,"ui","read model",r))}validateSources(e,r,n,a,i){for(const o of e.sourceFrames){const u=o.ref;u!==void 0&&!r.has(u.modelEntityType)&&i("error",`A ${n} can only receive input from a ${a}, not from '${u.modelEntityType}'.`,{node:e,property:"sourceFrames"})}}},s(Uo,"EventModelingValidator"),Uo),lk={parser:{TokenBuilder:s(()=>new fK,"TokenBuilder"),ValueConverter:s(()=>new dl,"ValueConverter")},validation:{EventModelingValidator:s(()=>new dK,"EventModelingValidator")}};function uk(t=st){const e=re(Je(t),vt),r=re(Xe({shared:e}),CU,lk);return e.ServiceRegistry.register(r),ok(r),{shared:e,EventModel:r}}s(uk,"createEventModelingServices");var rt={},pK={info:s(async()=>{const{createInfoServices:t}=await Promise.resolve().then(()=>mK),e=t().Info.parser.LangiumParser;rt.info=e},"info"),packet:s(async()=>{const{createPacketServices:t}=await Promise.resolve().then(()=>hK),e=t().Packet.parser.LangiumParser;rt.packet=e},"packet"),pie:s(async()=>{const{createPieServices:t}=await Promise.resolve().then(()=>yK),e=t().Pie.parser.LangiumParser;rt.pie=e},"pie"),treeView:s(async()=>{const{createTreeViewServices:t}=await Promise.resolve().then(()=>gK),e=t().TreeView.parser.LangiumParser;rt.treeView=e},"treeView"),architecture:s(async()=>{const{createArchitectureServices:t}=await Promise.resolve().then(()=>vK),e=t().Architecture.parser.LangiumParser;rt.architecture=e},"architecture"),gitGraph:s(async()=>{const{createGitGraphServices:t}=await Promise.resolve().then(()=>TK),e=t().GitGraph.parser.LangiumParser;rt.gitGraph=e},"gitGraph"),eventmodeling:s(async()=>{const{createEventModelingServices:t}=await Promise.resolve().then(()=>$K),e=t().EventModel.parser.LangiumParser;rt.eventmodeling=e},"eventmodeling"),radar:s(async()=>{const{createRadarServices:t}=await Promise.resolve().then(()=>RK),e=t().Radar.parser.LangiumParser;rt.radar=e},"radar"),railroad:s(async()=>{const{createRailroadServices:t}=await Promise.resolve().then(()=>AK),e=t().Railroad.parser.LangiumParser;rt.railroad=e},"railroad"),railroadEbnf:s(async()=>{const{createRailroadEbnfServices:t}=await Promise.resolve().then(()=>EK),e=t().RailroadEbnf.parser.LangiumParser;rt.railroadEbnf=e},"railroadEbnf"),railroadAbnf:s(async()=>{const{createRailroadAbnfServices:t}=await Promise.resolve().then(()=>CK),e=t().RailroadAbnf.parser.LangiumParser;rt.railroadAbnf=e},"railroadAbnf"),railroadPeg:s(async()=>{const{createRailroadPegServices:t}=await Promise.resolve().then(()=>bK),e=t().RailroadPeg.parser.LangiumParser;rt.railroadPeg=e},"railroadPeg"),treemap:s(async()=>{const{createTreemapServices:t}=await Promise.resolve().then(()=>_K),e=t().Treemap.parser.LangiumParser;rt.treemap=e},"treemap"),wardley:s(async()=>{const{createWardleyServices:t}=await Promise.resolve().then(()=>SK),e=t().Wardley.parser.LangiumParser;rt.wardley=e},"wardley"),cynefin:s(async()=>{const{createCynefinServices:t}=await Promise.resolve().then(()=>wK),e=t().Cynefin.parser.LangiumParser;rt.cynefin=e},"cynefin")};async function ck(t,e){const r=pK[t];if(!r)throw new Error(`Unknown diagram type: ${t}`);rt[t]||await r();const a=rt[t].parse(e);if(a.lexerErrors.length>0||a.parserErrors.length>0)throw new fk(a);return a.value}s(ck,"parse");var Ko,fk=(Ko=class extends Error{constructor(e){const r=e.lexerErrors.map(a=>{const i=a.line!==void 0&&!isNaN(a.line)?a.line:"?",o=a.column!==void 0&&!isNaN(a.column)?a.column:"?";return`Lexer error on line ${i}, column ${o}: ${a.message}`}).join(`
165
165
  `),n=e.parserErrors.map(a=>{const i=a.token.startLine!==void 0&&!isNaN(a.token.startLine)?a.token.startLine:"?",o=a.token.startColumn!==void 0&&!isNaN(a.token.startColumn)?a.token.startColumn:"?";return`Parse error on line ${i}, column ${o}: ${a.message}`}).join(`
166
166
  `);super(`Parsing failed: ${r} ${n}`),this.result=e}},s(Ko,"MermaidParseError"),Ko);const mK=Object.freeze(Object.defineProperty({__proto__:null,InfoModule:JP,createInfoServices:ZP},Symbol.toStringTag,{value:"Module"})),hK=Object.freeze(Object.defineProperty({__proto__:null,PacketModule:QP,createPacketServices:ek},Symbol.toStringTag,{value:"Module"})),yK=Object.freeze(Object.defineProperty({__proto__:null,PieModule:tk,createPieServices:rk},Symbol.toStringTag,{value:"Module"})),gK=Object.freeze(Object.defineProperty({__proto__:null,TreeViewModule:nk,createTreeViewServices:ak},Symbol.toStringTag,{value:"Module"})),vK=Object.freeze(Object.defineProperty({__proto__:null,ArchitectureModule:ik,createArchitectureServices:sk},Symbol.toStringTag,{value:"Module"})),TK=Object.freeze(Object.defineProperty({__proto__:null,GitGraphModule:YP,createGitGraphServices:XP},Symbol.toStringTag,{value:"Module"})),$K=Object.freeze(Object.defineProperty({__proto__:null,EventModelingModule:lk,createEventModelingServices:uk},Symbol.toStringTag,{value:"Module"})),RK=Object.freeze(Object.defineProperty({__proto__:null,RadarModule:MP,createRadarServices:xP},Symbol.toStringTag,{value:"Module"})),AK=Object.freeze(Object.defineProperty({__proto__:null,RailroadModule:GP,createRailroadServices:nv},Symbol.toStringTag,{value:"Module"})),EK=Object.freeze(Object.defineProperty({__proto__:null,RailroadEbnfModule:FP,createRailroadEbnfServices:av},Symbol.toStringTag,{value:"Module"})),CK=Object.freeze(Object.defineProperty({__proto__:null,RailroadAbnfModule:zP,createRailroadAbnfServices:iv},Symbol.toStringTag,{value:"Module"})),bK=Object.freeze(Object.defineProperty({__proto__:null,RailroadPegModule:jP,createRailroadPegServices:sv},Symbol.toStringTag,{value:"Module"})),_K=Object.freeze(Object.defineProperty({__proto__:null,TreemapModule:UP,createTreemapServices:KP},Symbol.toStringTag,{value:"Module"})),SK=Object.freeze(Object.defineProperty({__proto__:null,WardleyModule:WP,createWardleyServices:qP},Symbol.toStringTag,{value:"Module"})),wK=Object.freeze(Object.defineProperty({__proto__:null,CynefinModule:VP,createCynefinServices:HP},Symbol.toStringTag,{value:"Module"}));exports.MermaidParseError=fk;exports.createRailroadAbnfServices=iv;exports.createRailroadEbnfServices=av;exports.createRailroadPegServices=sv;exports.createRailroadServices=nv;exports.isEmResetFrame=LP;exports.parse=ck;
167
- //# sourceMappingURL=cynefin-VYW2F7L2-MpAliYy9.cjs.map
@@ -60,4 +60,3 @@
60
60
  fill: ${t.labelColor};
61
61
  }
62
62
  `},"styles"),Bt=kt,St={parser:wt,db:G,renderer:Tt,styles:Bt};exports.diagram=St;
63
- //# sourceMappingURL=cynefinDiagram-TSTJHNR4-B1lNDIu_.cjs.map
@@ -297,4 +297,3 @@ var at = {
297
297
  export {
298
298
  jt as diagram
299
299
  };
300
- //# sourceMappingURL=cynefinDiagram-TSTJHNR4-CUwuCyMp.js.map
@@ -319,4 +319,3 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
319
319
  else outColor = vIndex;`:"",`
320
320
  }
321
321
  `),o=Uy(a,n,s);o.aPosition=a.getAttribLocation(o,"aPosition"),o.aIndex=a.getAttribLocation(o,"aIndex"),o.aVertType=a.getAttribLocation(o,"aVertType"),o.aTransform=a.getAttribLocation(o,"aTransform"),o.aAtlasId=a.getAttribLocation(o,"aAtlasId"),o.aTex=a.getAttribLocation(o,"aTex"),o.aPointAPointB=a.getAttribLocation(o,"aPointAPointB"),o.aPointCPointD=a.getAttribLocation(o,"aPointCPointD"),o.aLineWidth=a.getAttribLocation(o,"aLineWidth"),o.aColor=a.getAttribLocation(o,"aColor"),o.aCornerRadius=a.getAttribLocation(o,"aCornerRadius"),o.aBorderColor=a.getAttribLocation(o,"aBorderColor"),o.uPanZoomMatrix=a.getUniformLocation(o,"uPanZoomMatrix"),o.uAtlasSize=a.getUniformLocation(o,"uAtlasSize"),o.uBGColor=a.getUniformLocation(o,"uBGColor"),o.uZoom=a.getUniformLocation(o,"uZoom"),o.uTextures=[];for(var u=0;u<this.batchManager.getMaxAtlasesPerBatch();u++)o.uTextures.push(a.getUniformLocation(o,"uTexture".concat(u)));return o}},{key:"_createVAO",value:function(){var t=[0,0,1,0,1,1,0,0,1,1,0,1];this.vertexCount=t.length/2;var a=this.maxInstances,n=this.gl,i=this.program,s=n.createVertexArray();return n.bindVertexArray(s),rm(n,"vec2",i.aPosition,t),this.transformBuffer=tm(n,a,i.aTransform),this.indexBuffer=Fr(n,a,"vec4",i.aIndex),this.vertTypeBuffer=Fr(n,a,"int",i.aVertType),this.atlasIdBuffer=Fr(n,a,"int",i.aAtlasId),this.texBuffer=Fr(n,a,"vec4",i.aTex),this.pointAPointBBuffer=Fr(n,a,"vec4",i.aPointAPointB),this.pointCPointDBuffer=Fr(n,a,"vec4",i.aPointCPointD),this.lineWidthBuffer=Fr(n,a,"vec2",i.aLineWidth),this.colorBuffer=Fr(n,a,"vec4",i.aColor),this.cornerRadiusBuffer=Fr(n,a,"vec4",i.aCornerRadius),this.borderColorBuffer=Fr(n,a,"vec4",i.aBorderColor),n.bindVertexArray(null),s}},{key:"buffers",get:function(){var t=this;return this._buffers||(this._buffers=Object.keys(this).filter(function(a){return tt(a,"Buffer")}).map(function(a){return t[a]})),this._buffers}},{key:"startFrame",value:function(t){var a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Ea.SCREEN;this.panZoomMatrix=t,this.renderTarget=a,this.batchDebugInfo=[],this.wrappedCount=0,this.simpleCount=0,this.startBatch()}},{key:"startBatch",value:function(){this.instanceCount=0,this.batchManager.startBatch()}},{key:"endFrame",value:function(){this.endBatch()}},{key:"_isVisible",value:function(t,a){return t.visible()?a&&a.isVisible?a.isVisible(t):!0:!1}},{key:"drawTexture",value:function(t,a,n){var i=this.atlasManager,s=this.batchManager,o=i.getRenderTypeOpts(n);if(this._isVisible(t,o)&&!(t.isEdge()&&!this._isValidEdge(t))){if(this.renderTarget.picking&&o.getTexPickingMode){var u=o.getTexPickingMode(t);if(u===An.IGNORE)return;if(u==An.USE_BB){this.drawPickingRectangle(t,a,n);return}}var l=i.getAtlasInfo(t,n),v=Cr(l),f;try{for(v.s();!(f=v.n()).done;){var c=f.value,h=c.atlas,d=c.tex1,y=c.tex2;s.canAddToCurrentBatch(h)||this.endBatch();for(var g=s.getAtlasIndexForBatch(h),p=0,m=[[d,!0],[y,!1]];p<m.length;p++){var b=Qe(m[p],2),w=b[0],E=b[1];if(w.w!=0){var C=this.instanceCount;this.vertTypeBuffer.getView(C)[0]=Cs;var x=this.indexBuffer.getView(C);Vt(a,x);var S=this.atlasIdBuffer.getView(C);S[0]=g;var k=this.texBuffer.getView(C);k[0]=w.x,k[1]=w.y,k[2]=w.w,k[3]=w.h;var B=this.transformBuffer.getMatrixView(C);this.setTransformMatrix(t,B,o,c,E),this.instanceCount++,E||this.wrappedCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}}catch(D){v.e(D)}finally{v.f()}}}},{key:"setTransformMatrix",value:function(t,a,n,i){var s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,o=0;if(n.shapeProps&&n.shapeProps.padding&&(o=t.pstyle(n.shapeProps.padding).pfValue),i){var u=i.bb,l=i.tex1,v=i.tex2,f=l.w/(l.w+v.w);s||(f=1-f);var c=this._getAdjustedBB(u,o,s,f);this._applyTransformMatrix(a,c,n,t)}else{var h=n.getBoundingBox(t),d=this._getAdjustedBB(h,o,!0,1);this._applyTransformMatrix(a,d,n,t)}}},{key:"_applyTransformMatrix",value:function(t,a,n,i){var s,o;$l(t);var u=n.getRotation?n.getRotation(i):0;if(u!==0){var l=n.getRotationPoint(i),v=l.x,f=l.y;yn(t,t,[v,f]),Ul(t,t,u);var c=n.getRotationOffset(i);s=c.x+(a.xOffset||0),o=c.y+(a.yOffset||0)}else s=a.x1,o=a.y1;yn(t,t,[s,o]),Ws(t,t,[a.w,a.h])}},{key:"_getAdjustedBB",value:function(t,a,n,i){var s=t.x1,o=t.y1,u=t.w,l=t.h,v=t.yOffset;a&&(s-=a,o-=a,u+=2*a,l+=2*a);var f=0,c=u*i;return n&&i<1?u=c:!n&&i<1&&(f=u-c,s+=f,u=c),{x1:s,y1:o,w:u,h:l,xOffset:f,yOffset:v}}},{key:"drawPickingRectangle",value:function(t,a,n){var i=this.atlasManager.getRenderTypeOpts(n),s=this.instanceCount;this.vertTypeBuffer.getView(s)[0]=qt;var o=this.indexBuffer.getView(s);Vt(a,o);var u=this.colorBuffer.getView(s);wt([0,0,0],1,u);var l=this.transformBuffer.getMatrixView(s);this.setTransformMatrix(t,l,i),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}},{key:"drawNode",value:function(t,a,n){var i=this.simpleShapeOptions.get(n);if(this._isVisible(t,i)){var s=i.shapeProps,o=this._getVertTypeForShape(t,s.shape);if(o===void 0||i.isSimple&&!i.isSimple(t,this.renderTarget)){this.drawTexture(t,a,n);return}var u=this.instanceCount;if(this.vertTypeBuffer.getView(u)[0]=o,o===sn||o===ga){var l=i.getBoundingBox(t),v=this._getCornerRadius(t,s.radius,l),f=this.cornerRadiusBuffer.getView(u);f[0]=v,f[1]=v,f[2]=v,f[3]=v,o===ga&&(f[0]=0,f[2]=0)}var c=this.indexBuffer.getView(u);Vt(a,c);var h=this.renderTarget.picking?1:n==="node-body"?t.effectiveOpacity():1,d=this.renderTarget.picking?1:t.pstyle(s.opacity).value*h,y=t.pstyle(s.color).value,g=this.colorBuffer.getView(u);wt(y,d,g);var p=this.lineWidthBuffer.getView(u);if(p[0]=0,p[1]=0,s.border){var m=t.pstyle("border-width").value;if(m>0){var b=t.pstyle("border-color").value,w=h*t.pstyle("border-opacity").value,E=this.borderColorBuffer.getView(u);wt(b,w,E);var C=t.pstyle("border-position").value;if(C==="inside")p[0]=0,p[1]=-m;else if(C==="outside")p[0]=m,p[1]=0;else{var x=m/2;p[0]=x,p[1]=-x}}}var S=this.transformBuffer.getMatrixView(u);this.setTransformMatrix(t,S,i),this.simpleCount++,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}},{key:"_getVertTypeForShape",value:function(t,a){var n=t.pstyle(a).value;switch(n){case"rectangle":return qt;case"ellipse":return pa;case"roundrectangle":case"round-rectangle":return sn;case"bottom-round-rectangle":return ga;default:return}}},{key:"_getCornerRadius",value:function(t,a,n){var i=n.w,s=n.h;if(t.pstyle(a).value==="auto")return lt(i,s);var o=t.pstyle(a).pfValue,u=i/2,l=s/2;return Math.min(o,l,u)}},{key:"drawEdgeArrow",value:function(t,a,n){if(t.visible()){var i=t._private.rscratch,s,o,u;if(n==="source"?(s=i.arrowStartX,o=i.arrowStartY,u=i.srcArrowAngle):(s=i.arrowEndX,o=i.arrowEndY,u=i.tgtArrowAngle),!(isNaN(s)||s==null||isNaN(o)||o==null||isNaN(u)||u==null)){var l=t.pstyle(n+"-arrow-shape").value;if(l!=="none"){var v=t.pstyle(n+"-arrow-color").value,f=t.pstyle("opacity").value,c=t.pstyle("line-opacity").value,h=f*c,d=t.pstyle("width").pfValue,y=t.pstyle("arrow-scale").value,g=this.r.getArrowWidth(d,y),p=this.instanceCount,m=this.transformBuffer.getMatrixView(p);$l(m),yn(m,m,[s,o]),Ws(m,m,[g,g]),Ul(m,m,u),this.vertTypeBuffer.getView(p)[0]=Ts;var b=this.indexBuffer.getView(p);Vt(a,b);var w=this.colorBuffer.getView(p);wt(v,h,w),this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}}},{key:"drawEdgeLine",value:function(t,a){if(t.visible()){var n=this._getEdgePoints(t);if(n){var i=t.pstyle("opacity").value,s=t.pstyle("line-opacity").value,o=t.pstyle("width").pfValue,u=t.pstyle("line-color").value,l=i*s;if(n.length/2+this.instanceCount>this.maxInstances&&this.endBatch(),n.length==4){var v=this.instanceCount;this.vertTypeBuffer.getView(v)[0]=Kl;var f=this.indexBuffer.getView(v);Vt(a,f);var c=this.colorBuffer.getView(v);wt(u,l,c);var h=this.lineWidthBuffer.getView(v);h[0]=o;var d=this.pointAPointBBuffer.getView(v);d[0]=n[0],d[1]=n[1],d[2]=n[2],d[3]=n[3],this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}else for(var y=0;y<n.length-2;y+=2){var g=this.instanceCount;this.vertTypeBuffer.getView(g)[0]=Xl;var p=this.indexBuffer.getView(g);Vt(a,p);var m=this.colorBuffer.getView(g);wt(u,l,m);var b=this.lineWidthBuffer.getView(g);b[0]=o;var w=n[y-2],E=n[y-1],C=n[y],x=n[y+1],S=n[y+2],k=n[y+3],B=n[y+4],D=n[y+5];y==0&&(w=2*C-S+.001,E=2*x-k+.001),y==n.length-4&&(B=2*S-C+.001,D=2*k-x+.001);var P=this.pointAPointBBuffer.getView(g);P[0]=w,P[1]=E,P[2]=C,P[3]=x;var A=this.pointCPointDBuffer.getView(g);A[0]=S,A[1]=k,A[2]=B,A[3]=D,this.instanceCount++,this.instanceCount>=this.maxInstances&&this.endBatch()}}}}},{key:"_isValidEdge",value:function(t){var a=t._private.rscratch;return!(a.badLine||a.allpts==null||isNaN(a.allpts[0]))}},{key:"_getEdgePoints",value:function(t){var a=t._private.rscratch;if(this._isValidEdge(t)){var n=a.allpts;if(n.length==4)return n;var i=this._getNumSegments(t);return this._getCurveSegmentPoints(n,i)}}},{key:"_getNumSegments",value:function(t){var a=15;return Math.min(Math.max(a,5),this.maxInstances)}},{key:"_getCurveSegmentPoints",value:function(t,a){if(t.length==4)return t;for(var n=Array((a+1)*2),i=0;i<=a;i++)if(i==0)n[0]=t[0],n[1]=t[1];else if(i==a)n[i*2]=t[t.length-2],n[i*2+1]=t[t.length-1];else{var s=i/a;this._setCurvePoint(t,s,n,i*2)}return n}},{key:"_setCurvePoint",value:function(t,a,n,i){if(t.length<=2)n[i]=t[0],n[i+1]=t[1];else{for(var s=Array(t.length-2),o=0;o<s.length;o+=2){var u=(1-a)*t[o]+a*t[o+2],l=(1-a)*t[o+1]+a*t[o+3];s[o]=u,s[o+1]=l}return this._setCurvePoint(s,a,n,i)}}},{key:"endBatch",value:function(){var t=this.gl,a=this.vao,n=this.vertexCount,i=this.instanceCount;if(i!==0){var s=this.renderTarget.picking?this.pickingProgram:this.program;t.useProgram(s),t.bindVertexArray(a);var o=Cr(this.buffers),u;try{for(o.s();!(u=o.n()).done;){var l=u.value;l.bufferSubData(i)}}catch(d){o.e(d)}finally{o.f()}for(var v=this.batchManager.getAtlases(),f=0;f<v.length;f++)v[f].bufferIfNeeded(t);for(var c=0;c<v.length;c++)t.activeTexture(t.TEXTURE0+c),t.bindTexture(t.TEXTURE_2D,v[c].texture),t.uniform1i(s.uTextures[c],c);t.uniform1f(s.uZoom,Xy(this.r)),t.uniformMatrix3fv(s.uPanZoomMatrix,!1,this.panZoomMatrix),t.uniform1i(s.uAtlasSize,this.batchManager.getAtlasSize());var h=wt(this.bgColor,1);t.uniform4fv(s.uBGColor,h),t.drawArraysInstanced(t.TRIANGLES,0,n,i),t.bindVertexArray(null),t.bindTexture(t.TEXTURE_2D,null),this.debug&&this.batchDebugInfo.push({count:i,atlasCount:v.length}),this.startBatch()}}},{key:"getDebugInfo",value:function(){var t=this.atlasManager.getDebugInfo(),a=t.reduce(function(s,o){return s+o.atlasCount},0),n=this.batchDebugInfo,i=n.reduce(function(s,o){return s+o.count},0);return{atlasInfo:t,totalAtlases:a,wrappedCount:this.wrappedCount,simpleCount:this.simpleCount,batchCount:n.length,batchInfo:n,totalInstances:i}}}])})(),Lf={};Lf.initWebgl=function(r,e){var t=this,a=t.data.contexts[t.WEBGL];r.bgColor=pm(t),r.webglTexSize=Math.min(r.webglTexSize,a.getParameter(a.MAX_TEXTURE_SIZE)),r.webglTexRows=Math.min(r.webglTexRows,54),r.webglTexRowsNodes=Math.min(r.webglTexRowsNodes,54),r.webglBatchSize=Math.min(r.webglBatchSize,16384),r.webglTexPerBatch=Math.min(r.webglTexPerBatch,a.getParameter(a.MAX_TEXTURE_IMAGE_UNITS)),t.webglDebug=r.webglDebug,t.webglDebugShowAtlases=r.webglDebugShowAtlases,t.pickingFrameBuffer=am(a),t.pickingFrameBuffer.needsDraw=!0,t.drawing=new gm(t,a,r);var n=function(f){return function(c){return t.getTextAngle(c,f)}},i=function(f){return function(c){var h=c.pstyle(f);return h&&h.value}},s=function(f){return function(c){return c.pstyle("".concat(f,"-opacity")).value>0}},o=function(f){var c=f.pstyle("text-events").strValue==="yes";return c?An.USE_BB:An.IGNORE},u=function(f){var c=f.position(),h=c.x,d=c.y,y=f.outerWidth(),g=f.outerHeight();return{w:y,h:g,x1:h-y/2,y1:d-g/2}};t.drawing.addAtlasCollection("node",{texRows:r.webglTexRowsNodes}),t.drawing.addAtlasCollection("label",{texRows:r.webglTexRows}),t.drawing.addTextureAtlasRenderType("node-body",{collection:"node",getKey:e.getStyleKey,getBoundingBox:e.getElementBox,drawElement:e.drawElement}),t.drawing.addSimpleShapeRenderType("node-body",{getBoundingBox:u,isSimple:Zy,shapeProps:{shape:"shape",color:"background-color",opacity:"background-opacity",radius:"corner-radius",border:!0}}),t.drawing.addSimpleShapeRenderType("node-overlay",{getBoundingBox:u,isVisible:s("overlay"),shapeProps:{shape:"overlay-shape",color:"overlay-color",opacity:"overlay-opacity",padding:"overlay-padding",radius:"overlay-corner-radius"}}),t.drawing.addSimpleShapeRenderType("node-underlay",{getBoundingBox:u,isVisible:s("underlay"),shapeProps:{shape:"underlay-shape",color:"underlay-color",opacity:"underlay-opacity",padding:"underlay-padding",radius:"underlay-corner-radius"}}),t.drawing.addTextureAtlasRenderType("label",{collection:"label",getTexPickingMode:o,getKey:Ss(e.getLabelKey,null),getBoundingBox:ks(e.getLabelBox,null),drawClipped:!0,drawElement:e.drawLabel,getRotation:n(null),getRotationPoint:e.getLabelRotationPoint,getRotationOffset:e.getLabelRotationOffset,isVisible:i("label")}),t.drawing.addTextureAtlasRenderType("edge-source-label",{collection:"label",getTexPickingMode:o,getKey:Ss(e.getSourceLabelKey,"source"),getBoundingBox:ks(e.getSourceLabelBox,"source"),drawClipped:!0,drawElement:e.drawSourceLabel,getRotation:n("source"),getRotationPoint:e.getSourceLabelRotationPoint,getRotationOffset:e.getSourceLabelRotationOffset,isVisible:i("source-label")}),t.drawing.addTextureAtlasRenderType("edge-target-label",{collection:"label",getTexPickingMode:o,getKey:Ss(e.getTargetLabelKey,"target"),getBoundingBox:ks(e.getTargetLabelBox,"target"),drawClipped:!0,drawElement:e.drawTargetLabel,getRotation:n("target"),getRotationPoint:e.getTargetLabelRotationPoint,getRotationOffset:e.getTargetLabelRotationOffset,isVisible:i("target-label")});var l=Fa(function(){console.log("garbage collect flag set"),t.data.gc=!0},1e4);t.onUpdateEleCalcs(function(v,f){var c=!1;f&&f.length>0&&(c|=t.drawing.invalidate(f)),c&&l()}),ym(t)};function pm(r){var e=r.cy.container(),t=e&&e.style&&e.style.backgroundColor||"white";return iv(t)}function If(r,e){var t=r._private.rscratch;return yr(t,"labelWrapCachedLines",e)||[]}var Ss=function(e,t){return function(a){var n=e(a),i=If(a,t);return i.length>1?i.map(function(s,o){return"".concat(n,"_").concat(o)}):n}},ks=function(e,t){return function(a,n){var i=e(a);if(typeof n=="string"){var s=n.indexOf("_");if(s>0){var o=Number(n.substring(s+1)),u=If(a,t),l=i.h/u.length,v=l*o,f=i.y1+v;return{x1:i.x1,w:i.w,y1:f,h:l,yOffset:v}}}return i}};function ym(r){{var e=r.render;r.render=function(i){i=i||{};var s=r.cy;r.webgl&&(s.zoom()>kf?(mm(r),e.call(r,i)):(bm(r),Nf(r,i,Ea.SCREEN)))}}{var t=r.matchCanvasSize;r.matchCanvasSize=function(i){t.call(r,i),r.pickingFrameBuffer.setFramebufferAttachmentSizes(r.canvasWidth,r.canvasHeight),r.pickingFrameBuffer.needsDraw=!0}}r.findNearestElements=function(i,s,o,u){return Sm(r,i,s)};{var a=r.invalidateCachedZSortedEles;r.invalidateCachedZSortedEles=function(){a.call(r),r.pickingFrameBuffer.needsDraw=!0}}{var n=r.notify;r.notify=function(i,s){n.call(r,i,s),i==="viewport"||i==="bounds"?r.pickingFrameBuffer.needsDraw=!0:i==="background"&&r.drawing.invalidate(s,{type:"node-body"})}}}function mm(r){var e=r.data.contexts[r.WEBGL];e.clear(e.COLOR_BUFFER_BIT|e.DEPTH_BUFFER_BIT)}function bm(r){var e=function(a){a.save(),a.setTransform(1,0,0,1,0,0),a.clearRect(0,0,r.canvasWidth,r.canvasHeight),a.restore()};e(r.data.contexts[r.NODE]),e(r.data.contexts[r.DRAG])}function wm(r){var e=r.canvasWidth,t=r.canvasHeight,a=bo(r),n=a.pan,i=a.zoom,s=Es();yn(s,s,[n.x,n.y]),Ws(s,s,[i,i]);var o=Es();im(o,e,t);var u=Es();return nm(u,o,s),u}function Of(r,e){var t=r.canvasWidth,a=r.canvasHeight,n=bo(r),i=n.pan,s=n.zoom;e.setTransform(1,0,0,1,0,0),e.clearRect(0,0,t,a),e.translate(i.x,i.y),e.scale(s,s)}function xm(r,e){r.drawSelectionRectangle(e,function(t){return Of(r,t)})}function Em(r){var e=r.data.contexts[r.NODE];e.save(),Of(r,e),e.strokeStyle="rgba(0, 0, 0, 0.3)",e.beginPath(),e.moveTo(-1e3,0),e.lineTo(1e3,0),e.stroke(),e.beginPath(),e.moveTo(0,-1e3),e.lineTo(0,1e3),e.stroke(),e.restore()}function Cm(r){var e=function(n,i,s){for(var o=n.atlasManager.getAtlasCollection(i),u=r.data.contexts[r.NODE],l=o.atlases,v=0;v<l.length;v++){var f=l[v],c=f.canvas;if(c){var h=c.width,d=c.height,y=h*v,g=c.height*s,p=.4;u.save(),u.scale(p,p),u.drawImage(c,y,g),u.strokeStyle="black",u.rect(y,g,h,d),u.stroke(),u.restore()}}},t=0;e(r.drawing,"node",t++),e(r.drawing,"label",t++)}function Tm(r,e,t,a,n){var i,s,o,u,l=bo(r),v=l.pan,f=l.zoom;{var c=Yy(r,v,f,e,t),h=Qe(c,2),d=h[0],y=h[1],g=6;i=d-g/2,s=y-g/2,o=g,u=g}if(o===0||u===0)return[];var p=r.data.contexts[r.WEBGL];p.bindFramebuffer(p.FRAMEBUFFER,r.pickingFrameBuffer),r.pickingFrameBuffer.needsDraw&&(p.viewport(0,0,p.canvas.width,p.canvas.height),Nf(r,null,Ea.PICKING),r.pickingFrameBuffer.needsDraw=!1);var m=o*u,b=new Uint8Array(m*4);p.readPixels(i,s,o,u,p.RGBA,p.UNSIGNED_BYTE,b),p.bindFramebuffer(p.FRAMEBUFFER,null);for(var w=new Set,E=0;E<m;E++){var C=b.slice(E*4,E*4+4),x=Jy(C)-1;x>=0&&w.add(x)}return w}function Sm(r,e,t){var a=Tm(r,e,t),n=r.getCachedZSortedEles(),i,s,o=Cr(a),u;try{for(o.s();!(u=o.n()).done;){var l=u.value,v=n[l];if(!i&&v.isNode()&&(i=v),!s&&v.isEdge()&&(s=v),i&&s)break}}catch(f){o.e(f)}finally{o.f()}return[i,s].filter(Boolean)}function Ds(r,e,t){var a=r.drawing;e+=1,t.isNode()?(a.drawNode(t,e,"node-underlay"),a.drawNode(t,e,"node-body"),a.drawTexture(t,e,"label"),a.drawNode(t,e,"node-overlay")):(a.drawEdgeLine(t,e),a.drawEdgeArrow(t,e,"source"),a.drawEdgeArrow(t,e,"target"),a.drawTexture(t,e,"label"),a.drawTexture(t,e,"edge-source-label"),a.drawTexture(t,e,"edge-target-label"))}function Nf(r,e,t){var a;r.webglDebug&&(a=performance.now());var n=r.drawing,i=0;if(t.screen&&r.data.canvasNeedsRedraw[r.SELECT_BOX]&&xm(r,e),r.data.canvasNeedsRedraw[r.NODE]||t.picking){var s=r.data.contexts[r.WEBGL];t.screen?(s.clearColor(0,0,0,0),s.enable(s.BLEND),s.blendFunc(s.ONE,s.ONE_MINUS_SRC_ALPHA)):s.disable(s.BLEND),s.clear(s.COLOR_BUFFER_BIT|s.DEPTH_BUFFER_BIT),s.viewport(0,0,s.canvas.width,s.canvas.height);var o=wm(r),u=r.getCachedZSortedEles();if(i=u.length,n.startFrame(o,t),t.screen){for(var l=0;l<u.nondrag.length;l++)Ds(r,l,u.nondrag[l]);for(var v=0;v<u.drag.length;v++)Ds(r,v,u.drag[v])}else if(t.picking)for(var f=0;f<u.length;f++)Ds(r,f,u[f]);n.endFrame(),t.screen&&r.webglDebugShowAtlases&&(Em(r),Cm(r)),r.data.canvasNeedsRedraw[r.NODE]=!1,r.data.canvasNeedsRedraw[r.DRAG]=!1}if(r.webglDebug){var c=performance.now(),h=!1,d=Math.ceil(c-a),y=n.getDebugInfo(),g=["".concat(i," elements"),"".concat(y.totalInstances," instances"),"".concat(y.batchCount," batches"),"".concat(y.totalAtlases," atlases"),"".concat(y.wrappedCount," wrapped textures"),"".concat(y.simpleCount," simple shapes")].join(", ");if(h)console.log("WebGL (".concat(t.name,") - time ").concat(d,"ms, ").concat(g));else{console.log("WebGL (".concat(t.name,") - frame time ").concat(d,"ms")),console.log("Totals:"),console.log(" ".concat(g)),console.log("Texture Atlases Used:");var p=y.atlasInfo,m=Cr(p),b;try{for(m.s();!(b=m.n()).done;){var w=b.value;console.log(" ".concat(w.type,": ").concat(w.keyCount," keys, ").concat(w.atlasCount," atlases"))}}catch(E){m.e(E)}finally{m.f()}console.log("")}}r.data.gc&&(console.log("Garbage Collect!"),r.data.gc=!1,n.gc())}var yt={};yt.drawPolygonPath=function(r,e,t,a,n,i){var s=a/2,o=n/2;r.beginPath&&r.beginPath(),r.moveTo(e+s*i[0],t+o*i[1]);for(var u=1;u<i.length/2;u++)r.lineTo(e+s*i[u*2],t+o*i[u*2+1]);r.closePath()};yt.drawRoundPolygonPath=function(r,e,t,a,n,i,s){s.forEach(function(o){return pf(r,o)}),r.closePath()};yt.drawRoundRectanglePath=function(r,e,t,a,n,i){var s=a/2,o=n/2,u=i==="auto"?lt(a,n):Math.min(i,o,s);r.beginPath&&r.beginPath(),r.moveTo(e,t-o),r.arcTo(e+s,t-o,e+s,t,u),r.arcTo(e+s,t+o,e,t+o,u),r.arcTo(e-s,t+o,e-s,t,u),r.arcTo(e-s,t-o,e,t-o,u),r.lineTo(e,t-o),r.closePath()};yt.drawBottomRoundRectanglePath=function(r,e,t,a,n,i){var s=a/2,o=n/2,u=i==="auto"?lt(a,n):i;r.beginPath&&r.beginPath(),r.moveTo(e,t-o),r.lineTo(e+s,t-o),r.lineTo(e+s,t),r.arcTo(e+s,t+o,e,t+o,u),r.arcTo(e-s,t+o,e-s,t,u),r.lineTo(e-s,t-o),r.lineTo(e,t-o),r.closePath()};yt.drawCutRectanglePath=function(r,e,t,a,n,i,s){var o=a/2,u=n/2,l=s==="auto"?no():s;r.beginPath&&r.beginPath(),r.moveTo(e-o+l,t-u),r.lineTo(e+o-l,t-u),r.lineTo(e+o,t-u+l),r.lineTo(e+o,t+u-l),r.lineTo(e+o-l,t+u),r.lineTo(e-o+l,t+u),r.lineTo(e-o,t+u-l),r.lineTo(e-o,t-u+l),r.closePath()};yt.drawBarrelPath=function(r,e,t,a,n){var i=a/2,s=n/2,o=e-i,u=e+i,l=t-s,v=t+s,f=As(a,n),c=f.widthOffset,h=f.heightOffset,d=f.ctrlPtOffsetPct*c;r.beginPath&&r.beginPath(),r.moveTo(o,l+h),r.lineTo(o,v-h),r.quadraticCurveTo(o+d,v,o+c,v),r.lineTo(u-c,v),r.quadraticCurveTo(u-d,v,u,v-h),r.lineTo(u,l+h),r.quadraticCurveTo(u-d,l,u-c,l),r.lineTo(o+c,l),r.quadraticCurveTo(o+d,l,o,l+h),r.closePath()};var Yl=Math.sin(0),Zl=Math.cos(0),$s={},Us={},zf=Math.PI/40;for(var _t=0*Math.PI;_t<2*Math.PI;_t+=zf)$s[_t]=Math.sin(_t),Us[_t]=Math.cos(_t);yt.drawEllipsePath=function(r,e,t,a,n){if(r.beginPath&&r.beginPath(),r.ellipse)r.ellipse(e,t,a/2,n/2,0,0,2*Math.PI);else for(var i,s,o=a/2,u=n/2,l=0*Math.PI;l<2*Math.PI;l+=zf)i=e-o*$s[l]*Yl+o*Us[l]*Zl,s=t+u*Us[l]*Yl+u*$s[l]*Zl,l===0?r.moveTo(i,s):r.lineTo(i,s);r.closePath()};var Wa={};Wa.createBuffer=function(r,e){var t=document.createElement("canvas");return t.width=r,t.height=e,[t,t.getContext("2d")]};Wa.bufferCanvasImage=function(r){var e=this.cy,t=e.mutableElements(),a=t.boundingBox(),n=this.findContainerClientCoords(),i=r.full?Math.ceil(a.w):n[2],s=r.full?Math.ceil(a.h):n[3],o=ae(r.maxWidth)||ae(r.maxHeight),u=this.getPixelRatio(),l=1;if(r.scale!==void 0)i*=r.scale,s*=r.scale,l=r.scale;else if(o){var v=1/0,f=1/0;ae(r.maxWidth)&&(v=l*r.maxWidth/i),ae(r.maxHeight)&&(f=l*r.maxHeight/s),l=Math.min(v,f),i*=l,s*=l}o||(i*=u,s*=u,l*=u);var c=document.createElement("canvas");c.width=i,c.height=s,c.style.width=i+"px",c.style.height=s+"px";var h=c.getContext("2d");if(i>0&&s>0){h.clearRect(0,0,i,s),h.globalCompositeOperation="source-over";var d=this.getCachedZSortedEles();if(r.full)h.translate(-a.x1*l,-a.y1*l),h.scale(l,l),this.drawElements(h,d),h.scale(1/l,1/l),h.translate(a.x1*l,a.y1*l);else{var y=e.pan(),g={x:y.x*l,y:y.y*l};l*=e.zoom(),h.translate(g.x,g.y),h.scale(l,l),this.drawElements(h,d),h.scale(1/l,1/l),h.translate(-g.x,-g.y)}r.bg&&(h.globalCompositeOperation="destination-over",h.fillStyle=r.bg,h.rect(0,0,i,s),h.fill())}return c};function km(r,e){for(var t=atob(r),a=new ArrayBuffer(t.length),n=new Uint8Array(a),i=0;i<t.length;i++)n[i]=t.charCodeAt(i);return new Blob([a],{type:e})}function Ql(r){var e=r.indexOf(",");return r.substr(e+1)}function Ff(r,e,t){var a=function(){return e.toDataURL(t,r.quality)};switch(r.output){case"blob-promise":return new ta(function(n,i){try{e.toBlob(function(s){s!=null?n(s):i(new Error("`canvas.toBlob()` sent a null value in its callback"))},t,r.quality)}catch(s){i(s)}});case"blob":return km(Ql(a()),t);case"base64":return Ql(a());default:return a()}}Wa.png=function(r){return Ff(r,this.bufferCanvasImage(r),"image/png")};Wa.jpg=function(r){return Ff(r,this.bufferCanvasImage(r),"image/jpeg")};var Vf={};Vf.nodeShapeImpl=function(r,e,t,a,n,i,s,o){switch(r){case"ellipse":return this.drawEllipsePath(e,t,a,n,i);case"polygon":return this.drawPolygonPath(e,t,a,n,i,s);case"round-polygon":return this.drawRoundPolygonPath(e,t,a,n,i,s,o);case"roundrectangle":case"round-rectangle":return this.drawRoundRectanglePath(e,t,a,n,i,o);case"cutrectangle":case"cut-rectangle":return this.drawCutRectanglePath(e,t,a,n,i,s,o);case"bottomroundrectangle":case"bottom-round-rectangle":return this.drawBottomRoundRectanglePath(e,t,a,n,i,o);case"barrel":return this.drawBarrelPath(e,t,a,n,i)}};var Dm=qf,Te=qf.prototype;Te.CANVAS_LAYERS=3;Te.SELECT_BOX=0;Te.DRAG=1;Te.NODE=2;Te.WEBGL=3;Te.CANVAS_TYPES=["2d","2d","2d","webgl2"];Te.BUFFER_COUNT=3;Te.TEXTURE_BUFFER=0;Te.MOTIONBLUR_BUFFER_NODE=1;Te.MOTIONBLUR_BUFFER_DRAG=2;function qf(r){var e=this,t=e.cy.window(),a=t.document;r.webgl&&(Te.CANVAS_LAYERS=e.CANVAS_LAYERS=4,console.log("webgl rendering enabled")),e.data={canvases:new Array(Te.CANVAS_LAYERS),contexts:new Array(Te.CANVAS_LAYERS),canvasNeedsRedraw:new Array(Te.CANVAS_LAYERS),bufferCanvases:new Array(Te.BUFFER_COUNT),bufferContexts:new Array(Te.CANVAS_LAYERS)};var n="-webkit-tap-highlight-color",i="rgba(0,0,0,0)";e.data.canvasContainer=a.createElement("div");var s=e.data.canvasContainer.style;e.data.canvasContainer.style[n]=i,s.position="relative",s.zIndex="0",s.overflow="hidden";var o=r.cy.container();o.appendChild(e.data.canvasContainer),o.style[n]=i;var u={"-webkit-user-select":"none","-moz-user-select":"-moz-none","user-select":"none","-webkit-tap-highlight-color":"rgba(0,0,0,0)","outline-style":"none"};mc()&&(u["-ms-touch-action"]="none",u["touch-action"]="none");for(var l=0;l<Te.CANVAS_LAYERS;l++){var v=e.data.canvases[l]=a.createElement("canvas"),f=Te.CANVAS_TYPES[l];e.data.contexts[l]=v.getContext(f),e.data.contexts[l]||He("Could not create canvas of type "+f),Object.keys(u).forEach(function(X){v.style[X]=u[X]}),v.style.position="absolute",v.setAttribute("data-id","layer"+l),v.style.zIndex=String(Te.CANVAS_LAYERS-l),e.data.canvasContainer.appendChild(v),e.data.canvasNeedsRedraw[l]=!1}e.data.topCanvas=e.data.canvases[0],e.data.canvases[Te.NODE].setAttribute("data-id","layer"+Te.NODE+"-node"),e.data.canvases[Te.SELECT_BOX].setAttribute("data-id","layer"+Te.SELECT_BOX+"-selectbox"),e.data.canvases[Te.DRAG].setAttribute("data-id","layer"+Te.DRAG+"-drag"),e.data.canvases[Te.WEBGL]&&e.data.canvases[Te.WEBGL].setAttribute("data-id","layer"+Te.WEBGL+"-webgl");for(var l=0;l<Te.BUFFER_COUNT;l++)e.data.bufferCanvases[l]=a.createElement("canvas"),e.data.bufferContexts[l]=e.data.bufferCanvases[l].getContext("2d"),e.data.bufferCanvases[l].style.position="absolute",e.data.bufferCanvases[l].setAttribute("data-id","buffer"+l),e.data.bufferCanvases[l].style.zIndex=String(-l-1),e.data.bufferCanvases[l].style.visibility="hidden";e.pathsEnabled=!0;var c=mr(),h=function(F){return{x:(F.x1+F.x2)/2,y:(F.y1+F.y2)/2}},d=function(F){return{x:-F.w/2,y:-F.h/2}},y=function(F){var H=F[0]._private,W=H.oldBackgroundTimestamp===H.backgroundTimestamp;return!W},g=function(F){return F[0]._private.nodeKey},p=function(F){return F[0]._private.labelStyleKey},m=function(F){return F[0]._private.sourceLabelStyleKey},b=function(F){return F[0]._private.targetLabelStyleKey},w=function(F,H,W,U,te){return e.drawElement(F,H,W,!1,!1,te)},E=function(F,H,W,U,te){return e.drawElementText(F,H,W,U,"main",te)},C=function(F,H,W,U,te){return e.drawElementText(F,H,W,U,"source",te)},x=function(F,H,W,U,te){return e.drawElementText(F,H,W,U,"target",te)},S=function(F){return F.boundingBox(),F[0]._private.bodyBounds},k=function(F){return F.boundingBox(),F[0]._private.labelBounds.main||c},B=function(F){return F.boundingBox(),F[0]._private.labelBounds.source||c},D=function(F){return F.boundingBox(),F[0]._private.labelBounds.target||c},P=function(F,H){return H},A=function(F){return h(S(F))},R=function(F,H,W){var U=F?F+"-":"";return{x:H.x+W.pstyle(U+"text-margin-x").pfValue,y:H.y+W.pstyle(U+"text-margin-y").pfValue}},L=function(F,H,W){var U=F[0]._private.rscratch;return{x:U[H],y:U[W]}},I=function(F){return R("",L(F,"labelX","labelY"),F)},M=function(F){return R("source",L(F,"sourceLabelX","sourceLabelY"),F)},O=function(F){return R("target",L(F,"targetLabelX","targetLabelY"),F)},q=function(F){return d(S(F))},_=function(F){return d(B(F))},N=function(F){return d(D(F))},V=function(F){var H=k(F),W=d(k(F));if(F.isNode()){switch(jt(F.pstyle("text-halign").value)){case"left":W.x=-H.w-(H.leftPad||0);break;case"right":W.x=-(H.rightPad||0);break}switch(ea(F.pstyle("text-valign").value)){case"top":W.y=-H.h-(H.topPad||0);break;case"bottom":W.y=-(H.botPad||0);break}}return W},Y=e.data.eleTxrCache=new ba(e,{getKey:g,doesEleInvalidateKey:y,drawElement:w,getBoundingBox:S,getRotationPoint:A,getRotationOffset:q,allowEdgeTxrCaching:!1,allowParentTxrCaching:!1}),J=e.data.lblTxrCache=new ba(e,{getKey:p,drawElement:E,getBoundingBox:k,getRotationPoint:I,getRotationOffset:V,isVisible:P}),Z=e.data.slbTxrCache=new ba(e,{getKey:m,drawElement:C,getBoundingBox:B,getRotationPoint:M,getRotationOffset:_,isVisible:P}),ee=e.data.tlbTxrCache=new ba(e,{getKey:b,drawElement:x,getBoundingBox:D,getRotationPoint:O,getRotationOffset:N,isVisible:P}),re=e.data.lyrTxrCache=new Df(e);e.onUpdateEleCalcs(function(F,H){Y.invalidateElements(H),J.invalidateElements(H),Z.invalidateElements(H),ee.invalidateElements(H),re.invalidateElements(H);for(var W=0;W<H.length;W++){var U=H[W]._private;U.oldBackgroundTimestamp=U.backgroundTimestamp}});var ne=function(F){for(var H=0;H<F.length;H++)re.enqueueElementRefinement(F[H].ele)};Y.onDequeue(ne),J.onDequeue(ne),Z.onDequeue(ne),ee.onDequeue(ne),r.webgl&&e.initWebgl(r,{getStyleKey:g,getLabelKey:p,getSourceLabelKey:m,getTargetLabelKey:b,drawElement:w,drawLabel:E,drawSourceLabel:C,drawTargetLabel:x,getElementBox:S,getLabelBox:k,getSourceLabelBox:B,getTargetLabelBox:D,getElementRotationPoint:A,getElementRotationOffset:q,getLabelRotationPoint:I,getSourceLabelRotationPoint:M,getTargetLabelRotationPoint:O,getLabelRotationOffset:V,getSourceLabelRotationOffset:_,getTargetLabelRotationOffset:N})}Te.redrawHint=function(r,e){var t=this;switch(r){case"eles":t.data.canvasNeedsRedraw[Te.NODE]=e;break;case"drag":t.data.canvasNeedsRedraw[Te.DRAG]=e;break;case"select":t.data.canvasNeedsRedraw[Te.SELECT_BOX]=e;break;case"gc":t.data.gc=!0;break}};var Bm=typeof Path2D<"u";Te.path2dEnabled=function(r){if(r===void 0)return this.pathsEnabled;this.pathsEnabled=!!r};Te.usePaths=function(){return Bm&&this.pathsEnabled};Te.setImgSmoothing=function(r,e){r.imageSmoothingEnabled!=null?r.imageSmoothingEnabled=e:(r.webkitImageSmoothingEnabled=e,r.mozImageSmoothingEnabled=e,r.msImageSmoothingEnabled=e)};Te.getImgSmoothing=function(r){return r.imageSmoothingEnabled!=null?r.imageSmoothingEnabled:r.webkitImageSmoothingEnabled||r.mozImageSmoothingEnabled||r.msImageSmoothingEnabled};Te.makeOffscreenCanvas=function(r,e){var t;if((typeof OffscreenCanvas>"u"?"undefined":rr(OffscreenCanvas))!=="undefined")t=new OffscreenCanvas(r,e);else{var a=this.cy.window(),n=a.document;t=n.createElement("canvas"),t.width=r,t.height=e}return t};[Bf,Wr,Qr,mo,Lt,pt,br,Lf,yt,Wa,Vf].forEach(function(r){ye(Te,r)});var Pm=[{name:"null",impl:df},{name:"base",impl:Tf},{name:"canvas",impl:Dm}],Am=[{type:"layout",extensions:jp},{type:"renderer",extensions:Pm}],_f={},Gf={};function Hf(r,e,t){var a=t,n=function(S){ze("Can not register `"+e+"` for `"+r+"` since `"+S+"` already exists in the prototype and can not be overridden")};if(r==="core"){if(Ra.prototype[e])return n(e);Ra.prototype[e]=t}else if(r==="collection"){if(lr.prototype[e])return n(e);lr.prototype[e]=t}else if(r==="layout"){for(var i=function(S){this.options=S,t.call(this,S),Me(this._private)||(this._private={}),this._private.cy=S.cy,this._private.listeners=[],this.createEmitter()},s=i.prototype=Object.create(t.prototype),o=[],u=0;u<o.length;u++){var l=o[u];s[l]=s[l]||function(){return this}}s.start&&!s.run?s.run=function(){return this.start(),this}:!s.start&&s.run&&(s.start=function(){return this.run(),this});var v=t.prototype.stop;s.stop=function(){var x=this.options;if(x&&x.animate){var S=this.animations;if(S)for(var k=0;k<S.length;k++)S[k].stop()}return v?v.call(this):this.emit("layoutstop"),this},s.destroy||(s.destroy=function(){return this}),s.cy=function(){return this._private.cy};var f=function(S){return S._private.cy},c={addEventFields:function(S,k){k.layout=S,k.cy=f(S),k.target=S},bubble:function(){return!0},parent:function(S){return f(S)}};ye(s,{createEmitter:function(){return this._private.emitter=new Gn(c,this),this},emitter:function(){return this._private.emitter},on:function(S,k){return this.emitter().on(S,k),this},one:function(S,k){return this.emitter().one(S,k),this},once:function(S,k){return this.emitter().one(S,k),this},removeListener:function(S,k){return this.emitter().removeListener(S,k),this},removeAllListeners:function(){return this.emitter().removeAllListeners(),this},emit:function(S,k){return this.emitter().emit(S,k),this}}),Ne.eventAliasesOn(s),a=i}else if(r==="renderer"&&e!=="null"&&e!=="base"){var h=Wf("renderer","base"),d=h.prototype,y=t,g=t.prototype,p=function(){h.apply(this,arguments),y.apply(this,arguments)},m=p.prototype;for(var b in d){var w=d[b],E=g[b]!=null;if(E)return n(b);m[b]=w}for(var C in g)m[C]=g[C];d.clientFunctions.forEach(function(x){m[x]=m[x]||function(){He("Renderer does not implement `renderer."+x+"()` on its prototype")}}),a=p}else if(r==="__proto__"||r==="constructor"||r==="prototype")return He(r+" is an illegal type to be registered, possibly lead to prototype pollutions");return sv({map:_f,keys:[r,e],value:a})}function Wf(r,e){return ov({map:_f,keys:[r,e]})}function Rm(r,e,t,a,n){return sv({map:Gf,keys:[r,e,t,a],value:n})}function Mm(r,e,t,a){return ov({map:Gf,keys:[r,e,t,a]})}var Ks=function(){if(arguments.length===2)return Wf.apply(null,arguments);if(arguments.length===3)return Hf.apply(null,arguments);if(arguments.length===4)return Mm.apply(null,arguments);if(arguments.length===5)return Rm.apply(null,arguments);He("Invalid extension access syntax")};Ra.prototype.extension=Ks;Am.forEach(function(r){r.extensions.forEach(function(e){Hf(r.type,e.name,e.impl)})});var Rn=function(){if(!(this instanceof Rn))return new Rn;this.length=0},At=Rn.prototype;At.instanceString=function(){return"stylesheet"};At.selector=function(r){var e=this.length++;return this[e]={selector:r,properties:[]},this};At.css=function(r,e){var t=this.length-1;if(he(r))this[t].properties.push({name:r,value:e});else if(Me(r))for(var a=r,n=Object.keys(a),i=0;i<n.length;i++){var s=n[i],o=a[s];if(o!=null){var u=ir.properties[s]||ir.properties[Mn(s)];if(u!=null){var l=u.name,v=o;this[t].properties.push({name:l,value:v})}}}return this};At.style=At.css;At.generateStyle=function(r){var e=new ir(r);return this.appendToStyle(e)};At.appendToStyle=function(r){for(var e=0;e<this.length;e++){var t=this[e],a=t.selector,n=t.properties;r.selector(a);for(var i=0;i<n.length;i++){var s=n[i];r.css(s.name,s.value)}}return r};var Lm="3.34.0",Rt=function(e){if(e===void 0&&(e={}),Me(e))return new Ra(e);if(he(e))return Ks.apply(Ks,arguments)};Rt.use=function(r){var e=Array.prototype.slice.call(arguments,1);return e.unshift(Rt),r.apply(null,e),this};Rt.warnings=function(r){return hv(r)};Rt.version=Lm;Rt.stylesheet=Rt.Stylesheet=Rn;exports.cytoscape=Rt;
322
- //# sourceMappingURL=cytoscape.esm-D8x1ApSO.cjs.map
@@ -18753,4 +18753,3 @@ ea.stylesheet = ea.Stylesheet = Rn;
18753
18753
  export {
18754
18754
  ea as c
18755
18755
  };
18756
- //# sourceMappingURL=cytoscape.esm-kVAWcYoG.js.map
@@ -2,4 +2,3 @@
2
2
  Node.id = `,l,`
3
3
  data=`,u.height,`
4
4
  Parent cluster`,c.height),t.setNode(c.id,u),t.parent(l)||(n.log.trace("Setting parent",l,c.id),t.setParent(l,c.id,u))}if(n.log.info("(Insert) Node XXX"+l+": "+JSON.stringify(t.node(l))),e?.clusterNode){n.log.info("Cluster identified XBX",l,e.width,t.node(l));const{ranksep:u,nodesep:S}=t.graph();e.graph.setGraph({...e.graph.graph(),ranksep:u+25,nodesep:S});const L=await P(o,e.graph,f,y,t.node(l),s),N=L.elem;n.updateNodeBounds(e,N),e.diff=L.diff||0,n.log.info("New compound node after recursive render XAX",l,"width",e.width,"height",e.height),n.setNodeElem(N,e)}else t.children(l).length>0?(n.log.trace("Cluster - the non recursive path XBX",l,e.id,e,e.width,"Graph:",t),n.log.trace(m.findNonClusterChild(e.id,t)),m.clusterDb.set(e.id,{id:m.findNonClusterChild(e.id,t),node:e})):(n.log.trace("Node - the non recursive path XAX",l,o,t.node(l),d),await n.insertNode(o,t.node(l),{config:s,dir:d}))})),await n.__name(async()=>{const l=t.edges().map(async function(e){const u=t.edge(e.v,e.w,e.name);if(n.log.info("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(e)),n.log.info("Edge "+e.v+" -> "+e.w+": ",e," ",JSON.stringify(t.edge(e))),n.log.info("Fix",m.clusterDb,"ids:",e.v,e.w,"Translating: ",m.clusterDb.get(e.v),m.clusterDb.get(e.w)),p&&u.selfLoop){if(u.selfLoop.order!==1)return;const S=u.id;u.id=u.selfLoop.id,await n.insertEdgeLabel(r,u),u.id=S;return}await n.insertEdgeLabel(r,u)});await Promise.all(l)},"processEdges")(),n.log.info("Graph before layout:",JSON.stringify(m.write(t))),n.log.info("############################################# XXX"),n.log.info("### Layout ### XXX"),n.log.info("############################################# XXX"),T.layout(t),n.log.info("Graph after layout:",JSON.stringify(m.write(t)));let E=0,{subGraphTitleTotalMargin:x}=n.getSubGraphTitleMargins(s);await Promise.all(m.sortNodesByHierarchy(t).map(async function(l){const e=t.node(l);if(n.log.info("Position XBX => "+l+": ("+e.x,","+e.y,") width: ",e.width," height: ",e.height),e?.clusterNode)e.y+=x,n.log.info("A tainted cluster node XBX1",l,e.id,e.width,e.height,e.x,e.y,t.parent(l)),m.clusterDb.get(e.id).node=e,n.positionNode(e);else if(t.children(l).length>0){n.log.info("A pure cluster node XBX1",l,e.id,e.x,e.y,e.width,e.height,t.parent(l)),e.height+=x,t.node(e.parentId);const u=e?.padding/2||0,S=e?.labelBBox?.height||0,L=S-u||0;n.log.debug("OffsetY",L,"labelHeight",S,"halfPadding",u),await n.insertCluster(h,e),m.clusterDb.get(e.id).node=e}else{const u=t.node(e.parentId);e.y+=x/2,n.log.info("A regular node XBX1 - using the padding",e.id,"parent",e.parentId,e.width,e.height,e.x,e.y,"offsetY",e.offsetY,"parent",u,u?.offsetY,e),n.positionNode(e)}}));const b=x/2;return M(t,b,{mergeSelfLoops:p}).forEach(function({edge:l,start:e,end:u}){n.log.info("Edge "+e+" -> "+u+": "+JSON.stringify(l),l),l.points.forEach(R=>R.y+=b);const S=t.node(e),L=t.node(u),N=n.insertEdge(a,l,m.clusterDb,f,S,L,y);n.positionEdgeLabel(l,N)}),t.nodes().forEach(function(l){const e=t.node(l);n.log.info(l,e.type,e.diff),e.isGroup&&(E=e.diff)}),n.log.warn("Returning from recursive render XAX",g,E),{elem:g,diff:E}},"recursiveRender"),O=n.__name(async(i,t)=>{const f=new C.Graph({multigraph:!0,compound:!0}).setGraph({rankdir:i.direction,nodesep:i.config?.nodeSpacing||i.config?.flowchart?.nodeSpacing||i.nodeSpacing,ranksep:i.config?.rankSpacing||i.config?.flowchart?.rankSpacing||i.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}}),y=t.select("g");n.markers_default(y,i.markers,i.type,i.diagramId),n.clear2(),n.clear$1(),n.clear$2(),m.clear(),i.nodes.forEach(s=>{f.setNode(s.id,{...s}),s.parentId&&f.setParent(s.id,s.parentId)}),n.log.debug("Edges:",i.edges),i.edges.forEach(s=>{if(s.start===s.end){const d=s.start,g=d+"---"+d+"---1",h=d+"---"+d+"---2",a=f.node(d);f.setNode(g,{domId:g,id:g,parentId:a.parentId,labelStyle:"",label:"",padding:0,shape:"labelRect",style:"",width:10,height:10}),f.setParent(g,a.parentId),f.setNode(h,{domId:h,id:h,parentId:a.parentId,labelStyle:"",padding:0,shape:"labelRect",label:"",style:"",width:10,height:10}),f.setParent(h,a.parentId);const r=structuredClone(s),o=structuredClone(s),p=structuredClone(s),w=structuredClone(s);o.originalEdge=r,o.selfLoop={id:r.id,order:0},p.originalEdge=r,p.selfLoop={id:r.id,order:1},w.originalEdge=r,w.selfLoop={id:r.id,order:2},o.label="",o.arrowTypeEnd="none",o.endLabelLeft="",o.endLabelRight="",o.startLabelLeft="",o.id=d+"-cyclic-special-1",p.startLabelRight="",p.startLabelLeft="",p.endLabelLeft="",p.endLabelRight="",p.arrowTypeStart="none",p.arrowTypeEnd="none",p.id=d+"-cyclic-special-mid",w.label="",w.startLabelRight="",w.startLabelLeft="",w.arrowTypeStart="none",a.isGroup&&(o.fromCluster=d,w.toCluster=d),w.id=d+"-cyclic-special-2",w.arrowTypeStart="none",f.setEdge(d,g,o,d+"-cyclic-special-0"),f.setEdge(g,h,p,d+"-cyclic-special-1"),f.setEdge(h,d,w,d+"-cyclic-special-2")}else f.setEdge(s.start,s.end,{...s},s.id)}),n.log.warn("Graph at first:",JSON.stringify(m.write(f))),m.adjustClustersAndEdges(f),n.log.warn("Graph after XAX:",JSON.stringify(m.write(f)));const c=n.getConfig2();await P(y,f,i.type,i.diagramId,void 0,c)},"render");exports.getEdgesToRender=M;exports.render=O;
5
- //# sourceMappingURL=dagre-VKFMJZFB-COYURQTh.cjs.map
@@ -338,4 +338,3 @@ export {
338
338
  ne as getEdgesToRender,
339
339
  de as render
340
340
  };
341
- //# sourceMappingURL=dagre-VKFMJZFB-Ct0vbIs9.js.map
@@ -169,4 +169,3 @@ export {
169
169
  K as e,
170
170
  $ as f
171
171
  };
172
- //# sourceMappingURL=defaultLocale-BgPVtth8.js.map
@@ -1,2 +1 @@
1
1
  "use strict";function K(n){return Math.abs(n=Math.round(n))>=1e21?n.toLocaleString("en").replace(/,/g,""):n.toString(10)}function j(n,t){if(!isFinite(n)||n===0)return null;var e=(n=t?n.toExponential(t-1):n.toExponential()).indexOf("e"),i=n.slice(0,e);return[i.length>1?i[0]+i.slice(2):i,+n.slice(e+1)]}function Z(n){return n=j(Math.abs(n)),n?n[1]:NaN}function Q(n,t){return function(e,i){for(var o=e.length,a=[],c=0,m=n[0],M=0;o>0&&m>0&&(M+m+1>i&&(m=Math.max(1,i-M)),a.push(e.substring(o-=m,o+m)),!((M+=m+1)>i));)m=n[c=(c+1)%n.length];return a.reverse().join(t)}}function V(n){return function(t){return t.replace(/[0-9]/g,function(e){return n[+e]})}}var W=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function N(n){if(!(t=W.exec(n)))throw new Error("invalid format: "+n);var t;return new L({fill:t[1],align:t[2],sign:t[3],symbol:t[4],zero:t[5],width:t[6],comma:t[7],precision:t[8]&&t[8].slice(1),trim:t[9],type:t[10]})}N.prototype=L.prototype;function L(n){this.fill=n.fill===void 0?" ":n.fill+"",this.align=n.align===void 0?">":n.align+"",this.sign=n.sign===void 0?"-":n.sign+"",this.symbol=n.symbol===void 0?"":n.symbol+"",this.zero=!!n.zero,this.width=n.width===void 0?void 0:+n.width,this.comma=!!n.comma,this.precision=n.precision===void 0?void 0:+n.precision,this.trim=!!n.trim,this.type=n.type===void 0?"":n.type+""}L.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function _(n){n:for(var t=n.length,e=1,i=-1,o;e<t;++e)switch(n[e]){case".":i=o=e;break;case"0":i===0&&(i=e),o=e;break;default:if(!+n[e])break n;i>0&&(i=0);break}return i>0?n.slice(0,i)+n.slice(o+1):n}var E;function v(n,t){var e=j(n,t);if(!e)return E=void 0,n.toPrecision(t);var i=e[0],o=e[1],a=o-(E=Math.max(-8,Math.min(8,Math.floor(o/3)))*3)+1,c=i.length;return a===c?i:a>c?i+new Array(a-c+1).join("0"):a>0?i.slice(0,a)+"."+i.slice(a):"0."+new Array(1-a).join("0")+j(n,Math.max(0,t+a-1))[0]}function X(n,t){var e=j(n,t);if(!e)return n+"";var i=e[0],o=e[1];return o<0?"0."+new Array(-o).join("0")+i:i.length>o+1?i.slice(0,o+1)+"."+i.slice(o+1):i+new Array(o-i.length+2).join("0")}const O={"%":(n,t)=>(n*100).toFixed(t),b:n=>Math.round(n).toString(2),c:n=>n+"",d:K,e:(n,t)=>n.toExponential(t),f:(n,t)=>n.toFixed(t),g:(n,t)=>n.toPrecision(t),o:n=>Math.round(n).toString(8),p:(n,t)=>X(n*100,t),r:X,s:v,X:n=>Math.round(n).toString(16).toUpperCase(),x:n=>Math.round(n).toString(16)};function R(n){return n}var U=Array.prototype.map,Y=["y","z","a","f","p","n","µ","m","","k","M","G","T","P","E","Z","Y"];function nn(n){var t=n.grouping===void 0||n.thousands===void 0?R:Q(U.call(n.grouping,Number),n.thousands+""),e=n.currency===void 0?"":n.currency[0]+"",i=n.currency===void 0?"":n.currency[1]+"",o=n.decimal===void 0?".":n.decimal+"",a=n.numerals===void 0?R:V(U.call(n.numerals,String)),c=n.percent===void 0?"%":n.percent+"",m=n.minus===void 0?"−":n.minus+"",M=n.nan===void 0?"NaN":n.nan+"";function T(f,g){f=N(f);var x=f.fill,p=f.align,h=f.sign,w=f.symbol,S=f.zero,F=f.width,$=f.comma,y=f.precision,C=f.trim,d=f.type;d==="n"?($=!0,d="g"):O[d]||(y===void 0&&(y=12),C=!0,d="g"),(S||x==="0"&&p==="=")&&(S=!0,x="0",p="=");var B=(g&&g.prefix!==void 0?g.prefix:"")+(w==="$"?e:w==="#"&&/[boxX]/.test(d)?"0"+d.toLowerCase():""),H=(w==="$"?i:/[%p]/.test(d)?c:"")+(g&&g.suffix!==void 0?g.suffix:""),D=O[d],J=/[defgprs%]/.test(d);y=y===void 0?6:/[gprs]/.test(d)?Math.max(1,Math.min(21,y)):Math.max(0,Math.min(20,y));function G(r){var l=B,u=H,b,I,k;if(d==="c")u=D(r)+u,r="";else{r=+r;var P=r<0||1/r<0;if(r=isNaN(r)?M:D(Math.abs(r),y),C&&(r=_(r)),P&&+r==0&&h!=="+"&&(P=!1),l=(P?h==="("?h:m:h==="-"||h==="("?"":h)+l,u=(d==="s"&&!isNaN(r)&&E!==void 0?Y[8+E/3]:"")+u+(P&&h==="("?")":""),J){for(b=-1,I=r.length;++b<I;)if(k=r.charCodeAt(b),48>k||k>57){u=(k===46?o+r.slice(b+1):r.slice(b))+u,r=r.slice(0,b);break}}}$&&!S&&(r=t(r,1/0));var z=l.length+r.length+u.length,s=z<F?new Array(F-z+1).join(x):"";switch($&&S&&(r=t(s+r,s.length?F-u.length:1/0),s=""),p){case"<":r=l+r+u+s;break;case"=":r=l+s+r+u;break;case"^":r=s.slice(0,z=s.length>>1)+l+r+u+s.slice(z);break;default:r=s+l+r+u;break}return a(r)}return G.toString=function(){return f+""},G}function q(f,g){var x=Math.max(-8,Math.min(8,Math.floor(Z(g)/3)))*3,p=Math.pow(10,-x),h=T((f=N(f),f.type="f",f),{suffix:Y[8+x/3]});return function(w){return h(p*w)}}return{format:T,formatPrefix:q}}var A;exports.format=void 0;exports.formatPrefix=void 0;tn({thousands:",",grouping:[3],currency:["$",""]});function tn(n){return A=nn(n),exports.format=A.format,exports.formatPrefix=A.formatPrefix,A}exports.exponent=Z;exports.formatSpecifier=N;
2
- //# sourceMappingURL=defaultLocale-C4wbwF1n.cjs.map
@@ -459,4 +459,3 @@ var $e = /* @__PURE__ */ o(function(e, n, t, i) {
459
459
  export {
460
460
  Ie as diagram
461
461
  };
462
- //# sourceMappingURL=diagram-FQU43EPY-B5HmiJPw.js.map
@@ -1,4 +1,3 @@
1
1
  "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const te=require("./chunk-JWPE2WC7-CNFRDah7.cjs"),i=require("./extractHeadings-BrLI2qQF.cjs"),M=require("./cynefin-VYW2F7L2-MpAliYy9.cjs");var B="position frame",E="frame positioned",w="position relation",A="relation positioned",ne=i.__name(function(e){i.log.debug("options str",e)},"setOptions"),ie=i.__name(function(){return{}},"getOptions"),ae=i.__name(function(){T(),i.clear()},"clear");function T(){P={}}i.__name(T,"reset");var re=i.defaultConfig_default.eventmodeling,oe=i.__name(()=>i.cleanAndMerge({...re,...i.getConfig().eventmodeling}),"getConfig"),P={};function D(){let e=se;const{ast:n}=P,t=S();if(!n)throw new Error("No data for EventModel");return n.frames.forEach((a,r)=>{const o=I(a,n.dataEntities,t);e=p(e,{$kind:B,index:r,frame:a,textProps:o});let l;X(a)?(i.log.debug("source frame",a.sourceFrames),l=n.frames.filter(d=>a.sourceFrames.some(c=>c.$refText===d.name)),l.forEach(d=>{e=p(e,{$kind:w,index:r,frame:a,sourceFrame:d})})):e=p(e,{$kind:w,index:r,frame:a})}),e={...e,sortedSwimlanesArray:k(e.swimlanes)},e}i.__name(D,"getState");function R(e){P.ast=e}i.__name(R,"setAst");var s={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:"bold",boxTextPadding:10,swimlaneTextFontWeight:"bold",labelUiAutomation:"UI/Automation",labelUiAutomationPrefix:"UI/A: ",labelCommandReadModel:"Command/Read Model",labelCommandReadModelPrefix:"C/RM: ",labelEvents:"Events",labelEventsPrefix:"Stream: "};function S(){return s}i.__name(S,"getDiagramProps");var se={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function C(e){const n=e.split(".");if(n.length===2)return n[0]}i.__name(C,"extractNamespace");function $(e){const n=e.split(".");return n.length===2?n[1]:e}i.__name($,"extractName");function N(e,n){if(!(!n||n.length===0))return Object.values(e).find(t=>t.namespace===n)}i.__name(N,"findSwimlaneByNamespace");function b(e,n,t){return Math.max(n,...Object.keys(e).filter(a=>{const r=Number.parseInt(a);return r>n&&r<t}).map(a=>Number.parseInt(a)))+1}i.__name(b,"findNextAvailableIndex");function O(e,n){const t=C(e.entityIdentifier),a=N(n,t);switch(e.modelEntityType){case"ui":case"pcr":case"processor":return a?{index:a.index,label:a.namespace||s.labelUiAutomation}:t?{index:b(n,0,100),label:s.labelUiAutomationPrefix+t}:{index:0,label:s.labelUiAutomation};case"rmo":case"readmodel":case"cmd":case"command":return a?{index:a.index,label:a.namespace||s.labelCommandReadModel}:t?{index:b(n,100,200),label:s.labelCommandReadModelPrefix+t}:{index:100,label:s.labelCommandReadModel};default:return a?{index:a.index,label:a.namespace||s.labelEvents}:t?{index:b(n,200,300),label:s.labelEventsPrefix+t}:{index:200,label:s.labelEvents}}}i.__name(O,"calculateSwimlaneProps");function W(e){const{themeVariables:n}=i.getConfig();switch(e.modelEntityType){case"ui":return{fill:n.emUiFill??"white",stroke:n.emUiStroke??"#dbdada"};case"pcr":case"processor":return{fill:n.emProcessorFill??"#edb3f6",stroke:n.emProcessorStroke??"#b88cbf"};case"rmo":case"readmodel":return{fill:n.emReadModelFill??"#d3f1a2",stroke:n.emReadModelStroke??"#a3b732"};case"cmd":case"command":return{fill:n.emCommandFill??"#bcd6fe",stroke:n.emCommandStroke??"#679ac3"};case"evt":case"event":return{fill:n.emEventFill??"#ffb778",stroke:n.emEventStroke??"#c19a0f"};default:return{fill:"red",stroke:"black"}}}i.__name(W,"calculateEntityVisualProps");function I(e,n,t){const a=i.getConfig(),r=i.sanitizeText($(e.entityIdentifier)??"",a);let o;const l={fontSize:16,fontWeight:700,fontFamily:'"trebuchet ms", verdana, arial, sans-serif',joinWith:"<br/>"};let c=`<b>${i.wrapLabel(r,t.textMaxWidth,l)}</b>`;if(e.dataInlineValue&&(o=e.dataInlineValue,o=o.substring(o.indexOf("{")+1),o=o.substring(0,o.lastIndexOf("}")-1),o=i.sanitizeText(o,a),o=i.wrapLabel(o,t.textMaxWidth,l),o=o.replaceAll(" ","&nbsp;")),e.dataReference){const h=n.find(v=>v.name===e.dataReference?.$refText);h&&(o=h.dataBlockValue,o=o.substring(o.indexOf(`{
2
2
  `)+2),o=o.substring(0,o.lastIndexOf("}")-1),o=i.sanitizeText(o,a),o=i.wrapLabel(o,t.textMaxWidth,l),o=o.replaceAll(" ","&nbsp;"),o+="<br/>")}const m=o!==void 0;m&&(c+=`<br/><br/><code style="text-align: left; display: block;max-width:${t.textMaxWidth}px">${o}</code>`);const x={fontSize:l.fontSize,fontWeight:l.fontWeight,fontFamily:l.fontFamily},u=i.calculateTextDimensions(c,x),f=m?u.width/3:u.width,g={content:c,width:f,height:u.height};return i.log.debug(`[${e.name}] ${e.entityIdentifier} text`,g),g}i.__name(I,"calculateTextProps");function H(e,n){const t=n,a=W(t.frame),r={width:t.textProps.width+2*s.boxTextPadding,height:t.textProps.height+2*s.boxTextPadding};return[{$kind:E,frame:t.frame,index:t.index,visual:a,dimension:r,textProps:t.textProps}]}i.__name(H,"decidePositionFrame");function U(e,n,t){return n===void 0?s.contentStartX:n.index===e.index&&e.r?e.r+s.boxPadding:t===void 0?s.contentStartX:t.r-s.boxOverlap+s.boxPadding}i.__name(U,"calculateX");function L(e,n){const t=[...e.map(a=>a.r),n];return Math.max(...t)}i.__name(L,"calculateMaxRight");function k(e){return Object.values(e).sort((n,t)=>n.index-t.index)}i.__name(k,"sortedSwimlanesArray");function V(e,n){const t=n,a=O(t.frame,e.swimlanes);let r;a.index in e.swimlanes?r=e.swimlanes[a.index]:r={index:a.index,label:a.label,r:0,y:a.index*s.swimlaneMinHeight+s.swimlaneGap,height:s.swimlaneMinHeight,maxHeight:s.swimlaneMinHeight};const o=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,l=e.previousSwimlaneNumber!==void 0?e.swimlanes[e.previousSwimlaneNumber]:void 0,d={width:Math.max(s.boxMinWidth,Math.min(s.boxMaxWidth,t.dimension.width))+2*s.boxPadding,height:Math.max(s.boxMinHeight,Math.min(s.boxMaxHeight,t.dimension.height))+2*s.boxPadding},c=U(r,l,o),m=c+d.width+s.boxPadding,x=L(Object.values(e.swimlanes),m);r.r=c+d.width,r.maxHeight=Math.max(r.maxHeight,d.height),r.height=Math.max(s.swimlaneMinHeight,r.maxHeight)+2*s.swimlanePadding;const u={x:c,y:s.swimlanePadding+r.y,r:m,dimension:d,leftSibling:!1,swimlane:r,visual:t.visual,text:t.textProps.content,frame:t.frame,index:t.index},f={...e,boxes:[...e.boxes,u],swimlanes:{...e.swimlanes,[`${r.index}`]:r},previousSwimlaneNumber:a.index,previousFrame:t.frame,maxR:x},g=k(f.swimlanes);g.length>0&&(g[0].y=0);for(let h=1;h<g.length;h++){const v=g[h],F=g[h-1];v.y=F.y+F.height+s.swimlaneGap}return f}i.__name(V,"evolveFramePositioned");function G(e,n){return e===0&&n.sourceFrames.length===0}i.__name(G,"isFirstFrame");function X(e){return e.sourceFrames!==void 0&&e.sourceFrames!==null&&e.sourceFrames.length>0}i.__name(X,"hasSourceFrame");function _(e,n){if(n!=null)return e.find(t=>t.frame.name===n.name)}i.__name(_,"findBoxByFrame");function j(e,n,t){if(!(t<0))for(let a=t;a>=0;a--){const r=e[a];if(r.swimlane.index!==n)return r}}i.__name(j,"findBoxByLineIndex");function Y(e,n){const t=n;if(M.isEmResetFrame(t.frame)||G(t.index,t.frame))return[];const a=_(e.boxes,t.frame);if(a===void 0)throw new Error(`Target box not found for frame ${t.frame.name}`);let r;return t.sourceFrame?r=_(e.boxes,t.sourceFrame):r=j(e.boxes,a.swimlane.index,t.index-1),r===void 0?[]:[{$kind:A,frame:t.frame,index:t.index,sourceBox:r,targetBox:a}]}i.__name(Y,"decidePositionRelation");function z(e,n){const t=n,a={visual:{fill:"none",stroke:"#000"},source:{x:t.sourceBox.x,y:t.sourceBox.y},target:{x:t.targetBox.x,y:t.targetBox.y},sourceBox:t.sourceBox,targetBox:t.targetBox};return{...e,relations:[...e.relations,a]}}i.__name(z,"evolveRelationPositioned");var le={[B]:H,[w]:Y},de={[E]:V,[A]:z};function K(e,n){const t=le[n.$kind];if(t==null)return[];const a=t(e,n);return i.log.debug("decided events",a),a}i.__name(K,"decide");function q(e,n){const t=n.reduce((a,r)=>{const o=de[r.$kind];return o==null?a:o(a,r)},e);return i.log.debug("evolve events",{state:e,newState:t,events:n}),t}i.__name(q,"evolve");function p(e,n){const t=K(e,n);return q(e,t)}i.__name(p,"dispatch");var y={getConfig:oe,setOptions:ne,getOptions:ie,clear:ae,setAccTitle:i.setAccTitle,getAccTitle:i.getAccTitle,getAccDescription:i.getAccDescription,setAccDescription:i.setAccDescription,setDiagramTitle:i.setDiagramTitle,getDiagramTitle:i.getDiagramTitle,setAst:R,getDiagramProps:S,getState:D},ce={parse:i.__name(async e=>{const n=await M.parse("eventmodeling",e);i.log.debug(n),y.setAst(n),te.populateCommonDb(n,y)},"parse")},me=i.getConfig2(),ue=me?.eventmodeling;function J(e,n){return t=>{const a=t.swimlane.y+n.swimlanePadding,r=e.append("g").attr("class","em-box");r.append("rect").attr("x",t.x).attr("y",a).attr("rx","3").attr("width",t.dimension.width).attr("height",t.dimension.height).attr("stroke",t.visual.stroke).attr("fill",t.visual.fill),r.append("foreignObject").attr("x",t.x+n.boxPadding).attr("y",a+10).attr("width",t.dimension.width-2*n.boxPadding).attr("height",t.dimension.height-2*n.boxPadding).append("xhtml:div").style("display","table").style("height","100%").style("width","100%").append("span").style("display","table-cell").style("text-align","center").style("vertical-align","middle").html(t.text)}}i.__name(J,"renderD3Box");function Q(e,n){return e>n}i.__name(Q,"dirUpwards");function Z(e,n,t,a){return r=>{const o=r.sourceBox.swimlane.y+n.swimlanePadding,l=r.targetBox.swimlane.y+n.swimlanePadding,d=Q(o,l),c=r.sourceBox.x+r.sourceBox.dimension.width*2/3,m=r.targetBox.x+r.targetBox.dimension.width/3;let x,u;i.log.debug(`rendering relation up=${d} for `,{sourceBox:r.sourceBox,targetBox:r.targetBox}),d?(x=o,u=l+r.targetBox.dimension.height):(x=o+r.sourceBox.dimension.height,u=l);const f=a.emRelationStroke??r.visual.stroke;e.append("path").attr("class","em-relation").attr("fill",r.visual.fill).attr("stroke",f).attr("stroke-width","1").attr("marker-end",`url(#${t})`).attr("d",`M${c} ${x} L${m} ${u}`)}}i.__name(Z,"renderD3Relation");function ee(e,n,t,a){return r=>{const o=e.append("g").attr("class","em-swimlane"),l=a.emSwimlaneBackgroundOdd??"rgb(250,250,250)",d=a.emSwimlaneBackgroundStroke??"rgb(240,240,240)";o.append("rect").attr("x",0).attr("y",r.y).attr("rx","3").attr("width",n+t.swimlanePadding).attr("height",r.height).attr("fill",l).attr("stroke",d),o.append("text").attr("font-weight",t.swimlaneTextFontWeight).attr("x",30).attr("y",r.y+30).text(r.label)}}i.__name(ee,"renderD3Swimlane");var xe=i.__name(function(e,n,t,a){if(i.log.debug("in eventmodeling renderer",e+`
3
3
  `,"id:",n,t),!ue)throw new Error("EventModeling config not found");const r=a.db,{themeVariables:o,eventmodeling:l}=i.getConfig2(),d=i.select(`[id="${n}"]`),c=r.getDiagramProps(),m=r.getState(),x=`em-arrowhead-${n}`,u=o.emArrowhead??"#000000";m.sortedSwimlanesArray.forEach(ee(d,m.maxR,c,o)),m.boxes.forEach(J(d,c)),m.relations.forEach(Z(d,c,x,o)),d.append("defs").append("marker").attr("id",x).attr("markerWidth","10").attr("markerHeight","7").attr("refX","10").attr("refY","3.5").attr("orient","auto").append("polygon").attr("points","0 0, 10 3.5, 0 7").attr("fill",u),i.setupGraphViewbox2(void 0,d,l?.padding??30,l?.useMaxWidth)},"draw"),ge={draw:xe},fe=i.__name(e=>"","getStyles"),he=fe,be={parser:ce,db:y,renderer:ge,styles:he};exports.diagram=be;
4
- //# sourceMappingURL=diagram-FQU43EPY-DkgdwwAT.cjs.map
@@ -526,4 +526,3 @@ var rt = /* @__PURE__ */ w((t, a) => {
526
526
  export {
527
527
  bt as diagram
528
528
  };
529
- //# sourceMappingURL=diagram-G47NLZAW-C-nfBNGF.js.map
@@ -22,4 +22,3 @@
22
22
  font-size: ${r.titleFontSize};
23
23
  }
24
24
  `},"getStyles"),Ue=Je,Ze={parser:re,get db(){return new ne},renderer:Ye,styles:Ue};exports.diagram=Ze;
25
- //# sourceMappingURL=diagram-G47NLZAW-CcXcBx81.cjs.map
@@ -22,4 +22,3 @@
22
22
  fill: ${t.blockFillColor};
23
23
  }
24
24
  `},"styles"),z={parser:w,get db(){return new m},renderer:D,styles:F};exports.diagram=z;
25
- //# sourceMappingURL=diagram-NH7WQ7WH-BMYzS0pm.cjs.map
@@ -140,4 +140,3 @@ var L = W.packet, u, v = (u = class {
140
140
  export {
141
141
  R as diagram
142
142
  };
143
- //# sourceMappingURL=diagram-NH7WQ7WH-yu8B8Q4y.js.map
@@ -348,4 +348,3 @@ var y = 14, ge = 4, ue = 16, W = /* @__PURE__ */ f((n, e) => `tv-icon-${n}-${e.r
348
348
  export {
349
349
  Ae as diagram
350
350
  };
351
- //# sourceMappingURL=diagram-OA4YK3LP-CROsfore.js.map
@@ -28,4 +28,3 @@
28
28
  stroke-width: 1;
29
29
  }
30
30
  `},"styles"),ce=ae,le={db:b,renderer:oe,parser:U,styles:ce};exports.diagram=le;
31
- //# sourceMappingURL=diagram-OA4YK3LP-DSeI6RLe.cjs.map
@@ -39,4 +39,3 @@
39
39
  }
40
40
  ${Y(e,t)}
41
41
  `},"styles"),U={parser:G,db:_,renderer:q,styles:N};exports.diagram=U;
42
- //# sourceMappingURL=diagram-WEI45ONY-CCJwQ42c.cjs.map
@@ -215,4 +215,3 @@ var nt = { draw: et }, ot = /* @__PURE__ */ c((a, t) => {
215
215
  export {
216
216
  pt as diagram
217
217
  };
218
- //# sourceMappingURL=diagram-WEI45ONY-DmPpMglv.js.map
@@ -107,4 +107,3 @@ var c = f().RailroadEbnf.parser.LangiumParser, s = /* @__PURE__ */ t((e) => {
107
107
  export {
108
108
  N as diagram
109
109
  };
110
- //# sourceMappingURL=ebnfDiagram-CCIWWBDH-B2ck9j39.js.map
@@ -1,2 +1 @@
1
1
  "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const n=require("./chunk-MOJQB5TN-Bs5Jj3Zh.cjs"),l=require("./chunk-JWPE2WC7-CNFRDah7.cjs"),t=require("./extractHeadings-BrLI2qQF.cjs"),o=require("./cynefin-VYW2F7L2-MpAliYy9.cjs");var m=o.createRailroadEbnfServices().RailroadEbnf.parser.LangiumParser,s=t.__name(e=>{const r=e.alternatives.map(u);return r.length===1?r[0]:{type:"choice",alternatives:r}},"transformChoice"),u=t.__name(e=>{const r=e.elements.map(c);return r.length===1?r[0]:{type:"sequence",elements:r}},"transformSequence"),i=t.__name(e=>{switch(e.$type){case"EbnfTerminal":return{type:"terminal",value:e.value};case"EbnfNonTerminal":return{type:"nonterminal",name:e.name};case"EbnfSpecial":return{type:"special",text:e.text};case"EbnfGroup":return s(e.element);case"EbnfOptional":return{type:"optional",element:s(e.element)};case"EbnfRepetition":return{type:"repetition",element:s(e.element),min:0,max:1/0};default:throw new Error(`Unsupported EBNF primary node: ${e.$type}`)}},"transformPrimary"),p=t.__name((e,r)=>{switch(r.$type){case"EbnfOptionalPostfix":return{type:"optional",element:e};case"EbnfZeroOrMorePostfix":return{type:"repetition",element:e,min:0,max:1/0};case"EbnfOneOrMorePostfix":return{type:"repetition",element:e,min:1,max:1/0};case"EbnfExceptionPostfix":return{type:"sequence",elements:[e,{type:"terminal",value:"-"},i(r.except)]};default:throw new Error(`Unsupported EBNF postfix node: ${r.$type}`)}},"transformPostfix"),c=t.__name(e=>e.postfixes.reduce((r,a)=>p(r,a),i(e.base)),"transformTerm"),f=t.__name(e=>({name:e.name,definition:s(e.definition)}),"transformRule"),d=t.__name(e=>{l.populateCommonDb(e,n.db),e.title&&n.db.setTitle(e.title),e.rules.map(r=>n.db.addRule(f(r)))},"populateDb"),b={parse:t.__name(e=>{n.db.clear(),t.log.debug("[EBNF Parser] Starting Langium parse");const r=m.parse(e);if(r.lexerErrors.length>0||r.parserErrors.length>0)throw new o.MermaidParseError(r);const a=r.value;t.log.debug("[EBNF Parser] Parsed rules:",a.rules.length),d(a),t.log.debug("[EBNF Parser] Parse complete")},"parse"),parser:{yy:n.db}},E={parser:b,db:n.db,renderer:n.renderer,styles:n.getStyles};exports.diagram=E;
2
- //# sourceMappingURL=ebnfDiagram-CCIWWBDH-D_nz1FvR.cjs.map
@@ -83,4 +83,3 @@ Expecting `+se.join(", ")+", got '"+(this.terminals_[y]||y)+"'":fe="Parse error
83
83
  background-color: ${Re(s.tertiaryColor,.5)};
84
84
  }
85
85
  `},"getStyles"),Ke=Ge,Ue={parser:Fe,get db(){return new Ye},renderer:Ie,styles:Ke};exports.diagram=Ue;
86
- //# sourceMappingURL=erDiagram-Q63AITRT-2r-lfgSt.cjs.map
@@ -908,4 +908,3 @@ var se = /* @__PURE__ */ d(async function(s, i, c, h) {
908
908
  export {
909
909
  he as diagram
910
910
  };
911
- //# sourceMappingURL=erDiagram-Q63AITRT-BfpyxqAV.js.map