docmedown 0.1.7 → 0.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (304) hide show
  1. package/LICENSE +201 -21
  2. package/README.md +86 -37
  3. package/dist/architecture-7GRP2DOG-B8Xs9IfY.mjs +2 -0
  4. package/dist/architecture-7GRP2DOG-Vdsw7WC7.js +1 -0
  5. package/dist/cli.js +672 -1294
  6. package/dist/cynefin-OW5HDTMX-DU6kwwck.js +1 -0
  7. package/dist/cynefin-OW5HDTMX-F0P2M_lQ.mjs +2 -0
  8. package/dist/docmedown-compiler.js +228 -0
  9. package/dist/docmedown-mermaid.js +3588 -0
  10. package/dist/docmedown.cjs +7264 -80
  11. package/dist/docmedown.iife.js +7624 -424
  12. package/dist/docmedown.mjs +15531 -15009
  13. package/dist/docmedown.web.js +7628 -0
  14. package/dist/eventmodeling-NTZA5JFV-D58ICByZ.js +1 -0
  15. package/dist/eventmodeling-NTZA5JFV-SxxTo5cJ.mjs +2 -0
  16. package/dist/gitGraph-4MIJSDKK-C_R2a4aQ.mjs +2 -0
  17. package/dist/gitGraph-4MIJSDKK-CdMj8HJ8.js +1 -0
  18. package/dist/info-A6RAGUB7-CG4UBCfn.js +1 -0
  19. package/dist/info-A6RAGUB7-DmjQlHTj.mjs +2 -0
  20. package/dist/mermaid-BvOI3ZSW.js +3334 -0
  21. package/dist/mermaid-Cx9uSfoz.mjs +116948 -0
  22. package/dist/packet-AYTQ26CC-CMuoEJn0.js +1 -0
  23. package/dist/packet-AYTQ26CC-tdMo_iPL.mjs +2 -0
  24. package/dist/pie-WAS4IAKB-C1hjX8y0.js +1 -0
  25. package/dist/pie-WAS4IAKB-DG2Bio1G.mjs +2 -0
  26. package/dist/prism-CeBRmKvl.js +2 -0
  27. package/dist/prism-CummdiZX.mjs +1588 -0
  28. package/dist/radar-RG4KPBEZ-DHxYOB0f.mjs +2 -0
  29. package/dist/radar-RG4KPBEZ-Dvyo3gdA.js +1 -0
  30. package/dist/railroad-74A4TZTK-1sb9Z_QQ.js +1 -0
  31. package/dist/railroad-74A4TZTK-CwztrSkE.mjs +2 -0
  32. package/dist/railroad-abnf-HS5TGJTU-4264fZjH.js +1 -0
  33. package/dist/railroad-abnf-HS5TGJTU-BKCsR9iC.mjs +2 -0
  34. package/dist/railroad-ebnf-LZEXJU2U-BXErl5kO.js +1 -0
  35. package/dist/railroad-ebnf-LZEXJU2U-DzDOfuxK.mjs +2 -0
  36. package/dist/railroad-peg-WCYAUIDC-B6gNHamV.mjs +2 -0
  37. package/dist/railroad-peg-WCYAUIDC-D7pSwRGa.js +1 -0
  38. package/dist/rolldown-runtime-B0aSnxlc.mjs +20 -0
  39. package/dist/rolldown-runtime-DF3sbh8G.js +1 -0
  40. package/dist/svelte-compiler-loader-Deqbdbvf.js +1 -0
  41. package/dist/svelte-compiler-loader-DtYQgEKV.mjs +50 -0
  42. package/dist/svelte-runtime-Brc440dp.js +5 -0
  43. package/dist/svelte-runtime-CgCk_bw1.mjs +40 -0
  44. package/dist/treeView-Q6P3EWNA-DArM8kFH.mjs +2 -0
  45. package/dist/treeView-Q6P3EWNA-JstiGzov.js +1 -0
  46. package/dist/treemap-WGGIJYW6-CMIcmEVN.mjs +2 -0
  47. package/dist/treemap-WGGIJYW6-Dq6fFckz.js +1 -0
  48. package/dist/ts-compiler-BMDmcNn5.mjs +93 -0
  49. package/dist/ts-compiler-U7pTMJjY.js +3 -0
  50. package/dist/types/runtime/bridges/dynamic-component.d.ts +43 -0
  51. package/dist/types/runtime/bridges/element-bridge.d.ts +24 -0
  52. package/dist/types/runtime/bridges/index.d.ts +3 -0
  53. package/dist/types/runtime/bridges/react-bridge.d.ts +35 -0
  54. package/dist/types/runtime/compiler-cache.d.ts +18 -0
  55. package/dist/types/runtime/config-schema.d.ts +2 -0
  56. package/dist/types/runtime/favicons.d.ts +28 -0
  57. package/dist/types/runtime/loader/local-loader.d.ts +13 -0
  58. package/dist/types/runtime/markdown/component-body.d.ts +7 -0
  59. package/dist/types/runtime/markdown/escape.d.ts +1 -0
  60. package/dist/types/runtime/markdown/highlighter.d.ts +32 -6
  61. package/dist/types/runtime/markdown/katex.d.ts +5 -0
  62. package/dist/types/runtime/markdown/mermaid-engine.d.ts +1 -0
  63. package/dist/types/runtime/markdown/mermaid-loader.d.ts +19 -0
  64. package/dist/types/runtime/markdown/mermaid.d.ts +6 -0
  65. package/dist/types/runtime/markdown/tables.d.ts +68 -0
  66. package/dist/types/runtime/media.d.ts +30 -0
  67. package/dist/types/runtime/motion.d.ts +134 -0
  68. package/dist/types/runtime/offline-export.d.ts +9 -2
  69. package/dist/types/runtime/router.d.ts +40 -2
  70. package/dist/types/runtime/splash.d.ts +90 -0
  71. package/dist/types/runtime/svelte-compiler-engine.d.ts +1 -0
  72. package/dist/types/runtime/svelte-compiler-loader.d.ts +14 -0
  73. package/dist/types/runtime/svelte-runtime.d.ts +29 -0
  74. package/dist/types/runtime/svelte-tag.d.ts +7 -0
  75. package/dist/types/runtime/ts-compiler.d.ts +24 -0
  76. package/dist/types/runtime/types.d.ts +1 -0
  77. package/dist/types/ui/doc-context.svelte.d.ts +198 -0
  78. package/dist/types/ui/index.d.ts +33 -0
  79. package/dist/types/ui/registry.d.ts +52 -0
  80. package/dist/types/ui/theme.svelte.d.ts +32 -0
  81. package/dist/wardley-WFR3VGLG-BK9BA6h6.mjs +2 -0
  82. package/dist/wardley-WFR3VGLG-Cbs7W-dU.js +1 -0
  83. package/package.json +61 -48
  84. package/schemas/docs.schema.json +186 -181
  85. package/templates/.dmd/CounterWidget.svelte +29 -0
  86. package/templates/README.md +2 -2
  87. package/templates/favicon.svg +12 -0
  88. package/templates/favicons/favicon-book.svg +11 -0
  89. package/templates/favicons/favicon-markdown.svg +11 -0
  90. package/templates/favicons/favicon-minimal.svg +15 -0
  91. package/templates/favicons/favicon-terminal.svg +14 -0
  92. package/templates/favicons/favicon.svg +12 -0
  93. package/templates/guides/custom-components.md +82 -22
  94. package/templates/index.html +6 -3
  95. package/dist/abnfDiagram-VCTEODGH-CtQBp0Qv.mjs +0 -89
  96. package/dist/abnfDiagram-VCTEODGH-mccrzlD_.js +0 -1
  97. package/dist/arc-DgPKXEdT.mjs +0 -82
  98. package/dist/arc-n7TW7Bis.js +0 -1
  99. package/dist/architecture-7GRP2DOG-B7myQ46f.js +0 -1
  100. package/dist/architecture-7GRP2DOG-Cxj1ussQ.mjs +0 -3
  101. package/dist/architectureDiagram-5GKGNRK7-BdTCu5T3.js +0 -36
  102. package/dist/architectureDiagram-5GKGNRK7-CkgZa-G1.mjs +0 -4154
  103. package/dist/array-CApNbSU9.mjs +0 -6
  104. package/dist/array-DZSRzHA_.js +0 -1
  105. package/dist/blockDiagram-I7D4REHJ-CSYvpxQw.js +0 -129
  106. package/dist/blockDiagram-I7D4REHJ-CYngfPD9.mjs +0 -1922
  107. package/dist/c4Diagram-7LVT6UL2-B-sz5MUK.js +0 -38
  108. package/dist/c4Diagram-7LVT6UL2-DEzxFf2b.mjs +0 -3010
  109. package/dist/channel-LgHproiI.mjs +0 -5
  110. package/dist/channel-yqu0m4cl.js +0 -1
  111. package/dist/chunk-2E4U76K2-BOyeRQsI.js +0 -1
  112. package/dist/chunk-2E4U76K2-CoTrgtfg.mjs +0 -348
  113. package/dist/chunk-2Q5K7J3B-D4EgYPOq.mjs +0 -15
  114. package/dist/chunk-2Q5K7J3B-DhjCNjaM.js +0 -1
  115. package/dist/chunk-4HAMMTFA-GFyfmcSO.js +0 -62
  116. package/dist/chunk-4HAMMTFA-VgWPe1ng.mjs +0 -4188
  117. package/dist/chunk-5VM5RSS4-GINalzIv.js +0 -15
  118. package/dist/chunk-5VM5RSS4-TqxtqrwE.mjs +0 -5
  119. package/dist/chunk-75Z2AOVW-DYouz5MZ.js +0 -2
  120. package/dist/chunk-75Z2AOVW-Dz0Sko9Y.mjs +0 -1330
  121. package/dist/chunk-CLGD4ZFX-C5J-e2io.js +0 -1
  122. package/dist/chunk-CLGD4ZFX-DBkwyMMv.mjs +0 -14
  123. package/dist/chunk-DU6HZSFF-BEQZSmUu.mjs +0 -3836
  124. package/dist/chunk-DU6HZSFF-CWc5ewtb.js +0 -127
  125. package/dist/chunk-F27PBJKO-8jvY_jJK.js +0 -1
  126. package/dist/chunk-F27PBJKO-DFH3sRZG.mjs +0 -61
  127. package/dist/chunk-FOHPRMQF-LRqOLsSw.mjs +0 -21456
  128. package/dist/chunk-FOHPRMQF-tmTlwTeH.js +0 -161
  129. package/dist/chunk-GMAD6QVW-BZeZ4fdb.mjs +0 -1863
  130. package/dist/chunk-GMAD6QVW-DEQiTa0c.js +0 -72
  131. package/dist/chunk-GVQU2GXP-B1D3J05J.mjs +0 -37
  132. package/dist/chunk-GVQU2GXP-CdJIWN41.js +0 -1
  133. package/dist/chunk-IMKFNOWR-BmZb9U1f.mjs +0 -2042
  134. package/dist/chunk-IMKFNOWR-CPJsszGN.js +0 -231
  135. package/dist/chunk-JWPE2WC7-DIKiF5cm.mjs +0 -8
  136. package/dist/chunk-JWPE2WC7-p1fYVdYc.js +0 -1
  137. package/dist/chunk-L3NEJ4N5-TzDiVs78.js +0 -1
  138. package/dist/chunk-L3NEJ4N5-lal8wUID.mjs +0 -245
  139. package/dist/chunk-LNGE3PJU-BQX75wkM.js +0 -34
  140. package/dist/chunk-LNGE3PJU-DJ9JuXV6.mjs +0 -1521
  141. package/dist/chunk-OSK3NFVY-9AWK88m1.mjs +0 -672
  142. package/dist/chunk-OSK3NFVY-CHzvVe8m.js +0 -10
  143. package/dist/chunk-P2QGCYS3-6q3AXPt5.mjs +0 -67
  144. package/dist/chunk-P2QGCYS3-DKZzpRQW.js +0 -1
  145. package/dist/chunk-POPQ4Y6H-Dd7J9tx3.mjs +0 -26
  146. package/dist/chunk-POPQ4Y6H-T5C7wpjf.js +0 -1
  147. package/dist/chunk-PWAF6VOD-BYG76tEe.mjs +0 -275
  148. package/dist/chunk-PWAF6VOD-DxZLuCEw.js +0 -1
  149. package/dist/chunk-SHT3W25Y-B2Wes8jn.mjs +0 -4183
  150. package/dist/chunk-SHT3W25Y-BQjHSn5K.js +0 -168
  151. package/dist/chunk-SVP7TREG-BFMd615E.js +0 -88
  152. package/dist/chunk-SVP7TREG-CynckzeF.mjs +0 -490
  153. package/dist/chunk-TICWLB2K-BfCuoR1V.mjs +0 -3357
  154. package/dist/chunk-TICWLB2K-agcyBfUp.js +0 -206
  155. package/dist/chunk-TLUHSLCS-CUrWaKDG.mjs +0 -59
  156. package/dist/chunk-TLUHSLCS-Drx_a7am.js +0 -1
  157. package/dist/chunk-XXDRQBXY-AAk1-Cyg.js +0 -1
  158. package/dist/chunk-XXDRQBXY-DpR8eYzz.mjs +0 -9
  159. package/dist/chunk-Y2CYZVJY-CnmLqFtv.js +0 -1
  160. package/dist/chunk-Y2CYZVJY-i11wjrBe.mjs +0 -12
  161. package/dist/classDiagram-ZZMXUADV-B7IN9zcX.js +0 -1
  162. package/dist/classDiagram-ZZMXUADV-tcy6gxSB.mjs +0 -30
  163. package/dist/classDiagram-v2-VYDZK3BY-B7IN9zcX.js +0 -1
  164. package/dist/classDiagram-v2-VYDZK3BY-D5wM6Acp.mjs +0 -30
  165. package/dist/cose-bilkent-JH36ORCC-DBUPO3qJ.js +0 -1
  166. package/dist/cose-bilkent-JH36ORCC-Slpx4WIt.mjs +0 -2253
  167. package/dist/cynefin-OW5HDTMX--QVnfGi1.mjs +0 -3
  168. package/dist/cynefin-OW5HDTMX-lNKysi7S.js +0 -1
  169. package/dist/cynefinDiagram-5FMLGOSQ-CsFONYqx.js +0 -62
  170. package/dist/cynefinDiagram-5FMLGOSQ-DsrxYBcg.mjs +0 -355
  171. package/dist/cytoscape.esm-C5TvPYYm.mjs +0 -18148
  172. package/dist/cytoscape.esm-CBmWJr5M.js +0 -321
  173. package/dist/dagre-CZ6P9L_h.js +0 -1
  174. package/dist/dagre-GXQ25YYZ-CQszk-7P.js +0 -4
  175. package/dist/dagre-GXQ25YYZ-ecYByRSn.mjs +0 -425
  176. package/dist/dagre-J_1oH0eY.mjs +0 -1934
  177. package/dist/defaultLocale-N-0uLSyg.mjs +0 -198
  178. package/dist/defaultLocale-ybN1Vtvg.js +0 -1
  179. package/dist/diagram-S7CK7UJ4-CTMvxX__.js +0 -30
  180. package/dist/diagram-S7CK7UJ4-DxCghfa-.mjs +0 -301
  181. package/dist/diagram-UQ7AKVKN-1viEkqlG.js +0 -41
  182. package/dist/diagram-UQ7AKVKN-BA7Z_oB7.mjs +0 -214
  183. package/dist/diagram-VSXAHHWV-DgVT19mq.js +0 -3
  184. package/dist/diagram-VSXAHHWV-Dtqo03M5.mjs +0 -432
  185. package/dist/diagram-VX7I27RA-CNw0pOX_.js +0 -24
  186. package/dist/diagram-VX7I27RA-GMPRt8Zh.mjs +0 -527
  187. package/dist/diagram-Z3DM3KII-C6XdQK_Q.mjs +0 -134
  188. package/dist/diagram-Z3DM3KII-CPkBr3FT.js +0 -24
  189. package/dist/dist-CXWJafG_.js +0 -1
  190. package/dist/dist-DNdLIC8h.mjs +0 -59
  191. package/dist/ebnfDiagram-PWID7BFC-CseVsyL3.js +0 -1
  192. package/dist/ebnfDiagram-PWID7BFC-D_dBDXWC.mjs +0 -100
  193. package/dist/erDiagram-RLTQ6QDP-DFwfQTRS.js +0 -99
  194. package/dist/erDiagram-RLTQ6QDP-DP7ddGMH.mjs +0 -1966
  195. package/dist/eventmodeling-NTZA5JFV-CzxVg0l5.js +0 -1
  196. package/dist/eventmodeling-NTZA5JFV-Djsy__5n.mjs +0 -3
  197. package/dist/flowDiagram-HODETNUW-7hSJfI3W.js +0 -1
  198. package/dist/flowDiagram-HODETNUW-Dqu5Lr19.mjs +0 -17
  199. package/dist/ganttDiagram-EL5Y4UJY-KNL3tzTD.mjs +0 -3072
  200. package/dist/ganttDiagram-EL5Y4UJY-aiLqNWgi.js +0 -292
  201. package/dist/gitGraph-4MIJSDKK-DnElfqX7.js +0 -1
  202. package/dist/gitGraph-4MIJSDKK-xuKJBT2e.mjs +0 -3
  203. package/dist/gitGraphDiagram-WWUBYQGX-D4gSo_-e.js +0 -106
  204. package/dist/gitGraphDiagram-WWUBYQGX-Dooss5fG.mjs +0 -733
  205. package/dist/graphlib-BaETKKSa.js +0 -1
  206. package/dist/graphlib-XW-Jr8pF.mjs +0 -1267
  207. package/dist/info-A6RAGUB7-ClYskpn6.mjs +0 -3
  208. package/dist/info-A6RAGUB7-DDvvt-fW.js +0 -1
  209. package/dist/infoDiagram-27XIBGKW-B2-y2mdQ.mjs +0 -20
  210. package/dist/infoDiagram-27XIBGKW-DYQ9NzfL.js +0 -2
  211. package/dist/init-BJdqMO10.js +0 -1
  212. package/dist/init-CsQUQz36.mjs +0 -13
  213. package/dist/ishikawaDiagram-5VMMS53U-ULIhoYO5.js +0 -70
  214. package/dist/ishikawaDiagram-5VMMS53U-xAArNh-1.mjs +0 -719
  215. package/dist/journeyDiagram-3NMN7TZE-BBMYNZRL.js +0 -139
  216. package/dist/journeyDiagram-3NMN7TZE-BH-uKqP7.mjs +0 -884
  217. package/dist/kanban-definition-UXKFOSKX-Be49llXr.mjs +0 -976
  218. package/dist/kanban-definition-UXKFOSKX-CDL5yJkq.js +0 -89
  219. package/dist/line-BEwhHSLl.js +0 -1
  220. package/dist/line-CiXRog8O.mjs +0 -34
  221. package/dist/linear-75tfjrny.js +0 -1
  222. package/dist/linear-Ncx_RuON.mjs +0 -288
  223. package/dist/mermaid-parser.core-BBApyu_y.js +0 -6
  224. package/dist/mermaid-parser.core-BRHibdUE.mjs +0 -638
  225. package/dist/mindmap-definition-YA3MSWOX-Chy7XP_5.mjs +0 -1006
  226. package/dist/mindmap-definition-YA3MSWOX-DOda-fkL.js +0 -96
  227. package/dist/ordinal-B1BNQwUR.mjs +0 -65
  228. package/dist/ordinal-B9aFWmF9.js +0 -1
  229. package/dist/packet-AYTQ26CC-CorIy9Ul.js +0 -1
  230. package/dist/packet-AYTQ26CC-DWH8gXJK.mjs +0 -3
  231. package/dist/path-CnWkkRiY.mjs +0 -84
  232. package/dist/path-DIS6ck99.js +0 -1
  233. package/dist/pegDiagram-XKGWAZYB-Cdw6MeON.js +0 -1
  234. package/dist/pegDiagram-XKGWAZYB-uNfxRaq1.mjs +0 -94
  235. package/dist/pie-WAS4IAKB-Cn5eK-5P.mjs +0 -3
  236. package/dist/pie-WAS4IAKB-D84xrSoY.js +0 -1
  237. package/dist/pieDiagram-E7YTZNPT-Bd6mvpJw.js +0 -39
  238. package/dist/pieDiagram-E7YTZNPT-Cczo96a2.mjs +0 -203
  239. package/dist/quadrantDiagram-AXDQQJYC-BPfgvMsS.js +0 -7
  240. package/dist/quadrantDiagram-AXDQQJYC-eqRNtVRl.mjs +0 -2001
  241. package/dist/radar-RG4KPBEZ-DvkxGdO6.mjs +0 -3
  242. package/dist/radar-RG4KPBEZ-R2sQOLL9.js +0 -1
  243. package/dist/railroad-74A4TZTK-BOZIf6ts.js +0 -1
  244. package/dist/railroad-74A4TZTK-CrQzn8Nm.mjs +0 -3
  245. package/dist/railroad-abnf-HS5TGJTU-BZYetxLz.mjs +0 -3
  246. package/dist/railroad-abnf-HS5TGJTU-CXU1aC4B.js +0 -1
  247. package/dist/railroad-ebnf-LZEXJU2U-D29kI3YW.js +0 -1
  248. package/dist/railroad-ebnf-LZEXJU2U-qgzTOmN6.mjs +0 -3
  249. package/dist/railroad-peg-WCYAUIDC-Bjs9Ws3P.mjs +0 -3
  250. package/dist/railroad-peg-WCYAUIDC-CXviP0hz.js +0 -1
  251. package/dist/railroadDiagram-O6MQD6OU-58kvwt7H.mjs +0 -76
  252. package/dist/railroadDiagram-O6MQD6OU-CKY3uzTc.js +0 -1
  253. package/dist/requirementDiagram-BXWQKSXE-0hZ04Q6h.js +0 -84
  254. package/dist/requirementDiagram-BXWQKSXE-CS673B5n.mjs +0 -2224
  255. package/dist/rough.esm-ChRLLRha.js +0 -1
  256. package/dist/rough.esm-DXYGHN3m.mjs +0 -1361
  257. package/dist/sankeyDiagram-P5KCCOFB-D1D6HfAM.mjs +0 -972
  258. package/dist/sankeyDiagram-P5KCCOFB-ciJb9Zr8.js +0 -40
  259. package/dist/sequenceDiagram-WJ2MYXX4-BXEznuI6.js +0 -162
  260. package/dist/sequenceDiagram-WJ2MYXX4-CI1VT8AG.mjs +0 -4156
  261. package/dist/sizeCapture-INFHLROL-BihkCH-7.js +0 -1
  262. package/dist/sizeCapture-INFHLROL-BmxqyOLj.mjs +0 -46
  263. package/dist/src-B4mN2BMl.js +0 -1
  264. package/dist/src-D_hsMyeP.mjs +0 -2154
  265. package/dist/stateDiagram-D77RDMKH-BQrSs72W.mjs +0 -220
  266. package/dist/stateDiagram-D77RDMKH-D2PtkW2U.js +0 -1
  267. package/dist/stateDiagram-v2-MP3YSRHH-CCbvNfk-.mjs +0 -30
  268. package/dist/stateDiagram-v2-MP3YSRHH-Dq1QuPeN.js +0 -1
  269. package/dist/swimlanes-42K2YHIH-CA316NPm.mjs +0 -4979
  270. package/dist/swimlanes-42K2YHIH-DlggBCTy.js +0 -1
  271. package/dist/swimlanesDiagram-VR7AAH4N-BV9PEIoG.js +0 -8
  272. package/dist/swimlanesDiagram-VR7AAH4N-BfrOCfdf.mjs +0 -31
  273. package/dist/timeline-definition-24CTP7MA-Bkd8rWNJ.js +0 -120
  274. package/dist/timeline-definition-24CTP7MA-BvkqNYt1.mjs +0 -1069
  275. package/dist/treeView-Q6P3EWNA-Aof3Cp1M.mjs +0 -3
  276. package/dist/treeView-Q6P3EWNA-BTzvdwbb.js +0 -1
  277. package/dist/treemap-WGGIJYW6-BNXGg99p.mjs +0 -3
  278. package/dist/treemap-WGGIJYW6-DfR4P2Hh.js +0 -1
  279. package/dist/types/runtime/app.d.ts +0 -9
  280. package/dist/types/runtime/components/AppearanceMenu.d.ts +0 -2
  281. package/dist/types/runtime/components/Builtins.d.ts +0 -44
  282. package/dist/types/runtime/components/Content.d.ts +0 -2
  283. package/dist/types/runtime/components/DmdRegistry.d.ts +0 -19
  284. package/dist/types/runtime/components/Layout.d.ts +0 -2
  285. package/dist/types/runtime/components/MermaidDiagram.d.ts +0 -16
  286. package/dist/types/runtime/components/Navbar.d.ts +0 -2
  287. package/dist/types/runtime/components/OfflineDownloadButton.d.ts +0 -2
  288. package/dist/types/runtime/components/OfflineNotice.d.ts +0 -6
  289. package/dist/types/runtime/components/Sidebar.d.ts +0 -2
  290. package/dist/types/runtime/components/TableOfContents.d.ts +0 -8
  291. package/dist/types/runtime/index.d.ts +0 -8
  292. package/dist/types/runtime/markdown/renderer.d.ts +0 -7
  293. package/dist/types/runtime/provider/DocProvider.d.ts +0 -40
  294. package/dist/types/runtime/provider/ThemeProvider.d.ts +0 -25
  295. package/dist/types/runtime/search/SearchModal.d.ts +0 -11
  296. package/dist/vennDiagram-4TSXK5OY-BOUFXjso.js +0 -34
  297. package/dist/vennDiagram-4TSXK5OY-CeOg3-hU.mjs +0 -1880
  298. package/dist/wardley-WFR3VGLG-BOYcSLd1.mjs +0 -3
  299. package/dist/wardley-WFR3VGLG-DWDqJSgm.js +0 -1
  300. package/dist/wardleyDiagram-VM6X3IG4-BhWgMjFr.js +0 -78
  301. package/dist/wardleyDiagram-VM6X3IG4-C31KoRmF.mjs +0 -645
  302. package/dist/xychartDiagram-S5SC5T6Z-1yU8zz6I.js +0 -7
  303. package/dist/xychartDiagram-S5SC5T6Z-BK7upFom.mjs +0 -2210
  304. package/templates/.dmd/components.js +0 -25
