@leanspec/ui 0.2.21 → 0.2.23

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 (129) hide show
  1. package/dist/assets/_baseUniq-C4bkXOdh-BJ3-SRjw.js +1 -0
  2. package/dist/assets/{_baseUniq--5gbTAb8.js → _baseUniq-DuAmhUI0.js} +1 -1
  3. package/dist/assets/arc-DFohBtPV-Cpx6wOGp.js +1 -0
  4. package/dist/assets/{arc-4N6yDHjl.js → arc-DlFrPohT.js} +1 -1
  5. package/dist/assets/{architectureDiagram-VXUJARFQ-DDCzyF2V.js → architectureDiagram-VXUJARFQ-DieXp-qW.js} +1 -1
  6. package/dist/assets/architectureDiagram-VXUJARFQ-_R9_zrc5-D59ZHzYq.js +36 -0
  7. package/dist/assets/blockDiagram-VD42YOAC-CiyHYW6w-D8Afi1Q2.js +122 -0
  8. package/dist/assets/{blockDiagram-VD42YOAC-CqzgSlfV.js → blockDiagram-VD42YOAC-Cr1Ymz-c.js} +1 -1
  9. package/dist/assets/c4Diagram-YG6GDRKO-D9NuNc3r-Cre6pw7Q.js +10 -0
  10. package/dist/assets/{c4Diagram-YG6GDRKO-DcDDI9XD.js → c4Diagram-YG6GDRKO-w76CB7zN.js} +1 -1
  11. package/dist/assets/channel-C9MJ1fN1.js +1 -0
  12. package/dist/assets/channel-mhjF1lKa-DRGKdmbU.js +1 -0
  13. package/dist/assets/{chunk-4BX2VUAB-CVAs-OQz.js → chunk-4BX2VUAB-C4VXUg_9.js} +1 -1
  14. package/dist/assets/chunk-4BX2VUAB-D4Zhvat9-CJ2cQFgO.js +1 -0
  15. package/dist/assets/{chunk-55IACEB6-Dd3NjClm-icx5kZVe.js → chunk-55IACEB6-C_MzxCLx-DeYSk-O4.js} +1 -1
  16. package/dist/assets/{chunk-55IACEB6-Ccr-HMFu.js → chunk-55IACEB6-DUEMD_vX.js} +1 -1
  17. package/dist/assets/{chunk-B4BG7PRW-xLNbTmXA.js → chunk-B4BG7PRW-DlwRLtQb.js} +1 -1
  18. package/dist/assets/{chunk-B4BG7PRW-DLUrgkJI-Cic_-nsr.js → chunk-B4BG7PRW-Q8H7OQ1o-CGrle4fB.js} +6 -6
  19. package/dist/assets/{chunk-DI55MBZ5-BsHIkgDC.js → chunk-DI55MBZ5-DqvoeGRX.js} +1 -1
  20. package/dist/assets/chunk-DI55MBZ5-qwPYmgAw-BDnXruql.js +220 -0
  21. package/dist/assets/{chunk-FMBD7UC4-6dsbMKM7-DZVEYpsF.js → chunk-FMBD7UC4-DhXvRHU3-Ck_6Dma3.js} +1 -1
  22. package/dist/assets/{chunk-FMBD7UC4-CN5kw4_J.js → chunk-FMBD7UC4-eFjHw5gB.js} +1 -1
  23. package/dist/assets/chunk-QN33PNHL-CLwAcvO2-CC8RVa2u.js +1 -0
  24. package/dist/assets/{chunk-QN33PNHL-CHu6LVbN.js → chunk-QN33PNHL-CXXtNr0q.js} +1 -1
  25. package/dist/assets/{chunk-QZHKN3VN-CVAEdzef-CICjYRZu.js → chunk-QZHKN3VN-3tLb49S_-7wBVjYM3.js} +1 -1
  26. package/dist/assets/{chunk-QZHKN3VN-DOlyc5a_.js → chunk-QZHKN3VN-HkJTS77T.js} +1 -1
  27. package/dist/assets/{chunk-TZMSLE5B-qgYeZfVw.js → chunk-TZMSLE5B-CC9IwurK.js} +1 -1
  28. package/dist/assets/{chunk-TZMSLE5B-Cc8_PJIq-DBNHj8Jc.js → chunk-TZMSLE5B-DfaYobmr-uCvXwJUe.js} +1 -1
  29. package/dist/assets/classDiagram-2ON5EDUG-Dl5mwgLk.js +1 -0
  30. package/dist/assets/classDiagram-2ON5EDUG-xB0RyXwt-B4jZvvsf.js +1 -0
  31. package/dist/assets/classDiagram-v2-WZHVMYZB-Dl5mwgLk.js +1 -0
  32. package/dist/assets/classDiagram-v2-WZHVMYZB-xB0RyXwt-B4jZvvsf.js +1 -0
  33. package/dist/assets/clone-B-ElcgAC.js +1 -0
  34. package/dist/assets/clone-DqT6If4_-aVfgI0F6.js +1 -0
  35. package/dist/assets/code-block-37QAKDTI-CWOOD74I-DcBaZRtr.js +2 -0
  36. package/dist/assets/{cose-bilkent-S5V4N54A-aMn5Snue.js → cose-bilkent-S5V4N54A-BYenyErH.js} +1 -1
  37. package/dist/assets/{cose-bilkent-S5V4N54A-0O3dLIoy-Au1JV0Hr.js → cose-bilkent-S5V4N54A-DBS7wwrE-CwpmLGLG.js} +1 -1
  38. package/dist/assets/{cytoscape.esm-CjI2IsL8-U70Mzu-N.js → cytoscape.esm-Cvf3sx9F-DgU3JdRZ.js} +1 -1
  39. package/dist/assets/{dagre-6UL2VRFP-C0nN6YID.js → dagre-6UL2VRFP-DC4sfLGs.js} +1 -1
  40. package/dist/assets/dagre-6UL2VRFP-Lv6cE2gX-BtLPrZf0.js +4 -0
  41. package/dist/assets/diagram-PSM6KHXK-8QKT-Vki-CYrLTehq.js +24 -0
  42. package/dist/assets/{diagram-PSM6KHXK-DhvTMswv.js → diagram-PSM6KHXK-DSaG1dLc.js} +1 -1
  43. package/dist/assets/diagram-QEK2KX5R-Bqh-tlSV-BSsdJ6p7.js +43 -0
  44. package/dist/assets/{diagram-QEK2KX5R-w4lZ6XEJ.js → diagram-QEK2KX5R-z8D6ilji.js} +1 -1
  45. package/dist/assets/diagram-S2PKOQOG-Csj0p-s--BSyJI4Aq.js +24 -0
  46. package/dist/assets/{diagram-S2PKOQOG-DOXHCu2g.js → diagram-S2PKOQOG-gFoeY1VL.js} +1 -1
  47. package/dist/assets/{erDiagram-Q2GNP2WA-B0P-TPNi.js → erDiagram-Q2GNP2WA-oZvzX2B_.js} +1 -1
  48. package/dist/assets/{erDiagram-Q2GNP2WA-CXv6THpi-Cd4jg1J5.js → erDiagram-Q2GNP2WA-sDpapMNP-BlW75l-5.js} +5 -5
  49. package/dist/assets/flowDiagram-NV44I4VS-CitCGiJE-2Yn6xqge.js +162 -0
  50. package/dist/assets/{flowDiagram-NV44I4VS-KDzE7AT1.js → flowDiagram-NV44I4VS-DNfZjFHv.js} +1 -1
  51. package/dist/assets/{ganttDiagram-JELNMOA3-Ce3vKfsr.js → ganttDiagram-JELNMOA3-CI7qwp_G.js} +1 -1
  52. package/dist/assets/{ganttDiagram-JELNMOA3-CqVYbgbk-Dm-Q7o3L.js → ganttDiagram-JELNMOA3-DAaUYzNs-CqERSUiR.js} +3 -3
  53. package/dist/assets/{gitGraphDiagram-NY62KEGX-DDQ3wMsb.js → gitGraphDiagram-NY62KEGX-CTRy4vBb.js} +1 -1
  54. package/dist/assets/gitGraphDiagram-NY62KEGX-lj732X3H-CLhZmLfE.js +65 -0
  55. package/dist/assets/{graph-rt_wscbL-BYOC6Zos.js → graph-Bg_3T7Ud-8p9G4Jrq.js} +1 -1
  56. package/dist/assets/{graph-CIQI-Qnx.js → graph-C_DQAJXv.js} +1 -1
  57. package/dist/assets/index-BA4_7VkX.css +1 -0
  58. package/dist/assets/index-BzhKcNOt.js +2548 -0
  59. package/dist/assets/infoDiagram-WHAUD3N6-BbjOpAi3-DFq7Zumb.js +2 -0
  60. package/dist/assets/{infoDiagram-WHAUD3N6-CKi2MdjK.js → infoDiagram-WHAUD3N6-BjgZuatx.js} +1 -1
  61. package/dist/assets/{journeyDiagram-XKPGCS4Q-BzZgPZwu-FS4BVd7N.js → journeyDiagram-XKPGCS4Q-Cx34P8cj-Cuc55qMS.js} +4 -4
  62. package/dist/assets/{journeyDiagram-XKPGCS4Q-C8gYN3B8.js → journeyDiagram-XKPGCS4Q-JTQBV6RS.js} +1 -1
  63. package/dist/assets/kanban-definition-3W4ZIXB7-BP3ykzKL-BccB0ADl.js +89 -0
  64. package/dist/assets/{kanban-definition-3W4ZIXB7-CJBvuSy_.js → kanban-definition-3W4ZIXB7-CB7Cc0I4.js} +1 -1
  65. package/dist/assets/{layout-BoDR3kQT.js → layout-BDWTKgn6.js} +1 -1
  66. package/dist/assets/{layout-CX9neEHw-DZXKxUst.js → layout-Bft_7Aja-CYwoLCqB.js} +1 -1
  67. package/dist/assets/{linear-CkUVga7d-DcwQdvDv.js → linear-BDIyMYXP-Va3gUrsu.js} +1 -1
  68. package/dist/assets/{min-USsdh-HW.js → min-CzDI_uFs.js} +1 -1
  69. package/dist/assets/min-g4o2CnuX-D41MdeNm.js +1 -0
  70. package/dist/assets/{mindmap-definition-VGOIOE7T-CahlRCoo.js → mindmap-definition-VGOIOE7T-BFemN0Et.js} +1 -1
  71. package/dist/assets/mindmap-definition-VGOIOE7T-CteUNe1z-BgC77XEX.js +68 -0
  72. package/dist/assets/{pieDiagram-ADFJNKIX-B3ej6Rof.js → pieDiagram-ADFJNKIX-2fKAK3CV.js} +1 -1
  73. package/dist/assets/pieDiagram-ADFJNKIX-COS6mtim-2rnhimKu.js +30 -0
  74. package/dist/assets/{quadrantDiagram-AYHSOK5B-Di2kSbDD.js → quadrantDiagram-AYHSOK5B-Del1ofYi.js} +1 -1
  75. package/dist/assets/quadrantDiagram-AYHSOK5B-DmRa7VCS-D5jPyfOD.js +7 -0
  76. package/dist/assets/{requirementDiagram-UZGBJVZJ-MnXD59Yw-DoLLmzEr.js → requirementDiagram-UZGBJVZJ-CcQIz-20-DYIFGLWB.js} +7 -7
  77. package/dist/assets/{requirementDiagram-UZGBJVZJ-BIKMHzOU.js → requirementDiagram-UZGBJVZJ-aYICY3Ph.js} +1 -1
  78. package/dist/assets/{sankeyDiagram-TZEHDZUN-B45aWneB.js → sankeyDiagram-TZEHDZUN-CSxXWX7b.js} +1 -1
  79. package/dist/assets/{sankeyDiagram-TZEHDZUN-Dfyu7oJ6-upd_w6uL.js → sankeyDiagram-TZEHDZUN-CpcshR0Z-Ds6_Y4XZ.js} +8 -8
  80. package/dist/assets/sequenceDiagram-WL72ISMW-B1iDbV8x-Ba6xj9am.js +145 -0
  81. package/dist/assets/{sequenceDiagram-WL72ISMW-0WGvejjk.js → sequenceDiagram-WL72ISMW-_zLrGWf3.js} +1 -1
  82. package/dist/assets/{stateDiagram-FKZM4ZOC-DYV-na53-BrTgUi_v.js → stateDiagram-FKZM4ZOC-DIutB6RS-BM8RqJKW.js} +1 -1
  83. package/dist/assets/{stateDiagram-FKZM4ZOC-CyN90BQP.js → stateDiagram-FKZM4ZOC-DOd4P3H-.js} +1 -1
  84. package/dist/assets/stateDiagram-v2-4FDKWEC3-BKEaZomO-8zJq3ge5.js +1 -0
  85. package/dist/assets/stateDiagram-v2-4FDKWEC3-nRAFnllC.js +1 -0
  86. package/dist/assets/{timeline-definition-IT6M3QCI-B_SrPNXx.js → timeline-definition-IT6M3QCI-BKxuM11p.js} +1 -1
  87. package/dist/assets/timeline-definition-IT6M3QCI-D1yY4TSO-DoVTwDMg.js +61 -0
  88. package/dist/assets/{treemap-KMMF4GRG-Bj5u1csA.js → treemap-KMMF4GRG-ByJ02xk5.js} +1 -1
  89. package/dist/assets/{treemap-KMMF4GRG-l6HrdCLC-BpLaQV_H.js → treemap-KMMF4GRG-KtkxYt13-CZA1d7fY.js} +59 -59
  90. package/dist/assets/{xychartDiagram-PRI3JC2R-Ca3wGEm0.js → xychartDiagram-PRI3JC2R-CGA3Bi-e.js} +1 -1
  91. package/dist/assets/{xychartDiagram-PRI3JC2R-CkfCv2o_-BblxmbGy.js → xychartDiagram-PRI3JC2R-a_g9ptTp-BX4uGx-D.js} +3 -3
  92. package/dist/index.html +2 -2
  93. package/package.json +8 -15
  94. package/dist/assets/_baseUniq-KSDS6tgF-vSUSx1j2.js +0 -1
  95. package/dist/assets/arc-C-X5Xt_b-DxNTmc8E.js +0 -1
  96. package/dist/assets/architectureDiagram-VXUJARFQ-Bal8NTn4-C3CDAmmj.js +0 -36
  97. package/dist/assets/blockDiagram-VD42YOAC-B2gTo5wW-Chk-bWEZ.js +0 -122
  98. package/dist/assets/c4Diagram-YG6GDRKO-dIf_vNCY-B78U9OXb.js +0 -10
  99. package/dist/assets/channel-CXjddKEr.js +0 -1
  100. package/dist/assets/channel-klR7o7JB-D3KnrQ1u.js +0 -1
  101. package/dist/assets/chunk-4BX2VUAB-BQgzc1Sm-3MUJBN6J.js +0 -1
  102. package/dist/assets/chunk-DI55MBZ5-BwHLqSW9-Dg6tgfWJ.js +0 -220
  103. package/dist/assets/chunk-QN33PNHL-DHNejhbC-DbJMzG-e.js +0 -1
  104. package/dist/assets/classDiagram-2ON5EDUG-Cf3QVtDa.js +0 -1
  105. package/dist/assets/classDiagram-2ON5EDUG-D7bjndmT-0h2otGW6.js +0 -1
  106. package/dist/assets/classDiagram-v2-WZHVMYZB-Cf3QVtDa.js +0 -1
  107. package/dist/assets/classDiagram-v2-WZHVMYZB-D7bjndmT-0h2otGW6.js +0 -1
  108. package/dist/assets/clone-7srXemyd-DGxkCAtg.js +0 -1
  109. package/dist/assets/clone-DZrMJ9hz.js +0 -1
  110. package/dist/assets/code-block-37QAKDTI-MRm4xHKr-DLRpbM4W.js +0 -2
  111. package/dist/assets/dagre-6UL2VRFP-BqaZre9N-vdYA4a1q.js +0 -4
  112. package/dist/assets/diagram-PSM6KHXK-s2xYLlND-B6BOy07D.js +0 -24
  113. package/dist/assets/diagram-QEK2KX5R-D700jvoY-tTlqymfs.js +0 -43
  114. package/dist/assets/diagram-S2PKOQOG-BkgBSa1Q-59esupTS.js +0 -24
  115. package/dist/assets/flowDiagram-NV44I4VS-Dsrv00Gy-Cz-kjEu8.js +0 -162
  116. package/dist/assets/gitGraphDiagram-NY62KEGX-DOanbk62-D2EAn-OM.js +0 -65
  117. package/dist/assets/index-BXRJOAs4.js +0 -2540
  118. package/dist/assets/index-C5i0a-mH.css +0 -1
  119. package/dist/assets/infoDiagram-WHAUD3N6-Fq8ToFQ6-BmtVQ1WU.js +0 -2
  120. package/dist/assets/kanban-definition-3W4ZIXB7-CrmrjRAg-BJFHq-Xg.js +0 -89
  121. package/dist/assets/min-Ar5ebLd--DYc60i1a.js +0 -1
  122. package/dist/assets/mindmap-definition-VGOIOE7T-DeGZNL21-hbAsMota.js +0 -68
  123. package/dist/assets/pieDiagram-ADFJNKIX-C_V2NX6O-BNls6JWQ.js +0 -30
  124. package/dist/assets/quadrantDiagram-AYHSOK5B-B8fSnYQi-BEGj5HDN.js +0 -7
  125. package/dist/assets/sequenceDiagram-WL72ISMW-D2pgAoWi-CIx9uPOq.js +0 -145
  126. package/dist/assets/stateDiagram-v2-4FDKWEC3-Kp4sxr9o--i7eh5f-.js +0 -1
  127. package/dist/assets/stateDiagram-v2-4FDKWEC3-yJXh1tES.js +0 -1
  128. package/dist/assets/timeline-definition-IT6M3QCI-621ePKJ0-i5oeWE__.js +0 -61
  129. /package/dist/assets/{ordinal-DfAQgscy-Pc8f3NoK.js → ordinal-B6-f3MAq-Pc8f3NoK.js} +0 -0
