@lancc/cmark 0.0.0-stage → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (197) hide show
  1. package/CHANGELOG.md +17 -0
  2. package/LICENSE +21 -0
  3. package/README.md +185 -2
  4. package/assets/KaTeX_AMS-Regular-BQhdFMY1.woff2 +0 -0
  5. package/assets/KaTeX_AMS-Regular-DMm9YOAa.woff +0 -0
  6. package/assets/KaTeX_AMS-Regular-DRggAlZN.ttf +0 -0
  7. package/assets/KaTeX_Caligraphic-Bold-ATXxdsX0.ttf +0 -0
  8. package/assets/KaTeX_Caligraphic-Bold-BEiXGLvX.woff +0 -0
  9. package/assets/KaTeX_Caligraphic-Bold-Dq_IR9rO.woff2 +0 -0
  10. package/assets/KaTeX_Caligraphic-Regular-CTRA-rTL.woff +0 -0
  11. package/assets/KaTeX_Caligraphic-Regular-Di6jR-x-.woff2 +0 -0
  12. package/assets/KaTeX_Caligraphic-Regular-wX97UBjC.ttf +0 -0
  13. package/assets/KaTeX_Fraktur-Bold-BdnERNNW.ttf +0 -0
  14. package/assets/KaTeX_Fraktur-Bold-BsDP51OF.woff +0 -0
  15. package/assets/KaTeX_Fraktur-Bold-CL6g_b3V.woff2 +0 -0
  16. package/assets/KaTeX_Fraktur-Regular-CB_wures.ttf +0 -0
  17. package/assets/KaTeX_Fraktur-Regular-CTYiF6lA.woff2 +0 -0
  18. package/assets/KaTeX_Fraktur-Regular-Dxdc4cR9.woff +0 -0
  19. package/assets/KaTeX_Main-Bold-Cx986IdX.woff2 +0 -0
  20. package/assets/KaTeX_Main-Bold-Jm3AIy58.woff +0 -0
  21. package/assets/KaTeX_Main-Bold-waoOVXN0.ttf +0 -0
  22. package/assets/KaTeX_Main-BoldItalic-DxDJ3AOS.woff2 +0 -0
  23. package/assets/KaTeX_Main-BoldItalic-DzxPMmG6.ttf +0 -0
  24. package/assets/KaTeX_Main-BoldItalic-SpSLRI95.woff +0 -0
  25. package/assets/KaTeX_Main-Italic-3WenGoN9.ttf +0 -0
  26. package/assets/KaTeX_Main-Italic-BMLOBm91.woff +0 -0
  27. package/assets/KaTeX_Main-Italic-NWA7e6Wa.woff2 +0 -0
  28. package/assets/KaTeX_Main-Regular-B22Nviop.woff2 +0 -0
  29. package/assets/KaTeX_Main-Regular-Dr94JaBh.woff +0 -0
  30. package/assets/KaTeX_Main-Regular-ypZvNtVU.ttf +0 -0
  31. package/assets/KaTeX_Math-BoldItalic-B3XSjfu4.ttf +0 -0
  32. package/assets/KaTeX_Math-BoldItalic-CZnvNsCZ.woff2 +0 -0
  33. package/assets/KaTeX_Math-BoldItalic-iY-2wyZ7.woff +0 -0
  34. package/assets/KaTeX_Math-Italic-DA0__PXp.woff +0 -0
  35. package/assets/KaTeX_Math-Italic-flOr_0UB.ttf +0 -0
  36. package/assets/KaTeX_Math-Italic-t53AETM-.woff2 +0 -0
  37. package/assets/KaTeX_SansSerif-Bold-CFMepnvq.ttf +0 -0
  38. package/assets/KaTeX_SansSerif-Bold-D1sUS0GD.woff2 +0 -0
  39. package/assets/KaTeX_SansSerif-Bold-DbIhKOiC.woff +0 -0
  40. package/assets/KaTeX_SansSerif-Italic-C3H0VqGB.woff2 +0 -0
  41. package/assets/KaTeX_SansSerif-Italic-DN2j7dab.woff +0 -0
  42. package/assets/KaTeX_SansSerif-Italic-YYjJ1zSn.ttf +0 -0
  43. package/assets/KaTeX_SansSerif-Regular-BNo7hRIc.ttf +0 -0
  44. package/assets/KaTeX_SansSerif-Regular-CS6fqUqJ.woff +0 -0
  45. package/assets/KaTeX_SansSerif-Regular-DDBCnlJ7.woff2 +0 -0
  46. package/assets/KaTeX_Script-Regular-C5JkGWo-.ttf +0 -0
  47. package/assets/KaTeX_Script-Regular-D3wIWfF6.woff2 +0 -0
  48. package/assets/KaTeX_Script-Regular-D5yQViql.woff +0 -0
  49. package/assets/KaTeX_Size1-Regular-C195tn64.woff +0 -0
  50. package/assets/KaTeX_Size1-Regular-Dbsnue_I.ttf +0 -0
  51. package/assets/KaTeX_Size1-Regular-mCD8mA8B.woff2 +0 -0
  52. package/assets/KaTeX_Size2-Regular-B7gKUWhC.ttf +0 -0
  53. package/assets/KaTeX_Size2-Regular-Dy4dx90m.woff2 +0 -0
  54. package/assets/KaTeX_Size2-Regular-oD1tc_U0.woff +0 -0
  55. package/assets/KaTeX_Size3-Regular-CTq5MqoE.woff +0 -0
  56. package/assets/KaTeX_Size3-Regular-DgpXs0kz.ttf +0 -0
  57. package/assets/KaTeX_Size4-Regular-BF-4gkZK.woff +0 -0
  58. package/assets/KaTeX_Size4-Regular-DWFBv043.ttf +0 -0
  59. package/assets/KaTeX_Size4-Regular-Dl5lxZxV.woff2 +0 -0
  60. package/assets/KaTeX_Typewriter-Regular-C0xS9mPB.woff +0 -0
  61. package/assets/KaTeX_Typewriter-Regular-CO6r4hn1.woff2 +0 -0
  62. package/assets/KaTeX_Typewriter-Regular-D3Ib7_Hf.ttf +0 -0
  63. package/assets/abnfDiagram-WEYOIA3C-BgXsTF7a.js +1 -0
  64. package/assets/architectureDiagram-ZHVYKT53-BsCWa_qC.js +36 -0
  65. package/assets/blockDiagram-RJAE7QA3-wbIxEiYN.js +140 -0
  66. package/assets/c4Diagram-XDPPPE54-5zdyxFvA.js +38 -0
  67. package/assets/chunk-2E7WHVMD-F85Lca-i.js +88 -0
  68. package/assets/chunk-2Q5K7J3B-CjpAZ0OI.js +1 -0
  69. package/assets/chunk-4EMNKR2T-C8Kbh83c.js +1 -0
  70. package/assets/chunk-55XCU76K-BINcFiLN.js +1 -0
  71. package/assets/chunk-5VM5RSS4-Diy5h2LS.js +15 -0
  72. package/assets/chunk-JWPE2WC7-BXnjDdh1.js +1 -0
  73. package/assets/chunk-VQ5W62QI-BM7ZZo1I.js +1 -0
  74. package/assets/chunk-XXDRQBXY-CW8CjB1w.js +1 -0
  75. package/assets/chunk-ZCHMQSOR-C7ATz1L1.js +2 -0
  76. package/assets/classDiagram-v2-4MYWR3UA-CMoqNk-b.js +217 -0
  77. package/assets/cose-bilkent-JH36ORCC-6rqR5iJk.js +1 -0
  78. package/assets/cynefin-EF2NZ3EQ-DypLIJxl.js +141 -0
  79. package/assets/cynefinDiagram-WF24UDRP-8b2CEBlR.js +62 -0
  80. package/assets/cytoscape.esm-CjX6Hyah.js +331 -0
  81. package/assets/dagre-NK4GIZVX-Dv6vuUbR.js +4 -0
  82. package/assets/diagram-CBK3MWTC-DJgMDeYd.js +24 -0
  83. package/assets/diagram-I5XIIV2D-BB9cMoRW.js +24 -0
  84. package/assets/diagram-ODIL2UCW-BVcRtsdy.js +30 -0
  85. package/assets/diagram-PFBEJUXE-BbGSOtJx.js +3 -0
  86. package/assets/diagram-RJA3I4VV-CzkY_8Fo.js +41 -0
  87. package/assets/diagram-TYUNFSNR-YTl5QdfL.js +200 -0
  88. package/assets/ebnfDiagram-V4P3TTPT-COVjPAjE.js +1 -0
  89. package/assets/echarts-BAPDkhe3.js +61 -0
  90. package/assets/elk-QONTBCTQ-DHsjY8Z_.js +27 -0
  91. package/assets/erDiagram-KYQIGQAA-CUAbTUl1.js +99 -0
  92. package/assets/flowDiagram-IUGLLWBU-CWsiqTQC.js +213 -0
  93. package/assets/ganttDiagram-R7GPNTJY-DetBW0Wm.js +292 -0
  94. package/assets/gitGraphDiagram-PDYL7XHY-ByrdgJmw.js +106 -0
  95. package/assets/graph-D8UmR1vK.js +1 -0
  96. package/assets/index-BLONSItV.css +1 -0
  97. package/assets/index-Cz6qaZbV.js +744 -0
  98. package/assets/infoDiagram-MVDRKAX5-BM48fjhU.js +2 -0
  99. package/assets/ishikawaDiagram-HPEHV2GE-DtHYywHZ.js +70 -0
  100. package/assets/journeyDiagram-BOSHW7O7-DJ1LiRh3.js +139 -0
  101. package/assets/kanban-definition-FNSA4HC5-DPPt8pwJ.js +89 -0
  102. package/assets/katex-CQL9J12G.js +257 -0
  103. package/assets/markdown-DVehI1Sg.js +314 -0
  104. package/assets/mermaid-C_q9pug0.js +312 -0
  105. package/assets/mindmap-definition-6OY57UG3-zbqYOEY6.js +98 -0
  106. package/assets/pegDiagram-ECIUJNBX-e7QG7TMq.js +1 -0
  107. package/assets/pieDiagram-GNMPY74T-Duf6YP0N.js +39 -0
  108. package/assets/quadrantDiagram-D57K4MC3-B2eYoUUy.js +7 -0
  109. package/assets/railroadDiagram-Y72NRBL7-BWCzPcI_.js +1 -0
  110. package/assets/requirementDiagram-EQYSW5RA-HhPMEqB1.js +84 -0
  111. package/assets/sankeyDiagram-SY24JHO5-CMUTwFBB.js +40 -0
  112. package/assets/sequenceDiagram-BLEHNHQU-C9wR2ll7.js +169 -0
  113. package/assets/sizeCapture-INFHLROL-DXfz37S6.js +1 -0
  114. package/assets/stateDiagram-v2-A6IESKWZ-D_gtonhE.js +291 -0
  115. package/assets/swimlanes-B3ENRKFQ-DdJOuuMV.js +1 -0
  116. package/assets/swimlanesDiagram-AYQRV4AK-BWt3HxHV.js +8 -0
  117. package/assets/timeline-definition-JXYKGLGB-DQsdwJe-.js +120 -0
  118. package/assets/usecaseDiagram-WPOLBNNX-DTRyFq7d.js +370 -0
  119. package/assets/vennDiagram-Q3Y3IDCW-dihYszm0.js +34 -0
  120. package/assets/wardleyDiagram-IVAIDKWA-BoPpgYfK.js +78 -0
  121. package/assets/xychartDiagram-4URNHDU4-DoLjYxeB.js +7 -0
  122. package/export-file/github-markdown.css +550 -0
  123. package/export-file/index.html +33 -0
  124. package/fonts/KaTeX_AMS-Regular.ttf +0 -0
  125. package/fonts/KaTeX_AMS-Regular.woff +0 -0
  126. package/fonts/KaTeX_AMS-Regular.woff2 +0 -0
  127. package/fonts/KaTeX_Caligraphic-Bold.ttf +0 -0
  128. package/fonts/KaTeX_Caligraphic-Bold.woff +0 -0
  129. package/fonts/KaTeX_Caligraphic-Bold.woff2 +0 -0
  130. package/fonts/KaTeX_Caligraphic-Regular.ttf +0 -0
  131. package/fonts/KaTeX_Caligraphic-Regular.woff +0 -0
  132. package/fonts/KaTeX_Caligraphic-Regular.woff2 +0 -0
  133. package/fonts/KaTeX_Fraktur-Bold.ttf +0 -0
  134. package/fonts/KaTeX_Fraktur-Bold.woff +0 -0
  135. package/fonts/KaTeX_Fraktur-Bold.woff2 +0 -0
  136. package/fonts/KaTeX_Fraktur-Regular.ttf +0 -0
  137. package/fonts/KaTeX_Fraktur-Regular.woff +0 -0
  138. package/fonts/KaTeX_Fraktur-Regular.woff2 +0 -0
  139. package/fonts/KaTeX_Main-Bold.ttf +0 -0
  140. package/fonts/KaTeX_Main-Bold.woff +0 -0
  141. package/fonts/KaTeX_Main-Bold.woff2 +0 -0
  142. package/fonts/KaTeX_Main-BoldItalic.ttf +0 -0
  143. package/fonts/KaTeX_Main-BoldItalic.woff +0 -0
  144. package/fonts/KaTeX_Main-BoldItalic.woff2 +0 -0
  145. package/fonts/KaTeX_Main-Italic.ttf +0 -0
  146. package/fonts/KaTeX_Main-Italic.woff +0 -0
  147. package/fonts/KaTeX_Main-Italic.woff2 +0 -0
  148. package/fonts/KaTeX_Main-Regular.ttf +0 -0
  149. package/fonts/KaTeX_Main-Regular.woff +0 -0
  150. package/fonts/KaTeX_Main-Regular.woff2 +0 -0
  151. package/fonts/KaTeX_Math-BoldItalic.ttf +0 -0
  152. package/fonts/KaTeX_Math-BoldItalic.woff +0 -0
  153. package/fonts/KaTeX_Math-BoldItalic.woff2 +0 -0
  154. package/fonts/KaTeX_Math-Italic.ttf +0 -0
  155. package/fonts/KaTeX_Math-Italic.woff +0 -0
  156. package/fonts/KaTeX_Math-Italic.woff2 +0 -0
  157. package/fonts/KaTeX_SansSerif-Bold.ttf +0 -0
  158. package/fonts/KaTeX_SansSerif-Bold.woff +0 -0
  159. package/fonts/KaTeX_SansSerif-Bold.woff2 +0 -0
  160. package/fonts/KaTeX_SansSerif-Italic.ttf +0 -0
  161. package/fonts/KaTeX_SansSerif-Italic.woff +0 -0
  162. package/fonts/KaTeX_SansSerif-Italic.woff2 +0 -0
  163. package/fonts/KaTeX_SansSerif-Regular.ttf +0 -0
  164. package/fonts/KaTeX_SansSerif-Regular.woff +0 -0
  165. package/fonts/KaTeX_SansSerif-Regular.woff2 +0 -0
  166. package/fonts/KaTeX_Script-Regular.ttf +0 -0
  167. package/fonts/KaTeX_Script-Regular.woff +0 -0
  168. package/fonts/KaTeX_Script-Regular.woff2 +0 -0
  169. package/fonts/KaTeX_Size1-Regular.ttf +0 -0
  170. package/fonts/KaTeX_Size1-Regular.woff +0 -0
  171. package/fonts/KaTeX_Size1-Regular.woff2 +0 -0
  172. package/fonts/KaTeX_Size2-Regular.ttf +0 -0
  173. package/fonts/KaTeX_Size2-Regular.woff +0 -0
  174. package/fonts/KaTeX_Size2-Regular.woff2 +0 -0
  175. package/fonts/KaTeX_Size3-Regular.ttf +0 -0
  176. package/fonts/KaTeX_Size3-Regular.woff +0 -0
  177. package/fonts/KaTeX_Size3-Regular.woff2 +0 -0
  178. package/fonts/KaTeX_Size4-Regular.ttf +0 -0
  179. package/fonts/KaTeX_Size4-Regular.woff +0 -0
  180. package/fonts/KaTeX_Size4-Regular.woff2 +0 -0
  181. package/fonts/KaTeX_Typewriter-Regular.ttf +0 -0
  182. package/fonts/KaTeX_Typewriter-Regular.woff +0 -0
  183. package/fonts/KaTeX_Typewriter-Regular.woff2 +0 -0
  184. package/index.html +15 -0
  185. package/katex.min.css +1 -0
  186. package/logo.png +0 -0
  187. package/package.json +31 -4
  188. package/plugin.json +241 -0
  189. package/preload/branch-bar.js +159 -0
  190. package/preload/git-panel.js +1311 -0
  191. package/preload/git-service.js +1403 -0
  192. package/preload/ndb.js +1407 -0
  193. package/preload/package.json +3 -0
  194. package/preload/rename-note.js +151 -0
  195. package/preload/services.js +432 -0
  196. package/preload/settings-panel.js +847 -0
  197. package/preload.js +1615 -0
