@softistx/pulsarix-widget 0.8.5 → 0.10.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (135) hide show
  1. package/README.md +76 -48
  2. package/dist/chunks/{abnfDiagram-XWFEHMT6.b9yk4x5x.js → abnfDiagram-XWFEHMT6.rxx9wyp3.js} +1 -1
  3. package/dist/chunks/architecture-WOLXFQ4H.hwrxbct0.js +1 -0
  4. package/dist/chunks/architectureDiagram-CSQXQB3N.mrm0pgc0.js +36 -0
  5. package/dist/chunks/{blockDiagram-BEDRHYPZ.bb08b9nt.js → blockDiagram-BEDRHYPZ.f4dfpk7e.js} +11 -11
  6. package/dist/chunks/{c4Diagram-M2UUVUY5.px0epccd.js → c4Diagram-M2UUVUY5.rz43j1my.js} +3 -3
  7. package/dist/chunks/{chat-markdown-CrbWbK1O.k4nmgyey.js → chat-markdown-BSu4FB_l.xgn4yj83.js} +29 -29
  8. package/dist/chunks/{classDiagram-v2-KXABOMEV.f02387t9.js → classDiagram-v2-KXABOMEV.m96cfcad.js} +8 -8
  9. package/dist/chunks/cose-bilkent-JH36ORCC.zz2rwyw6.js +1 -0
  10. package/dist/chunks/cynefin-EF2NZ3EQ.y29bn1cz.js +1 -0
  11. package/dist/chunks/{cynefinDiagram-NJNITYFG.zt7gprt1.js → cynefinDiagram-NJNITYFG.az2k68wq.js} +1 -1
  12. package/dist/chunks/{dagre-KIHZ2IZ3.702bqbr9.js → dagre-KIHZ2IZ3.mgwg8bc4.js} +2 -2
  13. package/dist/chunks/{diagram-7YQZDPLS.m7vf21j6.js → diagram-7YQZDPLS.x8fg6705.js} +2 -2
  14. package/dist/chunks/{diagram-QBROCOUO.33e5hv7x.js → diagram-QBROCOUO.db60dsss.js} +24 -24
  15. package/dist/chunks/{diagram-RJJCUUZO.94k74bz7.js → diagram-RJJCUUZO.a7e9w297.js} +4 -4
  16. package/dist/chunks/{diagram-WERXNKYE.7fe849z6.js → diagram-WERXNKYE.a04f53kd.js} +2 -2
  17. package/dist/chunks/diagram-YHHI257C.v19jhmrh.js +3 -0
  18. package/dist/chunks/{diagram-YR4HJLHV.310x2we2.js → diagram-YR4HJLHV.c5e87gmw.js} +1 -1
  19. package/dist/chunks/{ebnfDiagram-N527522P.a4crteq1.js → ebnfDiagram-N527522P.bjrxfgze.js} +1 -1
  20. package/dist/chunks/editor-shortcuts-dialog-Cz3T8435.5ve4nsaw.js +1 -0
  21. package/dist/chunks/editor.yak1qktd.js +4 -0
  22. package/dist/chunks/{elk-O5DQBFGD.dx61etan.js → elk-O5DQBFGD.1ydp0b7a.js} +13 -13
  23. package/dist/chunks/emoji-picker-00Bw2c2b.gzznrrz5.js +4 -0
  24. package/dist/chunks/{erDiagram-K3K3BIDK.qzqv67zm.js → erDiagram-K3K3BIDK.g171ckq1.js} +8 -8
  25. package/dist/chunks/eventmodeling-K75KTNOO.46qfxqj7.js +1 -0
  26. package/dist/chunks/{flow-diagram-AiM6FiIm.73jr19pb.js → flow-diagram-DGZOc1z1.3gbgbm5m.js} +6 -6
  27. package/dist/chunks/flowDiagram-Z6JWZHQI.f0eaj70g.js +1 -0
  28. package/dist/chunks/{ganttDiagram-3PRQTZWP.xngzb32h.js → ganttDiagram-3PRQTZWP.3b9dh4nr.js} +5 -5
  29. package/dist/chunks/gitGraph-VSP46ZUC.swware7n.js +1 -0
  30. package/dist/chunks/{gitGraphDiagram-VXDFKS5L.1sm36z2q.js → gitGraphDiagram-VXDFKS5L.thyp7vsd.js} +22 -22
  31. package/dist/chunks/{grid-E2QIVN74.76pgtn2n.js → grid-E2QIVN74.entqjpa3.js} +1 -1
  32. package/dist/chunks/illustration-BcaGDjvB.1q9xtmyq.js +1 -0
  33. package/dist/chunks/{index.r0p3fm9f.js → index.0g1t1pjx.js} +1 -1
  34. package/dist/chunks/{index.rfyzb2yv.js → index.35d4zbh8.js} +4 -4
  35. package/dist/chunks/index.5fcbba6e.js +2 -0
  36. package/dist/chunks/{index.7gxz6d1f.js → index.6pzexww5.js} +10 -10
  37. package/dist/chunks/{index.zm5x44tn.js → index.8vaktk8x.js} +1 -1
  38. package/dist/chunks/{index.dnnzjw18.js → index.8zg579vd.js} +2 -2
  39. package/dist/chunks/{index.0k4tbjhp.js → index.9n1y396a.js} +1 -1
  40. package/dist/chunks/{index.8f3x951p.js → index.a3njhfdd.js} +2 -2
  41. package/dist/chunks/{index.a6rz456z.js → index.cw97ff3b.js} +2 -2
  42. package/dist/chunks/{index.fv9af3wd.js → index.d57x7pg9.js} +6 -6
  43. package/dist/chunks/{index.fbeztcp3.js → index.g2ba0pke.js} +2 -2
  44. package/dist/chunks/index.h1xzvasx.js +2 -0
  45. package/dist/chunks/{index.hvdnkr5m.js → index.qr6a02kx.js} +2 -2
  46. package/dist/chunks/index.rkgfxpm3.js +44 -0
  47. package/dist/chunks/index.sw8gvntb.js +2 -0
  48. package/dist/chunks/{index.0e4s8r4m.js → index.v02zf4zg.js} +2 -2
  49. package/dist/chunks/{index.t34t6kpe.js → index.w1516g8q.js} +35 -35
  50. package/dist/chunks/{index.9bf5qrah.js → index.w4emtsqw.js} +2 -2
  51. package/dist/chunks/{index.nsckd1vt.js → index.yhmqh641.js} +2 -2
  52. package/dist/chunks/{index.1d7qpsyx.js → index.zkngte5k.js} +2 -2
  53. package/dist/chunks/{index.a1bxkgd3.js → index.zkx4ryzt.js} +104 -104
  54. package/dist/chunks/info-OHQRW6UA.1er9b42t.js +1 -0
  55. package/dist/chunks/{infoDiagram-EZ3ZOAHP.pfd0fjwn.js → infoDiagram-EZ3ZOAHP.833fvq8n.js} +2 -2
  56. package/dist/chunks/{ishikawaDiagram-S3EKX5GW.h5kjez1x.js → ishikawaDiagram-S3EKX5GW.q3evaw24.js} +5 -5
  57. package/dist/chunks/{journeyDiagram-POQNLL5X.55cqc9p0.js → journeyDiagram-POQNLL5X.9werrmpy.js} +5 -5
  58. package/dist/chunks/{kanban-definition-BH5XI6FM.pkdvda4y.js → kanban-definition-BH5XI6FM.f3ssda0m.js} +7 -7
  59. package/dist/chunks/markup-color-chrome-ykGNUl8y.pcgw4znz.js +1 -0
  60. package/dist/chunks/markup-custom-color-MM-HnrqY.sygnt3gs.js +1 -0
  61. package/dist/chunks/mention-list-6cR5VSPa.x0x55xzp.js +1 -0
  62. package/dist/chunks/{mermaid.core.j7s05j63.js → mermaid.core.5cqab0cw.js} +7 -7
  63. package/dist/chunks/{mindmap-definition-WVAN44T4.x3jbxvft.js → mindmap-definition-WVAN44T4.pjjxgse0.js} +6 -6
  64. package/dist/chunks/packet-JDAUHWVQ.t5jwb2rb.js +1 -0
  65. package/dist/chunks/panel.2vwd6k3h.js +7 -0
  66. package/dist/chunks/{pegDiagram-D4NLKWP3.xq15gqy9.js → pegDiagram-D4NLKWP3.mdacgbzb.js} +1 -1
  67. package/dist/chunks/pie-XZMESJXO.pe88zesw.js +1 -0
  68. package/dist/chunks/pieDiagram-36ENHN4W.fb0d6a9w.js +39 -0
  69. package/dist/chunks/plated-illustration-pTqcYOQg.6b9fm4a7.js +1 -0
  70. package/dist/chunks/{quadrantDiagram-ZQUDMS73.k28g8jpn.js → quadrantDiagram-ZQUDMS73.m5cgqatg.js} +4 -4
  71. package/dist/chunks/radar-ABXABTNO.jtbddwfq.js +1 -0
  72. package/dist/chunks/railroad-I3PHUGI6.kvyt0f9s.js +1 -0
  73. package/dist/chunks/railroad-abnf-LNEFI6M7.ybx0vspg.js +1 -0
  74. package/dist/chunks/railroad-ebnf-DWYD2UWJ.yx4c4enn.js +1 -0
  75. package/dist/chunks/railroad-peg-JR7BVNR7.mb71eyqe.js +1 -0
  76. package/dist/chunks/{railroadDiagram-JIZHGYPL.e7p2vqgg.js → railroadDiagram-JIZHGYPL.w2e1k61e.js} +1 -1
  77. package/dist/chunks/{render-VIF2ZAQL.w5ytncsg.js → render-VIF2ZAQL.exs2rt60.js} +1 -1
  78. package/dist/chunks/{requirementDiagram-AXW2TVFA.arekdz02.js → requirementDiagram-AXW2TVFA.mrxb120d.js} +4 -4
  79. package/dist/chunks/{sankeyDiagram-FBCJTAIF.1d04xcmb.js → sankeyDiagram-FBCJTAIF.csj5n1sg.js} +6 -6
  80. package/dist/chunks/{sequenceDiagram-3LA2ROMG.j4xywwp1.js → sequenceDiagram-3LA2ROMG.73qx1ab4.js} +11 -11
  81. package/dist/chunks/{sizeCapture-2Q2CQKSF.862bnf6p.js → sizeCapture-2Q2CQKSF.vfe8maj3.js} +1 -1
  82. package/dist/chunks/{stateDiagram-v2-ATKHQDJO.xvvtr0y2.js → stateDiagram-v2-ATKHQDJO.h4grfmy4.js} +8 -8
  83. package/dist/chunks/{swimlanes-YQL5WMAO.dtnjb4xt.js → swimlanes-YQL5WMAO.e2y8jam1.js} +1 -1
  84. package/dist/chunks/swimlanesDiagram-UCCPES4V.dtthssd5.js +8 -0
  85. package/dist/chunks/{timeline-definition-7Z437IG3.zfhqzc4r.js → timeline-definition-7Z437IG3.2zxa6hz5.js} +9 -9
  86. package/dist/chunks/treeView-D4JQ5SDB.3kgztv30.js +1 -0
  87. package/dist/chunks/treemap-SAJKECNS.xj47e2ae.js +1 -0
  88. package/dist/chunks/{usecaseDiagram-RDK6N6HP.ewxnyz4c.js → usecaseDiagram-RDK6N6HP.61cdyktj.js} +57 -57
  89. package/dist/chunks/{vennDiagram-SHRQU5PJ.wkzf1f00.js → vennDiagram-SHRQU5PJ.4tspw3rs.js} +7 -7
  90. package/dist/chunks/wardley-7MLQ67FV.pckbr6zr.js +1 -0
  91. package/dist/chunks/{wardleyDiagram-F3OXNVQS.srjfm4nb.js → wardleyDiagram-F3OXNVQS.q2p8tshx.js} +4 -4
  92. package/dist/chunks/{xychartDiagram-GDYJKCDI.xfa2vexk.js → xychartDiagram-GDYJKCDI.69desp9j.js} +5 -5
  93. package/dist/index.js +48 -21
  94. package/dist/react.js +74 -0
  95. package/dist/server.js +20 -0
  96. package/dist/types/config.d.ts +1 -1
  97. package/dist/types/mount.d.ts +1 -1
  98. package/dist/types/react.d.ts +27 -0
  99. package/dist/types/server.d.ts +15 -0
  100. package/docs/integration.md +109 -36
  101. package/package.json +20 -5
  102. package/dist/chunks/architecture-WOLXFQ4H.aft3rkrr.js +0 -1
  103. package/dist/chunks/architectureDiagram-CSQXQB3N.qz18rz0g.js +0 -36
  104. package/dist/chunks/cose-bilkent-JH36ORCC.azq9k24r.js +0 -1
  105. package/dist/chunks/cynefin-EF2NZ3EQ.dk039jny.js +0 -1
  106. package/dist/chunks/diagram-YHHI257C.qjjjfq7w.js +0 -3
  107. package/dist/chunks/editor-shortcuts-dialog-B0ppoiza.x3p4h07t.js +0 -1
  108. package/dist/chunks/editor.arg3zy29.js +0 -4
  109. package/dist/chunks/emoji-picker-CbvQZ2ZL.nst616hd.js +0 -4
  110. package/dist/chunks/eventmodeling-K75KTNOO.gmm1bcak.js +0 -1
  111. package/dist/chunks/flowDiagram-Z6JWZHQI.fzwqg115.js +0 -1
  112. package/dist/chunks/gitGraph-VSP46ZUC.0m8jykgw.js +0 -1
  113. package/dist/chunks/illustration-BOW28wq5.bkz28k1x.js +0 -1
  114. package/dist/chunks/index.32jxrb9b.js +0 -2
  115. package/dist/chunks/index.7k5v3p25.js +0 -2
  116. package/dist/chunks/index.e35b4yh5.js +0 -44
  117. package/dist/chunks/index.wrjdgn4c.js +0 -2
  118. package/dist/chunks/info-OHQRW6UA.e0a85drn.js +0 -1
  119. package/dist/chunks/markup-color-chrome-ykGNUl8y.0ds56d6x.js +0 -1
  120. package/dist/chunks/markup-custom-color-Dgm2hHI7.7darvajx.js +0 -1
  121. package/dist/chunks/mention-list-CkAUzPBG.mtjgmmzb.js +0 -1
  122. package/dist/chunks/packet-JDAUHWVQ.52409p3r.js +0 -1
  123. package/dist/chunks/panel.9tp7gr60.js +0 -7
  124. package/dist/chunks/pie-XZMESJXO.q5kre8cx.js +0 -1
  125. package/dist/chunks/pieDiagram-36ENHN4W.8h0wam54.js +0 -39
  126. package/dist/chunks/plated-illustration-COZYWJ81.xy7ba5mq.js +0 -1
  127. package/dist/chunks/radar-ABXABTNO.yk872k2n.js +0 -1
  128. package/dist/chunks/railroad-I3PHUGI6.9wfa6vs3.js +0 -1
  129. package/dist/chunks/railroad-abnf-LNEFI6M7.70zznk3b.js +0 -1
  130. package/dist/chunks/railroad-ebnf-DWYD2UWJ.4pvdng0p.js +0 -1
  131. package/dist/chunks/railroad-peg-JR7BVNR7.ev15ebp6.js +0 -1
  132. package/dist/chunks/swimlanesDiagram-UCCPES4V.0q8kd5qn.js +0 -8
  133. package/dist/chunks/treeView-D4JQ5SDB.3fzswdjp.js +0 -1
  134. package/dist/chunks/treemap-SAJKECNS.cgh74bhn.js +0 -1
  135. package/dist/chunks/wardley-7MLQ67FV.6q5tgt0s.js +0 -1