@@ -0,0 +1,122 @@
1
+ import{l as le}from"./chunk-FMBD7UC4-DhXvRHU3-Ck_6Dma3.js";import{H as g,aC as rt,a5 as I,ab as ce,a as m,au as de,aw as he,b as B,bn as ge,b8 as ue,bf as ye,bc as pe,bo as H,bp as Mt,k as be,an as Q,ah as xe,bq as fe,br as pt,ae as bt,bs as we}from"./index-BzhKcNOt.js";import{a as me}from"./clone-DqT6If4_-aVfgI0F6.js";import{X as Le}from"./graph-Bg_3T7Ud-8p9G4Jrq.js";import{t as Se}from"./channel-mhjF1lKa-DRGKdmbU.js";import"./_baseUniq-C4bkXOdh-BJ3-SRjw.js";var xt=(function(){var e=g(function(v,c,p,w){for(p=p||{},w=v.length;w--;p[v[w]]=c);return p},"o"),t=[1,15],a=[1,7],i=[1,13],o=[1,14],r=[1,19],s=[1,16],n=[1,17],l=[1,18],u=[8,30],h=[8,10,21,28,29,30,31,39,43,46],b=[1,23],f=[1,24],x=[8,10,15,16,21,28,29,30,31,39,43,46],L=[8,10,15,16,21,27,28,29,30,31,39,43,46],S=[1,49],k={trace:g(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:g(function(v,c,p,w,E,d,_){var y=d.length-1;switch(E){case 4:w.getLogger().debug("Rule: separator (NL) ");break;case 5:w.getLogger().debug("Rule: separator (Space) ");break;case 6:w.getLogger().debug("Rule: separator (EOF) ");break;case 7:w.getLogger().debug("Rule: hierarchy: ",d[y-1]),w.setHierarchy(d[y-1]);break;case 8:w.getLogger().debug("Stop NL ");break;case 9:w.getLogger().debug("Stop EOF ");break;case 10:w.getLogger().debug("Stop NL2 ");break;case 11:w.getLogger().debug("Stop EOF2 ");break;case 12:w.getLogger().debug("Rule: statement: ",d[y]),typeof d[y].length=="number"?this.$=d[y]:this.$=[d[y]];break;case 13:w.getLogger().debug("Rule: statement #2: ",d[y-1]),this.$=[d[y-1]].concat(d[y]);break;case 14:w.getLogger().debug("Rule: link: ",d[y],v),this.$={edgeTypeStr:d[y],label:""};break;case 15:w.getLogger().debug("Rule: LABEL link: ",d[y-3],d[y-1],d[y]),this.$={edgeTypeStr:d[y],label:d[y-1]};break;case 18:const A=parseInt(d[y]),O=w.generateId();this.$={id:O,type:"space",label:"",width:A,children:[]};break;case 23:w.getLogger().debug("Rule: (nodeStatement link node) ",d[y-2],d[y-1],d[y]," typestr: ",d[y-1].edgeTypeStr);const q=w.edgeStrToEdgeData(d[y-1].edgeTypeStr);this.$=[{id:d[y-2].id,label:d[y-2].label,type:d[y-2].type,directions:d[y-2].directions},{id:d[y-2].id+"-"+d[y].id,start:d[y-2].id,end:d[y].id,label:d[y-1].label,type:"edge",directions:d[y].directions,arrowTypeEnd:q,arrowTypeStart:"arrow_open"},{id:d[y].id,label:d[y].label,type:w.typeStr2Type(d[y].typeStr),directions:d[y].directions}];break;case 24:w.getLogger().debug("Rule: nodeStatement (abc88 node size) ",d[y-1],d[y]),this.$={id:d[y-1].id,label:d[y-1].label,type:w.typeStr2Type(d[y-1].typeStr),directions:d[y-1].directions,widthInColumns:parseInt(d[y],10)};break;case 25:w.getLogger().debug("Rule: nodeStatement (node) ",d[y]),this.$={id:d[y].id,label:d[y].label,type:w.typeStr2Type(d[y].typeStr),directions:d[y].directions,widthInColumns:1};break;case 26:w.getLogger().debug("APA123",this?this:"na"),w.getLogger().debug("COLUMNS: ",d[y]),this.$={type:"column-setting",columns:d[y]==="auto"?-1:parseInt(d[y])};break;case 27:w.getLogger().debug("Rule: id-block statement : ",d[y-2],d[y-1]),w.generateId(),this.$={...d[y-2],type:"composite",children:d[y-1]};break;case 28:w.getLogger().debug("Rule: blockStatement : ",d[y-2],d[y-1],d[y]);const j=w.generateId();this.$={id:j,type:"composite",label:"",children:d[y-1]};break;case 29:w.getLogger().debug("Rule: node (NODE_ID separator): ",d[y]),this.$={id:d[y]};break;case 30:w.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",d[y-1],d[y]),this.$={id:d[y-1],label:d[y].label,typeStr:d[y].typeStr,directions:d[y].directions};break;case 31:w.getLogger().debug("Rule: dirList: ",d[y]),this.$=[d[y]];break;case 32:w.getLogger().debug("Rule: dirList: ",d[y-1],d[y]),this.$=[d[y-1]].concat(d[y]);break;case 33:w.getLogger().debug("Rule: nodeShapeNLabel: ",d[y-2],d[y-1],d[y]),this.$={typeStr:d[y-2]+d[y],label:d[y-1]};break;case 34:w.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",d[y-3],d[y-2]," #3:",d[y-1],d[y]),this.$={typeStr:d[y-3]+d[y],label:d[y-2],directions:d[y-1]};break;case 35:case 36:this.$={type:"classDef",id:d[y-1].trim(),css:d[y].trim()};break;case 37:this.$={type:"applyClass",id:d[y-1].trim(),styleClass:d[y].trim()};break;case 38:this.$={type:"applyStyles",id:d[y-1].trim(),stylesStr:d[y].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:t,11:3,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:o,31:r,39:s,43:n,46:l},{8:[1,20]},e(u,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:t,21:a,28:i,29:o,31:r,39:s,43:n,46:l}),e(h,[2,16],{14:22,15:b,16:f}),e(h,[2,17]),e(h,[2,18]),e(h,[2,19]),e(h,[2,20]),e(h,[2,21]),e(h,[2,22]),e(x,[2,25],{27:[1,25]}),e(h,[2,26]),{19:26,26:12,31:r},{10:t,11:27,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:o,31:r,39:s,43:n,46:l},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(L,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(u,[2,13]),{26:35,31:r},{31:[2,14]},{17:[1,36]},e(x,[2,24]),{10:t,11:37,13:4,14:22,15:b,16:f,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:o,31:r,39:s,43:n,46:l},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(L,[2,30]),{18:[1,43]},{18:[1,44]},e(x,[2,23]),{18:[1,45]},{30:[1,46]},e(h,[2,28]),e(h,[2,35]),e(h,[2,36]),e(h,[2,37]),e(h,[2,38]),{36:[1,47]},{33:48,34:S},{15:[1,50]},e(h,[2,27]),e(L,[2,33]),{38:[1,51]},{33:52,34:S,38:[2,31]},{31:[2,15]},e(L,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:g(function(v,c){if(c.recoverable)this.trace(v);else{var p=new Error(v);throw p.hash=c,p}},"parseError"),parse:g(function(v){var c=this,p=[0],w=[],E=[null],d=[],_=this.table,y="",A=0,O=0,q=2,j=1,ie=d.slice.call(arguments,1),z=Object.create(this.lexer),V={yy:{}};for(var ht in this.yy)Object.prototype.hasOwnProperty.call(this.yy,ht)&&(V.yy[ht]=this.yy[ht]);z.setInput(v,V.yy),V.yy.lexer=z,V.yy.parser=this,typeof z.yylloc>"u"&&(z.yylloc={});var gt=z.yylloc;d.push(gt);var ne=z.options&&z.options.ranges;typeof V.yy.parseError=="function"?this.parseError=V.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function oe(Y){p.length=p.length-2*Y,E.length=E.length-Y,d.length=d.length-Y}g(oe,"popStack");function vt(){var Y;return Y=w.pop()||z.lex()||j,typeof Y!="number"&&(Y instanceof Array&&(w=Y,Y=w.pop()),Y=c.symbols_[Y]||Y),Y}g(vt,"lex");for(var P,J,W,ut,G={},at,Z,Nt,st;;){if(J=p[p.length-1],this.defaultActions[J]?W=this.defaultActions[J]:((P===null||typeof P>"u")&&(P=vt()),W=_[J]&&_[J][P]),typeof W>"u"||!W.length||!W[0]){var yt="";st=[];for(at in _[J])this.terminals_[at]&&at>q&&st.push("'"+this.terminals_[at]+"'");z.showPosition?yt="Parse error on line "+(A+1)+`:
2
+ `+z.showPosition()+`
3
+ Expecting `+st.join(", ")+", got '"+(this.terminals_[P]||P)+"'":yt="Parse error on line "+(A+1)+": Unexpected "+(P==j?"end of input":"'"+(this.terminals_[P]||P)+"'"),this.parseError(yt,{text:z.match,token:this.terminals_[P]||P,line:z.yylineno,loc:gt,expected:st})}if(W[0]instanceof Array&&W.length>1)throw new Error("Parse Error: multiple actions possible at state: "+J+", token: "+P);switch(W[0]){case 1:p.push(P),E.push(z.yytext),d.push(z.yylloc),p.push(W[1]),P=null,O=z.yyleng,y=z.yytext,A=z.yylineno,gt=z.yylloc;break;case 2:if(Z=this.productions_[W[1]][1],G.$=E[E.length-Z],G._$={first_line:d[d.length-(Z||1)].first_line,last_line:d[d.length-1].last_line,first_column:d[d.length-(Z||1)].first_column,last_column:d[d.length-1].last_column},ne&&(G._$.range=[d[d.length-(Z||1)].range[0],d[d.length-1].range[1]]),ut=this.performAction.apply(G,[y,O,A,V.yy,W[1],E,d].concat(ie)),typeof ut<"u")return ut;Z&&(p=p.slice(0,-1*Z*2),E=E.slice(0,-1*Z),d=d.slice(0,-1*Z)),p.push(this.productions_[W[1]][0]),E.push(G.$),d.push(G._$),Nt=_[p[p.length-2]][p[p.length-1]],p.push(Nt);break;case 3:return!0}}return!0},"parse")},$=(function(){var v={EOF:1,parseError:g(function(c,p){if(this.yy.parser)this.yy.parser.parseError(c,p);else throw new Error(c)},"parseError"),setInput:g(function(c,p){return this.yy=p||this.yy||{},this._input=c,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:g(function(){var c=this._input[0];this.yytext+=c,this.yyleng++,this.offset++,this.match+=c,this.matched+=c;var p=c.match(/(?:\r\n?|\n).*/g);return p?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),c},"input"),unput:g(function(c){var p=c.length,w=c.split(/(?:\r\n?|\n)/g);this._input=c+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-p),this.offset-=p;var E=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),w.length-1&&(this.yylineno-=w.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:w?(w.length===E.length?this.yylloc.first_column:0)+E[E.length-w.length].length-w[0].length:this.yylloc.first_column-p},this.options.ranges&&(this.yylloc.range=[d[0],d[0]+this.yyleng-p]),this.yyleng=this.yytext.length,this},"unput"),more:g(function(){return this._more=!0,this},"more"),reject:g(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:g(function(c){this.unput(this.match.slice(c))},"less"),pastInput:g(function(){var c=this.matched.substr(0,this.matched.length-this.match.length);return(c.length>20?"...":"")+c.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:g(function(){var c=this.match;return c.length<20&&(c+=this._input.substr(0,20-c.length)),(c.substr(0,20)+(c.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:g(function(){var c=this.pastInput(),p=new Array(c.length+1).join("-");return c+this.upcomingInput()+`
5
+ `+p+"^"},"showPosition"),test_match:g(function(c,p){var w,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))),E=c[0].match(/(?:\r\n?|\n).*/g),E&&(this.yylineno+=E.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:E?E[E.length-1].length-E[E.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+c[0].length},this.yytext+=c[0],this.match+=c[0],this.matches=c,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(c[0].length),this.matched+=c[0],w=this.performAction.call(this,this.yy,this,p,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),w)return w;if(this._backtrack){for(var _ in d)this[_]=d[_];return!1}return!1},"test_match"),next:g(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var c,p,w,E;this._more||(this.yytext="",this.match="");for(var d=this._currentRules(),_=0;_<d.length;_++)if(w=this._input.match(this.rules[d[_]]),w&&(!p||w[0].length>p[0].length)){if(p=w,E=_,this.options.backtrack_lexer){if(c=this.test_match(w,d[_]),c!==!1)return c;if(this._backtrack){p=!1;continue}else return!1}else if(!this.options.flex)break}return p?(c=this.test_match(p,d[E]),c!==!1?c:!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:g(function(){var c=this.next();return c||this.lex()},"lex"),begin:g(function(c){this.conditionStack.push(c)},"begin"),popState:g(function(){var c=this.conditionStack.length-1;return c>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:g(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:g(function(c){return c=this.conditionStack.length-1-Math.abs(c||0),c>=0?this.conditionStack[c]:"INITIAL"},"topState"),pushState:g(function(c){this.begin(c)},"pushState"),stateStackSize:g(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:g(function(c,p,w,E){switch(w){case 0:return c.getLogger().debug("Found block-beta"),10;case 1:return c.getLogger().debug("Found id-block"),29;case 2:return c.getLogger().debug("Found block"),10;case 3:c.getLogger().debug(".",p.yytext);break;case 4:c.getLogger().debug("_",p.yytext);break;case 5:return 5;case 6:return p.yytext=-1,28;case 7:return p.yytext=p.yytext.replace(/columns\s+/,""),c.getLogger().debug("COLUMNS (LEX)",p.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:c.getLogger().debug("LEX: POPPING STR:",p.yytext),this.popState();break;case 13:return c.getLogger().debug("LEX: STR end:",p.yytext),"STR";case 14:return p.yytext=p.yytext.replace(/space\:/,""),c.getLogger().debug("SPACE NUM (LEX)",p.yytext),21;case 15:return p.yytext="1",c.getLogger().debug("COLUMNS (LEX)",p.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(),c.getLogger().debug("Lex: (("),"NODE_DEND";case 38:return this.popState(),c.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),c.getLogger().debug("Lex: ))"),"NODE_DEND";case 40:return this.popState(),c.getLogger().debug("Lex: (("),"NODE_DEND";case 41:return this.popState(),c.getLogger().debug("Lex: (("),"NODE_DEND";case 42:return this.popState(),c.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),c.getLogger().debug("Lex: -)"),"NODE_DEND";case 44:return this.popState(),c.getLogger().debug("Lex: (("),"NODE_DEND";case 45:return this.popState(),c.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),c.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),c.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:return this.popState(),c.getLogger().debug("Lex: /]"),"NODE_DEND";case 49:return this.popState(),c.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),c.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),c.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),c.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),c.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return c.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return c.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return c.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:return c.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return c.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 59:return c.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 60:return c.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 61:return c.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 62:return c.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return c.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 64:return c.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 c.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),c.getLogger().debug("LEX ARR START"),37;case 74:return c.getLogger().debug("Lex: NODE_ID",p.yytext),31;case 75:return c.getLogger().debug("Lex: EOF",p.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:c.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:c.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return c.getLogger().debug("LEX: NODE_DESCR:",p.yytext),"NODE_DESCR";case 83:c.getLogger().debug("LEX POPPING"),this.popState();break;case 84:c.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (right): dir:",p.yytext),"DIR";case 86:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (left):",p.yytext),"DIR";case 87:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (x):",p.yytext),"DIR";case 88:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (y):",p.yytext),"DIR";case 89:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (up):",p.yytext),"DIR";case 90:return p.yytext=p.yytext.replace(/^,\s*/,""),c.getLogger().debug("Lex (down):",p.yytext),"DIR";case 91:return p.yytext="]>",c.getLogger().debug("Lex (ARROW_DIR end):",p.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return c.getLogger().debug("Lex: LINK","#"+p.yytext+"#"),15;case 93:return c.getLogger().debug("Lex: LINK",p.yytext),15;case 94:return c.getLogger().debug("Lex: LINK",p.yytext),15;case 95:return c.getLogger().debug("Lex: LINK",p.yytext),15;case 96:return c.getLogger().debug("Lex: START_LINK",p.yytext),this.pushState("LLABEL"),16;case 97:return c.getLogger().debug("Lex: START_LINK",p.yytext),this.pushState("LLABEL"),16;case 98:return c.getLogger().debug("Lex: START_LINK",p.yytext),this.pushState("LLABEL"),16;case 99:this.pushState("md_string");break;case 100:return c.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),c.getLogger().debug("Lex: LINK","#"+p.yytext+"#"),15;case 102:return this.popState(),c.getLogger().debug("Lex: LINK",p.yytext),15;case 103:return this.popState(),c.getLogger().debug("Lex: LINK",p.yytext),15;case 104:return c.getLogger().debug("Lex: COLON",p.yytext),p.yytext=p.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})();k.lexer=$;function D(){this.yy={}}return g(D,"Parser"),D.prototype=k,k.Parser=D,new D})();xt.parser=xt;var ke=xt,U=new Map,St=[],ft=new Map,Tt="color",$t="fill",_e="bgFill",Pt=",",Ee=B(),ot=new Map,De=g(e=>xe.sanitizeText(e,Ee),"sanitizeText"),ve=g(function(e,t=""){let a=ot.get(e);a||(a={id:e,styles:[],textStyles:[]},ot.set(e,a)),t?.split(Pt).forEach(i=>{const o=i.replace(/([^;]*);/,"$1").trim();if(RegExp(Tt).exec(i)){const r=o.replace($t,_e).replace(Tt,$t);a.textStyles.push(r)}a.styles.push(o)})},"addStyleClass"),Ne=g(function(e,t=""){const a=U.get(e);t!=null&&(a.styles=t.split(Pt))},"addStyle2Node"),Te=g(function(e,t){e.split(",").forEach(function(a){let i=U.get(a);if(i===void 0){const o=a.trim();i={id:o,type:"na",children:[]},U.set(o,i)}i.classes||(i.classes=[]),i.classes.push(t)})},"setCssClass"),Yt=g((e,t)=>{const a=e.flat(),i=[],o=a.find(r=>r?.type==="column-setting")?.columns??-1;for(const r of a){if(typeof o=="number"&&o>0&&r.type!=="column-setting"&&typeof r.widthInColumns=="number"&&r.widthInColumns>o&&m.warn(`Block ${r.id} width ${r.widthInColumns} exceeds configured column width ${o}`),r.label&&(r.label=De(r.label)),r.type==="classDef"){ve(r.id,r.css);continue}if(r.type==="applyClass"){Te(r.id,r?.styleClass??"");continue}if(r.type==="applyStyles"){r?.stylesStr&&Ne(r.id,r?.stylesStr);continue}if(r.type==="column-setting")t.columns=r.columns??-1;else if(r.type==="edge"){const s=(ft.get(r.id)??0)+1;ft.set(r.id,s),r.id=s+"-"+r.id,St.push(r)}else{r.label||(r.type==="composite"?r.label="":r.label=r.id);const s=U.get(r.id);if(s===void 0?U.set(r.id,r):(r.type!=="na"&&(s.type=r.type),r.label!==r.id&&(s.label=r.label)),r.children&&Yt(r.children,r),r.type==="space"){const n=r.width??1;for(let l=0;l<n;l++){const u=me(r);u.id=u.id+"-"+l,U.set(u.id,u),i.push(u)}}else s===void 0&&i.push(r)}}t.children=i},"populateBlockDatabase"),kt=[],et={id:"root",type:"composite",children:[],columns:-1},$e=g(()=>{m.debug("Clear called"),de(),et={id:"root",type:"composite",children:[],columns:-1},U=new Map([["root",et]]),kt=[],ot=new Map,St=[],ft=new Map},"clear");function Xt(e){switch(m.debug("typeStr2Type",e),e){case"[]":return"square";case"()":return m.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"}}g(Xt,"typeStr2Type");function Wt(e){return m.debug("typeStr2Type",e),e==="=="?"thick":"normal"}g(Wt,"edgeTypeStr2Type");function Kt(e){switch(e.replace(/^[\s-]+|[\s-]+$/g,"")){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}g(Kt,"edgeStrToEdgeData");var Ct=0,Ce=g(()=>(Ct++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Ct),"generateId"),Ie=g(e=>{et.children=e,Yt(e,et),kt=et.children},"setHierarchy"),Be=g(e=>{const t=U.get(e);return t?t.columns?t.columns:t.children?t.children.length:-1:-1},"getColumns"),Oe=g(()=>[...U.values()],"getBlocksFlat"),ze=g(()=>kt||[],"getBlocks"),Re=g(()=>St,"getEdges"),Ae=g(e=>U.get(e),"getBlock"),Me=g(e=>{U.set(e.id,e)},"setBlock"),Pe=g(()=>m,"getLogger"),Ye=g(function(){return ot},"getClasses"),Xe={getConfig:g(()=>rt().block,"getConfig"),typeStr2Type:Xt,edgeTypeStr2Type:Wt,edgeStrToEdgeData:Kt,getLogger:Pe,getBlocksFlat:Oe,getBlocks:ze,getEdges:Re,setHierarchy:Ie,getBlock:Ae,setBlock:Me,getColumns:Be,getClasses:Ye,clear:$e,generateId:Ce},We=Xe,it=g((e,t)=>{const a=Se,i=a(e,"r"),o=a(e,"g"),r=a(e,"b");return he(i,o,r,t)},"fade"),Ke=g(e=>`.label {
7
+ font-family: ${e.fontFamily};
8
+ color: ${e.nodeTextColor||e.textColor};
9
+ }
10
+ .cluster-label text {
11
+ fill: ${e.titleColor};
12
+ }
13
+ .cluster-label span,p {
14
+ color: ${e.titleColor};
15
+ }
16
+
17
+
18
+
19
+ .label text,span,p {
20
+ fill: ${e.nodeTextColor||e.textColor};
21
+ color: ${e.nodeTextColor||e.textColor};
22
+ }
23
+
24
+ .node rect,
25
+ .node circle,
26
+ .node ellipse,
27
+ .node polygon,
28
+ .node path {
29
+ fill: ${e.mainBkg};
30
+ stroke: ${e.nodeBorder};
31
+ stroke-width: 1px;
32
+ }
33
+ .flowchart-label text {
34
+ text-anchor: middle;
35
+ }
36
+ // .flowchart-label .text-outer-tspan {
37
+ // text-anchor: middle;
38
+ // }
39
+ // .flowchart-label .text-inner-tspan {
40
+ // text-anchor: start;
41
+ // }
42
+
43
+ .node .label {
44
+ text-align: center;
45
+ }
46
+ .node.clickable {
47
+ cursor: pointer;
48
+ }
49
+
50
+ .arrowheadPath {
51
+ fill: ${e.arrowheadColor};
52
+ }
53
+
54
+ .edgePath .path {
55
+ stroke: ${e.lineColor};
56
+ stroke-width: 2.0px;
57
+ }
58
+
59
+ .flowchart-link {
60
+ stroke: ${e.lineColor};
61
+ fill: none;
62
+ }
63
+
64
+ .edgeLabel {
65
+ background-color: ${e.edgeLabelBackground};
66
+ rect {
67
+ opacity: 0.5;
68
+ background-color: ${e.edgeLabelBackground};
69
+ fill: ${e.edgeLabelBackground};
70
+ }
71
+ text-align: center;
72
+ }
73
+
74
+ /* For html labels only */
75
+ .labelBkg {
76
+ background-color: ${it(e.edgeLabelBackground,.5)};
77
+ // background-color:
78
+ }
79
+
80
+ .node .cluster {
81
+ // fill: ${it(e.mainBkg,.5)};
82
+ fill: ${it(e.clusterBkg,.5)};
83
+ stroke: ${it(e.clusterBorder,.2)};
84
+ box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
85
+ stroke-width: 1px;
86
+ }
87
+
88
+ .cluster text {
89
+ fill: ${e.titleColor};
90
+ }
91
+
92
+ .cluster span,p {
93
+ color: ${e.titleColor};
94
+ }
95
+ /* .cluster div {
96
+ color: ${e.titleColor};
97
+ } */
98
+
99
+ div.mermaidTooltip {
100
+ position: absolute;
101
+ text-align: center;
102
+ max-width: 200px;
103
+ padding: 2px;
104
+ font-family: ${e.fontFamily};
105
+ font-size: 12px;
106
+ background: ${e.tertiaryColor};
107
+ border: 1px solid ${e.border2};
108
+ border-radius: 2px;
109
+ pointer-events: none;
110
+ z-index: 100;
111
+ }
112
+
113
+ .flowchartTitleText {
114
+ text-anchor: middle;
115
+ font-size: 18px;
116
+ fill: ${e.textColor};
117
+ }
118
+ ${le()}
119
+ `,"getStyles"),Ue=Ke,Fe=g((e,t,a,i)=>{t.forEach(o=>{er[o](e,a,i)})},"insertMarkers"),je=g((e,t,a)=>{m.trace("Making markers for ",a),e.append("defs").append("marker").attr("id",a+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),e.append("defs").append("marker").attr("id",a+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},"extension"),He=g((e,t,a)=>{e.append("defs").append("marker").attr("id",a+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",a+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),Ze=g((e,t,a)=>{e.append("defs").append("marker").attr("id",a+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",a+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),qe=g((e,t,a)=>{e.append("defs").append("marker").attr("id",a+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),e.append("defs").append("marker").attr("id",a+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).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")},"dependency"),Ve=g((e,t,a)=>{e.append("defs").append("marker").attr("id",a+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),e.append("defs").append("marker").attr("id",a+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},"lollipop"),Je=g((e,t,a)=>{e.append("marker").attr("id",a+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",6).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").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",a+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"point"),Ge=g((e,t,a)=>{e.append("marker").attr("id",a+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),e.append("marker").attr("id",a+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"circle"),Qe=g((e,t,a)=>{e.append("marker").attr("id",a+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),e.append("marker").attr("id",a+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},"cross"),tr=g((e,t,a)=>{e.append("defs").append("marker").attr("id",a+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),er={extension:je,composition:He,aggregation:Ze,dependency:qe,lollipop:Ve,point:Je,circle:Ge,cross:Qe,barb:tr},rr=Fe,C=B()?.block?.padding??8;function Ut(e,t){if(e===0||!Number.isInteger(e))throw new Error("Columns must be an integer !== 0.");if(t<0||!Number.isInteger(t))throw new Error("Position must be a non-negative integer."+t);if(e<0)return{px:t,py:0};if(e===1)return{px:0,py:t};const a=t%e,i=Math.floor(t/e);return{px:a,py:i}}g(Ut,"calculateBlockPosition");var ar=g(e=>{let t=0,a=0;for(const i of e.children){const{width:o,height:r,x:s,y:n}=i.size??{width:0,height:0,x:0,y:0};m.debug("getMaxChildSize abc95 child:",i.id,"width:",o,"height:",r,"x:",s,"y:",n,i.type),i.type!=="space"&&(o>t&&(t=o/(e.widthInColumns??1)),r>a&&(a=r))}return{width:t,height:a}},"getMaxChildSize");function lt(e,t,a=0,i=0){m.debug("setBlockSizes abc95 (start)",e.id,e?.size?.x,"block width =",e?.size,"siblingWidth",a),e?.size?.width||(e.size={width:a,height:i,x:0,y:0});let o=0,r=0;if(e.children?.length>0){for(const x of e.children)lt(x,t);const s=ar(e);o=s.width,r=s.height,m.debug("setBlockSizes abc95 maxWidth of",e.id,":s children is ",o,r);for(const x of e.children)x.size&&(m.debug(`abc95 Setting size of children of ${e.id} id=${x.id} ${o} ${r} ${JSON.stringify(x.size)}`),x.size.width=o*(x.widthInColumns??1)+C*((x.widthInColumns??1)-1),x.size.height=r,x.size.x=0,x.size.y=0,m.debug(`abc95 updating size of ${e.id} children child:${x.id} maxWidth:${o} maxHeight:${r}`));for(const x of e.children)lt(x,t,o,r);const n=e.columns??-1;let l=0;for(const x of e.children)l+=x.widthInColumns??1;let u=e.children.length;n>0&&n<l&&(u=n);const h=Math.ceil(l/u);let b=u*(o+C)+C,f=h*(r+C)+C;if(b<a){m.debug(`Detected to small sibling: abc95 ${e.id} siblingWidth ${a} siblingHeight ${i} width ${b}`),b=a,f=i;const x=(a-u*C-C)/u,L=(i-h*C-C)/h;m.debug("Size indata abc88",e.id,"childWidth",x,"maxWidth",o),m.debug("Size indata abc88",e.id,"childHeight",L,"maxHeight",r),m.debug("Size indata abc88 xSize",u,"padding",C);for(const S of e.children)S.size&&(S.size.width=x,S.size.height=L,S.size.x=0,S.size.y=0)}if(m.debug(`abc95 (finale calc) ${e.id} xSize ${u} ySize ${h} columns ${n}${e.children.length} width=${Math.max(b,e.size?.width||0)}`),b<(e?.size?.width||0)){b=e?.size?.width||0;const x=n>0?Math.min(e.children.length,n):e.children.length;if(x>0){const L=(b-x*C-C)/x;m.debug("abc95 (growing to fit) width",e.id,b,e.size?.width,L);for(const S of e.children)S.size&&(S.size.width=L)}}e.size={width:b,height:f,x:0,y:0}}m.debug("setBlockSizes abc94 (done)",e.id,e?.size?.x,e?.size?.width,e?.size?.y,e?.size?.height)}g(lt,"setBlockSizes");function _t(e,t){m.debug(`abc85 layout blocks (=>layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`);const a=e.columns??-1;if(m.debug("layoutBlocks columns abc95",e.id,"=>",a,e),e.children&&e.children.length>0){const i=e?.children[0]?.size?.width??0,o=e.children.length*i+(e.children.length-1)*C;m.debug("widthOfChildren 88",o,"posX");let r=0;m.debug("abc91 block?.size?.x",e.id,e?.size?.x);let s=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-C,n=0;for(const l of e.children){const u=e;if(!l.size)continue;const{width:h,height:b}=l.size,{px:f,py:x}=Ut(a,r);if(x!=n&&(n=x,s=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-C,m.debug("New row in layout for block",e.id," and child ",l.id,n)),m.debug(`abc89 layout blocks (child) id: ${l.id} Pos: ${r} (px, py) ${f},${x} (${u?.size?.x},${u?.size?.y}) parent: ${u.id} width: ${h}${C}`),u.size){const S=h/2;l.size.x=s+C+S,m.debug(`abc91 layout blocks (calc) px, pyid:${l.id} startingPos=X${s} new startingPosX${l.size.x} ${S} padding=${C} width=${h} halfWidth=${S} => x:${l.size.x} y:${l.size.y} ${l.widthInColumns} (width * (child?.w || 1)) / 2 ${h*(l?.widthInColumns??1)/2}`),s=l.size.x+S,l.size.y=u.size.y-u.size.height/2+x*(b+C)+b/2+C,m.debug(`abc88 layout blocks (calc) px, pyid:${l.id}startingPosX${s}${C}${S}=>x:${l.size.x}y:${l.size.y}${l.widthInColumns}(width * (child?.w || 1)) / 2${h*(l?.widthInColumns??1)/2}`)}l.children&&_t(l);let L=l?.widthInColumns??1;a>0&&(L=Math.min(L,a-r%a)),r+=L,m.debug("abc88 columnsPos",l,r)}}m.debug(`layout blocks (<==layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`)}g(_t,"layoutBlocks");function Et(e,{minX:t,minY:a,maxX:i,maxY:o}={minX:0,minY:0,maxX:0,maxY:0}){if(e.size&&e.id!=="root"){const{x:r,y:s,width:n,height:l}=e.size;r-n/2<t&&(t=r-n/2),s-l/2<a&&(a=s-l/2),r+n/2>i&&(i=r+n/2),s+l/2>o&&(o=s+l/2)}if(e.children)for(const r of e.children)({minX:t,minY:a,maxX:i,maxY:o}=Et(r,{minX:t,minY:a,maxX:i,maxY:o}));return{minX:t,minY:a,maxX:i,maxY:o}}g(Et,"findBounds");function Ft(e){const t=e.getBlock("root");if(!t)return;lt(t,e,0,0),_t(t),m.debug("getBlocks",JSON.stringify(t,null,2));const{minX:a,minY:i,maxX:o,maxY:r}=Et(t),s=r-i,n=o-a;return{x:a,y:i,width:n,height:s}}g(Ft,"layout");function wt(e,t){t&&e.attr("style",t)}g(wt,"applyStyle");function jt(e,t){const a=I(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),i=a.append("xhtml:div"),o=e.label,r=e.isNode?"nodeLabel":"edgeLabel",s=i.append("span");return s.html(bt(o,t)),wt(s,e.labelStyle),s.attr("class",r),wt(i,e.labelStyle),i.style("display","inline-block"),i.style("white-space","nowrap"),i.attr("xmlns","http://www.w3.org/1999/xhtml"),a.node()}g(jt,"addHtmlLabel");var sr=g(async(e,t,a,i)=>{let o=e||"";typeof o=="object"&&(o=o[0]);const r=B();if(H(r.flowchart.htmlLabels)){o=o.replace(/\\n|\n/g,"<br />"),m.debug("vertexText"+o);const s=await fe(pt(o)),n={isNode:i,label:s,labelStyle:t.replace("fill:","color:")};return jt(n,r)}else{const s=document.createElementNS("http://www.w3.org/2000/svg","text");s.setAttribute("style",t.replace("color:","fill:"));let n=[];typeof o=="string"?n=o.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(o)?n=o:n=[];for(const l of n){const u=document.createElementNS("http://www.w3.org/2000/svg","tspan");u.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),u.setAttribute("dy","1em"),u.setAttribute("x","0"),a?u.setAttribute("class","title-row"):u.setAttribute("class","row"),u.textContent=l.trim(),s.appendChild(u)}return s}},"createLabel"),K=sr,ir=g((e,t,a,i,o)=>{t.arrowTypeStart&&It(e,"start",t.arrowTypeStart,a,i,o),t.arrowTypeEnd&&It(e,"end",t.arrowTypeEnd,a,i,o)},"addEdgeMarkers"),nr={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},It=g((e,t,a,i,o,r)=>{const s=nr[a];if(!s){m.warn(`Unknown arrow type: ${a}`);return}const n=t==="start"?"Start":"End";e.attr(`marker-${t}`,`url(${i}#${o}_${r}-${s}${n})`)},"addEdgeMarker"),mt={},M={},or=g(async(e,t)=>{const a=B(),i=H(a.flowchart.htmlLabels),o=t.labelType==="markdown"?Mt(e,t.label,{style:t.labelStyle,useHtmlLabels:i,addSvgBackground:!0},a):await K(t.label,t.labelStyle),r=e.insert("g").attr("class","edgeLabel"),s=r.insert("g").attr("class","label");s.node().appendChild(o);let n=o.getBBox();if(i){const u=o.children[0],h=I(o);n=u.getBoundingClientRect(),h.attr("width",n.width),h.attr("height",n.height)}s.attr("transform","translate("+-n.width/2+", "+-n.height/2+")"),mt[t.id]=r,t.width=n.width,t.height=n.height;let l;if(t.startLabelLeft){const u=await K(t.startLabelLeft,t.labelStyle),h=e.insert("g").attr("class","edgeTerminals"),b=h.insert("g").attr("class","inner");l=b.node().appendChild(u);const f=u.getBBox();b.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),M[t.id]||(M[t.id]={}),M[t.id].startLeft=h,tt(l,t.startLabelLeft)}if(t.startLabelRight){const u=await K(t.startLabelRight,t.labelStyle),h=e.insert("g").attr("class","edgeTerminals"),b=h.insert("g").attr("class","inner");l=h.node().appendChild(u),b.node().appendChild(u);const f=u.getBBox();b.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),M[t.id]||(M[t.id]={}),M[t.id].startRight=h,tt(l,t.startLabelRight)}if(t.endLabelLeft){const u=await K(t.endLabelLeft,t.labelStyle),h=e.insert("g").attr("class","edgeTerminals"),b=h.insert("g").attr("class","inner");l=b.node().appendChild(u);const f=u.getBBox();b.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),h.node().appendChild(u),M[t.id]||(M[t.id]={}),M[t.id].endLeft=h,tt(l,t.endLabelLeft)}if(t.endLabelRight){const u=await K(t.endLabelRight,t.labelStyle),h=e.insert("g").attr("class","edgeTerminals"),b=h.insert("g").attr("class","inner");l=b.node().appendChild(u);const f=u.getBBox();b.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),h.node().appendChild(u),M[t.id]||(M[t.id]={}),M[t.id].endRight=h,tt(l,t.endLabelRight)}return o},"insertEdgeLabel");function tt(e,t){B().flowchart.htmlLabels&&e&&(e.style.width=t.length*9+"px",e.style.height="12px")}g(tt,"setTerminalWidth");var lr=g((e,t)=>{m.debug("Moving label abc88 ",e.id,e.label,mt[e.id],t);let a=t.updatedPath?t.updatedPath:t.originalPath;const i=B(),{subGraphTitleTotalMargin:o}=be(i);if(e.label){const r=mt[e.id];let s=e.x,n=e.y;if(a){const l=Q.calcLabelPosition(a);m.debug("Moving label "+e.label+" from (",s,",",n,") to (",l.x,",",l.y,") abc88"),t.updatedPath&&(s=l.x,n=l.y)}r.attr("transform",`translate(${s}, ${n+o/2})`)}if(e.startLabelLeft){const r=M[e.id].startLeft;let s=e.x,n=e.y;if(a){const l=Q.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_left",a);s=l.x,n=l.y}r.attr("transform",`translate(${s}, ${n})`)}if(e.startLabelRight){const r=M[e.id].startRight;let s=e.x,n=e.y;if(a){const l=Q.calcTerminalLabelPosition(e.arrowTypeStart?10:0,"start_right",a);s=l.x,n=l.y}r.attr("transform",`translate(${s}, ${n})`)}if(e.endLabelLeft){const r=M[e.id].endLeft;let s=e.x,n=e.y;if(a){const l=Q.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_left",a);s=l.x,n=l.y}r.attr("transform",`translate(${s}, ${n})`)}if(e.endLabelRight){const r=M[e.id].endRight;let s=e.x,n=e.y;if(a){const l=Q.calcTerminalLabelPosition(e.arrowTypeEnd?10:0,"end_right",a);s=l.x,n=l.y}r.attr("transform",`translate(${s}, ${n})`)}},"positionEdgeLabel"),cr=g((e,t)=>{const a=e.x,i=e.y,o=Math.abs(t.x-a),r=Math.abs(t.y-i),s=e.width/2,n=e.height/2;return o>=s||r>=n},"outsideNode"),dr=g((e,t,a)=>{m.debug(`intersection calc abc89:
120
+ outsidePoint: ${JSON.stringify(t)}
121
+ insidePoint : ${JSON.stringify(a)}
122
+ node : x:${e.x} y:${e.y} w:${e.width} h:${e.height}`);const i=e.x,o=e.y,r=Math.abs(i-a.x),s=e.width/2;let n=a.x<t.x?s-r:s+r;const l=e.height/2,u=Math.abs(t.y-a.y),h=Math.abs(t.x-a.x);if(Math.abs(o-t.y)*s>Math.abs(i-t.x)*l){let b=a.y<t.y?t.y-l-o:o-l-t.y;n=h*b/u;const f={x:a.x<t.x?a.x+n:a.x-h+n,y:a.y<t.y?a.y+u-b:a.y-u+b};return n===0&&(f.x=t.x,f.y=t.y),h===0&&(f.x=t.x),u===0&&(f.y=t.y),m.debug(`abc89 topp/bott calc, Q ${u}, q ${b}, R ${h}, r ${n}`,f),f}else{a.x<t.x?n=t.x-s-i:n=i-s-t.x;let b=u*n/h,f=a.x<t.x?a.x+h-n:a.x-h+n,x=a.y<t.y?a.y+b:a.y-b;return m.debug(`sides calc abc89, Q ${u}, q ${b}, R ${h}, r ${n}`,{_x:f,_y:x}),n===0&&(f=t.x,x=t.y),h===0&&(f=t.x),u===0&&(x=t.y),{x:f,y:x}}},"intersection"),Bt=g((e,t)=>{m.debug("abc88 cutPathAtIntersect",e,t);let a=[],i=e[0],o=!1;return e.forEach(r=>{if(!cr(t,r)&&!o){const s=dr(t,i,r);let n=!1;a.forEach(l=>{n=n||l.x===s.x&&l.y===s.y}),a.some(l=>l.x===s.x&&l.y===s.y)||a.push(s),o=!0}else i=r,o||a.push(r)}),a},"cutPathAtIntersect"),hr=g(function(e,t,a,i,o,r,s){let n=a.points;m.debug("abc88 InsertEdge: edge=",a,"e=",t);let l=!1;const u=r.node(t.v);var h=r.node(t.w);h?.intersect&&u?.intersect&&(n=n.slice(1,a.points.length-1),n.unshift(u.intersect(n[0])),n.push(h.intersect(n[n.length-1]))),a.toCluster&&(m.debug("to cluster abc88",i[a.toCluster]),n=Bt(a.points,i[a.toCluster].node),l=!0),a.fromCluster&&(m.debug("from cluster abc88",i[a.fromCluster]),n=Bt(n.reverse(),i[a.fromCluster].node).reverse(),l=!0);const b=n.filter(c=>!Number.isNaN(c.y));let f=ye;a.curve&&(o==="graph"||o==="flowchart")&&(f=a.curve);const{x,y:L}=ge(a),S=ue().x(x).y(L).curve(f);let k;switch(a.thickness){case"normal":k="edge-thickness-normal";break;case"thick":k="edge-thickness-thick";break;case"invisible":k="edge-thickness-thick";break;default:k=""}switch(a.pattern){case"solid":k+=" edge-pattern-solid";break;case"dotted":k+=" edge-pattern-dotted";break;case"dashed":k+=" edge-pattern-dashed";break}const $=e.append("path").attr("d",S(b)).attr("id",a.id).attr("class"," "+k+(a.classes?" "+a.classes:"")).attr("style",a.style);let D="";(B().flowchart.arrowMarkerAbsolute||B().state.arrowMarkerAbsolute)&&(D=pe(!0)),ir($,a,D,s,o);let v={};return l&&(v.updatedPath=n),v.originalPath=a.points,v},"insertEdge"),gr=g(e=>{const t=new Set;for(const a of e)switch(a){case"x":t.add("right"),t.add("left");break;case"y":t.add("up"),t.add("down");break;default:t.add(a);break}return t},"expandAndDeduplicateDirections"),ur=g((e,t,a)=>{const i=gr(e),o=2,r=t.height+2*a.padding,s=r/o,n=t.width+2*s+a.padding,l=a.padding/2;return i.has("right")&&i.has("left")&&i.has("up")&&i.has("down")?[{x:0,y:0},{x:s,y:0},{x:n/2,y:2*l},{x:n-s,y:0},{x:n,y:0},{x:n,y:-r/3},{x:n+2*l,y:-r/2},{x:n,y:-2*r/3},{x:n,y:-r},{x:n-s,y:-r},{x:n/2,y:-r-2*l},{x:s,y:-r},{x:0,y:-r},{x:0,y:-2*r/3},{x:-2*l,y:-r/2},{x:0,y:-r/3}]:i.has("right")&&i.has("left")&&i.has("up")?[{x:s,y:0},{x:n-s,y:0},{x:n,y:-r/2},{x:n-s,y:-r},{x:s,y:-r},{x:0,y:-r/2}]:i.has("right")&&i.has("left")&&i.has("down")?[{x:0,y:0},{x:s,y:-r},{x:n-s,y:-r},{x:n,y:0}]:i.has("right")&&i.has("up")&&i.has("down")?[{x:0,y:0},{x:n,y:-s},{x:n,y:-r+s},{x:0,y:-r}]:i.has("left")&&i.has("up")&&i.has("down")?[{x:n,y:0},{x:0,y:-s},{x:0,y:-r+s},{x:n,y:-r}]:i.has("right")&&i.has("left")?[{x:s,y:0},{x:s,y:-l},{x:n-s,y:-l},{x:n-s,y:0},{x:n,y:-r/2},{x:n-s,y:-r},{x:n-s,y:-r+l},{x:s,y:-r+l},{x:s,y:-r},{x:0,y:-r/2}]:i.has("up")&&i.has("down")?[{x:n/2,y:0},{x:0,y:-l},{x:s,y:-l},{x:s,y:-r+l},{x:0,y:-r+l},{x:n/2,y:-r},{x:n,y:-r+l},{x:n-s,y:-r+l},{x:n-s,y:-l},{x:n,y:-l}]:i.has("right")&&i.has("up")?[{x:0,y:0},{x:n,y:-s},{x:0,y:-r}]:i.has("right")&&i.has("down")?[{x:0,y:0},{x:n,y:0},{x:0,y:-r}]:i.has("left")&&i.has("up")?[{x:n,y:0},{x:0,y:-s},{x:n,y:-r}]:i.has("left")&&i.has("down")?[{x:n,y:0},{x:0,y:0},{x:n,y:-r}]:i.has("right")?[{x:s,y:-l},{x:s,y:-l},{x:n-s,y:-l},{x:n-s,y:0},{x:n,y:-r/2},{x:n-s,y:-r},{x:n-s,y:-r+l},{x:s,y:-r+l},{x:s,y:-r+l}]:i.has("left")?[{x:s,y:0},{x:s,y:-l},{x:n-s,y:-l},{x:n-s,y:-r+l},{x:s,y:-r+l},{x:s,y:-r},{x:0,y:-r/2}]:i.has("up")?[{x:s,y:-l},{x:s,y:-r+l},{x:0,y:-r+l},{x:n/2,y:-r},{x:n,y:-r+l},{x:n-s,y:-r+l},{x:n-s,y:-l}]:i.has("down")?[{x:n/2,y:0},{x:0,y:-l},{x:s,y:-l},{x:s,y:-r+l},{x:n-s,y:-r+l},{x:n-s,y:-l},{x:n,y:-l}]:[{x:0,y:0}]},"getArrowPoints");function Ht(e,t){return e.intersect(t)}g(Ht,"intersectNode");var yr=Ht;function Zt(e,t,a,i){var o=e.x,r=e.y,s=o-i.x,n=r-i.y,l=Math.sqrt(t*t*n*n+a*a*s*s),u=Math.abs(t*a*s/l);i.x<o&&(u=-u);var h=Math.abs(t*a*n/l);return i.y<r&&(h=-h),{x:o+u,y:r+h}}g(Zt,"intersectEllipse");var qt=Zt;function Vt(e,t,a){return qt(e,t,t,a)}g(Vt,"intersectCircle");var pr=Vt;function Jt(e,t,a,i){var o,r,s,n,l,u,h,b,f,x,L,S,k,$,D;if(o=t.y-e.y,s=e.x-t.x,l=t.x*e.y-e.x*t.y,f=o*a.x+s*a.y+l,x=o*i.x+s*i.y+l,!(f!==0&&x!==0&&Lt(f,x))&&(r=i.y-a.y,n=a.x-i.x,u=i.x*a.y-a.x*i.y,h=r*e.x+n*e.y+u,b=r*t.x+n*t.y+u,!(h!==0&&b!==0&&Lt(h,b))&&(L=o*n-r*s,L!==0)))return S=Math.abs(L/2),k=s*u-n*l,$=k<0?(k-S)/L:(k+S)/L,k=r*l-o*u,D=k<0?(k-S)/L:(k+S)/L,{x:$,y:D}}g(Jt,"intersectLine");function Lt(e,t){return e*t>0}g(Lt,"sameSign");var br=Jt,xr=Gt;function Gt(e,t,a){var i=e.x,o=e.y,r=[],s=Number.POSITIVE_INFINITY,n=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(L){s=Math.min(s,L.x),n=Math.min(n,L.y)}):(s=Math.min(s,t.x),n=Math.min(n,t.y));for(var l=i-e.width/2-s,u=o-e.height/2-n,h=0;h<t.length;h++){var b=t[h],f=t[h<t.length-1?h+1:0],x=br(e,a,{x:l+b.x,y:u+b.y},{x:l+f.x,y:u+f.y});x&&r.push(x)}return r.length?(r.length>1&&r.sort(function(L,S){var k=L.x-a.x,$=L.y-a.y,D=Math.sqrt(k*k+$*$),v=S.x-a.x,c=S.y-a.y,p=Math.sqrt(v*v+c*c);return D<p?-1:D===p?0:1}),r[0]):e}g(Gt,"intersectPolygon");var fr=g((e,t)=>{var a=e.x,i=e.y,o=t.x-a,r=t.y-i,s=e.width/2,n=e.height/2,l,u;return Math.abs(r)*s>Math.abs(o)*n?(r<0&&(n=-n),l=r===0?0:n*o/r,u=n):(o<0&&(s=-s),l=s,u=o===0?0:s*r/o),{x:a+l,y:i+u}},"intersectRect"),wr=fr,N={node:yr,circle:pr,ellipse:qt,polygon:xr,rect:wr},R=g(async(e,t,a,i)=>{const o=B();let r;const s=t.useHtmlLabels||H(o.flowchart.htmlLabels);a?r=a:r="node default";const n=e.insert("g").attr("class",r).attr("id",t.domId||t.id),l=n.insert("g").attr("class","label").attr("style",t.labelStyle);let u;t.labelText===void 0?u="":u=typeof t.labelText=="string"?t.labelText:t.labelText[0];const h=l.node();let b;t.labelType==="markdown"?b=Mt(l,bt(pt(u),o),{useHtmlLabels:s,width:t.width||o.flowchart.wrappingWidth,classes:"markdown-node-label"},o):b=h.appendChild(await K(bt(pt(u),o),t.labelStyle,!1,i));let f=b.getBBox();const x=t.padding/2;if(H(o.flowchart.htmlLabels)){const L=b.children[0],S=I(b),k=L.getElementsByTagName("img");if(k){const $=u.replace(/<img[^>]*>/g,"").trim()==="";await Promise.all([...k].map(D=>new Promise(v=>{function c(){if(D.style.display="flex",D.style.flexDirection="column",$){const p=o.fontSize?o.fontSize:window.getComputedStyle(document.body).fontSize,w=parseInt(p,10)*5+"px";D.style.minWidth=w,D.style.maxWidth=w}else D.style.width="100%";v(D)}g(c,"setupImage"),setTimeout(()=>{D.complete&&c()}),D.addEventListener("error",c),D.addEventListener("load",c)})))}f=L.getBoundingClientRect(),S.attr("width",f.width),S.attr("height",f.height)}return s?l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"):l.attr("transform","translate(0, "+-f.height/2+")"),t.centerLabel&&l.attr("transform","translate("+-f.width/2+", "+-f.height/2+")"),l.insert("rect",":first-child"),{shapeSvg:n,bbox:f,halfPadding:x,label:l}},"labelHelper"),T=g((e,t)=>{const a=t.node().getBBox();e.width=a.width,e.height=a.height},"updateNodeBounds");function F(e,t,a,i){return e.insert("polygon",":first-child").attr("points",i.map(function(o){return o.x+","+o.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+a/2+")")}g(F,"insertPolygonShape");var mr=g(async(e,t)=>{t.useHtmlLabels||B().flowchart.htmlLabels||(t.centerLabel=!0);const{shapeSvg:a,bbox:i,halfPadding:o}=await R(e,t,"node "+t.classes,!0);m.info("Classes = ",t.classes);const r=a.insert("rect",":first-child");return r.attr("rx",t.rx).attr("ry",t.ry).attr("x",-i.width/2-o).attr("y",-i.height/2-o).attr("width",i.width+t.padding).attr("height",i.height+t.padding),T(t,r),t.intersect=function(s){return N.rect(t,s)},a},"note"),Lr=mr,Ot=g(e=>e?" "+e:"","formatClass"),X=g((e,t)=>`${t||"node default"}${Ot(e.classes)} ${Ot(e.class)}`,"getClassesFromNode"),zt=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=o+r,n=[{x:s/2,y:0},{x:s,y:-s/2},{x:s/2,y:-s},{x:0,y:-s/2}];m.info("Question main (Circle)");const l=F(a,s,s,n);return l.attr("style",t.style),T(t,l),t.intersect=function(u){return m.warn("Intersect called"),N.polygon(t,n,u)},a},"question"),Sr=g((e,t)=>{const a=e.insert("g").attr("class","node default").attr("id",t.domId||t.id),i=28,o=[{x:0,y:i/2},{x:i/2,y:0},{x:0,y:-i/2},{x:-i/2,y:0}];return a.insert("polygon",":first-child").attr("points",o.map(function(r){return r.x+","+r.y}).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),t.width=28,t.height=28,t.intersect=function(r){return N.circle(t,14,r)},a},"choice"),kr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=4,r=i.height+t.padding,s=r/o,n=i.width+2*s+t.padding,l=[{x:s,y:0},{x:n-s,y:0},{x:n,y:-r/2},{x:n-s,y:-r},{x:s,y:-r},{x:0,y:-r/2}],u=F(a,n,r,l);return u.attr("style",t.style),T(t,u),t.intersect=function(h){return N.polygon(t,l,h)},a},"hexagon"),_r=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,void 0,!0),o=2,r=i.height+2*t.padding,s=r/o,n=i.width+2*s+t.padding,l=ur(t.directions,i,t),u=F(a,n,r,l);return u.attr("style",t.style),T(t,u),t.intersect=function(h){return N.polygon(t,l,h)},a},"block_arrow"),Er=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:-r/2,y:0},{x:o,y:0},{x:o,y:-r},{x:-r/2,y:-r},{x:0,y:-r/2}];return F(a,o,r,s).attr("style",t.style),t.width=o+r,t.height=r,t.intersect=function(n){return N.polygon(t,s,n)},a},"rect_left_inv_arrow"),Dr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:-2*r/6,y:0},{x:o-r/6,y:0},{x:o+2*r/6,y:-r},{x:r/6,y:-r}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"lean_right"),vr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:2*r/6,y:0},{x:o+r/6,y:0},{x:o-2*r/6,y:-r},{x:-r/6,y:-r}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"lean_left"),Nr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:-2*r/6,y:0},{x:o+2*r/6,y:0},{x:o-r/6,y:-r},{x:r/6,y:-r}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"trapezoid"),Tr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:r/6,y:0},{x:o-r/6,y:0},{x:o+2*r/6,y:-r},{x:-2*r/6,y:-r}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"inv_trapezoid"),$r=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:0,y:0},{x:o+r/2,y:0},{x:o,y:-r/2},{x:o+r/2,y:-r},{x:0,y:-r}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"rect_right_inv_arrow"),Cr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=o/2,s=r/(2.5+o/50),n=i.height+s+t.padding,l="M 0,"+s+" a "+r+","+s+" 0,0,0 "+o+" 0 a "+r+","+s+" 0,0,0 "+-o+" 0 l 0,"+n+" a "+r+","+s+" 0,0,0 "+o+" 0 l 0,"+-n,u=a.attr("label-offset-y",s).insert("path",":first-child").attr("style",t.style).attr("d",l).attr("transform","translate("+-o/2+","+-(n/2+s)+")");return T(t,u),t.intersect=function(h){const b=N.rect(t,h),f=b.x-t.x;if(r!=0&&(Math.abs(f)<t.width/2||Math.abs(f)==t.width/2&&Math.abs(b.y-t.y)>t.height/2-s)){let x=s*s*(1-f*f/(r*r));x!=0&&(x=Math.sqrt(x)),x=s-x,h.y-t.y>0&&(x=-x),b.y+=x}return b},a},"cylinder"),Ir=g(async(e,t)=>{const{shapeSvg:a,bbox:i,halfPadding:o}=await R(e,t,"node "+t.classes+" "+t.class,!0),r=a.insert("rect",":first-child"),s=t.positioned?t.width:i.width+t.padding,n=t.positioned?t.height:i.height+t.padding,l=t.positioned?-s/2:-i.width/2-o,u=t.positioned?-n/2:-i.height/2-o;if(r.attr("class","basic label-container").attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",l).attr("y",u).attr("width",s).attr("height",n),t.props){const h=new Set(Object.keys(t.props));t.props.borders&&(ct(r,t.props.borders,s,n),h.delete("borders")),h.forEach(b=>{m.warn(`Unknown node property ${b}`)})}return T(t,r),t.intersect=function(h){return N.rect(t,h)},a},"rect"),Br=g(async(e,t)=>{const{shapeSvg:a,bbox:i,halfPadding:o}=await R(e,t,"node "+t.classes,!0),r=a.insert("rect",":first-child"),s=t.positioned?t.width:i.width+t.padding,n=t.positioned?t.height:i.height+t.padding,l=t.positioned?-s/2:-i.width/2-o,u=t.positioned?-n/2:-i.height/2-o;if(r.attr("class","basic cluster composite label-container").attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("x",l).attr("y",u).attr("width",s).attr("height",n),t.props){const h=new Set(Object.keys(t.props));t.props.borders&&(ct(r,t.props.borders,s,n),h.delete("borders")),h.forEach(b=>{m.warn(`Unknown node property ${b}`)})}return T(t,r),t.intersect=function(h){return N.rect(t,h)},a},"composite"),Or=g(async(e,t)=>{const{shapeSvg:a}=await R(e,t,"label",!0);m.trace("Classes = ",t.class);const i=a.insert("rect",":first-child"),o=0,r=0;if(i.attr("width",o).attr("height",r),a.attr("class","label edgeLabel"),t.props){const s=new Set(Object.keys(t.props));t.props.borders&&(ct(i,t.props.borders,o,r),s.delete("borders")),s.forEach(n=>{m.warn(`Unknown node property ${n}`)})}return T(t,i),t.intersect=function(s){return N.rect(t,s)},a},"labelRect");function ct(e,t,a,i){const o=[],r=g(n=>{o.push(n,0)},"addBorder"),s=g(n=>{o.push(0,n)},"skipBorder");t.includes("t")?(m.debug("add top border"),r(a)):s(a),t.includes("r")?(m.debug("add right border"),r(i)):s(i),t.includes("b")?(m.debug("add bottom border"),r(a)):s(a),t.includes("l")?(m.debug("add left border"),r(i)):s(i),e.attr("stroke-dasharray",o.join(" "))}g(ct,"applyNodePropertyBorders");var zr=g(async(e,t)=>{let a;t.classes?a="node "+t.classes:a="node default";const i=e.insert("g").attr("class",a).attr("id",t.domId||t.id),o=i.insert("rect",":first-child"),r=i.insert("line"),s=i.insert("g").attr("class","label"),n=t.labelText.flat?t.labelText.flat():t.labelText;let l="";typeof n=="object"?l=n[0]:l=n,m.info("Label text abc79",l,n,typeof n=="object");const u=s.node().appendChild(await K(l,t.labelStyle,!0,!0));let h={width:0,height:0};if(H(B().flowchart.htmlLabels)){const S=u.children[0],k=I(u);h=S.getBoundingClientRect(),k.attr("width",h.width),k.attr("height",h.height)}m.info("Text 2",n);const b=n.slice(1,n.length);let f=u.getBBox();const x=s.node().appendChild(await K(b.join?b.join("<br/>"):b,t.labelStyle,!0,!0));if(H(B().flowchart.htmlLabels)){const S=x.children[0],k=I(x);h=S.getBoundingClientRect(),k.attr("width",h.width),k.attr("height",h.height)}const L=t.padding/2;return I(x).attr("transform","translate( "+(h.width>f.width?0:(f.width-h.width)/2)+", "+(f.height+L+5)+")"),I(u).attr("transform","translate( "+(h.width<f.width?0:-(f.width-h.width)/2)+", 0)"),h=s.node().getBBox(),s.attr("transform","translate("+-h.width/2+", "+(-h.height/2-L+3)+")"),o.attr("class","outer title-state").attr("x",-h.width/2-L).attr("y",-h.height/2-L).attr("width",h.width+t.padding).attr("height",h.height+t.padding),r.attr("class","divider").attr("x1",-h.width/2-L).attr("x2",h.width/2+L).attr("y1",-h.height/2-L+f.height+L).attr("y2",-h.height/2-L+f.height+L),T(t,o),t.intersect=function(S){return N.rect(t,S)},i},"rectWithTitle"),Rr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.height+t.padding,r=i.width+o/4+t.padding,s=a.insert("rect",":first-child").attr("style",t.style).attr("rx",o/2).attr("ry",o/2).attr("x",-r/2).attr("y",-o/2).attr("width",r).attr("height",o);return T(t,s),t.intersect=function(n){return N.rect(t,n)},a},"stadium"),Ar=g(async(e,t)=>{const{shapeSvg:a,bbox:i,halfPadding:o}=await R(e,t,X(t,void 0),!0),r=a.insert("circle",":first-child");return r.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",i.width/2+o).attr("width",i.width+t.padding).attr("height",i.height+t.padding),m.info("Circle main"),T(t,r),t.intersect=function(s){return m.info("Circle intersect",t,i.width/2+o,s),N.circle(t,i.width/2+o,s)},a},"circle"),Mr=g(async(e,t)=>{const{shapeSvg:a,bbox:i,halfPadding:o}=await R(e,t,X(t,void 0),!0),r=5,s=a.insert("g",":first-child"),n=s.insert("circle"),l=s.insert("circle");return s.attr("class",t.class),n.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",i.width/2+o+r).attr("width",i.width+t.padding+r*2).attr("height",i.height+t.padding+r*2),l.attr("style",t.style).attr("rx",t.rx).attr("ry",t.ry).attr("r",i.width/2+o).attr("width",i.width+t.padding).attr("height",i.height+t.padding),m.info("DoubleCircle main"),T(t,n),t.intersect=function(u){return m.info("DoubleCircle intersect",t,i.width/2+o+r,u),N.circle(t,i.width/2+o+r,u)},a},"doublecircle"),Pr=g(async(e,t)=>{const{shapeSvg:a,bbox:i}=await R(e,t,X(t,void 0),!0),o=i.width+t.padding,r=i.height+t.padding,s=[{x:0,y:0},{x:o,y:0},{x:o,y:-r},{x:0,y:-r},{x:0,y:0},{x:-8,y:0},{x:o+8,y:0},{x:o+8,y:-r},{x:-8,y:-r},{x:-8,y:0}],n=F(a,o,r,s);return n.attr("style",t.style),T(t,n),t.intersect=function(l){return N.polygon(t,s,l)},a},"subroutine"),Yr=g((e,t)=>{const a=e.insert("g").attr("class","node default").attr("id",t.domId||t.id),i=a.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),T(t,i),t.intersect=function(o){return N.circle(t,7,o)},a},"start"),Rt=g((e,t,a)=>{const i=e.insert("g").attr("class","node default").attr("id",t.domId||t.id);let o=70,r=10;a==="LR"&&(o=10,r=70);const s=i.append("rect").attr("x",-1*o/2).attr("y",-1*r/2).attr("width",o).attr("height",r).attr("class","fork-join");return T(t,s),t.height=t.height+t.padding/2,t.width=t.width+t.padding/2,t.intersect=function(n){return N.rect(t,n)},i},"forkJoin"),Xr=g((e,t)=>{const a=e.insert("g").attr("class","node default").attr("id",t.domId||t.id),i=a.insert("circle",":first-child"),o=a.insert("circle",":first-child");return o.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),i.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),T(t,o),t.intersect=function(r){return N.circle(t,7,r)},a},"end"),Wr=g(async(e,t)=>{const a=t.padding/2,i=4,o=8;let r;t.classes?r="node "+t.classes:r="node default";const s=e.insert("g").attr("class",r).attr("id",t.domId||t.id),n=s.insert("rect",":first-child"),l=s.insert("line"),u=s.insert("line");let h=0,b=i;const f=s.insert("g").attr("class","label");let x=0;const L=t.classData.annotations?.[0],S=t.classData.annotations[0]?"«"+t.classData.annotations[0]+"»":"",k=f.node().appendChild(await K(S,t.labelStyle,!0,!0));let $=k.getBBox();if(H(B().flowchart.htmlLabels)){const d=k.children[0],_=I(k);$=d.getBoundingClientRect(),_.attr("width",$.width),_.attr("height",$.height)}t.classData.annotations[0]&&(b+=$.height+i,h+=$.width);let D=t.classData.label;t.classData.type!==void 0&&t.classData.type!==""&&(B().flowchart.htmlLabels?D+="&lt;"+t.classData.type+"&gt;":D+="<"+t.classData.type+">");const v=f.node().appendChild(await K(D,t.labelStyle,!0,!0));I(v).attr("class","classTitle");let c=v.getBBox();if(H(B().flowchart.htmlLabels)){const d=v.children[0],_=I(v);c=d.getBoundingClientRect(),_.attr("width",c.width),_.attr("height",c.height)}b+=c.height+i,c.width>h&&(h=c.width);const p=[];t.classData.members.forEach(async d=>{const _=d.getDisplayDetails();let y=_.displayText;B().flowchart.htmlLabels&&(y=y.replace(/</g,"&lt;").replace(/>/g,"&gt;"));const A=f.node().appendChild(await K(y,_.cssStyle?_.cssStyle:t.labelStyle,!0,!0));let O=A.getBBox();if(H(B().flowchart.htmlLabels)){const q=A.children[0],j=I(A);O=q.getBoundingClientRect(),j.attr("width",O.width),j.attr("height",O.height)}O.width>h&&(h=O.width),b+=O.height+i,p.push(A)}),b+=o;const w=[];if(t.classData.methods.forEach(async d=>{const _=d.getDisplayDetails();let y=_.displayText;B().flowchart.htmlLabels&&(y=y.replace(/</g,"&lt;").replace(/>/g,"&gt;"));const A=f.node().appendChild(await K(y,_.cssStyle?_.cssStyle:t.labelStyle,!0,!0));let O=A.getBBox();if(H(B().flowchart.htmlLabels)){const q=A.children[0],j=I(A);O=q.getBoundingClientRect(),j.attr("width",O.width),j.attr("height",O.height)}O.width>h&&(h=O.width),b+=O.height+i,w.push(A)}),b+=o,L){let d=(h-$.width)/2;I(k).attr("transform","translate( "+(-1*h/2+d)+", "+-1*b/2+")"),x=$.height+i}let E=(h-c.width)/2;return I(v).attr("transform","translate( "+(-1*h/2+E)+", "+(-1*b/2+x)+")"),x+=c.height+i,l.attr("class","divider").attr("x1",-h/2-a).attr("x2",h/2+a).attr("y1",-b/2-a+o+x).attr("y2",-b/2-a+o+x),x+=o,p.forEach(d=>{I(d).attr("transform","translate( "+-h/2+", "+(-1*b/2+x+o/2)+")");const _=d?.getBBox();x+=(_?.height??0)+i}),x+=o,u.attr("class","divider").attr("x1",-h/2-a).attr("x2",h/2+a).attr("y1",-b/2-a+o+x).attr("y2",-b/2-a+o+x),x+=o,w.forEach(d=>{I(d).attr("transform","translate( "+-h/2+", "+(-1*b/2+x)+")");const _=d?.getBBox();x+=(_?.height??0)+i}),n.attr("style",t.style).attr("class","outer title-state").attr("x",-h/2-a).attr("y",-(b/2)-a).attr("width",h+t.padding).attr("height",b+t.padding),T(t,n),t.intersect=function(d){return N.rect(t,d)},s},"class_box"),At={rhombus:zt,composite:Br,question:zt,rect:Ir,labelRect:Or,rectWithTitle:zr,choice:Sr,circle:Ar,doublecircle:Mr,stadium:Rr,hexagon:kr,block_arrow:_r,rect_left_inv_arrow:Er,lean_right:Dr,lean_left:vr,trapezoid:Nr,inv_trapezoid:Tr,rect_right_inv_arrow:$r,cylinder:Cr,start:Yr,end:Xr,note:Lr,subroutine:Pr,fork:Rt,join:Rt,class_box:Wr},nt={},Qt=g(async(e,t,a)=>{let i,o;if(t.link){let r;B().securityLevel==="sandbox"?r="_top":t.linkTarget&&(r=t.linkTarget||"_blank"),i=e.insert("svg:a").attr("xlink:href",t.link).attr("target",r),o=await At[t.shape](i,t,a)}else o=await At[t.shape](e,t,a),i=o;return t.tooltip&&o.attr("title",t.tooltip),t.class&&o.attr("class","node default "+t.class),nt[t.id]=i,t.haveCallback&&nt[t.id].attr("class",nt[t.id].attr("class")+" clickable"),i},"insertNode"),Kr=g(e=>{const t=nt[e.id];m.trace("Transforming node",e.diff,e,"translate("+(e.x-e.width/2-5)+", "+e.width/2+")");const a=8,i=e.diff||0;return e.clusterNode?t.attr("transform","translate("+(e.x+i-e.width/2)+", "+(e.y-e.height/2-a)+")"):t.attr("transform","translate("+e.x+", "+e.y+")"),i},"positionNode");function Dt(e,t,a=!1){const i=e;let o="default";(i?.classes?.length||0)>0&&(o=(i?.classes??[]).join(" ")),o=o+" flowchart-label";let r=0,s="",n;switch(i.type){case"round":r=5,s="rect";break;case"composite":r=0,s="composite",n=0;break;case"square":s="rect";break;case"diamond":s="question";break;case"hexagon":s="hexagon";break;case"block_arrow":s="block_arrow";break;case"odd":s="rect_left_inv_arrow";break;case"lean_right":s="lean_right";break;case"lean_left":s="lean_left";break;case"trapezoid":s="trapezoid";break;case"inv_trapezoid":s="inv_trapezoid";break;case"rect_left_inv_arrow":s="rect_left_inv_arrow";break;case"circle":s="circle";break;case"ellipse":s="ellipse";break;case"stadium":s="stadium";break;case"subroutine":s="subroutine";break;case"cylinder":s="cylinder";break;case"group":s="rect";break;case"doublecircle":s="doublecircle";break;default:s="rect"}const l=we(i?.styles??[]),u=i.label,h=i.size??{width:0,height:0,x:0,y:0};return{labelStyle:l.labelStyle,shape:s,labelText:u,rx:r,ry:r,class:o,style:l.style,id:i.id,directions:i.directions,width:h.width,height:h.height,x:h.x,y:h.y,positioned:a,intersect:void 0,type:i.type,padding:n??rt()?.block?.padding??0}}g(Dt,"getNodeFromBlock");async function te(e,t,a){const i=Dt(t,a,!1);if(i.type==="group")return;const o=rt(),r=await Qt(e,i,{config:o}),s=r.node().getBBox(),n=a.getBlock(i.id);n.size={width:s.width,height:s.height,x:0,y:0,node:r},a.setBlock(n),r.remove()}g(te,"calculateBlockSize");async function ee(e,t,a){const i=Dt(t,a,!0);if(a.getBlock(i.id).type!=="space"){const o=rt();await Qt(e,i,{config:o}),t.intersect=i?.intersect,Kr(i)}}g(ee,"insertBlockPositioned");async function dt(e,t,a,i){for(const o of t)await i(e,o,a),o.children&&await dt(e,o.children,a,i)}g(dt,"performOperations");async function re(e,t,a){await dt(e,t,a,te)}g(re,"calculateBlockSizes");async function ae(e,t,a){await dt(e,t,a,ee)}g(ae,"insertBlocks");async function se(e,t,a,i,o){const r=new Le({multigraph:!0,compound:!0});r.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(const s of a)s.size&&r.setNode(s.id,{width:s.size.width,height:s.size.height,intersect:s.intersect});for(const s of t)if(s.start&&s.end){const n=i.getBlock(s.start),l=i.getBlock(s.end);if(n?.size&&l?.size){const u=n.size,h=l.size,b=[{x:u.x,y:u.y},{x:u.x+(h.x-u.x)/2,y:u.y+(h.y-u.y)/2},{x:h.x,y:h.y}];hr(e,{v:s.start,w:s.end,name:s.id},{...s,arrowTypeEnd:s.arrowTypeEnd,arrowTypeStart:s.arrowTypeStart,points:b,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"},void 0,"block",r,o),s.label&&(await or(e,{...s,label:s.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:s.arrowTypeEnd,arrowTypeStart:s.arrowTypeStart,points:b,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"}),lr({...s,x:b[1].x,y:b[1].y},{originalPath:b}))}}}g(se,"insertEdges");var Ur=g(function(e,t){return t.db.getClasses()},"getClasses"),Fr=g(async function(e,t,a,i){const{securityLevel:o,block:r}=rt(),s=i.db;let n;o==="sandbox"&&(n=I("#i"+t));const l=o==="sandbox"?I(n.nodes()[0].contentDocument.body):I("body"),u=o==="sandbox"?l.select(`[id="${t}"]`):I(`[id="${t}"]`);rr(u,["point","circle","cross"],i.type,t);const h=s.getBlocks(),b=s.getBlocksFlat(),f=s.getEdges(),x=u.insert("g").attr("class","block");await re(x,h,s);const L=Ft(s);if(await ae(x,h,s),await se(x,f,b,s,t),L){const S=L,k=Math.max(1,Math.round(.125*(S.width/S.height))),$=S.height+k+10,D=S.width+10,{useMaxWidth:v}=r;ce(u,$,D,!!v),m.debug("Here Bounds",L,S),u.attr("viewBox",`${S.x-5} ${S.y-5} ${S.width+10} ${S.height+10}`)}},"draw"),jr={draw:Fr,getClasses:Ur},Qr={parser:ke,db:We,renderer:jr,styles:Ue};export{Qr as diagram};
@@ -1,4 +1,4 @@
1
- import{g as oe}from"./chunk-FMBD7UC4-CN5kw4_J.js";import{bE as d,cb as rt,bK as O,bM as he,bL as L,c3 as de,c5 as ge,bJ as R,cR as ue,cz as pe,cH as fe,cE as xe,cS as j,cT as Wt,cU as ye,bY as $,bS as be,cV as we,cW as xt,bP as yt,cX as me}from"./index-BXRJOAs4.js";import{c as Le}from"./clone-DZrMJ9hz.js";import{G as Se}from"./graph-CIQI-Qnx.js";import{c as ke}from"./channel-CXjddKEr.js";import"./_baseUniq--5gbTAb8.js";var bt=(function(){var e=d(function(D,y,g,f){for(g=g||{},f=D.length;f--;g[D[f]]=y);return g},"o"),t=[1,15],a=[1,7],i=[1,13],l=[1,14],s=[1,19],r=[1,16],n=[1,17],c=[1,18],u=[8,30],o=[8,10,21,28,29,30,31,39,43,46],x=[1,23],w=[1,24],b=[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],v=[1,49],k={trace:d(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:d(function(y,g,f,m,E,h,W){var p=h.length-1;switch(E){case 4:m.getLogger().debug("Rule: separator (NL) ");break;case 5:m.getLogger().debug("Rule: separator (Space) ");break;case 6:m.getLogger().debug("Rule: separator (EOF) ");break;case 7:m.getLogger().debug("Rule: hierarchy: ",h[p-1]),m.setHierarchy(h[p-1]);break;case 8:m.getLogger().debug("Stop NL ");break;case 9:m.getLogger().debug("Stop EOF ");break;case 10:m.getLogger().debug("Stop NL2 ");break;case 11:m.getLogger().debug("Stop EOF2 ");break;case 12:m.getLogger().debug("Rule: statement: ",h[p]),typeof h[p].length=="number"?this.$=h[p]:this.$=[h[p]];break;case 13:m.getLogger().debug("Rule: statement #2: ",h[p-1]),this.$=[h[p-1]].concat(h[p]);break;case 14:m.getLogger().debug("Rule: link: ",h[p],y),this.$={edgeTypeStr:h[p],label:""};break;case 15:m.getLogger().debug("Rule: LABEL link: ",h[p-3],h[p-1],h[p]),this.$={edgeTypeStr:h[p],label:h[p-1]};break;case 18:const I=parseInt(h[p]),Z=m.generateId();this.$={id:Z,type:"space",label:"",width:I,children:[]};break;case 23:m.getLogger().debug("Rule: (nodeStatement link node) ",h[p-2],h[p-1],h[p]," typestr: ",h[p-1].edgeTypeStr);const V=m.edgeStrToEdgeData(h[p-1].edgeTypeStr);this.$=[{id:h[p-2].id,label:h[p-2].label,type:h[p-2].type,directions:h[p-2].directions},{id:h[p-2].id+"-"+h[p].id,start:h[p-2].id,end:h[p].id,label:h[p-1].label,type:"edge",directions:h[p].directions,arrowTypeEnd:V,arrowTypeStart:"arrow_open"},{id:h[p].id,label:h[p].label,type:m.typeStr2Type(h[p].typeStr),directions:h[p].directions}];break;case 24:m.getLogger().debug("Rule: nodeStatement (abc88 node size) ",h[p-1],h[p]),this.$={id:h[p-1].id,label:h[p-1].label,type:m.typeStr2Type(h[p-1].typeStr),directions:h[p-1].directions,widthInColumns:parseInt(h[p],10)};break;case 25:m.getLogger().debug("Rule: nodeStatement (node) ",h[p]),this.$={id:h[p].id,label:h[p].label,type:m.typeStr2Type(h[p].typeStr),directions:h[p].directions,widthInColumns:1};break;case 26:m.getLogger().debug("APA123",this?this:"na"),m.getLogger().debug("COLUMNS: ",h[p]),this.$={type:"column-setting",columns:h[p]==="auto"?-1:parseInt(h[p])};break;case 27:m.getLogger().debug("Rule: id-block statement : ",h[p-2],h[p-1]),m.generateId(),this.$={...h[p-2],type:"composite",children:h[p-1]};break;case 28:m.getLogger().debug("Rule: blockStatement : ",h[p-2],h[p-1],h[p]);const at=m.generateId();this.$={id:at,type:"composite",label:"",children:h[p-1]};break;case 29:m.getLogger().debug("Rule: node (NODE_ID separator): ",h[p]),this.$={id:h[p]};break;case 30:m.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",h[p-1],h[p]),this.$={id:h[p-1],label:h[p].label,typeStr:h[p].typeStr,directions:h[p].directions};break;case 31:m.getLogger().debug("Rule: dirList: ",h[p]),this.$=[h[p]];break;case 32:m.getLogger().debug("Rule: dirList: ",h[p-1],h[p]),this.$=[h[p-1]].concat(h[p]);break;case 33:m.getLogger().debug("Rule: nodeShapeNLabel: ",h[p-2],h[p-1],h[p]),this.$={typeStr:h[p-2]+h[p],label:h[p-1]};break;case 34:m.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",h[p-3],h[p-2]," #3:",h[p-1],h[p]),this.$={typeStr:h[p-3]+h[p],label:h[p-2],directions:h[p-1]};break;case 35:case 36:this.$={type:"classDef",id:h[p-1].trim(),css:h[p].trim()};break;case 37:this.$={type:"applyClass",id:h[p-1].trim(),styleClass:h[p].trim()};break;case 38:this.$={type:"applyStyles",id:h[p-1].trim(),stylesStr:h[p].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:t,11:3,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{8:[1,20]},e(u,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:t,21:a,28:i,29:l,31:s,39:r,43:n,46:c}),e(o,[2,16],{14:22,15:x,16:w}),e(o,[2,17]),e(o,[2,18]),e(o,[2,19]),e(o,[2,20]),e(o,[2,21]),e(o,[2,22]),e(b,[2,25],{27:[1,25]}),e(o,[2,26]),{19:26,26:12,31:s},{10:t,11:27,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{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(u,[2,13]),{26:35,31:s},{31:[2,14]},{17:[1,36]},e(b,[2,24]),{10:t,11:37,13:4,14:22,15:x,16:w,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{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(b,[2,23]),{18:[1,45]},{30:[1,46]},e(o,[2,28]),e(o,[2,35]),e(o,[2,36]),e(o,[2,37]),e(o,[2,38]),{36:[1,47]},{33:48,34:v},{15:[1,50]},e(o,[2,27]),e(S,[2,33]),{38:[1,51]},{33:52,34:v,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:d(function(y,g){if(g.recoverable)this.trace(y);else{var f=new Error(y);throw f.hash=g,f}},"parseError"),parse:d(function(y){var g=this,f=[0],m=[],E=[null],h=[],W=this.table,p="",I=0,Z=0,V=2,at=1,ne=h.slice.call(arguments,1),z=Object.create(this.lexer),q={yy:{}};for(var gt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,gt)&&(q.yy[gt]=this.yy[gt]);z.setInput(y,q.yy),q.yy.lexer=z,q.yy.parser=this,typeof z.yylloc>"u"&&(z.yylloc={});var ut=z.yylloc;h.push(ut);var le=z.options&&z.options.ranges;typeof q.yy.parseError=="function"?this.parseError=q.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ce(P){f.length=f.length-2*P,E.length=E.length-P,h.length=h.length-P}d(ce,"popStack");function Tt(){var P;return P=m.pop()||z.lex()||at,typeof P!="number"&&(P instanceof Array&&(m=P,P=m.pop()),P=g.symbols_[P]||P),P}d(Tt,"lex");for(var F,J,H,pt,Q={},st,G,Nt,it;;){if(J=f[f.length-1],this.defaultActions[J]?H=this.defaultActions[J]:((F===null||typeof F>"u")&&(F=Tt()),H=W[J]&&W[J][F]),typeof H>"u"||!H.length||!H[0]){var ft="";it=[];for(st in W[J])this.terminals_[st]&&st>V&&it.push("'"+this.terminals_[st]+"'");z.showPosition?ft="Parse error on line "+(I+1)+`:
1
+ import{g as oe}from"./chunk-FMBD7UC4-eFjHw5gB.js";import{bE as d,cb as rt,bK as O,bM as he,bL as L,c3 as de,c5 as ge,bJ as R,cR as ue,cz as pe,cH as fe,cE as xe,cS as j,cT as Wt,cU as ye,bY as $,bS as be,cV as we,cW as xt,bP as yt,cX as me}from"./index-BzhKcNOt.js";import{c as Le}from"./clone-B-ElcgAC.js";import{G as Se}from"./graph-C_DQAJXv.js";import{c as ke}from"./channel-C9MJ1fN1.js";import"./_baseUniq-DuAmhUI0.js";var bt=(function(){var e=d(function(D,y,g,f){for(g=g||{},f=D.length;f--;g[D[f]]=y);return g},"o"),t=[1,15],a=[1,7],i=[1,13],l=[1,14],s=[1,19],r=[1,16],n=[1,17],c=[1,18],u=[8,30],o=[8,10,21,28,29,30,31,39,43,46],x=[1,23],w=[1,24],b=[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],v=[1,49],k={trace:d(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:d(function(y,g,f,m,E,h,W){var p=h.length-1;switch(E){case 4:m.getLogger().debug("Rule: separator (NL) ");break;case 5:m.getLogger().debug("Rule: separator (Space) ");break;case 6:m.getLogger().debug("Rule: separator (EOF) ");break;case 7:m.getLogger().debug("Rule: hierarchy: ",h[p-1]),m.setHierarchy(h[p-1]);break;case 8:m.getLogger().debug("Stop NL ");break;case 9:m.getLogger().debug("Stop EOF ");break;case 10:m.getLogger().debug("Stop NL2 ");break;case 11:m.getLogger().debug("Stop EOF2 ");break;case 12:m.getLogger().debug("Rule: statement: ",h[p]),typeof h[p].length=="number"?this.$=h[p]:this.$=[h[p]];break;case 13:m.getLogger().debug("Rule: statement #2: ",h[p-1]),this.$=[h[p-1]].concat(h[p]);break;case 14:m.getLogger().debug("Rule: link: ",h[p],y),this.$={edgeTypeStr:h[p],label:""};break;case 15:m.getLogger().debug("Rule: LABEL link: ",h[p-3],h[p-1],h[p]),this.$={edgeTypeStr:h[p],label:h[p-1]};break;case 18:const I=parseInt(h[p]),Z=m.generateId();this.$={id:Z,type:"space",label:"",width:I,children:[]};break;case 23:m.getLogger().debug("Rule: (nodeStatement link node) ",h[p-2],h[p-1],h[p]," typestr: ",h[p-1].edgeTypeStr);const V=m.edgeStrToEdgeData(h[p-1].edgeTypeStr);this.$=[{id:h[p-2].id,label:h[p-2].label,type:h[p-2].type,directions:h[p-2].directions},{id:h[p-2].id+"-"+h[p].id,start:h[p-2].id,end:h[p].id,label:h[p-1].label,type:"edge",directions:h[p].directions,arrowTypeEnd:V,arrowTypeStart:"arrow_open"},{id:h[p].id,label:h[p].label,type:m.typeStr2Type(h[p].typeStr),directions:h[p].directions}];break;case 24:m.getLogger().debug("Rule: nodeStatement (abc88 node size) ",h[p-1],h[p]),this.$={id:h[p-1].id,label:h[p-1].label,type:m.typeStr2Type(h[p-1].typeStr),directions:h[p-1].directions,widthInColumns:parseInt(h[p],10)};break;case 25:m.getLogger().debug("Rule: nodeStatement (node) ",h[p]),this.$={id:h[p].id,label:h[p].label,type:m.typeStr2Type(h[p].typeStr),directions:h[p].directions,widthInColumns:1};break;case 26:m.getLogger().debug("APA123",this?this:"na"),m.getLogger().debug("COLUMNS: ",h[p]),this.$={type:"column-setting",columns:h[p]==="auto"?-1:parseInt(h[p])};break;case 27:m.getLogger().debug("Rule: id-block statement : ",h[p-2],h[p-1]),m.generateId(),this.$={...h[p-2],type:"composite",children:h[p-1]};break;case 28:m.getLogger().debug("Rule: blockStatement : ",h[p-2],h[p-1],h[p]);const at=m.generateId();this.$={id:at,type:"composite",label:"",children:h[p-1]};break;case 29:m.getLogger().debug("Rule: node (NODE_ID separator): ",h[p]),this.$={id:h[p]};break;case 30:m.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",h[p-1],h[p]),this.$={id:h[p-1],label:h[p].label,typeStr:h[p].typeStr,directions:h[p].directions};break;case 31:m.getLogger().debug("Rule: dirList: ",h[p]),this.$=[h[p]];break;case 32:m.getLogger().debug("Rule: dirList: ",h[p-1],h[p]),this.$=[h[p-1]].concat(h[p]);break;case 33:m.getLogger().debug("Rule: nodeShapeNLabel: ",h[p-2],h[p-1],h[p]),this.$={typeStr:h[p-2]+h[p],label:h[p-1]};break;case 34:m.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",h[p-3],h[p-2]," #3:",h[p-1],h[p]),this.$={typeStr:h[p-3]+h[p],label:h[p-2],directions:h[p-1]};break;case 35:case 36:this.$={type:"classDef",id:h[p-1].trim(),css:h[p].trim()};break;case 37:this.$={type:"applyClass",id:h[p-1].trim(),styleClass:h[p].trim()};break;case 38:this.$={type:"applyStyles",id:h[p-1].trim(),stylesStr:h[p].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:t,11:3,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{8:[1,20]},e(u,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:t,21:a,28:i,29:l,31:s,39:r,43:n,46:c}),e(o,[2,16],{14:22,15:x,16:w}),e(o,[2,17]),e(o,[2,18]),e(o,[2,19]),e(o,[2,20]),e(o,[2,21]),e(o,[2,22]),e(b,[2,25],{27:[1,25]}),e(o,[2,26]),{19:26,26:12,31:s},{10:t,11:27,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{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(u,[2,13]),{26:35,31:s},{31:[2,14]},{17:[1,36]},e(b,[2,24]),{10:t,11:37,13:4,14:22,15:x,16:w,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:l,31:s,39:r,43:n,46:c},{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(b,[2,23]),{18:[1,45]},{30:[1,46]},e(o,[2,28]),e(o,[2,35]),e(o,[2,36]),e(o,[2,37]),e(o,[2,38]),{36:[1,47]},{33:48,34:v},{15:[1,50]},e(o,[2,27]),e(S,[2,33]),{38:[1,51]},{33:52,34:v,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:d(function(y,g){if(g.recoverable)this.trace(y);else{var f=new Error(y);throw f.hash=g,f}},"parseError"),parse:d(function(y){var g=this,f=[0],m=[],E=[null],h=[],W=this.table,p="",I=0,Z=0,V=2,at=1,ne=h.slice.call(arguments,1),z=Object.create(this.lexer),q={yy:{}};for(var gt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,gt)&&(q.yy[gt]=this.yy[gt]);z.setInput(y,q.yy),q.yy.lexer=z,q.yy.parser=this,typeof z.yylloc>"u"&&(z.yylloc={});var ut=z.yylloc;h.push(ut);var le=z.options&&z.options.ranges;typeof q.yy.parseError=="function"?this.parseError=q.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function ce(P){f.length=f.length-2*P,E.length=E.length-P,h.length=h.length-P}d(ce,"popStack");function Tt(){var P;return P=m.pop()||z.lex()||at,typeof P!="number"&&(P instanceof Array&&(m=P,P=m.pop()),P=g.symbols_[P]||P),P}d(Tt,"lex");for(var F,J,H,pt,Q={},st,G,Nt,it;;){if(J=f[f.length-1],this.defaultActions[J]?H=this.defaultActions[J]:((F===null||typeof F>"u")&&(F=Tt()),H=W[J]&&W[J][F]),typeof H>"u"||!H.length||!H[0]){var ft="";it=[];for(st in W[J])this.terminals_[st]&&st>V&&it.push("'"+this.terminals_[st]+"'");z.showPosition?ft="Parse error on line "+(I+1)+`:
2
2
  `+z.showPosition()+`
3
3
  Expecting `+it.join(", ")+", got '"+(this.terminals_[F]||F)+"'":ft="Parse error on line "+(I+1)+": Unexpected "+(F==at?"end of input":"'"+(this.terminals_[F]||F)+"'"),this.parseError(ft,{text:z.match,token:this.terminals_[F]||F,line:z.yylineno,loc:ut,expected:it})}if(H[0]instanceof Array&&H.length>1)throw new Error("Parse Error: multiple actions possible at state: "+J+", token: "+F);switch(H[0]){case 1:f.push(F),E.push(z.yytext),h.push(z.yylloc),f.push(H[1]),F=null,Z=z.yyleng,p=z.yytext,I=z.yylineno,ut=z.yylloc;break;case 2:if(G=this.productions_[H[1]][1],Q.$=E[E.length-G],Q._$={first_line:h[h.length-(G||1)].first_line,last_line:h[h.length-1].last_line,first_column:h[h.length-(G||1)].first_column,last_column:h[h.length-1].last_column},le&&(Q._$.range=[h[h.length-(G||1)].range[0],h[h.length-1].range[1]]),pt=this.performAction.apply(Q,[p,Z,I,q.yy,H[1],E,h].concat(ne)),typeof pt<"u")return pt;G&&(f=f.slice(0,-1*G*2),E=E.slice(0,-1*G),h=h.slice(0,-1*G)),f.push(this.productions_[H[1]][0]),E.push(Q.$),h.push(Q._$),Nt=W[f[f.length-2]][f[f.length-1]],f.push(Nt);break;case 3:return!0}}return!0},"parse")},B=(function(){var D={EOF:1,parseError:d(function(g,f){if(this.yy.parser)this.yy.parser.parseError(g,f);else throw new Error(g)},"parseError"),setInput:d(function(y,g){return this.yy=g||this.yy||{},this._input=y,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 y=this._input[0];this.yytext+=y,this.yyleng++,this.offset++,this.match+=y,this.matched+=y;var g=y.match(/(?:\r\n?|\n).*/g);return g?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),y},"input"),unput:d(function(y){var g=y.length,f=y.split(/(?:\r\n?|\n)/g);this._input=y+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-g),this.offset-=g;var m=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),f.length-1&&(this.yylineno-=f.length-1);var E=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:f?(f.length===m.length?this.yylloc.first_column:0)+m[m.length-f.length].length-f[0].length:this.yylloc.first_column-g},this.options.ranges&&(this.yylloc.range=[E[0],E[0]+this.yyleng-g]),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
4
  `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:d(function(y){this.unput(this.match.slice(y))},"less"),pastInput:d(function(){var y=this.matched.substr(0,this.matched.length-this.match.length);return(y.length>20?"...":"")+y.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:d(function(){var y=this.match;return y.length<20&&(y+=this._input.substr(0,20-y.length)),(y.substr(0,20)+(y.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:d(function(){var y=this.pastInput(),g=new Array(y.length+1).join("-");return y+this.upcomingInput()+`
@@ -0,0 +1,10 @@
1
+ import{y as ve,x as Re}from"./chunk-TZMSLE5B-DfaYobmr-uCvXwJUe.js";import{H as g,a7 as De,a8 as Pe,a9 as Ne,aa as Be,b as Rt,a5 as jt,a as de,ab as Me,ac as je,ad as wt,ae as fe,af as Le,ag as Ye,ah as Jt,ai as ue}from"./index-BzhKcNOt.js";var Yt=(function(){var e=g(function(z,_,x,b){for(x=x||{},b=z.length;b--;x[z[b]]=_);return x},"o"),t=[1,24],r=[1,25],h=[1,26],l=[1,27],a=[1,28],s=[1,63],i=[1,64],n=[1,65],d=[1,66],u=[1,67],y=[1,68],f=[1,69],E=[1,29],T=[1,30],v=[1,31],B=[1,32],X=[1,33],I=[1,34],q=[1,35],V=[1,36],G=[1,37],K=[1,38],J=[1,39],Z=[1,40],tt=[1,41],et=[1,42],at=[1,43],nt=[1,44],it=[1,45],st=[1,46],rt=[1,47],lt=[1,48],ot=[1,50],ct=[1,51],ht=[1,52],dt=[1,53],ut=[1,54],pt=[1,55],yt=[1,56],ft=[1,57],gt=[1,58],bt=[1,59],_t=[1,60],Ot=[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],Tt=[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],C=[1,83],A=[1,84],O=[1,85],k=[12,14,42],re=[12,14,33,42],Pt=[12,14,33,42,76,77,79,80],Et=[12,33],Qt=[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],$t={trace:g(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:g(function(z,_,x,b,w,o,P){var p=o.length-1;switch(w){case 3:b.setDirection("TB");break;case 4:b.setDirection("BT");break;case 5:b.setDirection("RL");break;case 6:b.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:b.setC4Type(o[p-3]);break;case 19:b.setTitle(o[p].substring(6)),this.$=o[p].substring(6);break;case 20:b.setAccDescription(o[p].substring(15)),this.$=o[p].substring(15);break;case 21:this.$=o[p].trim(),b.setTitle(this.$);break;case 22:case 23:this.$=o[p].trim(),b.setAccDescription(this.$);break;case 28:o[p].splice(2,0,"ENTERPRISE"),b.addPersonOrSystemBoundary(...o[p]),this.$=o[p];break;case 29:o[p].splice(2,0,"SYSTEM"),b.addPersonOrSystemBoundary(...o[p]),this.$=o[p];break;case 30:b.addPersonOrSystemBoundary(...o[p]),this.$=o[p];break;case 31:o[p].splice(2,0,"CONTAINER"),b.addContainerBoundary(...o[p]),this.$=o[p];break;case 32:b.addDeploymentNode("node",...o[p]),this.$=o[p];break;case 33:b.addDeploymentNode("nodeL",...o[p]),this.$=o[p];break;case 34:b.addDeploymentNode("nodeR",...o[p]),this.$=o[p];break;case 35:b.popBoundaryParseStack();break;case 39:b.addPersonOrSystem("person",...o[p]),this.$=o[p];break;case 40:b.addPersonOrSystem("external_person",...o[p]),this.$=o[p];break;case 41:b.addPersonOrSystem("system",...o[p]),this.$=o[p];break;case 42:b.addPersonOrSystem("system_db",...o[p]),this.$=o[p];break;case 43:b.addPersonOrSystem("system_queue",...o[p]),this.$=o[p];break;case 44:b.addPersonOrSystem("external_system",...o[p]),this.$=o[p];break;case 45:b.addPersonOrSystem("external_system_db",...o[p]),this.$=o[p];break;case 46:b.addPersonOrSystem("external_system_queue",...o[p]),this.$=o[p];break;case 47:b.addContainer("container",...o[p]),this.$=o[p];break;case 48:b.addContainer("container_db",...o[p]),this.$=o[p];break;case 49:b.addContainer("container_queue",...o[p]),this.$=o[p];break;case 50:b.addContainer("external_container",...o[p]),this.$=o[p];break;case 51:b.addContainer("external_container_db",...o[p]),this.$=o[p];break;case 52:b.addContainer("external_container_queue",...o[p]),this.$=o[p];break;case 53:b.addComponent("component",...o[p]),this.$=o[p];break;case 54:b.addComponent("component_db",...o[p]),this.$=o[p];break;case 55:b.addComponent("component_queue",...o[p]),this.$=o[p];break;case 56:b.addComponent("external_component",...o[p]),this.$=o[p];break;case 57:b.addComponent("external_component_db",...o[p]),this.$=o[p];break;case 58:b.addComponent("external_component_queue",...o[p]),this.$=o[p];break;case 60:b.addRel("rel",...o[p]),this.$=o[p];break;case 61:b.addRel("birel",...o[p]),this.$=o[p];break;case 62:b.addRel("rel_u",...o[p]),this.$=o[p];break;case 63:b.addRel("rel_d",...o[p]),this.$=o[p];break;case 64:b.addRel("rel_l",...o[p]),this.$=o[p];break;case 65:b.addRel("rel_r",...o[p]),this.$=o[p];break;case 66:b.addRel("rel_b",...o[p]),this.$=o[p];break;case 67:o[p].splice(0,1),b.addRel("rel",...o[p]),this.$=o[p];break;case 68:b.updateElStyle("update_el_style",...o[p]),this.$=o[p];break;case 69:b.updateRelStyle("update_rel_style",...o[p]),this.$=o[p];break;case 70:b.updateLayoutConfig("update_layout_config",...o[p]),this.$=o[p];break;case 71:this.$=[o[p]];break;case 72:o[p].unshift(o[p-1]),this.$=o[p];break;case 73:case 75:this.$=o[p].trim();break;case 74:let St={};St[o[p-1].trim()]=o[p].trim(),this.$=St;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:t,23:r,24:h,26:l,28:a,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{13:70,19:20,20:21,21:22,22:t,23:r,24:h,26:l,28:a,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{13:71,19:20,20:21,21:22,22:t,23:r,24:h,26:l,28:a,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{13:72,19:20,20:21,21:22,22:t,23:r,24:h,26:l,28:a,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{13:73,19:20,20:21,21:22,22:t,23:r,24:h,26:l,28:a,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{14:[1,74]},e(Ot,[2,13],{43:23,29:49,30:61,32:62,20:75,34:s,36:i,37:n,38:d,39:u,40:y,41:f,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t}),e(Ot,[2,14]),e(zt,[2,16],{12:[1,76]}),e(Ot,[2,36],{12:[1,77]}),e(Tt,[2,19]),e(Tt,[2,20]),{25:[1,78]},{27:[1,79]},e(Tt,[2,23]),{35:80,75:81,76:S,77:C,79:A,80:O},{35:86,75:81,76:S,77:C,79:A,80:O},{35:87,75:81,76:S,77:C,79:A,80:O},{35:88,75:81,76:S,77:C,79:A,80:O},{35:89,75:81,76:S,77:C,79:A,80:O},{35:90,75:81,76:S,77:C,79:A,80:O},{35:91,75:81,76:S,77:C,79:A,80:O},{35:92,75:81,76:S,77:C,79:A,80:O},{35:93,75:81,76:S,77:C,79:A,80:O},{35:94,75:81,76:S,77:C,79:A,80:O},{35:95,75:81,76:S,77:C,79:A,80:O},{35:96,75:81,76:S,77:C,79:A,80:O},{35:97,75:81,76:S,77:C,79:A,80:O},{35:98,75:81,76:S,77:C,79:A,80:O},{35:99,75:81,76:S,77:C,79:A,80:O},{35:100,75:81,76:S,77:C,79:A,80:O},{35:101,75:81,76:S,77:C,79:A,80:O},{35:102,75:81,76:S,77:C,79:A,80:O},{35:103,75:81,76:S,77:C,79:A,80:O},{35:104,75:81,76:S,77:C,79:A,80:O},e(k,[2,59]),{35:105,75:81,76:S,77:C,79:A,80:O},{35:106,75:81,76:S,77:C,79:A,80:O},{35:107,75:81,76:S,77:C,79:A,80:O},{35:108,75:81,76:S,77:C,79:A,80:O},{35:109,75:81,76:S,77:C,79:A,80:O},{35:110,75:81,76:S,77:C,79:A,80:O},{35:111,75:81,76:S,77:C,79:A,80:O},{35:112,75:81,76:S,77:C,79:A,80:O},{35:113,75:81,76:S,77:C,79:A,80:O},{35:114,75:81,76:S,77:C,79:A,80:O},{35:115,75:81,76:S,77:C,79:A,80:O},{20:116,29:49,30:61,32:62,34:s,36:i,37:n,38:d,39:u,40:y,41:f,43:23,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t},{12:[1,118],33:[1,117]},{35:119,75:81,76:S,77:C,79:A,80:O},{35:120,75:81,76:S,77:C,79:A,80:O},{35:121,75:81,76:S,77:C,79:A,80:O},{35:122,75:81,76:S,77:C,79:A,80:O},{35:123,75:81,76:S,77:C,79:A,80:O},{35:124,75:81,76:S,77:C,79:A,80:O},{35:125,75:81,76:S,77:C,79:A,80:O},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},e(Ot,[2,15]),e(zt,[2,17],{21:22,19:130,22:t,23:r,24:h,26:l,28:a}),e(Ot,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:t,23:r,24:h,26:l,28:a,34:s,36:i,37:n,38:d,39:u,40:y,41:f,44:E,45:T,46:v,47:B,48:X,49:I,50:q,51:V,52:G,53:K,54:J,55:Z,56:tt,57:et,58:at,59:nt,60:it,61:st,62:rt,63:lt,64:ot,65:ct,66:ht,67:dt,68:ut,69:pt,70:yt,71:ft,72:gt,73:bt,74:_t}),e(Tt,[2,21]),e(Tt,[2,22]),e(k,[2,39]),e(re,[2,71],{75:81,35:132,76:S,77:C,79:A,80:O}),e(Pt,[2,73]),{78:[1,133]},e(Pt,[2,75]),e(Pt,[2,76]),e(k,[2,40]),e(k,[2,41]),e(k,[2,42]),e(k,[2,43]),e(k,[2,44]),e(k,[2,45]),e(k,[2,46]),e(k,[2,47]),e(k,[2,48]),e(k,[2,49]),e(k,[2,50]),e(k,[2,51]),e(k,[2,52]),e(k,[2,53]),e(k,[2,54]),e(k,[2,55]),e(k,[2,56]),e(k,[2,57]),e(k,[2,58]),e(k,[2,60]),e(k,[2,61]),e(k,[2,62]),e(k,[2,63]),e(k,[2,64]),e(k,[2,65]),e(k,[2,66]),e(k,[2,67]),e(k,[2,68]),e(k,[2,69]),e(k,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},e(Et,[2,28]),e(Et,[2,29]),e(Et,[2,30]),e(Et,[2,31]),e(Et,[2,32]),e(Et,[2,33]),e(Et,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},e(zt,[2,18]),e(Ot,[2,38]),e(re,[2,72]),e(Pt,[2,74]),e(k,[2,24]),e(k,[2,35]),e(Qt,[2,25]),e(Qt,[2,26],{12:[1,138]}),e(Qt,[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:g(function(z,_){if(_.recoverable)this.trace(z);else{var x=new Error(z);throw x.hash=_,x}},"parseError"),parse:g(function(z){var _=this,x=[0],b=[],w=[null],o=[],P=this.table,p="",St=0,le=0,Oe=2,oe=1,ke=o.slice.call(arguments,1),R=Object.create(this.lexer),Ct={yy:{}};for(var Wt in this.yy)Object.prototype.hasOwnProperty.call(this.yy,Wt)&&(Ct.yy[Wt]=this.yy[Wt]);R.setInput(z,Ct.yy),Ct.yy.lexer=R,Ct.yy.parser=this,typeof R.yylloc>"u"&&(R.yylloc={});var Ht=R.yylloc;o.push(Ht);var we=R.options&&R.options.ranges;typeof Ct.yy.parseError=="function"?this.parseError=Ct.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Te(M){x.length=x.length-2*M,w.length=w.length-M,o.length=o.length-M}g(Te,"popStack");function ce(){var M;return M=b.pop()||R.lex()||oe,typeof M!="number"&&(M instanceof Array&&(b=M,M=b.pop()),M=_.symbols_[M]||M),M}g(ce,"lex");for(var N,At,j,qt,kt={},Bt,W,he,Mt;;){if(At=x[x.length-1],this.defaultActions[At]?j=this.defaultActions[At]:((N===null||typeof N>"u")&&(N=ce()),j=P[At]&&P[At][N]),typeof j>"u"||!j.length||!j[0]){var Vt="";Mt=[];for(Bt in P[At])this.terminals_[Bt]&&Bt>Oe&&Mt.push("'"+this.terminals_[Bt]+"'");R.showPosition?Vt="Parse error on line "+(St+1)+`:
2
+ `+R.showPosition()+`
3
+ Expecting `+Mt.join(", ")+", got '"+(this.terminals_[N]||N)+"'":Vt="Parse error on line "+(St+1)+": Unexpected "+(N==oe?"end of input":"'"+(this.terminals_[N]||N)+"'"),this.parseError(Vt,{text:R.match,token:this.terminals_[N]||N,line:R.yylineno,loc:Ht,expected:Mt})}if(j[0]instanceof Array&&j.length>1)throw new Error("Parse Error: multiple actions possible at state: "+At+", token: "+N);switch(j[0]){case 1:x.push(N),w.push(R.yytext),o.push(R.yylloc),x.push(j[1]),N=null,le=R.yyleng,p=R.yytext,St=R.yylineno,Ht=R.yylloc;break;case 2:if(W=this.productions_[j[1]][1],kt.$=w[w.length-W],kt._$={first_line:o[o.length-(W||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(W||1)].first_column,last_column:o[o.length-1].last_column},we&&(kt._$.range=[o[o.length-(W||1)].range[0],o[o.length-1].range[1]]),qt=this.performAction.apply(kt,[p,le,St,Ct.yy,j[1],w,o].concat(ke)),typeof qt<"u")return qt;W&&(x=x.slice(0,-1*W*2),w=w.slice(0,-1*W),o=o.slice(0,-1*W)),x.push(this.productions_[j[1]][0]),w.push(kt.$),o.push(kt._$),he=P[x[x.length-2]][x[x.length-1]],x.push(he);break;case 3:return!0}}return!0},"parse")},Ae=(function(){var z={EOF:1,parseError:g(function(_,x){if(this.yy.parser)this.yy.parser.parseError(_,x);else throw new Error(_)},"parseError"),setInput:g(function(_,x){return this.yy=x||this.yy||{},this._input=_,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:g(function(){var _=this._input[0];this.yytext+=_,this.yyleng++,this.offset++,this.match+=_,this.matched+=_;var x=_.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),_},"input"),unput:g(function(_){var x=_.length,b=_.split(/(?:\r\n?|\n)/g);this._input=_+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-x),this.offset-=x;var w=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),b.length-1&&(this.yylineno-=b.length-1);var o=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:b?(b.length===w.length?this.yylloc.first_column:0)+w[w.length-b.length].length-b[0].length:this.yylloc.first_column-x},this.options.ranges&&(this.yylloc.range=[o[0],o[0]+this.yyleng-x]),this.yyleng=this.yytext.length,this},"unput"),more:g(function(){return this._more=!0,this},"more"),reject:g(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:g(function(_){this.unput(this.match.slice(_))},"less"),pastInput:g(function(){var _=this.matched.substr(0,this.matched.length-this.match.length);return(_.length>20?"...":"")+_.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:g(function(){var _=this.match;return _.length<20&&(_+=this._input.substr(0,20-_.length)),(_.substr(0,20)+(_.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:g(function(){var _=this.pastInput(),x=new Array(_.length+1).join("-");return _+this.upcomingInput()+`
5
+ `+x+"^"},"showPosition"),test_match:g(function(_,x){var b,w,o;if(this.options.backtrack_lexer&&(o={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&&(o.yylloc.range=this.yylloc.range.slice(0))),w=_[0].match(/(?:\r\n?|\n).*/g),w&&(this.yylineno+=w.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:w?w[w.length-1].length-w[w.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+_[0].length},this.yytext+=_[0],this.match+=_[0],this.matches=_,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(_[0].length),this.matched+=_[0],b=this.performAction.call(this,this.yy,this,x,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),b)return b;if(this._backtrack){for(var P in o)this[P]=o[P];return!1}return!1},"test_match"),next:g(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var _,x,b,w;this._more||(this.yytext="",this.match="");for(var o=this._currentRules(),P=0;P<o.length;P++)if(b=this._input.match(this.rules[o[P]]),b&&(!x||b[0].length>x[0].length)){if(x=b,w=P,this.options.backtrack_lexer){if(_=this.test_match(b,o[P]),_!==!1)return _;if(this._backtrack){x=!1;continue}else return!1}else if(!this.options.flex)break}return x?(_=this.test_match(x,o[w]),_!==!1?_:!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:g(function(){var _=this.next();return _||this.lex()},"lex"),begin:g(function(_){this.conditionStack.push(_)},"begin"),popState:g(function(){var _=this.conditionStack.length-1;return _>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:g(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:g(function(_){return _=this.conditionStack.length-1-Math.abs(_||0),_>=0?this.conditionStack[_]:"INITIAL"},"topState"),pushState:g(function(_){this.begin(_)},"pushState"),stateStackSize:g(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:g(function(_,x,b,w){switch(b){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:[],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 z})();$t.lexer=Ae;function Nt(){this.yy={}}return g(Nt,"Parser"),Nt.prototype=$t,$t.Parser=Nt,new Nt})();Yt.parser=Yt;var Ie=Yt,F=[],mt=[""],D="global",U="",$=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],Dt=[],ae="",ne=!1,It=4,Ut=2,ge,Ue=g(function(){return ge},"getC4Type"),Fe=g(function(e){ge=fe(e,Rt())},"setC4Type"),Xe=g(function(e,t,r,h,l,a,s,i,n){if(e==null||t===void 0||t===null||r===void 0||r===null||h===void 0||h===null)return;let d={};const u=Dt.find(y=>y.from===t&&y.to===r);if(u?d=u:Dt.push(d),d.type=e,d.from=t,d.to=r,d.label={text:h},l==null)d.techn={text:""};else if(typeof l=="object"){let[y,f]=Object.entries(l)[0];d[y]={text:f}}else d.techn={text:l};if(a==null)d.descr={text:""};else if(typeof a=="object"){let[y,f]=Object.entries(a)[0];d[y]={text:f}}else d.descr={text:a};if(typeof s=="object"){let[y,f]=Object.entries(s)[0];d[y]=f}else d.sprite=s;if(typeof i=="object"){let[y,f]=Object.entries(i)[0];d[y]=f}else d.tags=i;if(typeof n=="object"){let[y,f]=Object.entries(n)[0];d[y]=f}else d.link=n;d.wrap=xt()},"addRel"),ze=g(function(e,t,r,h,l,a,s){if(t===null||r===null)return;let i={};const n=F.find(d=>d.alias===t);if(n&&t===n.alias?i=n:(i.alias=t,F.push(i)),r==null?i.label={text:""}:i.label={text:r},h==null)i.descr={text:""};else if(typeof h=="object"){let[d,u]=Object.entries(h)[0];i[d]={text:u}}else i.descr={text:h};if(typeof l=="object"){let[d,u]=Object.entries(l)[0];i[d]=u}else i.sprite=l;if(typeof a=="object"){let[d,u]=Object.entries(a)[0];i[d]=u}else i.tags=a;if(typeof s=="object"){let[d,u]=Object.entries(s)[0];i[d]=u}else i.link=s;i.typeC4Shape={text:e},i.parentBoundary=D,i.wrap=xt()},"addPersonOrSystem"),Qe=g(function(e,t,r,h,l,a,s,i){if(t===null||r===null)return;let n={};const d=F.find(u=>u.alias===t);if(d&&t===d.alias?n=d:(n.alias=t,F.push(n)),r==null?n.label={text:""}:n.label={text:r},h==null)n.techn={text:""};else if(typeof h=="object"){let[u,y]=Object.entries(h)[0];n[u]={text:y}}else n.techn={text:h};if(l==null)n.descr={text:""};else if(typeof l=="object"){let[u,y]=Object.entries(l)[0];n[u]={text:y}}else n.descr={text:l};if(typeof a=="object"){let[u,y]=Object.entries(a)[0];n[u]=y}else n.sprite=a;if(typeof s=="object"){let[u,y]=Object.entries(s)[0];n[u]=y}else n.tags=s;if(typeof i=="object"){let[u,y]=Object.entries(i)[0];n[u]=y}else n.link=i;n.wrap=xt(),n.typeC4Shape={text:e},n.parentBoundary=D},"addContainer"),$e=g(function(e,t,r,h,l,a,s,i){if(t===null||r===null)return;let n={};const d=F.find(u=>u.alias===t);if(d&&t===d.alias?n=d:(n.alias=t,F.push(n)),r==null?n.label={text:""}:n.label={text:r},h==null)n.techn={text:""};else if(typeof h=="object"){let[u,y]=Object.entries(h)[0];n[u]={text:y}}else n.techn={text:h};if(l==null)n.descr={text:""};else if(typeof l=="object"){let[u,y]=Object.entries(l)[0];n[u]={text:y}}else n.descr={text:l};if(typeof a=="object"){let[u,y]=Object.entries(a)[0];n[u]=y}else n.sprite=a;if(typeof s=="object"){let[u,y]=Object.entries(s)[0];n[u]=y}else n.tags=s;if(typeof i=="object"){let[u,y]=Object.entries(i)[0];n[u]=y}else n.link=i;n.wrap=xt(),n.typeC4Shape={text:e},n.parentBoundary=D},"addComponent"),We=g(function(e,t,r,h,l){if(e===null||t===null)return;let a={};const s=$.find(i=>i.alias===e);if(s&&e===s.alias?a=s:(a.alias=e,$.push(a)),t==null?a.label={text:""}:a.label={text:t},r==null)a.type={text:"system"};else if(typeof r=="object"){let[i,n]=Object.entries(r)[0];a[i]={text:n}}else a.type={text:r};if(typeof h=="object"){let[i,n]=Object.entries(h)[0];a[i]=n}else a.tags=h;if(typeof l=="object"){let[i,n]=Object.entries(l)[0];a[i]=n}else a.link=l;a.parentBoundary=D,a.wrap=xt(),U=D,D=e,mt.push(U)},"addPersonOrSystemBoundary"),He=g(function(e,t,r,h,l){if(e===null||t===null)return;let a={};const s=$.find(i=>i.alias===e);if(s&&e===s.alias?a=s:(a.alias=e,$.push(a)),t==null?a.label={text:""}:a.label={text:t},r==null)a.type={text:"container"};else if(typeof r=="object"){let[i,n]=Object.entries(r)[0];a[i]={text:n}}else a.type={text:r};if(typeof h=="object"){let[i,n]=Object.entries(h)[0];a[i]=n}else a.tags=h;if(typeof l=="object"){let[i,n]=Object.entries(l)[0];a[i]=n}else a.link=l;a.parentBoundary=D,a.wrap=xt(),U=D,D=e,mt.push(U)},"addContainerBoundary"),qe=g(function(e,t,r,h,l,a,s,i){if(t===null||r===null)return;let n={};const d=$.find(u=>u.alias===t);if(d&&t===d.alias?n=d:(n.alias=t,$.push(n)),r==null?n.label={text:""}:n.label={text:r},h==null)n.type={text:"node"};else if(typeof h=="object"){let[u,y]=Object.entries(h)[0];n[u]={text:y}}else n.type={text:h};if(l==null)n.descr={text:""};else if(typeof l=="object"){let[u,y]=Object.entries(l)[0];n[u]={text:y}}else n.descr={text:l};if(typeof s=="object"){let[u,y]=Object.entries(s)[0];n[u]=y}else n.tags=s;if(typeof i=="object"){let[u,y]=Object.entries(i)[0];n[u]=y}else n.link=i;n.nodeType=e,n.parentBoundary=D,n.wrap=xt(),U=D,D=t,mt.push(U)},"addDeploymentNode"),Ve=g(function(){D=U,mt.pop(),U=mt.pop(),mt.push(U)},"popBoundaryParseStack"),Ge=g(function(e,t,r,h,l,a,s,i,n,d,u){let y=F.find(f=>f.alias===t);if(!(y===void 0&&(y=$.find(f=>f.alias===t),y===void 0))){if(r!=null)if(typeof r=="object"){let[f,E]=Object.entries(r)[0];y[f]=E}else y.bgColor=r;if(h!=null)if(typeof h=="object"){let[f,E]=Object.entries(h)[0];y[f]=E}else y.fontColor=h;if(l!=null)if(typeof l=="object"){let[f,E]=Object.entries(l)[0];y[f]=E}else y.borderColor=l;if(a!=null)if(typeof a=="object"){let[f,E]=Object.entries(a)[0];y[f]=E}else y.shadowing=a;if(s!=null)if(typeof s=="object"){let[f,E]=Object.entries(s)[0];y[f]=E}else y.shape=s;if(i!=null)if(typeof i=="object"){let[f,E]=Object.entries(i)[0];y[f]=E}else y.sprite=i;if(n!=null)if(typeof n=="object"){let[f,E]=Object.entries(n)[0];y[f]=E}else y.techn=n;if(d!=null)if(typeof d=="object"){let[f,E]=Object.entries(d)[0];y[f]=E}else y.legendText=d;if(u!=null)if(typeof u=="object"){let[f,E]=Object.entries(u)[0];y[f]=E}else y.legendSprite=u}},"updateElStyle"),Ke=g(function(e,t,r,h,l,a,s){const i=Dt.find(n=>n.from===t&&n.to===r);if(i!==void 0){if(h!=null)if(typeof h=="object"){let[n,d]=Object.entries(h)[0];i[n]=d}else i.textColor=h;if(l!=null)if(typeof l=="object"){let[n,d]=Object.entries(l)[0];i[n]=d}else i.lineColor=l;if(a!=null)if(typeof a=="object"){let[n,d]=Object.entries(a)[0];i[n]=parseInt(d)}else i.offsetX=parseInt(a);if(s!=null)if(typeof s=="object"){let[n,d]=Object.entries(s)[0];i[n]=parseInt(d)}else i.offsetY=parseInt(s)}},"updateRelStyle"),Je=g(function(e,t,r){let h=It,l=Ut;if(typeof t=="object"){const a=Object.values(t)[0];h=parseInt(a)}else h=parseInt(t);if(typeof r=="object"){const a=Object.values(r)[0];l=parseInt(a)}else l=parseInt(r);h>=1&&(It=h),l>=1&&(Ut=l)},"updateLayoutConfig"),Ze=g(function(){return It},"getC4ShapeInRow"),t0=g(function(){return Ut},"getC4BoundaryInRow"),e0=g(function(){return D},"getCurrentBoundaryParse"),a0=g(function(){return U},"getParentBoundaryParse"),be=g(function(e){return e==null?F:F.filter(t=>t.parentBoundary===e)},"getC4ShapeArray"),n0=g(function(e){return F.find(t=>t.alias===e)},"getC4Shape"),i0=g(function(e){return Object.keys(be(e))},"getC4ShapeKeys"),_e=g(function(e){return e==null?$:$.filter(t=>t.parentBoundary===e)},"getBoundaries"),s0=_e,r0=g(function(){return Dt},"getRels"),l0=g(function(){return ae},"getTitle"),o0=g(function(e){ne=e},"setWrap"),xt=g(function(){return ne},"autoWrap"),c0=g(function(){F=[],$=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],U="",D="global",mt=[""],Dt=[],mt=[""],ae="",ne=!1,It=4,Ut=2},"clear"),h0={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},d0={FILLED:0,OPEN:1},u0={LEFTOF:0,RIGHTOF:1,OVER:2},p0=g(function(e){ae=fe(e,Rt())},"setTitle"),Zt={addPersonOrSystem:ze,addPersonOrSystemBoundary:We,addContainer:Qe,addContainerBoundary:He,addComponent:$e,addDeploymentNode:qe,popBoundaryParseStack:Ve,addRel:Xe,updateElStyle:Ge,updateRelStyle:Ke,updateLayoutConfig:Je,autoWrap:xt,setWrap:o0,getC4ShapeArray:be,getC4Shape:n0,getC4ShapeKeys:i0,getBoundaries:_e,getBoundarys:s0,getCurrentBoundaryParse:e0,getParentBoundaryParse:a0,getRels:r0,getTitle:l0,getC4Type:Ue,getC4ShapeInRow:Ze,getC4BoundaryInRow:t0,setAccTitle:Be,getAccTitle:Ne,getAccDescription:Pe,setAccDescription:De,getConfig:g(()=>Rt().c4,"getConfig"),clear:c0,LINETYPE:h0,ARROWTYPE:d0,PLACEMENT:u0,setTitle:p0,setC4Type:Fe},ie=g(function(e,t){return Re(e,t)},"drawRect"),me=g(function(e,t,r,h,l,a){const s=e.append("image");s.attr("width",t),s.attr("height",r),s.attr("x",h),s.attr("y",l);let i=a.startsWith("data:image/png;base64")?a:Le.sanitizeUrl(a);s.attr("xlink:href",i)},"drawImage"),y0=g((e,t,r)=>{const h=e.append("g");let l=0;for(let a of t){let s=a.textColor?a.textColor:"#444444",i=a.lineColor?a.lineColor:"#444444",n=a.offsetX?parseInt(a.offsetX):0,d=a.offsetY?parseInt(a.offsetY):0,u="";if(l===0){let f=h.append("line");f.attr("x1",a.startPoint.x),f.attr("y1",a.startPoint.y),f.attr("x2",a.endPoint.x),f.attr("y2",a.endPoint.y),f.attr("stroke-width","1"),f.attr("stroke",i),f.style("fill","none"),a.type!=="rel_b"&&f.attr("marker-end","url("+u+"#arrowhead)"),(a.type==="birel"||a.type==="rel_b")&&f.attr("marker-start","url("+u+"#arrowend)"),l=-1}else{let f=h.append("path");f.attr("fill","none").attr("stroke-width","1").attr("stroke",i).attr("d","Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx",a.startPoint.x).replaceAll("starty",a.startPoint.y).replaceAll("controlx",a.startPoint.x+(a.endPoint.x-a.startPoint.x)/2-(a.endPoint.x-a.startPoint.x)/4).replaceAll("controly",a.startPoint.y+(a.endPoint.y-a.startPoint.y)/2).replaceAll("stopx",a.endPoint.x).replaceAll("stopy",a.endPoint.y)),a.type!=="rel_b"&&f.attr("marker-end","url("+u+"#arrowhead)"),(a.type==="birel"||a.type==="rel_b")&&f.attr("marker-start","url("+u+"#arrowend)")}let y=r.messageFont();H(r)(a.label.text,h,Math.min(a.startPoint.x,a.endPoint.x)+Math.abs(a.endPoint.x-a.startPoint.x)/2+n,Math.min(a.startPoint.y,a.endPoint.y)+Math.abs(a.endPoint.y-a.startPoint.y)/2+d,a.label.width,a.label.height,{fill:s},y),a.techn&&a.techn.text!==""&&(y=r.messageFont(),H(r)("["+a.techn.text+"]",h,Math.min(a.startPoint.x,a.endPoint.x)+Math.abs(a.endPoint.x-a.startPoint.x)/2+n,Math.min(a.startPoint.y,a.endPoint.y)+Math.abs(a.endPoint.y-a.startPoint.y)/2+r.messageFontSize+5+d,Math.max(a.label.width,a.techn.width),a.techn.height,{fill:s,"font-style":"italic"},y))}},"drawRels"),f0=g(function(e,t,r){const h=e.append("g");let l=t.bgColor?t.bgColor:"none",a=t.borderColor?t.borderColor:"#444444",s=t.fontColor?t.fontColor:"black",i={"stroke-width":1,"stroke-dasharray":"7.0,7.0"};t.nodeType&&(i={"stroke-width":1});let n={x:t.x,y:t.y,fill:l,stroke:a,width:t.width,height:t.height,rx:2.5,ry:2.5,attrs:i};ie(h,n);let d=r.boundaryFont();d.fontWeight="bold",d.fontSize=d.fontSize+2,d.fontColor=s,H(r)(t.label.text,h,t.x,t.y+t.label.Y,t.width,t.height,{fill:"#444444"},d),t.type&&t.type.text!==""&&(d=r.boundaryFont(),d.fontColor=s,H(r)(t.type.text,h,t.x,t.y+t.type.Y,t.width,t.height,{fill:"#444444"},d)),t.descr&&t.descr.text!==""&&(d=r.boundaryFont(),d.fontSize=d.fontSize-2,d.fontColor=s,H(r)(t.descr.text,h,t.x,t.y+t.descr.Y,t.width,t.height,{fill:"#444444"},d))},"drawBoundary"),g0=g(function(e,t,r){let h=t.bgColor?t.bgColor:r[t.typeC4Shape.text+"_bg_color"],l=t.borderColor?t.borderColor:r[t.typeC4Shape.text+"_border_color"],a=t.fontColor?t.fontColor:"#FFFFFF",s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";switch(t.typeC4Shape.text){case"person":s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";break;case"external_person":s="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAAB6ElEQVR4Xu2YLY+EMBCG9+dWr0aj0Wg0Go1Go0+j8Xdv2uTCvv1gpt0ebHKPuhDaeW4605Z9mJvx4AdXUyTUdd08z+u6flmWZRnHsWkafk9DptAwDPu+f0eAYtu2PEaGWuj5fCIZrBAC2eLBAnRCsEkkxmeaJp7iDJ2QMDdHsLg8SxKFEJaAo8lAXnmuOFIhTMpxxKATebo4UiFknuNo4OniSIXQyRxEA3YsnjGCVEjVXD7yLUAqxBGUyPv/Y4W2beMgGuS7kVQIBycH0fD+oi5pezQETxdHKmQKGk1eQEYldK+jw5GxPfZ9z7Mk0Qnhf1W1m3w//EUn5BDmSZsbR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII=";break}const i=e.append("g");i.attr("class","person-man");const n=ve();switch(t.typeC4Shape.text){case"person":case"external_person":case"system":case"external_system":case"container":case"external_container":case"component":case"external_component":n.x=t.x,n.y=t.y,n.fill=h,n.width=t.width,n.height=t.height,n.stroke=l,n.rx=2.5,n.ry=2.5,n.attrs={"stroke-width":.5},ie(i,n);break;case"system_db":case"external_system_db":case"container_db":case"external_container_db":case"component_db":case"external_component_db":i.append("path").attr("fill",h).attr("stroke-width","0.5").attr("stroke",l).attr("d","Mstartx,startyc0,-10 half,-10 half,-10c0,0 half,0 half,10l0,heightc0,10 -half,10 -half,10c0,0 -half,0 -half,-10l0,-height".replaceAll("startx",t.x).replaceAll("starty",t.y).replaceAll("half",t.width/2).replaceAll("height",t.height)),i.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",l).attr("d","Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10".replaceAll("startx",t.x).replaceAll("starty",t.y).replaceAll("half",t.width/2));break;case"system_queue":case"external_system_queue":case"container_queue":case"external_container_queue":case"component_queue":case"external_component_queue":i.append("path").attr("fill",h).attr("stroke-width","0.5").attr("stroke",l).attr("d","Mstartx,startylwidth,0c5,0 5,half 5,halfc0,0 0,half -5,halfl-width,0c-5,0 -5,-half -5,-halfc0,0 0,-half 5,-half".replaceAll("startx",t.x).replaceAll("starty",t.y).replaceAll("width",t.width).replaceAll("half",t.height/2)),i.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",l).attr("d","Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half".replaceAll("startx",t.x+t.width).replaceAll("starty",t.y).replaceAll("half",t.height/2));break}let d=O0(r,t.typeC4Shape.text);switch(i.append("text").attr("fill",a).attr("font-family",d.fontFamily).attr("font-size",d.fontSize-2).attr("font-style","italic").attr("lengthAdjust","spacing").attr("textLength",t.typeC4Shape.width).attr("x",t.x+t.width/2-t.typeC4Shape.width/2).attr("y",t.y+t.typeC4Shape.Y).text("<<"+t.typeC4Shape.text+">>"),t.typeC4Shape.text){case"person":case"external_person":me(i,48,48,t.x+t.width/2-24,t.y+t.image.Y,s);break}let u=r[t.typeC4Shape.text+"Font"]();return u.fontWeight="bold",u.fontSize=u.fontSize+2,u.fontColor=a,H(r)(t.label.text,i,t.x,t.y+t.label.Y,t.width,t.height,{fill:a},u),u=r[t.typeC4Shape.text+"Font"](),u.fontColor=a,t.techn&&t.techn?.text!==""?H(r)(t.techn.text,i,t.x,t.y+t.techn.Y,t.width,t.height,{fill:a,"font-style":"italic"},u):t.type&&t.type.text!==""&&H(r)(t.type.text,i,t.x,t.y+t.type.Y,t.width,t.height,{fill:a,"font-style":"italic"},u),t.descr&&t.descr.text!==""&&(u=r.personFont(),u.fontColor=a,H(r)(t.descr.text,i,t.x,t.y+t.descr.Y,t.width,t.height,{fill:a},u)),t.height},"drawC4Shape"),b0=g(function(e){e.append("defs").append("symbol").attr("id","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"),_0=g(function(e){e.append("defs").append("symbol").attr("id","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"),m0=g(function(e){e.append("defs").append("symbol").attr("id","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"),x0=g(function(e){e.append("defs").append("marker").attr("id","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"),E0=g(function(e){e.append("defs").append("marker").attr("id","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"),S0=g(function(e){e.append("defs").append("marker").attr("id","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=g(function(e){e.append("defs").append("marker").attr("id","sequencenumber").attr("refX",15).attr("refY",15).attr("markerWidth",60).attr("markerHeight",40).attr("orient","auto").append("circle").attr("cx",15).attr("cy",15).attr("r",6)},"insertDynamicNumber"),A0=g(function(e){const t=e.append("defs").append("marker").attr("id","crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);t.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"),t.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"),O0=g((e,t)=>({fontFamily:e[t+"FontFamily"],fontSize:e[t+"FontSize"],fontWeight:e[t+"FontWeight"]}),"getC4ShapeFont"),H=(function(){function e(l,a,s,i,n,d,u){const y=a.append("text").attr("x",s+n/2).attr("y",i+d/2+5).style("text-anchor","middle").text(l);h(y,u)}g(e,"byText");function t(l,a,s,i,n,d,u,y){const{fontSize:f,fontFamily:E,fontWeight:T}=y,v=l.split(Jt.lineBreakRegex);for(let B=0;B<v.length;B++){const X=B*f-f*(v.length-1)/2,I=a.append("text").attr("x",s+n/2).attr("y",i).style("text-anchor","middle").attr("dominant-baseline","middle").style("font-size",f).style("font-weight",T).style("font-family",E);I.append("tspan").attr("dy",X).text(v[B]).attr("alignment-baseline","mathematical"),h(I,u)}}g(t,"byTspan");function r(l,a,s,i,n,d,u,y){const f=a.append("switch"),E=f.append("foreignObject").attr("x",s).attr("y",i).attr("width",n).attr("height",d).append("xhtml:div").style("display","table").style("height","100%").style("width","100%");E.append("div").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(l),t(l,f,s,i,n,d,u,y),h(E,u)}g(r,"byFo");function h(l,a){for(const s in a)a.hasOwnProperty(s)&&l.attr(s,a[s])}return g(h,"_setTextAttrs"),function(l){return l.textPlacement==="fo"?r:l.textPlacement==="old"?e:t}})(),Q={drawRect:ie,drawBoundary:f0,drawC4Shape:g0,drawRels:y0,drawImage:me,insertArrowHead:x0,insertArrowEnd:E0,insertArrowFilledHead:S0,insertDynamicNumber:C0,insertArrowCrossHead:A0,insertDatabaseIcon:b0,insertComputerIcon:_0,insertClockIcon:m0},Ft=0,Xt=0,xe=4,te=2;Yt.yy=Zt;var m={},Gt,Ee=(Gt=class{constructor(e){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(e.db.getConfig())}setData(e,t,r,h){this.nextData.startx=this.data.startx=e,this.nextData.stopx=this.data.stopx=t,this.nextData.starty=this.data.starty=r,this.nextData.stopy=this.data.stopy=h}updateVal(e,t,r,h){e[t]===void 0?e[t]=r:e[t]=h(r,e[t])}insert(e){this.nextData.cnt=this.nextData.cnt+1;let t=this.nextData.startx===this.nextData.stopx?this.nextData.stopx+e.margin:this.nextData.stopx+e.margin*2,r=t+e.width,h=this.nextData.starty+e.margin*2,l=h+e.height;(t>=this.data.widthLimit||r>=this.data.widthLimit||this.nextData.cnt>xe)&&(t=this.nextData.startx+e.margin+m.nextLinePaddingX,h=this.nextData.stopy+e.margin*2,this.nextData.stopx=r=t+e.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=l=h+e.height,this.nextData.cnt=1),e.x=t,e.y=h,this.updateVal(this.data,"startx",t,Math.min),this.updateVal(this.data,"starty",h,Math.min),this.updateVal(this.data,"stopx",r,Math.max),this.updateVal(this.data,"stopy",l,Math.max),this.updateVal(this.nextData,"startx",t,Math.min),this.updateVal(this.nextData,"starty",h,Math.min),this.updateVal(this.nextData,"stopx",r,Math.max),this.updateVal(this.nextData,"stopy",l,Math.max)}init(e){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(e.db.getConfig())}bumpLastMargin(e){this.data.stopx+=e,this.data.stopy+=e}},g(Gt,"Bounds"),Gt),ee=g(function(e){je(m,e),e.fontFamily&&(m.personFontFamily=m.systemFontFamily=m.messageFontFamily=e.fontFamily),e.fontSize&&(m.personFontSize=m.systemFontSize=m.messageFontSize=e.fontSize),e.fontWeight&&(m.personFontWeight=m.systemFontWeight=m.messageFontWeight=e.fontWeight)},"setConf"),vt=g((e,t)=>({fontFamily:e[t+"FontFamily"],fontSize:e[t+"FontSize"],fontWeight:e[t+"FontWeight"]}),"c4ShapeFont"),Lt=g(e=>({fontFamily:e.boundaryFontFamily,fontSize:e.boundaryFontSize,fontWeight:e.boundaryFontWeight}),"boundaryFont"),k0=g(e=>({fontFamily:e.messageFontFamily,fontSize:e.messageFontSize,fontWeight:e.messageFontWeight}),"messageFont");function Y(e,t,r,h,l){if(!t[e].width)if(r)t[e].text=Ye(t[e].text,l,h),t[e].textLines=t[e].text.split(Jt.lineBreakRegex).length,t[e].width=l,t[e].height=ue(t[e].text,h);else{let a=t[e].text.split(Jt.lineBreakRegex);t[e].textLines=a.length;let s=0;t[e].height=0,t[e].width=0;for(const i of a)t[e].width=Math.max(wt(i,h),t[e].width),s=ue(i,h),t[e].height=t[e].height+s}}g(Y,"calcC4ShapeTextWH");var Se=g(function(e,t,r){t.x=r.data.startx,t.y=r.data.starty,t.width=r.data.stopx-r.data.startx,t.height=r.data.stopy-r.data.starty,t.label.y=m.c4ShapeMargin-35;let h=t.wrap&&m.wrap,l=Lt(m);l.fontSize=l.fontSize+2,l.fontWeight="bold";let a=wt(t.label.text,l);Y("label",t,h,l,a),Q.drawBoundary(e,t,m)},"drawBoundary"),Ce=g(function(e,t,r,h){let l=0;for(const a of h){l=0;const s=r[a];let i=vt(m,s.typeC4Shape.text);switch(i.fontSize=i.fontSize-2,s.typeC4Shape.width=wt("«"+s.typeC4Shape.text+"»",i),s.typeC4Shape.height=i.fontSize+2,s.typeC4Shape.Y=m.c4ShapePadding,l=s.typeC4Shape.Y+s.typeC4Shape.height-4,s.image={width:0,height:0,Y:0},s.typeC4Shape.text){case"person":case"external_person":s.image.width=48,s.image.height=48,s.image.Y=l,l=s.image.Y+s.image.height;break}s.sprite&&(s.image.width=48,s.image.height=48,s.image.Y=l,l=s.image.Y+s.image.height);let n=s.wrap&&m.wrap,d=m.width-m.c4ShapePadding*2,u=vt(m,s.typeC4Shape.text);if(u.fontSize=u.fontSize+2,u.fontWeight="bold",Y("label",s,n,u,d),s.label.Y=l+8,l=s.label.Y+s.label.height,s.type&&s.type.text!==""){s.type.text="["+s.type.text+"]";let E=vt(m,s.typeC4Shape.text);Y("type",s,n,E,d),s.type.Y=l+5,l=s.type.Y+s.type.height}else if(s.techn&&s.techn.text!==""){s.techn.text="["+s.techn.text+"]";let E=vt(m,s.techn.text);Y("techn",s,n,E,d),s.techn.Y=l+5,l=s.techn.Y+s.techn.height}let y=l,f=s.label.width;if(s.descr&&s.descr.text!==""){let E=vt(m,s.typeC4Shape.text);Y("descr",s,n,E,d),s.descr.Y=l+20,l=s.descr.Y+s.descr.height,f=Math.max(s.label.width,s.descr.width),y=l-s.descr.textLines*5}f=f+m.c4ShapePadding,s.width=Math.max(s.width||m.width,f,m.width),s.height=Math.max(s.height||m.height,y,m.height),s.margin=s.margin||m.c4ShapeMargin,e.insert(s),Q.drawC4Shape(t,s,m)}e.bumpLastMargin(m.c4ShapeMargin)},"drawC4ShapeArray"),Kt,L=(Kt=class{constructor(e,t){this.x=e,this.y=t}},g(Kt,"Point"),Kt),pe=g(function(e,t){let r=e.x,h=e.y,l=t.x,a=t.y,s=r+e.width/2,i=h+e.height/2,n=Math.abs(r-l),d=Math.abs(h-a),u=d/n,y=e.height/e.width,f=null;return h==a&&r<l?f=new L(r+e.width,i):h==a&&r>l?f=new L(r,i):r==l&&h<a?f=new L(s,h+e.height):r==l&&h>a&&(f=new L(s,h)),r>l&&h<a?y>=u?f=new L(r,i+u*e.width/2):f=new L(s-n/d*e.height/2,h+e.height):r<l&&h<a?y>=u?f=new L(r+e.width,i+u*e.width/2):f=new L(s+n/d*e.height/2,h+e.height):r<l&&h>a?y>=u?f=new L(r+e.width,i-u*e.width/2):f=new L(s+e.height/2*n/d,h):r>l&&h>a&&(y>=u?f=new L(r,i-e.width/2*u):f=new L(s-e.height/2*n/d,h)),f},"getIntersectPoint"),w0=g(function(e,t){let r={x:0,y:0};r.x=t.x+t.width/2,r.y=t.y+t.height/2;let h=pe(e,r);r.x=e.x+e.width/2,r.y=e.y+e.height/2;let l=pe(t,r);return{startPoint:h,endPoint:l}},"getIntersectPoints"),T0=g(function(e,t,r,h){let l=0;for(let a of t){l=l+1;let s=a.wrap&&m.wrap,i=k0(m);h.db.getC4Type()==="C4Dynamic"&&(a.label.text=l+": "+a.label.text);let n=wt(a.label.text,i);Y("label",a,s,i,n),a.techn&&a.techn.text!==""&&(n=wt(a.techn.text,i),Y("techn",a,s,i,n)),a.descr&&a.descr.text!==""&&(n=wt(a.descr.text,i),Y("descr",a,s,i,n));let d=r(a.from),u=r(a.to),y=w0(d,u);a.startPoint=y.startPoint,a.endPoint=y.endPoint}Q.drawRels(e,t,m)},"drawRels");function se(e,t,r,h,l){let a=new Ee(l);a.data.widthLimit=r.data.widthLimit/Math.min(te,h.length);for(let[s,i]of h.entries()){let n=0;i.image={width:0,height:0,Y:0},i.sprite&&(i.image.width=48,i.image.height=48,i.image.Y=n,n=i.image.Y+i.image.height);let d=i.wrap&&m.wrap,u=Lt(m);if(u.fontSize=u.fontSize+2,u.fontWeight="bold",Y("label",i,d,u,a.data.widthLimit),i.label.Y=n+8,n=i.label.Y+i.label.height,i.type&&i.type.text!==""){i.type.text="["+i.type.text+"]";let T=Lt(m);Y("type",i,d,T,a.data.widthLimit),i.type.Y=n+5,n=i.type.Y+i.type.height}if(i.descr&&i.descr.text!==""){let T=Lt(m);T.fontSize=T.fontSize-2,Y("descr",i,d,T,a.data.widthLimit),i.descr.Y=n+20,n=i.descr.Y+i.descr.height}if(s==0||s%te===0){let T=r.data.startx+m.diagramMarginX,v=r.data.stopy+m.diagramMarginY+n;a.setData(T,T,v,v)}else{let T=a.data.stopx!==a.data.startx?a.data.stopx+m.diagramMarginX:a.data.startx,v=a.data.starty;a.setData(T,T,v,v)}a.name=i.alias;let y=l.db.getC4ShapeArray(i.alias),f=l.db.getC4ShapeKeys(i.alias);f.length>0&&Ce(a,e,y,f),t=i.alias;let E=l.db.getBoundaries(t);E.length>0&&se(e,t,a,E,l),i.alias!=="global"&&Se(e,i,a),r.data.stopy=Math.max(a.data.stopy+m.c4ShapeMargin,r.data.stopy),r.data.stopx=Math.max(a.data.stopx+m.c4ShapeMargin,r.data.stopx),Ft=Math.max(Ft,r.data.stopx),Xt=Math.max(Xt,r.data.stopy)}}g(se,"drawInsideBoundary");var v0=g(function(e,t,r,h){m=Rt().c4;const l=Rt().securityLevel;let a;l==="sandbox"&&(a=jt("#i"+t));const s=l==="sandbox"?jt(a.nodes()[0].contentDocument.body):jt("body");let i=h.db;h.db.setWrap(m.wrap),xe=i.getC4ShapeInRow(),te=i.getC4BoundaryInRow(),de.debug(`C:${JSON.stringify(m,null,2)}`);const n=l==="sandbox"?s.select(`[id="${t}"]`):jt(`[id="${t}"]`);Q.insertComputerIcon(n),Q.insertDatabaseIcon(n),Q.insertClockIcon(n);let d=new Ee(h);d.setData(m.diagramMarginX,m.diagramMarginX,m.diagramMarginY,m.diagramMarginY),d.data.widthLimit=screen.availWidth,Ft=m.diagramMarginX,Xt=m.diagramMarginY;const u=h.db.getTitle();let y=h.db.getBoundaries("");se(n,"",d,y,h),Q.insertArrowHead(n),Q.insertArrowEnd(n),Q.insertArrowCrossHead(n),Q.insertArrowFilledHead(n),T0(n,h.db.getRels(),h.db.getC4Shape,h),d.data.stopx=Ft,d.data.stopy=Xt;const f=d.data;let E=f.stopy-f.starty+2*m.diagramMarginY;const T=f.stopx-f.startx+2*m.diagramMarginX;u&&n.append("text").text(u).attr("x",(f.stopx-f.startx)/2-4*m.diagramMarginX).attr("y",f.starty+m.diagramMarginY),Me(n,E,T,m.useMaxWidth);const v=u?60:0;n.attr("viewBox",f.startx-m.diagramMarginX+" -"+(m.diagramMarginY+v)+" "+T+" "+(E+v)),de.debug("models:",f)},"draw"),ye={drawPersonOrSystemArray:Ce,drawBoundary:Se,setConf:ee,draw:v0},R0=g(e=>`.person {
7
+ stroke: ${e.personBorder};
8
+ fill: ${e.personBkg};
9
+ }
10
+ `,"getStyles"),D0=R0,B0={parser:Ie,db:Zt,renderer:ye,styles:D0,init:g(({c4:e,wrap:t})=>{ye.setConf(e),Zt.setWrap(t)},"init")};export{B0 as diagram};