@softistx/pulsarix-widget 0.9.1 → 0.10.1
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/README.md +39 -27
- package/dist/chunks/{abnfDiagram-XWFEHMT6.xef4vppv.js → abnfDiagram-XWFEHMT6.9n16jbeh.js} +1 -1
- package/dist/chunks/architecture-WOLXFQ4H.04w48nbq.js +1 -0
- package/dist/chunks/architectureDiagram-CSQXQB3N.3c7xm6kb.js +36 -0
- package/dist/chunks/{blockDiagram-BEDRHYPZ.wgdr8xfr.js → blockDiagram-BEDRHYPZ.b7d9kkgr.js} +11 -11
- package/dist/chunks/{c4Diagram-M2UUVUY5.t09pndbz.js → c4Diagram-M2UUVUY5.f883rrpb.js} +3 -3
- package/dist/chunks/{chat-markdown-CQ4fSIYN.cv3fprzq.js → chat-markdown-BSu4FB_l.ngsfz1hc.js} +29 -29
- package/dist/chunks/{classDiagram-v2-KXABOMEV.9yfjtevj.js → classDiagram-v2-KXABOMEV.6gcf0jbx.js} +8 -8
- package/dist/chunks/cose-bilkent-JH36ORCC.900yznpf.js +1 -0
- package/dist/chunks/cynefin-EF2NZ3EQ.jp3enwcw.js +1 -0
- package/dist/chunks/{cynefinDiagram-NJNITYFG.k6mhek0s.js → cynefinDiagram-NJNITYFG.7y6esx64.js} +1 -1
- package/dist/chunks/{dagre-KIHZ2IZ3.sqeg911s.js → dagre-KIHZ2IZ3.2xtjsjjb.js} +2 -2
- package/dist/chunks/{diagram-7YQZDPLS.k1qvmctj.js → diagram-7YQZDPLS.5a4btxfh.js} +2 -2
- package/dist/chunks/{diagram-QBROCOUO.v7fe7e4g.js → diagram-QBROCOUO.je55sz0f.js} +24 -24
- package/dist/chunks/{diagram-RJJCUUZO.12s15pm6.js → diagram-RJJCUUZO.19nj7yqv.js} +4 -4
- package/dist/chunks/{diagram-WERXNKYE.tmrcv4we.js → diagram-WERXNKYE.h15fxc8e.js} +2 -2
- package/dist/chunks/diagram-YHHI257C.rjb588jf.js +3 -0
- package/dist/chunks/{diagram-YR4HJLHV.nytxr7pa.js → diagram-YR4HJLHV.5cj602t4.js} +1 -1
- package/dist/chunks/{ebnfDiagram-N527522P.6eqw92nv.js → ebnfDiagram-N527522P.edah3bz7.js} +1 -1
- package/dist/chunks/editor-shortcuts-dialog-Cz3T8435.kb0b5cra.js +1 -0
- package/dist/chunks/editor.ywaw7sz9.js +4 -0
- package/dist/chunks/{elk-O5DQBFGD.a5rqryhg.js → elk-O5DQBFGD.qnxmxe5n.js} +13 -13
- package/dist/chunks/emoji-picker-00Bw2c2b.2985hrzf.js +4 -0
- package/dist/chunks/{erDiagram-K3K3BIDK.exfeddaa.js → erDiagram-K3K3BIDK.9wh4fsa9.js} +8 -8
- package/dist/chunks/eventmodeling-K75KTNOO.xt3yb4h8.js +1 -0
- package/dist/chunks/{flow-diagram-Byy7DBZZ.pf5vdbkn.js → flow-diagram-DGZOc1z1.1276ykn3.js} +6 -6
- package/dist/chunks/flowDiagram-Z6JWZHQI.3t1zqq9x.js +1 -0
- package/dist/chunks/{ganttDiagram-3PRQTZWP.0tjaeqjw.js → ganttDiagram-3PRQTZWP.4t4r8jy0.js} +5 -5
- package/dist/chunks/gitGraph-VSP46ZUC.v9e8d46n.js +1 -0
- package/dist/chunks/{gitGraphDiagram-VXDFKS5L.6vvbj88t.js → gitGraphDiagram-VXDFKS5L.x4pypqh9.js} +19 -19
- package/dist/chunks/{grid-E2QIVN74.frpdy6t3.js → grid-E2QIVN74.8njsnft0.js} +1 -1
- package/dist/chunks/illustration-BcaGDjvB.ahkxq9mz.js +1 -0
- package/dist/chunks/{index.sv013f1z.js → index.0tz15aew.js} +1 -1
- package/dist/chunks/{index.zjykrx6y.js → index.0yskyw4t.js} +4 -4
- package/dist/chunks/{index.0kv7tp87.js → index.10k18jx6.js} +2 -2
- package/dist/chunks/{index.93zpfh3k.js → index.28jrnjz5.js} +2 -2
- package/dist/chunks/{index.f6jhkm5c.js → index.2j6fty9j.js} +35 -35
- package/dist/chunks/index.3c95g5mh.js +2 -0
- package/dist/chunks/{index.d8b8y928.js → index.3y8baz7q.js} +10 -10
- package/dist/chunks/{index.7q6v461v.js → index.5n55ccv6.js} +2 -2
- package/dist/chunks/{index.yfbwd99n.js → index.5sj251kq.js} +106 -106
- package/dist/chunks/{index.3pn4wy4j.js → index.a7m06kba.js} +1 -1
- package/dist/chunks/{index.fv9af3wd.js → index.d57x7pg9.js} +6 -6
- package/dist/chunks/{index.mcyw2bze.js → index.f1bfv6bh.js} +1 -1
- package/dist/chunks/{index.xrg5yg8d.js → index.gzgeb5ax.js} +2 -2
- package/dist/chunks/{index.nrd5w1x0.js → index.mjp06b03.js} +2 -2
- package/dist/chunks/{index.a6rz456z.js → index.mtrj86e8.js} +2 -2
- package/dist/chunks/index.n53k66q8.js +2 -0
- package/dist/chunks/index.pg4f51t3.js +44 -0
- package/dist/chunks/index.q39061xn.js +2 -0
- package/dist/chunks/{index.pyz71tqx.js → index.tnx5y2zc.js} +2 -2
- package/dist/chunks/{index.nsckd1vt.js → index.yhmqh641.js} +2 -2
- package/dist/chunks/{index.kh3f3gw8.js → index.znt11tbm.js} +2 -2
- package/dist/chunks/info-OHQRW6UA.atpz16bq.js +1 -0
- package/dist/chunks/{infoDiagram-EZ3ZOAHP.qh2bwz3m.js → infoDiagram-EZ3ZOAHP.mq5603w2.js} +2 -2
- package/dist/chunks/{ishikawaDiagram-S3EKX5GW.w2v6vnwd.js → ishikawaDiagram-S3EKX5GW.sx08qj3j.js} +5 -5
- package/dist/chunks/{journeyDiagram-POQNLL5X.ftkfdsrw.js → journeyDiagram-POQNLL5X.c3e37ws5.js} +5 -5
- package/dist/chunks/{kanban-definition-BH5XI6FM.9scqhcx5.js → kanban-definition-BH5XI6FM.6b85jkvt.js} +7 -7
- package/dist/chunks/markup-color-chrome-ykGNUl8y.76asgnkk.js +1 -0
- package/dist/chunks/markup-custom-color-MM-HnrqY.de5f5c2g.js +1 -0
- package/dist/chunks/mention-list-6cR5VSPa.r7r4w0q8.js +1 -0
- package/dist/chunks/{mermaid.core.tnh468qk.js → mermaid.core.kh4z9f22.js} +7 -7
- package/dist/chunks/{mindmap-definition-WVAN44T4.gskntx1f.js → mindmap-definition-WVAN44T4.07nv313g.js} +6 -6
- package/dist/chunks/packet-JDAUHWVQ.dmnq0wwq.js +1 -0
- package/dist/chunks/panel.zcphrx3e.js +7 -0
- package/dist/chunks/{pegDiagram-D4NLKWP3.yb58dpky.js → pegDiagram-D4NLKWP3.2mqrk2xy.js} +1 -1
- package/dist/chunks/pie-XZMESJXO.0rpk8mwa.js +1 -0
- package/dist/chunks/pieDiagram-36ENHN4W.kx9bhkyj.js +39 -0
- package/dist/chunks/plated-illustration-pTqcYOQg.a24pxzgf.js +1 -0
- package/dist/chunks/{quadrantDiagram-ZQUDMS73.1a721ces.js → quadrantDiagram-ZQUDMS73.68vxq0vb.js} +4 -4
- package/dist/chunks/radar-ABXABTNO.xt7snfyy.js +1 -0
- package/dist/chunks/railroad-I3PHUGI6.bjssfxkf.js +1 -0
- package/dist/chunks/railroad-abnf-LNEFI6M7.mchc5mex.js +1 -0
- package/dist/chunks/railroad-ebnf-DWYD2UWJ.wz1e7a1n.js +1 -0
- package/dist/chunks/railroad-peg-JR7BVNR7.xg4e4nsz.js +1 -0
- package/dist/chunks/{railroadDiagram-JIZHGYPL.xpgkt1zp.js → railroadDiagram-JIZHGYPL.dnj3h1n0.js} +1 -1
- package/dist/chunks/{render-VIF2ZAQL.khtqjmgm.js → render-VIF2ZAQL.cawqkxpf.js} +1 -1
- package/dist/chunks/{requirementDiagram-AXW2TVFA.ms6anxwg.js → requirementDiagram-AXW2TVFA.5z51j1hn.js} +4 -4
- package/dist/chunks/{sankeyDiagram-FBCJTAIF.40yzed7d.js → sankeyDiagram-FBCJTAIF.0dqdm7yd.js} +6 -6
- package/dist/chunks/{sequenceDiagram-3LA2ROMG.z0h3shw2.js → sequenceDiagram-3LA2ROMG.0fpdfwg0.js} +11 -11
- package/dist/chunks/{sizeCapture-2Q2CQKSF.4dh5g271.js → sizeCapture-2Q2CQKSF.gverqc02.js} +1 -1
- package/dist/chunks/{stateDiagram-v2-ATKHQDJO.5ftcgs8s.js → stateDiagram-v2-ATKHQDJO.56dj904f.js} +8 -8
- package/dist/chunks/{swimlanes-YQL5WMAO.r6vmskrb.js → swimlanes-YQL5WMAO.frj4npw4.js} +1 -1
- package/dist/chunks/swimlanesDiagram-UCCPES4V.834hahmm.js +8 -0
- package/dist/chunks/{timeline-definition-7Z437IG3.eke70hfq.js → timeline-definition-7Z437IG3.v99ghwdb.js} +9 -9
- package/dist/chunks/treeView-D4JQ5SDB.tbqcaq5q.js +1 -0
- package/dist/chunks/treemap-SAJKECNS.jgfv37a0.js +1 -0
- package/dist/chunks/{usecaseDiagram-RDK6N6HP.d8p4tnc6.js → usecaseDiagram-RDK6N6HP.b6317ne8.js} +57 -57
- package/dist/chunks/{vennDiagram-SHRQU5PJ.4s46abxd.js → vennDiagram-SHRQU5PJ.adr331gc.js} +7 -7
- package/dist/chunks/wardley-7MLQ67FV.4653yv6a.js +1 -0
- package/dist/chunks/{wardleyDiagram-F3OXNVQS.mq49fny4.js → wardleyDiagram-F3OXNVQS.5tt3knhg.js} +4 -4
- package/dist/chunks/{xychartDiagram-GDYJKCDI.d7he0fxa.js → xychartDiagram-GDYJKCDI.dqs1thzc.js} +5 -5
- package/dist/index.js +48 -21
- package/dist/types/config.d.ts +1 -1
- package/dist/types/mount.d.ts +1 -1
- package/docs/integration.md +32 -26
- package/package.json +4 -4
- package/dist/chunks/architecture-WOLXFQ4H.pp4drcrh.js +0 -1
- package/dist/chunks/architectureDiagram-CSQXQB3N.0bddzt5e.js +0 -36
- package/dist/chunks/cose-bilkent-JH36ORCC.qam7r9b1.js +0 -1
- package/dist/chunks/cynefin-EF2NZ3EQ.wgr8qmb2.js +0 -1
- package/dist/chunks/diagram-YHHI257C.7735ve6v.js +0 -3
- package/dist/chunks/editor-shortcuts-dialog-VmvMTjnq.mm7ab69f.js +0 -1
- package/dist/chunks/editor.wb4jsrjy.js +0 -4
- package/dist/chunks/emoji-picker-bnO0yA8e.bymgjc9a.js +0 -4
- package/dist/chunks/eventmodeling-K75KTNOO.nkahp6zg.js +0 -1
- package/dist/chunks/flowDiagram-Z6JWZHQI.54yz6gfm.js +0 -1
- package/dist/chunks/gitGraph-VSP46ZUC.2a0am491.js +0 -1
- package/dist/chunks/illustration-BfueshiW.syv54ccw.js +0 -1
- package/dist/chunks/index.bs3ygyp2.js +0 -2
- package/dist/chunks/index.newjn1k4.js +0 -2
- package/dist/chunks/index.rn0vxns6.js +0 -44
- package/dist/chunks/index.yexf86bf.js +0 -2
- package/dist/chunks/info-OHQRW6UA.4824y3cd.js +0 -1
- package/dist/chunks/markup-color-chrome-ykGNUl8y.8cysjsfb.js +0 -1
- package/dist/chunks/markup-custom-color-CytmKw-R.d25j0pcj.js +0 -1
- package/dist/chunks/mention-list-5h2lZwEU.wffam6eb.js +0 -1
- package/dist/chunks/packet-JDAUHWVQ.w0pv2dxr.js +0 -1
- package/dist/chunks/panel.dq8vt40k.js +0 -7
- package/dist/chunks/pie-XZMESJXO.zq72f2fq.js +0 -1
- package/dist/chunks/pieDiagram-36ENHN4W.7pgn8ayz.js +0 -39
- package/dist/chunks/plated-illustration-VrnsTz7H.tcyq0sxa.js +0 -1
- package/dist/chunks/radar-ABXABTNO.288gs0b8.js +0 -1
- package/dist/chunks/railroad-I3PHUGI6.aadrd13j.js +0 -1
- package/dist/chunks/railroad-abnf-LNEFI6M7.6btgmncj.js +0 -1
- package/dist/chunks/railroad-ebnf-DWYD2UWJ.y44ppt8p.js +0 -1
- package/dist/chunks/railroad-peg-JR7BVNR7.328jgxkz.js +0 -1
- package/dist/chunks/swimlanesDiagram-UCCPES4V.exhrz16x.js +0 -8
- package/dist/chunks/treeView-D4JQ5SDB.xz61fh4x.js +0 -1
- package/dist/chunks/treemap-SAJKECNS.8gv7pmqr.js +0 -1
- package/dist/chunks/wardley-7MLQ67FV.6v9j3be8.js +0 -1
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import{e,n,
|
|
1
|
+
import{e,n,me,mt,k,y,j,A,u,p,ao,ge,de,fe,Je,et,Kr,mn,io,Ma,Na,Oa,Da,oo,so,lo,co,uo,fo,ho,po,mo,go,bo,vo,yo,xo,wo,ko,To,gn,Xt,So,Bt,Ct,Ft,yn,gr,xn}from"./index.5sj251kq.js";import{le}from"./index.n53k66q8.js";import{Ye}from"./index.gzgeb5ax.js";function Te(t){return Array.isArray(t)}function Ne(t){if(Kr(t))return t;let o=mn(t);if(!Ze(t))return{};if(Te(t)){let i=Array.from(t);if(t.length>0&&typeof t[0]==="string"&&gn(t,"index"))i.index=t.index,i.input=t.input;return i}if(Xt(t)){let i=t;return new i.constructor(i.buffer,i.byteOffset,i.length)}if(o==="[object ArrayBuffer]")return new ArrayBuffer(t.byteLength);if(o==="[object DataView]"){let i=t,{buffer:g,byteOffset:f,byteLength:r}=i,d=new ArrayBuffer(r),E=new Uint8Array(g,f,r);return new Uint8Array(d).set(E),new DataView(d)}if(o==="[object Boolean]"||o==="[object Number]"||o==="[object String]"){let g=new t.constructor(t.valueOf());if(o==="[object String]")$e(g,t);else ue(g,t);return g}if(o==="[object Date]")return new Date(Number(t));if(o==="[object RegExp]"){let i=t,g=new RegExp(i.source,i.flags);return g.lastIndex=i.lastIndex,g}if(o==="[object Symbol]")return Object(Symbol.prototype.valueOf.call(t));if(o==="[object Map]"){let i=t,g=new Map;return i.forEach((f,r)=>{g.set(r,f)}),g}if(o==="[object Set]"){let i=t,g=new Set;return i.forEach((f)=>{g.add(f)}),g}if(o==="[object Arguments]"){let i=t,g={};return ue(g,i),g.length=i.length,g[Symbol.iterator]=i[Symbol.iterator],g}let c={};return tt(c,t),ue(c,t),Qe(c,t),c}function Ze(t){switch(mn(t)){case Da:case uo:case fo:case po:case Oa:case so:case ko:case To:case yo:case xo:case wo:case lo:case Na:case ho:case io:case co:case Ma:case oo:case mo:case go:case bo:case vo:return!0;default:return!1}}function ue(t,o){for(let c in o)if(gn(o,c))t[c]=o[c]}function Qe(t,o){let c=Object.getOwnPropertySymbols(o);for(let i=0;i<c.length;i++){let g=c[i];if(Object.prototype.propertyIsEnumerable.call(o,g))t[g]=o[g]}}function $e(t,o){let c=o.valueOf().length;for(let i in o)if(gn(o,i)&&(Number.isNaN(Number(i))||Number(i)>=c))t[i]=o[i]}function tt(t,o){let c=Object.getPrototypeOf(o);if(c!==null){if(typeof o.constructor==="function")Object.setPrototypeOf(t,c)}}var pe=function(){var t=e(function(B,b,a,h){for(a=a||{},h=B.length;h--;a[B[h]]=b);return a},"o"),o=[1,15],c=[1,7],i=[1,13],g=[1,14],f=[1,19],r=[1,16],d=[1,17],E=[1,18],w=[8,30],x=[8,10,21,28,29,30,31,39,43,46],m=[1,23],_=[1,24],T=[8,10,15,16,21,28,29,30,31,39,43,46],L=[8,10,15,16,21,27,28,29,30,31,39,43,46],I=[1,49],N={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(b,a,h,S,D,s,U){var l=s.length-1;switch(D){case 4:S.getLogger().debug("Rule: separator (NL) ");break;case 5:S.getLogger().debug("Rule: separator (Space) ");break;case 6:S.getLogger().debug("Rule: separator (EOF) ");break;case 7:S.getLogger().debug("Rule: hierarchy: ",s[l-1]),S.setHierarchy(s[l-1]);break;case 8:S.getLogger().debug("Stop NL ");break;case 9:S.getLogger().debug("Stop EOF ");break;case 10:S.getLogger().debug("Stop NL2 ");break;case 11:S.getLogger().debug("Stop EOF2 ");break;case 12:S.getLogger().debug("Rule: statement: ",s[l]),typeof s[l].length==="number"?this.$=s[l]:this.$=[s[l]];break;case 13:S.getLogger().debug("Rule: statement #2: ",s[l-1]),this.$=[s[l-1]].concat(s[l]);break;case 14:S.getLogger().debug("Rule: link: ",s[l],b),this.$={edgeTypeStr:s[l],label:""};break;case 15:S.getLogger().debug("Rule: LABEL link: ",s[l-3],s[l-1],s[l]),this.$={edgeTypeStr:s[l],label:s[l-1]};break;case 18:let W=parseInt(s[l]),X=S.generateId();this.$={id:X,type:"space",label:"",width:W,children:[]};break;case 23:S.getLogger().debug("Rule: (nodeStatement link node) ",s[l-2],s[l-1],s[l]," typestr: ",s[l-1].edgeTypeStr);let G=S.edgeStrToEdgeData(s[l-1].edgeTypeStr),re=S.edgeStrToEdgeStartData(s[l-1].edgeTypeStr),q=S.edgeStrToThickness(s[l-1].edgeTypeStr),se=S.edgeStrToPattern(s[l-1].edgeTypeStr);this.$=[{id:s[l-2].id,label:s[l-2].label,type:s[l-2].type,directions:s[l-2].directions},{id:s[l-2].id+"-"+s[l].id,start:s[l-2].id,end:s[l].id,label:s[l-1].label,type:"edge",thickness:q,pattern:se,directions:s[l].directions,arrowTypeEnd:G,arrowTypeStart:re},{id:s[l].id,label:s[l].label,type:S.typeStr2Type(s[l].typeStr),directions:s[l].directions}];break;case 24:S.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[l-1],s[l]),this.$={id:s[l-1].id,label:s[l-1].label,type:S.typeStr2Type(s[l-1].typeStr),directions:s[l-1].directions,widthInColumns:parseInt(s[l],10)};break;case 25:S.getLogger().debug("Rule: nodeStatement (node) ",s[l]),this.$={id:s[l].id,label:s[l].label,type:S.typeStr2Type(s[l].typeStr),directions:s[l].directions,widthInColumns:1};break;case 26:S.getLogger().debug("APA123",this?this:"na"),S.getLogger().debug("COLUMNS: ",s[l]),this.$={type:"column-setting",columns:s[l]==="auto"?-1:parseInt(s[l])};break;case 27:S.getLogger().debug("Rule: id-block statement : ",s[l-2],s[l-1]);let C=S.generateId();this.$={...s[l-2],type:"composite",children:s[l-1]};break;case 28:S.getLogger().debug("Rule: blockStatement : ",s[l-2],s[l-1],s[l]);let M=S.generateId();this.$={id:M,type:"composite",label:"",children:s[l-1]};break;case 29:S.getLogger().debug("Rule: node (NODE_ID separator): ",s[l]),this.$={id:s[l]};break;case 30:S.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[l-1],s[l]),this.$={id:s[l-1],label:s[l].label,typeStr:s[l].typeStr,directions:s[l].directions};break;case 31:S.getLogger().debug("Rule: dirList: ",s[l]),this.$=[s[l]];break;case 32:S.getLogger().debug("Rule: dirList: ",s[l-1],s[l]),this.$=[s[l-1]].concat(s[l]);break;case 33:S.getLogger().debug("Rule: nodeShapeNLabel: ",s[l-2],s[l-1],s[l]),this.$={typeStr:s[l-2]+s[l],label:s[l-1]};break;case 34:S.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[l-3],s[l-2]," #3:",s[l-1],s[l]),this.$={typeStr:s[l-3]+s[l],label:s[l-2],directions:s[l-1]};break;case 35:case 36:this.$={type:"classDef",id:s[l-1].trim(),css:s[l].trim()};break;case 37:this.$={type:"applyClass",id:s[l-1].trim(),styleClass:s[l].trim()};break;case 38:this.$={type:"applyStyles",id:s[l-1].trim(),stylesStr:s[l].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:o,11:3,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:E},{8:[1,20]},t(w,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:o,21:c,28:i,29:g,31:f,39:r,43:d,46:E}),t(x,[2,16],{14:22,15:m,16:_}),t(x,[2,17]),t(x,[2,18]),t(x,[2,19]),t(x,[2,20]),t(x,[2,21]),t(x,[2,22]),t(T,[2,25],{27:[1,25]}),t(x,[2,26]),{19:26,26:12,31:f},{10:o,11:27,13:4,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:E},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},t(L,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},t(w,[2,13]),{26:35,31:f},{31:[2,14]},{17:[1,36]},t(T,[2,24]),{10:o,11:37,13:4,14:22,15:m,16:_,19:5,20:6,21:c,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:E},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},t(L,[2,30]),{18:[1,43]},{18:[1,44]},t(T,[2,23]),{18:[1,45]},{30:[1,46]},t(x,[2,28]),t(x,[2,35]),t(x,[2,36]),t(x,[2,37]),t(x,[2,38]),{36:[1,47]},{33:48,34:I},{15:[1,50]},t(x,[2,27]),t(L,[2,33]),{38:[1,51]},{33:52,34:I,38:[2,31]},{31:[2,15]},t(L,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:e(function(b,a){if(a.recoverable)this.trace(b);else{var h=Error(b);throw h.hash=a,h}},"parseError"),parse:e(function(b){var a=this,h=[0],S=[],D=[null],s=[],U=this.table,l="",W=0,X=0,G=0,re=2,q=1,se=s.slice.call(arguments,1),C=Object.create(this.lexer),M={yy:{}};for(var ie in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,ie))M.yy[ie]=this.yy[ie];if(C.setInput(b,M.yy),M.yy.lexer=C,M.yy.parser=this,typeof C.yylloc>"u")C.yylloc={};var ae=C.yylloc;s.push(ae);var je=C.options&&C.options.ranges;if(typeof M.yy.parseError==="function")this.parseError=M.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function qe(P){h.length=h.length-2*P,D.length=D.length-P,s.length=s.length-P}e(qe,"popStack");function _e(){var P=S.pop()||C.lex()||q;if(typeof P!=="number"){if(P instanceof Array)S=P,P=S.pop();P=a.symbols_[P]||P}return P}e(_e,"lex");var O,ne,Y,R,Ot,oe,V={},J,K,De,Z;while(!0){if(Y=h[h.length-1],this.defaultActions[Y])R=this.defaultActions[Y];else{if(O===null||typeof O>"u")O=_e();R=U[Y]&&U[Y][O]}if(typeof R>"u"||!R.length||!R[0]){var ce="";Z=[];for(J in U[Y])if(this.terminals_[J]&&J>re)Z.push("'"+this.terminals_[J]+"'");if(C.showPosition)ce="Parse error on line "+(W+1)+`:
|
|
2
2
|
`+C.showPosition()+`
|
|
3
|
-
Expecting `+Z.join(", ")+", got '"+(this.terminals_[O]||O)+"'";else
|
|
4
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:e(function(
|
|
5
|
-
`+a+"^"},"showPosition"),test_match:e(function(
|
|
6
|
-
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var a=this.next();if(a)return a;else return this.lex()},"lex"),begin:e(function(a){this.conditionStack.push(a)},"begin"),popState:e(function(){var a=this.conditionStack.length-1;if(a>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:e(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:e(function(a){if(a=this.conditionStack.length-1-Math.abs(a||0),a>=0)return this.conditionStack[a];else return"INITIAL"},"topState"),pushState:e(function(a){this.begin(a)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:e(function(a,h,b,D){var s=D;switch(b){case 0:return a.getLogger().debug("Found block-beta"),10;break;case 1:return a.getLogger().debug("Found id-block"),29;break;case 2:return a.getLogger().debug("Found block"),10;break;case 3:a.getLogger().debug(".",h.yytext);break;case 4:a.getLogger().debug("_",h.yytext);break;case 5:return 5;case 6:return h.yytext=-1,28;break;case 7:return h.yytext=h.yytext.replace(/columns\s+/,""),a.getLogger().debug("COLUMNS (LEX)",h.yytext),28;break;case 8:this.pushState("md_string");break;case 9:return"MD_STR";case 10:this.popState();break;case 11:this.pushState("string");break;case 12:a.getLogger().debug("LEX: POPPING STR:",h.yytext),this.popState();break;case 13:return a.getLogger().debug("LEX: STR end:",h.yytext),"STR";break;case 14:return h.yytext=h.yytext.replace(/space\:/,""),a.getLogger().debug("SPACE NUM (LEX)",h.yytext),21;break;case 15:return h.yytext="1",a.getLogger().debug("COLUMNS (LEX)",h.yytext),21;break;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;break;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";break;case 21:return this.popState(),this.pushState("CLASSDEFID"),40;break;case 22:return this.popState(),41;break;case 23:return this.pushState("CLASS"),43;break;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;break;case 25:return this.popState(),45;break;case 26:return this.pushState("STYLE_STMNT"),46;break;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;break;case 28:return this.popState(),48;break;case 29:return this.pushState("acc_title"),"acc_title";break;case 30:return this.popState(),"acc_title_value";break;case 31:return this.pushState("acc_descr"),"acc_descr";break;case 32:return this.popState(),"acc_descr_value";break;case 33:this.pushState("acc_descr_multiline");break;case 34:this.popState();break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 38:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 39:return this.popState(),a.getLogger().debug("Lex: ))"),"NODE_DEND";break;case 40:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 41:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 42:return this.popState(),a.getLogger().debug("Lex: (-"),"NODE_DEND";break;case 43:return this.popState(),a.getLogger().debug("Lex: -)"),"NODE_DEND";break;case 44:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 45:return this.popState(),a.getLogger().debug("Lex: ]]"),"NODE_DEND";break;case 46:return this.popState(),a.getLogger().debug("Lex: ("),"NODE_DEND";break;case 47:return this.popState(),a.getLogger().debug("Lex: ])"),"NODE_DEND";break;case 48:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 49:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 50:return this.popState(),a.getLogger().debug("Lex: )]"),"NODE_DEND";break;case 51:return this.popState(),a.getLogger().debug("Lex: )"),"NODE_DEND";break;case 52:return this.popState(),a.getLogger().debug("Lex: ]>"),"NODE_DEND";break;case 53:return this.popState(),a.getLogger().debug("Lex: ]"),"NODE_DEND";break;case 54:return a.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;break;case 55:return a.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;break;case 56:return a.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;break;case 57:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 58:return a.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;break;case 59:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 60:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 61:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 62:return a.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;break;case 63:return a.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;break;case 64:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 65:return this.pushState("NODE"),35;break;case 66:return this.pushState("NODE"),35;break;case 67:return this.pushState("NODE"),35;break;case 68:return this.pushState("NODE"),35;break;case 69:return this.pushState("NODE"),35;break;case 70:return this.pushState("NODE"),35;break;case 71:return this.pushState("NODE"),35;break;case 72:return a.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;break;case 73:return this.pushState("BLOCK_ARROW"),a.getLogger().debug("LEX ARR START"),37;break;case 74:return a.getLogger().debug("Lex: NODE_ID",h.yytext),31;break;case 75:return a.getLogger().debug("Lex: EOF",h.yytext),8;break;case 76:this.pushState("md_string");break;case 77:this.pushState("md_string");break;case 78:return"NODE_DESCR";case 79:this.popState();break;case 80:a.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:a.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return a.getLogger().debug("LEX: NODE_DESCR:",h.yytext),"NODE_DESCR";break;case 83:a.getLogger().debug("LEX POPPING"),this.popState();break;case 84:a.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (right): dir:",h.yytext),"DIR";break;case 86:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (left):",h.yytext),"DIR";break;case 87:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (x):",h.yytext),"DIR";break;case 88:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (y):",h.yytext),"DIR";break;case 89:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (up):",h.yytext),"DIR";break;case 90:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (down):",h.yytext),"DIR";break;case 91:return h.yytext="]>",a.getLogger().debug("Lex (ARROW_DIR end):",h.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";break;case 92:return a.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 93:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 94:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 95:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 96:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 97:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 98:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 99:this.pushState("md_string");break;case 100:return a.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";break;case 101:return this.popState(),a.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 102:return this.popState(),a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 103:return this.popState(),a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 104:return a.getLogger().debug("Lex: COLON",h.yytext),h.yytext=h.yytext.slice(1),27;break}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}};return B}();N.lexer=v;function z(){this.yy={}}return e(z,"Parser"),z.prototype=N,N.Parser=z,new z}();de.parser=de;var et=de,F=new Map,me=[],fe=new Map,Ne="color",Ie="fill",st="bgFill",Oe=",",Q=new Map,xe="",it=e((t)=>y.sanitizeText(t,u()),"sanitizeText"),at=e(function(t,o=""){let c=Q.get(t);if(!c)c={id:t,styles:[],textStyles:[]},Q.set(t,c);if(o!==void 0&&o!==null)o.split(Oe).forEach((i)=>{let g=i.replace(/([^;]*);/,"$1").trim();if(RegExp(Ne).exec(i)){let r=g.replace(Ie,st).replace(Ne,Ie);c.textStyles.push(r)}c.styles.push(g)})},"addStyleClass"),nt=e(function(t,o=""){let c=F.get(t);if(o!==void 0&&o!==null)c.styles=o.split(Oe)},"addStyle2Node"),ot=e(function(t,o){t.split(",").forEach(function(c){let i=F.get(c);if(i===void 0){let g=c.trim();i={id:g,type:"na",children:[]},F.set(g,i)}if(!i.classes)i.classes=[];i.classes.push(o)})},"setCssClass"),Ae=0,ze=e((t,o)=>{let c=t.flat(),i=[],p=c.find((r)=>r?.type==="column-setting")?.columns??-1;for(let r of c){if(typeof p==="number"&&p>0&&r.type!=="column-setting"&&typeof r.widthInColumns==="number"&&r.widthInColumns>p)n.warn(`Block ${r.id} width ${r.widthInColumns} exceeds configured column width ${p}`);if(r.label)r.label=it(r.label);if(r.type==="classDef"){at(r.id,r.css);continue}if(r.type==="applyClass"){ot(r.id,r?.styleClass??"");continue}if(r.type==="applyStyles"){if(r?.stylesStr)nt(r.id,r?.stylesStr);continue}if(r.type==="column-setting")o.columns=r.columns??-1;else if(r.type==="edge"){let d=(fe.get(r.id)??0)+1;fe.set(r.id,d),r.id=d+"-"+r.id,me.push(r)}else{if(!r.label)if(r.type==="composite")r.label="";else r.label=r.id;let d=F.get(r.id);if(d===void 0){if(r.type==="composite")r.colorIndex=Ae++;F.set(r.id,r)}else{if(r.type!=="na")d.type=r.type;if(r.label!==r.id)d.label=r.label}if(r.children)ze(r.children,r);if(r.type==="space"){let E=r.width??1;for(let w=0;w<E;w++){let x=Te(r);x.id=x.id+"-"+w,F.set(x.id,x),i.push(x)}}else if(d===void 0)i.push(r)}}o.children=i},"populateBlockDatabase"),Le=[],H={id:"root",type:"composite",children:[],columns:-1},lt=e(()=>{n.debug("Clear called"),A(),H={id:"root",type:"composite",children:[],columns:-1},F=new Map([["root",H]]),Le=[],Q=new Map,me=[],fe=new Map,xe="",Ae=0},"clear");function Be(t){switch(n.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return n.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"}}e(Be,"typeStr2Type");function Re(t){switch(n.debug("typeStr2Type",t),t){case"==":return"thick";default:return"normal"}}e(Re,"edgeTypeStr2Type");function Pe(t){switch(t.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}e(Pe,"edgeStrToEdgeData");function Fe(t){switch(t.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}e(Fe,"edgeStrToEdgeStartData");function Me(t){return t.includes("==")?"thick":"normal"}e(Me,"edgeStrToThickness");function Ke(t){if(t.includes(".-"))return"dotted";return"solid"}e(Ke,"edgeStrToPattern");var Ce=0,ct=e(()=>(Ce++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Ce),"generateId"),ut=e((t)=>{H.children=t,ze(t,H),Le=H.children},"setHierarchy"),ht=e((t)=>{let o=F.get(t);if(!o)return-1;if(o.columns)return o.columns;if(!o.children)return-1;return o.children.length},"getColumns"),dt=e(()=>[...F.values()],"getBlocksFlat"),pt=e(()=>Le||[],"getBlocks"),ft=e(()=>me,"getEdges"),bt=e((t)=>F.get(t),"getBlock"),mt=e((t)=>{F.set(t.id,t)},"setBlock"),xt=e((t)=>{xe=t},"setDiagramId"),Lt=e(()=>xe,"getDiagramId"),kt=e(()=>n,"getLogger"),yt=e(function(){return Q},"getClasses"),Et={getConfig:e(()=>k().block,"getConfig"),typeStr2Type:Be,edgeTypeStr2Type:Re,edgeStrToEdgeData:Pe,edgeStrToEdgeStartData:Fe,edgeStrToThickness:Me,edgeStrToPattern:Ke,getLogger:kt,getBlocksFlat:dt,getBlocks:pt,getEdges:ft,setHierarchy:ut,getBlock:bt,setBlock:mt,getColumns:ht,getClasses:yt,clear:lt,generateId:ct,setDiagramId:xt,getDiagramId:Lt},wt=Et,_t=e((t)=>{let{theme:o,bkgColorArray:c,borderColorArray:i}=t;if(!he(o,i))return"";let g=pe(t.look),p=ve(c),r="";for(let d=0;d<tt(t.THEME_COLOR_LIMIT,i);d++){let E=i[d%i.length],w=p?`fill: ${c[d%c.length]};`:"",x=`[data-look="${g}"][data-color-id="color-${d}"]`;r+=`
|
|
3
|
+
Expecting `+Z.join(", ")+", got '"+(this.terminals_[O]||O)+"'";else ce="Parse error on line "+(W+1)+": Unexpected "+(O==q?"end of input":"'"+(this.terminals_[O]||O)+"'");this.parseError(ce,{text:C.match,token:this.terminals_[O]||O,line:C.yylineno,loc:ae,expected:Z})}if(R[0]instanceof Array&&R.length>1)throw Error("Parse Error: multiple actions possible at state: "+Y+", token: "+O);switch(R[0]){case 1:if(h.push(O),D.push(C.yytext),s.push(C.yylloc),h.push(R[1]),O=null,!ne){if(X=C.yyleng,l=C.yytext,W=C.yylineno,ae=C.yylloc,G>0)G--}else O=ne,ne=null;break;case 2:if(K=this.productions_[R[1]][1],V.$=D[D.length-K],V._$={first_line:s[s.length-(K||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(K||1)].first_column,last_column:s[s.length-1].last_column},je)V._$.range=[s[s.length-(K||1)].range[0],s[s.length-1].range[1]];if(oe=this.performAction.apply(V,[l,X,W,M.yy,R[1],D,s].concat(se)),typeof oe<"u")return oe;if(K)h=h.slice(0,-1*K*2),D=D.slice(0,-1*K),s=s.slice(0,-1*K);h.push(this.productions_[R[1]][0]),D.push(V.$),s.push(V._$),De=U[h[h.length-2]][h[h.length-1]],h.push(De);break;case 3:return!0}}return!0},"parse")},v=function(){var B={EOF:1,parseError:e(function(a,h){if(this.yy.parser)this.yy.parser.parseError(a,h);else throw Error(a)},"parseError"),setInput:e(function(b,a){if(this.yy=a||this.yy||{},this._input=b,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];return this.offset=0,this},"setInput"),input:e(function(){var b=this._input[0];this.yytext+=b,this.yyleng++,this.offset++,this.match+=b,this.matched+=b;var a=b.match(/(?:\r\n?|\n).*/g);if(a)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),b},"input"),unput:e(function(b){var a=b.length,h=b.split(/(?:\r\n?|\n)/g);this._input=b+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-a),this.offset-=a;var S=this.match.split(/(?:\r\n?|\n)/g);if(this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),h.length-1)this.yylineno-=h.length-1;var D=this.yylloc.range;if(this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:h?(h.length===S.length?this.yylloc.first_column:0)+S[S.length-h.length].length-h[0].length:this.yylloc.first_column-a},this.options.ranges)this.yylloc.range=[D[0],D[0]+this.yyleng-a];return this.yyleng=this.yytext.length,this},"unput"),more:e(function(){return this._more=!0,this},"more"),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:e(function(b){this.unput(this.match.slice(b))},"less"),pastInput:e(function(){var b=this.matched.substr(0,this.matched.length-this.match.length);return(b.length>20?"...":"")+b.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:e(function(){var b=this.match;if(b.length<20)b+=this._input.substr(0,20-b.length);return(b.substr(0,20)+(b.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:e(function(){var b=this.pastInput(),a=Array(b.length+1).join("-");return b+this.upcomingInput()+`
|
|
5
|
+
`+a+"^"},"showPosition"),test_match:e(function(b,a){var h,S,D;if(this.options.backtrack_lexer){if(D={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges)D.yylloc.range=this.yylloc.range.slice(0)}if(S=b[0].match(/(?:\r\n?|\n).*/g),S)this.yylineno+=S.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:S?S[S.length-1].length-S[S.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+b[0].length},this.yytext+=b[0],this.match+=b[0],this.matches=b,this.yyleng=this.yytext.length,this.options.ranges)this.yylloc.range=[this.offset,this.offset+=this.yyleng];if(this._more=!1,this._backtrack=!1,this._input=this._input.slice(b[0].length),this.matched+=b[0],h=this.performAction.call(this,this.yy,this,a,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(h)return h;else if(this._backtrack){for(var s in D)this[s]=D[s];return!1}return!1},"test_match"),next:e(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var b,a,h,S;if(!this._more)this.yytext="",this.match="";var D=this._currentRules();for(var s=0;s<D.length;s++)if(h=this._input.match(this.rules[D[s]]),h&&(!a||h[0].length>a[0].length)){if(a=h,S=s,this.options.backtrack_lexer)if(b=this.test_match(h,D[s]),b!==!1)return b;else if(this._backtrack){a=!1;continue}else return!1;else if(!this.options.flex)break}if(a){if(b=this.test_match(a,D[S]),b!==!1)return b;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
|
|
6
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var a=this.next();if(a)return a;else return this.lex()},"lex"),begin:e(function(a){this.conditionStack.push(a)},"begin"),popState:e(function(){var a=this.conditionStack.length-1;if(a>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:e(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:e(function(a){if(a=this.conditionStack.length-1-Math.abs(a||0),a>=0)return this.conditionStack[a];else return"INITIAL"},"topState"),pushState:e(function(a){this.begin(a)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:e(function(a,h,S,D){var s=D;switch(S){case 0:return a.getLogger().debug("Found block-beta"),10;break;case 1:return a.getLogger().debug("Found id-block"),29;break;case 2:return a.getLogger().debug("Found block"),10;break;case 3:a.getLogger().debug(".",h.yytext);break;case 4:a.getLogger().debug("_",h.yytext);break;case 5:return 5;case 6:return h.yytext=-1,28;break;case 7:return h.yytext=h.yytext.replace(/columns\s+/,""),a.getLogger().debug("COLUMNS (LEX)",h.yytext),28;break;case 8:this.pushState("md_string");break;case 9:return"MD_STR";case 10:this.popState();break;case 11:this.pushState("string");break;case 12:a.getLogger().debug("LEX: POPPING STR:",h.yytext),this.popState();break;case 13:return a.getLogger().debug("LEX: STR end:",h.yytext),"STR";break;case 14:return h.yytext=h.yytext.replace(/space\:/,""),a.getLogger().debug("SPACE NUM (LEX)",h.yytext),21;break;case 15:return h.yytext="1",a.getLogger().debug("COLUMNS (LEX)",h.yytext),21;break;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;break;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";break;case 21:return this.popState(),this.pushState("CLASSDEFID"),40;break;case 22:return this.popState(),41;break;case 23:return this.pushState("CLASS"),43;break;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;break;case 25:return this.popState(),45;break;case 26:return this.pushState("STYLE_STMNT"),46;break;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;break;case 28:return this.popState(),48;break;case 29:return this.pushState("acc_title"),"acc_title";break;case 30:return this.popState(),"acc_title_value";break;case 31:return this.pushState("acc_descr"),"acc_descr";break;case 32:return this.popState(),"acc_descr_value";break;case 33:this.pushState("acc_descr_multiline");break;case 34:this.popState();break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 38:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 39:return this.popState(),a.getLogger().debug("Lex: ))"),"NODE_DEND";break;case 40:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 41:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 42:return this.popState(),a.getLogger().debug("Lex: (-"),"NODE_DEND";break;case 43:return this.popState(),a.getLogger().debug("Lex: -)"),"NODE_DEND";break;case 44:return this.popState(),a.getLogger().debug("Lex: (("),"NODE_DEND";break;case 45:return this.popState(),a.getLogger().debug("Lex: ]]"),"NODE_DEND";break;case 46:return this.popState(),a.getLogger().debug("Lex: ("),"NODE_DEND";break;case 47:return this.popState(),a.getLogger().debug("Lex: ])"),"NODE_DEND";break;case 48:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 49:return this.popState(),a.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 50:return this.popState(),a.getLogger().debug("Lex: )]"),"NODE_DEND";break;case 51:return this.popState(),a.getLogger().debug("Lex: )"),"NODE_DEND";break;case 52:return this.popState(),a.getLogger().debug("Lex: ]>"),"NODE_DEND";break;case 53:return this.popState(),a.getLogger().debug("Lex: ]"),"NODE_DEND";break;case 54:return a.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;break;case 55:return a.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;break;case 56:return a.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;break;case 57:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 58:return a.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;break;case 59:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 60:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 61:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 62:return a.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;break;case 63:return a.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;break;case 64:return a.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 65:return this.pushState("NODE"),35;break;case 66:return this.pushState("NODE"),35;break;case 67:return this.pushState("NODE"),35;break;case 68:return this.pushState("NODE"),35;break;case 69:return this.pushState("NODE"),35;break;case 70:return this.pushState("NODE"),35;break;case 71:return this.pushState("NODE"),35;break;case 72:return a.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;break;case 73:return this.pushState("BLOCK_ARROW"),a.getLogger().debug("LEX ARR START"),37;break;case 74:return a.getLogger().debug("Lex: NODE_ID",h.yytext),31;break;case 75:return a.getLogger().debug("Lex: EOF",h.yytext),8;break;case 76:this.pushState("md_string");break;case 77:this.pushState("md_string");break;case 78:return"NODE_DESCR";case 79:this.popState();break;case 80:a.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:a.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return a.getLogger().debug("LEX: NODE_DESCR:",h.yytext),"NODE_DESCR";break;case 83:a.getLogger().debug("LEX POPPING"),this.popState();break;case 84:a.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (right): dir:",h.yytext),"DIR";break;case 86:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (left):",h.yytext),"DIR";break;case 87:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (x):",h.yytext),"DIR";break;case 88:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (y):",h.yytext),"DIR";break;case 89:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (up):",h.yytext),"DIR";break;case 90:return h.yytext=h.yytext.replace(/^,\s*/,""),a.getLogger().debug("Lex (down):",h.yytext),"DIR";break;case 91:return h.yytext="]>",a.getLogger().debug("Lex (ARROW_DIR end):",h.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";break;case 92:return a.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 93:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 94:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 95:return a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 96:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 97:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 98:return a.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 99:this.pushState("md_string");break;case 100:return a.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";break;case 101:return this.popState(),a.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 102:return this.popState(),a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 103:return this.popState(),a.getLogger().debug("Lex: LINK",h.yytext),15;break;case 104:return a.getLogger().debug("Lex: COLON",h.yytext),h.yytext=h.yytext.slice(1),27;break}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}};return B}();N.lexer=v;function z(){this.yy={}}return e(z,"Parser"),z.prototype=N,N.Parser=z,new z}();pe.parser=pe;var rt=pe,F=new Map,xe=[],be=new Map,Ie="color",Ce="fill",st="bgFill",Oe=",",Q=new Map,Le="",it=e((t)=>y.sanitizeText(t,u()),"sanitizeText"),at=e(function(t,o=""){let c=Q.get(t);if(!c)c={id:t,styles:[],textStyles:[]},Q.set(t,c);if(o!==void 0&&o!==null)o.split(Oe).forEach((i)=>{let g=i.replace(/([^;]*);/,"$1").trim();if(RegExp(Ie).exec(i)){let r=g.replace(Ce,st).replace(Ie,Ce);c.textStyles.push(r)}c.styles.push(g)})},"addStyleClass"),nt=e(function(t,o=""){let c=F.get(t);if(o!==void 0&&o!==null)c.styles=o.split(Oe)},"addStyle2Node"),ot=e(function(t,o){t.split(",").forEach(function(c){let i=F.get(c);if(i===void 0){let g=c.trim();i={id:g,type:"na",children:[]},F.set(g,i)}if(!i.classes)i.classes=[];i.classes.push(o)})},"setCssClass"),Ae=0,ze=e((t,o)=>{let c=t.flat(),i=[],f=c.find((r)=>r?.type==="column-setting")?.columns??-1;for(let r of c){if(typeof f==="number"&&f>0&&r.type!=="column-setting"&&typeof r.widthInColumns==="number"&&r.widthInColumns>f)n.warn(`Block ${r.id} width ${r.widthInColumns} exceeds configured column width ${f}`);if(r.label)r.label=it(r.label);if(r.type==="classDef"){at(r.id,r.css);continue}if(r.type==="applyClass"){ot(r.id,r?.styleClass??"");continue}if(r.type==="applyStyles"){if(r?.stylesStr)nt(r.id,r?.stylesStr);continue}if(r.type==="column-setting")o.columns=r.columns??-1;else if(r.type==="edge"){let d=(be.get(r.id)??0)+1;be.set(r.id,d),r.id=d+"-"+r.id,xe.push(r)}else{if(!r.label)if(r.type==="composite")r.label="";else r.label=r.id;let d=F.get(r.id);if(d===void 0){if(r.type==="composite")r.colorIndex=Ae++;F.set(r.id,r)}else{if(r.type!=="na")d.type=r.type;if(r.label!==r.id)d.label=r.label}if(r.children)ze(r.children,r);if(r.type==="space"){let E=r.width??1;for(let w=0;w<E;w++){let x=Ne(r);x.id=x.id+"-"+w,F.set(x.id,x),i.push(x)}}else if(d===void 0)i.push(r)}}o.children=i},"populateBlockDatabase"),ke=[],H={id:"root",type:"composite",children:[],columns:-1},lt=e(()=>{n.debug("Clear called"),A(),H={id:"root",type:"composite",children:[],columns:-1},F=new Map([["root",H]]),ke=[],Q=new Map,xe=[],be=new Map,Le="",Ae=0},"clear");function Be(t){switch(n.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return n.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"}}e(Be,"typeStr2Type");function Re(t){switch(n.debug("typeStr2Type",t),t){case"==":return"thick";default:return"normal"}}e(Re,"edgeTypeStr2Type");function Pe(t){switch(t.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}e(Pe,"edgeStrToEdgeData");function Fe(t){switch(t.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}e(Fe,"edgeStrToEdgeStartData");function Me(t){return t.includes("==")?"thick":"normal"}e(Me,"edgeStrToThickness");function Ke(t){if(t.includes(".-"))return"dotted";return"solid"}e(Ke,"edgeStrToPattern");var ve=0,ct=e(()=>(ve++,"id-"+Math.random().toString(36).substr(2,12)+"-"+ve),"generateId"),ut=e((t)=>{H.children=t,ze(t,H),ke=H.children},"setHierarchy"),ht=e((t)=>{let o=F.get(t);if(!o)return-1;if(o.columns)return o.columns;if(!o.children)return-1;return o.children.length},"getColumns"),gt=e(()=>[...F.values()],"getBlocksFlat"),dt=e(()=>ke||[],"getBlocks"),pt=e(()=>xe,"getEdges"),ft=e((t)=>F.get(t),"getBlock"),bt=e((t)=>{F.set(t.id,t)},"setBlock"),St=e((t)=>{Le=t},"setDiagramId"),xt=e(()=>Le,"getDiagramId"),Lt=e(()=>n,"getLogger"),kt=e(function(){return Q},"getClasses"),yt={getConfig:e(()=>k().block,"getConfig"),typeStr2Type:Be,edgeTypeStr2Type:Re,edgeStrToEdgeData:Pe,edgeStrToEdgeStartData:Fe,edgeStrToThickness:Me,edgeStrToPattern:Ke,getLogger:Lt,getBlocksFlat:gt,getBlocks:dt,getEdges:pt,setHierarchy:ut,getBlock:ft,setBlock:bt,getColumns:ht,getClasses:kt,clear:lt,generateId:ct,setDiagramId:St,getDiagramId:xt},Et=yt,wt=e((t)=>{let{theme:o,bkgColorArray:c,borderColorArray:i}=t;if(!de(o,i))return"";let g=fe(t.look),f=ge(c),r="";for(let d=0;d<Je(t.THEME_COLOR_LIMIT,i);d++){let E=i[d%i.length],w=f?`fill: ${c[d%c.length]};`:"",x=`[data-look="${g}"][data-color-id="color-${d}"]`;r+=`
|
|
7
7
|
|
|
8
8
|
${x}.node rect.composite {
|
|
9
9
|
stroke: ${E};
|
|
10
10
|
${w}
|
|
11
11
|
}
|
|
12
|
-
`}return r},"genColor"),
|
|
12
|
+
`}return r},"genColor"),he=e((t,o)=>{let c=mt,i=c(t,"r"),g=c(t,"g"),f=c(t,"b");return me(i,g,f,o)},"fade"),_t=e((t)=>`${wt(t)}
|
|
13
13
|
.label {
|
|
14
14
|
font-family: ${t.fontFamily};
|
|
15
15
|
color: ${t.nodeTextColor||t.textColor};
|
|
@@ -99,9 +99,9 @@ Expecting `+Z.join(", ")+", got '"+(this.terminals_[O]||O)+"'";else le="Parse er
|
|
|
99
99
|
}
|
|
100
100
|
|
|
101
101
|
.node .cluster {
|
|
102
|
-
// fill: ${
|
|
103
|
-
fill: ${
|
|
104
|
-
stroke: ${
|
|
102
|
+
// fill: ${he(t.mainBkg,0.5)};
|
|
103
|
+
fill: ${he(t.clusterBkg,0.5)};
|
|
104
|
+
stroke: ${he(t.clusterBorder,0.2)};
|
|
105
105
|
box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
|
|
106
106
|
stroke-width: 1px;
|
|
107
107
|
}
|
|
@@ -136,5 +136,5 @@ Expecting `+Z.join(", ")+", got '"+(this.terminals_[O]||O)+"'";else le="Parse er
|
|
|
136
136
|
font-size: 18px;
|
|
137
137
|
fill: ${t.textColor};
|
|
138
138
|
}
|
|
139
|
-
${
|
|
140
|
-
`,"getStyles"),
|
|
139
|
+
${Ye()}
|
|
140
|
+
`,"getStyles"),Dt=_t;function Se(t,o){if(t===0||!Number.isInteger(t))throw Error("Columns must be an integer !== 0.");if(o<0||!Number.isInteger(o))throw Error("Position must be a non-negative integer."+o);if(t<0)return{px:o,py:0};if(t===1)return{px:0,py:o};let c=o%t,i=Math.floor(o/t);return{px:c,py:i}}e(Se,"calculateBlockPosition");var Tt=e((t)=>{let o=0,c=0;for(let i of t.children){let{width:g,height:f,x:r,y:d}=i.size??{width:0,height:0,x:0,y:0};if(n.debug("getMaxChildSize abc95 child:",i.id,"width:",g,"height:",f,"x:",r,"y:",d,i.type),i.type==="space")continue;let E=g/(i.widthInColumns??1);if(E>o)o=E;if(f>c)c=f}return{width:o,height:c}},"getMaxChildSize");function ee(t,o,c=0,i=0,g=8){if(n.debug("setBlockSizes abc95 (start)",t.id,t?.size?.x,"block width =",t?.size,"siblingWidth",c),!t?.size?.width)t.size={width:c,height:i,x:0,y:0};let f=0,r=0;if(t.children?.length>0){for(let L of t.children)ee(L,o,0,0,g);let d=Tt(t);f=d.width,r=d.height,n.debug("setBlockSizes abc95 maxWidth of",t.id,":s children is ",f,r);for(let L of t.children)if(L.size)n.debug(`abc95 Setting size of children of ${t.id} id=${L.id} ${f} ${r} ${JSON.stringify(L.size)}`),L.size.width=f*(L.widthInColumns??1)+g*((L.widthInColumns??1)-1),L.size.height=r,L.size.x=0,L.size.y=0,n.debug(`abc95 updating size of ${t.id} children child:${L.id} maxWidth:${f} maxHeight:${r}`);for(let L of t.children)ee(L,o,f,r,g);let E=t.columns??-1,w=0;for(let L of t.children)w+=L.widthInColumns??1;let x=t.children.length;if(E>0&&E<w)x=E;let m=Math.ceil(w/x),_=x*(f+g)+g,T=m*(r+g)+g;if(_<c){n.debug(`Detected to small sibling: abc95 ${t.id} siblingWidth ${c} siblingHeight ${i} width ${_}`),_=c,T=i;let L=(c-x*g-g)/x,I=(i-m*g-g)/m;n.debug("Size indata abc88",t.id,"childWidth",L,"maxWidth",f),n.debug("Size indata abc88",t.id,"childHeight",I,"maxHeight",r),n.debug("Size indata abc88 xSize",x,"padding",g);for(let N of t.children)if(N.size)N.size.width=L,N.size.height=I,N.size.x=0,N.size.y=0}if(n.debug(`abc95 (finale calc) ${t.id} xSize ${x} ySize ${m} columns ${E}${t.children.length} width=${Math.max(_,t.size?.width||0)}`),_<(t?.size?.width||0)){_=t?.size?.width||0;let L=E>0?Math.min(t.children.length,E):t.children.length;if(L>0){let I=(_-L*g-g)/L;n.debug("abc95 (growing to fit) width",t.id,_,t.size?.width,I);for(let N of t.children)if(N.size)N.size.width=I}}t.size={width:_,height:T,x:0,y:0}}n.debug("setBlockSizes abc94 (done)",t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}e(ee,"setBlockSizes");function ye(t,o,c=8){n.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);let i=t.columns??-1;if(n.debug("layoutBlocks columns abc95",t.id,"=>",i,t),t.children&&t.children.length>0){let g=t?.children[0]?.size?.width??0,f=t.children.length*g+(t.children.length-1)*c;n.debug("widthOfChildren 88",f,"posX");let r=new Map;{let m=0;for(let _ of t.children){if(!_.size)continue;let{py:T}=Se(i,m),L=r.get(T)??0;if(_.size.height>L)r.set(T,_.size.height);let I=_?.widthInColumns??1;if(i>0)I=Math.min(I,i-m%i);m+=I}}let d=new Map;{let m=0,_=[...r.keys()].sort((T,L)=>T-L);for(let T of _)d.set(T,m),m+=(r.get(T)??0)+c}let E=0;n.debug("abc91 block?.size?.x",t.id,t?.size?.x);let w=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-c,x=0;for(let m of t.children){let _=t;if(!m.size)continue;let{width:T,height:L}=m.size,{px:I,py:N}=Se(i,E);if(N!=x)x=N,w=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-c,n.debug("New row in layout for block",t.id," and child ",m.id,x);if(n.debug(`abc89 layout blocks (child) id: ${m.id} Pos: ${E} (px, py) ${I},${N} (${_?.size?.x},${_?.size?.y}) parent: ${_.id} width: ${T}${c}`),_.size){let z=T/2;m.size.x=w+c+z,n.debug(`abc91 layout blocks (calc) px, pyid:${m.id} startingPos=X${w} new startingPosX${m.size.x} ${z} padding=${c} width=${T} halfWidth=${z} => x:${m.size.x} y:${m.size.y} ${m.widthInColumns} (width * (child?.w || 1)) / 2 ${T*(m?.widthInColumns??1)/2}`),w=m.size.x+z;let B=d.get(N)??0,b=r.get(N)??L;m.size.y=_.size.y-_.size.height/2+B+b/2+c,n.debug(`abc88 layout blocks (calc) px, pyid:${m.id}startingPosX${w}${c}${z}=>x:${m.size.x}y:${m.size.y}${m.widthInColumns}(width * (child?.w || 1)) / 2${T*(m?.widthInColumns??1)/2}`)}if(m.children)ye(m,o,c);let v=m?.widthInColumns??1;if(i>0)v=Math.min(v,i-E%i);E+=v,n.debug("abc88 columnsPos",m,E)}}n.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}e(ye,"layoutBlocks");function Ee(t,{minX:o,minY:c,maxX:i,maxY:g}={minX:0,minY:0,maxX:0,maxY:0}){if(t.size&&t.id!=="root"){let{x:f,y:r,width:d,height:E}=t.size;if(f-d/2<o)o=f-d/2;if(r-E/2<c)c=r-E/2;if(f+d/2>i)i=f+d/2;if(r+E/2>g)g=r+E/2}if(t.children)for(let f of t.children)({minX:o,minY:c,maxX:i,maxY:g}=Ee(f,{minX:o,minY:c,maxX:i,maxY:g}));return{minX:o,minY:c,maxX:i,maxY:g}}e(Ee,"findBounds");function We(t){let o=t.getBlock("root");if(!o)return;let c=u()?.block?.padding??8;ee(o,t,0,0,c),ye(o,t,c),n.debug("getBlocks",JSON.stringify(o,null,2));let{minX:i,minY:g,maxX:f,maxY:r}=Ee(o),d=r-g,E=f-i;return{x:i,y:g,width:E,height:d}}e(We,"layout");function we(t,o,c=!1){let i=t,g="default";if((i?.classes?.length||0)>0)g=(i?.classes??[]).join(" ");g=g+" flowchart-label";let f=(i?.classes??[]).flatMap((L)=>o.getClasses().get(L)?.styles??[]),r=0,d="rect",E;switch(i.type){case"round":r=5,d="rect";break;case"composite":r=0,d="composite",E=0;break;case"square":d="rect";break;case"diamond":d="question";break;case"hexagon":d="hexagon";break;case"block_arrow":d="block_arrow";break;case"odd":d="rect_left_inv_arrow";break;case"lean_right":d="lean_right";break;case"lean_left":d="lean_left";break;case"trapezoid":d="trapezoid";break;case"inv_trapezoid":d="inv_trapezoid";break;case"rect_left_inv_arrow":d="rect_left_inv_arrow";break;case"circle":d="circle";break;case"ellipse":d="ellipse";break;case"stadium":d="stadium";break;case"subroutine":d="subroutine";break;case"cylinder":d="cylinder";break;case"group":d="rect";break;case"doublecircle":d="doublecircle";break;default:d="rect"}let w=So(i?.styles??[]),x=i.label,m=i.size??{width:0,height:0,x:0,y:0},_=o.getDiagramId();return{labelStyle:w.labelStyle,shape:d,label:x,labelText:x,rx:r,ry:r,class:g,cssClasses:g,cssStyles:i?.styles??[],cssCompiledStyles:f,style:w.style,id:i.id,domId:_?`${_}-${i.id}`:i.id,isGroup:!1,directions:i.directions,width:m.width||void 0,height:m.height||void 0,wrappingWidth:m.width||Number.POSITIVE_INFINITY,x:m.x,y:m.y,positioned:c,intersect:void 0,padding:E??k()?.block?.padding??0,widthInColumns:i.widthInColumns??1,colorIndex:i.colorIndex,look:k().look}}e(we,"getNodeFromBlock");async function Ve(t,o,c){let i=we(o,c,!1);if(o.type==="group")return;let g=k(),f=await Bt(t,i,{config:g}),r=f.node()?.getBBox()??{width:0,height:0},d=c.getBlock(i.id);d.size={width:r.width,height:r.height,x:0,y:0,node:f},c.setBlock(d),f.remove()}e(Ve,"calculateBlockSize");async function Ue(t,o,c){let i=we(o,c,!0);if(c.getBlock(i.id).type!=="space"){let f=k(),r=await Bt(t,i,{config:f});if(i.colorIndex!==void 0)et(r,i.colorIndex,f.theme,f.themeVariables?.borderColorArray);o.intersect=i?.intersect,Ct(i)}}e(Ue,"insertBlockPositioned");async function te(t,o,c,i){for(let g of o)if(await i(t,g,c),g.children)await te(t,g.children,c,i)}e(te,"performOperations");async function He(t,o,c){await te(t,o,c,Ve)}e(He,"calculateBlockSizes");async function Xe(t,o,c){await te(t,o,c,Ue)}e(Xe,"insertBlocks");async function Ge(t,o,c,i,g){let f=new le({multigraph:!0,compound:!0});f.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(let r of c)if(r.size)f.setNode(r.id,{width:r.size.width,height:r.size.height,intersect:r.intersect});for(let r of o)if(r.start&&r.end){let d=i.getBlock(r.start),E=i.getBlock(r.end);if(d?.size&&E?.size){let w=d.size,x=E.size,m=[{x:w.x,y:w.y},{x:w.x+(x.x-w.x)/2,y:w.y+(x.y-w.y)/2},{x:x.x,y:x.y}],_=g?`${g}-${r.id}`:r.id,T=r.thickness==="thick"?"edge-thickness-thick":"edge-thickness-normal",L=r.pattern==="dotted"?"edge-pattern-dotted":"edge-pattern-solid",I=`${T} ${L} flowchart-link LS-a1 LE-b1`;if(gr(t,{...r,id:_,arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:m,classes:I},{},"block",f.node(r.start),f.node(r.end),g),r.label)await Ft(t,{...r,label:r.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:m,classes:I}),yn({...r,x:m[1].x,y:m[1].y},{originalPath:m})}}}e(Ge,"insertEdges");var Nt=e(function(t,o){return o.db.getClasses()},"getClasses"),It=e(async function(t,o,c,i){let{securityLevel:g,block:f}=k(),r=i.db;r.setDiagramId(o);let d;if(g==="sandbox")d=p("#i"+o);let E=g==="sandbox"?p(d.nodes()[0].contentDocument.body):p("body"),w=g==="sandbox"?E.select(`[id="${o}"]`):p(`[id="${o}"]`);ao(w,k()),xn(w,["point","circle","cross"],i.type,o);let m=r.getBlocks(),_=r.getBlocksFlat(),T=r.getEdges(),L=w.insert("g").attr("class","block");await He(L,m,r);let I=We(r);await Xe(L,m,r),await Ge(L,T,_,r,o);let N=L.node()?.getBBox(),v=N&&Number.isFinite(N.width)&&Number.isFinite(N.height)?N:I;if(v){let z=Math.max(1,Math.round(0.125*(v.width/v.height))),B=v.height+z+10,b=v.width+10,{useMaxWidth:a}=f;j(w,B,b,!!a),n.debug("Here Bounds",I,v),w.attr("viewBox",`${v.x-5} ${v.y-5} ${v.width+10} ${v.height+10}`)}},"draw"),vt={draw:It,getClasses:Nt},or={parser:rt,db:Et,renderer:vt,styles:Dt};export{or as diagram};
|