@bkm016/basalt 0.1.9 → 0.1.10
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/{chunk-0xd9mnc2.js → chunk-0mjb3sm3.js} +2 -2
- package/{chunk-66h5qpc6.js → chunk-3mqf9ped.js} +89 -89
- package/compiled.js +1 -1
- package/package.json +1 -1
- package/ui-test-worker.js +1 -1
- package/web/chunk-045d3b5d.js +1 -0
- package/web/{chunk-ff1pmd3g.js → chunk-0770q5e1.js} +1 -1
- package/web/{chunk-2x4g9t37.js → chunk-18neka5g.js} +2 -2
- package/web/{chunk-w3w18stt.js → chunk-1ev0n3n4.js} +1 -1
- package/web/chunk-1ex3wgms.js +2 -0
- package/web/{chunk-7qkav30b.js → chunk-1qh7f5kr.js} +1 -1
- package/web/{chunk-rayf24gy.js → chunk-26ecc2xh.js} +8 -8
- package/web/{chunk-me7dza1c.js → chunk-2cz7tx8q.js} +1 -1
- package/web/{chunk-mdfksj61.js → chunk-32ty2xfn.js} +1 -1
- package/web/{chunk-ts6jsfdk.js → chunk-3eexx7y5.js} +1 -1
- package/web/{chunk-2dvbeqt0.js → chunk-46jnkghq.js} +1 -1
- package/web/chunk-4am8j3k3.js +1 -0
- package/web/{chunk-qz6r9v1z.js → chunk-5qvmefq2.js} +1 -1
- package/web/{chunk-9ctg0f30.js → chunk-5svqfj4g.js} +1 -1
- package/web/{chunk-qsqtwf34.js → chunk-5v5q13hz.js} +1 -1
- package/web/chunk-7np1jp3x.js +8 -0
- package/web/chunk-87e8d1hv.js +1 -0
- package/web/{chunk-kcjz03h5.js → chunk-88wd49xe.js} +2 -2
- package/web/{chunk-0pghpg4y.js → chunk-8h2x89tw.js} +1 -1
- package/web/chunk-8y2526ve.js +1 -0
- package/web/{chunk-8jcvdd5d.js → chunk-905vw286.js} +1 -1
- package/web/{chunk-2hrswh3d.js → chunk-918e5t4x.js} +1 -1
- package/web/chunk-96m2m3e8.js +1 -0
- package/web/{chunk-43g4wd7a.js → chunk-9f4zzqbx.js} +1 -1
- package/web/{chunk-dnv8dx72.js → chunk-a1n4468c.js} +1 -1
- package/web/{chunk-s37beysw.js → chunk-b46ws7rf.js} +1 -1
- package/web/{chunk-24jhbz82.js → chunk-bc3ajvfg.js} +1 -1
- package/web/{chunk-ket6g0yd.js → chunk-d5gshd1a.js} +1 -1
- package/web/{chunk-c6yacwbc.js → chunk-de40q05r.js} +1 -1
- package/web/chunk-dp0k5vhd.js +1 -0
- package/web/{chunk-5dr4tkem.js → chunk-dv1berk6.js} +3 -3
- package/web/{chunk-dwjmr0zj.js → chunk-eh7wp62z.js} +1 -1
- package/web/{chunk-ctzkqx2g.js → chunk-ehtmb6sn.js} +1 -1
- package/web/chunk-et1hytyv.js +1 -0
- package/web/chunk-f9m9seam.js +1 -0
- package/web/{chunk-3pd0qt83.js → chunk-fmmrthpa.js} +2 -2
- package/web/chunk-g2erm7k0.js +1 -0
- package/web/chunk-g3kbn0t2.js +1 -0
- package/web/{chunk-t893141g.js → chunk-g7dc4hrd.js} +1 -1
- package/web/{chunk-p9hfcamx.js → chunk-g7kz8f7q.js} +1 -1
- package/web/chunk-ght0t49g.js +1 -0
- package/web/{chunk-xa43ndfj.js → chunk-ghwm7bdj.js} +2 -2
- package/web/{chunk-8z0r0wtk.js → chunk-grm2208k.js} +1 -1
- package/web/{chunk-0zwc2rvh.js → chunk-gsw1tv96.js} +1 -1
- package/web/{chunk-tftc5v89.js → chunk-gw8x1g61.js} +1 -1
- package/web/chunk-gx340asc.js +1 -0
- package/web/{chunk-935mjq1c.js → chunk-h2txs73e.js} +1 -1
- package/web/chunk-h3tkacc7.js +1 -0
- package/web/{chunk-ewx42c11.js → chunk-h5ckjk48.js} +1 -1
- package/web/{chunk-nnyc889n.js → chunk-j37p0b13.js} +1 -1
- package/web/{chunk-fjb3ksfd.js → chunk-j89s11x8.js} +1 -1
- package/web/chunk-je78j3vr.js +1 -0
- package/web/{chunk-fpb2dd2d.js → chunk-jke2ev6m.js} +1 -1
- package/web/{chunk-98y92vmh.js → chunk-js6kb05s.js} +1 -1
- package/web/{chunk-30b33r2w.js → chunk-k0cg4n2k.js} +2 -2
- package/web/{chunk-b5h52neg.js → chunk-knm82fw9.js} +1 -1
- package/web/{chunk-vqmj6peg.js → chunk-kxdtg9dt.js} +1 -1
- package/web/{chunk-db3twjvk.js → chunk-m4fxd5d9.js} +5 -5
- package/web/chunk-m9xzt9p7.js +1 -0
- package/web/{chunk-xx11yv61.js → chunk-n4yzs2q0.js} +1 -1
- package/web/{chunk-zdyys4ar.js → chunk-nawxgz87.js} +2 -2
- package/web/chunk-ngt1j8py.js +1139 -0
- package/web/{chunk-3ak5dg10.js → chunk-p55vhns6.js} +1 -1
- package/web/{chunk-nvpp0ghj.js → chunk-pgwf37s2.js} +1 -1
- package/web/{chunk-af9evdza.js → chunk-q4bst4an.js} +1 -1
- package/web/{chunk-9fnr00kv.js → chunk-qdzy124b.js} +2 -2
- package/web/chunk-qe0bgeda.js +1 -0
- package/web/{chunk-60axh4sa.js → chunk-qy1zx2yw.js} +2 -2
- package/web/{chunk-sk1wkgjw.js → chunk-rag65pfs.js} +1 -1
- package/web/{chunk-5jdrev9p.js → chunk-rbqnre6q.js} +3 -3
- package/web/{chunk-ddyyc20r.js → chunk-rh3xb76f.js} +1 -1
- package/web/{chunk-wzd2a4k5.js → chunk-rwfmccmh.js} +1 -1
- package/web/{chunk-zb2bkr7f.js → chunk-rxvm70w5.js} +1 -1
- package/web/{chunk-z05x9cbm.js → chunk-sat7zyva.js} +1 -1
- package/web/{chunk-rrpn5r5w.js → chunk-sc63488q.js} +1 -1
- package/web/{chunk-v1exk5wd.js → chunk-sd3xat3r.js} +6 -6
- package/web/{chunk-4a6gdrbs.js → chunk-se4h6wx0.js} +1 -1
- package/web/{chunk-a0ryzdnp.js → chunk-sjkg40ay.js} +1 -1
- package/web/chunk-sk0hpa80.js +1 -0
- package/web/{chunk-spbs56wz.js → chunk-t5nvgz7z.js} +1 -1
- package/web/{chunk-veam6vk4.js → chunk-tfqarvdx.js} +30 -30
- package/web/{chunk-5a4mj3qz.js → chunk-tqze6d6b.js} +1 -1
- package/web/{chunk-8w7fyb3v.js → chunk-tt93zbn4.js} +7 -7
- package/web/chunk-tvcxrx6h.js +1 -0
- package/web/chunk-tzpnh70q.js +1 -0
- package/web/{chunk-79e08rk1.js → chunk-vasppf6b.js} +1 -1
- package/web/chunk-vb7g4xg6.js +1 -0
- package/web/{chunk-dz7g1gnv.js → chunk-w3zgfhjb.js} +1 -1
- package/web/{chunk-gn8kyz76.js → chunk-wrevb4ew.js} +1 -1
- package/web/{chunk-3ecrkvr3.js → chunk-wtvch4ad.js} +1 -1
- package/web/chunk-wzfe6jtq.js +1 -0
- package/web/{chunk-eadfxfkw.js → chunk-x5g1yy12.js} +1 -1
- package/web/{chunk-m9q5nr8f.js → chunk-x850q01z.js} +1 -1
- package/web/{chunk-a61zrp66.js → chunk-xk904wqv.js} +1 -1
- package/web/{chunk-3hr3ew9w.js → chunk-xtn305fd.js} +1 -1
- package/web/{chunk-3txxt0a7.js → chunk-yekaz74b.js} +1 -1
- package/web/{chunk-rasjtvsb.js → chunk-yppgejg7.js} +2 -2
- package/web/{chunk-66wb0p6e.js → chunk-z4bp6p32.js} +1 -1
- package/web/{chunk-5v2c0aqk.js → chunk-z5qn0xev.js} +1 -1
- package/web/{chunk-5baeh8q7.js → chunk-zms6mrqk.js} +4 -4
- package/web/{chunk-601k823s.js → chunk-zse05v6j.js} +2 -2
- package/web/{chunk-vsjpnwsr.js → chunk-zz1qkaar.js} +1 -1
- package/web/index.html +1 -1
- package/web/chunk-08sq3cwm.js +0 -1
- package/web/chunk-24fjnnee.js +0 -1
- package/web/chunk-2j2atyjw.js +0 -1
- package/web/chunk-3h3g3ca3.js +0 -1
- package/web/chunk-3pcrxg6m.js +0 -1
- package/web/chunk-814kkkmq.js +0 -8
- package/web/chunk-8w8atrdh.js +0 -1
- package/web/chunk-942g3eqn.js +0 -1
- package/web/chunk-avxk6jpc.js +0 -2
- package/web/chunk-fmthkpff.js +0 -1
- package/web/chunk-gv99c8zv.js +0 -1
- package/web/chunk-h0767tjv.js +0 -1
- package/web/chunk-hqynf99g.js +0 -1
- package/web/chunk-mbwwj216.js +0 -1
- package/web/chunk-n0wazxgz.js +0 -1
- package/web/chunk-nvt9tkt4.js +0 -1139
- package/web/chunk-ph1dgffm.js +0 -1
- package/web/chunk-rad2s9ha.js +0 -1
- package/web/chunk-s60s09mb.js +0 -1
- package/web/chunk-tfvcs2xx.js +0 -1
- package/web/chunk-wdq2tp9e.js +0 -1
- package/web/chunk-wkf5xfyr.js +0 -1
- package/web/chunk-y1qty77a.js +0 -1
- package/web/chunk-zgavhnt8.js +0 -1
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import{t,Kt,a,de,b,C,S,E,T,A,L,R,l,p,M,ze,Jr,pe,se,le,gt,ge,ye}from"./chunk-veam6vk4.js";import{Bt}from"./chunk-avxk6jpc.js";import{he}from"./chunk-rrpn5r5w.js";import{ue}from"./chunk-7qkav30b.js";var Ue=function(){var s=t(function(q,o,h,k){for(h=h||{},k=q.length;k--;h[q[k]]=o);return h},"o"),c=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],f=[2,2],n=[1,7],u=[1,9],y=[1,10],x=[1,11],_=[1,12],I=[1,30],g=[1,23],m=[1,24],B=[1,25],W=[1,26],X=[1,27],v=[1,19],Y=[1,28],te=[1,29],G=[1,20],P=[1,18],z=[1,21],U=[1,22],Ke=[2,6],d=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],Re=[1,36],ve=[1,37],De=[1,38],Le=[1,39],we=[1,40],ie=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],K=[1,46],Z=[1,47],re=[1,57],ae=[43,51,53,54,55,74,75],ne=[1,70],oe=[1,68],j=[1,65],ce=[1,69],be=[1,71],_e=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],me=[1,78],Ee=[1,77],Se=[1,76],Ze=[69,70,71,72,73],je=[1,91],qe=[6,9,45,50],J=[6,9,12,44,45,50,51,52],Te=[1,101],Ce=[1,100],Oe=[1,99],fe=[18,61],We=[1,110],He=[1,109],Qe=[20,43,51,53,54,55],Ve=[18,61,64,66],Me={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",9:"NEWLINE",12:"COLON",14:"STYLE_SEPARATOR",16:"BLOCK_START",18:"BLOCK_STOP",19:"SQS",20:"SQE",21:"title",22:"title_value",23:"acc_title",24:"acc_title_value",25:"acc_descr",26:"acc_descr_value",27:"acc_descr_multiline_value",33:"END",34:"SUBGRAPH",37:"direction_tb",38:"direction_bt",39:"direction_rl",40:"direction_lr",41:"CLASSDEF",43:"UNICODE_TEXT",44:"STYLE_TEXT",45:"COMMA",46:"CLASS",47:"STYLE",50:"SEMI",51:"NUM",52:"BRKT",53:"ENTITY_NAME",54:"DECIMAL_NUM",55:"ENTITY_ONE",61:"ATTRIBUTE_WORD",62:"?",64:",",65:"ATTRIBUTE_KEY",66:"COMMENT",69:"ZERO_OR_ONE",70:"ZERO_OR_MORE",71:"ONE_OR_MORE",72:"ONLY_ONE",73:"MD_PARENT",74:"NON_IDENTIFYING",75:"IDENTIFYING",76:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:t(function(o,h,k,r,O,e,ke){var i=e.length-1;switch(O){case 1:break;case 2:this.$=[];break;case 3:this.$=e[i-1].concat(e[i]);break;case 4:this.$=e[i];break;case 5:case 6:this.$=[];break;case 7:r.addEntity(e[i-4]),r.addEntity(e[i-2]),r.addRelationship(e[i-4],e[i],e[i-2],e[i-3]),this.$=[e[i-4],e[i-2]];break;case 8:r.addEntity(e[i-8]),r.addEntity(e[i-4]),r.addRelationship(e[i-8],e[i],e[i-4],e[i-5]),r.setClass([e[i-8]],e[i-6]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-8],e[i-4]];break;case 9:r.addEntity(e[i-6]),r.addEntity(e[i-2]),r.addRelationship(e[i-6],e[i],e[i-2],e[i-3]),r.setClass([e[i-6]],e[i-4]),this.$=[e[i-6],e[i-2]];break;case 10:r.addEntity(e[i-6]),r.addEntity(e[i-4]),r.addRelationship(e[i-6],e[i],e[i-4],e[i-5]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-6],e[i-4]];break;case 11:r.addEntity(e[i-3]),r.addAttributes(e[i-3],e[i-1]),this.$=[e[i-3]];break;case 12:r.addEntity(e[i-5]),r.addAttributes(e[i-5],e[i-1]),r.setClass([e[i-5]],e[i-3]),this.$=[e[i-5]];break;case 13:r.addEntity(e[i-2]),this.$=[e[i-2]];break;case 14:r.addEntity(e[i-4]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-4]];break;case 15:r.addEntity(e[i]),this.$=[e[i]];break;case 16:r.addEntity(e[i-2]),r.setClass([e[i-2]],e[i]),this.$=[e[i-2]];break;case 17:r.addEntity(e[i-6],e[i-4]),r.addAttributes(e[i-6],e[i-1]),this.$=[e[i-6]];break;case 18:r.addEntity(e[i-8],e[i-6]),r.addAttributes(e[i-8],e[i-1]),r.setClass([e[i-8]],e[i-3]),this.$=[e[i-8]];break;case 19:r.addEntity(e[i-5],e[i-3]),this.$=[e[i-5]];break;case 20:r.addEntity(e[i-7],e[i-5]),r.setClass([e[i-7]],e[i-2]),this.$=[e[i-7]];break;case 21:r.addEntity(e[i-3],e[i-1]);break;case 22:r.addEntity(e[i-5],e[i-3]),r.setClass([e[i-5]],e[i]);break;case 23:case 24:this.$=e[i].trim(),r.setAccTitle(this.$);break;case 25:case 26:this.$=e[i].trim(),r.setAccDescription(this.$);break;case 27:if(!r.subgraphDepth)r.setDirection(e[i].value),this.$=[];else this.$=e[i];break;case 31:r.subgraphDepth=(r.subgraphDepth||1)-1,this.$=r.addSubGraph({text:e[i-2].id},e[i-1],{text:e[i-2].text});break;case 32:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:e[i-1],text:e[i-1]};break;case 33:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:e[i-4],text:e[i-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=e[i];break;case 35:this.$=e[i-1]+" "+e[i];break;case 36:this.$={stmt:"dir",value:"TB"};break;case 37:this.$={stmt:"dir",value:"BT"};break;case 38:this.$={stmt:"dir",value:"RL"};break;case 39:this.$={stmt:"dir",value:"LR"};break;case 40:this.$=e[i-3],r.addClass(e[i-2],e[i-1]);break;case 41:case 42:case 63:case 72:this.$=[e[i]];break;case 43:case 44:this.$=e[i-2].concat([e[i]]);break;case 45:this.$=e[i-2],r.setClass(e[i-1],e[i]);break;case 46:this.$=e[i-3],r.addCssStyles(e[i-2],e[i-1]);break;case 47:this.$=[e[i]];break;case 48:e[i-2].push(e[i]),this.$=e[i-2];break;case 50:this.$=e[i-1]+e[i];break;case 58:case 84:case 85:this.$=e[i].replace(/"/g,"");break;case 64:e[i].push(e[i-1]),this.$=e[i];break;case 65:this.$={type:e[i-1],name:e[i]};break;case 66:this.$={type:e[i-2],name:e[i-1],keys:e[i]};break;case 67:this.$={type:e[i-2],name:e[i-1],comment:e[i]};break;case 68:this.$={type:e[i-3],name:e[i-2],keys:e[i-1],comment:e[i]};break;case 69:case 71:case 74:this.$=e[i];break;case 70:this.$=e[i-1]+e[i];break;case 73:e[i-2].push(e[i]),this.$=e[i-2];break;case 75:this.$=e[i].replace(/"/g,"");break;case 76:this.$={cardA:e[i],relType:e[i-1],cardB:e[i-2]};break;case 77:this.$=r.Cardinality.ZERO_OR_ONE;break;case 78:this.$=r.Cardinality.ZERO_OR_MORE;break;case 79:this.$=r.Cardinality.ONE_OR_MORE;break;case 80:this.$=r.Cardinality.ONLY_ONE;break;case 81:this.$=r.Cardinality.MD_PARENT;break;case 82:this.$=r.Identification.NON_IDENTIFYING;break;case 83:this.$=r.Identification.IDENTIFYING;break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},s(c,f,{5:3}),{6:[1,4],7:5,8:6,9:n,10:8,21:u,23:y,25:x,27:_,28:13,29:14,30:15,31:16,32:17,34:I,37:g,38:m,39:B,40:W,41:X,43:v,46:Y,47:te,51:G,53:P,54:z,55:U},s(c,Ke,{1:[2,1]}),s(d,[2,3]),s(d,[2,4]),s(d,[2,5]),s(d,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:Re,70:ve,71:De,72:Le,73:we}),{22:[1,41]},{24:[1,42]},{26:[1,43]},s(d,[2,26]),s(d,[2,27]),s(d,[2,28]),s(d,[2,29]),s(d,[2,30]),s(d,f,{5:44}),s(ie,[2,58]),s(ie,[2,59]),s(ie,[2,60]),s(ie,[2,61]),s(ie,[2,62]),s(d,[2,36]),s(d,[2,37]),s(d,[2,38]),s(d,[2,39]),{15:45,43:K,44:Z},{15:48,43:K,44:Z},{15:49,43:K,44:Z},{10:50,43:v,51:G,53:P,54:z,55:U},{10:51,43:v,51:G,53:P,54:z,55:U},{15:52,43:K,44:Z},{17:53,18:[1,54],56:55,57:56,61:re},{10:58,43:v,51:G,53:P,54:z,55:U},{68:59,74:[1,60],75:[1,61]},s(ae,[2,77]),s(ae,[2,78]),s(ae,[2,79]),s(ae,[2,80]),s(ae,[2,81]),s(d,[2,23]),s(d,[2,24]),s(d,[2,25]),{6:[1,63],7:5,8:6,9:n,10:8,21:u,23:y,25:x,27:_,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:I,37:g,38:m,39:B,40:W,41:X,43:v,46:Y,47:te,51:G,53:P,54:z,55:U},{12:ne,42:64,44:oe,45:j,48:66,49:67,51:ce,52:be},s(_e,[2,41]),s(_e,[2,42]),{15:72,43:K,44:Z,45:j},{12:ne,42:73,44:oe,45:j,48:66,49:67,51:ce,52:be},{6:me,9:Ee,19:[1,75],35:74,50:Se},{12:[1,79],14:[1,80]},s(d,[2,16],{67:35,11:81,16:[1,82],45:j,69:Re,70:ve,71:De,72:Le,73:we}),{18:[1,83]},s(d,[2,13]),{17:84,18:[2,63],56:55,57:56,61:re},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:Re,70:ve,71:De,72:Le,73:we},s(Ze,[2,82]),s(Ze,[2,83]),s(d,[2,31]),s(d,Ke),{6:me,9:Ee,35:90,45:je,50:Se},{43:[1,92],44:[1,93]},s(qe,[2,47],{49:94,12:ne,44:oe,51:ce,52:be}),s(J,[2,49]),s(J,[2,54]),s(J,[2,55]),s(J,[2,56]),s(J,[2,57]),s(d,[2,45],{45:j}),{6:me,9:Ee,35:95,45:je,50:Se},s(d,[2,32]),{10:97,36:96,43:v,51:G,53:P,54:z,55:U},s(d,[2,51]),s(d,[2,52]),s(d,[2,53]),{13:98,43:Te,53:Ce,76:Oe},{15:102,43:K,44:Z},{10:103,43:v,51:G,53:P,54:z,55:U},{17:104,18:[1,105],56:55,57:56,61:re},s(d,[2,11]),{18:[2,64]},s(fe,[2,65],{59:106,60:107,63:108,65:We,66:He}),s([18,61,65,66],[2,71]),{61:[2,70]},s(d,[2,21],{14:[1,112],16:[1,111]}),s([43,51,53,54,55],[2,76]),s(d,[2,40]),{12:ne,44:oe,48:113,49:67,51:ce,52:be},s(_e,[2,43]),s(_e,[2,44]),s(J,[2,50]),s(d,[2,46]),{10:115,20:[1,114],43:v,51:G,53:P,54:z,55:U},s(Qe,[2,34]),s(d,[2,7]),s(d,[2,84]),s(d,[2,85]),s(d,[2,86]),{12:[1,116],45:j},{12:[1,118],14:[1,117]},{18:[1,119]},s(d,[2,14]),s(fe,[2,66],{60:120,64:[1,121],66:He}),s(fe,[2,67]),s(Ve,[2,72]),s(fe,[2,75]),s(Ve,[2,74]),{17:122,18:[1,123],56:55,57:56,61:re},{15:124,43:K,44:Z},s(qe,[2,48],{49:94,12:ne,44:oe,51:ce,52:be}),{6:me,9:Ee,35:125,50:Se},s(Qe,[2,35]),{13:126,43:Te,53:Ce,76:Oe},{15:127,43:K,44:Z},{13:128,43:Te,53:Ce,76:Oe},s(d,[2,12]),s(fe,[2,68]),{63:129,65:We},{18:[1,130]},s(d,[2,19]),s(d,[2,22],{16:[1,131],45:j}),s(d,[2,33]),s(d,[2,10]),{12:[1,132],45:j},s(d,[2,9]),s(Ve,[2,73]),s(d,[2,17]),{17:133,18:[1,134],56:55,57:56,61:re},{13:135,43:Te,53:Ce,76:Oe},{18:[1,136]},s(d,[2,20]),s(d,[2,8]),s(d,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:t(function(o,h){if(h.recoverable)this.trace(o);else{var k=Error(o);throw k.hash=h,k}},"parseError"),parse:t(function(o){var h=this,k=[0],r=[],O=[null],e=[],ke=this.table,i="",xe=0,Xe=0,Je=0,at=2,$e=1,nt=e.slice.call(arguments,1),N=Object.create(this.lexer),H={yy:{}};for(var Be in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,Be))H.yy[Be]=this.yy[Be];if(N.setInput(o,H.yy),H.yy.lexer=N,H.yy.parser=this,typeof N.yylloc>"u")N.yylloc={};var Ge=N.yylloc;e.push(Ge);var ot=N.options&&N.options.ranges;if(typeof H.yy.parseError==="function")this.parseError=H.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function lt(V){k.length=k.length-2*V,O.length=O.length-V,e.length=e.length-V}t(lt,"popStack");function et(){var V=r.pop()||N.lex()||$e;if(typeof V!=="number"){if(V instanceof Array)r=V,V=r.pop();V=h.symbols_[V]||V}return V}t(et,"lex");var D,Fe,Q,w,ft,Ye,ee={},Ae,F,tt,Ie;while(!0){if(Q=k[k.length-1],this.defaultActions[Q])w=this.defaultActions[Q];else{if(D===null||typeof D>"u")D=et();w=ke[Q]&&ke[Q][D]}if(typeof w>"u"||!w.length||!w[0]){var Pe="";Ie=[];for(Ae in ke[Q])if(this.terminals_[Ae]&&Ae>at)Ie.push("'"+this.terminals_[Ae]+"'");if(N.showPosition)Pe="Parse error on line "+(xe+1)+`:
|
|
1
|
+
import{t,Kt,a,de,b,C,S,E,T,A,L,R,l,p,M,ze,Jr,pe,se,le,yt,ge,ye}from"./chunk-tfqarvdx.js";import{Bt}from"./chunk-1ex3wgms.js";import{he}from"./chunk-sc63488q.js";import{ue}from"./chunk-1qh7f5kr.js";var Ue=function(){var s=t(function(q,o,h,k){for(h=h||{},k=q.length;k--;h[q[k]]=o);return h},"o"),c=[6,9,21,23,25,27,34,37,38,39,40,41,43,46,47,51,53,54,55],f=[2,2],n=[1,7],u=[1,9],y=[1,10],x=[1,11],_=[1,12],I=[1,30],g=[1,23],m=[1,24],B=[1,25],W=[1,26],X=[1,27],v=[1,19],Y=[1,28],te=[1,29],G=[1,20],P=[1,18],z=[1,21],U=[1,22],Ke=[2,6],d=[6,9,21,23,25,27,33,34,37,38,39,40,41,43,46,47,51,53,54,55],Re=[1,36],ve=[1,37],De=[1,38],Le=[1,39],we=[1,40],ie=[6,9,12,14,16,19,20,21,23,25,27,33,34,37,38,39,40,41,43,46,47,50,51,53,54,55,69,70,71,72,73],K=[1,46],Z=[1,47],re=[1,57],ae=[43,51,53,54,55,74,75],ne=[1,70],oe=[1,68],j=[1,65],ce=[1,69],be=[1,71],_e=[6,9,12,16,21,23,25,27,33,34,37,38,39,40,41,43,44,45,46,47,51,52,53,54,55,69,70,71,72,73],me=[1,78],Ee=[1,77],Se=[1,76],Ze=[69,70,71,72,73],je=[1,91],qe=[6,9,45,50],J=[6,9,12,44,45,50,51,52],Te=[1,101],Ce=[1,100],Oe=[1,99],fe=[18,61],We=[1,110],He=[1,109],Qe=[20,43,51,53,54,55],Ve=[18,61,64,66],Me={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,statement:8,NEWLINE:9,entityName:10,relSpec:11,COLON:12,role:13,STYLE_SEPARATOR:14,idList:15,BLOCK_START:16,attributes:17,BLOCK_STOP:18,SQS:19,SQE:20,title:21,title_value:22,acc_title:23,acc_title_value:24,acc_descr:25,acc_descr_value:26,acc_descr_multiline_value:27,direction:28,classDefStatement:29,classStatement:30,styleStatement:31,subgraphHeader:32,END:33,SUBGRAPH:34,separator:35,subgraphTitle:36,direction_tb:37,direction_bt:38,direction_rl:39,direction_lr:40,CLASSDEF:41,stylesOpt:42,UNICODE_TEXT:43,STYLE_TEXT:44,COMMA:45,CLASS:46,STYLE:47,style:48,styleComponent:49,SEMI:50,NUM:51,BRKT:52,ENTITY_NAME:53,DECIMAL_NUM:54,ENTITY_ONE:55,attribute:56,attributeType:57,attributeName:58,attributeKeyTypeList:59,attributeComment:60,ATTRIBUTE_WORD:61,"?":62,attributeKeyType:63,",":64,ATTRIBUTE_KEY:65,COMMENT:66,cardinality:67,relType:68,ZERO_OR_ONE:69,ZERO_OR_MORE:70,ONE_OR_MORE:71,ONLY_ONE:72,MD_PARENT:73,NON_IDENTIFYING:74,IDENTIFYING:75,WORD:76,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",9:"NEWLINE",12:"COLON",14:"STYLE_SEPARATOR",16:"BLOCK_START",18:"BLOCK_STOP",19:"SQS",20:"SQE",21:"title",22:"title_value",23:"acc_title",24:"acc_title_value",25:"acc_descr",26:"acc_descr_value",27:"acc_descr_multiline_value",33:"END",34:"SUBGRAPH",37:"direction_tb",38:"direction_bt",39:"direction_rl",40:"direction_lr",41:"CLASSDEF",43:"UNICODE_TEXT",44:"STYLE_TEXT",45:"COMMA",46:"CLASS",47:"STYLE",50:"SEMI",51:"NUM",52:"BRKT",53:"ENTITY_NAME",54:"DECIMAL_NUM",55:"ENTITY_ONE",61:"ATTRIBUTE_WORD",62:"?",64:",",65:"ATTRIBUTE_KEY",66:"COMMENT",69:"ZERO_OR_ONE",70:"ZERO_OR_MORE",71:"ONE_OR_MORE",72:"ONLY_ONE",73:"MD_PARENT",74:"NON_IDENTIFYING",75:"IDENTIFYING",76:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,1],[7,1],[7,1],[8,5],[8,9],[8,7],[8,7],[8,4],[8,6],[8,3],[8,5],[8,1],[8,3],[8,7],[8,9],[8,6],[8,8],[8,4],[8,6],[8,2],[8,2],[8,2],[8,1],[8,1],[8,1],[8,1],[8,1],[8,3],[32,3],[32,6],[36,1],[36,2],[28,1],[28,1],[28,1],[28,1],[29,4],[15,1],[15,1],[15,3],[15,3],[30,3],[31,4],[42,1],[42,3],[48,1],[48,2],[35,1],[35,1],[35,1],[49,1],[49,1],[49,1],[49,1],[10,1],[10,1],[10,1],[10,1],[10,1],[17,1],[17,2],[56,2],[56,3],[56,3],[56,4],[57,1],[57,2],[58,1],[59,1],[59,3],[63,1],[60,1],[11,3],[67,1],[67,1],[67,1],[67,1],[67,1],[68,1],[68,1],[13,1],[13,1],[13,1]],performAction:t(function(o,h,k,r,O,e,ke){var i=e.length-1;switch(O){case 1:break;case 2:this.$=[];break;case 3:this.$=e[i-1].concat(e[i]);break;case 4:this.$=e[i];break;case 5:case 6:this.$=[];break;case 7:r.addEntity(e[i-4]),r.addEntity(e[i-2]),r.addRelationship(e[i-4],e[i],e[i-2],e[i-3]),this.$=[e[i-4],e[i-2]];break;case 8:r.addEntity(e[i-8]),r.addEntity(e[i-4]),r.addRelationship(e[i-8],e[i],e[i-4],e[i-5]),r.setClass([e[i-8]],e[i-6]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-8],e[i-4]];break;case 9:r.addEntity(e[i-6]),r.addEntity(e[i-2]),r.addRelationship(e[i-6],e[i],e[i-2],e[i-3]),r.setClass([e[i-6]],e[i-4]),this.$=[e[i-6],e[i-2]];break;case 10:r.addEntity(e[i-6]),r.addEntity(e[i-4]),r.addRelationship(e[i-6],e[i],e[i-4],e[i-5]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-6],e[i-4]];break;case 11:r.addEntity(e[i-3]),r.addAttributes(e[i-3],e[i-1]),this.$=[e[i-3]];break;case 12:r.addEntity(e[i-5]),r.addAttributes(e[i-5],e[i-1]),r.setClass([e[i-5]],e[i-3]),this.$=[e[i-5]];break;case 13:r.addEntity(e[i-2]),this.$=[e[i-2]];break;case 14:r.addEntity(e[i-4]),r.setClass([e[i-4]],e[i-2]),this.$=[e[i-4]];break;case 15:r.addEntity(e[i]),this.$=[e[i]];break;case 16:r.addEntity(e[i-2]),r.setClass([e[i-2]],e[i]),this.$=[e[i-2]];break;case 17:r.addEntity(e[i-6],e[i-4]),r.addAttributes(e[i-6],e[i-1]),this.$=[e[i-6]];break;case 18:r.addEntity(e[i-8],e[i-6]),r.addAttributes(e[i-8],e[i-1]),r.setClass([e[i-8]],e[i-3]),this.$=[e[i-8]];break;case 19:r.addEntity(e[i-5],e[i-3]),this.$=[e[i-5]];break;case 20:r.addEntity(e[i-7],e[i-5]),r.setClass([e[i-7]],e[i-2]),this.$=[e[i-7]];break;case 21:r.addEntity(e[i-3],e[i-1]);break;case 22:r.addEntity(e[i-5],e[i-3]),r.setClass([e[i-5]],e[i]);break;case 23:case 24:this.$=e[i].trim(),r.setAccTitle(this.$);break;case 25:case 26:this.$=e[i].trim(),r.setAccDescription(this.$);break;case 27:if(!r.subgraphDepth)r.setDirection(e[i].value),this.$=[];else this.$=e[i];break;case 31:r.subgraphDepth=(r.subgraphDepth||1)-1,this.$=r.addSubGraph({text:e[i-2].id},e[i-1],{text:e[i-2].text});break;case 32:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:e[i-1],text:e[i-1]};break;case 33:r.subgraphDepth=(r.subgraphDepth||0)+1,this.$={id:e[i-4],text:e[i-2]};break;case 34:case 59:case 60:case 61:case 62:case 86:this.$=e[i];break;case 35:this.$=e[i-1]+" "+e[i];break;case 36:this.$={stmt:"dir",value:"TB"};break;case 37:this.$={stmt:"dir",value:"BT"};break;case 38:this.$={stmt:"dir",value:"RL"};break;case 39:this.$={stmt:"dir",value:"LR"};break;case 40:this.$=e[i-3],r.addClass(e[i-2],e[i-1]);break;case 41:case 42:case 63:case 72:this.$=[e[i]];break;case 43:case 44:this.$=e[i-2].concat([e[i]]);break;case 45:this.$=e[i-2],r.setClass(e[i-1],e[i]);break;case 46:this.$=e[i-3],r.addCssStyles(e[i-2],e[i-1]);break;case 47:this.$=[e[i]];break;case 48:e[i-2].push(e[i]),this.$=e[i-2];break;case 50:this.$=e[i-1]+e[i];break;case 58:case 84:case 85:this.$=e[i].replace(/"/g,"");break;case 64:e[i].push(e[i-1]),this.$=e[i];break;case 65:this.$={type:e[i-1],name:e[i]};break;case 66:this.$={type:e[i-2],name:e[i-1],keys:e[i]};break;case 67:this.$={type:e[i-2],name:e[i-1],comment:e[i]};break;case 68:this.$={type:e[i-3],name:e[i-2],keys:e[i-1],comment:e[i]};break;case 69:case 71:case 74:this.$=e[i];break;case 70:this.$=e[i-1]+e[i];break;case 73:e[i-2].push(e[i]),this.$=e[i-2];break;case 75:this.$=e[i].replace(/"/g,"");break;case 76:this.$={cardA:e[i],relType:e[i-1],cardB:e[i-2]};break;case 77:this.$=r.Cardinality.ZERO_OR_ONE;break;case 78:this.$=r.Cardinality.ZERO_OR_MORE;break;case 79:this.$=r.Cardinality.ONE_OR_MORE;break;case 80:this.$=r.Cardinality.ONLY_ONE;break;case 81:this.$=r.Cardinality.MD_PARENT;break;case 82:this.$=r.Identification.NON_IDENTIFYING;break;case 83:this.$=r.Identification.IDENTIFYING;break}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},s(c,f,{5:3}),{6:[1,4],7:5,8:6,9:n,10:8,21:u,23:y,25:x,27:_,28:13,29:14,30:15,31:16,32:17,34:I,37:g,38:m,39:B,40:W,41:X,43:v,46:Y,47:te,51:G,53:P,54:z,55:U},s(c,Ke,{1:[2,1]}),s(d,[2,3]),s(d,[2,4]),s(d,[2,5]),s(d,[2,15],{11:31,67:35,14:[1,32],16:[1,33],19:[1,34],69:Re,70:ve,71:De,72:Le,73:we}),{22:[1,41]},{24:[1,42]},{26:[1,43]},s(d,[2,26]),s(d,[2,27]),s(d,[2,28]),s(d,[2,29]),s(d,[2,30]),s(d,f,{5:44}),s(ie,[2,58]),s(ie,[2,59]),s(ie,[2,60]),s(ie,[2,61]),s(ie,[2,62]),s(d,[2,36]),s(d,[2,37]),s(d,[2,38]),s(d,[2,39]),{15:45,43:K,44:Z},{15:48,43:K,44:Z},{15:49,43:K,44:Z},{10:50,43:v,51:G,53:P,54:z,55:U},{10:51,43:v,51:G,53:P,54:z,55:U},{15:52,43:K,44:Z},{17:53,18:[1,54],56:55,57:56,61:re},{10:58,43:v,51:G,53:P,54:z,55:U},{68:59,74:[1,60],75:[1,61]},s(ae,[2,77]),s(ae,[2,78]),s(ae,[2,79]),s(ae,[2,80]),s(ae,[2,81]),s(d,[2,23]),s(d,[2,24]),s(d,[2,25]),{6:[1,63],7:5,8:6,9:n,10:8,21:u,23:y,25:x,27:_,28:13,29:14,30:15,31:16,32:17,33:[1,62],34:I,37:g,38:m,39:B,40:W,41:X,43:v,46:Y,47:te,51:G,53:P,54:z,55:U},{12:ne,42:64,44:oe,45:j,48:66,49:67,51:ce,52:be},s(_e,[2,41]),s(_e,[2,42]),{15:72,43:K,44:Z,45:j},{12:ne,42:73,44:oe,45:j,48:66,49:67,51:ce,52:be},{6:me,9:Ee,19:[1,75],35:74,50:Se},{12:[1,79],14:[1,80]},s(d,[2,16],{67:35,11:81,16:[1,82],45:j,69:Re,70:ve,71:De,72:Le,73:we}),{18:[1,83]},s(d,[2,13]),{17:84,18:[2,63],56:55,57:56,61:re},{58:85,61:[1,86]},{61:[2,69],62:[1,87]},{20:[1,88]},{67:89,69:Re,70:ve,71:De,72:Le,73:we},s(Ze,[2,82]),s(Ze,[2,83]),s(d,[2,31]),s(d,Ke),{6:me,9:Ee,35:90,45:je,50:Se},{43:[1,92],44:[1,93]},s(qe,[2,47],{49:94,12:ne,44:oe,51:ce,52:be}),s(J,[2,49]),s(J,[2,54]),s(J,[2,55]),s(J,[2,56]),s(J,[2,57]),s(d,[2,45],{45:j}),{6:me,9:Ee,35:95,45:je,50:Se},s(d,[2,32]),{10:97,36:96,43:v,51:G,53:P,54:z,55:U},s(d,[2,51]),s(d,[2,52]),s(d,[2,53]),{13:98,43:Te,53:Ce,76:Oe},{15:102,43:K,44:Z},{10:103,43:v,51:G,53:P,54:z,55:U},{17:104,18:[1,105],56:55,57:56,61:re},s(d,[2,11]),{18:[2,64]},s(fe,[2,65],{59:106,60:107,63:108,65:We,66:He}),s([18,61,65,66],[2,71]),{61:[2,70]},s(d,[2,21],{14:[1,112],16:[1,111]}),s([43,51,53,54,55],[2,76]),s(d,[2,40]),{12:ne,44:oe,48:113,49:67,51:ce,52:be},s(_e,[2,43]),s(_e,[2,44]),s(J,[2,50]),s(d,[2,46]),{10:115,20:[1,114],43:v,51:G,53:P,54:z,55:U},s(Qe,[2,34]),s(d,[2,7]),s(d,[2,84]),s(d,[2,85]),s(d,[2,86]),{12:[1,116],45:j},{12:[1,118],14:[1,117]},{18:[1,119]},s(d,[2,14]),s(fe,[2,66],{60:120,64:[1,121],66:He}),s(fe,[2,67]),s(Ve,[2,72]),s(fe,[2,75]),s(Ve,[2,74]),{17:122,18:[1,123],56:55,57:56,61:re},{15:124,43:K,44:Z},s(qe,[2,48],{49:94,12:ne,44:oe,51:ce,52:be}),{6:me,9:Ee,35:125,50:Se},s(Qe,[2,35]),{13:126,43:Te,53:Ce,76:Oe},{15:127,43:K,44:Z},{13:128,43:Te,53:Ce,76:Oe},s(d,[2,12]),s(fe,[2,68]),{63:129,65:We},{18:[1,130]},s(d,[2,19]),s(d,[2,22],{16:[1,131],45:j}),s(d,[2,33]),s(d,[2,10]),{12:[1,132],45:j},s(d,[2,9]),s(Ve,[2,73]),s(d,[2,17]),{17:133,18:[1,134],56:55,57:56,61:re},{13:135,43:Te,53:Ce,76:Oe},{18:[1,136]},s(d,[2,20]),s(d,[2,8]),s(d,[2,18])],defaultActions:{84:[2,64],87:[2,70]},parseError:t(function(o,h){if(h.recoverable)this.trace(o);else{var k=Error(o);throw k.hash=h,k}},"parseError"),parse:t(function(o){var h=this,k=[0],r=[],O=[null],e=[],ke=this.table,i="",xe=0,Xe=0,Je=0,at=2,$e=1,nt=e.slice.call(arguments,1),N=Object.create(this.lexer),H={yy:{}};for(var Be in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,Be))H.yy[Be]=this.yy[Be];if(N.setInput(o,H.yy),H.yy.lexer=N,H.yy.parser=this,typeof N.yylloc>"u")N.yylloc={};var Ge=N.yylloc;e.push(Ge);var ot=N.options&&N.options.ranges;if(typeof H.yy.parseError==="function")this.parseError=H.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function lt(V){k.length=k.length-2*V,O.length=O.length-V,e.length=e.length-V}t(lt,"popStack");function et(){var V=r.pop()||N.lex()||$e;if(typeof V!=="number"){if(V instanceof Array)r=V,V=r.pop();V=h.symbols_[V]||V}return V}t(et,"lex");var D,Fe,Q,w,ft,Ye,ee={},Ae,F,tt,Ie;while(!0){if(Q=k[k.length-1],this.defaultActions[Q])w=this.defaultActions[Q];else{if(D===null||typeof D>"u")D=et();w=ke[Q]&&ke[Q][D]}if(typeof w>"u"||!w.length||!w[0]){var Pe="";Ie=[];for(Ae in ke[Q])if(this.terminals_[Ae]&&Ae>at)Ie.push("'"+this.terminals_[Ae]+"'");if(N.showPosition)Pe="Parse error on line "+(xe+1)+`:
|
|
2
2
|
`+N.showPosition()+`
|
|
3
3
|
Expecting `+Ie.join(", ")+", got '"+(this.terminals_[D]||D)+"'";else Pe="Parse error on line "+(xe+1)+": Unexpected "+(D==$e?"end of input":"'"+(this.terminals_[D]||D)+"'");this.parseError(Pe,{text:N.match,token:this.terminals_[D]||D,line:N.yylineno,loc:Ge,expected:Ie})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+Q+", token: "+D);switch(w[0]){case 1:if(k.push(D),O.push(N.yytext),e.push(N.yylloc),k.push(w[1]),D=null,!Fe){if(Xe=N.yyleng,i=N.yytext,xe=N.yylineno,Ge=N.yylloc,Je>0)Je--}else D=Fe,Fe=null;break;case 2:if(F=this.productions_[w[1]][1],ee.$=O[O.length-F],ee._$={first_line:e[e.length-(F||1)].first_line,last_line:e[e.length-1].last_line,first_column:e[e.length-(F||1)].first_column,last_column:e[e.length-1].last_column},ot)ee._$.range=[e[e.length-(F||1)].range[0],e[e.length-1].range[1]];if(Ye=this.performAction.apply(ee,[i,Xe,xe,H.yy,w[1],O,e].concat(nt)),typeof Ye<"u")return Ye;if(F)k=k.slice(0,-1*F*2),O=O.slice(0,-1*F),e=e.slice(0,-1*F);k.push(this.productions_[w[1]][0]),O.push(ee.$),e.push(ee._$),tt=ke[k[k.length-2]][k[k.length-1]],k.push(tt);break;case 3:return!0}}return!0},"parse")},rt=function(){var q={EOF:1,parseError:t(function(h,k){if(this.yy.parser)this.yy.parser.parseError(h,k);else throw Error(h)},"parseError"),setInput:t(function(o,h){if(this.yy=h||this.yy||{},this._input=o,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:t(function(){var o=this._input[0];this.yytext+=o,this.yyleng++,this.offset++,this.match+=o,this.matched+=o;var h=o.match(/(?:\r\n?|\n).*/g);if(h)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),o},"input"),unput:t(function(o){var h=o.length,k=o.split(/(?:\r\n?|\n)/g);this._input=o+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-h),this.offset-=h;var r=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),k.length-1)this.yylineno-=k.length-1;var O=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:k?(k.length===r.length?this.yylloc.first_column:0)+r[r.length-k.length].length-k[0].length:this.yylloc.first_column-h},this.options.ranges)this.yylloc.range=[O[0],O[0]+this.yyleng-h];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:t(function(o){this.unput(this.match.slice(o))},"less"),pastInput:t(function(){var o=this.matched.substr(0,this.matched.length-this.match.length);return(o.length>20?"...":"")+o.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:t(function(){var o=this.match;if(o.length<20)o+=this._input.substr(0,20-o.length);return(o.substr(0,20)+(o.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:t(function(){var o=this.pastInput(),h=Array(o.length+1).join("-");return o+this.upcomingInput()+`
|
|
5
5
|
`+h+"^"},"showPosition"),test_match:t(function(o,h){var k,r,O;if(this.options.backtrack_lexer){if(O={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges)O.yylloc.range=this.yylloc.range.slice(0)}if(r=o[0].match(/(?:\r\n?|\n).*/g),r)this.yylineno+=r.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:r?r[r.length-1].length-r[r.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+o[0].length},this.yytext+=o[0],this.match+=o[0],this.matches=o,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(o[0].length),this.matched+=o[0],k=this.performAction.call(this,this.yy,this,h,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(k)return k;else if(this._backtrack){for(var e in O)this[e]=O[e];return!1}return!1},"test_match"),next:t(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var o,h,k,r;if(!this._more)this.yytext="",this.match="";var O=this._currentRules();for(var e=0;e<O.length;e++)if(k=this._input.match(this.rules[O[e]]),k&&(!h||k[0].length>h[0].length)){if(h=k,r=e,this.options.backtrack_lexer)if(o=this.test_match(k,O[e]),o!==!1)return o;else if(this._backtrack){h=!1;continue}else return!1;else if(!this.options.flex)break}if(h){if(o=this.test_match(h,O[r]),o!==!1)return o;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:t(function(){var h=this.next();if(h)return h;else return this.lex()},"lex"),begin:t(function(h){this.conditionStack.push(h)},"begin"),popState:t(function(){var h=this.conditionStack.length-1;if(h>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(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:t(function(h){if(h=this.conditionStack.length-1-Math.abs(h||0),h>=0)return this.conditionStack[h];else return"INITIAL"},"topState"),pushState:t(function(h){this.begin(h)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:t(function(h,k,r,O){var e=O;switch(r){case 0:return this.begin("acc_title"),23;break;case 1:return this.popState(),"acc_title_value";break;case 2:return this.begin("acc_descr"),25;break;case 3:return this.popState(),"acc_descr_value";break;case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 37;case 8:return 38;case 9:return 39;case 10:return 40;case 11:break;case 12:return 9;case 13:return 53;case 14:return 76;case 15:return 4;case 16:return this.begin("block"),16;break;case 17:return 52;case 18:return 52;case 19:return 45;case 20:return 14;case 21:return 12;case 22:break;case 23:return 65;case 24:return 61;case 25:return 61;case 26:this.begin("block_bq");break;case 27:return 61;case 28:this.popState();break;case 29:return 66;case 30:break;case 31:return this.popState(),18;break;case 32:return k.yytext[0];case 33:return 19;case 34:return 20;case 35:return this.begin("style"),47;break;case 36:return this.popState(),9;break;case 37:break;case 38:return 12;case 39:return 45;case 40:return 52;case 41:return this.begin("style"),41;break;case 42:return 46;case 43:return 34;case 44:return 33;case 45:return 69;case 46:return 71;case 47:return 71;case 48:return 71;case 49:return 69;case 50:return 69;case 51:return 70;case 52:return 70;case 53:return 70;case 54:return 70;case 55:return 70;case 56:return 71;case 57:return 70;case 58:return 71;case 59:return 72;case 60:return 72;case 61:return 54;case 62:return 72;case 63:return 72;case 64:return 72;case 65:return 55;case 66:return 51;case 67:return 72;case 68:return 69;case 69:return 70;case 70:return 71;case 71:return 73;case 72:return 74;case 73:return 75;case 74:return 75;case 75:return 74;case 76:return 74;case 77:return 74;case 78:return 44;case 79:return 50;case 80:return 43;case 81:return k.yytext[0];case 82:return 6}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[ \t\r]+)/i,/^(?:[\n]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:subgraph\b)/i,/^(?:end\b\s*)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[36,37,38,39,40,78,79],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[27,28],inclusive:!1},block:{rules:[22,23,24,25,26,29,30,31,32],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,33,34,35,41,42,43,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,75,76,77,80,81,82],inclusive:!0}}};return q}();Me.lexer=rt;function Ne(){this.yy={}}return t(Ne,"Parser"),Ne.prototype=Me,Me.Parser=Ne,new Ne}();Ue.parser=Ue;var ct=Ue,ht=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.subgraphDepth=0,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=S,this.getAccTitle=E,this.setAccDescription=T,this.getAccDescription=A,this.setDiagramTitle=L,this.getDiagramTitle=R,this.getConfig=t(()=>l().er,"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this),this.addSubGraph=this.addSubGraph.bind(this)}static{t(this,"ErDB")}addEntity(s,c=""){if(!this.entities.has(s))this.entities.set(s,{id:`entity-${s}-${this.entities.size}`,label:s,attributes:[],alias:c,shape:"erBox",look:l().look??"default",cssClasses:"default",cssStyles:[],labelType:"markdown"}),a.info("Added new entity :",s);else if(!this.entities.get(s)?.alias&&c)this.entities.get(s).alias=c,a.info(`Add alias '${c}' to entity '${s}'`);return this.entities.get(s)}getEntity(s){return this.entities.get(s)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(s,c){let f=this.addEntity(s),n;for(n=c.length-1;n>=0;n--){if(!c[n].keys)c[n].keys=[];if(!c[n].comment)c[n].comment="";f.attributes.push(c[n]),a.debug("Added attribute ",c[n].name)}}addRelationship(s,c,f,n){let u;if(this.subGraphLookup.has(s))u=s;else{let _=this.addEntity(s);if(!_)return;u=_.id}let y;if(this.subGraphLookup.has(f))y=f;else{let _=this.addEntity(f);if(!_)return;y=_.id}let x={entityA:u,roleA:c,entityB:y,relSpec:n};this.relationships.push(x),a.debug("Added new relationship :",x)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(s){this.direction=s}getCompiledStyles(s){let c=[];for(let f of s){let n=this.classes.get(f);if(n?.styles)c=[...c,...n.styles??[]].map((u)=>u.trim());if(n?.textStyles)c=[...c,...n.textStyles??[]].map((u)=>u.trim())}return c}addCssStyles(s,c){for(let f of s){let n=this.entities.get(f),u=this.subGraphLookup.get(f);if(!c)continue;if(n)for(let y of c)n.cssStyles.push(y);if(u){if(!u.cssStyles)u.cssStyles=[];for(let y of c)u.cssStyles.push(y)}}}addClass(s,c){s.forEach((f)=>{let n=this.classes.get(f);if(n===void 0)n={id:f,styles:[],textStyles:[]},this.classes.set(f,n);if(c)c.forEach(function(u){if(/color/.exec(u)){let y=u.replace("fill","bgFill");n.textStyles.push(y)}n.styles.push(u)})})}addSubGraph(s,c,f){let n=s.text.trim(),u=f.text,x=t((m)=>{let B=new Set,W;return{nodeList:m.filter((v)=>{if(v?.stmt){if(v.stmt==="dir")W=v.value;return!1}if(typeof v!=="string")return!1;let Y=v.trim();if(!Y)return!1;if(B.has(Y))return!1;return B.add(Y),!0}),dir:W}},"uniq")(c.flat()),{nodeList:_,dir:I}=x;n=n??"subGraph"+this.subCount,u=u||"",u=this.sanitizeText(u),this.subCount=this.subCount+1;let g={id:n,nodes:_,title:u.trim(),classes:[],cssStyles:[],dir:I,labelType:this.sanitizeNodeLabelType(f?.type)};return a.info("Adding",g.id,g.nodes,g.dir),g.nodes=this.makeUniq(g,this.subGraphs).nodes,this.subGraphs.push(g),this.subGraphLookup.set(n,g),n}getSubGraphs(){return this.subGraphs}setClass(s,c){for(let f of s){let n=this.entities.get(f);if(n)for(let y of c)n.cssClasses+=" "+y;let u=this.subGraphLookup.get(f);if(u)for(let y of c)u.classes.push(y)}}subgraphNodeCache(s){let c=new Set;for(let f of s)for(let n of f.nodes)c.add(n);return c}makeUniq(s,c){let f=this.subgraphNodeCache(c),n=[];return s.nodes.forEach((u,y)=>{if(f.has(u))a.warn(`Entity '${u}' already belongs to another subgraph and will be ignored`);else n.push(s.nodes[y])}),{nodes:n}}sanitizeText(s){return b.sanitizeText(s,l())}sanitizeNodeLabelType(s){switch(s){case"markdown":case"string":case"text":return s;default:return"markdown"}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.subgraphDepth=0,C()}getData(){let s=[],c=[],f=l(),n=this.getSubGraphs(),u=new Map,y=new Map;for(let g=n.length-1;g>=0;g--){let m=n[g];if(m.nodes.length>0)y.set(m.id,!0);for(let B of m.nodes)u.set(B,m.id)}for(let g=n.length-1;g>=0;g--){let m=n[g];s.push({id:m.id,label:m.title,labelStyle:"",labelType:m.labelType,parentId:u.get(m.id),padding:8,cssCompiledStyles:this.getCompiledStyles(m.classes),cssStyles:m.cssStyles,cssClasses:m.classes.join(" "),shape:"rect",dir:m.dir,isGroup:!0,look:f.look})}let x=new Set(n.map((g)=>g.id)),_=0;for(let g of this.entities.keys()){if(x.has(g))continue;let m=this.entities.get(g);if(m)m.cssCompiledStyles=this.getCompiledStyles(m.cssClasses.split(" ")),m.colorIndex=_++,s.push({...m,parentId:u.get(g),isGroup:!1})}let I=0;for(let g of this.relationships){let m={id:ze(g.entityA,g.entityB,{prefix:"id",counter:I++}),type:"normal",curve:"basis",start:g.entityA,end:g.entityB,label:g.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:g.relSpec.cardB.toLowerCase(),arrowTypeEnd:g.relSpec.cardA.toLowerCase(),pattern:g.relSpec.relType=="IDENTIFYING"?"solid":"dashed",look:f.look,labelType:"markdown"};c.push(m)}return{nodes:s,edges:c,other:{},config:f,direction:this.direction}}},it={};Kt(it,{draw:()=>ut});var ut=t(async function(s,c,f,n){a.info("REF0:"),a.info("Drawing er diagram (unified)",c);let{securityLevel:u,er:y,layout:x}=l(),_=n.db.getData(),I=he(c,u);_.type=n.type,_.layoutAlgorithm=ye(x),_.config.flowchart.nodeSpacing=y?.nodeSpacing||140,_.config.flowchart.rankSpacing=y?.rankSpacing||80,_.direction=n.db.getDirection();let{config:g}=_,{look:m}=g;if(m==="neo")_.markers=["only_one_neo","zero_or_one_neo","one_or_more_neo","zero_or_more_neo"];else _.markers=["only_one","zero_or_one","one_or_more","zero_or_more"];_.diagramId=c,await ge(_,I);let B=I.selectAll('[id*="-background"]');if(Array.from(B).length>0)B.each(function(){let X=p(this),Y=X.attr("id").replace("-background",""),te=I.select(`#${CSS.escape(Y)}`);if(!te.empty()){let G=te.attr("transform");X.attr("transform",G)}});let W=8;M.insertTitle(I,"erDiagramTitleText",y?.titleTopMargin??25,n.db.getDiagramTitle()),ue(I,W,"erDiagram",y?.useMaxWidth??!0)},"draw"),st=t((s,c)=>{let f=Bt,n=f(s,"r"),u=f(s,"g"),y=f(s,"b");return de(n,u,y,c)},"fade"),dt=t((s)=>{let{theme:c,bkgColorArray:f,borderColorArray:n}=s;if(!se(c,n))return"";let u=le(s.look),y=pe(f),x="";for(let _=0;_<gt(n);_++){let I=n[_],g=y?`fill: ${f[_%f.length]};`:"";x+=`
|
|
6
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:t(function(){var h=this.next();if(h)return h;else return this.lex()},"lex"),begin:t(function(h){this.conditionStack.push(h)},"begin"),popState:t(function(){var h=this.conditionStack.length-1;if(h>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(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:t(function(h){if(h=this.conditionStack.length-1-Math.abs(h||0),h>=0)return this.conditionStack[h];else return"INITIAL"},"topState"),pushState:t(function(h){this.begin(h)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:t(function(h,k,r,O){var e=O;switch(r){case 0:return this.begin("acc_title"),23;break;case 1:return this.popState(),"acc_title_value";break;case 2:return this.begin("acc_descr"),25;break;case 3:return this.popState(),"acc_descr_value";break;case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 37;case 8:return 38;case 9:return 39;case 10:return 40;case 11:break;case 12:return 9;case 13:return 53;case 14:return 76;case 15:return 4;case 16:return this.begin("block"),16;break;case 17:return 52;case 18:return 52;case 19:return 45;case 20:return 14;case 21:return 12;case 22:break;case 23:return 65;case 24:return 61;case 25:return 61;case 26:this.begin("block_bq");break;case 27:return 61;case 28:this.popState();break;case 29:return 66;case 30:break;case 31:return this.popState(),18;break;case 32:return k.yytext[0];case 33:return 19;case 34:return 20;case 35:return this.begin("style"),47;break;case 36:return this.popState(),9;break;case 37:break;case 38:return 12;case 39:return 45;case 40:return 52;case 41:return this.begin("style"),41;break;case 42:return 46;case 43:return 34;case 44:return 33;case 45:return 69;case 46:return 71;case 47:return 71;case 48:return 71;case 49:return 69;case 50:return 69;case 51:return 70;case 52:return 70;case 53:return 70;case 54:return 70;case 55:return 70;case 56:return 71;case 57:return 70;case 58:return 71;case 59:return 72;case 60:return 72;case 61:return 54;case 62:return 72;case 63:return 72;case 64:return 72;case 65:return 55;case 66:return 51;case 67:return 72;case 68:return 69;case 69:return 70;case 70:return 71;case 71:return 73;case 72:return 74;case 73:return 75;case 74:return 75;case 75:return 74;case 76:return 74;case 77:return 74;case 78:return 44;case 79:return 50;case 80:return 43;case 81:return k.yytext[0];case 82:return 6}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[ \t\r]+)/i,/^(?:[\n]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\.,\u00C0-\uFFFF\*]*))/i,/^(?:[`])/i,/^(?:[^`]+)/i,/^(?:[`])/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:subgraph\b)/i,/^(?:end\b\s*)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[36,37,38,39,40,78,79],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block_bq:{rules:[27,28],inclusive:!1},block:{rules:[22,23,24,25,26,29,30,31,32],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,33,34,35,41,42,43,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,75,76,77,80,81,82],inclusive:!0}}};return q}();Me.lexer=rt;function Ne(){this.yy={}}return t(Ne,"Parser"),Ne.prototype=Me,Me.Parser=Ne,new Ne}();Ue.parser=Ue;var ct=Ue,ht=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.subgraphDepth=0,this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=S,this.getAccTitle=E,this.setAccDescription=T,this.getAccDescription=A,this.setDiagramTitle=L,this.getDiagramTitle=R,this.getConfig=t(()=>l().er,"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this),this.addSubGraph=this.addSubGraph.bind(this)}static{t(this,"ErDB")}addEntity(s,c=""){if(!this.entities.has(s))this.entities.set(s,{id:`entity-${s}-${this.entities.size}`,label:s,attributes:[],alias:c,shape:"erBox",look:l().look??"default",cssClasses:"default",cssStyles:[],labelType:"markdown"}),a.info("Added new entity :",s);else if(!this.entities.get(s)?.alias&&c)this.entities.get(s).alias=c,a.info(`Add alias '${c}' to entity '${s}'`);return this.entities.get(s)}getEntity(s){return this.entities.get(s)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(s,c){let f=this.addEntity(s),n;for(n=c.length-1;n>=0;n--){if(!c[n].keys)c[n].keys=[];if(!c[n].comment)c[n].comment="";f.attributes.push(c[n]),a.debug("Added attribute ",c[n].name)}}addRelationship(s,c,f,n){let u;if(this.subGraphLookup.has(s))u=s;else{let _=this.addEntity(s);if(!_)return;u=_.id}let y;if(this.subGraphLookup.has(f))y=f;else{let _=this.addEntity(f);if(!_)return;y=_.id}let x={entityA:u,roleA:c,entityB:y,relSpec:n};this.relationships.push(x),a.debug("Added new relationship :",x)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(s){this.direction=s}getCompiledStyles(s){let c=[];for(let f of s){let n=this.classes.get(f);if(n?.styles)c=[...c,...n.styles??[]].map((u)=>u.trim());if(n?.textStyles)c=[...c,...n.textStyles??[]].map((u)=>u.trim())}return c}addCssStyles(s,c){for(let f of s){let n=this.entities.get(f),u=this.subGraphLookup.get(f);if(!c)continue;if(n)for(let y of c)n.cssStyles.push(y);if(u){if(!u.cssStyles)u.cssStyles=[];for(let y of c)u.cssStyles.push(y)}}}addClass(s,c){s.forEach((f)=>{let n=this.classes.get(f);if(n===void 0)n={id:f,styles:[],textStyles:[]},this.classes.set(f,n);if(c)c.forEach(function(u){if(/color/.exec(u)){let y=u.replace("fill","bgFill");n.textStyles.push(y)}n.styles.push(u)})})}addSubGraph(s,c,f){let n=s.text.trim(),u=f.text,x=t((m)=>{let B=new Set,W;return{nodeList:m.filter((v)=>{if(v?.stmt){if(v.stmt==="dir")W=v.value;return!1}if(typeof v!=="string")return!1;let Y=v.trim();if(!Y)return!1;if(B.has(Y))return!1;return B.add(Y),!0}),dir:W}},"uniq")(c.flat()),{nodeList:_,dir:I}=x;n=n??"subGraph"+this.subCount,u=u||"",u=this.sanitizeText(u),this.subCount=this.subCount+1;let g={id:n,nodes:_,title:u.trim(),classes:[],cssStyles:[],dir:I,labelType:this.sanitizeNodeLabelType(f?.type)};return a.info("Adding",g.id,g.nodes,g.dir),g.nodes=this.makeUniq(g,this.subGraphs).nodes,this.subGraphs.push(g),this.subGraphLookup.set(n,g),n}getSubGraphs(){return this.subGraphs}setClass(s,c){for(let f of s){let n=this.entities.get(f);if(n)for(let y of c)n.cssClasses+=" "+y;let u=this.subGraphLookup.get(f);if(u)for(let y of c)u.classes.push(y)}}subgraphNodeCache(s){let c=new Set;for(let f of s)for(let n of f.nodes)c.add(n);return c}makeUniq(s,c){let f=this.subgraphNodeCache(c),n=[];return s.nodes.forEach((u,y)=>{if(f.has(u))a.warn(`Entity '${u}' already belongs to another subgraph and will be ignored`);else n.push(s.nodes[y])}),{nodes:n}}sanitizeText(s){return b.sanitizeText(s,l())}sanitizeNodeLabelType(s){switch(s){case"markdown":case"string":case"text":return s;default:return"markdown"}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.subgraphDepth=0,C()}getData(){let s=[],c=[],f=l(),n=this.getSubGraphs(),u=new Map,y=new Map;for(let g=n.length-1;g>=0;g--){let m=n[g];if(m.nodes.length>0)y.set(m.id,!0);for(let B of m.nodes)u.set(B,m.id)}for(let g=n.length-1;g>=0;g--){let m=n[g];s.push({id:m.id,label:m.title,labelStyle:"",labelType:m.labelType,parentId:u.get(m.id),padding:8,cssCompiledStyles:this.getCompiledStyles(m.classes),cssStyles:m.cssStyles,cssClasses:m.classes.join(" "),shape:"rect",dir:m.dir,isGroup:!0,look:f.look})}let x=new Set(n.map((g)=>g.id)),_=0;for(let g of this.entities.keys()){if(x.has(g))continue;let m=this.entities.get(g);if(m)m.cssCompiledStyles=this.getCompiledStyles(m.cssClasses.split(" ")),m.colorIndex=_++,s.push({...m,parentId:u.get(g),isGroup:!1})}let I=0;for(let g of this.relationships){let m={id:ze(g.entityA,g.entityB,{prefix:"id",counter:I++}),type:"normal",curve:"basis",start:g.entityA,end:g.entityB,label:g.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:g.relSpec.cardB.toLowerCase(),arrowTypeEnd:g.relSpec.cardA.toLowerCase(),pattern:g.relSpec.relType=="IDENTIFYING"?"solid":"dashed",look:f.look,labelType:"markdown"};c.push(m)}return{nodes:s,edges:c,other:{},config:f,direction:this.direction}}},it={};Kt(it,{draw:()=>ut});var ut=t(async function(s,c,f,n){a.info("REF0:"),a.info("Drawing er diagram (unified)",c);let{securityLevel:u,er:y,layout:x}=l(),_=n.db.getData(),I=he(c,u);_.type=n.type,_.layoutAlgorithm=ye(x),_.config.flowchart.nodeSpacing=y?.nodeSpacing||140,_.config.flowchart.rankSpacing=y?.rankSpacing||80,_.direction=n.db.getDirection();let{config:g}=_,{look:m}=g;if(m==="neo")_.markers=["only_one_neo","zero_or_one_neo","one_or_more_neo","zero_or_more_neo"];else _.markers=["only_one","zero_or_one","one_or_more","zero_or_more"];_.diagramId=c,await ge(_,I);let B=I.selectAll('[id*="-background"]');if(Array.from(B).length>0)B.each(function(){let X=p(this),Y=X.attr("id").replace("-background",""),te=I.select(`#${CSS.escape(Y)}`);if(!te.empty()){let G=te.attr("transform");X.attr("transform",G)}});let W=8;M.insertTitle(I,"erDiagramTitleText",y?.titleTopMargin??25,n.db.getDiagramTitle()),ue(I,W,"erDiagram",y?.useMaxWidth??!0)},"draw"),st=t((s,c)=>{let f=Bt,n=f(s,"r"),u=f(s,"g"),y=f(s,"b");return de(n,u,y,c)},"fade"),dt=t((s)=>{let{theme:c,bkgColorArray:f,borderColorArray:n}=s;if(!se(c,n))return"";let u=le(s.look),y=pe(f),x="";for(let _=0;_<yt(n);_++){let I=n[_],g=y?`fill: ${f[_%f.length]};`:"";x+=`
|
|
7
7
|
|
|
8
8
|
[data-look="${u}"][data-color-id="color-${_}"].node path {
|
|
9
9
|
stroke: ${I};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{G}from"./chunk-
|
|
1
|
+
import{G}from"./chunk-eh7wp62z.js";import{t,a,ke,N,x,F,C,S,E,T,A,L,R,V,U}from"./chunk-tfqarvdx.js";import{J}from"./chunk-qy1zx2yw.js";var ht=t(()=>({domains:new Map,transitions:[]}),"createDefaultData"),ot=ht(),St=t(()=>ot.domains,"getDomains"),Mt=t(()=>ot.transitions,"getTransitions"),zt=t((e)=>{if(!e)return;for(let n of e){let o=n.domain,r=(n.items??[]).map((l)=>({label:l.label}));ot.domains.set(o,{name:o,items:r})}},"setDomains"),Lt=t((e)=>{if(!e)return;ot.transitions=e.filter((n)=>{if(n.from===n.to)return a.warn(`Cynefin: self-loop transition on domain "${n.from}" is not meaningful and will be skipped.`),!1;return!0}).map((n)=>({from:n.from,to:n.to,label:n.label||void 0}))},"setTransitions"),Nt=t(()=>U({...N.cynefin,...x().cynefin}),"getConfig"),Pt=t(()=>{C(),ot=ht()},"clear"),it={getDomains:St,getTransitions:Mt,setDomains:zt,setTransitions:Lt,getConfig:Nt,clear:Pt,setAccTitle:S,getAccTitle:E,setDiagramTitle:L,getDiagramTitle:R,getAccDescription:A,setAccDescription:T},It=t((e)=>{G(e,it),it.setDomains(e.domains),it.setTransitions(e.transitions)},"populate"),Wt={parse:t(async(e)=>{let n=await J("cynefin",e);a.debug(n),It(n)},"parse")};function nt(e){let n=e+1831565813|0;return n=Math.imul(n^n>>>15,n|1),n^=n+Math.imul(n^n>>>7,n|61),((n^n>>>14)>>>0)/4294967296}t(nt,"seededRandom");function xt(e){let n=0;for(let o=0;o<e.length;o++){let r=e.charCodeAt(o);n=(n<<5)-n+r,n|=0}return n}t(xt,"hashString");function $t(e,n){if(typeof e==="number"&&Number.isFinite(e)&&e!==0)return e;return xt(n)}t($t,"resolveSeed");function bt(e,n,o,r){let l=e/2,p=r??e*0.015,at=7,Q=n/7,f=[];for(let i=0;i<=7;i++){let y=nt(o+i*17)*p*2-p;f.push({x:l+y,y:i*Q})}let M=`M${f[0].x},${f[0].y}`;for(let i=0;i<f.length-1;i++){let y=f[i],c=f[i+1],m=(y.y+c.y)/2,D=i%2===0?1:-1,h=p*1.5*D*nt(o+i*31+7),Z=y.x+h,K=m,tt=c.x-h;M+=` C${Z},${K} ${tt},${m} ${c.x},${c.y}`}return M}t(bt,"generateFoldPath");function wt(e,n,o,r){let l=n/2,p=r??n*0.015,at=7,Q=e/7,f=[];for(let i=0;i<=7;i++){let y=nt(o+i*23)*p*2-p;f.push({x:i*Q,y:l+y})}let M=`M${f[0].x},${f[0].y}`;for(let i=0;i<f.length-1;i++){let y=f[i],c=f[i+1],m=(y.x+c.x)/2,D=i%2===0?1:-1,h=p*1.5*D*nt(o+i*37+11),Z=m,K=y.y+h,tt=m,Y=c.y-h;M+=` C${Z},${K} ${tt},${Y} ${c.x},${c.y}`}return M}t(wt,"generateHorizontalBoundary");function Ct(e,n){let o=e/2,r=n*0.5,l=n,p=e*0.03;return[`M${o},${r}`,`C${o+p},${r+(l-r)*0.2}`,`${o-p*1.5},${r+(l-r)*0.55}`,`${o+p*0.5},${r+(l-r)*0.75}`,`C${o-p},${r+(l-r)*0.85}`,`${o+p*0.3},${r+(l-r)*0.95}`,`${o},${l}`].join(" ")}t(Ct,"generateCliffPath");function vt(e,n,o,r){return[`M${e-o},${n}`,`A${o},${r} 0 1,1 ${e+o},${n}`,`A${o},${r} 0 1,1 ${e-o},${n}`,"Z"].join(" ")}t(vt,"generateConfusionPath");var gt={complex:{model:"Probe → Sense → Respond",practice:"Emergent Practices"},complicated:{model:"Sense → Analyse → Respond",practice:"Good Practices"},clear:{model:"Sense → Categorise → Respond",practice:"Best Practices"},chaotic:{model:"Act → Sense → Respond",practice:"Novel Practices"},confusion:{model:"",practice:"Disorder"}},Rt=t((e,n)=>{let o=e/2,r=n/2;return{complex:{cx:o/2,cy:r/2,x:0,y:0,w:o,h:r},complicated:{cx:o+o/2,cy:r/2,x:o,y:0,w:o,h:r},chaotic:{cx:o/2,cy:r+r/2,x:0,y:r,w:o,h:r},clear:{cx:o+o/2,cy:r+r/2,x:o,y:r,w:o,h:r},confusion:{cx:o,cy:r,x:o*0.7,y:r*0.7,w:o*0.6,h:r*0.6}}},"getDomainLayouts"),Ft=t(()=>{let e=ke(),n=x();return U(e,n.themeVariables).cynefin},"getCynefinDomainColors"),lt=3,Vt=t((e,n,o,r)=>{let l=r.db,p=l.getDomains(),at=l.getTransitions(),Q=l.getDiagramTitle(),f=l.getAccTitle(),M=l.getAccDescription(),i=l.getConfig(),y=Ft();a.debug("Rendering Cynefin diagram");let{width:c,height:m,padding:D,showDomainDescriptions:h,boundaryAmplitude:Z}=i,K=c+D*2,tt=m+D*2,Y={complex:y.complexBg,complicated:y.complicatedBg,clear:y.clearBg,chaotic:y.chaoticBg,confusion:y.confusionBg},z=V(n);if(F(z,tt,K,i.useMaxWidth??!0),z.attr("viewBox",`0 0 ${K} ${tt}`),f)z.append("title").text(f);if(M)z.append("desc").text(M);let P=z.append("g").attr("transform",`translate(${D}, ${D})`),et=Rt(c,m),dt=$t(i.seed,n),Dt=P.append("g").attr("class","cynefin-backgrounds"),st=["complex","complicated","chaotic","clear"];for(let d of st){let s=et[d];Dt.append("rect").attr("class","cynefinDomain").attr("x",s.x).attr("y",s.y).attr("width",s.w).attr("height",s.h).attr("fill",Y[d]).attr("fill-opacity",0.4).attr("stroke","none")}let ct=P.append("g").attr("class","cynefin-boundaries");ct.append("path").attr("class","cynefinBoundary").attr("d",bt(c,m,dt,Z)).attr("fill","none"),ct.append("path").attr("class","cynefinBoundary").attr("d",wt(c,m,dt+100,Z)).attr("fill","none"),ct.append("path").attr("class","cynefinCliff").attr("d",Ct(c,m)).attr("fill","none");let kt=c*0.15,Tt=m*0.15;P.append("path").attr("class","cynefinConfusion").attr("d",vt(c/2,m/2,kt,Tt)).attr("fill",Y.confusion).attr("fill-opacity",0.5);let ft=P.append("g").attr("class","cynefin-labels");for(let d of st){let s=et[d];ft.append("text").attr("class","cynefinDomainLabel").attr("x",s.cx).attr("y",h?s.cy-30:s.cy).attr("text-anchor","middle").attr("dominant-baseline","middle").text(d.charAt(0).toUpperCase()+d.slice(1))}if(ft.append("text").attr("class","cynefinDomainLabel").attr("x",c/2).attr("y",h?m/2-10:m/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text("Confusion"),h){let d=P.append("g").attr("class","cynefin-subtitles");for(let s of st){let g=et[s],u=gt[s];d.append("text").attr("class","cynefinSubtitle").attr("x",g.cx).attr("y",g.cy-10).attr("text-anchor","middle").attr("dominant-baseline","middle").text(u.model),d.append("text").attr("class","cynefinSubtitle").attr("x",g.cx).attr("y",g.cy+5).attr("text-anchor","middle").attr("dominant-baseline","middle").text(u.practice)}d.append("text").attr("class","cynefinSubtitle").attr("x",c/2).attr("y",m/2+8).attr("text-anchor","middle").attr("dominant-baseline","middle").text(gt.confusion.practice)}let mt=P.append("g").attr("class","cynefin-items"),I=26,pt=10,At=["complex","complicated","chaotic","clear","confusion"];for(let d of At){let s=p.get(d);if(!s||s.items.length===0)continue;let g=et[d],u=d==="confusion",O=s.items,X=0;if(u&&s.items.length>lt)X=s.items.length-lt,O=s.items.slice(0,lt);let W;if(u){let w=h?22:14;W=g.cy+w}else W=g.cy+(h?25:15);if([...O].forEach((w,_)=>{let k=W+_*(I+4),H=mt.append("g"),j=H.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",I/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(w.label),v=w.label.length*7,b=j.node();if(b&&typeof b.getBBox==="function"){let rt=b.getBBox();if(rt.width>0)v=rt.width}let B=v+pt*2,q=g.cx-B/2;H.attr("transform",`translate(${q}, ${k})`),H.insert("rect","text").attr("class","cynefinItem").attr("x",0).attr("y",0).attr("width",B).attr("height",I).attr("rx",4).attr("ry",4).attr("fill",Y[d]).attr("fill-opacity",0.95),j.attr("x",B/2).attr("y",I/2)}),X>0){let w=W+O.length*(I+4),_=`+${X} more`,k=mt.append("g"),H=k.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",I/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(_),j=_.length*7,v=H.node();if(v&&typeof v.getBBox==="function"){let q=v.getBBox();if(q.width>0)j=q.width}let b=j+pt*2,B=g.cx-b/2;k.attr("transform",`translate(${B}, ${w})`),k.insert("rect","text").attr("class","cynefinItemOverflow").attr("x",0).attr("y",0).attr("width",b).attr("height",I).attr("rx",4).attr("ry",4).attr("fill",Y[d]).attr("fill-opacity",0.6),H.attr("x",b/2).attr("y",I/2)}}if(at.length>0){let d=z.select("defs").empty()?z.append("defs"):z.select("defs"),s=`cynefin-arrow-${n}`;d.append("marker").attr("id",s).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",6).attr("markerHeight",6).attr("orient","auto-start-reverse").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","cynefinArrowHead");let g=P.append("g").attr("class","cynefin-arrows");at.forEach((u)=>{let O=et[u.from],X=et[u.to];if(!O||!X)return;if(u.from===u.to){a.warn(`Cynefin renderer: skipping self-loop on domain "${u.from}"`);return}let{cx:W,cy:w}=O,{cx:_,cy:k}=X,H=(W+_)/2,j=(w+k)/2,v=_-W,b=k-w,B=Math.sqrt(v*v+b*b),q=B*0.15,rt=-b/B,Bt=v/B,yt=H+rt*q,ut=j+Bt*q;if(g.append("path").attr("class","cynefinArrowLine").attr("d",`M${W},${w} Q${yt},${ut} ${_},${k}`).attr("fill","none").attr("marker-end",`url(#${s})`),u.label)g.append("text").attr("class","cynefinArrowLabel").attr("x",yt).attr("y",ut-6).attr("text-anchor","middle").attr("dominant-baseline","auto").text(u.label)})}if(Q)P.append("text").attr("class","cynefinTitle").attr("x",c/2).attr("y",-D/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text(Q)},"draw"),_t={draw:Vt},Et=t(()=>{let e=ke(),n=x();return U(e,n.themeVariables).cynefin},"getCynefinTheme"),Ht=t(()=>{let e=Et();return`
|
|
2
2
|
.cynefinDomain {
|
|
3
3
|
stroke: none;
|
|
4
4
|
}
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import{t,a,de,x,b,F,C,l,p,za,In,cn,Ua,Ar,Rr,Lr,Ir,ja,qa,Va,Wa,Ga,Ha,Ya,Za,Xa,Ka,Qa,Ja,ei,ti,ni,ri,ai,un,oi,pe,se,le,Ye,Ze,Et,
|
|
1
|
+
import{t,a,de,x,b,F,C,l,p,za,In,cn,Ua,Ar,Rr,Lr,Ir,ja,qa,Va,Wa,Ga,Ha,Ya,Za,Xa,Ka,Qa,Ja,ei,ti,ni,ri,ai,un,oi,pe,se,le,Ye,Ze,Et,vt,At,Yn,tn,Zn}from"./chunk-tfqarvdx.js";import{re}from"./chunk-88wd49xe.js";import{je}from"./chunk-z5qn0xev.js";import{Bt}from"./chunk-1ex3wgms.js";function Te(e){return Array.isArray(e)}function Ne(e){if(In(e))return e;let o=cn(e);if(!Qe(e))return{};if(Te(e)){let i=Array.from(e);if(e.length>0&&typeof e[0]==="string"&&Object.hasOwn(e,"index"))i.index=e.index,i.input=e.input;return i}if(un(e)){let i=e;return new i.constructor(i.buffer,i.byteOffset,i.length)}if(o==="[object ArrayBuffer]")return new ArrayBuffer(e.byteLength);if(o==="[object DataView]"){let i=e,{buffer:g,byteOffset:f,byteLength:r}=i,d=new ArrayBuffer(r),w=new Uint8Array(g,f,r);return new Uint8Array(d).set(w),new DataView(d)}if(o==="[object Boolean]"||o==="[object Number]"||o==="[object String]"){let g=new e.constructor(e.valueOf());if(o==="[object String]")et(g,e);else ge(g,e);return g}if(o==="[object Date]")return new Date(Number(e));if(o==="[object RegExp]"){let i=e,g=new RegExp(i.source,i.flags);return g.lastIndex=i.lastIndex,g}if(o==="[object Symbol]")return Object(Symbol.prototype.valueOf.call(e));if(o==="[object Map]"){let i=e,g=new Map;return i.forEach((f,r)=>{g.set(r,f)}),g}if(o==="[object Set]"){let i=e,g=new Set;return i.forEach((f)=>{g.add(f)}),g}if(o==="[object Arguments]"){let i=e,g={};return ge(g,i),g.length=i.length,g[Symbol.iterator]=i[Symbol.iterator],g}let u={};return tt(u,e),ge(u,e),$e(u,e),u}function Qe(e){switch(cn(e)){case Ir:case Ga:case Ha:case Za:case Lr:case qa:case ri:case ai:case ei:case ti:case ni:case Va:case Rr:case Ya:case Ua:case Wa:case Ar:case ja:case Xa:case Ka:case Qa:case Ja:return!0;default:return!1}}function ge(e,o){for(let u in o)if(Object.hasOwn(o,u))e[u]=o[u]}function $e(e,o){let u=Object.getOwnPropertySymbols(o);for(let i=0;i<u.length;i++){let g=u[i];if(Object.prototype.propertyIsEnumerable.call(o,g))e[g]=o[g]}}function et(e,o){let u=o.valueOf().length;for(let i in o)if(Object.hasOwn(o,i)&&(Number.isNaN(Number(i))||Number(i)>=u))e[i]=o[i]}function tt(e,o){let u=Object.getPrototypeOf(o);if(u!==null){if(typeof o.constructor==="function")Object.setPrototypeOf(e,u)}}var be=function(){var e=t(function(B,S,n,h){for(n=n||{},h=B.length;h--;n[B[h]]=S);return n},"o"),o=[1,15],u=[1,7],i=[1,13],g=[1,14],f=[1,19],r=[1,16],d=[1,17],w=[1,18],E=[8,30],k=[8,10,21,28,29,30,31,39,43,46],L=[1,23],_=[1,24],T=[8,10,15,16,21,28,29,30,31,39,43,46],y=[8,10,15,16,21,27,28,29,30,31,39,43,46],I=[1,49],N={trace:t(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:t(function(S,n,h,m,D,s,H){var c=s.length-1;switch(D){case 4:m.getLogger().debug("Rule: separator (NL) ");break;case 5:m.getLogger().debug("Rule: separator (Space) ");break;case 6:m.getLogger().debug("Rule: separator (EOF) ");break;case 7:m.getLogger().debug("Rule: hierarchy: ",s[c-1]),m.setHierarchy(s[c-1]);break;case 8:m.getLogger().debug("Stop NL ");break;case 9:m.getLogger().debug("Stop EOF ");break;case 10:m.getLogger().debug("Stop NL2 ");break;case 11:m.getLogger().debug("Stop EOF2 ");break;case 12:m.getLogger().debug("Rule: statement: ",s[c]),typeof s[c].length==="number"?this.$=s[c]:this.$=[s[c]];break;case 13:m.getLogger().debug("Rule: statement #2: ",s[c-1]),this.$=[s[c-1]].concat(s[c]);break;case 14:m.getLogger().debug("Rule: link: ",s[c],S),this.$={edgeTypeStr:s[c],label:""};break;case 15:m.getLogger().debug("Rule: LABEL link: ",s[c-3],s[c-1],s[c]),this.$={edgeTypeStr:s[c],label:s[c-1]};break;case 18:let V=parseInt(s[c]),j=m.generateId();this.$={id:j,type:"space",label:"",width:V,children:[]};break;case 23:m.getLogger().debug("Rule: (nodeStatement link node) ",s[c-2],s[c-1],s[c]," typestr: ",s[c-1].edgeTypeStr);let G=m.edgeStrToEdgeData(s[c-1].edgeTypeStr),ie=m.edgeStrToEdgeStartData(s[c-1].edgeTypeStr),q=m.edgeStrToThickness(s[c-1].edgeTypeStr),ae=m.edgeStrToPattern(s[c-1].edgeTypeStr);this.$=[{id:s[c-2].id,label:s[c-2].label,type:s[c-2].type,directions:s[c-2].directions},{id:s[c-2].id+"-"+s[c].id,start:s[c-2].id,end:s[c].id,label:s[c-1].label,type:"edge",thickness:q,pattern:ae,directions:s[c].directions,arrowTypeEnd:G,arrowTypeStart:ie},{id:s[c].id,label:s[c].label,type:m.typeStr2Type(s[c].typeStr),directions:s[c].directions}];break;case 24:m.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[c-1],s[c]),this.$={id:s[c-1].id,label:s[c-1].label,type:m.typeStr2Type(s[c-1].typeStr),directions:s[c-1].directions,widthInColumns:parseInt(s[c],10)};break;case 25:m.getLogger().debug("Rule: nodeStatement (node) ",s[c]),this.$={id:s[c].id,label:s[c].label,type:m.typeStr2Type(s[c].typeStr),directions:s[c].directions,widthInColumns:1};break;case 26:m.getLogger().debug("APA123",this?this:"na"),m.getLogger().debug("COLUMNS: ",s[c]),this.$={type:"column-setting",columns:s[c]==="auto"?-1:parseInt(s[c])};break;case 27:m.getLogger().debug("Rule: id-block statement : ",s[c-2],s[c-1]);let O=m.generateId();this.$={...s[c-2],type:"composite",children:s[c-1]};break;case 28:m.getLogger().debug("Rule: blockStatement : ",s[c-2],s[c-1],s[c]);let K=m.generateId();this.$={id:K,type:"composite",label:"",children:s[c-1]};break;case 29:m.getLogger().debug("Rule: node (NODE_ID separator): ",s[c]),this.$={id:s[c]};break;case 30:m.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[c-1],s[c]),this.$={id:s[c-1],label:s[c].label,typeStr:s[c].typeStr,directions:s[c].directions};break;case 31:m.getLogger().debug("Rule: dirList: ",s[c]),this.$=[s[c]];break;case 32:m.getLogger().debug("Rule: dirList: ",s[c-1],s[c]),this.$=[s[c-1]].concat(s[c]);break;case 33:m.getLogger().debug("Rule: nodeShapeNLabel: ",s[c-2],s[c-1],s[c]),this.$={typeStr:s[c-2]+s[c],label:s[c-1]};break;case 34:m.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[c-3],s[c-2]," #3:",s[c-1],s[c]),this.$={typeStr:s[c-3]+s[c],label:s[c-2],directions:s[c-1]};break;case 35:case 36:this.$={type:"classDef",id:s[c-1].trim(),css:s[c].trim()};break;case 37:this.$={type:"applyClass",id:s[c-1].trim(),styleClass:s[c].trim()};break;case 38:this.$={type:"applyStyles",id:s[c-1].trim(),stylesStr:s[c].trim()};break}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:o,11:3,13:4,19:5,20:6,21:u,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:w},{8:[1,20]},e(E,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:o,21:u,28:i,29:g,31:f,39:r,43:d,46:w}),e(k,[2,16],{14:22,15:L,16:_}),e(k,[2,17]),e(k,[2,18]),e(k,[2,19]),e(k,[2,20]),e(k,[2,21]),e(k,[2,22]),e(T,[2,25],{27:[1,25]}),e(k,[2,26]),{19:26,26:12,31:f},{10:o,11:27,13:4,19:5,20:6,21:u,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:w},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},e(y,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},e(E,[2,13]),{26:35,31:f},{31:[2,14]},{17:[1,36]},e(T,[2,24]),{10:o,11:37,13:4,14:22,15:L,16:_,19:5,20:6,21:u,22:8,23:9,24:10,25:11,26:12,28:i,29:g,31:f,39:r,43:d,46:w},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},e(y,[2,30]),{18:[1,43]},{18:[1,44]},e(T,[2,23]),{18:[1,45]},{30:[1,46]},e(k,[2,28]),e(k,[2,35]),e(k,[2,36]),e(k,[2,37]),e(k,[2,38]),{36:[1,47]},{33:48,34:I},{15:[1,50]},e(k,[2,27]),e(y,[2,33]),{38:[1,51]},{33:52,34:I,38:[2,31]},{31:[2,15]},e(y,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:t(function(S,n){if(n.recoverable)this.trace(S);else{var h=Error(S);throw h.hash=n,h}},"parseError"),parse:t(function(S){var n=this,h=[0],m=[],D=[null],s=[],H=this.table,c="",V=0,j=0,G=0,ie=2,q=1,ae=s.slice.call(arguments,1),O=Object.create(this.lexer),K={yy:{}};for(var ne in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,ne))K.yy[ne]=this.yy[ne];if(O.setInput(S,K.yy),K.yy.lexer=O,K.yy.parser=this,typeof O.yylloc>"u")O.yylloc={};var oe=O.yylloc;s.push(oe);var qe=O.options&&O.options.ranges;if(typeof K.yy.parseError==="function")this.parseError=K.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function Je(P){h.length=h.length-2*P,D.length=D.length-P,s.length=s.length-P}t(Je,"popStack");function _e(){var P=m.pop()||O.lex()||q;if(typeof P!=="number"){if(P instanceof Array)m=P,P=m.pop();P=n.symbols_[P]||P}return P}t(_e,"lex");var A,ce,W,R,Ct,ue,U={},J,Y,De,Z;while(!0){if(W=h[h.length-1],this.defaultActions[W])R=this.defaultActions[W];else{if(A===null||typeof A>"u")A=_e();R=H[W]&&H[W][A]}if(typeof R>"u"||!R.length||!R[0]){var he="";Z=[];for(J in H[W])if(this.terminals_[J]&&J>ie)Z.push("'"+this.terminals_[J]+"'");if(O.showPosition)he="Parse error on line "+(V+1)+`:
|
|
2
2
|
`+O.showPosition()+`
|
|
3
3
|
Expecting `+Z.join(", ")+", got '"+(this.terminals_[A]||A)+"'";else he="Parse error on line "+(V+1)+": Unexpected "+(A==q?"end of input":"'"+(this.terminals_[A]||A)+"'");this.parseError(he,{text:O.match,token:this.terminals_[A]||A,line:O.yylineno,loc:oe,expected:Z})}if(R[0]instanceof Array&&R.length>1)throw Error("Parse Error: multiple actions possible at state: "+W+", token: "+A);switch(R[0]){case 1:if(h.push(A),D.push(O.yytext),s.push(O.yylloc),h.push(R[1]),A=null,!ce){if(j=O.yyleng,c=O.yytext,V=O.yylineno,oe=O.yylloc,G>0)G--}else A=ce,ce=null;break;case 2:if(Y=this.productions_[R[1]][1],U.$=D[D.length-Y],U._$={first_line:s[s.length-(Y||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(Y||1)].first_column,last_column:s[s.length-1].last_column},qe)U._$.range=[s[s.length-(Y||1)].range[0],s[s.length-1].range[1]];if(ue=this.performAction.apply(U,[c,j,V,K.yy,R[1],D,s].concat(ae)),typeof ue<"u")return ue;if(Y)h=h.slice(0,-1*Y*2),D=D.slice(0,-1*Y),s=s.slice(0,-1*Y);h.push(this.productions_[R[1]][0]),D.push(U.$),s.push(U._$),De=H[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:t(function(n,h){if(this.yy.parser)this.yy.parser.parseError(n,h);else throw Error(n)},"parseError"),setInput:t(function(S,n){if(this.yy=n||this.yy||{},this._input=S,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:t(function(){var S=this._input[0];this.yytext+=S,this.yyleng++,this.offset++,this.match+=S,this.matched+=S;var n=S.match(/(?:\r\n?|\n).*/g);if(n)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),S},"input"),unput:t(function(S){var n=S.length,h=S.split(/(?:\r\n?|\n)/g);this._input=S+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-n),this.offset-=n;var m=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===m.length?this.yylloc.first_column:0)+m[m.length-h.length].length-h[0].length:this.yylloc.first_column-n},this.options.ranges)this.yylloc.range=[D[0],D[0]+this.yyleng-n];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:t(function(S){this.unput(this.match.slice(S))},"less"),pastInput:t(function(){var S=this.matched.substr(0,this.matched.length-this.match.length);return(S.length>20?"...":"")+S.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:t(function(){var S=this.match;if(S.length<20)S+=this._input.substr(0,20-S.length);return(S.substr(0,20)+(S.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:t(function(){var S=this.pastInput(),n=Array(S.length+1).join("-");return S+this.upcomingInput()+`
|
|
5
5
|
`+n+"^"},"showPosition"),test_match:t(function(S,n){var h,m,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(m=S[0].match(/(?:\r\n?|\n).*/g),m)this.yylineno+=m.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:m?m[m.length-1].length-m[m.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+S[0].length},this.yytext+=S[0],this.match+=S[0],this.matches=S,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(S[0].length),this.matched+=S[0],h=this.performAction.call(this,this.yy,this,n,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:t(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var S,n,h,m;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&&(!n||h[0].length>n[0].length)){if(n=h,m=s,this.options.backtrack_lexer)if(S=this.test_match(h,D[s]),S!==!1)return S;else if(this._backtrack){n=!1;continue}else return!1;else if(!this.options.flex)break}if(n){if(S=this.test_match(n,D[m]),S!==!1)return S;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:t(function(){var n=this.next();if(n)return n;else return this.lex()},"lex"),begin:t(function(n){this.conditionStack.push(n)},"begin"),popState:t(function(){var n=this.conditionStack.length-1;if(n>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(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:t(function(n){if(n=this.conditionStack.length-1-Math.abs(n||0),n>=0)return this.conditionStack[n];else return"INITIAL"},"topState"),pushState:t(function(n){this.begin(n)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:t(function(n,h,m,D){var s=D;switch(m){case 0:return n.getLogger().debug("Found block-beta"),10;break;case 1:return n.getLogger().debug("Found id-block"),29;break;case 2:return n.getLogger().debug("Found block"),10;break;case 3:n.getLogger().debug(".",h.yytext);break;case 4:n.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+/,""),n.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:n.getLogger().debug("LEX: POPPING STR:",h.yytext),this.popState();break;case 13:return n.getLogger().debug("LEX: STR end:",h.yytext),"STR";break;case 14:return h.yytext=h.yytext.replace(/space\:/,""),n.getLogger().debug("SPACE NUM (LEX)",h.yytext),21;break;case 15:return h.yytext="1",n.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(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 38:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 39:return this.popState(),n.getLogger().debug("Lex: ))"),"NODE_DEND";break;case 40:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 41:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 42:return this.popState(),n.getLogger().debug("Lex: (-"),"NODE_DEND";break;case 43:return this.popState(),n.getLogger().debug("Lex: -)"),"NODE_DEND";break;case 44:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 45:return this.popState(),n.getLogger().debug("Lex: ]]"),"NODE_DEND";break;case 46:return this.popState(),n.getLogger().debug("Lex: ("),"NODE_DEND";break;case 47:return this.popState(),n.getLogger().debug("Lex: ])"),"NODE_DEND";break;case 48:return this.popState(),n.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 49:return this.popState(),n.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 50:return this.popState(),n.getLogger().debug("Lex: )]"),"NODE_DEND";break;case 51:return this.popState(),n.getLogger().debug("Lex: )"),"NODE_DEND";break;case 52:return this.popState(),n.getLogger().debug("Lex: ]>"),"NODE_DEND";break;case 53:return this.popState(),n.getLogger().debug("Lex: ]"),"NODE_DEND";break;case 54:return n.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;break;case 55:return n.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;break;case 56:return n.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;break;case 57:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 58:return n.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;break;case 59:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 60:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 61:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 62:return n.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;break;case 63:return n.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;break;case 64:return n.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 n.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;break;case 73:return this.pushState("BLOCK_ARROW"),n.getLogger().debug("LEX ARR START"),37;break;case 74:return n.getLogger().debug("Lex: NODE_ID",h.yytext),31;break;case 75:return n.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:n.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:n.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return n.getLogger().debug("LEX: NODE_DESCR:",h.yytext),"NODE_DESCR";break;case 83:n.getLogger().debug("LEX POPPING"),this.popState();break;case 84:n.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (right): dir:",h.yytext),"DIR";break;case 86:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (left):",h.yytext),"DIR";break;case 87:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (x):",h.yytext),"DIR";break;case 88:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (y):",h.yytext),"DIR";break;case 89:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (up):",h.yytext),"DIR";break;case 90:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (down):",h.yytext),"DIR";break;case 91:return h.yytext="]>",n.getLogger().debug("Lex (ARROW_DIR end):",h.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";break;case 92:return n.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 93:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 94:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 95:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 96:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 97:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 98:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 99:this.pushState("md_string");break;case 100:return n.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";break;case 101:return this.popState(),n.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 102:return this.popState(),n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 103:return this.popState(),n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 104:return n.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 t(z,"Parser"),z.prototype=N,N.Parser=z,new z}();be.parser=be;var rt=be,M=new Map,me=[],Se=new Map,Ie="color",Oe="fill",st="bgFill",ve=",",Q=new Map,Le="",it=t((e)=>b.sanitizeText(e,l()),"sanitizeText"),at=t(function(e,o=""){let u=Q.get(e);if(!u)u={id:e,styles:[],textStyles:[]},Q.set(e,u);if(o!==void 0&&o!==null)o.split(ve).forEach((i)=>{let g=i.replace(/([^;]*);/,"$1").trim();if(RegExp(Ie).exec(i)){let r=g.replace(Oe,st).replace(Ie,Oe);u.textStyles.push(r)}u.styles.push(g)})},"addStyleClass"),nt=t(function(e,o=""){let u=M.get(e);if(o!==void 0&&o!==null)u.styles=o.split(ve)},"addStyle2Node"),ot=t(function(e,o){e.split(",").forEach(function(u){let i=M.get(u);if(i===void 0){let g=u.trim();i={id:g,type:"na",children:[]},M.set(g,i)}if(!i.classes)i.classes=[];i.classes.push(o)})},"setCssClass"),Ae=0,ze=t((e,o)=>{let u=e.flat(),i=[],f=u.find((r)=>r?.type==="column-setting")?.columns??-1;for(let r of u){if(typeof f==="number"&&f>0&&r.type!=="column-setting"&&typeof r.widthInColumns==="number"&&r.widthInColumns>f)a.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=(Se.get(r.id)??0)+1;Se.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=M.get(r.id);if(d===void 0){if(r.type==="composite")r.colorIndex=Ae++;M.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 w=r.width??1;for(let E=0;E<w;E++){let k=Ne(r);k.id=k.id+"-"+E,M.set(k.id,k),i.push(k)}}else if(d===void 0)i.push(r)}}o.children=i},"populateBlockDatabase"),ke=[],X={id:"root",type:"composite",children:[],columns:-1},lt=t(()=>{a.debug("Clear called"),C(),X={id:"root",type:"composite",children:[],columns:-1},M=new Map([["root",X]]),ke=[],Q=new Map,me=[],Se=new Map,Le="",Ae=0},"clear");function Be(e){switch(a.debug("typeStr2Type",e),e){case"[]":return"square";case"()":return a.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"}}t(Be,"typeStr2Type");function Re(e){switch(a.debug("typeStr2Type",e),e){case"==":return"thick";default:return"normal"}}t(Re,"edgeTypeStr2Type");function Pe(e){switch(e.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}t(Pe,"edgeStrToEdgeData");function Fe(e){switch(e.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}t(Fe,"edgeStrToEdgeStartData");function Me(e){return e.includes("==")?"thick":"normal"}t(Me,"edgeStrToThickness");function Ke(e){if(e.includes(".-"))return"dotted";return"solid"}t(Ke,"edgeStrToPattern");var Ce=0,ct=t(()=>(Ce++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Ce),"generateId"),ut=t((e)=>{X.children=e,ze(e,X),ke=X.children},"setHierarchy"),ht=t((e)=>{let o=M.get(e);if(!o)return-1;if(o.columns)return o.columns;if(!o.children)return-1;return o.children.length},"getColumns"),gt=t(()=>[...M.values()],"getBlocksFlat"),dt=t(()=>ke||[],"getBlocks"),pt=t(()=>me,"getEdges"),ft=t((e)=>M.get(e),"getBlock"),bt=t((e)=>{M.set(e.id,e)},"setBlock"),St=t((e)=>{Le=e},"setDiagramId"),xt=t(()=>Le,"getDiagramId"),mt=t(()=>a,"getLogger"),Lt=t(function(){return Q},"getClasses"),kt={getConfig:t(()=>x().block,"getConfig"),typeStr2Type:Be,edgeTypeStr2Type:Re,edgeStrToEdgeData:Pe,edgeStrToEdgeStartData:Fe,edgeStrToThickness:Me,edgeStrToPattern:Ke,getLogger:mt,getBlocksFlat:gt,getBlocks:dt,getEdges:pt,setHierarchy:ut,getBlock:ft,setBlock:bt,getColumns:ht,getClasses:Lt,clear:lt,generateId:ct,setDiagramId:St,getDiagramId:xt},wt=kt,_t=t((e)=>{let{theme:o,bkgColorArray:u,borderColorArray:i}=e;if(!se(o,i))return"";let g=le(e.look),f=pe(u),r="";for(let d=0;d<Ye(e.THEME_COLOR_LIMIT,i);d++){let w=i[d%i.length],E=f?`fill: ${u[d%u.length]};`:"",k=`[data-look="${g}"][data-color-id="color-${d}"]`;r+=`
|
|
6
|
+
`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:t(function(){var n=this.next();if(n)return n;else return this.lex()},"lex"),begin:t(function(n){this.conditionStack.push(n)},"begin"),popState:t(function(){var n=this.conditionStack.length-1;if(n>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:t(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:t(function(n){if(n=this.conditionStack.length-1-Math.abs(n||0),n>=0)return this.conditionStack[n];else return"INITIAL"},"topState"),pushState:t(function(n){this.begin(n)},"pushState"),stateStackSize:t(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:t(function(n,h,m,D){var s=D;switch(m){case 0:return n.getLogger().debug("Found block-beta"),10;break;case 1:return n.getLogger().debug("Found id-block"),29;break;case 2:return n.getLogger().debug("Found block"),10;break;case 3:n.getLogger().debug(".",h.yytext);break;case 4:n.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+/,""),n.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:n.getLogger().debug("LEX: POPPING STR:",h.yytext),this.popState();break;case 13:return n.getLogger().debug("LEX: STR end:",h.yytext),"STR";break;case 14:return h.yytext=h.yytext.replace(/space\:/,""),n.getLogger().debug("SPACE NUM (LEX)",h.yytext),21;break;case 15:return h.yytext="1",n.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(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 38:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 39:return this.popState(),n.getLogger().debug("Lex: ))"),"NODE_DEND";break;case 40:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 41:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 42:return this.popState(),n.getLogger().debug("Lex: (-"),"NODE_DEND";break;case 43:return this.popState(),n.getLogger().debug("Lex: -)"),"NODE_DEND";break;case 44:return this.popState(),n.getLogger().debug("Lex: (("),"NODE_DEND";break;case 45:return this.popState(),n.getLogger().debug("Lex: ]]"),"NODE_DEND";break;case 46:return this.popState(),n.getLogger().debug("Lex: ("),"NODE_DEND";break;case 47:return this.popState(),n.getLogger().debug("Lex: ])"),"NODE_DEND";break;case 48:return this.popState(),n.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 49:return this.popState(),n.getLogger().debug("Lex: /]"),"NODE_DEND";break;case 50:return this.popState(),n.getLogger().debug("Lex: )]"),"NODE_DEND";break;case 51:return this.popState(),n.getLogger().debug("Lex: )"),"NODE_DEND";break;case 52:return this.popState(),n.getLogger().debug("Lex: ]>"),"NODE_DEND";break;case 53:return this.popState(),n.getLogger().debug("Lex: ]"),"NODE_DEND";break;case 54:return n.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;break;case 55:return n.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;break;case 56:return n.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;break;case 57:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 58:return n.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;break;case 59:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 60:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 61:return n.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;break;case 62:return n.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;break;case 63:return n.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;break;case 64:return n.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 n.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;break;case 73:return this.pushState("BLOCK_ARROW"),n.getLogger().debug("LEX ARR START"),37;break;case 74:return n.getLogger().debug("Lex: NODE_ID",h.yytext),31;break;case 75:return n.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:n.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:n.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return n.getLogger().debug("LEX: NODE_DESCR:",h.yytext),"NODE_DESCR";break;case 83:n.getLogger().debug("LEX POPPING"),this.popState();break;case 84:n.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (right): dir:",h.yytext),"DIR";break;case 86:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (left):",h.yytext),"DIR";break;case 87:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (x):",h.yytext),"DIR";break;case 88:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (y):",h.yytext),"DIR";break;case 89:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (up):",h.yytext),"DIR";break;case 90:return h.yytext=h.yytext.replace(/^,\s*/,""),n.getLogger().debug("Lex (down):",h.yytext),"DIR";break;case 91:return h.yytext="]>",n.getLogger().debug("Lex (ARROW_DIR end):",h.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";break;case 92:return n.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 93:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 94:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 95:return n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 96:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 97:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 98:return n.getLogger().debug("Lex: START_LINK",h.yytext),this.pushState("LLABEL"),16;break;case 99:this.pushState("md_string");break;case 100:return n.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";break;case 101:return this.popState(),n.getLogger().debug("Lex: LINK","#"+h.yytext+"#"),15;break;case 102:return this.popState(),n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 103:return this.popState(),n.getLogger().debug("Lex: LINK",h.yytext),15;break;case 104:return n.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 t(z,"Parser"),z.prototype=N,N.Parser=z,new z}();be.parser=be;var rt=be,M=new Map,me=[],Se=new Map,Ie="color",Oe="fill",st="bgFill",ve=",",Q=new Map,Le="",it=t((e)=>b.sanitizeText(e,l()),"sanitizeText"),at=t(function(e,o=""){let u=Q.get(e);if(!u)u={id:e,styles:[],textStyles:[]},Q.set(e,u);if(o!==void 0&&o!==null)o.split(ve).forEach((i)=>{let g=i.replace(/([^;]*);/,"$1").trim();if(RegExp(Ie).exec(i)){let r=g.replace(Oe,st).replace(Ie,Oe);u.textStyles.push(r)}u.styles.push(g)})},"addStyleClass"),nt=t(function(e,o=""){let u=M.get(e);if(o!==void 0&&o!==null)u.styles=o.split(ve)},"addStyle2Node"),ot=t(function(e,o){e.split(",").forEach(function(u){let i=M.get(u);if(i===void 0){let g=u.trim();i={id:g,type:"na",children:[]},M.set(g,i)}if(!i.classes)i.classes=[];i.classes.push(o)})},"setCssClass"),Ae=0,ze=t((e,o)=>{let u=e.flat(),i=[],f=u.find((r)=>r?.type==="column-setting")?.columns??-1;for(let r of u){if(typeof f==="number"&&f>0&&r.type!=="column-setting"&&typeof r.widthInColumns==="number"&&r.widthInColumns>f)a.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=(Se.get(r.id)??0)+1;Se.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=M.get(r.id);if(d===void 0){if(r.type==="composite")r.colorIndex=Ae++;M.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 w=r.width??1;for(let E=0;E<w;E++){let k=Ne(r);k.id=k.id+"-"+E,M.set(k.id,k),i.push(k)}}else if(d===void 0)i.push(r)}}o.children=i},"populateBlockDatabase"),ke=[],X={id:"root",type:"composite",children:[],columns:-1},lt=t(()=>{a.debug("Clear called"),C(),X={id:"root",type:"composite",children:[],columns:-1},M=new Map([["root",X]]),ke=[],Q=new Map,me=[],Se=new Map,Le="",Ae=0},"clear");function Be(e){switch(a.debug("typeStr2Type",e),e){case"[]":return"square";case"()":return a.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"}}t(Be,"typeStr2Type");function Re(e){switch(a.debug("typeStr2Type",e),e){case"==":return"thick";default:return"normal"}}t(Re,"edgeTypeStr2Type");function Pe(e){switch(e.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}t(Pe,"edgeStrToEdgeData");function Fe(e){switch(e.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}t(Fe,"edgeStrToEdgeStartData");function Me(e){return e.includes("==")?"thick":"normal"}t(Me,"edgeStrToThickness");function Ke(e){if(e.includes(".-"))return"dotted";return"solid"}t(Ke,"edgeStrToPattern");var Ce=0,ct=t(()=>(Ce++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Ce),"generateId"),ut=t((e)=>{X.children=e,ze(e,X),ke=X.children},"setHierarchy"),ht=t((e)=>{let o=M.get(e);if(!o)return-1;if(o.columns)return o.columns;if(!o.children)return-1;return o.children.length},"getColumns"),gt=t(()=>[...M.values()],"getBlocksFlat"),dt=t(()=>ke||[],"getBlocks"),pt=t(()=>me,"getEdges"),ft=t((e)=>M.get(e),"getBlock"),bt=t((e)=>{M.set(e.id,e)},"setBlock"),St=t((e)=>{Le=e},"setDiagramId"),xt=t(()=>Le,"getDiagramId"),mt=t(()=>a,"getLogger"),Lt=t(function(){return Q},"getClasses"),kt={getConfig:t(()=>x().block,"getConfig"),typeStr2Type:Be,edgeTypeStr2Type:Re,edgeStrToEdgeData:Pe,edgeStrToEdgeStartData:Fe,edgeStrToThickness:Me,edgeStrToPattern:Ke,getLogger:mt,getBlocksFlat:gt,getBlocks:dt,getEdges:pt,setHierarchy:ut,getBlock:ft,setBlock:bt,getColumns:ht,getClasses:Lt,clear:lt,generateId:ct,setDiagramId:St,getDiagramId:xt},yt=kt,wt=t((e)=>{let{theme:o,bkgColorArray:u,borderColorArray:i}=e;if(!se(o,i))return"";let g=le(e.look),f=pe(u),r="";for(let d=0;d<Ye(e.THEME_COLOR_LIMIT,i);d++){let w=i[d%i.length],E=f?`fill: ${u[d%u.length]};`:"",k=`[data-look="${g}"][data-color-id="color-${d}"]`;r+=`
|
|
7
7
|
|
|
8
8
|
${k}.node rect.composite {
|
|
9
9
|
stroke: ${w};
|
|
10
10
|
${E}
|
|
11
11
|
}
|
|
12
|
-
`}return r},"genColor"),fe=t((e,o)=>{let u=Bt,i=u(e,"r"),g=u(e,"g"),f=u(e,"b");return de(i,g,f,o)},"fade"),
|
|
12
|
+
`}return r},"genColor"),fe=t((e,o)=>{let u=Bt,i=u(e,"r"),g=u(e,"g"),f=u(e,"b");return de(i,g,f,o)},"fade"),_t=t((e)=>`${wt(e)}
|
|
13
13
|
.label {
|
|
14
14
|
font-family: ${e.fontFamily};
|
|
15
15
|
color: ${e.nodeTextColor||e.textColor};
|
|
@@ -137,4 +137,4 @@ Expecting `+Z.join(", ")+", got '"+(this.terminals_[A]||A)+"'";else he="Parse er
|
|
|
137
137
|
fill: ${e.textColor};
|
|
138
138
|
}
|
|
139
139
|
${je()}
|
|
140
|
-
`,"getStyles"),
|
|
140
|
+
`,"getStyles"),Dt=_t;function xe(e,o){if(e===0||!Number.isInteger(e))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(e<0)return{px:o,py:0};if(e===1)return{px:0,py:o};let u=o%e,i=Math.floor(o/e);return{px:u,py:i}}t(xe,"calculateBlockPosition");var Tt=t((e)=>{let o=0,u=0;for(let i of e.children){let{width:g,height:f,x:r,y:d}=i.size??{width:0,height:0,x:0,y:0};if(a.debug("getMaxChildSize abc95 child:",i.id,"width:",g,"height:",f,"x:",r,"y:",d,i.type),i.type==="space")continue;let w=g/(i.widthInColumns??1);if(w>o)o=w;if(f>u)u=f}return{width:o,height:u}},"getMaxChildSize");function ee(e,o,u=0,i=0,g=8){if(a.debug("setBlockSizes abc95 (start)",e.id,e?.size?.x,"block width =",e?.size,"siblingWidth",u),!e?.size?.width)e.size={width:u,height:i,x:0,y:0};let f=0,r=0;if(e.children?.length>0){for(let y of e.children)ee(y,o,0,0,g);let d=Tt(e);f=d.width,r=d.height,a.debug("setBlockSizes abc95 maxWidth of",e.id,":s children is ",f,r);for(let y of e.children)if(y.size)a.debug(`abc95 Setting size of children of ${e.id} id=${y.id} ${f} ${r} ${JSON.stringify(y.size)}`),y.size.width=f*(y.widthInColumns??1)+g*((y.widthInColumns??1)-1),y.size.height=r,y.size.x=0,y.size.y=0,a.debug(`abc95 updating size of ${e.id} children child:${y.id} maxWidth:${f} maxHeight:${r}`);for(let y of e.children)ee(y,o,f,r,g);let w=e.columns??-1,E=0;for(let y of e.children)E+=y.widthInColumns??1;let k=e.children.length;if(w>0&&w<E)k=w;let L=Math.ceil(E/k),_=k*(f+g)+g,T=L*(r+g)+g;if(_<u){a.debug(`Detected to small sibling: abc95 ${e.id} siblingWidth ${u} siblingHeight ${i} width ${_}`),_=u,T=i;let y=(u-k*g-g)/k,I=(i-L*g-g)/L;a.debug("Size indata abc88",e.id,"childWidth",y,"maxWidth",f),a.debug("Size indata abc88",e.id,"childHeight",I,"maxHeight",r),a.debug("Size indata abc88 xSize",k,"padding",g);for(let N of e.children)if(N.size)N.size.width=y,N.size.height=I,N.size.x=0,N.size.y=0}if(a.debug(`abc95 (finale calc) ${e.id} xSize ${k} ySize ${L} columns ${w}${e.children.length} width=${Math.max(_,e.size?.width||0)}`),_<(e?.size?.width||0)){_=e?.size?.width||0;let y=w>0?Math.min(e.children.length,w):e.children.length;if(y>0){let I=(_-y*g-g)/y;a.debug("abc95 (growing to fit) width",e.id,_,e.size?.width,I);for(let N of e.children)if(N.size)N.size.width=I}}e.size={width:_,height:T,x:0,y:0}}a.debug("setBlockSizes abc94 (done)",e.id,e?.size?.x,e?.size?.width,e?.size?.y,e?.size?.height)}t(ee,"setBlockSizes");function ye(e,o,u=8){a.debug(`abc85 layout blocks (=>layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`);let i=e.columns??-1;if(a.debug("layoutBlocks columns abc95",e.id,"=>",i,e),e.children&&e.children.length>0){let g=e?.children[0]?.size?.width??0,f=e.children.length*g+(e.children.length-1)*u;a.debug("widthOfChildren 88",f,"posX");let r=new Map;{let L=0;for(let _ of e.children){if(!_.size)continue;let{py:T}=xe(i,L),y=r.get(T)??0;if(_.size.height>y)r.set(T,_.size.height);let I=_?.widthInColumns??1;if(i>0)I=Math.min(I,i-L%i);L+=I}}let d=new Map;{let L=0,_=[...r.keys()].sort((T,y)=>T-y);for(let T of _)d.set(T,L),L+=(r.get(T)??0)+u}let w=0;a.debug("abc91 block?.size?.x",e.id,e?.size?.x);let E=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-u,k=0;for(let L of e.children){let _=e;if(!L.size)continue;let{width:T,height:y}=L.size,{px:I,py:N}=xe(i,w);if(N!=k)k=N,E=e?.size?.x?e?.size?.x+(-e?.size?.width/2||0):-u,a.debug("New row in layout for block",e.id," and child ",L.id,k);if(a.debug(`abc89 layout blocks (child) id: ${L.id} Pos: ${w} (px, py) ${I},${N} (${_?.size?.x},${_?.size?.y}) parent: ${_.id} width: ${T}${u}`),_.size){let z=T/2;L.size.x=E+u+z,a.debug(`abc91 layout blocks (calc) px, pyid:${L.id} startingPos=X${E} new startingPosX${L.size.x} ${z} padding=${u} width=${T} halfWidth=${z} => x:${L.size.x} y:${L.size.y} ${L.widthInColumns} (width * (child?.w || 1)) / 2 ${T*(L?.widthInColumns??1)/2}`),E=L.size.x+z;let B=d.get(N)??0,S=r.get(N)??y;L.size.y=_.size.y-_.size.height/2+B+S/2+u,a.debug(`abc88 layout blocks (calc) px, pyid:${L.id}startingPosX${E}${u}${z}=>x:${L.size.x}y:${L.size.y}${L.widthInColumns}(width * (child?.w || 1)) / 2${T*(L?.widthInColumns??1)/2}`)}if(L.children)ye(L,o,u);let v=L?.widthInColumns??1;if(i>0)v=Math.min(v,i-w%i);w+=v,a.debug("abc88 columnsPos",L,w)}}a.debug(`layout blocks (<==layoutBlocks) ${e.id} x: ${e?.size?.x} y: ${e?.size?.y} width: ${e?.size?.width}`)}t(ye,"layoutBlocks");function we(e,{minX:o,minY:u,maxX:i,maxY:g}={minX:0,minY:0,maxX:0,maxY:0}){if(e.size&&e.id!=="root"){let{x:f,y:r,width:d,height:w}=e.size;if(f-d/2<o)o=f-d/2;if(r-w/2<u)u=r-w/2;if(f+d/2>i)i=f+d/2;if(r+w/2>g)g=r+w/2}if(e.children)for(let f of e.children)({minX:o,minY:u,maxX:i,maxY:g}=we(f,{minX:o,minY:u,maxX:i,maxY:g}));return{minX:o,minY:u,maxX:i,maxY:g}}t(we,"findBounds");function We(e){let o=e.getBlock("root");if(!o)return;let u=l()?.block?.padding??8;ee(o,e,0,0,u),ye(o,e,u),a.debug("getBlocks",JSON.stringify(o,null,2));let{minX:i,minY:g,maxX:f,maxY:r}=we(o),d=r-g,w=f-i;return{x:i,y:g,width:w,height:d}}t(We,"layout");function Ee(e,o,u=!1){let i=e,g="default";if((i?.classes?.length||0)>0)g=(i?.classes??[]).join(" ");g=g+" flowchart-label";let f=(i?.classes??[]).flatMap((y)=>o.getClasses().get(y)?.styles??[]),r=0,d="rect",w;switch(i.type){case"round":r=5,d="rect";break;case"composite":r=0,d="composite",w=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 E=oi(i?.styles??[]),k=i.label,L=i.size??{width:0,height:0,x:0,y:0},_=o.getDiagramId();return{labelStyle:E.labelStyle,shape:d,label:k,labelText:k,rx:r,ry:r,class:g,cssClasses:g,cssStyles:i?.styles??[],cssCompiledStyles:f,style:E.style,id:i.id,domId:_?`${_}-${i.id}`:i.id,isGroup:!1,directions:i.directions,width:L.width||void 0,height:L.height||void 0,wrappingWidth:L.width||Number.POSITIVE_INFINITY,x:L.x,y:L.y,positioned:u,intersect:void 0,padding:w??x()?.block?.padding??0,widthInColumns:i.widthInColumns??1,colorIndex:i.colorIndex,look:x().look}}t(Ee,"getNodeFromBlock");async function Ve(e,o,u){let i=Ee(o,u,!1);if(o.type==="group")return;let g=x(),f=await Et(e,i,{config:g}),r=f.node()?.getBBox()??{width:0,height:0},d=u.getBlock(i.id);d.size={width:r.width,height:r.height,x:0,y:0,node:f},u.setBlock(d),f.remove()}t(Ve,"calculateBlockSize");async function Ue(e,o,u){let i=Ee(o,u,!0);if(u.getBlock(i.id).type!=="space"){let f=x(),r=await Et(e,i,{config:f});if(i.colorIndex!==void 0)Ze(r,i.colorIndex,f.theme,f.themeVariables?.borderColorArray);o.intersect=i?.intersect,vt(i)}}t(Ue,"insertBlockPositioned");async function te(e,o,u,i){for(let g of o)if(await i(e,g,u),g.children)await te(e,g.children,u,i)}t(te,"performOperations");async function He(e,o,u){await te(e,o,u,Ve)}t(He,"calculateBlockSizes");async function Xe(e,o,u){await te(e,o,u,Ue)}t(Xe,"insertBlocks");async function Ge(e,o,u,i,g){let f=new re({multigraph:!0,compound:!0});f.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(let r of u)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),w=i.getBlock(r.end);if(d?.size&&w?.size){let E=d.size,k=w.size,L=[{x:E.x,y:E.y},{x:E.x+(k.x-E.x)/2,y:E.y+(k.y-E.y)/2},{x:k.x,y:k.y}],_=g?`${g}-${r.id}`:r.id,T=r.thickness==="thick"?"edge-thickness-thick":"edge-thickness-normal",y=r.pattern==="dotted"?"edge-pattern-dotted":"edge-pattern-solid",I=`${T} ${y} flowchart-link LS-a1 LE-b1`;if(tn(e,{...r,id:_,arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:L,classes:I},{},"block",f.node(r.start),f.node(r.end),g),r.label)await At(e,{...r,label:r.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:L,classes:I}),Yn({...r,x:L[1].x,y:L[1].y},{originalPath:L})}}}t(Ge,"insertEdges");var Nt=t(function(e,o){return o.db.getClasses()},"getClasses"),It=t(async function(e,o,u,i){let{securityLevel:g,block:f}=x(),r=i.db;r.setDiagramId(o);let d;if(g==="sandbox")d=p("#i"+o);let w=g==="sandbox"?p(d.nodes()[0].contentDocument.body):p("body"),E=g==="sandbox"?w.select(`[id="${o}"]`):p(`[id="${o}"]`);za(E,x()),Zn(E,["point","circle","cross"],i.type,o);let L=r.getBlocks(),_=r.getBlocksFlat(),T=r.getEdges(),y=E.insert("g").attr("class","block");await He(y,L,r);let I=We(r);await Xe(y,L,r),await Ge(y,T,_,r,o);let N=y.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,S=v.width+10,{useMaxWidth:n}=f;F(E,B,S,!!n),a.debug("Here Bounds",I,v),E.attr("viewBox",`${v.x-5} ${v.y-5} ${v.width+10} ${v.height+10}`)}},"draw"),Ot={draw:It,getClasses:Nt},ar={parser:rt,db:yt,renderer:Ot,styles:Dt};export{ar as diagram};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{t,a,K,u,d,N,O,
|
|
1
|
+
import{t,a,K,u,d,N,O,gt,l,V,et,tt,Et,vt,en}from"./chunk-tfqarvdx.js";import{je}from"./chunk-z5qn0xev.js";var ae=function(){var e=t(function(R,r,i,o){for(i=i||{},o=R.length;o--;i[R[o]]=r);return i},"o"),f=[1,4],m=[1,13],s=[1,12],y=[1,15],x=[1,16],S=[1,20],g=[1,19],A=[6,7,8],P=[1,26],b=[1,24],j=[1,25],v=[6,7,11],Y=[1,31],L=[6,7,11,24],W=[1,6,13,16,17,20,23],k=[1,35],F=[1,36],T=[1,6,7,11,13,16,17,20,23],J=[1,38],G={trace:t(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:t(function(r,i,o,c,p,n,M){var h=n.length-1;switch(p){case 6:case 7:return c;case 8:c.getLogger().trace("Stop NL ");break;case 9:c.getLogger().trace("Stop EOF ");break;case 11:c.getLogger().trace("Stop NL2 ");break;case 12:c.getLogger().trace("Stop EOF2 ");break;case 15:c.getLogger().info("Node: ",n[h-1].id),c.addNode(n[h-2].length,n[h-1].id,n[h-1].descr,n[h-1].type,n[h]);break;case 16:c.getLogger().info("Node: ",n[h].id),c.addNode(n[h-1].length,n[h].id,n[h].descr,n[h].type);break;case 17:c.getLogger().trace("Icon: ",n[h]),c.decorateNode({icon:n[h]});break;case 18:case 23:c.decorateNode({class:n[h]});break;case 19:c.getLogger().trace("SPACELIST");break;case 20:c.getLogger().trace("Node: ",n[h-1].id),c.addNode(0,n[h-1].id,n[h-1].descr,n[h-1].type,n[h]);break;case 21:c.getLogger().trace("Node: ",n[h].id),c.addNode(0,n[h].id,n[h].descr,n[h].type);break;case 22:c.decorateNode({icon:n[h]});break;case 27:c.getLogger().trace("node found ..",n[h-2]),this.$={id:n[h-1],descr:n[h-1],type:c.getType(n[h-2],n[h])};break;case 28:this.$={id:n[h],descr:n[h],type:0};break;case 29:c.getLogger().trace("node found ..",n[h-3]),this.$={id:n[h-3],descr:n[h-1],type:c.getType(n[h-2],n[h])};break;case 30:this.$=n[h-1]+n[h];break;case 31:this.$=n[h];break}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:f},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:f},{6:m,7:[1,10],9:9,12:11,13:s,14:14,16:y,17:x,18:17,19:18,20:S,23:g},e(A,[2,3]),{1:[2,2]},e(A,[2,4]),e(A,[2,5]),{1:[2,6],6:m,12:21,13:s,14:14,16:y,17:x,18:17,19:18,20:S,23:g},{6:m,9:22,12:11,13:s,14:14,16:y,17:x,18:17,19:18,20:S,23:g},{6:P,7:b,10:23,11:j},e(v,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:S,23:g}),e(v,[2,19]),e(v,[2,21],{15:30,24:Y}),e(v,[2,22]),e(v,[2,23]),e(L,[2,25]),e(L,[2,26]),e(L,[2,28],{20:[1,32]}),{21:[1,33]},{6:P,7:b,10:34,11:j},{1:[2,7],6:m,12:21,13:s,14:14,16:y,17:x,18:17,19:18,20:S,23:g},e(W,[2,14],{7:k,11:F}),e(T,[2,8]),e(T,[2,9]),e(T,[2,10]),e(v,[2,16],{15:37,24:Y}),e(v,[2,17]),e(v,[2,18]),e(v,[2,20],{24:J}),e(L,[2,31]),{21:[1,39]},{22:[1,40]},e(W,[2,13],{7:k,11:F}),e(T,[2,11]),e(T,[2,12]),e(v,[2,15],{24:J}),e(L,[2,30]),{22:[1,41]},e(L,[2,27]),e(L,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:t(function(r,i){if(i.recoverable)this.trace(r);else{var o=Error(r);throw o.hash=i,o}},"parseError"),parse:t(function(r){var i=this,o=[0],c=[],p=[null],n=[],M=this.table,h="",q=0,he=0,ue=0,be=2,ge=1,ye=n.slice.call(arguments,1),_=Object.create(this.lexer),U={yy:{}};for(var te in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,te))U.yy[te]=this.yy[te];if(_.setInput(r,U.yy),U.yy.lexer=_,U.yy.parser=this,typeof _.yylloc>"u")_.yylloc={};var ne=_.yylloc;n.push(ne);var me=_.options&&_.options.ranges;if(typeof U.yy.parseError==="function")this.parseError=U.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function ke(C){o.length=o.length-2*C,p.length=p.length-C,n.length=n.length-C}t(ke,"popStack");function de(){var C=c.pop()||_.lex()||ge;if(typeof C!=="number"){if(C instanceof Array)c=C,C=c.pop();C=i.symbols_[C]||C}return C}t(de,"lex");var D,ie,H,I,Fe,re,X={},Q,B,pe,Z;while(!0){if(H=o[o.length-1],this.defaultActions[H])I=this.defaultActions[H];else{if(D===null||typeof D>"u")D=de();I=M[H]&&M[H][D]}if(typeof I>"u"||!I.length||!I[0]){var se="";Z=[];for(Q in M[H])if(this.terminals_[Q]&&Q>be)Z.push("'"+this.terminals_[Q]+"'");if(_.showPosition)se="Parse error on line "+(q+1)+`:
|
|
2
2
|
`+_.showPosition()+`
|
|
3
3
|
Expecting `+Z.join(", ")+", got '"+(this.terminals_[D]||D)+"'";else se="Parse error on line "+(q+1)+": Unexpected "+(D==ge?"end of input":"'"+(this.terminals_[D]||D)+"'");this.parseError(se,{text:_.match,token:this.terminals_[D]||D,line:_.yylineno,loc:ne,expected:Z})}if(I[0]instanceof Array&&I.length>1)throw Error("Parse Error: multiple actions possible at state: "+H+", token: "+D);switch(I[0]){case 1:if(o.push(D),p.push(_.yytext),n.push(_.yylloc),o.push(I[1]),D=null,!ie){if(he=_.yyleng,h=_.yytext,q=_.yylineno,ne=_.yylloc,ue>0)ue--}else D=ie,ie=null;break;case 2:if(B=this.productions_[I[1]][1],X.$=p[p.length-B],X._$={first_line:n[n.length-(B||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(B||1)].first_column,last_column:n[n.length-1].last_column},me)X._$.range=[n[n.length-(B||1)].range[0],n[n.length-1].range[1]];if(re=this.performAction.apply(X,[h,he,q,U.yy,I[1],p,n].concat(ye)),typeof re<"u")return re;if(B)o=o.slice(0,-1*B*2),p=p.slice(0,-1*B),n=n.slice(0,-1*B);o.push(this.productions_[I[1]][0]),p.push(X.$),n.push(X._$),pe=M[o[o.length-2]][o[o.length-1]],o.push(pe);break;case 3:return!0}}return!0},"parse")},ee=function(){var R={EOF:1,parseError:t(function(i,o){if(this.yy.parser)this.yy.parser.parseError(i,o);else throw Error(i)},"parseError"),setInput:t(function(r,i){if(this.yy=i||this.yy||{},this._input=r,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:t(function(){var r=this._input[0];this.yytext+=r,this.yyleng++,this.offset++,this.match+=r,this.matched+=r;var i=r.match(/(?:\r\n?|\n).*/g);if(i)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),r},"input"),unput:t(function(r){var i=r.length,o=r.split(/(?:\r\n?|\n)/g);this._input=r+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var c=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),o.length-1)this.yylineno-=o.length-1;var p=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:o?(o.length===c.length?this.yylloc.first_column:0)+c[c.length-o.length].length-o[0].length:this.yylloc.first_column-i},this.options.ranges)this.yylloc.range=[p[0],p[0]+this.yyleng-i];return this.yyleng=this.yytext.length,this},"unput"),more:t(function(){return this._more=!0,this},"more"),reject:t(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
|
|
4
4
|
`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:t(function(r){this.unput(this.match.slice(r))},"less"),pastInput:t(function(){var r=this.matched.substr(0,this.matched.length-this.match.length);return(r.length>20?"...":"")+r.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:t(function(){var r=this.match;if(r.length<20)r+=this._input.substr(0,20-r.length);return(r.substr(0,20)+(r.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:t(function(){var r=this.pastInput(),i=Array(r.length+1).join("-");return r+this.upcomingInput()+`
|
|
@@ -8,7 +8,7 @@ Expecting `+Z.join(", ")+", got '"+(this.terminals_[D]||D)+"'";else se="Parse er
|
|
|
8
8
|
`+y+`
|
|
9
9
|
}`;else P=y+`
|
|
10
10
|
`;let b=tt(P,{schema:et});if(b.shape&&(b.shape!==b.shape.toLowerCase()||b.shape.includes("_")))throw Error(`No such shape: ${b.shape}. Shape names should be lowercase.`);if(b?.shape&&b.shape==="kanbanItem")g.shape=b?.shape;if(b?.label)g.label=b?.label;if(b?.icon)g.icon=b?.icon.toString();if(b?.assigned)g.assigned=b?.assigned.toString();if(b?.ticket)g.ticket=b?.ticket.toString();if(b?.priority)g.priority=b?.priority}let A=Se(e);if(A)g.parentId=A.id||"kbn"+oe++;else ce.push(g);w.push(g)},"addNode"),E={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},ve=t((e,f)=>{switch(a.debug("In get type",e,f),e){case"[":return E.RECT;case"(":return f===")"?E.ROUNDED_RECT:E.CLOUD;case"((":return E.CIRCLE;case")":return E.CLOUD;case"))":return E.BANG;case"{{":return E.HEXAGON;default:return E.DEFAULT}},"getType"),De=t((e,f)=>{le[e]=f},"setElementForId"),Le=t((e)=>{if(!e)return;let f=l(),m=w[w.length-1];if(e.icon)m.icon=O(e.icon,f);if(e.class)m.cssClasses=O(e.class,f)},"decorateNode"),Oe=t((e)=>{switch(e){case E.DEFAULT:return"no-border";case E.RECT:return"rect";case E.ROUNDED_RECT:return"rounded-rect";case E.CIRCLE:return"circle";case E.CLOUD:return"cloud";case E.BANG:return"bang";case E.HEXAGON:return"hexgon";default:return"no-border"}},"type2Str"),Ie=t(()=>a,"getLogger"),Ce=t((e)=>le[e],"getElementById"),we={clear:_e,addNode:xe,getSections:fe,getData:Ne,nodeType:E,getType:ve,setElementForId:De,decorateNode:Le,type2Str:Oe,getLogger:Ie,getElementById:Ce},Ae=we,Te=t(async(e,f,m,s)=>{a.debug(`Rendering kanban diagram
|
|
11
|
-
`+e);let x=s.db.getData(),S=l();S.htmlLabels=!1;let g=V(f);for(let k of x.nodes)k.domId=`${f}-${k.id}`;let A=g.append("g");A.attr("class","sections");let P=g.append("g");P.attr("class","items");let b=x.nodes.filter((k)=>k.isGroup),j=0,v=10,Y=[],L=25;for(let k of b){let F=S?.kanban?.sectionWidth||200;j=j+1,k.x=F*j+(j-1)*v/2,k.width=F,k.y=0,k.height=F*3,k.rx=5,k.ry=5,k.cssClasses=k.cssClasses+" section-"+j;let T=await en(A,k);L=Math.max(L,T?.labelBBox?.height),Y.push(T)}let W=0;for(let k of b){let F=Y[W];W=W+1;let T=S?.kanban?.sectionWidth||200,J=-T*3/2+L,G=J,ee=x.nodes.filter((r)=>r.parentId===k.id);for(let r of ee){if(r.isGroup)throw Error("Groups within groups are not allowed in Kanban diagrams");r.x=k.x,r.width=T-1.5*v;let o=(await Et(P,r,{config:S})).node().getBBox();r.y=G+o.height/2,await
|
|
11
|
+
`+e);let x=s.db.getData(),S=l();S.htmlLabels=!1;let g=V(f);for(let k of x.nodes)k.domId=`${f}-${k.id}`;let A=g.append("g");A.attr("class","sections");let P=g.append("g");P.attr("class","items");let b=x.nodes.filter((k)=>k.isGroup),j=0,v=10,Y=[],L=25;for(let k of b){let F=S?.kanban?.sectionWidth||200;j=j+1,k.x=F*j+(j-1)*v/2,k.width=F,k.y=0,k.height=F*3,k.rx=5,k.ry=5,k.cssClasses=k.cssClasses+" section-"+j;let T=await en(A,k);L=Math.max(L,T?.labelBBox?.height),Y.push(T)}let W=0;for(let k of b){let F=Y[W];W=W+1;let T=S?.kanban?.sectionWidth||200,J=-T*3/2+L,G=J,ee=x.nodes.filter((r)=>r.parentId===k.id);for(let r of ee){if(r.isGroup)throw Error("Groups within groups are not allowed in Kanban diagrams");r.x=k.x,r.width=T-1.5*v;let o=(await Et(P,r,{config:S})).node().getBBox();r.y=G+o.height/2,await vt(r),G=r.y+o.height/2+v/2}let z=F.cluster.select("rect"),R=Math.max(G-J+3*v,50)+(L-25);z.attr("height",R)}gt(void 0,g,S.mindmap?.padding??N.kanban.padding,S.mindmap?.useMaxWidth??N.kanban.useMaxWidth)},"draw"),Re={draw:Te},Pe=t((e)=>{let f="";for(let s=0;s<e.THEME_COLOR_LIMIT;s++)if(e["lineColor"+s]=e["lineColor"+s]||e["cScaleInv"+s],K(e["lineColor"+s]))e["lineColor"+s]=u(e["lineColor"+s],20);else e["lineColor"+s]=d(e["lineColor"+s],20);let m=t((s,y)=>e.darkMode?d(s,y):u(s,y),"adjuster");for(let s=0;s<e.THEME_COLOR_LIMIT;s++){let y=""+(17-3*s);f+=`
|
|
12
12
|
.section-${s-1} rect, .section-${s-1} path, .section-${s-1} circle, .section-${s-1} polygon, .section-${s-1} path {
|
|
13
13
|
fill: ${m(e["cScale"+s],10)};
|
|
14
14
|
stroke: ${m(e["cScale"+s],10)};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import{Mt,gn,Pt,da}from"./chunk-9yfftz38.js";import{Ot}from"./chunk-h0c42zy3.js";import{zt,Sr,zn,Be,Tr}from"./chunk-
|
|
1
|
+
import{Mt,gn,Pt,da}from"./chunk-9yfftz38.js";import{Ot}from"./chunk-h0c42zy3.js";import{zt,Sr,zn,Be,Tr}from"./chunk-tfqarvdx.js";function s(r,n){return r==null||n==null?NaN:r<n?-1:r>n?1:r>=n?0:NaN}function x(r,n){return r==null||n==null?NaN:n<r?-1:n>r?1:n>=r?0:NaN}function sr(r){let n,e,t;if(r.length!==2)n=s,e=(f,c)=>s(r(f),c),t=(f,c)=>r(f)-c;else n=r===s||r===x?r:O,e=r,t=r;function o(f,c,i=0,p=f.length){if(i<p){if(n(c,c)!==0)return p;do{let l=i+p>>>1;if(e(f[l],c)<0)i=l+1;else p=l}while(i<p)}return i}function a(f,c,i=0,p=f.length){if(i<p){if(n(c,c)!==0)return p;do{let l=i+p>>>1;if(e(f[l],c)<=0)i=l+1;else p=l}while(i<p)}return i}function u(f,c,i=0,p=f.length){let l=o(f,c,i,p-1);return l>i&&t(f[l-1],c)>-t(f[l],c)?l-1:l}return{left:o,center:u,right:a}}function O(){return 0}function y(r){return r===null?NaN:+r}var V=sr(s),{right:T,left:ir}=V,or=sr(y).center,z=T;var E=Math.sqrt(50),G=Math.sqrt(10),H=Math.sqrt(2);function g(r,n,e){let t=(n-r)/Math.max(0,e),o=Math.floor(Math.log10(t)),a=t/Math.pow(10,o),u=a>=E?10:a>=G?5:a>=H?2:1,f,c,i;if(o<0){if(i=Math.pow(10,-o)/u,f=Math.round(r*i),c=Math.round(n*i),f/i<r)++f;if(c/i>n)--c;i=-i}else{if(i=Math.pow(10,o)*u,f=Math.round(r/i),c=Math.round(n/i),f*i<r)++f;if(c*i>n)--c}if(c<f&&0.5<=e&&e<2)return g(r,n,e*2);return[f,c,i]}function v(r,n,e){if(n=+n,r=+r,e=+e,!(e>0))return[];if(r===n)return[r];let t=n<r,[o,a,u]=t?g(n,r,e):g(r,n,e);if(!(a>=o))return[];let f=a-o+1,c=Array(f);if(t)if(u<0)for(let i=0;i<f;++i)c[i]=(a-i)/-u;else for(let i=0;i<f;++i)c[i]=(a-i)*u;else if(u<0)for(let i=0;i<f;++i)c[i]=(o+i)/-u;else for(let i=0;i<f;++i)c[i]=(o+i)*u;return c}function M(r,n,e){return n=+n,r=+r,e=+e,g(r,n,e)[2]}function zr(r,n,e){n=+n,r=+r,e=+e;let t=n<r,o=t?M(n,r,e):M(r,n,e);return(t?-1:1)*(o<0?1/-o:o)}function N(r,n){if(!n)n=[];var e=r?Math.min(n.length,r.length):0,t=n.slice(),o;return function(a){for(o=0;o<e;++o)t[o]=r[o]*(1-a)+n[o]*a;return t}}function B(r){return ArrayBuffer.isView(r)&&!(r instanceof DataView)}function P(r,n){var e=n?n.length:0,t=r?Math.min(e,r.length):0,o=Array(t),a=Array(e),u;for(u=0;u<t;++u)o[u]=h(r[u],n[u]);for(;u<e;++u)a[u]=n[u];return function(f){for(u=0;u<t;++u)a[u]=o[u](f);return a}}function w(r,n){var e=new Date;return r=+r,n=+n,function(t){return e.setTime(r*(1-t)+n*t),e}}function k(r,n){var e={},t={},o;if(r===null||typeof r!=="object")r={};if(n===null||typeof n!=="object")n={};for(o in n)if(o in r)e[o]=h(r[o],n[o]);else t[o]=n[o];return function(a){for(o in e)t[o]=e[o](a);return t}}function h(r,n){var e=typeof n,t;return n==null||e==="boolean"?Sr(n):(e==="number"?Be:e==="string"?(t=zt(n))?(n=t,zn):Tr:n instanceof zt?zn:n instanceof Date?w:B(n)?N:Array.isArray(n)?P:typeof n.valueOf!=="function"&&typeof n.toString!=="function"||isNaN(n)?k:Be)(r,n)}function A(r,n){return r=+r,n=+n,function(e){return Math.round(r*(1-e)+n*e)}}function R(r){return Math.max(0,-Mt(Math.abs(r)))}function S(r,n){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Mt(n)/3)))*3-Mt(Math.abs(r)))}function j(r,n){return r=Math.abs(r),n=Math.abs(n)-r,Math.max(0,Mt(n)-Mt(r))+1}function F(r){return function(){return r}}function q(r){return+r}var C=[0,1];function d(r){return r}function D(r,n){return(n-=r=+r)?function(e){return(e-r)/n}:F(isNaN(n)?NaN:0.5)}function J(r,n){var e;if(r>n)e=r,r=n,n=e;return function(t){return Math.max(r,Math.min(n,t))}}function K(r,n,e){var t=r[0],o=r[1],a=n[0],u=n[1];if(o<t)t=D(o,t),a=e(u,a);else t=D(t,o),a=e(a,u);return function(f){return a(t(f))}}function Q(r,n,e){var t=Math.min(r.length,n.length)-1,o=Array(t),a=Array(t),u=-1;if(r[t]<r[0])r=r.slice().reverse(),n=n.slice().reverse();while(++u<t)o[u]=D(r[u],r[u+1]),a[u]=e(n[u],n[u+1]);return function(f){var c=z(r,f,1,t)-1;return a[c](o[c](f))}}function ua(r,n){return n.domain(r.domain()).range(r.range()).interpolate(r.interpolate()).clamp(r.clamp()).unknown(r.unknown())}function U(){var r=C,n=C,e=h,t,o,a,u=d,f,c,i;function p(){var m=Math.min(r.length,n.length);if(u!==d)u=J(r[0],r[m-1]);return f=m>2?Q:K,c=i=null,l}function l(m){return m==null||isNaN(m=+m)?a:(c||(c=f(r.map(t),n,e)))(t(u(m)))}return l.invert=function(m){return u(o((i||(i=f(n,r.map(t),Be)))(m)))},l.domain=function(m){return arguments.length?(r=Array.from(m,q),p()):r.slice()},l.range=function(m){return arguments.length?(n=Array.from(m),p()):n.slice()},l.rangeRound=function(m){return n=Array.from(m),e=A,p()},l.clamp=function(m){return arguments.length?(u=m?!0:d,p()):u!==d},l.interpolate=function(m){return arguments.length?(e=m,p()):e},l.unknown=function(m){return arguments.length?(a=m,l):a},function(m,L){return t=m,o=L,p()}}function Ur(){return U()(d,d)}function I(r,n,e,t){var o=zr(r,n,e),a;switch(t=gn(t==null?",f":t),t.type){case"s":{var u=Math.max(Math.abs(r),Math.abs(n));if(t.precision==null&&!isNaN(a=S(o,u)))t.precision=a;return da(t,u)}case"":case"e":case"g":case"p":case"r":{if(t.precision==null&&!isNaN(a=j(o,Math.max(Math.abs(r),Math.abs(n)))))t.precision=a-(t.type==="e");break}case"f":case"%":{if(t.precision==null&&!isNaN(a=R(o)))t.precision=a-(t.type==="%")*2;break}}return Pt(t)}function W(r){var n=r.domain;return r.ticks=function(e){var t=n();return v(t[0],t[t.length-1],e==null?10:e)},r.tickFormat=function(e,t){var o=n();return I(o[0],o[o.length-1],e==null?10:e,t)},r.nice=function(e){if(e==null)e=10;var t=n(),o=0,a=t.length-1,u=t[o],f=t[a],c,i,p=10;if(f<u)i=u,u=f,f=i,i=o,o=a,a=i;while(p-- >0){if(i=M(u,f,e),i===c)return t[o]=u,t[a]=f,n(t);else if(i>0)u=Math.floor(u/i)*i,f=Math.ceil(f/i)*i;else if(i<0)u=Math.ceil(u*i)/i,f=Math.floor(f*i)/i;else break;c=i}return r},r}function kt(){var r=Ur();return r.copy=function(){return ua(r,kt())},Ot.apply(r,arguments),W(r)}
|
|
2
2
|
export{sr,zr,ua,Ur,kt};
|
package/web/index.html
CHANGED
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
<link rel="icon" href="./icon-1wgy7kzy.svg" type="image/svg+xml" />
|
|
16
16
|
<link rel="apple-touch-icon" href="./apple-touch-icon-7dkm33qp.png" />
|
|
17
17
|
|
|
18
|
-
<link rel="stylesheet" crossorigin href="./chunk-5z2n4z9x.css"><script type="module" crossorigin src="./chunk-
|
|
18
|
+
<link rel="stylesheet" crossorigin href="./chunk-5z2n4z9x.css"><script type="module" crossorigin src="./chunk-ngt1j8py.js"></script></head>
|
|
19
19
|
<body>
|
|
20
20
|
<div id="root"></div>
|
|
21
21
|
|
package/web/chunk-08sq3cwm.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Ni}from"./chunk-60axh4sa.js";export{Ni as createArchitectureServices};
|
package/web/chunk-24fjnnee.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Ii}from"./chunk-60axh4sa.js";export{Ii as createPieServices};
|
package/web/chunk-2j2atyjw.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Ei}from"./chunk-60axh4sa.js";export{Ei as createCynefinServices};
|
package/web/chunk-3h3g3ca3.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Mi}from"./chunk-60axh4sa.js";export{Mi as createEventModelingServices};
|
package/web/chunk-3pcrxg6m.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Di}from"./chunk-60axh4sa.js";export{Di as createTreeViewServices};
|
package/web/chunk-814kkkmq.js
DELETED
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import{t}from"./chunk-veam6vk4.js";import"./chunk-79e08rk1.js";import{Pi,Oi}from"./chunk-ddyyc20r.js";import"./chunk-5v2c0aqk.js";import"./chunk-avxk6jpc.js";import"./chunk-rrpn5r5w.js";import"./chunk-7qkav30b.js";var o=t((r)=>`${Pi(r)}
|
|
2
|
-
.swimlane.cluster:not([data-color-id]) rect {
|
|
3
|
-
stroke: ${r.clusterBorder} !important;
|
|
4
|
-
}
|
|
5
|
-
[data-look="neo"].cluster rect {
|
|
6
|
-
filter: none;
|
|
7
|
-
}
|
|
8
|
-
`,"getStyles"),m=o,D=Oi({styles:m});export{D as diagram};
|
package/web/chunk-8w8atrdh.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Si}from"./chunk-60axh4sa.js";export{Si as createTreemapServices};
|
package/web/chunk-942g3eqn.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{ir}from"./chunk-60axh4sa.js";export{ir as createRailroadAbnfServices};
|
package/web/chunk-avxk6jpc.js
DELETED
package/web/chunk-fmthkpff.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{ct}from"./chunk-30b33r2w.js";export{ct as default};
|
package/web/chunk-gv99c8zv.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{ao,Do,io,No,Mo,oo}from"./chunk-9fnr00kv.js";import"./chunk-zb2bkr7f.js";import"./chunk-kcjz03h5.js";import"./chunk-veam6vk4.js";export{Do as applyDagreLayoutResult,ao as getEdgesToRender,No as measureDagreLayout,io as prepareLayoutForDagre,oo as render,Mo as runDagreLayoutCore};
|
package/web/chunk-h0767tjv.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{ar}from"./chunk-60axh4sa.js";export{ar as createRailroadEbnfServices};
|
package/web/chunk-hqynf99g.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{Ti}from"./chunk-60axh4sa.js";export{Ti as createWardleyServices};
|