docmedown 0.1.0 → 0.1.2

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 (233) hide show
  1. package/README.md +69 -20
  2. package/dist/abnfDiagram-VCTEODGH-CtQBp0Qv.mjs +89 -0
  3. package/dist/abnfDiagram-VCTEODGH-mccrzlD_.js +1 -0
  4. package/dist/arc-DgPKXEdT.mjs +82 -0
  5. package/dist/arc-n7TW7Bis.js +1 -0
  6. package/dist/architecture-7GRP2DOG-B7myQ46f.js +1 -0
  7. package/dist/architecture-7GRP2DOG-Cxj1ussQ.mjs +3 -0
  8. package/dist/architectureDiagram-5GKGNRK7-BdTCu5T3.js +36 -0
  9. package/dist/architectureDiagram-5GKGNRK7-CkgZa-G1.mjs +4154 -0
  10. package/dist/array-CApNbSU9.mjs +6 -0
  11. package/dist/array-DZSRzHA_.js +1 -0
  12. package/dist/blockDiagram-I7D4REHJ-CSYvpxQw.js +129 -0
  13. package/dist/blockDiagram-I7D4REHJ-CYngfPD9.mjs +1922 -0
  14. package/dist/c4Diagram-7LVT6UL2-B-sz5MUK.js +38 -0
  15. package/dist/c4Diagram-7LVT6UL2-DEzxFf2b.mjs +3010 -0
  16. package/dist/channel-LgHproiI.mjs +5 -0
  17. package/dist/channel-yqu0m4cl.js +1 -0
  18. package/dist/chunk-2E4U76K2-BOyeRQsI.js +1 -0
  19. package/dist/chunk-2E4U76K2-CoTrgtfg.mjs +348 -0
  20. package/dist/chunk-2Q5K7J3B-D4EgYPOq.mjs +15 -0
  21. package/dist/chunk-2Q5K7J3B-DhjCNjaM.js +1 -0
  22. package/dist/chunk-4HAMMTFA-GFyfmcSO.js +62 -0
  23. package/dist/chunk-4HAMMTFA-VgWPe1ng.mjs +4188 -0
  24. package/dist/chunk-5VM5RSS4-GINalzIv.js +15 -0
  25. package/dist/chunk-5VM5RSS4-TqxtqrwE.mjs +5 -0
  26. package/dist/chunk-75Z2AOVW-DYouz5MZ.js +2 -0
  27. package/dist/chunk-75Z2AOVW-Dz0Sko9Y.mjs +1330 -0
  28. package/dist/chunk-CLGD4ZFX-C5J-e2io.js +1 -0
  29. package/dist/chunk-CLGD4ZFX-DBkwyMMv.mjs +14 -0
  30. package/dist/chunk-DU6HZSFF-BEQZSmUu.mjs +3836 -0
  31. package/dist/chunk-DU6HZSFF-CWc5ewtb.js +127 -0
  32. package/dist/chunk-F27PBJKO-8jvY_jJK.js +1 -0
  33. package/dist/chunk-F27PBJKO-DFH3sRZG.mjs +61 -0
  34. package/dist/chunk-FOHPRMQF-LRqOLsSw.mjs +21456 -0
  35. package/dist/chunk-FOHPRMQF-tmTlwTeH.js +161 -0
  36. package/dist/chunk-GMAD6QVW-BZeZ4fdb.mjs +1863 -0
  37. package/dist/chunk-GMAD6QVW-DEQiTa0c.js +72 -0
  38. package/dist/chunk-GVQU2GXP-B1D3J05J.mjs +37 -0
  39. package/dist/chunk-GVQU2GXP-CdJIWN41.js +1 -0
  40. package/dist/chunk-IMKFNOWR-BmZb9U1f.mjs +2042 -0
  41. package/dist/chunk-IMKFNOWR-CPJsszGN.js +231 -0
  42. package/dist/chunk-JWPE2WC7-DIKiF5cm.mjs +8 -0
  43. package/dist/chunk-JWPE2WC7-p1fYVdYc.js +1 -0
  44. package/dist/chunk-L3NEJ4N5-TzDiVs78.js +1 -0
  45. package/dist/chunk-L3NEJ4N5-lal8wUID.mjs +245 -0
  46. package/dist/chunk-LNGE3PJU-BQX75wkM.js +34 -0
  47. package/dist/chunk-LNGE3PJU-DJ9JuXV6.mjs +1521 -0
  48. package/dist/chunk-OSK3NFVY-9AWK88m1.mjs +672 -0
  49. package/dist/chunk-OSK3NFVY-CHzvVe8m.js +10 -0
  50. package/dist/chunk-P2QGCYS3-6q3AXPt5.mjs +67 -0
  51. package/dist/chunk-P2QGCYS3-DKZzpRQW.js +1 -0
  52. package/dist/chunk-POPQ4Y6H-Dd7J9tx3.mjs +26 -0
  53. package/dist/chunk-POPQ4Y6H-T5C7wpjf.js +1 -0
  54. package/dist/chunk-PWAF6VOD-BYG76tEe.mjs +275 -0
  55. package/dist/chunk-PWAF6VOD-DxZLuCEw.js +1 -0
  56. package/dist/chunk-SHT3W25Y-B2Wes8jn.mjs +4183 -0
  57. package/dist/chunk-SHT3W25Y-BQjHSn5K.js +168 -0
  58. package/dist/chunk-SVP7TREG-BFMd615E.js +88 -0
  59. package/dist/chunk-SVP7TREG-CynckzeF.mjs +490 -0
  60. package/dist/chunk-TICWLB2K-BfCuoR1V.mjs +3357 -0
  61. package/dist/chunk-TICWLB2K-agcyBfUp.js +206 -0
  62. package/dist/chunk-TLUHSLCS-CUrWaKDG.mjs +59 -0
  63. package/dist/chunk-TLUHSLCS-Drx_a7am.js +1 -0
  64. package/dist/chunk-XXDRQBXY-AAk1-Cyg.js +1 -0
  65. package/dist/chunk-XXDRQBXY-DpR8eYzz.mjs +9 -0
  66. package/dist/chunk-Y2CYZVJY-CnmLqFtv.js +1 -0
  67. package/dist/chunk-Y2CYZVJY-i11wjrBe.mjs +12 -0
  68. package/dist/classDiagram-ZZMXUADV-B7IN9zcX.js +1 -0
  69. package/dist/classDiagram-ZZMXUADV-tcy6gxSB.mjs +30 -0
  70. package/dist/classDiagram-v2-VYDZK3BY-B7IN9zcX.js +1 -0
  71. package/dist/classDiagram-v2-VYDZK3BY-D5wM6Acp.mjs +30 -0
  72. package/dist/cli.js +719 -532
  73. package/dist/cose-bilkent-JH36ORCC-DBUPO3qJ.js +1 -0
  74. package/dist/cose-bilkent-JH36ORCC-Slpx4WIt.mjs +2253 -0
  75. package/dist/cynefin-OW5HDTMX--QVnfGi1.mjs +3 -0
  76. package/dist/cynefin-OW5HDTMX-lNKysi7S.js +1 -0
  77. package/dist/cynefinDiagram-5FMLGOSQ-CsFONYqx.js +62 -0
  78. package/dist/cynefinDiagram-5FMLGOSQ-DsrxYBcg.mjs +355 -0
  79. package/dist/cytoscape.esm-C5TvPYYm.mjs +18148 -0
  80. package/dist/cytoscape.esm-CBmWJr5M.js +321 -0
  81. package/dist/dagre-CZ6P9L_h.js +1 -0
  82. package/dist/dagre-GXQ25YYZ-CQszk-7P.js +4 -0
  83. package/dist/dagre-GXQ25YYZ-ecYByRSn.mjs +425 -0
  84. package/dist/dagre-J_1oH0eY.mjs +1934 -0
  85. package/dist/defaultLocale-N-0uLSyg.mjs +198 -0
  86. package/dist/defaultLocale-ybN1Vtvg.js +1 -0
  87. package/dist/diagram-S7CK7UJ4-CTMvxX__.js +30 -0
  88. package/dist/diagram-S7CK7UJ4-DxCghfa-.mjs +301 -0
  89. package/dist/diagram-UQ7AKVKN-1viEkqlG.js +41 -0
  90. package/dist/diagram-UQ7AKVKN-BA7Z_oB7.mjs +214 -0
  91. package/dist/diagram-VSXAHHWV-DgVT19mq.js +3 -0
  92. package/dist/diagram-VSXAHHWV-Dtqo03M5.mjs +432 -0
  93. package/dist/diagram-VX7I27RA-CNw0pOX_.js +24 -0
  94. package/dist/diagram-VX7I27RA-GMPRt8Zh.mjs +527 -0
  95. package/dist/diagram-Z3DM3KII-C6XdQK_Q.mjs +134 -0
  96. package/dist/diagram-Z3DM3KII-CPkBr3FT.js +24 -0
  97. package/dist/dist-CXWJafG_.js +1 -0
  98. package/dist/dist-DNdLIC8h.mjs +59 -0
  99. package/dist/docmedown.cjs +125 -44
  100. package/dist/docmedown.iife.js +3477 -72
  101. package/dist/docmedown.mjs +10003 -4807
  102. package/dist/ebnfDiagram-PWID7BFC-CseVsyL3.js +1 -0
  103. package/dist/ebnfDiagram-PWID7BFC-D_dBDXWC.mjs +100 -0
  104. package/dist/erDiagram-RLTQ6QDP-DFwfQTRS.js +99 -0
  105. package/dist/erDiagram-RLTQ6QDP-DP7ddGMH.mjs +1966 -0
  106. package/dist/eventmodeling-NTZA5JFV-CzxVg0l5.js +1 -0
  107. package/dist/eventmodeling-NTZA5JFV-Djsy__5n.mjs +3 -0
  108. package/dist/flowDiagram-HODETNUW-7hSJfI3W.js +1 -0
  109. package/dist/flowDiagram-HODETNUW-Dqu5Lr19.mjs +17 -0
  110. package/dist/ganttDiagram-EL5Y4UJY-KNL3tzTD.mjs +3072 -0
  111. package/dist/ganttDiagram-EL5Y4UJY-aiLqNWgi.js +292 -0
  112. package/dist/gitGraph-4MIJSDKK-DnElfqX7.js +1 -0
  113. package/dist/gitGraph-4MIJSDKK-xuKJBT2e.mjs +3 -0
  114. package/dist/gitGraphDiagram-WWUBYQGX-D4gSo_-e.js +106 -0
  115. package/dist/gitGraphDiagram-WWUBYQGX-Dooss5fG.mjs +733 -0
  116. package/dist/graphlib-BaETKKSa.js +1 -0
  117. package/dist/graphlib-XW-Jr8pF.mjs +1267 -0
  118. package/dist/info-A6RAGUB7-ClYskpn6.mjs +3 -0
  119. package/dist/info-A6RAGUB7-DDvvt-fW.js +1 -0
  120. package/dist/infoDiagram-27XIBGKW-B2-y2mdQ.mjs +20 -0
  121. package/dist/infoDiagram-27XIBGKW-DYQ9NzfL.js +2 -0
  122. package/dist/init-BJdqMO10.js +1 -0
  123. package/dist/init-CsQUQz36.mjs +13 -0
  124. package/dist/ishikawaDiagram-5VMMS53U-ULIhoYO5.js +70 -0
  125. package/dist/ishikawaDiagram-5VMMS53U-xAArNh-1.mjs +719 -0
  126. package/dist/journeyDiagram-3NMN7TZE-BBMYNZRL.js +139 -0
  127. package/dist/journeyDiagram-3NMN7TZE-BH-uKqP7.mjs +884 -0
  128. package/dist/kanban-definition-UXKFOSKX-Be49llXr.mjs +976 -0
  129. package/dist/kanban-definition-UXKFOSKX-CDL5yJkq.js +89 -0
  130. package/dist/line-BEwhHSLl.js +1 -0
  131. package/dist/line-CiXRog8O.mjs +34 -0
  132. package/dist/linear-75tfjrny.js +1 -0
  133. package/dist/linear-Ncx_RuON.mjs +288 -0
  134. package/dist/mermaid-parser.core-BBApyu_y.js +6 -0
  135. package/dist/mermaid-parser.core-BRHibdUE.mjs +638 -0
  136. package/dist/mindmap-definition-YA3MSWOX-Chy7XP_5.mjs +1006 -0
  137. package/dist/mindmap-definition-YA3MSWOX-DOda-fkL.js +96 -0
  138. package/dist/ordinal-B1BNQwUR.mjs +65 -0
  139. package/dist/ordinal-B9aFWmF9.js +1 -0
  140. package/dist/packet-AYTQ26CC-CorIy9Ul.js +1 -0
  141. package/dist/packet-AYTQ26CC-DWH8gXJK.mjs +3 -0
  142. package/dist/path-CnWkkRiY.mjs +84 -0
  143. package/dist/path-DIS6ck99.js +1 -0
  144. package/dist/pegDiagram-XKGWAZYB-Cdw6MeON.js +1 -0
  145. package/dist/pegDiagram-XKGWAZYB-uNfxRaq1.mjs +94 -0
  146. package/dist/pie-WAS4IAKB-Cn5eK-5P.mjs +3 -0
  147. package/dist/pie-WAS4IAKB-D84xrSoY.js +1 -0
  148. package/dist/pieDiagram-E7YTZNPT-Bd6mvpJw.js +39 -0
  149. package/dist/pieDiagram-E7YTZNPT-Cczo96a2.mjs +203 -0
  150. package/dist/quadrantDiagram-AXDQQJYC-BPfgvMsS.js +7 -0
  151. package/dist/quadrantDiagram-AXDQQJYC-eqRNtVRl.mjs +2001 -0
  152. package/dist/radar-RG4KPBEZ-DvkxGdO6.mjs +3 -0
  153. package/dist/radar-RG4KPBEZ-R2sQOLL9.js +1 -0
  154. package/dist/railroad-74A4TZTK-BOZIf6ts.js +1 -0
  155. package/dist/railroad-74A4TZTK-CrQzn8Nm.mjs +3 -0
  156. package/dist/railroad-abnf-HS5TGJTU-BZYetxLz.mjs +3 -0
  157. package/dist/railroad-abnf-HS5TGJTU-CXU1aC4B.js +1 -0
  158. package/dist/railroad-ebnf-LZEXJU2U-D29kI3YW.js +1 -0
  159. package/dist/railroad-ebnf-LZEXJU2U-qgzTOmN6.mjs +3 -0
  160. package/dist/railroad-peg-WCYAUIDC-Bjs9Ws3P.mjs +3 -0
  161. package/dist/railroad-peg-WCYAUIDC-CXviP0hz.js +1 -0
  162. package/dist/railroadDiagram-O6MQD6OU-58kvwt7H.mjs +76 -0
  163. package/dist/railroadDiagram-O6MQD6OU-CKY3uzTc.js +1 -0
  164. package/dist/requirementDiagram-BXWQKSXE-0hZ04Q6h.js +84 -0
  165. package/dist/requirementDiagram-BXWQKSXE-CS673B5n.mjs +2224 -0
  166. package/dist/rough.esm-ChRLLRha.js +1 -0
  167. package/dist/rough.esm-DXYGHN3m.mjs +1361 -0
  168. package/dist/sankeyDiagram-P5KCCOFB-D1D6HfAM.mjs +972 -0
  169. package/dist/sankeyDiagram-P5KCCOFB-ciJb9Zr8.js +40 -0
  170. package/dist/sequenceDiagram-WJ2MYXX4-BXEznuI6.js +162 -0
  171. package/dist/sequenceDiagram-WJ2MYXX4-CI1VT8AG.mjs +4156 -0
  172. package/dist/sizeCapture-INFHLROL-BihkCH-7.js +1 -0
  173. package/dist/sizeCapture-INFHLROL-BmxqyOLj.mjs +46 -0
  174. package/dist/src-B4mN2BMl.js +1 -0
  175. package/dist/src-D_hsMyeP.mjs +2154 -0
  176. package/dist/stateDiagram-D77RDMKH-BQrSs72W.mjs +220 -0
  177. package/dist/stateDiagram-D77RDMKH-D2PtkW2U.js +1 -0
  178. package/dist/stateDiagram-v2-MP3YSRHH-CCbvNfk-.mjs +30 -0
  179. package/dist/stateDiagram-v2-MP3YSRHH-Dq1QuPeN.js +1 -0
  180. package/dist/swimlanes-42K2YHIH-CA316NPm.mjs +4979 -0
  181. package/dist/swimlanes-42K2YHIH-DlggBCTy.js +1 -0
  182. package/dist/swimlanesDiagram-VR7AAH4N-BV9PEIoG.js +8 -0
  183. package/dist/swimlanesDiagram-VR7AAH4N-BfrOCfdf.mjs +31 -0
  184. package/dist/timeline-definition-24CTP7MA-Bkd8rWNJ.js +120 -0
  185. package/dist/timeline-definition-24CTP7MA-BvkqNYt1.mjs +1069 -0
  186. package/dist/treeView-Q6P3EWNA-Aof3Cp1M.mjs +3 -0
  187. package/dist/treeView-Q6P3EWNA-BTzvdwbb.js +1 -0
  188. package/dist/treemap-WGGIJYW6-BNXGg99p.mjs +3 -0
  189. package/dist/treemap-WGGIJYW6-DfR4P2Hh.js +1 -0
  190. package/dist/types/runtime/app.d.ts +3 -3
  191. package/dist/types/runtime/components/AppearanceMenu.d.ts +2 -0
  192. package/dist/types/runtime/components/Builtins.d.ts +3 -3
  193. package/dist/types/runtime/components/Content.d.ts +1 -1
  194. package/dist/types/runtime/components/DmdRegistry.d.ts +4 -2
  195. package/dist/types/runtime/components/Layout.d.ts +1 -1
  196. package/dist/types/runtime/components/MermaidDiagram.d.ts +16 -0
  197. package/dist/types/runtime/components/Navbar.d.ts +1 -1
  198. package/dist/types/runtime/components/OfflineDownloadButton.d.ts +2 -0
  199. package/dist/types/runtime/components/Sidebar.d.ts +1 -1
  200. package/dist/types/runtime/components/TableOfContents.d.ts +2 -2
  201. package/dist/types/runtime/config-schema.d.ts +386 -0
  202. package/dist/types/runtime/config.d.ts +10 -3
  203. package/dist/types/runtime/index.d.ts +7 -5
  204. package/dist/types/runtime/loader/auto-indexer.d.ts +1 -1
  205. package/dist/types/runtime/loader/local-loader.d.ts +1 -1
  206. package/dist/types/runtime/loader/remote-github.d.ts +2 -2
  207. package/dist/types/runtime/loader/remote-gitlab.d.ts +2 -2
  208. package/dist/types/runtime/markdown/callouts.d.ts +1 -1
  209. package/dist/types/runtime/markdown/highlighter.d.ts +16 -16
  210. package/dist/types/runtime/markdown/mermaid.d.ts +82 -1
  211. package/dist/types/runtime/markdown/parser.d.ts +1 -1
  212. package/dist/types/runtime/markdown/renderer.d.ts +1 -1
  213. package/dist/types/runtime/offline-export.d.ts +26 -0
  214. package/dist/types/runtime/provider/DocProvider.d.ts +5 -5
  215. package/dist/types/runtime/provider/ThemeProvider.d.ts +13 -6
  216. package/dist/types/runtime/search/SearchModal.d.ts +2 -2
  217. package/dist/types/runtime/search/search-index.d.ts +1 -1
  218. package/dist/types/runtime/types.d.ts +28 -99
  219. package/dist/vennDiagram-4TSXK5OY-BOUFXjso.js +34 -0
  220. package/dist/vennDiagram-4TSXK5OY-CeOg3-hU.mjs +1880 -0
  221. package/dist/wardley-WFR3VGLG-BOYcSLd1.mjs +3 -0
  222. package/dist/wardley-WFR3VGLG-DWDqJSgm.js +1 -0
  223. package/dist/wardleyDiagram-VM6X3IG4-BhWgMjFr.js +78 -0
  224. package/dist/wardleyDiagram-VM6X3IG4-C31KoRmF.mjs +645 -0
  225. package/dist/xychartDiagram-S5SC5T6Z-1yU8zz6I.js +7 -0
  226. package/dist/xychartDiagram-S5SC5T6Z-BK7upFom.mjs +2210 -0
  227. package/package.json +15 -4
  228. package/schemas/docs.schema.json +166 -0
  229. package/templates/README.md +4 -4
  230. package/templates/docs.json +5 -2
  231. package/templates/getting-started.md +1 -1
  232. package/templates/guides/custom-components.md +2 -0
  233. package/templates/index.html +2 -4
