@juki-team/base-ui 1.4.121 → 1.4.126
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.
- package/dist/esm/ArrowForwardIcon-BGNGoaPb.js +1 -0
- package/dist/esm/BarChart-BRhncYPh.js +1 -0
- package/dist/esm/{CartesianChart-tXHM9yHp.js → CartesianChart-CHBFhWU-.js} +1 -1
- package/dist/esm/ChangePasswordModal-BQLB54Cr.js +1 -0
- package/dist/esm/CodeEditor-CYG_k0Lp.js +1 -0
- package/dist/esm/CodeViewer-B7gQlNa4.js +1 -0
- package/dist/esm/Collapse-qB-EKyco.js +1 -0
- package/dist/esm/{DataGrid-CD44fkam.js → DataGrid-cnHfaSnO.js} +1 -1
- package/dist/esm/DataViewer-CtixdklI.js +1 -0
- package/dist/esm/DrawerView-BX-EuTEz.js +1 -0
- package/dist/esm/ExcalidrawButton-mBvm3E_8.js +1 -0
- package/dist/esm/GraphvizViewer-BSUIZVzn.js +1 -0
- package/dist/esm/ImageLoaderCropper-CAxLOrvB.js +1 -0
- package/dist/esm/InputCellPhoneNumber-sEhV7X7S.js +1 -0
- package/dist/esm/{InputColor-D_uAIBKY.js → InputColor-DzcLo0RL.js} +3 -3
- package/dist/esm/LineChart-9CP_N6Dp.js +1 -0
- package/dist/esm/MdMath-C2cj4Ncj.js +1 -0
- package/dist/esm/{MdMathEditor-BUf36EaT.js → MdMathEditor-Bh-kGfC0.js} +1 -1
- package/dist/esm/{Popover-myjbsRtv.js → Popover-DI0clp6-.js} +1 -1
- package/dist/esm/ReplyIcon-B25ABlw2.js +1 -0
- package/dist/esm/SettingsIcon-ive9Ghpw.js +1 -0
- package/dist/esm/SlideDeck-CbQNd9o8.js +1 -0
- package/dist/esm/{ProblemStatus-C5CR0Z8d.js → SubmissionDateField-D3AvKusK.js} +1 -1
- package/dist/esm/TableOfContents-h0mxAylD.js +1 -0
- package/dist/esm/TextHeadCell-xNcsNvcB.js +1 -0
- package/dist/esm/{Tooltip-CHc2LM3e.js → Tooltip-B0QLaU02.js} +2 -2
- package/dist/esm/{UserCodeEditor-BwNoHEIy.js → UserCodeEditor-1Q_AyVss.js} +3 -3
- package/dist/esm/VirtualizedRowsFixed-FKX6Oha-.js +1 -0
- package/dist/esm/WorksheetAsSlides-DeGxqAVa.js +1 -0
- package/dist/esm/WorksheetBodies-C6g1jLca.js +1 -0
- package/dist/esm/WorksheetContents-BJVQN9Da.js +1 -0
- package/dist/esm/WorksheetEditor-OLyrUrSa.js +1 -0
- package/dist/esm/WorksheetNode-Cq5WqUjf.js +1 -0
- package/dist/esm/WorksheetViewer-KN7MZ6tv.js +1 -0
- package/dist/esm/architecture-YZFGNWBL-C3AvEsb9.js +1 -0
- package/dist/esm/architectureDiagram-Q4EWVU46-JfdzkzTF.js +1 -0
- package/dist/esm/blockDiagram-DXYQGD6D-CCNaXRDY.js +1 -0
- package/dist/esm/c4Diagram-AHTNJAMY-DYguHdC-.js +1 -0
- package/dist/esm/channel-BwWtuiHW.js +1 -0
- package/dist/esm/{chunk-4BX2VUAB-COJYrArq.js → chunk-4BX2VUAB-B3YOaF9V.js} +1 -1
- package/dist/esm/{chunk-4TB4RGXK-BgOhjp4u.js → chunk-4TB4RGXK-DoSJMkEM.js} +1 -1
- package/dist/esm/{chunk-55IACEB6-BlGeNxvg.js → chunk-55IACEB6-B252J5rd.js} +1 -1
- package/dist/esm/{chunk-EDXVE4YY-CrsJ2Hnl.js → chunk-EDXVE4YY-BFbj9sbF.js} +1 -1
- package/dist/esm/{chunk-FMBD7UC4-PcmGZaXU.js → chunk-FMBD7UC4-yfeFLPr5.js} +1 -1
- package/dist/esm/{chunk-OYMX7WX6-Dd_OySsr.js → chunk-OYMX7WX6-Ck43KFw_.js} +1 -1
- package/dist/esm/{chunk-QZHKN3VN-D5wczz_U.js → chunk-QZHKN3VN-Bu8lDQIJ.js} +1 -1
- package/dist/esm/{chunk-YZCP3GAM-J0il8D93.js → chunk-YZCP3GAM-BleOO0o9.js} +1 -1
- package/dist/esm/classDiagram-6PBFFD2Q-BXMqxslq.js +1 -0
- package/dist/esm/classDiagram-v2-HSJHXN6E-BXMqxslq.js +1 -0
- package/dist/esm/clone-BOCOsCRj.js +1 -0
- package/dist/esm/cose-bilkent-S5V4N54A-B9_if8Zu.js +1 -0
- package/dist/esm/dagre-KV5264BT-DV80i6H7.js +1 -0
- package/dist/esm/diagram-5BDNPKRD-CvSq5VhZ.js +1 -0
- package/dist/esm/diagram-G4DWMVQ6-2LXWeAq0.js +1 -0
- package/dist/esm/diagram-MMDJMWI5-C9TdZJKm.js +1 -0
- package/dist/esm/diagram-TYMM5635-BnRtbot8.js +1 -0
- package/dist/esm/erDiagram-SMLLAGMA-DcBeM5L8.js +1 -0
- package/dist/esm/flowDiagram-DWJPFMVM-DB-IVMWG.js +1 -0
- package/dist/esm/ganttDiagram-T4ZO3ILL-CHeCKKxg.js +1 -0
- package/dist/esm/gitGraph-7Q5UKJZL-NBOYkfJG.js +1 -0
- package/dist/esm/gitGraphDiagram-UUTBAWPF-Bu-s5uIZ.js +1 -0
- package/dist/esm/{graph-Bh_6Hxf_.js → graph-Da_w8zjC.js} +1 -1
- package/dist/esm/helpers.js +1 -1
- package/dist/esm/{index-Bx0ktss6.js → index-BIV0VXr-.js} +1 -1
- package/dist/esm/index-CDfJgeHe.js +2 -0
- package/dist/esm/{index-BWbfbDmw.js → index-CH9DJEEq.js} +1 -1
- package/dist/esm/index-DSRdBu-J.js +1 -0
- package/dist/esm/index-tqdOtCFo.js +1 -0
- package/dist/esm/info-OMHHGYJF-CzmEvbS6.js +1 -0
- package/dist/esm/infoDiagram-42DDH7IO-CPcCPi5m.js +1 -0
- package/dist/esm/ishikawaDiagram-UXIWVN3A-CueHOskG.js +1 -0
- package/dist/esm/journeyDiagram-VCZTEJTY-CIFSUUZI.js +1 -0
- package/dist/esm/kanban-definition-6JOO6SKY-CIs3hbs0.js +1 -0
- package/dist/esm/{layout-BsYGzjO0.js → layout-DDbWXrIm.js} +1 -1
- package/dist/esm/main.js +1 -1
- package/dist/esm/{mermaid-parser.core-DxB6tfwM.js → mermaid-parser.core-DanmL-Td.js} +1 -1
- package/dist/esm/{mermaid.core-DmkzFmrK.js → mermaid.core-BHSaFUkv.js} +1 -1
- package/dist/esm/mindmap-definition-QFDTVHPH-SgHbFXe-.js +1 -0
- package/dist/esm/packet-4T2RLAQJ-CPh-Emqi.js +1 -0
- package/dist/esm/pie-ZZUOXDRM-BG9lV5xj.js +1 -0
- package/dist/esm/pieDiagram-DEJITSTG-BXJ3wszp.js +1 -0
- package/dist/esm/quadrantDiagram-34T5L4WZ-DQY0pNz6.js +1 -0
- package/dist/esm/radar-PYXPWWZC-CTTR6mD4.js +1 -0
- package/dist/esm/requirementDiagram-MS252O5E-BEx2GMJz.js +1 -0
- package/dist/esm/sankeyDiagram-XADWPNL6-Xs8yE439.js +1 -0
- package/dist/esm/sequenceDiagram-FGHM5R23-BRN5pTP-.js +1 -0
- package/dist/esm/server.js +1 -1
- package/dist/esm/settings.js +1 -1
- package/dist/esm/stateDiagram-FHFEXIEX-BgMmQXPF.js +1 -0
- package/dist/esm/stateDiagram-v2-QKLJ7IA2-DcAYS7fn.js +1 -0
- package/dist/esm/timeline-definition-GMOUNBTQ-B8yc3YE0.js +1 -0
- package/dist/esm/treeView-SZITEDCU-BQoV8XJs.js +1 -0
- package/dist/esm/treemap-W4RFUUIX-BuNBpvu9.js +1 -0
- package/dist/esm/{types-NAGOQCyQ.js → types-Vls6Vkq9.js} +1 -1
- package/dist/esm/vennDiagram-DHZGUBPP-CWksExk6.js +1 -0
- package/dist/esm/wardley-RL74JXVD-B1RYxIGW.js +1 -0
- package/dist/esm/wardleyDiagram-NUSXRM2D-B0EUAKR5.js +1 -0
- package/dist/esm/{websocket-Nx7WdiK7.js → websocket-DCvEZ5Ma.js} +1 -1
- package/dist/esm/xychartDiagram-5P7HB3ND-KvOi074l.js +1 -0
- package/dist/module-types/src/components/templates/columns/contest-columns/index.d.ts +2 -2
- package/dist/module-types/src/components/templates/index.d.ts +0 -2
- package/dist/module-types/src/components/templates/{columns → server/columns}/contest-columns/getContestContestantsHeader.d.ts +1 -1
- package/dist/module-types/src/components/templates/{columns → server/columns}/contest-columns/getContestDateHeader.d.ts +1 -1
- package/dist/module-types/src/components/templates/server/index.d.ts +4 -0
- package/dist/module-types/src/components/templates/{problem → server/problem}/TagsField.d.ts +1 -1
- package/dist/module-types/src/components/templates/{submission → server/submission}/SubmissionDateField.d.ts +1 -1
- package/package.json +1 -1
- package/src/styles/components/atoms/_data-viewer.scss +3 -3
- package/dist/esm/ArrowForwardIcon-CVIKnzmu.js +0 -1
- package/dist/esm/BarChart-C4j466sV.js +0 -1
- package/dist/esm/ChangePasswordModal-DAn7XeyD.js +0 -1
- package/dist/esm/CodeEditor-CFWIRByc.js +0 -1
- package/dist/esm/CodeViewer-C6XCe0GT.js +0 -1
- package/dist/esm/Collapse-DpriDerh.js +0 -1
- package/dist/esm/DataViewer-B1l0B0-d.js +0 -1
- package/dist/esm/DrawerView-hvnlPQq6.js +0 -1
- package/dist/esm/ExcalidrawButton-COXAKOpn.js +0 -1
- package/dist/esm/GraphvizViewer-BK4ypl3L.js +0 -1
- package/dist/esm/ImageLoaderCropper-DEt5ge51.js +0 -1
- package/dist/esm/InputCellPhoneNumber-CbFB6H2i.js +0 -1
- package/dist/esm/LineChart-B3nrTHaA.js +0 -1
- package/dist/esm/MdMath-Mf8WxhKy.js +0 -1
- package/dist/esm/ReplyIcon-DJFT1Tjl.js +0 -1
- package/dist/esm/SettingsIcon-CaFHSleq.js +0 -1
- package/dist/esm/SlideDeck-DvVHz3uy.js +0 -1
- package/dist/esm/TableOfContents-I1zUQZlM.js +0 -1
- package/dist/esm/TextHeadCell-CDT516Nd.js +0 -1
- package/dist/esm/VirtualizedRowsFixed-SmGRufd0.js +0 -1
- package/dist/esm/WorksheetAsSlides-BQVnbTDc.js +0 -1
- package/dist/esm/WorksheetBodies-kphWX0g5.js +0 -1
- package/dist/esm/WorksheetContents-CI8UrxIy.js +0 -1
- package/dist/esm/WorksheetEditor-CHC4ormG.js +0 -1
- package/dist/esm/WorksheetNode-C9ioDzE-.js +0 -1
- package/dist/esm/WorksheetViewer-Drg2e9_6.js +0 -1
- package/dist/esm/architecture-YZFGNWBL-DHLZLvJj.js +0 -1
- package/dist/esm/architectureDiagram-Q4EWVU46-DO8F0qz7.js +0 -1
- package/dist/esm/blockDiagram-DXYQGD6D-DNKe0cgR.js +0 -1
- package/dist/esm/c4Diagram-AHTNJAMY-DN5fuFmb.js +0 -1
- package/dist/esm/channel-4mHTJV-N.js +0 -1
- package/dist/esm/classDiagram-6PBFFD2Q-BudcHsyy.js +0 -1
- package/dist/esm/classDiagram-v2-HSJHXN6E-BudcHsyy.js +0 -1
- package/dist/esm/clone-Bdky4iBO.js +0 -1
- package/dist/esm/cose-bilkent-S5V4N54A-ZsIi3T0h.js +0 -1
- package/dist/esm/dagre-KV5264BT-Ps6KiA13.js +0 -1
- package/dist/esm/diagram-5BDNPKRD-CmcDSDfS.js +0 -1
- package/dist/esm/diagram-G4DWMVQ6-MRapKKyA.js +0 -1
- package/dist/esm/diagram-MMDJMWI5--Lf_QB5P.js +0 -1
- package/dist/esm/diagram-TYMM5635-CfbzkptG.js +0 -1
- package/dist/esm/erDiagram-SMLLAGMA-DmAtzyw1.js +0 -1
- package/dist/esm/flowDiagram-DWJPFMVM-Cd5g_eEq.js +0 -1
- package/dist/esm/ganttDiagram-T4ZO3ILL-O3kXJMuu.js +0 -1
- package/dist/esm/gitGraph-7Q5UKJZL-w9fSBFuS.js +0 -1
- package/dist/esm/gitGraphDiagram-UUTBAWPF-XLFtNk0y.js +0 -1
- package/dist/esm/index-DdRpaNiN.js +0 -1
- package/dist/esm/index-USryHMlL.js +0 -1
- package/dist/esm/index-tDMZSRa9.js +0 -2
- package/dist/esm/info-OMHHGYJF-6icJTSRL.js +0 -1
- package/dist/esm/infoDiagram-42DDH7IO-DiPK6iLZ.js +0 -1
- package/dist/esm/ishikawaDiagram-UXIWVN3A-DNCSSMvk.js +0 -1
- package/dist/esm/journeyDiagram-VCZTEJTY-BxyeAOhI.js +0 -1
- package/dist/esm/kanban-definition-6JOO6SKY-BR8Xd4RY.js +0 -1
- package/dist/esm/mindmap-definition-QFDTVHPH-BUmIu9eO.js +0 -1
- package/dist/esm/packet-4T2RLAQJ-jB8585_W.js +0 -1
- package/dist/esm/pie-ZZUOXDRM-BKLoVTcY.js +0 -1
- package/dist/esm/pieDiagram-DEJITSTG-CJQonP9T.js +0 -1
- package/dist/esm/quadrantDiagram-34T5L4WZ-o3IEMDUC.js +0 -1
- package/dist/esm/radar-PYXPWWZC-BBal7TH8.js +0 -1
- package/dist/esm/requirementDiagram-MS252O5E-CSBSz0_J.js +0 -1
- package/dist/esm/sankeyDiagram-XADWPNL6-Dd0d-7E4.js +0 -1
- package/dist/esm/sequenceDiagram-FGHM5R23-DEPMVZxI.js +0 -1
- package/dist/esm/stateDiagram-FHFEXIEX-B_eljgWF.js +0 -1
- package/dist/esm/stateDiagram-v2-QKLJ7IA2-D9FCD1lO.js +0 -1
- package/dist/esm/timeline-definition-GMOUNBTQ-Cg4NUF_H.js +0 -1
- package/dist/esm/treeView-SZITEDCU-S-ba_Q_y.js +0 -1
- package/dist/esm/treemap-W4RFUUIX-CnmNi6qL.js +0 -1
- package/dist/esm/vennDiagram-DHZGUBPP-B0vBQEXk.js +0 -1
- package/dist/esm/wardley-RL74JXVD-CQrog0ka.js +0 -1
- package/dist/esm/wardleyDiagram-NUSXRM2D-BxnrOeU9.js +0 -1
- package/dist/esm/xychartDiagram-5P7HB3ND-B6KmAHYz.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as t}from"./chunk-FMBD7UC4-yfeFLPr5.js";import{_ as e,E as r,d as a,e as i,l as s,z as n,B as o,a3 as l,c,Q as d,a4 as h,a5 as g,a6 as y,a7 as u,u as p,k as x,a8 as b,i as f,a9 as m,aa as w}from"./mermaid.core-BHSaFUkv.js";import{c as k}from"./clone-BOCOsCRj.js";import{G as S}from"./graph-Da_w8zjC.js";import{c as L}from"./channel-BwWtuiHW.js";import{l as _,k as E}from"./string-LeDn2fkG.js";import"./index-CDfJgeHe.js";import"react/jsx-runtime";import"react";import"./settings-DgLs6IK_.js";import"./SubmissionDateField-D3AvKusK.js";import"./index-CH9DJEEq.js";import"./enums.js";import"./date-DabTuCYQ.js";import"./time-BPMFfIa-.js";import"./websocket-DCvEZ5Ma.js";import"./worksheet-ClM0CaBH.js";import"motion/react";import"react-dom";import"./index-BD_n8l03.js";import"swr";import"@ably/spaces";import"@ably/spaces/react";import"ably";import"ably/liveobjects";import"ably/react";import"@ably/spaces/dist/mjs/react";import"./purify.es-BkjUCQC6.js";import"./memoize-CPUrcYQl.js";import"./_baseIteratee-DJNkOVK7.js";import"./isSymbol-CATEdeai.js";import"./_baseUniq-BJKKUJ6e.js";import"./isUndefined-DgmxjSXK.js";var D=function(){var t=e(function(t,e,r,a){for(r=r||{},a=t.length;a--;r[t[a]]=e);return r},"o"),r=[1,15],a=[1,7],i=[1,13],s=[1,14],n=[1,19],o=[1,16],l=[1,17],c=[1,18],d=[8,30],h=[8,10,21,28,29,30,31,39,43,46],g=[1,23],y=[1,24],u=[8,10,15,16,21,28,29,30,31,39,43,46],p=[8,10,15,16,21,27,28,29,30,31,39,43,46],x=[1,49],b={trace:e(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:e(function(t,e,r,a,i,s,n){var o=s.length-1;switch(i){case 4:a.getLogger().debug("Rule: separator (NL) ");break;case 5:a.getLogger().debug("Rule: separator (Space) ");break;case 6:a.getLogger().debug("Rule: separator (EOF) ");break;case 7:a.getLogger().debug("Rule: hierarchy: ",s[o-1]),a.setHierarchy(s[o-1]);break;case 8:a.getLogger().debug("Stop NL ");break;case 9:a.getLogger().debug("Stop EOF ");break;case 10:a.getLogger().debug("Stop NL2 ");break;case 11:a.getLogger().debug("Stop EOF2 ");break;case 12:a.getLogger().debug("Rule: statement: ",s[o]),"number"==typeof s[o].length?this.$=s[o]:this.$=[s[o]];break;case 13:a.getLogger().debug("Rule: statement #2: ",s[o-1]),this.$=[s[o-1]].concat(s[o]);break;case 14:a.getLogger().debug("Rule: link: ",s[o],t),this.$={edgeTypeStr:s[o],label:""};break;case 15:a.getLogger().debug("Rule: LABEL link: ",s[o-3],s[o-1],s[o]),this.$={edgeTypeStr:s[o],label:s[o-1]};break;case 18:const e=parseInt(s[o]),r=a.generateId();this.$={id:r,type:"space",label:"",width:e,children:[]};break;case 23:a.getLogger().debug("Rule: (nodeStatement link node) ",s[o-2],s[o-1],s[o]," typestr: ",s[o-1].edgeTypeStr);const i=a.edgeStrToEdgeData(s[o-1].edgeTypeStr);this.$=[{id:s[o-2].id,label:s[o-2].label,type:s[o-2].type,directions:s[o-2].directions},{id:s[o-2].id+"-"+s[o].id,start:s[o-2].id,end:s[o].id,label:s[o-1].label,type:"edge",directions:s[o].directions,arrowTypeEnd:i,arrowTypeStart:"arrow_open"},{id:s[o].id,label:s[o].label,type:a.typeStr2Type(s[o].typeStr),directions:s[o].directions}];break;case 24:a.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[o-1],s[o]),this.$={id:s[o-1].id,label:s[o-1].label,type:a.typeStr2Type(s[o-1].typeStr),directions:s[o-1].directions,widthInColumns:parseInt(s[o],10)};break;case 25:a.getLogger().debug("Rule: nodeStatement (node) ",s[o]),this.$={id:s[o].id,label:s[o].label,type:a.typeStr2Type(s[o].typeStr),directions:s[o].directions,widthInColumns:1};break;case 26:a.getLogger().debug("APA123",this?this:"na"),a.getLogger().debug("COLUMNS: ",s[o]),this.$={type:"column-setting",columns:"auto"===s[o]?-1:parseInt(s[o])};break;case 27:a.getLogger().debug("Rule: id-block statement : ",s[o-2],s[o-1]),a.generateId(),this.$={...s[o-2],type:"composite",children:s[o-1]};break;case 28:a.getLogger().debug("Rule: blockStatement : ",s[o-2],s[o-1],s[o]);const n=a.generateId();this.$={id:n,type:"composite",label:"",children:s[o-1]};break;case 29:a.getLogger().debug("Rule: node (NODE_ID separator): ",s[o]),this.$={id:s[o]};break;case 30:a.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[o-1],s[o]),this.$={id:s[o-1],label:s[o].label,typeStr:s[o].typeStr,directions:s[o].directions};break;case 31:a.getLogger().debug("Rule: dirList: ",s[o]),this.$=[s[o]];break;case 32:a.getLogger().debug("Rule: dirList: ",s[o-1],s[o]),this.$=[s[o-1]].concat(s[o]);break;case 33:a.getLogger().debug("Rule: nodeShapeNLabel: ",s[o-2],s[o-1],s[o]),this.$={typeStr:s[o-2]+s[o],label:s[o-1]};break;case 34:a.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[o-3],s[o-2]," #3:",s[o-1],s[o]),this.$={typeStr:s[o-3]+s[o],label:s[o-2],directions:s[o-1]};break;case 35:case 36:this.$={type:"classDef",id:s[o-1].trim(),css:s[o].trim()};break;case 37:this.$={type:"applyClass",id:s[o-1].trim(),styleClass:s[o].trim()};break;case 38:this.$={type:"applyStyles",id:s[o-1].trim(),stylesStr:s[o].trim()}}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:r,11:3,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:s,31:n,39:o,43:l,46:c},{8:[1,20]},t(d,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:r,21:a,28:i,29:s,31:n,39:o,43:l,46:c}),t(h,[2,16],{14:22,15:g,16:y}),t(h,[2,17]),t(h,[2,18]),t(h,[2,19]),t(h,[2,20]),t(h,[2,21]),t(h,[2,22]),t(u,[2,25],{27:[1,25]}),t(h,[2,26]),{19:26,26:12,31:n},{10:r,11:27,13:4,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:s,31:n,39:o,43:l,46:c},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},t(p,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},t(d,[2,13]),{26:35,31:n},{31:[2,14]},{17:[1,36]},t(u,[2,24]),{10:r,11:37,13:4,14:22,15:g,16:y,19:5,20:6,21:a,22:8,23:9,24:10,25:11,26:12,28:i,29:s,31:n,39:o,43:l,46:c},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},t(p,[2,30]),{18:[1,43]},{18:[1,44]},t(u,[2,23]),{18:[1,45]},{30:[1,46]},t(h,[2,28]),t(h,[2,35]),t(h,[2,36]),t(h,[2,37]),t(h,[2,38]),{36:[1,47]},{33:48,34:x},{15:[1,50]},t(h,[2,27]),t(p,[2,33]),{38:[1,51]},{33:52,34:x,38:[2,31]},{31:[2,15]},t(p,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:e(function(t,e){if(!e.recoverable){var r=new Error(t);throw r.hash=e,r}this.trace(t)},"parseError"),parse:e(function(t){var r=this,a=[0],i=[],s=[null],n=[],o=this.table,l="",c=0,d=0,h=n.slice.call(arguments,1),g=Object.create(this.lexer),y={yy:{}};for(var u in this.yy)Object.prototype.hasOwnProperty.call(this.yy,u)&&(y.yy[u]=this.yy[u]);g.setInput(t,y.yy),y.yy.lexer=g,y.yy.parser=this,void 0===g.yylloc&&(g.yylloc={});var p=g.yylloc;n.push(p);var x=g.options&&g.options.ranges;function b(){var t;return"number"!=typeof(t=i.pop()||g.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=r.symbols_[t]||t),t}"function"==typeof y.yy.parseError?this.parseError=y.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,e(function(t){a.length=a.length-2*t,s.length=s.length-t,n.length=n.length-t},"popStack"),e(b,"lex");for(var f,m,w,k,S,L,_,E,D={};;){if(m=a[a.length-1],this.defaultActions[m]?w=this.defaultActions[m]:(null==f&&(f=b()),w=o[m]&&o[m][f]),void 0===w||!w.length||!w[0]){var $="";for(S in E=[],o[m])this.terminals_[S]&&S>2&&E.push("'"+this.terminals_[S]+"'");$=g.showPosition?"Parse error on line "+(c+1)+":\n"+g.showPosition()+"\nExpecting "+E.join(", ")+", got '"+(this.terminals_[f]||f)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==f?"end of input":"'"+(this.terminals_[f]||f)+"'"),this.parseError($,{text:g.match,token:this.terminals_[f]||f,line:g.yylineno,loc:p,expected:E})}if(w[0]instanceof Array&&w.length>1)throw new Error("Parse Error: multiple actions possible at state: "+m+", token: "+f);switch(w[0]){case 1:a.push(f),s.push(g.yytext),n.push(g.yylloc),a.push(w[1]),f=null,d=g.yyleng,l=g.yytext,c=g.yylineno,p=g.yylloc;break;case 2:if(L=this.productions_[w[1]][1],D.$=s[s.length-L],D._$={first_line:n[n.length-(L||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(L||1)].first_column,last_column:n[n.length-1].last_column},x&&(D._$.range=[n[n.length-(L||1)].range[0],n[n.length-1].range[1]]),void 0!==(k=this.performAction.apply(D,[l,d,c,y.yy,w[1],s,n].concat(h))))return k;L&&(a=a.slice(0,-1*L*2),s=s.slice(0,-1*L),n=n.slice(0,-1*L)),a.push(this.productions_[w[1]][0]),s.push(D.$),n.push(D._$),_=o[a[a.length-2]][a[a.length-1]],a.push(_);break;case 3:return!0}}return!0},"parse")},f=function(){return{EOF:1,parseError:e(function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},"parseError"),setInput:e(function(t,e){return this.yy=e||this.yy||{},this._input=t,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:e(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:e(function(t){var e=t.length,r=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var a=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),r.length-1&&(this.yylineno-=r.length-1);var i=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:r?(r.length===a.length?this.yylloc.first_column:0)+a[a.length-r.length].length-r[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:e(function(){return this._more=!0,this},"more"),reject:e(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:e(function(t){this.unput(this.match.slice(t))},"less"),pastInput:e(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:e(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:e(function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:e(function(t,e){var r,a,i;if(this.options.backtrack_lexer&&(i={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&&(i.yylloc.range=this.yylloc.range.slice(0))),(a=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],r=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack){for(var s in i)this[s]=i[s];return!1}return!1},"test_match"),next:e(function(){if(this.done)return this.EOF;var t,e,r,a;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),s=0;s<i.length;s++)if((r=this._input.match(this.rules[i[s]]))&&(!e||r[0].length>e[0].length)){if(e=r,a=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(r,i[s])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[a]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var t=this.next();return t||this.lex()},"lex"),begin:e(function(t){this.conditionStack.push(t)},"begin"),popState:e(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:e(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:e(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:e(function(t){this.begin(t)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:e(function(t,e,r,a){switch(r){case 0:return t.getLogger().debug("Found block-beta"),10;case 1:return t.getLogger().debug("Found id-block"),29;case 2:return t.getLogger().debug("Found block"),10;case 3:t.getLogger().debug(".",e.yytext);break;case 4:t.getLogger().debug("_",e.yytext);break;case 5:return 5;case 6:return e.yytext=-1,28;case 7:return e.yytext=e.yytext.replace(/columns\s+/,""),t.getLogger().debug("COLUMNS (LEX)",e.yytext),28;case 8:case 76:case 77:case 99:this.pushState("md_string");break;case 9:return"MD_STR";case 10:case 34:case 79:this.popState();break;case 11:this.pushState("string");break;case 12:t.getLogger().debug("LEX: POPPING STR:",e.yytext),this.popState();break;case 13:return t.getLogger().debug("LEX: STR end:",e.yytext),"STR";case 14:return e.yytext=e.yytext.replace(/space\:/,""),t.getLogger().debug("SPACE NUM (LEX)",e.yytext),21;case 15:return e.yytext="1",t.getLogger().debug("COLUMNS (LEX)",e.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 35:return"acc_descr_multiline_value";case 36:return 30;case 37:case 38:case 40:case 41:case 44:return this.popState(),t.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),t.getLogger().debug("Lex: ))"),"NODE_DEND";case 42:return this.popState(),t.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),t.getLogger().debug("Lex: -)"),"NODE_DEND";case 45:return this.popState(),t.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),t.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),t.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:case 49:return this.popState(),t.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),t.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),t.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),t.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),t.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return t.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return t.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return t.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:case 59:case 60:case 61:case 64:return t.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return t.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 62:return t.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return t.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 65:case 66:case 67:case 68:case 69:case 70:case 71:return this.pushState("NODE"),35;case 72:return t.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),t.getLogger().debug("LEX ARR START"),37;case 74:return t.getLogger().debug("Lex: NODE_ID",e.yytext),31;case 75:return t.getLogger().debug("Lex: EOF",e.yytext),8;case 78:return"NODE_DESCR";case 80:t.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:t.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return t.getLogger().debug("LEX: NODE_DESCR:",e.yytext),"NODE_DESCR";case 83:t.getLogger().debug("LEX POPPING"),this.popState();break;case 84:t.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (right): dir:",e.yytext),"DIR";case 86:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (left):",e.yytext),"DIR";case 87:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (x):",e.yytext),"DIR";case 88:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (y):",e.yytext),"DIR";case 89:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (up):",e.yytext),"DIR";case 90:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (down):",e.yytext),"DIR";case 91:return e.yytext="]>",t.getLogger().debug("Lex (ARROW_DIR end):",e.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 93:case 94:case 95:return t.getLogger().debug("Lex: LINK",e.yytext),15;case 96:case 97:case 98:return t.getLogger().debug("Lex: START_LINK",e.yytext),this.pushState("LLABEL"),16;case 100:return t.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 102:case 103:return this.popState(),t.getLogger().debug("Lex: LINK",e.yytext),15;case 104:return t.getLogger().debug("Lex: COLON",e.yytext),e.yytext=e.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}}}}();function m(){this.yy={}}return b.lexer=f,e(m,"Parser"),m.prototype=b,b.Parser=m,new m}();D.parser=D;var $=D,v=new Map,T=[],I=new Map,N="color",C="fill",B=c(),R=new Map,z="",O=e(t=>x.sanitizeText(t,B),"sanitizeText"),A=e(function(t,e=""){let r=R.get(t);r||(r={id:t,styles:[],textStyles:[]},R.set(t,r)),null!=e&&e.split(",").forEach(t=>{const e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(N).exec(t)){const t=e.replace(C,"bgFill").replace(N,C);r.textStyles.push(t)}r.styles.push(e)})},"addStyleClass"),M=e(function(t,e=""){const r=v.get(t);null!=e&&(r.styles=e.split(","))},"addStyle2Node"),P=e(function(t,e){t.split(",").forEach(function(t){let r=v.get(t);if(void 0===r){const e=t.trim();r={id:e,type:"na",children:[]},v.set(e,r)}r.classes||(r.classes=[]),r.classes.push(e)})},"setCssClass"),Y=e((t,e)=>{const r=t.flat(),a=[],i=r.find(t=>"column-setting"===t?.type),n=i?.columns??-1;for(const t of r)if("number"==typeof n&&n>0&&"column-setting"!==t.type&&"number"==typeof t.widthInColumns&&t.widthInColumns>n&&s.warn(`Block ${t.id} width ${t.widthInColumns} exceeds configured column width ${n}`),t.label&&(t.label=O(t.label)),"classDef"!==t.type)if("applyClass"!==t.type)if("applyStyles"!==t.type)if("column-setting"===t.type)e.columns=t.columns??-1;else if("edge"===t.type){const e=(I.get(t.id)??0)+1;I.set(t.id,e),t.id=e+"-"+t.id,T.push(t)}else{t.label||("composite"===t.type?t.label="":t.label=t.id);const e=v.get(t.id);if(void 0===e?v.set(t.id,t):("na"!==t.type&&(e.type=t.type),t.label!==t.id&&(e.label=t.label)),t.children&&Y(t.children,t),"space"===t.type){const e=t.width??1;for(let r=0;r<e;r++){const e=k(t);e.id=e.id+"-"+r,v.set(e.id,e),a.push(e)}}else void 0===e&&a.push(t)}else t?.stylesStr&&M(t.id,t?.stylesStr);else P(t.id,t?.styleClass??"");else A(t.id,t.css);e.children=a},"populateBlockDatabase"),j=[],F={id:"root",type:"composite",children:[],columns:-1},W=e(()=>{s.debug("Clear called"),n(),F={id:"root",type:"composite",children:[],columns:-1},v=new Map([["root",F]]),j=[],R=new Map,T=[],I=new Map,z=""},"clear");function X(t){switch(s.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return s.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"}}function U(t){return s.debug("typeStr2Type",t),"=="===t?"thick":"normal"}function H(t){switch(t.replace(/^[\s-]+|[\s-]+$/g,"")){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}e(X,"typeStr2Type"),e(U,"edgeTypeStr2Type"),e(H,"edgeStrToEdgeData");var K=0,q=e(()=>(K++,"id-"+Math.random().toString(36).substr(2,12)+"-"+K),"generateId"),Z=e(t=>{F.children=t,Y(t,F),j=F.children},"setHierarchy"),G=e(t=>{const e=v.get(t);return e?e.columns?e.columns:e.children?e.children.length:-1:-1},"getColumns"),V=e(()=>[...v.values()],"getBlocksFlat"),J=e(()=>j||[],"getBlocks"),Q=e(()=>T,"getEdges"),tt=e(t=>v.get(t),"getBlock"),et=e(t=>{v.set(t.id,t)},"setBlock"),rt=e(t=>{z=t},"setDiagramId"),at=e(()=>z,"getDiagramId"),it=e(()=>s,"getLogger"),st=e(function(){return R},"getClasses"),nt={getConfig:e(()=>r().block,"getConfig"),typeStr2Type:X,edgeTypeStr2Type:U,edgeStrToEdgeData:H,getLogger:it,getBlocksFlat:V,getBlocks:J,getEdges:Q,setHierarchy:Z,getBlock:tt,setBlock:et,getColumns:G,getClasses:st,clear:W,generateId:q,setDiagramId:rt,getDiagramId:at},ot=e((t,e)=>{const r=L,a=r(t,"r"),i=r(t,"g"),s=r(t,"b");return o(a,i,s,e)},"fade"),lt=e(e=>`.label {\n font-family: ${e.fontFamily};\n color: ${e.nodeTextColor||e.textColor};\n }\n .cluster-label text {\n fill: ${e.titleColor};\n }\n .cluster-label span,p {\n color: ${e.titleColor};\n }\n\n\n\n .label text,span,p {\n fill: ${e.nodeTextColor||e.textColor};\n color: ${e.nodeTextColor||e.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${e.mainBkg};\n stroke: ${e.nodeBorder};\n stroke-width: 1px;\n }\n .flowchart-label text {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${e.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${e.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${e.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${e.edgeLabelBackground};\n /*\n * This is for backward compatibility with existing code that didn't\n * add a \`<p>\` around edge labels.\n *\n * TODO: We should probably remove this in a future release.\n */\n p {\n margin: 0;\n padding: 0;\n display: inline;\n }\n rect {\n opacity: 0.5;\n background-color: ${e.edgeLabelBackground};\n fill: ${e.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${e.edgeLabelBackground};\n }\n\n .node .cluster {\n // fill: ${ot(e.mainBkg,.5)};\n fill: ${ot(e.clusterBkg,.5)};\n stroke: ${ot(e.clusterBorder,.2)};\n box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${e.titleColor};\n }\n\n .cluster span,p {\n color: ${e.titleColor};\n }\n /* .cluster div {\n color: ${e.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${e.fontFamily};\n font-size: 12px;\n background: ${e.tertiaryColor};\n border: 1px solid ${e.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${e.textColor};\n }\n ${t()}\n`,"getStyles"),ct=e((t,e,r,a)=>{e.forEach(e=>{dt[e](t,r,a)})},"insertMarkers"),dt={extension:e((t,e,r)=>{s.trace("Making markers for ",r),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionStart").attr("class","marker extension "+e).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"),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionEnd").attr("class","marker extension "+e).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"),composition:e((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionStart").attr("class","marker composition "+e).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"),t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionEnd").attr("class","marker composition "+e).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"),aggregation:e((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).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"),t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).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"),dependency:e((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).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"),t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).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"),lollipop:e((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).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),t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).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"),point:e((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-pointEnd").attr("class","marker "+e).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"),t.append("marker").attr("id",r+"_"+e+"-pointStart").attr("class","marker "+e).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"),circle:e((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-circleEnd").attr("class","marker "+e).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"),t.append("marker").attr("id",r+"_"+e+"-circleStart").attr("class","marker "+e).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"),cross:e((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-crossEnd").attr("class","marker cross "+e).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"),t.append("marker").attr("id",r+"_"+e+"-crossStart").attr("class","marker cross "+e).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"),barb:e((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-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")},ht=ct,gt=c()?.block?.padding??8;function yt(t,e){if(0===t||!Number.isInteger(t))throw new Error("Columns must be an integer !== 0.");if(e<0||!Number.isInteger(e))throw new Error("Position must be a non-negative integer."+e);if(t<0)return{px:e,py:0};if(1===t)return{px:0,py:e};return{px:e%t,py:Math.floor(e/t)}}e(yt,"calculateBlockPosition");var ut=e(t=>{let e=0,r=0;for(const a of t.children){const{width:t,height:i,x:n,y:o}=a.size??{width:0,height:0,x:0,y:0};s.debug("getMaxChildSize abc95 child:",a.id,"width:",t,"height:",i,"x:",n,"y:",o,a.type),"space"!==a.type&&(t>e&&(e=t/(a.widthInColumns??1)),i>r&&(r=i))}return{width:e,height:r}},"getMaxChildSize");function pt(t,e,r=0,a=0){s.debug("setBlockSizes abc95 (start)",t.id,t?.size?.x,"block width =",t?.size,"siblingWidth",r),t?.size?.width||(t.size={width:r,height:a,x:0,y:0});let i=0,n=0;if(t.children?.length>0){for(const r of t.children)pt(r,e);const o=ut(t);i=o.width,n=o.height,s.debug("setBlockSizes abc95 maxWidth of",t.id,":s children is ",i,n);for(const e of t.children)e.size&&(s.debug(`abc95 Setting size of children of ${t.id} id=${e.id} ${i} ${n} ${JSON.stringify(e.size)}`),e.size.width=i*(e.widthInColumns??1)+gt*((e.widthInColumns??1)-1),e.size.height=n,e.size.x=0,e.size.y=0,s.debug(`abc95 updating size of ${t.id} children child:${e.id} maxWidth:${i} maxHeight:${n}`));for(const r of t.children)pt(r,e,i,n);const l=t.columns??-1;let c=0;for(const e of t.children)c+=e.widthInColumns??1;let d=t.children.length;l>0&&l<c&&(d=l);const h=Math.ceil(c/d);let g=d*(i+gt)+gt,y=h*(n+gt)+gt;if(g<r){s.debug(`Detected to small sibling: abc95 ${t.id} siblingWidth ${r} siblingHeight ${a} width ${g}`),g=r,y=a;const e=(r-d*gt-gt)/d,o=(a-h*gt-gt)/h;s.debug("Size indata abc88",t.id,"childWidth",e,"maxWidth",i),s.debug("Size indata abc88",t.id,"childHeight",o,"maxHeight",n),s.debug("Size indata abc88 xSize",d,"padding",gt);for(const r of t.children)r.size&&(r.size.width=e,r.size.height=o,r.size.x=0,r.size.y=0)}if(s.debug(`abc95 (finale calc) ${t.id} xSize ${d} ySize ${h} columns ${l}${t.children.length} width=${Math.max(g,t.size?.width||0)}`),g<(t?.size?.width||0)){g=t?.size?.width||0;const e=l>0?Math.min(t.children.length,l):t.children.length;if(e>0){const r=(g-e*gt-gt)/e;s.debug("abc95 (growing to fit) width",t.id,g,t.size?.width,r);for(const e of t.children)e.size&&(e.size.width=r)}}t.size={width:g,height:y,x:0,y:0}}s.debug("setBlockSizes abc94 (done)",t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}function xt(t,e){s.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);const r=t.columns??-1;if(s.debug("layoutBlocks columns abc95",t.id,"=>",r,t),t.children&&t.children.length>0){const e=t?.children[0]?.size?.width??0,a=t.children.length*e+(t.children.length-1)*gt;s.debug("widthOfChildren 88",a,"posX");const i=new Map;{let e=0;for(const a of t.children){if(!a.size)continue;const{py:t}=yt(r,e),s=i.get(t)??0;a.size.height>s&&i.set(t,a.size.height);let n=a?.widthInColumns??1;r>0&&(n=Math.min(n,r-e%r)),e+=n}}const n=new Map;{let t=0;const e=[...i.keys()].sort((t,e)=>t-e);for(const r of e)n.set(r,t),t+=(i.get(r)??0)+gt}let o=0;s.debug("abc91 block?.size?.x",t.id,t?.size?.x);let l=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-gt,c=0;for(const e of t.children){const a=t;if(!e.size)continue;const{width:d,height:h}=e.size,{px:g,py:y}=yt(r,o);if(y!=c&&(c=y,l=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-gt,s.debug("New row in layout for block",t.id," and child ",e.id,c)),s.debug(`abc89 layout blocks (child) id: ${e.id} Pos: ${o} (px, py) ${g},${y} (${a?.size?.x},${a?.size?.y}) parent: ${a.id} width: ${d}${gt}`),a.size){const t=d/2;e.size.x=l+gt+t,s.debug(`abc91 layout blocks (calc) px, pyid:${e.id} startingPos=X${l} new startingPosX${e.size.x} ${t} padding=${gt} width=${d} halfWidth=${t} => x:${e.size.x} y:${e.size.y} ${e.widthInColumns} (width * (child?.w || 1)) / 2 ${d*(e?.widthInColumns??1)/2}`),l=e.size.x+t;const r=n.get(y)??0,o=i.get(y)??h;e.size.y=a.size.y-a.size.height/2+r+o/2+gt,s.debug(`abc88 layout blocks (calc) px, pyid:${e.id}startingPosX${l}${gt}${t}=>x:${e.size.x}y:${e.size.y}${e.widthInColumns}(width * (child?.w || 1)) / 2${d*(e?.widthInColumns??1)/2}`)}e.children&&xt(e);let u=e?.widthInColumns??1;r>0&&(u=Math.min(u,r-o%r)),o+=u,s.debug("abc88 columnsPos",e,o)}}s.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}function bt(t,{minX:e,minY:r,maxX:a,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(t.size&&"root"!==t.id){const{x:s,y:n,width:o,height:l}=t.size;s-o/2<e&&(e=s-o/2),n-l/2<r&&(r=n-l/2),s+o/2>a&&(a=s+o/2),n+l/2>i&&(i=n+l/2)}if(t.children)for(const s of t.children)({minX:e,minY:r,maxX:a,maxY:i}=bt(s,{minX:e,minY:r,maxX:a,maxY:i}));return{minX:e,minY:r,maxX:a,maxY:i}}function ft(t){const e=t.getBlock("root");if(!e)return;pt(e,t,0,0),xt(e),s.debug("getBlocks",JSON.stringify(e,null,2));const{minX:r,minY:a,maxX:i,maxY:n}=bt(e);return{x:r,y:a,width:i-r,height:n-a}}e(pt,"setBlockSizes"),e(xt,"layoutBlocks"),e(bt,"findBounds"),e(ft,"layout");var mt=e(async(t,e,r,a=!1,i=!1)=>{let s=e||"";"object"==typeof s&&(s=s[0]);const n=c(),o=h(n);return await g(t,s,{style:r,isTitle:a,useHtmlLabels:o,markdown:!1,isNode:i,width:Number.POSITIVE_INFINITY},n)},"createLabel"),wt=e((t,e,r,a,i)=>{e.arrowTypeStart&&St(t,"start",e.arrowTypeStart,r,a,i),e.arrowTypeEnd&&St(t,"end",e.arrowTypeEnd,r,a,i)},"addEdgeMarkers"),kt={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},St=e((t,e,r,a,i,n)=>{const o=kt[r];if(!o)return void s.warn(`Unknown arrow type: ${r}`);const l="start"===e?"Start":"End";t.attr(`marker-${e}`,`url(${a}#${i}_${n}-${o}${l})`)},"addEdgeMarker"),Lt={},_t={},Et=e(async(t,e)=>{const r=c(),i=h(r),s=t.insert("g").attr("class","edgeLabel"),n=s.insert("g").attr("class","label"),o="markdown"===e.labelType,l=await g(t,e.label,{style:e.labelStyle,useHtmlLabels:i,addSvgBackground:o,isNode:!1,markdown:o,width:o?void 0:Number.POSITIVE_INFINITY},r);n.node().appendChild(l);let d,u=l.getBBox(),p=u;if(i){const t=l.children[0],e=a(l);u=t.getBoundingClientRect(),p=u,e.attr("width",u.width),e.attr("height",u.height)}else{const t=a(l).select("text").node();t&&"function"==typeof t.getBBox&&(p=t.getBBox())}if(n.attr("transform",y(p,i)),Lt[e.id]=s,e.width=u.width,e.height=u.height,e.startLabelLeft){const r=t.insert("g").attr("class","edgeTerminals"),s=r.insert("g").attr("class","inner"),n=await mt(s,e.startLabelLeft,e.labelStyle);d=n;let o=n.getBBox();if(i){const t=n.children[0],e=a(n);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}s.attr("transform",y(o,i)),_t[e.id]||(_t[e.id]={}),_t[e.id].startLeft=r,Dt(d,e.startLabelLeft)}if(e.startLabelRight){const r=t.insert("g").attr("class","edgeTerminals"),s=r.insert("g").attr("class","inner"),n=await mt(r,e.startLabelRight,e.labelStyle);d=n,s.node().appendChild(n);let o=n.getBBox();if(i){const t=n.children[0],e=a(n);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}s.attr("transform",y(o,i)),_t[e.id]||(_t[e.id]={}),_t[e.id].startRight=r,Dt(d,e.startLabelRight)}if(e.endLabelLeft){const r=t.insert("g").attr("class","edgeTerminals"),s=r.insert("g").attr("class","inner"),n=await mt(s,e.endLabelLeft,e.labelStyle);d=n;let o=n.getBBox();if(i){const t=n.children[0],e=a(n);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}s.attr("transform",y(o,i)),r.node().appendChild(n),_t[e.id]||(_t[e.id]={}),_t[e.id].endLeft=r,Dt(d,e.endLabelLeft)}if(e.endLabelRight){const r=t.insert("g").attr("class","edgeTerminals"),s=r.insert("g").attr("class","inner"),n=await mt(s,e.endLabelRight,e.labelStyle);d=n;let o=n.getBBox();if(i){const t=n.children[0],e=a(n);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}s.attr("transform",y(o,i)),r.node().appendChild(n),_t[e.id]||(_t[e.id]={}),_t[e.id].endRight=r,Dt(d,e.endLabelRight)}return l},"insertEdgeLabel");function Dt(t,e){h(c())&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}e(Dt,"setTerminalWidth");var $t=e((t,e)=>{s.debug("Moving label abc88 ",t.id,t.label,Lt[t.id],e);let r=e.updatedPath?e.updatedPath:e.originalPath;const a=c(),{subGraphTitleTotalMargin:i}=u(a);if(t.label){const a=Lt[t.id];let n=t.x,o=t.y;if(r){const a=p.calcLabelPosition(r);s.debug("Moving label "+t.label+" from (",n,",",o,") to (",a.x,",",a.y,") abc88"),e.updatedPath&&(n=a.x,o=a.y)}a.attr("transform",`translate(${n}, ${o+i/2})`)}if(t.startLabelLeft){const e=_t[t.id].startLeft;let a=t.x,i=t.y;if(r){const e=p.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.startLabelRight){const e=_t[t.id].startRight;let a=t.x,i=t.y;if(r){const e=p.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelLeft){const e=_t[t.id].endLeft;let a=t.x,i=t.y;if(r){const e=p.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelRight){const e=_t[t.id].endRight;let a=t.x,i=t.y;if(r){const e=p.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}},"positionEdgeLabel"),vt=e((t,e)=>{const r=t.x,a=t.y,i=Math.abs(e.x-r),s=Math.abs(e.y-a),n=t.width/2,o=t.height/2;return i>=n||s>=o},"outsideNode"),Tt=e((t,e,r)=>{s.debug(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(e)}\n insidePoint : ${JSON.stringify(r)}\n node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);const a=t.x,i=t.y,n=Math.abs(a-r.x),o=t.width/2;let l=r.x<e.x?o-n:o+n;const c=t.height/2,d=Math.abs(e.y-r.y),h=Math.abs(e.x-r.x);if(Math.abs(i-e.y)*o>Math.abs(a-e.x)*c){let t=r.y<e.y?e.y-c-i:i-c-e.y;l=h*t/d;const a={x:r.x<e.x?r.x+l:r.x-h+l,y:r.y<e.y?r.y+d-t:r.y-d+t};return 0===l&&(a.x=e.x,a.y=e.y),0===h&&(a.x=e.x),0===d&&(a.y=e.y),s.debug(`abc89 topp/bott calc, Q ${d}, q ${t}, R ${h}, r ${l}`,a),a}{l=r.x<e.x?e.x-o-a:a-o-e.x;let t=d*l/h,i=r.x<e.x?r.x+h-l:r.x-h+l,n=r.y<e.y?r.y+t:r.y-t;return s.debug(`sides calc abc89, Q ${d}, q ${t}, R ${h}, r ${l}`,{_x:i,_y:n}),0===l&&(i=e.x,n=e.y),0===h&&(i=e.x),0===d&&(n=e.y),{x:i,y:n}}},"intersection"),It=e((t,e)=>{s.debug("abc88 cutPathAtIntersect",t,e);let r=[],a=t[0],i=!1;return t.forEach(t=>{if(vt(e,t)||i)a=t,i||r.push(t);else{const s=Tt(e,a,t);let n=!1;r.forEach(t=>{n=n||t.x===s.x&&t.y===s.y}),r.some(t=>t.x===s.x&&t.y===s.y)||r.push(s),i=!0}}),r},"cutPathAtIntersect"),Nt=e(function(t,e,r,a,i,n,o){let h=r.points;s.debug("abc88 InsertEdge: edge=",r,"e=",e);let g=!1;const y=n.node(e.v);var u=n.node(e.w);u?.intersect&&y?.intersect&&(h=h.slice(1,r.points.length-1),h.unshift(y.intersect(h[0])),h.push(u.intersect(h[h.length-1]))),r.toCluster&&(s.debug("to cluster abc88",a[r.toCluster]),h=It(r.points,a[r.toCluster].node),g=!0),r.fromCluster&&(s.debug("from cluster abc88",a[r.fromCluster]),h=It(h.reverse(),a[r.fromCluster].node).reverse(),g=!0);const p=h.filter(t=>!Number.isNaN(t.y));let x=E;!r.curve||"graph"!==i&&"flowchart"!==i||(x=r.curve);const{x:b,y:f}=l(r),m=_().x(b).y(f).curve(x);let w;switch(r.thickness){case"normal":w="edge-thickness-normal";break;case"thick":case"invisible":w="edge-thickness-thick";break;default:w=""}switch(r.pattern){case"solid":w+=" edge-pattern-solid";break;case"dotted":w+=" edge-pattern-dotted";break;case"dashed":w+=" edge-pattern-dashed"}const k=t.append("path").attr("d",m(p)).attr("id",r.id).attr("class"," "+w+(r.classes?" "+r.classes:"")).attr("style",r.style);let S="";(c().flowchart.arrowMarkerAbsolute||c().state.arrowMarkerAbsolute)&&(S=d(!0)),wt(k,r,S,o,i);let L={};return g&&(L.updatedPath=h),L.originalPath=r.points,L},"insertEdge"),Ct=e(t=>{const e=new Set;for(const r of t)switch(r){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(r)}return e},"expandAndDeduplicateDirections"),Bt=e((t,e,r)=>{const a=Ct(t),i=e.height+2*r.padding,s=i/2,n=e.width+2*s+r.padding,o=r.padding/2;return a.has("right")&&a.has("left")&&a.has("up")&&a.has("down")?[{x:0,y:0},{x:s,y:0},{x:n/2,y:2*o},{x:n-s,y:0},{x:n,y:0},{x:n,y:-i/3},{x:n+2*o,y:-i/2},{x:n,y:-2*i/3},{x:n,y:-i},{x:n-s,y:-i},{x:n/2,y:-i-2*o},{x:s,y:-i},{x:0,y:-i},{x:0,y:-2*i/3},{x:-2*o,y:-i/2},{x:0,y:-i/3}]:a.has("right")&&a.has("left")&&a.has("up")?[{x:s,y:0},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}]:a.has("right")&&a.has("left")&&a.has("down")?[{x:0,y:0},{x:s,y:-i},{x:n-s,y:-i},{x:n,y:0}]:a.has("right")&&a.has("up")&&a.has("down")?[{x:0,y:0},{x:n,y:-s},{x:n,y:-i+s},{x:0,y:-i}]:a.has("left")&&a.has("up")&&a.has("down")?[{x:n,y:0},{x:0,y:-s},{x:0,y:-i+s},{x:n,y:-i}]:a.has("right")&&a.has("left")?[{x:s,y:0},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i},{x:0,y:-i/2}]:a.has("up")&&a.has("down")?[{x:n/2,y:0},{x:0,y:-o},{x:s,y:-o},{x:s,y:-i+o},{x:0,y:-i+o},{x:n/2,y:-i},{x:n,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o},{x:n,y:-o}]:a.has("right")&&a.has("up")?[{x:0,y:0},{x:n,y:-s},{x:0,y:-i}]:a.has("right")&&a.has("down")?[{x:0,y:0},{x:n,y:0},{x:0,y:-i}]:a.has("left")&&a.has("up")?[{x:n,y:0},{x:0,y:-s},{x:n,y:-i}]:a.has("left")&&a.has("down")?[{x:n,y:0},{x:0,y:0},{x:n,y:-i}]:a.has("right")?[{x:s,y:-o},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i+o}]:a.has("left")?[{x:s,y:0},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i},{x:0,y:-i/2}]:a.has("up")?[{x:s,y:-o},{x:s,y:-i+o},{x:0,y:-i+o},{x:n/2,y:-i},{x:n,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o}]:a.has("down")?[{x:n/2,y:0},{x:0,y:-o},{x:s,y:-o},{x:s,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o},{x:n,y:-o}]:[{x:0,y:0}]},"getArrowPoints");function Rt(t,e){return t.intersect(e)}e(Rt,"intersectNode");var zt=Rt;function Ot(t,e,r,a){var i=t.x,s=t.y,n=i-a.x,o=s-a.y,l=Math.sqrt(e*e*o*o+r*r*n*n),c=Math.abs(e*r*n/l);a.x<i&&(c=-c);var d=Math.abs(e*r*o/l);return a.y<s&&(d=-d),{x:i+c,y:s+d}}e(Ot,"intersectEllipse");var At=Ot;function Mt(t,e,r){return At(t,e,e,r)}e(Mt,"intersectCircle");var Pt=Mt;function Yt(t,e,r,a){var i,s,n,o,l,c,d,h,g,y,u,p,x;if(i=e.y-t.y,n=t.x-e.x,l=e.x*t.y-t.x*e.y,g=i*r.x+n*r.y+l,y=i*a.x+n*a.y+l,!(0!==g&&0!==y&&jt(g,y)||(s=a.y-r.y,o=r.x-a.x,c=a.x*r.y-r.x*a.y,d=s*t.x+o*t.y+c,h=s*e.x+o*e.y+c,0!==d&&0!==h&&jt(d,h)||0===(u=i*o-s*n))))return p=Math.abs(u/2),{x:(x=n*c-o*l)<0?(x-p)/u:(x+p)/u,y:(x=s*l-i*c)<0?(x-p)/u:(x+p)/u}}function jt(t,e){return t*e>0}e(Yt,"intersectLine"),e(jt,"sameSign");var Ft=Yt,Wt=Xt;function Xt(t,e,r){var a=t.x,i=t.y,s=[],n=Number.POSITIVE_INFINITY,o=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach(function(t){n=Math.min(n,t.x),o=Math.min(o,t.y)}):(n=Math.min(n,e.x),o=Math.min(o,e.y));for(var l=a-t.width/2-n,c=i-t.height/2-o,d=0;d<e.length;d++){var h=e[d],g=e[d<e.length-1?d+1:0],y=Ft(t,r,{x:l+h.x,y:c+h.y},{x:l+g.x,y:c+g.y});y&&s.push(y)}return s.length?(s.length>1&&s.sort(function(t,e){var a=t.x-r.x,i=t.y-r.y,s=Math.sqrt(a*a+i*i),n=e.x-r.x,o=e.y-r.y,l=Math.sqrt(n*n+o*o);return s<l?-1:s===l?0:1}),s[0]):t}e(Xt,"intersectPolygon");var Ut={node:zt,circle:Pt,ellipse:At,polygon:Wt,rect:e((t,e)=>{var r,a,i=t.x,s=t.y,n=e.x-i,o=e.y-s,l=t.width/2,c=t.height/2;return Math.abs(o)*l>Math.abs(n)*c?(o<0&&(c=-c),r=0===o?0:c*n/o,a=c):(n<0&&(l=-l),r=l,a=0===n?0:l*o/n),{x:i+r,y:s+a}},"intersectRect")},Ht=e(async(t,e,r,i)=>{const s=c();let n;const o=e.useHtmlLabels||h(s);n=r||"node default";const l=t.insert("g").attr("class",n).attr("id",e.domId||e.id),d=l.insert("g").attr("class","label").attr("style",e.labelStyle);let y,u;y=void 0===e.labelText?"":"string"==typeof e.labelText?e.labelText:e.labelText[0],u="markdown"===e.labelType?g(d,f(m(y),s),{useHtmlLabels:o,width:e.width||s.flowchart.wrappingWidth,classes:"markdown-node-label"},s):await mt(d,f(m(y),s),e.labelStyle,!1,i);let p=u.getBBox();const x=e.padding/2;if(h(s)){const t=u.children[0],e=a(u);await w(t,y),p=t.getBoundingClientRect(),e.attr("width",p.width),e.attr("height",p.height)}return o?d.attr("transform","translate("+-p.width/2+", "+-p.height/2+")"):d.attr("transform","translate(0, "+-p.height/2+")"),e.centerLabel&&d.attr("transform","translate("+-p.width/2+", "+-p.height/2+")"),d.insert("rect",":first-child"),{shapeSvg:l,bbox:p,halfPadding:x,label:d}},"labelHelper"),Kt=e((t,e)=>{const r=e.node().getBBox();t.width=r.width,t.height=r.height},"updateNodeBounds");function qt(t,e,r,a){return t.insert("polygon",":first-child").attr("points",a.map(function(t){return t.x+","+t.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+r/2+")")}e(qt,"insertPolygonShape");var Zt=e(async(t,e)=>{e.useHtmlLabels||h(c())||(e.centerLabel=!0);const{shapeSvg:r,bbox:a,halfPadding:i}=await Ht(t,e,"node "+e.classes,!0);s.info("Classes = ",e.classes);const n=r.insert("rect",":first-child");return n.attr("rx",e.rx).attr("ry",e.ry).attr("x",-a.width/2-i).attr("y",-a.height/2-i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},r},"note"),Gt=e(t=>t?" "+t:"","formatClass"),Vt=e((t,e)=>`${e||"node default"}${Gt(t.classes)} ${Gt(t.class)}`,"getClassesFromNode"),Jt=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding+(a.height+e.padding),n=[{x:i/2,y:0},{x:i,y:-i/2},{x:i/2,y:-i},{x:0,y:-i/2}];s.info("Question main (Circle)");const o=qt(r,i,i,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return s.warn("Intersect called"),Ut.polygon(e,n,t)},r},"question"),Qt=e((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=[{x:0,y:14},{x:14,y:0},{x:0,y:-14},{x:-14,y:0}];return r.insert("polygon",":first-child").attr("points",a.map(function(t){return t.x+","+t.y}).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),e.width=28,e.height=28,e.intersect=function(t){return Ut.circle(e,14,t)},r},"choice"),te=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.height+e.padding,s=i/4,n=a.width+2*s+e.padding,o=[{x:s,y:0},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}],l=qt(r,n,i,o);return l.attr("style",e.style),Kt(e,l),e.intersect=function(t){return Ut.polygon(e,o,t)},r},"hexagon"),ee=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,void 0,!0),i=a.height+2*e.padding,s=i/2,n=a.width+2*s+e.padding,o=Bt(e.directions,a,e),l=qt(r,n,i,o);return l.attr("style",e.style),Kt(e,l),e.intersect=function(t){return Ut.polygon(e,o,t)},r},"block_arrow"),re=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-s/2,y:0},{x:i,y:0},{x:i,y:-s},{x:-s/2,y:-s},{x:0,y:-s/2}];return qt(r,i,s,n).attr("style",e.style),e.width=i+s,e.height=s,e.intersect=function(t){return Ut.polygon(e,n,t)},r},"rect_left_inv_arrow"),ae=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:s/6,y:-s}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"lean_right"),ie=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:2*s/6,y:0},{x:i+s/6,y:0},{x:i-2*s/6,y:-s},{x:-s/6,y:-s}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"lean_left"),se=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i+2*s/6,y:0},{x:i-s/6,y:-s},{x:s/6,y:-s}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"trapezoid"),ne=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:-2*s/6,y:-s}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"inv_trapezoid"),oe=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i+s/2,y:0},{x:i,y:-s/2},{x:i+s/2,y:-s},{x:0,y:-s}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"rect_right_inv_arrow"),le=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=i/2,n=s/(2.5+i/50),o=a.height+n+e.padding,l="M 0,"+n+" a "+s+","+n+" 0,0,0 "+i+" 0 a "+s+","+n+" 0,0,0 "+-i+" 0 l 0,"+o+" a "+s+","+n+" 0,0,0 "+i+" 0 l 0,"+-o,c=r.attr("label-offset-y",n).insert("path",":first-child").attr("style",e.style).attr("d",l).attr("transform","translate("+-i/2+","+-(o/2+n)+")");return Kt(e,c),e.intersect=function(t){const r=Ut.rect(e,t),a=r.x-e.x;if(0!=s&&(Math.abs(a)<e.width/2||Math.abs(a)==e.width/2&&Math.abs(r.y-e.y)>e.height/2-n)){let i=n*n*(1-a*a/(s*s));0!=i&&(i=Math.sqrt(i)),i=n-i,t.y-e.y>0&&(i=-i),r.y+=i}return r},r},"cylinder"),ce=e(async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await Ht(t,e,"node "+e.classes+" "+e.class,!0),n=r.insert("rect",":first-child"),o=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,c=e.positioned?-o/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(n.attr("class","basic label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",d).attr("width",o).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(ge(n,e.props.borders,o,l),t.delete("borders")),t.forEach(t=>{s.warn(`Unknown node property ${t}`)})}return Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},r},"rect"),de=e(async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await Ht(t,e,"node "+e.classes,!0),n=r.insert("rect",":first-child"),o=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,c=e.positioned?-o/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(n.attr("class","basic cluster composite label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",d).attr("width",o).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(ge(n,e.props.borders,o,l),t.delete("borders")),t.forEach(t=>{s.warn(`Unknown node property ${t}`)})}return Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},r},"composite"),he=e(async(t,e)=>{const{shapeSvg:r}=await Ht(t,e,"label",!0);s.trace("Classes = ",e.class);const a=r.insert("rect",":first-child");if(a.attr("width",0).attr("height",0),r.attr("class","label edgeLabel"),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(ge(a,e.props.borders,0,0),t.delete("borders")),t.forEach(t=>{s.warn(`Unknown node property ${t}`)})}return Kt(e,a),e.intersect=function(t){return Ut.rect(e,t)},r},"labelRect");function ge(t,r,a,i){const n=[],o=e(t=>{n.push(t,0)},"addBorder"),l=e(t=>{n.push(0,t)},"skipBorder");r.includes("t")?(s.debug("add top border"),o(a)):l(a),r.includes("r")?(s.debug("add right border"),o(i)):l(i),r.includes("b")?(s.debug("add bottom border"),o(a)):l(a),r.includes("l")?(s.debug("add left border"),o(i)):l(i),t.attr("stroke-dasharray",n.join(" "))}e(ge,"applyNodePropertyBorders");var ye=e(async(t,e)=>{let r;r=e.classes?"node "+e.classes:"node default";const i=t.insert("g").attr("class",r).attr("id",e.domId||e.id),n=i.insert("rect",":first-child"),o=i.insert("line"),l=i.insert("g").attr("class","label"),d=e.labelText.flat?e.labelText.flat():e.labelText;let g="";g="object"==typeof d?d[0]:d,s.info("Label text abc79",g,d,"object"==typeof d);const y=await mt(l,g,e.labelStyle,!0,!0);let u={width:0,height:0};if(h(c())){const t=y.children[0],e=a(y);u=t.getBoundingClientRect(),e.attr("width",u.width),e.attr("height",u.height)}s.info("Text 2",d);const p=d.slice(1,d.length);let x=y.getBBox();const b=await mt(l,p.join?p.join("<br/>"):p,e.labelStyle,!0,!0);if(h(c())){const t=b.children[0],e=a(b);u=t.getBoundingClientRect(),e.attr("width",u.width),e.attr("height",u.height)}const f=e.padding/2;return a(b).attr("transform","translate( "+(u.width>x.width?0:(x.width-u.width)/2)+", "+(x.height+f+5)+")"),a(y).attr("transform","translate( "+(u.width<x.width?0:-(x.width-u.width)/2)+", 0)"),u=l.node().getBBox(),l.attr("transform","translate("+-u.width/2+", "+(-u.height/2-f+3)+")"),n.attr("class","outer title-state").attr("x",-u.width/2-f).attr("y",-u.height/2-f).attr("width",u.width+e.padding).attr("height",u.height+e.padding),o.attr("class","divider").attr("x1",-u.width/2-f).attr("x2",u.width/2+f).attr("y1",-u.height/2-f+x.height+f).attr("y2",-u.height/2-f+x.height+f),Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},i},"rectWithTitle"),ue=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.height+e.padding,s=a.width+i/4+e.padding,n=r.insert("rect",":first-child").attr("style",e.style).attr("rx",i/2).attr("ry",i/2).attr("x",-s/2).attr("y",-i/2).attr("width",s).attr("height",i);return Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},r},"stadium"),pe=e(async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await Ht(t,e,Vt(e,void 0),!0),n=r.insert("circle",":first-child");return n.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),s.info("Circle main"),Kt(e,n),e.intersect=function(t){return s.info("Circle intersect",e,a.width/2+i,t),Ut.circle(e,a.width/2+i,t)},r},"circle"),xe=e(async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await Ht(t,e,Vt(e,void 0),!0),n=r.insert("g",":first-child"),o=n.insert("circle"),l=n.insert("circle");return n.attr("class",e.class),o.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i+5).attr("width",a.width+e.padding+10).attr("height",a.height+e.padding+10),l.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),s.info("DoubleCircle main"),Kt(e,o),e.intersect=function(t){return s.info("DoubleCircle intersect",e,a.width/2+i+5,t),Ut.circle(e,a.width/2+i+5,t)},r},"doublecircle"),be=e(async(t,e)=>{const{shapeSvg:r,bbox:a}=await Ht(t,e,Vt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i,y:0},{x:i,y:-s},{x:0,y:-s},{x:0,y:0},{x:-8,y:0},{x:i+8,y:0},{x:i+8,y:-s},{x:-8,y:-s},{x:-8,y:0}],o=qt(r,i,s,n);return o.attr("style",e.style),Kt(e,o),e.intersect=function(t){return Ut.polygon(e,n,t)},r},"subroutine"),fe=e((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child");return a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),Kt(e,a),e.intersect=function(t){return Ut.circle(e,7,t)},r},"start"),me=e((t,e,r)=>{const a=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);let i=70,s=10;"LR"===r&&(i=10,s=70);const n=a.append("rect").attr("x",-1*i/2).attr("y",-1*s/2).attr("width",i).attr("height",s).attr("class","fork-join");return Kt(e,n),e.height=e.height+e.padding/2,e.width=e.width+e.padding/2,e.intersect=function(t){return Ut.rect(e,t)},a},"forkJoin"),we={rhombus:Jt,composite:de,question:Jt,rect:ce,labelRect:he,rectWithTitle:ye,choice:Qt,circle:pe,doublecircle:xe,stadium:ue,hexagon:te,block_arrow:ee,rect_left_inv_arrow:re,lean_right:ae,lean_left:ie,trapezoid:se,inv_trapezoid:ne,rect_right_inv_arrow:oe,cylinder:le,start:fe,end:e((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child"),i=r.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),a.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),Kt(e,i),e.intersect=function(t){return Ut.circle(e,7,t)},r},"end"),note:Zt,subroutine:be,fork:me,join:me,class_box:e(async(t,e)=>{const r=e.padding/2;let i;i=e.classes?"node "+e.classes:"node default";const s=t.insert("g").attr("class",i).attr("id",e.domId||e.id),n=s.insert("rect",":first-child"),o=s.insert("line"),l=s.insert("line");let d=0,g=4;const y=s.insert("g").attr("class","label");let u=0;const p=e.classData.annotations?.[0],x=e.classData.annotations[0]?"«"+e.classData.annotations[0]+"»":"",b=await mt(y,x,e.labelStyle,!0,!0);let f=b.getBBox();if(h(c())){const t=b.children[0],e=a(b);f=t.getBoundingClientRect(),e.attr("width",f.width),e.attr("height",f.height)}e.classData.annotations[0]&&(g+=f.height+4,d+=f.width);let m=e.classData.label;void 0!==e.classData.type&&""!==e.classData.type&&(h(c())?m+="<"+e.classData.type+">":m+="<"+e.classData.type+">");const w=await mt(y,m,e.labelStyle,!0,!0);a(w).attr("class","classTitle");let k=w.getBBox();if(h(c())){const t=w.children[0],e=a(w);k=t.getBoundingClientRect(),e.attr("width",k.width),e.attr("height",k.height)}g+=k.height+4,k.width>d&&(d=k.width);const S=[];e.classData.members.forEach(async t=>{const r=t.getDisplayDetails();let i=r.displayText;h(c())&&(i=i.replace(/</g,"<").replace(/>/g,">"));const s=await mt(y,i,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0);let n=s.getBBox();if(h(c())){const t=s.children[0],e=a(s);n=t.getBoundingClientRect(),e.attr("width",n.width),e.attr("height",n.height)}n.width>d&&(d=n.width),g+=n.height+4,S.push(s)}),g+=8;const L=[];if(e.classData.methods.forEach(async t=>{const r=t.getDisplayDetails();let i=r.displayText;h(c())&&(i=i.replace(/</g,"<").replace(/>/g,">"));const s=await mt(y,i,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0);let n=s.getBBox();if(h(c())){const t=s.children[0],e=a(s);n=t.getBoundingClientRect(),e.attr("width",n.width),e.attr("height",n.height)}n.width>d&&(d=n.width),g+=n.height+4,L.push(s)}),g+=8,p){let t=(d-f.width)/2;a(b).attr("transform","translate( "+(-1*d/2+t)+", "+-1*g/2+")"),u=f.height+4}let _=(d-k.width)/2;return a(w).attr("transform","translate( "+(-1*d/2+_)+", "+(-1*g/2+u)+")"),u+=k.height+4,o.attr("class","divider").attr("x1",-d/2-r).attr("x2",d/2+r).attr("y1",-g/2-r+8+u).attr("y2",-g/2-r+8+u),u+=8,S.forEach(t=>{a(t).attr("transform","translate( "+-d/2+", "+(-1*g/2+u+4)+")");const e=t?.getBBox();u+=(e?.height??0)+4}),u+=8,l.attr("class","divider").attr("x1",-d/2-r).attr("x2",d/2+r).attr("y1",-g/2-r+8+u).attr("y2",-g/2-r+8+u),u+=8,L.forEach(t=>{a(t).attr("transform","translate( "+-d/2+", "+(-1*g/2+u)+")");const e=t?.getBBox();u+=(e?.height??0)+4}),n.attr("style",e.style).attr("class","outer title-state").attr("x",-d/2-r).attr("y",-g/2-r).attr("width",d+e.padding).attr("height",g+e.padding),Kt(e,n),e.intersect=function(t){return Ut.rect(e,t)},s},"class_box")},ke={},Se=e(async(t,e,r)=>{let a,i;if(e.link){let s;"sandbox"===c().securityLevel?s="_top":e.linkTarget&&(s=e.linkTarget||"_blank"),a=t.insert("svg:a").attr("xlink:href",e.link).attr("target",s),i=await we[e.shape](a,e,r)}else i=await we[e.shape](t,e,r),a=i;return e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),ke[e.id]=a,e.haveCallback&&ke[e.id].attr("class",ke[e.id].attr("class")+" clickable"),a},"insertNode"),Le=e(t=>{const e=ke[t.id];s.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");const r=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+r-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),r},"positionNode");function _e(t,e,a=!1){const i=t;let s="default";(i?.classes?.length||0)>0&&(s=(i?.classes??[]).join(" ")),s+=" flowchart-label";let n,o=0,l="";switch(i.type){case"round":o=5,l="rect";break;case"composite":o=0,l="composite",n=0;break;case"square":case"group":default:l="rect";break;case"diamond":l="question";break;case"hexagon":l="hexagon";break;case"block_arrow":l="block_arrow";break;case"odd":case"rect_left_inv_arrow":l="rect_left_inv_arrow";break;case"lean_right":l="lean_right";break;case"lean_left":l="lean_left";break;case"trapezoid":l="trapezoid";break;case"inv_trapezoid":l="inv_trapezoid";break;case"circle":l="circle";break;case"ellipse":l="ellipse";break;case"stadium":l="stadium";break;case"subroutine":l="subroutine";break;case"cylinder":l="cylinder";break;case"doublecircle":l="doublecircle"}const c=b(i?.styles??[]),d=i.label,h=i.size??{width:0,height:0,x:0,y:0},g=e.getDiagramId();return{labelStyle:c.labelStyle,shape:l,labelText:d,rx:o,ry:o,class:s,style:c.style,id:i.id,domId:g?`${g}-${i.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??r()?.block?.padding??0}}async function Ee(t,e,a){const i=_e(e,a,!1);if("group"===i.type)return;const s=r(),n=await Se(t,i,{config:s}),o=n.node().getBBox(),l=a.getBlock(i.id);l.size={width:o.width,height:o.height,x:0,y:0,node:n},a.setBlock(l),n.remove()}async function De(t,e,a){const i=_e(e,a,!0);if("space"!==a.getBlock(i.id).type){const a=r();await Se(t,i,{config:a}),e.intersect=i?.intersect,Le(i)}}async function $e(t,e,r,a){for(const i of e)await a(t,i,r),i.children&&await $e(t,i.children,r,a)}async function ve(t,e,r){await $e(t,e,r,Ee)}async function Te(t,e,r){await $e(t,e,r,De)}async function Ie(t,e,r,a,i){const s=new S({multigraph:!0,compound:!0});s.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(const t of r)t.size&&s.setNode(t.id,{width:t.size.width,height:t.size.height,intersect:t.intersect});for(const r of e)if(r.start&&r.end){const e=a.getBlock(r.start),n=a.getBlock(r.end);if(e?.size&&n?.size){const a=e.size,o=n.size,l=[{x:a.x,y:a.y},{x:a.x+(o.x-a.x)/2,y:a.y+(o.y-a.y)/2},{x:o.x,y:o.y}],c=i?`${i}-${r.id}`:r.id;Nt(t,{v:r.start,w:r.end,name:c},{...r,id:c,arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"},void 0,"block",s,i),r.label&&(await Et(t,{...r,label:r.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"}),$t({...r,x:l[1].x,y:l[1].y},{originalPath:l}))}}}e(_e,"getNodeFromBlock"),e(Ee,"calculateBlockSize"),e(De,"insertBlockPositioned"),e($e,"performOperations"),e(ve,"calculateBlockSizes"),e(Te,"insertBlocks"),e(Ie,"insertEdges");var Ne=e(function(t,e){return e.db.getClasses()},"getClasses"),Ce={parser:$,db:nt,renderer:{draw:e(async function(t,e,n,o){const{securityLevel:l,block:c}=r(),d=o.db;let h;d.setDiagramId(e),"sandbox"===l&&(h=a("#i"+e));const g=a("sandbox"===l?h.nodes()[0].contentDocument.body:"body"),y="sandbox"===l?g.select(`[id="${e}"]`):a(`[id="${e}"]`);ht(y,["point","circle","cross"],o.type,e);const u=d.getBlocks(),p=d.getBlocksFlat(),x=d.getEdges(),b=y.insert("g").attr("class","block");await ve(b,u,d);const f=ft(d);if(await Te(b,u,d),await Ie(b,x,p,d,e),f){const t=f,e=Math.max(1,Math.round(t.width/t.height*.125)),r=t.height+e+10,a=t.width+10,{useMaxWidth:n}=c;i(y,r,a,!!n),s.debug("Here Bounds",f,t),y.attr("viewBox",`${t.x-5} ${t.y-5} ${t.width+10} ${t.height+10}`)}},"draw"),getClasses:Ne},styles:lt};export{Ce as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{g as t,d as e}from"./chunk-YZCP3GAM-BleOO0o9.js";import{s as n,g as a,a as i,b as s,_ as r,c as o,d as l,l as h,e as d,f as p,h as u,i as y,j as g,w as b,k as f,m}from"./mermaid.core-BHSaFUkv.js";import"./index-CDfJgeHe.js";import"react/jsx-runtime";import"react";import"./settings-DgLs6IK_.js";import"./SubmissionDateField-D3AvKusK.js";import"./index-CH9DJEEq.js";import"./enums.js";import"./date-DabTuCYQ.js";import"./time-BPMFfIa-.js";import"./websocket-DCvEZ5Ma.js";import"./worksheet-ClM0CaBH.js";import"motion/react";import"react-dom";import"./index-BD_n8l03.js";import"swr";import"@ably/spaces";import"@ably/spaces/react";import"ably";import"ably/liveobjects";import"ably/react";import"@ably/spaces/dist/mjs/react";import"./purify.es-BkjUCQC6.js";import"./string-LeDn2fkG.js";import"./memoize-CPUrcYQl.js";var _=function(){var t=r(function(t,e,n,a){for(n=n||{},a=t.length;a--;n[t[a]]=e);return n},"o"),e=[1,24],n=[1,25],a=[1,26],i=[1,27],s=[1,28],o=[1,63],l=[1,64],h=[1,65],d=[1,66],p=[1,67],u=[1,68],y=[1,69],g=[1,29],b=[1,30],f=[1,31],m=[1,32],_=[1,33],x=[1,34],E=[1,35],S=[1,36],A=[1,37],C=[1,38],w=[1,39],O=[1,40],k=[1,41],T=[1,42],v=[1,43],R=[1,44],D=[1,45],N=[1,46],P=[1,47],j=[1,48],B=[1,50],M=[1,51],I=[1,52],L=[1,53],Y=[1,54],U=[1,55],F=[1,56],X=[1,57],z=[1,58],W=[1,59],Q=[1,60],$=[14,42],H=[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],q=[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],V=[1,82],G=[1,83],K=[1,84],J=[1,85],Z=[12,14,42],tt=[12,14,33,42],et=[12,14,33,42,76,77,79,80],nt=[12,33],at=[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],it={trace:r(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:r(function(t,e,n,a,i,s,r){var o=s.length-1;switch(i){case 3:a.setDirection("TB");break;case 4:a.setDirection("BT");break;case 5:a.setDirection("RL");break;case 6:a.setDirection("LR");break;case 8:case 9:case 10:case 11:case 12:a.setC4Type(s[o-3]);break;case 19:a.setTitle(s[o].substring(6)),this.$=s[o].substring(6);break;case 20:a.setAccDescription(s[o].substring(15)),this.$=s[o].substring(15);break;case 21:this.$=s[o].trim(),a.setTitle(this.$);break;case 22:case 23:this.$=s[o].trim(),a.setAccDescription(this.$);break;case 28:s[o].splice(2,0,"ENTERPRISE"),a.addPersonOrSystemBoundary(...s[o]),this.$=s[o];break;case 29:s[o].splice(2,0,"SYSTEM"),a.addPersonOrSystemBoundary(...s[o]),this.$=s[o];break;case 30:a.addPersonOrSystemBoundary(...s[o]),this.$=s[o];break;case 31:s[o].splice(2,0,"CONTAINER"),a.addContainerBoundary(...s[o]),this.$=s[o];break;case 32:a.addDeploymentNode("node",...s[o]),this.$=s[o];break;case 33:a.addDeploymentNode("nodeL",...s[o]),this.$=s[o];break;case 34:a.addDeploymentNode("nodeR",...s[o]),this.$=s[o];break;case 35:a.popBoundaryParseStack();break;case 39:a.addPersonOrSystem("person",...s[o]),this.$=s[o];break;case 40:a.addPersonOrSystem("external_person",...s[o]),this.$=s[o];break;case 41:a.addPersonOrSystem("system",...s[o]),this.$=s[o];break;case 42:a.addPersonOrSystem("system_db",...s[o]),this.$=s[o];break;case 43:a.addPersonOrSystem("system_queue",...s[o]),this.$=s[o];break;case 44:a.addPersonOrSystem("external_system",...s[o]),this.$=s[o];break;case 45:a.addPersonOrSystem("external_system_db",...s[o]),this.$=s[o];break;case 46:a.addPersonOrSystem("external_system_queue",...s[o]),this.$=s[o];break;case 47:a.addContainer("container",...s[o]),this.$=s[o];break;case 48:a.addContainer("container_db",...s[o]),this.$=s[o];break;case 49:a.addContainer("container_queue",...s[o]),this.$=s[o];break;case 50:a.addContainer("external_container",...s[o]),this.$=s[o];break;case 51:a.addContainer("external_container_db",...s[o]),this.$=s[o];break;case 52:a.addContainer("external_container_queue",...s[o]),this.$=s[o];break;case 53:a.addComponent("component",...s[o]),this.$=s[o];break;case 54:a.addComponent("component_db",...s[o]),this.$=s[o];break;case 55:a.addComponent("component_queue",...s[o]),this.$=s[o];break;case 56:a.addComponent("external_component",...s[o]),this.$=s[o];break;case 57:a.addComponent("external_component_db",...s[o]),this.$=s[o];break;case 58:a.addComponent("external_component_queue",...s[o]),this.$=s[o];break;case 60:a.addRel("rel",...s[o]),this.$=s[o];break;case 61:a.addRel("birel",...s[o]),this.$=s[o];break;case 62:a.addRel("rel_u",...s[o]),this.$=s[o];break;case 63:a.addRel("rel_d",...s[o]),this.$=s[o];break;case 64:a.addRel("rel_l",...s[o]),this.$=s[o];break;case 65:a.addRel("rel_r",...s[o]),this.$=s[o];break;case 66:a.addRel("rel_b",...s[o]),this.$=s[o];break;case 67:s[o].splice(0,1),a.addRel("rel",...s[o]),this.$=s[o];break;case 68:a.updateElStyle("update_el_style",...s[o]),this.$=s[o];break;case 69:a.updateRelStyle("update_rel_style",...s[o]),this.$=s[o];break;case 70:a.updateLayoutConfig("update_layout_config",...s[o]),this.$=s[o];break;case 71:this.$=[s[o]];break;case 72:s[o].unshift(s[o-1]),this.$=s[o];break;case 73:case 75:this.$=s[o].trim();break;case 74:let t={};t[s[o-1].trim()]=s[o].trim(),this.$=t;break;case 76:this.$=""}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],7:[1,6],8:[1,7],9:[1,8],10:4,11:[1,9],15:[1,10],16:[1,11],17:[1,12],18:[1,13]},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,7]},{1:[2,3]},{1:[2,4]},{1:[2,5]},{1:[2,6]},{12:[1,14]},{12:[1,15]},{12:[1,16]},{12:[1,17]},{12:[1,18]},{13:19,19:20,20:21,21:22,22:e,23:n,24:a,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{13:70,19:20,20:21,21:22,22:e,23:n,24:a,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{13:71,19:20,20:21,21:22,22:e,23:n,24:a,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{13:72,19:20,20:21,21:22,22:e,23:n,24:a,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{13:73,19:20,20:21,21:22,22:e,23:n,24:a,26:i,28:s,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{14:[1,74]},t($,[2,13],{43:23,29:49,30:61,32:62,20:75,34:o,36:l,37:h,38:d,39:p,40:u,41:y,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q}),t($,[2,14]),t(H,[2,16],{12:[1,76]}),t($,[2,36],{12:[1,77]}),t(q,[2,19]),t(q,[2,20]),{25:[1,78]},{27:[1,79]},t(q,[2,23]),{35:80,75:81,76:V,77:G,79:K,80:J},{35:86,75:81,76:V,77:G,79:K,80:J},{35:87,75:81,76:V,77:G,79:K,80:J},{35:88,75:81,76:V,77:G,79:K,80:J},{35:89,75:81,76:V,77:G,79:K,80:J},{35:90,75:81,76:V,77:G,79:K,80:J},{35:91,75:81,76:V,77:G,79:K,80:J},{35:92,75:81,76:V,77:G,79:K,80:J},{35:93,75:81,76:V,77:G,79:K,80:J},{35:94,75:81,76:V,77:G,79:K,80:J},{35:95,75:81,76:V,77:G,79:K,80:J},{35:96,75:81,76:V,77:G,79:K,80:J},{35:97,75:81,76:V,77:G,79:K,80:J},{35:98,75:81,76:V,77:G,79:K,80:J},{35:99,75:81,76:V,77:G,79:K,80:J},{35:100,75:81,76:V,77:G,79:K,80:J},{35:101,75:81,76:V,77:G,79:K,80:J},{35:102,75:81,76:V,77:G,79:K,80:J},{35:103,75:81,76:V,77:G,79:K,80:J},{35:104,75:81,76:V,77:G,79:K,80:J},t(Z,[2,59]),{35:105,75:81,76:V,77:G,79:K,80:J},{35:106,75:81,76:V,77:G,79:K,80:J},{35:107,75:81,76:V,77:G,79:K,80:J},{35:108,75:81,76:V,77:G,79:K,80:J},{35:109,75:81,76:V,77:G,79:K,80:J},{35:110,75:81,76:V,77:G,79:K,80:J},{35:111,75:81,76:V,77:G,79:K,80:J},{35:112,75:81,76:V,77:G,79:K,80:J},{35:113,75:81,76:V,77:G,79:K,80:J},{35:114,75:81,76:V,77:G,79:K,80:J},{35:115,75:81,76:V,77:G,79:K,80:J},{20:116,29:49,30:61,32:62,34:o,36:l,37:h,38:d,39:p,40:u,41:y,43:23,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q},{12:[1,118],33:[1,117]},{35:119,75:81,76:V,77:G,79:K,80:J},{35:120,75:81,76:V,77:G,79:K,80:J},{35:121,75:81,76:V,77:G,79:K,80:J},{35:122,75:81,76:V,77:G,79:K,80:J},{35:123,75:81,76:V,77:G,79:K,80:J},{35:124,75:81,76:V,77:G,79:K,80:J},{35:125,75:81,76:V,77:G,79:K,80:J},{14:[1,126]},{14:[1,127]},{14:[1,128]},{14:[1,129]},{1:[2,8]},t($,[2,15]),t(H,[2,17],{21:22,19:130,22:e,23:n,24:a,26:i,28:s}),t($,[2,37],{19:20,20:21,21:22,43:23,29:49,30:61,32:62,13:131,22:e,23:n,24:a,26:i,28:s,34:o,36:l,37:h,38:d,39:p,40:u,41:y,44:g,45:b,46:f,47:m,48:_,49:x,50:E,51:S,52:A,53:C,54:w,55:O,56:k,57:T,58:v,59:R,60:D,61:N,62:P,63:j,64:B,65:M,66:I,67:L,68:Y,69:U,70:F,71:X,72:z,73:W,74:Q}),t(q,[2,21]),t(q,[2,22]),t(Z,[2,39]),t(tt,[2,71],{75:81,35:132,76:V,77:G,79:K,80:J}),t(et,[2,73]),{78:[1,133]},t(et,[2,75]),t(et,[2,76]),t(Z,[2,40]),t(Z,[2,41]),t(Z,[2,42]),t(Z,[2,43]),t(Z,[2,44]),t(Z,[2,45]),t(Z,[2,46]),t(Z,[2,47]),t(Z,[2,48]),t(Z,[2,49]),t(Z,[2,50]),t(Z,[2,51]),t(Z,[2,52]),t(Z,[2,53]),t(Z,[2,54]),t(Z,[2,55]),t(Z,[2,56]),t(Z,[2,57]),t(Z,[2,58]),t(Z,[2,60]),t(Z,[2,61]),t(Z,[2,62]),t(Z,[2,63]),t(Z,[2,64]),t(Z,[2,65]),t(Z,[2,66]),t(Z,[2,67]),t(Z,[2,68]),t(Z,[2,69]),t(Z,[2,70]),{31:134,42:[1,135]},{12:[1,136]},{33:[1,137]},t(nt,[2,28]),t(nt,[2,29]),t(nt,[2,30]),t(nt,[2,31]),t(nt,[2,32]),t(nt,[2,33]),t(nt,[2,34]),{1:[2,9]},{1:[2,10]},{1:[2,11]},{1:[2,12]},t(H,[2,18]),t($,[2,38]),t(tt,[2,72]),t(et,[2,74]),t(Z,[2,24]),t(Z,[2,35]),t(at,[2,25]),t(at,[2,26],{12:[1,138]}),t(at,[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:r(function(t,e){if(!e.recoverable){var n=new Error(t);throw n.hash=e,n}this.trace(t)},"parseError"),parse:r(function(t){var e=this,n=[0],a=[],i=[null],s=[],o=this.table,l="",c=0,h=0,d=s.slice.call(arguments,1),p=Object.create(this.lexer),u={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(u.yy[y]=this.yy[y]);p.setInput(t,u.yy),u.yy.lexer=p,u.yy.parser=this,void 0===p.yylloc&&(p.yylloc={});var g=p.yylloc;s.push(g);var b=p.options&&p.options.ranges;function f(){var t;return"number"!=typeof(t=a.pop()||p.lex()||1)&&(t instanceof Array&&(t=(a=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof u.yy.parseError?this.parseError=u.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,r(function(t){n.length=n.length-2*t,i.length=i.length-t,s.length=s.length-t},"popStack"),r(f,"lex");for(var m,_,x,E,S,A,C,w,O={};;){if(_=n[n.length-1],this.defaultActions[_]?x=this.defaultActions[_]:(null==m&&(m=f()),x=o[_]&&o[_][m]),void 0===x||!x.length||!x[0]){var k="";for(S in w=[],o[_])this.terminals_[S]&&S>2&&w.push("'"+this.terminals_[S]+"'");k=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+w.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==m?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(k,{text:p.match,token:this.terminals_[m]||m,line:p.yylineno,loc:g,expected:w})}if(x[0]instanceof Array&&x.length>1)throw new Error("Parse Error: multiple actions possible at state: "+_+", token: "+m);switch(x[0]){case 1:n.push(m),i.push(p.yytext),s.push(p.yylloc),n.push(x[1]),m=null,h=p.yyleng,l=p.yytext,c=p.yylineno,g=p.yylloc;break;case 2:if(A=this.productions_[x[1]][1],O.$=i[i.length-A],O._$={first_line:s[s.length-(A||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(A||1)].first_column,last_column:s[s.length-1].last_column},b&&(O._$.range=[s[s.length-(A||1)].range[0],s[s.length-1].range[1]]),void 0!==(E=this.performAction.apply(O,[l,h,c,u.yy,x[1],i,s].concat(d))))return E;A&&(n=n.slice(0,-1*A*2),i=i.slice(0,-1*A),s=s.slice(0,-1*A)),n.push(this.productions_[x[1]][0]),i.push(O.$),s.push(O._$),C=o[n[n.length-2]][n[n.length-1]],n.push(C);break;case 3:return!0}}return!0},"parse")},st=function(){return{EOF:1,parseError:r(function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)},"parseError"),setInput:r(function(t,e){return this.yy=e||this.yy||{},this._input=t,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:r(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:r(function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var a=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),n.length-1&&(this.yylineno-=n.length-1);var i=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:n?(n.length===a.length?this.yylloc.first_column:0)+a[a.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:r(function(){return this._more=!0,this},"more"),reject:r(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:r(function(t){this.unput(this.match.slice(t))},"less"),pastInput:r(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:r(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:r(function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:r(function(t,e){var n,a,i;if(this.options.backtrack_lexer&&(i={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&&(i.yylloc.range=this.yylloc.range.slice(0))),(a=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,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(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack){for(var s in i)this[s]=i[s];return!1}return!1},"test_match"),next:r(function(){if(this.done)return this.EOF;var t,e,n,a;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),s=0;s<i.length;s++)if((n=this._input.match(this.rules[i[s]]))&&(!e||n[0].length>e[0].length)){if(e=n,a=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[s])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[a]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:r(function(){var t=this.next();return t||this.lex()},"lex"),begin:r(function(t){this.conditionStack.push(t)},"begin"),popState:r(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:r(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:r(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:r(function(t){this.begin(t)},"pushState"),stateStackSize:r(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:r(function(t,e,n,a){switch(n){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:case 73:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:case 16:case 70:break;case 14:c;break;case 15:return 12;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: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:case 53:return this.begin("rel_u"),66;case 54:case 55:return this.begin("rel_d"),67;case 56:case 57:return this.begin("rel_l"),68;case 58: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:case 79:this.popState(),this.popState();break;case 69:case 71:return 80;case 72:this.begin("string");break;case 74:case 80: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 81:return"LBRACE";case 82:return"RBRACE";case 83:return"SPACE";case 84:return"EOL";case 85:return 14}},"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:title\s[^#\n;]+)/,/^(?:accDescription\s[^#\n;]+)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:C4Context\b)/,/^(?:C4Container\b)/,/^(?:C4Component\b)/,/^(?:C4Dynamic\b)/,/^(?:C4Deployment\b)/,/^(?:Person_Ext\b)/,/^(?:Person\b)/,/^(?:SystemQueue_Ext\b)/,/^(?:SystemDb_Ext\b)/,/^(?:System_Ext\b)/,/^(?:SystemQueue\b)/,/^(?:SystemDb\b)/,/^(?:System\b)/,/^(?:Boundary\b)/,/^(?:Enterprise_Boundary\b)/,/^(?:System_Boundary\b)/,/^(?:ContainerQueue_Ext\b)/,/^(?:ContainerDb_Ext\b)/,/^(?:Container_Ext\b)/,/^(?:ContainerQueue\b)/,/^(?:ContainerDb\b)/,/^(?:Container\b)/,/^(?:Container_Boundary\b)/,/^(?:ComponentQueue_Ext\b)/,/^(?:ComponentDb_Ext\b)/,/^(?:Component_Ext\b)/,/^(?:ComponentQueue\b)/,/^(?:ComponentDb\b)/,/^(?:Component\b)/,/^(?:Deployment_Node\b)/,/^(?:Node\b)/,/^(?:Node_L\b)/,/^(?:Node_R\b)/,/^(?:Rel\b)/,/^(?:BiRel\b)/,/^(?:Rel_Up\b)/,/^(?:Rel_U\b)/,/^(?:Rel_Down\b)/,/^(?:Rel_D\b)/,/^(?:Rel_Left\b)/,/^(?:Rel_L\b)/,/^(?:Rel_Right\b)/,/^(?:Rel_R\b)/,/^(?:Rel_Back\b)/,/^(?:RelIndex\b)/,/^(?:UpdateElementStyle\b)/,/^(?:UpdateRelStyle\b)/,/^(?:UpdateLayoutConfig\b)/,/^(?:$)/,/^(?:[(][ ]*[,])/,/^(?:[(])/,/^(?:[)])/,/^(?:,,)/,/^(?:,)/,/^(?:[ ]*["]["])/,/^(?:[ ]*["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:[ ]*[\$])/,/^(?:[^=]*)/,/^(?:[=][ ]*["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:[^,]+)/,/^(?:\{)/,/^(?:\})/,/^(?:[\s]+)/,/^(?:[\n\r]+)/,/^(?:$)/],conditions:{acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},string_kv_value:{rules:[78,79],inclusive:!1},string_kv_key:{rules:[77],inclusive:!1},string_kv:{rules:[76],inclusive:!1},string:{rules:[73,74],inclusive:!1},attribute:{rules:[68,69,70,71,72,75,80],inclusive:!1},update_layout_config:{rules:[65,66,67,68],inclusive:!1},update_rel_style:{rules:[65,66,67,68],inclusive:!1},update_el_style:{rules:[65,66,67,68],inclusive:!1},rel_b:{rules:[65,66,67,68],inclusive:!1},rel_r:{rules:[65,66,67,68],inclusive:!1},rel_l:{rules:[65,66,67,68],inclusive:!1},rel_d:{rules:[65,66,67,68],inclusive:!1},rel_u:{rules:[65,66,67,68],inclusive:!1},rel_bi:{rules:[],inclusive:!1},rel:{rules:[65,66,67,68],inclusive:!1},node_r:{rules:[65,66,67,68],inclusive:!1},node_l:{rules:[65,66,67,68],inclusive:!1},node:{rules:[65,66,67,68],inclusive:!1},index:{rules:[],inclusive:!1},rel_index:{rules:[65,66,67,68],inclusive:!1},component_ext_queue:{rules:[65,66,67,68],inclusive:!1},component_ext_db:{rules:[65,66,67,68],inclusive:!1},component_ext:{rules:[65,66,67,68],inclusive:!1},component_queue:{rules:[65,66,67,68],inclusive:!1},component_db:{rules:[65,66,67,68],inclusive:!1},component:{rules:[65,66,67,68],inclusive:!1},container_boundary:{rules:[65,66,67,68],inclusive:!1},container_ext_queue:{rules:[65,66,67,68],inclusive:!1},container_ext_db:{rules:[65,66,67,68],inclusive:!1},container_ext:{rules:[65,66,67,68],inclusive:!1},container_queue:{rules:[65,66,67,68],inclusive:!1},container_db:{rules:[65,66,67,68],inclusive:!1},container:{rules:[65,66,67,68],inclusive:!1},birel:{rules:[65,66,67,68],inclusive:!1},system_boundary:{rules:[65,66,67,68],inclusive:!1},enterprise_boundary:{rules:[65,66,67,68],inclusive:!1},boundary:{rules:[65,66,67,68],inclusive:!1},system_ext_queue:{rules:[65,66,67,68],inclusive:!1},system_ext_db:{rules:[65,66,67,68],inclusive:!1},system_ext:{rules:[65,66,67,68],inclusive:!1},system_queue:{rules:[65,66,67,68],inclusive:!1},system_db:{rules:[65,66,67,68],inclusive:!1},system:{rules:[65,66,67,68],inclusive:!1},person_ext:{rules:[65,66,67,68],inclusive:!1},person:{rules:[65,66,67,68],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,81,82,83,84,85],inclusive:!0}}}}();function rt(){this.yy={}}return it.lexer=st,r(rt,"Parser"),rt.prototype=it,it.Parser=rt,new rt}();_.parser=_;var x,E=_,S=[],A=[""],C="global",w="",O=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],k=[],T="",v=!1,R=4,D=2,N=r(function(){return x},"getC4Type"),P=r(function(t){let e=y(t,o());x=e},"setC4Type"),j=r(function(t,e,n,a,i,s,r,o,l){if(null==t||null==e||null==n||null==a)return;let c={};const h=k.find(t=>t.from===e&&t.to===n);if(h?c=h:k.push(c),c.type=t,c.from=e,c.to=n,c.label={text:a},null==i)c.techn={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];c[t]={text:e}}else c.techn={text:i};if(null==s)c.descr={text:""};else if("object"==typeof s){let[t,e]=Object.entries(s)[0];c[t]={text:e}}else c.descr={text:s};if("object"==typeof r){let[t,e]=Object.entries(r)[0];c[t]=e}else c.sprite=r;if("object"==typeof o){let[t,e]=Object.entries(o)[0];c[t]=e}else c.tags=o;if("object"==typeof l){let[t,e]=Object.entries(l)[0];c[t]=e}else c.link=l;c.wrap=at()},"addRel"),B=r(function(t,e,n,a,i,s,r){if(null===e||null===n)return;let o={};const l=S.find(t=>t.alias===e);if(l&&e===l.alias?o=l:(o.alias=e,S.push(o)),o.label=null==n?{text:""}:{text:n},null==a)o.descr={text:""};else if("object"==typeof a){let[t,e]=Object.entries(a)[0];o[t]={text:e}}else o.descr={text:a};if("object"==typeof i){let[t,e]=Object.entries(i)[0];o[t]=e}else o.sprite=i;if("object"==typeof s){let[t,e]=Object.entries(s)[0];o[t]=e}else o.tags=s;if("object"==typeof r){let[t,e]=Object.entries(r)[0];o[t]=e}else o.link=r;o.typeC4Shape={text:t},o.parentBoundary=C,o.wrap=at()},"addPersonOrSystem"),M=r(function(t,e,n,a,i,s,r,o){if(null===e||null===n)return;let l={};const c=S.find(t=>t.alias===e);if(c&&e===c.alias?l=c:(l.alias=e,S.push(l)),l.label=null==n?{text:""}:{text:n},null==a)l.techn={text:""};else if("object"==typeof a){let[t,e]=Object.entries(a)[0];l[t]={text:e}}else l.techn={text:a};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof s){let[t,e]=Object.entries(s)[0];l[t]=e}else l.sprite=s;if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]=e}else l.tags=r;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.wrap=at(),l.typeC4Shape={text:t},l.parentBoundary=C},"addContainer"),I=r(function(t,e,n,a,i,s,r,o){if(null===e||null===n)return;let l={};const c=S.find(t=>t.alias===e);if(c&&e===c.alias?l=c:(l.alias=e,S.push(l)),l.label=null==n?{text:""}:{text:n},null==a)l.techn={text:""};else if("object"==typeof a){let[t,e]=Object.entries(a)[0];l[t]={text:e}}else l.techn={text:a};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof s){let[t,e]=Object.entries(s)[0];l[t]=e}else l.sprite=s;if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]=e}else l.tags=r;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.wrap=at(),l.typeC4Shape={text:t},l.parentBoundary=C},"addComponent"),L=r(function(t,e,n,a,i){if(null===t||null===e)return;let s={};const r=O.find(e=>e.alias===t);if(r&&t===r.alias?s=r:(s.alias=t,O.push(s)),s.label=null==e?{text:""}:{text:e},null==n)s.type={text:"system"};else if("object"==typeof n){let[t,e]=Object.entries(n)[0];s[t]={text:e}}else s.type={text:n};if("object"==typeof a){let[t,e]=Object.entries(a)[0];s[t]=e}else s.tags=a;if("object"==typeof i){let[t,e]=Object.entries(i)[0];s[t]=e}else s.link=i;s.parentBoundary=C,s.wrap=at(),w=C,C=t,A.push(w)},"addPersonOrSystemBoundary"),Y=r(function(t,e,n,a,i){if(null===t||null===e)return;let s={};const r=O.find(e=>e.alias===t);if(r&&t===r.alias?s=r:(s.alias=t,O.push(s)),s.label=null==e?{text:""}:{text:e},null==n)s.type={text:"container"};else if("object"==typeof n){let[t,e]=Object.entries(n)[0];s[t]={text:e}}else s.type={text:n};if("object"==typeof a){let[t,e]=Object.entries(a)[0];s[t]=e}else s.tags=a;if("object"==typeof i){let[t,e]=Object.entries(i)[0];s[t]=e}else s.link=i;s.parentBoundary=C,s.wrap=at(),w=C,C=t,A.push(w)},"addContainerBoundary"),U=r(function(t,e,n,a,i,s,r,o){if(null===e||null===n)return;let l={};const c=O.find(t=>t.alias===e);if(c&&e===c.alias?l=c:(l.alias=e,O.push(l)),l.label=null==n?{text:""}:{text:n},null==a)l.type={text:"node"};else if("object"==typeof a){let[t,e]=Object.entries(a)[0];l[t]={text:e}}else l.type={text:a};if(null==i)l.descr={text:""};else if("object"==typeof i){let[t,e]=Object.entries(i)[0];l[t]={text:e}}else l.descr={text:i};if("object"==typeof r){let[t,e]=Object.entries(r)[0];l[t]=e}else l.tags=r;if("object"==typeof o){let[t,e]=Object.entries(o)[0];l[t]=e}else l.link=o;l.nodeType=t,l.parentBoundary=C,l.wrap=at(),w=C,C=e,A.push(w)},"addDeploymentNode"),F=r(function(){C=w,A.pop(),w=A.pop(),A.push(w)},"popBoundaryParseStack"),X=r(function(t,e,n,a,i,s,r,o,l,c,h){let d=S.find(t=>t.alias===e);if(void 0!==d||(d=O.find(t=>t.alias===e),void 0!==d)){if(null!=n)if("object"==typeof n){let[t,e]=Object.entries(n)[0];d[t]=e}else d.bgColor=n;if(null!=a)if("object"==typeof a){let[t,e]=Object.entries(a)[0];d[t]=e}else d.fontColor=a;if(null!=i)if("object"==typeof i){let[t,e]=Object.entries(i)[0];d[t]=e}else d.borderColor=i;if(null!=s)if("object"==typeof s){let[t,e]=Object.entries(s)[0];d[t]=e}else d.shadowing=s;if(null!=r)if("object"==typeof r){let[t,e]=Object.entries(r)[0];d[t]=e}else d.shape=r;if(null!=o)if("object"==typeof o){let[t,e]=Object.entries(o)[0];d[t]=e}else d.sprite=o;if(null!=l)if("object"==typeof l){let[t,e]=Object.entries(l)[0];d[t]=e}else d.techn=l;if(null!=c)if("object"==typeof c){let[t,e]=Object.entries(c)[0];d[t]=e}else d.legendText=c;if(null!=h)if("object"==typeof h){let[t,e]=Object.entries(h)[0];d[t]=e}else d.legendSprite=h}},"updateElStyle"),z=r(function(t,e,n,a,i,s,r){const o=k.find(t=>t.from===e&&t.to===n);if(void 0!==o){if(null!=a)if("object"==typeof a){let[t,e]=Object.entries(a)[0];o[t]=e}else o.textColor=a;if(null!=i)if("object"==typeof i){let[t,e]=Object.entries(i)[0];o[t]=e}else o.lineColor=i;if(null!=s)if("object"==typeof s){let[t,e]=Object.entries(s)[0];o[t]=parseInt(e)}else o.offsetX=parseInt(s);if(null!=r)if("object"==typeof r){let[t,e]=Object.entries(r)[0];o[t]=parseInt(e)}else o.offsetY=parseInt(r)}},"updateRelStyle"),W=r(function(t,e,n){let a=R,i=D;if("object"==typeof e){const t=Object.values(e)[0];a=parseInt(t)}else a=parseInt(e);if("object"==typeof n){const t=Object.values(n)[0];i=parseInt(t)}else i=parseInt(n);a>=1&&(R=a),i>=1&&(D=i)},"updateLayoutConfig"),Q=r(function(){return R},"getC4ShapeInRow"),$=r(function(){return D},"getC4BoundaryInRow"),H=r(function(){return C},"getCurrentBoundaryParse"),q=r(function(){return w},"getParentBoundaryParse"),V=r(function(t){return null==t?S:S.filter(e=>e.parentBoundary===t)},"getC4ShapeArray"),G=r(function(t){return S.find(e=>e.alias===t)},"getC4Shape"),K=r(function(t){return Object.keys(V(t))},"getC4ShapeKeys"),J=r(function(t){return null==t?O:O.filter(e=>e.parentBoundary===t)},"getBoundaries"),Z=J,tt=r(function(){return k},"getRels"),et=r(function(){return T},"getTitle"),nt=r(function(t){v=t},"setWrap"),at=r(function(){return v},"autoWrap"),it=r(function(){S=[],O=[{alias:"global",label:{text:"global"},type:{text:"global"},tags:null,link:null,parentBoundary:""}],w="",C="global",A=[""],k=[],A=[""],T="",v=!1,R=4,D=2},"clear"),st=r(function(t){let e=y(t,o());T=e},"setTitle"),rt={addPersonOrSystem:B,addPersonOrSystemBoundary:L,addContainer:M,addContainerBoundary:Y,addComponent:I,addDeploymentNode:U,popBoundaryParseStack:F,addRel:j,updateElStyle:X,updateRelStyle:z,updateLayoutConfig:W,autoWrap:at,setWrap:nt,getC4ShapeArray:V,getC4Shape:G,getC4ShapeKeys:K,getBoundaries:J,getBoundarys:Z,getCurrentBoundaryParse:H,getParentBoundaryParse:q,getRels:tt,getTitle:et,getC4Type:N,getC4ShapeInRow:Q,getC4BoundaryInRow:$,setAccTitle:s,getAccTitle:i,getAccDescription:a,setAccDescription:n,getConfig:r(()=>o().c4,"getConfig"),clear:it,LINETYPE:{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},ARROWTYPE:{FILLED:0,OPEN:1},PLACEMENT:{LEFTOF:0,RIGHTOF:1,OVER:2},setTitle:st,setC4Type:P},ot=r(function(t,n){return e(t,n)},"drawRect"),lt=r(function(t,e,n,a,i,s){const r=t.append("image");r.attr("width",e),r.attr("height",n),r.attr("x",a),r.attr("y",i);let o=s.startsWith("data:image/png;base64")?s:g.sanitizeUrl(s);r.attr("xlink:href",o)},"drawImage"),ct=r((t,e,n,a)=>{const i=t.append("g");let s=0;for(let t of e){let e=t.textColor?t.textColor:"#444444",r=t.lineColor?t.lineColor:"#444444",o=t.offsetX?parseInt(t.offsetX):0,l=t.offsetY?parseInt(t.offsetY):0,c="";if(0===s){let e=i.append("line");e.attr("x1",t.startPoint.x),e.attr("y1",t.startPoint.y),e.attr("x2",t.endPoint.x),e.attr("y2",t.endPoint.y),e.attr("stroke-width","1"),e.attr("stroke",r),e.style("fill","none"),"rel_b"!==t.type&&e.attr("marker-end","url("+c+"#"+a+"-arrowhead)"),"birel"!==t.type&&"rel_b"!==t.type||e.attr("marker-start","url("+c+"#"+a+"-arrowend)"),s=-1}else{let e=i.append("path");e.attr("fill","none").attr("stroke-width","1").attr("stroke",r).attr("d","Mstartx,starty Qcontrolx,controly stopx,stopy ".replaceAll("startx",t.startPoint.x).replaceAll("starty",t.startPoint.y).replaceAll("controlx",t.startPoint.x+(t.endPoint.x-t.startPoint.x)/2-(t.endPoint.x-t.startPoint.x)/4).replaceAll("controly",t.startPoint.y+(t.endPoint.y-t.startPoint.y)/2).replaceAll("stopx",t.endPoint.x).replaceAll("stopy",t.endPoint.y)),"rel_b"!==t.type&&e.attr("marker-end","url("+c+"#"+a+"-arrowhead)"),"birel"!==t.type&&"rel_b"!==t.type||e.attr("marker-start","url("+c+"#"+a+"-arrowend)")}let h=n.messageFont();xt(n)(t.label.text,i,Math.min(t.startPoint.x,t.endPoint.x)+Math.abs(t.endPoint.x-t.startPoint.x)/2+o,Math.min(t.startPoint.y,t.endPoint.y)+Math.abs(t.endPoint.y-t.startPoint.y)/2+l,t.label.width,t.label.height,{fill:e},h),t.techn&&""!==t.techn.text&&(h=n.messageFont(),xt(n)("["+t.techn.text+"]",i,Math.min(t.startPoint.x,t.endPoint.x)+Math.abs(t.endPoint.x-t.startPoint.x)/2+o,Math.min(t.startPoint.y,t.endPoint.y)+Math.abs(t.endPoint.y-t.startPoint.y)/2+n.messageFontSize+5+l,Math.max(t.label.width,t.techn.width),t.techn.height,{fill:e,"font-style":"italic"},h))}},"drawRels"),ht=r(function(t,e,n){const a=t.append("g");let i=e.bgColor?e.bgColor:"none",s=e.borderColor?e.borderColor:"#444444",r=e.fontColor?e.fontColor:"black",o={"stroke-width":1,"stroke-dasharray":"7.0,7.0"};e.nodeType&&(o={"stroke-width":1});let l={x:e.x,y:e.y,fill:i,stroke:s,width:e.width,height:e.height,rx:2.5,ry:2.5,attrs:o};ot(a,l);let c=n.boundaryFont();c.fontWeight="bold",c.fontSize=c.fontSize+2,c.fontColor=r,xt(n)(e.label.text,a,e.x,e.y+e.label.Y,e.width,e.height,{fill:"#444444"},c),e.type&&""!==e.type.text&&(c=n.boundaryFont(),c.fontColor=r,xt(n)(e.type.text,a,e.x,e.y+e.type.Y,e.width,e.height,{fill:"#444444"},c)),e.descr&&""!==e.descr.text&&(c=n.boundaryFont(),c.fontSize=c.fontSize-2,c.fontColor=r,xt(n)(e.descr.text,a,e.x,e.y+e.descr.Y,e.width,e.height,{fill:"#444444"},c))},"drawBoundary"),dt=r(function(e,n,a){let i=n.bgColor?n.bgColor:a[n.typeC4Shape.text+"_bg_color"],s=n.borderColor?n.borderColor:a[n.typeC4Shape.text+"_border_color"],r=n.fontColor?n.fontColor:"#FFFFFF",o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACD0lEQVR4Xu2YoU4EMRCGT+4j8Ai8AhaH4QHgAUjQuFMECUgMIUgwJAgMhgQsAYUiJCiQIBBY+EITsjfTdme6V24v4c8vyGbb+ZjOtN0bNcvjQXmkH83WvYBWto6PLm6v7p7uH1/w2fXD+PBycX1Pv2l3IdDm/vn7x+dXQiAubRzoURa7gRZWd0iGRIiJbOnhnfYBQZNJjNbuyY2eJG8fkDE3bbG4ep6MHUAsgYxmE3nVs6VsBWJSGccsOlFPmLIViMzLOB7pCVO2AtHJMohH7Fh6zqitQK7m0rJvAVYgGcEpe//PLdDz65sM4pF9N7ICcXDKIB5Nv6j7tD0NoSdM2QrU9Gg0ewE1LqBhHR3BBdvj2vapnidjHxD/q6vd7Pvhr31AwcY8eXMTXAKECZZJFXuEq27aLgQK5uLMohCenGGuGewOxSjBvYBqeG6B+Nqiblggdjnc+ZXDy+FNFpFzw76O3UBAROuXh6FoiAcf5g9eTvUgzy0nWg6I8cXHRUpg5bOVBCo+KDpFajOf23GgPme7RSQ+lacIENUgJ6gg1k6HjgOlqnLqip4tEuhv0hNEMXUD0clyXE3p6pZA0S2nnvTlXwLJEZWlb7cTQH1+USgTN4VhAenm/wea1OCAOmqo6fE1WCb9WSKBah+rbUWPWAmE2Rvk0ApiB45eOyNAzU8xcTvj8KvkKEoOaIYeHNA3ZuygAvFMUO0AAAAASUVORK5CYII=";switch(n.typeC4Shape.text){case"person":o="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":o="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAAB6ElEQVR4Xu2YLY+EMBCG9+dWr0aj0Wg0Go1Go0+j8Xdv2uTCvv1gpt0ebHKPuhDaeW4605Z9mJvx4AdXUyTUdd08z+u6flmWZRnHsWkafk9DptAwDPu+f0eAYtu2PEaGWuj5fCIZrBAC2eLBAnRCsEkkxmeaJp7iDJ2QMDdHsLg8SxKFEJaAo8lAXnmuOFIhTMpxxKATebo4UiFknuNo4OniSIXQyRxEA3YsnjGCVEjVXD7yLUAqxBGUyPv/Y4W2beMgGuS7kVQIBycH0fD+oi5pezQETxdHKmQKGk1eQEYldK+jw5GxPfZ9z7Mk0Qnhf1W1m3w//EUn5BDmSZsbR44QQLBEqrBHqOrmSKaQAxdnLArCrxZcM7A7ZKs4ioRq8LFC+NpC3WCBJsvpVw5edm9iEXFuyNfxXAgSwfrFQ1c0iNda8AdejvUgnktOtJQQxmcfFzGglc5WVCj7oDgFqU18boeFSs52CUh8LE8BIVQDT1ABrB0HtgSEYlX5doJnCwv9TXocKCaKbnwhdDKPq4lf3SwU3HLq4V/+WYhHVMa/3b4IlfyikAduCkcBc7mQ3/z/Qq/cTuikhkzB12Ae/mcJC9U+Vo8Ej1gWAtgbeGgFsAMHr50BIWOLCbezvhpBFUdY6EJuJ/QDW0XoMX60zZ0AAAAASUVORK5CYII="}const l=e.append("g");l.attr("class","person-man");const c=t();switch(n.typeC4Shape.text){case"person":case"external_person":case"system":case"external_system":case"container":case"external_container":case"component":case"external_component":c.x=n.x,c.y=n.y,c.fill=i,c.width=n.width,c.height=n.height,c.stroke=s,c.rx=2.5,c.ry=2.5,c.attrs={"stroke-width":.5},ot(l,c);break;case"system_db":case"external_system_db":case"container_db":case"external_container_db":case"component_db":case"external_component_db":l.append("path").attr("fill",i).attr("stroke-width","0.5").attr("stroke",s).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",n.x).replaceAll("starty",n.y).replaceAll("half",n.width/2).replaceAll("height",n.height)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",s).attr("d","Mstartx,startyc0,10 half,10 half,10c0,0 half,0 half,-10".replaceAll("startx",n.x).replaceAll("starty",n.y).replaceAll("half",n.width/2));break;case"system_queue":case"external_system_queue":case"container_queue":case"external_container_queue":case"component_queue":case"external_component_queue":l.append("path").attr("fill",i).attr("stroke-width","0.5").attr("stroke",s).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",n.x).replaceAll("starty",n.y).replaceAll("width",n.width).replaceAll("half",n.height/2)),l.append("path").attr("fill","none").attr("stroke-width","0.5").attr("stroke",s).attr("d","Mstartx,startyc-5,0 -5,half -5,halfc0,half 5,half 5,half".replaceAll("startx",n.x+n.width).replaceAll("starty",n.y).replaceAll("half",n.height/2))}let h=_t(a,n.typeC4Shape.text);switch(l.append("text").attr("fill",r).attr("font-family",h.fontFamily).attr("font-size",h.fontSize-2).attr("font-style","italic").attr("lengthAdjust","spacing").attr("textLength",n.typeC4Shape.width).attr("x",n.x+n.width/2-n.typeC4Shape.width/2).attr("y",n.y+n.typeC4Shape.Y).text("<<"+n.typeC4Shape.text+">>"),n.typeC4Shape.text){case"person":case"external_person":lt(l,48,48,n.x+n.width/2-24,n.y+n.image.Y,o)}let d=a[n.typeC4Shape.text+"Font"]();return d.fontWeight="bold",d.fontSize=d.fontSize+2,d.fontColor=r,xt(a)(n.label.text,l,n.x,n.y+n.label.Y,n.width,n.height,{fill:r},d),d=a[n.typeC4Shape.text+"Font"](),d.fontColor=r,n.techn&&""!==n.techn?.text?xt(a)(n.techn.text,l,n.x,n.y+n.techn.Y,n.width,n.height,{fill:r,"font-style":"italic"},d):n.type&&""!==n.type.text&&xt(a)(n.type.text,l,n.x,n.y+n.type.Y,n.width,n.height,{fill:r,"font-style":"italic"},d),n.descr&&""!==n.descr.text&&(d=a.personFont(),d.fontColor=r,xt(a)(n.descr.text,l,n.x,n.y+n.descr.Y,n.width,n.height,{fill:r},d)),n.height},"drawC4Shape"),pt=r(function(t,e){t.append("defs").append("symbol").attr("id",e+"-database").attr("fill-rule","evenodd").attr("clip-rule","evenodd").append("path").attr("transform","scale(.5)").attr("d","M12.258.001l.256.004.255.005.253.008.251.01.249.012.247.015.246.016.242.019.241.02.239.023.236.024.233.027.231.028.229.031.225.032.223.034.22.036.217.038.214.04.211.041.208.043.205.045.201.046.198.048.194.05.191.051.187.053.183.054.18.056.175.057.172.059.168.06.163.061.16.063.155.064.15.066.074.033.073.033.071.034.07.034.069.035.068.035.067.035.066.035.064.036.064.036.062.036.06.036.06.037.058.037.058.037.055.038.055.038.053.038.052.038.051.039.05.039.048.039.047.039.045.04.044.04.043.04.041.04.04.041.039.041.037.041.036.041.034.041.033.042.032.042.03.042.029.042.027.042.026.043.024.043.023.043.021.043.02.043.018.044.017.043.015.044.013.044.012.044.011.045.009.044.007.045.006.045.004.045.002.045.001.045v17l-.001.045-.002.045-.004.045-.006.045-.007.045-.009.044-.011.045-.012.044-.013.044-.015.044-.017.043-.018.044-.02.043-.021.043-.023.043-.024.043-.026.043-.027.042-.029.042-.03.042-.032.042-.033.042-.034.041-.036.041-.037.041-.039.041-.04.041-.041.04-.043.04-.044.04-.045.04-.047.039-.048.039-.05.039-.051.039-.052.038-.053.038-.055.038-.055.038-.058.037-.058.037-.06.037-.06.036-.062.036-.064.036-.064.036-.066.035-.067.035-.068.035-.069.035-.07.034-.071.034-.073.033-.074.033-.15.066-.155.064-.16.063-.163.061-.168.06-.172.059-.175.057-.18.056-.183.054-.187.053-.191.051-.194.05-.198.048-.201.046-.205.045-.208.043-.211.041-.214.04-.217.038-.22.036-.223.034-.225.032-.229.031-.231.028-.233.027-.236.024-.239.023-.241.02-.242.019-.246.016-.247.015-.249.012-.251.01-.253.008-.255.005-.256.004-.258.001-.258-.001-.256-.004-.255-.005-.253-.008-.251-.01-.249-.012-.247-.015-.245-.016-.243-.019-.241-.02-.238-.023-.236-.024-.234-.027-.231-.028-.228-.031-.226-.032-.223-.034-.22-.036-.217-.038-.214-.04-.211-.041-.208-.043-.204-.045-.201-.046-.198-.048-.195-.05-.19-.051-.187-.053-.184-.054-.179-.056-.176-.057-.172-.059-.167-.06-.164-.061-.159-.063-.155-.064-.151-.066-.074-.033-.072-.033-.072-.034-.07-.034-.069-.035-.068-.035-.067-.035-.066-.035-.064-.036-.063-.036-.062-.036-.061-.036-.06-.037-.058-.037-.057-.037-.056-.038-.055-.038-.053-.038-.052-.038-.051-.039-.049-.039-.049-.039-.046-.039-.046-.04-.044-.04-.043-.04-.041-.04-.04-.041-.039-.041-.037-.041-.036-.041-.034-.041-.033-.042-.032-.042-.03-.042-.029-.042-.027-.042-.026-.043-.024-.043-.023-.043-.021-.043-.02-.043-.018-.044-.017-.043-.015-.044-.013-.044-.012-.044-.011-.045-.009-.044-.007-.045-.006-.045-.004-.045-.002-.045-.001-.045v-17l.001-.045.002-.045.004-.045.006-.045.007-.045.009-.044.011-.045.012-.044.013-.044.015-.044.017-.043.018-.044.02-.043.021-.043.023-.043.024-.043.026-.043.027-.042.029-.042.03-.042.032-.042.033-.042.034-.041.036-.041.037-.041.039-.041.04-.041.041-.04.043-.04.044-.04.046-.04.046-.039.049-.039.049-.039.051-.039.052-.038.053-.038.055-.038.056-.038.057-.037.058-.037.06-.037.061-.036.062-.036.063-.036.064-.036.066-.035.067-.035.068-.035.069-.035.07-.034.072-.034.072-.033.074-.033.151-.066.155-.064.159-.063.164-.061.167-.06.172-.059.176-.057.179-.056.184-.054.187-.053.19-.051.195-.05.198-.048.201-.046.204-.045.208-.043.211-.041.214-.04.217-.038.22-.036.223-.034.226-.032.228-.031.231-.028.234-.027.236-.024.238-.023.241-.02.243-.019.245-.016.247-.015.249-.012.251-.01.253-.008.255-.005.256-.004.258-.001.258.001zm-9.258 20.499v.01l.001.021.003.021.004.022.005.021.006.022.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.023.018.024.019.024.021.024.022.025.023.024.024.025.052.049.056.05.061.051.066.051.07.051.075.051.079.052.084.052.088.052.092.052.097.052.102.051.105.052.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.048.144.049.147.047.152.047.155.047.16.045.163.045.167.043.171.043.176.041.178.041.183.039.187.039.19.037.194.035.197.035.202.033.204.031.209.03.212.029.216.027.219.025.222.024.226.021.23.02.233.018.236.016.24.015.243.012.246.01.249.008.253.005.256.004.259.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.021.224-.024.22-.026.216-.027.212-.028.21-.031.205-.031.202-.034.198-.034.194-.036.191-.037.187-.039.183-.04.179-.04.175-.042.172-.043.168-.044.163-.045.16-.046.155-.046.152-.047.148-.048.143-.049.139-.049.136-.05.131-.05.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.053.083-.051.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.05.023-.024.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.023.01-.022.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.127l-.077.055-.08.053-.083.054-.085.053-.087.052-.09.052-.093.051-.095.05-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.045-.118.044-.12.043-.122.042-.124.042-.126.041-.128.04-.13.04-.132.038-.134.038-.135.037-.138.037-.139.035-.142.035-.143.034-.144.033-.147.032-.148.031-.15.03-.151.03-.153.029-.154.027-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.01-.179.008-.179.008-.181.006-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.006-.179-.008-.179-.008-.178-.01-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.027-.153-.029-.151-.03-.15-.03-.148-.031-.146-.032-.145-.033-.143-.034-.141-.035-.14-.035-.137-.037-.136-.037-.134-.038-.132-.038-.13-.04-.128-.04-.126-.041-.124-.042-.122-.042-.12-.044-.117-.043-.116-.045-.113-.045-.112-.046-.109-.047-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.05-.093-.052-.09-.051-.087-.052-.085-.053-.083-.054-.08-.054-.077-.054v4.127zm0-5.654v.011l.001.021.003.021.004.021.005.022.006.022.007.022.009.022.01.022.011.023.012.023.013.023.015.024.016.023.017.024.018.024.019.024.021.024.022.024.023.025.024.024.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.052.11.051.114.051.119.052.123.05.127.051.131.05.135.049.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.044.171.042.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.022.23.02.233.018.236.016.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.012.241-.015.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.048.139-.05.136-.049.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.051.051-.049.023-.025.023-.024.021-.025.02-.024.019-.024.018-.024.017-.024.015-.023.014-.023.013-.024.012-.022.01-.023.01-.023.008-.022.006-.022.006-.022.004-.021.004-.022.001-.021.001-.021v-4.139l-.077.054-.08.054-.083.054-.085.052-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.049-.105.048-.106.047-.109.047-.111.046-.114.045-.115.044-.118.044-.12.044-.122.042-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.035-.143.033-.144.033-.147.033-.148.031-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.025-.161.024-.162.023-.163.022-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.011-.178.009-.179.009-.179.007-.181.007-.182.005-.182.004-.184.003-.184.002h-.37l-.184-.002-.184-.003-.182-.004-.182-.005-.181-.007-.179-.007-.179-.009-.178-.009-.176-.011-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.022-.162-.023-.161-.024-.159-.025-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.031-.146-.033-.145-.033-.143-.033-.141-.035-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.04-.126-.041-.124-.042-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.047-.105-.048-.102-.049-.1-.049-.097-.05-.095-.051-.093-.051-.09-.051-.087-.053-.085-.052-.083-.054-.08-.054-.077-.054v4.139zm0-5.666v.011l.001.02.003.022.004.021.005.022.006.021.007.022.009.023.01.022.011.023.012.023.013.023.015.023.016.024.017.024.018.023.019.024.021.025.022.024.023.024.024.025.052.05.056.05.061.05.066.051.07.051.075.052.079.051.084.052.088.052.092.052.097.052.102.052.105.051.11.052.114.051.119.051.123.051.127.05.131.05.135.05.139.049.144.048.147.048.152.047.155.046.16.045.163.045.167.043.171.043.176.042.178.04.183.04.187.038.19.037.194.036.197.034.202.033.204.032.209.03.212.028.216.027.219.025.222.024.226.021.23.02.233.018.236.017.24.014.243.012.246.01.249.008.253.006.256.003.259.001.26-.001.257-.003.254-.006.25-.008.247-.01.244-.013.241-.014.237-.016.233-.018.231-.02.226-.022.224-.024.22-.025.216-.027.212-.029.21-.03.205-.032.202-.033.198-.035.194-.036.191-.037.187-.039.183-.039.179-.041.175-.042.172-.043.168-.044.163-.045.16-.045.155-.047.152-.047.148-.048.143-.049.139-.049.136-.049.131-.051.126-.05.123-.051.118-.052.114-.051.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.052.07-.051.065-.051.06-.051.056-.05.051-.049.023-.025.023-.025.021-.024.02-.024.019-.024.018-.024.017-.024.015-.023.014-.024.013-.023.012-.023.01-.022.01-.023.008-.022.006-.022.006-.022.004-.022.004-.021.001-.021.001-.021v-4.153l-.077.054-.08.054-.083.053-.085.053-.087.053-.09.051-.093.051-.095.051-.097.05-.1.049-.102.048-.105.048-.106.048-.109.046-.111.046-.114.046-.115.044-.118.044-.12.043-.122.043-.124.042-.126.041-.128.04-.13.039-.132.039-.134.038-.135.037-.138.036-.139.036-.142.034-.143.034-.144.033-.147.032-.148.032-.15.03-.151.03-.153.028-.154.028-.156.027-.158.026-.159.024-.161.024-.162.023-.163.023-.165.021-.166.02-.167.019-.169.018-.169.017-.171.016-.173.015-.173.014-.175.013-.175.012-.177.01-.178.01-.179.009-.179.007-.181.006-.182.006-.182.004-.184.003-.184.001-.185.001-.185-.001-.184-.001-.184-.003-.182-.004-.182-.006-.181-.006-.179-.007-.179-.009-.178-.01-.176-.01-.176-.012-.175-.013-.173-.014-.172-.015-.171-.016-.17-.017-.169-.018-.167-.019-.166-.02-.165-.021-.163-.023-.162-.023-.161-.024-.159-.024-.157-.026-.156-.027-.155-.028-.153-.028-.151-.03-.15-.03-.148-.032-.146-.032-.145-.033-.143-.034-.141-.034-.14-.036-.137-.036-.136-.037-.134-.038-.132-.039-.13-.039-.128-.041-.126-.041-.124-.041-.122-.043-.12-.043-.117-.044-.116-.044-.113-.046-.112-.046-.109-.046-.106-.048-.105-.048-.102-.048-.1-.05-.097-.049-.095-.051-.093-.051-.09-.052-.087-.052-.085-.053-.083-.053-.08-.054-.077-.054v4.153zm8.74-8.179l-.257.004-.254.005-.25.008-.247.011-.244.012-.241.014-.237.016-.233.018-.231.021-.226.022-.224.023-.22.026-.216.027-.212.028-.21.031-.205.032-.202.033-.198.034-.194.036-.191.038-.187.038-.183.04-.179.041-.175.042-.172.043-.168.043-.163.045-.16.046-.155.046-.152.048-.148.048-.143.048-.139.049-.136.05-.131.05-.126.051-.123.051-.118.051-.114.052-.11.052-.106.052-.101.052-.096.052-.092.052-.088.052-.083.052-.079.052-.074.051-.07.052-.065.051-.06.05-.056.05-.051.05-.023.025-.023.024-.021.024-.02.025-.019.024-.018.024-.017.023-.015.024-.014.023-.013.023-.012.023-.01.023-.01.022-.008.022-.006.023-.006.021-.004.022-.004.021-.001.021-.001.021.001.021.001.021.004.021.004.022.006.021.006.023.008.022.01.022.01.023.012.023.013.023.014.023.015.024.017.023.018.024.019.024.02.025.021.024.023.024.023.025.051.05.056.05.06.05.065.051.07.052.074.051.079.052.083.052.088.052.092.052.096.052.101.052.106.052.11.052.114.052.118.051.123.051.126.051.131.05.136.05.139.049.143.048.148.048.152.048.155.046.16.046.163.045.168.043.172.043.175.042.179.041.183.04.187.038.191.038.194.036.198.034.202.033.205.032.21.031.212.028.216.027.22.026.224.023.226.022.231.021.233.018.237.016.241.014.244.012.247.011.25.008.254.005.257.004.26.001.26-.001.257-.004.254-.005.25-.008.247-.011.244-.012.241-.014.237-.016.233-.018.231-.021.226-.022.224-.023.22-.026.216-.027.212-.028.21-.031.205-.032.202-.033.198-.034.194-.036.191-.038.187-.038.183-.04.179-.041.175-.042.172-.043.168-.043.163-.045.16-.046.155-.046.152-.048.148-.048.143-.048.139-.049.136-.05.131-.05.126-.051.123-.051.118-.051.114-.052.11-.052.106-.052.101-.052.096-.052.092-.052.088-.052.083-.052.079-.052.074-.051.07-.052.065-.051.06-.05.056-.05.051-.05.023-.025.023-.024.021-.024.02-.025.019-.024.018-.024.017-.023.015-.024.014-.023.013-.023.012-.023.01-.023.01-.022.008-.022.006-.023.006-.021.004-.022.004-.021.001-.021.001-.021-.001-.021-.001-.021-.004-.021-.004-.022-.006-.021-.006-.023-.008-.022-.01-.022-.01-.023-.012-.023-.013-.023-.014-.023-.015-.024-.017-.023-.018-.024-.019-.024-.02-.025-.021-.024-.023-.024-.023-.025-.051-.05-.056-.05-.06-.05-.065-.051-.07-.052-.074-.051-.079-.052-.083-.052-.088-.052-.092-.052-.096-.052-.101-.052-.106-.052-.11-.052-.114-.052-.118-.051-.123-.051-.126-.051-.131-.05-.136-.05-.139-.049-.143-.048-.148-.048-.152-.048-.155-.046-.16-.046-.163-.045-.168-.043-.172-.043-.175-.042-.179-.041-.183-.04-.187-.038-.191-.038-.194-.036-.198-.034-.202-.033-.205-.032-.21-.031-.212-.028-.216-.027-.22-.026-.224-.023-.226-.022-.231-.021-.233-.018-.237-.016-.241-.014-.244-.012-.247-.011-.25-.008-.254-.005-.257-.004-.26-.001-.26.001z")},"insertDatabaseIcon"),ut=r(function(t,e){t.append("defs").append("symbol").attr("id",e+"-computer").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M2 2v13h20v-13h-20zm18 11h-16v-9h16v9zm-10.228 6l.466-1h3.524l.467 1h-4.457zm14.228 3h-24l2-6h2.104l-1.33 4h18.45l-1.297-4h2.073l2 6zm-5-10h-14v-7h14v7z")},"insertComputerIcon"),yt=r(function(t,e){t.append("defs").append("symbol").attr("id",e+"-clock").attr("width","24").attr("height","24").append("path").attr("transform","scale(.5)").attr("d","M12 2c5.514 0 10 4.486 10 10s-4.486 10-10 10-10-4.486-10-10 4.486-10 10-10zm0-2c-6.627 0-12 5.373-12 12s5.373 12 12 12 12-5.373 12-12-5.373-12-12-12zm5.848 12.459c.202.038.202.333.001.372-1.907.361-6.045 1.111-6.547 1.111-.719 0-1.301-.582-1.301-1.301 0-.512.77-5.447 1.125-7.445.034-.192.312-.181.343.014l.985 6.238 5.394 1.011z")},"insertClockIcon"),gt=r(function(t,e){t.append("defs").append("marker").attr("id",e+"-arrowhead").attr("refX",9).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z")},"insertArrowHead"),bt=r(function(t,e){t.append("defs").append("marker").attr("id",e+"-arrowend").attr("refX",1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z")},"insertArrowEnd"),ft=r(function(t,e){t.append("defs").append("marker").attr("id",e+"-filled-head").attr("refX",18).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"insertArrowFilledHead"),mt=r(function(t,e){const n=t.append("defs").append("marker").attr("id",e+"-crosshead").attr("markerWidth",15).attr("markerHeight",8).attr("orient","auto").attr("refX",16).attr("refY",4);n.append("path").attr("fill","black").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 9,2 V 6 L16,4 Z"),n.append("path").attr("fill","none").attr("stroke","#000000").style("stroke-dasharray","0, 0").attr("stroke-width","1px").attr("d","M 0,1 L 6,7 M 6,1 L 0,7")},"insertArrowCrossHead"),_t=r((t,e)=>({fontFamily:t[e+"FontFamily"],fontSize:t[e+"FontSize"],fontWeight:t[e+"FontWeight"]}),"getC4ShapeFont"),xt=function(){function t(t,e,n,i,s,r,o){a(e.append("text").attr("x",n+s/2).attr("y",i+r/2+5).style("text-anchor","middle").text(t),o)}function e(t,e,n,i,s,r,o,l){const{fontSize:c,fontFamily:h,fontWeight:d}=l,p=t.split(f.lineBreakRegex);for(let t=0;t<p.length;t++){const r=t*c-c*(p.length-1)/2,l=e.append("text").attr("x",n+s/2).attr("y",i).style("text-anchor","middle").attr("dominant-baseline","middle").style("font-size",c).style("font-weight",d).style("font-family",h);l.append("tspan").attr("dy",r).text(p[t]).attr("alignment-baseline","mathematical"),a(l,o)}}function n(t,n,i,s,r,o,l,c){const h=n.append("switch"),d=h.append("foreignObject").attr("x",i).attr("y",s).attr("width",r).attr("height",o).append("xhtml:div").style("display","table").style("height","100%").style("width","100%");d.append("div").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(t),e(t,h,i,s,r,0,l,c),a(d,l)}function a(t,e){for(const n in e)e.hasOwnProperty(n)&&t.attr(n,e[n])}return r(t,"byText"),r(e,"byTspan"),r(n,"byFo"),r(a,"_setTextAttrs"),function(a){return"fo"===a.textPlacement?n:"old"===a.textPlacement?t:e}}(),Et={drawRect:ot,drawBoundary:ht,drawC4Shape:dt,drawRels:ct,drawImage:lt,insertArrowHead:gt,insertArrowEnd:bt,insertArrowFilledHead:ft,insertArrowCrossHead:mt,insertDatabaseIcon:pt,insertComputerIcon:ut,insertClockIcon:yt},St=0,At=0,Ct=4,wt=2;_.yy=rt;var Ot={},kt=class{static{r(this,"Bounds")}constructor(t){this.name="",this.data={},this.data.startx=void 0,this.data.stopx=void 0,this.data.starty=void 0,this.data.stopy=void 0,this.data.widthLimit=void 0,this.nextData={},this.nextData.startx=void 0,this.nextData.stopx=void 0,this.nextData.starty=void 0,this.nextData.stopy=void 0,this.nextData.cnt=0,Tt(t.db.getConfig())}setData(t,e,n,a){this.nextData.startx=this.data.startx=t,this.nextData.stopx=this.data.stopx=e,this.nextData.starty=this.data.starty=n,this.nextData.stopy=this.data.stopy=a}updateVal(t,e,n,a){void 0===t[e]?t[e]=n:t[e]=a(n,t[e])}insert(t){this.nextData.cnt=this.nextData.cnt+1;let e=this.nextData.startx===this.nextData.stopx?this.nextData.stopx+t.margin:this.nextData.stopx+2*t.margin,n=e+t.width,a=this.nextData.starty+2*t.margin,i=a+t.height;(e>=this.data.widthLimit||n>=this.data.widthLimit||this.nextData.cnt>Ct)&&(e=this.nextData.startx+t.margin+Ot.nextLinePaddingX,a=this.nextData.stopy+2*t.margin,this.nextData.stopx=n=e+t.width,this.nextData.starty=this.nextData.stopy,this.nextData.stopy=i=a+t.height,this.nextData.cnt=1),t.x=e,t.y=a,this.updateVal(this.data,"startx",e,Math.min),this.updateVal(this.data,"starty",a,Math.min),this.updateVal(this.data,"stopx",n,Math.max),this.updateVal(this.data,"stopy",i,Math.max),this.updateVal(this.nextData,"startx",e,Math.min),this.updateVal(this.nextData,"starty",a,Math.min),this.updateVal(this.nextData,"stopx",n,Math.max),this.updateVal(this.nextData,"stopy",i,Math.max)}init(t){this.name="",this.data={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,widthLimit:void 0},this.nextData={startx:void 0,stopx:void 0,starty:void 0,stopy:void 0,cnt:0},Tt(t.db.getConfig())}bumpLastMargin(t){this.data.stopx+=t,this.data.stopy+=t}},Tt=r(function(t){p(Ot,t),t.fontFamily&&(Ot.personFontFamily=Ot.systemFontFamily=Ot.messageFontFamily=t.fontFamily),t.fontSize&&(Ot.personFontSize=Ot.systemFontSize=Ot.messageFontSize=t.fontSize),t.fontWeight&&(Ot.personFontWeight=Ot.systemFontWeight=Ot.messageFontWeight=t.fontWeight)},"setConf"),vt=r((t,e)=>({fontFamily:t[e+"FontFamily"],fontSize:t[e+"FontSize"],fontWeight:t[e+"FontWeight"]}),"c4ShapeFont"),Rt=r(t=>({fontFamily:t.boundaryFontFamily,fontSize:t.boundaryFontSize,fontWeight:t.boundaryFontWeight}),"boundaryFont"),Dt=r(t=>({fontFamily:t.messageFontFamily,fontSize:t.messageFontSize,fontWeight:t.messageFontWeight}),"messageFont");function Nt(t,e,n,a,i){if(!e[t].width)if(n)e[t].text=b(e[t].text,i,a),e[t].textLines=e[t].text.split(f.lineBreakRegex).length,e[t].width=i,e[t].height=m(e[t].text,a);else{let n=e[t].text.split(f.lineBreakRegex);e[t].textLines=n.length;let i=0;e[t].height=0,e[t].width=0;for(const s of n)e[t].width=Math.max(u(s,a),e[t].width),i=m(s,a),e[t].height=e[t].height+i}}r(Nt,"calcC4ShapeTextWH");var Pt=r(function(t,e,n){e.x=n.data.startx,e.y=n.data.starty,e.width=n.data.stopx-n.data.startx,e.height=n.data.stopy-n.data.starty,e.label.y=Ot.c4ShapeMargin-35;let a=e.wrap&&Ot.wrap,i=Rt(Ot);i.fontSize=i.fontSize+2,i.fontWeight="bold",Nt("label",e,a,i,u(e.label.text,i)),Et.drawBoundary(t,e,Ot)},"drawBoundary"),jt=r(function(t,e,n,a){let i=0;for(const s of a){i=0;const a=n[s];let r=vt(Ot,a.typeC4Shape.text);switch(r.fontSize=r.fontSize-2,a.typeC4Shape.width=u("«"+a.typeC4Shape.text+"»",r),a.typeC4Shape.height=r.fontSize+2,a.typeC4Shape.Y=Ot.c4ShapePadding,i=a.typeC4Shape.Y+a.typeC4Shape.height-4,a.image={width:0,height:0,Y:0},a.typeC4Shape.text){case"person":case"external_person":a.image.width=48,a.image.height=48,a.image.Y=i,i=a.image.Y+a.image.height}a.sprite&&(a.image.width=48,a.image.height=48,a.image.Y=i,i=a.image.Y+a.image.height);let o=a.wrap&&Ot.wrap,l=Ot.width-2*Ot.c4ShapePadding,c=vt(Ot,a.typeC4Shape.text);if(c.fontSize=c.fontSize+2,c.fontWeight="bold",Nt("label",a,o,c,l),a.label.Y=i+8,i=a.label.Y+a.label.height,a.type&&""!==a.type.text){a.type.text="["+a.type.text+"]",Nt("type",a,o,vt(Ot,a.typeC4Shape.text),l),a.type.Y=i+5,i=a.type.Y+a.type.height}else if(a.techn&&""!==a.techn.text){a.techn.text="["+a.techn.text+"]",Nt("techn",a,o,vt(Ot,a.techn.text),l),a.techn.Y=i+5,i=a.techn.Y+a.techn.height}let h=i,d=a.label.width;if(a.descr&&""!==a.descr.text){Nt("descr",a,o,vt(Ot,a.typeC4Shape.text),l),a.descr.Y=i+20,i=a.descr.Y+a.descr.height,d=Math.max(a.label.width,a.descr.width),h=i-5*a.descr.textLines}d+=Ot.c4ShapePadding,a.width=Math.max(a.width||Ot.width,d,Ot.width),a.height=Math.max(a.height||Ot.height,h,Ot.height),a.margin=a.margin||Ot.c4ShapeMargin,t.insert(a),Et.drawC4Shape(e,a,Ot)}t.bumpLastMargin(Ot.c4ShapeMargin)},"drawC4ShapeArray"),Bt=class{static{r(this,"Point")}constructor(t,e){this.x=t,this.y=e}},Mt=r(function(t,e){let n=t.x,a=t.y,i=e.x,s=e.y,r=n+t.width/2,o=a+t.height/2,l=Math.abs(n-i),c=Math.abs(a-s),h=c/l,d=t.height/t.width,p=null;return a==s&&n<i?p=new Bt(n+t.width,o):a==s&&n>i?p=new Bt(n,o):n==i&&a<s?p=new Bt(r,a+t.height):n==i&&a>s&&(p=new Bt(r,a)),n>i&&a<s?p=d>=h?new Bt(n,o+h*t.width/2):new Bt(r-l/c*t.height/2,a+t.height):n<i&&a<s?p=d>=h?new Bt(n+t.width,o+h*t.width/2):new Bt(r+l/c*t.height/2,a+t.height):n<i&&a>s?p=d>=h?new Bt(n+t.width,o-h*t.width/2):new Bt(r+t.height/2*l/c,a):n>i&&a>s&&(p=d>=h?new Bt(n,o-t.width/2*h):new Bt(r-t.height/2*l/c,a)),p},"getIntersectPoint"),It=r(function(t,e){let n={x:0,y:0};n.x=e.x+e.width/2,n.y=e.y+e.height/2;let a=Mt(t,n);return n.x=t.x+t.width/2,n.y=t.y+t.height/2,{startPoint:a,endPoint:Mt(e,n)}},"getIntersectPoints"),Lt=r(function(t,e,n,a,i){let s=0;for(let t of e){s+=1;let e=t.wrap&&Ot.wrap,i=Dt(Ot);"C4Dynamic"===a.db.getC4Type()&&(t.label.text=s+": "+t.label.text);let r=u(t.label.text,i);Nt("label",t,e,i,r),t.techn&&""!==t.techn.text&&(r=u(t.techn.text,i),Nt("techn",t,e,i,r)),t.descr&&""!==t.descr.text&&(r=u(t.descr.text,i),Nt("descr",t,e,i,r));let o=n(t.from),l=n(t.to),c=It(o,l);t.startPoint=c.startPoint,t.endPoint=c.endPoint}Et.drawRels(t,e,Ot,i)},"drawRels");function Yt(t,e,n,a,i){let s=new kt(i);s.data.widthLimit=n.data.widthLimit/Math.min(wt,a.length);for(let[r,o]of a.entries()){let a=0;o.image={width:0,height:0,Y:0},o.sprite&&(o.image.width=48,o.image.height=48,o.image.Y=a,a=o.image.Y+o.image.height);let l=o.wrap&&Ot.wrap,c=Rt(Ot);if(c.fontSize=c.fontSize+2,c.fontWeight="bold",Nt("label",o,l,c,s.data.widthLimit),o.label.Y=a+8,a=o.label.Y+o.label.height,o.type&&""!==o.type.text){o.type.text="["+o.type.text+"]",Nt("type",o,l,Rt(Ot),s.data.widthLimit),o.type.Y=a+5,a=o.type.Y+o.type.height}if(o.descr&&""!==o.descr.text){let t=Rt(Ot);t.fontSize=t.fontSize-2,Nt("descr",o,l,t,s.data.widthLimit),o.descr.Y=a+20,a=o.descr.Y+o.descr.height}if(0==r||r%wt===0){let t=n.data.startx+Ot.diagramMarginX,e=n.data.stopy+Ot.diagramMarginY+a;s.setData(t,t,e,e)}else{let t=s.data.stopx!==s.data.startx?s.data.stopx+Ot.diagramMarginX:s.data.startx,e=s.data.starty;s.setData(t,t,e,e)}s.name=o.alias;let h=i.db.getC4ShapeArray(o.alias),d=i.db.getC4ShapeKeys(o.alias);d.length>0&&jt(s,t,h,d),e=o.alias;let p=i.db.getBoundaries(e);p.length>0&&Yt(t,e,s,p,i),"global"!==o.alias&&Pt(t,o,s),n.data.stopy=Math.max(s.data.stopy+Ot.c4ShapeMargin,n.data.stopy),n.data.stopx=Math.max(s.data.stopx+Ot.c4ShapeMargin,n.data.stopx),St=Math.max(St,n.data.stopx),At=Math.max(At,n.data.stopy)}}r(Yt,"drawInsideBoundary");var Ut={drawPersonOrSystemArray:jt,drawBoundary:Pt,setConf:Tt,draw:r(function(t,e,n,a){Ot=o().c4;const i=o().securityLevel;let s;"sandbox"===i&&(s=l("#i"+e));const r=l("sandbox"===i?s.nodes()[0].contentDocument.body:"body");let c=a.db;a.db.setWrap(Ot.wrap),Ct=c.getC4ShapeInRow(),wt=c.getC4BoundaryInRow(),h.debug(`C:${JSON.stringify(Ot,null,2)}`);const p="sandbox"===i?r.select(`[id="${e}"]`):l(`[id="${e}"]`);Et.insertComputerIcon(p,e),Et.insertDatabaseIcon(p,e),Et.insertClockIcon(p,e);let u=new kt(a);u.setData(Ot.diagramMarginX,Ot.diagramMarginX,Ot.diagramMarginY,Ot.diagramMarginY),u.data.widthLimit=screen.availWidth,St=Ot.diagramMarginX,At=Ot.diagramMarginY;const y=a.db.getTitle();Yt(p,"",u,a.db.getBoundaries(""),a),Et.insertArrowHead(p,e),Et.insertArrowEnd(p,e),Et.insertArrowCrossHead(p,e),Et.insertArrowFilledHead(p,e),Lt(p,a.db.getRels(),a.db.getC4Shape,a,e),u.data.stopx=St,u.data.stopy=At;const g=u.data;let b=g.stopy-g.starty+2*Ot.diagramMarginY;const f=g.stopx-g.startx+2*Ot.diagramMarginX;y&&p.append("text").text(y).attr("x",(g.stopx-g.startx)/2-4*Ot.diagramMarginX).attr("y",g.starty+Ot.diagramMarginY),d(p,b,f,Ot.useMaxWidth);const m=y?60:0;p.attr("viewBox",g.startx-Ot.diagramMarginX+" -"+(Ot.diagramMarginY+m)+" "+f+" "+(b+m)),h.debug("models:",g)},"draw")},Ft={parser:E,db:rt,renderer:Ut,styles:r(t=>`.person {\n stroke: ${t.personBorder};\n fill: ${t.personBkg};\n }\n`,"getStyles"),init:r(({c4:t,wrap:e})=>{Ut.setConf(t),rt.setWrap(e)},"init")};export{Ft as diagram};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{U as r,C as a}from"./mermaid.core-BHSaFUkv.js";const o=(o,s)=>r.lang.round(a.parse(o)[s]);export{o as c};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{_ as c}from"./mermaid.core-
|
|
1
|
+
import{_ as c}from"./mermaid.core-BHSaFUkv.js";function e(c,e){c.accDescr&&e.setAccDescription?.(c.accDescr),c.accTitle&&e.setAccTitle?.(c.accTitle),c.title&&e.setDiagramTitle?.(c.title)}c(e,"populateCommonDb");export{e as p};
|