@@ -1,9 +1,9 @@
1
- import{e,n,Pe,q,hr,y,A,L,R,I,M,D,O,u,m,ve,he,pe,tt,z,We,Ae,_e}from"./index.a1bxkgd3.js";import{Xt}from"./index.0e4s8r4m.js";import{Xe}from"./index.dnnzjw18.js";import{Ee}from"./index.7k5v3p25.js";import{ge}from"./index.9bf5qrah.js";var et=function(){var s=e(function(K,p,f,k){for(f=f||{},k=K.length;k--;f[K[k]]=p);return f},"o"),a=[1,18],r=[1,19],l=[1,20],o=[1,41],d=[1,26],b=[1,42],h=[1,24],C=[1,25],E=[1,32],w=[1,33],J=[1,34],F=[1,45],xe=[1,35],Ie=[1,36],Oe=[1,37],we=[1,38],Me=[1,27],Ve=[1,28],Re=[1,29],Ge=[1,30],Ue=[1,31],B=[1,44],_=[1,46],S=[1,43],N=[1,47],ze=[1,9],g=[1,8,9],ce=[1,58],de=[1,59],be=[1,60],fe=[1,61],ke=[1,62],Ye=[1,63],Ke=[1,64],P=[1,8,9,41],st=[1,77],X=[1,8,9,12,13,22,39,41,44,46,68,69,70,71,72,73,74,79,81],me=[1,8,9,12,13,18,20,22,39,41,44,46,47,60,68,69,70,71,72,73,74,79,81,86,100,102,103],Ce=[13,60,86,100,102,103],Z=[13,60,73,74,86,100,102,103],it=[13,60,68,69,70,71,72,86,100,102,103],Te=[1,103],ee=[1,121],te=[1,117],se=[1,113],ie=[1,119],ae=[1,114],re=[1,115],ne=[1,116],le=[1,118],ue=[1,120],at=[22,50,60,61,82,86,87,88,89,90],rt=[1,128],ye=[12,39],Qe=[1,8,9,39,41,44,46],De=[1,8,9,22],nt=[1,153],lt=[1,8,9,61],U=[1,8,9,22,50,60,61,82,86,87,88,89,90],je={trace:e(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,classLiteralName:17,DOT:18,className:19,GENERICTYPE:20,relationStatement:21,LABEL:22,namespaceStatement:23,classStatement:24,memberStatement:25,annotationStatement:26,clickStatement:27,styleStatement:28,cssClassStatement:29,noteStatement:30,classDefStatement:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,namespaceIdentifier:38,STRUCT_START:39,classStatements:40,STRUCT_STOP:41,NAMESPACE:42,classIdentifier:43,STYLE_SEPARATOR:44,members:45,ANNOTATION_START:46,ANNOTATION_END:47,CLASS:48,emptyBody:49,SPACE:50,MEMBER:51,SEPARATOR:52,relation:53,NOTE_FOR:54,noteText:55,NOTE:56,CLASSDEF:57,classList:58,stylesOpt:59,ALPHA:60,COMMA:61,direction_tb:62,direction_bt:63,direction_rl:64,direction_lr:65,relationType:66,lineType:67,AGGREGATION:68,EXTENSION:69,COMPOSITION:70,DEPENDENCY:71,LOLLIPOP:72,LINE:73,DOTTED_LINE:74,CALLBACK:75,LINK:76,LINK_TARGET:77,CLICK:78,CALLBACK_NAME:79,CALLBACK_ARGS:80,HREF:81,STYLE:82,CSSCLASS:83,style:84,styleComponent:85,NUM:86,COLON:87,UNIT:88,BRKT:89,PCT:90,commentToken:91,textToken:92,graphCodeTokens:93,textNoTagsToken:94,TAGSTART:95,TAGEND:96,"==":97,"--":98,DEFAULT:99,MINUS:100,keywords:101,UNICODE_TEXT:102,BQUOTE_STR:103,$accept:0,$end:1},terminals_:{2:"error",7:"CLASS_DIAGRAM",8:"NEWLINE",9:"EOF",12:"SQS",13:"STR",14:"SQE",18:"DOT",20:"GENERICTYPE",22:"LABEL",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",39:"STRUCT_START",41:"STRUCT_STOP",42:"NAMESPACE",44:"STYLE_SEPARATOR",46:"ANNOTATION_START",47:"ANNOTATION_END",48:"CLASS",50:"SPACE",51:"MEMBER",52:"SEPARATOR",54:"NOTE_FOR",56:"NOTE",57:"CLASSDEF",60:"ALPHA",61:"COMMA",62:"direction_tb",63:"direction_bt",64:"direction_rl",65:"direction_lr",68:"AGGREGATION",69:"EXTENSION",70:"COMPOSITION",71:"DEPENDENCY",72:"LOLLIPOP",73:"LINE",74:"DOTTED_LINE",75:"CALLBACK",76:"LINK",77:"LINK_TARGET",78:"CLICK",79:"CALLBACK_NAME",80:"CALLBACK_ARGS",81:"HREF",82:"STYLE",83:"CSSCLASS",86:"NUM",87:"COLON",88:"UNIT",89:"BRKT",90:"PCT",93:"graphCodeTokens",95:"TAGSTART",96:"TAGEND",97:"==",98:"--",99:"DEFAULT",100:"MINUS",101:"keywords",102:"UNICODE_TEXT",103:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,1],[15,3],[15,2],[19,1],[19,3],[19,1],[19,2],[19,2],[19,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[23,4],[23,5],[38,2],[38,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[24,1],[24,3],[24,4],[24,3],[24,6],[24,4],[24,7],[24,6],[43,2],[43,3],[49,0],[49,2],[49,2],[26,4],[45,1],[45,2],[25,1],[25,2],[25,1],[25,1],[21,3],[21,4],[21,4],[21,5],[30,3],[30,2],[31,3],[58,1],[58,3],[32,1],[32,1],[32,1],[32,1],[53,3],[53,2],[53,2],[53,1],[66,1],[66,1],[66,1],[66,1],[66,1],[67,1],[67,1],[27,3],[27,4],[27,3],[27,4],[27,4],[27,5],[27,3],[27,4],[27,4],[27,5],[27,4],[27,5],[27,5],[27,6],[28,3],[29,3],[59,1],[59,3],[84,1],[84,2],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[91,1],[91,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[94,1],[94,1],[94,1],[94,1],[16,1],[16,1],[16,1],[16,1],[17,1],[55,1]],performAction:e(function(p,f,k,c,T,t,oe){var i=t.length-1;switch(T){case 8:this.$=t[i-1];break;case 9:case 10:case 13:case 15:this.$=t[i];break;case 11:case 14:this.$=t[i-2]+"."+t[i];break;case 12:case 16:this.$=t[i-1]+t[i];break;case 17:case 18:this.$=t[i-1]+"~"+t[i]+"~";break;case 19:c.addRelation(t[i]);break;case 20:t[i-1].title=c.cleanupLabel(t[i]),c.addRelation(t[i-1]);break;case 31:this.$=t[i].trim(),c.setAccTitle(this.$);break;case 32:case 33:this.$=t[i].trim(),c.setAccDescription(this.$);break;case 34:c.addClassesToNamespace(t[i-3],t[i-1][0],t[i-1][1]),c.popNamespace();break;case 35:c.addClassesToNamespace(t[i-4],t[i-1][0],t[i-1][1]),c.popNamespace();break;case 36:this.$=c.addNamespace(t[i]);break;case 37:this.$=c.addNamespace(t[i-1],t[i]);break;case 38:this.$=[[t[i]],[]];break;case 39:this.$=[[t[i-1]],[]];break;case 40:t[i][0].unshift(t[i-2]),this.$=t[i];break;case 41:this.$=[[],[t[i]]];break;case 42:this.$=[[],[t[i-1]]];break;case 43:t[i][1].unshift(t[i-2]),this.$=t[i];break;case 44:case 45:this.$=[[],[]];break;case 46:this.$=t[i];break;case 48:c.setCssClass(t[i-2],t[i]);break;case 49:c.addMembers(t[i-3],t[i-1]);break;case 51:c.setCssClass(t[i-5],t[i-3]),c.addMembers(t[i-5],t[i-1]);break;case 52:c.addAnnotation(t[i-3],t[i-1]);break;case 53:c.addAnnotation(t[i-6],t[i-4]),c.addMembers(t[i-6],t[i-1]);break;case 54:c.addAnnotation(t[i-5],t[i-3]);break;case 55:this.$=t[i],c.addClass(t[i]);break;case 56:this.$=t[i-1],c.addClass(t[i-1]),c.setClassLabel(t[i-1],t[i]);break;case 60:c.addAnnotation(t[i],t[i-2]);break;case 61:case 74:this.$=[t[i]];break;case 62:t[i].push(t[i-1]),this.$=t[i];break;case 63:break;case 64:c.addMember(t[i-1],c.cleanupLabel(t[i]));break;case 65:break;case 66:break;case 67:this.$={id1:t[i-2],id2:t[i],relation:t[i-1],relationTitle1:"none",relationTitle2:"none"};break;case 68:this.$={id1:t[i-3],id2:t[i],relation:t[i-1],relationTitle1:t[i-2],relationTitle2:"none"};break;case 69:this.$={id1:t[i-3],id2:t[i],relation:t[i-2],relationTitle1:"none",relationTitle2:t[i-1]};break;case 70:this.$={id1:t[i-4],id2:t[i],relation:t[i-2],relationTitle1:t[i-3],relationTitle2:t[i-1]};break;case 71:this.$=c.addNote(t[i],t[i-1]);break;case 72:this.$=c.addNote(t[i]);break;case 73:this.$=t[i-2],c.defineClass(t[i-1],t[i]);break;case 75:this.$=t[i-2].concat([t[i]]);break;case 76:c.setDirection("TB");break;case 77:c.setDirection("BT");break;case 78:c.setDirection("RL");break;case 79:c.setDirection("LR");break;case 80:this.$={type1:t[i-2],type2:t[i],lineType:t[i-1]};break;case 81:this.$={type1:"none",type2:t[i],lineType:t[i-1]};break;case 82:this.$={type1:t[i-1],type2:"none",lineType:t[i]};break;case 83:this.$={type1:"none",type2:"none",lineType:t[i]};break;case 84:this.$=c.relationType.AGGREGATION;break;case 85:this.$=c.relationType.EXTENSION;break;case 86:this.$=c.relationType.COMPOSITION;break;case 87:this.$=c.relationType.DEPENDENCY;break;case 88:this.$=c.relationType.LOLLIPOP;break;case 89:this.$=c.lineType.LINE;break;case 90:this.$=c.lineType.DOTTED_LINE;break;case 91:case 97:this.$=t[i-2],c.setClickEvent(t[i-1],t[i]);break;case 92:case 98:this.$=t[i-3],c.setClickEvent(t[i-2],t[i-1]),c.setTooltip(t[i-2],t[i]);break;case 93:this.$=t[i-2],c.setLink(t[i-1],t[i]);break;case 94:this.$=t[i-3],c.setLink(t[i-2],t[i-1],t[i]);break;case 95:this.$=t[i-3],c.setLink(t[i-2],t[i-1]),c.setTooltip(t[i-2],t[i]);break;case 96:this.$=t[i-4],c.setLink(t[i-3],t[i-2],t[i]),c.setTooltip(t[i-3],t[i-1]);break;case 99:this.$=t[i-3],c.setClickEvent(t[i-2],t[i-1],t[i]);break;case 100:this.$=t[i-4],c.setClickEvent(t[i-3],t[i-2],t[i-1]),c.setTooltip(t[i-3],t[i]);break;case 101:this.$=t[i-3],c.setLink(t[i-2],t[i]);break;case 102:this.$=t[i-4],c.setLink(t[i-3],t[i-1],t[i]);break;case 103:this.$=t[i-4],c.setLink(t[i-3],t[i-1]),c.setTooltip(t[i-3],t[i]);break;case 104:this.$=t[i-5],c.setLink(t[i-4],t[i-2],t[i]),c.setTooltip(t[i-4],t[i-1]);break;case 105:this.$=t[i-2],c.setCssStyle(t[i-1],t[i]);break;case 106:c.setCssClass(t[i-1],t[i]);break;case 107:this.$=[t[i]];break;case 108:t[i-2].push(t[i]),this.$=t[i-2];break;case 110:this.$=t[i-1]+t[i];break}},"anonymous"),table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:a,35:r,37:l,38:22,42:o,43:23,46:d,48:b,51:h,52:C,54:E,56:w,57:J,60:F,62:xe,63:Ie,64:Oe,65:we,75:Me,76:Ve,78:Re,82:Ge,83:Ue,86:B,100:_,102:S,103:N},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},s(ze,[2,5],{8:[1,48]}),{8:[1,49]},s(g,[2,19],{22:[1,50]}),s(g,[2,21]),s(g,[2,22]),s(g,[2,23]),s(g,[2,24]),s(g,[2,25]),s(g,[2,26]),s(g,[2,27]),s(g,[2,28]),s(g,[2,29]),s(g,[2,30]),{34:[1,51]},{36:[1,52]},s(g,[2,33]),s(g,[2,63],{53:53,66:56,67:57,13:[1,54],22:[1,55],68:ce,69:de,70:be,71:fe,72:ke,73:Ye,74:Ke}),{39:[1,65]},s(P,[2,47],{39:[1,67],44:[1,66],46:[1,68]}),s(g,[2,65]),s(g,[2,66]),{16:69,60:F,86:B,100:_,102:S},{16:39,17:40,19:70,60:F,86:B,100:_,102:S,103:N},{16:39,17:40,19:71,60:F,86:B,100:_,102:S,103:N},{16:39,17:40,19:72,60:F,86:B,100:_,102:S,103:N},{60:[1,73]},{13:[1,74]},{16:39,17:40,19:75,60:F,86:B,100:_,102:S,103:N},{13:st,55:76},{58:78,60:[1,79]},s(g,[2,76]),s(g,[2,77]),s(g,[2,78]),s(g,[2,79]),s(X,[2,13],{16:39,17:40,19:81,18:[1,80],20:[1,82],60:F,86:B,100:_,102:S,103:N}),s(X,[2,15],{20:[1,83]}),{15:84,16:85,17:86,60:F,86:B,100:_,102:S,103:N},{16:39,17:40,19:87,60:F,86:B,100:_,102:S,103:N},s(me,[2,133]),s(me,[2,134]),s(me,[2,135]),s(me,[2,136]),s([1,8,9,12,13,20,22,39,41,44,46,68,69,70,71,72,73,74,79,81],[2,137]),s(ze,[2,6],{10:5,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,19:21,38:22,43:23,16:39,17:40,5:88,33:a,35:r,37:l,42:o,46:d,48:b,51:h,52:C,54:E,56:w,57:J,60:F,62:xe,63:Ie,64:Oe,65:we,75:Me,76:Ve,78:Re,82:Ge,83:Ue,86:B,100:_,102:S,103:N}),{5:89,10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:a,35:r,37:l,38:22,42:o,43:23,46:d,48:b,51:h,52:C,54:E,56:w,57:J,60:F,62:xe,63:Ie,64:Oe,65:we,75:Me,76:Ve,78:Re,82:Ge,83:Ue,86:B,100:_,102:S,103:N},s(g,[2,20]),s(g,[2,31]),s(g,[2,32]),{13:[1,91],16:39,17:40,19:90,60:F,86:B,100:_,102:S,103:N},{53:92,66:56,67:57,68:ce,69:de,70:be,71:fe,72:ke,73:Ye,74:Ke},s(g,[2,64]),{67:93,73:Ye,74:Ke},s(Ce,[2,83],{66:94,68:ce,69:de,70:be,71:fe,72:ke}),s(Z,[2,84]),s(Z,[2,85]),s(Z,[2,86]),s(Z,[2,87]),s(Z,[2,88]),s(it,[2,89]),s(it,[2,90]),{8:[1,96],23:99,24:97,30:98,38:22,40:95,42:o,43:23,48:b,54:E,56:w},{16:100,60:F,86:B,100:_,102:S},{41:[1,102],45:101,51:Te},{16:104,60:F,86:B,100:_,102:S},{47:[1,105]},{13:[1,106]},{13:[1,107]},{79:[1,108],81:[1,109]},{22:ee,50:te,59:110,60:se,82:ie,84:111,85:112,86:ae,87:re,88:ne,89:le,90:ue},{60:[1,122]},{13:st,55:123},s(P,[2,72]),s(P,[2,138]),{22:ee,50:te,59:124,60:se,61:[1,125],82:ie,84:111,85:112,86:ae,87:re,88:ne,89:le,90:ue},s(at,[2,74]),{16:39,17:40,19:126,60:F,86:B,100:_,102:S,103:N},s(X,[2,16]),s(X,[2,17]),s(X,[2,18]),{11:127,12:rt,39:[2,36]},s(ye,[2,9],{16:85,17:86,15:130,18:[1,129],60:F,86:B,100:_,102:S,103:N}),s(ye,[2,10]),s(Qe,[2,55],{11:131,12:rt}),s(ze,[2,7]),{9:[1,132]},s(De,[2,67]),{16:39,17:40,19:133,60:F,86:B,100:_,102:S,103:N},{13:[1,135],16:39,17:40,19:134,60:F,86:B,100:_,102:S,103:N},s(Ce,[2,82],{66:136,68:ce,69:de,70:be,71:fe,72:ke}),s(Ce,[2,81]),{41:[1,137]},{23:99,24:97,30:98,38:22,40:138,42:o,43:23,48:b,54:E,56:w},{8:[1,139],41:[2,38]},{8:[1,140],41:[2,41]},{8:[1,141],41:[2,44]},s(P,[2,48],{39:[1,142]}),{41:[1,143]},s(P,[2,50]),{41:[2,61],45:144,51:Te},{47:[1,145]},{16:39,17:40,19:146,60:F,86:B,100:_,102:S,103:N},s(g,[2,91],{13:[1,147]}),s(g,[2,93],{13:[1,149],77:[1,148]}),s(g,[2,97],{13:[1,150],80:[1,151]}),{13:[1,152]},s(g,[2,105],{61:nt}),s(lt,[2,107],{85:154,22:ee,50:te,60:se,82:ie,86:ae,87:re,88:ne,89:le,90:ue}),s(U,[2,109]),s(U,[2,111]),s(U,[2,112]),s(U,[2,113]),s(U,[2,114]),s(U,[2,115]),s(U,[2,116]),s(U,[2,117]),s(U,[2,118]),s(U,[2,119]),s(g,[2,106]),s(P,[2,71]),s(g,[2,73],{61:nt}),{60:[1,155]},s(X,[2,14]),{39:[2,37]},{13:[1,156]},{15:157,16:85,17:86,60:F,86:B,100:_,102:S,103:N},s(ye,[2,12]),s(Qe,[2,56]),{1:[2,4]},s(De,[2,69]),s(De,[2,68]),{16:39,17:40,19:158,60:F,86:B,100:_,102:S,103:N},s(Ce,[2,80]),s(P,[2,34]),{41:[1,159]},{23:99,24:97,30:98,38:22,40:160,41:[2,39],42:o,43:23,48:b,54:E,56:w},{23:99,24:97,30:98,38:22,40:161,41:[2,42],42:o,43:23,48:b,54:E,56:w},{23:99,24:97,30:98,38:22,40:162,41:[2,45],42:o,43:23,48:b,54:E,56:w},{45:163,51:Te},s(P,[2,49]),{41:[2,62]},s(P,[2,52],{39:[1,164]}),s(g,[2,60]),s(g,[2,92]),s(g,[2,94]),s(g,[2,95],{77:[1,165]}),s(g,[2,98]),s(g,[2,99],{13:[1,166]}),s(g,[2,101],{13:[1,168],77:[1,167]}),{22:ee,50:te,60:se,82:ie,84:169,85:112,86:ae,87:re,88:ne,89:le,90:ue},s(U,[2,110]),s(at,[2,75]),{14:[1,170]},s(ye,[2,11]),s(De,[2,70]),s(P,[2,35]),{41:[2,40]},{41:[2,43]},{41:[2,46]},{41:[1,171]},{41:[1,173],45:172,51:Te},s(g,[2,96]),s(g,[2,100]),s(g,[2,102]),s(g,[2,103],{77:[1,174]}),s(lt,[2,108],{85:154,22:ee,50:te,60:se,82:ie,86:ae,87:re,88:ne,89:le,90:ue}),s(Qe,[2,8]),s(P,[2,51]),{41:[1,175]},s(P,[2,54]),s(g,[2,104]),s(P,[2,53])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],127:[2,37],132:[2,4],144:[2,62],160:[2,40],161:[2,43],162:[2,46]},parseError:e(function(p,f){if(f.recoverable)this.trace(p);else{var k=Error(p);throw k.hash=f,k}},"parseError"),parse:e(function(p){var f=this,k=[0],c=[],T=[null],t=[],oe=this.table,i="",Be=0,ut=0,ot=0,kt=2,ct=1,mt=t.slice.call(arguments,1),x=Object.create(this.lexer),W={yy:{}};for(var He in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,He))W.yy[He]=this.yy[He];if(x.setInput(p,W.yy),W.yy.lexer=x,W.yy.parser=this,typeof x.yylloc>"u")x.yylloc={};var qe=x.yylloc;t.push(qe);var gt=x.options&&x.options.ranges;if(typeof W.yy.parseError==="function")this.parseError=W.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function Ct(G){k.length=k.length-2*G,T.length=T.length-G,t.length=t.length-G}e(Ct,"popStack");function ht(){var G=c.pop()||x.lex()||ct;if(typeof G!=="number"){if(G instanceof Array)c=G,G=c.pop();G=f.symbols_[G]||G}return G}e(ht,"lex");var v,Je,Q,V,Lt,Ze,H={},Se,Y,dt,Ne;while(!0){if(Q=k[k.length-1],this.defaultActions[Q])V=this.defaultActions[Q];else{if(v===null||typeof v>"u")v=ht();V=oe[Q]&&oe[Q][v]}if(typeof V>"u"||!V.length||!V[0]){var $e="";Ne=[];for(Se in oe[Q])if(this.terminals_[Se]&&Se>kt)Ne.push("'"+this.terminals_[Se]+"'");if(x.showPosition)$e="Parse error on line "+(Be+1)+`:
1
+ import{e,n,Oe,q,fr,y,A,L,R,I,M,P,O,u,p,ge,de,fe,Je,F,Ve,Se,Ee}from"./index.zkx4ryzt.js";import{Kt}from"./index.v02zf4zg.js";import{Ye}from"./index.8zg579vd.js";import{Ce}from"./index.5fcbba6e.js";import{pe}from"./index.w4emtsqw.js";var tt=function(){var s=e(function(K,b,k,m){for(k=k||{},m=K.length;m--;k[K[m]]=b);return k},"o"),a=[1,18],r=[1,19],l=[1,20],o=[1,41],d=[1,26],f=[1,42],h=[1,24],C=[1,25],E=[1,32],w=[1,33],J=[1,34],D=[1,45],ve=[1,35],Ie=[1,36],we=[1,37],Me=[1,38],Pe=[1,27],Re=[1,28],Ge=[1,29],Ue=[1,30],ze=[1,31],B=[1,44],_=[1,46],S=[1,43],N=[1,47],Ke=[1,9],g=[1,8,9],ce=[1,58],he=[1,59],Ae=[1,60],be=[1,61],ke=[1,62],We=[1,63],Qe=[1,64],V=[1,8,9,41],st=[1,77],X=[1,8,9,12,13,22,39,41,44,46,68,69,70,71,72,73,74,79,81],me=[1,8,9,12,13,18,20,22,39,41,44,46,47,60,68,69,70,71,72,73,74,79,81,86,100,102,103],Te=[13,60,86,100,102,103],Z=[13,60,73,74,86,100,102,103],it=[13,60,68,69,70,71,72,86,100,102,103],ye=[1,103],ee=[1,121],te=[1,117],se=[1,113],ie=[1,119],ae=[1,114],re=[1,115],ne=[1,116],le=[1,118],ue=[1,120],at=[22,50,60,61,82,86,87,88,89,90],rt=[1,128],De=[12,39],je=[1,8,9,39,41,44,46],Fe=[1,8,9,22],nt=[1,153],lt=[1,8,9,61],z=[1,8,9,22,50,60,61,82,86,87,88,89,90],Xe={trace:e(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mermaidDoc:4,statements:5,graphConfig:6,CLASS_DIAGRAM:7,NEWLINE:8,EOF:9,statement:10,classLabel:11,SQS:12,STR:13,SQE:14,namespaceName:15,alphaNumToken:16,classLiteralName:17,DOT:18,className:19,GENERICTYPE:20,relationStatement:21,LABEL:22,namespaceStatement:23,classStatement:24,memberStatement:25,annotationStatement:26,clickStatement:27,styleStatement:28,cssClassStatement:29,noteStatement:30,classDefStatement:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,namespaceIdentifier:38,STRUCT_START:39,classStatements:40,STRUCT_STOP:41,NAMESPACE:42,classIdentifier:43,STYLE_SEPARATOR:44,members:45,ANNOTATION_START:46,ANNOTATION_END:47,CLASS:48,emptyBody:49,SPACE:50,MEMBER:51,SEPARATOR:52,relation:53,NOTE_FOR:54,noteText:55,NOTE:56,CLASSDEF:57,classList:58,stylesOpt:59,ALPHA:60,COMMA:61,direction_tb:62,direction_bt:63,direction_rl:64,direction_lr:65,relationType:66,lineType:67,AGGREGATION:68,EXTENSION:69,COMPOSITION:70,DEPENDENCY:71,LOLLIPOP:72,LINE:73,DOTTED_LINE:74,CALLBACK:75,LINK:76,LINK_TARGET:77,CLICK:78,CALLBACK_NAME:79,CALLBACK_ARGS:80,HREF:81,STYLE:82,CSSCLASS:83,style:84,styleComponent:85,NUM:86,COLON:87,UNIT:88,BRKT:89,PCT:90,commentToken:91,textToken:92,graphCodeTokens:93,textNoTagsToken:94,TAGSTART:95,TAGEND:96,"==":97,"--":98,DEFAULT:99,MINUS:100,keywords:101,UNICODE_TEXT:102,BQUOTE_STR:103,$accept:0,$end:1},terminals_:{2:"error",7:"CLASS_DIAGRAM",8:"NEWLINE",9:"EOF",12:"SQS",13:"STR",14:"SQE",18:"DOT",20:"GENERICTYPE",22:"LABEL",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",39:"STRUCT_START",41:"STRUCT_STOP",42:"NAMESPACE",44:"STYLE_SEPARATOR",46:"ANNOTATION_START",47:"ANNOTATION_END",48:"CLASS",50:"SPACE",51:"MEMBER",52:"SEPARATOR",54:"NOTE_FOR",56:"NOTE",57:"CLASSDEF",60:"ALPHA",61:"COMMA",62:"direction_tb",63:"direction_bt",64:"direction_rl",65:"direction_lr",68:"AGGREGATION",69:"EXTENSION",70:"COMPOSITION",71:"DEPENDENCY",72:"LOLLIPOP",73:"LINE",74:"DOTTED_LINE",75:"CALLBACK",76:"LINK",77:"LINK_TARGET",78:"CLICK",79:"CALLBACK_NAME",80:"CALLBACK_ARGS",81:"HREF",82:"STYLE",83:"CSSCLASS",86:"NUM",87:"COLON",88:"UNIT",89:"BRKT",90:"PCT",93:"graphCodeTokens",95:"TAGSTART",96:"TAGEND",97:"==",98:"--",99:"DEFAULT",100:"MINUS",101:"keywords",102:"UNICODE_TEXT",103:"BQUOTE_STR"},productions_:[0,[3,1],[3,1],[4,1],[6,4],[5,1],[5,2],[5,3],[11,3],[15,1],[15,1],[15,3],[15,2],[19,1],[19,3],[19,1],[19,2],[19,2],[19,2],[10,1],[10,2],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,1],[10,2],[10,2],[10,1],[23,4],[23,5],[38,2],[38,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[40,1],[40,2],[40,3],[24,1],[24,3],[24,4],[24,3],[24,6],[24,4],[24,7],[24,6],[43,2],[43,3],[49,0],[49,2],[49,2],[26,4],[45,1],[45,2],[25,1],[25,2],[25,1],[25,1],[21,3],[21,4],[21,4],[21,5],[30,3],[30,2],[31,3],[58,1],[58,3],[32,1],[32,1],[32,1],[32,1],[53,3],[53,2],[53,2],[53,1],[66,1],[66,1],[66,1],[66,1],[66,1],[67,1],[67,1],[27,3],[27,4],[27,3],[27,4],[27,4],[27,5],[27,3],[27,4],[27,4],[27,5],[27,4],[27,5],[27,5],[27,6],[28,3],[29,3],[59,1],[59,3],[84,1],[84,2],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[85,1],[91,1],[91,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[92,1],[94,1],[94,1],[94,1],[94,1],[16,1],[16,1],[16,1],[16,1],[17,1],[55,1]],performAction:e(function(b,k,m,c,T,t,oe){var i=t.length-1;switch(T){case 8:this.$=t[i-1];break;case 9:case 10:case 13:case 15:this.$=t[i];break;case 11:case 14:this.$=t[i-2]+"."+t[i];break;case 12:case 16:this.$=t[i-1]+t[i];break;case 17:case 18:this.$=t[i-1]+"~"+t[i]+"~";break;case 19:c.addRelation(t[i]);break;case 20:t[i-1].title=c.cleanupLabel(t[i]),c.addRelation(t[i-1]);break;case 31:this.$=t[i].trim(),c.setAccTitle(this.$);break;case 32:case 33:this.$=t[i].trim(),c.setAccDescription(this.$);break;case 34:c.addClassesToNamespace(t[i-3],t[i-1][0],t[i-1][1]),c.popNamespace();break;case 35:c.addClassesToNamespace(t[i-4],t[i-1][0],t[i-1][1]),c.popNamespace();break;case 36:this.$=c.addNamespace(t[i]);break;case 37:this.$=c.addNamespace(t[i-1],t[i]);break;case 38:this.$=[[t[i]],[]];break;case 39:this.$=[[t[i-1]],[]];break;case 40:t[i][0].unshift(t[i-2]),this.$=t[i];break;case 41:this.$=[[],[t[i]]];break;case 42:this.$=[[],[t[i-1]]];break;case 43:t[i][1].unshift(t[i-2]),this.$=t[i];break;case 44:case 45:this.$=[[],[]];break;case 46:this.$=t[i];break;case 48:c.setCssClass(t[i-2],t[i]);break;case 49:c.addMembers(t[i-3],t[i-1]);break;case 51:c.setCssClass(t[i-5],t[i-3]),c.addMembers(t[i-5],t[i-1]);break;case 52:c.addAnnotation(t[i-3],t[i-1]);break;case 53:c.addAnnotation(t[i-6],t[i-4]),c.addMembers(t[i-6],t[i-1]);break;case 54:c.addAnnotation(t[i-5],t[i-3]);break;case 55:this.$=t[i],c.addClass(t[i]);break;case 56:this.$=t[i-1],c.addClass(t[i-1]),c.setClassLabel(t[i-1],t[i]);break;case 60:c.addAnnotation(t[i],t[i-2]);break;case 61:case 74:this.$=[t[i]];break;case 62:t[i].push(t[i-1]),this.$=t[i];break;case 63:break;case 64:c.addMember(t[i-1],c.cleanupLabel(t[i]));break;case 65:break;case 66:break;case 67:this.$={id1:t[i-2],id2:t[i],relation:t[i-1],relationTitle1:"none",relationTitle2:"none"};break;case 68:this.$={id1:t[i-3],id2:t[i],relation:t[i-1],relationTitle1:t[i-2],relationTitle2:"none"};break;case 69:this.$={id1:t[i-3],id2:t[i],relation:t[i-2],relationTitle1:"none",relationTitle2:t[i-1]};break;case 70:this.$={id1:t[i-4],id2:t[i],relation:t[i-2],relationTitle1:t[i-3],relationTitle2:t[i-1]};break;case 71:this.$=c.addNote(t[i],t[i-1]);break;case 72:this.$=c.addNote(t[i]);break;case 73:this.$=t[i-2],c.defineClass(t[i-1],t[i]);break;case 75:this.$=t[i-2].concat([t[i]]);break;case 76:c.setDirection("TB");break;case 77:c.setDirection("BT");break;case 78:c.setDirection("RL");break;case 79:c.setDirection("LR");break;case 80:this.$={type1:t[i-2],type2:t[i],lineType:t[i-1]};break;case 81:this.$={type1:"none",type2:t[i],lineType:t[i-1]};break;case 82:this.$={type1:t[i-1],type2:"none",lineType:t[i]};break;case 83:this.$={type1:"none",type2:"none",lineType:t[i]};break;case 84:this.$=c.relationType.AGGREGATION;break;case 85:this.$=c.relationType.EXTENSION;break;case 86:this.$=c.relationType.COMPOSITION;break;case 87:this.$=c.relationType.DEPENDENCY;break;case 88:this.$=c.relationType.LOLLIPOP;break;case 89:this.$=c.lineType.LINE;break;case 90:this.$=c.lineType.DOTTED_LINE;break;case 91:case 97:this.$=t[i-2],c.setClickEvent(t[i-1],t[i]);break;case 92:case 98:this.$=t[i-3],c.setClickEvent(t[i-2],t[i-1]),c.setTooltip(t[i-2],t[i]);break;case 93:this.$=t[i-2],c.setLink(t[i-1],t[i]);break;case 94:this.$=t[i-3],c.setLink(t[i-2],t[i-1],t[i]);break;case 95:this.$=t[i-3],c.setLink(t[i-2],t[i-1]),c.setTooltip(t[i-2],t[i]);break;case 96:this.$=t[i-4],c.setLink(t[i-3],t[i-2],t[i]),c.setTooltip(t[i-3],t[i-1]);break;case 99:this.$=t[i-3],c.setClickEvent(t[i-2],t[i-1],t[i]);break;case 100:this.$=t[i-4],c.setClickEvent(t[i-3],t[i-2],t[i-1]),c.setTooltip(t[i-3],t[i]);break;case 101:this.$=t[i-3],c.setLink(t[i-2],t[i]);break;case 102:this.$=t[i-4],c.setLink(t[i-3],t[i-1],t[i]);break;case 103:this.$=t[i-4],c.setLink(t[i-3],t[i-1]),c.setTooltip(t[i-3],t[i]);break;case 104:this.$=t[i-5],c.setLink(t[i-4],t[i-2],t[i]),c.setTooltip(t[i-4],t[i-1]);break;case 105:this.$=t[i-2],c.setCssStyle(t[i-1],t[i]);break;case 106:c.setCssClass(t[i-1],t[i]);break;case 107:this.$=[t[i]];break;case 108:t[i-2].push(t[i]),this.$=t[i-2];break;case 110:this.$=t[i-1]+t[i];break}},"anonymous"),table:[{3:1,4:2,5:3,6:4,7:[1,6],10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:a,35:r,37:l,38:22,42:o,43:23,46:d,48:f,51:h,52:C,54:E,56:w,57:J,60:D,62:ve,63:Ie,64:we,65:Me,75:Pe,76:Re,78:Ge,82:Ue,83:ze,86:B,100:_,102:S,103:N},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},s(Ke,[2,5],{8:[1,48]}),{8:[1,49]},s(g,[2,19],{22:[1,50]}),s(g,[2,21]),s(g,[2,22]),s(g,[2,23]),s(g,[2,24]),s(g,[2,25]),s(g,[2,26]),s(g,[2,27]),s(g,[2,28]),s(g,[2,29]),s(g,[2,30]),{34:[1,51]},{36:[1,52]},s(g,[2,33]),s(g,[2,63],{53:53,66:56,67:57,13:[1,54],22:[1,55],68:ce,69:he,70:Ae,71:be,72:ke,73:We,74:Qe}),{39:[1,65]},s(V,[2,47],{39:[1,67],44:[1,66],46:[1,68]}),s(g,[2,65]),s(g,[2,66]),{16:69,60:D,86:B,100:_,102:S},{16:39,17:40,19:70,60:D,86:B,100:_,102:S,103:N},{16:39,17:40,19:71,60:D,86:B,100:_,102:S,103:N},{16:39,17:40,19:72,60:D,86:B,100:_,102:S,103:N},{60:[1,73]},{13:[1,74]},{16:39,17:40,19:75,60:D,86:B,100:_,102:S,103:N},{13:st,55:76},{58:78,60:[1,79]},s(g,[2,76]),s(g,[2,77]),s(g,[2,78]),s(g,[2,79]),s(X,[2,13],{16:39,17:40,19:81,18:[1,80],20:[1,82],60:D,86:B,100:_,102:S,103:N}),s(X,[2,15],{20:[1,83]}),{15:84,16:85,17:86,60:D,86:B,100:_,102:S,103:N},{16:39,17:40,19:87,60:D,86:B,100:_,102:S,103:N},s(me,[2,133]),s(me,[2,134]),s(me,[2,135]),s(me,[2,136]),s([1,8,9,12,13,20,22,39,41,44,46,68,69,70,71,72,73,74,79,81],[2,137]),s(Ke,[2,6],{10:5,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,19:21,38:22,43:23,16:39,17:40,5:88,33:a,35:r,37:l,42:o,46:d,48:f,51:h,52:C,54:E,56:w,57:J,60:D,62:ve,63:Ie,64:we,65:Me,75:Pe,76:Re,78:Ge,82:Ue,83:ze,86:B,100:_,102:S,103:N}),{5:89,10:5,16:39,17:40,19:21,21:7,23:8,24:9,25:10,26:11,27:12,28:13,29:14,30:15,31:16,32:17,33:a,35:r,37:l,38:22,42:o,43:23,46:d,48:f,51:h,52:C,54:E,56:w,57:J,60:D,62:ve,63:Ie,64:we,65:Me,75:Pe,76:Re,78:Ge,82:Ue,83:ze,86:B,100:_,102:S,103:N},s(g,[2,20]),s(g,[2,31]),s(g,[2,32]),{13:[1,91],16:39,17:40,19:90,60:D,86:B,100:_,102:S,103:N},{53:92,66:56,67:57,68:ce,69:he,70:Ae,71:be,72:ke,73:We,74:Qe},s(g,[2,64]),{67:93,73:We,74:Qe},s(Te,[2,83],{66:94,68:ce,69:he,70:Ae,71:be,72:ke}),s(Z,[2,84]),s(Z,[2,85]),s(Z,[2,86]),s(Z,[2,87]),s(Z,[2,88]),s(it,[2,89]),s(it,[2,90]),{8:[1,96],23:99,24:97,30:98,38:22,40:95,42:o,43:23,48:f,54:E,56:w},{16:100,60:D,86:B,100:_,102:S},{41:[1,102],45:101,51:ye},{16:104,60:D,86:B,100:_,102:S},{47:[1,105]},{13:[1,106]},{13:[1,107]},{79:[1,108],81:[1,109]},{22:ee,50:te,59:110,60:se,82:ie,84:111,85:112,86:ae,87:re,88:ne,89:le,90:ue},{60:[1,122]},{13:st,55:123},s(V,[2,72]),s(V,[2,138]),{22:ee,50:te,59:124,60:se,61:[1,125],82:ie,84:111,85:112,86:ae,87:re,88:ne,89:le,90:ue},s(at,[2,74]),{16:39,17:40,19:126,60:D,86:B,100:_,102:S,103:N},s(X,[2,16]),s(X,[2,17]),s(X,[2,18]),{11:127,12:rt,39:[2,36]},s(De,[2,9],{16:85,17:86,15:130,18:[1,129],60:D,86:B,100:_,102:S,103:N}),s(De,[2,10]),s(je,[2,55],{11:131,12:rt}),s(Ke,[2,7]),{9:[1,132]},s(Fe,[2,67]),{16:39,17:40,19:133,60:D,86:B,100:_,102:S,103:N},{13:[1,135],16:39,17:40,19:134,60:D,86:B,100:_,102:S,103:N},s(Te,[2,82],{66:136,68:ce,69:he,70:Ae,71:be,72:ke}),s(Te,[2,81]),{41:[1,137]},{23:99,24:97,30:98,38:22,40:138,42:o,43:23,48:f,54:E,56:w},{8:[1,139],41:[2,38]},{8:[1,140],41:[2,41]},{8:[1,141],41:[2,44]},s(V,[2,48],{39:[1,142]}),{41:[1,143]},s(V,[2,50]),{41:[2,61],45:144,51:ye},{47:[1,145]},{16:39,17:40,19:146,60:D,86:B,100:_,102:S,103:N},s(g,[2,91],{13:[1,147]}),s(g,[2,93],{13:[1,149],77:[1,148]}),s(g,[2,97],{13:[1,150],80:[1,151]}),{13:[1,152]},s(g,[2,105],{61:nt}),s(lt,[2,107],{85:154,22:ee,50:te,60:se,82:ie,86:ae,87:re,88:ne,89:le,90:ue}),s(z,[2,109]),s(z,[2,111]),s(z,[2,112]),s(z,[2,113]),s(z,[2,114]),s(z,[2,115]),s(z,[2,116]),s(z,[2,117]),s(z,[2,118]),s(z,[2,119]),s(g,[2,106]),s(V,[2,71]),s(g,[2,73],{61:nt}),{60:[1,155]},s(X,[2,14]),{39:[2,37]},{13:[1,156]},{15:157,16:85,17:86,60:D,86:B,100:_,102:S,103:N},s(De,[2,12]),s(je,[2,56]),{1:[2,4]},s(Fe,[2,69]),s(Fe,[2,68]),{16:39,17:40,19:158,60:D,86:B,100:_,102:S,103:N},s(Te,[2,80]),s(V,[2,34]),{41:[1,159]},{23:99,24:97,30:98,38:22,40:160,41:[2,39],42:o,43:23,48:f,54:E,56:w},{23:99,24:97,30:98,38:22,40:161,41:[2,42],42:o,43:23,48:f,54:E,56:w},{23:99,24:97,30:98,38:22,40:162,41:[2,45],42:o,43:23,48:f,54:E,56:w},{45:163,51:ye},s(V,[2,49]),{41:[2,62]},s(V,[2,52],{39:[1,164]}),s(g,[2,60]),s(g,[2,92]),s(g,[2,94]),s(g,[2,95],{77:[1,165]}),s(g,[2,98]),s(g,[2,99],{13:[1,166]}),s(g,[2,101],{13:[1,168],77:[1,167]}),{22:ee,50:te,60:se,82:ie,84:169,85:112,86:ae,87:re,88:ne,89:le,90:ue},s(z,[2,110]),s(at,[2,75]),{14:[1,170]},s(De,[2,11]),s(Fe,[2,70]),s(V,[2,35]),{41:[2,40]},{41:[2,43]},{41:[2,46]},{41:[1,171]},{41:[1,173],45:172,51:ye},s(g,[2,96]),s(g,[2,100]),s(g,[2,102]),s(g,[2,103],{77:[1,174]}),s(lt,[2,108],{85:154,22:ee,50:te,60:se,82:ie,86:ae,87:re,88:ne,89:le,90:ue}),s(je,[2,8]),s(V,[2,51]),{41:[1,175]},s(V,[2,54]),s(g,[2,104]),s(V,[2,53])],defaultActions:{2:[2,1],3:[2,2],4:[2,3],127:[2,37],132:[2,4],144:[2,62],160:[2,40],161:[2,43],162:[2,46]},parseError:e(function(b,k){if(k.recoverable)this.trace(b);else{var m=Error(b);throw m.hash=k,m}},"parseError"),parse:e(function(b){var k=this,m=[0],c=[],T=[null],t=[],oe=this.table,i="",_e=0,ut=0,ot=0,kt=2,ct=1,mt=t.slice.call(arguments,1),x=Object.create(this.lexer),W={yy:{}};for(var He in this.yy)if(Object.prototype.hasOwnProperty.call(this.yy,He))W.yy[He]=this.yy[He];if(x.setInput(b,W.yy),W.yy.lexer=x,W.yy.parser=this,typeof x.yylloc>"u")x.yylloc={};var qe=x.yylloc;t.push(qe);var gt=x.options&&x.options.ranges;if(typeof W.yy.parseError==="function")this.parseError=W.yy.parseError;else this.parseError=Object.getPrototypeOf(this).parseError;function Ct(U){m.length=m.length-2*U,T.length=T.length-U,t.length=t.length-U}e(Ct,"popStack");function ht(){var U=c.pop()||x.lex()||ct;if(typeof U!=="number"){if(U instanceof Array)c=U,U=c.pop();U=k.symbols_[U]||U}return U}e(ht,"lex");var v,Ze,Q,G,Lt,$e,H={},Ne,Y,dt,Le;while(!0){if(Q=m[m.length-1],this.defaultActions[Q])G=this.defaultActions[Q];else{if(v===null||typeof v>"u")v=ht();G=oe[Q]&&oe[Q][v]}if(typeof G>"u"||!G.length||!G[0]){var et="";Le=[];for(Ne in oe[Q])if(this.terminals_[Ne]&&Ne>kt)Le.push("'"+this.terminals_[Ne]+"'");if(x.showPosition)et="Parse error on line "+(_e+1)+`:
2
2
  `+x.showPosition()+`
3
- Expecting `+Ne.join(", ")+", got '"+(this.terminals_[v]||v)+"'";else $e="Parse error on line "+(Be+1)+": Unexpected "+(v==ct?"end of input":"'"+(this.terminals_[v]||v)+"'");this.parseError($e,{text:x.match,token:this.terminals_[v]||v,line:x.yylineno,loc:qe,expected:Ne})}if(V[0]instanceof Array&&V.length>1)throw Error("Parse Error: multiple actions possible at state: "+Q+", token: "+v);switch(V[0]){case 1:if(k.push(v),T.push(x.yytext),t.push(x.yylloc),k.push(V[1]),v=null,!Je){if(ut=x.yyleng,i=x.yytext,Be=x.yylineno,qe=x.yylloc,ot>0)ot--}else v=Je,Je=null;break;case 2:if(Y=this.productions_[V[1]][1],H.$=T[T.length-Y],H._$={first_line:t[t.length-(Y||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(Y||1)].first_column,last_column:t[t.length-1].last_column},gt)H._$.range=[t[t.length-(Y||1)].range[0],t[t.length-1].range[1]];if(Ze=this.performAction.apply(H,[i,ut,Be,W.yy,V[1],T,t].concat(mt)),typeof Ze<"u")return Ze;if(Y)k=k.slice(0,-1*Y*2),T=T.slice(0,-1*Y),t=t.slice(0,-1*Y);k.push(this.productions_[V[1]][0]),T.push(H.$),t.push(H._$),dt=oe[k[k.length-2]][k[k.length-1]],k.push(dt);break;case 3:return!0}}return!0},"parse")},ft=function(){var K={EOF:1,parseError:e(function(f,k){if(this.yy.parser)this.yy.parser.parseError(f,k);else throw Error(f)},"parseError"),setInput:e(function(p,f){if(this.yy=f||this.yy||{},this._input=p,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:e(function(){var p=this._input[0];this.yytext+=p,this.yyleng++,this.offset++,this.match+=p,this.matched+=p;var f=p.match(/(?:\r\n?|\n).*/g);if(f)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),p},"input"),unput:e(function(p){var f=p.length,k=p.split(/(?:\r\n?|\n)/g);this._input=p+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-f),this.offset-=f;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),k.length-1)this.yylineno-=k.length-1;var T=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===c.length?this.yylloc.first_column:0)+c[c.length-k.length].length-k[0].length:this.yylloc.first_column-f},this.options.ranges)this.yylloc.range=[T[0],T[0]+this.yyleng-f];return this.yyleng=this.yytext.length,this},"unput"),more:e(function(){return this._more=!0,this},"more"),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
- `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:e(function(p){this.unput(this.match.slice(p))},"less"),pastInput:e(function(){var p=this.matched.substr(0,this.matched.length-this.match.length);return(p.length>20?"...":"")+p.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:e(function(){var p=this.match;if(p.length<20)p+=this._input.substr(0,20-p.length);return(p.substr(0,20)+(p.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:e(function(){var p=this.pastInput(),f=Array(p.length+1).join("-");return p+this.upcomingInput()+`
5
- `+f+"^"},"showPosition"),test_match:e(function(p,f){var k,c,T;if(this.options.backtrack_lexer){if(T={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)T.yylloc.range=this.yylloc.range.slice(0)}if(c=p[0].match(/(?:\r\n?|\n).*/g),c)this.yylineno+=c.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:c?c[c.length-1].length-c[c.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+p[0].length},this.yytext+=p[0],this.match+=p[0],this.matches=p,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(p[0].length),this.matched+=p[0],k=this.performAction.call(this,this.yy,this,f,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(k)return k;else if(this._backtrack){for(var t in T)this[t]=T[t];return!1}return!1},"test_match"),next:e(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var p,f,k,c;if(!this._more)this.yytext="",this.match="";var T=this._currentRules();for(var t=0;t<T.length;t++)if(k=this._input.match(this.rules[T[t]]),k&&(!f||k[0].length>f[0].length)){if(f=k,c=t,this.options.backtrack_lexer)if(p=this.test_match(k,T[t]),p!==!1)return p;else if(this._backtrack){f=!1;continue}else return!1;else if(!this.options.flex)break}if(f){if(p=this.test_match(f,T[c]),p!==!1)return p;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
- `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var f=this.next();if(f)return f;else return this.lex()},"lex"),begin:e(function(f){this.conditionStack.push(f)},"begin"),popState:e(function(){var f=this.conditionStack.length-1;if(f>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:e(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:e(function(f){if(f=this.conditionStack.length-1-Math.abs(f||0),f>=0)return this.conditionStack[f];else return"INITIAL"},"topState"),pushState:e(function(f){this.begin(f)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:e(function(f,k,c,T){var t=T;switch(c){case 0:return 62;case 1:return 63;case 2:return 64;case 3:return 65;case 4:break;case 5:break;case 6:return this.begin("acc_title"),33;break;case 7:return this.popState(),"acc_title_value";break;case 8:return this.begin("acc_descr"),35;break;case 9:return this.popState(),"acc_descr_value";break;case 10:this.begin("acc_descr_multiline");break;case 11:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:return 8;case 14:break;case 15:return 7;case 16:return 7;case 17:return"EDGE_STATE";case 18:this.begin("callback_name");break;case 19:this.popState();break;case 20:this.popState(),this.begin("callback_args");break;case 21:return 79;case 22:this.popState();break;case 23:return 80;case 24:this.popState();break;case 25:return"STR";case 26:this.begin("string");break;case 27:return 82;case 28:return 57;case 29:return this.begin("namespace"),42;break;case 30:return this.popState(),8;break;case 31:break;case 32:return this.begin("namespace-body"),39;break;case 33:this.popState(),this.less(0);break;case 34:return this.popState(),41;break;case 35:return"EOF_IN_STRUCT";case 36:return 8;case 37:break;case 38:return"EDGE_STATE";case 39:return this.begin("class"),48;break;case 40:return this.popState(),8;break;case 41:break;case 42:return this.popState(),this.popState(),41;break;case 43:return this.begin("class-body"),39;break;case 44:return this.popState(),41;break;case 45:return"EOF_IN_STRUCT";case 46:return"EDGE_STATE";case 47:return"OPEN_IN_STRUCT";case 48:break;case 49:return"MEMBER";case 50:return 83;case 51:return 75;case 52:return 76;case 53:return 78;case 54:return 54;case 55:return 56;case 56:return 46;case 57:return 47;case 58:return 81;case 59:this.popState();break;case 60:return"GENERICTYPE";case 61:this.begin("generic");break;case 62:this.popState();break;case 63:return"BQUOTE_STR";case 64:this.begin("bqstring");break;case 65:return 77;case 66:return 77;case 67:return 77;case 68:return 77;case 69:return 69;case 70:return 69;case 71:return 71;case 72:return 71;case 73:return 70;case 74:return 68;case 75:return 72;case 76:return 73;case 77:return 74;case 78:return 22;case 79:return 44;case 80:return 100;case 81:return 18;case 82:return"PLUS";case 83:return 87;case 84:return 61;case 85:return 89;case 86:return 89;case 87:return 90;case 88:return"EQUALS";case 89:return"EQUALS";case 90:return 60;case 91:return 12;case 92:return 14;case 93:return"PUNCTUATION";case 94:return 86;case 95:return 102;case 96:return 50;case 97:return 50;case 98:return 9}},"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:\[\*\])/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:["])/,/^(?:[^"]*)/,/^(?:["])/,/^(?:style\b)/,/^(?:classDef\b)/,/^(?:namespace\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[{])/,/^(?:[}])/,/^(?:[}])/,/^(?:$)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:\[\*\])/,/^(?:class\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[}])/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\[\*\])/,/^(?:[{])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:note for\b)/,/^(?:note\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:href\b)/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:~)/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:[`])/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:\s*\(\))/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?::)/,/^(?:,)/,/^(?:#)/,/^(?:#)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:\[)/,/^(?:\])/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:\s)/,/^(?:$)/],conditions:{"namespace-body":{rules:[26,29,34,35,36,37,38,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},namespace:{rules:[26,29,30,31,32,33,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},"class-body":{rules:[26,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},class:{rules:[26,40,41,42,43,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr_multiline:{rules:[11,12,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr:{rules:[9,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_title:{rules:[7,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_args:{rules:[22,23,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_name:{rules:[19,20,21,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},href:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},struct:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},generic:{rules:[26,50,51,52,53,54,55,56,57,58,59,60,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},bqstring:{rules:[26,50,51,52,53,54,55,56,57,58,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},string:{rules:[24,25,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,26,27,28,29,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98],inclusive:!0}}};return K}();je.lexer=ft;function Fe(){this.yy={}}return e(Fe,"Parser"),Fe.prototype=je,je.Parser=Fe,new Fe}();et.parser=et;var Et=et,pt=["#","+","~","-",""],At=class{static{e(this,"ClassMember")}constructor(s,a){this.memberType=a,this.visibility="",this.classifier="",this.text="";let r=q(s,u());this.parseMember(r)}getDisplayDetails(){let s=this.visibility+hr(this.id);if(this.memberType==="method"){if(s+=`(${hr(this.parameters.trim())})`,this.returnType)s+=" : "+hr(this.returnType)}s=s.trim();let a=this.parseClassifier();return{displayText:s,cssStyle:a}}parseMember(s){let a="";if(this.memberType==="method"){let o=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(s);if(o){let d=o[1]?o[1].trim():"";if(pt.includes(d))this.visibility=d;if(this.id=o[2],this.parameters=o[3]?o[3].trim():"",a=o[4]?o[4].trim():"",this.returnType=o[5]?o[5].trim():"",a===""){let b=this.returnType.substring(this.returnType.length-1);if(/[$*]/.exec(b))a=b,this.returnType=this.returnType.substring(0,this.returnType.length-1)}}}else{let l=s.length,o=s.substring(0,1),d=s.substring(l-1);if(pt.includes(o))this.visibility=o;if(/[$*]/.exec(d))a=d;this.id=s.substring(this.visibility===""?0:1,a===""?l:l-1)}this.classifier=a,this.id=this.id.startsWith(" ")?" "+this.id.trim():this.id.trim();let r=`${this.visibility?"\\"+this.visibility:""}${hr(this.id)}${this.memberType==="method"?`(${hr(this.parameters)})${this.returnType?" : "+hr(this.returnType):""}`:""}`;if(this.text=r.replaceAll("<","&lt;").replaceAll(">","&gt;"),this.text.startsWith("\\&lt;"))this.text=this.text.replace("\\&lt;","~")}parseClassifier(){switch(this.classifier){case"*":return"font-style:italic;";case"$":return"text-decoration:underline;";default:return""}}},Le="classId-",bt=0,j=e((s)=>y.sanitizeText(s,u()),"sanitizeText"),Tt=class s{constructor(){this.relations=[],this.classes=new Map,this.styleClasses=new Map,this.notes=new Map,this.interfaces=[],this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId="",this.functions=[],this.lineType={LINE:0,DOTTED_LINE:1},this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3,LOLLIPOP:4},this.setupToolTips=e((a)=>{let r=Xt();m(a).select("svg").selectAll("g").filter(function(){return m(this).attr("title")!==null}).on("mouseover",(d)=>{let b=m(d.currentTarget),h=b.attr("title");if(!h)return;let C=d.currentTarget.getBoundingClientRect();r.transition().duration(200).style("opacity",".9"),r.html(Pe.sanitize(h)).style("left",`${window.scrollX+C.left+C.width/2}px`).style("top",`${window.scrollY+C.bottom+4}px`),b.classed("hover",!0)}).on("mouseout",(d)=>{r.transition().duration(500).style("opacity",0),m(d.currentTarget).classed("hover",!1)})},"setupToolTips"),this.direction="TB",this.setAccTitle=L,this.getAccTitle=R,this.setAccDescription=I,this.getAccDescription=M,this.setDiagramTitle=D,this.getDiagramTitle=O,this.getConfig=e(()=>u().class,"getConfig"),this.functions.push(this.setupToolTips.bind(this)),this.clear(),this.addRelation=this.addRelation.bind(this),this.addClassesToNamespace=this.addClassesToNamespace.bind(this),this.addNamespace=this.addNamespace.bind(this),this.popNamespace=this.popNamespace.bind(this),this.setCssClass=this.setCssClass.bind(this),this.addMembers=this.addMembers.bind(this),this.addClass=this.addClass.bind(this),this.setClassLabel=this.setClassLabel.bind(this),this.addAnnotation=this.addAnnotation.bind(this),this.addMember=this.addMember.bind(this),this.cleanupLabel=this.cleanupLabel.bind(this),this.addNote=this.addNote.bind(this),this.defineClass=this.defineClass.bind(this),this.setDirection=this.setDirection.bind(this),this.setLink=this.setLink.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.clear=this.clear.bind(this),this.setTooltip=this.setTooltip.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setCssStyle=this.setCssStyle.bind(this)}static{e(this,"ClassDB")}splitClassNameAndType(a){let r=y.sanitizeText(a,u()),l="",o=r;if(r.indexOf("~")>0){let d=r.split("~");o=j(d[0]),l=j(d[1])}return{className:o,type:l}}setClassLabel(a,r){let l=y.sanitizeText(a,u());if(r)r=j(r);let{className:o}=this.splitClassNameAndType(l);this.classes.get(o).label=r,this.classes.get(o).text=`${r}${this.classes.get(o).type?`<${this.classes.get(o).type}>`:""}`}addClass(a){let r=y.sanitizeText(a,u()),{className:l,type:o}=this.splitClassNameAndType(r);if(this.classes.has(l))return;let d=y.sanitizeText(l,u());this.classes.set(d,{id:d,type:o,label:d,text:`${d}${o?`&lt;${o}&gt;`:""}`,shape:"classBox",cssClasses:"default",methods:[],members:[],annotations:[],styles:[],domId:Le+d+"-"+bt}),bt++}addInterface(a,r){let l={id:`interface${this.interfaces.length}`,label:a,classId:r};this.interfaces.push(l)}setDiagramId(a){this.diagramId=a}lookUpDomId(a){let r=y.sanitizeText(a,u());if(this.classes.has(r)){let l=this.classes.get(r).domId;return this.diagramId?`${this.diagramId}-${l}`:l}throw Error("Class not found: "+r)}clear(){this.relations=[],this.classes=new Map,this.notes=new Map,this.interfaces=[],this.functions=[],this.functions.push(this.setupToolTips.bind(this)),this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId="",this.direction="TB",A()}getClass(a){return this.classes.get(a)}getClasses(){return this.classes}getRelations(){return this.relations}getNote(a){let r=typeof a==="number"?`note${a}`:a;return this.notes.get(r)}getNotes(){return this.notes}addRelation(a){n.debug("Adding relation: "+JSON.stringify(a));let r=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];if(a.relation.type1===this.relationType.LOLLIPOP&&!r.includes(a.relation.type2))this.addClass(a.id2),this.addInterface(a.id1,a.id2),a.id1=`interface${this.interfaces.length-1}`;else if(a.relation.type2===this.relationType.LOLLIPOP&&!r.includes(a.relation.type1))this.addClass(a.id1),this.addInterface(a.id2,a.id1),a.id2=`interface${this.interfaces.length-1}`;else this.addClass(a.id1),this.addClass(a.id2);a.id1=this.splitClassNameAndType(a.id1).className,a.id2=this.splitClassNameAndType(a.id2).className,a.relationTitle1=y.sanitizeText(a.relationTitle1.trim(),u()),a.relationTitle2=y.sanitizeText(a.relationTitle2.trim(),u()),this.relations.push(a)}addAnnotation(a,r){let l=this.splitClassNameAndType(a).className;this.classes.get(l).annotations.push(r)}addMember(a,r){this.addClass(a);let l=this.splitClassNameAndType(a).className,o=this.classes.get(l);if(typeof r==="string"){let d=r.trim();if(d.startsWith("<<")&&d.endsWith(">>"))o.annotations.push(j(d.substring(2,d.length-2)));else if(d.indexOf(")")>0)o.methods.push(new At(d,"method"));else if(d)o.members.push(new At(d,"attribute"))}}addMembers(a,r){if(Array.isArray(r))r.reverse(),r.forEach((l)=>this.addMember(a,l))}addNote(a,r){let l=this.notes.size,o={id:`note${l}`,class:r,text:a,index:l};return this.notes.set(o.id,o),o.id}cleanupLabel(a){if(a.startsWith(":"))a=a.substring(1);return j(a.trim())}setCssClass(a,r){a.split(",").forEach((l)=>{let o=l;if(/\d/.exec(l[0]))o=Le+o;o=this.splitClassNameAndType(o).className;let d=this.classes.get(o);if(d)d.cssClasses+=" "+r})}defineClass(a,r){for(let l of a){let o=this.styleClasses.get(l);if(o===void 0)o={id:l,styles:[],textStyles:[]},this.styleClasses.set(l,o);if(r)r.forEach((d)=>{if(/color/.exec(d)){let b=d.replace("fill","bgFill");o.textStyles.push(b)}o.styles.push(d)});this.classes.forEach((d)=>{if(d.cssClasses.includes(l))d.styles.push(...r.flatMap((b)=>b.split(",")))})}}setTooltip(a,r){a.split(",").forEach((l)=>{if(r!==void 0){let o=this.splitClassNameAndType(l).className,d=this.classes.get(o);if(d)d.tooltip=j(r)}})}getTooltip(a,r){if(r&&this.namespaces.has(r))return this.namespaces.get(r).classes.get(a).tooltip;return this.classes.get(a).tooltip}setLink(a,r,l){let o=u();a.split(",").forEach((d)=>{let b=d;if(/\d/.exec(d[0]))b=Le+b;b=this.splitClassNameAndType(b).className;let h=this.classes.get(b);if(h)if(h.link=z.formatUrl(r,o),o.securityLevel==="sandbox")h.linkTarget="_top";else if(typeof l==="string")h.linkTarget=j(l);else h.linkTarget="_blank"}),this.setCssClass(a,"clickable")}setClickEvent(a,r,l){a.split(",").forEach((o)=>{this.setClickFunc(o,r,l);let d=this.splitClassNameAndType(o).className,b=this.classes.get(d);if(b)b.haveCallback=!0}),this.setCssClass(a,"clickable")}setClickFunc(a,r,l){let o=y.sanitizeText(a,u());if(u().securityLevel!=="loose")return;if(r===void 0)return;let b=this.splitClassNameAndType(o).className;if(this.classes.has(b)){let h=[];if(typeof l==="string"){h=l.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let C=0;C<h.length;C++){let E=h[C].trim();if(E.startsWith('"')&&E.endsWith('"'))E=E.substr(1,E.length-2);h[C]=E}}if(h.length===0)h.push(b);this.functions.push(()=>{let C=this.lookUpDomId(b),E=document.querySelector(`[id="${C}"]`);if(E!==null)E.addEventListener("click",()=>{z.runFunc(r,...h)},!1)})}}bindFunctions(a){this.functions.forEach((r)=>{r(a)})}escapeHtml(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}getDirection(){return this.direction}setDirection(a){this.direction=a}static resolveQualifiedId(a,r){let l=r.at(-1);return l?`${l}.${a}`:a}static getAncestorIds(a){let r=a.split("."),l=Array(r.length);l[0]=r[0];for(let o=1;o<r.length;o++)l[o]=`${l[o-1]}.${r[o]}`;return l}createNamespaceNode(a,r,l,o=!1){return{id:a,label:r,classes:new Map,notes:new Map,children:new Map,domId:Le+a+"-"+this.namespaceCounter++,parent:l,explicit:o}}linkParentChild(a,r){let l=this.namespaces.get(a),o=this.namespaces.get(r);if(!l||!o)return;if(!l.children.has(r))l.children.set(r,o);o.parent??=a}addNamespace(a,r){let l=s.resolveQualifiedId(a,this.namespaceStack);if(this.namespaceStack.push(l),this.namespaces.has(l)){let b=this.namespaces.get(l);if(b.explicit=!0,r)b.label=r;return l}let o=l.split("."),d=s.getAncestorIds(l);for(let b=0;b<d.length;b++){let h=d[b],C=b>0?d[b-1]:void 0,E=b===d.length-1,w=E&&r?r:o[b];if(!this.namespaces.has(h))this.namespaces.set(h,this.createNamespaceNode(h,w,C,E));else if(E)this.namespaces.get(h).explicit=!0;if(C)this.linkParentChild(C,h)}return l}popNamespace(){this.namespaceStack.pop()}getNamespace(a){return this.namespaces.get(a)}getNamespaces(){return this.namespaces}addClassesToNamespace(a,r,l){if(!this.namespaces.has(a))return;for(let o of r){let{className:d}=this.splitClassNameAndType(o),b=this.getClass(d);b.parent=a,this.namespaces.get(a).classes.set(d,b)}for(let o of l){let d=this.getNote(o);d.parent=a,this.namespaces.get(a).notes.set(o,d)}}setCssStyle(a,r){let l=this.classes.get(a);if(!r||!l)return;for(let o of r)if(o.includes(","))l.styles.push(...o.split(","));else l.styles.push(o)}getArrowMarker(a){let r;switch(a){case 0:r="aggregation";break;case 1:r="extension";break;case 2:r="composition";break;case 3:r="dependency";break;case 4:r="lollipop";break;default:r="none"}return r}resolveExplicitAncestor(a){let r=a;while(r){let l=this.namespaces.get(r);if(!l)return;if(l.explicit)return r;r=l.parent}return}getData(){let a=[],r=[],l=u(),o=l.class?.hierarchicalNamespaces??!0;for(let h of this.namespaces.values()){if(!o&&!h.explicit)continue;let C={id:h.id,label:o?h.label:h.id,isGroup:!0,padding:l.class.padding??16,shape:"rect",cssStyles:[],look:l.look,parentId:o?h.parent:void 0};a.push(C)}let d=0;for(let h of this.classes.values()){let C=o?h.parent:this.resolveExplicitAncestor(h.parent),E={...h,type:void 0,isGroup:!1,parentId:C,look:l.look,colorIndex:d++};a.push(E)}for(let h of this.notes.values()){let C=o?h.parent:this.resolveExplicitAncestor(h.parent),E={id:h.id,label:h.text,isGroup:!1,shape:"note",padding:l.class.padding??6,cssStyles:["text-align: left","white-space: nowrap",`fill: ${l.themeVariables.noteBkgColor}`,`stroke: ${l.themeVariables.noteBorderColor}`],look:l.look,parentId:C,labelType:"markdown"};a.push(E);let w=this.classes.get(h.class)?.id;if(w){let J={id:`edgeNote${h.index}`,start:h.id,end:w,type:"normal",thickness:"normal",classes:"relation",arrowTypeStart:"none",arrowTypeEnd:"none",arrowheadStyle:"",labelStyle:[""],style:["fill: none"],pattern:"dotted",look:l.look};r.push(J)}}for(let h of this.interfaces){let C={id:h.id,label:h.label,isGroup:!1,shape:"rect",cssStyles:["opacity: 0;"],look:l.look};a.push(C)}let b=0;for(let h of this.relations){b++;let C={id:We(h.id1,h.id2,{prefix:"id",counter:b}),start:h.id1,end:h.id2,type:"normal",label:h.title,labelpos:"c",thickness:"normal",classes:"relation",arrowTypeStart:this.getArrowMarker(h.relation.type1),arrowTypeEnd:this.getArrowMarker(h.relation.type2),startLabelRight:h.relationTitle1==="none"?"":h.relationTitle1,endLabelLeft:h.relationTitle2==="none"?"":h.relationTitle2,arrowheadStyle:"",labelStyle:["display: inline-block"],style:h.style||"",pattern:h.relation.lineType==1?"dashed":"solid",look:l.look,labelType:"markdown"};r.push(C)}return{nodes:a,edges:r,other:{},config:l,direction:this.getDirection()}}},yt=e((s)=>{let{theme:a,bkgColorArray:r,borderColorArray:l}=s;if(!he(a,l))return"";let o=pe(s.look),d=ve(r),b="";for(let h=0;h<tt(s.THEME_COLOR_LIMIT,l);h++){let C=l[h%l.length];b+=`
3
+ Expecting `+Le.join(", ")+", got '"+(this.terminals_[v]||v)+"'";else et="Parse error on line "+(_e+1)+": Unexpected "+(v==ct?"end of input":"'"+(this.terminals_[v]||v)+"'");this.parseError(et,{text:x.match,token:this.terminals_[v]||v,line:x.yylineno,loc:qe,expected:Le})}if(G[0]instanceof Array&&G.length>1)throw Error("Parse Error: multiple actions possible at state: "+Q+", token: "+v);switch(G[0]){case 1:if(m.push(v),T.push(x.yytext),t.push(x.yylloc),m.push(G[1]),v=null,!Ze){if(ut=x.yyleng,i=x.yytext,_e=x.yylineno,qe=x.yylloc,ot>0)ot--}else v=Ze,Ze=null;break;case 2:if(Y=this.productions_[G[1]][1],H.$=T[T.length-Y],H._$={first_line:t[t.length-(Y||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(Y||1)].first_column,last_column:t[t.length-1].last_column},gt)H._$.range=[t[t.length-(Y||1)].range[0],t[t.length-1].range[1]];if($e=this.performAction.apply(H,[i,ut,_e,W.yy,G[1],T,t].concat(mt)),typeof $e<"u")return $e;if(Y)m=m.slice(0,-1*Y*2),T=T.slice(0,-1*Y),t=t.slice(0,-1*Y);m.push(this.productions_[G[1]][0]),T.push(H.$),t.push(H._$),dt=oe[m[m.length-2]][m[m.length-1]],m.push(dt);break;case 3:return!0}}return!0},"parse")},ft=function(){var K={EOF:1,parseError:e(function(k,m){if(this.yy.parser)this.yy.parser.parseError(k,m);else throw Error(k)},"parseError"),setInput:e(function(b,k){if(this.yy=k||this.yy||{},this._input=b,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges)this.yylloc.range=[0,0];return this.offset=0,this},"setInput"),input:e(function(){var b=this._input[0];this.yytext+=b,this.yyleng++,this.offset++,this.match+=b,this.matched+=b;var k=b.match(/(?:\r\n?|\n).*/g);if(k)this.yylineno++,this.yylloc.last_line++;else this.yylloc.last_column++;if(this.options.ranges)this.yylloc.range[1]++;return this._input=this._input.slice(1),b},"input"),unput:e(function(b){var k=b.length,m=b.split(/(?:\r\n?|\n)/g);this._input=b+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-k),this.offset-=k;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),m.length-1)this.yylineno-=m.length-1;var T=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:m?(m.length===c.length?this.yylloc.first_column:0)+c[c.length-m.length].length-m[0].length:this.yylloc.first_column-k},this.options.ranges)this.yylloc.range=[T[0],T[0]+this.yyleng-k];return this.yyleng=this.yytext.length,this},"unput"),more:e(function(){return this._more=!0,this},"more"),reject:e(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).
4
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:e(function(b){this.unput(this.match.slice(b))},"less"),pastInput:e(function(){var b=this.matched.substr(0,this.matched.length-this.match.length);return(b.length>20?"...":"")+b.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:e(function(){var b=this.match;if(b.length<20)b+=this._input.substr(0,20-b.length);return(b.substr(0,20)+(b.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:e(function(){var b=this.pastInput(),k=Array(b.length+1).join("-");return b+this.upcomingInput()+`
5
+ `+k+"^"},"showPosition"),test_match:e(function(b,k){var m,c,T;if(this.options.backtrack_lexer){if(T={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)T.yylloc.range=this.yylloc.range.slice(0)}if(c=b[0].match(/(?:\r\n?|\n).*/g),c)this.yylineno+=c.length;if(this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:c?c[c.length-1].length-c[c.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+b[0].length},this.yytext+=b[0],this.match+=b[0],this.matches=b,this.yyleng=this.yytext.length,this.options.ranges)this.yylloc.range=[this.offset,this.offset+=this.yyleng];if(this._more=!1,this._backtrack=!1,this._input=this._input.slice(b[0].length),this.matched+=b[0],m=this.performAction.call(this,this.yy,this,k,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input)this.done=!1;if(m)return m;else if(this._backtrack){for(var t in T)this[t]=T[t];return!1}return!1},"test_match"),next:e(function(){if(this.done)return this.EOF;if(!this._input)this.done=!0;var b,k,m,c;if(!this._more)this.yytext="",this.match="";var T=this._currentRules();for(var t=0;t<T.length;t++)if(m=this._input.match(this.rules[T[t]]),m&&(!k||m[0].length>k[0].length)){if(k=m,c=t,this.options.backtrack_lexer)if(b=this.test_match(m,T[t]),b!==!1)return b;else if(this._backtrack){k=!1;continue}else return!1;else if(!this.options.flex)break}if(k){if(b=this.test_match(k,T[c]),b!==!1)return b;return!1}if(this._input==="")return this.EOF;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text.
6
+ `+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:e(function(){var k=this.next();if(k)return k;else return this.lex()},"lex"),begin:e(function(k){this.conditionStack.push(k)},"begin"),popState:e(function(){var k=this.conditionStack.length-1;if(k>0)return this.conditionStack.pop();else return this.conditionStack[0]},"popState"),_currentRules:e(function(){if(this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1])return this.conditions[this.conditionStack[this.conditionStack.length-1]].rules;else return this.conditions.INITIAL.rules},"_currentRules"),topState:e(function(k){if(k=this.conditionStack.length-1-Math.abs(k||0),k>=0)return this.conditionStack[k];else return"INITIAL"},"topState"),pushState:e(function(k){this.begin(k)},"pushState"),stateStackSize:e(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:e(function(k,m,c,T){var t=T;switch(c){case 0:return 62;case 1:return 63;case 2:return 64;case 3:return 65;case 4:break;case 5:break;case 6:return this.begin("acc_title"),33;break;case 7:return this.popState(),"acc_title_value";break;case 8:return this.begin("acc_descr"),35;break;case 9:return this.popState(),"acc_descr_value";break;case 10:this.begin("acc_descr_multiline");break;case 11:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:return 8;case 14:break;case 15:return 7;case 16:return 7;case 17:return"EDGE_STATE";case 18:this.begin("callback_name");break;case 19:this.popState();break;case 20:this.popState(),this.begin("callback_args");break;case 21:return 79;case 22:this.popState();break;case 23:return 80;case 24:this.popState();break;case 25:return"STR";case 26:this.begin("string");break;case 27:return 82;case 28:return 57;case 29:return this.begin("namespace"),42;break;case 30:return this.popState(),8;break;case 31:break;case 32:return this.begin("namespace-body"),39;break;case 33:this.popState(),this.less(0);break;case 34:return this.popState(),41;break;case 35:return"EOF_IN_STRUCT";case 36:return 8;case 37:break;case 38:return"EDGE_STATE";case 39:return this.begin("class"),48;break;case 40:return this.popState(),8;break;case 41:break;case 42:return this.popState(),this.popState(),41;break;case 43:return this.begin("class-body"),39;break;case 44:return this.popState(),41;break;case 45:return"EOF_IN_STRUCT";case 46:return"EDGE_STATE";case 47:return"OPEN_IN_STRUCT";case 48:break;case 49:return"MEMBER";case 50:return 83;case 51:return 75;case 52:return 76;case 53:return 78;case 54:return 54;case 55:return 56;case 56:return 46;case 57:return 47;case 58:return 81;case 59:this.popState();break;case 60:return"GENERICTYPE";case 61:this.begin("generic");break;case 62:this.popState();break;case 63:return"BQUOTE_STR";case 64:this.begin("bqstring");break;case 65:return 77;case 66:return 77;case 67:return 77;case 68:return 77;case 69:return 69;case 70:return 69;case 71:return 71;case 72:return 71;case 73:return 70;case 74:return 68;case 75:return 72;case 76:return 73;case 77:return 74;case 78:return 22;case 79:return 44;case 80:return 100;case 81:return 18;case 82:return"PLUS";case 83:return 87;case 84:return 61;case 85:return 89;case 86:return 89;case 87:return 90;case 88:return"EQUALS";case 89:return"EQUALS";case 90:return 60;case 91:return 12;case 92:return 14;case 93:return"PUNCTUATION";case 94:return 86;case 95:return 102;case 96:return 50;case 97:return 50;case 98:return 9}},"anonymous"),rules:[/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:%%(?!\{)*[^\n]*(\r?\n?)+)/,/^(?:%%[^\n]*(\r?\n)*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:classDiagram-v2\b)/,/^(?:classDiagram\b)/,/^(?:\[\*\])/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:["])/,/^(?:[^"]*)/,/^(?:["])/,/^(?:style\b)/,/^(?:classDef\b)/,/^(?:namespace\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[{])/,/^(?:[}])/,/^(?:[}])/,/^(?:$)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:\[\*\])/,/^(?:class\b)/,/^(?:\s*(\r?\n)+)/,/^(?:\s+)/,/^(?:[}])/,/^(?:[{])/,/^(?:[}])/,/^(?:$)/,/^(?:\[\*\])/,/^(?:[{])/,/^(?:[\n])/,/^(?:[^{}\n]*)/,/^(?:cssClass\b)/,/^(?:callback\b)/,/^(?:link\b)/,/^(?:click\b)/,/^(?:note for\b)/,/^(?:note\b)/,/^(?:<<)/,/^(?:>>)/,/^(?:href\b)/,/^(?:[~])/,/^(?:[^~]*)/,/^(?:~)/,/^(?:[`])/,/^(?:[^`]+)/,/^(?:[`])/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:\s*<\|)/,/^(?:\s*\|>)/,/^(?:\s*>)/,/^(?:\s*<)/,/^(?:\s*\*)/,/^(?:\s*o\b)/,/^(?:\s*\(\))/,/^(?:--)/,/^(?:\.\.)/,/^(?::{1}[^:\n;]+)/,/^(?::{3})/,/^(?:-)/,/^(?:\.)/,/^(?:\+)/,/^(?::)/,/^(?:,)/,/^(?:#)/,/^(?:#)/,/^(?:%)/,/^(?:=)/,/^(?:=)/,/^(?:\w+)/,/^(?:\[)/,/^(?:\])/,/^(?:[!"#$%&'*+,-.`?\\/])/,/^(?:[0-9]+)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\s)/,/^(?:\s)/,/^(?:$)/],conditions:{"namespace-body":{rules:[26,29,34,35,36,37,38,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},namespace:{rules:[26,29,30,31,32,33,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},"class-body":{rules:[26,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},class:{rules:[26,40,41,42,43,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr_multiline:{rules:[11,12,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_descr:{rules:[9,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},acc_title:{rules:[7,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_args:{rules:[22,23,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},callback_name:{rules:[19,20,21,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},href:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},struct:{rules:[26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},generic:{rules:[26,50,51,52,53,54,55,56,57,58,59,60,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},bqstring:{rules:[26,50,51,52,53,54,55,56,57,58,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},string:{rules:[24,25,26,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,87,88,89,90,91,92,93,94,95,96,98],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,8,10,13,14,15,16,17,18,26,27,28,29,39,50,51,52,53,54,55,56,57,58,61,64,65,66,67,68,69,70,71,72,73,74,75,76,77,78,79,80,81,82,83,84,85,86,87,88,89,90,91,92,93,94,95,96,97,98],inclusive:!0}}};return K}();Xe.lexer=ft;function Be(){this.yy={}}return e(Be,"Parser"),Be.prototype=Xe,Xe.Parser=Be,new Be}();tt.parser=tt;var Et=tt,pt=["#","+","~","-",""],At=class{static{e(this,"ClassMember")}constructor(s,a){this.memberType=a,this.visibility="",this.classifier="",this.text="";let r=q(s,u());this.parseMember(r)}getDisplayDetails(){let s=this.visibility+fr(this.id);if(this.memberType==="method"){if(s+=`(${fr(this.parameters.trim())})`,this.returnType)s+=" : "+fr(this.returnType)}s=s.trim();let a=this.parseClassifier();return{displayText:s,cssStyle:a}}parseMember(s){let a="";if(this.memberType==="method"){let o=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(s);if(o){let d=o[1]?o[1].trim():"";if(pt.includes(d))this.visibility=d;if(this.id=o[2],this.parameters=o[3]?o[3].trim():"",a=o[4]?o[4].trim():"",this.returnType=o[5]?o[5].trim():"",a===""){let f=this.returnType.substring(this.returnType.length-1);if(/[$*]/.exec(f))a=f,this.returnType=this.returnType.substring(0,this.returnType.length-1)}}}else{let l=s.length,o=s.substring(0,1),d=s.substring(l-1);if(pt.includes(o))this.visibility=o;if(/[$*]/.exec(d))a=d;this.id=s.substring(this.visibility===""?0:1,a===""?l:l-1)}this.classifier=a,this.id=this.id.startsWith(" ")?" "+this.id.trim():this.id.trim();let r=`${this.visibility?"\\"+this.visibility:""}${fr(this.id)}${this.memberType==="method"?`(${fr(this.parameters)})${this.returnType?" : "+fr(this.returnType):""}`:""}`;if(this.text=r.replaceAll("<","&lt;").replaceAll(">","&gt;"),this.text.startsWith("\\&lt;"))this.text=this.text.replace("\\&lt;","~")}parseClassifier(){switch(this.classifier){case"*":return"font-style:italic;";case"$":return"text-decoration:underline;";default:return""}}},xe="classId-",bt=0,j=e((s)=>y.sanitizeText(s,u()),"sanitizeText"),Tt=class s{constructor(){this.relations=[],this.classes=new Map,this.styleClasses=new Map,this.notes=new Map,this.interfaces=[],this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId="",this.functions=[],this.lineType={LINE:0,DOTTED_LINE:1},this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3,LOLLIPOP:4},this.setupToolTips=e((a)=>{let r=Kt();p(a).select("svg").selectAll("g").filter(function(){return p(this).attr("title")!==null}).on("mouseover",(d)=>{let f=p(d.currentTarget),h=f.attr("title");if(!h)return;let C=d.currentTarget.getBoundingClientRect();r.transition().duration(200).style("opacity",".9"),r.html(Oe.sanitize(h)).style("left",`${window.scrollX+C.left+C.width/2}px`).style("top",`${window.scrollY+C.bottom+4}px`),f.classed("hover",!0)}).on("mouseout",(d)=>{r.transition().duration(500).style("opacity",0),p(d.currentTarget).classed("hover",!1)})},"setupToolTips"),this.direction="TB",this.setAccTitle=L,this.getAccTitle=R,this.setAccDescription=I,this.getAccDescription=M,this.setDiagramTitle=P,this.getDiagramTitle=O,this.getConfig=e(()=>u().class,"getConfig"),this.functions.push(this.setupToolTips.bind(this)),this.clear(),this.addRelation=this.addRelation.bind(this),this.addClassesToNamespace=this.addClassesToNamespace.bind(this),this.addNamespace=this.addNamespace.bind(this),this.popNamespace=this.popNamespace.bind(this),this.setCssClass=this.setCssClass.bind(this),this.addMembers=this.addMembers.bind(this),this.addClass=this.addClass.bind(this),this.setClassLabel=this.setClassLabel.bind(this),this.addAnnotation=this.addAnnotation.bind(this),this.addMember=this.addMember.bind(this),this.cleanupLabel=this.cleanupLabel.bind(this),this.addNote=this.addNote.bind(this),this.defineClass=this.defineClass.bind(this),this.setDirection=this.setDirection.bind(this),this.setLink=this.setLink.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.clear=this.clear.bind(this),this.setTooltip=this.setTooltip.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setCssStyle=this.setCssStyle.bind(this)}static{e(this,"ClassDB")}splitClassNameAndType(a){let r=y.sanitizeText(a,u()),l="",o=r;if(r.indexOf("~")>0){let d=r.split("~");o=j(d[0]),l=j(d[1])}return{className:o,type:l}}setClassLabel(a,r){let l=y.sanitizeText(a,u());if(r)r=j(r);let{className:o}=this.splitClassNameAndType(l);this.classes.get(o).label=r,this.classes.get(o).text=`${r}${this.classes.get(o).type?`<${this.classes.get(o).type}>`:""}`}addClass(a){let r=y.sanitizeText(a,u()),{className:l,type:o}=this.splitClassNameAndType(r);if(this.classes.has(l))return;let d=y.sanitizeText(l,u());this.classes.set(d,{id:d,type:o,label:d,text:`${d}${o?`&lt;${o}&gt;`:""}`,shape:"classBox",cssClasses:"default",methods:[],members:[],annotations:[],styles:[],domId:xe+d+"-"+bt}),bt++}addInterface(a,r){let l={id:`interface${this.interfaces.length}`,label:a,classId:r};this.interfaces.push(l)}setDiagramId(a){this.diagramId=a}lookUpDomId(a){let r=y.sanitizeText(a,u());if(this.classes.has(r)){let l=this.classes.get(r).domId;return this.diagramId?`${this.diagramId}-${l}`:l}throw Error("Class not found: "+r)}clear(){this.relations=[],this.classes=new Map,this.notes=new Map,this.interfaces=[],this.functions=[],this.functions.push(this.setupToolTips.bind(this)),this.namespaces=new Map,this.namespaceCounter=0,this.namespaceStack=[],this.diagramId="",this.direction="TB",A()}getClass(a){return this.classes.get(a)}getClasses(){return this.classes}getRelations(){return this.relations}getNote(a){let r=typeof a==="number"?`note${a}`:a;return this.notes.get(r)}getNotes(){return this.notes}addRelation(a){n.debug("Adding relation: "+JSON.stringify(a));let r=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];if(a.relation.type1===this.relationType.LOLLIPOP&&!r.includes(a.relation.type2))this.addClass(a.id2),this.addInterface(a.id1,a.id2),a.id1=`interface${this.interfaces.length-1}`;else if(a.relation.type2===this.relationType.LOLLIPOP&&!r.includes(a.relation.type1))this.addClass(a.id1),this.addInterface(a.id2,a.id1),a.id2=`interface${this.interfaces.length-1}`;else this.addClass(a.id1),this.addClass(a.id2);a.id1=this.splitClassNameAndType(a.id1).className,a.id2=this.splitClassNameAndType(a.id2).className,a.relationTitle1=y.sanitizeText(a.relationTitle1.trim(),u()),a.relationTitle2=y.sanitizeText(a.relationTitle2.trim(),u()),this.relations.push(a)}addAnnotation(a,r){let l=this.splitClassNameAndType(a).className;this.classes.get(l).annotations.push(r)}addMember(a,r){this.addClass(a);let l=this.splitClassNameAndType(a).className,o=this.classes.get(l);if(typeof r==="string"){let d=r.trim();if(d.startsWith("<<")&&d.endsWith(">>"))o.annotations.push(j(d.substring(2,d.length-2)));else if(d.indexOf(")")>0)o.methods.push(new At(d,"method"));else if(d)o.members.push(new At(d,"attribute"))}}addMembers(a,r){if(Array.isArray(r))r.reverse(),r.forEach((l)=>this.addMember(a,l))}addNote(a,r){let l=this.notes.size,o={id:`note${l}`,class:r,text:a,index:l};return this.notes.set(o.id,o),o.id}cleanupLabel(a){if(a.startsWith(":"))a=a.substring(1);return j(a.trim())}setCssClass(a,r){a.split(",").forEach((l)=>{let o=l;if(/\d/.exec(l[0]))o=xe+o;o=this.splitClassNameAndType(o).className;let d=this.classes.get(o);if(d)d.cssClasses+=" "+r})}defineClass(a,r){for(let l of a){let o=this.styleClasses.get(l);if(o===void 0)o={id:l,styles:[],textStyles:[]},this.styleClasses.set(l,o);if(r)r.forEach((d)=>{if(/color/.exec(d)){let f=d.replace("fill","bgFill");o.textStyles.push(f)}o.styles.push(d)});this.classes.forEach((d)=>{if(d.cssClasses.includes(l))d.styles.push(...r.flatMap((f)=>f.split(",")))})}}setTooltip(a,r){a.split(",").forEach((l)=>{if(r!==void 0){let o=this.splitClassNameAndType(l).className,d=this.classes.get(o);if(d)d.tooltip=j(r)}})}getTooltip(a,r){if(r&&this.namespaces.has(r))return this.namespaces.get(r).classes.get(a).tooltip;return this.classes.get(a).tooltip}setLink(a,r,l){let o=u();a.split(",").forEach((d)=>{let f=d;if(/\d/.exec(d[0]))f=xe+f;f=this.splitClassNameAndType(f).className;let h=this.classes.get(f);if(h)if(h.link=F.formatUrl(r,o),o.securityLevel==="sandbox")h.linkTarget="_top";else if(typeof l==="string")h.linkTarget=j(l);else h.linkTarget="_blank"}),this.setCssClass(a,"clickable")}setClickEvent(a,r,l){a.split(",").forEach((o)=>{this.setClickFunc(o,r,l);let d=this.splitClassNameAndType(o).className,f=this.classes.get(d);if(f)f.haveCallback=!0}),this.setCssClass(a,"clickable")}setClickFunc(a,r,l){let o=y.sanitizeText(a,u());if(u().securityLevel!=="loose")return;if(r===void 0)return;let f=this.splitClassNameAndType(o).className;if(this.classes.has(f)){let h=[];if(typeof l==="string"){h=l.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let C=0;C<h.length;C++){let E=h[C].trim();if(E.startsWith('"')&&E.endsWith('"'))E=E.substr(1,E.length-2);h[C]=E}}if(h.length===0)h.push(f);this.functions.push(()=>{let C=this.lookUpDomId(f),E=document.querySelector(`[id="${C}"]`);if(E!==null)E.addEventListener("click",()=>{F.runFunc(r,...h)},!1)})}}bindFunctions(a){this.functions.forEach((r)=>{r(a)})}escapeHtml(a){return a.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}getDirection(){return this.direction}setDirection(a){this.direction=a}static resolveQualifiedId(a,r){let l=r.at(-1);return l?`${l}.${a}`:a}static getAncestorIds(a){let r=a.split("."),l=Array(r.length);l[0]=r[0];for(let o=1;o<r.length;o++)l[o]=`${l[o-1]}.${r[o]}`;return l}createNamespaceNode(a,r,l,o=!1){return{id:a,label:r,classes:new Map,notes:new Map,children:new Map,domId:xe+a+"-"+this.namespaceCounter++,parent:l,explicit:o}}linkParentChild(a,r){let l=this.namespaces.get(a),o=this.namespaces.get(r);if(!l||!o)return;if(!l.children.has(r))l.children.set(r,o);o.parent??=a}addNamespace(a,r){let l=s.resolveQualifiedId(a,this.namespaceStack);if(this.namespaceStack.push(l),this.namespaces.has(l)){let f=this.namespaces.get(l);if(f.explicit=!0,r)f.label=r;return l}let o=l.split("."),d=s.getAncestorIds(l);for(let f=0;f<d.length;f++){let h=d[f],C=f>0?d[f-1]:void 0,E=f===d.length-1,w=E&&r?r:o[f];if(!this.namespaces.has(h))this.namespaces.set(h,this.createNamespaceNode(h,w,C,E));else if(E)this.namespaces.get(h).explicit=!0;if(C)this.linkParentChild(C,h)}return l}popNamespace(){this.namespaceStack.pop()}getNamespace(a){return this.namespaces.get(a)}getNamespaces(){return this.namespaces}addClassesToNamespace(a,r,l){if(!this.namespaces.has(a))return;for(let o of r){let{className:d}=this.splitClassNameAndType(o),f=this.getClass(d);f.parent=a,this.namespaces.get(a).classes.set(d,f)}for(let o of l){let d=this.getNote(o);d.parent=a,this.namespaces.get(a).notes.set(o,d)}}setCssStyle(a,r){let l=this.classes.get(a);if(!r||!l)return;for(let o of r)if(o.includes(","))l.styles.push(...o.split(","));else l.styles.push(o)}getArrowMarker(a){let r;switch(a){case 0:r="aggregation";break;case 1:r="extension";break;case 2:r="composition";break;case 3:r="dependency";break;case 4:r="lollipop";break;default:r="none"}return r}resolveExplicitAncestor(a){let r=a;while(r){let l=this.namespaces.get(r);if(!l)return;if(l.explicit)return r;r=l.parent}return}getData(){let a=[],r=[],l=u(),o=l.class?.hierarchicalNamespaces??!0;for(let h of this.namespaces.values()){if(!o&&!h.explicit)continue;let C={id:h.id,label:o?h.label:h.id,isGroup:!0,padding:l.class.padding??16,shape:"rect",cssStyles:[],look:l.look,parentId:o?h.parent:void 0};a.push(C)}let d=0;for(let h of this.classes.values()){let C=o?h.parent:this.resolveExplicitAncestor(h.parent),E={...h,type:void 0,isGroup:!1,parentId:C,look:l.look,colorIndex:d++};a.push(E)}for(let h of this.notes.values()){let C=o?h.parent:this.resolveExplicitAncestor(h.parent),E={id:h.id,label:h.text,isGroup:!1,shape:"note",padding:l.class.padding??6,cssStyles:["text-align: left","white-space: nowrap",`fill: ${l.themeVariables.noteBkgColor}`,`stroke: ${l.themeVariables.noteBorderColor}`],look:l.look,parentId:C,labelType:"markdown"};a.push(E);let w=this.classes.get(h.class)?.id;if(w){let J={id:`edgeNote${h.index}`,start:h.id,end:w,type:"normal",thickness:"normal",classes:"relation",arrowTypeStart:"none",arrowTypeEnd:"none",arrowheadStyle:"",labelStyle:[""],style:["fill: none"],pattern:"dotted",look:l.look};r.push(J)}}for(let h of this.interfaces){let C={id:h.id,label:h.label,isGroup:!1,shape:"rect",cssStyles:["opacity: 0;"],look:l.look};a.push(C)}let f=0;for(let h of this.relations){f++;let C={id:Ve(h.id1,h.id2,{prefix:"id",counter:f}),start:h.id1,end:h.id2,type:"normal",label:h.title,labelpos:"c",thickness:"normal",classes:"relation",arrowTypeStart:this.getArrowMarker(h.relation.type1),arrowTypeEnd:this.getArrowMarker(h.relation.type2),startLabelRight:h.relationTitle1==="none"?"":h.relationTitle1,endLabelLeft:h.relationTitle2==="none"?"":h.relationTitle2,arrowheadStyle:"",labelStyle:["display: inline-block"],style:h.style||"",pattern:h.relation.lineType==1?"dashed":"solid",look:l.look,labelType:"markdown"};r.push(C)}return{nodes:a,edges:r,other:{},config:l,direction:this.getDirection()}}},yt=e((s)=>{let{theme:a,bkgColorArray:r,borderColorArray:l}=s;if(!de(a,l))return"";let o=fe(s.look),d=ge(r),f="";for(let h=0;h<Je(s.THEME_COLOR_LIMIT,l);h++){let C=l[h%l.length];f+=`
7
7
 
8
8
  [data-look="${o}"][data-color-id="color-${h}"].node .outer-path path {
9
9
  stroke: ${C};
@@ -13,7 +13,7 @@ Expecting `+Ne.join(", ")+", got '"+(this.terminals_[v]||v)+"'";else $e="Parse e
13
13
  [data-look="${o}"][data-color-id="color-${h}"].node .divider path {
14
14
  stroke: ${C};
15
15
  }
16
- `}return b},"genColor"),Dt=e((s)=>`${yt(s)}
16
+ `}return f},"genColor"),Dt=e((s)=>`${yt(s)}
17
17
  g.classGroup text {
18
18
  fill: ${s.nodeBorder||s.classText};
19
19
  stroke: none;
@@ -213,5 +213,5 @@ g.classGroup line {
213
213
  }
214
214
  text-align: center;
215
215
  }
216
- ${Xe()}
217
- `,"getStyles"),Ft=Dt,Bt=e((s,a="TB")=>{if(!s.doc)return a;let r=a;for(let l of s.doc)if(l.stmt==="dir")r=l.value;return r},"getDir"),_t=e(function(s,a){return a.db.getClasses()},"getClasses"),St=e(async function(s,a,r,l){n.info("REF0:"),n.info("Drawing class diagram (v3)",a);let{securityLevel:o,state:d,layout:b}=u();l.db.setDiagramId(a);let h=l.db.getData(),C=Ee(a,o);h.type=l.type,h.layoutAlgorithm=_e(b),h.nodeSpacing=d?.nodeSpacing||50,h.rankSpacing=d?.rankSpacing||50,h.markers=["aggregation","extension","composition","dependency","lollipop"],h.diagramId=a,await Ae(h,C);let E=8;z.insertTitle(C,"classDiagramTitleText",d?.titleTopMargin??25,l.db.getDiagramTitle()),ge(C,E,"classDiagram",d?.useMaxWidth??!0)},"draw"),Nt={getClasses:_t,draw:St,getDir:Bt},Zt={parser:Et,get db(){return new Tt},renderer:Nt,styles:Ft,init:e((s)=>{if(!s.class)s.class={};s.class.arrowMarkerAbsolute=s.arrowMarkerAbsolute},"init")};export{Zt as diagram};
216
+ ${Ye()}
217
+ `,"getStyles"),Ft=Dt,Bt=e((s,a="TB")=>{if(!s.doc)return a;let r=a;for(let l of s.doc)if(l.stmt==="dir")r=l.value;return r},"getDir"),_t=e(function(s,a){return a.db.getClasses()},"getClasses"),St=e(async function(s,a,r,l){n.info("REF0:"),n.info("Drawing class diagram (v3)",a);let{securityLevel:o,state:d,layout:f}=u();l.db.setDiagramId(a);let h=l.db.getData(),C=Ce(a,o);h.type=l.type,h.layoutAlgorithm=Ee(f),h.nodeSpacing=d?.nodeSpacing||50,h.rankSpacing=d?.rankSpacing||50,h.markers=["aggregation","extension","composition","dependency","lollipop"],h.diagramId=a,await Se(h,C);let E=8;F.insertTitle(C,"classDiagramTitleText",d?.titleTopMargin??25,l.db.getDiagramTitle()),pe(C,E,"classDiagram",d?.useMaxWidth??!0)},"draw"),Nt={getClasses:_t,draw:St,getDir:Bt},Zt={parser:Et,get db(){return new Tt},renderer:Nt,styles:Ft,init:e((s)=>{if(!s.class)s.class={};s.class.arrowMarkerAbsolute=s.arrowMarkerAbsolute},"init")};export{Zt as diagram};
@@ -0,0 +1 @@
1
+ import{e,n,p}from"./index.zkx4ryzt.js";import{xt}from"./index.d57x7pg9.js";import{Pe,We}from"./index.rkgfxpm3.js";var q=We(function(Z,K){(function(w,L){if(typeof Z==="object"&&typeof K==="object")K.exports=L();else if(typeof define==="function"&&define.amd)define([],L);else if(typeof Z==="object")Z.layoutBase=L();else w.layoutBase=L()})(Z,function(){return function(m){var w={};function L(o){if(w[o])return w[o].exports;var r=w[o]={i:o,l:!1,exports:{}};return m[o].call(r.exports,r,r.exports,L),r.l=!0,r.exports}return L.m=m,L.c=w,L.i=function(o){return o},L.d=function(o,r,t){if(!L.o(o,r))Object.defineProperty(o,r,{configurable:!1,enumerable:!0,get:t})},L.n=function(o){var r=o&&o.__esModule?function(){return o.default}:function(){return o};return L.d(r,"a",r),r},L.o=function(o,r){return Object.prototype.hasOwnProperty.call(o,r)},L.p="",L(L.s=26)}([function(m,w,L){function o(){}o.QUALITY=1,o.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,o.DEFAULT_INCREMENTAL=!1,o.DEFAULT_ANIMATION_ON_LAYOUT=!0,o.DEFAULT_ANIMATION_DURING_LAYOUT=!1,o.DEFAULT_ANIMATION_PERIOD=50,o.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,o.DEFAULT_GRAPH_MARGIN=15,o.NODE_DIMENSIONS_INCLUDE_LABELS=!1,o.SIMPLE_NODE_SIZE=40,o.SIMPLE_NODE_HALF_SIZE=o.SIMPLE_NODE_SIZE/2,o.EMPTY_COMPOUND_NODE_SIZE=40,o.MIN_EDGE_LENGTH=1,o.WORLD_BOUNDARY=1e6,o.INITIAL_WORLD_BOUNDARY=o.WORLD_BOUNDARY/1000,o.WORLD_CENTER_X=1200,o.WORLD_CENTER_Y=900,m.exports=o},function(m,w,L){var o=L(2),r=L(8),t=L(9);function i(f,a,y){o.call(this,y),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=y,this.bendpoints=[],this.source=f,this.target=a}i.prototype=Object.create(o.prototype);for(var l in o)i[l]=o[l];i.prototype.getSource=function(){return this.source},i.prototype.getTarget=function(){return this.target},i.prototype.isInterGraph=function(){return this.isInterGraph},i.prototype.getLength=function(){return this.length},i.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},i.prototype.getBendpoints=function(){return this.bendpoints},i.prototype.getLca=function(){return this.lca},i.prototype.getSourceInLca=function(){return this.sourceInLca},i.prototype.getTargetInLca=function(){return this.targetInLca},i.prototype.getOtherEnd=function(f){if(this.source===f)return this.target;else if(this.target===f)return this.source;else throw"Node is not incident with this edge"},i.prototype.getOtherEndInGraph=function(f,a){var y=this.getOtherEnd(f),s=a.getGraphManager().getRoot();while(!0){if(y.getOwner()==a)return y;if(y.getOwner()==s)break;y=y.getOwner().getParent()}return null},i.prototype.updateLength=function(){var f=[,,,,];if(this.isOverlapingSourceAndTarget=r.getIntersection(this.target.getRect(),this.source.getRect(),f),!this.isOverlapingSourceAndTarget){if(this.lengthX=f[0]-f[2],this.lengthY=f[1]-f[3],Math.abs(this.lengthX)<1)this.lengthX=t.sign(this.lengthX);if(Math.abs(this.lengthY)<1)this.lengthY=t.sign(this.lengthY);this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)}},i.prototype.updateLengthSimple=function(){if(this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),Math.abs(this.lengthX)<1)this.lengthX=t.sign(this.lengthX);if(Math.abs(this.lengthY)<1)this.lengthY=t.sign(this.lengthY);this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},m.exports=i},function(m,w,L){function o(r){this.vGraphObject=r}m.exports=o},function(m,w,L){var o=L(2),r=L(10),t=L(13),i=L(0),l=L(16),f=L(4);function a(s,u,g,E){if(g==null&&E==null)E=u;if(o.call(this,E),s.graphManager!=null)s=s.graphManager;if(this.estimatedSize=r.MIN_VALUE,this.inclusionTreeDepth=r.MAX_VALUE,this.vGraphObject=E,this.edges=[],this.graphManager=s,g!=null&&u!=null)this.rect=new t(u.x,u.y,g.width,g.height);else this.rect=new t}a.prototype=Object.create(o.prototype);for(var y in o)a[y]=o[y];a.prototype.getEdges=function(){return this.edges},a.prototype.getChild=function(){return this.child},a.prototype.getOwner=function(){return this.owner},a.prototype.getWidth=function(){return this.rect.width},a.prototype.setWidth=function(s){this.rect.width=s},a.prototype.getHeight=function(){return this.rect.height},a.prototype.setHeight=function(s){this.rect.height=s},a.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},a.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},a.prototype.getCenter=function(){return new f(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},a.prototype.getLocation=function(){return new f(this.rect.x,this.rect.y)},a.prototype.getRect=function(){return this.rect},a.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},a.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},a.prototype.setRect=function(s,u){this.rect.x=s.x,this.rect.y=s.y,this.rect.width=u.width,this.rect.height=u.height},a.prototype.setCenter=function(s,u){this.rect.x=s-this.rect.width/2,this.rect.y=u-this.rect.height/2},a.prototype.setLocation=function(s,u){this.rect.x=s,this.rect.y=u},a.prototype.moveBy=function(s,u){this.rect.x+=s,this.rect.y+=u},a.prototype.getEdgeListToNode=function(s){var u=[],g,E=this;return E.edges.forEach(function(T){if(T.target==s){if(T.source!=E)throw"Incorrect edge source!";u.push(T)}}),u},a.prototype.getEdgesBetween=function(s){var u=[],g,E=this;return E.edges.forEach(function(T){if(!(T.source==E||T.target==E))throw"Incorrect edge source and/or target";if(T.target==s||T.source==s)u.push(T)}),u},a.prototype.getNeighborsList=function(){var s=new Set,u=this;return u.edges.forEach(function(g){if(g.source==u)s.add(g.target);else{if(g.target!=u)throw"Incorrect incidency!";s.add(g.source)}}),s},a.prototype.withChildren=function(){var s=new Set,u,g;if(s.add(this),this.child!=null){var E=this.child.getNodes();for(var T=0;T<E.length;T++)u=E[T],g=u.withChildren(),g.forEach(function(N){s.add(N)})}return s},a.prototype.getNoOfChildren=function(){var s=0,u;if(this.child==null)s=1;else{var g=this.child.getNodes();for(var E=0;E<g.length;E++)u=g[E],s+=u.getNoOfChildren()}if(s==0)s=1;return s},a.prototype.getEstimatedSize=function(){if(this.estimatedSize==r.MIN_VALUE)throw"assert failed";return this.estimatedSize},a.prototype.calcEstimatedSize=function(){if(this.child==null)return this.estimatedSize=(this.rect.width+this.rect.height)/2;else return this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize},a.prototype.scatter=function(){var s,u,g=-i.INITIAL_WORLD_BOUNDARY,E=i.INITIAL_WORLD_BOUNDARY;s=i.WORLD_CENTER_X+l.nextDouble()*(E-g)+g;var T=-i.INITIAL_WORLD_BOUNDARY,N=i.INITIAL_WORLD_BOUNDARY;u=i.WORLD_CENTER_Y+l.nextDouble()*(N-T)+T,this.rect.x=s,this.rect.y=u},a.prototype.updateBounds=function(){if(this.getChild()==null)throw"assert failed";if(this.getChild().getNodes().length!=0){var s=this.getChild();if(s.updateBounds(!0),this.rect.x=s.getLeft(),this.rect.y=s.getTop(),this.setWidth(s.getRight()-s.getLeft()),this.setHeight(s.getBottom()-s.getTop()),i.NODE_DIMENSIONS_INCLUDE_LABELS){var u=s.getRight()-s.getLeft(),g=s.getBottom()-s.getTop();if(this.labelWidth>u)this.rect.x-=(this.labelWidth-u)/2,this.setWidth(this.labelWidth);if(this.labelHeight>g){if(this.labelPos=="center")this.rect.y-=(this.labelHeight-g)/2;else if(this.labelPos=="top")this.rect.y-=this.labelHeight-g;this.setHeight(this.labelHeight)}}}},a.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==r.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},a.prototype.transform=function(s){var u=this.rect.x;if(u>i.WORLD_BOUNDARY)u=i.WORLD_BOUNDARY;else if(u<-i.WORLD_BOUNDARY)u=-i.WORLD_BOUNDARY;var g=this.rect.y;if(g>i.WORLD_BOUNDARY)g=i.WORLD_BOUNDARY;else if(g<-i.WORLD_BOUNDARY)g=-i.WORLD_BOUNDARY;var E=new f(u,g),T=s.inverseTransformPoint(E);this.setLocation(T.x,T.y)},a.prototype.getLeft=function(){return this.rect.x},a.prototype.getRight=function(){return this.rect.x+this.rect.width},a.prototype.getTop=function(){return this.rect.y},a.prototype.getBottom=function(){return this.rect.y+this.rect.height},a.prototype.getParent=function(){if(this.owner==null)return null;return this.owner.getParent()},m.exports=a},function(m,w,L){function o(r,t){if(r==null&&t==null)this.x=0,this.y=0;else this.x=r,this.y=t}o.prototype.getX=function(){return this.x},o.prototype.getY=function(){return this.y},o.prototype.setX=function(r){this.x=r},o.prototype.setY=function(r){this.y=r},o.prototype.getDifference=function(r){return new DimensionD(this.x-r.x,this.y-r.y)},o.prototype.getCopy=function(){return new o(this.x,this.y)},o.prototype.translate=function(r){return this.x+=r.width,this.y+=r.height,this},m.exports=o},function(m,w,L){var o=L(2),r=L(10),t=L(0),i=L(6),l=L(3),f=L(1),a=L(13),y=L(12),s=L(11);function u(E,T,N){if(o.call(this,N),this.estimatedSize=r.MIN_VALUE,this.margin=t.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=E,T!=null&&T instanceof i)this.graphManager=T;else if(T!=null&&T instanceof Layout)this.graphManager=T.graphManager}u.prototype=Object.create(o.prototype);for(var g in o)u[g]=o[g];u.prototype.getNodes=function(){return this.nodes},u.prototype.getEdges=function(){return this.edges},u.prototype.getGraphManager=function(){return this.graphManager},u.prototype.getParent=function(){return this.parent},u.prototype.getLeft=function(){return this.left},u.prototype.getRight=function(){return this.right},u.prototype.getTop=function(){return this.top},u.prototype.getBottom=function(){return this.bottom},u.prototype.isConnected=function(){return this.isConnected},u.prototype.add=function(E,T,N){if(T==null&&N==null){var v=E;if(this.graphManager==null)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(v)>-1)throw"Node already in graph!";return v.owner=this,this.getNodes().push(v),v}else{var O=E;if(!(this.getNodes().indexOf(T)>-1&&this.getNodes().indexOf(N)>-1))throw"Source or target not in graph!";if(!(T.owner==N.owner&&T.owner==this))throw"Both owners must be this graph!";if(T.owner!=N.owner)return null;if(O.source=T,O.target=N,O.isInterGraph=!1,this.getEdges().push(O),T.edges.push(O),N!=T)N.edges.push(O);return O}},u.prototype.remove=function(E){var T=E;if(E instanceof l){if(T==null)throw"Node is null!";if(!(T.owner!=null&&T.owner==this))throw"Owner graph is invalid!";if(this.graphManager==null)throw"Owner graph manager is invalid!";var N=T.edges.slice(),v,O=N.length;for(var D=0;D<O;D++)if(v=N[D],v.isInterGraph)this.graphManager.remove(v);else v.source.owner.remove(v);var R=this.nodes.indexOf(T);if(R==-1)throw"Node not in owner node list!";this.nodes.splice(R,1)}else if(E instanceof f){var v=E;if(v==null)throw"Edge is null!";if(!(v.source!=null&&v.target!=null))throw"Source and/or target is null!";if(!(v.source.owner!=null&&v.target.owner!=null&&v.source.owner==this&&v.target.owner==this))throw"Source and/or target owner is invalid!";var h=v.source.edges.indexOf(v),c=v.target.edges.indexOf(v);if(!(h>-1&&c>-1))throw"Source and/or target doesn't know this edge!";if(v.source.edges.splice(h,1),v.target!=v.source)v.target.edges.splice(c,1);var R=v.source.owner.getEdges().indexOf(v);if(R==-1)throw"Not in owner's edge list!";v.source.owner.getEdges().splice(R,1)}},u.prototype.updateLeftTop=function(){var{MAX_VALUE:E,MAX_VALUE:T}=r,N,v,O,D=this.getNodes(),R=D.length;for(var h=0;h<R;h++){var c=D[h];if(N=c.getTop(),v=c.getLeft(),E>N)E=N;if(T>v)T=v}if(E==r.MAX_VALUE)return null;if(D[0].getParent().paddingLeft!=null)O=D[0].getParent().paddingLeft;else O=this.margin;return this.left=T-O,this.top=E-O,new y(this.left,this.top)},u.prototype.updateBounds=function(E){var T=r.MAX_VALUE,N=-r.MAX_VALUE,v=r.MAX_VALUE,O=-r.MAX_VALUE,D,R,h,c,d,A=this.nodes,I=A.length;for(var C=0;C<I;C++){var M=A[C];if(E&&M.child!=null)M.updateBounds();if(D=M.getLeft(),R=M.getRight(),h=M.getTop(),c=M.getBottom(),T>D)T=D;if(N<R)N=R;if(v>h)v=h;if(O<c)O=c}var G=new a(T,v,N-T,O-v);if(T==r.MAX_VALUE)this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom();if(A[0].getParent().paddingLeft!=null)d=A[0].getParent().paddingLeft;else d=this.margin;this.left=G.x-d,this.right=G.x+G.width+d,this.top=G.y-d,this.bottom=G.y+G.height+d},u.calculateBounds=function(E){var T=r.MAX_VALUE,N=-r.MAX_VALUE,v=r.MAX_VALUE,O=-r.MAX_VALUE,D,R,h,c,d=E.length;for(var A=0;A<d;A++){var I=E[A];if(D=I.getLeft(),R=I.getRight(),h=I.getTop(),c=I.getBottom(),T>D)T=D;if(N<R)N=R;if(v>h)v=h;if(O<c)O=c}var C=new a(T,v,N-T,O-v);return C},u.prototype.getInclusionTreeDepth=function(){if(this==this.graphManager.getRoot())return 1;else return this.parent.getInclusionTreeDepth()},u.prototype.getEstimatedSize=function(){if(this.estimatedSize==r.MIN_VALUE)throw"assert failed";return this.estimatedSize},u.prototype.calcEstimatedSize=function(){var E=0,T=this.nodes,N=T.length;for(var v=0;v<N;v++){var O=T[v];E+=O.calcEstimatedSize()}if(E==0)this.estimatedSize=t.EMPTY_COMPOUND_NODE_SIZE;else this.estimatedSize=E/Math.sqrt(this.nodes.length);return this.estimatedSize},u.prototype.updateConnected=function(){var E=this;if(this.nodes.length==0){this.isConnected=!0;return}var T=new s,N=new Set,v=this.nodes[0],O,D,R=v.withChildren();R.forEach(function(C){T.push(C),N.add(C)});while(T.length!==0){v=T.shift(),O=v.getEdges();var h=O.length;for(var c=0;c<h;c++){var d=O[c];if(D=d.getOtherEndInGraph(v,this),D!=null&&!N.has(D)){var A=D.withChildren();A.forEach(function(C){T.push(C),N.add(C)})}}}if(this.isConnected=!1,N.size>=this.nodes.length){var I=0;if(N.forEach(function(C){if(C.owner==E)I++}),I==this.nodes.length)this.isConnected=!0}},m.exports=u},function(m,w,L){var o,r=L(1);function t(i){o=L(5),this.layout=i,this.graphs=[],this.edges=[]}t.prototype.addRoot=function(){var i=this.layout.newGraph(),l=this.layout.newNode(null),f=this.add(i,l);return this.setRootGraph(f),this.rootGraph},t.prototype.add=function(i,l,f,a,y){if(f==null&&a==null&&y==null){if(i==null)throw"Graph is null!";if(l==null)throw"Parent node is null!";if(this.graphs.indexOf(i)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(i),i.parent!=null)throw"Already has a parent!";if(l.child!=null)throw"Already has a child!";return i.parent=l,l.child=i,i}else{y=f,a=l,f=i;var s=a.getOwner(),u=y.getOwner();if(!(s!=null&&s.getGraphManager()==this))throw"Source not in this graph mgr!";if(!(u!=null&&u.getGraphManager()==this))throw"Target not in this graph mgr!";if(s==u)return f.isInterGraph=!1,s.add(f,a,y);else{if(f.isInterGraph=!0,f.source=a,f.target=y,this.edges.indexOf(f)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(f),!(f.source!=null&&f.target!=null))throw"Edge source and/or target is null!";if(!(f.source.edges.indexOf(f)==-1&&f.target.edges.indexOf(f)==-1))throw"Edge already in source and/or target incidency list!";return f.source.edges.push(f),f.target.edges.push(f),f}}},t.prototype.remove=function(i){if(i instanceof o){var l=i;if(l.getGraphManager()!=this)throw"Graph not in this graph mgr";if(!(l==this.rootGraph||l.parent!=null&&l.parent.graphManager==this))throw"Invalid parent node!";var f=[];f=f.concat(l.getEdges());var a,y=f.length;for(var s=0;s<y;s++)a=f[s],l.remove(a);var u=[];u=u.concat(l.getNodes());var g;y=u.length;for(var s=0;s<y;s++)g=u[s],l.remove(g);if(l==this.rootGraph)this.setRootGraph(null);var E=this.graphs.indexOf(l);this.graphs.splice(E,1),l.parent=null}else if(i instanceof r){if(a=i,a==null)throw"Edge is null!";if(!a.isInterGraph)throw"Not an inter-graph edge!";if(!(a.source!=null&&a.target!=null))throw"Source and/or target is null!";if(!(a.source.edges.indexOf(a)!=-1&&a.target.edges.indexOf(a)!=-1))throw"Source and/or target doesn't know this edge!";var E=a.source.edges.indexOf(a);if(a.source.edges.splice(E,1),E=a.target.edges.indexOf(a),a.target.edges.splice(E,1),!(a.source.owner!=null&&a.source.owner.getGraphManager()!=null))throw"Edge owner graph or owner graph manager is null!";if(a.source.owner.getGraphManager().edges.indexOf(a)==-1)throw"Not in owner graph manager's edge list!";var E=a.source.owner.getGraphManager().edges.indexOf(a);a.source.owner.getGraphManager().edges.splice(E,1)}},t.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},t.prototype.getGraphs=function(){return this.graphs},t.prototype.getAllNodes=function(){if(this.allNodes==null){var i=[],l=this.getGraphs(),f=l.length;for(var a=0;a<f;a++)i=i.concat(l[a].getNodes());this.allNodes=i}return this.allNodes},t.prototype.resetAllNodes=function(){this.allNodes=null},t.prototype.resetAllEdges=function(){this.allEdges=null},t.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},t.prototype.getAllEdges=function(){if(this.allEdges==null){var i=[],l=this.getGraphs(),f=l.length;for(var a=0;a<l.length;a++)i=i.concat(l[a].getEdges());i=i.concat(this.edges),this.allEdges=i}return this.allEdges},t.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},t.prototype.setAllNodesToApplyGravitation=function(i){if(this.allNodesToApplyGravitation!=null)throw"assert failed";this.allNodesToApplyGravitation=i},t.prototype.getRoot=function(){return this.rootGraph},t.prototype.setRootGraph=function(i){if(i.getGraphManager()!=this)throw"Root not in this graph mgr!";if(this.rootGraph=i,i.parent==null)i.parent=this.layout.newNode("Root node")},t.prototype.getLayout=function(){return this.layout},t.prototype.isOneAncestorOfOther=function(i,l){if(!(i!=null&&l!=null))throw"assert failed";if(i==l)return!0;var f=i.getOwner(),a;do{if(a=f.getParent(),a==null)break;if(a==l)return!0;if(f=a.getOwner(),f==null)break}while(!0);f=l.getOwner();do{if(a=f.getParent(),a==null)break;if(a==i)return!0;if(f=a.getOwner(),f==null)break}while(!0);return!1},t.prototype.calcLowestCommonAncestors=function(){var i,l,f,a,y,s=this.getAllEdges(),u=s.length;for(var g=0;g<u;g++){if(i=s[g],l=i.source,f=i.target,i.lca=null,i.sourceInLca=l,i.targetInLca=f,l==f){i.lca=l.getOwner();continue}a=l.getOwner();while(i.lca==null){i.targetInLca=f,y=f.getOwner();while(i.lca==null){if(y==a){i.lca=y;break}if(y==this.rootGraph)break;if(i.lca!=null)throw"assert failed";i.targetInLca=y.getParent(),y=i.targetInLca.getOwner()}if(a==this.rootGraph)break;if(i.lca==null)i.sourceInLca=a.getParent(),a=i.sourceInLca.getOwner()}if(i.lca==null)throw"assert failed"}},t.prototype.calcLowestCommonAncestor=function(i,l){if(i==l)return i.getOwner();var f=i.getOwner();do{if(f==null)break;var a=l.getOwner();do{if(a==null)break;if(a==f)return a;a=a.getParent().getOwner()}while(!0);f=f.getParent().getOwner()}while(!0);return f},t.prototype.calcInclusionTreeDepths=function(i,l){if(i==null&&l==null)i=this.rootGraph,l=1;var f,a=i.getNodes(),y=a.length;for(var s=0;s<y;s++)if(f=a[s],f.inclusionTreeDepth=l,f.child!=null)this.calcInclusionTreeDepths(f.child,l+1)},t.prototype.includesInvalidEdge=function(){var i,l=this.edges.length;for(var f=0;f<l;f++)if(i=this.edges[f],this.isOneAncestorOfOther(i.source,i.target))return!0;return!1},m.exports=t},function(m,w,L){var o=L(0);function r(){}for(var t in o)r[t]=o[t];r.MAX_ITERATIONS=2500,r.DEFAULT_EDGE_LENGTH=50,r.DEFAULT_SPRING_STRENGTH=0.45,r.DEFAULT_REPULSION_STRENGTH=4500,r.DEFAULT_GRAVITY_STRENGTH=0.4,r.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,r.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,r.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,r.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,r.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,r.DEFAULT_COOLING_FACTOR_INCREMENTAL=0.3,r.COOLING_ADAPTATION_FACTOR=0.33,r.ADAPTATION_LOWER_NODE_LIMIT=1000,r.ADAPTATION_UPPER_NODE_LIMIT=5000,r.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,r.MAX_NODE_DISPLACEMENT=r.MAX_NODE_DISPLACEMENT_INCREMENTAL*3,r.MIN_REPULSION_DIST=r.DEFAULT_EDGE_LENGTH/10,r.CONVERGENCE_CHECK_PERIOD=100,r.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=0.1,r.MIN_EDGE_LENGTH=1,r.GRID_CALCULATION_CHECK_PERIOD=10,m.exports=r},function(m,w,L){var o=L(12);function r(){}r.calcSeparationAmount=function(t,i,l,f){if(!t.intersects(i))throw"assert failed";var a=[,,];if(this.decideDirectionsForOverlappingNodes(t,i,a),l[0]=Math.min(t.getRight(),i.getRight())-Math.max(t.x,i.x),l[1]=Math.min(t.getBottom(),i.getBottom())-Math.max(t.y,i.y),t.getX()<=i.getX()&&t.getRight()>=i.getRight())l[0]+=Math.min(i.getX()-t.getX(),t.getRight()-i.getRight());else if(i.getX()<=t.getX()&&i.getRight()>=t.getRight())l[0]+=Math.min(t.getX()-i.getX(),i.getRight()-t.getRight());if(t.getY()<=i.getY()&&t.getBottom()>=i.getBottom())l[1]+=Math.min(i.getY()-t.getY(),t.getBottom()-i.getBottom());else if(i.getY()<=t.getY()&&i.getBottom()>=t.getBottom())l[1]+=Math.min(t.getY()-i.getY(),i.getBottom()-t.getBottom());var y=Math.abs((i.getCenterY()-t.getCenterY())/(i.getCenterX()-t.getCenterX()));if(i.getCenterY()===t.getCenterY()&&i.getCenterX()===t.getCenterX())y=1;var s=y*l[0],u=l[1]/y;if(l[0]<u)u=l[0];else s=l[1];l[0]=-1*a[0]*(u/2+f),l[1]=-1*a[1]*(s/2+f)},r.decideDirectionsForOverlappingNodes=function(t,i,l){if(t.getCenterX()<i.getCenterX())l[0]=-1;else l[0]=1;if(t.getCenterY()<i.getCenterY())l[1]=-1;else l[1]=1},r.getIntersection2=function(t,i,l){var f=t.getCenterX(),a=t.getCenterY(),y=i.getCenterX(),s=i.getCenterY();if(t.intersects(i))return l[0]=f,l[1]=a,l[2]=y,l[3]=s,!0;var u=t.getX(),g=t.getY(),E=t.getRight(),T=t.getX(),N=t.getBottom(),v=t.getRight(),O=t.getWidthHalf(),D=t.getHeightHalf(),R=i.getX(),h=i.getY(),c=i.getRight(),d=i.getX(),A=i.getBottom(),I=i.getRight(),C=i.getWidthHalf(),M=i.getHeightHalf(),G=!1,F=!1;if(f===y){if(a>s)return l[0]=f,l[1]=g,l[2]=y,l[3]=A,!1;else if(a<s)return l[0]=f,l[1]=N,l[2]=y,l[3]=h,!1}else if(a===s){if(f>y)return l[0]=u,l[1]=a,l[2]=c,l[3]=s,!1;else if(f<y)return l[0]=E,l[1]=a,l[2]=R,l[3]=s,!1}else{var P=t.height/t.width,b=i.height/i.width,U=(s-a)/(y-f),x=void 0,S=void 0,Y=void 0,X=void 0,H=void 0,_=void 0;if(-P===U)if(f>y)l[0]=T,l[1]=N,G=!0;else l[0]=E,l[1]=g,G=!0;else if(P===U)if(f>y)l[0]=u,l[1]=g,G=!0;else l[0]=v,l[1]=N,G=!0;if(-b===U)if(y>f)l[2]=d,l[3]=A,F=!0;else l[2]=c,l[3]=h,F=!0;else if(b===U)if(y>f)l[2]=R,l[3]=h,F=!0;else l[2]=I,l[3]=A,F=!0;if(G&&F)return!1;if(f>y)if(a>s)x=this.getCardinalDirection(P,U,4),S=this.getCardinalDirection(b,U,2);else x=this.getCardinalDirection(-P,U,3),S=this.getCardinalDirection(-b,U,1);else if(a>s)x=this.getCardinalDirection(-P,U,1),S=this.getCardinalDirection(-b,U,3);else x=this.getCardinalDirection(P,U,2),S=this.getCardinalDirection(b,U,4);if(!G)switch(x){case 1:X=g,Y=f+-D/U,l[0]=Y,l[1]=X;break;case 2:Y=v,X=a+O*U,l[0]=Y,l[1]=X;break;case 3:X=N,Y=f+D/U,l[0]=Y,l[1]=X;break;case 4:Y=T,X=a+-O*U,l[0]=Y,l[1]=X;break}if(!F)switch(S){case 1:_=h,H=y+-M/U,l[2]=H,l[3]=_;break;case 2:H=I,_=s+C*U,l[2]=H,l[3]=_;break;case 3:_=A,H=y+M/U,l[2]=H,l[3]=_;break;case 4:H=d,_=s+-C*U,l[2]=H,l[3]=_;break}}return!1},r.getCardinalDirection=function(t,i,l){if(t>i)return l;else return 1+l%4},r.getIntersection=function(t,i,l,f){if(f==null)return this.getIntersection2(t,i,l);var{x:a,y}=t,{x:s,y:u}=i,{x:g,y:E}=l,{x:T,y:N}=f,v=void 0,O=void 0,D=void 0,R=void 0,h=void 0,c=void 0,d=void 0,A=void 0,I=void 0;if(D=u-y,h=a-s,d=s*y-a*u,R=N-E,c=g-T,A=T*E-g*N,I=D*c-R*h,I===0)return null;return v=(h*A-c*d)/I,O=(R*d-D*A)/I,new o(v,O)},r.angleOfVector=function(t,i,l,f){var a=void 0;if(t!==l){if(a=Math.atan((f-i)/(l-t)),l<t)a+=Math.PI;else if(f<i)a+=this.TWO_PI}else if(f<i)a=this.ONE_AND_HALF_PI;else a=this.HALF_PI;return a},r.doIntersect=function(t,i,l,f){var{x:a,y}=t,{x:s,y:u}=i,{x:g,y:E}=l,{x:T,y:N}=f,v=(s-a)*(N-E)-(T-g)*(u-y);if(v===0)return!1;else{var O=((N-E)*(T-a)+(g-T)*(N-y))/v,D=((y-u)*(T-a)+(s-a)*(N-y))/v;return 0<O&&O<1&&0<D&&D<1}},r.HALF_PI=0.5*Math.PI,r.ONE_AND_HALF_PI=1.5*Math.PI,r.TWO_PI=2*Math.PI,r.THREE_PI=3*Math.PI,m.exports=r},function(m,w,L){function o(){}o.sign=function(r){if(r>0)return 1;else if(r<0)return-1;else return 0},o.floor=function(r){return r<0?Math.ceil(r):Math.floor(r)},o.ceil=function(r){return r<0?Math.floor(r):Math.ceil(r)},m.exports=o},function(m,w,L){function o(){}o.MAX_VALUE=2147483647,o.MIN_VALUE=-2147483648,m.exports=o},function(m,w,L){var o=function(){function a(y,s){for(var u=0;u<s.length;u++){var g=s[u];if(g.enumerable=g.enumerable||!1,g.configurable=!0,"value"in g)g.writable=!0;Object.defineProperty(y,g.key,g)}}return function(y,s,u){if(s)a(y.prototype,s);if(u)a(y,u);return y}}();function r(a,y){if(!(a instanceof y))throw TypeError("Cannot call a class as a function")}var t=function(y){return{value:y,next:null,prev:null}},i=function(y,s,u,g){if(y!==null)y.next=s;else g.head=s;if(u!==null)u.prev=s;else g.tail=s;return s.prev=y,s.next=u,g.length++,s},l=function(y,s){var{prev:u,next:g}=y;if(u!==null)u.next=g;else s.head=g;if(g!==null)g.prev=u;else s.tail=u;return y.prev=y.next=null,s.length--,y},f=function(){function a(y){var s=this;if(r(this,a),this.length=0,this.head=null,this.tail=null,y!=null)y.forEach(function(u){return s.push(u)})}return o(a,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(s,u){return i(u.prev,t(s),u,this)}},{key:"insertAfter",value:function(s,u){return i(u,t(s),u.next,this)}},{key:"insertNodeBefore",value:function(s,u){return i(u.prev,s,u,this)}},{key:"insertNodeAfter",value:function(s,u){return i(u,s,u.next,this)}},{key:"push",value:function(s){return i(this.tail,t(s),null,this)}},{key:"unshift",value:function(s){return i(null,t(s),this.head,this)}},{key:"remove",value:function(s){return l(s,this)}},{key:"pop",value:function(){return l(this.tail,this).value}},{key:"popNode",value:function(){return l(this.tail,this)}},{key:"shift",value:function(){return l(this.head,this).value}},{key:"shiftNode",value:function(){return l(this.head,this)}},{key:"get_object_at",value:function(s){if(s<=this.length()){var u=1,g=this.head;while(u<s)g=g.next,u++;return g.value}}},{key:"set_object_at",value:function(s,u){if(s<=this.length()){var g=1,E=this.head;while(g<s)E=E.next,g++;E.value=u}}}]),a}();m.exports=f},function(m,w,L){function o(r,t,i){if(this.x=null,this.y=null,r==null&&t==null&&i==null)this.x=0,this.y=0;else if(typeof r=="number"&&typeof t=="number"&&i==null)this.x=r,this.y=t;else if(r.constructor.name=="Point"&&t==null&&i==null)i=r,this.x=i.x,this.y=i.y}o.prototype.getX=function(){return this.x},o.prototype.getY=function(){return this.y},o.prototype.getLocation=function(){return new o(this.x,this.y)},o.prototype.setLocation=function(r,t,i){if(r.constructor.name=="Point"&&t==null&&i==null)i=r,this.setLocation(i.x,i.y);else if(typeof r=="number"&&typeof t=="number"&&i==null)if(parseInt(r)==r&&parseInt(t)==t)this.move(r,t);else this.x=Math.floor(r+0.5),this.y=Math.floor(t+0.5)},o.prototype.move=function(r,t){this.x=r,this.y=t},o.prototype.translate=function(r,t){this.x+=r,this.y+=t},o.prototype.equals=function(r){if(r.constructor.name=="Point"){var t=r;return this.x==t.x&&this.y==t.y}return this==r},o.prototype.toString=function(){return new o().constructor.name+"[x="+this.x+",y="+this.y+"]"},m.exports=o},function(m,w,L){function o(r,t,i,l){if(this.x=0,this.y=0,this.width=0,this.height=0,r!=null&&t!=null&&i!=null&&l!=null)this.x=r,this.y=t,this.width=i,this.height=l}o.prototype.getX=function(){return this.x},o.prototype.setX=function(r){this.x=r},o.prototype.getY=function(){return this.y},o.prototype.setY=function(r){this.y=r},o.prototype.getWidth=function(){return this.width},o.prototype.setWidth=function(r){this.width=r},o.prototype.getHeight=function(){return this.height},o.prototype.setHeight=function(r){this.height=r},o.prototype.getRight=function(){return this.x+this.width},o.prototype.getBottom=function(){return this.y+this.height},o.prototype.intersects=function(r){if(this.getRight()<r.x)return!1;if(this.getBottom()<r.y)return!1;if(r.getRight()<this.x)return!1;if(r.getBottom()<this.y)return!1;return!0},o.prototype.getCenterX=function(){return this.x+this.width/2},o.prototype.getMinX=function(){return this.getX()},o.prototype.getMaxX=function(){return this.getX()+this.width},o.prototype.getCenterY=function(){return this.y+this.height/2},o.prototype.getMinY=function(){return this.getY()},o.prototype.getMaxY=function(){return this.getY()+this.height},o.prototype.getWidthHalf=function(){return this.width/2},o.prototype.getHeightHalf=function(){return this.height/2},m.exports=o},function(m,w,L){var o=typeof Symbol==="function"&&typeof Symbol.iterator==="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol==="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function r(){}r.lastID=0,r.createID=function(t){if(r.isPrimitive(t))return t;if(t.uniqueID!=null)return t.uniqueID;return t.uniqueID=r.getString(),r.lastID++,t.uniqueID},r.getString=function(t){if(t==null)t=r.lastID;return"Object#"+t},r.isPrimitive=function(t){var i=typeof t>"u"?"undefined":o(t);return t==null||i!="object"&&i!="function"},m.exports=r},function(m,w,L){function o(g){if(Array.isArray(g)){for(var E=0,T=Array(g.length);E<g.length;E++)T[E]=g[E];return T}else return Array.from(g)}var r=L(0),t=L(6),i=L(3),l=L(1),f=L(5),a=L(4),y=L(17),s=L(27);function u(g){if(s.call(this),this.layoutQuality=r.QUALITY,this.createBendsAsNeeded=r.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=r.DEFAULT_INCREMENTAL,this.animationOnLayout=r.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=r.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=r.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=r.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new t(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,g!=null)this.isRemoteUse=g}u.RANDOM_SEED=1,u.prototype=Object.create(s.prototype),u.prototype.getGraphManager=function(){return this.graphManager},u.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},u.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},u.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},u.prototype.newGraphManager=function(){var g=new t(this);return this.graphManager=g,g},u.prototype.newGraph=function(g){return new f(null,this.graphManager,g)},u.prototype.newNode=function(g){return new i(this.graphManager,g)},u.prototype.newEdge=function(g){return new l(null,null,g)},u.prototype.checkLayoutSuccess=function(){return this.graphManager.getRoot()==null||this.graphManager.getRoot().getNodes().length==0||this.graphManager.includesInvalidEdge()},u.prototype.runLayout=function(){if(this.isLayoutFinished=!1,this.tilingPreLayout)this.tilingPreLayout();this.initParameters();var g;if(this.checkLayoutSuccess())g=!1;else g=this.layout();if(r.ANIMATE==="during")return!1;if(g){if(!this.isSubLayout)this.doPostLayout()}if(this.tilingPostLayout)this.tilingPostLayout();return this.isLayoutFinished=!0,g},u.prototype.doPostLayout=function(){if(!this.incremental)this.transform();this.update()},u.prototype.update2=function(){if(this.createBendsAsNeeded)this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges();if(!this.isRemoteUse){var g,E=this.graphManager.getAllEdges();for(var T=0;T<E.length;T++)g=E[T];var N,v=this.graphManager.getRoot().getNodes();for(var T=0;T<v.length;T++)N=v[T];this.update(this.graphManager.getRoot())}},u.prototype.update=function(g){if(g==null)this.update2();else if(g instanceof i){var E=g;if(E.getChild()!=null){var T=E.getChild().getNodes();for(var N=0;N<T.length;N++)update(T[N])}if(E.vGraphObject!=null){var v=E.vGraphObject;v.update(E)}}else if(g instanceof l){var O=g;if(O.vGraphObject!=null){var D=O.vGraphObject;D.update(O)}}else if(g instanceof f){var R=g;if(R.vGraphObject!=null){var h=R.vGraphObject;h.update(R)}}},u.prototype.initParameters=function(){if(!this.isSubLayout)this.layoutQuality=r.QUALITY,this.animationDuringLayout=r.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=r.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=r.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=r.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=r.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=r.DEFAULT_UNIFORM_LEAF_NODE_SIZES;if(this.animationDuringLayout)this.animationOnLayout=!1},u.prototype.transform=function(g){if(g==null)this.transform(new a(0,0));else{var E=new y,T=this.graphManager.getRoot().updateLeftTop();if(T!=null){E.setWorldOrgX(g.x),E.setWorldOrgY(g.y),E.setDeviceOrgX(T.x),E.setDeviceOrgY(T.y);var N=this.getAllNodes(),v;for(var O=0;O<N.length;O++)v=N[O],v.transform(E)}}},u.prototype.positionNodesRandomly=function(g){if(g==null)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else{var E,T,N=g.getNodes();for(var v=0;v<N.length;v++)if(E=N[v],T=E.getChild(),T==null)E.scatter();else if(T.getNodes().length==0)E.scatter();else this.positionNodesRandomly(T),E.updateBounds()}},u.prototype.getFlatForest=function(){var g=[],E=!0,T=this.graphManager.getRoot().getNodes(),N=!0;for(var v=0;v<T.length;v++)if(T[v].getChild()!=null)N=!1;if(!N)return g;var O=new Set,D=[],R=new Map,h=[];h=h.concat(T);while(h.length>0&&E){D.push(h[0]);while(D.length>0&&E){var c=D[0];D.splice(0,1),O.add(c);var d=c.getEdges();for(var v=0;v<d.length;v++){var A=d[v].getOtherEnd(c);if(R.get(c)!=A)if(!O.has(A))D.push(A),R.set(A,c);else{E=!1;break}}}if(!E)g=[];else{var I=[].concat(o(O));g.push(I);for(var v=0;v<I.length;v++){var C=I[v],M=h.indexOf(C);if(M>-1)h.splice(M,1)}O=new Set,R=new Map}}return g},u.prototype.createDummyNodesForBendpoints=function(g){var E=[],T=g.source,N=this.graphManager.calcLowestCommonAncestor(g.source,g.target);for(var v=0;v<g.bendpoints.length;v++){var O=this.newNode(null);O.setRect(new Point(0,0),new Dimension(1,1)),N.add(O);var D=this.newEdge(null);this.graphManager.add(D,T,O),E.add(O),T=O}var D=this.newEdge(null);if(this.graphManager.add(D,T,g.target),this.edgeToDummyNodes.set(g,E),g.isInterGraph())this.graphManager.remove(g);else N.remove(g);return E},u.prototype.createBendpointsFromDummyNodes=function(){var g=[];g=g.concat(this.graphManager.getAllEdges()),g=[].concat(o(this.edgeToDummyNodes.keys())).concat(g);for(var E=0;E<g.length;E++){var T=g[E];if(T.bendpoints.length>0){var N=this.edgeToDummyNodes.get(T);for(var v=0;v<N.length;v++){var O=N[v],D=new a(O.getCenterX(),O.getCenterY()),R=T.bendpoints.get(v);R.x=D.x,R.y=D.y,O.getOwner().remove(O)}this.graphManager.add(T,T.source,T.target)}}},u.transform=function(g,E,T,N){if(T!=null&&N!=null){var v=E;if(g<=50){var O=E/T;v-=(E-O)/50*(50-g)}else{var D=E*N;v+=(D-E)/50*(g-50)}return v}else{var R,h;if(g<=50)R=9*E/500,h=E/10;else R=9*E/50,h=-8*E;return R*g+h}},u.findCenterOfTree=function(g){var E=[];E=E.concat(g);var T=[],N=new Map,v=!1,O=null;if(E.length==1||E.length==2)v=!0,O=E[0];for(var D=0;D<E.length;D++){var R=E[D],h=R.getNeighborsList().size;if(N.set(R,R.getNeighborsList().size),h==1)T.push(R)}var c=[];c=c.concat(T);while(!v){var d=[];d=d.concat(c),c=[];for(var D=0;D<E.length;D++){var R=E[D],A=E.indexOf(R);if(A>=0)E.splice(A,1);var I=R.getNeighborsList();I.forEach(function(G){if(T.indexOf(G)<0){var F=N.get(G),P=F-1;if(P==1)c.push(G);N.set(G,P)}})}if(T=T.concat(c),E.length==1||E.length==2)v=!0,O=E[0]}return O},u.prototype.setGraphManager=function(g){this.graphManager=g},m.exports=u},function(m,w,L){function o(){}o.seed=1,o.x=0,o.nextDouble=function(){return o.x=Math.sin(o.seed++)*1e4,o.x-Math.floor(o.x)},m.exports=o},function(m,w,L){var o=L(4);function r(t,i){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}r.prototype.getWorldOrgX=function(){return this.lworldOrgX},r.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},r.prototype.getWorldOrgY=function(){return this.lworldOrgY},r.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},r.prototype.getWorldExtX=function(){return this.lworldExtX},r.prototype.setWorldExtX=function(t){this.lworldExtX=t},r.prototype.getWorldExtY=function(){return this.lworldExtY},r.prototype.setWorldExtY=function(t){this.lworldExtY=t},r.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},r.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},r.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},r.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},r.prototype.getDeviceExtX=function(){return this.ldeviceExtX},r.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},r.prototype.getDeviceExtY=function(){return this.ldeviceExtY},r.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},r.prototype.transformX=function(t){var i=0,l=this.lworldExtX;if(l!=0)i=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/l;return i},r.prototype.transformY=function(t){var i=0,l=this.lworldExtY;if(l!=0)i=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/l;return i},r.prototype.inverseTransformX=function(t){var i=0,l=this.ldeviceExtX;if(l!=0)i=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/l;return i},r.prototype.inverseTransformY=function(t){var i=0,l=this.ldeviceExtY;if(l!=0)i=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/l;return i},r.prototype.inverseTransformPoint=function(t){var i=new o(this.inverseTransformX(t.x),this.inverseTransformY(t.y));return i},m.exports=r},function(m,w,L){function o(s){if(Array.isArray(s)){for(var u=0,g=Array(s.length);u<s.length;u++)g[u]=s[u];return g}else return Array.from(s)}var r=L(15),t=L(7),i=L(0),l=L(8),f=L(9);function a(){r.call(this),this.useSmartIdealEdgeLengthCalculation=t.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=t.DEFAULT_EDGE_LENGTH,this.springConstant=t.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=t.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=t.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=t.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*t.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=t.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=t.MAX_ITERATIONS}a.prototype=Object.create(r.prototype);for(var y in r)a[y]=r[y];a.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=t.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},a.prototype.calcIdealEdgeLengths=function(){var s,u,g,E,T,N,v=this.getGraphManager().getAllEdges();for(var O=0;O<v.length;O++)if(s=v[O],s.idealLength=this.idealEdgeLength,s.isInterGraph){if(g=s.getSource(),E=s.getTarget(),T=s.getSourceInLca().getEstimatedSize(),N=s.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation)s.idealLength+=T+N-2*i.SIMPLE_NODE_SIZE;u=s.getLca().getInclusionTreeDepth(),s.idealLength+=t.DEFAULT_EDGE_LENGTH*t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(g.getInclusionTreeDepth()+E.getInclusionTreeDepth()-2*u)}},a.prototype.initSpringEmbedder=function(){var s=this.getAllNodes().length;if(this.incremental){if(s>t.ADAPTATION_LOWER_NODE_LIMIT)this.coolingFactor=Math.max(this.coolingFactor*t.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-t.COOLING_ADAPTATION_FACTOR));this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT_INCREMENTAL}else{if(s>t.ADAPTATION_LOWER_NODE_LIMIT)this.coolingFactor=Math.max(t.COOLING_ADAPTATION_FACTOR,1-(s-t.ADAPTATION_LOWER_NODE_LIMIT)/(t.ADAPTATION_UPPER_NODE_LIMIT-t.ADAPTATION_LOWER_NODE_LIMIT)*(1-t.COOLING_ADAPTATION_FACTOR));else this.coolingFactor=1;this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=t.MAX_NODE_DISPLACEMENT}this.maxIterations=Math.max(this.getAllNodes().length*5,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},a.prototype.calcSpringForces=function(){var s=this.getAllEdges(),u;for(var g=0;g<s.length;g++)u=s[g],this.calcSpringForce(u,u.idealLength)},a.prototype.calcRepulsionForces=function(){var s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,g,E,T,N,v=this.getAllNodes(),O;if(this.useFRGridVariant){if(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&s)this.updateGrid();O=new Set;for(g=0;g<v.length;g++)T=v[g],this.calculateRepulsionForceOfANode(T,O,s,u),O.add(T)}else for(g=0;g<v.length;g++){T=v[g];for(E=g+1;E<v.length;E++){if(N=v[E],T.getOwner()!=N.getOwner())continue;this.calcRepulsionForce(T,N)}}},a.prototype.calcGravitationalForces=function(){var s,u=this.getAllNodesToApplyGravitation();for(var g=0;g<u.length;g++)s=u[g],this.calcGravitationalForce(s)},a.prototype.moveNodes=function(){var s=this.getAllNodes(),u;for(var g=0;g<s.length;g++)u=s[g],u.move()},a.prototype.calcSpringForce=function(s,u){var g=s.getSource(),E=s.getTarget(),T,N,v,O;if(this.uniformLeafNodeSizes&&g.getChild()==null&&E.getChild()==null)s.updateLengthSimple();else if(s.updateLength(),s.isOverlapingSourceAndTarget)return;if(T=s.getLength(),T==0)return;N=this.springConstant*(T-u),v=N*(s.lengthX/T),O=N*(s.lengthY/T),g.springForceX+=v,g.springForceY+=O,E.springForceX-=v,E.springForceY-=O},a.prototype.calcRepulsionForce=function(s,u){var g=s.getRect(),E=u.getRect(),T=[,,],N=[,,,,],v,O,D,R,h,c,d;if(g.intersects(E)){l.calcSeparationAmount(g,E,T,t.DEFAULT_EDGE_LENGTH/2),c=2*T[0],d=2*T[1];var A=s.noOfChildren*u.noOfChildren/(s.noOfChildren+u.noOfChildren);s.repulsionForceX-=A*c,s.repulsionForceY-=A*d,u.repulsionForceX+=A*c,u.repulsionForceY+=A*d}else{if(this.uniformLeafNodeSizes&&s.getChild()==null&&u.getChild()==null)v=E.getCenterX()-g.getCenterX(),O=E.getCenterY()-g.getCenterY();else l.getIntersection(g,E,N),v=N[2]-N[0],O=N[3]-N[1];if(Math.abs(v)<t.MIN_REPULSION_DIST)v=f.sign(v)*t.MIN_REPULSION_DIST;if(Math.abs(O)<t.MIN_REPULSION_DIST)O=f.sign(O)*t.MIN_REPULSION_DIST;D=v*v+O*O,R=Math.sqrt(D),h=this.repulsionConstant*s.noOfChildren*u.noOfChildren/D,c=h*v/R,d=h*O/R,s.repulsionForceX-=c,s.repulsionForceY-=d,u.repulsionForceX+=c,u.repulsionForceY+=d}},a.prototype.calcGravitationalForce=function(s){var u,g,E,T,N,v,O,D;if(u=s.getOwner(),g=(u.getRight()+u.getLeft())/2,E=(u.getTop()+u.getBottom())/2,T=s.getCenterX()-g,N=s.getCenterY()-E,v=Math.abs(T)+s.getWidth()/2,O=Math.abs(N)+s.getHeight()/2,s.getOwner()==this.graphManager.getRoot()){if(D=u.getEstimatedSize()*this.gravityRangeFactor,v>D||O>D)s.gravitationForceX=-this.gravityConstant*T,s.gravitationForceY=-this.gravityConstant*N}else if(D=u.getEstimatedSize()*this.compoundGravityRangeFactor,v>D||O>D)s.gravitationForceX=-this.gravityConstant*T*this.compoundGravityConstant,s.gravitationForceY=-this.gravityConstant*N*this.compoundGravityConstant},a.prototype.isConverged=function(){var s,u=!1;if(this.totalIterations>this.maxIterations/3)u=Math.abs(this.totalDisplacement-this.oldTotalDisplacement)<2;return s=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,s||u},a.prototype.animate=function(){if(this.animationDuringLayout&&!this.isSubLayout)if(this.notAnimatedIterations==this.animationPeriod)this.update(),this.notAnimatedIterations=0;else this.notAnimatedIterations++},a.prototype.calcNoOfChildrenForAllNodes=function(){var s,u=this.graphManager.getAllNodes();for(var g=0;g<u.length;g++)s=u[g],s.noOfChildren=s.getNoOfChildren()},a.prototype.calcGrid=function(s){var u=0,g=0;u=parseInt(Math.ceil((s.getRight()-s.getLeft())/this.repulsionRange)),g=parseInt(Math.ceil((s.getBottom()-s.getTop())/this.repulsionRange));var E=Array(u);for(var T=0;T<u;T++)E[T]=Array(g);for(var T=0;T<u;T++)for(var N=0;N<g;N++)E[T][N]=[];return E},a.prototype.addNodeToGrid=function(s,u,g){var E=0,T=0,N=0,v=0;E=parseInt(Math.floor((s.getRect().x-u)/this.repulsionRange)),T=parseInt(Math.floor((s.getRect().width+s.getRect().x-u)/this.repulsionRange)),N=parseInt(Math.floor((s.getRect().y-g)/this.repulsionRange)),v=parseInt(Math.floor((s.getRect().height+s.getRect().y-g)/this.repulsionRange));for(var O=E;O<=T;O++)for(var D=N;D<=v;D++)this.grid[O][D].push(s),s.setGridCoordinates(E,T,N,v)},a.prototype.updateGrid=function(){var s,u,g=this.getAllNodes();this.grid=this.calcGrid(this.graphManager.getRoot());for(s=0;s<g.length;s++)u=g[s],this.addNodeToGrid(u,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},a.prototype.calculateRepulsionForceOfANode=function(s,u,g,E){if(this.totalIterations%t.GRID_CALCULATION_CHECK_PERIOD==1&&g||E){var T=new Set;s.surrounding=[];var N,v=this.grid;for(var O=s.startX-1;O<s.finishX+2;O++)for(var D=s.startY-1;D<s.finishY+2;D++)if(!(O<0||D<0||O>=v.length||D>=v[0].length))for(var R=0;R<v[O][D].length;R++){if(N=v[O][D][R],s.getOwner()!=N.getOwner()||s==N)continue;if(!u.has(N)&&!T.has(N)){var h=Math.abs(s.getCenterX()-N.getCenterX())-(s.getWidth()/2+N.getWidth()/2),c=Math.abs(s.getCenterY()-N.getCenterY())-(s.getHeight()/2+N.getHeight()/2);if(h<=this.repulsionRange&&c<=this.repulsionRange)T.add(N)}}s.surrounding=[].concat(o(T))}for(O=0;O<s.surrounding.length;O++)this.calcRepulsionForce(s,s.surrounding[O])},a.prototype.calcRepulsionRange=function(){return 0},m.exports=a},function(m,w,L){var o=L(1),r=L(7);function t(l,f,a){o.call(this,l,f,a),this.idealLength=r.DEFAULT_EDGE_LENGTH}t.prototype=Object.create(o.prototype);for(var i in o)t[i]=o[i];m.exports=t},function(m,w,L){var o=L(3);function r(i,l,f,a){o.call(this,i,l,f,a),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0,this.startX=0,this.finishX=0,this.startY=0,this.finishY=0,this.surrounding=[]}r.prototype=Object.create(o.prototype);for(var t in o)r[t]=o[t];r.prototype.setGridCoordinates=function(i,l,f,a){this.startX=i,this.finishX=l,this.startY=f,this.finishY=a},m.exports=r},function(m,w,L){function o(r,t){if(this.width=0,this.height=0,r!==null&&t!==null)this.height=t,this.width=r}o.prototype.getWidth=function(){return this.width},o.prototype.setWidth=function(r){this.width=r},o.prototype.getHeight=function(){return this.height},o.prototype.setHeight=function(r){this.height=r},m.exports=o},function(m,w,L){var o=L(14);function r(){this.map={},this.keys=[]}r.prototype.put=function(t,i){var l=o.createID(t);if(!this.contains(l))this.map[l]=i,this.keys.push(t)},r.prototype.contains=function(t){var i=o.createID(t);return this.map[t]!=null},r.prototype.get=function(t){var i=o.createID(t);return this.map[i]},r.prototype.keySet=function(){return this.keys},m.exports=r},function(m,w,L){var o=L(14);function r(){this.set={}}r.prototype.add=function(t){var i=o.createID(t);if(!this.contains(i))this.set[i]=t},r.prototype.remove=function(t){delete this.set[o.createID(t)]},r.prototype.clear=function(){this.set={}},r.prototype.contains=function(t){return this.set[o.createID(t)]==t},r.prototype.isEmpty=function(){return this.size()===0},r.prototype.size=function(){return Object.keys(this.set).length},r.prototype.addAllTo=function(t){var i=Object.keys(this.set),l=i.length;for(var f=0;f<l;f++)t.push(this.set[i[f]])},r.prototype.size=function(){return Object.keys(this.set).length},r.prototype.addAll=function(t){var i=t.length;for(var l=0;l<i;l++){var f=t[l];this.add(f)}},m.exports=r},function(m,w,L){var o=function(){function l(f,a){for(var y=0;y<a.length;y++){var s=a[y];if(s.enumerable=s.enumerable||!1,s.configurable=!0,"value"in s)s.writable=!0;Object.defineProperty(f,s.key,s)}}return function(f,a,y){if(a)l(f.prototype,a);if(y)l(f,y);return f}}();function r(l,f){if(!(l instanceof f))throw TypeError("Cannot call a class as a function")}var t=L(11),i=function(){function l(f,a){if(r(this,l),a!==null||a!==void 0)this.compareFunction=this._defaultCompareFunction;var y=void 0;if(f instanceof t)y=f.size();else y=f.length;this._quicksort(f,0,y-1)}return o(l,[{key:"_quicksort",value:function(a,y,s){if(y<s){var u=this._partition(a,y,s);this._quicksort(a,y,u),this._quicksort(a,u+1,s)}}},{key:"_partition",value:function(a,y,s){var u=this._get(a,y),g=y,E=s;while(!0){while(this.compareFunction(u,this._get(a,E)))E--;while(this.compareFunction(this._get(a,g),u))g++;if(g<E)this._swap(a,g,E),g++,E--;else return E}}},{key:"_get",value:function(a,y){if(a instanceof t)return a.get_object_at(y);else return a[y]}},{key:"_set",value:function(a,y,s){if(a instanceof t)a.set_object_at(y,s);else a[y]=s}},{key:"_swap",value:function(a,y,s){var u=this._get(a,y);this._set(a,y,this._get(a,s)),this._set(a,s,u)}},{key:"_defaultCompareFunction",value:function(a,y){return y>a}}]),l}();m.exports=i},function(m,w,L){var o=function(){function i(l,f){for(var a=0;a<f.length;a++){var y=f[a];if(y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y)y.writable=!0;Object.defineProperty(l,y.key,y)}}return function(l,f,a){if(f)i(l.prototype,f);if(a)i(l,a);return l}}();function r(i,l){if(!(i instanceof l))throw TypeError("Cannot call a class as a function")}var t=function(){function i(l,f){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,y=arguments.length>3&&arguments[3]!==void 0?arguments[3]:-1,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:-1;r(this,i),this.sequence1=l,this.sequence2=f,this.match_score=a,this.mismatch_penalty=y,this.gap_penalty=s,this.iMax=l.length+1,this.jMax=f.length+1,this.grid=Array(this.iMax);for(var u=0;u<this.iMax;u++){this.grid[u]=Array(this.jMax);for(var g=0;g<this.jMax;g++)this.grid[u][g]=0}this.tracebackGrid=Array(this.iMax);for(var E=0;E<this.iMax;E++){this.tracebackGrid[E]=Array(this.jMax);for(var T=0;T<this.jMax;T++)this.tracebackGrid[E][T]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return o(i,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var f=1;f<this.jMax;f++)this.grid[0][f]=this.grid[0][f-1]+this.gap_penalty,this.tracebackGrid[0][f]=[!1,!1,!0];for(var a=1;a<this.iMax;a++)this.grid[a][0]=this.grid[a-1][0]+this.gap_penalty,this.tracebackGrid[a][0]=[!1,!0,!1];for(var y=1;y<this.iMax;y++)for(var s=1;s<this.jMax;s++){var u=void 0;if(this.sequence1[y-1]===this.sequence2[s-1])u=this.grid[y-1][s-1]+this.match_score;else u=this.grid[y-1][s-1]+this.mismatch_penalty;var g=this.grid[y-1][s]+this.gap_penalty,E=this.grid[y][s-1]+this.gap_penalty,T=[u,g,E],N=this.arrayAllMaxIndexes(T);this.grid[y][s]=T[N[0]],this.tracebackGrid[y][s]=[N.includes(0),N.includes(1),N.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var f=[];f.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});while(f[0]){var a=f[0],y=this.tracebackGrid[a.pos[0]][a.pos[1]];if(y[0])f.push({pos:[a.pos[0]-1,a.pos[1]-1],seq1:this.sequence1[a.pos[0]-1]+a.seq1,seq2:this.sequence2[a.pos[1]-1]+a.seq2});if(y[1])f.push({pos:[a.pos[0]-1,a.pos[1]],seq1:this.sequence1[a.pos[0]-1]+a.seq1,seq2:"-"+a.seq2});if(y[2])f.push({pos:[a.pos[0],a.pos[1]-1],seq1:"-"+a.seq1,seq2:this.sequence2[a.pos[1]-1]+a.seq2});if(a.pos[0]===0&&a.pos[1]===0)this.alignments.push({sequence1:a.seq1,sequence2:a.seq2});f.shift()}return this.alignments}},{key:"getAllIndexes",value:function(f,a){var y=[],s=-1;while((s=f.indexOf(a,s+1))!==-1)y.push(s);return y}},{key:"arrayAllMaxIndexes",value:function(f){return this.getAllIndexes(f,Math.max.apply(null,f))}}]),i}();m.exports=t},function(m,w,L){var o=function(){return};o.FDLayout=L(18),o.FDLayoutConstants=L(7),o.FDLayoutEdge=L(19),o.FDLayoutNode=L(20),o.DimensionD=L(21),o.HashMap=L(22),o.HashSet=L(23),o.IGeometry=L(8),o.IMath=L(9),o.Integer=L(10),o.Point=L(12),o.PointD=L(4),o.RandomSeed=L(16),o.RectangleD=L(13),o.Transform=L(17),o.UniqueIDGeneretor=L(14),o.Quicksort=L(24),o.LinkedList=L(11),o.LGraphObject=L(2),o.LGraph=L(5),o.LEdge=L(1),o.LGraphManager=L(6),o.LNode=L(3),o.Layout=L(15),o.LayoutConstants=L(0),o.NeedlemanWunsch=L(25),m.exports=o},function(m,w,L){function o(){this.listeners=[]}var r=o.prototype;r.addListener=function(t,i){this.listeners.push({event:t,callback:i})},r.removeListener=function(t,i){for(var l=this.listeners.length;l>=0;l--){var f=this.listeners[l];if(f.event===t&&f.callback===i)this.listeners.splice(l,1)}},r.emit=function(t,i){for(var l=0;l<this.listeners.length;l++){var f=this.listeners[l];if(t===f.event)f.callback(i)}},m.exports=o}])})});var J=We(function(Q,z){(function(w,L){if(typeof Q==="object"&&typeof z==="object")z.exports=L(q());else if(typeof define==="function"&&define.amd)define(["layout-base"],L);else if(typeof Q==="object")Q.coseBase=L(q());else w.coseBase=L(w.layoutBase)})(Q,function(m){return function(w){var L={};function o(r){if(L[r])return L[r].exports;var t=L[r]={i:r,l:!1,exports:{}};return w[r].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=w,o.c=L,o.i=function(r){return r},o.d=function(r,t,i){if(!o.o(r,t))Object.defineProperty(r,t,{configurable:!1,enumerable:!0,get:i})},o.n=function(r){var t=r&&r.__esModule?function(){return r.default}:function(){return r};return o.d(t,"a",t),t},o.o=function(r,t){return Object.prototype.hasOwnProperty.call(r,t)},o.p="",o(o.s=7)}([function(w,L){w.exports=m},function(w,L,o){var r=o(0).FDLayoutConstants;function t(){}for(var i in r)t[i]=r[i];t.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,t.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,t.DEFAULT_COMPONENT_SEPERATION=60,t.TILE=!0,t.TILING_PADDING_VERTICAL=10,t.TILING_PADDING_HORIZONTAL=10,t.TREE_REDUCTION_ON_INCREMENTAL=!1,w.exports=t},function(w,L,o){var r=o(0).FDLayoutEdge;function t(l,f,a){r.call(this,l,f,a)}t.prototype=Object.create(r.prototype);for(var i in r)t[i]=r[i];w.exports=t},function(w,L,o){var r=o(0).LGraph;function t(l,f,a){r.call(this,l,f,a)}t.prototype=Object.create(r.prototype);for(var i in r)t[i]=r[i];w.exports=t},function(w,L,o){var r=o(0).LGraphManager;function t(l){r.call(this,l)}t.prototype=Object.create(r.prototype);for(var i in r)t[i]=r[i];w.exports=t},function(w,L,o){var r=o(0).FDLayoutNode,t=o(0).IMath;function i(f,a,y,s){r.call(this,f,a,y,s)}i.prototype=Object.create(r.prototype);for(var l in r)i[l]=r[l];i.prototype.move=function(){var f=this.graphManager.getLayout();if(this.displacementX=f.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=f.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>f.coolingFactor*f.maxNodeDisplacement)this.displacementX=f.coolingFactor*f.maxNodeDisplacement*t.sign(this.displacementX);if(Math.abs(this.displacementY)>f.coolingFactor*f.maxNodeDisplacement)this.displacementY=f.coolingFactor*f.maxNodeDisplacement*t.sign(this.displacementY);if(this.child==null)this.moveBy(this.displacementX,this.displacementY);else if(this.child.getNodes().length==0)this.moveBy(this.displacementX,this.displacementY);else this.propogateDisplacementToChildren(this.displacementX,this.displacementY);f.totalDisplacement+=Math.abs(this.displacementX)+Math.abs(this.displacementY),this.springForceX=0,this.springForceY=0,this.repulsionForceX=0,this.repulsionForceY=0,this.gravitationForceX=0,this.gravitationForceY=0,this.displacementX=0,this.displacementY=0},i.prototype.propogateDisplacementToChildren=function(f,a){var y=this.getChild().getNodes(),s;for(var u=0;u<y.length;u++)if(s=y[u],s.getChild()==null)s.moveBy(f,a),s.displacementX+=f,s.displacementY+=a;else s.propogateDisplacementToChildren(f,a)},i.prototype.setPred1=function(f){this.pred1=f},i.prototype.getPred1=function(){return pred1},i.prototype.getPred2=function(){return pred2},i.prototype.setNext=function(f){this.next=f},i.prototype.getNext=function(){return next},i.prototype.setProcessed=function(f){this.processed=f},i.prototype.isProcessed=function(){return processed},w.exports=i},function(w,L,o){var r=o(0).FDLayout,t=o(4),i=o(3),l=o(5),f=o(2),a=o(1),y=o(0).FDLayoutConstants,s=o(0).LayoutConstants,u=o(0).Point,g=o(0).PointD,E=o(0).Layout,T=o(0).Integer,N=o(0).IGeometry,v=o(0).LGraph,O=o(0).Transform;function D(){r.call(this),this.toBeTiled={}}D.prototype=Object.create(r.prototype);for(var R in r)D[R]=r[R];D.prototype.newGraphManager=function(){var h=new t(this);return this.graphManager=h,h},D.prototype.newGraph=function(h){return new i(null,this.graphManager,h)},D.prototype.newNode=function(h){return new l(this.graphManager,h)},D.prototype.newEdge=function(h){return new f(null,null,h)},D.prototype.initParameters=function(){if(r.prototype.initParameters.call(this,arguments),!this.isSubLayout){if(a.DEFAULT_EDGE_LENGTH<10)this.idealEdgeLength=10;else this.idealEdgeLength=a.DEFAULT_EDGE_LENGTH;this.useSmartIdealEdgeLengthCalculation=a.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=y.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=y.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=y.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=y.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=y.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=y.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.prunedNodesAll=[],this.growTreeIterations=0,this.afterGrowthIterations=0,this.isTreeGrowing=!1,this.isGrowthFinished=!1,this.coolingCycle=0,this.maxCoolingCycle=this.maxIterations/y.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=y.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1}},D.prototype.layout=function(){var h=s.DEFAULT_CREATE_BENDS_AS_NEEDED;if(h)this.createBendpoints(),this.graphManager.resetAllEdges();return this.level=0,this.classicLayout()},D.prototype.classicLayout=function(){if(this.nodesWithGravity=this.calculateNodesToApplyGravitationTo(),this.graphManager.setAllNodesToApplyGravitation(this.nodesWithGravity),this.calcNoOfChildrenForAllNodes(),this.graphManager.calcLowestCommonAncestors(),this.graphManager.calcInclusionTreeDepths(),this.graphManager.getRoot().calcEstimatedSize(),this.calcIdealEdgeLengths(),!this.incremental){var h=this.getFlatForest();if(h.length>0)this.positionNodesRadially(h);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var c=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(A){return c.has(A)});this.graphManager.setAllNodesToApplyGravitation(d),this.positionNodesRandomly()}}else if(a.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var c=new Set(this.getAllNodes()),d=this.nodesWithGravity.filter(function(C){return c.has(C)});this.graphManager.setAllNodesToApplyGravitation(d)}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},D.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished)if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;if(this.totalIterations%y.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged())if(this.prunedNodesAll.length>0)this.isTreeGrowing=!0;else return!0;if(this.coolingCycle++,this.layoutQuality==0)this.coolingAdjuster=this.coolingCycle;else if(this.layoutQuality==1)this.coolingAdjuster=this.coolingCycle/3;this.coolingFactor=Math.max(this.initialCoolingFactor-Math.pow(this.coolingCycle,Math.log(100*(this.initialCoolingFactor-this.finalTemperature))/Math.log(this.maxCoolingCycle))/100*this.coolingAdjuster,this.finalTemperature),this.animationPeriod=Math.ceil(this.initialAnimationPeriod*Math.sqrt(this.coolingFactor))}if(this.isTreeGrowing){if(this.growTreeIterations%10==0)if(this.prunedNodesAll.length>0){this.graphManager.updateBounds(),this.updateGrid(),this.growTree(this.prunedNodesAll),this.graphManager.resetAllNodesToApplyGravitation();var h=new Set(this.getAllNodes()),c=this.nodesWithGravity.filter(function(I){return h.has(I)});this.graphManager.setAllNodesToApplyGravitation(c),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=y.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;if(this.afterGrowthIterations%10==0)this.graphManager.updateBounds(),this.updateGrid();this.coolingFactor=y.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var d=!this.isTreeGrowing&&!this.isGrowthFinished,A=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(d,A),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},D.prototype.getPositionsData=function(){var h=this.graphManager.getAllNodes(),c={};for(var d=0;d<h.length;d++){var A=h[d].rect,I=h[d].id;c[I]={id:I,x:A.getCenterX(),y:A.getCenterY(),w:A.width,h:A.height}}return c},D.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var h=!1;if(y.ANIMATE==="during")this.emit("layoutstarted");else{while(!h)h=this.tick();this.graphManager.updateBounds()}},D.prototype.calculateNodesToApplyGravitationTo=function(){var h=[],c,d=this.graphManager.getGraphs(),A=d.length,I;for(I=0;I<A;I++)if(c=d[I],c.updateConnected(),!c.isConnected)h=h.concat(c.getNodes());return h},D.prototype.createBendpoints=function(){var h=[];h=h.concat(this.graphManager.getAllEdges());var c=new Set,d;for(d=0;d<h.length;d++){var A=h[d];if(!c.has(A)){var I=A.getSource(),C=A.getTarget();if(I==C)A.getBendpoints().push(new g),A.getBendpoints().push(new g),this.createDummyNodesForBendpoints(A),c.add(A);else{var M=[];if(M=M.concat(I.getEdgeListToNode(C)),M=M.concat(C.getEdgeListToNode(I)),!c.has(M[0])){if(M.length>1){var G;for(G=0;G<M.length;G++){var F=M[G];F.getBendpoints().push(new g),this.createDummyNodesForBendpoints(F)}}M.forEach(function(P){c.add(P)})}}}if(c.size==h.length)break}},D.prototype.positionNodesRadially=function(h){var c=new u(0,0),d=Math.ceil(Math.sqrt(h.length)),A=0,I=0,C=0,M=new g(0,0);for(var G=0;G<h.length;G++){if(G%d==0){if(C=0,I=A,G!=0)I+=a.DEFAULT_COMPONENT_SEPERATION;A=0}var F=h[G],P=E.findCenterOfTree(F);if(c.x=C,c.y=I,M=D.radialLayout(F,P,c),M.y>A)A=Math.floor(M.y);C=Math.floor(M.x+a.DEFAULT_COMPONENT_SEPERATION)}this.transform(new g(s.WORLD_CENTER_X-M.x/2,s.WORLD_CENTER_Y-M.y/2))},D.radialLayout=function(h,c,d){var A=Math.max(this.maxDiagonalInTree(h),a.DEFAULT_RADIAL_SEPARATION);D.branchRadialLayout(c,null,0,359,0,A);var I=v.calculateBounds(h),C=new O;C.setDeviceOrgX(I.getMinX()),C.setDeviceOrgY(I.getMinY()),C.setWorldOrgX(d.x),C.setWorldOrgY(d.y);for(var M=0;M<h.length;M++){var G=h[M];G.transform(C)}var F=new g(I.getMaxX(),I.getMaxY());return C.inverseTransformPoint(F)},D.branchRadialLayout=function(h,c,d,A,I,C){var M=(A-d+1)/2;if(M<0)M+=180;var G=(M+d)%360,F=G*N.TWO_PI/360,P=Math.cos(F),b=I*Math.cos(F),U=I*Math.sin(F);h.setCenter(b,U);var x=[];x=x.concat(h.getEdges());var S=x.length;if(c!=null)S--;var Y=0,X=x.length,H,_=h.getEdgesBetween(c);while(_.length>1){var W=_[0];_.splice(0,1);var k=x.indexOf(W);if(k>=0)x.splice(k,1);X--,S--}if(c!=null)H=(x.indexOf(_[0])+1)%X;else H=0;var B=Math.abs(A-d)/S;for(var V=H;Y!=S;V=++V%X){var et=x[V].getOtherEnd(h);if(et==c)continue;var rt=(d+Y*B)%360,ft=(rt+B)%360;D.branchRadialLayout(et,h,rt,ft,I+C,C),Y++}},D.maxDiagonalInTree=function(h){var c=T.MIN_VALUE;for(var d=0;d<h.length;d++){var A=h[d],I=A.getDiagonal();if(I>c)c=I}return c},D.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},D.prototype.groupZeroDegreeMembers=function(){var h=this,c={};this.memberGroups={},this.idToDummyNode={};var d=[],A=this.graphManager.getAllNodes();for(var I=0;I<A.length;I++){var C=A[I],M=C.getParent();if(this.getNodeDegreeWithChildren(C)===0&&(M.id==null||!this.getToBeTiled(M)))d.push(C)}for(var I=0;I<d.length;I++){var C=d[I],G=C.getParent().id;if(typeof c[G]>"u")c[G]=[];c[G]=c[G].concat(C)}Object.keys(c).forEach(function(F){if(c[F].length>1){var P="DummyCompound_"+F;h.memberGroups[P]=c[F];var b=c[F][0].getParent(),U=new l(h.graphManager);U.id=P,U.paddingLeft=b.paddingLeft||0,U.paddingRight=b.paddingRight||0,U.paddingBottom=b.paddingBottom||0,U.paddingTop=b.paddingTop||0,h.idToDummyNode[P]=U;var x=h.getGraphManager().add(h.newGraph(),U),S=b.getChild();S.add(U);for(var Y=0;Y<c[F].length;Y++){var X=c[F][Y];S.remove(X),x.add(X)}}})},D.prototype.clearCompounds=function(){var h={},c={};this.performDFSOnCompounds();for(var d=0;d<this.compoundOrder.length;d++)c[this.compoundOrder[d].id]=this.compoundOrder[d],h[this.compoundOrder[d].id]=[].concat(this.compoundOrder[d].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[d].getChild()),this.compoundOrder[d].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(h,c)},D.prototype.clearZeroDegreeMembers=function(){var h=this,c=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach(function(d){var A=h.idToDummyNode[d];c[d]=h.tileNodes(h.memberGroups[d],A.paddingLeft+A.paddingRight),A.rect.width=c[d].width,A.rect.height=c[d].height})},D.prototype.repopulateCompounds=function(){for(var h=this.compoundOrder.length-1;h>=0;h--){var c=this.compoundOrder[h],{id:d,paddingLeft:A,paddingTop:I}=c;this.adjustLocations(this.tiledMemberPack[d],c.rect.x,c.rect.y,A,I)}},D.prototype.repopulateZeroDegreeMembers=function(){var h=this,c=this.tiledZeroDegreePack;Object.keys(c).forEach(function(d){var A=h.idToDummyNode[d],{paddingLeft:I,paddingTop:C}=A;h.adjustLocations(c[d],A.rect.x,A.rect.y,I,C)})},D.prototype.getToBeTiled=function(h){var c=h.id;if(this.toBeTiled[c]!=null)return this.toBeTiled[c];var d=h.getChild();if(d==null)return this.toBeTiled[c]=!1,!1;var A=d.getNodes();for(var I=0;I<A.length;I++){var C=A[I];if(this.getNodeDegree(C)>0)return this.toBeTiled[c]=!1,!1;if(C.getChild()==null){this.toBeTiled[C.id]=!1;continue}if(!this.getToBeTiled(C))return this.toBeTiled[c]=!1,!1}return this.toBeTiled[c]=!0,!0},D.prototype.getNodeDegree=function(h){var c=h.id,d=h.getEdges(),A=0;for(var I=0;I<d.length;I++){var C=d[I];if(C.getSource().id!==C.getTarget().id)A=A+1}return A},D.prototype.getNodeDegreeWithChildren=function(h){var c=this.getNodeDegree(h);if(h.getChild()==null)return c;var d=h.getChild().getNodes();for(var A=0;A<d.length;A++){var I=d[A];c+=this.getNodeDegreeWithChildren(I)}return c},D.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},D.prototype.fillCompexOrderByDFS=function(h){for(var c=0;c<h.length;c++){var d=h[c];if(d.getChild()!=null)this.fillCompexOrderByDFS(d.getChild().getNodes());if(this.getToBeTiled(d))this.compoundOrder.push(d)}},D.prototype.adjustLocations=function(h,c,d,A,I){c+=A,d+=I;var C=c;for(var M=0;M<h.rows.length;M++){var G=h.rows[M];c=C;var F=0;for(var P=0;P<G.length;P++){var b=G[P];if(b.rect.x=c,b.rect.y=d,c+=b.rect.width+h.horizontalPadding,b.rect.height>F)F=b.rect.height}d+=F+h.verticalPadding}},D.prototype.tileCompoundMembers=function(h,c){var d=this;this.tiledMemberPack=[],Object.keys(h).forEach(function(A){var I=c[A];d.tiledMemberPack[A]=d.tileNodes(h[A],I.paddingLeft+I.paddingRight),I.rect.width=d.tiledMemberPack[A].width,I.rect.height=d.tiledMemberPack[A].height})},D.prototype.tileNodes=function(h,c){var{TILING_PADDING_VERTICAL:d,TILING_PADDING_HORIZONTAL:A}=a,I={rows:[],rowWidth:[],rowHeight:[],width:0,height:c,verticalPadding:d,horizontalPadding:A};h.sort(function(G,F){if(G.rect.width*G.rect.height>F.rect.width*F.rect.height)return-1;if(G.rect.width*G.rect.height<F.rect.width*F.rect.height)return 1;return 0});for(var C=0;C<h.length;C++){var M=h[C];if(I.rows.length==0)this.insertNodeToRow(I,M,0,c);else if(this.canAddHorizontal(I,M.rect.width,M.rect.height))this.insertNodeToRow(I,M,this.getShortestRowIndex(I),c);else this.insertNodeToRow(I,M,I.rows.length,c);this.shiftToLastRow(I)}return I},D.prototype.insertNodeToRow=function(h,c,d,A){var I=A;if(d==h.rows.length){var C=[];h.rows.push(C),h.rowWidth.push(I),h.rowHeight.push(0)}var M=h.rowWidth[d]+c.rect.width;if(h.rows[d].length>0)M+=h.horizontalPadding;if(h.rowWidth[d]=M,h.width<M)h.width=M;var G=c.rect.height;if(d>0)G+=h.verticalPadding;var F=0;if(G>h.rowHeight[d])F=h.rowHeight[d],h.rowHeight[d]=G,F=h.rowHeight[d]-F;h.height+=F,h.rows[d].push(c)},D.prototype.getShortestRowIndex=function(h){var c=-1,d=Number.MAX_VALUE;for(var A=0;A<h.rows.length;A++)if(h.rowWidth[A]<d)c=A,d=h.rowWidth[A];return c},D.prototype.getLongestRowIndex=function(h){var c=-1,d=Number.MIN_VALUE;for(var A=0;A<h.rows.length;A++)if(h.rowWidth[A]>d)c=A,d=h.rowWidth[A];return c},D.prototype.canAddHorizontal=function(h,c,d){var A=this.getShortestRowIndex(h);if(A<0)return!0;var I=h.rowWidth[A];if(I+h.horizontalPadding+c<=h.width)return!0;var C=0;if(h.rowHeight[A]<d){if(A>0)C=d+h.verticalPadding-h.rowHeight[A]}var M;if(h.width-I>=c+h.horizontalPadding)M=(h.height+C)/(I+c+h.horizontalPadding);else M=(h.height+C)/h.width;C=d+h.verticalPadding;var G;if(h.width<c)G=(h.height+C)/c;else G=(h.height+C)/h.width;if(G<1)G=1/G;if(M<1)M=1/M;return M<G},D.prototype.shiftToLastRow=function(h){var c=this.getLongestRowIndex(h),d=h.rowWidth.length-1,A=h.rows[c],I=A[A.length-1],C=I.width+h.horizontalPadding;if(h.width-h.rowWidth[d]>C&&c!=d){A.splice(-1,1),h.rows[d].push(I),h.rowWidth[c]=h.rowWidth[c]-C,h.rowWidth[d]=h.rowWidth[d]+C,h.width=h.rowWidth[instance.getLongestRowIndex(h)];var M=Number.MIN_VALUE;for(var G=0;G<A.length;G++)if(A[G].height>M)M=A[G].height;if(c>0)M+=h.verticalPadding;var F=h.rowHeight[c]+h.rowHeight[d];if(h.rowHeight[c]=M,h.rowHeight[d]<I.height+h.verticalPadding)h.rowHeight[d]=I.height+h.verticalPadding;var P=h.rowHeight[c]+h.rowHeight[d];h.height+=P-F,this.shiftToLastRow(h)}},D.prototype.tilingPreLayout=function(){if(a.TILE)this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers()},D.prototype.tilingPostLayout=function(){if(a.TILE)this.repopulateZeroDegreeMembers(),this.repopulateCompounds()},D.prototype.reduceTrees=function(){var h=[],c=!0,d;while(c){var A=this.graphManager.getAllNodes(),I=[];c=!1;for(var C=0;C<A.length;C++)if(d=A[C],d.getEdges().length==1&&!d.getEdges()[0].isInterGraph&&d.getChild()==null)I.push([d,d.getEdges()[0],d.getOwner()]),c=!0;if(c==!0){var M=[];for(var G=0;G<I.length;G++)if(I[G][0].getEdges().length==1)M.push(I[G]),I[G][0].getOwner().remove(I[G][0]);h.push(M),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=h},D.prototype.growTree=function(h){var c=h.length,d=h[c-1],A;for(var I=0;I<d.length;I++)A=d[I],this.findPlaceforPrunedNode(A),A[2].add(A[0]),A[2].add(A[1],A[1].source,A[1].target);h.splice(h.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},D.prototype.findPlaceforPrunedNode=function(h){var c,d,A=h[0];if(A==h[1].source)d=h[1].target;else d=h[1].source;var I=d.startX,C=d.finishX,M=d.startY,G=d.finishY,F=0,P=0,b=0,U=0,x=[F,b,P,U];if(M>0)for(var S=I;S<=C;S++)x[0]+=this.grid[S][M-1].length+this.grid[S][M].length-1;if(C<this.grid.length-1)for(var S=M;S<=G;S++)x[1]+=this.grid[C+1][S].length+this.grid[C][S].length-1;if(G<this.grid[0].length-1)for(var S=I;S<=C;S++)x[2]+=this.grid[S][G+1].length+this.grid[S][G].length-1;if(I>0)for(var S=M;S<=G;S++)x[3]+=this.grid[I-1][S].length+this.grid[I][S].length-1;var Y=T.MAX_VALUE,X,H;for(var _=0;_<x.length;_++)if(x[_]<Y)Y=x[_],X=1,H=_;else if(x[_]==Y)X++;if(X==3&&Y==0){if(x[0]==0&&x[1]==0&&x[2]==0)c=1;else if(x[0]==0&&x[1]==0&&x[3]==0)c=0;else if(x[0]==0&&x[2]==0&&x[3]==0)c=3;else if(x[1]==0&&x[2]==0&&x[3]==0)c=2}else if(X==2&&Y==0){var W=Math.floor(Math.random()*2);if(x[0]==0&&x[1]==0)if(W==0)c=0;else c=1;else if(x[0]==0&&x[2]==0)if(W==0)c=0;else c=2;else if(x[0]==0&&x[3]==0)if(W==0)c=0;else c=3;else if(x[1]==0&&x[2]==0)if(W==0)c=1;else c=2;else if(x[1]==0&&x[3]==0)if(W==0)c=1;else c=3;else if(W==0)c=2;else c=3}else if(X==4&&Y==0){var W=Math.floor(Math.random()*4);c=W}else c=H;if(c==0)A.setCenter(d.getCenterX(),d.getCenterY()-d.getHeight()/2-y.DEFAULT_EDGE_LENGTH-A.getHeight()/2);else if(c==1)A.setCenter(d.getCenterX()+d.getWidth()/2+y.DEFAULT_EDGE_LENGTH+A.getWidth()/2,d.getCenterY());else if(c==2)A.setCenter(d.getCenterX(),d.getCenterY()+d.getHeight()/2+y.DEFAULT_EDGE_LENGTH+A.getHeight()/2);else A.setCenter(d.getCenterX()-d.getWidth()/2-y.DEFAULT_EDGE_LENGTH-A.getWidth()/2,d.getCenterY())},w.exports=D},function(w,L,o){var r={};r.layoutBase=o(0),r.CoSEConstants=o(1),r.CoSEEdge=o(2),r.CoSEGraph=o(3),r.CoSEGraphManager=o(4),r.CoSELayout=o(6),r.CoSENode=o(5),w.exports=r}])})});var it=We(function(j,tt){(function(w,L){if(typeof j==="object"&&typeof tt==="object")tt.exports=L(J());else if(typeof define==="function"&&define.amd)define(["cose-base"],L);else if(typeof j==="object")j.cytoscapeCoseBilkent=L(J());else w.cytoscapeCoseBilkent=L(w.coseBase)})(j,function(m){return function(w){var L={};function o(r){if(L[r])return L[r].exports;var t=L[r]={i:r,l:!1,exports:{}};return w[r].call(t.exports,t,t.exports,o),t.l=!0,t.exports}return o.m=w,o.c=L,o.i=function(r){return r},o.d=function(r,t,i){if(!o.o(r,t))Object.defineProperty(r,t,{configurable:!1,enumerable:!0,get:i})},o.n=function(r){var t=r&&r.__esModule?function(){return r.default}:function(){return r};return o.d(t,"a",t),t},o.o=function(r,t){return Object.prototype.hasOwnProperty.call(r,t)},o.p="",o(o.s=1)}([function(w,L){w.exports=m},function(w,L,o){var r=o(0).layoutBase.LayoutConstants,t=o(0).layoutBase.FDLayoutConstants,i=o(0).CoSEConstants,l=o(0).CoSELayout,f=o(0).CoSENode,a=o(0).layoutBase.PointD,y=o(0).layoutBase.DimensionD,s={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:0.45,nestingFactor:0.1,gravity:0.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:0.5};function u(N,v){var O={};for(var D in N)O[D]=N[D];for(var D in v)O[D]=v[D];return O}function g(N){this.options=u(s,N),E(this.options)}var E=function(v){if(v.nodeRepulsion!=null)i.DEFAULT_REPULSION_STRENGTH=t.DEFAULT_REPULSION_STRENGTH=v.nodeRepulsion;if(v.idealEdgeLength!=null)i.DEFAULT_EDGE_LENGTH=t.DEFAULT_EDGE_LENGTH=v.idealEdgeLength;if(v.edgeElasticity!=null)i.DEFAULT_SPRING_STRENGTH=t.DEFAULT_SPRING_STRENGTH=v.edgeElasticity;if(v.nestingFactor!=null)i.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=v.nestingFactor;if(v.gravity!=null)i.DEFAULT_GRAVITY_STRENGTH=t.DEFAULT_GRAVITY_STRENGTH=v.gravity;if(v.numIter!=null)i.MAX_ITERATIONS=t.MAX_ITERATIONS=v.numIter;if(v.gravityRange!=null)i.DEFAULT_GRAVITY_RANGE_FACTOR=t.DEFAULT_GRAVITY_RANGE_FACTOR=v.gravityRange;if(v.gravityCompound!=null)i.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.DEFAULT_COMPOUND_GRAVITY_STRENGTH=v.gravityCompound;if(v.gravityRangeCompound!=null)i.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=v.gravityRangeCompound;if(v.initialEnergyOnIncremental!=null)i.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.DEFAULT_COOLING_FACTOR_INCREMENTAL=v.initialEnergyOnIncremental;if(v.quality=="draft")r.QUALITY=0;else if(v.quality=="proof")r.QUALITY=2;else r.QUALITY=1;i.NODE_DIMENSIONS_INCLUDE_LABELS=t.NODE_DIMENSIONS_INCLUDE_LABELS=r.NODE_DIMENSIONS_INCLUDE_LABELS=v.nodeDimensionsIncludeLabels,i.DEFAULT_INCREMENTAL=t.DEFAULT_INCREMENTAL=r.DEFAULT_INCREMENTAL=!v.randomize,i.ANIMATE=t.ANIMATE=r.ANIMATE=v.animate,i.TILE=v.tile,i.TILING_PADDING_VERTICAL=typeof v.tilingPaddingVertical==="function"?v.tilingPaddingVertical.call():v.tilingPaddingVertical,i.TILING_PADDING_HORIZONTAL=typeof v.tilingPaddingHorizontal==="function"?v.tilingPaddingHorizontal.call():v.tilingPaddingHorizontal};g.prototype.run=function(){var N,v,O=this.options,D=this.idToLNode={},R=this.layout=new l,h=this;h.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this});var c=R.newGraphManager();this.gm=c;var d=this.options.eles.nodes(),A=this.options.eles.edges();this.root=c.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(d),R);for(var I=0;I<A.length;I++){var C=A[I],M=this.idToLNode[C.data("source")],G=this.idToLNode[C.data("target")];if(M!==G&&M.getEdgesBetween(G).length==0){var F=c.add(R.newEdge(),M,G);F.id=C.id()}}var P=function(x,S){if(typeof x==="number")x=S;var Y=x.data("id"),X=h.idToLNode[Y];return{x:X.getRect().getCenterX(),y:X.getRect().getCenterY()}},b=function U(){var x=function(){if(O.fit)O.cy.fit(O.eles,O.padding);if(!N)N=!0,h.cy.one("layoutready",O.ready),h.cy.trigger({type:"layoutready",layout:h})},S=h.options.refresh,Y;for(var X=0;X<S&&!Y;X++)Y=h.stopped||h.layout.tick();if(Y){if(R.checkLayoutSuccess()&&!R.isSubLayout)R.doPostLayout();if(R.tilingPostLayout)R.tilingPostLayout();if(R.isLayoutFinished=!0,h.options.eles.nodes().positions(P),x(),h.cy.one("layoutstop",h.options.stop),h.cy.trigger({type:"layoutstop",layout:h}),v)cancelAnimationFrame(v);N=!1;return}var H=h.layout.getPositionsData();O.eles.nodes().positions(function(_,W){if(typeof _==="number")_=W;if(!_.isParent()){var k=_.id(),B=H[k],V=_;while(B==null)if(B=H[V.data("parent")]||H["DummyCompound_"+V.data("parent")],H[k]=B,V=V.parent()[0],V==null)break;if(B!=null)return{x:B.x,y:B.y};else return{x:_.position("x"),y:_.position("y")}}}),x(),v=requestAnimationFrame(U)};if(R.addListener("layoutstarted",function(){if(h.options.animate==="during")v=requestAnimationFrame(b)}),R.runLayout(),this.options.animate!=="during")h.options.eles.nodes().not(":parent").layoutPositions(h,h.options,P),N=!1;return this},g.prototype.getTopMostNodes=function(N){var v={};for(var O=0;O<N.length;O++)v[N[O].id()]=!0;var D=N.filter(function(R,h){if(typeof R==="number")R=h;var c=R.parent()[0];while(c!=null){if(v[c.id()])return!1;c=c.parent()[0]}return!0});return D},g.prototype.processChildrenList=function(N,v,O){var D=v.length;for(var R=0;R<D;R++){var h=v[R],c=h.children(),d,A=h.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});if(h.outerWidth()!=null&&h.outerHeight()!=null)d=N.add(new f(O.graphManager,new a(h.position("x")-A.w/2,h.position("y")-A.h/2),new y(parseFloat(A.w),parseFloat(A.h))));else d=N.add(new f(this.graphManager));if(d.id=h.data("id"),d.paddingLeft=parseInt(h.css("padding")),d.paddingTop=parseInt(h.css("padding")),d.paddingRight=parseInt(h.css("padding")),d.paddingBottom=parseInt(h.css("padding")),this.options.nodeDimensionsIncludeLabels){if(h.isParent()){var I=h.boundingBox({includeLabels:!0,includeNodes:!1}).w,C=h.boundingBox({includeLabels:!0,includeNodes:!1}).h,M=h.css("text-halign");d.labelWidth=I,d.labelHeight=C,d.labelPos=M}}if(this.idToLNode[h.data("id")]=d,isNaN(d.rect.x))d.rect.x=0;if(isNaN(d.rect.y))d.rect.y=0;if(c!=null&&c.length>0){var G=O.getGraphManager().add(O.newGraph(),d);this.processChildrenList(G,c,O)}}},g.prototype.stop=function(){return this.stopped=!0,this};var T=function(v){v("layout","cose-bilkent",g)};if(typeof cytoscape<"u")T(cytoscape);w.exports=T}])})});var nt=Pe(it(),1);xt.use(nt.default);function st(m,w){m.forEach((L)=>{let o={id:L.id,labelText:L.label,height:L.height,width:L.width,padding:L.padding??0};Object.keys(L).forEach((r)=>{if(!["id","label","height","width","padding","x","y"].includes(r))o[r]=L[r]}),w.add({group:"nodes",data:o,position:{x:L.x??0,y:L.y??0}})})}e(st,"addNodes");function ot(m,w){m.forEach((L)=>{let o={id:L.id,source:L.start,target:L.end};Object.keys(L).forEach((r)=>{if(!["id","start","end"].includes(r))o[r]=L[r]}),w.add({group:"edges",data:o})})}e(ot,"addEdges");function at(m){return new Promise((w)=>{let L=p("body").append("div").attr("id","cy").attr("style","display:none"),o=xt({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});L.remove(),st(m.nodes,o),ot(m.edges,o),o.nodes().forEach(function(t){t.layoutDimensions=()=>{let i=t.data();return{w:i.width,h:i.height}}});let r={name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1};o.layout(r).run(),o.ready((t)=>{n.info("Cytoscape ready",t),w(o)})})}e(at,"createCytoscapeInstance");function ht(m){return m.nodes().map((w)=>{let L=w.data(),o=w.position(),r={id:L.id,x:o.x,y:o.y};return Object.keys(L).forEach((t)=>{if(t!=="id")r[t]=L[t]}),r})}e(ht,"extractPositionedNodes");function lt(m){return m.edges().map((w)=>{let L=w.data(),o=w._private.rscratch,r={id:L.id,source:L.source,target:L.target,startX:o.startX,startY:o.startY,midX:o.midX,midY:o.midY,endX:o.endX,endY:o.endY};return Object.keys(L).forEach((t)=>{if(!["id","source","target"].includes(t))r[t]=L[t]}),r})}e(lt,"extractPositionedEdges");async function ut(m,w){n.debug("Starting cose-bilkent layout algorithm");try{gt(m);let L=await at(m),o=ht(L),r=lt(L);return n.debug(`Layout completed: ${o.length} nodes, ${r.length} edges`),{nodes:o,edges:r}}catch(L){throw n.error("Error in cose-bilkent layout algorithm:",L),L}}e(ut,"executeCoseBilkentLayout");function gt(m){if(!m)throw Error("Layout data is required");if(!m.config)throw Error("Configuration is required in layout data");if(!m.rootNode)throw Error("Root node is required");if(!m.nodes||!Array.isArray(m.nodes))throw Error("No nodes found in layout data");if(!Array.isArray(m.edges))throw Error("Edges array is required in layout data");return!0}e(gt,"validateLayoutData");var ct=e(async(m,w,{insertCluster:L,insertEdge:o,insertEdgeLabel:r,insertMarkers:t,insertNode:i,log:l,positionEdgeLabel:f},{algorithm:a})=>{let y={},s={},u=w.select("g");t(u,m.markers,m.type,m.diagramId);let g=u.insert("g").attr("class","subgraphs"),E=u.insert("g").attr("class","edgePaths"),T=u.insert("g").attr("class","edgeLabels"),N=u.insert("g").attr("class","nodes");l.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(m.nodes.map(async(D)=>{if(D.isGroup){let R={...D};s[D.id]=R,y[D.id]=R,await L(g,D)}else{let R={...D};y[D.id]=R;let h=await i(N,D,{config:m.config,dir:m.direction||"TB"}),c=h.node().getBBox();R.width=c.width,R.height=c.height,R.domId=h,l.debug(`Node ${D.id} dimensions: ${c.width}x${c.height}`)}})),l.debug("Running cose-bilkent layout algorithm");let v={...m,nodes:m.nodes.map((D)=>{let R=y[D.id];return{...D,width:R.width,height:R.height}})},O=await ut(v,m.config);l.debug("Positioning nodes based on layout results"),O.nodes.forEach((D)=>{let R=y[D.id];if(R?.domId)R.domId.attr("transform",`translate(${D.x}, ${D.y})`),R.x=D.x,R.y=D.y,l.debug(`Positioned node ${R.id} at center (${D.x}, ${D.y})`)}),O.edges.forEach((D)=>{let R=m.edges.find((h)=>h.id===D.id);if(R)R.points=[{x:D.startX,y:D.startY},{x:D.midX,y:D.midY},{x:D.endX,y:D.endY}]}),l.debug("Inserting and positioning edges"),await Promise.all(m.edges.map(async(D)=>{let R=await r(T,D),h=y[D.start??""],c=y[D.end??""];if(h&&c){let d=O.edges.find((A)=>A.id===D.id);if(d){l.debug("APA01 positionedEdge",d);let A={...D},I=o(E,A,s,m.type,h,c,m.diagramId);f(A,I)}else{let A={...D,points:[{x:h.x||0,y:h.y||0},{x:c.x||0,y:c.y||0}]},I=o(E,A,s,m.type,h,c,m.diagramId);f(A,I)}}})),l.debug("Cose-bilkent rendering completed")},"render"),Et=ct;export{Et as render};
@@ -0,0 +1 @@
1
+ import{Qo}from"./index.6pzexww5.js";export{Qo as createCynefinServices};
@@ -1,4 +1,4 @@
1
- import{ee}from"./index.r0p3fm9f.js";import{e,n,Me,F,k,j,A,L,R,I,M,D,O,Y,K}from"./index.a1bxkgd3.js";import{se}from"./index.7gxz6d1f.js";var ut=e(()=>({domains:new Map,transitions:[]}),"createDefaultData"),et=ut(),At=e(()=>et.domains,"getDomains"),Bt=e(()=>et.transitions,"getTransitions"),St=e((t)=>{if(!t)return;for(let o of t){let a=o.domain,r=(o.items??[]).map((l)=>({label:l.label}));et.domains.set(a,{name:a,items:r})}},"setDomains"),Mt=e((t)=>{if(!t)return;et.transitions=t.filter((o)=>{if(o.from===o.to)return n.warn(`Cynefin: self-loop transition on domain "${o.from}" is not meaningful and will be skipped.`),!1;return!0}).map((o)=>({from:o.from,to:o.to,label:o.label||void 0}))},"setTransitions"),zt=e(()=>K({...F.cynefin,...k().cynefin}),"getConfig"),Lt=e(()=>{A(),et=ut()},"clear"),at={getDomains:At,getTransitions:Bt,setDomains:St,setTransitions:Mt,getConfig:zt,clear:Lt,setAccTitle:L,getAccTitle:R,setDiagramTitle:D,getDiagramTitle:O,getAccDescription:M,setAccDescription:I},Nt=e((t)=>{ee(t,at),at.setDomains(t.domains),at.setTransitions(t.transitions)},"populate"),Pt={parse:e(async(t)=>{let o=await se("cynefin",t);n.debug(o),Nt(o)},"parse")};function tt(t){let o=t+1831565813|0;return o=Math.imul(o^o>>>15,o|1),o^=o+Math.imul(o^o>>>7,o|61),((o^o>>>14)>>>0)/4294967296}e(tt,"seededRandom");function gt(t){let o=0;for(let a=0;a<t.length;a++){let r=t.charCodeAt(a);o=(o<<5)-o+r,o|=0}return o}e(gt,"hashString");function ht(t,o){if(typeof t==="number"&&Number.isFinite(t)&&t!==0)return t;return gt(o)}e(ht,"resolveSeed");function xt(t,o,a,r){let l=t/2,p=r??t*0.015,nt=7,q=o/7,f=[];for(let i=0;i<=7;i++){let y=tt(a+i*17)*p*2-p;f.push({x:l+y,y:i*q})}let B=`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,C=i%2===0?1:-1,h=p*1.5*C*tt(a+i*31+7),U=y.x+h,Q=m,Z=c.x-h;B+=` C${U},${Q} ${Z},${m} ${c.x},${c.y}`}return B}e(xt,"generateFoldPath");function $t(t,o,a,r){let l=o/2,p=r??o*0.015,nt=7,q=t/7,f=[];for(let i=0;i<=7;i++){let y=tt(a+i*23)*p*2-p;f.push({x:i*q,y:l+y})}let B=`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,C=i%2===0?1:-1,h=p*1.5*C*tt(a+i*37+11),U=m,Q=y.y+h,Z=m,_=c.y-h;B+=` C${U},${Q} ${Z},${_} ${c.x},${c.y}`}return B}e($t,"generateHorizontalBoundary");function bt(t,o){let a=t/2,r=o*0.5,l=o,p=t*0.03;return[`M${a},${r}`,`C${a+p},${r+(l-r)*0.2}`,`${a-p*1.5},${r+(l-r)*0.55}`,`${a+p*0.5},${r+(l-r)*0.75}`,`C${a-p},${r+(l-r)*0.85}`,`${a+p*0.3},${r+(l-r)*0.95}`,`${a},${l}`].join(" ")}e(bt,"generateCliffPath");function wt(t,o,a,r){return[`M${t-a},${o}`,`A${a},${r} 0 1,1 ${t+a},${o}`,`A${a},${r} 0 1,1 ${t-a},${o}`,"Z"].join(" ")}e(wt,"generateConfusionPath");var yt={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"}},It=e((t,o)=>{let a=t/2,r=o/2;return{complex:{cx:a/2,cy:r/2,x:0,y:0,w:a,h:r},complicated:{cx:a+a/2,cy:r/2,x:a,y:0,w:a,h:r},chaotic:{cx:a/2,cy:r+r/2,x:0,y:r,w:a,h:r},clear:{cx:a+a/2,cy:r+r/2,x:a,y:r,w:a,h:r},confusion:{cx:a,cy:r,x:a*0.7,y:r*0.7,w:a*0.6,h:r*0.6}}},"getDomainLayouts"),Wt=e(()=>{let t=Me(),o=k();return K(t,o.themeVariables).cynefin},"getCynefinDomainColors"),st=3,Rt=e((t,o,a,r)=>{let l=r.db,p=l.getDomains(),nt=l.getTransitions(),q=l.getDiagramTitle(),f=l.getAccTitle(),B=l.getAccDescription(),i=l.getConfig(),y=Wt();n.debug("Rendering Cynefin diagram");let{width:c,height:m,padding:C,showDomainDescriptions:h,boundaryAmplitude:U}=i,Q=c+C*2,Z=m+C*2,_={complex:y.complexBg,complicated:y.complicatedBg,clear:y.clearBg,chaotic:y.chaoticBg,confusion:y.confusionBg},S=Y(o);if(j(S,Z,Q,i.useMaxWidth??!0),S.attr("viewBox",`0 0 ${Q} ${Z}`),f)S.append("title").text(f);if(B)S.append("desc").text(B);let z=S.append("g").attr("transform",`translate(${C}, ${C})`),J=It(c,m),ct=ht(i.seed,o),Ct=z.append("g").attr("class","cynefin-backgrounds"),rt=["complex","complicated","chaotic","clear"];for(let d of rt){let s=J[d];Ct.append("rect").attr("class","cynefinDomain").attr("x",s.x).attr("y",s.y).attr("width",s.w).attr("height",s.h).attr("fill",_[d]).attr("fill-opacity",0.4).attr("stroke","none")}let it=z.append("g").attr("class","cynefin-boundaries");it.append("path").attr("class","cynefinBoundary").attr("d",xt(c,m,ct,U)).attr("fill","none"),it.append("path").attr("class","cynefinBoundary").attr("d",$t(c,m,ct+100,U)).attr("fill","none"),it.append("path").attr("class","cynefinCliff").attr("d",bt(c,m)).attr("fill","none");let vt=c*0.15,Dt=m*0.15;z.append("path").attr("class","cynefinConfusion").attr("d",wt(c/2,m/2,vt,Dt)).attr("fill",_.confusion).attr("fill-opacity",0.5);let lt=z.append("g").attr("class","cynefin-labels");for(let d of rt){let s=J[d];lt.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(lt.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=z.append("g").attr("class","cynefin-subtitles");for(let s of rt){let g=J[s],u=yt[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(yt.confusion.practice)}let dt=z.append("g").attr("class","cynefin-items"),N=26,ft=10,kt=["complex","complicated","chaotic","clear","confusion"];for(let d of kt){let s=p.get(d);if(!s||s.items.length===0)continue;let g=J[d],u=d==="confusion",E=s.items,H=0;if(u&&s.items.length>st)H=s.items.length-st,E=s.items.slice(0,st);let P;if(u){let b=h?22:14;P=g.cy+b}else P=g.cy+(h?25:15);if([...E].forEach((b,W)=>{let v=P+W*(N+4),V=dt.append("g"),G=V.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",N/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(b.label),w=b.label.length*7,x=G.node();if(x&&typeof x.getBBox==="function"){let ot=x.getBBox();if(ot.width>0)w=ot.width}let T=w+ft*2,X=g.cx-T/2;V.attr("transform",`translate(${X}, ${v})`),V.insert("rect","text").attr("class","cynefinItem").attr("x",0).attr("y",0).attr("width",T).attr("height",N).attr("rx",4).attr("ry",4).attr("fill",_[d]).attr("fill-opacity",0.95),G.attr("x",T/2).attr("y",N/2)}),H>0){let b=P+E.length*(N+4),W=`+${H} more`,v=dt.append("g"),V=v.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",N/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(W),G=W.length*7,w=V.node();if(w&&typeof w.getBBox==="function"){let X=w.getBBox();if(X.width>0)G=X.width}let x=G+ft*2,T=g.cx-x/2;v.attr("transform",`translate(${T}, ${b})`),v.insert("rect","text").attr("class","cynefinItemOverflow").attr("x",0).attr("y",0).attr("width",x).attr("height",N).attr("rx",4).attr("ry",4).attr("fill",_[d]).attr("fill-opacity",0.6),V.attr("x",x/2).attr("y",N/2)}}if(nt.length>0){let d=S.select("defs").empty()?S.append("defs"):S.select("defs"),s=`cynefin-arrow-${o}`;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=z.append("g").attr("class","cynefin-arrows");nt.forEach((u)=>{let E=J[u.from],H=J[u.to];if(!E||!H)return;if(u.from===u.to){n.warn(`Cynefin renderer: skipping self-loop on domain "${u.from}"`);return}let{cx:P,cy:b}=E,{cx:W,cy:v}=H,V=(P+W)/2,G=(b+v)/2,w=W-P,x=v-b,T=Math.sqrt(w*w+x*x),X=T*0.15,ot=-x/T,Tt=w/T,mt=V+ot*X,pt=G+Tt*X;if(g.append("path").attr("class","cynefinArrowLine").attr("d",`M${P},${b} Q${mt},${pt} ${W},${v}`).attr("fill","none").attr("marker-end",`url(#${s})`),u.label)g.append("text").attr("class","cynefinArrowLabel").attr("x",mt).attr("y",pt-6).attr("text-anchor","middle").attr("dominant-baseline","auto").text(u.label)})}if(q)z.append("text").attr("class","cynefinTitle").attr("x",c/2).attr("y",-C/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text(q)},"draw"),Ft={draw:Rt},Vt=e(()=>{let t=Me(),o=k();return K(t,o.themeVariables).cynefin},"getCynefinTheme"),_t=e(()=>{let t=Vt();return`
1
+ import{ee}from"./index.0g1t1pjx.js";import{e,n,Ie,B,k,j,A,L,R,I,M,P,O,X,Y}from"./index.zkx4ryzt.js";import{oe}from"./index.6pzexww5.js";var ut=e(()=>({domains:new Map,transitions:[]}),"createDefaultData"),et=ut(),At=e(()=>et.domains,"getDomains"),Bt=e(()=>et.transitions,"getTransitions"),St=e((t)=>{if(!t)return;for(let o of t){let a=o.domain,r=(o.items??[]).map((l)=>({label:l.label}));et.domains.set(a,{name:a,items:r})}},"setDomains"),Mt=e((t)=>{if(!t)return;et.transitions=t.filter((o)=>{if(o.from===o.to)return n.warn(`Cynefin: self-loop transition on domain "${o.from}" is not meaningful and will be skipped.`),!1;return!0}).map((o)=>({from:o.from,to:o.to,label:o.label||void 0}))},"setTransitions"),zt=e(()=>Y({...B.cynefin,...k().cynefin}),"getConfig"),Lt=e(()=>{A(),et=ut()},"clear"),at={getDomains:At,getTransitions:Bt,setDomains:St,setTransitions:Mt,getConfig:zt,clear:Lt,setAccTitle:L,getAccTitle:R,setDiagramTitle:P,getDiagramTitle:O,getAccDescription:M,setAccDescription:I},Nt=e((t)=>{ee(t,at),at.setDomains(t.domains),at.setTransitions(t.transitions)},"populate"),Pt={parse:e(async(t)=>{let o=await oe("cynefin",t);n.debug(o),Nt(o)},"parse")};function tt(t){let o=t+1831565813|0;return o=Math.imul(o^o>>>15,o|1),o^=o+Math.imul(o^o>>>7,o|61),((o^o>>>14)>>>0)/4294967296}e(tt,"seededRandom");function gt(t){let o=0;for(let a=0;a<t.length;a++){let r=t.charCodeAt(a);o=(o<<5)-o+r,o|=0}return o}e(gt,"hashString");function ht(t,o){if(typeof t==="number"&&Number.isFinite(t)&&t!==0)return t;return gt(o)}e(ht,"resolveSeed");function xt(t,o,a,r){let l=t/2,p=r??t*0.015,nt=7,U=o/7,f=[];for(let i=0;i<=7;i++){let y=tt(a+i*17)*p*2-p;f.push({x:l+y,y:i*U})}let T=`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,C=i%2===0?1:-1,h=p*1.5*C*tt(a+i*31+7),Q=y.x+h,Z=m,J=c.x-h;T+=` C${Q},${Z} ${J},${m} ${c.x},${c.y}`}return T}e(xt,"generateFoldPath");function $t(t,o,a,r){let l=o/2,p=r??o*0.015,nt=7,U=t/7,f=[];for(let i=0;i<=7;i++){let y=tt(a+i*23)*p*2-p;f.push({x:i*U,y:l+y})}let T=`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,C=i%2===0?1:-1,h=p*1.5*C*tt(a+i*37+11),Q=m,Z=y.y+h,J=m,_=c.y-h;T+=` C${Q},${Z} ${J},${_} ${c.x},${c.y}`}return T}e($t,"generateHorizontalBoundary");function bt(t,o){let a=t/2,r=o*0.5,l=o,p=t*0.03;return[`M${a},${r}`,`C${a+p},${r+(l-r)*0.2}`,`${a-p*1.5},${r+(l-r)*0.55}`,`${a+p*0.5},${r+(l-r)*0.75}`,`C${a-p},${r+(l-r)*0.85}`,`${a+p*0.3},${r+(l-r)*0.95}`,`${a},${l}`].join(" ")}e(bt,"generateCliffPath");function wt(t,o,a,r){return[`M${t-a},${o}`,`A${a},${r} 0 1,1 ${t+a},${o}`,`A${a},${r} 0 1,1 ${t-a},${o}`,"Z"].join(" ")}e(wt,"generateConfusionPath");var yt={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"}},It=e((t,o)=>{let a=t/2,r=o/2;return{complex:{cx:a/2,cy:r/2,x:0,y:0,w:a,h:r},complicated:{cx:a+a/2,cy:r/2,x:a,y:0,w:a,h:r},chaotic:{cx:a/2,cy:r+r/2,x:0,y:r,w:a,h:r},clear:{cx:a+a/2,cy:r+r/2,x:a,y:r,w:a,h:r},confusion:{cx:a,cy:r,x:a*0.7,y:r*0.7,w:a*0.6,h:r*0.6}}},"getDomainLayouts"),Wt=e(()=>{let t=Ie(),o=k();return Y(t,o.themeVariables).cynefin},"getCynefinDomainColors"),st=3,Rt=e((t,o,a,r)=>{let l=r.db,p=l.getDomains(),nt=l.getTransitions(),U=l.getDiagramTitle(),f=l.getAccTitle(),T=l.getAccDescription(),i=l.getConfig(),y=Wt();n.debug("Rendering Cynefin diagram");let{width:c,height:m,padding:C,showDomainDescriptions:h,boundaryAmplitude:Q}=i,Z=c+C*2,J=m+C*2,_={complex:y.complexBg,complicated:y.complicatedBg,clear:y.clearBg,chaotic:y.chaoticBg,confusion:y.confusionBg},S=X(o);if(j(S,J,Z,i.useMaxWidth??!0),S.attr("viewBox",`0 0 ${Z} ${J}`),f)S.append("title").text(f);if(T)S.append("desc").text(T);let z=S.append("g").attr("transform",`translate(${C}, ${C})`),K=It(c,m),ct=ht(i.seed,o),Ct=z.append("g").attr("class","cynefin-backgrounds"),rt=["complex","complicated","chaotic","clear"];for(let d of rt){let s=K[d];Ct.append("rect").attr("class","cynefinDomain").attr("x",s.x).attr("y",s.y).attr("width",s.w).attr("height",s.h).attr("fill",_[d]).attr("fill-opacity",0.4).attr("stroke","none")}let it=z.append("g").attr("class","cynefin-boundaries");it.append("path").attr("class","cynefinBoundary").attr("d",xt(c,m,ct,Q)).attr("fill","none"),it.append("path").attr("class","cynefinBoundary").attr("d",$t(c,m,ct+100,Q)).attr("fill","none"),it.append("path").attr("class","cynefinCliff").attr("d",bt(c,m)).attr("fill","none");let vt=c*0.15,Dt=m*0.15;z.append("path").attr("class","cynefinConfusion").attr("d",wt(c/2,m/2,vt,Dt)).attr("fill",_.confusion).attr("fill-opacity",0.5);let lt=z.append("g").attr("class","cynefin-labels");for(let d of rt){let s=K[d];lt.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(lt.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=z.append("g").attr("class","cynefin-subtitles");for(let s of rt){let g=K[s],u=yt[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(yt.confusion.practice)}let dt=z.append("g").attr("class","cynefin-items"),N=26,ft=10,kt=["complex","complicated","chaotic","clear","confusion"];for(let d of kt){let s=p.get(d);if(!s||s.items.length===0)continue;let g=K[d],u=d==="confusion",E=s.items,H=0;if(u&&s.items.length>st)H=s.items.length-st,E=s.items.slice(0,st);let W;if(u){let b=h?22:14;W=g.cy+b}else W=g.cy+(h?25:15);if([...E].forEach((b,F)=>{let v=W+F*(N+4),V=dt.append("g"),G=V.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",N/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(b.label),w=b.label.length*7,x=G.node();if(x&&typeof x.getBBox==="function"){let ot=x.getBBox();if(ot.width>0)w=ot.width}let D=w+ft*2,q=g.cx-D/2;V.attr("transform",`translate(${q}, ${v})`),V.insert("rect","text").attr("class","cynefinItem").attr("x",0).attr("y",0).attr("width",D).attr("height",N).attr("rx",4).attr("ry",4).attr("fill",_[d]).attr("fill-opacity",0.95),G.attr("x",D/2).attr("y",N/2)}),H>0){let b=W+E.length*(N+4),F=`+${H} more`,v=dt.append("g"),V=v.append("text").attr("class","cynefinItemText").attr("x",0).attr("y",N/2).attr("text-anchor","middle").attr("dominant-baseline","central").text(F),G=F.length*7,w=V.node();if(w&&typeof w.getBBox==="function"){let q=w.getBBox();if(q.width>0)G=q.width}let x=G+ft*2,D=g.cx-x/2;v.attr("transform",`translate(${D}, ${b})`),v.insert("rect","text").attr("class","cynefinItemOverflow").attr("x",0).attr("y",0).attr("width",x).attr("height",N).attr("rx",4).attr("ry",4).attr("fill",_[d]).attr("fill-opacity",0.6),V.attr("x",x/2).attr("y",N/2)}}if(nt.length>0){let d=S.select("defs").empty()?S.append("defs"):S.select("defs"),s=`cynefin-arrow-${o}`;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=z.append("g").attr("class","cynefin-arrows");nt.forEach((u)=>{let E=K[u.from],H=K[u.to];if(!E||!H)return;if(u.from===u.to){n.warn(`Cynefin renderer: skipping self-loop on domain "${u.from}"`);return}let{cx:W,cy:b}=E,{cx:F,cy:v}=H,V=(W+F)/2,G=(b+v)/2,w=F-W,x=v-b,D=Math.sqrt(w*w+x*x),q=D*0.15,ot=-x/D,Tt=w/D,mt=V+ot*q,pt=G+Tt*q;if(g.append("path").attr("class","cynefinArrowLine").attr("d",`M${W},${b} Q${mt},${pt} ${F},${v}`).attr("fill","none").attr("marker-end",`url(#${s})`),u.label)g.append("text").attr("class","cynefinArrowLabel").attr("x",mt).attr("y",pt-6).attr("text-anchor","middle").attr("dominant-baseline","auto").text(u.label)})}if(U)z.append("text").attr("class","cynefinTitle").attr("x",c/2).attr("y",-C/2).attr("text-anchor","middle").attr("dominant-baseline","middle").text(U)},"draw"),Ft={draw:Rt},Vt=e(()=>{let t=Ie(),o=k();return Y(t,o.themeVariables).cynefin},"getCynefinTheme"),_t=e(()=>{let t=Vt();return`
2
2
  .cynefinDomain {
3
3
  stroke: none;
4
4
  }