@@ -0,0 +1,140 @@
1
+ import{g as Re}from"./chunk-5VM5RSS4-Diy5h2LS.js";import{_ as c,L as P,k as H,ag as Pe,ah as Fe,d as Me,l as y,z as Ke,B as Ye,C as We,D as Ve,E as je,F as Ue,G as He,c as Se,ai as Ge,aj as Xe,ak as qe,al as Je,m as Ze,am as Qe,ae as xe,an as $e,af as et}from"./mermaid-C_q9pug0.js";import{G as tt}from"./graph-D8UmR1vK.js";import"./markdown-DVehI1Sg.js";var re=(function(){var e=c(function(v,g,r,a){for(r=r||{},a=v.length;a--;r[v[a]]=g);return r},"o"),o=[1,15],l=[1,7],n=[1,13],h=[1,14],p=[1,19],t=[1,16],u=[1,17],x=[1,18],L=[8,30],b=[8,10,21,28,29,30,31,39,43,46],f=[1,23],m=[1,24],E=[8,10,15,16,21,28,29,30,31,39,43,46],S=[8,10,15,16,21,27,28,29,30,31,39,43,46],_=[1,49],w={trace:c(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:c(function(g,r,a,d,k,s,K){var i=s.length-1;switch(k){case 4:d.getLogger().debug("Rule: separator (NL) ");break;case 5:d.getLogger().debug("Rule: separator (Space) ");break;case 6:d.getLogger().debug("Rule: separator (EOF) ");break;case 7:d.getLogger().debug("Rule: hierarchy: ",s[i-1]),d.setHierarchy(s[i-1]);break;case 8:d.getLogger().debug("Stop NL ");break;case 9:d.getLogger().debug("Stop EOF ");break;case 10:d.getLogger().debug("Stop NL2 ");break;case 11:d.getLogger().debug("Stop EOF2 ");break;case 12:d.getLogger().debug("Rule: statement: ",s[i]),typeof s[i].length=="number"?this.$=s[i]:this.$=[s[i]];break;case 13:d.getLogger().debug("Rule: statement #2: ",s[i-1]),this.$=[s[i-1]].concat(s[i]);break;case 14:d.getLogger().debug("Rule: link: ",s[i],g),this.$={edgeTypeStr:s[i],label:""};break;case 15:d.getLogger().debug("Rule: LABEL link: ",s[i-3],s[i-1],s[i]),this.$={edgeTypeStr:s[i],label:s[i-1]};break;case 18:const F=parseInt(s[i]),W=d.generateId();this.$={id:W,type:"space",label:"",width:F,children:[]};break;case 23:d.getLogger().debug("Rule: (nodeStatement link node) ",s[i-2],s[i-1],s[i]," typestr: ",s[i-1].edgeTypeStr);const J=d.edgeStrToEdgeData(s[i-1].edgeTypeStr),V=d.edgeStrToEdgeStartData(s[i-1].edgeTypeStr),Z=d.edgeStrToThickness(s[i-1].edgeTypeStr),D=d.edgeStrToPattern(s[i-1].edgeTypeStr);this.$=[{id:s[i-2].id,label:s[i-2].label,type:s[i-2].type,directions:s[i-2].directions},{id:s[i-2].id+"-"+s[i].id,start:s[i-2].id,end:s[i].id,label:s[i-1].label,type:"edge",thickness:Z,pattern:D,directions:s[i].directions,arrowTypeEnd:J,arrowTypeStart:V},{id:s[i].id,label:s[i].label,type:d.typeStr2Type(s[i].typeStr),directions:s[i].directions}];break;case 24:d.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[i-1],s[i]),this.$={id:s[i-1].id,label:s[i-1].label,type:d.typeStr2Type(s[i-1].typeStr),directions:s[i-1].directions,widthInColumns:parseInt(s[i],10)};break;case 25:d.getLogger().debug("Rule: nodeStatement (node) ",s[i]),this.$={id:s[i].id,label:s[i].label,type:d.typeStr2Type(s[i].typeStr),directions:s[i].directions,widthInColumns:1};break;case 26:d.getLogger().debug("APA123",this?this:"na"),d.getLogger().debug("COLUMNS: ",s[i]),this.$={type:"column-setting",columns:s[i]==="auto"?-1:parseInt(s[i])};break;case 27:d.getLogger().debug("Rule: id-block statement : ",s[i-2],s[i-1]),d.generateId(),this.$={...s[i-2],type:"composite",children:s[i-1]};break;case 28:d.getLogger().debug("Rule: blockStatement : ",s[i-2],s[i-1],s[i]);const B=d.generateId();this.$={id:B,type:"composite",label:"",children:s[i-1]};break;case 29:d.getLogger().debug("Rule: node (NODE_ID separator): ",s[i]),this.$={id:s[i]};break;case 30:d.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[i-1],s[i]),this.$={id:s[i-1],label:s[i].label,typeStr:s[i].typeStr,directions:s[i].directions};break;case 31:d.getLogger().debug("Rule: dirList: ",s[i]),this.$=[s[i]];break;case 32:d.getLogger().debug("Rule: dirList: ",s[i-1],s[i]),this.$=[s[i-1]].concat(s[i]);break;case 33:d.getLogger().debug("Rule: nodeShapeNLabel: ",s[i-2],s[i-1],s[i]),this.$={typeStr:s[i-2]+s[i],label:s[i-1]};break;case 34:d.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[i-3],s[i-2]," #3:",s[i-1],s[i]),this.$={typeStr:s[i-3]+s[i],label:s[i-2],directions:s[i-1]};break;case 35:case 36:this.$={type:"classDef",id:s[i-1].trim(),css:s[i].trim()};break;case 37:this.$={type:"applyClass",id:s[i-1].trim(),styleClass:s[i].trim()};break;case 38:this.$={type:"applyStyles",id:s[i-1].trim(),stylesStr:s[i].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:o,11:3,13:4,19:5,20:6,21:l,22:8,23:9,24:10,25:11,26:12,28:n,29:h,31:p,39:t,43:u,46:x},{8:[1,20]},e(L,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:o,21:l,28:n,29:h,31:p,39:t,43:u,46:x}),e(b,[2,16],{14:22,15:f,16:m}),e(b,[2,17]),e(b,[2,18]),e(b,[2,19]),e(b,[2,20]),e(b,[2,21]),e(b,[2,22]),e(E,[2,25],{27:[1,25]}),e(b,[2,26]),{19:26,26:12,31:p},{10:o,11:27,13:4,19:5,20:6,21:l,22:8,23:9,24:10,25:11,26:12,28:n,29:h,31:p,39:t,43:u,46:x},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(S,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(L,[2,13]),{26:35,31:p},{31:[2,14]},{17:[1,36]},e(E,[2,24]),{10:o,11:37,13:4,14:22,15:f,16:m,19:5,20:6,21:l,22:8,23:9,24:10,25:11,26:12,28:n,29:h,31:p,39:t,43:u,46:x},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(S,[2,30]),{18:[1,43]},{18:[1,44]},e(E,[2,23]),{18:[1,45]},{30:[1,46]},e(b,[2,28]),e(b,[2,35]),e(b,[2,36]),e(b,[2,37]),e(b,[2,38]),{36:[1,47]},{33:48,34:_},{15:[1,50]},e(b,[2,27]),e(S,[2,33]),{38:[1,51]},{33:52,34:_,38:[2,31]},{31:[2,15]},e(S,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:c(function(g,r){if(r.recoverable)this.trace(g);else{var a=new Error(g);throw a.hash=r,a}},"parseError"),parse:c(function(g){var r=this,a=[0],d=[],k=[null],s=[],K=this.table,i="",F=0,W=0,J=2,V=1,Z=s.slice.call(arguments,1),D=Object.create(this.lexer),B={yy:{}};for(var Q in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Q)&&(B.yy[Q]=this.yy[Q]);D.setInput(g,B.yy),B.yy.lexer=D,B.yy.parser=this,typeof D.yylloc>"u"&&(D.yylloc={});var $=D.yylloc;s.push($);var Be=D.options&&D.options.ranges;typeof B.yy.parseError=="function"?this.parseError=B.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Ae(T){a.length=a.length-2*T,k.length=k.length-T,s.length=s.length-T}c(Ae,"popStack");function ge(){var T;return T=d.pop()||D.lex()||V,typeof T!="number"&&(T instanceof Array&&(d=T,T=d.pop()),T=r.symbols_[T]||T),T}c(ge,"lex");for(var N,R,O,ee,M={},j,A,de,U;;){if(R=a[a.length-1],this.defaultActions[R]?O=this.defaultActions[R]:((N===null||typeof N>"u")&&(N=ge()),O=K[R]&&K[R][N]),typeof O>"u"||!O.length||!O[0]){var te="";U=[];for(j in K[R])this.terminals_[j]&&j>J&&U.push("'"+this.terminals_[j]+"'");D.showPosition?te="Parse error on line "+(F+1)+`:
2
+ `+D.showPosition()+`
3
+ Expecting `+U.join(", ")+", got '"+(this.terminals_[N]||N)+"'":te="Parse error on line "+(F+1)+": Unexpected "+(N==V?"end of input":"'"+(this.terminals_[N]||N)+"'"),this.parseError(te,{text:D.match,token:this.terminals_[N]||N,line:D.yylineno,loc:$,expected:U})}if(O[0]instanceof Array&&O.length>1)throw new Error("Parse Error: multiple actions possible at state: "+R+", token: "+N);switch(O[0]){case 1:a.push(N),k.push(D.yytext),s.push(D.yylloc),a.push(O[1]),N=null,W=D.yyleng,i=D.yytext,F=D.yylineno,$=D.yylloc;break;case 2:if(A=this.productions_[O[1]][1],M.$=k[k.length-A],M._$={first_line:s[s.length-(A||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(A||1)].first_column,last_column:s[s.length-1].last_column},Be&&(M._$.range=[s[s.length-(A||1)].range[0],s[s.length-1].range[1]]),ee=this.performAction.apply(M,[i,W,F,B.yy,O[1],k,s].concat(Z)),typeof ee<"u")return ee;A&&(a=a.slice(0,-1*A*2),k=k.slice(0,-1*A),s=s.slice(0,-1*A)),a.push(this.productions_[O[1]][0]),k.push(M.$),s.push(M._$),de=K[a[a.length-2]][a[a.length-1]],a.push(de);break;case 3:return!0}}return!0},"parse")},I=(function(){var v={EOF:1,parseError:c(function(r,a){if(this.yy.parser)this.yy.parser.parseError(r,a);else throw new Error(r)},"parseError"),setInput:c(function(g,r){return this.yy=r||this.yy||{},this._input=g,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:c(function(){var g=this._input[0];this.yytext+=g,this.yyleng++,this.offset++,this.match+=g,this.matched+=g;var r=g.match(/(?:\r\n?|\n).*/g);return r?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),g},"input"),unput:c(function(g){var r=g.length,a=g.split(/(?:\r\n?|\n)/g);this._input=g+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-r),this.offset-=r;var d=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),a.length-1&&(this.yylineno-=a.length-1);var k=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:a?(a.length===d.length?this.yylloc.first_column:0)+d[d.length-a.length].length-a[0].length:this.yylloc.first_column-r},this.options.ranges&&(this.yylloc.range=[k[0],k[0]+this.yyleng-r]),this.yyleng=this.yytext.length,this},"unput"),more:c(function(){return this._more=!0,this},"more"),reject:c(function(){if(this.options.backtrack_lexer)this._backtrack=!0;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).
4
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:c(function(g){this.unput(this.match.slice(g))},"less"),pastInput:c(function(){var g=this.matched.substr(0,this.matched.length-this.match.length);return(g.length>20?"...":"")+g.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:c(function(){var g=this.match;return g.length<20&&(g+=this._input.substr(0,20-g.length)),(g.substr(0,20)+(g.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:c(function(){var g=this.pastInput(),r=new Array(g.length+1).join("-");return g+this.upcomingInput()+`
5
+ `+r+"^"},"showPosition"),test_match:c(function(g,r){var a,d,k;if(this.options.backtrack_lexer&&(k={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(k.yylloc.range=this.yylloc.range.slice(0))),d=g[0].match(/(?:\r\n?|\n).*/g),d&&(this.yylineno+=d.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:d?d[d.length-1].length-d[d.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+g[0].length},this.yytext+=g[0],this.match+=g[0],this.matches=g,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(g[0].length),this.matched+=g[0],a=this.performAction.call(this,this.yy,this,r,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),a)return a;if(this._backtrack){for(var s in k)this[s]=k[s];return!1}return!1},"test_match"),next:c(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var g,r,a,d;this._more||(this.yytext="",this.match="");for(var k=this._currentRules(),s=0;s<k.length;s++)if(a=this._input.match(this.rules[k[s]]),a&&(!r||a[0].length>r[0].length)){if(r=a,d=s,this.options.backtrack_lexer){if(g=this.test_match(a,k[s]),g!==!1)return g;if(this._backtrack){r=!1;continue}else return!1}else if(!this.options.flex)break}return r?(g=this.test_match(r,k[d]),g!==!1?g:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:c(function(){var r=this.next();return r||this.lex()},"lex"),begin:c(function(r){this.conditionStack.push(r)},"begin"),popState:c(function(){var r=this.conditionStack.length-1;return r>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:c(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:c(function(r){return r=this.conditionStack.length-1-Math.abs(r||0),r>=0?this.conditionStack[r]:"INITIAL"},"topState"),pushState:c(function(r){this.begin(r)},"pushState"),stateStackSize:c(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:c(function(r,a,d,k){switch(d){case 0:return r.getLogger().debug("Found block-beta"),10;case 1:return r.getLogger().debug("Found id-block"),29;case 2:return r.getLogger().debug("Found block"),10;case 3:r.getLogger().debug(".",a.yytext);break;case 4:r.getLogger().debug("_",a.yytext);break;case 5:return 5;case 6:return a.yytext=-1,28;case 7:return a.yytext=a.yytext.replace(/columns\s+/,""),r.getLogger().debug("COLUMNS (LEX)",a.yytext),28;case 8:this.pushState("md_string");break;case 9:return"MD_STR";case 10:this.popState();break;case 11:this.pushState("string");break;case 12:r.getLogger().debug("LEX: POPPING STR:",a.yytext),this.popState();break;case 13:return r.getLogger().debug("LEX: STR end:",a.yytext),"STR";case 14:return a.yytext=a.yytext.replace(/space\:/,""),r.getLogger().debug("SPACE NUM (LEX)",a.yytext),21;case 15:return a.yytext="1",r.getLogger().debug("COLUMNS (LEX)",a.yytext),21;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 21:return this.popState(),this.pushState("CLASSDEFID"),40;case 22:return this.popState(),41;case 23:return this.pushState("CLASS"),43;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;case 25:return this.popState(),45;case 26:return this.pushState("STYLE_STMNT"),46;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;case 28:return this.popState(),48;case 29:return this.pushState("acc_title"),"acc_title";case 30:return this.popState(),"acc_title_value";case 31:return this.pushState("acc_descr"),"acc_descr";case 32:return this.popState(),"acc_descr_value";case 33:this.pushState("acc_descr_multiline");break;case 34:this.popState();break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:return this.popState(),r.getLogger().debug("Lex: (("),"NODE_DEND";case 38:return this.popState(),r.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),r.getLogger().debug("Lex: ))"),"NODE_DEND";case 40:return this.popState(),r.getLogger().debug("Lex: (("),"NODE_DEND";case 41:return this.popState(),r.getLogger().debug("Lex: (("),"NODE_DEND";case 42:return this.popState(),r.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),r.getLogger().debug("Lex: -)"),"NODE_DEND";case 44:return this.popState(),r.getLogger().debug("Lex: (("),"NODE_DEND";case 45:return this.popState(),r.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),r.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),r.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:return this.popState(),r.getLogger().debug("Lex: /]"),"NODE_DEND";case 49:return this.popState(),r.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),r.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),r.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),r.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),r.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return r.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return r.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return r.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:return r.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return r.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 59:return r.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 60:return r.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 61:return r.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 62:return r.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return r.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 64:return r.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 65:return this.pushState("NODE"),35;case 66:return this.pushState("NODE"),35;case 67:return this.pushState("NODE"),35;case 68:return this.pushState("NODE"),35;case 69:return this.pushState("NODE"),35;case 70:return this.pushState("NODE"),35;case 71:return this.pushState("NODE"),35;case 72:return r.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),r.getLogger().debug("LEX ARR START"),37;case 74:return r.getLogger().debug("Lex: NODE_ID",a.yytext),31;case 75:return r.getLogger().debug("Lex: EOF",a.yytext),8;case 76:this.pushState("md_string");break;case 77:this.pushState("md_string");break;case 78:return"NODE_DESCR";case 79:this.popState();break;case 80:r.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:r.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return r.getLogger().debug("LEX: NODE_DESCR:",a.yytext),"NODE_DESCR";case 83:r.getLogger().debug("LEX POPPING"),this.popState();break;case 84:r.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (right): dir:",a.yytext),"DIR";case 86:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (left):",a.yytext),"DIR";case 87:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (x):",a.yytext),"DIR";case 88:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (y):",a.yytext),"DIR";case 89:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (up):",a.yytext),"DIR";case 90:return a.yytext=a.yytext.replace(/^,\s*/,""),r.getLogger().debug("Lex (down):",a.yytext),"DIR";case 91:return a.yytext="]>",r.getLogger().debug("Lex (ARROW_DIR end):",a.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return r.getLogger().debug("Lex: LINK","#"+a.yytext+"#"),15;case 93:return r.getLogger().debug("Lex: LINK",a.yytext),15;case 94:return r.getLogger().debug("Lex: LINK",a.yytext),15;case 95:return r.getLogger().debug("Lex: LINK",a.yytext),15;case 96:return r.getLogger().debug("Lex: START_LINK",a.yytext),this.pushState("LLABEL"),16;case 97:return r.getLogger().debug("Lex: START_LINK",a.yytext),this.pushState("LLABEL"),16;case 98:return r.getLogger().debug("Lex: START_LINK",a.yytext),this.pushState("LLABEL"),16;case 99:this.pushState("md_string");break;case 100:return r.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),r.getLogger().debug("Lex: LINK","#"+a.yytext+"#"),15;case 102:return this.popState(),r.getLogger().debug("Lex: LINK",a.yytext),15;case 103:return this.popState(),r.getLogger().debug("Lex: LINK",a.yytext),15;case 104:return r.getLogger().debug("Lex: COLON",a.yytext),a.yytext=a.yytext.slice(1),27}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}};return v})();w.lexer=I;function C(){this.yy={}}return c(C,"Parser"),C.prototype=w,w.Parser=C,new C})();re.parser=re;var st=re,z=new Map,ae=[],ie=new Map,pe="color",fe="fill",rt="bgFill",Le=",",G=new Map,oe="",it=c(e=>Ze.sanitizeText(e,Se()),"sanitizeText"),nt=c(function(e,o=""){let l=G.get(e);l||(l={id:e,styles:[],textStyles:[]},G.set(e,l)),o?.split(Le).forEach(n=>{const h=n.replace(/([^;]*);/,"$1").trim();if(RegExp(pe).exec(n)){const t=h.replace(fe,rt).replace(pe,fe);l.textStyles.push(t)}l.styles.push(h)})},"addStyleClass"),at=c(function(e,o=""){const l=z.get(e);o!=null&&(l.styles=o.split(Le))},"addStyle2Node"),ot=c(function(e,o){e.split(",").forEach(function(l){let n=z.get(l);if(n===void 0){const h=l.trim();n={id:h,type:"na",children:[]},z.set(h,n)}n.classes||(n.classes=[]),n.classes.push(o)})},"setCssClass"),me=0,ye=c((e,o)=>{const l=e.flat(),n=[],p=l.find(t=>t?.type==="column-setting")?.columns??-1;for(const t of l){if(typeof p=="number"&&p>0&&t.type!=="column-setting"&&typeof t.widthInColumns=="number"&&t.widthInColumns>p&&y.warn(`Block ${t.id} width ${t.widthInColumns} exceeds configured column width ${p}`),t.label&&(t.label=it(t.label)),t.type==="classDef"){nt(t.id,t.css);continue}if(t.type==="applyClass"){ot(t.id,t?.styleClass??"");continue}if(t.type==="applyStyles"){t?.stylesStr&&at(t.id,t?.stylesStr);continue}if(t.type==="column-setting")o.columns=t.columns??-1;else if(t.type==="edge"){const u=(ie.get(t.id)??0)+1;ie.set(t.id,u),t.id=u+"-"+t.id,ae.push(t)}else{t.label||(t.type==="composite"?t.label="":t.label=t.id);const u=z.get(t.id);if(u===void 0?(t.type==="composite"&&(t.colorIndex=me++),z.set(t.id,t)):(t.type!=="na"&&(u.type=t.type),t.label!==t.id&&(u.label=t.label)),t.children&&ye(t.children,t),t.type==="space"){const x=t.width??1;for(let L=0;L<x;L++){const b=Je(t);b.id=b.id+"-"+L,z.set(b.id,b),n.push(b)}}else u===void 0&&n.push(t)}}o.children=n},"populateBlockDatabase"),le=[],Y={id:"root",type:"composite",children:[],columns:-1},lt=c(()=>{y.debug("Clear called"),Ke(),Y={id:"root",type:"composite",children:[],columns:-1},z=new Map([["root",Y]]),le=[],G=new Map,ae=[],ie=new Map,oe="",me=0},"clear");function Ee(e){switch(y.debug("typeStr2Type",e),e){case"[]":return"square";case"()":return y.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}c(Ee,"typeStr2Type");function ke(e){switch(y.debug("typeStr2Type",e),e){case"==":return"thick";default:return"normal"}}c(ke,"edgeTypeStr2Type");function we(e){switch(e.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}c(we,"edgeStrToEdgeData");function _e(e){switch(e.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}c(_e,"edgeStrToEdgeStartData");function De(e){return e.includes("==")?"thick":"normal"}c(De,"edgeStrToThickness");function Ie(e){return e.includes(".-")?"dotted":"solid"}c(Ie,"edgeStrToPattern");var be=0,ct=c(()=>(be++,"id-"+Math.random().toString(36).substr(2,12)+"-"+be),"generateId"),ht=c(e=>{Y.children=e,ye(e,Y),le=Y.children},"setHierarchy"),ut=c(e=>{const o=z.get(e);return o?o.columns?o.columns:o.children?o.children.length:-1:-1},"getColumns"),gt=c(()=>[...z.values()],"getBlocksFlat"),dt=c(()=>le||[],"getBlocks"),pt=c(()=>ae,"getEdges"),ft=c(e=>z.get(e),"getBlock"),bt=c(e=>{z.set(e.id,e)},"setBlock"),St=c(e=>{oe=e},"setDiagramId"),xt=c(()=>oe,"getDiagramId"),Lt=c(()=>y,"getLogger"),mt=c(function(){return G},"getClasses"),yt={getConfig:c(()=>P().block,"getConfig"),typeStr2Type:Ee,edgeTypeStr2Type:ke,edgeStrToEdgeData:we,edgeStrToEdgeStartData:_e,edgeStrToThickness:De,edgeStrToPattern:Ie,getLogger:Lt,getBlocksFlat:gt,getBlocks:dt,getEdges:pt,setHierarchy:ht,getBlock:ft,setBlock:bt,getColumns:ut,getClasses:mt,clear:lt,generateId:ct,setDiagramId:St,getDiagramId:xt},Et=yt,kt=c(e=>{const{theme:o,bkgColorArray:l,borderColorArray:n}=e;if(!Ye(o,n))return"";const h=We(e.look),p=Ve(l);let t="";for(let u=0;u<je(e.THEME_COLOR_LIMIT,n);u++){const x=n[u%n.length],L=p?`fill: ${l[u%l.length]};`:"",b=`[data-look="${h}"][data-color-id="color-${u}"]`;t+=`
7
+
8
+ ${b}.node rect.composite {
9
+ stroke: ${x};
10
+ ${L}
11
+ }
12
+ `}return t},"genColor"),se=c((e,o)=>{const l=He,n=l(e,"r"),h=l(e,"g"),p=l(e,"b");return Ue(n,h,p,o)},"fade"),wt=c(e=>`${kt(e)}
13
+ .label {
14
+ font-family: ${e.fontFamily};
15
+ color: ${e.nodeTextColor||e.textColor};
16
+ }
17
+ .cluster-label text {
18
+ fill: ${e.titleColor};
19
+ }
20
+ .cluster-label span {
21
+ color: ${e.titleColor};
22
+ }
23
+
24
+
25
+
26
+ .label text,span {
27
+ fill: ${e.nodeTextColor||e.textColor};
28
+ color: ${e.nodeTextColor||e.textColor};
29
+ }
30
+
31
+ .node rect,
32
+ .node circle,
33
+ .node ellipse,
34
+ .node polygon,
35
+ .node path {
36
+ fill: ${e.mainBkg};
37
+ stroke: ${e.nodeBorder};
38
+ /* From the theme, as every other diagram does. Pinned at 1px here, so block drew a
39
+ thinner border than an identical flowchart node under any theme asking for more --
40
+ the neo theme asks for 2. Nothing downstream corrected it: the neo rules set stroke
41
+ and filter, never stroke-width. */
42
+ stroke-width: ${e.strokeWidth??1}px;
43
+ }
44
+ .flowchart-label text {
45
+ text-anchor: middle;
46
+ }
47
+ // .flowchart-label .text-outer-tspan {
48
+ // text-anchor: middle;
49
+ // }
50
+ // .flowchart-label .text-inner-tspan {
51
+ // text-anchor: start;
52
+ // }
53
+
54
+ .node .label {
55
+ text-align: center;
56
+ }
57
+ .node.clickable {
58
+ cursor: pointer;
59
+ }
60
+
61
+ .arrowheadPath {
62
+ fill: ${e.arrowheadColor};
63
+ }
64
+
65
+ .edgePaths .path {
66
+ stroke: ${e.lineColor};
67
+ stroke-width: 2.0px;
68
+ }
69
+
70
+ .flowchart-link {
71
+ stroke: ${e.lineColor};
72
+ fill: none;
73
+ }
74
+
75
+ .edgeLabel {
76
+ background-color: ${e.edgeLabelBackground};
77
+ /*
78
+ * This is for backward compatibility with existing code that didn't
79
+ * add a \`<p>\` around edge labels.
80
+ *
81
+ * TODO: We should probably remove this in a future release.
82
+ */
83
+ p {
84
+ margin: 0;
85
+ padding: 0;
86
+ display: inline;
87
+ }
88
+ rect {
89
+ opacity: 0.5;
90
+ background-color: ${e.edgeLabelBackground};
91
+ fill: ${e.edgeLabelBackground};
92
+ }
93
+ text-align: center;
94
+ }
95
+
96
+ /* For html labels only */
97
+ .labelBkg {
98
+ background-color: ${e.edgeLabelBackground};
99
+ }
100
+
101
+ .node .cluster {
102
+ // fill: ${se(e.mainBkg,.5)};
103
+ fill: ${se(e.clusterBkg,.5)};
104
+ stroke: ${se(e.clusterBorder,.2)};
105
+ box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
106
+ stroke-width: 1px;
107
+ }
108
+
109
+ .cluster text {
110
+ fill: ${e.titleColor};
111
+ }
112
+
113
+ .cluster span {
114
+ color: ${e.titleColor};
115
+ }
116
+ /* .cluster div {
117
+ color: ${e.titleColor};
118
+ } */
119
+
120
+ div.mermaidTooltip {
121
+ position: absolute;
122
+ text-align: center;
123
+ max-width: 200px;
124
+ padding: 2px;
125
+ font-family: ${e.fontFamily};
126
+ font-size: 12px;
127
+ background: ${e.tertiaryColor};
128
+ border: 1px solid ${e.border2};
129
+ border-radius: 2px;
130
+ pointer-events: none;
131
+ z-index: 100;
132
+ }
133
+
134
+ .flowchartTitleText {
135
+ text-anchor: middle;
136
+ font-size: 18px;
137
+ fill: ${e.textColor};
138
+ }
139
+ ${Re()}
140
+ `,"getStyles"),_t=wt;function ne(e,o){if(e===0||!Number.isInteger(e))throw new Error("Columns must be an integer !== 0.");if(o<0||!Number.isInteger(o))throw new Error("Position must be a non-negative integer."+o);if(e<0)return{px:o,py:0};if(e===1)return{px:0,py:o};const l=o%e,n=Math.floor(o/e);return{px:l,py:n}}c(ne,"calculateBlockPosition");var Dt=c(e=>{let o=0,l=0;for(const n of e.children){const{width:h,height:p,x:t,y:u}=n.size??{width:0,height:0,x:0,y:0};if(y.debug("getMaxChildSize abc95 child:",n.id,"width:",h,"height:",p,"x:",t,"y:",u,n.type),n.type==="space")continue;const x=h/(n.widthInColumns??1);x>o&&(o=x),p>l&&(l=p)}return{width:o,height:l}},"getMaxChildSize");function X(e,o,l=0,n=0,h=8){y.debug("setBlockSizes abc95 (start)",e.id,e?.size?.x,"block width =",e?.size,"siblingWidth",l),e?.size?.width||(e.size={width:l,height:n,x:0,y:0});let p=0,t=0;if(e.children?.length>0){for(const S of e.children)X(S,o,0,0,h);const u=Dt(e);p=u.width,t=u.height,y.debug("setBlockSizes abc95 maxWidth of",e.id,":s children is ",p,t);for(const S of e.children)S.size&&(y.debug(`abc95 Setting size of children of ${e.id} id=${S.id} ${p} ${t} ${JSON.stringify(S.size)}`),S.size.width=p*(S.widthInColumns??1)+h*((S.widthInColumns??1)-1),S.size.height=t,S.size.x=0,S.size.y=0,y.debug(`abc95 updating size of ${e.id} children child:${S.id} maxWidth:${p} maxHeight:${t}`));for(const S of e.children)X(S,o,p,t,h);const x=e.columns??-1;let L=0;for(const S of e.children)L+=S.widthInColumns??1;let b=e.children.length;x>0&&x<L&&(b=x);const f=Math.ceil(L/b);let m=b*(p+h)+h,E=f*(t+h)+h;if(m<l){y.debug(`Detected to small sibling: abc95 ${e.id} siblingWidth ${l} siblingHeight ${n} width ${m}`),m=l,E=n;const S=(l-b*h-h)/b,_=(n-f*h-h)/f;y.debug("Size indata abc88",e.id,"childWidth",S,"maxWidth",p),y.debug("Size indata abc88",e.id,"childHeight",_,"maxHeight",t),y.debug("Size indata abc88 xSize",b,"padding",h);for(const w of e.children)w.size&&(w.size.width=S,w.size.height=_,w.size.x=0,w.size.y=0)}if(y.debug(`abc95 (finale calc) ${e.id} xSize ${b} ySize ${f} columns ${x}${e.children.length} width=${Math.max(m,e.size?.width||0)}`),m<(e?.size?.width||0)){m=e?.size?.width||0;const S=x>0?Math.min(e.children.length,x):e.children.length;if(S>0){const _=(m-S*h-h)/S;y.debug("abc95 (growing to fit) width",e.id,m,e.size?.width,_);for(const w of e.children)w.size&&(w.size.width=_)}}e.size={width:m,height:E,x:0,y:0}}y.debug("setBlockSizes abc94 (done)",e.id,e?.size?.x,e?.size?.width,e?.size?.y,e?.size?.height)}c(X,"setBlockSizes");function ce(e,o,l=8){y.debug(`abc85 layout blocks (=>layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`);const n=e.columns??-1;if(y.debug("layoutBlocks columns abc95",e.id,"=>",n,e),e.children&&e.children.length>0){const h=e?.children[0]?.size?.width??0,p=e.children.length*h+(e.children.length-1)*l;y.debug("widthOfChildren 88",p,"posX");const t=new Map;{let f=0;for(const m of e.children){if(!m.size)continue;const{py:E}=ne(n,f),S=t.get(E)??0;m.size.height>S&&t.set(E,m.size.height);let _=m?.widthInColumns??1;n>0&&(_=Math.min(_,n-f%n)),f+=_}}const u=new Map;{let f=0;const m=[...t.keys()].sort((E,S)=>E-S);for(const E of m)u.set(E,f),f+=(t.get(E)??0)+l}let x=0;y.debug("abc91 block?.size?.x",e.id,e?.size?.x);let L=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-l,b=0;for(const f of e.children){const m=e;if(!f.size)continue;const{width:E,height:S}=f.size,{px:_,py:w}=ne(n,x);if(w!=b&&(b=w,L=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-l,y.debug("New row in layout for block",e.id," and child ",f.id,b)),y.debug(`abc89 layout blocks (child) id: ${f.id} Pos: ${x} (px, py) ${_},${w} (${m?.size?.x},${m?.size?.y}) parent: ${m.id} width: ${E}${l}`),m.size){const C=E/2;f.size.x=L+l+C,y.debug(`abc91 layout blocks (calc) px, pyid:${f.id} startingPos=X${L} new startingPosX${f.size.x} ${C} padding=${l} width=${E} halfWidth=${C} => x:${f.size.x} y:${f.size.y} ${f.widthInColumns} (width * (child?.w || 1)) / 2 ${E*(f?.widthInColumns??1)/2}`),L=f.size.x+C;const v=u.get(w)??0,g=t.get(w)??S;f.size.y=m.size.y-m.size.height/2+v+g/2+l,y.debug(`abc88 layout blocks (calc) px, pyid:${f.id}startingPosX${L}${l}${C}=>x:${f.size.x}y:${f.size.y}${f.widthInColumns}(width * (child?.w || 1)) / 2${E*(f?.widthInColumns??1)/2}`)}f.children&&ce(f,o,l);let I=f?.widthInColumns??1;n>0&&(I=Math.min(I,n-x%n)),x+=I,y.debug("abc88 columnsPos",f,x)}}y.debug(`layout blocks (<==layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`)}c(ce,"layoutBlocks");function he(e,{minX:o,minY:l,maxX:n,maxY:h}={minX:0,minY:0,maxX:0,maxY:0}){if(e.size&&e.id!=="root"){const{x:p,y:t,width:u,height:x}=e.size;p-u/2<o&&(o=p-u/2),t-x/2<l&&(l=t-x/2),p+u/2>n&&(n=p+u/2),t+x/2>h&&(h=t+x/2)}if(e.children)for(const p of e.children)({minX:o,minY:l,maxX:n,maxY:h}=he(p,{minX:o,minY:l,maxX:n,maxY:h}));return{minX:o,minY:l,maxX:n,maxY:h}}c(he,"findBounds");function Ne(e){const o=e.getBlock("root");if(!o)return;const l=Se()?.block?.padding??8;X(o,e,0,0,l),ce(o,e,l),y.debug("getBlocks",JSON.stringify(o,null,2));const{minX:n,minY:h,maxX:p,maxY:t}=he(o),u=t-h,x=p-n;return{x:n,y:h,width:x,height:u}}c(Ne,"layout");function ue(e,o,l=!1){const n=e;let h="default";(n?.classes?.length||0)>0&&(h=(n?.classes??[]).join(" ")),h=h+" flowchart-label";const p=(n?.classes??[]).flatMap(S=>o.getClasses().get(S)?.styles??[]);let t=0,u="rect",x;switch(n.type){case"round":t=5,u="rect";break;case"composite":t=0,u="composite",x=0;break;case"square":u="rect";break;case"diamond":u="question";break;case"hexagon":u="hexagon";break;case"block_arrow":u="block_arrow";break;case"odd":u="rect_left_inv_arrow";break;case"lean_right":u="lean_right";break;case"lean_left":u="lean_left";break;case"trapezoid":u="trapezoid";break;case"inv_trapezoid":u="inv_trapezoid";break;case"rect_left_inv_arrow":u="rect_left_inv_arrow";break;case"circle":u="circle";break;case"ellipse":u="ellipse";break;case"stadium":u="stadium";break;case"subroutine":u="subroutine";break;case"cylinder":u="cylinder";break;case"group":u="rect";break;case"doublecircle":u="doublecircle";break;default:u="rect"}const L=Qe(n?.styles??[]),b=n.label,f=n.size??{width:0,height:0,x:0,y:0},m=o.getDiagramId();return{labelStyle:L.labelStyle,shape:u,label:b,labelText:b,rx:t,ry:t,class:h,cssClasses:h,cssStyles:n?.styles??[],cssCompiledStyles:p,style:L.style,id:n.id,domId:m?`${m}-${n.id}`:n.id,isGroup:!1,directions:n.directions,width:f.width||void 0,height:f.height||void 0,wrappingWidth:f.width||Number.POSITIVE_INFINITY,x:f.x,y:f.y,positioned:l,intersect:void 0,padding:x??P()?.block?.padding??0,widthInColumns:n.widthInColumns??1,colorIndex:n.colorIndex,look:P().look}}c(ue,"getNodeFromBlock");async function Te(e,o,l){const n=ue(o,l,!1);if(o.type==="group")return;const h=P(),p=await xe(e,n,{config:h}),t=p.node()?.getBBox()??{width:0,height:0},u=l.getBlock(n.id);u.size={width:t.width,height:t.height,x:0,y:0,node:p},l.setBlock(u),p.remove()}c(Te,"calculateBlockSize");async function Ce(e,o,l){const n=ue(o,l,!0);if(l.getBlock(n.id).type!=="space"){const p=P(),t=await xe(e,n,{config:p});n.colorIndex!==void 0&&$e(t,n.colorIndex,p.theme,p.themeVariables?.borderColorArray),o.intersect=n?.intersect,et(n)}}c(Ce,"insertBlockPositioned");async function q(e,o,l,n){for(const h of o)await n(e,h,l),h.children&&await q(e,h.children,l,n)}c(q,"performOperations");async function ve(e,o,l){await q(e,o,l,Te)}c(ve,"calculateBlockSizes");async function Oe(e,o,l){await q(e,o,l,Ce)}c(Oe,"insertBlocks");async function ze(e,o,l,n,h){const p=new tt({multigraph:!0,compound:!0});p.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(const t of l)t.size&&p.setNode(t.id,{width:t.size.width,height:t.size.height,intersect:t.intersect});for(const t of o)if(t.start&&t.end){const u=n.getBlock(t.start),x=n.getBlock(t.end);if(u?.size&&x?.size){const L=u.size,b=x.size,f=[{x:L.x,y:L.y},{x:L.x+(b.x-L.x)/2,y:L.y+(b.y-L.y)/2},{x:b.x,y:b.y}],m=h?`${h}-${t.id}`:t.id,E=t.thickness==="thick"?"edge-thickness-thick":"edge-thickness-normal",S=t.pattern==="dotted"?"edge-pattern-dotted":"edge-pattern-solid",_=`${E} ${S} flowchart-link LS-a1 LE-b1`;Ge(e,{...t,id:m,arrowTypeEnd:t.arrowTypeEnd,arrowTypeStart:t.arrowTypeStart,points:f,classes:_},{},"block",p.node(t.start),p.node(t.end),h),t.label&&(await Xe(e,{...t,label:t.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:t.arrowTypeEnd,arrowTypeStart:t.arrowTypeStart,points:f,classes:_}),qe({...t,x:f[1].x,y:f[1].y},{originalPath:f}))}}}c(ze,"insertEdges");var It=c(function(e,o){return o.db.getClasses()},"getClasses"),Nt=c(async function(e,o,l,n){const{securityLevel:h,block:p}=P(),t=n.db;t.setDiagramId(o);let u;h==="sandbox"&&(u=H("#i"+o));const x=h==="sandbox"?H(u.nodes()[0].contentDocument.body):H("body"),L=h==="sandbox"?x.select(`[id="${o}"]`):H(`[id="${o}"]`);Pe(L,P()),Fe(L,["point","circle","cross"],n.type,o);const f=t.getBlocks(),m=t.getBlocksFlat(),E=t.getEdges(),S=L.insert("g").attr("class","block");await ve(S,f,t);const _=Ne(t);await Oe(S,f,t),await ze(S,E,m,t,o);const w=S.node()?.getBBox(),I=w&&Number.isFinite(w.width)&&Number.isFinite(w.height)?w:_;if(I){const C=Math.max(1,Math.round(.125*(I.width/I.height))),v=I.height+C+10,g=I.width+10,{useMaxWidth:r}=p;Me(L,v,g,!!r),y.debug("Here Bounds",_,I),L.attr("viewBox",`${I.x-5} ${I.y-5} ${I.width+10} ${I.height+10}`)}},"draw"),Tt={draw:Nt,getClasses:It},Bt={parser:st,db:Et,renderer:Tt,styles:_t};export{Bt as diagram};
@@ -0,0 +1,38 @@
1
+ import{d as Ae}from"./chunk-55XCU76K-BINcFiLN.js";import{s as Le,g as Ie,a as Me,b as Be,_ as d,c as Rt,l as ue,d as Ve,e as Ye,i as Fe,f as Pt,h as Ue,j as _e,k as Gt,w as je,m as Zt,n as he}from"./mermaid-C_q9pug0.js";import"./markdown-DVehI1Sg.js";var Ft=(function(){var t=d(function(_t,m,x,E){for(x=x||{},E=_t.length;E--;x[_t[E]]=m);return x},"o"),e=[1,24],a=[1,25],r=[1,26],u=[1,27],i=[1,28],n=[1,63],l=[1,64],s=[1,65],h=[1,66],y=[1,67],p=[1,68],g=[1,69],v=[1,29],w=[1,30],N=[1,31],O=[1,32],P=[1,33],I=[1,34],X=[1,35],q=[1,36],H=[1,37],Q=[1,38],K=[1,39],G=[1,40],J=[1,41],Z=[1,42],$=[1,43],tt=[1,44],et=[1,45],nt=[1,46],st=[1,47],at=[1,48],rt=[1,50],it=[1,51],ot=[1,52],lt=[1,53],ct=[1,54],ut=[1,55],ht=[1,56],dt=[1,57],pt=[1,58],ft=[1,59],yt=[1,60],kt=[14,42],zt=[14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],wt=[12,14,34,36,37,38,39,40,41,42,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],S=[1,82],T=[1,83],k=[1,84],C=[1,85],R=[12,14,42],re=[12,14,33,42],It=[12,14,33,42,76,77,79,80],xt=[12,33],Wt=[34,36,37,38,39,40,41,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74],Xt={trace:d(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,direction:5,direction_tb:6,direction_bt:7,direction_rl:8,direction_lr:9,graphConfig:10,C4_CONTEXT:11,NEWLINE:12,statements:13,EOF:14,C4_CONTAINER:15,C4_COMPONENT:16,C4_DYNAMIC:17,C4_DEPLOYMENT:18,otherStatements:19,diagramStatements:20,otherStatement:21,title:22,accDescription:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,boundaryStatement:29,boundaryStartStatement:30,boundaryStopStatement:31,boundaryStart:32,LBRACE:33,ENTERPRISE_BOUNDARY:34,attributes:35,SYSTEM_BOUNDARY:36,BOUNDARY:37,CONTAINER_BOUNDARY:38,NODE:39,NODE_L:40,NODE_R:41,RBRACE:42,diagramStatement:43,PERSON:44,PERSON_EXT:45,SYSTEM:46,SYSTEM_DB:47,SYSTEM_QUEUE:48,SYSTEM_EXT:49,SYSTEM_EXT_DB:50,SYSTEM_EXT_QUEUE:51,CONTAINER:52,CONTAINER_DB:53,CONTAINER_QUEUE:54,CONTAINER_EXT:55,CONTAINER_EXT_DB:56,CONTAINER_EXT_QUEUE:57,COMPONENT:58,COMPONENT_DB:59,COMPONENT_QUEUE:60,COMPONENT_EXT:61,COMPONENT_EXT_DB:62,COMPONENT_EXT_QUEUE:63,REL:64,BIREL:65,REL_U:66,REL_D:67,REL_L:68,REL_R:69,REL_B:70,REL_INDEX:71,UPDATE_EL_STYLE:72,UPDATE_REL_STYLE:73,UPDATE_LAYOUT_CONFIG:74,attribute:75,STR:76,STR_KEY:77,STR_VALUE:78,ATTRIBUTE:79,ATTRIBUTE_EMPTY:80,$accept:0,$end:1},terminals_:{2:"error",6:"direction_tb",7:"direction_bt",8:"direction_rl",9:"direction_lr",11:"C4_CONTEXT",12:"NEWLINE",14:"EOF",15:"C4_CONTAINER",16:"C4_COMPONENT",17:"C4_DYNAMIC",18:"C4_DEPLOYMENT",22:"title",23:"accDescription",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"LBRACE",34:"ENTERPRISE_BOUNDARY",36:"SYSTEM_BOUNDARY",37:"BOUNDARY",38:"CONTAINER_BOUNDARY",39:"NODE",40:"NODE_L",41:"NODE_R",42:"RBRACE",44:"PERSON",45:"PERSON_EXT",46:"SYSTEM",47:"SYSTEM_DB",48:"SYSTEM_QUEUE",49:"SYSTEM_EXT",50:"SYSTEM_EXT_DB",51:"SYSTEM_EXT_QUEUE",52:"CONTAINER",53:"CONTAINER_DB",54:"CONTAINER_QUEUE",55:"CONTAINER_EXT",56:"CONTAINER_EXT_DB",57:"CONTAINER_EXT_QUEUE",58:"COMPONENT",59:"COMPONENT_DB",60:"COMPONENT_QUEUE",61:"COMPONENT_EXT",62:"COMPONENT_EXT_DB",63:"COMPONENT_EXT_QUEUE",64:"REL",65:"BIREL",66:"REL_U",67:"REL_D",68:"REL_L",69:"REL_R",70:"REL_B",71:"REL_INDEX",72:"UPDATE_EL_STYLE",73:"UPDATE_REL_STYLE",74:"UPDATE_LAYOUT_CONFIG",76:"STR",77:"STR_KEY",78:"STR_VALUE",79:"ATTRIBUTE",80:"ATTRIBUTE_EMPTY"},productions_:[0,[3,1],[3,1],[5,1],[5,1],[5,1],[5,1],[4,1],[10,4],[10,4],[10,4],[10,4],[10,4],[13,1],[13,1],[13,2],[19,1],[19,2],[19,3],[21,1],[21,1],[21,2],[21,2],[21,1],[29,3],[30,3],[30,3],[30,4],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[32,2],[31,1],[20,1],[20,2],[20,3],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,1],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[43,2],[35,1],[35,2],[75,1],[75,2],[75,1],[75,1]],performAction:d(function(m,x,E,_,D,o,Ot){var f=o.length-1;switch(D){case 3:_.setDirection("TB");break;case 4:_.setDirection("BT");break;case 5:_.setDirection("RL");break;case 6:_.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:_.setC4Type(o[f-3]);break;case 19:_.setTitle(o[f].substring(6)),this.$=o[f].substring(6);break;case 20:_.setAccDescription(o[f].substring(15)),this.$=o[f].substring(15);break;case 21:this.$=o[f].trim(),_.setTitle(this.$);break;case 22:case 23:this.$=o[f].trim(),_.setAccDescription(this.$);break;case 28:o[f].splice(2,0,"ENTERPRISE"),_.addPersonOrSystemBoundary(...o[f]),this.$=o[f];break;case 29:o[f].splice(2,0,"SYSTEM"),_.addPersonOrSystemBoundary(...o[f]),this.$=o[f];break;case 30:_.addPersonOrSystemBoundary(...o[f]),this.$=o[f];break;case 31:o[f].splice(2,0,"CONTAINER"),_.addContainerBoundary(...o[f]),this.$=o[f];break;case 32:_.addDeploymentNode("node",...o[f]),this.$=o[f];break;case 33:_.addDeploymentNode("nodeL",...o[f]),this.$=o[f];break;case 34:_.addDeploymentNode("nodeR",...o[f]),this.$=o[f];break;case 35:_.popBoundaryParseStack();break;case 39:_.addPersonOrSystem("person",...o[f]),this.$=o[f];break;case 40:_.addPersonOrSystem("external_person",...o[f]),this.$=o[f];break;case 41:_.addPersonOrSystem("system",...o[f]),this.$=o[f];break;case 42:_.addPersonOrSystem("system_db",...o[f]),this.$=o[f];break;case 43:_.addPersonOrSystem("system_queue",...o[f]),this.$=o[f];break;case 44:_.addPersonOrSystem("external_system",...o[f]),this.$=o[f];break;case 45:_.addPersonOrSystem("external_system_db",...o[f]),this.$=o[f];break;case 46:_.addPersonOrSystem("external_system_queue",...o[f]),this.$=o[f];break;case 47:_.addContainer("container",...o[f]),this.$=o[f];break;case 48:_.addContainer("container_db",...o[f]),this.$=o[f];break;case 49:_.addContainer("container_queue",...o[f]),this.$=o[f];break;case 50:_.addContainer("external_container",...o[f]),this.$=o[f];break;case 51:_.addContainer("external_container_db",...o[f]),this.$=o[f];break;case 52:_.addContainer("external_container_queue",...o[f]),this.$=o[f];break;case 53:_.addComponent("component",...o[f]),this.$=o[f];break;case 54:_.addComponent("component_db",...o[f]),this.$=o[f];break;case 55:_.addComponent("component_queue",...o[f]),this.$=o[f];break;case 56:_.addComponent("external_component",...o[f]),this.$=o[f];break;case 57:_.addComponent("external_component_db",...o[f]),this.$=o[f];break;case 58:_.addComponent("external_component_queue",...o[f]),this.$=o[f];break;case 60:_.addRel("rel",...o[f]),this.$=o[f];break;case 61:_.addRel("birel",...o[f]),this.$=o[f];break;case 62:_.addRel("rel_u",...o[f]),this.$=o[f];break;case 63:_.addRel("rel_d",...o[f]),this.$=o[f];break;case 64:_.addRel("rel_l",...o[f]),this.$=o[f];break;case 65:_.addRel("rel_r",...o[f]),this.$=o[f];break;case 66:_.addRel("rel_b",...o[f]),this.$=o[f];break;case 67:o[f].splice(0,1),_.addRel("rel",...o[f]),this.$=o[f];break;case 68:_.updateElStyle("update_el_style",...o[f]),this.$=o[f];break;case 69:_.updateRelStyle("update_rel_style",...o[f]),this.$=o[f];break;case 70:_.updateLayoutConfig("update_layout_config",...o[f]),this.$=o[f];break;case 71:this.$=[o[f]];break;case 72:o[f].unshift(o[f-1]),this.$=o[f];break;case 73:case 75:this.$=o[f].trim();break;case 74:let vt={};vt[o[f-1].trim()]=o[f].trim(),this.$=vt;break;case 76:this.$="";break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:e,23:a,24:r,26:u,28:i,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{13:70,19:20,20:21,21:22,22:e,23:a,24:r,26:u,28:i,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{13:71,19:20,20:21,21:22,22:e,23:a,24:r,26:u,28:i,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{13:72,19:20,20:21,21:22,22:e,23:a,24:r,26:u,28:i,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{13:73,19:20,20:21,21:22,22:e,23:a,24:r,26:u,28:i,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{14:[1,74]},t(kt,[2,13],{43:23,29:49,30:61,32:62,20:75,34:n,36:l,37:s,38:h,39:y,40:p,41:g,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt}),t(kt,[2,14]),t(zt,[2,16],{12:[1,76]}),t(kt,[2,36],{12:[1,77]}),t(wt,[2,19]),t(wt,[2,20]),{25:[1,78]},{27:[1,79]},t(wt,[2,23]),{35:80,75:81,76:S,77:T,79:k,80:C},{35:86,75:81,76:S,77:T,79:k,80:C},{35:87,75:81,76:S,77:T,79:k,80:C},{35:88,75:81,76:S,77:T,79:k,80:C},{35:89,75:81,76:S,77:T,79:k,80:C},{35:90,75:81,76:S,77:T,79:k,80:C},{35:91,75:81,76:S,77:T,79:k,80:C},{35:92,75:81,76:S,77:T,79:k,80:C},{35:93,75:81,76:S,77:T,79:k,80:C},{35:94,75:81,76:S,77:T,79:k,80:C},{35:95,75:81,76:S,77:T,79:k,80:C},{35:96,75:81,76:S,77:T,79:k,80:C},{35:97,75:81,76:S,77:T,79:k,80:C},{35:98,75:81,76:S,77:T,79:k,80:C},{35:99,75:81,76:S,77:T,79:k,80:C},{35:100,75:81,76:S,77:T,79:k,80:C},{35:101,75:81,76:S,77:T,79:k,80:C},{35:102,75:81,76:S,77:T,79:k,80:C},{35:103,75:81,76:S,77:T,79:k,80:C},{35:104,75:81,76:S,77:T,79:k,80:C},t(R,[2,59]),{35:105,75:81,76:S,77:T,79:k,80:C},{35:106,75:81,76:S,77:T,79:k,80:C},{35:107,75:81,76:S,77:T,79:k,80:C},{35:108,75:81,76:S,77:T,79:k,80:C},{35:109,75:81,76:S,77:T,79:k,80:C},{35:110,75:81,76:S,77:T,79:k,80:C},{35:111,75:81,76:S,77:T,79:k,80:C},{35:112,75:81,76:S,77:T,79:k,80:C},{35:113,75:81,76:S,77:T,79:k,80:C},{35:114,75:81,76:S,77:T,79:k,80:C},{35:115,75:81,76:S,77:T,79:k,80:C},{20:116,29:49,30:61,32:62,34:n,36:l,37:s,38:h,39:y,40:p,41:g,43:23,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt},{12:[1,118],33:[1,117]},{35:119,75:81,76:S,77:T,79:k,80:C},{35:120,75:81,76:S,77:T,79:k,80:C},{35:121,75:81,76:S,77:T,79:k,80:C},{35:122,75:81,76:S,77:T,79:k,80:C},{35:123,75:81,76:S,77:T,79:k,80:C},{35:124,75:81,76:S,77:T,79:k,80:C},{35:125,75:81,76:S,77:T,79:k,80:C},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},t(kt,[2,15]),t(zt,[2,17],{21:22,19:130,22:e,23:a,24:r,26:u,28:i}),t(kt,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:e,23:a,24:r,26:u,28:i,34:n,36:l,37:s,38:h,39:y,40:p,41:g,44:v,45:w,46:N,47:O,48:P,49:I,50:X,51:q,52:H,53:Q,54:K,55:G,56:J,57:Z,58:$,59:tt,60:et,61:nt,62:st,63:at,64:rt,65:it,66:ot,67:lt,68:ct,69:ut,70:ht,71:dt,72:pt,73:ft,74:yt}),t(wt,[2,21]),t(wt,[2,22]),t(R,[2,39]),t(re,[2,71],{75:81,35:132,76:S,77:T,79:k,80:C}),t(It,[2,73]),{78:[1,133]},t(It,[2,75]),t(It,[2,76]),t(R,[2,40]),t(R,[2,41]),t(R,[2,42]),t(R,[2,43]),t(R,[2,44]),t(R,[2,45]),t(R,[2,46]),t(R,[2,47]),t(R,[2,48]),t(R,[2,49]),t(R,[2,50]),t(R,[2,51]),t(R,[2,52]),t(R,[2,53]),t(R,[2,54]),t(R,[2,55]),t(R,[2,56]),t(R,[2,57]),t(R,[2,58]),t(R,[2,60]),t(R,[2,61]),t(R,[2,62]),t(R,[2,63]),t(R,[2,64]),t(R,[2,65]),t(R,[2,66]),t(R,[2,67]),t(R,[2,68]),t(R,[2,69]),t(R,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},t(xt,[2,28]),t(xt,[2,29]),t(xt,[2,30]),t(xt,[2,31]),t(xt,[2,32]),t(xt,[2,33]),t(xt,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},t(zt,[2,18]),t(kt,[2,38]),t(re,[2,72]),t(It,[2,74]),t(R,[2,24]),t(R,[2,35]),t(Wt,[2,25]),t(Wt,[2,26],{12:[1,138]}),t(Wt,[2,27])],defaultActions:{2:[2,1],3:[2,2],4:[2,7],5:[2,3],6:[2,4],7:[2,5],8:[2,6],74:[2,8],126:[2,9],127:[2,10],128:[2,11],129:[2,12]},parseError:d(function(m,x){if(x.recoverable)this.trace(m);else{var E=new Error(m);throw E.hash=x,E}},"parseError"),parse:d(function(m){var x=this,E=[0],_=[],D=[null],o=[],Ot=this.table,f="",vt=0,ie=0,Oe=2,oe=1,Pe=o.slice.call(arguments,1),A=Object.create(this.lexer),Et={yy:{}};for(var qt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,qt)&&(Et.yy[qt]=this.yy[qt]);A.setInput(m,Et.yy),Et.yy.lexer=A,Et.yy.parser=this,typeof A.yylloc>"u"&&(A.yylloc={});var Ht=A.yylloc;o.push(Ht);var De=A.options&&A.options.ranges;typeof Et.yy.parseError=="function"?this.parseError=Et.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Ne(B){E.length=E.length-2*B,D.length=D.length-B,o.length=o.length-B}d(Ne,"popStack");function le(){var B;return B=_.pop()||A.lex()||oe,typeof B!="number"&&(B instanceof Array&&(_=B,B=_.pop()),B=x.symbols_[B]||B),B}d(le,"lex");for(var M,St,V,Qt,Ct={},Bt,z,ce,Vt;;){if(St=E[E.length-1],this.defaultActions[St]?V=this.defaultActions[St]:((M===null||typeof M>"u")&&(M=le()),V=Ot[St]&&Ot[St][M]),typeof V>"u"||!V.length||!V[0]){var Kt="";Vt=[];for(Bt in Ot[St])this.terminals_[Bt]&&Bt>Oe&&Vt.push("'"+this.terminals_[Bt]+"'");A.showPosition?Kt="Parse error on line "+(vt+1)+`:
2
+ `+A.showPosition()+`
3
+ Expecting `+Vt.join(", ")+", got '"+(this.terminals_[M]||M)+"'":Kt="Parse error on line "+(vt+1)+": Unexpected "+(M==oe?"end of input":"'"+(this.terminals_[M]||M)+"'"),this.parseError(Kt,{text:A.match,token:this.terminals_[M]||M,line:A.yylineno,loc:Ht,expected:Vt})}if(V[0]instanceof Array&&V.length>1)throw new Error("Parse Error: multiple actions possible at state: "+St+", token: "+M);switch(V[0]){case 1:E.push(M),D.push(A.yytext),o.push(A.yylloc),E.push(V[1]),M=null,ie=A.yyleng,f=A.yytext,vt=A.yylineno,Ht=A.yylloc;break;case 2:if(z=this.productions_[V[1]][1],Ct.$=D[D.length-z],Ct._$={first_line:o[o.length-(z||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(z||1)].first_column,last_column:o[o.length-1].last_column},De&&(Ct._$.range=[o[o.length-(z||1)].range[0],o[o.length-1].range[1]]),Qt=this.performAction.apply(Ct,[f,ie,vt,Et.yy,V[1],D,o].concat(Pe)),typeof Qt<"u")return Qt;z&&(E=E.slice(0,-1*z*2),D=D.slice(0,-1*z),o=o.slice(0,-1*z)),E.push(this.productions_[V[1]][0]),D.push(Ct.$),o.push(Ct._$),ce=Ot[E[E.length-2]][E[E.length-1]],E.push(ce);break;case 3:return!0}}return!0},"parse")},we=(function(){var _t={EOF:1,parseError:d(function(x,E){if(this.yy.parser)this.yy.parser.parseError(x,E);else throw new Error(x)},"parseError"),setInput:d(function(m,x){return this.yy=x||this.yy||{},this._input=m,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:d(function(){var m=this._input[0];this.yytext+=m,this.yyleng++,this.offset++,this.match+=m,this.matched+=m;var x=m.match(/(?:\r\n?|\n).*/g);return x?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),m},"input"),unput:d(function(m){var x=m.length,E=m.split(/(?:\r\n?|\n)/g);this._input=m+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-x),this.offset-=x;var _=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),E.length-1&&(this.yylineno-=E.length-1);var D=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:E?(E.length===_.length?this.yylloc.first_column:0)+_[_.length-E.length].length-E[0].length:this.yylloc.first_column-x},this.options.ranges&&(this.yylloc.range=[D[0],D[0]+this.yyleng-x]),this.yyleng=this.yytext.length,this},"unput"),more:d(function(){return this._more=!0,this},"more"),reject:d(function(){if(this.options.backtrack_lexer)this._backtrack=!0;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).
4
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:d(function(m){this.unput(this.match.slice(m))},"less"),pastInput:d(function(){var m=this.matched.substr(0,this.matched.length-this.match.length);return(m.length>20?"...":"")+m.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:d(function(){var m=this.match;return m.length<20&&(m+=this._input.substr(0,20-m.length)),(m.substr(0,20)+(m.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:d(function(){var m=this.pastInput(),x=new Array(m.length+1).join("-");return m+this.upcomingInput()+`
5
+ `+x+"^"},"showPosition"),test_match:d(function(m,x){var E,_,D;if(this.options.backtrack_lexer&&(D={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(D.yylloc.range=this.yylloc.range.slice(0))),_=m[0].match(/(?:\r\n?|\n).*/g),_&&(this.yylineno+=_.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:_?_[_.length-1].length-_[_.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+m[0].length},this.yytext+=m[0],this.match+=m[0],this.matches=m,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(m[0].length),this.matched+=m[0],E=this.performAction.call(this,this.yy,this,x,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),E)return E;if(this._backtrack){for(var o in D)this[o]=D[o];return!1}return!1},"test_match"),next:d(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var m,x,E,_;this._more||(this.yytext="",this.match="");for(var D=this._currentRules(),o=0;o<D.length;o++)if(E=this._input.match(this.rules[D[o]]),E&&(!x||E[0].length>x[0].length)){if(x=E,_=o,this.options.backtrack_lexer){if(m=this.test_match(E,D[o]),m!==!1)return m;if(this._backtrack){x=!1;continue}else return!1}else if(!this.options.flex)break}return x?(m=this.test_match(x,D[_]),m!==!1?m:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:d(function(){var x=this.next();return x||this.lex()},"lex"),begin:d(function(x){this.conditionStack.push(x)},"begin"),popState:d(function(){var x=this.conditionStack.length-1;return x>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:d(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:d(function(x){return x=this.conditionStack.length-1-Math.abs(x||0),x>=0?this.conditionStack[x]:"INITIAL"},"topState"),pushState:d(function(x){this.begin(x)},"pushState"),stateStackSize:d(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:d(function(x,E,_,D){switch(_){case 0:return 6;case 1:return 7;case 2:return 8;case 3:return 9;case 4:return 22;case 5:return 23;case 6:return this.begin("acc_title"),24;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),26;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:break;case 14:c;break;case 15:return 12;case 16:break;case 17:return 11;case 18:return 15;case 19:return 16;case 20:return 17;case 21:return 18;case 22:return this.begin("person_ext"),45;case 23:return this.begin("person"),44;case 24:return this.begin("system_ext_queue"),51;case 25:return this.begin("system_ext_db"),50;case 26:return this.begin("system_ext"),49;case 27:return this.begin("system_queue"),48;case 28:return this.begin("system_db"),47;case 29:return this.begin("system"),46;case 30:return this.begin("boundary"),37;case 31:return this.begin("enterprise_boundary"),34;case 32:return this.begin("system_boundary"),36;case 33:return this.begin("container_ext_queue"),57;case 34:return this.begin("container_ext_db"),56;case 35:return this.begin("container_ext"),55;case 36:return this.begin("container_queue"),54;case 37:return this.begin("container_db"),53;case 38:return this.begin("container"),52;case 39:return this.begin("container_boundary"),38;case 40:return this.begin("component_ext_queue"),63;case 41:return this.begin("component_ext_db"),62;case 42:return this.begin("component_ext"),61;case 43:return this.begin("component_queue"),60;case 44:return this.begin("component_db"),59;case 45:return this.begin("component"),58;case 46:return this.begin("node"),39;case 47:return this.begin("node"),39;case 48:return this.begin("node_l"),40;case 49:return this.begin("node_r"),41;case 50:return this.begin("rel"),64;case 51:return this.begin("birel"),65;case 52:return this.begin("rel_u"),66;case 53:return this.begin("rel_u"),66;case 54:return this.begin("rel_d"),67;case 55:return this.begin("rel_d"),67;case 56:return this.begin("rel_l"),68;case 57:return this.begin("rel_l"),68;case 58:return this.begin("rel_r"),69;case 59:return this.begin("rel_r"),69;case 60:return this.begin("rel_b"),70;case 61:return this.begin("rel_index"),71;case 62:return this.begin("update_el_style"),72;case 63:return this.begin("update_rel_style"),73;case 64:return this.begin("update_layout_config"),74;case 65:return"EOF_IN_STRUCT";case 66:return this.begin("attribute"),"ATTRIBUTE_EMPTY";case 67:this.begin("attribute");break;case 68:this.popState(),this.popState();break;case 69:return 80;case 70:break;case 71:return 80;case 72:this.begin("string");break;case 73:this.popState();break;case 74:return"STR";case 75:this.begin("string_kv");break;case 76:return this.begin("string_kv_key"),"STR_KEY";case 77:this.popState(),this.begin("string_kv_value");break;case 78:return"STR_VALUE";case 79:this.popState(),this.popState();break;case 80:return"STR";case 81:return"LBRACE";case 82:return"RBRACE";case 83:return"SPACE";case 84:return"EOL";case 85:return 14}},"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:title\s[^#\n;]+)/,/^(?:accDescription\s[^#\n;]+)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:C4Context\b)/,/^(?:C4Container\b)/,/^(?:C4Component\b)/,/^(?:C4Dynamic\b)/,/^(?:C4Deployment\b)/,/^(?:Person_Ext\b)/,/^(?:Person\b)/,/^(?:SystemQueue_Ext\b)/,/^(?:SystemDb_Ext\b)/,/^(?:System_Ext\b)/,/^(?:SystemQueue\b)/,/^(?:SystemDb\b)/,/^(?:System\b)/,/^(?:Boundary\b)/,/^(?:Enterprise_Boundary\b)/,/^(?:System_Boundary\b)/,/^(?:ContainerQueue_Ext\b)/,/^(?:ContainerDb_Ext\b)/,/^(?:Container_Ext\b)/,/^(?:ContainerQueue\b)/,/^(?:ContainerDb\b)/,/^(?:Container\b)/,/^(?:Container_Boundary\b)/,/^(?:ComponentQueue_Ext\b)/,/^(?:ComponentDb_Ext\b)/,/^(?:Component_Ext\b)/,/^(?:ComponentQueue\b)/,/^(?:ComponentDb\b)/,/^(?:Component\b)/,/^(?:Deployment_Node\b)/,/^(?:Node\b)/,/^(?:Node_L\b)/,/^(?:Node_R\b)/,/^(?:Rel\b)/,/^(?:BiRel\b)/,/^(?:Rel_Up\b)/,/^(?:Rel_U\b)/,/^(?:Rel_Down\b)/,/^(?:Rel_D\b)/,/^(?:Rel_Left\b)/,/^(?:Rel_L\b)/,/^(?:Rel_Right\b)/,/^(?:Rel_R\b)/,/^(?:Rel_Back\b)/,/^(?:RelIndex\b)/,/^(?:UpdateElementStyle\b)/,/^(?:UpdateRelStyle\b)/,/^(?:UpdateLayoutConfig\b)/,/^(?:$)/,/^(?:[(][ ]*[,])/,/^(?:[(])/,/^(?:[)])/,/^(?:,,)/,/^(?:,)/,/^(?:[ ]*["]["])/,/^(?:[ ]*["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[ ]*[\$])/,/^(?:[^=]*)/,/^(?:[=][ ]*["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:[^,]+)/,/^(?:\{)/,/^(?:\})/,/^(?:[\s]+)/,/^(?:[\n\r]+)/,/^(?:$)/],conditions:{acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},string_kv_value:{rules:[78,79],inclusive:!1},string_kv_key:{rules:[77],inclusive:!1},string_kv:{rules:[76],inclusive:!1},string:{rules:[73,74],inclusive:!1},attribute:{rules:[68,69,70,71,72,75,80],inclusive:!1},update_layout_config:{rules:[65,66,67,68],inclusive:!1},update_rel_style:{rules:[65,66,67,68],inclusive:!1},update_el_style:{rules:[65,66,67,68],inclusive:!1},rel_b:{rules:[65,66,67,68],inclusive:!1},rel_r:{rules:[65,66,67,68],inclusive:!1},rel_l:{rules:[65,66,67,68],inclusive:!1},rel_d:{rules:[65,66,67,68],inclusive:!1},rel_u:{rules:[65,66,67,68],inclusive:!1},rel_bi:{rules:[],inclusive:!1},rel:{rules:[65,66,67,68],inclusive:!1},node_r:{rules:[65,66,67,68],inclusive:!1},node_l:{rules:[65,66,67,68],inclusive:!1},node:{rules:[65,66,67,68],inclusive:!1},index:{rules:[],inclusive:!1},rel_index:{rules:[65,66,67,68],inclusive:!1},component_ext_queue:{rules:[65,66,67,68],inclusive:!1},component_ext_db:{rules:[65,66,67,68],inclusive:!1},component_ext:{rules:[65,66,67,68],inclusive:!1},component_queue:{rules:[65,66,67,68],inclusive:!1},component_db:{rules:[65,66,67,68],inclusive:!1},component:{rules:[65,66,67,68],inclusive:!1},container_boundary:{rules:[65,66,67,68],inclusive:!1},container_ext_queue:{rules:[65,66,67,68],inclusive:!1},container_ext_db:{rules:[65,66,67,68],inclusive:!1},container_ext:{rules:[65,66,67,68],inclusive:!1},container_queue:{rules:[65,66,67,68],inclusive:!1},container_db:{rules:[65,66,67,68],inclusive:!1},container:{rules:[65,66,67,68],inclusive:!1},birel:{rules:[65,66,67,68],inclusive:!1},system_boundary:{rules:[65,66,67,68],inclusive:!1},enterprise_boundary:{rules:[65,66,67,68],inclusive:!1},boundary:{rules:[65,66,67,68],inclusive:!1},system_ext_queue:{rules:[65,66,67,68],inclusive:!1},system_ext_db:{rules:[65,66,67,68],inclusive:!1},system_ext:{rules:[65,66,67,68],inclusive:!1},system_queue:{rules:[65,66,67,68],inclusive:!1},system_db:{rules:[65,66,67,68],inclusive:!1},system:{rules:[65,66,67,68],inclusive:!1},person_ext:{rules:[65,66,67,68],inclusive:!1},person:{rules:[65,66,67,68],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,82,83,84,85],inclusive:!0}}};return _t})();Xt.lexer=we;function Mt(){this.yy={}}return d(Mt,"Parser"),Mt.prototype=Xt,Xt.Parser=Mt,new Mt})();Ft.parser=Ft;var ze=Ft,ge=d(t=>Rt()[t],"getRequiredConfig"),Y=new Set(["label","descr","techn","type"]),Tt=d((t,e)=>{for(const[a,r]of Object.entries(e))if(r!==void 0)if(typeof r=="object"){const[u,i]=Object.entries(r)[0];t[u]=Y.has(u)?{text:i}:i}else t[a]=r},"assignAttributes"),me=d(()=>({alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}),"createGlobalBoundary"),U=[],gt=[""],L="global",F="",j=[me()],Lt=[],ne="",se=!1,Ut=4,jt=2,be,We=d(function(){return be},"getC4Type"),Xe=d(function(t){be=_e(t,Rt())},"setC4Type"),qe=d(function(t,e,a,r,u,i,n,l,s){if(t==null||e===void 0||e===null||a===void 0||a===null||r===void 0||r===null)return;let h={};const y=Lt.find(p=>p.from===e&&p.to===a);if(y?h=y:Lt.push(h),h.type=t,h.from=e,h.to=a,h.label={text:r},u==null)h.techn??={text:""};else if(typeof u=="object"){const[p,g]=Object.entries(u)[0];h[p]=Y.has(p)?{text:g}:g}else h.techn={text:u};if(i==null)h.descr??={text:""};else if(typeof i=="object"){const[p,g]=Object.entries(i)[0];h[p]=Y.has(p)?{text:g}:g}else h.descr={text:i};Tt(h,{sprite:n,tags:l,link:s}),h.wrap=bt()},"addRel"),He=d(function(t,e,a,r,u,i,n){if(e===null||a===null)return;let l={};const s=U.find(h=>h.alias===e);if(s&&e===s.alias?l=s:(l.alias=e,U.push(l)),a==null?l.label={text:""}:l.label={text:a},r==null)l.descr??={text:""};else if(typeof r=="object"){const[h,y]=Object.entries(r)[0];l[h]=Y.has(h)?{text:y}:y}else l.descr={text:r};Tt(l,{sprite:u,tags:i,link:n}),l.typeC4Shape={text:t},l.parentBoundary=L,l.wrap=bt()},"addPersonOrSystem"),Qe=d(function(t,e,a,r,u,i,n,l){if(e===null||a===null)return;let s={};const h=U.find(y=>y.alias===e);if(h&&e===h.alias?s=h:(s.alias=e,U.push(s)),a==null?s.label={text:""}:s.label={text:a},r==null)s.techn??={text:""};else if(typeof r=="object"){const[y,p]=Object.entries(r)[0];s[y]=Y.has(y)?{text:p}:p}else s.techn={text:r};if(u==null)s.descr??={text:""};else if(typeof u=="object"){const[y,p]=Object.entries(u)[0];s[y]=Y.has(y)?{text:p}:p}else s.descr={text:u};Tt(s,{sprite:i,tags:n,link:l}),s.wrap=bt(),s.typeC4Shape={text:t},s.parentBoundary=L},"addContainer"),Ke=d(function(t,e,a,r,u,i,n,l){if(e===null||a===null)return;let s={};const h=U.find(y=>y.alias===e);if(h&&e===h.alias?s=h:(s.alias=e,U.push(s)),a==null?s.label={text:""}:s.label={text:a},r==null)s.techn??={text:""};else if(typeof r=="object"){const[y,p]=Object.entries(r)[0];s[y]=Y.has(y)?{text:p}:p}else s.techn={text:r};if(u==null)s.descr??={text:""};else if(typeof u=="object"){const[y,p]=Object.entries(u)[0];s[y]=Y.has(y)?{text:p}:p}else s.descr={text:u};Tt(s,{sprite:i,tags:n,link:l}),s.wrap=bt(),s.typeC4Shape={text:t},s.parentBoundary=L},"addComponent"),Ge=d(function(t,e,a,r,u){if(t===null||e===null)return;let i={};const n=j.find(l=>l.alias===t);if(n&&t===n.alias?i=n:(i.alias=t,j.push(i)),e==null?i.label={text:""}:i.label={text:e},a==null)i.type={text:"system"};else if(typeof a=="object"){const[l,s]=Object.entries(a)[0];i[l]=Y.has(l)?{text:s}:s}else i.type={text:a};Tt(i,{tags:r,link:u}),i.parentBoundary=L,i.wrap=bt(),F=L,L=t,gt.push(F)},"addPersonOrSystemBoundary"),Je=d(function(t,e,a,r,u){if(t===null||e===null)return;let i={};const n=j.find(l=>l.alias===t);if(n&&t===n.alias?i=n:(i.alias=t,j.push(i)),e==null?i.label={text:""}:i.label={text:e},a==null)i.type={text:"container"};else if(typeof a=="object"){const[l,s]=Object.entries(a)[0];i[l]=Y.has(l)?{text:s}:s}else i.type={text:a};Tt(i,{tags:r,link:u}),i.parentBoundary=L,i.wrap=bt(),F=L,L=t,gt.push(F)},"addContainerBoundary"),Ze=d(function(t,e,a,r,u,i,n,l){if(e===null||a===null)return;let s={};const h=j.find(y=>y.alias===e);if(h&&e===h.alias?s=h:(s.alias=e,j.push(s)),a==null?s.label={text:""}:s.label={text:a},r==null)s.type={text:"node"};else if(typeof r=="object"){const[y,p]=Object.entries(r)[0];s[y]=Y.has(y)?{text:p}:p}else s.type={text:r};if(u==null)s.descr??={text:""};else if(typeof u=="object"){const[y,p]=Object.entries(u)[0];s[y]=Y.has(y)?{text:p}:p}else s.descr={text:u};Tt(s,{tags:n,link:l}),s.nodeType=t,s.parentBoundary=L,s.wrap=bt(),F=L,L=e,gt.push(F)},"addDeploymentNode"),$e=d(function(){L=F,gt.pop(),F=gt.pop(),gt.push(F)},"popBoundaryParseStack"),t0=d(function(t,e,a,r,u,i,n,l,s,h,y){let p=U.find(g=>g.alias===e);if(!(p===void 0&&(p=j.find(g=>g.alias===e),p===void 0))){if(a!=null)if(typeof a=="object"){const[g,v]=Object.entries(a)[0];p[g]=v}else p.bgColor=a;if(r!=null)if(typeof r=="object"){const[g,v]=Object.entries(r)[0];p[g]=v}else p.fontColor=r;if(u!=null)if(typeof u=="object"){const[g,v]=Object.entries(u)[0];p[g]=v}else p.borderColor=u;if(i!=null)if(typeof i=="object"){const[g,v]=Object.entries(i)[0];p[g]=v}else p.shadowing=i;if(n!=null)if(typeof n=="object"){const[g,v]=Object.entries(n)[0];p[g]=v}else p.shape=n;if(l!=null)if(typeof l=="object"){const[g,v]=Object.entries(l)[0];p[g]=v}else p.sprite=l;if(s!=null)if(typeof s=="object"){const[g,v]=Object.entries(s)[0];p[g]=v}else p.techn=s;if(h!=null)if(typeof h=="object"){const[g,v]=Object.entries(h)[0];p[g]=v}else p.legendText=h;if(y!=null)if(typeof y=="object"){const[g,v]=Object.entries(y)[0];p[g]=v}else p.legendSprite=y}},"updateElStyle"),e0=d(function(t,e,a,r,u,i,n){const l=Lt.find(s=>s.from===e&&s.to===a);if(l!==void 0){if(r!=null)if(typeof r=="object"){const[s,h]=Object.entries(r)[0];l[s]=h}else l.textColor=r;if(u!=null)if(typeof u=="object"){const[s,h]=Object.entries(u)[0];l[s]=h}else l.lineColor=u;if(i!=null)if(typeof i=="object"){const[s,h]=Object.entries(i)[0];l[s]=parseInt(h)}else l.offsetX=parseInt(i);if(n!=null)if(typeof n=="object"){const[s,h]=Object.entries(n)[0];l[s]=parseInt(h)}else l.offsetY=parseInt(n)}},"updateRelStyle"),n0=d(function(t,e,a){let r=Ut,u=jt;if(typeof e=="object"){const i=Object.values(e)[0];r=parseInt(i)}else r=parseInt(e);if(typeof a=="object"){const i=Object.values(a)[0];u=parseInt(i)}else u=parseInt(a);r>=1&&(Ut=r),u>=1&&(jt=u)},"updateLayoutConfig"),s0=d(function(){return Ut},"getC4ShapeInRow"),a0=d(function(){return jt},"getC4BoundaryInRow"),r0=d(function(){return L},"getCurrentBoundaryParse"),i0=d(function(){return F},"getParentBoundaryParse"),xe=d(function(t){return t==null?U:U.filter(e=>e.parentBoundary===t)},"getC4ShapeArray"),o0=d(function(t){return U.find(e=>e.alias===t)??j.find(e=>e.alias===t)},"getC4Shape"),l0=d(function(t){return Object.keys(xe(t))},"getC4ShapeKeys"),ve=d(function(t){return t==null?j:j.filter(e=>e.parentBoundary===t)},"getBoundaries"),c0=ve,u0=d(function(){return Lt},"getRels"),h0=d(function(){return ne},"getTitle"),d0=d(function(t){se=t},"setWrap"),bt=d(function(){return se},"autoWrap"),p0=d(function(){U=[],j=[me()],F="",L="global",gt=[""],Lt=[],gt=[""],ne="",se=!1,Ut=4,jt=2},"clear"),f0={SOLID:0,DOTTED:1,NOTE:2,SOLID_CROSS:3,DOTTED_CROSS:4,SOLID_OPEN:5,DOTTED_OPEN:6,LOOP_START:10,LOOP_END:11,ALT_START:12,ALT_ELSE:13,ALT_END:14,OPT_START:15,OPT_END:16,ACTIVE_START:17,ACTIVE_END:18,PAR_START:19,PAR_AND:20,PAR_END:21,RECT_START:22,RECT_END:23,SOLID_POINT:24,DOTTED_POINT:25},y0={FILLED:0,OPEN:1},_0={LEFTOF:0,RIGHTOF:1,OVER:2},g0=d(function(t){ne=_e(t,Rt())},"setTitle"),$t={addPersonOrSystem:He,addPersonOrSystemBoundary:Ge,addContainer:Qe,addContainerBoundary:Je,addComponent:Ke,addDeploymentNode:Ze,popBoundaryParseStack:$e,addRel:qe,updateElStyle:t0,updateRelStyle:e0,updateLayoutConfig:n0,autoWrap:bt,setWrap:d0,getC4ShapeArray:xe,getC4Shape:o0,getC4ShapeKeys:l0,getBoundaries:ve,getBoundarys:c0,getCurrentBoundaryParse:r0,getParentBoundaryParse:i0,getRels:u0,getTitle:h0,getC4Type:We,getC4ShapeInRow:s0,getC4BoundaryInRow:a0,setAccTitle:Be,getAccTitle:Me,getAccDescription:Ie,setAccDescription:Le,getConfig:d(()=>ge("c4"),"getConfig"),clear:p0,LINETYPE:f0,ARROWTYPE:y0,PLACEMENT:_0,setTitle:g0,setC4Type:Xe},Ee=d(function(t,e){return Ae(t,e)},"drawRect"),m0=d((t,e,a,r)=>{const u=t.append("g");let i=0;for(const n of e){const l=n.textColor?n.textColor:"#444444",s=n.lineColor?n.lineColor:"#444444",h=n.offsetX?parseInt(String(n.offsetX)):0,y=n.offsetY?parseInt(String(n.offsetY)):0,p="";if(i===0){const w=u.append("line");w.attr("x1",n.startPoint.x),w.attr("y1",n.startPoint.y),w.attr("x2",n.endPoint.x),w.attr("y2",n.endPoint.y),w.attr("stroke-width","1"),w.attr("stroke",s),w.style("fill","none"),n.type!=="rel_b"&&w.attr("marker-end","url("+p+"#"+r+"-arrowhead)"),(n.type==="birel"||n.type==="rel_b")&&w.attr("marker-start","url("+p+"#"+r+"-arrowend)"),i=-1}else{const w=u.append("path");w.attr("fill","none").attr("stroke-width","1").attr("stroke",s).attr("d","Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx",n.startPoint.x).replaceAll("starty",n.startPoint.y).replaceAll("controlx",n.startPoint.x+(n.endPoint.x-n.startPoint.x)/2-(n.endPoint.x-n.startPoint.x)/4).replaceAll("controly",n.startPoint.y+(n.endPoint.y-n.startPoint.y)/2).replaceAll("stopx",n.endPoint.x).replaceAll("stopy",n.endPoint.y)),n.type!=="rel_b"&&w.attr("marker-end","url("+p+"#"+r+"-arrowhead)"),(n.type==="birel"||n.type==="rel_b")&&w.attr("marker-start","url("+p+"#"+r+"-arrowend)")}const g=n.label.width;let v=a.messageFont();Dt(a)(n.label.text,u,Math.min(n.startPoint.x,n.endPoint.x)+Math.abs(n.endPoint.x-n.startPoint.x)/2+h,Math.min(n.startPoint.y,n.endPoint.y)+Math.abs(n.endPoint.y-n.startPoint.y)/2+y,g,n.label.height,{fill:l},v),n.techn&&n.techn.text!==""&&(v=a.messageFont(),Dt(a)("["+n.techn.text+"]",u,Math.min(n.startPoint.x,n.endPoint.x)+Math.abs(n.endPoint.x-n.startPoint.x)/2+h,Math.min(n.startPoint.y,n.endPoint.y)+Math.abs(n.endPoint.y-n.startPoint.y)/2+a.messageFontSize+5+y,Math.max(g,n.techn.width),n.techn.height,{fill:l,"font-style":"italic"},v))}},"drawRels"),b0=d(function(t,e,a){const r=t.append("g"),u=e.bgColor?e.bgColor:"none",i=e.borderColor?e.borderColor:"#444444",n=e.fontColor?e.fontColor:"black";let l={"stroke-width":1,"stroke-dasharray":"7.0,7.0"};e.nodeType&&(l={"stroke-width":1});const s={x:e.x,y:e.y,fill:u,stroke:i,width:e.width,height:e.height,rx:2.5,ry:2.5,attrs:l};Ee(r,s);let h=a.boundaryFont();h.fontWeight="bold",h.fontSize=h.fontSize+2,h.fontColor=n,Dt(a)(e.label.text,r,e.x,e.y+e.label.Y,e.width,e.height,{fill:"#444444"},h),e.type&&e.type.text!==""&&(h=a.boundaryFont(),h.fontColor=n,Dt(a)(e.type.text,r,e.x,e.y+e.type.Y,e.width,e.height,{fill:"#444444"},h)),e.descr&&e.descr.text!==""&&(h=a.boundaryFont(),h.fontSize=h.fontSize-2,h.fontColor=n,Dt(a)(e.descr.text,r,e.x,e.y+e.descr.Y,e.width,e.height,{fill:"#444444"},h))},"drawBoundary"),x0=d(function(t,e){t.append("defs").append("symbol").attr("id",e+"-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")},"insertDatabaseIcon"),v0=d(function(t,e){t.append("defs").append("symbol").attr("id",e+"-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")},"insertComputerIcon"),E0=d(function(t,e){t.append("defs").append("symbol").attr("id",e+"-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")},"insertClockIcon"),S0=d(function(t,e){t.append("defs").append("marker").attr("id",e+"-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")},"insertArrowHead"),T0=d(function(t,e){t.append("defs").append("marker").attr("id",e+"-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")},"insertArrowEnd"),k0=d(function(t,e){t.append("defs").append("marker").attr("id",e+"-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")},"insertArrowFilledHead"),C0=d(function(t,e){const r=t.append("defs").append("marker").attr("id",e+"-crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);r.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"),r.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")},"insertArrowCrossHead"),Dt=(function(){function t(u,i,n,l,s,h,y){const p=i.append("text").attr("x",n+s/2).attr("y",l+h/2+5).style("text-anchor","middle").text(u);r(p,y)}d(t,"byText");function e(u,i,n,l,s,h,y,p){const{fontSize:g,fontFamily:v,fontWeight:w}=p,N=u.split(Zt.lineBreakRegex);for(let O=0;O<N.length;O++){const P=O*g-g*(N.length-1)/2,I=i.append("text").attr("x",n+s/2).attr("y",l).style("text-anchor","middle").attr("dominant-baseline","middle").style("font-size",g).style("font-weight",w).style("font-family",v);I.append("tspan").attr("dy",P).text(N[O]).attr("alignment-baseline","mathematical"),r(I,y)}}d(e,"byTspan");function a(u,i,n,l,s,h,y,p){const g=i.append("switch"),w=g.append("foreignObject").attr("x",n).attr("y",l).attr("width",s).attr("height",h).append("xhtml:div").style("display","table").style("height","100%").style("width","100%");w.append("div").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(u),e(u,g,n,l,s,h,y,p),r(w,y)}d(a,"byFo");function r(u,i){for(const n in i)i.hasOwnProperty(n)&&u.attr(n,i[n])}return d(r,"_setTextAttrs"),function(u){return u.textPlacement==="fo"?a:u.textPlacement==="old"?t:e}})(),W={drawRect:Ee,drawBoundary:b0,drawRels:m0,insertArrowHead:S0,insertArrowEnd:T0,insertArrowFilledHead:k0,insertArrowCrossHead:C0,insertDatabaseIcon:x0,insertComputerIcon:v0,insertClockIcon:E0},R0=d((t,e)=>{if(e==="sandbox"){const r=Gt("#i"+t).node()?.contentDocument;if(!r)throw new Error(`Sandbox iframe #i${t} is missing its content document`);return{root:Gt(r.body),doc:r}}return{root:Gt("body"),doc:document}},"getDiagramRoot"),w0=new Set(["system_queue","external_system_queue","container_queue","external_container_queue","component_queue","external_component_queue"]),O0=new Set(["system_db","external_system_db","container_db","external_container_db","component_db","external_component_db"]),P0={person:"person",box:"rounded",rounded:"rounded",cylinder:"cylinder",database:"cylinder",db:"cylinder",queue:"h-cyl",pipe:"h-cyl",component:"fr-rect"},Jt=d(t=>t?P0[t.toLowerCase()]:void 0,"keywordShape"),D0=d(t=>{const e=Jt(t.shape)??Jt(t.sprite);if(e)return e;if(t.tags)for(const r of t.tags.split(",")){const u=Jt(r.trim());if(u)return u}const a=t.typeC4Shape.text;return a==="person"||a==="external_person"?"person":O0.has(a)?"cylinder":w0.has(a)?"h-cyl":"rounded"},"resolveNodeShape"),N0={person:"Person",system:"Software System",container:"Container",component:"Component"},A0=d(t=>{const e=t.replace(/^external_/,"").replace(/_(db|queue)$/,"");return N0[e]??e.replace(/_/g," ")},"stereotypeLabel"),L0=d(t=>t.startsWith("external_"),"isExternal"),I0=d(t=>{const e=A0(t.typeC4Shape.text);return t.techn?.text?`[${e}: ${t.techn.text}]`:`[${e}]`},"stereotypeText"),Se=["person","system","system_db","system_queue","container","container_db","container_queue","component","component_db","component_queue"].flatMap(t=>[t,`external_${t}`]),M0=new Set(Se),de=d(t=>M0.has(t),"isC4ElementType"),B0=d((t,e)=>{const a=t.typeC4Shape.text,r=t.bgColor??(de(a)&&e[`${a}_bg_color`]),u=t.borderColor??(de(a)&&e[`${a}_border_color`]),i=[];return r&&i.push(`fill:${r}`),u&&i.push(`stroke:${u}`),i.push(`color:${t.fontColor??"#FFFFFF"}`),i},"elementCssStyles"),pe=d((t,e,a,r,u)=>{const i=t.typeC4Shape.text,n=["c4-shape",`c4-${i}`];L0(i)&&n.push("c4-external");const l=D0(t),s=B0(t,e);return(l==="rounded"||l==="fr-rect")&&s.push("rx:12px","ry:12px"),{id:t.alias,label:t.label.text,stereotype:I0(t),description:t.descr?.text?[t.descr.text]:void 0,labelType:"string",isGroup:!1,shape:l,cssClasses:n.join(" "),cssStyles:s,padding:a,look:r,useHtmlLabels:!1,width:u}},"buildC4Node"),Nt=0,At=0,Te=4,te=2;Ft.yy=$t;var b={},ke=class{static{d(this,"Bounds")}constructor(t){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,ee(t.db.getConfig())}setData(t,e,a,r){this.nextData.startx=this.data.startx=t,this.nextData.stopx=this.data.stopx=e,this.nextData.starty=this.data.starty=a,this.nextData.stopy=this.data.stopy=r}updateVal(t,e,a,r){t[e]===void 0?t[e]=a:t[e]=r(a,t[e])}insert(t){this.nextData.cnt=this.nextData.cnt+1;const e=this.nextData.stopx,a=this.data.widthLimit;let r=this.nextData.startx===this.nextData.stopx?e+t.margin:e+t.margin*2,u=r+t.width,i=this.nextData.starty+t.margin*2,n=i+t.height;(r>=a||u>=a||this.nextData.cnt>Te)&&(r=this.nextData.startx+t.margin+b.nextLinePaddingX,i=this.nextData.stopy+t.margin*2,this.nextData.stopx=u=r+t.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=n=i+t.height,this.nextData.cnt=1),t.x=r,t.y=i,this.updateVal(this.data,"startx",r,Math.min),this.updateVal(this.data,"starty",i,Math.min),this.updateVal(this.data,"stopx",u,Math.max),this.updateVal(this.data,"stopy",n,Math.max),this.updateVal(this.nextData,"startx",r,Math.min),this.updateVal(this.nextData,"starty",i,Math.min),this.updateVal(this.nextData,"stopx",u,Math.max),this.updateVal(this.nextData,"stopy",n,Math.max)}init(t){this.name="",this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,widthLimit:void 0},this.nextData={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,cnt:0},ee(t.db.getConfig())}bumpLastMargin(t){this.data.stopx+=t,this.data.stopy+=t}},ee=d(function(t){Ye(b,t),t?.fontFamily&&(b.personFontFamily=b.systemFontFamily=b.messageFontFamily=t.fontFamily),t?.fontSize&&(b.personFontSize=b.systemFontSize=b.messageFontSize=t.fontSize),t?.fontWeight&&(b.personFontWeight=b.systemFontWeight=b.messageFontWeight=t.fontWeight)},"setConf"),Yt=d(t=>({fontFamily:t.boundaryFontFamily,fontSize:t.boundaryFontSize,fontWeight:t.boundaryFontWeight}),"boundaryFont"),V0=d(t=>({fontFamily:t.messageFontFamily,fontSize:t.messageFontSize,fontWeight:t.messageFontWeight}),"messageFont");function mt(t,e,a,r,u){const i=e[t];if(!i.width)if(a)i.text=je(i.text,u,r),i.textLines=i.text.split(Zt.lineBreakRegex).length,i.width=u,i.height=he(i.text,r);else{const n=i.text.split(Zt.lineBreakRegex);i.textLines=n.length;let l=0;i.height=0,i.width=0;for(const s of n)i.width=Math.max(Pt(s,r),i.width),l=he(s,r),i.height=i.height+l}return i}d(mt,"calcC4ShapeTextWH");var Ce=d(function(t,e,a){const r=a.data.startx,u=a.data.starty;e.x=r,e.y=u,e.width=a.data.stopx-r,e.height=a.data.stopy-u,e.intersect=s=>Fe.rect({x:e.x+e.width/2,y:e.y+e.height/2,width:e.width,height:e.height},s),e.label.y=b.c4ShapeMargin-35;const i=e.wrap&&b.wrap,n=Yt(b);n.fontSize=n.fontSize+2,n.fontWeight="bold";const l=Pt(e.label.text,n);mt("label",e,i,n,l),W.drawBoundary(t,e,b)},"drawBoundary"),Re=d(async function(t,e,a,r){const u=Rt(),i=u.look??"classic",n={config:u},l=e.attr("id")??"",s=r.map(y=>a[Number(y)]),h=d(y=>{const p=y.shape?Ue[y.shape]:void 0;if(!p)throw new Error(`C4: no shape handler for "${y.shape}"`);return p},"shapeHandlerFor");await Promise.all(s.map(async y=>{const p=pe(y,b,b.c4ShapePadding,i,b.width);p.domId=`${l}-${p.id}`;const g=await h(p)(e,p,n);y.width=p.width??b.width,y.height=p.height??b.height,y.margin=b.c4ShapeMargin,g.remove()}));for(const y of s)t.insert(y);await Promise.all(s.map(async y=>{const p=pe(y,b,b.c4ShapePadding,i,b.width);p.domId=`${l}-${p.id}`,p.x=y.x+y.width/2,p.y=y.y+y.height/2;const g=e.append("g").attr("transform",`translate(${y.x+y.width/2}, ${y.y+y.height/2})`);await h(p)(g,p,n),y.intersect=p.intersect})),t.bumpLastMargin(b.c4ShapeMargin)},"drawC4ShapeArray"),Y0=class{static{d(this,"Point")}constructor(t,e){this.x=t,this.y=e}},fe=d(function(t,e){if(!t.intersect)throw new Error(`C4 element "${t.alias}" has no intersect function. Please report this to https://github.com/mermaid-js/mermaid/issues`);const{x:a,y:r}=t.intersect(e);return new Y0(a,r)},"getIntersectPoint"),F0=d(function(t,e){const a={x:0,y:0};a.x=e.x+e.width/2,a.y=e.y+e.height/2;const r=fe(t,a);a.x=t.x+t.width/2,a.y=t.y+t.height/2;const u=fe(e,a);return{startPoint:r,endPoint:u}},"getIntersectPoints"),U0=d(function(t,e,a,r,u){const i=r.db.getC4Type();let n=0;for(const l of e){n=n+1;const s=l.wrap&&b.wrap,h=V0(b);i==="C4Dynamic"&&(l.label.text=n+": "+l.label.text);let y=Pt(l.label.text,h);mt("label",l,s,h,y),l.techn&&l.techn.text!==""&&(y=Pt(l.techn.text,h),mt("techn",l,s,h,y)),l.descr&&l.descr.text!==""&&(y=Pt(l.descr.text,h),mt("descr",l,s,h,y));const p=a(l.from),g=a(l.to);if(!p||!g)throw new Error(`C4 rel "${l.from}" -> "${l.to}" references an unknown shape or boundary`);const v=F0(p,g);if(!v.startPoint||!v.endPoint)throw new Error(`Could not calculate intersection points for rel "${l.from}" -> "${l.to}"`);l.startPoint=v.startPoint,l.endPoint=v.endPoint}W.drawRels(t,e,b,u)},"drawRels");async function ae(t,e,a,r,u){const i=u.db,n=new ke(u);n.data.widthLimit=a.data.widthLimit/Math.min(te,r.length);for(const[l,s]of r.entries()){let h=0;s.image={width:0,height:0,Y:0},s.sprite&&(s.image.width=48,s.image.height=48,s.image.Y=h,h=s.image.Y+s.image.height);const y=s.wrap&&b.wrap,p=Yt(b);p.fontSize=p.fontSize+2,p.fontWeight="bold";const g=mt("label",s,y,p,n.data.widthLimit);if(g.Y=h+8,h=g.Y+g.height,s.type&&s.type.text!==""){s.type.text="["+s.type.text+"]";const O=Yt(b),P=mt("type",s,y,O,n.data.widthLimit);P.Y=h+5,h=P.Y+P.height}if(s.descr&&s.descr.text!==""){const O=Yt(b);O.fontSize=O.fontSize-2;const P=mt("descr",s,y,O,n.data.widthLimit);P.Y=h+20,h=P.Y+P.height}if(l==0||l%te===0){const O=a.data.startx+b.diagramMarginX,P=a.data.stopy+b.diagramMarginY+h;n.setData(O,O,P,P)}else{const O=n.data.stopx!==n.data.startx?n.data.stopx+b.diagramMarginX:n.data.startx,P=n.data.starty;n.setData(O,O,P,P)}n.name=s.alias;const v=i.getC4ShapeArray(s.alias),w=i.getC4ShapeKeys(s.alias);w.length>0&&await Re(n,t,v,w),e=s.alias;const N=i.getBoundaries(e);N.length>0&&await ae(t,e,n,N,u),s.alias!=="global"&&Ce(t,s,n),a.data.stopy=Math.max(n.data.stopy+b.c4ShapeMargin,a.data.stopy),a.data.stopx=Math.max(n.data.stopx+b.c4ShapeMargin,a.data.stopx),Nt=Math.max(Nt,a.data.stopx),At=Math.max(At,a.data.stopy)}}d(ae,"drawInsideBoundary");var j0=d(async function(t,e,a,r){b=ge("c4");const u=Rt().securityLevel,{root:i}=R0(e,u),n=r.db;n.setWrap(b.wrap),Te=n.getC4ShapeInRow(),te=n.getC4BoundaryInRow(),ue.debug(`C:${JSON.stringify(b,null,2)}`);const l=i.select(`[id="${e}"]`);W.insertComputerIcon(l,e),W.insertDatabaseIcon(l,e),W.insertClockIcon(l,e);const s=new ke(r);s.setData(b.diagramMarginX,b.diagramMarginX,b.diagramMarginY,b.diagramMarginY),s.data.widthLimit=screen.availWidth,Nt=b.diagramMarginX,At=b.diagramMarginY;const h=n.getTitle(),y=n.getBoundaries("");await ae(l,"",s,y,r),W.insertArrowHead(l,e),W.insertArrowEnd(l,e),W.insertArrowCrossHead(l,e),W.insertArrowFilledHead(l,e),U0(l,n.getRels(),n.getC4Shape,r,e),s.data.stopx=Nt,s.data.stopy=At;const p=s.data,g=p.startx,v=p.starty,N=At-v+2*b.diagramMarginY,O=Nt-g,P=O+2*b.diagramMarginX;h&&l.append("text").text(h).attr("x",O/2-4*b.diagramMarginX).attr("y",v+b.diagramMarginY),Ve(l,N,P,b.useMaxWidth);const I=h?60:0;l.attr("viewBox",g-b.diagramMarginX+" -"+(b.diagramMarginY+I)+" "+P+" "+(N+I)),ue.debug("models:",p)},"draw"),ye={drawPersonOrSystemArray:Re,drawBoundary:Ce,setConf:ee,draw:j0},z0=d(()=>{const t=Rt().c4??{},e=new CSSStyleSheet;for(const a of Se){const r=e.cssRules[e.insertRule(`.c4-shape.c4-${a} .label {}`,e.cssRules.length)],u=t[`${a}FontFamily`],i=t[`${a}FontSize`],n=t[`${a}FontWeight`];u&&r.style.setProperty("font-family",u),i&&r.style.setProperty("font-size",typeof i=="number"?`${i}px`:i),n&&r.style.setProperty("font-weight",String(n))}return[...e.cssRules].filter(a=>a.style.length>0).map(a=>` ${a.cssText}`).join(`
7
+ `)},"elementFontStyles"),W0=d(t=>`.person {
8
+ stroke: ${t.personBorder};
9
+ fill: ${t.personBkg};
10
+ }
11
+ ${z0()}
12
+
13
+ /* The element font colour is set inline per element (default white); the
14
+ label text takes it via currentColor. */
15
+ .c4-shape .label,
16
+ .c4-shape .label text {
17
+ color: inherit;
18
+ fill: currentColor;
19
+ }
20
+ /* Structurizr typography: bold name, smaller stereotype/type and description lines. */
21
+ .c4-shape .label .c4-name {
22
+ font-weight: bold;
23
+ }
24
+ .c4-shape .label .c4-type {
25
+ font-size: 0.75em;
26
+ }
27
+ .c4-shape .label .c4-descr {
28
+ font-size: 0.82em;
29
+ }
30
+ .c4-shape .basic,
31
+ .c4-shape rect,
32
+ .c4-shape path,
33
+ .c4-shape circle,
34
+ .c4-shape ellipse,
35
+ .c4-shape line {
36
+ stroke-width: 2px;
37
+ }
38
+ `,"getStyles"),X0=W0,K0={parser:ze,db:$t,renderer:ye,styles:X0,init:d(({c4:t,wrap:e})=>{ye.setConf(t),$t.setWrap(e)},"init")};export{K0 as diagram};
@@ -0,0 +1,88 @@
1
+ import{_ as p,l as w,Q as L,L as E,z as I,W as X,d as H,j as q,c as G}from"./mermaid-C_q9pug0.js";var z="",b="",N="",A=[],R=new Map,k=p(e=>q(e,G()),"sanitizeText"),F=p(e=>{switch(e.type){case"terminal":return{...e,value:k(e.value)};case"nonterminal":return{...e,name:k(e.name)};case"sequence":return{...e,elements:e.elements.map(F)};case"choice":return{...e,alternatives:e.alternatives.map(F)};case"optional":return{...e,element:F(e.element)};case"repetition":return{...e,element:F(e.element),separator:e.separator?F(e.separator):void 0};case"special":return{...e,text:k(e.text)}}},"sanitizeAstNode"),U=p(()=>{z="",b="",N="",A.length=0,R.clear(),I(),w.debug("[Railroad] Database cleared")},"clear"),W=p(e=>{z=k(e),w.debug("[Railroad] Title set:",e)},"setTitle"),_=p(()=>z,"getTitle"),j=p(e=>{const i={...e,name:k(e.name),definition:F(e.definition),comment:e.comment?k(e.comment):void 0};w.debug("[Railroad] Adding rule:",i.name),R.has(i.name)&&w.warn(`[Railroad] Rule '${i.name}' is already defined. Overwriting.`),A.push(i),R.set(i.name,i)},"addRule"),K=p(()=>A,"getRules"),Q=p(e=>R.get(e),"getRule"),J=p(e=>{b=k(e).replace(/^\s+/g,""),w.debug("[Railroad] Accessibility title set:",e)},"setAccTitle"),Z=p(()=>b,"getAccTitle"),V=p(e=>{N=k(e).replace(/\n\s+/g,`
2
+ `),w.debug("[Railroad] Accessibility description set:",e)},"setAccDescription"),ee=p(()=>N,"getAccDescription"),te=W,re=_,ie={clear:U,setTitle:W,getTitle:_,addRule:j,getRules:K,getRule:Q,setAccTitle:J,getAccTitle:Z,setAccDescription:V,getAccDescription:ee,setDiagramTitle:te,getDiagramTitle:re},g={compactMode:!1,padding:10,verticalSeparation:8,horizontalSeparation:10,arcRadius:10,fontSize:14,fontFamily:"monospace",terminalFill:"#FFFFC0",terminalStroke:"#000000",terminalTextColor:"#000000",nonTerminalFill:"#FFFFFF",nonTerminalStroke:"#000000",nonTerminalTextColor:"#000000",lineColor:"#000000",strokeWidth:2,markerFill:"#000000",commentFill:"#E8E8E8",commentStroke:"#888888",commentTextColor:"#666666",specialFill:"#F0E0FF",specialStroke:"#8800CC",ruleNameColor:"#000066",showMarkers:!0,markerRadius:5},ne=/^#(?:[\da-f]{3,4}|[\da-f]{6}|[\da-f]{8})$|^(?:rgb|rgba|hsl|hsla|hwb|lab|lch|oklab|oklch)\([\d\s%+,./-]+\)$|^[a-z]+$/i,ae=/^[\w "',.-]+$/,oe=new Set(["compactMode","padding","verticalSeparation","horizontalSeparation","arcRadius","fontSize","fontFamily","terminalFill","terminalStroke","terminalTextColor","nonTerminalFill","nonTerminalStroke","nonTerminalTextColor","lineColor","strokeWidth","markerFill","commentFill","commentStroke","commentTextColor","specialFill","specialStroke","ruleNameColor","showMarkers","markerRadius"]),B=p(e=>e?Object.keys(e).every(i=>i==="railroad"||oe.has(i)):!1,"isRailroadStyleOptions"),le=p(e=>e?"railroad"in e&&e.railroad?e.railroad:B(e)?e:{}:{},"extractRailroadOverrides"),se=p(e=>{if(!e||B(e))return{};const{railroad:i,svgId:a,theme:r,look:t,...n}=e;return n},"extractThemeOverrides"),m=p((e,i)=>{if(typeof e!="string")return i;const a=e.trim();return ne.test(a)?a:i},"sanitizeColorValue"),Y=p((e,i)=>{if(typeof e!="string")return i;const a=e.trim();return ae.test(a)?a:i},"sanitizeFontFamilyValue"),S=p((e,i)=>{const a=typeof e=="number"?e:typeof e=="string"?Number.parseFloat(e):Number.NaN;return Number.isFinite(a)&&a>=0?a:i},"sanitizeNumberValue"),de=p(e=>{const i=typeof e=="number"?e:typeof e=="string"?Number.parseFloat(e):Number.NaN;return Number.isFinite(i)&&i>0?i:void 0},"parseThemeFontSize"),ce=p(e=>{const i=Y(e.fontFamily,g.fontFamily),a=de(e.fontSize)??g.fontSize;return{...g,fontFamily:i,fontSize:a,terminalFill:m(e.secondBkg??e.secondaryColor,g.terminalFill),terminalStroke:m(e.secondaryBorderColor??e.lineColor,g.terminalStroke),terminalTextColor:m(e.secondaryTextColor??e.textColor,g.terminalTextColor),nonTerminalFill:m(e.mainBkg??e.background,g.nonTerminalFill),nonTerminalStroke:m(e.primaryBorderColor??e.lineColor,g.nonTerminalStroke),nonTerminalTextColor:m(e.primaryTextColor??e.textColor,g.nonTerminalTextColor),lineColor:m(e.lineColor,g.lineColor),markerFill:m(e.lineColor,g.markerFill),commentFill:m(e.labelBackground??e.tertiaryColor,g.commentFill),commentStroke:m(e.tertiaryBorderColor??e.lineColor,g.commentStroke),commentTextColor:m(e.tertiaryTextColor??e.textColor,g.commentTextColor),specialFill:m(e.tertiaryColor??e.secondaryColor,g.specialFill),specialStroke:m(e.tertiaryBorderColor??e.secondaryBorderColor,g.specialStroke),ruleNameColor:m(e.titleColor??e.textColor,g.ruleNameColor)}},"buildThemeDefaults"),M=p(e=>{const i=E(),a={...X(),...i.themeVariables??{},...se(e)},r=ce(a),t={...i.railroad??{},...le(e)};return{compactMode:t.compactMode??r.compactMode,padding:S(t.padding,r.padding),verticalSeparation:S(t.verticalSeparation,r.verticalSeparation),horizontalSeparation:S(t.horizontalSeparation,r.horizontalSeparation),arcRadius:S(t.arcRadius,r.arcRadius),fontSize:S(t.fontSize,r.fontSize),fontFamily:Y(t.fontFamily,r.fontFamily),terminalFill:m(t.terminalFill,r.terminalFill),terminalStroke:m(t.terminalStroke,r.terminalStroke),terminalTextColor:m(t.terminalTextColor,r.terminalTextColor),nonTerminalFill:m(t.nonTerminalFill,r.nonTerminalFill),nonTerminalStroke:m(t.nonTerminalStroke,r.nonTerminalStroke),nonTerminalTextColor:m(t.nonTerminalTextColor,r.nonTerminalTextColor),lineColor:m(t.lineColor,r.lineColor),strokeWidth:S(t.strokeWidth,r.strokeWidth),markerFill:m(t.markerFill,r.markerFill),commentFill:m(t.commentFill,r.commentFill),commentStroke:m(t.commentStroke,r.commentStroke),commentTextColor:m(t.commentTextColor,r.commentTextColor),specialFill:m(t.specialFill,r.specialFill),specialStroke:m(t.specialStroke,r.specialStroke),ruleNameColor:m(t.ruleNameColor,r.ruleNameColor),showMarkers:t.showMarkers??r.showMarkers,markerRadius:S(t.markerRadius,r.markerRadius)}},"buildRailroadStyleOptions"),ue=p(e=>{const{fontFamily:i,fontSize:a,terminalFill:r,terminalStroke:t,terminalTextColor:n,nonTerminalFill:h,nonTerminalStroke:s,nonTerminalTextColor:o,lineColor:u,strokeWidth:c,markerFill:d,commentFill:x,commentStroke:l,commentTextColor:f,specialFill:y,specialStroke:v,ruleNameColor:C}=M(e);return`
3
+ .railroad-diagram {
4
+ font-family: ${i};
5
+ font-size: ${a}px;
6
+ }
7
+
8
+ .railroad-terminal rect {
9
+ fill: ${r};
10
+ stroke: ${t};
11
+ stroke-width: ${c}px;
12
+ }
13
+
14
+ .railroad-terminal text {
15
+ fill: ${n};
16
+ font-family: ${i};
17
+ font-size: ${a}px;
18
+ text-anchor: middle;
19
+ dominant-baseline: middle;
20
+ }
21
+
22
+ .railroad-nonterminal rect {
23
+ fill: ${h};
24
+ stroke: ${s};
25
+ stroke-width: ${c}px;
26
+ }
27
+
28
+ .railroad-nonterminal text {
29
+ fill: ${o};
30
+ font-family: ${i};
31
+ font-size: ${a}px;
32
+ text-anchor: middle;
33
+ dominant-baseline: middle;
34
+ }
35
+
36
+ .railroad-line {
37
+ stroke: ${u};
38
+ stroke-width: ${c}px;
39
+ fill: none;
40
+ }
41
+
42
+ .railroad-start circle,
43
+ .railroad-end circle {
44
+ fill: ${d};
45
+ }
46
+
47
+ .railroad-comment ellipse {
48
+ fill: ${x};
49
+ stroke: ${l};
50
+ stroke-width: ${c}px;
51
+ }
52
+
53
+ .railroad-comment text {
54
+ fill: ${f};
55
+ font-style: italic;
56
+ font-family: ${i};
57
+ font-size: ${a}px;
58
+ text-anchor: middle;
59
+ dominant-baseline: middle;
60
+ }
61
+
62
+ .railroad-special rect {
63
+ fill: ${y};
64
+ stroke: ${v};
65
+ stroke-width: ${c}px;
66
+ stroke-dasharray: 5,3;
67
+ }
68
+
69
+ .railroad-special text {
70
+ fill: ${o};
71
+ font-family: ${i};
72
+ font-size: ${a}px;
73
+ text-anchor: middle;
74
+ dominant-baseline: middle;
75
+ }
76
+
77
+ .railroad-rule-name {
78
+ font-weight: bold;
79
+ fill: ${C};
80
+ font-family: ${i};
81
+ font-size: ${a}px;
82
+ }
83
+
84
+ .railroad-group {
85
+ /* Grouping container, no specific styles */
86
+ }
87
+ `},"getStyles"),T=class{constructor(){this.d=""}static{p(this,"PathBuilder")}moveTo(e,i){return this.d+=`M ${e} ${i} `,this}lineTo(e,i){return this.d+=`L ${e} ${i} `,this}horizontalTo(e){return this.d+=`H ${e} `,this}verticalTo(e){return this.d+=`V ${e} `,this}arcTo(e,i,a,r,t,n,h){return this.d+=`A ${e} ${i} ${a} ${r?1:0} ${t?1:0} ${n} ${h} `,this}build(){return this.d.trim()}},me=class{constructor(e,i=M()){this.textCache=new Map,this.svg=e,this.config=i}static{p(this,"RailroadRenderer")}measureText(e){if(this.textCache.has(e))return this.textCache.get(e);const i=this.svg.append("text").attr("font-family",this.config.fontFamily).attr("font-size",this.config.fontSize).text(e),a=i.node().getBBox(),r={width:a.width,height:a.height};return i.remove(),this.textCache.set(e,r),r}renderTerminal(e,i){const a=this.measureText(i),r=a.width+this.config.padding*2,t=a.height+this.config.padding*2,n=e.append("g").attr("class","railroad-terminal");return n.append("rect").attr("x",0).attr("y",0).attr("width",r).attr("height",t).attr("rx",10).attr("ry",10),n.append("text").attr("x",r/2).attr("y",t/2).text(i),{element:n.node(),dimensions:{width:r,height:t,up:t/2,down:t/2}}}renderNonTerminal(e,i){const a=this.measureText(i),r=a.width+this.config.padding*2,t=a.height+this.config.padding*2,n=e.append("g").attr("class","railroad-nonterminal");return n.append("rect").attr("x",0).attr("y",0).attr("width",r).attr("height",t),n.append("text").attr("x",r/2).attr("y",t/2).text(i),{element:n.node(),dimensions:{width:r,height:t,up:t/2,down:t/2}}}renderSequence(e,i){const a=i.map(o=>this.renderExpression(e,o));let r=0,t=0,n=0;for(const o of a)r+=o.dimensions.width,t=Math.max(t,o.dimensions.up),n=Math.max(n,o.dimensions.down);r+=(a.length-1)*this.config.horizontalSeparation;const h=e.append("g").attr("class","railroad-sequence");let s=0;for(let o=0;o<a.length;o++){const u=a[o],c=t-u.dimensions.up;if(h.node().appendChild(u.element).setAttribute("transform",`translate(${s}, ${c})`),o<a.length-1){const x=s+u.dimensions.width,l=x+this.config.horizontalSeparation,f=t;h.append("path").attr("class","railroad-line").attr("d",new T().moveTo(x,f).lineTo(l,f).build())}s+=u.dimensions.width+this.config.horizontalSeparation}return{element:h.node(),dimensions:{width:r,height:t+n,up:t,down:n}}}renderChoice(e,i){const a=i.map(d=>this.renderExpression(e,d));let r=0,t=0;for(const d of a)r=Math.max(r,d.dimensions.width),t+=d.dimensions.height;t+=(a.length-1)*this.config.verticalSeparation;const n=this.config.arcRadius,h=n*4,s=r+h,o=e.append("g").attr("class","railroad-choice");let u=0;const c=t/2;for(const d of a){const x=u,l=x+d.dimensions.up,f=n*2+(r-d.dimensions.width)/2;o.node().appendChild(d.element).setAttribute("transform",`translate(${f}, ${x})`);const v=new T,C=l>c;l===c?v.moveTo(0,c).lineTo(f,l):v.moveTo(0,c).arcTo(n,n,0,!1,C,n,c+(C?n:-n)).lineTo(n,l-(C?n:-n)).arcTo(n,n,0,!1,!C,n*2,l).lineTo(f,l),o.append("path").attr("class","railroad-line").attr("d",v.build());const $=new T,O=f+d.dimensions.width,P=s-n*2;l===c?$.moveTo(O,l).lineTo(s,c):$.moveTo(O,l).lineTo(P,l).arcTo(n,n,0,!1,!C,s-n,l+(C?-n:n)).lineTo(s-n,c+(C?n:-n)).arcTo(n,n,0,!1,C,s,c),o.append("path").attr("class","railroad-line").attr("d",$.build()),u+=d.dimensions.height+this.config.verticalSeparation}return{element:o.node(),dimensions:{width:s,height:t,up:c,down:t-c}}}renderOptional(e,i){const a=this.renderExpression(e,i),r=this.config.arcRadius,t=r*2,n=a.dimensions.width+r*4,h=a.dimensions.height+t,s=e.append("g").attr("class","railroad-optional"),o=r*2,u=t;s.node().appendChild(a.element).setAttribute("transform",`translate(${o}, ${u})`);const d=u+a.dimensions.up,x=new T().moveTo(0,d).lineTo(r*2,d);s.append("path").attr("class","railroad-line").attr("d",x.build());const l=new T().moveTo(o+a.dimensions.width,d).lineTo(n,d);s.append("path").attr("class","railroad-line").attr("d",l.build());const f=new T().moveTo(0,d).arcTo(r,r,0,!1,!1,r,d-r).lineTo(r,r).arcTo(r,r,0,!1,!0,r*2,0).lineTo(n-r*2,0).arcTo(r,r,0,!1,!0,n-r,r).lineTo(n-r,d-r).arcTo(r,r,0,!1,!1,n,d);return s.append("path").attr("class","railroad-line").attr("d",f.build()),{element:s.node(),dimensions:{width:n,height:h,up:d,down:h-d}}}renderRepetition(e,i,a){const r=this.renderExpression(e,i),t=this.config.arcRadius,n=t*2,h=r.dimensions.width+t*4,s=a===0,o=r.dimensions.height+n+(s?n:0),u=e.append("g").attr("class","railroad-repetition"),c=t*2,d=s?n:0;u.node().appendChild(r.element).setAttribute("transform",`translate(${c}, ${d})`);const l=d+r.dimensions.up;u.append("path").attr("class","railroad-line").attr("d",new T().moveTo(0,l).lineTo(t*2,l).build()),u.append("path").attr("class","railroad-line").attr("d",new T().moveTo(c+r.dimensions.width,l).lineTo(h,l).build());const f=d+r.dimensions.height+t,y=new T().moveTo(c+r.dimensions.width,l).arcTo(t,t,0,!1,!0,c+r.dimensions.width+t,l+t).lineTo(c+r.dimensions.width+t,f).arcTo(t,t,0,!1,!0,c+r.dimensions.width,f+t).lineTo(t*2,f+t).arcTo(t,t,0,!1,!0,t,f).lineTo(t,l+t).arcTo(t,t,0,!1,!0,t*2,l);if(u.append("path").attr("class","railroad-line").attr("d",y.build()),s){const v=new T().moveTo(0,l).arcTo(t,t,0,!1,!1,t,l-t).lineTo(t,t).arcTo(t,t,0,!1,!0,t*2,0).lineTo(h-t*2,0).arcTo(t,t,0,!1,!0,h-t,t).lineTo(h-t,l-t).arcTo(t,t,0,!1,!1,h,l);u.append("path").attr("class","railroad-line").attr("d",v.build())}return{element:u.node(),dimensions:{width:h,height:o,up:l,down:o-l}}}renderSpecial(e,i){const a=this.measureText("? "+i+" ?"),r=a.width+this.config.padding*2,t=a.height+this.config.padding*2,n=e.append("g").attr("class","railroad-special");return n.append("rect").attr("x",0).attr("y",0).attr("width",r).attr("height",t),n.append("text").attr("x",r/2).attr("y",t/2).text("? "+i+" ?"),{element:n.node(),dimensions:{width:r,height:t,up:t/2,down:t/2}}}renderExpression(e,i){switch(i.type){case"terminal":return this.renderTerminal(e,i.value);case"nonterminal":return this.renderNonTerminal(e,i.name);case"sequence":return this.renderSequence(e,i.elements);case"choice":return this.renderChoice(e,i.alternatives);case"optional":return this.renderOptional(e,i.element);case"repetition":return this.renderRepetition(e,i.element,i.min);case"special":return this.renderSpecial(e,i.text);default:throw new Error(`Unknown node type: ${i.type}`)}}renderRule(e,i){const a=this.svg.append("g").attr("class","railroad-rule").attr("transform",`translate(0, ${i})`),r=e.name+" =",t=this.measureText(r).width+20,n=t+20,h=a.append("g"),s=this.renderExpression(h,e.definition),o=Math.max(20,s.dimensions.up),u=o-s.dimensions.up;return h.attr("transform",`translate(${n}, ${u})`),a.append("g").attr("class","railroad-rule-name-group").append("text").attr("class","railroad-rule-name").attr("x",0).attr("y",o).text(r),a.append("g").attr("class","railroad-start").append("circle").attr("cx",t).attr("cy",o).attr("r",this.config.markerRadius),a.append("g").attr("class","railroad-end").append("circle").attr("cx",n+s.dimensions.width+10).attr("cy",o).attr("r",this.config.markerRadius),a.append("path").attr("class","railroad-line").attr("d",new T().moveTo(t+this.config.markerRadius,o).lineTo(n,o).build()),a.append("path").attr("class","railroad-line").attr("d",new T().moveTo(n+s.dimensions.width,o).lineTo(n+s.dimensions.width+10-this.config.markerRadius,o).build()),{height:Math.max(40,u+s.dimensions.height+this.config.padding*2),width:n+s.dimensions.width+10+this.config.markerRadius}}renderDiagram(e){let i=this.config.padding,a=0;for(const r of e){const t=this.renderRule(r,i);i+=t.height+this.config.verticalSeparation,a=Math.max(a,t.width)}return{width:a+this.config.padding*2,height:i+this.config.padding}}},D=p((e,i,a)=>{H(e,i.height,i.width,a),e.attr("viewBox",`0 0 ${i.width} ${i.height}`)},"configureRailroadSvgSize"),he=p((e,i,a)=>{w.debug(`[Railroad] Rendering diagram
88
+ `+e);try{const r=L(i);r.attr("class","railroad-diagram");const n=E().railroad?.useMaxWidth??!0,h=ie.getRules();if(w.debug(`[Railroad] Rendering ${h.length} rules`),h.length===0){w.warn("[Railroad] No rules to render"),D(r,{height:100,width:200},n);return}const o=new me(r,M()).renderDiagram(h);D(r,o,n),w.debug("[Railroad] Render complete")}catch(r){throw w.error("[Railroad] Render error:",r),r}},"draw"),ge={draw:he};export{ie as d,ue as g,ge as r};
@@ -0,0 +1 @@
1
+ import{_ as i}from"./mermaid-C_q9pug0.js";var r=class{constructor(t){this.init=t,this.records=this.init()}static{i(this,"ImperativeState")}reset(){this.records=this.init()}};export{r as I};
@@ -0,0 +1 @@
1
+ import{ax as B,_ as y}from"./mermaid-C_q9pug0.js";var w=5,O=1e-5,X=2,Y=.6,R=1e-6;function N(t){const e=[];for(let s=0;s<t.length-1;s++)e.push({a:t[s],b:t[s+1]});return e}y(N,"buildSegmentList");function T(t,e,s,a){const r=e.x-t.x,o=e.y-t.y,i=a.x-s.x,d=a.y-s.y,u=r*d-o*i;if(u===0)return null;const n=s.x-t.x,c=s.y-t.y,p=(n*d-c*i)/u,f=(n*o-c*r)/u;return p<=R||p>=1-R||f<=R||f>=1-R?null:{point:{x:t.x+p*r,y:t.y+p*o},tA:p,tB:f}}y(T,"segmentIntersection");function P(t){return Math.abs(t.b.x-t.a.x)>=Math.abs(t.b.y-t.a.y)}y(P,"isHorizontalSeg");function v(t,e,s){if(t.curve!=="rounded")return!1;const a=t.points,r=a[e],o=a[e+1];if(!r||!o)return!1;const i=Math.hypot(o.x-r.x,o.y-r.y),d=s*i,u=e>0?L(a[e-1],r,o,w):null;if(u&&d<u.cutLen)return!0;const n=e+2<a.length?L(r,o,a[e+2],w):null;return n!==null&&i-d<n.cutLen}y(v,"crossingSitsInRoundedCorner");function _(t){const e=[];for(let s=0;s<t.length;s++){const a=t[s],r=N(a.points);for(let o=s+1;o<t.length;o++){const i=t[o],d=N(i.points);for(const[u,n]of r.entries())for(const[c,p]of d.entries()){const f=T(n.a,n.b,p.a,p.b);if(!f||v(a,u,f.tA)||v(i,c,f.tB))continue;const g=P(n),S=P(p);(g!==S?g:!1)?e.push({jumpEdgeId:a.id,otherEdgeId:i.id,segIndex:u,t:f.tA,point:f.point}):e.push({jumpEdgeId:i.id,otherEdgeId:a.id,segIndex:c,t:f.tB,point:f.point})}}}return e}y(_,"findEdgeIntersections");function M(t){const e=Math.round(t*1e3)/1e3;return Number.isInteger(e)?`${e}`:`${e}`}y(M,"fmt");function A(t){return`${M(t.x)},${M(t.y)}`}y(A,"pointToString");function C(t){const e=t.b.x-t.a.x,s=t.b.y-t.a.y;return Math.abs(e)>=Math.abs(s)?e>=0?1:0:s>=0?1:0}y(C,"getArcSweepFlag");function D(t,e){if(t.length<2)return t.map(o=>({...o}));const s=t.map(o=>({...o})),a=e.arrowTypeStart&&B[e.arrowTypeStart];if(a){const o=t[0],i=t[1],d=Math.atan2(i.y-o.y,i.x-o.x);s[0].x=o.x+a*Math.cos(d),s[0].y=o.y+a*Math.sin(d)}const r=e.arrowTypeEnd&&B[e.arrowTypeEnd];if(r){const o=t.length,i=t[o-2],d=t[o-1],u=Math.atan2(d.y-i.y,d.x-i.x);s[o-1].x=d.x-r*Math.cos(u),s[o-1].y=d.y-r*Math.sin(u)}return s}y(D,"applyMarkerOffsets");function k(t,e,s,a,r){const o=t.point.x,i=t.point.y,d={x:o-e*t.r,y:i-s*t.r},u={x:o+e*t.r,y:i+s*t.r},n=[`L${A(d)}`];return r==="arc"?n.push(`A${M(t.r)},${M(t.r)} 0 0 ${a} ${A(u)}`):n.push(`M${A(u)}`),n}y(k,"emitJump");function L(t,e,s,a){const r=e.x-t.x,o=e.y-t.y,i=s.x-e.x,d=s.y-e.y,u=Math.hypot(r,o),n=Math.hypot(i,d);if(u<O||n<O)return null;const c=r/u,p=o/u,f=i/n,g=d/n,S=c*f+p*g,b=Math.max(-1,Math.min(1,S)),m=Math.acos(b);if(m<O||Math.abs(Math.PI-m)<O)return null;const h=Math.min(a/Math.sin(m/2),u/2,n/2);return{startX:e.x-c*h,startY:e.y-p*h,endX:e.x+f*h,endY:e.y+g*h,ctrlX:e.x,ctrlY:e.y,cutLen:h}}y(L,"computeRoundedCorner");function H(t,e,s){const a=t.points;if(a.length<2)return"";const r=D(a,t),o=t.curve==="rounded",i=N(r),d=new Map;for(const n of e){const c=i[n.segIndex];if(!c)continue;const p=Math.hypot(c.b.x-c.a.x,c.b.y-c.a.y),f=d.get(n.segIndex)??[];f.push({t:n.t,point:n.point,d:n.t*p,r:s.jumpRadius}),d.set(n.segIndex,f)}const u=[`M${A(r[0])}`];for(let n=0;n<i.length;n++){const c=i[n],p=Math.hypot(c.b.x-c.a.x,c.b.y-c.a.y),f=p===0?0:(c.b.x-c.a.x)/p,g=p===0?0:(c.b.y-c.a.y)/p,S=C(c);let b=0;if(o&&n>0){const l=L(r[n-1],r[n],r[n+1]??r[n],w);l&&(b=l.cutLen)}let m=p,h=null;o&&n<i.length-1&&(h=L(r[n],r[n+1],r[n+2]??r[n+1],w),h&&(m=p-h.cutLen));const $=s.jumpRadius*Y,x=[...d.get(n)??[]].sort((l,E)=>l.t-E.t).filter(l=>{const E=Math.min(l.d-b,m-l.d)-X;return l.r=Math.min(l.r,E),l.r>=$});for(let l=0;l<x.length-1;l++){const E=x[l+1].d-x[l].d;if(x[l].r+x[l+1].r>E){const I=E/2;x[l].r=Math.min(x[l].r,I),x[l+1].r=Math.min(x[l+1].r,I)}}for(const l of x)l.r<$||u.push(...k(l,f,g,S,s.jumpStyle));o&&h?(u.push(`L${M(h.startX)},${M(h.startY)}`),u.push(`Q${M(h.ctrlX)},${M(h.ctrlY)} ${M(h.endX)},${M(h.endY)}`)):u.push(`L${A(c.b)}`)}return u.join(" ")}y(H,"rewriteEdgePath");function J(t){return/^[\d\s+,.LMelm-]*$/.test(t)}y(J,"isStraightPath");function U(t){return t?t==="linear"||t==="rounded"||t==="step"||t==="stepBefore"||t==="stepAfter":!0}y(U,"curveSupportsLineHops");function j(t){if(!t)return null;try{const e=typeof atob=="function"?atob(t):Buffer.from(t,"base64").toString(),s=JSON.parse(e);if(!Array.isArray(s))return null;const a=[];for(const r of s)r&&typeof r.x=="number"&&typeof r.y=="number"&&a.push({x:r.x,y:r.y});return a.length>=2?a:null}catch{return null}}y(j,"decodeDataPoints");function F(t,e,s){if(!s.enabled)return;const a=t.node();if(!a)return;const r=new Map;for(const n of e)r.set(n.id,n);const o=new Map;for(const n of a.querySelectorAll("path[data-id]")){const c=n.getAttribute("data-id");c!==null&&!o.has(c)&&o.set(c,n)}const i=[];for(const n of e){const c=o.get(n.id);if(!c)continue;const f=j(c.getAttribute("data-points"))??n.points;i.push({...n,points:f})}const d=_(i);if(d.length===0)return;const u=new Map;for(const n of d){const c=u.get(n.jumpEdgeId)??[];c.push(n),u.set(n.jumpEdgeId,c)}for(const n of i){const c=u.get(n.id);if(!c||c.length===0)continue;const f=r.get(n.id)?.curve;if(f!==void 0&&!U(f))continue;const g=o.get(n.id);if(!g)continue;if(f===void 0){const x=g.getAttribute("d")??"";if(!J(x))continue}const S=g.getAttribute("style")??"",b=/stroke-dasharray\s*:\s*0\s+([\d.]+)\s+[\d.]+\s+([\d.]+)/.exec(S),m=b?Number.parseFloat(b[1]):null,h=b?Number.parseFloat(b[2]):null,$=H(n,c,s);if(g.setAttribute("d",$),m!==null&&h!==null&&typeof g.getTotalLength=="function"){const x=g.getTotalLength(),l=Math.max(0,x-m-h),E=`0 ${m} ${l} ${h}`,I=S.replace(/stroke-dasharray\s*:[^;]*;?/g,`stroke-dasharray: ${E};`).replace(/;\s*;+/g,";");g.setAttribute("style",I)}}}y(F,"applyLineJumpsToSvg");export{F as a};
@@ -0,0 +1 @@
1
+ import{_ as i,k as l,a7 as d,$ as o}from"./mermaid-C_q9pug0.js";var x=i((r,t)=>{const e=r.append("rect");if(e.attr("x",t.x),e.attr("y",t.y),e.attr("fill",t.fill),e.attr("stroke",t.stroke),e.attr("width",t.width),e.attr("height",t.height),t.name&&e.attr("name",t.name),t.rx&&e.attr("rx",t.rx),t.ry&&e.attr("ry",t.ry),t.attrs!==void 0)for(const s in t.attrs)e.attr(s,t.attrs[s]);return t.class&&e.attr("class",t.class),e},"drawRect"),p=i((r,t)=>{const e={x:t.startx,y:t.starty,width:t.stopx-t.startx,height:t.stopy-t.starty,fill:t.fill,stroke:t.stroke,class:"rect"};x(r,e).lower()},"drawBackgroundRect"),y=i((r,t)=>{const e=t.text.replace(d," "),s=r.append("text");s.attr("x",t.x),s.attr("y",t.y),s.attr("class","legend"),s.style("text-anchor",t.anchor),t.class&&s.attr("class",t.class);const a=s.append("tspan");return a.attr("x",t.x+t.textMargin*2),a.text(e),s},"drawText"),m=i((r,t,e,s)=>{const a=r.append("image");a.attr("x",t),a.attr("y",e);const n=o.sanitizeUrl(s);a.attr("xlink:href",n)},"drawImage"),g=i((r,t,e,s)=>{const a=r.append("use");a.attr("x",t),a.attr("y",e);const n=o.sanitizeUrl(s);a.attr("xlink:href",`#${n}`)},"drawEmbeddedImage"),h=i(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),f=i(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj"),w=i(()=>{let r=l(".mermaidTooltip");return r.empty()&&(r=l("body").append("div").attr("class","mermaidTooltip").style("opacity",0).style("position","absolute").style("text-align","center").style("max-width","200px").style("padding","2px").style("font-size","12px").style("background","#ffffde").style("border","1px solid #333").style("border-radius","2px").style("pointer-events","none").style("z-index","100")),r},"createTooltip");export{p as a,h as b,w as c,x as d,g as e,m as f,f as g,y as h};
@@ -0,0 +1,15 @@
1
+ import{_ as e}from"./mermaid-C_q9pug0.js";var l=e(()=>`
2
+ /* Font Awesome icon styling - consolidated */
3
+ .label-icon {
4
+ display: inline-block;
5
+ height: 1em;
6
+ overflow: visible;
7
+ vertical-align: -0.125em;
8
+ }
9
+
10
+ .node .label-icon path {
11
+ fill: currentColor;
12
+ stroke: revert;
13
+ stroke-width: revert;
14
+ }
15
+ `,"getIconStyles");export{l as g};
@@ -0,0 +1 @@
1
+ import{_ as i}from"./mermaid-C_q9pug0.js";function t(c,e){c.accDescr&&e.setAccDescription?.(c.accDescr),c.accTitle&&e.setAccTitle?.(c.accTitle),c.title&&e.setDiagramTitle?.(c.title)}i(t,"populateCommonDb");export{t as p};
@@ -0,0 +1 @@
1
+ import{_ as a,d as w,l as x}from"./mermaid-C_q9pug0.js";var B=a((e,t,i,r)=>{e.attr("class",i);const{width:o,height:h,x:n,y:c}=u(e,t);w(e,h,o,r);const s=d(n,c,o,h,t);e.attr("viewBox",s),x.debug(`viewBox configured: ${s} with padding: ${t}`)},"setupViewPortForSVG"),u=a((e,t)=>{const i=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:i.width+t*2,height:i.height+t*2,x:i.x,y:i.y}},"calculateDimensionsWithPadding"),d=a((e,t,i,r,o)=>`${e-o} ${t-o} ${i} ${r}`,"createViewBox");export{B as s};
@@ -0,0 +1 @@
1
+ import{_ as a,k as o}from"./mermaid-C_q9pug0.js";var g=a((t,e)=>{let n;return e==="sandbox"&&(n=o("#i"+t)),(e==="sandbox"?o(n.nodes()[0].contentDocument.body):o("body")).select(`[id="${t}"]`)},"getDiagramElement");export{g};