@@ -0,0 +1,3010 @@
1
+ import { m as e, p as t } from "./src-D_hsMyeP.mjs";
2
+ import { n } from "./chunk-Y2CYZVJY-i11wjrBe.mjs";
3
+ import { H as r, U as i, c as a, r as o, s, v as l, x as u, y as d, z as f } from "./chunk-DU6HZSFF-BEQZSmUu.mjs";
4
+ import { _ as p, n as m, r as h } from "./chunk-75Z2AOVW-Dz0Sko9Y.mjs";
5
+ import "./chunk-P2QGCYS3-6q3AXPt5.mjs";
6
+ import "./chunk-PWAF6VOD-BYG76tEe.mjs";
7
+ import "./chunk-GMAD6QVW-BZeZ4fdb.mjs";
8
+ import { o as g } from "./chunk-4HAMMTFA-VgWPe1ng.mjs";
9
+ import { a as _ } from "./chunk-F27PBJKO-DFH3sRZG.mjs";
10
+ //#region node_modules/mermaid/dist/chunks/mermaid.core/c4Diagram-7LVT6UL2.mjs
11
+ var v = (function() {
12
+ var e = /* @__PURE__ */ n(function(e, t, n, r) {
13
+ for (n ||= {}, r = e.length; r--; n[e[r]] = t);
14
+ return n;
15
+ }, "o"), t = [1, 24], r = [1, 25], i = [1, 26], a = [1, 27], o = [1, 28], s = [1, 63], l = [1, 64], u = [1, 65], d = [1, 66], f = [1, 67], p = [1, 68], m = [1, 69], h = [1, 29], g = [1, 30], _ = [1, 31], v = [1, 32], y = [1, 33], b = [1, 34], x = [1, 35], S = [1, 36], C = [1, 37], w = [1, 38], T = [1, 39], E = [1, 40], D = [1, 41], O = [1, 42], k = [1, 43], A = [1, 44], j = [1, 45], M = [1, 46], N = [1, 47], P = [1, 48], F = [1, 50], I = [1, 51], L = [1, 52], R = [1, 53], z = [1, 54], B = [1, 55], V = [1, 56], H = [1, 57], U = [1, 58], W = [1, 59], G = [1, 60], ee = [14, 42], te = [
16
+ 14,
17
+ 34,
18
+ 36,
19
+ 37,
20
+ 38,
21
+ 39,
22
+ 40,
23
+ 41,
24
+ 42,
25
+ 44,
26
+ 45,
27
+ 46,
28
+ 47,
29
+ 48,
30
+ 49,
31
+ 50,
32
+ 51,
33
+ 52,
34
+ 53,
35
+ 54,
36
+ 55,
37
+ 56,
38
+ 57,
39
+ 58,
40
+ 59,
41
+ 60,
42
+ 61,
43
+ 62,
44
+ 63,
45
+ 64,
46
+ 65,
47
+ 66,
48
+ 67,
49
+ 68,
50
+ 69,
51
+ 70,
52
+ 71,
53
+ 72,
54
+ 73,
55
+ 74
56
+ ], ne = [
57
+ 12,
58
+ 14,
59
+ 34,
60
+ 36,
61
+ 37,
62
+ 38,
63
+ 39,
64
+ 40,
65
+ 41,
66
+ 42,
67
+ 44,
68
+ 45,
69
+ 46,
70
+ 47,
71
+ 48,
72
+ 49,
73
+ 50,
74
+ 51,
75
+ 52,
76
+ 53,
77
+ 54,
78
+ 55,
79
+ 56,
80
+ 57,
81
+ 58,
82
+ 59,
83
+ 60,
84
+ 61,
85
+ 62,
86
+ 63,
87
+ 64,
88
+ 65,
89
+ 66,
90
+ 67,
91
+ 68,
92
+ 69,
93
+ 70,
94
+ 71,
95
+ 72,
96
+ 73,
97
+ 74
98
+ ], K = [1, 82], q = [1, 83], J = [1, 84], Y = [1, 85], X = [
99
+ 12,
100
+ 14,
101
+ 42
102
+ ], re = [
103
+ 12,
104
+ 14,
105
+ 33,
106
+ 42
107
+ ], ie = [
108
+ 12,
109
+ 14,
110
+ 33,
111
+ 42,
112
+ 76,
113
+ 77,
114
+ 79,
115
+ 80
116
+ ], ae = [12, 33], oe = [
117
+ 34,
118
+ 36,
119
+ 37,
120
+ 38,
121
+ 39,
122
+ 40,
123
+ 41,
124
+ 44,
125
+ 45,
126
+ 46,
127
+ 47,
128
+ 48,
129
+ 49,
130
+ 50,
131
+ 51,
132
+ 52,
133
+ 53,
134
+ 54,
135
+ 55,
136
+ 56,
137
+ 57,
138
+ 58,
139
+ 59,
140
+ 60,
141
+ 61,
142
+ 62,
143
+ 63,
144
+ 64,
145
+ 65,
146
+ 66,
147
+ 67,
148
+ 68,
149
+ 69,
150
+ 70,
151
+ 71,
152
+ 72,
153
+ 73,
154
+ 74
155
+ ], se = {
156
+ trace: /* @__PURE__ */ n(function() {}, "trace"),
157
+ yy: {},
158
+ symbols_: {
159
+ error: 2,
160
+ start: 3,
161
+ mermaidDoc: 4,
162
+ direction: 5,
163
+ direction_tb: 6,
164
+ direction_bt: 7,
165
+ direction_rl: 8,
166
+ direction_lr: 9,
167
+ graphConfig: 10,
168
+ C4_CONTEXT: 11,
169
+ NEWLINE: 12,
170
+ statements: 13,
171
+ EOF: 14,
172
+ C4_CONTAINER: 15,
173
+ C4_COMPONENT: 16,
174
+ C4_DYNAMIC: 17,
175
+ C4_DEPLOYMENT: 18,
176
+ otherStatements: 19,
177
+ diagramStatements: 20,
178
+ otherStatement: 21,
179
+ title: 22,
180
+ accDescription: 23,
181
+ acc_title: 24,
182
+ acc_title_value: 25,
183
+ acc_descr: 26,
184
+ acc_descr_value: 27,
185
+ acc_descr_multiline_value: 28,
186
+ boundaryStatement: 29,
187
+ boundaryStartStatement: 30,
188
+ boundaryStopStatement: 31,
189
+ boundaryStart: 32,
190
+ LBRACE: 33,
191
+ ENTERPRISE_BOUNDARY: 34,
192
+ attributes: 35,
193
+ SYSTEM_BOUNDARY: 36,
194
+ BOUNDARY: 37,
195
+ CONTAINER_BOUNDARY: 38,
196
+ NODE: 39,
197
+ NODE_L: 40,
198
+ NODE_R: 41,
199
+ RBRACE: 42,
200
+ diagramStatement: 43,
201
+ PERSON: 44,
202
+ PERSON_EXT: 45,
203
+ SYSTEM: 46,
204
+ SYSTEM_DB: 47,
205
+ SYSTEM_QUEUE: 48,
206
+ SYSTEM_EXT: 49,
207
+ SYSTEM_EXT_DB: 50,
208
+ SYSTEM_EXT_QUEUE: 51,
209
+ CONTAINER: 52,
210
+ CONTAINER_DB: 53,
211
+ CONTAINER_QUEUE: 54,
212
+ CONTAINER_EXT: 55,
213
+ CONTAINER_EXT_DB: 56,
214
+ CONTAINER_EXT_QUEUE: 57,
215
+ COMPONENT: 58,
216
+ COMPONENT_DB: 59,
217
+ COMPONENT_QUEUE: 60,
218
+ COMPONENT_EXT: 61,
219
+ COMPONENT_EXT_DB: 62,
220
+ COMPONENT_EXT_QUEUE: 63,
221
+ REL: 64,
222
+ BIREL: 65,
223
+ REL_U: 66,
224
+ REL_D: 67,
225
+ REL_L: 68,
226
+ REL_R: 69,
227
+ REL_B: 70,
228
+ REL_INDEX: 71,
229
+ UPDATE_EL_STYLE: 72,
230
+ UPDATE_REL_STYLE: 73,
231
+ UPDATE_LAYOUT_CONFIG: 74,
232
+ attribute: 75,
233
+ STR: 76,
234
+ STR_KEY: 77,
235
+ STR_VALUE: 78,
236
+ ATTRIBUTE: 79,
237
+ ATTRIBUTE_EMPTY: 80,
238
+ $accept: 0,
239
+ $end: 1
240
+ },
241
+ terminals_: {
242
+ 2: "error",
243
+ 6: "direction_tb",
244
+ 7: "direction_bt",
245
+ 8: "direction_rl",
246
+ 9: "direction_lr",
247
+ 11: "C4_CONTEXT",
248
+ 12: "NEWLINE",
249
+ 14: "EOF",
250
+ 15: "C4_CONTAINER",
251
+ 16: "C4_COMPONENT",
252
+ 17: "C4_DYNAMIC",
253
+ 18: "C4_DEPLOYMENT",
254
+ 22: "title",
255
+ 23: "accDescription",
256
+ 24: "acc_title",
257
+ 25: "acc_title_value",
258
+ 26: "acc_descr",
259
+ 27: "acc_descr_value",
260
+ 28: "acc_descr_multiline_value",
261
+ 33: "LBRACE",
262
+ 34: "ENTERPRISE_BOUNDARY",
263
+ 36: "SYSTEM_BOUNDARY",
264
+ 37: "BOUNDARY",
265
+ 38: "CONTAINER_BOUNDARY",
266
+ 39: "NODE",
267
+ 40: "NODE_L",
268
+ 41: "NODE_R",
269
+ 42: "RBRACE",
270
+ 44: "PERSON",
271
+ 45: "PERSON_EXT",
272
+ 46: "SYSTEM",
273
+ 47: "SYSTEM_DB",
274
+ 48: "SYSTEM_QUEUE",
275
+ 49: "SYSTEM_EXT",
276
+ 50: "SYSTEM_EXT_DB",
277
+ 51: "SYSTEM_EXT_QUEUE",
278
+ 52: "CONTAINER",
279
+ 53: "CONTAINER_DB",
280
+ 54: "CONTAINER_QUEUE",
281
+ 55: "CONTAINER_EXT",
282
+ 56: "CONTAINER_EXT_DB",
283
+ 57: "CONTAINER_EXT_QUEUE",
284
+ 58: "COMPONENT",
285
+ 59: "COMPONENT_DB",
286
+ 60: "COMPONENT_QUEUE",
287
+ 61: "COMPONENT_EXT",
288
+ 62: "COMPONENT_EXT_DB",
289
+ 63: "COMPONENT_EXT_QUEUE",
290
+ 64: "REL",
291
+ 65: "BIREL",
292
+ 66: "REL_U",
293
+ 67: "REL_D",
294
+ 68: "REL_L",
295
+ 69: "REL_R",
296
+ 70: "REL_B",
297
+ 71: "REL_INDEX",
298
+ 72: "UPDATE_EL_STYLE",
299
+ 73: "UPDATE_REL_STYLE",
300
+ 74: "UPDATE_LAYOUT_CONFIG",
301
+ 76: "STR",
302
+ 77: "STR_KEY",
303
+ 78: "STR_VALUE",
304
+ 79: "ATTRIBUTE",
305
+ 80: "ATTRIBUTE_EMPTY"
306
+ },
307
+ productions_: [
308
+ 0,
309
+ [3, 1],
310
+ [3, 1],
311
+ [5, 1],
312
+ [5, 1],
313
+ [5, 1],
314
+ [5, 1],
315
+ [4, 1],
316
+ [10, 4],
317
+ [10, 4],
318
+ [10, 4],
319
+ [10, 4],
320
+ [10, 4],
321
+ [13, 1],
322
+ [13, 1],
323
+ [13, 2],
324
+ [19, 1],
325
+ [19, 2],
326
+ [19, 3],
327
+ [21, 1],
328
+ [21, 1],
329
+ [21, 2],
330
+ [21, 2],
331
+ [21, 1],
332
+ [29, 3],
333
+ [30, 3],
334
+ [30, 3],
335
+ [30, 4],
336
+ [32, 2],
337
+ [32, 2],
338
+ [32, 2],
339
+ [32, 2],
340
+ [32, 2],
341
+ [32, 2],
342
+ [32, 2],
343
+ [31, 1],
344
+ [20, 1],
345
+ [20, 2],
346
+ [20, 3],
347
+ [43, 2],
348
+ [43, 2],
349
+ [43, 2],
350
+ [43, 2],
351
+ [43, 2],
352
+ [43, 2],
353
+ [43, 2],
354
+ [43, 2],
355
+ [43, 2],
356
+ [43, 2],
357
+ [43, 2],
358
+ [43, 2],
359
+ [43, 2],
360
+ [43, 2],
361
+ [43, 2],
362
+ [43, 2],
363
+ [43, 2],
364
+ [43, 2],
365
+ [43, 2],
366
+ [43, 2],
367
+ [43, 1],
368
+ [43, 2],
369
+ [43, 2],
370
+ [43, 2],
371
+ [43, 2],
372
+ [43, 2],
373
+ [43, 2],
374
+ [43, 2],
375
+ [43, 2],
376
+ [43, 2],
377
+ [43, 2],
378
+ [43, 2],
379
+ [35, 1],
380
+ [35, 2],
381
+ [75, 1],
382
+ [75, 2],
383
+ [75, 1],
384
+ [75, 1]
385
+ ],
386
+ performAction: /* @__PURE__ */ n(function(e, t, n, r, i, a, o) {
387
+ var s = a.length - 1;
388
+ switch (i) {
389
+ case 3:
390
+ r.setDirection("TB");
391
+ break;
392
+ case 4:
393
+ r.setDirection("BT");
394
+ break;
395
+ case 5:
396
+ r.setDirection("RL");
397
+ break;
398
+ case 6:
399
+ r.setDirection("LR");
400
+ break;
401
+ case 8:
402
+ case 9:
403
+ case 10:
404
+ case 11:
405
+ case 12:
406
+ r.setC4Type(a[s - 3]);
407
+ break;
408
+ case 19:
409
+ r.setTitle(a[s].substring(6)), this.$ = a[s].substring(6);
410
+ break;
411
+ case 20:
412
+ r.setAccDescription(a[s].substring(15)), this.$ = a[s].substring(15);
413
+ break;
414
+ case 21:
415
+ this.$ = a[s].trim(), r.setTitle(this.$);
416
+ break;
417
+ case 22:
418
+ case 23:
419
+ this.$ = a[s].trim(), r.setAccDescription(this.$);
420
+ break;
421
+ case 28:
422
+ a[s].splice(2, 0, "ENTERPRISE"), r.addPersonOrSystemBoundary(...a[s]), this.$ = a[s];
423
+ break;
424
+ case 29:
425
+ a[s].splice(2, 0, "SYSTEM"), r.addPersonOrSystemBoundary(...a[s]), this.$ = a[s];
426
+ break;
427
+ case 30:
428
+ r.addPersonOrSystemBoundary(...a[s]), this.$ = a[s];
429
+ break;
430
+ case 31:
431
+ a[s].splice(2, 0, "CONTAINER"), r.addContainerBoundary(...a[s]), this.$ = a[s];
432
+ break;
433
+ case 32:
434
+ r.addDeploymentNode("node", ...a[s]), this.$ = a[s];
435
+ break;
436
+ case 33:
437
+ r.addDeploymentNode("nodeL", ...a[s]), this.$ = a[s];
438
+ break;
439
+ case 34:
440
+ r.addDeploymentNode("nodeR", ...a[s]), this.$ = a[s];
441
+ break;
442
+ case 35:
443
+ r.popBoundaryParseStack();
444
+ break;
445
+ case 39:
446
+ r.addPersonOrSystem("person", ...a[s]), this.$ = a[s];
447
+ break;
448
+ case 40:
449
+ r.addPersonOrSystem("external_person", ...a[s]), this.$ = a[s];
450
+ break;
451
+ case 41:
452
+ r.addPersonOrSystem("system", ...a[s]), this.$ = a[s];
453
+ break;
454
+ case 42:
455
+ r.addPersonOrSystem("system_db", ...a[s]), this.$ = a[s];
456
+ break;
457
+ case 43:
458
+ r.addPersonOrSystem("system_queue", ...a[s]), this.$ = a[s];
459
+ break;
460
+ case 44:
461
+ r.addPersonOrSystem("external_system", ...a[s]), this.$ = a[s];
462
+ break;
463
+ case 45:
464
+ r.addPersonOrSystem("external_system_db", ...a[s]), this.$ = a[s];
465
+ break;
466
+ case 46:
467
+ r.addPersonOrSystem("external_system_queue", ...a[s]), this.$ = a[s];
468
+ break;
469
+ case 47:
470
+ r.addContainer("container", ...a[s]), this.$ = a[s];
471
+ break;
472
+ case 48:
473
+ r.addContainer("container_db", ...a[s]), this.$ = a[s];
474
+ break;
475
+ case 49:
476
+ r.addContainer("container_queue", ...a[s]), this.$ = a[s];
477
+ break;
478
+ case 50:
479
+ r.addContainer("external_container", ...a[s]), this.$ = a[s];
480
+ break;
481
+ case 51:
482
+ r.addContainer("external_container_db", ...a[s]), this.$ = a[s];
483
+ break;
484
+ case 52:
485
+ r.addContainer("external_container_queue", ...a[s]), this.$ = a[s];
486
+ break;
487
+ case 53:
488
+ r.addComponent("component", ...a[s]), this.$ = a[s];
489
+ break;
490
+ case 54:
491
+ r.addComponent("component_db", ...a[s]), this.$ = a[s];
492
+ break;
493
+ case 55:
494
+ r.addComponent("component_queue", ...a[s]), this.$ = a[s];
495
+ break;
496
+ case 56:
497
+ r.addComponent("external_component", ...a[s]), this.$ = a[s];
498
+ break;
499
+ case 57:
500
+ r.addComponent("external_component_db", ...a[s]), this.$ = a[s];
501
+ break;
502
+ case 58:
503
+ r.addComponent("external_component_queue", ...a[s]), this.$ = a[s];
504
+ break;
505
+ case 60:
506
+ r.addRel("rel", ...a[s]), this.$ = a[s];
507
+ break;
508
+ case 61:
509
+ r.addRel("birel", ...a[s]), this.$ = a[s];
510
+ break;
511
+ case 62:
512
+ r.addRel("rel_u", ...a[s]), this.$ = a[s];
513
+ break;
514
+ case 63:
515
+ r.addRel("rel_d", ...a[s]), this.$ = a[s];
516
+ break;
517
+ case 64:
518
+ r.addRel("rel_l", ...a[s]), this.$ = a[s];
519
+ break;
520
+ case 65:
521
+ r.addRel("rel_r", ...a[s]), this.$ = a[s];
522
+ break;
523
+ case 66:
524
+ r.addRel("rel_b", ...a[s]), this.$ = a[s];
525
+ break;
526
+ case 67:
527
+ a[s].splice(0, 1), r.addRel("rel", ...a[s]), this.$ = a[s];
528
+ break;
529
+ case 68:
530
+ r.updateElStyle("update_el_style", ...a[s]), this.$ = a[s];
531
+ break;
532
+ case 69:
533
+ r.updateRelStyle("update_rel_style", ...a[s]), this.$ = a[s];
534
+ break;
535
+ case 70:
536
+ r.updateLayoutConfig("update_layout_config", ...a[s]), this.$ = a[s];
537
+ break;
538
+ case 71:
539
+ this.$ = [a[s]];
540
+ break;
541
+ case 72:
542
+ a[s].unshift(a[s - 1]), this.$ = a[s];
543
+ break;
544
+ case 73:
545
+ case 75:
546
+ this.$ = a[s].trim();
547
+ break;
548
+ case 74:
549
+ let e = {};
550
+ e[a[s - 1].trim()] = a[s].trim(), this.$ = e;
551
+ break;
552
+ case 76: this.$ = "";
553
+ }
554
+ }, "anonymous"),
555
+ table: [
556
+ {
557
+ 3: 1,
558
+ 4: 2,
559
+ 5: 3,
560
+ 6: [1, 5],
561
+ 7: [1, 6],
562
+ 8: [1, 7],
563
+ 9: [1, 8],
564
+ 10: 4,
565
+ 11: [1, 9],
566
+ 15: [1, 10],
567
+ 16: [1, 11],
568
+ 17: [1, 12],
569
+ 18: [1, 13]
570
+ },
571
+ { 1: [3] },
572
+ { 1: [2, 1] },
573
+ { 1: [2, 2] },
574
+ { 1: [2, 7] },
575
+ { 1: [2, 3] },
576
+ { 1: [2, 4] },
577
+ { 1: [2, 5] },
578
+ { 1: [2, 6] },
579
+ { 12: [1, 14] },
580
+ { 12: [1, 15] },
581
+ { 12: [1, 16] },
582
+ { 12: [1, 17] },
583
+ { 12: [1, 18] },
584
+ {
585
+ 13: 19,
586
+ 19: 20,
587
+ 20: 21,
588
+ 21: 22,
589
+ 22: t,
590
+ 23: r,
591
+ 24: i,
592
+ 26: a,
593
+ 28: o,
594
+ 29: 49,
595
+ 30: 61,
596
+ 32: 62,
597
+ 34: s,
598
+ 36: l,
599
+ 37: u,
600
+ 38: d,
601
+ 39: f,
602
+ 40: p,
603
+ 41: m,
604
+ 43: 23,
605
+ 44: h,
606
+ 45: g,
607
+ 46: _,
608
+ 47: v,
609
+ 48: y,
610
+ 49: b,
611
+ 50: x,
612
+ 51: S,
613
+ 52: C,
614
+ 53: w,
615
+ 54: T,
616
+ 55: E,
617
+ 56: D,
618
+ 57: O,
619
+ 58: k,
620
+ 59: A,
621
+ 60: j,
622
+ 61: M,
623
+ 62: N,
624
+ 63: P,
625
+ 64: F,
626
+ 65: I,
627
+ 66: L,
628
+ 67: R,
629
+ 68: z,
630
+ 69: B,
631
+ 70: V,
632
+ 71: H,
633
+ 72: U,
634
+ 73: W,
635
+ 74: G
636
+ },
637
+ {
638
+ 13: 70,
639
+ 19: 20,
640
+ 20: 21,
641
+ 21: 22,
642
+ 22: t,
643
+ 23: r,
644
+ 24: i,
645
+ 26: a,
646
+ 28: o,
647
+ 29: 49,
648
+ 30: 61,
649
+ 32: 62,
650
+ 34: s,
651
+ 36: l,
652
+ 37: u,
653
+ 38: d,
654
+ 39: f,
655
+ 40: p,
656
+ 41: m,
657
+ 43: 23,
658
+ 44: h,
659
+ 45: g,
660
+ 46: _,
661
+ 47: v,
662
+ 48: y,
663
+ 49: b,
664
+ 50: x,
665
+ 51: S,
666
+ 52: C,
667
+ 53: w,
668
+ 54: T,
669
+ 55: E,
670
+ 56: D,
671
+ 57: O,
672
+ 58: k,
673
+ 59: A,
674
+ 60: j,
675
+ 61: M,
676
+ 62: N,
677
+ 63: P,
678
+ 64: F,
679
+ 65: I,
680
+ 66: L,
681
+ 67: R,
682
+ 68: z,
683
+ 69: B,
684
+ 70: V,
685
+ 71: H,
686
+ 72: U,
687
+ 73: W,
688
+ 74: G
689
+ },
690
+ {
691
+ 13: 71,
692
+ 19: 20,
693
+ 20: 21,
694
+ 21: 22,
695
+ 22: t,
696
+ 23: r,
697
+ 24: i,
698
+ 26: a,
699
+ 28: o,
700
+ 29: 49,
701
+ 30: 61,
702
+ 32: 62,
703
+ 34: s,
704
+ 36: l,
705
+ 37: u,
706
+ 38: d,
707
+ 39: f,
708
+ 40: p,
709
+ 41: m,
710
+ 43: 23,
711
+ 44: h,
712
+ 45: g,
713
+ 46: _,
714
+ 47: v,
715
+ 48: y,
716
+ 49: b,
717
+ 50: x,
718
+ 51: S,
719
+ 52: C,
720
+ 53: w,
721
+ 54: T,
722
+ 55: E,
723
+ 56: D,
724
+ 57: O,
725
+ 58: k,
726
+ 59: A,
727
+ 60: j,
728
+ 61: M,
729
+ 62: N,
730
+ 63: P,
731
+ 64: F,
732
+ 65: I,
733
+ 66: L,
734
+ 67: R,
735
+ 68: z,
736
+ 69: B,
737
+ 70: V,
738
+ 71: H,
739
+ 72: U,
740
+ 73: W,
741
+ 74: G
742
+ },
743
+ {
744
+ 13: 72,
745
+ 19: 20,
746
+ 20: 21,
747
+ 21: 22,
748
+ 22: t,
749
+ 23: r,
750
+ 24: i,
751
+ 26: a,
752
+ 28: o,
753
+ 29: 49,
754
+ 30: 61,
755
+ 32: 62,
756
+ 34: s,
757
+ 36: l,
758
+ 37: u,
759
+ 38: d,
760
+ 39: f,
761
+ 40: p,
762
+ 41: m,
763
+ 43: 23,
764
+ 44: h,
765
+ 45: g,
766
+ 46: _,
767
+ 47: v,
768
+ 48: y,
769
+ 49: b,
770
+ 50: x,
771
+ 51: S,
772
+ 52: C,
773
+ 53: w,
774
+ 54: T,
775
+ 55: E,
776
+ 56: D,
777
+ 57: O,
778
+ 58: k,
779
+ 59: A,
780
+ 60: j,
781
+ 61: M,
782
+ 62: N,
783
+ 63: P,
784
+ 64: F,
785
+ 65: I,
786
+ 66: L,
787
+ 67: R,
788
+ 68: z,
789
+ 69: B,
790
+ 70: V,
791
+ 71: H,
792
+ 72: U,
793
+ 73: W,
794
+ 74: G
795
+ },
796
+ {
797
+ 13: 73,
798
+ 19: 20,
799
+ 20: 21,
800
+ 21: 22,
801
+ 22: t,
802
+ 23: r,
803
+ 24: i,
804
+ 26: a,
805
+ 28: o,
806
+ 29: 49,
807
+ 30: 61,
808
+ 32: 62,
809
+ 34: s,
810
+ 36: l,
811
+ 37: u,
812
+ 38: d,
813
+ 39: f,
814
+ 40: p,
815
+ 41: m,
816
+ 43: 23,
817
+ 44: h,
818
+ 45: g,
819
+ 46: _,
820
+ 47: v,
821
+ 48: y,
822
+ 49: b,
823
+ 50: x,
824
+ 51: S,
825
+ 52: C,
826
+ 53: w,
827
+ 54: T,
828
+ 55: E,
829
+ 56: D,
830
+ 57: O,
831
+ 58: k,
832
+ 59: A,
833
+ 60: j,
834
+ 61: M,
835
+ 62: N,
836
+ 63: P,
837
+ 64: F,
838
+ 65: I,
839
+ 66: L,
840
+ 67: R,
841
+ 68: z,
842
+ 69: B,
843
+ 70: V,
844
+ 71: H,
845
+ 72: U,
846
+ 73: W,
847
+ 74: G
848
+ },
849
+ { 14: [1, 74] },
850
+ e(ee, [2, 13], {
851
+ 43: 23,
852
+ 29: 49,
853
+ 30: 61,
854
+ 32: 62,
855
+ 20: 75,
856
+ 34: s,
857
+ 36: l,
858
+ 37: u,
859
+ 38: d,
860
+ 39: f,
861
+ 40: p,
862
+ 41: m,
863
+ 44: h,
864
+ 45: g,
865
+ 46: _,
866
+ 47: v,
867
+ 48: y,
868
+ 49: b,
869
+ 50: x,
870
+ 51: S,
871
+ 52: C,
872
+ 53: w,
873
+ 54: T,
874
+ 55: E,
875
+ 56: D,
876
+ 57: O,
877
+ 58: k,
878
+ 59: A,
879
+ 60: j,
880
+ 61: M,
881
+ 62: N,
882
+ 63: P,
883
+ 64: F,
884
+ 65: I,
885
+ 66: L,
886
+ 67: R,
887
+ 68: z,
888
+ 69: B,
889
+ 70: V,
890
+ 71: H,
891
+ 72: U,
892
+ 73: W,
893
+ 74: G
894
+ }),
895
+ e(ee, [2, 14]),
896
+ e(te, [2, 16], { 12: [1, 76] }),
897
+ e(ee, [2, 36], { 12: [1, 77] }),
898
+ e(ne, [2, 19]),
899
+ e(ne, [2, 20]),
900
+ { 25: [1, 78] },
901
+ { 27: [1, 79] },
902
+ e(ne, [2, 23]),
903
+ {
904
+ 35: 80,
905
+ 75: 81,
906
+ 76: K,
907
+ 77: q,
908
+ 79: J,
909
+ 80: Y
910
+ },
911
+ {
912
+ 35: 86,
913
+ 75: 81,
914
+ 76: K,
915
+ 77: q,
916
+ 79: J,
917
+ 80: Y
918
+ },
919
+ {
920
+ 35: 87,
921
+ 75: 81,
922
+ 76: K,
923
+ 77: q,
924
+ 79: J,
925
+ 80: Y
926
+ },
927
+ {
928
+ 35: 88,
929
+ 75: 81,
930
+ 76: K,
931
+ 77: q,
932
+ 79: J,
933
+ 80: Y
934
+ },
935
+ {
936
+ 35: 89,
937
+ 75: 81,
938
+ 76: K,
939
+ 77: q,
940
+ 79: J,
941
+ 80: Y
942
+ },
943
+ {
944
+ 35: 90,
945
+ 75: 81,
946
+ 76: K,
947
+ 77: q,
948
+ 79: J,
949
+ 80: Y
950
+ },
951
+ {
952
+ 35: 91,
953
+ 75: 81,
954
+ 76: K,
955
+ 77: q,
956
+ 79: J,
957
+ 80: Y
958
+ },
959
+ {
960
+ 35: 92,
961
+ 75: 81,
962
+ 76: K,
963
+ 77: q,
964
+ 79: J,
965
+ 80: Y
966
+ },
967
+ {
968
+ 35: 93,
969
+ 75: 81,
970
+ 76: K,
971
+ 77: q,
972
+ 79: J,
973
+ 80: Y
974
+ },
975
+ {
976
+ 35: 94,
977
+ 75: 81,
978
+ 76: K,
979
+ 77: q,
980
+ 79: J,
981
+ 80: Y
982
+ },
983
+ {
984
+ 35: 95,
985
+ 75: 81,
986
+ 76: K,
987
+ 77: q,
988
+ 79: J,
989
+ 80: Y
990
+ },
991
+ {
992
+ 35: 96,
993
+ 75: 81,
994
+ 76: K,
995
+ 77: q,
996
+ 79: J,
997
+ 80: Y
998
+ },
999
+ {
1000
+ 35: 97,
1001
+ 75: 81,
1002
+ 76: K,
1003
+ 77: q,
1004
+ 79: J,
1005
+ 80: Y
1006
+ },
1007
+ {
1008
+ 35: 98,
1009
+ 75: 81,
1010
+ 76: K,
1011
+ 77: q,
1012
+ 79: J,
1013
+ 80: Y
1014
+ },
1015
+ {
1016
+ 35: 99,
1017
+ 75: 81,
1018
+ 76: K,
1019
+ 77: q,
1020
+ 79: J,
1021
+ 80: Y
1022
+ },
1023
+ {
1024
+ 35: 100,
1025
+ 75: 81,
1026
+ 76: K,
1027
+ 77: q,
1028
+ 79: J,
1029
+ 80: Y
1030
+ },
1031
+ {
1032
+ 35: 101,
1033
+ 75: 81,
1034
+ 76: K,
1035
+ 77: q,
1036
+ 79: J,
1037
+ 80: Y
1038
+ },
1039
+ {
1040
+ 35: 102,
1041
+ 75: 81,
1042
+ 76: K,
1043
+ 77: q,
1044
+ 79: J,
1045
+ 80: Y
1046
+ },
1047
+ {
1048
+ 35: 103,
1049
+ 75: 81,
1050
+ 76: K,
1051
+ 77: q,
1052
+ 79: J,
1053
+ 80: Y
1054
+ },
1055
+ {
1056
+ 35: 104,
1057
+ 75: 81,
1058
+ 76: K,
1059
+ 77: q,
1060
+ 79: J,
1061
+ 80: Y
1062
+ },
1063
+ e(X, [2, 59]),
1064
+ {
1065
+ 35: 105,
1066
+ 75: 81,
1067
+ 76: K,
1068
+ 77: q,
1069
+ 79: J,
1070
+ 80: Y
1071
+ },
1072
+ {
1073
+ 35: 106,
1074
+ 75: 81,
1075
+ 76: K,
1076
+ 77: q,
1077
+ 79: J,
1078
+ 80: Y
1079
+ },
1080
+ {
1081
+ 35: 107,
1082
+ 75: 81,
1083
+ 76: K,
1084
+ 77: q,
1085
+ 79: J,
1086
+ 80: Y
1087
+ },
1088
+ {
1089
+ 35: 108,
1090
+ 75: 81,
1091
+ 76: K,
1092
+ 77: q,
1093
+ 79: J,
1094
+ 80: Y
1095
+ },
1096
+ {
1097
+ 35: 109,
1098
+ 75: 81,
1099
+ 76: K,
1100
+ 77: q,
1101
+ 79: J,
1102
+ 80: Y
1103
+ },
1104
+ {
1105
+ 35: 110,
1106
+ 75: 81,
1107
+ 76: K,
1108
+ 77: q,
1109
+ 79: J,
1110
+ 80: Y
1111
+ },
1112
+ {
1113
+ 35: 111,
1114
+ 75: 81,
1115
+ 76: K,
1116
+ 77: q,
1117
+ 79: J,
1118
+ 80: Y
1119
+ },
1120
+ {
1121
+ 35: 112,
1122
+ 75: 81,
1123
+ 76: K,
1124
+ 77: q,
1125
+ 79: J,
1126
+ 80: Y
1127
+ },
1128
+ {
1129
+ 35: 113,
1130
+ 75: 81,
1131
+ 76: K,
1132
+ 77: q,
1133
+ 79: J,
1134
+ 80: Y
1135
+ },
1136
+ {
1137
+ 35: 114,
1138
+ 75: 81,
1139
+ 76: K,
1140
+ 77: q,
1141
+ 79: J,
1142
+ 80: Y
1143
+ },
1144
+ {
1145
+ 35: 115,
1146
+ 75: 81,
1147
+ 76: K,
1148
+ 77: q,
1149
+ 79: J,
1150
+ 80: Y
1151
+ },
1152
+ {
1153
+ 20: 116,
1154
+ 29: 49,
1155
+ 30: 61,
1156
+ 32: 62,
1157
+ 34: s,
1158
+ 36: l,
1159
+ 37: u,
1160
+ 38: d,
1161
+ 39: f,
1162
+ 40: p,
1163
+ 41: m,
1164
+ 43: 23,
1165
+ 44: h,
1166
+ 45: g,
1167
+ 46: _,
1168
+ 47: v,
1169
+ 48: y,
1170
+ 49: b,
1171
+ 50: x,
1172
+ 51: S,
1173
+ 52: C,
1174
+ 53: w,
1175
+ 54: T,
1176
+ 55: E,
1177
+ 56: D,
1178
+ 57: O,
1179
+ 58: k,
1180
+ 59: A,
1181
+ 60: j,
1182
+ 61: M,
1183
+ 62: N,
1184
+ 63: P,
1185
+ 64: F,
1186
+ 65: I,
1187
+ 66: L,
1188
+ 67: R,
1189
+ 68: z,
1190
+ 69: B,
1191
+ 70: V,
1192
+ 71: H,
1193
+ 72: U,
1194
+ 73: W,
1195
+ 74: G
1196
+ },
1197
+ {
1198
+ 12: [1, 118],
1199
+ 33: [1, 117]
1200
+ },
1201
+ {
1202
+ 35: 119,
1203
+ 75: 81,
1204
+ 76: K,
1205
+ 77: q,
1206
+ 79: J,
1207
+ 80: Y
1208
+ },
1209
+ {
1210
+ 35: 120,
1211
+ 75: 81,
1212
+ 76: K,
1213
+ 77: q,
1214
+ 79: J,
1215
+ 80: Y
1216
+ },
1217
+ {
1218
+ 35: 121,
1219
+ 75: 81,
1220
+ 76: K,
1221
+ 77: q,
1222
+ 79: J,
1223
+ 80: Y
1224
+ },
1225
+ {
1226
+ 35: 122,
1227
+ 75: 81,
1228
+ 76: K,
1229
+ 77: q,
1230
+ 79: J,
1231
+ 80: Y
1232
+ },
1233
+ {
1234
+ 35: 123,
1235
+ 75: 81,
1236
+ 76: K,
1237
+ 77: q,
1238
+ 79: J,
1239
+ 80: Y
1240
+ },
1241
+ {
1242
+ 35: 124,
1243
+ 75: 81,
1244
+ 76: K,
1245
+ 77: q,
1246
+ 79: J,
1247
+ 80: Y
1248
+ },
1249
+ {
1250
+ 35: 125,
1251
+ 75: 81,
1252
+ 76: K,
1253
+ 77: q,
1254
+ 79: J,
1255
+ 80: Y
1256
+ },
1257
+ { 14: [1, 126] },
1258
+ { 14: [1, 127] },
1259
+ { 14: [1, 128] },
1260
+ { 14: [1, 129] },
1261
+ { 1: [2, 8] },
1262
+ e(ee, [2, 15]),
1263
+ e(te, [2, 17], {
1264
+ 21: 22,
1265
+ 19: 130,
1266
+ 22: t,
1267
+ 23: r,
1268
+ 24: i,
1269
+ 26: a,
1270
+ 28: o
1271
+ }),
1272
+ e(ee, [2, 37], {
1273
+ 19: 20,
1274
+ 20: 21,
1275
+ 21: 22,
1276
+ 43: 23,
1277
+ 29: 49,
1278
+ 30: 61,
1279
+ 32: 62,
1280
+ 13: 131,
1281
+ 22: t,
1282
+ 23: r,
1283
+ 24: i,
1284
+ 26: a,
1285
+ 28: o,
1286
+ 34: s,
1287
+ 36: l,
1288
+ 37: u,
1289
+ 38: d,
1290
+ 39: f,
1291
+ 40: p,
1292
+ 41: m,
1293
+ 44: h,
1294
+ 45: g,
1295
+ 46: _,
1296
+ 47: v,
1297
+ 48: y,
1298
+ 49: b,
1299
+ 50: x,
1300
+ 51: S,
1301
+ 52: C,
1302
+ 53: w,
1303
+ 54: T,
1304
+ 55: E,
1305
+ 56: D,
1306
+ 57: O,
1307
+ 58: k,
1308
+ 59: A,
1309
+ 60: j,
1310
+ 61: M,
1311
+ 62: N,
1312
+ 63: P,
1313
+ 64: F,
1314
+ 65: I,
1315
+ 66: L,
1316
+ 67: R,
1317
+ 68: z,
1318
+ 69: B,
1319
+ 70: V,
1320
+ 71: H,
1321
+ 72: U,
1322
+ 73: W,
1323
+ 74: G
1324
+ }),
1325
+ e(ne, [2, 21]),
1326
+ e(ne, [2, 22]),
1327
+ e(X, [2, 39]),
1328
+ e(re, [2, 71], {
1329
+ 75: 81,
1330
+ 35: 132,
1331
+ 76: K,
1332
+ 77: q,
1333
+ 79: J,
1334
+ 80: Y
1335
+ }),
1336
+ e(ie, [2, 73]),
1337
+ { 78: [1, 133] },
1338
+ e(ie, [2, 75]),
1339
+ e(ie, [2, 76]),
1340
+ e(X, [2, 40]),
1341
+ e(X, [2, 41]),
1342
+ e(X, [2, 42]),
1343
+ e(X, [2, 43]),
1344
+ e(X, [2, 44]),
1345
+ e(X, [2, 45]),
1346
+ e(X, [2, 46]),
1347
+ e(X, [2, 47]),
1348
+ e(X, [2, 48]),
1349
+ e(X, [2, 49]),
1350
+ e(X, [2, 50]),
1351
+ e(X, [2, 51]),
1352
+ e(X, [2, 52]),
1353
+ e(X, [2, 53]),
1354
+ e(X, [2, 54]),
1355
+ e(X, [2, 55]),
1356
+ e(X, [2, 56]),
1357
+ e(X, [2, 57]),
1358
+ e(X, [2, 58]),
1359
+ e(X, [2, 60]),
1360
+ e(X, [2, 61]),
1361
+ e(X, [2, 62]),
1362
+ e(X, [2, 63]),
1363
+ e(X, [2, 64]),
1364
+ e(X, [2, 65]),
1365
+ e(X, [2, 66]),
1366
+ e(X, [2, 67]),
1367
+ e(X, [2, 68]),
1368
+ e(X, [2, 69]),
1369
+ e(X, [2, 70]),
1370
+ {
1371
+ 31: 134,
1372
+ 42: [1, 135]
1373
+ },
1374
+ { 12: [1, 136] },
1375
+ { 33: [1, 137] },
1376
+ e(ae, [2, 28]),
1377
+ e(ae, [2, 29]),
1378
+ e(ae, [2, 30]),
1379
+ e(ae, [2, 31]),
1380
+ e(ae, [2, 32]),
1381
+ e(ae, [2, 33]),
1382
+ e(ae, [2, 34]),
1383
+ { 1: [2, 9] },
1384
+ { 1: [2, 10] },
1385
+ { 1: [2, 11] },
1386
+ { 1: [2, 12] },
1387
+ e(te, [2, 18]),
1388
+ e(ee, [2, 38]),
1389
+ e(re, [2, 72]),
1390
+ e(ie, [2, 74]),
1391
+ e(X, [2, 24]),
1392
+ e(X, [2, 35]),
1393
+ e(oe, [2, 25]),
1394
+ e(oe, [2, 26], { 12: [1, 138] }),
1395
+ e(oe, [2, 27])
1396
+ ],
1397
+ defaultActions: {
1398
+ 2: [2, 1],
1399
+ 3: [2, 2],
1400
+ 4: [2, 7],
1401
+ 5: [2, 3],
1402
+ 6: [2, 4],
1403
+ 7: [2, 5],
1404
+ 8: [2, 6],
1405
+ 74: [2, 8],
1406
+ 126: [2, 9],
1407
+ 127: [2, 10],
1408
+ 128: [2, 11],
1409
+ 129: [2, 12]
1410
+ },
1411
+ parseError: /* @__PURE__ */ n(function(e, t) {
1412
+ if (t.recoverable) this.trace(e);
1413
+ else {
1414
+ var n = Error(e);
1415
+ throw n.hash = t, n;
1416
+ }
1417
+ }, "parseError"),
1418
+ parse: /* @__PURE__ */ n(function(e) {
1419
+ var t = this, r = [0], i = [], a = [null], o = [], s = this.table, l = "", u = 0, d = 0, f = 0, p = 2, m = 1, h = o.slice.call(arguments, 1), g = Object.create(this.lexer), _ = { yy: {} };
1420
+ for (var v in this.yy) Object.prototype.hasOwnProperty.call(this.yy, v) && (_.yy[v] = this.yy[v]);
1421
+ g.setInput(e, _.yy), _.yy.lexer = g, _.yy.parser = this, g.yylloc === void 0 && (g.yylloc = {});
1422
+ var y = g.yylloc;
1423
+ o.push(y);
1424
+ var b = g.options && g.options.ranges;
1425
+ this.parseError = typeof _.yy.parseError == "function" ? _.yy.parseError : Object.getPrototypeOf(this).parseError;
1426
+ function x(e) {
1427
+ r.length -= 2 * e, a.length -= e, o.length -= e;
1428
+ }
1429
+ n(x, "popStack");
1430
+ function S() {
1431
+ var e = i.pop() || g.lex() || m;
1432
+ return typeof e != "number" && (e instanceof Array && (i = e, e = i.pop()), e = t.symbols_[e] || e), e;
1433
+ }
1434
+ n(S, "lex");
1435
+ for (var C, w, T, E, D, O = {}, k, A, j, M;;) {
1436
+ if (T = r[r.length - 1], this.defaultActions[T] ? E = this.defaultActions[T] : (C ??= S(), E = s[T] && s[T][C]), E === void 0 || !E.length || !E[0]) {
1437
+ var N = "";
1438
+ for (k in M = [], s[T]) this.terminals_[k] && k > p && M.push("'" + this.terminals_[k] + "'");
1439
+ N = g.showPosition ? "Parse error on line " + (u + 1) + ":\n" + g.showPosition() + "\nExpecting " + M.join(", ") + ", got '" + (this.terminals_[C] || C) + "'" : "Parse error on line " + (u + 1) + ": Unexpected " + (C == m ? "end of input" : "'" + (this.terminals_[C] || C) + "'"), this.parseError(N, {
1440
+ text: g.match,
1441
+ token: this.terminals_[C] || C,
1442
+ line: g.yylineno,
1443
+ loc: y,
1444
+ expected: M
1445
+ });
1446
+ }
1447
+ if (E[0] instanceof Array && E.length > 1) throw Error("Parse Error: multiple actions possible at state: " + T + ", token: " + C);
1448
+ switch (E[0]) {
1449
+ case 1:
1450
+ r.push(C), a.push(g.yytext), o.push(g.yylloc), r.push(E[1]), C = null, w ? (C = w, w = null) : (d = g.yyleng, l = g.yytext, u = g.yylineno, y = g.yylloc, f > 0 && f--);
1451
+ break;
1452
+ case 2:
1453
+ if (A = this.productions_[E[1]][1], O.$ = a[a.length - A], O._$ = {
1454
+ first_line: o[o.length - (A || 1)].first_line,
1455
+ last_line: o[o.length - 1].last_line,
1456
+ first_column: o[o.length - (A || 1)].first_column,
1457
+ last_column: o[o.length - 1].last_column
1458
+ }, b && (O._$.range = [o[o.length - (A || 1)].range[0], o[o.length - 1].range[1]]), D = this.performAction.apply(O, [
1459
+ l,
1460
+ d,
1461
+ u,
1462
+ _.yy,
1463
+ E[1],
1464
+ a,
1465
+ o
1466
+ ].concat(h)), D !== void 0) return D;
1467
+ A && (r = r.slice(0, -1 * A * 2), a = a.slice(0, -1 * A), o = o.slice(0, -1 * A)), r.push(this.productions_[E[1]][0]), a.push(O.$), o.push(O._$), j = s[r[r.length - 2]][r[r.length - 1]], r.push(j);
1468
+ break;
1469
+ case 3: return !0;
1470
+ }
1471
+ }
1472
+ return !0;
1473
+ }, "parse")
1474
+ };
1475
+ se.lexer = /* @__PURE__ */ (function() {
1476
+ return {
1477
+ EOF: 1,
1478
+ parseError: /* @__PURE__ */ n(function(e, t) {
1479
+ if (this.yy.parser) this.yy.parser.parseError(e, t);
1480
+ else throw Error(e);
1481
+ }, "parseError"),
1482
+ setInput: /* @__PURE__ */ n(function(e, t) {
1483
+ 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 = {
1484
+ first_line: 1,
1485
+ first_column: 0,
1486
+ last_line: 1,
1487
+ last_column: 0
1488
+ }, this.options.ranges && (this.yylloc.range = [0, 0]), this.offset = 0, this;
1489
+ }, "setInput"),
1490
+ input: /* @__PURE__ */ n(function() {
1491
+ var e = this._input[0];
1492
+ 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;
1493
+ }, "input"),
1494
+ unput: /* @__PURE__ */ n(function(e) {
1495
+ var t = e.length, n = e.split(/(?:\r\n?|\n)/g);
1496
+ this._input = e + this._input, this.yytext = this.yytext.substr(0, this.yytext.length - t), this.offset -= t;
1497
+ var r = this.match.split(/(?:\r\n?|\n)/g);
1498
+ 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);
1499
+ var i = this.yylloc.range;
1500
+ return this.yylloc = {
1501
+ first_line: this.yylloc.first_line,
1502
+ last_line: this.yylineno + 1,
1503
+ first_column: this.yylloc.first_column,
1504
+ 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
1505
+ }, this.options.ranges && (this.yylloc.range = [i[0], i[0] + this.yyleng - t]), this.yyleng = this.yytext.length, this;
1506
+ }, "unput"),
1507
+ more: /* @__PURE__ */ n(function() {
1508
+ return this._more = !0, this;
1509
+ }, "more"),
1510
+ reject: /* @__PURE__ */ n(function() {
1511
+ if (this.options.backtrack_lexer) this._backtrack = !0;
1512
+ 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(), {
1513
+ text: "",
1514
+ token: null,
1515
+ line: this.yylineno
1516
+ });
1517
+ return this;
1518
+ }, "reject"),
1519
+ less: /* @__PURE__ */ n(function(e) {
1520
+ this.unput(this.match.slice(e));
1521
+ }, "less"),
1522
+ pastInput: /* @__PURE__ */ n(function() {
1523
+ var e = this.matched.substr(0, this.matched.length - this.match.length);
1524
+ return (e.length > 20 ? "..." : "") + e.substr(-20).replace(/\n/g, "");
1525
+ }, "pastInput"),
1526
+ upcomingInput: /* @__PURE__ */ n(function() {
1527
+ var e = this.match;
1528
+ return e.length < 20 && (e += this._input.substr(0, 20 - e.length)), (e.substr(0, 20) + (e.length > 20 ? "..." : "")).replace(/\n/g, "");
1529
+ }, "upcomingInput"),
1530
+ showPosition: /* @__PURE__ */ n(function() {
1531
+ var e = this.pastInput(), t = Array(e.length + 1).join("-");
1532
+ return e + this.upcomingInput() + "\n" + t + "^";
1533
+ }, "showPosition"),
1534
+ test_match: /* @__PURE__ */ n(function(e, t) {
1535
+ var n, r, i;
1536
+ if (this.options.backtrack_lexer && (i = {
1537
+ yylineno: this.yylineno,
1538
+ yylloc: {
1539
+ first_line: this.yylloc.first_line,
1540
+ last_line: this.last_line,
1541
+ first_column: this.yylloc.first_column,
1542
+ last_column: this.yylloc.last_column
1543
+ },
1544
+ yytext: this.yytext,
1545
+ match: this.match,
1546
+ matches: this.matches,
1547
+ matched: this.matched,
1548
+ yyleng: this.yyleng,
1549
+ offset: this.offset,
1550
+ _more: this._more,
1551
+ _input: this._input,
1552
+ yy: this.yy,
1553
+ conditionStack: this.conditionStack.slice(0),
1554
+ done: this.done
1555
+ }, 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 = {
1556
+ first_line: this.yylloc.last_line,
1557
+ last_line: this.yylineno + 1,
1558
+ first_column: this.yylloc.last_column,
1559
+ last_column: r ? r[r.length - 1].length - r[r.length - 1].match(/\r?\n?/)[0].length : this.yylloc.last_column + e[0].length
1560
+ }, 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;
1561
+ if (this._backtrack) {
1562
+ for (var a in i) this[a] = i[a];
1563
+ return !1;
1564
+ }
1565
+ return !1;
1566
+ }, "test_match"),
1567
+ next: /* @__PURE__ */ n(function() {
1568
+ if (this.done) return this.EOF;
1569
+ this._input || (this.done = !0);
1570
+ var e, t, n, r;
1571
+ this._more || (this.yytext = "", this.match = "");
1572
+ 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)) {
1573
+ if (t = n, r = a, this.options.backtrack_lexer) {
1574
+ if (e = this.test_match(n, i[a]), e !== !1) return e;
1575
+ if (this._backtrack) {
1576
+ t = !1;
1577
+ continue;
1578
+ }
1579
+ return !1;
1580
+ }
1581
+ if (!this.options.flex) break;
1582
+ }
1583
+ 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(), {
1584
+ text: "",
1585
+ token: null,
1586
+ line: this.yylineno
1587
+ });
1588
+ }, "next"),
1589
+ lex: /* @__PURE__ */ n(function() {
1590
+ return this.next() || this.lex();
1591
+ }, "lex"),
1592
+ begin: /* @__PURE__ */ n(function(e) {
1593
+ this.conditionStack.push(e);
1594
+ }, "begin"),
1595
+ popState: /* @__PURE__ */ n(function() {
1596
+ return this.conditionStack.length - 1 > 0 ? this.conditionStack.pop() : this.conditionStack[0];
1597
+ }, "popState"),
1598
+ _currentRules: /* @__PURE__ */ n(function() {
1599
+ return this.conditionStack.length && this.conditionStack[this.conditionStack.length - 1] ? this.conditions[this.conditionStack[this.conditionStack.length - 1]].rules : this.conditions.INITIAL.rules;
1600
+ }, "_currentRules"),
1601
+ topState: /* @__PURE__ */ n(function(e) {
1602
+ return e = this.conditionStack.length - 1 - Math.abs(e || 0), e >= 0 ? this.conditionStack[e] : "INITIAL";
1603
+ }, "topState"),
1604
+ pushState: /* @__PURE__ */ n(function(e) {
1605
+ this.begin(e);
1606
+ }, "pushState"),
1607
+ stateStackSize: /* @__PURE__ */ n(function() {
1608
+ return this.conditionStack.length;
1609
+ }, "stateStackSize"),
1610
+ options: {},
1611
+ performAction: /* @__PURE__ */ n(function(e, t, n, r) {
1612
+ switch (n) {
1613
+ case 0: return 6;
1614
+ case 1: return 7;
1615
+ case 2: return 8;
1616
+ case 3: return 9;
1617
+ case 4: return 22;
1618
+ case 5: return 23;
1619
+ case 6: return this.begin("acc_title"), 24;
1620
+ case 7: return this.popState(), "acc_title_value";
1621
+ case 8: return this.begin("acc_descr"), 26;
1622
+ case 9: return this.popState(), "acc_descr_value";
1623
+ case 10:
1624
+ this.begin("acc_descr_multiline");
1625
+ break;
1626
+ case 11:
1627
+ this.popState();
1628
+ break;
1629
+ case 12: return "acc_descr_multiline_value";
1630
+ case 13: break;
1631
+ case 14:
1632
+ c;
1633
+ break;
1634
+ case 15: return 12;
1635
+ case 16: break;
1636
+ case 17: return 11;
1637
+ case 18: return 15;
1638
+ case 19: return 16;
1639
+ case 20: return 17;
1640
+ case 21: return 18;
1641
+ case 22: return this.begin("person_ext"), 45;
1642
+ case 23: return this.begin("person"), 44;
1643
+ case 24: return this.begin("system_ext_queue"), 51;
1644
+ case 25: return this.begin("system_ext_db"), 50;
1645
+ case 26: return this.begin("system_ext"), 49;
1646
+ case 27: return this.begin("system_queue"), 48;
1647
+ case 28: return this.begin("system_db"), 47;
1648
+ case 29: return this.begin("system"), 46;
1649
+ case 30: return this.begin("boundary"), 37;
1650
+ case 31: return this.begin("enterprise_boundary"), 34;
1651
+ case 32: return this.begin("system_boundary"), 36;
1652
+ case 33: return this.begin("container_ext_queue"), 57;
1653
+ case 34: return this.begin("container_ext_db"), 56;
1654
+ case 35: return this.begin("container_ext"), 55;
1655
+ case 36: return this.begin("container_queue"), 54;
1656
+ case 37: return this.begin("container_db"), 53;
1657
+ case 38: return this.begin("container"), 52;
1658
+ case 39: return this.begin("container_boundary"), 38;
1659
+ case 40: return this.begin("component_ext_queue"), 63;
1660
+ case 41: return this.begin("component_ext_db"), 62;
1661
+ case 42: return this.begin("component_ext"), 61;
1662
+ case 43: return this.begin("component_queue"), 60;
1663
+ case 44: return this.begin("component_db"), 59;
1664
+ case 45: return this.begin("component"), 58;
1665
+ case 46: return this.begin("node"), 39;
1666
+ case 47: return this.begin("node"), 39;
1667
+ case 48: return this.begin("node_l"), 40;
1668
+ case 49: return this.begin("node_r"), 41;
1669
+ case 50: return this.begin("rel"), 64;
1670
+ case 51: return this.begin("birel"), 65;
1671
+ case 52: return this.begin("rel_u"), 66;
1672
+ case 53: return this.begin("rel_u"), 66;
1673
+ case 54: return this.begin("rel_d"), 67;
1674
+ case 55: return this.begin("rel_d"), 67;
1675
+ case 56: return this.begin("rel_l"), 68;
1676
+ case 57: return this.begin("rel_l"), 68;
1677
+ case 58: return this.begin("rel_r"), 69;
1678
+ case 59: return this.begin("rel_r"), 69;
1679
+ case 60: return this.begin("rel_b"), 70;
1680
+ case 61: return this.begin("rel_index"), 71;
1681
+ case 62: return this.begin("update_el_style"), 72;
1682
+ case 63: return this.begin("update_rel_style"), 73;
1683
+ case 64: return this.begin("update_layout_config"), 74;
1684
+ case 65: return "EOF_IN_STRUCT";
1685
+ case 66: return this.begin("attribute"), "ATTRIBUTE_EMPTY";
1686
+ case 67:
1687
+ this.begin("attribute");
1688
+ break;
1689
+ case 68:
1690
+ this.popState(), this.popState();
1691
+ break;
1692
+ case 69: return 80;
1693
+ case 70: break;
1694
+ case 71: return 80;
1695
+ case 72:
1696
+ this.begin("string");
1697
+ break;
1698
+ case 73:
1699
+ this.popState();
1700
+ break;
1701
+ case 74: return "STR";
1702
+ case 75:
1703
+ this.begin("string_kv");
1704
+ break;
1705
+ case 76: return this.begin("string_kv_key"), "STR_KEY";
1706
+ case 77:
1707
+ this.popState(), this.begin("string_kv_value");
1708
+ break;
1709
+ case 78: return "STR_VALUE";
1710
+ case 79:
1711
+ this.popState(), this.popState();
1712
+ break;
1713
+ case 80: return "STR";
1714
+ case 81: return "LBRACE";
1715
+ case 82: return "RBRACE";
1716
+ case 83: return "SPACE";
1717
+ case 84: return "EOL";
1718
+ case 85: return 14;
1719
+ }
1720
+ }, "anonymous"),
1721
+ rules: [
1722
+ /^(?:.*direction\s+TB[^\n]*)/,
1723
+ /^(?:.*direction\s+BT[^\n]*)/,
1724
+ /^(?:.*direction\s+RL[^\n]*)/,
1725
+ /^(?:.*direction\s+LR[^\n]*)/,
1726
+ /^(?:title\s[^#\n;]+)/,
1727
+ /^(?:accDescription\s[^#\n;]+)/,
1728
+ /^(?:accTitle\s*:\s*)/,
1729
+ /^(?:(?!\n||)*[^\n]*)/,
1730
+ /^(?:accDescr\s*:\s*)/,
1731
+ /^(?:(?!\n||)*[^\n]*)/,
1732
+ /^(?:accDescr\s*\{\s*)/,
1733
+ /^(?:[\}])/,
1734
+ /^(?:[^\}]*)/,
1735
+ /^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,
1736
+ /^(?:%%[^\n]*(\r?\n)*)/,
1737
+ /^(?:\s*(\r?\n)+)/,
1738
+ /^(?:\s+)/,
1739
+ /^(?:C4Context\b)/,
1740
+ /^(?:C4Container\b)/,
1741
+ /^(?:C4Component\b)/,
1742
+ /^(?:C4Dynamic\b)/,
1743
+ /^(?:C4Deployment\b)/,
1744
+ /^(?:Person_Ext\b)/,
1745
+ /^(?:Person\b)/,
1746
+ /^(?:SystemQueue_Ext\b)/,
1747
+ /^(?:SystemDb_Ext\b)/,
1748
+ /^(?:System_Ext\b)/,
1749
+ /^(?:SystemQueue\b)/,
1750
+ /^(?:SystemDb\b)/,
1751
+ /^(?:System\b)/,
1752
+ /^(?:Boundary\b)/,
1753
+ /^(?:Enterprise_Boundary\b)/,
1754
+ /^(?:System_Boundary\b)/,
1755
+ /^(?:ContainerQueue_Ext\b)/,
1756
+ /^(?:ContainerDb_Ext\b)/,
1757
+ /^(?:Container_Ext\b)/,
1758
+ /^(?:ContainerQueue\b)/,
1759
+ /^(?:ContainerDb\b)/,
1760
+ /^(?:Container\b)/,
1761
+ /^(?:Container_Boundary\b)/,
1762
+ /^(?:ComponentQueue_Ext\b)/,
1763
+ /^(?:ComponentDb_Ext\b)/,
1764
+ /^(?:Component_Ext\b)/,
1765
+ /^(?:ComponentQueue\b)/,
1766
+ /^(?:ComponentDb\b)/,
1767
+ /^(?:Component\b)/,
1768
+ /^(?:Deployment_Node\b)/,
1769
+ /^(?:Node\b)/,
1770
+ /^(?:Node_L\b)/,
1771
+ /^(?:Node_R\b)/,
1772
+ /^(?:Rel\b)/,
1773
+ /^(?:BiRel\b)/,
1774
+ /^(?:Rel_Up\b)/,
1775
+ /^(?:Rel_U\b)/,
1776
+ /^(?:Rel_Down\b)/,
1777
+ /^(?:Rel_D\b)/,
1778
+ /^(?:Rel_Left\b)/,
1779
+ /^(?:Rel_L\b)/,
1780
+ /^(?:Rel_Right\b)/,
1781
+ /^(?:Rel_R\b)/,
1782
+ /^(?:Rel_Back\b)/,
1783
+ /^(?:RelIndex\b)/,
1784
+ /^(?:UpdateElementStyle\b)/,
1785
+ /^(?:UpdateRelStyle\b)/,
1786
+ /^(?:UpdateLayoutConfig\b)/,
1787
+ /^(?:$)/,
1788
+ /^(?:[(][ ]*[,])/,
1789
+ /^(?:[(])/,
1790
+ /^(?:[)])/,
1791
+ /^(?:,,)/,
1792
+ /^(?:,)/,
1793
+ /^(?:[ ]*["]["])/,
1794
+ /^(?:[ ]*["])/,
1795
+ /^(?:["])/,
1796
+ /^(?:[^"]*)/,
1797
+ /^(?:[ ]*[\$])/,
1798
+ /^(?:[^=]*)/,
1799
+ /^(?:[=][ ]*["])/,
1800
+ /^(?:[^"]+)/,
1801
+ /^(?:["])/,
1802
+ /^(?:[^,]+)/,
1803
+ /^(?:\{)/,
1804
+ /^(?:\})/,
1805
+ /^(?:[\s]+)/,
1806
+ /^(?:[\n\r]+)/,
1807
+ /^(?:$)/
1808
+ ],
1809
+ conditions: {
1810
+ acc_descr_multiline: {
1811
+ rules: [11, 12],
1812
+ inclusive: !1
1813
+ },
1814
+ acc_descr: {
1815
+ rules: [9],
1816
+ inclusive: !1
1817
+ },
1818
+ acc_title: {
1819
+ rules: [7],
1820
+ inclusive: !1
1821
+ },
1822
+ string_kv_value: {
1823
+ rules: [78, 79],
1824
+ inclusive: !1
1825
+ },
1826
+ string_kv_key: {
1827
+ rules: [77],
1828
+ inclusive: !1
1829
+ },
1830
+ string_kv: {
1831
+ rules: [76],
1832
+ inclusive: !1
1833
+ },
1834
+ string: {
1835
+ rules: [73, 74],
1836
+ inclusive: !1
1837
+ },
1838
+ attribute: {
1839
+ rules: [
1840
+ 68,
1841
+ 69,
1842
+ 70,
1843
+ 71,
1844
+ 72,
1845
+ 75,
1846
+ 80
1847
+ ],
1848
+ inclusive: !1
1849
+ },
1850
+ update_layout_config: {
1851
+ rules: [
1852
+ 65,
1853
+ 66,
1854
+ 67,
1855
+ 68
1856
+ ],
1857
+ inclusive: !1
1858
+ },
1859
+ update_rel_style: {
1860
+ rules: [
1861
+ 65,
1862
+ 66,
1863
+ 67,
1864
+ 68
1865
+ ],
1866
+ inclusive: !1
1867
+ },
1868
+ update_el_style: {
1869
+ rules: [
1870
+ 65,
1871
+ 66,
1872
+ 67,
1873
+ 68
1874
+ ],
1875
+ inclusive: !1
1876
+ },
1877
+ rel_b: {
1878
+ rules: [
1879
+ 65,
1880
+ 66,
1881
+ 67,
1882
+ 68
1883
+ ],
1884
+ inclusive: !1
1885
+ },
1886
+ rel_r: {
1887
+ rules: [
1888
+ 65,
1889
+ 66,
1890
+ 67,
1891
+ 68
1892
+ ],
1893
+ inclusive: !1
1894
+ },
1895
+ rel_l: {
1896
+ rules: [
1897
+ 65,
1898
+ 66,
1899
+ 67,
1900
+ 68
1901
+ ],
1902
+ inclusive: !1
1903
+ },
1904
+ rel_d: {
1905
+ rules: [
1906
+ 65,
1907
+ 66,
1908
+ 67,
1909
+ 68
1910
+ ],
1911
+ inclusive: !1
1912
+ },
1913
+ rel_u: {
1914
+ rules: [
1915
+ 65,
1916
+ 66,
1917
+ 67,
1918
+ 68
1919
+ ],
1920
+ inclusive: !1
1921
+ },
1922
+ rel_bi: {
1923
+ rules: [],
1924
+ inclusive: !1
1925
+ },
1926
+ rel: {
1927
+ rules: [
1928
+ 65,
1929
+ 66,
1930
+ 67,
1931
+ 68
1932
+ ],
1933
+ inclusive: !1
1934
+ },
1935
+ node_r: {
1936
+ rules: [
1937
+ 65,
1938
+ 66,
1939
+ 67,
1940
+ 68
1941
+ ],
1942
+ inclusive: !1
1943
+ },
1944
+ node_l: {
1945
+ rules: [
1946
+ 65,
1947
+ 66,
1948
+ 67,
1949
+ 68
1950
+ ],
1951
+ inclusive: !1
1952
+ },
1953
+ node: {
1954
+ rules: [
1955
+ 65,
1956
+ 66,
1957
+ 67,
1958
+ 68
1959
+ ],
1960
+ inclusive: !1
1961
+ },
1962
+ index: {
1963
+ rules: [],
1964
+ inclusive: !1
1965
+ },
1966
+ rel_index: {
1967
+ rules: [
1968
+ 65,
1969
+ 66,
1970
+ 67,
1971
+ 68
1972
+ ],
1973
+ inclusive: !1
1974
+ },
1975
+ component_ext_queue: {
1976
+ rules: [
1977
+ 65,
1978
+ 66,
1979
+ 67,
1980
+ 68
1981
+ ],
1982
+ inclusive: !1
1983
+ },
1984
+ component_ext_db: {
1985
+ rules: [
1986
+ 65,
1987
+ 66,
1988
+ 67,
1989
+ 68
1990
+ ],
1991
+ inclusive: !1
1992
+ },
1993
+ component_ext: {
1994
+ rules: [
1995
+ 65,
1996
+ 66,
1997
+ 67,
1998
+ 68
1999
+ ],
2000
+ inclusive: !1
2001
+ },
2002
+ component_queue: {
2003
+ rules: [
2004
+ 65,
2005
+ 66,
2006
+ 67,
2007
+ 68
2008
+ ],
2009
+ inclusive: !1
2010
+ },
2011
+ component_db: {
2012
+ rules: [
2013
+ 65,
2014
+ 66,
2015
+ 67,
2016
+ 68
2017
+ ],
2018
+ inclusive: !1
2019
+ },
2020
+ component: {
2021
+ rules: [
2022
+ 65,
2023
+ 66,
2024
+ 67,
2025
+ 68
2026
+ ],
2027
+ inclusive: !1
2028
+ },
2029
+ container_boundary: {
2030
+ rules: [
2031
+ 65,
2032
+ 66,
2033
+ 67,
2034
+ 68
2035
+ ],
2036
+ inclusive: !1
2037
+ },
2038
+ container_ext_queue: {
2039
+ rules: [
2040
+ 65,
2041
+ 66,
2042
+ 67,
2043
+ 68
2044
+ ],
2045
+ inclusive: !1
2046
+ },
2047
+ container_ext_db: {
2048
+ rules: [
2049
+ 65,
2050
+ 66,
2051
+ 67,
2052
+ 68
2053
+ ],
2054
+ inclusive: !1
2055
+ },
2056
+ container_ext: {
2057
+ rules: [
2058
+ 65,
2059
+ 66,
2060
+ 67,
2061
+ 68
2062
+ ],
2063
+ inclusive: !1
2064
+ },
2065
+ container_queue: {
2066
+ rules: [
2067
+ 65,
2068
+ 66,
2069
+ 67,
2070
+ 68
2071
+ ],
2072
+ inclusive: !1
2073
+ },
2074
+ container_db: {
2075
+ rules: [
2076
+ 65,
2077
+ 66,
2078
+ 67,
2079
+ 68
2080
+ ],
2081
+ inclusive: !1
2082
+ },
2083
+ container: {
2084
+ rules: [
2085
+ 65,
2086
+ 66,
2087
+ 67,
2088
+ 68
2089
+ ],
2090
+ inclusive: !1
2091
+ },
2092
+ birel: {
2093
+ rules: [
2094
+ 65,
2095
+ 66,
2096
+ 67,
2097
+ 68
2098
+ ],
2099
+ inclusive: !1
2100
+ },
2101
+ system_boundary: {
2102
+ rules: [
2103
+ 65,
2104
+ 66,
2105
+ 67,
2106
+ 68
2107
+ ],
2108
+ inclusive: !1
2109
+ },
2110
+ enterprise_boundary: {
2111
+ rules: [
2112
+ 65,
2113
+ 66,
2114
+ 67,
2115
+ 68
2116
+ ],
2117
+ inclusive: !1
2118
+ },
2119
+ boundary: {
2120
+ rules: [
2121
+ 65,
2122
+ 66,
2123
+ 67,
2124
+ 68
2125
+ ],
2126
+ inclusive: !1
2127
+ },
2128
+ system_ext_queue: {
2129
+ rules: [
2130
+ 65,
2131
+ 66,
2132
+ 67,
2133
+ 68
2134
+ ],
2135
+ inclusive: !1
2136
+ },
2137
+ system_ext_db: {
2138
+ rules: [
2139
+ 65,
2140
+ 66,
2141
+ 67,
2142
+ 68
2143
+ ],
2144
+ inclusive: !1
2145
+ },
2146
+ system_ext: {
2147
+ rules: [
2148
+ 65,
2149
+ 66,
2150
+ 67,
2151
+ 68
2152
+ ],
2153
+ inclusive: !1
2154
+ },
2155
+ system_queue: {
2156
+ rules: [
2157
+ 65,
2158
+ 66,
2159
+ 67,
2160
+ 68
2161
+ ],
2162
+ inclusive: !1
2163
+ },
2164
+ system_db: {
2165
+ rules: [
2166
+ 65,
2167
+ 66,
2168
+ 67,
2169
+ 68
2170
+ ],
2171
+ inclusive: !1
2172
+ },
2173
+ system: {
2174
+ rules: [
2175
+ 65,
2176
+ 66,
2177
+ 67,
2178
+ 68
2179
+ ],
2180
+ inclusive: !1
2181
+ },
2182
+ person_ext: {
2183
+ rules: [
2184
+ 65,
2185
+ 66,
2186
+ 67,
2187
+ 68
2188
+ ],
2189
+ inclusive: !1
2190
+ },
2191
+ person: {
2192
+ rules: [
2193
+ 65,
2194
+ 66,
2195
+ 67,
2196
+ 68
2197
+ ],
2198
+ inclusive: !1
2199
+ },
2200
+ INITIAL: {
2201
+ rules: [
2202
+ 0,
2203
+ 1,
2204
+ 2,
2205
+ 3,
2206
+ 4,
2207
+ 5,
2208
+ 6,
2209
+ 8,
2210
+ 10,
2211
+ 13,
2212
+ 14,
2213
+ 15,
2214
+ 16,
2215
+ 17,
2216
+ 18,
2217
+ 19,
2218
+ 20,
2219
+ 21,
2220
+ 22,
2221
+ 23,
2222
+ 24,
2223
+ 25,
2224
+ 26,
2225
+ 27,
2226
+ 28,
2227
+ 29,
2228
+ 30,
2229
+ 31,
2230
+ 32,
2231
+ 33,
2232
+ 34,
2233
+ 35,
2234
+ 36,
2235
+ 37,
2236
+ 38,
2237
+ 39,
2238
+ 40,
2239
+ 41,
2240
+ 42,
2241
+ 43,
2242
+ 44,
2243
+ 45,
2244
+ 46,
2245
+ 47,
2246
+ 48,
2247
+ 49,
2248
+ 50,
2249
+ 51,
2250
+ 52,
2251
+ 53,
2252
+ 54,
2253
+ 55,
2254
+ 56,
2255
+ 57,
2256
+ 58,
2257
+ 59,
2258
+ 60,
2259
+ 61,
2260
+ 62,
2261
+ 63,
2262
+ 64,
2263
+ 81,
2264
+ 82,
2265
+ 83,
2266
+ 84,
2267
+ 85
2268
+ ],
2269
+ inclusive: !0
2270
+ }
2271
+ }
2272
+ };
2273
+ })();
2274
+ function Z() {
2275
+ this.yy = {};
2276
+ }
2277
+ return n(Z, "Parser"), Z.prototype = se, se.Parser = Z, new Z();
2278
+ })();
2279
+ v.parser = v;
2280
+ var y = v, b = /* @__PURE__ */ n((e) => u()[e], "getRequiredConfig"), x = /* @__PURE__ */ n((e, t) => {
2281
+ for (let [n, r] of Object.entries(t)) if (r !== void 0) {
2282
+ if (typeof r == "object") {
2283
+ let [t, n] = Object.entries(r)[0];
2284
+ e[t] = n;
2285
+ } else e[n] = r;
2286
+ }
2287
+ }, "assignAttributes"), S = /* @__PURE__ */ n(() => ({
2288
+ alias: "global",
2289
+ label: { text: "global" },
2290
+ type: { text: "global" },
2291
+ tags: null,
2292
+ link: null,
2293
+ parentBoundary: ""
2294
+ }), "createGlobalBoundary"), C = [], w = [""], T = "global", E = "", D = [S()], O = [], k = "", A = !1, j = 4, M = 2, N, P = /* @__PURE__ */ n(function() {
2295
+ return N;
2296
+ }, "getC4Type"), F = /* @__PURE__ */ n(function(e) {
2297
+ N = f(e, u());
2298
+ }, "setC4Type"), I = /* @__PURE__ */ n(function(e, t, n, r, i, a, o, s, l) {
2299
+ if (e == null || t == null || n == null || r == null) return;
2300
+ let u = {}, d = O.find((e) => e.from === t && e.to === n);
2301
+ if (d ? u = d : O.push(u), u.type = e, u.from = t, u.to = n, u.label = { text: r }, i == null) u.techn = { text: "" };
2302
+ else if (typeof i == "object") {
2303
+ let [e, t] = Object.entries(i)[0];
2304
+ u[e] = { text: t };
2305
+ } else u.techn = { text: i };
2306
+ if (a == null) u.descr = { text: "" };
2307
+ else if (typeof a == "object") {
2308
+ let [e, t] = Object.entries(a)[0];
2309
+ u[e] = { text: t };
2310
+ } else u.descr = { text: a };
2311
+ x(u, {
2312
+ sprite: o,
2313
+ tags: s,
2314
+ link: l
2315
+ }), u.wrap = Z();
2316
+ }, "addRel"), L = /* @__PURE__ */ n(function(e, t, n, r, i, a, o) {
2317
+ if (t === null || n === null) return;
2318
+ let s = {}, l = C.find((e) => e.alias === t);
2319
+ if (l && t === l.alias ? s = l : (s.alias = t, C.push(s)), n == null ? s.label = { text: "" } : s.label = { text: n }, r == null) s.descr = { text: "" };
2320
+ else if (typeof r == "object") {
2321
+ let [e, t] = Object.entries(r)[0];
2322
+ s[e] = { text: t };
2323
+ } else s.descr = { text: r };
2324
+ x(s, {
2325
+ sprite: i,
2326
+ tags: a,
2327
+ link: o
2328
+ }), s.typeC4Shape = { text: e }, s.parentBoundary = T, s.wrap = Z();
2329
+ }, "addPersonOrSystem"), R = /* @__PURE__ */ n(function(e, t, n, r, i, a, o, s) {
2330
+ if (t === null || n === null) return;
2331
+ let l = {}, u = C.find((e) => e.alias === t);
2332
+ if (u && t === u.alias ? l = u : (l.alias = t, C.push(l)), n == null ? l.label = { text: "" } : l.label = { text: n }, r == null) l.techn = { text: "" };
2333
+ else if (typeof r == "object") {
2334
+ let [e, t] = Object.entries(r)[0];
2335
+ l[e] = { text: t };
2336
+ } else l.techn = { text: r };
2337
+ if (i == null) l.descr = { text: "" };
2338
+ else if (typeof i == "object") {
2339
+ let [e, t] = Object.entries(i)[0];
2340
+ l[e] = { text: t };
2341
+ } else l.descr = { text: i };
2342
+ x(l, {
2343
+ sprite: a,
2344
+ tags: o,
2345
+ link: s
2346
+ }), l.wrap = Z(), l.typeC4Shape = { text: e }, l.parentBoundary = T;
2347
+ }, "addContainer"), z = /* @__PURE__ */ n(function(e, t, n, r, i, a, o, s) {
2348
+ if (t === null || n === null) return;
2349
+ let l = {}, u = C.find((e) => e.alias === t);
2350
+ if (u && t === u.alias ? l = u : (l.alias = t, C.push(l)), n == null ? l.label = { text: "" } : l.label = { text: n }, r == null) l.techn = { text: "" };
2351
+ else if (typeof r == "object") {
2352
+ let [e, t] = Object.entries(r)[0];
2353
+ l[e] = { text: t };
2354
+ } else l.techn = { text: r };
2355
+ if (i == null) l.descr = { text: "" };
2356
+ else if (typeof i == "object") {
2357
+ let [e, t] = Object.entries(i)[0];
2358
+ l[e] = { text: t };
2359
+ } else l.descr = { text: i };
2360
+ x(l, {
2361
+ sprite: a,
2362
+ tags: o,
2363
+ link: s
2364
+ }), l.wrap = Z(), l.typeC4Shape = { text: e }, l.parentBoundary = T;
2365
+ }, "addComponent"), B = /* @__PURE__ */ n(function(e, t, n, r, i) {
2366
+ if (e === null || t === null) return;
2367
+ let a = {}, o = D.find((t) => t.alias === e);
2368
+ if (o && e === o.alias ? a = o : (a.alias = e, D.push(a)), t == null ? a.label = { text: "" } : a.label = { text: t }, n == null) a.type = { text: "system" };
2369
+ else if (typeof n == "object") {
2370
+ let [e, t] = Object.entries(n)[0];
2371
+ a[e] = { text: t };
2372
+ } else a.type = { text: n };
2373
+ x(a, {
2374
+ tags: r,
2375
+ link: i
2376
+ }), a.parentBoundary = T, a.wrap = Z(), E = T, T = e, w.push(E);
2377
+ }, "addPersonOrSystemBoundary"), V = /* @__PURE__ */ n(function(e, t, n, r, i) {
2378
+ if (e === null || t === null) return;
2379
+ let a = {}, o = D.find((t) => t.alias === e);
2380
+ if (o && e === o.alias ? a = o : (a.alias = e, D.push(a)), t == null ? a.label = { text: "" } : a.label = { text: t }, n == null) a.type = { text: "container" };
2381
+ else if (typeof n == "object") {
2382
+ let [e, t] = Object.entries(n)[0];
2383
+ a[e] = { text: t };
2384
+ } else a.type = { text: n };
2385
+ x(a, {
2386
+ tags: r,
2387
+ link: i
2388
+ }), a.parentBoundary = T, a.wrap = Z(), E = T, T = e, w.push(E);
2389
+ }, "addContainerBoundary"), H = /* @__PURE__ */ n(function(e, t, n, r, i, a, o, s) {
2390
+ if (t === null || n === null) return;
2391
+ let l = {}, u = D.find((e) => e.alias === t);
2392
+ if (u && t === u.alias ? l = u : (l.alias = t, D.push(l)), n == null ? l.label = { text: "" } : l.label = { text: n }, r == null) l.type = { text: "node" };
2393
+ else if (typeof r == "object") {
2394
+ let [e, t] = Object.entries(r)[0];
2395
+ l[e] = { text: t };
2396
+ } else l.type = { text: r };
2397
+ if (i == null) l.descr = { text: "" };
2398
+ else if (typeof i == "object") {
2399
+ let [e, t] = Object.entries(i)[0];
2400
+ l[e] = { text: t };
2401
+ } else l.descr = { text: i };
2402
+ x(l, {
2403
+ tags: o,
2404
+ link: s
2405
+ }), l.nodeType = e, l.parentBoundary = T, l.wrap = Z(), E = T, T = t, w.push(E);
2406
+ }, "addDeploymentNode"), U = /* @__PURE__ */ n(function() {
2407
+ T = E, w.pop(), E = w.pop(), w.push(E);
2408
+ }, "popBoundaryParseStack"), W = /* @__PURE__ */ n(function(e, t, n, r, i, a, o, s, l, u, d) {
2409
+ let f = C.find((e) => e.alias === t);
2410
+ if (!(f === void 0 && (f = D.find((e) => e.alias === t), f === void 0))) {
2411
+ if (n != null) {
2412
+ if (typeof n == "object") {
2413
+ let [e, t] = Object.entries(n)[0];
2414
+ f[e] = t;
2415
+ } else f.bgColor = n;
2416
+ }
2417
+ if (r != null) {
2418
+ if (typeof r == "object") {
2419
+ let [e, t] = Object.entries(r)[0];
2420
+ f[e] = t;
2421
+ } else f.fontColor = r;
2422
+ }
2423
+ if (i != null) {
2424
+ if (typeof i == "object") {
2425
+ let [e, t] = Object.entries(i)[0];
2426
+ f[e] = t;
2427
+ } else f.borderColor = i;
2428
+ }
2429
+ if (a != null) {
2430
+ if (typeof a == "object") {
2431
+ let [e, t] = Object.entries(a)[0];
2432
+ f[e] = t;
2433
+ } else f.shadowing = a;
2434
+ }
2435
+ if (o != null) {
2436
+ if (typeof o == "object") {
2437
+ let [e, t] = Object.entries(o)[0];
2438
+ f[e] = t;
2439
+ } else f.shape = o;
2440
+ }
2441
+ if (s != null) {
2442
+ if (typeof s == "object") {
2443
+ let [e, t] = Object.entries(s)[0];
2444
+ f[e] = t;
2445
+ } else f.sprite = s;
2446
+ }
2447
+ if (l != null) {
2448
+ if (typeof l == "object") {
2449
+ let [e, t] = Object.entries(l)[0];
2450
+ f[e] = t;
2451
+ } else f.techn = l;
2452
+ }
2453
+ if (u != null) {
2454
+ if (typeof u == "object") {
2455
+ let [e, t] = Object.entries(u)[0];
2456
+ f[e] = t;
2457
+ } else f.legendText = u;
2458
+ }
2459
+ if (d != null) {
2460
+ if (typeof d == "object") {
2461
+ let [e, t] = Object.entries(d)[0];
2462
+ f[e] = t;
2463
+ } else f.legendSprite = d;
2464
+ }
2465
+ }
2466
+ }, "updateElStyle"), G = /* @__PURE__ */ n(function(e, t, n, r, i, a, o) {
2467
+ let s = O.find((e) => e.from === t && e.to === n);
2468
+ if (s !== void 0) {
2469
+ if (r != null) {
2470
+ if (typeof r == "object") {
2471
+ let [e, t] = Object.entries(r)[0];
2472
+ s[e] = t;
2473
+ } else s.textColor = r;
2474
+ }
2475
+ if (i != null) {
2476
+ if (typeof i == "object") {
2477
+ let [e, t] = Object.entries(i)[0];
2478
+ s[e] = t;
2479
+ } else s.lineColor = i;
2480
+ }
2481
+ if (a != null) {
2482
+ if (typeof a == "object") {
2483
+ let [e, t] = Object.entries(a)[0];
2484
+ s[e] = parseInt(t);
2485
+ } else s.offsetX = parseInt(a);
2486
+ }
2487
+ if (o != null) {
2488
+ if (typeof o == "object") {
2489
+ let [e, t] = Object.entries(o)[0];
2490
+ s[e] = parseInt(t);
2491
+ } else s.offsetY = parseInt(o);
2492
+ }
2493
+ }
2494
+ }, "updateRelStyle"), ee = /* @__PURE__ */ n(function(e, t, n) {
2495
+ let r = j, i = M;
2496
+ if (typeof t == "object") {
2497
+ let e = Object.values(t)[0];
2498
+ r = parseInt(e);
2499
+ } else r = parseInt(t);
2500
+ if (typeof n == "object") {
2501
+ let e = Object.values(n)[0];
2502
+ i = parseInt(e);
2503
+ } else i = parseInt(n);
2504
+ r >= 1 && (j = r), i >= 1 && (M = i);
2505
+ }, "updateLayoutConfig"), te = /* @__PURE__ */ n(function() {
2506
+ return j;
2507
+ }, "getC4ShapeInRow"), ne = /* @__PURE__ */ n(function() {
2508
+ return M;
2509
+ }, "getC4BoundaryInRow"), K = /* @__PURE__ */ n(function() {
2510
+ return T;
2511
+ }, "getCurrentBoundaryParse"), q = /* @__PURE__ */ n(function() {
2512
+ return E;
2513
+ }, "getParentBoundaryParse"), J = /* @__PURE__ */ n(function(e) {
2514
+ return e == null ? C : C.filter((t) => t.parentBoundary === e);
2515
+ }, "getC4ShapeArray"), Y = /* @__PURE__ */ n(function(e) {
2516
+ return C.find((t) => t.alias === e);
2517
+ }, "getC4Shape"), X = /* @__PURE__ */ n(function(e) {
2518
+ return Object.keys(J(e));
2519
+ }, "getC4ShapeKeys"), re = /* @__PURE__ */ n(function(e) {
2520
+ return e == null ? D : D.filter((t) => t.parentBoundary === e);
2521
+ }, "getBoundaries"), ie = re, ae = /* @__PURE__ */ n(function() {
2522
+ return O;
2523
+ }, "getRels"), oe = /* @__PURE__ */ n(function() {
2524
+ return k;
2525
+ }, "getTitle"), se = /* @__PURE__ */ n(function(e) {
2526
+ A = e;
2527
+ }, "setWrap"), Z = /* @__PURE__ */ n(function() {
2528
+ return A;
2529
+ }, "autoWrap"), ce = {
2530
+ addPersonOrSystem: L,
2531
+ addPersonOrSystemBoundary: B,
2532
+ addContainer: R,
2533
+ addContainerBoundary: V,
2534
+ addComponent: z,
2535
+ addDeploymentNode: H,
2536
+ popBoundaryParseStack: U,
2537
+ addRel: I,
2538
+ updateElStyle: W,
2539
+ updateRelStyle: G,
2540
+ updateLayoutConfig: ee,
2541
+ autoWrap: Z,
2542
+ setWrap: se,
2543
+ getC4ShapeArray: J,
2544
+ getC4Shape: Y,
2545
+ getC4ShapeKeys: X,
2546
+ getBoundaries: re,
2547
+ getBoundarys: ie,
2548
+ getCurrentBoundaryParse: K,
2549
+ getParentBoundaryParse: q,
2550
+ getRels: ae,
2551
+ getTitle: oe,
2552
+ getC4Type: P,
2553
+ getC4ShapeInRow: te,
2554
+ getC4BoundaryInRow: ne,
2555
+ setAccTitle: i,
2556
+ getAccTitle: d,
2557
+ getAccDescription: l,
2558
+ setAccDescription: r,
2559
+ getConfig: /* @__PURE__ */ n(() => b("c4"), "getConfig"),
2560
+ clear: /* @__PURE__ */ n(function() {
2561
+ C = [], D = [S()], E = "", T = "global", w = [""], O = [], w = [""], k = "", A = !1, j = 4, M = 2;
2562
+ }, "clear"),
2563
+ LINETYPE: {
2564
+ SOLID: 0,
2565
+ DOTTED: 1,
2566
+ NOTE: 2,
2567
+ SOLID_CROSS: 3,
2568
+ DOTTED_CROSS: 4,
2569
+ SOLID_OPEN: 5,
2570
+ DOTTED_OPEN: 6,
2571
+ LOOP_START: 10,
2572
+ LOOP_END: 11,
2573
+ ALT_START: 12,
2574
+ ALT_ELSE: 13,
2575
+ ALT_END: 14,
2576
+ OPT_START: 15,
2577
+ OPT_END: 16,
2578
+ ACTIVE_START: 17,
2579
+ ACTIVE_END: 18,
2580
+ PAR_START: 19,
2581
+ PAR_AND: 20,
2582
+ PAR_END: 21,
2583
+ RECT_START: 22,
2584
+ RECT_END: 23,
2585
+ SOLID_POINT: 24,
2586
+ DOTTED_POINT: 25
2587
+ },
2588
+ ARROWTYPE: {
2589
+ FILLED: 0,
2590
+ OPEN: 1
2591
+ },
2592
+ PLACEMENT: {
2593
+ LEFTOF: 0,
2594
+ RIGHTOF: 1,
2595
+ OVER: 2
2596
+ },
2597
+ setTitle: /* @__PURE__ */ n(function(e) {
2598
+ k = f(e, u());
2599
+ }, "setTitle"),
2600
+ setC4Type: F
2601
+ }, le = /* @__PURE__ */ n(function(e, t) {
2602
+ return _(e, t);
2603
+ }, "drawRect"), ue = /* @__PURE__ */ n((e, t, n, r) => {
2604
+ let i = e.append("g"), a = 0;
2605
+ for (let e of t) {
2606
+ let t = e.textColor ? e.textColor : "#444444", o = e.lineColor ? e.lineColor : "#444444", s = e.offsetX ? parseInt(String(e.offsetX)) : 0, l = e.offsetY ? parseInt(String(e.offsetY)) : 0;
2607
+ if (a === 0) {
2608
+ let t = i.append("line");
2609
+ t.attr("x1", e.startPoint.x), t.attr("y1", e.startPoint.y), t.attr("x2", e.endPoint.x), t.attr("y2", e.endPoint.y), t.attr("stroke-width", "1"), t.attr("stroke", o), t.style("fill", "none"), e.type !== "rel_b" && t.attr("marker-end", "url(#" + r + "-arrowhead)"), (e.type === "birel" || e.type === "rel_b") && t.attr("marker-start", "url(#" + r + "-arrowend)"), a = -1;
2610
+ } else {
2611
+ let t = i.append("path");
2612
+ t.attr("fill", "none").attr("stroke-width", "1").attr("stroke", o).attr("d", "Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx", e.startPoint.x).replaceAll("starty", e.startPoint.y).replaceAll("controlx", e.startPoint.x + (e.endPoint.x - e.startPoint.x) / 2 - (e.endPoint.x - e.startPoint.x) / 4).replaceAll("controly", e.startPoint.y + (e.endPoint.y - e.startPoint.y) / 2).replaceAll("stopx", e.endPoint.x).replaceAll("stopy", e.endPoint.y)), e.type !== "rel_b" && t.attr("marker-end", "url(#" + r + "-arrowhead)"), (e.type === "birel" || e.type === "rel_b") && t.attr("marker-start", "url(#" + r + "-arrowend)");
2613
+ }
2614
+ let u = e.label.width, d = n.messageFont();
2615
+ ye(n)(e.label.text, i, Math.min(e.startPoint.x, e.endPoint.x) + Math.abs(e.endPoint.x - e.startPoint.x) / 2 + s, Math.min(e.startPoint.y, e.endPoint.y) + Math.abs(e.endPoint.y - e.startPoint.y) / 2 + l, u, e.label.height, { fill: t }, d), e.techn && e.techn.text !== "" && (d = n.messageFont(), ye(n)("[" + e.techn.text + "]", i, Math.min(e.startPoint.x, e.endPoint.x) + Math.abs(e.endPoint.x - e.startPoint.x) / 2 + s, Math.min(e.startPoint.y, e.endPoint.y) + Math.abs(e.endPoint.y - e.startPoint.y) / 2 + n.messageFontSize + 5 + l, Math.max(u, e.techn.width), e.techn.height, {
2616
+ fill: t,
2617
+ "font-style": "italic"
2618
+ }, d));
2619
+ }
2620
+ }, "drawRels"), de = /* @__PURE__ */ n(function(e, t, n) {
2621
+ let r = e.append("g"), i = t.bgColor ? t.bgColor : "none", a = t.borderColor ? t.borderColor : "#444444", o = t.fontColor ? t.fontColor : "black", s = {
2622
+ "stroke-width": 1,
2623
+ "stroke-dasharray": "7.0,7.0"
2624
+ };
2625
+ t.nodeType && (s = { "stroke-width": 1 }), le(r, {
2626
+ x: t.x,
2627
+ y: t.y,
2628
+ fill: i,
2629
+ stroke: a,
2630
+ width: t.width,
2631
+ height: t.height,
2632
+ rx: 2.5,
2633
+ ry: 2.5,
2634
+ attrs: s
2635
+ });
2636
+ let l = n.boundaryFont();
2637
+ l.fontWeight = "bold", l.fontSize += 2, l.fontColor = o, ye(n)(t.label.text, r, t.x, t.y + t.label.Y, t.width, t.height, { fill: "#444444" }, l), t.type && t.type.text !== "" && (l = n.boundaryFont(), l.fontColor = o, ye(n)(t.type.text, r, t.x, t.y + t.type.Y, t.width, t.height, { fill: "#444444" }, l)), t.descr && t.descr.text !== "" && (l = n.boundaryFont(), l.fontSize -= 2, l.fontColor = o, ye(n)(t.descr.text, r, t.x, t.y + t.descr.Y, t.width, t.height, { fill: "#444444" }, l));
2638
+ }, "drawBoundary"), fe = /* @__PURE__ */ n(function(e, t) {
2639
+ e.append("defs").append("symbol").attr("id", t + "-database").attr("fill-rule", "evenodd").attr("clip-rule", "evenodd").append("path").attr("transform", "scale(.5)").attr("d", "M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z");
2640
+ }, "insertDatabaseIcon"), pe = /* @__PURE__ */ n(function(e, t) {
2641
+ e.append("defs").append("symbol").attr("id", t + "-computer").attr("width", "24").attr("height", "24").append("path").attr("transform", "scale(.5)").attr("d", "M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z");
2642
+ }, "insertComputerIcon"), me = /* @__PURE__ */ n(function(e, t) {
2643
+ e.append("defs").append("symbol").attr("id", t + "-clock").attr("width", "24").attr("height", "24").append("path").attr("transform", "scale(.5)").attr("d", "M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z");
2644
+ }, "insertClockIcon"), he = /* @__PURE__ */ n(function(e, t) {
2645
+ e.append("defs").append("marker").attr("id", t + "-arrowhead").attr("refX", 9).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 12).attr("markerHeight", 12).attr("orient", "auto").append("path").attr("d", "M 0 0 L 10 5 L 0 10 z");
2646
+ }, "insertArrowHead"), ge = /* @__PURE__ */ n(function(e, t) {
2647
+ e.append("defs").append("marker").attr("id", t + "-arrowend").attr("refX", 1).attr("refY", 5).attr("markerUnits", "userSpaceOnUse").attr("markerWidth", 12).attr("markerHeight", 12).attr("orient", "auto").append("path").attr("d", "M 10 0 L 0 5 L 10 10 z");
2648
+ }, "insertArrowEnd"), _e = /* @__PURE__ */ n(function(e, t) {
2649
+ e.append("defs").append("marker").attr("id", t + "-filled-head").attr("refX", 18).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L14,7 L9,1 Z");
2650
+ }, "insertArrowFilledHead"), ve = /* @__PURE__ */ n(function(e, t) {
2651
+ let n = e.append("defs").append("marker").attr("id", t + "-crosshead").attr("markerWidth", 15).attr("markerHeight", 8).attr("orient", "auto").attr("refX", 16).attr("refY", 4);
2652
+ n.append("path").attr("fill", "black").attr("stroke", "#000000").style("stroke-dasharray", "0, 0").attr("stroke-width", "1px").attr("d", "M 9,2 V 6 L16,4 Z"), n.append("path").attr("fill", "none").attr("stroke", "#000000").style("stroke-dasharray", "0, 0").attr("stroke-width", "1px").attr("d", "M 0,1 L 6,7 M 6,1 L 0,7");
2653
+ }, "insertArrowCrossHead"), ye = /* @__PURE__ */ (function() {
2654
+ function e(e, t, n, r, a, o, s) {
2655
+ i(t.append("text").attr("x", n + a / 2).attr("y", r + o / 2 + 5).style("text-anchor", "middle").text(e), s);
2656
+ }
2657
+ n(e, "byText");
2658
+ function t(e, t, n, r, a, o, l, u) {
2659
+ let { fontSize: d, fontFamily: f, fontWeight: p } = u, m = e.split(s.lineBreakRegex);
2660
+ for (let e = 0; e < m.length; e++) {
2661
+ let o = e * d - d * (m.length - 1) / 2, s = t.append("text").attr("x", n + a / 2).attr("y", r).style("text-anchor", "middle").attr("dominant-baseline", "middle").style("font-size", d).style("font-weight", p).style("font-family", f);
2662
+ s.append("tspan").attr("dy", o).text(m[e]).attr("alignment-baseline", "mathematical"), i(s, l);
2663
+ }
2664
+ }
2665
+ n(t, "byTspan");
2666
+ function r(e, n, r, a, o, s, l, u) {
2667
+ let d = n.append("switch"), f = d.append("foreignObject").attr("x", r).attr("y", a).attr("width", o).attr("height", s).append("xhtml:div").style("display", "table").style("height", "100%").style("width", "100%");
2668
+ f.append("div").style("display", "table-cell").style("text-align", "center").style("vertical-align", "middle").text(e), t(e, d, r, a, o, s, l, u), i(f, l);
2669
+ }
2670
+ n(r, "byFo");
2671
+ function i(e, t) {
2672
+ for (let n in t) t.hasOwnProperty(n) && e.attr(n, t[n]);
2673
+ }
2674
+ return n(i, "_setTextAttrs"), function(n) {
2675
+ return n.textPlacement === "fo" ? r : n.textPlacement === "old" ? e : t;
2676
+ };
2677
+ })(), Q = {
2678
+ drawRect: le,
2679
+ drawBoundary: de,
2680
+ drawRels: ue,
2681
+ insertArrowHead: he,
2682
+ insertArrowEnd: ge,
2683
+ insertArrowFilledHead: _e,
2684
+ insertArrowCrossHead: ve,
2685
+ insertDatabaseIcon: fe,
2686
+ insertComputerIcon: pe,
2687
+ insertClockIcon: me
2688
+ }, be = /* @__PURE__ */ n((e, n) => {
2689
+ if (n === "sandbox") {
2690
+ let n = t("#i" + e).node()?.contentDocument;
2691
+ if (!n) throw Error(`Sandbox iframe #i${e} is missing its content document`);
2692
+ return {
2693
+ root: t(n.body),
2694
+ doc: n
2695
+ };
2696
+ }
2697
+ return {
2698
+ root: t("body"),
2699
+ doc: document
2700
+ };
2701
+ }, "getDiagramRoot"), xe = /* @__PURE__ */ new Set([
2702
+ "system_queue",
2703
+ "external_system_queue",
2704
+ "container_queue",
2705
+ "external_container_queue",
2706
+ "component_queue",
2707
+ "external_component_queue"
2708
+ ]), Se = /* @__PURE__ */ new Set([
2709
+ "system_db",
2710
+ "external_system_db",
2711
+ "container_db",
2712
+ "external_container_db",
2713
+ "component_db",
2714
+ "external_component_db"
2715
+ ]), Ce = {
2716
+ person: "person",
2717
+ box: "rounded",
2718
+ rounded: "rounded",
2719
+ cylinder: "cylinder",
2720
+ database: "cylinder",
2721
+ db: "cylinder",
2722
+ queue: "h-cyl",
2723
+ pipe: "h-cyl",
2724
+ component: "fr-rect"
2725
+ }, we = /* @__PURE__ */ n((e) => e ? Ce[e.toLowerCase()] : void 0, "keywordShape"), Te = /* @__PURE__ */ n((e) => {
2726
+ let t = we(e.shape) ?? we(e.sprite);
2727
+ if (t) return t;
2728
+ if (e.tags) for (let t of e.tags.split(",")) {
2729
+ let e = we(t.trim());
2730
+ if (e) return e;
2731
+ }
2732
+ let n = e.typeC4Shape.text;
2733
+ return n === "person" || n === "external_person" ? "person" : Se.has(n) ? "cylinder" : xe.has(n) ? "h-cyl" : "rounded";
2734
+ }, "resolveNodeShape"), Ee = {
2735
+ person: "Person",
2736
+ system: "Software System",
2737
+ container: "Container",
2738
+ component: "Component"
2739
+ }, De = /* @__PURE__ */ n((e) => {
2740
+ let t = e.replace(/^external_/, "").replace(/_(db|queue)$/, "");
2741
+ return Ee[t] ?? t.replace(/_/g, " ");
2742
+ }, "stereotypeLabel"), Oe = /* @__PURE__ */ n((e) => e.startsWith("external_"), "isExternal"), ke = /* @__PURE__ */ n((e) => {
2743
+ let t = De(e.typeC4Shape.text);
2744
+ return e.techn?.text ? `[${t}: ${e.techn.text}]` : `[${t}]`;
2745
+ }, "stereotypeText"), Ae = [
2746
+ "person",
2747
+ "system",
2748
+ "system_db",
2749
+ "system_queue",
2750
+ "container",
2751
+ "container_db",
2752
+ "container_queue",
2753
+ "component",
2754
+ "component_db",
2755
+ "component_queue"
2756
+ ].flatMap((e) => [e, `external_${e}`]), je = new Set(Ae), Me = /* @__PURE__ */ n((e) => je.has(e), "isC4ElementType"), Ne = /* @__PURE__ */ n((e, t) => {
2757
+ let n = e.typeC4Shape.text, r = e.bgColor ?? (Me(n) && t[`${n}_bg_color`]), i = e.borderColor ?? (Me(n) && t[`${n}_border_color`]), a = [];
2758
+ return r && a.push(`fill:${r}`), i && a.push(`stroke:${i}`), a.push(`color:${e.fontColor ?? "#FFFFFF"}`), a;
2759
+ }, "elementCssStyles"), Pe = /* @__PURE__ */ n((e, t, n, r, i) => {
2760
+ let a = e.typeC4Shape.text, o = ["c4-shape", `c4-${a}`];
2761
+ Oe(a) && o.push("c4-external");
2762
+ let s = Te(e), l = Ne(e, t);
2763
+ return (s === "rounded" || s === "fr-rect") && l.push("rx:12px", "ry:12px"), {
2764
+ id: e.alias,
2765
+ label: e.label.text,
2766
+ stereotype: ke(e),
2767
+ description: e.descr?.text ? [e.descr.text] : void 0,
2768
+ labelType: "string",
2769
+ isGroup: !1,
2770
+ shape: s,
2771
+ cssClasses: o.join(" "),
2772
+ cssStyles: l,
2773
+ padding: n,
2774
+ look: r,
2775
+ useHtmlLabels: !1,
2776
+ width: i
2777
+ };
2778
+ }, "buildC4Node"), Fe = 0, Ie = 0, Le = 4, Re = 2;
2779
+ v.yy = ce;
2780
+ var $ = {}, ze = class {
2781
+ static {
2782
+ n(this, "Bounds");
2783
+ }
2784
+ constructor(e) {
2785
+ this.name = "", this.data = {}, this.data.startx = void 0, this.data.stopx = void 0, this.data.starty = void 0, this.data.stopy = void 0, this.data.widthLimit = void 0, this.nextData = {}, this.nextData.startx = void 0, this.nextData.stopx = void 0, this.nextData.starty = void 0, this.nextData.stopy = void 0, this.nextData.cnt = 0, Be(e.db.getConfig());
2786
+ }
2787
+ setData(e, t, n, r) {
2788
+ this.nextData.startx = this.data.startx = e, this.nextData.stopx = this.data.stopx = t, this.nextData.starty = this.data.starty = n, this.nextData.stopy = this.data.stopy = r;
2789
+ }
2790
+ updateVal(e, t, n, r) {
2791
+ e[t] = e[t] === void 0 ? n : r(n, e[t]);
2792
+ }
2793
+ insert(e) {
2794
+ this.nextData.cnt = this.nextData.cnt + 1;
2795
+ let t = this.nextData.stopx, n = this.data.widthLimit, r = this.nextData.startx === this.nextData.stopx ? t + e.margin : t + e.margin * 2, i = r + e.width, a = this.nextData.starty + e.margin * 2, o = a + e.height;
2796
+ (r >= n || i >= n || this.nextData.cnt > Le) && (r = this.nextData.startx + e.margin + $.nextLinePaddingX, a = this.nextData.stopy + e.margin * 2, this.nextData.stopx = i = r + e.width, this.nextData.starty = this.nextData.stopy, this.nextData.stopy = o = a + e.height, this.nextData.cnt = 1), e.x = r, e.y = a, this.updateVal(this.data, "startx", r, Math.min), this.updateVal(this.data, "starty", a, Math.min), this.updateVal(this.data, "stopx", i, Math.max), this.updateVal(this.data, "stopy", o, Math.max), this.updateVal(this.nextData, "startx", r, Math.min), this.updateVal(this.nextData, "starty", a, Math.min), this.updateVal(this.nextData, "stopx", i, Math.max), this.updateVal(this.nextData, "stopy", o, Math.max);
2797
+ }
2798
+ init(e) {
2799
+ this.name = "", this.data = {
2800
+ startx: void 0,
2801
+ stopx: void 0,
2802
+ starty: void 0,
2803
+ stopy: void 0,
2804
+ widthLimit: void 0
2805
+ }, this.nextData = {
2806
+ startx: void 0,
2807
+ stopx: void 0,
2808
+ starty: void 0,
2809
+ stopy: void 0,
2810
+ cnt: 0
2811
+ }, Be(e.db.getConfig());
2812
+ }
2813
+ bumpLastMargin(e) {
2814
+ this.data.stopx += e, this.data.stopy += e;
2815
+ }
2816
+ }, Be = /* @__PURE__ */ n(function(e) {
2817
+ o($, e), e?.fontFamily && ($.personFontFamily = $.systemFontFamily = $.messageFontFamily = e.fontFamily), e?.fontSize && ($.personFontSize = $.systemFontSize = $.messageFontSize = e.fontSize), e?.fontWeight && ($.personFontWeight = $.systemFontWeight = $.messageFontWeight = e.fontWeight);
2818
+ }, "setConf"), Ve = /* @__PURE__ */ n((e) => ({
2819
+ fontFamily: e.boundaryFontFamily,
2820
+ fontSize: e.boundaryFontSize,
2821
+ fontWeight: e.boundaryFontWeight
2822
+ }), "boundaryFont"), He = /* @__PURE__ */ n((e) => ({
2823
+ fontFamily: e.messageFontFamily,
2824
+ fontSize: e.messageFontSize,
2825
+ fontWeight: e.messageFontWeight
2826
+ }), "messageFont");
2827
+ function Ue(e, t, n, r, i) {
2828
+ let a = t[e];
2829
+ if (!a.width) {
2830
+ if (n) a.text = p(a.text, i, r), a.textLines = a.text.split(s.lineBreakRegex).length, a.width = i, a.height = m(a.text, r);
2831
+ else {
2832
+ let e = a.text.split(s.lineBreakRegex);
2833
+ a.textLines = e.length;
2834
+ let t = 0;
2835
+ a.height = 0, a.width = 0;
2836
+ for (let n of e) a.width = Math.max(h(n, r), a.width), t = m(n, r), a.height += t;
2837
+ }
2838
+ }
2839
+ return a;
2840
+ }
2841
+ n(Ue, "calcC4ShapeTextWH");
2842
+ var We = /* @__PURE__ */ n(function(e, t, n) {
2843
+ let r = n.data.startx, i = n.data.starty;
2844
+ t.x = r, t.y = i, t.width = n.data.stopx - r, t.height = n.data.stopy - i, t.label.y = $.c4ShapeMargin - 35;
2845
+ let a = t.wrap && $.wrap, o = Ve($);
2846
+ o.fontSize += 2, o.fontWeight = "bold", Ue("label", t, a, o, h(t.label.text, o)), Q.drawBoundary(e, t, $);
2847
+ }, "drawBoundary"), Ge = /* @__PURE__ */ n(async function(e, t, r, i) {
2848
+ let a = u(), o = a.look ?? "classic", s = { config: a }, l = t.attr("id") ?? "", d = i.map((e) => r[Number(e)]), f = /* @__PURE__ */ n((e) => {
2849
+ let t = e.shape ? g[e.shape] : void 0;
2850
+ if (!t) throw Error(`C4: no shape handler for "${e.shape}"`);
2851
+ return t;
2852
+ }, "shapeHandlerFor");
2853
+ await Promise.all(d.map(async (e) => {
2854
+ let n = Pe(e, $, $.c4ShapePadding, o, $.width);
2855
+ n.domId = `${l}-${n.id}`;
2856
+ let r = await f(n)(t, n, s);
2857
+ e.width = n.width ?? $.width, e.height = n.height ?? $.height, e.margin = $.c4ShapeMargin, r.remove();
2858
+ }));
2859
+ for (let t of d) e.insert(t);
2860
+ await Promise.all(d.map(async (e) => {
2861
+ let n = Pe(e, $, $.c4ShapePadding, o, $.width);
2862
+ n.domId = `${l}-${n.id}`, n.x = e.x + e.width / 2, n.y = e.y + e.height / 2;
2863
+ let r = t.append("g").attr("transform", `translate(${e.x + e.width / 2}, ${e.y + e.height / 2})`);
2864
+ await f(n)(r, n, s), e.intersect = n.intersect;
2865
+ })), e.bumpLastMargin($.c4ShapeMargin);
2866
+ }, "drawC4ShapeArray"), Ke = class {
2867
+ static {
2868
+ n(this, "Point");
2869
+ }
2870
+ constructor(e, t) {
2871
+ this.x = e, this.y = t;
2872
+ }
2873
+ }, qe = /* @__PURE__ */ n(function(e, t) {
2874
+ if (!e.intersect) throw Error(`C4 shape "${e.alias}" has no intersect function. Please report this to https://github.com/mermaid-js/mermaid/issues`);
2875
+ let { x: n, y: r } = e.intersect(t);
2876
+ return new Ke(n, r);
2877
+ }, "getIntersectPoint"), Je = /* @__PURE__ */ n(function(e, t) {
2878
+ let n = {
2879
+ x: 0,
2880
+ y: 0
2881
+ };
2882
+ n.x = t.x + t.width / 2, n.y = t.y + t.height / 2;
2883
+ let r = qe(e, n);
2884
+ return n.x = e.x + e.width / 2, n.y = e.y + e.height / 2, {
2885
+ startPoint: r,
2886
+ endPoint: qe(t, n)
2887
+ };
2888
+ }, "getIntersectPoints"), Ye = /* @__PURE__ */ n(function(e, t, n, r, i) {
2889
+ let a = r.db.getC4Type(), o = 0;
2890
+ for (let e of t) {
2891
+ o += 1;
2892
+ let t = e.wrap && $.wrap, r = He($);
2893
+ a === "C4Dynamic" && (e.label.text = o + ": " + e.label.text);
2894
+ let i = h(e.label.text, r);
2895
+ Ue("label", e, t, r, i), e.techn && e.techn.text !== "" && (i = h(e.techn.text, r), Ue("techn", e, t, r, i)), e.descr && e.descr.text !== "" && (i = h(e.descr.text, r), Ue("descr", e, t, r, i));
2896
+ let s = n(e.from), l = n(e.to);
2897
+ if (!s || !l) throw Error(`C4 rel "${e.from}" -> "${e.to}" references an unknown shape`);
2898
+ let u = Je(s, l);
2899
+ if (!u.startPoint || !u.endPoint) throw Error(`Could not calculate intersection points for rel "${e.from}" -> "${e.to}"`);
2900
+ e.startPoint = u.startPoint, e.endPoint = u.endPoint;
2901
+ }
2902
+ Q.drawRels(e, t, $, i);
2903
+ }, "drawRels");
2904
+ async function Xe(e, t, n, r, i) {
2905
+ let a = i.db, o = new ze(i);
2906
+ o.data.widthLimit = n.data.widthLimit / Math.min(Re, r.length);
2907
+ for (let [s, l] of r.entries()) {
2908
+ let r = 0;
2909
+ l.image = {
2910
+ width: 0,
2911
+ height: 0,
2912
+ Y: 0
2913
+ }, l.sprite && (l.image.width = 48, l.image.height = 48, l.image.Y = r, r = l.image.Y + l.image.height);
2914
+ let u = l.wrap && $.wrap, d = Ve($);
2915
+ d.fontSize += 2, d.fontWeight = "bold";
2916
+ let f = Ue("label", l, u, d, o.data.widthLimit);
2917
+ if (f.Y = r + 8, r = f.Y + f.height, l.type && l.type.text !== "") {
2918
+ l.type.text = "[" + l.type.text + "]";
2919
+ let e = Ue("type", l, u, Ve($), o.data.widthLimit);
2920
+ e.Y = r + 5, r = e.Y + e.height;
2921
+ }
2922
+ if (l.descr && l.descr.text !== "") {
2923
+ let e = Ve($);
2924
+ e.fontSize -= 2;
2925
+ let t = Ue("descr", l, u, e, o.data.widthLimit);
2926
+ t.Y = r + 20, r = t.Y + t.height;
2927
+ }
2928
+ if (s == 0 || s % Re === 0) {
2929
+ let e = n.data.startx + $.diagramMarginX, t = n.data.stopy + $.diagramMarginY + r;
2930
+ o.setData(e, e, t, t);
2931
+ } else {
2932
+ let e = o.data.stopx === o.data.startx ? o.data.startx : o.data.stopx + $.diagramMarginX, t = o.data.starty;
2933
+ o.setData(e, e, t, t);
2934
+ }
2935
+ o.name = l.alias;
2936
+ let p = a.getC4ShapeArray(l.alias), m = a.getC4ShapeKeys(l.alias);
2937
+ m.length > 0 && await Ge(o, e, p, m), t = l.alias;
2938
+ let h = a.getBoundaries(t);
2939
+ h.length > 0 && await Xe(e, t, o, h, i), l.alias !== "global" && We(e, l, o), n.data.stopy = Math.max(o.data.stopy + $.c4ShapeMargin, n.data.stopy), n.data.stopx = Math.max(o.data.stopx + $.c4ShapeMargin, n.data.stopx), Fe = Math.max(Fe, n.data.stopx), Ie = Math.max(Ie, n.data.stopy);
2940
+ }
2941
+ }
2942
+ n(Xe, "drawInsideBoundary");
2943
+ var Ze = {
2944
+ drawPersonOrSystemArray: Ge,
2945
+ drawBoundary: We,
2946
+ setConf: Be,
2947
+ draw: /* @__PURE__ */ n(async function(t, n, r, i) {
2948
+ $ = b("c4");
2949
+ let o = u().securityLevel, { root: s } = be(n, o), l = i.db;
2950
+ l.setWrap($.wrap), Le = l.getC4ShapeInRow(), Re = l.getC4BoundaryInRow(), e.debug(`C:${JSON.stringify($, null, 2)}`);
2951
+ let d = s.select(`[id="${n}"]`);
2952
+ Q.insertComputerIcon(d, n), Q.insertDatabaseIcon(d, n), Q.insertClockIcon(d, n);
2953
+ let f = new ze(i);
2954
+ f.setData($.diagramMarginX, $.diagramMarginX, $.diagramMarginY, $.diagramMarginY), f.data.widthLimit = screen.availWidth, Fe = $.diagramMarginX, Ie = $.diagramMarginY;
2955
+ let p = l.getTitle();
2956
+ await Xe(d, "", f, l.getBoundaries(""), i), Q.insertArrowHead(d, n), Q.insertArrowEnd(d, n), Q.insertArrowCrossHead(d, n), Q.insertArrowFilledHead(d, n), Ye(d, l.getRels(), l.getC4Shape, i, n), f.data.stopx = Fe, f.data.stopy = Ie;
2957
+ let m = f.data, h = m.startx, g = m.starty, _ = Ie - g + 2 * $.diagramMarginY, v = Fe - h, y = v + 2 * $.diagramMarginX;
2958
+ p && d.append("text").text(p).attr("x", v / 2 - 4 * $.diagramMarginX).attr("y", g + $.diagramMarginY), a(d, _, y, $.useMaxWidth);
2959
+ let x = p ? 60 : 0;
2960
+ d.attr("viewBox", h - $.diagramMarginX + " -" + ($.diagramMarginY + x) + " " + y + " " + (_ + x)), e.debug("models:", m);
2961
+ }, "draw")
2962
+ }, Qe = /* @__PURE__ */ n(() => {
2963
+ let e = u().c4 ?? {}, t = new CSSStyleSheet();
2964
+ for (let n of Ae) {
2965
+ let r = t.cssRules[t.insertRule(`.c4-shape.c4-${n} .label {}`, t.cssRules.length)], i = e[`${n}FontFamily`], a = e[`${n}FontSize`], o = e[`${n}FontWeight`];
2966
+ i && r.style.setProperty("font-family", i), a && r.style.setProperty("font-size", typeof a == "number" ? `${a}px` : a), o && r.style.setProperty("font-weight", String(o));
2967
+ }
2968
+ return [...t.cssRules].filter((e) => e.style.length > 0).map((e) => ` ${e.cssText}`).join("\n");
2969
+ }, "elementFontStyles"), $e = {
2970
+ parser: y,
2971
+ db: ce,
2972
+ renderer: Ze,
2973
+ styles: /* @__PURE__ */ n((e) => `.person {
2974
+ stroke: ${e.personBorder};
2975
+ fill: ${e.personBkg};
2976
+ }
2977
+ ${Qe()}
2978
+
2979
+ /* The element font colour is set inline per element (default white); the
2980
+ label text takes it via currentColor. */
2981
+ .c4-shape .label,
2982
+ .c4-shape .label text {
2983
+ color: inherit;
2984
+ fill: currentColor;
2985
+ }
2986
+ /* Structurizr typography: bold name, smaller stereotype/type and description lines. */
2987
+ .c4-shape .label .c4-name {
2988
+ font-weight: bold;
2989
+ }
2990
+ .c4-shape .label .c4-type {
2991
+ font-size: 0.75em;
2992
+ }
2993
+ .c4-shape .label .c4-descr {
2994
+ font-size: 0.82em;
2995
+ }
2996
+ .c4-shape .basic,
2997
+ .c4-shape rect,
2998
+ .c4-shape path,
2999
+ .c4-shape circle,
3000
+ .c4-shape ellipse,
3001
+ .c4-shape line {
3002
+ stroke-width: 2px;
3003
+ }
3004
+ `, "getStyles"),
3005
+ init: /* @__PURE__ */ n(({ c4: e, wrap: t }) => {
3006
+ Ze.setConf(e), ce.setWrap(t);
3007
+ }, "init")
3008
+ };
3009
+ //#endregion
3010
+ export { $e as diagram };