@@ -1,972 +0,0 @@
1
- import { p as e } from "./src-D_hsMyeP.mjs";
2
- import { n as t } from "./chunk-Y2CYZVJY-i11wjrBe.mjs";
3
- import { H as n, J as r, K as i, U as a, a as o, d as s, s as c, v as l, w as u, x as d, y as f } from "./chunk-DU6HZSFF-BEQZSmUu.mjs";
4
- import { t as p } from "./ordinal-B1BNQwUR.mjs";
5
- //#region node_modules/d3-scale-chromatic/src/colors.js
6
- function m(e) {
7
- for (var t = e.length / 6 | 0, n = Array(t), r = 0; r < t;) n[r] = "#" + e.slice(r * 6, ++r * 6);
8
- return n;
9
- }
10
- //#endregion
11
- //#region node_modules/d3-scale-chromatic/src/categorical/Tableau10.js
12
- var h = m("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab");
13
- //#endregion
14
- //#region node_modules/d3-sankey/node_modules/d3-array/src/max.js
15
- function g(e, t) {
16
- let n;
17
- if (t === void 0) for (let t of e) t != null && (n < t || n === void 0 && t >= t) && (n = t);
18
- else {
19
- let r = -1;
20
- for (let i of e) (i = t(i, ++r, e)) != null && (n < i || n === void 0 && i >= i) && (n = i);
21
- }
22
- return n;
23
- }
24
- //#endregion
25
- //#region node_modules/d3-sankey/node_modules/d3-array/src/min.js
26
- function _(e, t) {
27
- let n;
28
- if (t === void 0) for (let t of e) t != null && (n > t || n === void 0 && t >= t) && (n = t);
29
- else {
30
- let r = -1;
31
- for (let i of e) (i = t(i, ++r, e)) != null && (n > i || n === void 0 && i >= i) && (n = i);
32
- }
33
- return n;
34
- }
35
- //#endregion
36
- //#region node_modules/d3-sankey/node_modules/d3-array/src/sum.js
37
- function v(e, t) {
38
- let n = 0;
39
- if (t === void 0) for (let t of e) (t = +t) && (n += t);
40
- else {
41
- let r = -1;
42
- for (let i of e) (i = +t(i, ++r, e)) && (n += i);
43
- }
44
- return n;
45
- }
46
- //#endregion
47
- //#region node_modules/d3-sankey/src/align.js
48
- function y(e) {
49
- return e.target.depth;
50
- }
51
- function b(e) {
52
- return e.depth;
53
- }
54
- function x(e, t) {
55
- return t - 1 - e.height;
56
- }
57
- function S(e, t) {
58
- return e.sourceLinks.length ? e.depth : t - 1;
59
- }
60
- function C(e) {
61
- return e.targetLinks.length ? e.depth : e.sourceLinks.length ? _(e.sourceLinks, y) - 1 : 0;
62
- }
63
- //#endregion
64
- //#region node_modules/d3-sankey/src/constant.js
65
- function w(e) {
66
- return function() {
67
- return e;
68
- };
69
- }
70
- //#endregion
71
- //#region node_modules/d3-sankey/src/sankey.js
72
- function T(e, t) {
73
- return D(e.source, t.source) || e.index - t.index;
74
- }
75
- function E(e, t) {
76
- return D(e.target, t.target) || e.index - t.index;
77
- }
78
- function D(e, t) {
79
- return e.y0 - t.y0;
80
- }
81
- function O(e) {
82
- return e.value;
83
- }
84
- function k(e) {
85
- return e.index;
86
- }
87
- function A(e) {
88
- return e.nodes;
89
- }
90
- function j(e) {
91
- return e.links;
92
- }
93
- function M(e, t) {
94
- let n = e.get(t);
95
- if (!n) throw Error("missing: " + t);
96
- return n;
97
- }
98
- function N({ nodes: e }) {
99
- for (let t of e) {
100
- let e = t.y0, n = e;
101
- for (let n of t.sourceLinks) n.y0 = e + n.width / 2, e += n.width;
102
- for (let e of t.targetLinks) e.y1 = n + e.width / 2, n += e.width;
103
- }
104
- }
105
- function P() {
106
- let e = 0, t = 0, n = 1, r = 1, i = 24, a = 8, o, s = k, c = S, l, u, d = A, f = j, p = 6;
107
- function m() {
108
- let e = {
109
- nodes: d.apply(null, arguments),
110
- links: f.apply(null, arguments)
111
- };
112
- return h(e), y(e), b(e), x(e), F(e), N(e), e;
113
- }
114
- m.update = function(e) {
115
- return N(e), e;
116
- }, m.nodeId = function(e) {
117
- return arguments.length ? (s = typeof e == "function" ? e : w(e), m) : s;
118
- }, m.nodeAlign = function(e) {
119
- return arguments.length ? (c = typeof e == "function" ? e : w(e), m) : c;
120
- }, m.nodeSort = function(e) {
121
- return arguments.length ? (l = e, m) : l;
122
- }, m.nodeWidth = function(e) {
123
- return arguments.length ? (i = +e, m) : i;
124
- }, m.nodePadding = function(e) {
125
- return arguments.length ? (a = o = +e, m) : a;
126
- }, m.nodes = function(e) {
127
- return arguments.length ? (d = typeof e == "function" ? e : w(e), m) : d;
128
- }, m.links = function(e) {
129
- return arguments.length ? (f = typeof e == "function" ? e : w(e), m) : f;
130
- }, m.linkSort = function(e) {
131
- return arguments.length ? (u = e, m) : u;
132
- }, m.size = function(i) {
133
- return arguments.length ? (e = t = 0, n = +i[0], r = +i[1], m) : [n - e, r - t];
134
- }, m.extent = function(i) {
135
- return arguments.length ? (e = +i[0][0], n = +i[1][0], t = +i[0][1], r = +i[1][1], m) : [[e, t], [n, r]];
136
- }, m.iterations = function(e) {
137
- return arguments.length ? (p = +e, m) : p;
138
- };
139
- function h({ nodes: e, links: t }) {
140
- for (let [t, n] of e.entries()) n.index = t, n.sourceLinks = [], n.targetLinks = [];
141
- let n = new Map(e.map((t, n) => [s(t, n, e), t]));
142
- for (let [e, r] of t.entries()) {
143
- r.index = e;
144
- let { source: t, target: i } = r;
145
- typeof t != "object" && (t = r.source = M(n, t)), typeof i != "object" && (i = r.target = M(n, i)), t.sourceLinks.push(r), i.targetLinks.push(r);
146
- }
147
- if (u != null) for (let { sourceLinks: t, targetLinks: n } of e) t.sort(u), n.sort(u);
148
- }
149
- function y({ nodes: e }) {
150
- for (let t of e) t.value = t.fixedValue === void 0 ? Math.max(v(t.sourceLinks, O), v(t.targetLinks, O)) : t.fixedValue;
151
- }
152
- function b({ nodes: e }) {
153
- let t = e.length, n = new Set(e), r = /* @__PURE__ */ new Set(), i = 0;
154
- for (; n.size;) {
155
- for (let e of n) {
156
- e.depth = i;
157
- for (let { target: t } of e.sourceLinks) r.add(t);
158
- }
159
- if (++i > t) throw Error("circular link");
160
- n = r, r = /* @__PURE__ */ new Set();
161
- }
162
- }
163
- function x({ nodes: e }) {
164
- let t = e.length, n = new Set(e), r = /* @__PURE__ */ new Set(), i = 0;
165
- for (; n.size;) {
166
- for (let e of n) {
167
- e.height = i;
168
- for (let { source: t } of e.targetLinks) r.add(t);
169
- }
170
- if (++i > t) throw Error("circular link");
171
- n = r, r = /* @__PURE__ */ new Set();
172
- }
173
- }
174
- function C({ nodes: t }) {
175
- let r = g(t, (e) => e.depth) + 1, a = (n - e - i) / (r - 1), o = Array(r);
176
- for (let n of t) {
177
- let t = Math.max(0, Math.min(r - 1, Math.floor(c.call(null, n, r))));
178
- n.layer = t, n.x0 = e + t * a, n.x1 = n.x0 + i, o[t] ? o[t].push(n) : o[t] = [n];
179
- }
180
- if (l) for (let e of o) e.sort(l);
181
- return o;
182
- }
183
- function P(e) {
184
- let n = _(e, (e) => (r - t - (e.length - 1) * o) / v(e, O));
185
- for (let i of e) {
186
- let e = t;
187
- for (let t of i) {
188
- t.y0 = e, t.y1 = e + t.value * n, e = t.y1 + o;
189
- for (let e of t.sourceLinks) e.width = e.value * n;
190
- }
191
- e = (r - e + o) / (i.length + 1);
192
- for (let t = 0; t < i.length; ++t) {
193
- let n = i[t];
194
- n.y0 += e * (t + 1), n.y1 += e * (t + 1);
195
- }
196
- H(i);
197
- }
198
- }
199
- function F(e) {
200
- let n = C(e);
201
- o = Math.min(a, (r - t) / (g(n, (e) => e.length) - 1)), P(n);
202
- for (let e = 0; e < p; ++e) {
203
- let t = .99 ** e, r = Math.max(1 - t, (e + 1) / p);
204
- L(n, t, r), I(n, t, r);
205
- }
206
- }
207
- function I(e, t, n) {
208
- for (let r = 1, i = e.length; r < i; ++r) {
209
- let i = e[r];
210
- for (let e of i) {
211
- let n = 0, r = 0;
212
- for (let { source: t, value: i } of e.targetLinks) {
213
- let a = i * (e.layer - t.layer);
214
- n += U(t, e) * a, r += a;
215
- }
216
- if (!(r > 0)) continue;
217
- let i = (n / r - e.y0) * t;
218
- e.y0 += i, e.y1 += i, V(e);
219
- }
220
- l === void 0 && i.sort(D), R(i, n);
221
- }
222
- }
223
- function L(e, t, n) {
224
- for (let r = e.length - 2; r >= 0; --r) {
225
- let i = e[r];
226
- for (let e of i) {
227
- let n = 0, r = 0;
228
- for (let { target: t, value: i } of e.sourceLinks) {
229
- let a = i * (t.layer - e.layer);
230
- n += W(e, t) * a, r += a;
231
- }
232
- if (!(r > 0)) continue;
233
- let i = (n / r - e.y0) * t;
234
- e.y0 += i, e.y1 += i, V(e);
235
- }
236
- l === void 0 && i.sort(D), R(i, n);
237
- }
238
- }
239
- function R(e, n) {
240
- let i = e.length >> 1, a = e[i];
241
- B(e, a.y0 - o, i - 1, n), z(e, a.y1 + o, i + 1, n), B(e, r, e.length - 1, n), z(e, t, 0, n);
242
- }
243
- function z(e, t, n, r) {
244
- for (; n < e.length; ++n) {
245
- let i = e[n], a = (t - i.y0) * r;
246
- a > 1e-6 && (i.y0 += a, i.y1 += a), t = i.y1 + o;
247
- }
248
- }
249
- function B(e, t, n, r) {
250
- for (; n >= 0; --n) {
251
- let i = e[n], a = (i.y1 - t) * r;
252
- a > 1e-6 && (i.y0 -= a, i.y1 -= a), t = i.y0 - o;
253
- }
254
- }
255
- function V({ sourceLinks: e, targetLinks: t }) {
256
- if (u === void 0) {
257
- for (let { source: { sourceLinks: e } } of t) e.sort(E);
258
- for (let { target: { targetLinks: t } } of e) t.sort(T);
259
- }
260
- }
261
- function H(e) {
262
- if (u === void 0) for (let { sourceLinks: t, targetLinks: n } of e) t.sort(E), n.sort(T);
263
- }
264
- function U(e, t) {
265
- let n = e.y0 - (e.sourceLinks.length - 1) * o / 2;
266
- for (let { target: r, width: i } of e.sourceLinks) {
267
- if (r === t) break;
268
- n += i + o;
269
- }
270
- for (let { source: r, width: i } of t.targetLinks) {
271
- if (r === e) break;
272
- n -= i;
273
- }
274
- return n;
275
- }
276
- function W(e, t) {
277
- let n = t.y0 - (t.targetLinks.length - 1) * o / 2;
278
- for (let { source: r, width: i } of t.targetLinks) {
279
- if (r === e) break;
280
- n += i + o;
281
- }
282
- for (let { target: r, width: i } of e.sourceLinks) {
283
- if (r === t) break;
284
- n -= i;
285
- }
286
- return n;
287
- }
288
- return m;
289
- }
290
- //#endregion
291
- //#region node_modules/d3-sankey/node_modules/d3-path/src/path.js
292
- var F = Math.PI, I = 2 * F, L = 1e-6, R = I - L;
293
- function z() {
294
- this._x0 = this._y0 = this._x1 = this._y1 = null, this._ = "";
295
- }
296
- function B() {
297
- return new z();
298
- }
299
- z.prototype = B.prototype = {
300
- constructor: z,
301
- moveTo: function(e, t) {
302
- this._ += "M" + (this._x0 = this._x1 = +e) + "," + (this._y0 = this._y1 = +t);
303
- },
304
- closePath: function() {
305
- this._x1 !== null && (this._x1 = this._x0, this._y1 = this._y0, this._ += "Z");
306
- },
307
- lineTo: function(e, t) {
308
- this._ += "L" + (this._x1 = +e) + "," + (this._y1 = +t);
309
- },
310
- quadraticCurveTo: function(e, t, n, r) {
311
- this._ += "Q" + +e + "," + +t + "," + (this._x1 = +n) + "," + (this._y1 = +r);
312
- },
313
- bezierCurveTo: function(e, t, n, r, i, a) {
314
- this._ += "C" + +e + "," + +t + "," + +n + "," + +r + "," + (this._x1 = +i) + "," + (this._y1 = +a);
315
- },
316
- arcTo: function(e, t, n, r, i) {
317
- e = +e, t = +t, n = +n, r = +r, i = +i;
318
- var a = this._x1, o = this._y1, s = n - e, c = r - t, l = a - e, u = o - t, d = l * l + u * u;
319
- if (i < 0) throw Error("negative radius: " + i);
320
- if (this._x1 === null) this._ += "M" + (this._x1 = e) + "," + (this._y1 = t);
321
- else if (d > L) {
322
- if (!(Math.abs(u * s - c * l) > L) || !i) this._ += "L" + (this._x1 = e) + "," + (this._y1 = t);
323
- else {
324
- var f = n - a, p = r - o, m = s * s + c * c, h = f * f + p * p, g = Math.sqrt(m), _ = Math.sqrt(d), v = i * Math.tan((F - Math.acos((m + d - h) / (2 * g * _))) / 2), y = v / _, b = v / g;
325
- Math.abs(y - 1) > L && (this._ += "L" + (e + y * l) + "," + (t + y * u)), this._ += "A" + i + "," + i + ",0,0," + +(u * f > l * p) + "," + (this._x1 = e + b * s) + "," + (this._y1 = t + b * c);
326
- }
327
- }
328
- },
329
- arc: function(e, t, n, r, i, a) {
330
- e = +e, t = +t, n = +n, a = !!a;
331
- var o = n * Math.cos(r), s = n * Math.sin(r), c = e + o, l = t + s, u = 1 ^ a, d = a ? r - i : i - r;
332
- if (n < 0) throw Error("negative radius: " + n);
333
- this._x1 === null ? this._ += "M" + c + "," + l : (Math.abs(this._x1 - c) > L || Math.abs(this._y1 - l) > L) && (this._ += "L" + c + "," + l), n && (d < 0 && (d = d % I + I), d > R ? this._ += "A" + n + "," + n + ",0,1," + u + "," + (e - o) + "," + (t - s) + "A" + n + "," + n + ",0,1," + u + "," + (this._x1 = c) + "," + (this._y1 = l) : d > L && (this._ += "A" + n + "," + n + ",0," + +(d >= F) + "," + u + "," + (this._x1 = e + n * Math.cos(i)) + "," + (this._y1 = t + n * Math.sin(i))));
334
- },
335
- rect: function(e, t, n, r) {
336
- this._ += "M" + (this._x0 = this._x1 = +e) + "," + (this._y0 = this._y1 = +t) + "h" + +n + "v" + +r + "h" + -n + "Z";
337
- },
338
- toString: function() {
339
- return this._;
340
- }
341
- };
342
- //#endregion
343
- //#region node_modules/d3-sankey/node_modules/d3-shape/src/constant.js
344
- function V(e) {
345
- return function() {
346
- return e;
347
- };
348
- }
349
- //#endregion
350
- //#region node_modules/d3-sankey/node_modules/d3-shape/src/point.js
351
- function H(e) {
352
- return e[0];
353
- }
354
- function U(e) {
355
- return e[1];
356
- }
357
- //#endregion
358
- //#region node_modules/d3-sankey/node_modules/d3-shape/src/array.js
359
- var W = Array.prototype.slice;
360
- //#endregion
361
- //#region node_modules/d3-sankey/node_modules/d3-shape/src/link/index.js
362
- function G(e) {
363
- return e.source;
364
- }
365
- function ee(e) {
366
- return e.target;
367
- }
368
- function te(e) {
369
- var t = G, n = ee, r = H, i = U, a = null;
370
- function o() {
371
- var o, s = W.call(arguments), c = t.apply(this, s), l = n.apply(this, s);
372
- if (a ||= o = B(), e(a, +r.apply(this, (s[0] = c, s)), +i.apply(this, s), +r.apply(this, (s[0] = l, s)), +i.apply(this, s)), o) return a = null, o + "" || null;
373
- }
374
- return o.source = function(e) {
375
- return arguments.length ? (t = e, o) : t;
376
- }, o.target = function(e) {
377
- return arguments.length ? (n = e, o) : n;
378
- }, o.x = function(e) {
379
- return arguments.length ? (r = typeof e == "function" ? e : V(+e), o) : r;
380
- }, o.y = function(e) {
381
- return arguments.length ? (i = typeof e == "function" ? e : V(+e), o) : i;
382
- }, o.context = function(e) {
383
- return arguments.length ? (a = e ?? null, o) : a;
384
- }, o;
385
- }
386
- function ne(e, t, n, r, i) {
387
- e.moveTo(t, n), e.bezierCurveTo(t = (t + r) / 2, n, t, i, r, i);
388
- }
389
- function re() {
390
- return te(ne);
391
- }
392
- //#endregion
393
- //#region node_modules/d3-sankey/src/sankeyLinkHorizontal.js
394
- function ie(e) {
395
- return [e.source.x1, e.y0];
396
- }
397
- function ae(e) {
398
- return [e.target.x0, e.y1];
399
- }
400
- function K() {
401
- return re().source(ie).target(ae);
402
- }
403
- //#endregion
404
- //#region node_modules/mermaid/dist/chunks/mermaid.core/sankeyDiagram-P5KCCOFB.mjs
405
- var q = (function() {
406
- var e = /* @__PURE__ */ t(function(e, t, n, r) {
407
- for (n ||= {}, r = e.length; r--; n[e[r]] = t);
408
- return n;
409
- }, "o"), n = [1, 9], r = [1, 10], i = [
410
- 1,
411
- 5,
412
- 10,
413
- 12
414
- ], a = {
415
- trace: /* @__PURE__ */ t(function() {}, "trace"),
416
- yy: {},
417
- symbols_: {
418
- error: 2,
419
- start: 3,
420
- SANKEY: 4,
421
- NEWLINE: 5,
422
- csv: 6,
423
- opt_eof: 7,
424
- record: 8,
425
- csv_tail: 9,
426
- EOF: 10,
427
- "field[source]": 11,
428
- COMMA: 12,
429
- "field[target]": 13,
430
- "field[value]": 14,
431
- field: 15,
432
- escaped: 16,
433
- non_escaped: 17,
434
- DQUOTE: 18,
435
- ESCAPED_TEXT: 19,
436
- NON_ESCAPED_TEXT: 20,
437
- $accept: 0,
438
- $end: 1
439
- },
440
- terminals_: {
441
- 2: "error",
442
- 4: "SANKEY",
443
- 5: "NEWLINE",
444
- 10: "EOF",
445
- 11: "field[source]",
446
- 12: "COMMA",
447
- 13: "field[target]",
448
- 14: "field[value]",
449
- 18: "DQUOTE",
450
- 19: "ESCAPED_TEXT",
451
- 20: "NON_ESCAPED_TEXT"
452
- },
453
- productions_: [
454
- 0,
455
- [3, 4],
456
- [6, 2],
457
- [9, 2],
458
- [9, 0],
459
- [7, 1],
460
- [7, 0],
461
- [8, 5],
462
- [15, 1],
463
- [15, 1],
464
- [16, 3],
465
- [17, 1]
466
- ],
467
- performAction: /* @__PURE__ */ t(function(e, t, n, r, i, a, o) {
468
- var s = a.length - 1;
469
- switch (i) {
470
- case 7:
471
- let e = r.findOrCreateNode(a[s - 4].trim().replaceAll("\"\"", "\"")), t = r.findOrCreateNode(a[s - 2].trim().replaceAll("\"\"", "\"")), n = parseFloat(a[s].trim());
472
- r.addLink(e, t, n);
473
- break;
474
- case 8:
475
- case 9:
476
- case 11:
477
- this.$ = a[s];
478
- break;
479
- case 10: this.$ = a[s - 1];
480
- }
481
- }, "anonymous"),
482
- table: [
483
- {
484
- 3: 1,
485
- 4: [1, 2]
486
- },
487
- { 1: [3] },
488
- { 5: [1, 3] },
489
- {
490
- 6: 4,
491
- 8: 5,
492
- 15: 6,
493
- 16: 7,
494
- 17: 8,
495
- 18: n,
496
- 20: r
497
- },
498
- {
499
- 1: [2, 6],
500
- 7: 11,
501
- 10: [1, 12]
502
- },
503
- e(r, [2, 4], {
504
- 9: 13,
505
- 5: [1, 14]
506
- }),
507
- { 12: [1, 15] },
508
- e(i, [2, 8]),
509
- e(i, [2, 9]),
510
- { 19: [1, 16] },
511
- e(i, [2, 11]),
512
- { 1: [2, 1] },
513
- { 1: [2, 5] },
514
- e(r, [2, 2]),
515
- {
516
- 6: 17,
517
- 8: 5,
518
- 15: 6,
519
- 16: 7,
520
- 17: 8,
521
- 18: n,
522
- 20: r
523
- },
524
- {
525
- 15: 18,
526
- 16: 7,
527
- 17: 8,
528
- 18: n,
529
- 20: r
530
- },
531
- { 18: [1, 19] },
532
- e(r, [2, 3]),
533
- { 12: [1, 20] },
534
- e(i, [2, 10]),
535
- {
536
- 15: 21,
537
- 16: 7,
538
- 17: 8,
539
- 18: n,
540
- 20: r
541
- },
542
- e([
543
- 1,
544
- 5,
545
- 10
546
- ], [2, 7])
547
- ],
548
- defaultActions: {
549
- 11: [2, 1],
550
- 12: [2, 5]
551
- },
552
- parseError: /* @__PURE__ */ t(function(e, t) {
553
- if (t.recoverable) this.trace(e);
554
- else {
555
- var n = Error(e);
556
- throw n.hash = t, n;
557
- }
558
- }, "parseError"),
559
- parse: /* @__PURE__ */ t(function(e) {
560
- var n = this, r = [0], i = [], a = [null], o = [], s = this.table, c = "", l = 0, u = 0, d = 0, f = 2, p = 1, m = o.slice.call(arguments, 1), h = Object.create(this.lexer), g = { yy: {} };
561
- for (var _ in this.yy) Object.prototype.hasOwnProperty.call(this.yy, _) && (g.yy[_] = this.yy[_]);
562
- h.setInput(e, g.yy), g.yy.lexer = h, g.yy.parser = this, h.yylloc === void 0 && (h.yylloc = {});
563
- var v = h.yylloc;
564
- o.push(v);
565
- var y = h.options && h.options.ranges;
566
- this.parseError = typeof g.yy.parseError == "function" ? g.yy.parseError : Object.getPrototypeOf(this).parseError;
567
- function b(e) {
568
- r.length -= 2 * e, a.length -= e, o.length -= e;
569
- }
570
- t(b, "popStack");
571
- function x() {
572
- var e = i.pop() || h.lex() || p;
573
- return typeof e != "number" && (e instanceof Array && (i = e, e = i.pop()), e = n.symbols_[e] || e), e;
574
- }
575
- t(x, "lex");
576
- for (var S, C, w, T, E, D = {}, O, k, A, j;;) {
577
- if (w = r[r.length - 1], this.defaultActions[w] ? T = this.defaultActions[w] : (S ??= x(), T = s[w] && s[w][S]), T === void 0 || !T.length || !T[0]) {
578
- var M = "";
579
- for (O in j = [], s[w]) this.terminals_[O] && O > f && j.push("'" + this.terminals_[O] + "'");
580
- M = h.showPosition ? "Parse error on line " + (l + 1) + ":\n" + h.showPosition() + "\nExpecting " + j.join(", ") + ", got '" + (this.terminals_[S] || S) + "'" : "Parse error on line " + (l + 1) + ": Unexpected " + (S == p ? "end of input" : "'" + (this.terminals_[S] || S) + "'"), this.parseError(M, {
581
- text: h.match,
582
- token: this.terminals_[S] || S,
583
- line: h.yylineno,
584
- loc: v,
585
- expected: j
586
- });
587
- }
588
- if (T[0] instanceof Array && T.length > 1) throw Error("Parse Error: multiple actions possible at state: " + w + ", token: " + S);
589
- switch (T[0]) {
590
- case 1:
591
- r.push(S), a.push(h.yytext), o.push(h.yylloc), r.push(T[1]), S = null, C ? (S = C, C = null) : (u = h.yyleng, c = h.yytext, l = h.yylineno, v = h.yylloc, d > 0 && d--);
592
- break;
593
- case 2:
594
- if (k = this.productions_[T[1]][1], D.$ = a[a.length - k], D._$ = {
595
- first_line: o[o.length - (k || 1)].first_line,
596
- last_line: o[o.length - 1].last_line,
597
- first_column: o[o.length - (k || 1)].first_column,
598
- last_column: o[o.length - 1].last_column
599
- }, y && (D._$.range = [o[o.length - (k || 1)].range[0], o[o.length - 1].range[1]]), E = this.performAction.apply(D, [
600
- c,
601
- u,
602
- l,
603
- g.yy,
604
- T[1],
605
- a,
606
- o
607
- ].concat(m)), E !== void 0) return E;
608
- k && (r = r.slice(0, -1 * k * 2), a = a.slice(0, -1 * k), o = o.slice(0, -1 * k)), r.push(this.productions_[T[1]][0]), a.push(D.$), o.push(D._$), A = s[r[r.length - 2]][r[r.length - 1]], r.push(A);
609
- break;
610
- case 3: return !0;
611
- }
612
- }
613
- return !0;
614
- }, "parse")
615
- };
616
- a.lexer = /* @__PURE__ */ (function() {
617
- return {
618
- EOF: 1,
619
- parseError: /* @__PURE__ */ t(function(e, t) {
620
- if (this.yy.parser) this.yy.parser.parseError(e, t);
621
- else throw Error(e);
622
- }, "parseError"),
623
- setInput: /* @__PURE__ */ t(function(e, t) {
624
- return this.yy = t || this.yy || {}, this._input = e, this._more = this._backtrack = this.done = !1, this.yylineno = this.yyleng = 0, this.yytext = this.matched = this.match = "", this.conditionStack = ["INITIAL"], this.yylloc = {
625
- first_line: 1,
626
- first_column: 0,
627
- last_line: 1,
628
- last_column: 0
629
- }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
630
- }, "setInput"),
631
- input: /* @__PURE__ */ t(function() {
632
- var e = this._input[0];
633
- return this.yytext += e, this.yyleng++, this.offset++, this.match += e, this.matched += e, e.match(/(?:\r\n?|\n).*/g) ? (this.yylineno++, this.yylloc.last_line++) : this.yylloc.last_column++, this.options.ranges && this.yylloc.range[1]++, this._input = this._input.slice(1), e;
634
- }, "input"),
635
- unput: /* @__PURE__ */ t(function(e) {
636
- var t = e.length, n = e.split(/(?:\r\n?|\n)/g);
637
- this._input = e + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - t), this.offset -= t;
638
- var r = this.match.split(/(?:\r\n?|\n)/g);
639
- this.match = this.match.substr(0, this.match.length - 1), this.matched = this.matched.substr(0, this.matched.length - 1), n.length - 1 && (this.yylineno -= n.length - 1);
640
- var i = this.yylloc.range;
641
- return this.yylloc = {
642
- first_line: this.yylloc.first_line,
643
- last_line: this.yylineno + 1,
644
- first_column: this.yylloc.first_column,
645
- last_column: n ? (n.length === r.length ? this.yylloc.first_column : 0) + r[r.length - n.length].length - n[0].length : this.yylloc.first_column - t
646
- }, this.options.ranges && (this.yylloc.range = [i[0], i[0] + this.yyleng - t]), this.yyleng = this.yytext.length, this;
647
- }, "unput"),
648
- more: /* @__PURE__ */ t(function() {
649
- return this._more = !0, this;
650
- }, "more"),
651
- reject: /* @__PURE__ */ t(function() {
652
- if (this.options.backtrack_lexer) this._backtrack = !0;
653
- else return this.parseError("Lexical error on line " + (this.yylineno + 1) + ". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n" + this.showPosition(), {
654
- text: "",
655
- token: null,
656
- line: this.yylineno
657
- });
658
- return this;
659
- }, "reject"),
660
- less: /* @__PURE__ */ t(function(e) {
661
- this.unput(this.match.slice(e));
662
- }, "less"),
663
- pastInput: /* @__PURE__ */ t(function() {
664
- var e = this.matched.substr(0, this.matched.length - this.match.length);
665
- return (e.length > 20 ? "..." : "") + e.substr(-20).replace(/\n/g, "");
666
- }, "pastInput"),
667
- upcomingInput: /* @__PURE__ */ t(function() {
668
- var e = this.match;
669
- return e.length < 20 && (e += this._input.substr(0, 20 - e.length)), (e.substr(0, 20) + (e.length > 20 ? "..." : "")).replace(/\n/g, "");
670
- }, "upcomingInput"),
671
- showPosition: /* @__PURE__ */ t(function() {
672
- var e = this.pastInput(), t = Array(e.length + 1).join("-");
673
- return e + this.upcomingInput() + "\n" + t + "^";
674
- }, "showPosition"),
675
- test_match: /* @__PURE__ */ t(function(e, t) {
676
- var n, r, i;
677
- if (this.options.backtrack_lexer && (i = {
678
- yylineno: this.yylineno,
679
- yylloc: {
680
- first_line: this.yylloc.first_line,
681
- last_line: this.last_line,
682
- first_column: this.yylloc.first_column,
683
- last_column: this.yylloc.last_column
684
- },
685
- yytext: this.yytext,
686
- match: this.match,
687
- matches: this.matches,
688
- matched: this.matched,
689
- yyleng: this.yyleng,
690
- offset: this.offset,
691
- _more: this._more,
692
- _input: this._input,
693
- yy: this.yy,
694
- conditionStack: this.conditionStack.slice(0),
695
- done: this.done
696
- }, this.options.ranges && (i.yylloc.range = this.yylloc.range.slice(0))), r = e[0].match(/(?:\r\n?|\n).*/g), r && (this.yylineno += r.length), this.yylloc = {
697
- first_line: this.yylloc.last_line,
698
- last_line: this.yylineno + 1,
699
- first_column: this.yylloc.last_column,
700
- last_column: r ? r[r.length - 1].length - r[r.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + e[0].length
701
- }, this.yytext += e[0], this.match += e[0], this.matches = e, this.yyleng = this.yytext.length, this.options.ranges && (this.yylloc.range = [this.offset, this.offset += this.yyleng]), this._more = !1, this._backtrack = !1, this._input = this._input.slice(e[0].length), this.matched += e[0], n = this.performAction.call(this, this.yy, this, t, this.conditionStack[this.conditionStack.length - 1]), this.done && this._input && (this.done = !1), n) return n;
702
- if (this._backtrack) {
703
- for (var a in i) this[a] = i[a];
704
- return !1;
705
- }
706
- return !1;
707
- }, "test_match"),
708
- next: /* @__PURE__ */ t(function() {
709
- if (this.done) return this.EOF;
710
- this._input || (this.done = !0);
711
- var e, t, n, r;
712
- this._more || (this.yytext = "", this.match = "");
713
- for (var i = this._currentRules(), a = 0; a < i.length; a++) if (n = this._input.match(this.rules[i[a]]), n && (!t || n[0].length > t[0].length)) {
714
- if (t = n, r = a, this.options.backtrack_lexer) {
715
- if (e = this.test_match(n, i[a]), e !== !1) return e;
716
- if (this._backtrack) {
717
- t = !1;
718
- continue;
719
- }
720
- return !1;
721
- }
722
- if (!this.options.flex) break;
723
- }
724
- return t ? (e = this.test_match(t, i[r]), e !== !1 && e) : this._input === "" ? this.EOF : this.parseError("Lexical error on line " + (this.yylineno + 1) + ". Unrecognized text.\n" + this.showPosition(), {
725
- text: "",
726
- token: null,
727
- line: this.yylineno
728
- });
729
- }, "next"),
730
- lex: /* @__PURE__ */ t(function() {
731
- return this.next() || this.lex();
732
- }, "lex"),
733
- begin: /* @__PURE__ */ t(function(e) {
734
- this.conditionStack.push(e);
735
- }, "begin"),
736
- popState: /* @__PURE__ */ t(function() {
737
- return this.conditionStack.length - 1 > 0 ? this.conditionStack.pop() : this.conditionStack[0];
738
- }, "popState"),
739
- _currentRules: /* @__PURE__ */ t(function() {
740
- return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
741
- }, "_currentRules"),
742
- topState: /* @__PURE__ */ t(function(e) {
743
- return e = this.conditionStack.length - 1 - Math.abs(e || 0), e >= 0 ? this.conditionStack[e] : "INITIAL";
744
- }, "topState"),
745
- pushState: /* @__PURE__ */ t(function(e) {
746
- this.begin(e);
747
- }, "pushState"),
748
- stateStackSize: /* @__PURE__ */ t(function() {
749
- return this.conditionStack.length;
750
- }, "stateStackSize"),
751
- options: { "case-insensitive": !0 },
752
- performAction: /* @__PURE__ */ t(function(e, t, n, r) {
753
- switch (n) {
754
- case 0: return this.pushState("csv"), 4;
755
- case 1: return this.pushState("csv"), 4;
756
- case 2: return 10;
757
- case 3: return 5;
758
- case 4: return 12;
759
- case 5: return this.pushState("escaped_text"), 18;
760
- case 6: return 20;
761
- case 7: return this.popState("escaped_text"), 18;
762
- case 8: return 19;
763
- }
764
- }, "anonymous"),
765
- rules: [
766
- /^(?:sankey-beta\b)/i,
767
- /^(?:sankey\b)/i,
768
- /^(?:$)/i,
769
- /^(?:((\u000D\u000A)|(\u000A)))/i,
770
- /^(?:(\u002C))/i,
771
- /^(?:(\u0022))/i,
772
- /^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,
773
- /^(?:(\u0022)(?!(\u0022)))/i,
774
- /^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i
775
- ],
776
- conditions: {
777
- csv: {
778
- rules: [
779
- 2,
780
- 3,
781
- 4,
782
- 5,
783
- 6,
784
- 7,
785
- 8
786
- ],
787
- inclusive: !1
788
- },
789
- escaped_text: {
790
- rules: [7, 8],
791
- inclusive: !1
792
- },
793
- INITIAL: {
794
- rules: [
795
- 0,
796
- 1,
797
- 2,
798
- 3,
799
- 4,
800
- 5,
801
- 6,
802
- 7,
803
- 8
804
- ],
805
- inclusive: !0
806
- }
807
- }
808
- };
809
- })();
810
- function o() {
811
- this.yy = {};
812
- }
813
- return t(o, "Parser"), o.prototype = a, a.Parser = o, new o();
814
- })();
815
- q.parser = q;
816
- var J = q, Y = [], X = [], Z = /* @__PURE__ */ new Map(), oe = /* @__PURE__ */ t(() => {
817
- Y = [], X = [], Z = /* @__PURE__ */ new Map(), o();
818
- }, "clear"), se = class {
819
- constructor(e, t, n = 0) {
820
- this.source = e, this.target = t, this.value = n;
821
- }
822
- static {
823
- t(this, "SankeyLink");
824
- }
825
- }, ce = /* @__PURE__ */ t((e, t, n) => {
826
- Y.push(new se(e, t, n));
827
- }, "addLink"), le = class {
828
- constructor(e) {
829
- this.ID = e;
830
- }
831
- static {
832
- t(this, "SankeyNode");
833
- }
834
- }, ue = {
835
- nodesMap: Z,
836
- getConfig: /* @__PURE__ */ t(() => d().sankey, "getConfig"),
837
- getNodes: /* @__PURE__ */ t(() => X, "getNodes"),
838
- getLinks: /* @__PURE__ */ t(() => Y, "getLinks"),
839
- getGraph: /* @__PURE__ */ t(() => ({
840
- nodes: X.map((e) => ({ id: e.ID })),
841
- links: Y.map((e) => ({
842
- source: e.source.ID,
843
- target: e.target.ID,
844
- value: e.value
845
- }))
846
- }), "getGraph"),
847
- addLink: ce,
848
- findOrCreateNode: /* @__PURE__ */ t((e) => {
849
- e = c.sanitizeText(e, d());
850
- let t = Z.get(e);
851
- return t === void 0 && (t = new le(e), Z.set(e, t), X.push(t)), t;
852
- }, "findOrCreateNode"),
853
- getAccTitle: f,
854
- setAccTitle: a,
855
- getAccDescription: l,
856
- setAccDescription: n,
857
- getDiagramTitle: u,
858
- setDiagramTitle: i,
859
- clear: oe
860
- }, Q = class e {
861
- static {
862
- t(this, "Uid");
863
- }
864
- static {
865
- this.count = 0;
866
- }
867
- static next(t) {
868
- return new e(t + ++e.count);
869
- }
870
- constructor(e) {
871
- this.id = e, this.href = `#${e}`;
872
- }
873
- toString() {
874
- return "url(" + this.href + ")";
875
- }
876
- }, $ = {
877
- left: b,
878
- right: x,
879
- center: C,
880
- justify: S
881
- }, de = /* @__PURE__ */ t((e) => {
882
- let t = 0, n = 0;
883
- for (let r of e) {
884
- let e = r.value ?? 0;
885
- e > t && (t = e, n = r.layer ?? 0);
886
- }
887
- return n;
888
- }, "findCentralNodeLayer"), fe = { draw: /* @__PURE__ */ t(function(n, i, a, o) {
889
- let { securityLevel: c, sankey: l } = d(), u = s.sankey, f;
890
- c === "sandbox" && (f = e("#i" + i));
891
- let m = e(c === "sandbox" ? f.nodes()[0].contentDocument.body : "body"), g = c === "sandbox" ? m.select(`[id="${i}"]`) : e(`[id="${i}"]`), _ = l?.width ?? u.width, v = l?.height ?? u.width, y = l?.useMaxWidth ?? u.useMaxWidth, b = l?.nodeAlignment ?? u.nodeAlignment, x = l?.prefix ?? u.prefix, S = l?.suffix ?? u.suffix, C = l?.showValues ?? u.showValues, w = l?.nodeWidth ?? u.nodeWidth ?? 10, T = l?.nodePadding ?? u.nodePadding ?? 12, E = l?.labelStyle ?? u.labelStyle ?? "legacy", D = l?.nodeColors ?? {}, O = o.db.getGraph(), k = $[b];
892
- P().nodeId((e) => e.id).nodeWidth(w).nodePadding(T + (C ? 15 : 0)).nodeAlign(k).extent([[0, 0], [_, v]])(O);
893
- let A = de(O.nodes), j = p(h), M = /* @__PURE__ */ t((e) => D[e] ?? j(e), "getNodeColor");
894
- g.append("g").attr("class", "nodes").selectAll(".node").data(O.nodes).join("g").attr("class", "node").attr("id", (e) => (e.uid = Q.next("node-")).id).attr("transform", function(e) {
895
- return "translate(" + e.x0 + "," + e.y0 + ")";
896
- }).attr("x", (e) => e.x0).attr("y", (e) => e.y0).append("rect").attr("height", (e) => e.y1 - e.y0).attr("width", (e) => e.x1 - e.x0).attr("fill", (e) => M(e.id));
897
- let N = /* @__PURE__ */ t(({ id: e, value: t }) => C ? `${e}
898
- ${x}${Math.round(t * 100) / 100}${S}` : e, "getText"), F = /* @__PURE__ */ t((e) => E === "outlined" ? (e.layer ?? 0) < A ? {
899
- x: e.x0 - 6,
900
- anchor: "end"
901
- } : {
902
- x: e.x1 + 6,
903
- anchor: "start"
904
- } : e.x0 < _ / 2 ? {
905
- x: e.x1 + 6,
906
- anchor: "start"
907
- } : {
908
- x: e.x0 - 6,
909
- anchor: "end"
910
- }, "getLabelPosition"), I = g.append("g").attr("class", "node-labels").attr("font-size", 14), L = /* @__PURE__ */ t((e) => I.selectAll(e ? `.${e}` : "text").data(O.nodes).join("text").attr("class", e ?? null).attr("x", (e) => F(e).x).attr("y", (e) => (e.y1 + e.y0) / 2).attr("dy", `${C ? "0" : "0.35"}em`).attr("text-anchor", (e) => F(e).anchor).text(N), "appendLabel");
911
- E === "outlined" ? (L("sankey-label-bg"), L("sankey-label-fg")) : L();
912
- let R = g.append("g").attr("class", "links").attr("fill", "none").attr("stroke-opacity", .5).selectAll(".link").data(O.links).join("g").attr("class", "link").style("mix-blend-mode", "multiply"), z = l?.linkColor ?? "gradient";
913
- if (z === "gradient") {
914
- let e = R.append("linearGradient").attr("id", (e) => (e.uid = Q.next("linearGradient-")).id).attr("gradientUnits", "userSpaceOnUse").attr("x1", (e) => e.source.x1).attr("x2", (e) => e.target.x0);
915
- e.append("stop").attr("offset", "0%").attr("stop-color", (e) => M(e.source.id)), e.append("stop").attr("offset", "100%").attr("stop-color", (e) => M(e.target.id));
916
- }
917
- let B;
918
- switch (z) {
919
- case "gradient":
920
- B = /* @__PURE__ */ t((e) => e.uid, "coloring");
921
- break;
922
- case "source":
923
- B = /* @__PURE__ */ t((e) => M(e.source.id), "coloring");
924
- break;
925
- case "target":
926
- B = /* @__PURE__ */ t((e) => M(e.target.id), "coloring");
927
- break;
928
- default: B = z;
929
- }
930
- R.append("path").attr("d", K()).attr("stroke", B).attr("stroke-width", (e) => Math.max(1, e.width)), r(void 0, g, 0, y);
931
- }, "draw") }, pe = /* @__PURE__ */ t((e) => e.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g, "").replaceAll(/([\n\r])+/g, "\n").trim(), "prepareTextForParsing"), me = /* @__PURE__ */ t((e) => `.label {
932
- font-family: ${e.fontFamily};
933
- }
934
-
935
- .node-labels {
936
- font-family: ${e.fontFamily};
937
- }
938
-
939
- /* Outlined label style - background stroke for better readability */
940
- .sankey-label-bg {
941
- stroke: ${e.mainBkg || e.background || "#fff"};
942
- stroke-width: 4px;
943
- stroke-linejoin: round;
944
- paint-order: stroke;
945
- }
946
-
947
- /* Foreground label text */
948
- .sankey-label-fg {
949
- fill: ${e.textColor};
950
- }
951
-
952
- /* Node styling */
953
- .node rect {
954
- shape-rendering: crispEdges;
955
- }
956
-
957
- /* Link styling */
958
- .link {
959
- fill: none;
960
- stroke-opacity: 0.5;
961
- mix-blend-mode: multiply;
962
- }
963
- `, "getStyles"), he = J.parse.bind(J);
964
- J.parse = (e) => he(pe(e));
965
- var ge = {
966
- styles: me,
967
- parser: J,
968
- db: ue,
969
- renderer: fe
970
- };
971
- //#endregion
972
- export { ge as diagram };