tmlsai commited on
Commit
e6a035c
·
verified ·
1 Parent(s): 75bf552

Publish paper as standalone Space

Browse files
This view is limited to 50 files because it contains too many changes.   See raw diff
Files changed (50) hide show
  1. README.md +40 -5
  2. _next/static/PK1lVknzJ5QE4Q9BEvK6D/_buildManifest.js +1 -0
  3. _next/static/PK1lVknzJ5QE4Q9BEvK6D/_ssgManifest.js +1 -0
  4. _next/static/chunks/0b9a0da7.1ac0e28d11b6291e.js +0 -0
  5. _next/static/chunks/104.35c46df49c7800b9.js +1 -0
  6. _next/static/chunks/1166.3e45b57167ec25fd.js +1 -0
  7. _next/static/chunks/1202.edd5323c61377019.js +1 -0
  8. _next/static/chunks/1255-29325acccda77703.js +0 -0
  9. _next/static/chunks/1345.3a0d752ef8f7cc0c.js +1 -0
  10. _next/static/chunks/2065.bfc6693b67a7e2cf.js +1 -0
  11. _next/static/chunks/2288.2f11050df7344f68.js +1 -0
  12. _next/static/chunks/2392.8ec2341e6d06e84b.js +77 -0
  13. _next/static/chunks/2442.01b89335df3ac251.js +104 -0
  14. _next/static/chunks/2452.1c5091d3e72e76a2.js +287 -0
  15. _next/static/chunks/2487.5d390db091e7b181.js +1 -0
  16. _next/static/chunks/261.4a233b47734aecfc.js +1 -0
  17. _next/static/chunks/2619-3c9e02e22d10480a.js +1 -0
  18. _next/static/chunks/2796.74619ac320f56d15.js +29 -0
  19. _next/static/chunks/2918becc.5ded705da9835bd2.js +0 -0
  20. _next/static/chunks/3384.6a7edf5cc56172fd.js +226 -0
  21. _next/static/chunks/3580.e76fc55d57dae2f8.js +80 -0
  22. _next/static/chunks/3627.baa361f72a00cf7e.js +1 -0
  23. _next/static/chunks/4162.6f781ac1e3d4e682.js +215 -0
  24. _next/static/chunks/4290.6ee778437eacd4f3.js +1 -0
  25. _next/static/chunks/4460.f9ae9bbf1d459b8b.js +79 -0
  26. _next/static/chunks/4603.762146ef732cf6a2.js +1 -0
  27. _next/static/chunks/4bd1b696-f785427dddbba9fb.js +0 -0
  28. _next/static/chunks/5090.850b2168c1a2a9a5.js +24 -0
  29. _next/static/chunks/5198.eaf564cf731be65e.js +1 -0
  30. _next/static/chunks/5244.25924b6e2254ceb0.js +0 -0
  31. _next/static/chunks/5294.2ba6d8370ce6373a.js +1 -0
  32. _next/static/chunks/533.caf5b2430c4c7b94.js +1 -0
  33. _next/static/chunks/5375.c699ec4a5c55285d.js +1 -0
  34. _next/static/chunks/5785.c376d430e74f953c.js +9 -0
  35. _next/static/chunks/58bb9007.15ec71a3d64fa897.js +0 -0
  36. _next/static/chunks/6091.9cda211185ade55d.js +1 -0
  37. _next/static/chunks/6215.17b66e816cb5b1c5.js +1 -0
  38. _next/static/chunks/6386.543ffeae6a482fb1.js +93 -0
  39. _next/static/chunks/6849.d9658296f38abc1c.js +1 -0
  40. _next/static/chunks/7048.a7719967455ae00c.js +115 -0
  41. _next/static/chunks/7286.a9914678c7734135.js +34 -0
  42. _next/static/chunks/7378.06f6c0e4bb90b63a.js +24 -0
  43. _next/static/chunks/73972abe.45f878fbba31a82b.js +0 -0
  44. _next/static/chunks/7423.e21816ef40efbfb4.js +23 -0
  45. _next/static/chunks/7635.40c4d6f768cf3c32.js +1 -0
  46. _next/static/chunks/7882.4d29af0e3f9c85c5.js +166 -0
  47. _next/static/chunks/802.112d13381f11bef6.js +141 -0
  48. _next/static/chunks/8050.7e59f099df2b9ec2.js +1 -0
  49. _next/static/chunks/806.f53e1370d77cbb73.js +64 -0
  50. _next/static/chunks/821-19aed8db548f58e8.js +1 -0
README.md CHANGED
@@ -1,10 +1,45 @@
1
  ---
2
- title: Semantic Caching Measure Theory
3
- emoji: 🐨
4
- colorFrom: blue
5
- colorTo: indigo
6
  sdk: static
 
7
  pinned: false
 
 
 
 
 
 
8
  ---
9
 
10
- Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
  ---
2
+ title: "A Measure-Theoretic Account of Semantic Caching: When Approx"
3
+ emoji: ♻️
4
+ colorFrom: indigo
5
+ colorTo: gray
6
  sdk: static
7
+ app_file: index.html
8
  pinned: false
9
+ license: cc-by-4.0
10
+ tags:
11
+ - semantic-cache
12
+ - llm-serving
13
+ - caching
14
+ - theory
15
  ---
16
 
17
+ # A Measure-Theoretic Account of Semantic Caching: When Approximate Reuse Is Provably Safe
18
+
19
+ A measure-theoretic safety criterion for semantic caches: the exact condition under which a cache hit cannot change the answer, and its false-reuse bound.
20
+
21
+ Authors: Agon Avdimetaj, TMLS AI Research. Published 2026-07-13.
22
+
23
+ ## What this paper is, and what it is not
24
+
25
+ This paper contains **no experiments of our own.** We did not train, serve, or
26
+ benchmark any model for it. Every empirical number is cited to a published
27
+ source with a working URL. Every curve we construct is labeled as an
28
+ **analytical model** with its assumptions stated, and figures that replot a
29
+ published study name that study in the caption.
30
+
31
+ The **derivations and proofs are original work**, carried out in full and shown
32
+ step by step. That is the contribution.
33
+
34
+ ## Corrections
35
+
36
+ If you find a wrong proof step, a mis-attributed number, or a citation that does
37
+ not say what we claim, please open a discussion. We will correct the paper and
38
+ say what changed.
39
+
40
+ ## Related
41
+
42
+ Canonical version: [tmls.nyc/research/semantic-caching-measure-theory](https://tmls.nyc/research/semantic-caching-measure-theory)
43
+ All five papers in this series: [TMLSNYC/research-inference-serving](https://huggingface.co/spaces/TMLSNYC/research-inference-serving)
44
+
45
+ Text licensed CC-BY-4.0.
_next/static/PK1lVknzJ5QE4Q9BEvK6D/_buildManifest.js ADDED
@@ -0,0 +1 @@
 
 
1
+ self.__BUILD_MANIFEST=function(e,r,t){return{__rewrites:{afterFiles:[],beforeFiles:[],fallback:[]},__routerFilterStatic:{numItems:12,errorRate:1e-4,numBits:231,numHashes:14,bitArray:[0,0,r,r,1,1,r,e,e,e,e,e,e,r,e,r,e,r,r,r,e,e,e,r,r,r,e,e,r,e,e,r,r,r,e,e,r,r,e,r,r,e,r,r,r,r,r,r,r,r,r,r,e,e,r,e,e,e,e,e,e,r,r,r,r,e,e,e,e,e,e,r,e,e,e,r,e,e,e,r,r,r,e,e,r,r,e,e,e,r,e,e,e,r,e,r,e,e,e,r,r,e,e,e,r,r,e,e,r,e,e,e,e,e,r,e,r,r,r,r,r,r,r,e,r,e,e,r,e,r,e,e,e,e,e,r,r,r,e,r,r,r,e,r,e,e,e,r,r,e,r,r,r,r,e,r,r,e,e,r,e,e,r,r,r,e,r,e,e,e,e,e,e,r,e,e,r,e,e,e,r,e,r,e,r,r,e,r,e,e,r,r,e,e,e,e,r,r,r,r,r,e,e,r,e,e,r,r,e,r,e,e,e,r,r,e,e,r,r,r,r,e,e,e,r,r,e,r,r,e,e]},__routerFilterDynamic:{numItems:r,errorRate:1e-4,numBits:r,numHashes:null,bitArray:[]},"/_error":["static/chunks/pages/_error-94812ad32cad7365.js"],sortedPages:["/_app","/_error"]}}(1,0,1e-4),self.__BUILD_MANIFEST_CB&&self.__BUILD_MANIFEST_CB();
_next/static/PK1lVknzJ5QE4Q9BEvK6D/_ssgManifest.js ADDED
@@ -0,0 +1 @@
 
 
1
+ self.__SSG_MANIFEST=new Set([]);self.__SSG_MANIFEST_CB&&self.__SSG_MANIFEST_CB()
_next/static/chunks/0b9a0da7.1ac0e28d11b6291e.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/104.35c46df49c7800b9.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[104],{104:(e,s,c)=>{c.d(s,{createPieServices:()=>a.f});var a=c(1669);c(4839)}}]);
_next/static/chunks/1166.3e45b57167ec25fd.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1166],{1166:(e,s,c)=>{c.d(s,{createEventModelingServices:()=>a.g});var a=c(6934);c(4839)}}]);
_next/static/chunks/1202.edd5323c61377019.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1202],{1202:(t,e,a)=>{a.d(e,{diagram:()=>K});var i,r=a(3384);a(1184),a(2888),a(1593),a(4982),a(1431),a(5407),a(7920),a(3148),a(1538);var d=a(3736),n=a(669),s=a(316),o=a(5508),g=a(4603),p=a(9856),l=(0,s.K2)(t=>t.append("circle").attr("class","start-state").attr("r",(0,n.D7)().state.sizeUnit).attr("cx",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit).attr("cy",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit),"drawStartState"),h=(0,s.K2)(t=>t.append("line").style("stroke","grey").style("stroke-dasharray","3").attr("x1",(0,n.D7)().state.textHeight).attr("class","divider").attr("x2",2*(0,n.D7)().state.textHeight).attr("y1",0).attr("y2",0),"drawDivider"),c=(0,s.K2)((t,e)=>{let a=t.append("text").attr("x",2*(0,n.D7)().state.padding).attr("y",(0,n.D7)().state.textHeight+2*(0,n.D7)().state.padding).attr("font-size",(0,n.D7)().state.fontSize).attr("class","state-title").text(e.id),i=a.node().getBBox();return t.insert("rect",":first-child").attr("x",(0,n.D7)().state.padding).attr("y",(0,n.D7)().state.padding).attr("width",i.width+2*(0,n.D7)().state.padding).attr("height",i.height+2*(0,n.D7)().state.padding).attr("rx",(0,n.D7)().state.radius),a},"drawSimpleState"),x=(0,s.K2)((t,e)=>{let a=(0,s.K2)(function(t,e,a){let i=t.append("tspan").attr("x",2*(0,n.D7)().state.padding).text(e);a||i.attr("dy",(0,n.D7)().state.textHeight)},"addTspan"),i=t.append("text").attr("x",2*(0,n.D7)().state.padding).attr("y",(0,n.D7)().state.textHeight+1.3*(0,n.D7)().state.padding).attr("font-size",(0,n.D7)().state.fontSize).attr("class","state-title").text(e.descriptions[0]).node().getBBox(),r=i.height,d=t.append("text").attr("x",(0,n.D7)().state.padding).attr("y",r+.4*(0,n.D7)().state.padding+(0,n.D7)().state.dividerMargin+(0,n.D7)().state.textHeight).attr("class","state-description"),o=!0,g=!0;e.descriptions.forEach(function(t){o||(a(d,t,g),g=!1),o=!1});let p=t.append("line").attr("x1",(0,n.D7)().state.padding).attr("y1",(0,n.D7)().state.padding+r+(0,n.D7)().state.dividerMargin/2).attr("y2",(0,n.D7)().state.padding+r+(0,n.D7)().state.dividerMargin/2).attr("class","descr-divider"),l=d.node().getBBox(),h=Math.max(l.width,i.width);return p.attr("x2",h+3*(0,n.D7)().state.padding),t.insert("rect",":first-child").attr("x",(0,n.D7)().state.padding).attr("y",(0,n.D7)().state.padding).attr("width",h+2*(0,n.D7)().state.padding).attr("height",l.height+r+2*(0,n.D7)().state.padding).attr("rx",(0,n.D7)().state.radius),t},"drawDescrState"),D=(0,s.K2)((t,e,a)=>{let i,r=(0,n.D7)().state.padding,d=2*(0,n.D7)().state.padding,s=t.node().getBBox(),o=s.width,g=s.x,p=t.append("text").attr("x",0).attr("y",(0,n.D7)().state.titleShift).attr("font-size",(0,n.D7)().state.fontSize).attr("class","state-title").text(e.id),l=p.node().getBBox().width+d,h=Math.max(l,o);h===o&&(h+=d);let c=t.node().getBBox();e.doc,i=g-r,l>o&&(i=(o-h)/2+r),Math.abs(g-c.x)<r&&l>o&&(i=g-(l-o)/2);let x=1-(0,n.D7)().state.textHeight;return t.insert("rect",":first-child").attr("x",i).attr("y",x).attr("class",a?"alt-composit":"composit").attr("width",h).attr("height",c.height+(0,n.D7)().state.textHeight+(0,n.D7)().state.titleShift+1).attr("rx","0"),p.attr("x",i+r),l<=o&&p.attr("x",g+(h-d)/2-l/2+r),t.insert("rect",":first-child").attr("x",i).attr("y",(0,n.D7)().state.titleShift-(0,n.D7)().state.textHeight-(0,n.D7)().state.padding).attr("width",h).attr("height",3*(0,n.D7)().state.textHeight).attr("rx",(0,n.D7)().state.radius),t.insert("rect",":first-child").attr("x",i).attr("y",(0,n.D7)().state.titleShift-(0,n.D7)().state.textHeight-(0,n.D7)().state.padding).attr("width",h).attr("height",c.height+3+2*(0,n.D7)().state.textHeight).attr("rx",(0,n.D7)().state.radius),t},"addTitleAndBox"),u=(0,s.K2)(t=>(t.append("circle").attr("class","end-state-outer").attr("r",(0,n.D7)().state.sizeUnit+(0,n.D7)().state.miniPadding).attr("cx",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit+(0,n.D7)().state.miniPadding).attr("cy",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit+(0,n.D7)().state.miniPadding),t.append("circle").attr("class","end-state-inner").attr("r",(0,n.D7)().state.sizeUnit).attr("cx",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit+2).attr("cy",(0,n.D7)().state.padding+(0,n.D7)().state.sizeUnit+2)),"drawEndState"),f=(0,s.K2)((t,e)=>{let a=(0,n.D7)().state.forkWidth,i=(0,n.D7)().state.forkHeight;if(e.parentId){let t=a;a=i,i=t}return t.append("rect").style("stroke","black").style("fill","black").attr("width",a).attr("height",i).attr("x",(0,n.D7)().state.padding).attr("y",(0,n.D7)().state.padding)},"drawForkJoinState"),y=(0,s.K2)((t,e,a,i)=>{let r=0,d=i.append("text");d.style("text-anchor","start"),d.attr("class","noteText");let s=t.replace(/\r\n/g,"<br/>"),o=(s=s.replace(/\n/g,"<br/>")).split(n.Y2.lineBreakRegex),g=1.25*(0,n.D7)().state.noteMargin;for(let t of o){let i=t.trim();if(i.length>0){let t=d.append("tspan");t.text(i),0===g&&(g+=t.node().getBBox().height),r+=g,t.attr("x",e+(0,n.D7)().state.noteMargin),t.attr("y",a+r+1.25*(0,n.D7)().state.noteMargin)}}return{textWidth:d.node().getBBox().width,textHeight:r}},"_drawLongText"),w=(0,s.K2)((t,e)=>{e.attr("class","state-note");let a=e.append("rect").attr("x",0).attr("y",(0,n.D7)().state.padding),{textWidth:i,textHeight:r}=y(t,0,0,e.append("g"));return a.attr("height",r+2*(0,n.D7)().state.noteMargin),a.attr("width",i+2*(0,n.D7)().state.noteMargin),a},"drawNote"),m=(0,s.K2)(function(t,e){let a=e.id,i={id:a,label:e.id,width:0,height:0},r=t.append("g").attr("id",a).attr("class","stateGroup");"start"===e.type&&l(r),"end"===e.type&&u(r),("fork"===e.type||"join"===e.type)&&f(r,e),"note"===e.type&&w(e.note.text,r),"divider"===e.type&&h(r),"default"===e.type&&0===e.descriptions.length&&c(r,e),"default"===e.type&&e.descriptions.length>0&&x(r,e);let d=r.node().getBBox();return i.width=d.width+2*(0,n.D7)().state.padding,i.height=d.height+2*(0,n.D7)().state.padding,i},"drawState"),b=0,B=(0,s.K2)(function(t,e,a){let i=(0,s.K2)(function(t){switch(t){case r.u4.relationType.AGGREGATION:return"aggregation";case r.u4.relationType.EXTENSION:return"extension";case r.u4.relationType.COMPOSITION:return"composition";case r.u4.relationType.DEPENDENCY:return"dependency"}},"getRelationType");e.points=e.points.filter(t=>!Number.isNaN(t.y));let g=e.points,p=(0,o.n8j)().x(function(t){return t.x}).y(function(t){return t.y}).curve(o.qrM),l=t.append("path").attr("d",p(g)).attr("id","edge"+b).attr("class","transition"),h="";if((0,n.D7)().state.arrowMarkerAbsolute&&(h=(0,n.ID)(!0)),l.attr("marker-end","url("+h+"#"+i(r.u4.relationType.DEPENDENCY)+"End)"),void 0!==a.title){let i=t.append("g").attr("class","stateLabel"),{x:r,y:o}=d._K.calcLabelPosition(e.points),g=n.Y2.getRows(a.title),p=0,l=[],h=0,c=0;for(let t=0;t<=g.length;t++){let e=i.append("text").attr("text-anchor","middle").text(g[t]).attr("x",r).attr("y",o+p),a=e.node().getBBox();h=Math.max(h,a.width),c=Math.min(c,a.x),s.Rm.info(a.x,r,o+p),0===p&&(p=e.node().getBBox().height,s.Rm.info("Title height",p,o)),l.push(e)}let x=p*g.length;if(g.length>1){let t=(g.length-1)*p*.5;l.forEach((e,a)=>e.attr("y",o+a*p-t)),x=p*g.length}let D=i.node().getBBox();i.insert("rect",":first-child").attr("class","box").attr("x",r-h/2-(0,n.D7)().state.padding/2).attr("y",o-x/2-(0,n.D7)().state.padding/2-3.5).attr("width",h+(0,n.D7)().state.padding).attr("height",x+(0,n.D7)().state.padding),s.Rm.info(D)}b++},"drawEdge"),k={},N=(0,s.K2)(function(){},"setConf"),E=(0,s.K2)(function(t){t.append("defs").append("marker").attr("id","dependencyEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"insertMarkers"),S=(0,s.K2)(function(t,e,a,r){let d;i=(0,n.D7)().state;let g=(0,n.D7)().securityLevel;"sandbox"===g&&(d=(0,o.Ltv)("#i"+e));let p="sandbox"===g?(0,o.Ltv)(d.nodes()[0].contentDocument.body):(0,o.Ltv)("body"),l="sandbox"===g?d.nodes()[0].contentDocument:document;s.Rm.debug("Rendering diagram "+t);let h=p.select(`[id='${e}']`);E(h),v(r.db.getRootDoc(),h.append("g").attr("id",e+"-root"),void 0,!1,p,l,r);let c=i.padding,x=h.node().getBBox(),D=x.width+2*c,u=x.height+2*c;(0,n.a$)(h,u,1.75*D,i.useMaxWidth),h.attr("viewBox",`${x.x-i.padding} ${x.y-i.padding} `+D+" "+u)},"draw"),M=(0,s.K2)(t=>t?t.length*i.fontSizeFactor:1,"getLabelWidth"),v=(0,s.K2)((t,e,a,r,d,o,l)=>{let h,c=new p.T({compound:!0,multigraph:!0}),x=!0;for(h=0;h<t.length;h++)if("relation"===t[h].stmt){x=!1;break}a?c.setGraph({rankdir:"LR",multigraph:!0,compound:!0,ranker:"tight-tree",ranksep:x?1:i.edgeLengthFactor,nodeSep:x?1:50,isMultiGraph:!0}):c.setGraph({rankdir:"TB",multigraph:!0,compound:!0,ranksep:x?1:i.edgeLengthFactor,nodeSep:x?1:50,ranker:"tight-tree",isMultiGraph:!0}),c.setDefaultEdgeLabel(function(){return{}});let u=l.db.getStates(),f=l.db.getRelations();for(let t of Object.keys(u)){let n,s=u[t];if(a&&(s.parentId=a),s.doc){let t=e.append("g").attr("id",s.id).attr("class","stateGroup");n=v(s.doc,t,s.id,!r,d,o,l);{let e=(t=D(t,s,r)).node().getBBox();n.width=e.width,n.height=e.height+i.padding/2,k[s.id]={y:i.compositTitleSize}}}else n=m(e,s,c);if(s.note){let t=m(e,{descriptions:[],id:s.id+"-note",note:s.note,type:"note"},c);"left of"===s.note.position?(c.setNode(n.id+"-note",t),c.setNode(n.id,n)):(c.setNode(n.id,n),c.setNode(n.id+"-note",t)),c.setParent(n.id,n.id+"-group"),c.setParent(n.id+"-note",n.id+"-group")}else c.setNode(n.id,n)}s.Rm.debug("Count=",c.nodeCount(),c);let y=0;f.forEach(function(t){y++,s.Rm.debug("Setting edge",t),c.setEdge(t.id1,t.id2,{relation:t,width:M(t.title),height:i.labelHeight*n.Y2.getRows(t.title).length,labelpos:"c"},"id"+y)}),(0,g.Zp)(c),s.Rm.debug("Graph after layout",c.nodes());let w=e.node();c.nodes().forEach(function(t){void 0!==t&&void 0!==c.node(t)?(s.Rm.warn("Node "+t+": "+JSON.stringify(c.node(t))),d.select("#"+w.id+" #"+t).attr("transform","translate("+(c.node(t).x-c.node(t).width/2)+","+(c.node(t).y+(k[t]?k[t].y:0)-c.node(t).height/2)+" )"),d.select("#"+w.id+" #"+t).attr("data-x-shift",c.node(t).x-c.node(t).width/2),o.querySelectorAll("#"+w.id+" #"+t+" .divider").forEach(t=>{let e=t.parentElement,a=0,i=0;e&&(e.parentElement&&(a=e.parentElement.getBBox().width),Number.isNaN(i=parseInt(e.getAttribute("data-x-shift"),10))&&(i=0)),t.setAttribute("x1",0-i+8),t.setAttribute("x2",a-i-8)})):s.Rm.debug("No Node "+t+": "+JSON.stringify(c.node(t)))});let b=w.getBBox();c.edges().forEach(function(t){void 0!==t&&void 0!==c.edge(t)&&(s.Rm.debug("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(c.edge(t))),B(e,c.edge(t),c.edge(t).relation))});let N={id:a||"root",label:a||"root",width:0,height:0};return N.width=(b=w.getBBox()).width+2*i.padding,N.height=b.height+2*i.padding,s.Rm.debug("Doc rendered",N,c),N},"renderDoc"),K={parser:r.Zk,get db(){return new r.u4(1)},renderer:{setConf:N,draw:S},styles:r.tM,init:(0,s.K2)(t=>{t.state||(t.state={}),t.state.arrowMarkerAbsolute=t.arrowMarkerAbsolute},"init")}}}]);
_next/static/chunks/1255-29325acccda77703.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/1345.3a0d752ef8f7cc0c.js ADDED
@@ -0,0 +1 @@
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1345],{3355:function(t,e,i){t.exports=function(t){var e=[function(e,i){e.exports=t},function(t,e,i){"use strict";var r=i(0).FDLayoutConstants;function n(){}for(var o in r)n[o]=r[o];n.DEFAULT_USE_MULTI_LEVEL_SCALING=!1,n.DEFAULT_RADIAL_SEPARATION=r.DEFAULT_EDGE_LENGTH,n.DEFAULT_COMPONENT_SEPERATION=60,n.TILE=!0,n.TILING_PADDING_VERTICAL=10,n.TILING_PADDING_HORIZONTAL=10,n.TREE_REDUCTION_ON_INCREMENTAL=!1,t.exports=n},function(t,e,i){"use strict";var r=i(0).FDLayoutEdge;function n(t,e,i){r.call(this,t,e,i)}for(var o in n.prototype=Object.create(r.prototype),r)n[o]=r[o];t.exports=n},function(t,e,i){"use strict";var r=i(0).LGraph;function n(t,e,i){r.call(this,t,e,i)}for(var o in n.prototype=Object.create(r.prototype),r)n[o]=r[o];t.exports=n},function(t,e,i){"use strict";var r=i(0).LGraphManager;function n(t){r.call(this,t)}for(var o in n.prototype=Object.create(r.prototype),r)n[o]=r[o];t.exports=n},function(t,e,i){"use strict";var r=i(0).FDLayoutNode,n=i(0).IMath;function o(t,e,i,n){r.call(this,t,e,i,n)}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];o.prototype.move=function(){var t=this.graphManager.getLayout();this.displacementX=t.coolingFactor*(this.springForceX+this.repulsionForceX+this.gravitationForceX)/this.noOfChildren,this.displacementY=t.coolingFactor*(this.springForceY+this.repulsionForceY+this.gravitationForceY)/this.noOfChildren,Math.abs(this.displacementX)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementX=t.coolingFactor*t.maxNodeDisplacement*n.sign(this.displacementX)),Math.abs(this.displacementY)>t.coolingFactor*t.maxNodeDisplacement&&(this.displacementY=t.coolingFactor*t.maxNodeDisplacement*n.sign(this.displacementY)),null==this.child||0==this.child.getNodes().length?this.moveBy(this.displacementX,this.displacementY):this.propogateDisplacementToChildren(this.displacementX,this.displacementY),t.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},o.prototype.propogateDisplacementToChildren=function(t,e){for(var i,r=this.getChild().getNodes(),n=0;n<r.length;n++)null==(i=r[n]).getChild()?(i.moveBy(t,e),i.displacementX+=t,i.displacementY+=e):i.propogateDisplacementToChildren(t,e)},o.prototype.setPred1=function(t){this.pred1=t},o.prototype.getPred1=function(){return pred1},o.prototype.getPred2=function(){return pred2},o.prototype.setNext=function(t){this.next=t},o.prototype.getNext=function(){return next},o.prototype.setProcessed=function(t){this.processed=t},o.prototype.isProcessed=function(){return processed},t.exports=o},function(t,e,i){"use strict";var r=i(0).FDLayout,n=i(4),o=i(3),s=i(5),a=i(2),h=i(1),l=i(0).FDLayoutConstants,g=i(0).LayoutConstants,u=i(0).Point,c=i(0).PointD,d=i(0).Layout,p=i(0).Integer,f=i(0).IGeometry,y=i(0).LGraph,E=i(0).Transform;function v(){r.call(this),this.toBeTiled={}}for(var A in v.prototype=Object.create(r.prototype),r)v[A]=r[A];v.prototype.newGraphManager=function(){var t=new n(this);return this.graphManager=t,t},v.prototype.newGraph=function(t){return new o(null,this.graphManager,t)},v.prototype.newNode=function(t){return new s(this.graphManager,t)},v.prototype.newEdge=function(t){return new a(null,null,t)},v.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.isSubLayout||(h.DEFAULT_EDGE_LENGTH<10?this.idealEdgeLength=10:this.idealEdgeLength=h.DEFAULT_EDGE_LENGTH,this.useSmartIdealEdgeLengthCalculation=h.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.springConstant=l.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=l.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=l.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=l.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=l.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=l.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/l.CONVERGENCE_CHECK_PERIOD,this.finalTemperature=l.CONVERGENCE_CHECK_PERIOD/this.maxIterations,this.coolingAdjuster=1)},v.prototype.layout=function(){return g.DEFAULT_CREATE_BENDS_AS_NEEDED&&(this.createBendpoints(),this.graphManager.resetAllEdges()),this.level=0,this.classicLayout()},v.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){if(h.TREE_REDUCTION_ON_INCREMENTAL){this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(e)}}else{var i=this.getFlatForest();if(i.length>0)this.positionNodesRadially(i);else{this.reduceTrees(),this.graphManager.resetAllNodesToApplyGravitation();var t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(e),this.positionNodesRandomly()}}return this.initSpringEmbedder(),this.runSpringEmbedder(),!0},v.prototype.tick=function(){if(this.totalIterations++,this.totalIterations===this.maxIterations&&!this.isTreeGrowing&&!this.isGrowthFinished)if(!(this.prunedNodesAll.length>0))return!0;else this.isTreeGrowing=!0;if(this.totalIterations%l.CONVERGENCE_CHECK_PERIOD==0&&!this.isTreeGrowing&&!this.isGrowthFinished){if(this.isConverged())if(!(this.prunedNodesAll.length>0))return!0;else this.isTreeGrowing=!0;this.coolingCycle++,0==this.layoutQuality?this.coolingAdjuster=this.coolingCycle:1==this.layoutQuality&&(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 t=new Set(this.getAllNodes()),e=this.nodesWithGravity.filter(function(e){return t.has(e)});this.graphManager.setAllNodesToApplyGravitation(e),this.graphManager.updateBounds(),this.updateGrid(),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL}else this.isTreeGrowing=!1,this.isGrowthFinished=!0;this.growTreeIterations++}if(this.isGrowthFinished){if(this.isConverged())return!0;this.afterGrowthIterations%10==0&&(this.graphManager.updateBounds(),this.updateGrid()),this.coolingFactor=l.DEFAULT_COOLING_FACTOR_INCREMENTAL*((100-this.afterGrowthIterations)/100),this.afterGrowthIterations++}var i=!this.isTreeGrowing&&!this.isGrowthFinished,r=this.growTreeIterations%10==1&&this.isTreeGrowing||this.afterGrowthIterations%10==1&&this.isGrowthFinished;return this.totalDisplacement=0,this.graphManager.updateBounds(),this.calcSpringForces(),this.calcRepulsionForces(i,r),this.calcGravitationalForces(),this.moveNodes(),this.animate(),!1},v.prototype.getPositionsData=function(){for(var t=this.graphManager.getAllNodes(),e={},i=0;i<t.length;i++){var r=t[i].rect,n=t[i].id;e[n]={id:n,x:r.getCenterX(),y:r.getCenterY(),w:r.width,h:r.height}}return e},v.prototype.runSpringEmbedder=function(){this.initialAnimationPeriod=25,this.animationPeriod=this.initialAnimationPeriod;var t=!1;if("during"===l.ANIMATE)this.emit("layoutstarted");else{for(;!t;)t=this.tick();this.graphManager.updateBounds()}},v.prototype.calculateNodesToApplyGravitationTo=function(){var t,e,i=[],r=this.graphManager.getGraphs(),n=r.length;for(e=0;e<n;e++)(t=r[e]).updateConnected(),t.isConnected||(i=i.concat(t.getNodes()));return i},v.prototype.createBendpoints=function(){var t=[];t=t.concat(this.graphManager.getAllEdges());var e=new Set;for(o=0;o<t.length;o++){var i=t[o];if(!e.has(i)){var r=i.getSource(),n=i.getTarget();if(r==n)i.getBendpoints().push(new c),i.getBendpoints().push(new c),this.createDummyNodesForBendpoints(i),e.add(i);else{var o,s,a=[];if(a=(a=a.concat(r.getEdgeListToNode(n))).concat(n.getEdgeListToNode(r)),!e.has(a[0])){if(a.length>1)for(s=0;s<a.length;s++){var h=a[s];h.getBendpoints().push(new c),this.createDummyNodesForBendpoints(h)}a.forEach(function(t){e.add(t)})}}}if(e.size==t.length)break}},v.prototype.positionNodesRadially=function(t){for(var e=new u(0,0),i=Math.ceil(Math.sqrt(t.length)),r=0,n=0,o=0,s=new c(0,0),a=0;a<t.length;a++){a%i==0&&(o=0,n=r,0!=a&&(n+=h.DEFAULT_COMPONENT_SEPERATION),r=0);var l=t[a],p=d.findCenterOfTree(l);e.x=o,e.y=n,(s=v.radialLayout(l,p,e)).y>r&&(r=Math.floor(s.y)),o=Math.floor(s.x+h.DEFAULT_COMPONENT_SEPERATION)}this.transform(new c(g.WORLD_CENTER_X-s.x/2,g.WORLD_CENTER_Y-s.y/2))},v.radialLayout=function(t,e,i){var r=Math.max(this.maxDiagonalInTree(t),h.DEFAULT_RADIAL_SEPARATION);v.branchRadialLayout(e,null,0,359,0,r);var n=y.calculateBounds(t),o=new E;o.setDeviceOrgX(n.getMinX()),o.setDeviceOrgY(n.getMinY()),o.setWorldOrgX(i.x),o.setWorldOrgY(i.y);for(var s=0;s<t.length;s++)t[s].transform(o);var a=new c(n.getMaxX(),n.getMaxY());return o.inverseTransformPoint(a)},v.branchRadialLayout=function(t,e,i,r,n,o){var s,a=(r-i+1)/2;a<0&&(a+=180);var h=(a+i)%360*f.TWO_PI/360,l=n*Math.cos(h),g=n*Math.sin(h);t.setCenter(l,g);var u=[],c=(u=u.concat(t.getEdges())).length;null!=e&&c--;for(var d=0,p=u.length,y=t.getEdgesBetween(e);y.length>1;){var E=y[0];y.splice(0,1);var A=u.indexOf(E);A>=0&&u.splice(A,1),p--,c--}s=null!=e?(u.indexOf(y[0])+1)%p:0;for(var N=Math.abs(r-i)/c,T=s;d!=c;T=++T%p){var _=u[T].getOtherEnd(t);if(_!=e){var L=(i+d*N)%360,m=(L+N)%360;v.branchRadialLayout(_,t,L,m,n+o,o),d++}}},v.maxDiagonalInTree=function(t){for(var e=p.MIN_VALUE,i=0;i<t.length;i++){var r=t[i].getDiagonal();r>e&&(e=r)}return e},v.prototype.calcRepulsionRange=function(){return 2*(this.level+1)*this.idealEdgeLength},v.prototype.groupZeroDegreeMembers=function(){var t=this,e={};this.memberGroups={},this.idToDummyNode={};for(var i=[],r=this.graphManager.getAllNodes(),n=0;n<r.length;n++){var o=r[n],a=o.getParent();0!==this.getNodeDegreeWithChildren(o)||void 0!=a.id&&this.getToBeTiled(a)||i.push(o)}for(var n=0;n<i.length;n++){var o=i[n],h=o.getParent().id;void 0===e[h]&&(e[h]=[]),e[h]=e[h].concat(o)}Object.keys(e).forEach(function(i){if(e[i].length>1){var r="DummyCompound_"+i;t.memberGroups[r]=e[i];var n=e[i][0].getParent(),o=new s(t.graphManager);o.id=r,o.paddingLeft=n.paddingLeft||0,o.paddingRight=n.paddingRight||0,o.paddingBottom=n.paddingBottom||0,o.paddingTop=n.paddingTop||0,t.idToDummyNode[r]=o;var a=t.getGraphManager().add(t.newGraph(),o),h=n.getChild();h.add(o);for(var l=0;l<e[i].length;l++){var g=e[i][l];h.remove(g),a.add(g)}}})},v.prototype.clearCompounds=function(){var t={},e={};this.performDFSOnCompounds();for(var i=0;i<this.compoundOrder.length;i++)e[this.compoundOrder[i].id]=this.compoundOrder[i],t[this.compoundOrder[i].id]=[].concat(this.compoundOrder[i].getChild().getNodes()),this.graphManager.remove(this.compoundOrder[i].getChild()),this.compoundOrder[i].child=null;this.graphManager.resetAllNodes(),this.tileCompoundMembers(t,e)},v.prototype.clearZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack=[];Object.keys(this.memberGroups).forEach(function(i){var r=t.idToDummyNode[i];e[i]=t.tileNodes(t.memberGroups[i],r.paddingLeft+r.paddingRight),r.rect.width=e[i].width,r.rect.height=e[i].height})},v.prototype.repopulateCompounds=function(){for(var t=this.compoundOrder.length-1;t>=0;t--){var e=this.compoundOrder[t],i=e.id,r=e.paddingLeft,n=e.paddingTop;this.adjustLocations(this.tiledMemberPack[i],e.rect.x,e.rect.y,r,n)}},v.prototype.repopulateZeroDegreeMembers=function(){var t=this,e=this.tiledZeroDegreePack;Object.keys(e).forEach(function(i){var r=t.idToDummyNode[i],n=r.paddingLeft,o=r.paddingTop;t.adjustLocations(e[i],r.rect.x,r.rect.y,n,o)})},v.prototype.getToBeTiled=function(t){var e=t.id;if(null!=this.toBeTiled[e])return this.toBeTiled[e];var i=t.getChild();if(null==i)return this.toBeTiled[e]=!1,!1;for(var r=i.getNodes(),n=0;n<r.length;n++){var o=r[n];if(this.getNodeDegree(o)>0)return this.toBeTiled[e]=!1,!1;if(null==o.getChild()){this.toBeTiled[o.id]=!1;continue}if(!this.getToBeTiled(o))return this.toBeTiled[e]=!1,!1}return this.toBeTiled[e]=!0,!0},v.prototype.getNodeDegree=function(t){t.id;for(var e=t.getEdges(),i=0,r=0;r<e.length;r++){var n=e[r];n.getSource().id!==n.getTarget().id&&(i+=1)}return i},v.prototype.getNodeDegreeWithChildren=function(t){var e=this.getNodeDegree(t);if(null==t.getChild())return e;for(var i=t.getChild().getNodes(),r=0;r<i.length;r++){var n=i[r];e+=this.getNodeDegreeWithChildren(n)}return e},v.prototype.performDFSOnCompounds=function(){this.compoundOrder=[],this.fillCompexOrderByDFS(this.graphManager.getRoot().getNodes())},v.prototype.fillCompexOrderByDFS=function(t){for(var e=0;e<t.length;e++){var i=t[e];null!=i.getChild()&&this.fillCompexOrderByDFS(i.getChild().getNodes()),this.getToBeTiled(i)&&this.compoundOrder.push(i)}},v.prototype.adjustLocations=function(t,e,i,r,n){e+=r,i+=n;for(var o=e,s=0;s<t.rows.length;s++){var a=t.rows[s];e=o;for(var h=0,l=0;l<a.length;l++){var g=a[l];g.rect.x=e,g.rect.y=i,e+=g.rect.width+t.horizontalPadding,g.rect.height>h&&(h=g.rect.height)}i+=h+t.verticalPadding}},v.prototype.tileCompoundMembers=function(t,e){var i=this;this.tiledMemberPack=[],Object.keys(t).forEach(function(r){var n=e[r];i.tiledMemberPack[r]=i.tileNodes(t[r],n.paddingLeft+n.paddingRight),n.rect.width=i.tiledMemberPack[r].width,n.rect.height=i.tiledMemberPack[r].height})},v.prototype.tileNodes=function(t,e){var i={rows:[],rowWidth:[],rowHeight:[],width:0,height:e,verticalPadding:h.TILING_PADDING_VERTICAL,horizontalPadding:h.TILING_PADDING_HORIZONTAL};t.sort(function(t,e){return t.rect.width*t.rect.height>e.rect.width*e.rect.height?-1:+(t.rect.width*t.rect.height<e.rect.width*e.rect.height)});for(var r=0;r<t.length;r++){var n=t[r];0==i.rows.length?this.insertNodeToRow(i,n,0,e):this.canAddHorizontal(i,n.rect.width,n.rect.height)?this.insertNodeToRow(i,n,this.getShortestRowIndex(i),e):this.insertNodeToRow(i,n,i.rows.length,e),this.shiftToLastRow(i)}return i},v.prototype.insertNodeToRow=function(t,e,i,r){i==t.rows.length&&(t.rows.push([]),t.rowWidth.push(r),t.rowHeight.push(0));var n=t.rowWidth[i]+e.rect.width;t.rows[i].length>0&&(n+=t.horizontalPadding),t.rowWidth[i]=n,t.width<n&&(t.width=n);var o=e.rect.height;i>0&&(o+=t.verticalPadding);var s=0;o>t.rowHeight[i]&&(s=t.rowHeight[i],t.rowHeight[i]=o,s=t.rowHeight[i]-s),t.height+=s,t.rows[i].push(e)},v.prototype.getShortestRowIndex=function(t){for(var e=-1,i=Number.MAX_VALUE,r=0;r<t.rows.length;r++)t.rowWidth[r]<i&&(e=r,i=t.rowWidth[r]);return e},v.prototype.getLongestRowIndex=function(t){for(var e=-1,i=5e-324,r=0;r<t.rows.length;r++)t.rowWidth[r]>i&&(e=r,i=t.rowWidth[r]);return e},v.prototype.canAddHorizontal=function(t,e,i){var r,n,o=this.getShortestRowIndex(t);if(o<0)return!0;var s=t.rowWidth[o];if(s+t.horizontalPadding+e<=t.width)return!0;var a=0;return t.rowHeight[o]<i&&o>0&&(a=i+t.verticalPadding-t.rowHeight[o]),r=t.width-s>=e+t.horizontalPadding?(t.height+a)/(s+e+t.horizontalPadding):(t.height+a)/t.width,a=i+t.verticalPadding,(n=t.width<e?(t.height+a)/e:(t.height+a)/t.width)<1&&(n=1/n),r<1&&(r=1/r),r<n},v.prototype.shiftToLastRow=function(t){var e=this.getLongestRowIndex(t),i=t.rowWidth.length-1,r=t.rows[e],n=r[r.length-1],o=n.width+t.horizontalPadding;if(t.width-t.rowWidth[i]>o&&e!=i){r.splice(-1,1),t.rows[i].push(n),t.rowWidth[e]=t.rowWidth[e]-o,t.rowWidth[i]=t.rowWidth[i]+o,t.width=t.rowWidth[instance.getLongestRowIndex(t)];for(var s=5e-324,a=0;a<r.length;a++)r[a].height>s&&(s=r[a].height);e>0&&(s+=t.verticalPadding);var h=t.rowHeight[e]+t.rowHeight[i];t.rowHeight[e]=s,t.rowHeight[i]<n.height+t.verticalPadding&&(t.rowHeight[i]=n.height+t.verticalPadding);var l=t.rowHeight[e]+t.rowHeight[i];t.height+=l-h,this.shiftToLastRow(t)}},v.prototype.tilingPreLayout=function(){h.TILE&&(this.groupZeroDegreeMembers(),this.clearCompounds(),this.clearZeroDegreeMembers())},v.prototype.tilingPostLayout=function(){h.TILE&&(this.repopulateZeroDegreeMembers(),this.repopulateCompounds())},v.prototype.reduceTrees=function(){for(var t,e=[],i=!0;i;){var r=this.graphManager.getAllNodes(),n=[];i=!1;for(var o=0;o<r.length;o++)1!=(t=r[o]).getEdges().length||t.getEdges()[0].isInterGraph||null!=t.getChild()||(n.push([t,t.getEdges()[0],t.getOwner()]),i=!0);if(!0==i){for(var s=[],a=0;a<n.length;a++)1==n[a][0].getEdges().length&&(s.push(n[a]),n[a][0].getOwner().remove(n[a][0]));e.push(s),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()}}this.prunedNodesAll=e},v.prototype.growTree=function(t){for(var e,i=t.length,r=t[i-1],n=0;n<r.length;n++)e=r[n],this.findPlaceforPrunedNode(e),e[2].add(e[0]),e[2].add(e[1],e[1].source,e[1].target);t.splice(t.length-1,1),this.graphManager.resetAllNodes(),this.graphManager.resetAllEdges()},v.prototype.findPlaceforPrunedNode=function(t){var e,i,r,n,o=t[0],s=(i=o==t[1].source?t[1].target:t[1].source).startX,a=i.finishX,h=i.startY,g=i.finishY,u=[0,0,0,0];if(h>0)for(var c=s;c<=a;c++)u[0]+=this.grid[c][h-1].length+this.grid[c][h].length-1;if(a<this.grid.length-1)for(var c=h;c<=g;c++)u[1]+=this.grid[a+1][c].length+this.grid[a][c].length-1;if(g<this.grid[0].length-1)for(var c=s;c<=a;c++)u[2]+=this.grid[c][g+1].length+this.grid[c][g].length-1;if(s>0)for(var c=h;c<=g;c++)u[3]+=this.grid[s-1][c].length+this.grid[s][c].length-1;for(var d=p.MAX_VALUE,f=0;f<u.length;f++)u[f]<d?(d=u[f],r=1,n=f):u[f]==d&&r++;if(3==r&&0==d)0==u[0]&&0==u[1]&&0==u[2]?e=1:0==u[0]&&0==u[1]&&0==u[3]?e=0:0==u[0]&&0==u[2]&&0==u[3]?e=3:0==u[1]&&0==u[2]&&0==u[3]&&(e=2);else if(2==r&&0==d){var y=Math.floor(2*Math.random());e=0==u[0]&&0==u[1]?+(0!=y):0==u[0]&&0==u[2]?2*(0!=y):0==u[0]&&0==u[3]?3*(0!=y):0==u[1]&&0==u[2]?0==y?1:2:0==u[1]&&0==u[3]?0==y?1:3:0==y?2:3}else if(4==r&&0==d){var y=Math.floor(4*Math.random());e=y}else e=n;0==e?o.setCenter(i.getCenterX(),i.getCenterY()-i.getHeight()/2-l.DEFAULT_EDGE_LENGTH-o.getHeight()/2):1==e?o.setCenter(i.getCenterX()+i.getWidth()/2+l.DEFAULT_EDGE_LENGTH+o.getWidth()/2,i.getCenterY()):2==e?o.setCenter(i.getCenterX(),i.getCenterY()+i.getHeight()/2+l.DEFAULT_EDGE_LENGTH+o.getHeight()/2):o.setCenter(i.getCenterX()-i.getWidth()/2-l.DEFAULT_EDGE_LENGTH-o.getWidth()/2,i.getCenterY())},t.exports=v},function(t,e,i){"use strict";var r={};r.layoutBase=i(0),r.CoSEConstants=i(1),r.CoSEEdge=i(2),r.CoSEGraph=i(3),r.CoSEGraphManager=i(4),r.CoSELayout=i(6),r.CoSENode=i(5),t.exports=r}],i={};function r(t){if(i[t])return i[t].exports;var n=i[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=i,r.i=function(t){return t},r.d=function(t,e,i){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:i})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=7)}(i(5019))},3726:(t,e,i)=>{"use strict";i.r(e),i.d(e,{render:()=>p});var r=i(316),n=i(1452),o=i(9701),s=i(5508);function a(t,e){t.forEach(t=>{let i={id:t.id,labelText:t.label,height:t.height,width:t.width,padding:t.padding??0};Object.keys(t).forEach(e=>{["id","label","height","width","padding","x","y"].includes(e)||(i[e]=t[e])}),e.add({group:"nodes",data:i,position:{x:t.x??0,y:t.y??0}})})}function h(t,e){t.forEach(t=>{let i={id:t.id,source:t.start,target:t.end};Object.keys(t).forEach(e=>{["id","start","end"].includes(e)||(i[e]=t[e])}),e.add({group:"edges",data:i})})}function l(t){return new Promise(e=>{let i=(0,s.Ltv)("body").append("div").attr("id","cy").attr("style","display:none"),o=(0,n.A)({container:document.getElementById("cy"),style:[{selector:"edge",style:{"curve-style":"bezier"}}]});i.remove(),a(t.nodes,o),h(t.edges,o),o.nodes().forEach(function(t){t.layoutDimensions=()=>{let e=t.data();return{w:e.width,h:e.height}}}),o.layout({name:"cose-bilkent",quality:"proof",styleEnabled:!1,animate:!1}).run(),o.ready(t=>{r.Rm.info("Cytoscape ready",t),e(o)})})}function g(t){return t.nodes().map(t=>{let e=t.data(),i=t.position(),r={id:e.id,x:i.x,y:i.y};return Object.keys(e).forEach(t=>{"id"!==t&&(r[t]=e[t])}),r})}function u(t){return t.edges().map(t=>{let e=t.data(),i=t._private.rscratch,r={id:e.id,source:e.source,target:e.target,startX:i.startX,startY:i.startY,midX:i.midX,midY:i.midY,endX:i.endX,endY:i.endY};return Object.keys(e).forEach(t=>{["id","source","target"].includes(t)||(r[t]=e[t])}),r})}async function c(t,e){r.Rm.debug("Starting cose-bilkent layout algorithm");try{d(t);let e=await l(t),i=g(e),n=u(e);return r.Rm.debug(`Layout completed: ${i.length} nodes, ${n.length} edges`),{nodes:i,edges:n}}catch(t){throw r.Rm.error("Error in cose-bilkent layout algorithm:",t),t}}function d(t){if(!t)throw Error("Layout data is required");if(!t.config)throw Error("Configuration is required in layout data");if(!t.rootNode)throw Error("Root node is required");if(!t.nodes||!Array.isArray(t.nodes))throw Error("No nodes found in layout data");if(!Array.isArray(t.edges))throw Error("Edges array is required in layout data");return!0}n.A.use(o),(0,r.K2)(a,"addNodes"),(0,r.K2)(h,"addEdges"),(0,r.K2)(l,"createCytoscapeInstance"),(0,r.K2)(g,"extractPositionedNodes"),(0,r.K2)(u,"extractPositionedEdges"),(0,r.K2)(c,"executeCoseBilkentLayout"),(0,r.K2)(d,"validateLayoutData");var p=(0,r.K2)(async(t,e,{insertCluster:i,insertEdge:r,insertEdgeLabel:n,insertMarkers:o,insertNode:s,log:a,positionEdgeLabel:h},{algorithm:l})=>{let g={},u={},d=e.select("g");o(d,t.markers,t.type,t.diagramId);let p=d.insert("g").attr("class","subgraphs"),f=d.insert("g").attr("class","edgePaths"),y=d.insert("g").attr("class","edgeLabels"),E=d.insert("g").attr("class","nodes");a.debug("Inserting nodes into DOM for dimension calculation"),await Promise.all(t.nodes.map(async e=>{if(e.isGroup){let t={...e};u[e.id]=t,g[e.id]=t,await i(p,e)}else{let i={...e};g[e.id]=i;let r=await s(E,e,{config:t.config,dir:t.direction||"TB"}),n=r.node().getBBox();i.width=n.width,i.height=n.height,i.domId=r,a.debug(`Node ${e.id} dimensions: ${n.width}x${n.height}`)}})),a.debug("Running cose-bilkent layout algorithm");let v={...t,nodes:t.nodes.map(t=>{let e=g[t.id];return{...t,width:e.width,height:e.height}})},A=await c(v,t.config);a.debug("Positioning nodes based on layout results"),A.nodes.forEach(t=>{let e=g[t.id];e?.domId&&(e.domId.attr("transform",`translate(${t.x}, ${t.y})`),e.x=t.x,e.y=t.y,a.debug(`Positioned node ${e.id} at center (${t.x}, ${t.y})`))}),A.edges.forEach(e=>{let i=t.edges.find(t=>t.id===e.id);i&&(i.points=[{x:e.startX,y:e.startY},{x:e.midX,y:e.midY},{x:e.endX,y:e.endY}])}),a.debug("Inserting and positioning edges"),await Promise.all(t.edges.map(async e=>{await n(y,e);let i=g[e.start??""],o=g[e.end??""];if(i&&o){let n=A.edges.find(t=>t.id===e.id);if(n){a.debug("APA01 positionedEdge",n);let s={...e},l=r(f,s,u,t.type,i,o,t.diagramId);h(s,l)}else{let n={...e,points:[{x:i.x||0,y:i.y||0},{x:o.x||0,y:o.y||0}]},s=r(f,n,u,t.type,i,o,t.diagramId);h(n,s)}}})),a.debug("Cose-bilkent rendering completed")},"render")},5019:function(t){t.exports=function(){var t=[function(t,e,i){"use strict";function r(){}r.QUALITY=1,r.DEFAULT_CREATE_BENDS_AS_NEEDED=!1,r.DEFAULT_INCREMENTAL=!1,r.DEFAULT_ANIMATION_ON_LAYOUT=!0,r.DEFAULT_ANIMATION_DURING_LAYOUT=!1,r.DEFAULT_ANIMATION_PERIOD=50,r.DEFAULT_UNIFORM_LEAF_NODE_SIZES=!1,r.DEFAULT_GRAPH_MARGIN=15,r.NODE_DIMENSIONS_INCLUDE_LABELS=!1,r.SIMPLE_NODE_SIZE=40,r.SIMPLE_NODE_HALF_SIZE=r.SIMPLE_NODE_SIZE/2,r.EMPTY_COMPOUND_NODE_SIZE=40,r.MIN_EDGE_LENGTH=1,r.WORLD_BOUNDARY=1e6,r.INITIAL_WORLD_BOUNDARY=r.WORLD_BOUNDARY/1e3,r.WORLD_CENTER_X=1200,r.WORLD_CENTER_Y=900,t.exports=r},function(t,e,i){"use strict";var r=i(2),n=i(8),o=i(9);function s(t,e,i){r.call(this,i),this.isOverlapingSourceAndTarget=!1,this.vGraphObject=i,this.bendpoints=[],this.source=t,this.target=e}for(var a in s.prototype=Object.create(r.prototype),r)s[a]=r[a];s.prototype.getSource=function(){return this.source},s.prototype.getTarget=function(){return this.target},s.prototype.isInterGraph=function(){return this.isInterGraph},s.prototype.getLength=function(){return this.length},s.prototype.isOverlapingSourceAndTarget=function(){return this.isOverlapingSourceAndTarget},s.prototype.getBendpoints=function(){return this.bendpoints},s.prototype.getLca=function(){return this.lca},s.prototype.getSourceInLca=function(){return this.sourceInLca},s.prototype.getTargetInLca=function(){return this.targetInLca},s.prototype.getOtherEnd=function(t){if(this.source===t)return this.target;if(this.target===t)return this.source;throw"Node is not incident with this edge"},s.prototype.getOtherEndInGraph=function(t,e){for(var i=this.getOtherEnd(t),r=e.getGraphManager().getRoot();;){if(i.getOwner()==e)return i;if(i.getOwner()==r)break;i=i.getOwner().getParent()}return null},s.prototype.updateLength=function(){var t=[,,,,];this.isOverlapingSourceAndTarget=n.getIntersection(this.target.getRect(),this.source.getRect(),t),this.isOverlapingSourceAndTarget||(this.lengthX=t[0]-t[2],this.lengthY=t[1]-t[3],1>Math.abs(this.lengthX)&&(this.lengthX=o.sign(this.lengthX)),1>Math.abs(this.lengthY)&&(this.lengthY=o.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY))},s.prototype.updateLengthSimple=function(){this.lengthX=this.target.getCenterX()-this.source.getCenterX(),this.lengthY=this.target.getCenterY()-this.source.getCenterY(),1>Math.abs(this.lengthX)&&(this.lengthX=o.sign(this.lengthX)),1>Math.abs(this.lengthY)&&(this.lengthY=o.sign(this.lengthY)),this.length=Math.sqrt(this.lengthX*this.lengthX+this.lengthY*this.lengthY)},t.exports=s},function(t,e,i){"use strict";t.exports=function(t){this.vGraphObject=t}},function(t,e,i){"use strict";var r=i(2),n=i(10),o=i(13),s=i(0),a=i(16),h=i(4);function l(t,e,i,s){null==i&&null==s&&(s=e),r.call(this,s),null!=t.graphManager&&(t=t.graphManager),this.estimatedSize=n.MIN_VALUE,this.inclusionTreeDepth=n.MAX_VALUE,this.vGraphObject=s,this.edges=[],this.graphManager=t,null!=i&&null!=e?this.rect=new o(e.x,e.y,i.width,i.height):this.rect=new o}for(var g in l.prototype=Object.create(r.prototype),r)l[g]=r[g];l.prototype.getEdges=function(){return this.edges},l.prototype.getChild=function(){return this.child},l.prototype.getOwner=function(){return this.owner},l.prototype.getWidth=function(){return this.rect.width},l.prototype.setWidth=function(t){this.rect.width=t},l.prototype.getHeight=function(){return this.rect.height},l.prototype.setHeight=function(t){this.rect.height=t},l.prototype.getCenterX=function(){return this.rect.x+this.rect.width/2},l.prototype.getCenterY=function(){return this.rect.y+this.rect.height/2},l.prototype.getCenter=function(){return new h(this.rect.x+this.rect.width/2,this.rect.y+this.rect.height/2)},l.prototype.getLocation=function(){return new h(this.rect.x,this.rect.y)},l.prototype.getRect=function(){return this.rect},l.prototype.getDiagonal=function(){return Math.sqrt(this.rect.width*this.rect.width+this.rect.height*this.rect.height)},l.prototype.getHalfTheDiagonal=function(){return Math.sqrt(this.rect.height*this.rect.height+this.rect.width*this.rect.width)/2},l.prototype.setRect=function(t,e){this.rect.x=t.x,this.rect.y=t.y,this.rect.width=e.width,this.rect.height=e.height},l.prototype.setCenter=function(t,e){this.rect.x=t-this.rect.width/2,this.rect.y=e-this.rect.height/2},l.prototype.setLocation=function(t,e){this.rect.x=t,this.rect.y=e},l.prototype.moveBy=function(t,e){this.rect.x+=t,this.rect.y+=e},l.prototype.getEdgeListToNode=function(t){var e=[],i=this;return i.edges.forEach(function(r){if(r.target==t){if(r.source!=i)throw"Incorrect edge source!";e.push(r)}}),e},l.prototype.getEdgesBetween=function(t){var e=[],i=this;return i.edges.forEach(function(r){if(r.source!=i&&r.target!=i)throw"Incorrect edge source and/or target";(r.target==t||r.source==t)&&e.push(r)}),e},l.prototype.getNeighborsList=function(){var t=new Set,e=this;return e.edges.forEach(function(i){if(i.source==e)t.add(i.target);else{if(i.target!=e)throw"Incorrect incidency!";t.add(i.source)}}),t},l.prototype.withChildren=function(){var t=new Set;if(t.add(this),null!=this.child)for(var e=this.child.getNodes(),i=0;i<e.length;i++)e[i].withChildren().forEach(function(e){t.add(e)});return t},l.prototype.getNoOfChildren=function(){var t=0;if(null==this.child)t=1;else for(var e=this.child.getNodes(),i=0;i<e.length;i++)t+=e[i].getNoOfChildren();return 0==t&&(t=1),t},l.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},l.prototype.calcEstimatedSize=function(){return null==this.child?this.estimatedSize=(this.rect.width+this.rect.height)/2:(this.estimatedSize=this.child.calcEstimatedSize(),this.rect.width=this.estimatedSize,this.rect.height=this.estimatedSize,this.estimatedSize)},l.prototype.scatter=function(){var t,e,i=-s.INITIAL_WORLD_BOUNDARY,r=s.INITIAL_WORLD_BOUNDARY;t=s.WORLD_CENTER_X+a.nextDouble()*(r-i)+i;var n=-s.INITIAL_WORLD_BOUNDARY,o=s.INITIAL_WORLD_BOUNDARY;e=s.WORLD_CENTER_Y+a.nextDouble()*(o-n)+n,this.rect.x=t,this.rect.y=e},l.prototype.updateBounds=function(){if(null==this.getChild())throw"assert failed";if(0!=this.getChild().getNodes().length){var t=this.getChild();if(t.updateBounds(!0),this.rect.x=t.getLeft(),this.rect.y=t.getTop(),this.setWidth(t.getRight()-t.getLeft()),this.setHeight(t.getBottom()-t.getTop()),s.NODE_DIMENSIONS_INCLUDE_LABELS){var e=t.getRight()-t.getLeft(),i=t.getBottom()-t.getTop();this.labelWidth>e&&(this.rect.x-=(this.labelWidth-e)/2,this.setWidth(this.labelWidth)),this.labelHeight>i&&("center"==this.labelPos?this.rect.y-=(this.labelHeight-i)/2:"top"==this.labelPos&&(this.rect.y-=this.labelHeight-i),this.setHeight(this.labelHeight))}}},l.prototype.getInclusionTreeDepth=function(){if(this.inclusionTreeDepth==n.MAX_VALUE)throw"assert failed";return this.inclusionTreeDepth},l.prototype.transform=function(t){var e=this.rect.x;e>s.WORLD_BOUNDARY?e=s.WORLD_BOUNDARY:e<-s.WORLD_BOUNDARY&&(e=-s.WORLD_BOUNDARY);var i=this.rect.y;i>s.WORLD_BOUNDARY?i=s.WORLD_BOUNDARY:i<-s.WORLD_BOUNDARY&&(i=-s.WORLD_BOUNDARY);var r=new h(e,i),n=t.inverseTransformPoint(r);this.setLocation(n.x,n.y)},l.prototype.getLeft=function(){return this.rect.x},l.prototype.getRight=function(){return this.rect.x+this.rect.width},l.prototype.getTop=function(){return this.rect.y},l.prototype.getBottom=function(){return this.rect.y+this.rect.height},l.prototype.getParent=function(){return null==this.owner?null:this.owner.getParent()},t.exports=l},function(t,e,i){"use strict";function r(t,e){null==t&&null==e?(this.x=0,this.y=0):(this.x=t,this.y=e)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.setX=function(t){this.x=t},r.prototype.setY=function(t){this.y=t},r.prototype.getDifference=function(t){return new DimensionD(this.x-t.x,this.y-t.y)},r.prototype.getCopy=function(){return new r(this.x,this.y)},r.prototype.translate=function(t){return this.x+=t.width,this.y+=t.height,this},t.exports=r},function(t,e,i){"use strict";var r=i(2),n=i(10),o=i(0),s=i(6),a=i(3),h=i(1),l=i(13),g=i(12),u=i(11);function c(t,e,i){r.call(this,i),this.estimatedSize=n.MIN_VALUE,this.margin=o.DEFAULT_GRAPH_MARGIN,this.edges=[],this.nodes=[],this.isConnected=!1,this.parent=t,null!=e&&e instanceof s?this.graphManager=e:null!=e&&e instanceof Layout&&(this.graphManager=e.graphManager)}for(var d in c.prototype=Object.create(r.prototype),r)c[d]=r[d];c.prototype.getNodes=function(){return this.nodes},c.prototype.getEdges=function(){return this.edges},c.prototype.getGraphManager=function(){return this.graphManager},c.prototype.getParent=function(){return this.parent},c.prototype.getLeft=function(){return this.left},c.prototype.getRight=function(){return this.right},c.prototype.getTop=function(){return this.top},c.prototype.getBottom=function(){return this.bottom},c.prototype.isConnected=function(){return this.isConnected},c.prototype.add=function(t,e,i){if(null==e&&null==i){if(null==this.graphManager)throw"Graph has no graph mgr!";if(this.getNodes().indexOf(t)>-1)throw"Node already in graph!";return t.owner=this,this.getNodes().push(t),t}if(!(this.getNodes().indexOf(e)>-1&&this.getNodes().indexOf(i)>-1))throw"Source or target not in graph!";if(e.owner!=i.owner||e.owner!=this)throw"Both owners must be this graph!";return e.owner!=i.owner?null:(t.source=e,t.target=i,t.isInterGraph=!1,this.getEdges().push(t),e.edges.push(t),i!=e&&i.edges.push(t),t)},c.prototype.remove=function(t){if(t instanceof a){if(null==t)throw"Node is null!";if(null==t.owner||t.owner!=this)throw"Owner graph is invalid!";if(null==this.graphManager)throw"Owner graph manager is invalid!";for(var e,i=t.edges.slice(),r=i.length,n=0;n<r;n++)(e=i[n]).isInterGraph?this.graphManager.remove(e):e.source.owner.remove(e);var o=this.nodes.indexOf(t);if(-1==o)throw"Node not in owner node list!";this.nodes.splice(o,1)}else if(t instanceof h){var e=t;if(null==e)throw"Edge is null!";if(null==e.source||null==e.target)throw"Source and/or target is null!";if(null==e.source.owner||null==e.target.owner||e.source.owner!=this||e.target.owner!=this)throw"Source and/or target owner is invalid!";var s=e.source.edges.indexOf(e),l=e.target.edges.indexOf(e);if(!(s>-1&&l>-1))throw"Source and/or target doesn't know this edge!";e.source.edges.splice(s,1),e.target!=e.source&&e.target.edges.splice(l,1);var o=e.source.owner.getEdges().indexOf(e);if(-1==o)throw"Not in owner's edge list!";e.source.owner.getEdges().splice(o,1)}},c.prototype.updateLeftTop=function(){for(var t,e,i,r=n.MAX_VALUE,o=n.MAX_VALUE,s=this.getNodes(),a=s.length,h=0;h<a;h++){var l=s[h];t=l.getTop(),e=l.getLeft(),r>t&&(r=t),o>e&&(o=e)}return r==n.MAX_VALUE?null:(i=void 0!=s[0].getParent().paddingLeft?s[0].getParent().paddingLeft:this.margin,this.left=o-i,this.top=r-i,new g(this.left,this.top))},c.prototype.updateBounds=function(t){for(var e,i,r,o,s,a=n.MAX_VALUE,h=-n.MAX_VALUE,g=n.MAX_VALUE,u=-n.MAX_VALUE,c=this.nodes,d=c.length,p=0;p<d;p++){var f=c[p];t&&null!=f.child&&f.updateBounds(),e=f.getLeft(),i=f.getRight(),r=f.getTop(),o=f.getBottom(),a>e&&(a=e),h<i&&(h=i),g>r&&(g=r),u<o&&(u=o)}var y=new l(a,g,h-a,u-g);a==n.MAX_VALUE&&(this.left=this.parent.getLeft(),this.right=this.parent.getRight(),this.top=this.parent.getTop(),this.bottom=this.parent.getBottom()),s=void 0!=c[0].getParent().paddingLeft?c[0].getParent().paddingLeft:this.margin,this.left=y.x-s,this.right=y.x+y.width+s,this.top=y.y-s,this.bottom=y.y+y.height+s},c.calculateBounds=function(t){for(var e,i,r,o,s=n.MAX_VALUE,a=-n.MAX_VALUE,h=n.MAX_VALUE,g=-n.MAX_VALUE,u=t.length,c=0;c<u;c++){var d=t[c];e=d.getLeft(),i=d.getRight(),r=d.getTop(),o=d.getBottom(),s>e&&(s=e),a<i&&(a=i),h>r&&(h=r),g<o&&(g=o)}return new l(s,h,a-s,g-h)},c.prototype.getInclusionTreeDepth=function(){return this==this.graphManager.getRoot()?1:this.parent.getInclusionTreeDepth()},c.prototype.getEstimatedSize=function(){if(this.estimatedSize==n.MIN_VALUE)throw"assert failed";return this.estimatedSize},c.prototype.calcEstimatedSize=function(){for(var t=0,e=this.nodes,i=e.length,r=0;r<i;r++)t+=e[r].calcEstimatedSize();return 0==t?this.estimatedSize=o.EMPTY_COMPOUND_NODE_SIZE:this.estimatedSize=t/Math.sqrt(this.nodes.length),this.estimatedSize},c.prototype.updateConnected=function(){var t,e,i=this;if(0==this.nodes.length){this.isConnected=!0;return}var r=new u,n=new Set,o=this.nodes[0];for(o.withChildren().forEach(function(t){r.push(t),n.add(t)});0!==r.length;)for(var s=(t=(o=r.shift()).getEdges()).length,a=0;a<s;a++)null==(e=t[a].getOtherEndInGraph(o,this))||n.has(e)||e.withChildren().forEach(function(t){r.push(t),n.add(t)});if(this.isConnected=!1,n.size>=this.nodes.length){var h=0;n.forEach(function(t){t.owner==i&&h++}),h==this.nodes.length&&(this.isConnected=!0)}},t.exports=c},function(t,e,i){"use strict";var r,n=i(1);function o(t){r=i(5),this.layout=t,this.graphs=[],this.edges=[]}o.prototype.addRoot=function(){var t=this.layout.newGraph(),e=this.layout.newNode(null),i=this.add(t,e);return this.setRootGraph(i),this.rootGraph},o.prototype.add=function(t,e,i,r,n){if(null==i&&null==r&&null==n){if(null==t)throw"Graph is null!";if(null==e)throw"Parent node is null!";if(this.graphs.indexOf(t)>-1)throw"Graph already in this graph mgr!";if(this.graphs.push(t),null!=t.parent)throw"Already has a parent!";if(null!=e.child)throw"Already has a child!";return t.parent=e,e.child=t,t}n=i,r=e,i=t;var o=r.getOwner(),s=n.getOwner();if(null==o||o.getGraphManager()!=this)throw"Source not in this graph mgr!";if(null==s||s.getGraphManager()!=this)throw"Target not in this graph mgr!";if(o==s)return i.isInterGraph=!1,o.add(i,r,n);if(i.isInterGraph=!0,i.source=r,i.target=n,this.edges.indexOf(i)>-1)throw"Edge already in inter-graph edge list!";if(this.edges.push(i),null==i.source||null==i.target)throw"Edge source and/or target is null!";if(-1!=i.source.edges.indexOf(i)||-1!=i.target.edges.indexOf(i))throw"Edge already in source and/or target incidency list!";return i.source.edges.push(i),i.target.edges.push(i),i},o.prototype.remove=function(t){if(t instanceof r){if(t.getGraphManager()!=this)throw"Graph not in this graph mgr";if(t!=this.rootGraph&&(null==t.parent||t.parent.graphManager!=this))throw"Invalid parent node!";for(var e,i,o=[],s=(o=o.concat(t.getEdges())).length,a=0;a<s;a++)e=o[a],t.remove(e);var h=[];s=(h=h.concat(t.getNodes())).length;for(var a=0;a<s;a++)i=h[a],t.remove(i);t==this.rootGraph&&this.setRootGraph(null);var l=this.graphs.indexOf(t);this.graphs.splice(l,1),t.parent=null}else if(t instanceof n){if(null==(e=t))throw"Edge is null!";if(!e.isInterGraph)throw"Not an inter-graph edge!";if(null==e.source||null==e.target)throw"Source and/or target is null!";if(-1==e.source.edges.indexOf(e)||-1==e.target.edges.indexOf(e))throw"Source and/or target doesn't know this edge!";var l=e.source.edges.indexOf(e);if(e.source.edges.splice(l,1),l=e.target.edges.indexOf(e),e.target.edges.splice(l,1),null==e.source.owner||null==e.source.owner.getGraphManager())throw"Edge owner graph or owner graph manager is null!";if(-1==e.source.owner.getGraphManager().edges.indexOf(e))throw"Not in owner graph manager's edge list!";var l=e.source.owner.getGraphManager().edges.indexOf(e);e.source.owner.getGraphManager().edges.splice(l,1)}},o.prototype.updateBounds=function(){this.rootGraph.updateBounds(!0)},o.prototype.getGraphs=function(){return this.graphs},o.prototype.getAllNodes=function(){if(null==this.allNodes){for(var t=[],e=this.getGraphs(),i=e.length,r=0;r<i;r++)t=t.concat(e[r].getNodes());this.allNodes=t}return this.allNodes},o.prototype.resetAllNodes=function(){this.allNodes=null},o.prototype.resetAllEdges=function(){this.allEdges=null},o.prototype.resetAllNodesToApplyGravitation=function(){this.allNodesToApplyGravitation=null},o.prototype.getAllEdges=function(){if(null==this.allEdges){var t=[],e=this.getGraphs();e.length;for(var i=0;i<e.length;i++)t=t.concat(e[i].getEdges());t=t.concat(this.edges),this.allEdges=t}return this.allEdges},o.prototype.getAllNodesToApplyGravitation=function(){return this.allNodesToApplyGravitation},o.prototype.setAllNodesToApplyGravitation=function(t){if(null!=this.allNodesToApplyGravitation)throw"assert failed";this.allNodesToApplyGravitation=t},o.prototype.getRoot=function(){return this.rootGraph},o.prototype.setRootGraph=function(t){if(t.getGraphManager()!=this)throw"Root not in this graph mgr!";this.rootGraph=t,null==t.parent&&(t.parent=this.layout.newNode("Root node"))},o.prototype.getLayout=function(){return this.layout},o.prototype.isOneAncestorOfOther=function(t,e){if(null==t||null==e)throw"assert failed";if(t==e)return!0;for(var i,r=t.getOwner();null!=(i=r.getParent());){if(i==e)return!0;if(null==(r=i.getOwner()))break}for(r=e.getOwner();null!=(i=r.getParent());){if(i==t)return!0;if(null==(r=i.getOwner()))break}return!1},o.prototype.calcLowestCommonAncestors=function(){for(var t,e,i,r,n,o=this.getAllEdges(),s=o.length,a=0;a<s;a++){if(e=(t=o[a]).source,i=t.target,t.lca=null,t.sourceInLca=e,t.targetInLca=i,e==i){t.lca=e.getOwner();continue}for(r=e.getOwner();null==t.lca;){for(t.targetInLca=i,n=i.getOwner();null==t.lca;){if(n==r){t.lca=n;break}if(n==this.rootGraph)break;if(null!=t.lca)throw"assert failed";t.targetInLca=n.getParent(),n=t.targetInLca.getOwner()}if(r==this.rootGraph)break;null==t.lca&&(t.sourceInLca=r.getParent(),r=t.sourceInLca.getOwner())}if(null==t.lca)throw"assert failed"}},o.prototype.calcLowestCommonAncestor=function(t,e){if(t==e)return t.getOwner();for(var i=t.getOwner();null!=i;){for(var r=e.getOwner();null!=r;){if(r==i)return r;r=r.getParent().getOwner()}i=i.getParent().getOwner()}return i},o.prototype.calcInclusionTreeDepths=function(t,e){null==t&&null==e&&(t=this.rootGraph,e=1);for(var i,r=t.getNodes(),n=r.length,o=0;o<n;o++)(i=r[o]).inclusionTreeDepth=e,null!=i.child&&this.calcInclusionTreeDepths(i.child,e+1)},o.prototype.includesInvalidEdge=function(){for(var t,e=this.edges.length,i=0;i<e;i++)if(t=this.edges[i],this.isOneAncestorOfOther(t.source,t.target))return!0;return!1},t.exports=o},function(t,e,i){"use strict";var r=i(0);function n(){}for(var o in r)n[o]=r[o];n.MAX_ITERATIONS=2500,n.DEFAULT_EDGE_LENGTH=50,n.DEFAULT_SPRING_STRENGTH=.45,n.DEFAULT_REPULSION_STRENGTH=4500,n.DEFAULT_GRAVITY_STRENGTH=.4,n.DEFAULT_COMPOUND_GRAVITY_STRENGTH=1,n.DEFAULT_GRAVITY_RANGE_FACTOR=3.8,n.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=1.5,n.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION=!0,n.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION=!0,n.DEFAULT_COOLING_FACTOR_INCREMENTAL=.3,n.COOLING_ADAPTATION_FACTOR=.33,n.ADAPTATION_LOWER_NODE_LIMIT=1e3,n.ADAPTATION_UPPER_NODE_LIMIT=5e3,n.MAX_NODE_DISPLACEMENT_INCREMENTAL=100,n.MAX_NODE_DISPLACEMENT=3*n.MAX_NODE_DISPLACEMENT_INCREMENTAL,n.MIN_REPULSION_DIST=n.DEFAULT_EDGE_LENGTH/10,n.CONVERGENCE_CHECK_PERIOD=100,n.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=.1,n.MIN_EDGE_LENGTH=1,n.GRID_CALCULATION_CHECK_PERIOD=10,t.exports=n},function(t,e,i){"use strict";var r=i(12);function n(){}n.calcSeparationAmount=function(t,e,i,r){if(!t.intersects(e))throw"assert failed";var n=[,,];this.decideDirectionsForOverlappingNodes(t,e,n),i[0]=Math.min(t.getRight(),e.getRight())-Math.max(t.x,e.x),i[1]=Math.min(t.getBottom(),e.getBottom())-Math.max(t.y,e.y),t.getX()<=e.getX()&&t.getRight()>=e.getRight()?i[0]+=Math.min(e.getX()-t.getX(),t.getRight()-e.getRight()):e.getX()<=t.getX()&&e.getRight()>=t.getRight()&&(i[0]+=Math.min(t.getX()-e.getX(),e.getRight()-t.getRight())),t.getY()<=e.getY()&&t.getBottom()>=e.getBottom()?i[1]+=Math.min(e.getY()-t.getY(),t.getBottom()-e.getBottom()):e.getY()<=t.getY()&&e.getBottom()>=t.getBottom()&&(i[1]+=Math.min(t.getY()-e.getY(),e.getBottom()-t.getBottom()));var o=Math.abs((e.getCenterY()-t.getCenterY())/(e.getCenterX()-t.getCenterX()));e.getCenterY()===t.getCenterY()&&e.getCenterX()===t.getCenterX()&&(o=1);var s=o*i[0],a=i[1]/o;i[0]<a?a=i[0]:s=i[1],i[0]=-1*n[0]*(a/2+r),i[1]=-1*n[1]*(s/2+r)},n.decideDirectionsForOverlappingNodes=function(t,e,i){t.getCenterX()<e.getCenterX()?i[0]=-1:i[0]=1,t.getCenterY()<e.getCenterY()?i[1]=-1:i[1]=1},n.getIntersection2=function(t,e,i){var r=t.getCenterX(),n=t.getCenterY(),o=e.getCenterX(),s=e.getCenterY();if(t.intersects(e))return i[0]=r,i[1]=n,i[2]=o,i[3]=s,!0;var a=t.getX(),h=t.getY(),l=t.getRight(),g=t.getX(),u=t.getBottom(),c=t.getRight(),d=t.getWidthHalf(),p=t.getHeightHalf(),f=e.getX(),y=e.getY(),E=e.getRight(),v=e.getX(),A=e.getBottom(),N=e.getRight(),T=e.getWidthHalf(),_=e.getHeightHalf(),L=!1,m=!1;if(r===o)n>s?(i[0]=r,i[1]=h,i[2]=o,i[3]=A):n<s&&(i[0]=r,i[1]=u,i[2]=o,i[3]=y);else if(n===s)r>o?(i[0]=a,i[1]=n,i[2]=E,i[3]=s):r<o&&(i[0]=l,i[1]=n,i[2]=f,i[3]=s);else{var O=t.height/t.width,I=e.height/e.width,D=(s-n)/(o-r),w=void 0,R=void 0,C=void 0,M=void 0,G=void 0,x=void 0;if(-O===D?(r>o?(i[0]=g,i[1]=u):(i[0]=l,i[1]=h),L=!0):O===D&&(r>o?(i[0]=a,i[1]=h):(i[0]=c,i[1]=u),L=!0),-I===D?(o>r?(i[2]=v,i[3]=A):(i[2]=E,i[3]=y),m=!0):I===D&&(o>r?(i[2]=f,i[3]=y):(i[2]=N,i[3]=A),m=!0),L&&m)return!1;if(r>o?n>s?(w=this.getCardinalDirection(O,D,4),R=this.getCardinalDirection(I,D,2)):(w=this.getCardinalDirection(-O,D,3),R=this.getCardinalDirection(-I,D,1)):n>s?(w=this.getCardinalDirection(-O,D,1),R=this.getCardinalDirection(-I,D,3)):(w=this.getCardinalDirection(O,D,2),R=this.getCardinalDirection(I,D,4)),!L)switch(w){case 1:M=h,C=r+-p/D,i[0]=C,i[1]=M;break;case 2:C=c,M=n+d*D,i[0]=C,i[1]=M;break;case 3:M=u,C=r+p/D,i[0]=C,i[1]=M;break;case 4:C=g,M=n+-d*D,i[0]=C,i[1]=M}if(!m)switch(R){case 1:x=y,G=o+-_/D,i[2]=G,i[3]=x;break;case 2:G=N,x=s+T*D,i[2]=G,i[3]=x;break;case 3:x=A,G=o+_/D,i[2]=G,i[3]=x;break;case 4:G=v,x=s+-T*D,i[2]=G,i[3]=x}}return!1},n.getCardinalDirection=function(t,e,i){return t>e?i:1+i%4},n.getIntersection=function(t,e,i,n){if(null==n)return this.getIntersection2(t,e,i);var o=t.x,s=t.y,a=e.x,h=e.y,l=i.x,g=i.y,u=n.x,c=n.y,d=void 0,p=void 0,f=void 0,y=void 0,E=void 0,v=void 0,A=void 0;return(d=h-s,f=o-a,E=a*s-o*h,p=c-g,y=l-u,v=u*g-l*c,0==(A=d*y-p*f))?null:new r((f*v-y*E)/A,(p*E-d*v)/A)},n.angleOfVector=function(t,e,i,r){var n=void 0;return t!==i?(n=Math.atan((r-e)/(i-t)),i<t?n+=Math.PI:r<e&&(n+=this.TWO_PI)):n=r<e?this.ONE_AND_HALF_PI:this.HALF_PI,n},n.doIntersect=function(t,e,i,r){var n=t.x,o=t.y,s=e.x,a=e.y,h=i.x,l=i.y,g=r.x,u=r.y,c=(s-n)*(u-l)-(g-h)*(a-o);if(0===c)return!1;var d=((u-l)*(g-n)+(h-g)*(u-o))/c,p=((o-a)*(g-n)+(s-n)*(u-o))/c;return 0<d&&d<1&&0<p&&p<1},n.HALF_PI=.5*Math.PI,n.ONE_AND_HALF_PI=1.5*Math.PI,n.TWO_PI=2*Math.PI,n.THREE_PI=3*Math.PI,t.exports=n},function(t,e,i){"use strict";function r(){}r.sign=function(t){return t>0?1:t<0?-1:0},r.floor=function(t){return t<0?Math.ceil(t):Math.floor(t)},r.ceil=function(t){return t<0?Math.floor(t):Math.ceil(t)},t.exports=r},function(t,e,i){"use strict";function r(){}r.MAX_VALUE=0x7fffffff,r.MIN_VALUE=-0x80000000,t.exports=r},function(t,e,i){"use strict";var r=function(){function t(t,e){for(var i=0;i<e.length;i++){var r=e[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,i,r){return i&&t(e.prototype,i),r&&t(e,r),e}}(),n=function(t){return{value:t,next:null,prev:null}},o=function(t,e,i,r){return null!==t?t.next=e:r.head=e,null!==i?i.prev=e:r.tail=e,e.prev=t,e.next=i,r.length++,e},s=function(t,e){var i=t.prev,r=t.next;return null!==i?i.next=r:e.head=r,null!==r?r.prev=i:e.tail=i,t.prev=t.next=null,e.length--,t};t.exports=function(){function t(e){var i=this;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");this.length=0,this.head=null,this.tail=null,null!=e&&e.forEach(function(t){return i.push(t)})}return r(t,[{key:"size",value:function(){return this.length}},{key:"insertBefore",value:function(t,e){return o(e.prev,n(t),e,this)}},{key:"insertAfter",value:function(t,e){return o(e,n(t),e.next,this)}},{key:"insertNodeBefore",value:function(t,e){return o(e.prev,t,e,this)}},{key:"insertNodeAfter",value:function(t,e){return o(e,t,e.next,this)}},{key:"push",value:function(t){return o(this.tail,n(t),null,this)}},{key:"unshift",value:function(t){return o(null,n(t),this.head,this)}},{key:"remove",value:function(t){return s(t,this)}},{key:"pop",value:function(){return s(this.tail,this).value}},{key:"popNode",value:function(){return s(this.tail,this)}},{key:"shift",value:function(){return s(this.head,this).value}},{key:"shiftNode",value:function(){return s(this.head,this)}},{key:"get_object_at",value:function(t){if(t<=this.length()){for(var e=1,i=this.head;e<t;)i=i.next,e++;return i.value}}},{key:"set_object_at",value:function(t,e){if(t<=this.length()){for(var i=1,r=this.head;i<t;)r=r.next,i++;r.value=e}}}]),t}()},function(t,e,i){"use strict";function r(t,e,i){this.x=null,this.y=null,null==t&&null==e&&null==i?(this.x=0,this.y=0):"number"==typeof t&&"number"==typeof e&&null==i?(this.x=t,this.y=e):"Point"==t.constructor.name&&null==e&&null==i&&(i=t,this.x=i.x,this.y=i.y)}r.prototype.getX=function(){return this.x},r.prototype.getY=function(){return this.y},r.prototype.getLocation=function(){return new r(this.x,this.y)},r.prototype.setLocation=function(t,e,i){"Point"==t.constructor.name&&null==e&&null==i?(i=t,this.setLocation(i.x,i.y)):"number"==typeof t&&"number"==typeof e&&null==i&&(parseInt(t)==t&&parseInt(e)==e?this.move(t,e):(this.x=Math.floor(t+.5),this.y=Math.floor(e+.5)))},r.prototype.move=function(t,e){this.x=t,this.y=e},r.prototype.translate=function(t,e){this.x+=t,this.y+=e},r.prototype.equals=function(t){return"Point"==t.constructor.name?this.x==t.x&&this.y==t.y:this==t},r.prototype.toString=function(){return new r().constructor.name+"[x="+this.x+",y="+this.y+"]"},t.exports=r},function(t,e,i){"use strict";function r(t,e,i,r){this.x=0,this.y=0,this.width=0,this.height=0,null!=t&&null!=e&&null!=i&&null!=r&&(this.x=t,this.y=e,this.width=i,this.height=r)}r.prototype.getX=function(){return this.x},r.prototype.setX=function(t){this.x=t},r.prototype.getY=function(){return this.y},r.prototype.setY=function(t){this.y=t},r.prototype.getWidth=function(){return this.width},r.prototype.setWidth=function(t){this.width=t},r.prototype.getHeight=function(){return this.height},r.prototype.setHeight=function(t){this.height=t},r.prototype.getRight=function(){return this.x+this.width},r.prototype.getBottom=function(){return this.y+this.height},r.prototype.intersects=function(t){return!(this.getRight()<t.x||this.getBottom()<t.y||t.getRight()<this.x||t.getBottom()<this.y)},r.prototype.getCenterX=function(){return this.x+this.width/2},r.prototype.getMinX=function(){return this.getX()},r.prototype.getMaxX=function(){return this.getX()+this.width},r.prototype.getCenterY=function(){return this.y+this.height/2},r.prototype.getMinY=function(){return this.getY()},r.prototype.getMaxY=function(){return this.getY()+this.height},r.prototype.getWidthHalf=function(){return this.width/2},r.prototype.getHeightHalf=function(){return this.height/2},t.exports=r},function(t,e,i){"use strict";var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t};function n(){}n.lastID=0,n.createID=function(t){return n.isPrimitive(t)?t:(null!=t.uniqueID||(t.uniqueID=n.getString(),n.lastID++),t.uniqueID)},n.getString=function(t){return null==t&&(t=n.lastID),"Object#"+t},n.isPrimitive=function(t){var e=void 0===t?"undefined":r(t);return null==t||"object"!=e&&"function"!=e},t.exports=n},function(t,e,i){"use strict";function r(t){if(!Array.isArray(t))return Array.from(t);for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}var n=i(0),o=i(6),s=i(3),a=i(1),h=i(5),l=i(4),g=i(17),u=i(27);function c(t){u.call(this),this.layoutQuality=n.QUALITY,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.incremental=n.DEFAULT_INCREMENTAL,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES,this.edgeToDummyNodes=new Map,this.graphManager=new o(this),this.isLayoutFinished=!1,this.isSubLayout=!1,this.isRemoteUse=!1,null!=t&&(this.isRemoteUse=t)}c.RANDOM_SEED=1,c.prototype=Object.create(u.prototype),c.prototype.getGraphManager=function(){return this.graphManager},c.prototype.getAllNodes=function(){return this.graphManager.getAllNodes()},c.prototype.getAllEdges=function(){return this.graphManager.getAllEdges()},c.prototype.getAllNodesToApplyGravitation=function(){return this.graphManager.getAllNodesToApplyGravitation()},c.prototype.newGraphManager=function(){var t=new o(this);return this.graphManager=t,t},c.prototype.newGraph=function(t){return new h(null,this.graphManager,t)},c.prototype.newNode=function(t){return new s(this.graphManager,t)},c.prototype.newEdge=function(t){return new a(null,null,t)},c.prototype.checkLayoutSuccess=function(){return null==this.graphManager.getRoot()||0==this.graphManager.getRoot().getNodes().length||this.graphManager.includesInvalidEdge()},c.prototype.runLayout=function(){var t;return this.isLayoutFinished=!1,this.tilingPreLayout&&this.tilingPreLayout(),this.initParameters(),t=!this.checkLayoutSuccess()&&this.layout(),"during"!==n.ANIMATE&&(t&&!this.isSubLayout&&this.doPostLayout(),this.tilingPostLayout&&this.tilingPostLayout(),this.isLayoutFinished=!0,t)},c.prototype.doPostLayout=function(){this.incremental||this.transform(),this.update()},c.prototype.update2=function(){if(this.createBendsAsNeeded&&(this.createBendpointsFromDummyNodes(),this.graphManager.resetAllEdges()),!this.isRemoteUse){for(var t=this.graphManager.getAllEdges(),e=0;e<t.length;e++)t[e];for(var i=this.graphManager.getRoot().getNodes(),e=0;e<i.length;e++)i[e];this.update(this.graphManager.getRoot())}},c.prototype.update=function(t){if(null==t)this.update2();else if(t instanceof s){if(null!=t.getChild())for(var e=t.getChild().getNodes(),i=0;i<e.length;i++)update(e[i]);null!=t.vGraphObject&&t.vGraphObject.update(t)}else t instanceof a?null!=t.vGraphObject&&t.vGraphObject.update(t):t instanceof h&&null!=t.vGraphObject&&t.vGraphObject.update(t)},c.prototype.initParameters=function(){this.isSubLayout||(this.layoutQuality=n.QUALITY,this.animationDuringLayout=n.DEFAULT_ANIMATION_DURING_LAYOUT,this.animationPeriod=n.DEFAULT_ANIMATION_PERIOD,this.animationOnLayout=n.DEFAULT_ANIMATION_ON_LAYOUT,this.incremental=n.DEFAULT_INCREMENTAL,this.createBendsAsNeeded=n.DEFAULT_CREATE_BENDS_AS_NEEDED,this.uniformLeafNodeSizes=n.DEFAULT_UNIFORM_LEAF_NODE_SIZES),this.animationDuringLayout&&(this.animationOnLayout=!1)},c.prototype.transform=function(t){if(void 0==t)this.transform(new l(0,0));else{var e=new g,i=this.graphManager.getRoot().updateLeftTop();if(null!=i){e.setWorldOrgX(t.x),e.setWorldOrgY(t.y),e.setDeviceOrgX(i.x),e.setDeviceOrgY(i.y);for(var r=this.getAllNodes(),n=0;n<r.length;n++)r[n].transform(e)}}},c.prototype.positionNodesRandomly=function(t){if(void 0==t)this.positionNodesRandomly(this.getGraphManager().getRoot()),this.getGraphManager().getRoot().updateBounds(!0);else for(var e,i,r=t.getNodes(),n=0;n<r.length;n++)null==(i=(e=r[n]).getChild())||0==i.getNodes().length?e.scatter():(this.positionNodesRandomly(i),e.updateBounds())},c.prototype.getFlatForest=function(){for(var t=[],e=!0,i=this.graphManager.getRoot().getNodes(),n=!0,o=0;o<i.length;o++)null!=i[o].getChild()&&(n=!1);if(!n)return t;var s=new Set,a=[],h=new Map,l=[];for(l=l.concat(i);l.length>0&&e;){for(a.push(l[0]);a.length>0&&e;){var g=a[0];a.splice(0,1),s.add(g);for(var u=g.getEdges(),o=0;o<u.length;o++){var c=u[o].getOtherEnd(g);if(h.get(g)!=c)if(s.has(c)){e=!1;break}else a.push(c),h.set(c,g)}}if(e){var d=[].concat(r(s));t.push(d);for(var o=0;o<d.length;o++){var p=d[o],f=l.indexOf(p);f>-1&&l.splice(f,1)}s=new Set,h=new Map}else t=[]}return t},c.prototype.createDummyNodesForBendpoints=function(t){for(var e=[],i=t.source,r=this.graphManager.calcLowestCommonAncestor(t.source,t.target),n=0;n<t.bendpoints.length;n++){var o=this.newNode(null);o.setRect(new Point(0,0),new Dimension(1,1)),r.add(o);var s=this.newEdge(null);this.graphManager.add(s,i,o),e.add(o),i=o}var s=this.newEdge(null);return this.graphManager.add(s,i,t.target),this.edgeToDummyNodes.set(t,e),t.isInterGraph()?this.graphManager.remove(t):r.remove(t),e},c.prototype.createBendpointsFromDummyNodes=function(){var t=[];t=t.concat(this.graphManager.getAllEdges()),t=[].concat(r(this.edgeToDummyNodes.keys())).concat(t);for(var e=0;e<t.length;e++){var i=t[e];if(i.bendpoints.length>0){for(var n=this.edgeToDummyNodes.get(i),o=0;o<n.length;o++){var s=n[o],a=new l(s.getCenterX(),s.getCenterY()),h=i.bendpoints.get(o);h.x=a.x,h.y=a.y,s.getOwner().remove(s)}this.graphManager.add(i,i.source,i.target)}}},c.transform=function(t,e,i,r){if(void 0==i||void 0==r)return t<=50?(n=9*e/500,o=e/10):(n=9*e/50,o=-8*e),n*t+o;var n,o,s=e;return t<=50?s-=(e-e/i)/50*(50-t):s+=(e*r-e)/50*(t-50),s},c.findCenterOfTree=function(t){var e=[];e=e.concat(t);var i=[],r=new Map,n=!1,o=null;(1==e.length||2==e.length)&&(n=!0,o=e[0]);for(var s=0;s<e.length;s++){var a=e[s],h=a.getNeighborsList().size;r.set(a,a.getNeighborsList().size),1==h&&i.push(a)}var l=[];for(l=l.concat(i);!n;){var g=[];g=g.concat(l),l=[];for(var s=0;s<e.length;s++){var a=e[s],u=e.indexOf(a);u>=0&&e.splice(u,1),a.getNeighborsList().forEach(function(t){if(0>i.indexOf(t)){var e=r.get(t)-1;1==e&&l.push(t),r.set(t,e)}})}i=i.concat(l),(1==e.length||2==e.length)&&(n=!0,o=e[0])}return o},c.prototype.setGraphManager=function(t){this.graphManager=t},t.exports=c},function(t,e,i){"use strict";function r(){}r.seed=1,r.x=0,r.nextDouble=function(){return r.x=1e4*Math.sin(r.seed++),r.x-Math.floor(r.x)},t.exports=r},function(t,e,i){"use strict";var r=i(4);function n(t,e){this.lworldOrgX=0,this.lworldOrgY=0,this.ldeviceOrgX=0,this.ldeviceOrgY=0,this.lworldExtX=1,this.lworldExtY=1,this.ldeviceExtX=1,this.ldeviceExtY=1}n.prototype.getWorldOrgX=function(){return this.lworldOrgX},n.prototype.setWorldOrgX=function(t){this.lworldOrgX=t},n.prototype.getWorldOrgY=function(){return this.lworldOrgY},n.prototype.setWorldOrgY=function(t){this.lworldOrgY=t},n.prototype.getWorldExtX=function(){return this.lworldExtX},n.prototype.setWorldExtX=function(t){this.lworldExtX=t},n.prototype.getWorldExtY=function(){return this.lworldExtY},n.prototype.setWorldExtY=function(t){this.lworldExtY=t},n.prototype.getDeviceOrgX=function(){return this.ldeviceOrgX},n.prototype.setDeviceOrgX=function(t){this.ldeviceOrgX=t},n.prototype.getDeviceOrgY=function(){return this.ldeviceOrgY},n.prototype.setDeviceOrgY=function(t){this.ldeviceOrgY=t},n.prototype.getDeviceExtX=function(){return this.ldeviceExtX},n.prototype.setDeviceExtX=function(t){this.ldeviceExtX=t},n.prototype.getDeviceExtY=function(){return this.ldeviceExtY},n.prototype.setDeviceExtY=function(t){this.ldeviceExtY=t},n.prototype.transformX=function(t){var e=0,i=this.lworldExtX;return 0!=i&&(e=this.ldeviceOrgX+(t-this.lworldOrgX)*this.ldeviceExtX/i),e},n.prototype.transformY=function(t){var e=0,i=this.lworldExtY;return 0!=i&&(e=this.ldeviceOrgY+(t-this.lworldOrgY)*this.ldeviceExtY/i),e},n.prototype.inverseTransformX=function(t){var e=0,i=this.ldeviceExtX;return 0!=i&&(e=this.lworldOrgX+(t-this.ldeviceOrgX)*this.lworldExtX/i),e},n.prototype.inverseTransformY=function(t){var e=0,i=this.ldeviceExtY;return 0!=i&&(e=this.lworldOrgY+(t-this.ldeviceOrgY)*this.lworldExtY/i),e},n.prototype.inverseTransformPoint=function(t){return new r(this.inverseTransformX(t.x),this.inverseTransformY(t.y))},t.exports=n},function(t,e,i){"use strict";var r=i(15),n=i(7),o=i(0),s=i(8),a=i(9);function h(){r.call(this),this.useSmartIdealEdgeLengthCalculation=n.DEFAULT_USE_SMART_IDEAL_EDGE_LENGTH_CALCULATION,this.idealEdgeLength=n.DEFAULT_EDGE_LENGTH,this.springConstant=n.DEFAULT_SPRING_STRENGTH,this.repulsionConstant=n.DEFAULT_REPULSION_STRENGTH,this.gravityConstant=n.DEFAULT_GRAVITY_STRENGTH,this.compoundGravityConstant=n.DEFAULT_COMPOUND_GRAVITY_STRENGTH,this.gravityRangeFactor=n.DEFAULT_GRAVITY_RANGE_FACTOR,this.compoundGravityRangeFactor=n.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR,this.displacementThresholdPerNode=3*n.DEFAULT_EDGE_LENGTH/100,this.coolingFactor=n.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.initialCoolingFactor=n.DEFAULT_COOLING_FACTOR_INCREMENTAL,this.totalDisplacement=0,this.oldTotalDisplacement=0,this.maxIterations=n.MAX_ITERATIONS}for(var l in h.prototype=Object.create(r.prototype),r)h[l]=r[l];h.prototype.initParameters=function(){r.prototype.initParameters.call(this,arguments),this.totalIterations=0,this.notAnimatedIterations=0,this.useFRGridVariant=n.DEFAULT_USE_SMART_REPULSION_RANGE_CALCULATION,this.grid=[]},h.prototype.calcIdealEdgeLengths=function(){for(var t,e,i,r,s,a,h=this.getGraphManager().getAllEdges(),l=0;l<h.length;l++)(t=h[l]).idealLength=this.idealEdgeLength,t.isInterGraph&&(i=t.getSource(),r=t.getTarget(),s=t.getSourceInLca().getEstimatedSize(),a=t.getTargetInLca().getEstimatedSize(),this.useSmartIdealEdgeLengthCalculation&&(t.idealLength+=s+a-2*o.SIMPLE_NODE_SIZE),e=t.getLca().getInclusionTreeDepth(),t.idealLength+=n.DEFAULT_EDGE_LENGTH*n.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR*(i.getInclusionTreeDepth()+r.getInclusionTreeDepth()-2*e))},h.prototype.initSpringEmbedder=function(){var t=this.getAllNodes().length;this.incremental?(t>n.ADAPTATION_LOWER_NODE_LIMIT&&(this.coolingFactor=Math.max(this.coolingFactor*n.COOLING_ADAPTATION_FACTOR,this.coolingFactor-(t-n.ADAPTATION_LOWER_NODE_LIMIT)/(n.ADAPTATION_UPPER_NODE_LIMIT-n.ADAPTATION_LOWER_NODE_LIMIT)*this.coolingFactor*(1-n.COOLING_ADAPTATION_FACTOR))),this.maxNodeDisplacement=n.MAX_NODE_DISPLACEMENT_INCREMENTAL):(t>n.ADAPTATION_LOWER_NODE_LIMIT?this.coolingFactor=Math.max(n.COOLING_ADAPTATION_FACTOR,1-(t-n.ADAPTATION_LOWER_NODE_LIMIT)/(n.ADAPTATION_UPPER_NODE_LIMIT-n.ADAPTATION_LOWER_NODE_LIMIT)*(1-n.COOLING_ADAPTATION_FACTOR)):this.coolingFactor=1,this.initialCoolingFactor=this.coolingFactor,this.maxNodeDisplacement=n.MAX_NODE_DISPLACEMENT),this.maxIterations=Math.max(5*this.getAllNodes().length,this.maxIterations),this.totalDisplacementThreshold=this.displacementThresholdPerNode*this.getAllNodes().length,this.repulsionRange=this.calcRepulsionRange()},h.prototype.calcSpringForces=function(){for(var t,e=this.getAllEdges(),i=0;i<e.length;i++)t=e[i],this.calcSpringForce(t,t.idealLength)},h.prototype.calcRepulsionForces=function(){var t,e,i,r,o,s=!(arguments.length>0)||void 0===arguments[0]||arguments[0],a=arguments.length>1&&void 0!==arguments[1]&&arguments[1],h=this.getAllNodes();if(this.useFRGridVariant)for(this.totalIterations%n.GRID_CALCULATION_CHECK_PERIOD==1&&s&&this.updateGrid(),o=new Set,t=0;t<h.length;t++)i=h[t],this.calculateRepulsionForceOfANode(i,o,s,a),o.add(i);else for(t=0;t<h.length;t++)for(i=h[t],e=t+1;e<h.length;e++)r=h[e],i.getOwner()==r.getOwner()&&this.calcRepulsionForce(i,r)},h.prototype.calcGravitationalForces=function(){for(var t,e=this.getAllNodesToApplyGravitation(),i=0;i<e.length;i++)t=e[i],this.calcGravitationalForce(t)},h.prototype.moveNodes=function(){for(var t=this.getAllNodes(),e=0;e<t.length;e++)t[e].move()},h.prototype.calcSpringForce=function(t,e){var i,r,n,o,s=t.getSource(),a=t.getTarget();if(this.uniformLeafNodeSizes&&null==s.getChild()&&null==a.getChild())t.updateLengthSimple();else if(t.updateLength(),t.isOverlapingSourceAndTarget)return;0!=(i=t.getLength())&&(n=(r=this.springConstant*(i-e))*(t.lengthX/i),o=r*(t.lengthY/i),s.springForceX+=n,s.springForceY+=o,a.springForceX-=n,a.springForceY-=o)},h.prototype.calcRepulsionForce=function(t,e){var i,r,o,h,l,g,u,c=t.getRect(),d=e.getRect(),p=[,,],f=[,,,,];if(c.intersects(d)){s.calcSeparationAmount(c,d,p,n.DEFAULT_EDGE_LENGTH/2),g=2*p[0],u=2*p[1];var y=t.noOfChildren*e.noOfChildren/(t.noOfChildren+e.noOfChildren);t.repulsionForceX-=y*g,t.repulsionForceY-=y*u,e.repulsionForceX+=y*g,e.repulsionForceY+=y*u}else this.uniformLeafNodeSizes&&null==t.getChild()&&null==e.getChild()?(i=d.getCenterX()-c.getCenterX(),r=d.getCenterY()-c.getCenterY()):(s.getIntersection(c,d,f),i=f[2]-f[0],r=f[3]-f[1]),Math.abs(i)<n.MIN_REPULSION_DIST&&(i=a.sign(i)*n.MIN_REPULSION_DIST),Math.abs(r)<n.MIN_REPULSION_DIST&&(r=a.sign(r)*n.MIN_REPULSION_DIST),h=Math.sqrt(o=i*i+r*r),g=(l=this.repulsionConstant*t.noOfChildren*e.noOfChildren/o)*i/h,u=l*r/h,t.repulsionForceX-=g,t.repulsionForceY-=u,e.repulsionForceX+=g,e.repulsionForceY+=u},h.prototype.calcGravitationalForce=function(t){var e,i,r,n,o,s,a,h;i=((e=t.getOwner()).getRight()+e.getLeft())/2,r=(e.getTop()+e.getBottom())/2,n=t.getCenterX()-i,o=t.getCenterY()-r,s=Math.abs(n)+t.getWidth()/2,a=Math.abs(o)+t.getHeight()/2,t.getOwner()==this.graphManager.getRoot()?(s>(h=e.getEstimatedSize()*this.gravityRangeFactor)||a>h)&&(t.gravitationForceX=-this.gravityConstant*n,t.gravitationForceY=-this.gravityConstant*o):(s>(h=e.getEstimatedSize()*this.compoundGravityRangeFactor)||a>h)&&(t.gravitationForceX=-this.gravityConstant*n*this.compoundGravityConstant,t.gravitationForceY=-this.gravityConstant*o*this.compoundGravityConstant)},h.prototype.isConverged=function(){var t,e=!1;return this.totalIterations>this.maxIterations/3&&(e=2>Math.abs(this.totalDisplacement-this.oldTotalDisplacement)),t=this.totalDisplacement<this.totalDisplacementThreshold,this.oldTotalDisplacement=this.totalDisplacement,t||e},h.prototype.animate=function(){this.animationDuringLayout&&!this.isSubLayout&&(this.notAnimatedIterations==this.animationPeriod?(this.update(),this.notAnimatedIterations=0):this.notAnimatedIterations++)},h.prototype.calcNoOfChildrenForAllNodes=function(){for(var t,e=this.graphManager.getAllNodes(),i=0;i<e.length;i++)(t=e[i]).noOfChildren=t.getNoOfChildren()},h.prototype.calcGrid=function(t){var e=0,i=0;e=parseInt(Math.ceil((t.getRight()-t.getLeft())/this.repulsionRange)),i=parseInt(Math.ceil((t.getBottom()-t.getTop())/this.repulsionRange));for(var r=Array(e),n=0;n<e;n++)r[n]=Array(i);for(var n=0;n<e;n++)for(var o=0;o<i;o++)r[n][o]=[];return r},h.prototype.addNodeToGrid=function(t,e,i){var r=0,n=0,o=0,s=0;r=parseInt(Math.floor((t.getRect().x-e)/this.repulsionRange)),n=parseInt(Math.floor((t.getRect().width+t.getRect().x-e)/this.repulsionRange)),o=parseInt(Math.floor((t.getRect().y-i)/this.repulsionRange)),s=parseInt(Math.floor((t.getRect().height+t.getRect().y-i)/this.repulsionRange));for(var a=r;a<=n;a++)for(var h=o;h<=s;h++)this.grid[a][h].push(t),t.setGridCoordinates(r,n,o,s)},h.prototype.updateGrid=function(){var t,e,i=this.getAllNodes();for(t=0,this.grid=this.calcGrid(this.graphManager.getRoot());t<i.length;t++)e=i[t],this.addNodeToGrid(e,this.graphManager.getRoot().getLeft(),this.graphManager.getRoot().getTop())},h.prototype.calculateRepulsionForceOfANode=function(t,e,i,r){if(this.totalIterations%n.GRID_CALCULATION_CHECK_PERIOD==1&&i||r){var o,s=new Set;t.surrounding=[];for(var a=this.grid,h=t.startX-1;h<t.finishX+2;h++)for(var l=t.startY-1;l<t.finishY+2;l++)if(!(h<0||l<0||h>=a.length||l>=a[0].length)){for(var g=0;g<a[h][l].length;g++)if(o=a[h][l][g],t.getOwner()==o.getOwner()&&t!=o&&!e.has(o)&&!s.has(o)){var u=Math.abs(t.getCenterX()-o.getCenterX())-(t.getWidth()/2+o.getWidth()/2),c=Math.abs(t.getCenterY()-o.getCenterY())-(t.getHeight()/2+o.getHeight()/2);u<=this.repulsionRange&&c<=this.repulsionRange&&s.add(o)}}t.surrounding=[].concat(function(t){if(!Array.isArray(t))return Array.from(t);for(var e=0,i=Array(t.length);e<t.length;e++)i[e]=t[e];return i}(s))}for(h=0;h<t.surrounding.length;h++)this.calcRepulsionForce(t,t.surrounding[h])},h.prototype.calcRepulsionRange=function(){return 0},t.exports=h},function(t,e,i){"use strict";var r=i(1),n=i(7);function o(t,e,i){r.call(this,t,e,i),this.idealLength=n.DEFAULT_EDGE_LENGTH}for(var s in o.prototype=Object.create(r.prototype),r)o[s]=r[s];t.exports=o},function(t,e,i){"use strict";var r=i(3);function n(t,e,i,n){r.call(this,t,e,i,n),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=[]}for(var o in n.prototype=Object.create(r.prototype),r)n[o]=r[o];n.prototype.setGridCoordinates=function(t,e,i,r){this.startX=t,this.finishX=e,this.startY=i,this.finishY=r},t.exports=n},function(t,e,i){"use strict";function r(t,e){this.width=0,this.height=0,null!==t&&null!==e&&(this.height=e,this.width=t)}r.prototype.getWidth=function(){return this.width},r.prototype.setWidth=function(t){this.width=t},r.prototype.getHeight=function(){return this.height},r.prototype.setHeight=function(t){this.height=t},t.exports=r},function(t,e,i){"use strict";var r=i(14);function n(){this.map={},this.keys=[]}n.prototype.put=function(t,e){var i=r.createID(t);this.contains(i)||(this.map[i]=e,this.keys.push(t))},n.prototype.contains=function(t){return r.createID(t),null!=this.map[t]},n.prototype.get=function(t){var e=r.createID(t);return this.map[e]},n.prototype.keySet=function(){return this.keys},t.exports=n},function(t,e,i){"use strict";var r=i(14);function n(){this.set={}}n.prototype.add=function(t){var e=r.createID(t);this.contains(e)||(this.set[e]=t)},n.prototype.remove=function(t){delete this.set[r.createID(t)]},n.prototype.clear=function(){this.set={}},n.prototype.contains=function(t){return this.set[r.createID(t)]==t},n.prototype.isEmpty=function(){return 0===this.size()},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAllTo=function(t){for(var e=Object.keys(this.set),i=e.length,r=0;r<i;r++)t.push(this.set[e[r]])},n.prototype.size=function(){return Object.keys(this.set).length},n.prototype.addAll=function(t){for(var e=t.length,i=0;i<e;i++){var r=t[i];this.add(r)}},t.exports=n},function(t,e,i){"use strict";var r=function(){function t(t,e){for(var i=0;i<e.length;i++){var r=e[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,i,r){return i&&t(e.prototype,i),r&&t(e,r),e}}(),n=i(11);t.exports=function(){function t(e,i){if(!(this instanceof t))throw TypeError("Cannot call a class as a function");(null!==i||void 0!==i)&&(this.compareFunction=this._defaultCompareFunction);var r=void 0;r=e instanceof n?e.size():e.length,this._quicksort(e,0,r-1)}return r(t,[{key:"_quicksort",value:function(t,e,i){if(e<i){var r=this._partition(t,e,i);this._quicksort(t,e,r),this._quicksort(t,r+1,i)}}},{key:"_partition",value:function(t,e,i){for(var r=this._get(t,e),n=e,o=i;;){for(;this.compareFunction(r,this._get(t,o));)o--;for(;this.compareFunction(this._get(t,n),r);)n++;if(!(n<o))return o;this._swap(t,n,o),n++,o--}}},{key:"_get",value:function(t,e){return t instanceof n?t.get_object_at(e):t[e]}},{key:"_set",value:function(t,e,i){t instanceof n?t.set_object_at(e,i):t[e]=i}},{key:"_swap",value:function(t,e,i){var r=this._get(t,e);this._set(t,e,this._get(t,i)),this._set(t,i,r)}},{key:"_defaultCompareFunction",value:function(t,e){return e>t}}]),t}()},function(t,e,i){"use strict";var r=function(){function t(t,e){for(var i=0;i<e.length;i++){var r=e[i];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(t,r.key,r)}}return function(e,i,r){return i&&t(e.prototype,i),r&&t(e,r),e}}();t.exports=function(){function t(e,i){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:-1,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:-1;if(!(this instanceof t))throw TypeError("Cannot call a class as a function");this.sequence1=e,this.sequence2=i,this.match_score=r,this.mismatch_penalty=n,this.gap_penalty=o,this.iMax=e.length+1,this.jMax=i.length+1,this.grid=Array(this.iMax);for(var s=0;s<this.iMax;s++){this.grid[s]=Array(this.jMax);for(var a=0;a<this.jMax;a++)this.grid[s][a]=0}this.tracebackGrid=Array(this.iMax);for(var h=0;h<this.iMax;h++){this.tracebackGrid[h]=Array(this.jMax);for(var l=0;l<this.jMax;l++)this.tracebackGrid[h][l]=[null,null,null]}this.alignments=[],this.score=-1,this.computeGrids()}return r(t,[{key:"getScore",value:function(){return this.score}},{key:"getAlignments",value:function(){return this.alignments}},{key:"computeGrids",value:function(){for(var t=1;t<this.jMax;t++)this.grid[0][t]=this.grid[0][t-1]+this.gap_penalty,this.tracebackGrid[0][t]=[!1,!1,!0];for(var e=1;e<this.iMax;e++)this.grid[e][0]=this.grid[e-1][0]+this.gap_penalty,this.tracebackGrid[e][0]=[!1,!0,!1];for(var i=1;i<this.iMax;i++)for(var r=1;r<this.jMax;r++){var n=[this.sequence1[i-1]===this.sequence2[r-1]?this.grid[i-1][r-1]+this.match_score:this.grid[i-1][r-1]+this.mismatch_penalty,this.grid[i-1][r]+this.gap_penalty,this.grid[i][r-1]+this.gap_penalty],o=this.arrayAllMaxIndexes(n);this.grid[i][r]=n[o[0]],this.tracebackGrid[i][r]=[o.includes(0),o.includes(1),o.includes(2)]}this.score=this.grid[this.iMax-1][this.jMax-1]}},{key:"alignmentTraceback",value:function(){var t=[];for(t.push({pos:[this.sequence1.length,this.sequence2.length],seq1:"",seq2:""});t[0];){var e=t[0],i=this.tracebackGrid[e.pos[0]][e.pos[1]];i[0]&&t.push({pos:[e.pos[0]-1,e.pos[1]-1],seq1:this.sequence1[e.pos[0]-1]+e.seq1,seq2:this.sequence2[e.pos[1]-1]+e.seq2}),i[1]&&t.push({pos:[e.pos[0]-1,e.pos[1]],seq1:this.sequence1[e.pos[0]-1]+e.seq1,seq2:"-"+e.seq2}),i[2]&&t.push({pos:[e.pos[0],e.pos[1]-1],seq1:"-"+e.seq1,seq2:this.sequence2[e.pos[1]-1]+e.seq2}),0===e.pos[0]&&0===e.pos[1]&&this.alignments.push({sequence1:e.seq1,sequence2:e.seq2}),t.shift()}return this.alignments}},{key:"getAllIndexes",value:function(t,e){for(var i=[],r=-1;-1!==(r=t.indexOf(e,r+1));)i.push(r);return i}},{key:"arrayAllMaxIndexes",value:function(t){return this.getAllIndexes(t,Math.max.apply(null,t))}}]),t}()},function(t,e,i){"use strict";var r=function(){};r.FDLayout=i(18),r.FDLayoutConstants=i(7),r.FDLayoutEdge=i(19),r.FDLayoutNode=i(20),r.DimensionD=i(21),r.HashMap=i(22),r.HashSet=i(23),r.IGeometry=i(8),r.IMath=i(9),r.Integer=i(10),r.Point=i(12),r.PointD=i(4),r.RandomSeed=i(16),r.RectangleD=i(13),r.Transform=i(17),r.UniqueIDGeneretor=i(14),r.Quicksort=i(24),r.LinkedList=i(11),r.LGraphObject=i(2),r.LGraph=i(5),r.LEdge=i(1),r.LGraphManager=i(6),r.LNode=i(3),r.Layout=i(15),r.LayoutConstants=i(0),r.NeedlemanWunsch=i(25),t.exports=r},function(t,e,i){"use strict";function r(){this.listeners=[]}var n=r.prototype;n.addListener=function(t,e){this.listeners.push({event:t,callback:e})},n.removeListener=function(t,e){for(var i=this.listeners.length;i>=0;i--){var r=this.listeners[i];r.event===t&&r.callback===e&&this.listeners.splice(i,1)}},n.emit=function(t,e){for(var i=0;i<this.listeners.length;i++){var r=this.listeners[i];t===r.event&&r.callback(e)}},t.exports=r}],e={};function i(r){if(e[r])return e[r].exports;var n=e[r]={i:r,l:!1,exports:{}};return t[r].call(n.exports,n,n.exports,i),n.l=!0,n.exports}return i.m=t,i.c=e,i.i=function(t){return t},i.d=function(t,e,r){i.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:r})},i.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return i.d(e,"a",e),e},i.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},i.p="",i(i.s=26)}()},9701:function(t,e,i){t.exports=function(t){var e=[function(e,i){e.exports=t},function(t,e,i){"use strict";var r=i(0).layoutBase.LayoutConstants,n=i(0).layoutBase.FDLayoutConstants,o=i(0).CoSEConstants,s=i(0).CoSELayout,a=i(0).CoSENode,h=i(0).layoutBase.PointD,l=i(0).layoutBase.DimensionD,g={ready:function(){},stop:function(){},quality:"default",nodeDimensionsIncludeLabels:!1,refresh:30,fit:!0,padding:10,randomize:!0,nodeRepulsion:4500,idealEdgeLength:50,edgeElasticity:.45,nestingFactor:.1,gravity:.25,numIter:2500,tile:!0,animate:"end",animationDuration:500,tilingPaddingVertical:10,tilingPaddingHorizontal:10,gravityRangeCompound:1.5,gravityCompound:1,gravityRange:3.8,initialEnergyOnIncremental:.5};function u(t){this.options=function(t,e){var i={};for(var r in t)i[r]=t[r];for(var r in e)i[r]=e[r];return i}(g,t),c(this.options)}var c=function(t){null!=t.nodeRepulsion&&(o.DEFAULT_REPULSION_STRENGTH=n.DEFAULT_REPULSION_STRENGTH=t.nodeRepulsion),null!=t.idealEdgeLength&&(o.DEFAULT_EDGE_LENGTH=n.DEFAULT_EDGE_LENGTH=t.idealEdgeLength),null!=t.edgeElasticity&&(o.DEFAULT_SPRING_STRENGTH=n.DEFAULT_SPRING_STRENGTH=t.edgeElasticity),null!=t.nestingFactor&&(o.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=n.PER_LEVEL_IDEAL_EDGE_LENGTH_FACTOR=t.nestingFactor),null!=t.gravity&&(o.DEFAULT_GRAVITY_STRENGTH=n.DEFAULT_GRAVITY_STRENGTH=t.gravity),null!=t.numIter&&(o.MAX_ITERATIONS=n.MAX_ITERATIONS=t.numIter),null!=t.gravityRange&&(o.DEFAULT_GRAVITY_RANGE_FACTOR=n.DEFAULT_GRAVITY_RANGE_FACTOR=t.gravityRange),null!=t.gravityCompound&&(o.DEFAULT_COMPOUND_GRAVITY_STRENGTH=n.DEFAULT_COMPOUND_GRAVITY_STRENGTH=t.gravityCompound),null!=t.gravityRangeCompound&&(o.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=n.DEFAULT_COMPOUND_GRAVITY_RANGE_FACTOR=t.gravityRangeCompound),null!=t.initialEnergyOnIncremental&&(o.DEFAULT_COOLING_FACTOR_INCREMENTAL=n.DEFAULT_COOLING_FACTOR_INCREMENTAL=t.initialEnergyOnIncremental),"draft"==t.quality?r.QUALITY=0:"proof"==t.quality?r.QUALITY=2:r.QUALITY=1,o.NODE_DIMENSIONS_INCLUDE_LABELS=n.NODE_DIMENSIONS_INCLUDE_LABELS=r.NODE_DIMENSIONS_INCLUDE_LABELS=t.nodeDimensionsIncludeLabels,o.DEFAULT_INCREMENTAL=n.DEFAULT_INCREMENTAL=r.DEFAULT_INCREMENTAL=!t.randomize,o.ANIMATE=n.ANIMATE=r.ANIMATE=t.animate,o.TILE=t.tile,o.TILING_PADDING_VERTICAL="function"==typeof t.tilingPaddingVertical?t.tilingPaddingVertical.call():t.tilingPaddingVertical,o.TILING_PADDING_HORIZONTAL="function"==typeof t.tilingPaddingHorizontal?t.tilingPaddingHorizontal.call():t.tilingPaddingHorizontal};u.prototype.run=function(){var t,e,i=this.options;this.idToLNode={};var r=this.layout=new s,n=this;n.stopped=!1,this.cy=this.options.cy,this.cy.trigger({type:"layoutstart",layout:this});var o=r.newGraphManager();this.gm=o;var a=this.options.eles.nodes(),h=this.options.eles.edges();this.root=o.addRoot(),this.processChildrenList(this.root,this.getTopMostNodes(a),r);for(var l=0;l<h.length;l++){var g=h[l],u=this.idToLNode[g.data("source")],c=this.idToLNode[g.data("target")];u!==c&&0==u.getEdgesBetween(c).length&&(o.add(r.newEdge(),u,c).id=g.id())}var d=function(t,e){"number"==typeof t&&(t=e);var i=t.data("id"),r=n.idToLNode[i];return{x:r.getRect().getCenterX(),y:r.getRect().getCenterY()}},p=function o(){for(var s,a=function(){i.fit&&i.cy.fit(i.eles,i.padding),t||(t=!0,n.cy.one("layoutready",i.ready),n.cy.trigger({type:"layoutready",layout:n}))},h=n.options.refresh,l=0;l<h&&!s;l++)s=n.stopped||n.layout.tick();if(s){r.checkLayoutSuccess()&&!r.isSubLayout&&r.doPostLayout(),r.tilingPostLayout&&r.tilingPostLayout(),r.isLayoutFinished=!0,n.options.eles.nodes().positions(d),a(),n.cy.one("layoutstop",n.options.stop),n.cy.trigger({type:"layoutstop",layout:n}),e&&cancelAnimationFrame(e),t=!1;return}var g=n.layout.getPositionsData();i.eles.nodes().positions(function(t,e){if("number"==typeof t&&(t=e),!t.isParent()){for(var i=t.id(),r=g[i],n=t;null==r&&(r=g[n.data("parent")]||g["DummyCompound_"+n.data("parent")],g[i]=r,void 0!=(n=n.parent()[0])););return null!=r?{x:r.x,y:r.y}:{x:t.position("x"),y:t.position("y")}}}),a(),e=requestAnimationFrame(o)};return r.addListener("layoutstarted",function(){"during"===n.options.animate&&(e=requestAnimationFrame(p))}),r.runLayout(),"during"!==this.options.animate&&(n.options.eles.nodes().not(":parent").layoutPositions(n,n.options,d),t=!1),this},u.prototype.getTopMostNodes=function(t){for(var e={},i=0;i<t.length;i++)e[t[i].id()]=!0;return t.filter(function(t,i){"number"==typeof t&&(t=i);for(var r=t.parent()[0];null!=r;){if(e[r.id()])return!1;r=r.parent()[0]}return!0})},u.prototype.processChildrenList=function(t,e,i){for(var r=e.length,n=0;n<r;n++){var o,s,g=e[n],u=g.children(),c=g.layoutDimensions({nodeDimensionsIncludeLabels:this.options.nodeDimensionsIncludeLabels});if((o=null!=g.outerWidth()&&null!=g.outerHeight()?t.add(new a(i.graphManager,new h(g.position("x")-c.w/2,g.position("y")-c.h/2),new l(parseFloat(c.w),parseFloat(c.h)))):t.add(new a(this.graphManager))).id=g.data("id"),o.paddingLeft=parseInt(g.css("padding")),o.paddingTop=parseInt(g.css("padding")),o.paddingRight=parseInt(g.css("padding")),o.paddingBottom=parseInt(g.css("padding")),this.options.nodeDimensionsIncludeLabels&&g.isParent()){var d=g.boundingBox({includeLabels:!0,includeNodes:!1}).w,p=g.boundingBox({includeLabels:!0,includeNodes:!1}).h,f=g.css("text-halign");o.labelWidth=d,o.labelHeight=p,o.labelPos=f}this.idToLNode[g.data("id")]=o,isNaN(o.rect.x)&&(o.rect.x=0),isNaN(o.rect.y)&&(o.rect.y=0),null!=u&&u.length>0&&(s=i.getGraphManager().add(i.newGraph(),o),this.processChildrenList(s,u,i))}},u.prototype.stop=function(){return this.stopped=!0,this};var d=function(t){t("layout","cose-bilkent",u)};"undefined"!=typeof cytoscape&&d(cytoscape),t.exports=d}],i={};function r(t){if(i[t])return i[t].exports;var n=i[t]={i:t,l:!1,exports:{}};return e[t].call(n.exports,n,n.exports,r),n.l=!0,n.exports}return r.m=e,r.c=i,r.i=function(t){return t},r.d=function(t,e,i){r.o(t,e)||Object.defineProperty(t,e,{configurable:!1,enumerable:!0,get:i})},r.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return r.d(e,"a",e),e},r.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},r.p="",r(r.s=1)}(i(3355))}}]);
_next/static/chunks/2065.bfc6693b67a7e2cf.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2065],{2065:(e,a,s)=>{s.d(a,{createRadarServices:()=>c.f});var c=s(5625);s(4839)}}]);
_next/static/chunks/2288.2f11050df7344f68.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2288],{2288:(e,t,n)=>{n.r(t),n.d(t,{render:()=>A});var r=n(4982);n(1431);var a=n(5407),i=n(7920);n(3148),n(1538),n(3736);var d=n(669),o=n(316),s=n(4603),l=n(2945),g=n(3048),c=n(131);function f(e){var t,n,r,a={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:(t=e,c.A(t.nodes(),function(e){var n=t.node(e),r=t.parent(e),a={v:e};return l.A(n)||(a.value=n),l.A(r)||(a.parent=r),a})),edges:(n=e,c.A(n.edges(),function(e){var t=n.edge(e),r={v:e.v,w:e.w};return l.A(e.name)||(r.name=e.name),l.A(t)||(r.value=t),r}))};return l.A(e.graph())||(r=e.graph(),a.value=(0,g.A)(r,4)),a}n(7585);var h=n(9856),p=new Map,u=new Map,m=new Map,w=(0,o.K2)(()=>{u.clear(),m.clear(),p.clear()},"clear"),R=(0,o.K2)((e,t)=>{let n=u.get(t)||[];return o.Rm.trace("In isDescendant",t," ",e," = ",n.includes(e)),n.includes(e)},"isDescendant"),v=(0,o.K2)((e,t)=>{let n=u.get(t)||[];return o.Rm.info("Descendants of ",t," is ",n),o.Rm.info("Edge is ",e),e.v!==t&&e.w!==t&&(n?n.includes(e.v)||R(e.v,t)||R(e.w,t)||n.includes(e.w):(o.Rm.debug("Tilt, ",t,",not in descendants"),!1))},"edgeInCluster"),y=(0,o.K2)((e,t,n,r)=>{o.Rm.warn("Copying children of ",e,"root",r,"data",t.node(e),r);let a=t.children(e)||[];e!==r&&a.push(e),o.Rm.warn("Copying (nodes) clusterId",e,"nodes",a),a.forEach(a=>{if(t.children(a).length>0)y(a,t,n,r);else{let i=t.node(a);o.Rm.info("cp ",a," to ",r," with parent ",e),n.setNode(a,i),r!==t.parent(a)&&(o.Rm.warn("Setting parent",a,t.parent(a)),n.setParent(a,t.parent(a))),e!==r&&a!==e?(o.Rm.debug("Setting parent",a,e),n.setParent(a,e)):(o.Rm.info("In copy ",e,"root",r,"data",t.node(e),r),o.Rm.debug("Not Setting parent for node=",a,"cluster!==rootId",e!==r,"node!==clusterId",a!==e));let d=t.edges(a);o.Rm.debug("Copying Edges",d),d.forEach(a=>{o.Rm.info("Edge",a);let i=t.edge(a.v,a.w,a.name);o.Rm.info("Edge data",i,r);try{v(a,r)?(o.Rm.info("Copying as ",a.v,a.w,i,a.name),n.setEdge(a.v,a.w,i,a.name),o.Rm.info("newGraph edges ",n.edges(),n.edge(n.edges()[0]))):o.Rm.info("Skipping copy of edge ",a.v,"--\x3e",a.w," rootId: ",r," clusterId:",e)}catch(e){o.Rm.error(e)}})}o.Rm.debug("Removing node",a),t.removeNode(a)})},"copy"),X=(0,o.K2)((e,t)=>{let n=t.children(e),r=[...n];for(let a of n)m.set(a,e),r=[...r,...X(a,t)];return r},"extractDescendants"),b=(0,o.K2)((e,t,n)=>{let r=e.edges().filter(e=>e.v===t||e.w===t),a=e.edges().filter(e=>e.v===n||e.w===n),i=r.map(e=>({v:e.v===t?n:e.v,w:e.w===t?t:e.w})),d=a.map(e=>({v:e.v,w:e.w}));return i.filter(e=>d.some(t=>e.v===t.v&&e.w===t.w))},"findCommonEdges"),E=(0,o.K2)((e,t,n)=>{let r,a=t.children(e);if(o.Rm.trace("Searching children of id ",e,a),a.length<1)return e;for(let e of a){let a=E(e,t,n),i=b(t,n,a);if(a)if(!(i.length>0))return a;else r=a}return r},"findNonClusterChild"),N=(0,o.K2)(e=>p.has(e)&&p.get(e).externalConnections&&p.has(e)?p.get(e).id:e,"getAnchorId"),C=(0,o.K2)((e,t)=>{if(!e||t>10)return void o.Rm.debug("Opting out, no graph ");for(let t of(o.Rm.debug("Opting in, graph "),e.nodes().forEach(function(t){e.children(t).length>0&&(o.Rm.warn("Cluster identified",t," Replacement id in edges: ",E(t,e,t)),u.set(t,X(t,e)),p.set(t,{id:E(t,e,t),clusterData:e.node(t)}))}),e.nodes().forEach(function(t){let n=e.children(t),r=e.edges();n.length>0?(o.Rm.debug("Cluster identified",t,u),r.forEach(e=>{R(e.v,t)^R(e.w,t)&&(o.Rm.warn("Edge: ",e," leaves cluster ",t),o.Rm.warn("Descendants of XXX ",t,": ",u.get(t)),p.get(t).externalConnections=!0)})):o.Rm.debug("Not a cluster ",t,u)}),p.keys())){let n=p.get(t).id,r=e.parent(n);r!==t&&p.has(r)&&!p.get(r).externalConnections&&(p.get(t).id=r)}e.edges().forEach(function(t){let n=e.edge(t);o.Rm.warn("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(t)),o.Rm.warn("Edge "+t.v+" -> "+t.w+": "+JSON.stringify(e.edge(t)));let r=t.v,a=t.w;if(o.Rm.warn("Fix XXX",p,"ids:",t.v,t.w,"Translating: ",p.get(t.v)," --- ",p.get(t.w)),p.get(t.v)||p.get(t.w)){if(o.Rm.warn("Fixing and trying - removing XXX",t.v,t.w,t.name),r=N(t.v),a=N(t.w),e.removeEdge(t.v,t.w,t.name),r!==t.v){let a=e.parent(r);p.get(a).externalConnections=!0,n.fromCluster=t.v}if(a!==t.w){let r=e.parent(a);p.get(r).externalConnections=!0,n.toCluster=t.w}o.Rm.warn("Fix Replacing with XXX",r,a,t.name),e.setEdge(r,a,n,t.name)}}),o.Rm.warn("Adjusted Graph",f(e)),S(e,0),o.Rm.trace(p)},"adjustClustersAndEdges"),S=(0,o.K2)((e,t)=>{if(o.Rm.warn("extractor - ",t,f(e),e.children("D")),t>10)return void o.Rm.error("Bailing out");let n=e.nodes(),r=!1;for(let t of n){let n=e.children(t);r=r||n.length>0}if(!r)return void o.Rm.debug("Done, no node has children",e.nodes());for(let r of(o.Rm.debug("Nodes = ",n,t),n))if(o.Rm.debug("Extracting node",r,p,p.has(r)&&!p.get(r).externalConnections,!e.parent(r),e.node(r),e.children("D")," Depth ",t),p.has(r))if(!p.get(r).externalConnections&&e.children(r)&&e.children(r).length>0){o.Rm.warn("Cluster without external connections, without a parent and with children",r,t);let n="TB"===e.graph().rankdir?"LR":"TB";p.get(r)?.clusterData?.dir&&(n=p.get(r).clusterData.dir,o.Rm.warn("Fixing dir",p.get(r).clusterData.dir,n));let a=new h.T({multigraph:!0,compound:!0}).setGraph({rankdir:n,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});o.Rm.warn("Old graph before copy",f(e)),y(r,e,a,r),e.setNode(r,{clusterNode:!0,id:r,clusterData:p.get(r).clusterData,label:p.get(r).label,graph:a}),o.Rm.warn("New graph after copy node: (",r,")",f(a)),o.Rm.debug("Old graph after copy",f(e))}else o.Rm.warn("Cluster ** ",r," **not meeting the criteria !externalConnections:",!p.get(r).externalConnections," no parent: ",!e.parent(r)," children ",e.children(r)&&e.children(r).length>0,e.children("D"),t),o.Rm.debug(p);else o.Rm.debug("Not a cluster",r,t);for(let r of(n=e.nodes(),o.Rm.warn("New list of nodes",n),n)){let n=e.node(r);o.Rm.warn(" Now next level",r,n),n?.clusterNode&&S(n.graph,t+1)}},"extractor"),x=(0,o.K2)((e,t)=>{if(0===t.length)return[];let n=Object.assign([],t);return t.forEach(t=>{let r=e.children(t),a=x(e,r);n=[...n,...a]}),n},"sorter"),I=(0,o.K2)(e=>x(e,e.children()),"sortNodesByHierarchy"),D=(0,o.K2)(async(e,t,n,d,l,g)=>{o.Rm.warn("Graph in recursive render:XAX",f(t),l);let c=t.graph().rankdir;o.Rm.trace("Dir in recursive render - dir:",c);let h=e.insert("g").attr("class","root");t.nodes()?o.Rm.info("Recursive render XXX",t.nodes()):o.Rm.info("No nodes found for",t),t.edges().length>0&&o.Rm.info("Recursive edges",t.edge(t.edges()[0]));let u=h.insert("g").attr("class","clusters"),m=h.insert("g").attr("class","edgePaths"),w=h.insert("g").attr("class","edgeLabels"),R=h.insert("g").attr("class","nodes");await Promise.all(t.nodes().map(async function(e){let r=t.node(e);if(void 0!==l){let n=JSON.parse(JSON.stringify(l.clusterData));o.Rm.trace("Setting data for parent cluster XXX\n Node.id = ",e,"\n data=",n.height,"\nParent cluster",l.height),t.setNode(l.id,n),t.parent(e)||(o.Rm.trace("Setting parent",e,l.id),t.setParent(e,l.id,n))}if(o.Rm.info("(Insert) Node XXX"+e+": "+JSON.stringify(t.node(e))),r?.clusterNode){o.Rm.info("Cluster identified XBX",e,r.width,t.node(e));let{ranksep:i,nodesep:s}=t.graph();r.graph.setGraph({...r.graph.graph(),ranksep:i+25,nodesep:s});let l=await D(R,r.graph,n,d,t.node(e),g),c=l.elem;(0,a.lC)(r,c),r.diff=l.diff||0,o.Rm.info("New compound node after recursive render XAX",e,"width",r.width,"height",r.height),(0,a.U7)(c,r)}else t.children(e).length>0?(o.Rm.trace("Cluster - the non recursive path XBX",e,r.id,r,r.width,"Graph:",t),o.Rm.trace(E(r.id,t)),p.set(r.id,{id:E(r.id,t),node:r})):(o.Rm.trace("Node - the non recursive path XAX",e,R,t.node(e),c),await (0,a.on)(R,t.node(e),{config:g,dir:c}))}));let v=(0,o.K2)(async()=>{let e=t.edges().map(async function(e){let n=t.edge(e.v,e.w,e.name);o.Rm.info("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(e)),o.Rm.info("Edge "+e.v+" -> "+e.w+": ",e," ",JSON.stringify(t.edge(e))),o.Rm.info("Fix",p,"ids:",e.v,e.w,"Translating: ",p.get(e.v),p.get(e.w)),await (0,r.jP)(w,n)});await Promise.all(e)},"processEdges");await v(),o.Rm.info("Graph before layout:",JSON.stringify(f(t))),o.Rm.info("############################################# XXX"),o.Rm.info("### Layout ### XXX"),o.Rm.info("############################################# XXX"),(0,s.Zp)(t),o.Rm.info("Graph after layout:",JSON.stringify(f(t)));let y=0,{subGraphTitleTotalMargin:X}=(0,i.O)(g);return await Promise.all(I(t).map(async function(e){let n=t.node(e);if(o.Rm.info("Position XBX => "+e+": ("+n.x,","+n.y,") width: ",n.width," height: ",n.height),n?.clusterNode)n.y+=X,o.Rm.info("A tainted cluster node XBX1",e,n.id,n.width,n.height,n.x,n.y,t.parent(e)),p.get(n.id).node=n,(0,a.U_)(n);else if(t.children(e).length>0){o.Rm.info("A pure cluster node XBX1",e,n.id,n.x,n.y,n.width,n.height,t.parent(e)),n.height+=X,t.node(n.parentId);let r=n?.padding/2||0,i=n?.labelBBox?.height||0;o.Rm.debug("OffsetY",i-r||0,"labelHeight",i,"halfPadding",r),await (0,a.U)(u,n),p.get(n.id).node=n}else{let e=t.node(n.parentId);n.y+=X/2,o.Rm.info("A regular node XBX1 - using the padding",n.id,"parent",n.parentId,n.width,n.height,n.x,n.y,"offsetY",n.offsetY,"parent",e,e?.offsetY,n),(0,a.U_)(n)}})),t.edges().forEach(function(e){let a=t.edge(e);o.Rm.info("Edge "+e.v+" -> "+e.w+": "+JSON.stringify(a),a),a.points.forEach(e=>e.y+=X/2);let i=t.node(e.v);var s=t.node(e.w);let l=(0,r.Jo)(m,a,p,n,i,s,d);(0,r.T_)(a,l)}),t.nodes().forEach(function(e){let n=t.node(e);o.Rm.info(e,n.type,n.diff),n.isGroup&&(y=n.diff)}),o.Rm.warn("Returning from recursive render XAX",h,y),{elem:h,diff:y}},"recursiveRender"),A=(0,o.K2)(async(e,t)=>{let n=new h.T({multigraph:!0,compound:!0}).setGraph({rankdir:e.direction,nodesep:e.config?.nodeSpacing||e.config?.flowchart?.nodeSpacing||e.nodeSpacing,ranksep:e.config?.rankSpacing||e.config?.flowchart?.rankSpacing||e.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}}),i=t.select("g");(0,r.g0)(i,e.markers,e.type,e.diagramId),(0,a.gh)(),(0,r.IU)(),(0,a.IU)(),w(),e.nodes.forEach(e=>{n.setNode(e.id,{...e}),e.parentId&&n.setParent(e.id,e.parentId)}),o.Rm.debug("Edges:",e.edges),e.edges.forEach(e=>{if(e.start===e.end){let t=e.start,r=t+"---"+t+"---1",a=t+"---"+t+"---2",i=n.node(t);n.setNode(r,{domId:r,id:r,parentId:i.parentId,labelStyle:"",label:"",padding:0,shape:"labelRect",style:"",width:10,height:10}),n.setParent(r,i.parentId),n.setNode(a,{domId:a,id:a,parentId:i.parentId,labelStyle:"",padding:0,shape:"labelRect",label:"",style:"",width:10,height:10}),n.setParent(a,i.parentId);let d=structuredClone(e),o=structuredClone(e),s=structuredClone(e);d.label="",d.arrowTypeEnd="none",d.endLabelLeft="",d.endLabelRight="",d.startLabelLeft="",d.id=t+"-cyclic-special-1",o.startLabelRight="",o.startLabelLeft="",o.endLabelLeft="",o.endLabelRight="",o.arrowTypeStart="none",o.arrowTypeEnd="none",o.id=t+"-cyclic-special-mid",s.label="",s.startLabelRight="",s.startLabelLeft="",s.arrowTypeStart="none",i.isGroup&&(d.fromCluster=t,s.toCluster=t),s.id=t+"-cyclic-special-2",s.arrowTypeStart="none",n.setEdge(t,r,d,t+"-cyclic-special-0"),n.setEdge(r,a,o,t+"-cyclic-special-1"),n.setEdge(a,t,s,t+"-cyc<lic-special-2")}else n.setEdge(e.start,e.end,{...e},e.id)}),o.Rm.warn("Graph at first:",JSON.stringify(f(n))),C(n),o.Rm.warn("Graph after XAX:",JSON.stringify(f(n)));let s=(0,d.D7)();await D(i,n,e.type,e.diagramId,void 0,s)},"render")}}]);
_next/static/chunks/2392.8ec2341e6d06e84b.js ADDED
@@ -0,0 +1,77 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2392],{2392:(t,e,a)=>{a.d(e,{diagram:()=>D});var r=a(2667),o=a(7566),n=a(3736),i=a(669),l=a(316),s=a(4290),d=(0,l.K2)((t,e)=>{let a=t<=1?100*t:t;if(a<0||a>100)throw Error(`${e} must be between 0-1 (decimal) or 0-100 (percentage). Received: ${t}`);return a},"toPercent"),c=(0,l.K2)((t,e,a)=>({x:d(e,`${a} evolution`),y:d(t,`${a} visibility`)}),"toCoordinates"),p=(0,l.K2)(t=>{if(t){if("+<>"===t)return"bidirectional";if("+<"===t)return"backward";if("+>"===t)return"forward"}},"getFlowFromPort"),h=(0,l.K2)(t=>{if(!t?.startsWith("+"))return{};let e=/^\+'([^']*)'/.exec(t),a=e?.[1];return t.includes("<>")?{flow:"bidirectional",label:a}:t.includes("<")?{flow:"backward",label:a}:t.includes(">")?{flow:"forward",label:a}:{label:a}},"extractFlowFromArrow"),x=(0,l.K2)((t,e)=>{if((0,o.S)(t,e),t.size&&e.setSize(t.size.width,t.size.height),t.evolution){let a=t.evolution.stages.map(t=>t.secondName?`${t.name.trim()} / ${t.secondName.trim()}`:t.name.trim()),r=t.evolution.stages.filter(t=>void 0!==t.boundary).map(t=>t.boundary);e.updateAxes({stages:a,stageBoundaries:r})}if(t.anchors.forEach(t=>{let a=c(t.visibility,t.evolution,`Anchor "${t.name}"`);e.addNode(t.name,t.name,a.x,a.y,"anchor")}),t.components.forEach(t=>{let a=c(t.visibility,t.evolution,`Component "${t.name}"`),r=t.label?(t.label.negX?-1:1)*t.label.offsetX:void 0,o=t.label?(t.label.negY?-1:1)*t.label.offsetY:void 0,n=t.decorator?.strategy;e.addNode(t.name,t.name,a.x,a.y,"component",r,o,t.inertia,n)}),t.notes.forEach(t=>{let a=c(t.visibility,t.evolution,`Note "${t.text}"`);e.addNote(t.text,a.x,a.y)}),t.pipelines.forEach(t=>{let a=e.getNode(t.parent);if(!a||"number"!=typeof a.y)throw Error(`Pipeline "${t.parent}" must reference an existing component with coordinates.`);let r=a.y;e.startPipeline(t.parent),t.components.forEach(a=>{let o=`${t.parent}_${a.name}`,n=a.label?(a.label.negX?-1:1)*a.label.offsetX:void 0,i=a.label?(a.label.negY?-1:1)*a.label.offsetY:void 0,l=d(a.evolution,`Pipeline component "${a.name}" evolution`);e.addNode(o,a.name,l,r,"pipeline-component",n,i),e.addPipelineComponent(t.parent,o)})}),t.links.forEach(t=>{let a=!!t.arrow&&(t.arrow.includes("-.->")||t.arrow.includes(".-.")),r=p(t.fromPort)??p(t.toPort),{flow:o,label:n}=h(t.arrow);!r&&o&&(r=o);let i=t.linkLabel;e.addLink(e.resolveNodeId(t.from),e.resolveNodeId(t.to),a,n??i,r)}),t.evolves.forEach(t=>{let a=e.getNode(t.component);if(a?.y!==void 0){let r=d(t.target,`Evolve target for "${t.component}"`);e.addTrend(t.component,r,a.y)}}),t.annotations.length>0){let a=t.annotations[0],r=c(a.x,a.y,"Annotations box");e.setAnnotationsBox(r.x,r.y)}t.annotation.forEach(t=>{let a=c(t.x,t.y,`Annotation ${t.number}`);e.addAnnotation(t.number,[{x:a.x,y:a.y}],t.text)}),t.accelerators.forEach(t=>{let a=c(t.x,t.y,`Accelerator "${t.name}"`);e.addAccelerator(t.name,a.x,a.y)}),t.deaccelerators.forEach(t=>{let a=c(t.x,t.y,`Deaccelerator "${t.name}"`);e.addDeaccelerator(t.name,a.x,a.y)})},"populateDb"),y={parser:{yy:void 0},parse:(0,l.K2)(async t=>{let e=await (0,s.qg)("wardley",t);l.Rm.debug(e);let a=y.parser?.yy;if(!a||"function"!=typeof a.addNode)throw Error("parser.parser?.yy was not a WardleyDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");x(e,a)},"parse")},f=new class{constructor(){this.nodes=new Map,this.links=[],this.trends=new Map,this.pipelines=new Map,this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.axes={}}static{(0,l.K2)(this,"WardleyBuilder")}addNode(t){let e=this.nodes.get(t.id)??{id:t.id,label:t.label},a={...e,...t,className:t.className??e.className,labelOffsetX:t.labelOffsetX??e.labelOffsetX,labelOffsetY:t.labelOffsetY??e.labelOffsetY};this.nodes.set(t.id,a)}addLink(t){this.links.push(t)}addTrend(t){this.trends.set(t.nodeId,t)}startPipeline(t){this.pipelines.set(t,{nodeId:t,componentIds:[]});let e=this.nodes.get(t);e&&(e.isPipelineParent=!0)}addPipelineComponent(t,e){let a=this.pipelines.get(t);a&&a.componentIds.push(e);let r=this.nodes.get(e);r&&(r.inPipeline=!0)}addAnnotation(t){this.annotations.push(t)}addNote(t){this.notes.push(t)}addAccelerator(t){this.accelerators.push(t)}addDeaccelerator(t){this.deaccelerators.push(t)}setAnnotationsBox(t,e){this.annotationsBox={x:t,y:e}}setAxes(t){this.axes={...this.axes,...t}}setSize(t,e){this.size={width:t,height:e}}getNode(t){return this.nodes.get(t)}resolveNodeId(t){if(this.nodes.has(t))return t;for(let[e,a]of this.nodes)if(a.label===t)return e;return t}build(){let t=[];for(let e of this.nodes.values()){if("number"!=typeof e.x||"number"!=typeof e.y)throw Error(`Node "${e.label}" is missing coordinates`);t.push(e)}return{nodes:t,links:[...this.links],trends:[...this.trends.values()],pipelines:[...this.pipelines.values()],annotations:[...this.annotations],notes:[...this.notes],accelerators:[...this.accelerators],deaccelerators:[...this.deaccelerators],annotationsBox:this.annotationsBox,axes:{...this.axes},size:this.size}}clear(){this.nodes.clear(),this.links=[],this.trends.clear(),this.pipelines.clear(),this.annotations=[],this.notes=[],this.accelerators=[],this.deaccelerators=[],this.annotationsBox=void 0,this.axes={},this.size=void 0}};function g(){return(0,i.D7)()["wardley-beta"]}function u(t,e,a,r,o,n,i,l,s){f.addNode({id:t,label:e,x:a,y:r,className:o,labelOffsetX:n,labelOffsetY:i,inertia:l,sourceStrategy:s})}function m(t,e,a=!1,r,o){f.addLink({source:t,target:e,dashed:a,label:r,flow:o})}function w(t,e,a){f.addTrend({nodeId:t,targetX:e,targetY:a})}function k(t,e,a){f.addAnnotation({number:t,coordinates:e,text:a})}function b(t,e,a){f.addNote({text:t,x:e,y:a})}function $(t,e,a){f.addAccelerator({name:t,x:e,y:a})}function S(t,e,a){f.addDeaccelerator({name:t,x:e,y:a})}function v(t,e){f.setAnnotationsBox(t,e)}function C(t,e){f.setSize(t,e)}function M(t){f.startPipeline(t)}function P(t,e){f.addPipelineComponent(t,e)}function N(t){f.setAxes(t)}function T(t){return f.getNode(t)}function z(t){return f.resolveNodeId(t)}function E(){return f.build()}function L(){f.clear(),(0,i.IU)()}(0,l.K2)(g,"getConfig"),(0,l.K2)(u,"addNode"),(0,l.K2)(m,"addLink"),(0,l.K2)(w,"addTrend"),(0,l.K2)(k,"addAnnotation"),(0,l.K2)(b,"addNote"),(0,l.K2)($,"addAccelerator"),(0,l.K2)(S,"addDeaccelerator"),(0,l.K2)(v,"setAnnotationsBox"),(0,l.K2)(C,"setSize"),(0,l.K2)(M,"startPipeline"),(0,l.K2)(P,"addPipelineComponent"),(0,l.K2)(N,"updateAxes"),(0,l.K2)(T,"getNode"),(0,l.K2)(z,"resolveNodeId"),(0,l.K2)(E,"getWardleyData"),(0,l.K2)(L,"clear");var A={getConfig:g,addNode:u,addLink:m,addTrend:w,addAnnotation:k,addNote:b,addAccelerator:$,addDeaccelerator:S,setAnnotationsBox:v,setSize:C,startPipeline:M,addPipelineComponent:P,updateAxes:N,getNode:T,resolveNodeId:z,getWardleyData:E,clear:L,setAccTitle:i.SV,getAccTitle:i.iN,setDiagramTitle:i.ke,getDiagramTitle:i.ab,getAccDescription:i.m7,setAccDescription:i.EI},K=["Genesis","Custom Built","Product","Commodity"],I=(0,l.K2)(()=>{let{themeVariables:t}=(0,i.D7)();return{backgroundColor:t.wardley?.backgroundColor??t.background??"#fff",axisColor:t.wardley?.axisColor??"#000",axisTextColor:t.wardley?.axisTextColor??t.primaryTextColor??"#222",gridColor:t.wardley?.gridColor??"rgba(100, 100, 100, 0.2)",componentFill:t.wardley?.componentFill??"#fff",componentStroke:t.wardley?.componentStroke??"#000",componentLabelColor:t.wardley?.componentLabelColor??t.primaryTextColor??"#222",linkStroke:t.wardley?.linkStroke??"#000",evolutionStroke:t.wardley?.evolutionStroke??"#dc3545",annotationStroke:t.wardley?.annotationStroke??"#000",annotationTextColor:t.wardley?.annotationTextColor??t.primaryTextColor??"#222",annotationFill:t.wardley?.annotationFill??t.background??"#fff"}},"getTheme"),R=(0,l.K2)(()=>{let t=(0,i.D7)()["wardley-beta"];return{width:t?.width??900,height:t?.height??600,padding:t?.padding??48,nodeRadius:t?.nodeRadius??6,nodeLabelOffset:t?.nodeLabelOffset??8,axisFontSize:t?.axisFontSize??12,labelFontSize:t?.labelFontSize??10,showGrid:t?.showGrid??!1,useMaxWidth:t?.useMaxWidth??!0}},"getConfigValues"),D={parser:y,db:A,renderer:{draw:(0,l.K2)((t,e,a,o)=>{l.Rm.debug("Rendering Wardley map\n"+t);let n=R(),s=I(),d=1.6*n.nodeRadius,c=o.db,p=c.getWardleyData(),h=c.getDiagramTitle(),x=p.size?.width??n.width,y=p.size?.height??n.height,f=(0,r.D)(e);f.selectAll("*").remove(),(0,i.a$)(f,y,x,n.useMaxWidth),f.attr("viewBox",`0 0 ${x} ${y}`);let g=f.append("g").attr("class","wardley-map"),u=f.append("defs");u.append("marker").attr("id",`arrow-${e}`).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("fill",s.evolutionStroke).attr("stroke","none"),u.append("marker").attr("id",`link-arrow-end-${e}`).attr("viewBox","0 0 10 10").attr("refX",9).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("fill",s.linkStroke).attr("stroke","none"),u.append("marker").attr("id",`link-arrow-start-${e}`).attr("viewBox","0 0 10 10").attr("refX",1).attr("refY",5).attr("markerWidth",5).attr("markerHeight",5).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 z").attr("fill",s.linkStroke).attr("stroke","none"),g.append("rect").attr("class","wardley-background").attr("width",x).attr("height",y).attr("fill",s.backgroundColor);let m=x-2*n.padding,w=y-2*n.padding;h&&g.append("text").attr("class","wardley-title").attr("x",x/2).attr("y",n.padding/2).attr("fill",s.axisTextColor).attr("font-size",1.05*n.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("dominant-baseline","middle").text(h);let k=(0,l.K2)(t=>n.padding+t/100*m,"projectX"),b=(0,l.K2)(t=>y-n.padding-t/100*w,"projectY"),$=g.append("g").attr("class","wardley-axes");$.append("line").attr("x1",n.padding).attr("x2",x-n.padding).attr("y1",y-n.padding).attr("y2",y-n.padding).attr("stroke",s.axisColor).attr("stroke-width",1),$.append("line").attr("x1",n.padding).attr("x2",n.padding).attr("y1",n.padding).attr("y2",y-n.padding).attr("stroke",s.axisColor).attr("stroke-width",1);let S=p.axes.xLabel??"Evolution",v=p.axes.yLabel??"Visibility";$.append("text").attr("class","wardley-axis-label wardley-axis-label-x").attr("x",n.padding+m/2).attr("y",y-n.padding/4).attr("fill",s.axisTextColor).attr("font-size",n.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").text(S),$.append("text").attr("class","wardley-axis-label wardley-axis-label-y").attr("x",n.padding/3).attr("y",n.padding+w/2).attr("fill",s.axisTextColor).attr("font-size",n.axisFontSize).attr("font-weight","bold").attr("text-anchor","middle").attr("transform",`rotate(-90 ${n.padding/3} ${n.padding+w/2})`).text(v);let C=p.axes.stages&&p.axes.stages.length>0?p.axes.stages:K;if(C.length>0){let t=g.append("g").attr("class","wardley-stages"),e=p.axes.stageBoundaries,a=[];if(e&&e.length===C.length){let t=0;e.forEach(e=>{a.push({start:t,end:e}),t=e})}else{let t=1/C.length;C.forEach((e,r)=>{a.push({start:r*t,end:(r+1)*t})})}C.forEach((e,r)=>{let o=a[r],i=n.padding+o.start*m,l=(i+(n.padding+o.end*m))/2;r>0&&t.append("line").attr("x1",i).attr("x2",i).attr("y1",n.padding).attr("y2",y-n.padding).attr("stroke","#000").attr("stroke-width",1).attr("stroke-dasharray","5 5").attr("opacity",.8),t.append("text").attr("class","wardley-stage-label").attr("x",l).attr("y",y-n.padding/1.5).attr("fill",s.axisTextColor).attr("font-size",n.axisFontSize-2).attr("text-anchor","middle").text(e)})}if(n.showGrid){let t=g.append("g").attr("class","wardley-grid");for(let e=1;e<4;e++){let a=e/4,r=n.padding+m*a;t.append("line").attr("x1",r).attr("x2",r).attr("y1",n.padding).attr("y2",y-n.padding).attr("stroke",s.gridColor).attr("stroke-dasharray","2 6"),t.append("line").attr("x1",n.padding).attr("x2",x-n.padding).attr("y1",y-n.padding-w*a).attr("y2",y-n.padding-w*a).attr("stroke",s.gridColor).attr("stroke-dasharray","2 6")}}let M=new Map;if(p.nodes.forEach(t=>{M.set(t.id,{x:k(t.x),y:b(t.y),node:t})}),p.pipelines.length>0){let t=g.append("g").attr("class","wardley-pipelines"),e=g.append("g").attr("class","wardley-pipeline-links");p.pipelines.forEach(a=>{if(0===a.componentIds.length)return;let r=a.componentIds.map(t=>({id:t,pos:M.get(t),node:p.nodes.find(e=>e.id===t)})).filter(t=>t.pos&&t.node).sort((t,e)=>t.node.x-e.node.x);for(let t=0;t<r.length-1;t++){let a=r[t],o=r[t+1];e.append("line").attr("class","wardley-pipeline-evolution-link").attr("x1",a.pos.x).attr("y1",a.pos.y).attr("x2",o.pos.x).attr("y2",o.pos.y).attr("stroke",s.linkStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4")}let o=1/0,i=-1/0,l=0;if(a.componentIds.forEach(t=>{let e=M.get(t);e&&(o=Math.min(o,e.x),i=Math.max(i,e.x),l=e.y)}),o!==1/0&&i!==-1/0){let e=4*n.nodeRadius,r=l-e/2,c=M.get(a.nodeId);c&&(c.x=(o+i)/2,c.y=r-d/6),t.append("rect").attr("class","wardley-pipeline-box").attr("x",o-15).attr("y",r).attr("width",i-o+30).attr("height",e).attr("fill","none").attr("stroke",s.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}})}let P=g.append("g").attr("class","wardley-links"),N=new Map;p.pipelines.forEach(t=>{N.set(t.nodeId,new Set(t.componentIds))});let T=p.links.filter(t=>{if(!M.has(t.source)||!M.has(t.target))return!1;let e=N.get(t.target);return!e?.has(t.source)});P.selectAll("line").data(T).enter().append("line").attr("class",t=>`wardley-link${t.dashed?" wardley-link--dashed":""}`).attr("x1",t=>{let e=M.get(t.source),a=M.get(t.target),r=p.nodes.find(e=>e.id===t.source).isPipelineParent?d/Math.sqrt(2):n.nodeRadius,o=a.x-e.x,i=a.y-e.y,l=Math.sqrt(o*o+i*i);return e.x+o/l*r}).attr("y1",t=>{let e=M.get(t.source),a=M.get(t.target),r=p.nodes.find(e=>e.id===t.source).isPipelineParent?d/Math.sqrt(2):n.nodeRadius,o=a.x-e.x,i=a.y-e.y,l=Math.sqrt(o*o+i*i);return e.y+i/l*r}).attr("x2",t=>{let e=M.get(t.source),a=M.get(t.target),r=p.nodes.find(e=>e.id===t.target).isPipelineParent?d/Math.sqrt(2):n.nodeRadius,o=e.x-a.x,i=e.y-a.y,l=Math.sqrt(o*o+i*i);return a.x+o/l*r}).attr("y2",t=>{let e=M.get(t.source),a=M.get(t.target),r=p.nodes.find(e=>e.id===t.target).isPipelineParent?d/Math.sqrt(2):n.nodeRadius,o=e.x-a.x,i=e.y-a.y,l=Math.sqrt(o*o+i*i);return a.y+i/l*r}).attr("stroke",s.linkStroke).attr("stroke-width",1).attr("stroke-dasharray",t=>t.dashed?"6 6":null).attr("marker-end",t=>"forward"===t.flow||"bidirectional"===t.flow?`url(#link-arrow-end-${e})`:null).attr("marker-start",t=>"backward"===t.flow||"bidirectional"===t.flow?`url(#link-arrow-start-${e})`:null),P.selectAll("text").data(T.filter(t=>t.label)).enter().append("text").attr("class","wardley-link-label").attr("x",t=>{let e=M.get(t.source),a=M.get(t.target),r=(e.x+a.x)/2,o=a.y-e.y,n=a.x-e.x,i=Math.sqrt(n*n+o*o);return r+o/i*8}).attr("y",t=>{let e=M.get(t.source),a=M.get(t.target),r=(e.y+a.y)/2,o=a.x-e.x,n=a.y-e.y,i=Math.sqrt(o*o+n*n);return r+-o/i*8}).attr("fill",s.axisTextColor).attr("font-size",n.labelFontSize).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("transform",t=>{let e=M.get(t.source),a=M.get(t.target),r=(e.x+a.x)/2,o=(e.y+a.y)/2,n=a.x-e.x,i=a.y-e.y,l=Math.sqrt(n*n+i*i),s=180*Math.atan2(i,n)/Math.PI;return(s>90||s<-90)&&(s+=180),`rotate(${s} ${r+i/l*8} ${o+-n/l*8})`}).text(t=>t.label);let z=g.append("g").attr("class","wardley-trends"),E=p.trends.map(t=>{let e=M.get(t.nodeId);if(!e)return null;let a=k(t.targetX),r=b(t.targetY),o=a-e.x,i=r-e.y,l=Math.sqrt(o*o+i*i),s=n.nodeRadius+2;return{origin:e,targetX:a,targetY:r,adjustedX2:l>s?a-o/l*s:a,adjustedY2:l>s?r-i/l*s:r}}).filter(t=>null!==t);z.selectAll("line").data(E).enter().append("line").attr("class","wardley-trend").attr("x1",t=>t.origin.x).attr("y1",t=>t.origin.y).attr("x2",t=>t.adjustedX2).attr("y2",t=>t.adjustedY2).attr("stroke",s.evolutionStroke).attr("stroke-width",1).attr("stroke-dasharray","4 4").attr("marker-end",`url(#arrow-${e})`);let L=g.append("g").attr("class","wardley-nodes").selectAll("g").data(p.nodes).enter().append("g").attr("class",t=>["wardley-node",t.className?`wardley-node--${t.className}`:""].filter(Boolean).join(" "));L.filter(t=>"outsource"===t.sourceStrategy).append("circle").attr("class","wardley-outsource-overlay").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y).attr("r",2*n.nodeRadius).attr("fill","#666").attr("stroke",s.componentStroke).attr("stroke-width",1),L.filter(t=>"buy"===t.sourceStrategy).append("circle").attr("class","wardley-buy-overlay").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y).attr("r",2*n.nodeRadius).attr("fill","#ccc").attr("stroke",s.componentStroke).attr("stroke-width",1),L.filter(t=>"build"===t.sourceStrategy).append("circle").attr("class","wardley-build-overlay").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y).attr("r",2*n.nodeRadius).attr("fill","#eee").attr("stroke","#000").attr("stroke-width",1);let A=L.filter(t=>"market"===t.sourceStrategy);A.append("circle").attr("class","wardley-market-overlay").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y).attr("r",2*n.nodeRadius).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",1),L.filter(t=>!t.isPipelineParent&&"market"!==t.sourceStrategy&&"anchor"!==t.className).append("circle").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y).attr("r",n.nodeRadius).attr("fill",s.componentFill).attr("stroke",s.componentStroke).attr("stroke-width",1);let D=.7*n.nodeRadius,F=1.2*n.nodeRadius;if(A.append("line").attr("class","wardley-market-line").attr("x1",t=>M.get(t.id).x).attr("y1",t=>M.get(t.id).y-F).attr("x2",t=>M.get(t.id).x-F*Math.cos(Math.PI/6)).attr("y2",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("stroke",s.componentStroke).attr("stroke-width",1),A.append("line").attr("class","wardley-market-line").attr("x1",t=>M.get(t.id).x-F*Math.cos(Math.PI/6)).attr("y1",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("x2",t=>M.get(t.id).x+F*Math.cos(Math.PI/6)).attr("y2",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("stroke",s.componentStroke).attr("stroke-width",1),A.append("line").attr("class","wardley-market-line").attr("x1",t=>M.get(t.id).x+F*Math.cos(Math.PI/6)).attr("y1",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("x2",t=>M.get(t.id).x).attr("y2",t=>M.get(t.id).y-F).attr("stroke",s.componentStroke).attr("stroke-width",1),A.append("circle").attr("class","wardley-market-dot").attr("cx",t=>M.get(t.id).x).attr("cy",t=>M.get(t.id).y-F).attr("r",D).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",2),A.append("circle").attr("class","wardley-market-dot").attr("cx",t=>M.get(t.id).x-F*Math.cos(Math.PI/6)).attr("cy",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("r",D).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",2),A.append("circle").attr("class","wardley-market-dot").attr("cx",t=>M.get(t.id).x+F*Math.cos(Math.PI/6)).attr("cy",t=>M.get(t.id).y+F*Math.sin(Math.PI/6)).attr("r",D).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",2),L.filter(t=>!0===t.isPipelineParent).append("rect").attr("x",t=>M.get(t.id).x-d/2).attr("y",t=>M.get(t.id).y-d/2).attr("width",d).attr("height",d).attr("fill",s.componentFill).attr("stroke",s.componentStroke).attr("stroke-width",1),L.filter(t=>!0===t.inertia).append("line").attr("class","wardley-inertia").attr("x1",t=>{let e=M.get(t.id),a=t.isPipelineParent?d/2+15:n.nodeRadius+15;return t.sourceStrategy&&(a+=n.nodeRadius+10),e.x+a}).attr("y1",t=>{let e=M.get(t.id),a=t.isPipelineParent?d:2*n.nodeRadius;return e.y-a/2}).attr("x2",t=>{let e=M.get(t.id),a=t.isPipelineParent?d/2+15:n.nodeRadius+15;return t.sourceStrategy&&(a+=n.nodeRadius+10),e.x+a}).attr("y2",t=>{let e=M.get(t.id),a=t.isPipelineParent?d:2*n.nodeRadius;return e.y+a/2}).attr("stroke",s.componentStroke).attr("stroke-width",6),L.append("text").attr("x",t=>{let e=M.get(t.id);if("anchor"===t.className)return void 0!==t.labelOffsetX?e.x+t.labelOffsetX:e.x;let a=n.nodeLabelOffset;t.sourceStrategy&&void 0===t.labelOffsetX&&(a+=10);let r=t.labelOffsetX??a;return e.x+r}).attr("y",t=>{let e=M.get(t.id);if("anchor"===t.className)return void 0!==t.labelOffsetY?e.y+t.labelOffsetY:e.y-3;let a=-n.nodeLabelOffset;t.sourceStrategy&&void 0===t.labelOffsetY&&(a-=10);let r=t.labelOffsetY??a;return e.y+r}).attr("class","wardley-node-label").attr("fill",t=>"evolved"===t.className?s.evolutionStroke:"anchor"===t.className?"#000":s.componentLabelColor).attr("font-size",n.labelFontSize).attr("font-weight",t=>"anchor"===t.className?"bold":"normal").attr("text-anchor",t=>"anchor"===t.className?"middle":"start").attr("dominant-baseline",t=>"anchor"===t.className?"middle":"auto").text(t=>t.label),p.annotations.length>0){let t=g.append("g").attr("class","wardley-annotations");if(p.annotations.forEach(e=>{let a=e.coordinates.map(t=>({x:k(t.x),y:b(t.y)}));if(a.length>1)for(let e=0;e<a.length-1;e++)t.append("line").attr("class","wardley-annotation-line").attr("x1",a[e].x).attr("y1",a[e].y).attr("x2",a[e+1].x).attr("y2",a[e+1].y).attr("stroke",s.axisColor).attr("stroke-width",1.5).attr("stroke-dasharray","4 4");a.forEach(a=>{let r=t.append("g").attr("class","wardley-annotation");r.append("circle").attr("cx",a.x).attr("cy",a.y).attr("r",10).attr("fill","white").attr("stroke",s.axisColor).attr("stroke-width",1.5),r.append("text").attr("x",a.x).attr("y",a.y).attr("text-anchor","middle").attr("dominant-baseline","central").attr("font-size",10).attr("fill",s.axisTextColor).attr("font-weight","bold").text(e.number)})}),p.annotationsBox){let e=k(p.annotationsBox.x),a=b(p.annotationsBox.y),r=t.append("g").attr("class","wardley-annotations-box"),o=[...p.annotations].filter(t=>t.text).sort((t,e)=>t.number-e.number),i=[];if(o.forEach((t,o)=>{let n=r.append("text").attr("x",e+10).attr("y",a+10+(o+1)*16).attr("font-size",11).attr("fill",s.axisTextColor).attr("text-anchor","start").attr("dominant-baseline","middle").text(`${t.number}. ${t.text}`);i.push(n)}),i.length>0){let t=0,l=0;i.forEach(e=>{let a=e.node(),r=a.getComputedTextLength();t=Math.max(t,r);let o=a.getBBox();l=Math.max(l,o.height)});let d=t+20+105,c=16*o.length+20+l/2,p=n.padding,h=x-n.padding-d,f=n.padding,g=y-n.padding-c;e=Math.max(p,Math.min(e,h)),a=Math.max(f,Math.min(a,g)),i.forEach((t,r)=>{t.attr("x",e+10).attr("y",a+10+(r+1)*16)}),r.insert("rect","text").attr("x",e).attr("y",a).attr("width",d).attr("height",c).attr("fill","white").attr("stroke",s.axisColor).attr("stroke-width",1.5).attr("rx",4).attr("ry",4)}}}if(p.notes.length>0){let t=g.append("g").attr("class","wardley-notes");p.notes.forEach(e=>{let a=k(e.x),r=b(e.y);t.append("text").attr("x",a).attr("y",r).attr("text-anchor","start").attr("font-size",11).attr("fill",s.axisTextColor).attr("font-weight","bold").text(e.text)})}if(p.accelerators.length>0){let t=g.append("g").attr("class","wardley-accelerators");p.accelerators.forEach(e=>{let a=k(e.x),r=b(e.y),o=`
2
+ M ${a} ${r-15}
3
+ L ${a+60-20} ${r-15}
4
+ L ${a+60-20} ${r-15-8}
5
+ L ${a+60} ${r}
6
+ L ${a+60-20} ${r+15+8}
7
+ L ${a+60-20} ${r+15}
8
+ L ${a} ${r+15}
9
+ Z
10
+ `;t.append("path").attr("d",o).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",1),t.append("text").attr("x",a+30).attr("y",r+15+15).attr("text-anchor","middle").attr("font-size",10).attr("fill",s.axisTextColor).attr("font-weight","bold").text(e.name)})}if(p.deaccelerators.length>0){let t=g.append("g").attr("class","wardley-deaccelerators");p.deaccelerators.forEach(e=>{let a=k(e.x),r=b(e.y),o=`
11
+ M ${a+60} ${r-15}
12
+ L ${a+20} ${r-15}
13
+ L ${a+20} ${r-15-8}
14
+ L ${a} ${r}
15
+ L ${a+20} ${r+15+8}
16
+ L ${a+20} ${r+15}
17
+ L ${a+60} ${r+15}
18
+ Z
19
+ `;t.append("path").attr("d",o).attr("fill","white").attr("stroke",s.componentStroke).attr("stroke-width",1),t.append("text").attr("x",a+30).attr("y",r+15+15).attr("text-anchor","middle").attr("font-size",10).attr("fill",s.axisTextColor).attr("font-weight","bold").text(e.name)})}},"draw")},styles:(0,l.K2)(({wardley:t}={})=>{let e=(0,i.P$)(),a=(0,i.zj)(),r=(0,n.$t)(e,a.themeVariables),o=(0,n.$t)(r.wardley,t);return`
20
+ .wardley-background {
21
+ fill: ${o.backgroundColor};
22
+ }
23
+ .wardley-axes line, .wardley-axes path {
24
+ stroke: ${o.axisColor};
25
+ }
26
+ .wardley-axis-label {
27
+ fill: ${o.axisTextColor};
28
+ }
29
+ .wardley-stage-label {
30
+ fill: ${o.axisTextColor};
31
+ }
32
+ .wardley-grid line {
33
+ stroke: ${o.gridColor};
34
+ }
35
+ .wardley-node circle {
36
+ fill: ${o.componentFill};
37
+ stroke: ${o.componentStroke};
38
+ }
39
+ .wardley-node-label {
40
+ fill: ${o.componentLabelColor};
41
+ }
42
+ .wardley-link {
43
+ stroke: ${o.linkStroke};
44
+ }
45
+ .wardley-link--dashed {
46
+ stroke-dasharray: 4 4;
47
+ }
48
+ .wardley-link-label {
49
+ fill: ${o.axisTextColor};
50
+ }
51
+ .wardley-trend line {
52
+ stroke: ${o.evolutionStroke};
53
+ }
54
+ .wardley-annotation-line {
55
+ stroke: ${o.annotationStroke};
56
+ }
57
+ .wardley-annotation circle {
58
+ fill: ${o.annotationFill};
59
+ stroke: ${o.annotationStroke};
60
+ }
61
+ .wardley-annotation text {
62
+ fill: ${o.annotationTextColor};
63
+ }
64
+ .wardley-annotations-box rect {
65
+ fill: ${o.annotationFill};
66
+ stroke: ${o.annotationStroke};
67
+ }
68
+ .wardley-annotations-box text {
69
+ fill: ${o.annotationTextColor};
70
+ }
71
+ .wardley-pipeline-box {
72
+ stroke: ${o.componentStroke};
73
+ }
74
+ .wardley-notes text {
75
+ fill: ${o.axisTextColor};
76
+ }
77
+ `},"styles")}},7566:(t,e,a)=>{function r(t,e){t.accDescr&&e.setAccDescription?.(t.accDescr),t.accTitle&&e.setAccTitle?.(t.accTitle),t.title&&e.setDiagramTitle?.(t.title)}a.d(e,{S:()=>r}),(0,a(316).K2)(r,"populateCommonDb")}}]);
_next/static/chunks/2442.01b89335df3ac251.js ADDED
@@ -0,0 +1,104 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2442],{2442:(t,e,r)=>{r.d(e,{diagram:()=>tK});var o=r(7566),a=r(3259),i=r(3736),n=r(669),s=r(316),c=r(4290),d=r(5508),l={NORMAL:0,REVERSE:1,HIGHLIGHT:2,MERGE:3,CHERRY_PICK:4},h=n.UI.gitGraph,$=(0,s.K2)(()=>(0,i.$t)({...h,...(0,n.zj)().gitGraph}),"getConfig"),m=new a.m(()=>{let t=$(),e=t.mainBranchName,r=t.mainBranchOrder;return{mainBranchName:e,commits:new Map,head:null,branchConfig:new Map([[e,{name:e,order:r}]]),branches:new Map([[e,null]]),currBranch:e,direction:"LR",seq:0,options:{}}});function g(){return(0,i.yT)({length:7})}function p(t,e){let r=Object.create(null);return t.reduce((t,o)=>{let a=e(o);return r[a]||(r[a]=!0,t.push(o)),t},[])}(0,s.K2)(g,"getID"),(0,s.K2)(p,"uniqBy");var y=(0,s.K2)(function(t){m.records.direction=t},"setDirection"),f=(0,s.K2)(function(t){s.Rm.debug("options str",t),t=(t=t?.trim())||"{}";try{m.records.options=JSON.parse(t)}catch(t){s.Rm.error("error while parsing gitGraph options",t.message)}},"setOptions"),x=(0,s.K2)(function(){return m.records.options},"getOptions"),u=(0,s.K2)(function(t){let e=t.msg,r=t.id,o=t.type,a=t.tags;s.Rm.info("commit",e,r,o,a),s.Rm.debug("Entering commit:",e,r,o,a);let i=$();r=n.Y2.sanitizeText(r,i),e=n.Y2.sanitizeText(e,i),a=a?.map(t=>n.Y2.sanitizeText(t,i));let c={id:r||m.records.seq+"-"+g(),message:e,seq:m.records.seq++,type:o??l.NORMAL,tags:a??[],parents:null==m.records.head?[]:[m.records.head.id],branch:m.records.currBranch};m.records.head=c,s.Rm.info("main branch",i.mainBranchName),m.records.commits.has(c.id)&&s.Rm.warn(`Commit ID ${c.id} already exists`),m.records.commits.set(c.id,c),m.records.branches.set(m.records.currBranch,c.id),s.Rm.debug("in pushCommit "+c.id)},"commit"),b=(0,s.K2)(function(t){let e=t.name,r=t.order;if(e=n.Y2.sanitizeText(e,$()),m.records.branches.has(e))throw Error(`Trying to create an existing branch. (Help: Either use a new name if you want create a new branch or try using "checkout ${e}")`);m.records.branches.set(e,null!=m.records.head?m.records.head.id:null),m.records.branchConfig.set(e,{name:e,order:r}),w(e),s.Rm.debug("in createBranch")},"branch"),k=(0,s.K2)(t=>{let e=t.branch,r=t.id,o=t.type,a=t.tags,i=$();e=n.Y2.sanitizeText(e,i),r&&(r=n.Y2.sanitizeText(r,i));let c=m.records.branches.get(m.records.currBranch),d=m.records.branches.get(e),h=c?m.records.commits.get(c):void 0,p=d?m.records.commits.get(d):void 0;if(h&&p&&h.branch===e)throw Error(`Cannot merge branch '${e}' into itself.`);if(m.records.currBranch===e){let t=Error('Incorrect usage of "merge". Cannot merge a branch to itself');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(void 0===h||!h){let t=Error(`Incorrect usage of "merge". Current branch (${m.records.currBranch})has no commits`);throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["commit"]},t}if(!m.records.branches.has(e)){let t=Error('Incorrect usage of "merge". Branch to be merged ('+e+") does not exist");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:[`branch ${e}`]},t}if(void 0===p||!p){let t=Error('Incorrect usage of "merge". Branch to be merged ('+e+") has no commits");throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:['"commit"']},t}if(h===p){let t=Error('Incorrect usage of "merge". Both branches have same head');throw t.hash={text:`merge ${e}`,token:`merge ${e}`,expected:["branch abc"]},t}if(r&&m.records.commits.has(r)){let t=Error('Incorrect usage of "merge". Commit with id:'+r+" already exists, use different custom id");throw t.hash={text:`merge ${e} ${r} ${o} ${a?.join(" ")}`,token:`merge ${e} ${r} ${o} ${a?.join(" ")}`,expected:[`merge ${e} ${r}_UNIQUE ${o} ${a?.join(" ")}`]},t}let y={id:r||`${m.records.seq}-${g()}`,message:`merged branch ${e} into ${m.records.currBranch}`,seq:m.records.seq++,parents:null==m.records.head?[]:[m.records.head.id,d||""],branch:m.records.currBranch,type:l.MERGE,customType:o,customId:!!r,tags:a??[]};m.records.head=y,m.records.commits.set(y.id,y),m.records.branches.set(m.records.currBranch,y.id),s.Rm.debug(m.records.branches),s.Rm.debug("in mergeBranch")},"merge"),B=(0,s.K2)(function(t){let e=t.id,r=t.targetId,o=t.tags,a=t.parent;s.Rm.debug("Entering cherryPick:",e,r,o);let i=$();if(e=n.Y2.sanitizeText(e,i),r=n.Y2.sanitizeText(r,i),o=o?.map(t=>n.Y2.sanitizeText(t,i)),a=n.Y2.sanitizeText(a,i),!e||!m.records.commits.has(e)){let t=Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let c=m.records.commits.get(e);if(void 0===c||!c)throw Error('Incorrect usage of "cherryPick". Source commit id should exist and provided');if(a&&!(Array.isArray(c.parents)&&c.parents.includes(a)))throw Error("Invalid operation: The specified parent commit is not an immediate parent of the cherry-picked commit.");let d=c.branch;if(c.type===l.MERGE&&!a)throw Error("Incorrect usage of cherry-pick: If the source commit is a merge commit, an immediate parent commit must be specified.");if(!r||!m.records.commits.has(r)){if(d===m.records.currBranch){let t=Error('Incorrect usage of "cherryPick". Source commit is already on current branch');throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let t=m.records.branches.get(m.records.currBranch);if(void 0===t||!t){let t=Error(`Incorrect usage of "cherry-pick". Current branch (${m.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let i=m.records.commits.get(t);if(void 0===i||!i){let t=Error(`Incorrect usage of "cherry-pick". Current branch (${m.records.currBranch})has no commits`);throw t.hash={text:`cherryPick ${e} ${r}`,token:`cherryPick ${e} ${r}`,expected:["cherry-pick abc"]},t}let n={id:m.records.seq+"-"+g(),message:`cherry-picked ${c?.message} into ${m.records.currBranch}`,seq:m.records.seq++,parents:null==m.records.head?[]:[m.records.head.id,c.id],branch:m.records.currBranch,type:l.CHERRY_PICK,tags:o?o.filter(Boolean):[`cherry-pick:${c.id}${c.type===l.MERGE?`|parent:${a}`:""}`]};m.records.head=n,m.records.commits.set(n.id,n),m.records.branches.set(m.records.currBranch,n.id),s.Rm.debug(m.records.branches),s.Rm.debug("in cherryPick")}},"cherryPick"),w=(0,s.K2)(function(t){if(t=n.Y2.sanitizeText(t,$()),m.records.branches.has(t)){m.records.currBranch=t;let e=m.records.branches.get(m.records.currBranch);void 0!==e&&e?m.records.head=m.records.commits.get(e)??null:m.records.head=null}else{let e=Error(`Trying to checkout branch which is not yet created. (Help try using "branch ${t}")`);throw e.hash={text:`checkout ${t}`,token:`checkout ${t}`,expected:[`branch ${t}`]},e}},"checkout");function E(t,e,r){let o=t.indexOf(e);-1===o?t.push(r):t.splice(o,1,r)}function T(t){let e=t.reduce((t,e)=>t.seq>e.seq?t:e,t[0]),r="";t.forEach(function(t){t===e?r+=" *":r+=" |"});let o=[r,e.id,e.seq];for(let t in m.records.branches)m.records.branches.get(t)===e.id&&o.push(t);if(s.Rm.debug(o.join(" ")),e.parents&&2==e.parents.length&&e.parents[0]&&e.parents[1]){let r=m.records.commits.get(e.parents[0]);E(t,e,r),e.parents[1]&&t.push(m.records.commits.get(e.parents[1]))}else if(0==e.parents.length)return;else if(e.parents[0]){let r=m.records.commits.get(e.parents[0]);E(t,e,r)}T(t=p(t,t=>t.id))}(0,s.K2)(E,"upsert"),(0,s.K2)(T,"prettyPrintCommitHistory");var C=(0,s.K2)(function(){s.Rm.debug(m.records.commits),T([v()[0]])},"prettyPrint"),L=(0,s.K2)(function(){m.reset(),(0,n.IU)()},"clear"),K=(0,s.K2)(function(){return[...m.records.branchConfig.values()].map((t,e)=>null!==t.order&&void 0!==t.order?t:{...t,order:parseFloat(`0.${e}`)}).sort((t,e)=>(t.order??0)-(e.order??0)).map(({name:t})=>({name:t}))},"getBranchesAsObjArray"),M=(0,s.K2)(function(){return m.records.branches},"getBranches"),R=(0,s.K2)(function(){return m.records.commits},"getCommits"),v=(0,s.K2)(function(){let t=[...m.records.commits.values()];return t.forEach(function(t){s.Rm.debug(t.id)}),t.sort((t,e)=>t.seq-e.seq),t},"getCommitsArray"),I={commitType:l,getConfig:$,setDirection:y,setOptions:f,getOptions:x,commit:u,branch:b,merge:k,cherryPick:B,checkout:w,prettyPrint:C,clear:L,getBranchesAsObjArray:K,getBranches:M,getCommits:R,getCommitsArray:v,getCurrentBranch:(0,s.K2)(function(){return m.records.currBranch},"getCurrentBranch"),getDirection:(0,s.K2)(function(){return m.records.direction},"getDirection"),getHead:(0,s.K2)(function(){return m.records.head},"getHead"),setAccTitle:n.SV,getAccTitle:n.iN,getAccDescription:n.m7,setAccDescription:n.EI,setDiagramTitle:n.ke,getDiagramTitle:n.ab},P=(0,s.K2)((t,e)=>{for(let r of((0,o.S)(t,e),t.dir&&e.setDirection(t.dir),t.statements))O(r,e)},"populate"),O=(0,s.K2)((t,e)=>{let r={Commit:(0,s.K2)(t=>e.commit(A(t)),"Commit"),Branch:(0,s.K2)(t=>e.branch(G(t)),"Branch"),Merge:(0,s.K2)(t=>e.merge(S(t)),"Merge"),Checkout:(0,s.K2)(t=>e.checkout(H(t)),"Checkout"),CherryPicking:(0,s.K2)(t=>e.cherryPick(D(t)),"CherryPicking")}[t.$type];r?r(t):s.Rm.error(`Unknown statement type: ${t.$type}`)},"parseStatement"),A=(0,s.K2)(t=>({id:t.id,msg:t.message??"",type:void 0!==t.type?l[t.type]:l.NORMAL,tags:t.tags??void 0}),"parseCommit"),G=(0,s.K2)(t=>({name:t.name,order:t.order??0}),"parseBranch"),S=(0,s.K2)(t=>({branch:t.branch,id:t.id??"",type:void 0!==t.type?l[t.type]:void 0,tags:t.tags??void 0}),"parseMerge"),H=(0,s.K2)(t=>t.branch,"parseCheckout"),D=(0,s.K2)(t=>({id:t.id,targetId:"",tags:t.tags?.length===0?void 0:t.tags,parent:t.parent}),"parseCherryPicking"),W={parse:(0,s.K2)(async t=>{let e=await (0,c.qg)("gitGraph",t);s.Rm.debug(e),P(e,I)},"parse")},q=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),_=new Set(["redux-color","redux-dark-color"]),z=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),Y=(0,s.K2)((t,e,r=!1)=>r&&t>0?(t-1)%(e-1)+1:t%e,"calcColorIndex"),N=new Map,j=new Map,F=new Map,U=[],V=0,J="LR",Q=(0,s.K2)(()=>{N.clear(),j.clear(),F.clear(),V=0,U=[],J="LR"},"clear"),X=(0,s.K2)(t=>{let e=document.createElementNS("http://www.w3.org/2000/svg","text");return("string"==typeof t?t.split(/\\n|\n|<br\s*\/?>/gi):t).forEach(t=>{let r=document.createElementNS("http://www.w3.org/2000/svg","tspan");r.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),r.setAttribute("dy","1em"),r.setAttribute("x","0"),r.setAttribute("class","row"),r.textContent=t.trim(),e.appendChild(r)}),e},"drawText"),Z=(0,s.K2)(t=>{let e,r,o;return"BT"===J?(r=(0,s.K2)((t,e)=>t<=e,"comparisonFunc"),o=1/0):(r=(0,s.K2)((t,e)=>t>=e,"comparisonFunc"),o=0),t.forEach(t=>{let a="TB"===J||"BT"==J?j.get(t)?.y:j.get(t)?.x;void 0!==a&&r(a,o)&&(e=t,o=a)}),e},"findClosestParent"),tt=(0,s.K2)(t=>{let e="",r=1/0;return t.forEach(t=>{let o=j.get(t).y;o<=r&&(e=t,r=o)}),e||void 0},"findClosestParentBT"),te=(0,s.K2)((t,e,r)=>{let o=r,a=r,i=[];t.forEach(t=>{let r=e.get(t);if(!r)throw Error(`Commit not found for key ${t}`);r.parents.length?a=Math.max(o=to(r),a):i.push(r),ta(r,o)}),o=a,i.forEach(t=>{ti(t,o,r)}),t.forEach(t=>{let r=e.get(t);if(r?.parents.length){let t=tt(r.parents);(o=j.get(t).y-40)<=a&&(a=o);let e=N.get(r.branch).pos,i=o-10;j.set(r.id,{x:e,y:i})}})},"setParallelBTPos"),tr=(0,s.K2)(t=>{let e=Z(t.parents.filter(t=>null!==t));if(!e)throw Error(`Closest parent not found for commit ${t.id}`);let r=j.get(e)?.y;if(void 0===r)throw Error(`Closest parent position not found for commit ${t.id}`);return r},"findClosestParentPos"),to=(0,s.K2)(t=>tr(t)+40,"calculateCommitPosition"),ta=(0,s.K2)((t,e)=>{let r=N.get(t.branch);if(!r)throw Error(`Branch not found for commit ${t.id}`);let o=r.pos,a=e+10;return j.set(t.id,{x:o,y:a}),{x:o,y:a}},"setCommitPosition"),ti=(0,s.K2)((t,e,r)=>{let o=N.get(t.branch);if(!o)throw Error(`Branch not found for commit ${t.id}`);let a=o.pos;j.set(t.id,{x:a,y:e+r})},"setRootPosition"),tn=(0,s.K2)((t,e,r,o,a,i)=>{let{theme:s}=(0,n.D7)(),c=q.has(s??""),d=_.has(s??""),h=z.has(s??"");if(i===l.HIGHLIGHT)t.append("rect").attr("x",r.x-10+3*!!c).attr("y",r.y-10+3*!!c).attr("width",c?14:20).attr("height",c?14:20).attr("class",`commit ${e.id} commit-highlight${Y(a,8,d)} ${o}-outer`),t.append("rect").attr("x",r.x-6+2*!!c).attr("y",r.y-6+2*!!c).attr("width",c?8:12).attr("height",c?8:12).attr("class",`commit ${e.id} commit${Y(a,8,d)} ${o}-inner`);else if(i===l.CHERRY_PICK)t.append("circle").attr("cx",r.x).attr("cy",r.y).attr("r",c?7:10).attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",r.x-3).attr("cy",r.y+2).attr("r",c?2.5:2.75).attr("fill",h?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("circle").attr("cx",r.x+3).attr("cy",r.y+2).attr("r",c?2.5:2.75).attr("fill",h?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",r.x+3).attr("y1",r.y+1).attr("x2",r.x).attr("y2",r.y-5).attr("stroke",h?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`),t.append("line").attr("x1",r.x-3).attr("y1",r.y+1).attr("x2",r.x).attr("y2",r.y-5).attr("stroke",h?"#000000":"#fff").attr("class",`commit ${e.id} ${o}`);else{let n=t.append("circle");if(n.attr("cx",r.x),n.attr("cy",r.y),n.attr("r",c?7:10),n.attr("class",`commit ${e.id} commit${Y(a,8,d)}`),i===l.MERGE){let i=t.append("circle");i.attr("cx",r.x),i.attr("cy",r.y),i.attr("r",c?5:6),i.attr("class",`commit ${o} ${e.id} commit${Y(a,8,d)}`)}if(i===l.REVERSE){let i=t.append("path"),n=c?4:5;i.attr("d",`M ${r.x-n},${r.y-n}L${r.x+n},${r.y+n}M${r.x-n},${r.y+n}L${r.x+n},${r.y-n}`).attr("class",`commit ${o} ${e.id} commit${Y(a,8,d)}`)}}},"drawCommitBullet"),ts=(0,s.K2)((t,e,r,o,a)=>{if(e.type!==l.CHERRY_PICK&&(e.customId&&e.type===l.MERGE||e.type!==l.MERGE)&&a.showCommitLabel){let i=t.append("g"),n=i.insert("rect").attr("class","commit-label-bkg"),s=i.append("text").attr("x",o).attr("y",r.y+25).attr("class","commit-label").text(e.id),c=s.node()?.getBBox();if(c&&(n.attr("x",r.posWithOffset-c.width/2-2).attr("y",r.y+13.5).attr("width",c.width+4).attr("height",c.height+4),"TB"===J||"BT"===J?(n.attr("x",r.x-(c.width+16+5)).attr("y",r.y-12),s.attr("x",r.x-(c.width+16)).attr("y",r.y+c.height-12)):s.attr("x",r.posWithOffset-c.width/2),a.rotateCommitLabel))if("TB"===J||"BT"===J)s.attr("transform","rotate(-45, "+r.x+", "+r.y+")"),n.attr("transform","rotate(-45, "+r.x+", "+r.y+")");else{let t=-7.5-(c.width+10)/25*9.5,e=10+c.width/25*8.5;i.attr("transform","translate("+t+", "+e+") rotate(-45, "+o+", "+r.y+")")}}},"drawCommitLabel"),tc=(0,s.K2)((t,e,r,o)=>{if(e.tags.length>0){let a=0,i=0,n=0,s=[];for(let o of e.tags.reverse()){let e=t.insert("polygon"),c=t.append("circle"),d=t.append("text").attr("y",r.y-16-a).attr("class","tag-label").text(o),l=d.node()?.getBBox();if(!l)throw Error("Tag bbox not found");i=Math.max(i,l.width),n=Math.max(n,l.height),d.attr("x",r.posWithOffset-l.width/2),s.push({tag:d,hole:c,rect:e,yOffset:a}),a+=20}for(let{tag:t,hole:e,rect:a,yOffset:c}of s){let s=n/2,d=r.y-19.2-c;if(a.attr("class","tag-label-bkg").attr("points",`
2
+ ${o-i/2-2},${d+2}
3
+ ${o-i/2-2},${d-2}
4
+ ${r.posWithOffset-i/2-4},${d-s-2}
5
+ ${r.posWithOffset+i/2+4},${d-s-2}
6
+ ${r.posWithOffset+i/2+4},${d+s+2}
7
+ ${r.posWithOffset-i/2-4},${d+s+2}`),e.attr("cy",d).attr("cx",o-i/2+2).attr("r",1.5).attr("class","tag-hole"),"TB"===J||"BT"===J){let n=o+c;a.attr("class","tag-label-bkg").attr("points",`
8
+ ${r.x},${n+2}
9
+ ${r.x},${n-2}
10
+ ${r.x+10},${n-s-2}
11
+ ${r.x+10+i+4},${n-s-2}
12
+ ${r.x+10+i+4},${n+s+2}
13
+ ${r.x+10},${n+s+2}`).attr("transform","translate(12,12) rotate(45, "+r.x+","+o+")"),e.attr("cx",r.x+2).attr("cy",n).attr("transform","translate(12,12) rotate(45, "+r.x+","+o+")"),t.attr("x",r.x+5).attr("y",n+3).attr("transform","translate(14,14) rotate(45, "+r.x+","+o+")")}}}},"drawCommitTags"),td=(0,s.K2)(t=>{switch(t.customType??t.type){case l.NORMAL:return"commit-normal";case l.REVERSE:return"commit-reverse";case l.HIGHLIGHT:return"commit-highlight";case l.MERGE:return"commit-merge";case l.CHERRY_PICK:return"commit-cherry-pick";default:return"commit-normal"}},"getCommitClassType"),tl=(0,s.K2)((t,e,r,o)=>{let a={x:0,y:0};if(t.parents.length>0){let r=Z(t.parents);if(r){let i=o.get(r)??a;return"TB"===e?i.y+40:"BT"===e?(o.get(t.id)??a).y-40:i.x+40}}else if("TB"===e)return 30;else if("BT"===e)return(o.get(t.id)??a).y-40;return 0},"calculatePosition"),th=(0,s.K2)((t,e,r)=>{let o="BT"===J&&r?e:e+10,a=N.get(t.branch)?.pos,i="TB"===J||"BT"===J?N.get(t.branch)?.pos:o;if(void 0===i||void 0===a)throw Error(`Position were undefined for commit ${t.id}`);let s=q.has((0,n.D7)().theme??"");return{x:i,y:"TB"===J||"BT"===J?o:a+(s?7:-2),posWithOffset:o}},"getCommitPosition"),t$=(0,s.K2)((t,e,r,o)=>{let a=t.append("g").attr("class","commit-bullets"),i=t.append("g").attr("class","commit-labels"),n=30*("TB"===J||"BT"===J),c=[...e.keys()],d=o.parallelCommits??!1,l=c.sort((0,s.K2)((t,r)=>{let o=e.get(t)?.seq,a=e.get(r)?.seq;return void 0!==o&&void 0!==a?o-a:0},"sortKeys"));"BT"===J&&(d&&te(l,e,n),l=l.reverse()),l.forEach(t=>{let s=e.get(t);if(!s)throw Error(`Commit not found for key ${t}`);d&&(n=tl(s,J,n,j));let c=th(s,n,d);if(r){let t=td(s),e=s.customType??s.type,r=N.get(s.branch)?.index??0;tn(a,s,c,t,r,e),ts(i,s,c,n,o),tc(i,s,c,n)}"TB"===J||"BT"===J?j.set(s.id,{x:c.x,y:c.posWithOffset}):j.set(s.id,{x:c.posWithOffset,y:c.y}),(n="BT"===J&&d?n+40:n+40+10)>V&&(V=n)})},"drawCommits"),tm=(0,s.K2)((t,e,r,o,a)=>{let i=("TB"===J||"BT"===J?r.x<o.x:r.y<o.y)?e.branch:t.branch,n=(0,s.K2)(t=>t.branch===i,"isOnBranchToGetCurve"),c=(0,s.K2)(r=>r.seq>t.seq&&r.seq<e.seq,"isBetweenCommits");return[...a.values()].some(t=>c(t)&&n(t))},"shouldRerouteArrow"),tg=(0,s.K2)((t,e,r=0)=>{let o=t+Math.abs(t-e)/2;if(r>5)return o;if(U.every(t=>Math.abs(t-o)>=10))return U.push(o),o;let a=Math.abs(t-e);return tg(t,e-a/5,r+1)},"findLane"),tp=(0,s.K2)((t,e,r,o)=>{let a,{theme:i}=(0,n.D7)(),s=_.has(i??""),c=j.get(e.id),d=j.get(r.id);if(void 0===c||void 0===d)throw Error(`Commit positions not found for commits ${e.id} and ${r.id}`);let h=tm(e,r,c,d,o),$="",m="",g=0,p=0,y=N.get(r.branch)?.index;if(r.type===l.MERGE&&e.id!==r.parents[0]&&(y=N.get(e.branch)?.index),h){$="A 10 10, 0, 0, 0,",m="A 10 10, 0, 0, 1,",g=10,p=10;let t=c.y<d.y?tg(c.y,d.y):tg(d.y,c.y),r=c.x<d.x?tg(c.x,d.x):tg(d.x,c.x);"TB"===J?c.x<d.x?a=`M ${c.x} ${c.y} L ${r-g} ${c.y} ${m} ${r} ${c.y+p} L ${r} ${d.y-g} ${$} ${r+p} ${d.y} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${r+g} ${c.y} ${$} ${r} ${c.y+p} L ${r} ${d.y-g} ${m} ${r-p} ${d.y} L ${d.x} ${d.y}`):"BT"===J?c.x<d.x?a=`M ${c.x} ${c.y} L ${r-g} ${c.y} ${$} ${r} ${c.y-p} L ${r} ${d.y+g} ${m} ${r+p} ${d.y} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${r+g} ${c.y} ${m} ${r} ${c.y-p} L ${r} ${d.y+g} ${$} ${r-p} ${d.y} L ${d.x} ${d.y}`):c.y<d.y?a=`M ${c.x} ${c.y} L ${c.x} ${t-g} ${$} ${c.x+p} ${t} L ${d.x-g} ${t} ${m} ${d.x} ${t+p} L ${d.x} ${d.y}`:(y=N.get(e.branch)?.index,a=`M ${c.x} ${c.y} L ${c.x} ${t+g} ${m} ${c.x+p} ${t} L ${d.x-g} ${t} ${$} ${d.x} ${t-p} L ${d.x} ${d.y}`)}else $="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,"TB"===J?(c.x<d.x&&(a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${$} ${c.x+p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${m} ${d.x} ${c.y+p} L ${d.x} ${d.y}`),c.x>d.x&&($="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${m} ${c.x-p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x+g} ${c.y} ${$} ${d.x} ${c.y+p} L ${d.x} ${d.y}`),c.x===d.x&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`)):"BT"===J?(c.x<d.x&&(a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${m} ${c.x+p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${$} ${d.x} ${c.y-p} L ${d.x} ${d.y}`),c.x>d.x&&($="A 20 20, 0, 0, 0,",m="A 20 20, 0, 0, 1,",g=20,p=20,a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${$} ${c.x-p} ${d.y} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${d.x+g} ${c.y} ${m} ${d.x} ${c.y-p} L ${d.x} ${d.y}`),c.x===d.x&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`)):(c.y<d.y&&(a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${m} ${d.x} ${c.y+p} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${c.x} ${d.y-g} ${$} ${c.x+p} ${d.y} L ${d.x} ${d.y}`),c.y>d.y&&(a=r.type===l.MERGE&&e.id!==r.parents[0]?`M ${c.x} ${c.y} L ${d.x-g} ${c.y} ${$} ${d.x} ${c.y-p} L ${d.x} ${d.y}`:`M ${c.x} ${c.y} L ${c.x} ${d.y+g} ${m} ${c.x+p} ${d.y} L ${d.x} ${d.y}`),c.y===d.y&&(a=`M ${c.x} ${c.y} L ${d.x} ${d.y}`));if(void 0===a)throw Error("Line definition not found");t.append("path").attr("d",a).attr("class","arrow arrow"+Y(y,8,s))},"drawArrow"),ty=(0,s.K2)((t,e)=>{let r=t.append("g").attr("class","commit-arrows");[...e.keys()].forEach(t=>{let o=e.get(t);o.parents&&o.parents.length>0&&o.parents.forEach(t=>{tp(r,e.get(t),o,e)})})},"drawArrows"),tf=(0,s.K2)((t,e,r,o)=>{let{look:a,theme:i,themeVariables:s}=(0,n.D7)(),{dropShadow:c,THEME_COLOR_LIMIT:d}=s,l=q.has(i??""),h=_.has(i??""),$=t.append("g");e.forEach((t,e)=>{let i=Y(e,l?d:8,h),n=N.get(t.name)?.pos;if(void 0===n)throw Error(`Position not found for branch ${t.name}`);let s="TB"===J||"BT"===J?n:l?n+6+1:n-2,m=$.append("line");m.attr("x1",0),m.attr("y1",s),m.attr("x2",V),m.attr("y2",s),m.attr("class","branch branch"+i),"TB"===J?(m.attr("y1",30),m.attr("x1",n),m.attr("y2",V),m.attr("x2",n)):"BT"===J&&(m.attr("y1",V),m.attr("x1",n),m.attr("y2",30),m.attr("x2",n)),U.push(s);let g=X(t.name),p=$.insert("rect"),y=$.insert("g").attr("class","branchLabel").insert("g").attr("class","label branch-label"+i);y.node().appendChild(g);let f=g.getBBox(),x=4*!l,u=16*!!l,b=12*!!l;"neo"===a&&p.attr("data-look","neo"),p.attr("class","branchLabelBkg label"+i).attr("style","neo"===a?`filter:${l?`url(#${o}-drop-shadow)`:c}`:"").attr("rx",x).attr("ry",x).attr("x",-f.width-4-30*(!0===r.rotateCommitLabel)).attr("y",-f.height/2+10).attr("width",f.width+18+u).attr("height",f.height+4+b),y.attr("transform","translate("+(-f.width-14-30*(!0===r.rotateCommitLabel)+u/2)+", "+(s-f.height/2-2)+")"),"TB"===J?(p.attr("x",n-f.width/2-10).attr("y",0),y.attr("transform","translate("+(n-f.width/2-5)+", 0)"),l&&(p.attr("transform",`translate(${-u/2-3}, ${-b-10})`),y.attr("transform","translate("+(n-f.width/2-5)+", "+(-(2*b)+7)+")"))):"BT"===J?(p.attr("x",n-f.width/2-10).attr("y",V),y.attr("transform","translate("+(n-f.width/2-5)+", "+V+")"),l&&(p.attr("transform",`translate(${-u/2-3}, ${b+10})`),y.attr("transform","translate("+(n-f.width/2-5)+", "+(V+2*b+4)+")"))):p.attr("transform","translate(-19, "+(s-12-b/2)+")")})},"drawBranches"),tx=(0,s.K2)(function(t,e,r,o,a){return N.set(t,{pos:e,index:r}),e+=50+40*!!a+("TB"===J||"BT"===J?o.width/2:0)},"setBranchPosition"),tu=(0,s.K2)(function(t,e,r,o){Q(),s.Rm.debug("in gitgraph renderer",t+"\n","id:",e,r);let a=o.db;if(!a.getConfig)return void s.Rm.error("getConfig method is not available on db");let c=a.getConfig(),l=c.rotateCommitLabel??!1;F=a.getCommits();let h=a.getBranchesAsObjArray();J=a.getDirection();let $=(0,d.Ltv)(`[id="${e}"]`),{look:m,theme:g,themeVariables:p}=(0,n.D7)(),{useGradient:y,gradientStart:f,gradientStop:x,filterColor:u}=p;if(y){let t=$.append("defs").append("linearGradient").attr("id",e+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");t.append("stop").attr("offset","0%").attr("stop-color",f).attr("stop-opacity",1),t.append("stop").attr("offset","100%").attr("stop-color",x).attr("stop-opacity",1)}"neo"===m&&q.has(g??"")&&$.append("defs").append("filter").attr("id",e+"-drop-shadow").attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity","0.06").attr("flood-color",u);let b=0;h.forEach((t,e)=>{let r=X(t.name),o=$.append("g"),a=o.insert("g").attr("class","branchLabel"),i=a.insert("g").attr("class","label branch-label");i.node()?.appendChild(r);let n=r.getBBox();b=tx(t.name,b,e,n,l),i.remove(),a.remove(),o.remove()}),t$($,F,!1,c),c.showBranches&&tf($,h,c,e),ty($,F),t$($,F,!0,c),i._K.insertTitle($,"gitTitleText",c.titleTopMargin??0,a.getDiagramTitle()),(0,n.mj)(void 0,$,c.diagramPadding,c.useMaxWidth)},"draw"),tb=new Set(["redux","redux-dark","redux-color","redux-dark-color"]),tk=new Set(["redux-color","redux-dark-color"]),tB=new Set(["neo","neo-dark"]),tw=new Set(["dark","redux-dark","redux-dark-color","neo-dark"]),tE=new Set(["redux","redux-dark","redux-color","redux-dark-color","neo","neo-dark"]),tT=(0,s.K2)(t=>{let{svgId:e}=t,r="";if(t.useGradient&&e)for(let o=0;o<t.THEME_COLOR_LIMIT;o++)r+=`
14
+ .label${o} { fill: ${t.mainBkg}; stroke: url(${e}-gradient); stroke-width: ${t.strokeWidth};}
15
+ `;return r},"genGitGraphGradient"),tC=(0,s.K2)(t=>{let{theme:e,themeVariables:r}=(0,n.zj)(),{borderColorArray:o}=r,a=tb.has(e);if(tB.has(e)){let e="";for(let r=0;r<t.THEME_COLOR_LIMIT;r++)if(0===r)e+=`
16
+ .branch-label${r} { fill: ${t.nodeBorder};}
17
+ .commit${r} { stroke: ${t.nodeBorder}; }
18
+ .commit-highlight${r} { stroke: ${t.nodeBorder}; fill: ${t.nodeBorder}; }
19
+ .arrow${r} { stroke: ${t.nodeBorder}; }
20
+ .commit-bullets { fill: ${t.nodeBorder}; }
21
+ .commit-cherry-pick${r} { stroke: ${t.nodeBorder}; }
22
+ ${tT(t)}`;else{let o=r%8;e+=`
23
+ .branch-label${r} { fill: ${t["gitBranchLabel"+o]}; }
24
+ .commit${r} { stroke: ${t["git"+o]}; fill: ${t["git"+o]}; }
25
+ .commit-highlight${r} { stroke: ${t["gitInv"+o]}; fill: ${t["gitInv"+o]}; }
26
+ .arrow${r} { stroke: ${t["git"+o]}; }
27
+ `}return e}if(tk.has(e)){let r="";for(let i=0;i<t.THEME_COLOR_LIMIT;i++)if(0===i)r+=`
28
+ .branch-label${i} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
29
+ .commit${i} { stroke: ${t.nodeBorder}; }
30
+ .commit-highlight${i} { stroke: ${t.nodeBorder}; fill: ${t.mainBkg}; }
31
+ .label${i} { fill: ${t.mainBkg}; stroke: ${t.nodeBorder}; stroke-width: ${t.strokeWidth}; ${a?`font-weight:${t.noteFontWeight}`:""} }
32
+ .arrow${i} { stroke: ${t.nodeBorder}; }
33
+ .commit-bullets { fill: ${t.nodeBorder}; }
34
+ `;else{let n=i%o.length;r+=`
35
+ .branch-label${i} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
36
+ .commit${i} { stroke: ${o[n]}; fill: ${o[n]}; }
37
+ .commit-highlight${i} { stroke: ${o[n]}; fill: ${o[n]}; }
38
+ .label${i} { fill: ${tw.has(e)?t.mainBkg:o[n]}; stroke: ${o[n]}; stroke-width: ${t.strokeWidth}; }
39
+ .arrow${i} { stroke: ${o[n]}; }
40
+ `}return r}{let e="";for(let r=0;r<t.THEME_COLOR_LIMIT;r++)e+=`
41
+ .branch-label${r} { fill: ${t.nodeBorder}; ${a?`font-weight:${t.noteFontWeight}`:""} }
42
+ .commit${r} { stroke: ${t.nodeBorder}; }
43
+ .commit-highlight${r} { stroke: ${t.nodeBorder}; fill: ${t.nodeBorder}; }
44
+ .label${r} { fill: ${t.mainBkg}; stroke: ${t.nodeBorder}; stroke-width: ${t.strokeWidth}; ${a?`font-weight:${t.noteFontWeight}`:""}}
45
+ .arrow${r} { stroke: ${t.nodeBorder}; }
46
+ .commit-bullets { fill: ${t.nodeBorder}; }
47
+ .commit-cherry-pick${r} { stroke: ${t.nodeBorder}; }
48
+ `;return e}},"genColor"),tL=(0,s.K2)(t=>`${Array.from({length:t.THEME_COLOR_LIMIT},(t,e)=>e).map(e=>{let r=e%8;return`
49
+ .branch-label${e} { fill: ${t["gitBranchLabel"+r]}; }
50
+ .commit${e} { stroke: ${t["git"+r]}; fill: ${t["git"+r]}; }
51
+ .commit-highlight${e} { stroke: ${t["gitInv"+r]}; fill: ${t["gitInv"+r]}; }
52
+ .label${e} { fill: ${t["git"+r]}; }
53
+ .arrow${e} { stroke: ${t["git"+r]}; }
54
+ `}).join("\n")}`,"normalTheme"),tK={parser:W,db:I,renderer:{draw:tu},styles:(0,s.K2)(t=>{let{theme:e}=(0,n.zj)(),r=tE.has(e);return`
55
+ .commit-id,
56
+ .commit-msg,
57
+ .branch-label {
58
+ fill: lightgrey;
59
+ color: lightgrey;
60
+ font-family: 'trebuchet ms', verdana, arial, sans-serif;
61
+ font-family: var(--mermaid-font-family);
62
+ }
63
+
64
+ ${r?tC(t):tL(t)}
65
+
66
+ .branch {
67
+ stroke-width: ${t.strokeWidth};
68
+ stroke: ${t.commitLineColor??t.lineColor};
69
+ stroke-dasharray: ${r?"4 2":"2"};
70
+ }
71
+ .commit-label { font-size: ${t.commitLabelFontSize}; fill: ${r?t.nodeBorder:t.commitLabelColor}; ${r?`font-weight:${t.noteFontWeight};`:""}}
72
+ .commit-label-bkg { font-size: ${t.commitLabelFontSize}; fill: ${r?"transparent":t.commitLabelBackground}; opacity: ${r?"":.5}; }
73
+ .tag-label { font-size: ${t.tagLabelFontSize}; fill: ${t.tagLabelColor};}
74
+ .tag-label-bkg { fill: ${r?t.mainBkg:t.tagLabelBackground}; stroke: ${r?t.nodeBorder:t.tagLabelBorder}; ${r?`filter:${t.dropShadow}`:""} }
75
+ .tag-hole { fill: ${t.textColor}; }
76
+
77
+ .commit-merge {
78
+ stroke: ${r?t.mainBkg:t.primaryColor};
79
+ fill: ${r?t.mainBkg:t.primaryColor};
80
+ }
81
+ .commit-reverse {
82
+ stroke: ${r?t.mainBkg:t.primaryColor};
83
+ fill: ${r?t.mainBkg:t.primaryColor};
84
+ stroke-width: ${r?t.strokeWidth:3};
85
+ }
86
+ .commit-highlight-outer {
87
+ }
88
+ .commit-highlight-inner {
89
+ stroke: ${r?t.mainBkg:t.primaryColor};
90
+ fill: ${r?t.mainBkg:t.primaryColor};
91
+ }
92
+
93
+ .arrow {
94
+ /* Intentional: neo themes keep the bold 8px arrow (like classic themes); only redux-geometry themes use the thinner options.strokeWidth. */
95
+ stroke-width: ${tb.has(e)?t.strokeWidth:8};
96
+ stroke-linecap: round;
97
+ fill: none
98
+ }
99
+ .gitTitleText {
100
+ text-anchor: middle;
101
+ font-size: 18px;
102
+ fill: ${t.textColor};
103
+ }
104
+ `},"getStyles")}},3259:(t,e,r)=>{r.d(e,{m:()=>a});var o=r(316),a=class{constructor(t){this.init=t,this.records=this.init()}static{(0,o.K2)(this,"ImperativeState")}reset(){this.records=this.init()}}},7566:(t,e,r)=>{function o(t,e){t.accDescr&&e.setAccDescription?.(t.accDescr),t.accTitle&&e.setAccTitle?.(t.accTitle),t.title&&e.setDiagramTitle?.(t.title)}r.d(e,{S:()=>o}),(0,r(316).K2)(o,"populateCommonDb")}}]);
_next/static/chunks/2452.1c5091d3e72e76a2.js ADDED
@@ -0,0 +1,287 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2452],{335:function(t){t.exports=function(t,e){var i=e.prototype,s=i.format;i.format=function(t){var e=this,i=this.$locale();if(!this.isValid())return s.bind(this)(t);var n=this.$utils(),r=(t||"YYYY-MM-DDTHH:mm:ssZ").replace(/\[([^\]]+)]|Q|wo|ww|w|WW|W|zzz|z|gggg|GGGG|Do|X|x|k{1,2}|S/g,function(t){switch(t){case"Q":return Math.ceil((e.$M+1)/3);case"Do":return i.ordinal(e.$D);case"gggg":return e.weekYear();case"GGGG":return e.isoWeekYear();case"wo":return i.ordinal(e.week(),"W");case"w":case"ww":return n.s(e.week(),"w"===t?1:2,"0");case"W":case"WW":return n.s(e.isoWeek(),"W"===t?1:2,"0");case"k":case"kk":return n.s(String(0===e.$H?24:e.$H),"k"===t?1:2,"0");case"X":return Math.floor(e.$d.getTime()/1e3);case"x":return e.$d.getTime();case"z":return"["+e.offsetName()+"]";case"zzz":return"["+e.offsetName("long")+"]";default:return t}});return s.bind(this)(r)}}},2452:(t,e,i)=>{"use strict";i.d(e,{diagram:()=>tF});var s,n,r,a=i(3736),o=i(669),c=i(316),l=i(3572),d=i(6117),u=i(8595),h=i(6571),f=i(335),m=i(9282),k=i(5508),y=function(){var t=(0,c.K2)(function(t,e,i,s){for(i=i||{},s=t.length;s--;i[t[s]]=e);return i},"o"),e=[6,8,10,12,13,14,15,16,17,18,20,21,22,23,24,25,26,27,28,29,30,31,33,35,36,38,40],i=[1,26],s=[1,27],n=[1,28],r=[1,29],a=[1,30],o=[1,31],l=[1,32],d=[1,33],u=[1,34],h=[1,9],f=[1,10],m=[1,11],k=[1,12],y=[1,13],g=[1,14],p=[1,15],v=[1,16],T=[1,19],x=[1,20],b=[1,21],$=[1,22],w=[1,23],_=[1,25],D=[1,35],S={trace:(0,c.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,gantt:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NL:10,weekday:11,weekday_monday:12,weekday_tuesday:13,weekday_wednesday:14,weekday_thursday:15,weekday_friday:16,weekday_saturday:17,weekday_sunday:18,weekend:19,weekend_friday:20,weekend_saturday:21,dateFormat:22,inclusiveEndDates:23,topAxis:24,axisFormat:25,tickInterval:26,excludes:27,includes:28,todayMarker:29,title:30,acc_title:31,acc_title_value:32,acc_descr:33,acc_descr_value:34,acc_descr_multiline_value:35,section:36,clickStatement:37,taskTxt:38,taskData:39,click:40,callbackname:41,callbackargs:42,href:43,clickStatementDebug:44,$accept:0,$end:1},terminals_:{2:"error",4:"gantt",6:"EOF",8:"SPACE",10:"NL",12:"weekday_monday",13:"weekday_tuesday",14:"weekday_wednesday",15:"weekday_thursday",16:"weekday_friday",17:"weekday_saturday",18:"weekday_sunday",20:"weekend_friday",21:"weekend_saturday",22:"dateFormat",23:"inclusiveEndDates",24:"topAxis",25:"axisFormat",26:"tickInterval",27:"excludes",28:"includes",29:"todayMarker",30:"title",31:"acc_title",32:"acc_title_value",33:"acc_descr",34:"acc_descr_value",35:"acc_descr_multiline_value",36:"section",38:"taskTxt",39:"taskData",40:"click",41:"callbackname",42:"callbackargs",43:"href"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[11,1],[19,1],[19,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,2],[9,1],[9,1],[9,1],[9,2],[37,2],[37,3],[37,3],[37,4],[37,3],[37,4],[37,2],[44,2],[44,3],[44,3],[44,4],[44,3],[44,4],[44,2]],performAction:(0,c.K2)(function(t,e,i,s,n,r,a){var o=r.length-1;switch(n){case 1:return r[o-1];case 2:case 6:case 7:this.$=[];break;case 3:r[o-1].push(r[o]),this.$=r[o-1];break;case 4:case 5:this.$=r[o];break;case 8:s.setWeekday("monday");break;case 9:s.setWeekday("tuesday");break;case 10:s.setWeekday("wednesday");break;case 11:s.setWeekday("thursday");break;case 12:s.setWeekday("friday");break;case 13:s.setWeekday("saturday");break;case 14:s.setWeekday("sunday");break;case 15:s.setWeekend("friday");break;case 16:s.setWeekend("saturday");break;case 17:s.setDateFormat(r[o].substr(11)),this.$=r[o].substr(11);break;case 18:s.enableInclusiveEndDates(),this.$=r[o].substr(18);break;case 19:s.TopAxis(),this.$=r[o].substr(8);break;case 20:s.setAxisFormat(r[o].substr(11)),this.$=r[o].substr(11);break;case 21:s.setTickInterval(r[o].substr(13)),this.$=r[o].substr(13);break;case 22:s.setExcludes(r[o].substr(9)),this.$=r[o].substr(9);break;case 23:s.setIncludes(r[o].substr(9)),this.$=r[o].substr(9);break;case 24:s.setTodayMarker(r[o].substr(12)),this.$=r[o].substr(12);break;case 27:s.setDiagramTitle(r[o].substr(6)),this.$=r[o].substr(6);break;case 28:this.$=r[o].trim(),s.setAccTitle(this.$);break;case 29:case 30:this.$=r[o].trim(),s.setAccDescription(this.$);break;case 31:s.addSection(r[o].substr(8)),this.$=r[o].substr(8);break;case 33:s.addTask(r[o-1],r[o]),this.$="task";break;case 34:this.$=r[o-1],s.setClickEvent(r[o-1],r[o],null);break;case 35:this.$=r[o-2],s.setClickEvent(r[o-2],r[o-1],r[o]);break;case 36:this.$=r[o-2],s.setClickEvent(r[o-2],r[o-1],null),s.setLink(r[o-2],r[o]);break;case 37:this.$=r[o-3],s.setClickEvent(r[o-3],r[o-2],r[o-1]),s.setLink(r[o-3],r[o]);break;case 38:this.$=r[o-2],s.setClickEvent(r[o-2],r[o],null),s.setLink(r[o-2],r[o-1]);break;case 39:this.$=r[o-3],s.setClickEvent(r[o-3],r[o-1],r[o]),s.setLink(r[o-3],r[o-2]);break;case 40:this.$=r[o-1],s.setLink(r[o-1],r[o]);break;case 41:case 47:this.$=r[o-1]+" "+r[o];break;case 42:case 43:case 45:this.$=r[o-2]+" "+r[o-1]+" "+r[o];break;case 44:case 46:this.$=r[o-3]+" "+r[o-2]+" "+r[o-1]+" "+r[o]}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:17,12:i,13:s,14:n,15:r,16:a,17:o,18:l,19:18,20:d,21:u,22:h,23:f,24:m,25:k,26:y,27:g,28:p,29:v,30:T,31:x,33:b,35:$,36:w,37:24,38:_,40:D},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:36,11:17,12:i,13:s,14:n,15:r,16:a,17:o,18:l,19:18,20:d,21:u,22:h,23:f,24:m,25:k,26:y,27:g,28:p,29:v,30:T,31:x,33:b,35:$,36:w,37:24,38:_,40:D},t(e,[2,5]),t(e,[2,6]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,20]),t(e,[2,21]),t(e,[2,22]),t(e,[2,23]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),t(e,[2,27]),{32:[1,37]},{34:[1,38]},t(e,[2,30]),t(e,[2,31]),t(e,[2,32]),{39:[1,39]},t(e,[2,8]),t(e,[2,9]),t(e,[2,10]),t(e,[2,11]),t(e,[2,12]),t(e,[2,13]),t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),{41:[1,40],43:[1,41]},t(e,[2,4]),t(e,[2,28]),t(e,[2,29]),t(e,[2,33]),t(e,[2,34],{42:[1,42],43:[1,43]}),t(e,[2,40],{41:[1,44]}),t(e,[2,35],{43:[1,45]}),t(e,[2,36]),t(e,[2,38],{42:[1,46]}),t(e,[2,37]),t(e,[2,39])],defaultActions:{},parseError:(0,c.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,c.K2)(function(t){var e=this,i=[0],s=[],n=[null],r=[],a=this.table,o="",l=0,d=0,u=0,h=r.slice.call(arguments,1),f=Object.create(this.lexer),m={};for(var k in this.yy)Object.prototype.hasOwnProperty.call(this.yy,k)&&(m[k]=this.yy[k]);f.setInput(t,m),m.lexer=f,m.parser=this,void 0===f.yylloc&&(f.yylloc={});var y=f.yylloc;r.push(y);var g=f.options&&f.options.ranges;function p(){var t;return"number"!=typeof(t=s.pop()||f.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof m.parseError?this.parseError=m.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,c.K2)(function(t){i.length=i.length-2*t,n.length=n.length-t,r.length=r.length-t},"popStack"),(0,c.K2)(p,"lex");for(var v,T,x,b,$,w,_,D,S,C={};;){if(x=i[i.length-1],this.defaultActions[x]?b=this.defaultActions[x]:(null==v&&(v=p()),b=a[x]&&a[x][v]),void 0===b||!b.length||!b[0]){var M="";for(w in S=[],a[x])this.terminals_[w]&&w>2&&S.push("'"+this.terminals_[w]+"'");M=f.showPosition?"Parse error on line "+(l+1)+":\n"+f.showPosition()+"\nExpecting "+S.join(", ")+", got '"+(this.terminals_[v]||v)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==v?"end of input":"'"+(this.terminals_[v]||v)+"'"),this.parseError(M,{text:f.match,token:this.terminals_[v]||v,line:f.yylineno,loc:y,expected:S})}if(b[0]instanceof Array&&b.length>1)throw Error("Parse Error: multiple actions possible at state: "+x+", token: "+v);switch(b[0]){case 1:i.push(v),n.push(f.yytext),r.push(f.yylloc),i.push(b[1]),v=null,T?(v=T,T=null):(d=f.yyleng,o=f.yytext,l=f.yylineno,y=f.yylloc,u>0&&u--);break;case 2:if(_=this.productions_[b[1]][1],C.$=n[n.length-_],C._$={first_line:r[r.length-(_||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(_||1)].first_column,last_column:r[r.length-1].last_column},g&&(C._$.range=[r[r.length-(_||1)].range[0],r[r.length-1].range[1]]),void 0!==($=this.performAction.apply(C,[o,d,l,m,b[1],n,r].concat(h))))return $;_&&(i=i.slice(0,-1*_*2),n=n.slice(0,-1*_),r=r.slice(0,-1*_)),i.push(this.productions_[b[1]][0]),n.push(C.$),r.push(C._$),D=a[i[i.length-2]][i[i.length-1]],i.push(D);break;case 3:return!0}}return!0},"parse")};function C(){this.yy={}}return S.lexer={EOF:1,parseError:(0,c.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,c.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,c.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,c.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var n=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===s.length?this.yylloc.first_column:0)+s[s.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[n[0],n[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,c.K2)(function(){return this._more=!0,this},"more"),reject:(0,c.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,c.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,c.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,c.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,c.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,c.K2)(function(t,e){var i,s,n;if(this.options.backtrack_lexer&&(n={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&&(n.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var r in n)this[r]=n[r];return!1},"test_match"),next:(0,c.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,s,n=this._currentRules(),r=0;r<n.length;r++)if((i=this._input.match(this.rules[n[r]]))&&(!e||i[0].length>e[0].length)){if(e=i,s=r,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,n[r])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,n[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,c.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,c.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,c.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,c.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,c.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,c.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,c.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,c.K2)(function(t,e,i,s){switch(i){case 0:return this.begin("open_directive"),"open_directive";case 1:return this.begin("acc_title"),31;case 2:return this.popState(),"acc_title_value";case 3:return this.begin("acc_descr"),33;case 4:return this.popState(),"acc_descr_value";case 5:this.begin("acc_descr_multiline");break;case 6:case 15:case 18:case 21:case 24:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:case 9:case 10:case 12:case 13:break;case 11:return 10;case 14:this.begin("href");break;case 16:return 43;case 17:this.begin("callbackname");break;case 19:this.popState(),this.begin("callbackargs");break;case 20:return 41;case 22:return 42;case 23:this.begin("click");break;case 25:return 40;case 26:return 4;case 27:return 22;case 28:return 23;case 29:return 24;case 30:return 25;case 31:return 26;case 32:return 28;case 33:return 27;case 34:return 29;case 35:return 12;case 36:return 13;case 37:return 14;case 38:return 15;case 39:return 16;case 40:return 17;case 41:return 18;case 42:return 20;case 43:return 21;case 44:return"date";case 45:return 30;case 46:return"accDescription";case 47:return 36;case 48:return 38;case 49:return 39;case 50:return":";case 51:return 6;case 52:return"INVALID"}},"anonymous"),rules:[/^(?:%%\{)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:%%(?!\{)*[^\n]*)/i,/^(?:[^\}]%%*[^\n]*)/i,/^(?:%%*[^\n]*[\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:%[^\n]*)/i,/^(?:href[\s]+["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:call[\s]+)/i,/^(?:\([\s]*\))/i,/^(?:\()/i,/^(?:[^(]*)/i,/^(?:\))/i,/^(?:[^)]*)/i,/^(?:click[\s]+)/i,/^(?:[\s\n])/i,/^(?:[^\s\n]*)/i,/^(?:gantt\b)/i,/^(?:dateFormat\s[^#\n;]+)/i,/^(?:inclusiveEndDates\b)/i,/^(?:topAxis\b)/i,/^(?:axisFormat\s[^#\n;]+)/i,/^(?:tickInterval\s[^#\n;]+)/i,/^(?:includes\s[^#\n;]+)/i,/^(?:excludes\s[^#\n;]+)/i,/^(?:todayMarker\s[^\n;]+)/i,/^(?:weekday\s+monday\b)/i,/^(?:weekday\s+tuesday\b)/i,/^(?:weekday\s+wednesday\b)/i,/^(?:weekday\s+thursday\b)/i,/^(?:weekday\s+friday\b)/i,/^(?:weekday\s+saturday\b)/i,/^(?:weekday\s+sunday\b)/i,/^(?:weekend\s+friday\b)/i,/^(?:weekend\s+saturday\b)/i,/^(?:\d\d\d\d-\d\d-\d\d\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accDescription\s[^#\n;]+)/i,/^(?:section\s[^\n]+)/i,/^(?:[^:\n]+)/i,/^(?::[^#\n;]+)/i,/^(?::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[6,7],inclusive:!1},acc_descr:{rules:[4],inclusive:!1},acc_title:{rules:[2],inclusive:!1},callbackargs:{rules:[21,22],inclusive:!1},callbackname:{rules:[18,19,20],inclusive:!1},href:{rules:[15,16],inclusive:!1},click:{rules:[24,25],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,17,23,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}},(0,c.K2)(C,"Parser"),C.prototype=S,S.Parser=C,new C}();y.parser=y,d.extend(u),d.extend(h),d.extend(f);var g={friday:5,saturday:6},p="",v="",T=void 0,x="",b=[],$=[],w=new Map,_=[],D=[],S="",C="",M=["active","done","crit","milestone","vert"],K=[],Y="",E=!1,L=!1,O="sunday",A="saturday",I=0,F=(0,c.K2)(function(){_=[],D=[],S="",K=[],ty=0,s=void 0,n=void 0,tT=[],p="",v="",C="",T=void 0,x="",b=[],$=[],E=!1,L=!1,I=0,w=new Map,Y="",(0,o.IU)(),O="sunday",A="saturday"},"clear"),W=(0,c.K2)(function(t){Y=t},"setDiagramId"),P=(0,c.K2)(function(t){v=t},"setAxisFormat"),N=(0,c.K2)(function(){return v},"getAxisFormat"),H=(0,c.K2)(function(t){T=t},"setTickInterval"),z=(0,c.K2)(function(){return T},"getTickInterval"),B=(0,c.K2)(function(t){x=t},"setTodayMarker"),R=(0,c.K2)(function(){return x},"getTodayMarker"),G=(0,c.K2)(function(t){p=t},"setDateFormat"),j=(0,c.K2)(function(){E=!0},"enableInclusiveEndDates"),U=(0,c.K2)(function(){return E},"endDatesAreInclusive"),V=(0,c.K2)(function(){L=!0},"enableTopAxis"),Z=(0,c.K2)(function(){return L},"topAxisEnabled"),X=(0,c.K2)(function(t){C=t},"setDisplayMode"),q=(0,c.K2)(function(){return C},"getDisplayMode"),Q=(0,c.K2)(function(){return p},"getDateFormat"),J=(0,c.K2)(function(t){b=t.toLowerCase().split(/[\s,]+/)},"setIncludes"),tt=(0,c.K2)(function(){return b},"getIncludes"),te=(0,c.K2)(function(t){$=t.toLowerCase().split(/[\s,]+/)},"setExcludes"),ti=(0,c.K2)(function(){return $},"getExcludes"),ts=(0,c.K2)(function(){return w},"getLinks"),tn=(0,c.K2)(function(t){S=t,_.push(t)},"addSection"),tr=(0,c.K2)(function(){return _},"getSections"),ta=(0,c.K2)(function(){let t=t_(),e=0;for(;!t&&e<10;)t=t_(),e++;return D=tT},"getTasks"),to=(0,c.K2)(function(t,e,i,s){let n=t.format(e.trim()),r=t.format("YYYY-MM-DD");return!(s.includes(n)||s.includes(r))&&(!!(i.includes("weekends")&&(t.isoWeekday()===g[A]||t.isoWeekday()===g[A]+1)||i.includes(t.format("dddd").toLowerCase()))||i.includes(n)||i.includes(r))},"isInvalidDate"),tc=(0,c.K2)(function(t){O=t},"setWeekday"),tl=(0,c.K2)(function(){return O},"getWeekday"),td=(0,c.K2)(function(t){A=t},"setWeekend"),tu=(0,c.K2)(function(t,e,i,s){let n;if(!i.length||t.manualEndTime)return;let[r,a]=th(n=(n=t.startTime instanceof Date?d(t.startTime):d(t.startTime,e,!0)).add(1,"d"),t.endTime instanceof Date?d(t.endTime):d(t.endTime,e,!0),e,i,s);t.endTime=r.toDate(),t.renderEndTime=a},"checkTaskDates"),th=(0,c.K2)(function(t,e,i,s,n){let r=!1,a=null,o=e.add(1e4,"d");for(;t<=e;){if(r||(a=e.toDate()),(r=to(t,i,s,n))&&(e=e.add(1,"d"))>o)throw Error("Failed to find a valid date that was not excluded by `excludes` after 10,000 iterations.");t=t.add(1,"d")}return[e,a]},"fixTaskDates"),tf=(0,c.K2)(function(t,e,i){if(i=i.trim(),(0,c.K2)(t=>{let e=t.trim();return"x"===e||"X"===e},"isTimestampFormat")(e)&&/^\d+$/.test(i))return new Date(Number(i));let s=/^after\s+(?<ids>[\d\w- ]+)/.exec(i);if(null!==s){let t=null;for(let e of s.groups.ids.split(" ")){let i=t$(e);void 0!==i&&(!t||i.endTime>t.endTime)&&(t=i)}if(t)return t.endTime;let e=new Date;return e.setHours(0,0,0,0),e}let n=d(i,e.trim(),!0);if(n.isValid())return n.toDate();{c.Rm.debug("Invalid date:"+i),c.Rm.debug("With date format:"+e.trim());let t=new Date(i);if(void 0===t||isNaN(t.getTime())||-1e4>t.getFullYear()||t.getFullYear()>1e4)throw Error("Invalid date:"+i);return t}},"getStartDate"),tm=(0,c.K2)(function(t){let e=/^(\d+(?:\.\d+)?)([Mdhmswy]|ms)$/.exec(t.trim());return null!==e?[Number.parseFloat(e[1]),e[2]]:[NaN,"ms"]},"parseDuration"),tk=(0,c.K2)(function(t,e,i,s=!1){i=i.trim();let n=/^until\s+(?<ids>[\d\w- ]+)/.exec(i);if(null!==n){let t=null;for(let e of n.groups.ids.split(" ")){let i=t$(e);void 0!==i&&(!t||i.startTime<t.startTime)&&(t=i)}if(t)return t.startTime;let e=new Date;return e.setHours(0,0,0,0),e}let r=d(i,e.trim(),!0);if(r.isValid())return s&&(r=r.add(1,"d")),r.toDate();let a=d(t),[o,c]=tm(i);if(!Number.isNaN(o)){let t=a.add(o,c);t.isValid()&&(a=t)}return a.toDate()},"getEndDate"),ty=0,tg=(0,c.K2)(function(t){return void 0===t?"task"+(ty+=1):t},"parseId"),tp=(0,c.K2)(function(t,e){let i=(":"===e.substr(0,1)?e.substr(1,e.length):e).split(","),s={};tL(i,s,M);for(let t=0;t<i.length;t++)i[t]=i[t].trim();let n="";switch(i.length){case 1:s.id=tg(),s.startTime=t.endTime,n=i[0];break;case 2:s.id=tg(),s.startTime=tf(void 0,p,i[0]),n=i[1];break;case 3:s.id=tg(i[0]),s.startTime=tf(void 0,p,i[1]),n=i[2]}return n&&(s.endTime=tk(s.startTime,p,n,E),s.manualEndTime=d(n,"YYYY-MM-DD",!0).isValid(),tu(s,p,$,b)),s},"compileData"),tv=(0,c.K2)(function(t,e){let i=(":"===e.substr(0,1)?e.substr(1,e.length):e).split(","),s={};tL(i,s,M);for(let t=0;t<i.length;t++)i[t]=i[t].trim();switch(i.length){case 1:s.id=tg(),s.startTime={type:"prevTaskEnd",id:t},s.endTime={data:i[0]};break;case 2:s.id=tg(),s.startTime={type:"getStartDate",startData:i[0]},s.endTime={data:i[1]};break;case 3:s.id=tg(i[0]),s.startTime={type:"getStartDate",startData:i[1]},s.endTime={data:i[2]}}return s},"parseData"),tT=[],tx={},tb=(0,c.K2)(function(t,e){let i={section:S,type:S,processed:!1,manualEndTime:!1,renderEndTime:null,raw:{data:e},task:t,classes:[]},s=tv(n,e);i.raw.startTime=s.startTime,i.raw.endTime=s.endTime,i.id=s.id,i.prevTaskId=n,i.active=s.active,i.done=s.done,i.crit=s.crit,i.milestone=s.milestone,i.vert=s.vert,i.order=I,I++;let r=tT.push(i);n=i.id,tx[i.id]=r-1},"addTask"),t$=(0,c.K2)(function(t){return tT[tx[t]]},"findTaskById"),tw=(0,c.K2)(function(t,e){let i={section:S,type:S,description:t,task:t,classes:[]},n=tp(s,e);i.startTime=n.startTime,i.endTime=n.endTime,i.id=n.id,i.active=n.active,i.done=n.done,i.crit=n.crit,i.milestone=n.milestone,i.vert=n.vert,s=i,D.push(i)},"addTaskOrg"),t_=(0,c.K2)(function(){let t=(0,c.K2)(function(t){let e=tT[t],i="";switch(tT[t].raw.startTime.type){case"prevTaskEnd":{let t=t$(e.prevTaskId);e.startTime=t.endTime;break}case"getStartDate":(i=tf(void 0,p,tT[t].raw.startTime.startData))&&(tT[t].startTime=i)}return tT[t].startTime&&(tT[t].endTime=tk(tT[t].startTime,p,tT[t].raw.endTime.data,E),tT[t].endTime&&(tT[t].processed=!0,tT[t].manualEndTime=d(tT[t].raw.endTime.data,"YYYY-MM-DD",!0).isValid(),tu(tT[t],p,$,b))),tT[t].processed},"compileTask"),e=!0;for(let[i,s]of tT.entries())t(i),e=e&&s.processed;return e},"compileTasks"),tD=(0,c.K2)(function(t,e){let i=e;"loose"!==(0,o.D7)().securityLevel&&(i=(0,l.J)(e)),t.split(",").forEach(function(t){void 0!==t$(t)&&(tM(t,()=>{window.open(i,"_self")}),w.set(t,i))}),tS(t,"clickable")},"setLink"),tS=(0,c.K2)(function(t,e){t.split(",").forEach(function(t){let i=t$(t);void 0!==i&&i.classes.push(e)})},"setClass"),tC=(0,c.K2)(function(t,e,i){if("loose"!==(0,o.D7)().securityLevel||void 0===e)return;let s=[];if("string"==typeof i){s=i.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t<s.length;t++){let e=s[t].trim();e.startsWith('"')&&e.endsWith('"')&&(e=e.substr(1,e.length-2)),s[t]=e}}0===s.length&&s.push(t),void 0!==t$(t)&&tM(t,()=>{a._K.runFunc(e,...s)})},"setClickFun"),tM=(0,c.K2)(function(t,e){K.push(function(){let i=Y?`${Y}-${t}`:t,s=document.querySelector(`[id="${i}"]`);null!==s&&s.addEventListener("click",function(){e()})},function(){let i=Y?`${Y}-${t}`:t,s=document.querySelector(`[id="${i}-text"]`);null!==s&&s.addEventListener("click",function(){e()})})},"pushFun"),tK=(0,c.K2)(function(t,e,i){t.split(",").forEach(function(t){tC(t,e,i)}),tS(t,"clickable")},"setClickEvent"),tY=(0,c.K2)(function(t){K.forEach(function(e){e(t)})},"bindFunctions"),tE={getConfig:(0,c.K2)(()=>(0,o.D7)().gantt,"getConfig"),clear:F,setDateFormat:G,getDateFormat:Q,enableInclusiveEndDates:j,endDatesAreInclusive:U,enableTopAxis:V,topAxisEnabled:Z,setAxisFormat:P,getAxisFormat:N,setTickInterval:H,getTickInterval:z,setTodayMarker:B,getTodayMarker:R,setAccTitle:o.SV,getAccTitle:o.iN,setDiagramTitle:o.ke,getDiagramTitle:o.ab,setDiagramId:W,setDisplayMode:X,getDisplayMode:q,setAccDescription:o.EI,getAccDescription:o.m7,addSection:tn,getSections:tr,getTasks:ta,addTask:tb,findTaskById:t$,addTaskOrg:tw,setIncludes:J,getIncludes:tt,setExcludes:te,getExcludes:ti,setClickEvent:tK,setLink:tD,getLinks:ts,bindFunctions:tY,parseDuration:tm,isInvalidDate:to,setWeekday:tc,getWeekday:tl,setWeekend:td};function tL(t,e,i){let s=!0;for(;s;)s=!1,i.forEach(function(i){let n=RegExp("^\\s*"+i+"\\s*$");t[0].match(n)&&(e[i]=!0,t.shift(1),s=!0)})}(0,c.K2)(tL,"getTaskTags"),d.extend(m);var tO=(0,c.K2)(function(){c.Rm.debug("Something is calling, setConf, remove the call")},"setConf"),tA={monday:k.ABi,tuesday:k.PGu,wednesday:k.GuW,thursday:k.Mol,friday:k.TUC,saturday:k.rGn,sunday:k.YPH},tI=(0,c.K2)((t,e)=>{let i=[...t].map(()=>-1/0),s=[...t].sort((t,e)=>t.startTime-e.startTime||t.order-e.order),n=0;for(let t of s)for(let s=0;s<i.length;s++)if(t.startTime>=i[s]){i[s]=t.endTime,t.order=s+e,s>n&&(n=s);break}return n},"getMaxIntersections"),tF={parser:y,db:tE,renderer:{setConf:tO,draw:(0,c.K2)(function(t,e,i,s){let n,a=(0,o.D7)().gantt;s.db.setDiagramId(e);let l=(0,o.D7)().securityLevel;"sandbox"===l&&(n=(0,k.Ltv)("#i"+e));let u="sandbox"===l?(0,k.Ltv)(n.nodes()[0].contentDocument.body):(0,k.Ltv)("body"),h="sandbox"===l?n.nodes()[0].contentDocument:document,f=h.getElementById(e);void 0===(r=f.parentElement.offsetWidth)&&(r=1200),void 0!==a.useWidth&&(r=a.useWidth);let m=s.db.getTasks(),y=[];for(let t of m)y.push(t.type);y=M(y);let g={},p=2*a.topPadding;if("compact"===s.db.getDisplayMode()||"compact"===a.displayMode){let t={};for(let e of m)void 0===t[e.section]?t[e.section]=[e]:t[e.section].push(e);let e=0;for(let i of Object.keys(t)){let s=tI(t[i],e)+1;e+=s,p+=s*(a.barHeight+a.barGap),g[i]=s}}else for(let t of(p+=m.length*(a.barHeight+a.barGap),y))g[t]=m.filter(e=>e.type===t).length;f.setAttribute("viewBox","0 0 "+r+" "+p);let v=u.select(`[id="${e}"]`),T=(0,k.w7C)().domain([(0,k.jkA)(m,function(t){return t.startTime}),(0,k.T9B)(m,function(t){return t.endTime})]).rangeRound([0,r-a.leftPadding-a.rightPadding]);function x(t,e){let i=t.startTime,s=e.startTime,n=0;return i>s?n=1:i<s&&(n=-1),n}function b(t,e,i){let n=a.barHeight,r=n+a.barGap,o=a.topPadding,c=a.leftPadding,l=(0,k.m4Y)().domain([0,y.length]).range(["#00B9FA","#F95002"]).interpolate(k.bEH);w(r,o,c,e,i,t,s.db.getExcludes(),s.db.getIncludes()),D(c,o,e,i),$(t,r,o,c,n,l,e,i),S(r,o,c,n,l),C(c,o,e,i)}function $(t,i,n,r,c,l,d){t.sort((t,e)=>t.vert===e.vert?0:t.vert?1:-1);let u=[...new Set(t.map(t=>t.order))].map(e=>t.find(t=>t.order===e));v.append("g").selectAll("rect").data(u).enter().append("rect").attr("x",0).attr("y",function(t,e){return t.order*i+n-2}).attr("width",function(){return d-a.rightPadding/2}).attr("height",i).attr("class",function(t){for(let[e,i]of y.entries())if(t.type===i)return"section section"+e%a.numberSectionStyles;return"section section0"}).enter();let h=v.append("g").selectAll("rect").data(t).enter(),f=s.db.getLinks();if(h.append("rect").attr("id",function(t){return e+"-"+t.id}).attr("rx",3).attr("ry",3).attr("x",function(t){return t.milestone?T(t.startTime)+r+.5*(T(t.endTime)-T(t.startTime))-.5*c:T(t.startTime)+r}).attr("y",function(t,e){return(e=t.order,t.vert)?a.gridLineStartPadding:e*i+n}).attr("width",function(t){return t.milestone?c:t.vert?.08*c:T(t.renderEndTime||t.endTime)-T(t.startTime)}).attr("height",function(t){return t.vert?m.length*(a.barHeight+a.barGap)+2*a.barHeight:c}).attr("transform-origin",function(t,e){return e=t.order,(T(t.startTime)+r+.5*(T(t.endTime)-T(t.startTime))).toString()+"px "+(e*i+n+.5*c).toString()+"px"}).attr("class",function(t){let e="";t.classes.length>0&&(e=t.classes.join(" "));let i=0;for(let[e,s]of y.entries())t.type===s&&(i=e%a.numberSectionStyles);let s="";return t.active?t.crit?s+=" activeCrit":s=" active":t.done?s=t.crit?" doneCrit":" done":t.crit&&(s+=" crit"),0===s.length&&(s=" task"),t.milestone&&(s=" milestone "+s),t.vert&&(s=" vert "+s),s+=i,"task"+(s+=" "+e)}),h.append("text").attr("id",function(t){return e+"-"+t.id+"-text"}).text(function(t){return t.task}).attr("font-size",a.fontSize).attr("x",function(t){let e=T(t.startTime),i=T(t.renderEndTime||t.endTime);if(t.milestone&&(e+=.5*(T(t.endTime)-T(t.startTime))-.5*c,i=e+c),t.vert)return T(t.startTime)+r;let s=this.getBBox().width;return s>i-e?i+s+1.5*a.leftPadding>d?e+r-5:i+r+5:(i-e)/2+e+r}).attr("y",function(t,e){return t.vert?a.gridLineStartPadding+m.length*(a.barHeight+a.barGap)+60:t.order*i+a.barHeight/2+(a.fontSize/2-2)+n}).attr("text-height",c).attr("class",function(t){let e=T(t.startTime),i=T(t.endTime);t.milestone&&(i=e+c);let s=this.getBBox().width,n="";t.classes.length>0&&(n=t.classes.join(" "));let r=0;for(let[e,i]of y.entries())t.type===i&&(r=e%a.numberSectionStyles);let o="";return(t.active&&(o=t.crit?"activeCritText"+r:"activeText"+r),t.done?o=t.crit?o+" doneCritText"+r:o+" doneText"+r:t.crit&&(o=o+" critText"+r),t.milestone&&(o+=" milestoneText"),t.vert&&(o+=" vertText"),s>i-e)?i+s+1.5*a.leftPadding>d?n+" taskTextOutsideLeft taskTextOutside"+r+" "+o:n+" taskTextOutsideRight taskTextOutside"+r+" "+o+" width-"+s:n+" taskText taskText"+r+" "+o+" width-"+s}),"sandbox"===(0,o.D7)().securityLevel){let t=(0,k.Ltv)("#i"+e).nodes()[0].contentDocument;h.filter(function(t){return f.has(t.id)}).each(function(i){var s=t.querySelector("#"+CSS.escape(e+"-"+i.id)),n=t.querySelector("#"+CSS.escape(e+"-"+i.id+"-text"));let r=s.parentNode;var a=t.createElement("a");a.setAttribute("xlink:href",f.get(i.id)),a.setAttribute("target","_top"),r.appendChild(a),a.appendChild(s),a.appendChild(n)})}}function w(t,i,n,r,o,l,u,h){let f,m;if(0===u.length&&0===h.length)return;for(let{startTime:t,endTime:e}of l)(void 0===f||t<f)&&(f=t),(void 0===m||e>m)&&(m=e);if(!f||!m)return;if(d(m).diff(d(f),"year")>5)return void c.Rm.warn("The difference between the min and max time is more than 5 years. This will cause performance issues. Skipping drawing exclude days.");let k=s.db.getDateFormat(),y=[],g=null,p=d(f);for(;p.valueOf()<=m;)s.db.isInvalidDate(p,k,u,h)?g?g.end=p:g={start:p,end:p}:g&&(y.push(g),g=null),p=p.add(1,"d");v.append("g").selectAll("rect").data(y).enter().append("rect").attr("id",t=>e+"-exclude-"+t.start.format("YYYY-MM-DD")).attr("x",t=>T(t.start.startOf("day"))+n).attr("y",a.gridLineStartPadding).attr("width",t=>T(t.end.endOf("day"))-T(t.start.startOf("day"))).attr("height",o-i-a.gridLineStartPadding).attr("transform-origin",function(e,i){return(T(e.start)+n+.5*(T(e.end)-T(e.start))).toString()+"px "+(i*t+.5*o).toString()+"px"}).attr("class","exclude-range")}function _(t,e,i,s){if(i<=0||t>e)return 1/0;let n=d.duration({[s??"day"]:i}).asMilliseconds();return n<=0?1/0:Math.ceil((e-t)/n)}function D(t,e,i,n){let r,o=s.db.getDateFormat(),l=s.db.getAxisFormat();r=l||("D"===o?"%d":a.axisFormat??"%Y-%m-%d");let d=(0,k.l78)(T).tickSize(-n+e+a.gridLineStartPadding).tickFormat((0,k.DCK)(r)),u=/^([1-9]\d*)(millisecond|second|minute|hour|day|week|month)$/.exec(s.db.getTickInterval()||a.tickInterval);if(null!==u){let t=parseInt(u[1],10);if(isNaN(t)||t<=0)c.Rm.warn(`Invalid tick interval value: "${u[1]}". Skipping custom tick interval.`);else{let e=u[2],i=s.db.getWeekday()||a.weekday,n=T.domain(),r=_(n[0],n[1],t,e);if(r>1e4)c.Rm.warn(`The tick interval "${t}${e}" would generate ${r} ticks, which exceeds the maximum allowed (10000). This may indicate an invalid date or time range. Skipping custom tick interval.`);else switch(e){case"millisecond":d.ticks(k.t6C.every(t));break;case"second":d.ticks(k.ucG.every(t));break;case"minute":d.ticks(k.wXd.every(t));break;case"hour":d.ticks(k.Agd.every(t));break;case"day":d.ticks(k.UAC.every(t));break;case"week":d.ticks(tA[i].every(t));break;case"month":d.ticks(k.Ui6.every(t))}}}if(v.append("g").attr("class","grid").attr("transform","translate("+t+", "+(n-50)+")").call(d).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10).attr("dy","1em"),s.db.topAxisEnabled()||a.topAxis){let i=(0,k.tlR)(T).tickSize(-n+e+a.gridLineStartPadding).tickFormat((0,k.DCK)(r));if(null!==u){let t=parseInt(u[1],10);if(isNaN(t)||t<=0)c.Rm.warn(`Invalid tick interval value: "${u[1]}". Skipping custom tick interval.`);else{let e=u[2],n=s.db.getWeekday()||a.weekday,r=T.domain();if(1e4>=_(r[0],r[1],t,e))switch(e){case"millisecond":i.ticks(k.t6C.every(t));break;case"second":i.ticks(k.ucG.every(t));break;case"minute":i.ticks(k.wXd.every(t));break;case"hour":i.ticks(k.Agd.every(t));break;case"day":i.ticks(k.UAC.every(t));break;case"week":i.ticks(tA[n].every(t));break;case"month":i.ticks(k.Ui6.every(t))}}}v.append("g").attr("class","grid").attr("transform","translate("+t+", "+e+")").call(i).selectAll("text").style("text-anchor","middle").attr("fill","#000").attr("stroke","none").attr("font-size",10)}}function S(t,e){let i=0,s=Object.keys(g).map(t=>[t,g[t]]);v.append("g").selectAll("text").data(s).enter().append(function(t){let e=t[0].split(o.Y2.lineBreakRegex),i=-(e.length-1)/2,s=h.createElementNS("http://www.w3.org/2000/svg","text");for(let[t,n]of(s.setAttribute("dy",i+"em"),e.entries())){let e=h.createElementNS("http://www.w3.org/2000/svg","tspan");e.setAttribute("alignment-baseline","central"),e.setAttribute("x","10"),t>0&&e.setAttribute("dy","1em"),e.textContent=n,s.appendChild(e)}return s}).attr("x",10).attr("y",function(n,r){if(!(r>0))return n[1]*t/2+e;for(let a=0;a<r;a++)return i+=s[r-1][1],n[1]*t/2+i*t+e}).attr("font-size",a.sectionFontSize).attr("class",function(t){for(let[e,i]of y.entries())if(t[0]===i)return"sectionTitle sectionTitle"+e%a.numberSectionStyles;return"sectionTitle"})}function C(t,e,i,n){let r=s.db.getTodayMarker();if("off"===r)return;let o=v.append("g").attr("class","today"),c=new Date,l=o.append("line");l.attr("x1",T(c)+t).attr("x2",T(c)+t).attr("y1",a.titleTopMargin).attr("y2",n-a.titleTopMargin).attr("class","today"),""!==r&&l.attr("style",r.replace(/,/g,";"))}function M(t){let e={},i=[];for(let s=0,n=t.length;s<n;++s)Object.prototype.hasOwnProperty.call(e,t[s])||(e[t[s]]=!0,i.push(t[s]));return i}(0,c.K2)(x,"taskCompare"),m.sort(x),b(m,r,p),(0,o.a$)(v,p,r,a.useMaxWidth),v.append("text").text(s.db.getDiagramTitle()).attr("x",r/2).attr("y",a.titleTopMargin).attr("class","titleText"),(0,c.K2)(b,"makeGantt"),(0,c.K2)($,"drawRects"),(0,c.K2)(w,"drawExcludeDays"),(0,c.K2)(_,"getEstimatedTickCount"),(0,c.K2)(D,"makeGrid"),(0,c.K2)(S,"vertLabels"),(0,c.K2)(C,"drawToday"),(0,c.K2)(M,"checkUnique")},"draw")},styles:(0,c.K2)(t=>`
2
+ .mermaid-main-font {
3
+ font-family: ${t.fontFamily};
4
+ }
5
+
6
+ .exclude-range {
7
+ fill: ${t.excludeBkgColor};
8
+ }
9
+
10
+ .section {
11
+ stroke: none;
12
+ opacity: 0.2;
13
+ }
14
+
15
+ .section0 {
16
+ fill: ${t.sectionBkgColor};
17
+ }
18
+
19
+ .section2 {
20
+ fill: ${t.sectionBkgColor2};
21
+ }
22
+
23
+ .section1,
24
+ .section3 {
25
+ fill: ${t.altSectionBkgColor};
26
+ opacity: 0.2;
27
+ }
28
+
29
+ .sectionTitle0 {
30
+ fill: ${t.titleColor};
31
+ }
32
+
33
+ .sectionTitle1 {
34
+ fill: ${t.titleColor};
35
+ }
36
+
37
+ .sectionTitle2 {
38
+ fill: ${t.titleColor};
39
+ }
40
+
41
+ .sectionTitle3 {
42
+ fill: ${t.titleColor};
43
+ }
44
+
45
+ .sectionTitle {
46
+ text-anchor: start;
47
+ font-family: ${t.fontFamily};
48
+ }
49
+
50
+
51
+ /* Grid and axis */
52
+
53
+ .grid .tick {
54
+ stroke: ${t.gridColor};
55
+ opacity: 0.8;
56
+ shape-rendering: crispEdges;
57
+ }
58
+
59
+ .grid .tick text {
60
+ font-family: ${t.fontFamily};
61
+ fill: ${t.textColor};
62
+ }
63
+
64
+ .grid path {
65
+ stroke-width: 0;
66
+ }
67
+
68
+
69
+ /* Today line */
70
+
71
+ .today {
72
+ fill: none;
73
+ stroke: ${t.todayLineColor};
74
+ stroke-width: 2px;
75
+ }
76
+
77
+
78
+ /* Task styling */
79
+
80
+ /* Default task */
81
+
82
+ .task {
83
+ stroke-width: 2;
84
+ }
85
+
86
+ .taskText {
87
+ text-anchor: middle;
88
+ font-family: ${t.fontFamily};
89
+ }
90
+
91
+ .taskTextOutsideRight {
92
+ fill: ${t.taskTextDarkColor};
93
+ text-anchor: start;
94
+ font-family: ${t.fontFamily};
95
+ }
96
+
97
+ .taskTextOutsideLeft {
98
+ fill: ${t.taskTextDarkColor};
99
+ text-anchor: end;
100
+ }
101
+
102
+
103
+ /* Special case clickable */
104
+
105
+ .task.clickable {
106
+ cursor: pointer;
107
+ }
108
+
109
+ .taskText.clickable {
110
+ cursor: pointer;
111
+ fill: ${t.taskTextClickableColor} !important;
112
+ font-weight: bold;
113
+ }
114
+
115
+ .taskTextOutsideLeft.clickable {
116
+ cursor: pointer;
117
+ fill: ${t.taskTextClickableColor} !important;
118
+ font-weight: bold;
119
+ }
120
+
121
+ .taskTextOutsideRight.clickable {
122
+ cursor: pointer;
123
+ fill: ${t.taskTextClickableColor} !important;
124
+ font-weight: bold;
125
+ }
126
+
127
+
128
+ /* Specific task settings for the sections*/
129
+
130
+ .taskText0,
131
+ .taskText1,
132
+ .taskText2,
133
+ .taskText3 {
134
+ fill: ${t.taskTextColor};
135
+ }
136
+
137
+ .task0,
138
+ .task1,
139
+ .task2,
140
+ .task3 {
141
+ fill: ${t.taskBkgColor};
142
+ stroke: ${t.taskBorderColor};
143
+ }
144
+
145
+ .taskTextOutside0,
146
+ .taskTextOutside2
147
+ {
148
+ fill: ${t.taskTextOutsideColor};
149
+ }
150
+
151
+ .taskTextOutside1,
152
+ .taskTextOutside3 {
153
+ fill: ${t.taskTextOutsideColor};
154
+ }
155
+
156
+
157
+ /* Active task */
158
+
159
+ .active0,
160
+ .active1,
161
+ .active2,
162
+ .active3 {
163
+ fill: ${t.activeTaskBkgColor};
164
+ stroke: ${t.activeTaskBorderColor};
165
+ }
166
+
167
+ .activeText0,
168
+ .activeText1,
169
+ .activeText2,
170
+ .activeText3 {
171
+ fill: ${t.taskTextDarkColor} !important;
172
+ }
173
+
174
+
175
+ /* Completed task */
176
+
177
+ .done0,
178
+ .done1,
179
+ .done2,
180
+ .done3 {
181
+ stroke: ${t.doneTaskBorderColor};
182
+ fill: ${t.doneTaskBkgColor};
183
+ stroke-width: 2;
184
+ }
185
+
186
+ .doneText0,
187
+ .doneText1,
188
+ .doneText2,
189
+ .doneText3 {
190
+ fill: ${t.taskTextDarkColor} !important;
191
+ }
192
+
193
+ /* Done task text displayed outside the bar sits against the diagram background,
194
+ not against the done-task bar, so it must use the outside/contrast color. */
195
+ .doneText0.taskTextOutsideLeft,
196
+ .doneText0.taskTextOutsideRight,
197
+ .doneText1.taskTextOutsideLeft,
198
+ .doneText1.taskTextOutsideRight,
199
+ .doneText2.taskTextOutsideLeft,
200
+ .doneText2.taskTextOutsideRight,
201
+ .doneText3.taskTextOutsideLeft,
202
+ .doneText3.taskTextOutsideRight {
203
+ fill: ${t.taskTextOutsideColor} !important;
204
+ }
205
+
206
+
207
+ /* Tasks on the critical line */
208
+
209
+ .crit0,
210
+ .crit1,
211
+ .crit2,
212
+ .crit3 {
213
+ stroke: ${t.critBorderColor};
214
+ fill: ${t.critBkgColor};
215
+ stroke-width: 2;
216
+ }
217
+
218
+ .activeCrit0,
219
+ .activeCrit1,
220
+ .activeCrit2,
221
+ .activeCrit3 {
222
+ stroke: ${t.critBorderColor};
223
+ fill: ${t.activeTaskBkgColor};
224
+ stroke-width: 2;
225
+ }
226
+
227
+ .doneCrit0,
228
+ .doneCrit1,
229
+ .doneCrit2,
230
+ .doneCrit3 {
231
+ stroke: ${t.critBorderColor};
232
+ fill: ${t.doneTaskBkgColor};
233
+ stroke-width: 2;
234
+ cursor: pointer;
235
+ shape-rendering: crispEdges;
236
+ }
237
+
238
+ .milestone {
239
+ transform: rotate(45deg) scale(0.8,0.8);
240
+ }
241
+
242
+ .milestoneText {
243
+ font-style: italic;
244
+ }
245
+ .doneCritText0,
246
+ .doneCritText1,
247
+ .doneCritText2,
248
+ .doneCritText3 {
249
+ fill: ${t.taskTextDarkColor} !important;
250
+ }
251
+
252
+ /* Done-crit task text outside the bar \u2014 same reasoning as doneText above. */
253
+ .doneCritText0.taskTextOutsideLeft,
254
+ .doneCritText0.taskTextOutsideRight,
255
+ .doneCritText1.taskTextOutsideLeft,
256
+ .doneCritText1.taskTextOutsideRight,
257
+ .doneCritText2.taskTextOutsideLeft,
258
+ .doneCritText2.taskTextOutsideRight,
259
+ .doneCritText3.taskTextOutsideLeft,
260
+ .doneCritText3.taskTextOutsideRight {
261
+ fill: ${t.taskTextOutsideColor} !important;
262
+ }
263
+
264
+ .vert {
265
+ stroke: ${t.vertLineColor};
266
+ }
267
+
268
+ .vertText {
269
+ font-size: 15px;
270
+ text-anchor: middle;
271
+ fill: ${t.vertLineColor} !important;
272
+ }
273
+
274
+ .activeCritText0,
275
+ .activeCritText1,
276
+ .activeCritText2,
277
+ .activeCritText3 {
278
+ fill: ${t.taskTextDarkColor} !important;
279
+ }
280
+
281
+ .titleText {
282
+ text-anchor: middle;
283
+ font-size: 18px;
284
+ fill: ${t.titleColor||t.textColor};
285
+ font-family: ${t.fontFamily};
286
+ }
287
+ `,"getStyles")}},6571:function(t){t.exports=function(){"use strict";var t={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"},e=/(\[[^[]*\])|([-_:/.,()\s]+)|(A|a|Q|YYYY|YY?|ww?|MM?M?M?|Do|DD?|hh?|HH?|mm?|ss?|S{1,3}|z|ZZ?)/g,i=/\d/,s=/\d\d/,n=/\d\d?/,r=/\d*[^-_:/,()\s\d]+/,a={},o=function(t){return(t*=1)+(t>68?1900:2e3)},c=function(t){return function(e){this[t]=+e}},l=[/[+-]\d\d:?(\d\d)?|Z/,function(t){(this.zone||(this.zone={})).offset=function(t){if(!t||"Z"===t)return 0;var e=t.match(/([+-]|\d\d)/g),i=60*e[1]+(+e[2]||0);return 0===i?0:"+"===e[0]?-i:i}(t)}],d=function(t){var e=a[t];return e&&(e.indexOf?e:e.s.concat(e.f))},u=function(t,e){var i,s=a.meridiem;if(s){for(var n=1;n<=24;n+=1)if(t.indexOf(s(n,0,e))>-1){i=n>12;break}}else i=t===(e?"pm":"PM");return i},h={A:[r,function(t){this.afternoon=u(t,!1)}],a:[r,function(t){this.afternoon=u(t,!0)}],Q:[i,function(t){this.month=3*(t-1)+1}],S:[i,function(t){this.milliseconds=100*t}],SS:[s,function(t){this.milliseconds=10*t}],SSS:[/\d{3}/,function(t){this.milliseconds=+t}],s:[n,c("seconds")],ss:[n,c("seconds")],m:[n,c("minutes")],mm:[n,c("minutes")],H:[n,c("hours")],h:[n,c("hours")],HH:[n,c("hours")],hh:[n,c("hours")],D:[n,c("day")],DD:[s,c("day")],Do:[r,function(t){var e=a.ordinal,i=t.match(/\d+/);if(this.day=i[0],e)for(var s=1;s<=31;s+=1)e(s).replace(/\[|\]/g,"")===t&&(this.day=s)}],w:[n,c("week")],ww:[s,c("week")],M:[n,c("month")],MM:[s,c("month")],MMM:[r,function(t){var e=d("months"),i=(d("monthsShort")||e.map(function(t){return t.slice(0,3)})).indexOf(t)+1;if(i<1)throw Error();this.month=i%12||i}],MMMM:[r,function(t){var e=d("months").indexOf(t)+1;if(e<1)throw Error();this.month=e%12||e}],Y:[/[+-]?\d+/,c("year")],YY:[s,function(t){this.year=o(t)}],YYYY:[/\d{4}/,c("year")],Z:l,ZZ:l};return function(i,s,n){n.p.customParseFormat=!0,i&&i.parseTwoDigitYear&&(o=i.parseTwoDigitYear);var r=s.prototype,c=r.parse;r.parse=function(i){var s=i.date,r=i.utc,o=i.args;this.$u=r;var l=o[1];if("string"==typeof l){var d=!0===o[2],u=!0===o[3],f=o[2];u&&(f=o[2]),a=this.$locale(),!d&&f&&(a=n.Ls[f]),this.$d=function(i,s,n,r){try{if(["x","X"].indexOf(s)>-1)return new Date(("X"===s?1e3:1)*i);var o=(function(i){var s,n;s=i,n=a&&a.formats;for(var r=(i=s.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,function(e,i,s){var r=s&&s.toUpperCase();return i||n[s]||t[s]||n[r].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,function(t,e,i){return e||i.slice(1)})})).match(e),o=r.length,c=0;c<o;c+=1){var l=r[c],d=h[l],u=d&&d[0],f=d&&d[1];r[c]=f?{regex:u,parser:f}:l.replace(/^\[|\]$/g,"")}return function(t){for(var e={},i=0,s=0;i<o;i+=1){var n=r[i];if("string"==typeof n)s+=n.length;else{var a=n.regex,c=n.parser,l=t.slice(s),d=a.exec(l)[0];c.call(e,d),t=t.replace(d,"")}}return function(t){var e=t.afternoon;if(void 0!==e){var i=t.hours;e?i<12&&(t.hours+=12):12===i&&(t.hours=0),delete t.afternoon}}(e),e}})(s)(i),c=o.year,l=o.month,d=o.day,u=o.hours,f=o.minutes,m=o.seconds,k=o.milliseconds,y=o.zone,g=o.week,p=new Date,v=d||(c||l?1:p.getDate()),T=c||p.getFullYear(),x=0;c&&!l||(x=l>0?l-1:p.getMonth());var b,$=u||0,w=f||0,_=m||0,D=k||0;return y?new Date(Date.UTC(T,x,v,$,w,_,D+60*y.offset*1e3)):n?new Date(Date.UTC(T,x,v,$,w,_,D)):(b=new Date(T,x,v,$,w,_,D),g&&(b=r(b).week(g).toDate()),b)}catch(t){return new Date("")}}(s,l,r,n),this.init(),f&&!0!==f&&(this.$L=this.locale(f).$L),(d||u)&&s!=this.format(l)&&(this.$d=new Date("")),a={}}else if(l instanceof Array)for(var m=l.length,k=1;k<=m;k+=1){o[1]=l[k-1];var y=n.apply(this,o);if(y.isValid()){this.$d=y.$d,this.$L=y.$L,this.init();break}k===m&&(this.$d=new Date(""))}else c.call(this,i)}}}()},8595:function(t){t.exports=function(t,e,i){var s=function(t){return t.add(4-t.isoWeekday(),"day")},n=e.prototype;n.isoWeekYear=function(){return s(this).year()},n.isoWeek=function(t){if(!this.$utils().u(t))return this.add(7*(t-this.isoWeek()),"day");var e,n,r,a=s(this),o=(e=this.isoWeekYear(),r=4-(n=(this.$u?i.utc:i)().year(e).startOf("year")).isoWeekday(),n.isoWeekday()>4&&(r+=7),n.add(r,"day"));return a.diff(o,"week")+1},n.isoWeekday=function(t){return this.$utils().u(t)?this.day()||7:this.day(this.day()%7?t:t-7)};var r=n.startOf;n.startOf=function(t,e){var i=this.$utils(),s=!!i.u(e)||e;return"isoweek"===i.p(t)?s?this.date(this.date()-(this.isoWeekday()-1)).startOf("day"):this.date(this.date()-1-(this.isoWeekday()-1)+7).endOf("day"):r.bind(this)(t,e)}}},9282:function(t){t.exports=function(){"use strict";var t,e,i=/^(-|\+)?P(?:([-+]?[0-9,.]*)Y)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)W)?(?:([-+]?[0-9,.]*)D)?(?:T(?:([-+]?[0-9,.]*)H)?(?:([-+]?[0-9,.]*)M)?(?:([-+]?[0-9,.]*)S)?)?$/,s=/\[([^\]]+)]|YYYY|YY|Y|M{1,2}|D{1,2}|H{1,2}|m{1,2}|s{1,2}|SSS/g,n={years:31536e6,months:2628e6,days:864e5,hours:36e5,minutes:6e4,seconds:1e3,milliseconds:1,weeks:6048e5},r=function(t){return t instanceof u},a=function(t,e,i){return new u(t,i,e.$l)},o=function(t){return e.p(t)+"s"},c=function(t){return t<0},l=function(t){return c(t)?Math.ceil(t):Math.floor(t)},d=function(t,e){return t?c(t)?{negative:!0,format:""+Math.abs(t)+e}:{negative:!1,format:""+t+e}:{negative:!1,format:""}},u=function(){function c(t,e,s){var r=this;if(this.$d={},this.$l=s,void 0===t&&(this.$ms=0,this.parseFromMilliseconds()),e)return a(t*n[o(e)],this);if("number"==typeof t)return this.$ms=t,this.parseFromMilliseconds(),this;if("object"==typeof t)return Object.keys(t).forEach(function(e){r.$d[o(e)]=t[e]}),this.calMilliseconds(),this;if("string"==typeof t){var c=t.match(i);if(c){var l=c.slice(2).map(function(t){return null!=t?Number(t):0});return this.$d.years=l[0],this.$d.months=l[1],this.$d.weeks=l[2],this.$d.days=l[3],this.$d.hours=l[4],this.$d.minutes=l[5],this.$d.seconds=l[6],this.calMilliseconds(),this}}return this}var u=c.prototype;return u.calMilliseconds=function(){var t=this;this.$ms=Object.keys(this.$d).reduce(function(e,i){return e+(t.$d[i]||0)*n[i]},0)},u.parseFromMilliseconds=function(){var t=this.$ms;this.$d.years=l(t/31536e6),t%=31536e6,this.$d.months=l(t/2628e6),t%=2628e6,this.$d.days=l(t/864e5),t%=864e5,this.$d.hours=l(t/36e5),t%=36e5,this.$d.minutes=l(t/6e4),t%=6e4,this.$d.seconds=l(t/1e3),t%=1e3,this.$d.milliseconds=t},u.toISOString=function(){var t=d(this.$d.years,"Y"),e=d(this.$d.months,"M"),i=+this.$d.days||0;this.$d.weeks&&(i+=7*this.$d.weeks);var s=d(i,"D"),n=d(this.$d.hours,"H"),r=d(this.$d.minutes,"M"),a=this.$d.seconds||0;this.$d.milliseconds&&(a+=this.$d.milliseconds/1e3,a=Math.round(1e3*a)/1e3);var o=d(a,"S"),c=t.negative||e.negative||s.negative||n.negative||r.negative||o.negative,l=n.format||r.format||o.format?"T":"",u=(c?"-":"")+"P"+t.format+e.format+s.format+l+n.format+r.format+o.format;return"P"===u||"-P"===u?"P0D":u},u.toJSON=function(){return this.toISOString()},u.format=function(t){var i={Y:this.$d.years,YY:e.s(this.$d.years,2,"0"),YYYY:e.s(this.$d.years,4,"0"),M:this.$d.months,MM:e.s(this.$d.months,2,"0"),D:this.$d.days,DD:e.s(this.$d.days,2,"0"),H:this.$d.hours,HH:e.s(this.$d.hours,2,"0"),m:this.$d.minutes,mm:e.s(this.$d.minutes,2,"0"),s:this.$d.seconds,ss:e.s(this.$d.seconds,2,"0"),SSS:e.s(this.$d.milliseconds,3,"0")};return(t||"YYYY-MM-DDTHH:mm:ss").replace(s,function(t,e){return e||String(i[t])})},u.as=function(t){return this.$ms/n[o(t)]},u.get=function(t){var e=this.$ms,i=o(t);return"milliseconds"===i?e%=1e3:e="weeks"===i?l(e/n[i]):this.$d[i],e||0},u.add=function(t,e,i){var s;return s=e?t*n[o(e)]:r(t)?t.$ms:a(t,this).$ms,a(this.$ms+s*(i?-1:1),this)},u.subtract=function(t,e){return this.add(t,e,!0)},u.locale=function(t){var e=this.clone();return e.$l=t,e},u.clone=function(){return a(this.$ms,this)},u.humanize=function(e){return t().add(this.$ms,"ms").locale(this.$l).fromNow(!e)},u.valueOf=function(){return this.asMilliseconds()},u.milliseconds=function(){return this.get("milliseconds")},u.asMilliseconds=function(){return this.as("milliseconds")},u.seconds=function(){return this.get("seconds")},u.asSeconds=function(){return this.as("seconds")},u.minutes=function(){return this.get("minutes")},u.asMinutes=function(){return this.as("minutes")},u.hours=function(){return this.get("hours")},u.asHours=function(){return this.as("hours")},u.days=function(){return this.get("days")},u.asDays=function(){return this.as("days")},u.weeks=function(){return this.get("weeks")},u.asWeeks=function(){return this.as("weeks")},u.months=function(){return this.get("months")},u.asMonths=function(){return this.as("months")},u.years=function(){return this.get("years")},u.asYears=function(){return this.as("years")},c}(),h=function(t,e,i){return t.add(e.years()*i,"y").add(e.months()*i,"M").add(e.days()*i,"d").add(e.hours()*i,"h").add(e.minutes()*i,"m").add(e.seconds()*i,"s").add(e.milliseconds()*i,"ms")};return function(i,s,n){t=n,e=n().$utils(),n.duration=function(t,e){return a(t,{$l:n.locale()},e)},n.isDuration=r;var o=s.prototype.add,c=s.prototype.subtract;s.prototype.add=function(t,e){return r(t)?h(this,t,1):o.bind(this)(t,e)},s.prototype.subtract=function(t,e){return r(t)?h(this,t,-1):c.bind(this)(t,e)}}}()}}]);
_next/static/chunks/2487.5d390db091e7b181.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2487],{2487:(e,s,a)=>{a.d(s,{createTreemapServices:()=>c.d});var c=a(4752);a(4839)}}]);
_next/static/chunks/261.4a233b47734aecfc.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[261],{261:(e,t,i)=>{i.d(t,{diagram:()=>ei});var n=i(7566),a=i(3736),r=i(669),o=i(316),l=i(4290),d=i(5508),s="position frame",m="frame positioned",c="position relation",x="relation positioned",u=(0,o.K2)(function(e){o.Rm.debug("options str",e)},"setOptions"),f=(0,o.K2)(function(){return{}},"getOptions"),g=(0,o.K2)(function(){h(),(0,r.IU)()},"clear");function h(){w={}}(0,o.K2)(h,"reset");var b=r.UI.eventmodeling,p=(0,o.K2)(()=>(0,a.$t)({...b,...(0,r.zj)().eventmodeling}),"getConfig"),w={};function v(){let e=M,{ast:t}=w,i=P();if(!t)throw Error("No data for EventModel");return t.frames.forEach((n,a)=>{let r=$(n,t.dataEntities,i);e=G(e,{$kind:s,index:a,frame:n,textProps:r}),C(n)?(o.Rm.debug("source frame",n.sourceFrames),t.frames.filter(e=>n.sourceFrames.some(t=>t.$refText===e.name)).forEach(t=>{e=G(e,{$kind:c,index:a,frame:n,sourceFrame:t})})):e=G(e,{$kind:c,index:a,frame:n})}),e={...e,sortedSwimlanesArray:D(e.swimlanes)}}function y(e){w.ast=e}(0,o.K2)(v,"getState"),(0,o.K2)(y,"setAst");var k={swimlaneMinHeight:70,swimlanePadding:15,swimlaneGap:10,boxPadding:10,boxOverlap:90,boxDefaultY:0,boxMinWidth:80,boxMaxWidth:450,boxMinHeight:80,boxMaxHeight:750,contentStartX:250,textMaxWidth:430,boxTextFontWeight:"bold",boxTextPadding:10,swimlaneTextFontWeight:"bold",labelUiAutomation:"UI/Automation",labelUiAutomationPrefix:"UI/A: ",labelCommandReadModel:"Command/Read Model",labelCommandReadModelPrefix:"C/RM: ",labelEvents:"Events",labelEventsPrefix:"Stream: "};function P(){return k}(0,o.K2)(P,"getDiagramProps");var M={boxes:[],swimlanes:{},relations:[],maxR:0,sortedSwimlanesArray:[]};function K(e){let t=e.split(".");if(2===t.length)return t[0]}function S(e){let t=e.split(".");return 2===t.length?t[1]:e}function B(e,t){if(t&&0!==t.length)return Object.values(e).find(e=>e.namespace===t)}function F(e,t,i){return Math.max(t,...Object.keys(e).filter(e=>{let n=Number.parseInt(e);return n>t&&n<i}).map(e=>Number.parseInt(e)))+1}function R(e,t){let i=K(e.entityIdentifier),n=B(t,i);switch(e.modelEntityType){case"ui":case"pcr":case"processor":if(n)return{index:n.index,label:n.namespace||k.labelUiAutomation};if(i)return{index:F(t,0,100),label:k.labelUiAutomationPrefix+i};return{index:0,label:k.labelUiAutomation};case"rmo":case"readmodel":case"cmd":case"command":if(n)return{index:n.index,label:n.namespace||k.labelCommandReadModel};if(i)return{index:F(t,100,200),label:k.labelCommandReadModelPrefix+i};return{index:100,label:k.labelCommandReadModel};default:if(n)return{index:n.index,label:n.namespace||k.labelEvents};if(i)return{index:F(t,200,300),label:k.labelEventsPrefix+i};return{index:200,label:k.labelEvents}}}function E(e){let{themeVariables:t}=(0,r.zj)();switch(e.modelEntityType){case"ui":return{fill:t.emUiFill??"white",stroke:t.emUiStroke??"#dbdada"};case"pcr":case"processor":return{fill:t.emProcessorFill??"#edb3f6",stroke:t.emProcessorStroke??"#b88cbf"};case"rmo":case"readmodel":return{fill:t.emReadModelFill??"#d3f1a2",stroke:t.emReadModelStroke??"#a3b732"};case"cmd":case"command":return{fill:t.emCommandFill??"#bcd6fe",stroke:t.emCommandStroke??"#679ac3"};case"evt":case"event":return{fill:t.emEventFill??"#ffb778",stroke:t.emEventStroke??"#c19a0f"};default:return{fill:"red",stroke:"black"}}}function $(e,t,i){let n,l=(0,r.zj)(),d=(0,r.jZ)(S(e.entityIdentifier)??"",l),s={fontSize:16,fontWeight:700,fontFamily:'"trebuchet ms", verdana, arial, sans-serif',joinWith:"<br/>"},m=(0,a.bH)(d,i.textMaxWidth,s),c=`<b>${m}</b>`;if(e.dataInlineValue&&(n=(n=(n=e.dataInlineValue).substring(n.indexOf("{")+1)).substring(0,n.lastIndexOf("}")-1),n=(0,r.jZ)(n,l),n=(n=(0,a.bH)(n,i.textMaxWidth,s)).replaceAll(" ","&nbsp;")),e.dataReference){let o=t.find(t=>t.name===e.dataReference?.$refText);o&&(n=(n=(n=o.dataBlockValue).substring(n.indexOf("{\n")+2)).substring(0,n.lastIndexOf("}")-1),n=(0,r.jZ)(n,l),n=(n=(0,a.bH)(n,i.textMaxWidth,s)).replaceAll(" ","&nbsp;")+"<br/>")}let x=void 0!==n;x&&(c+=`<br/><br/><code style="text-align: left; display: block;max-width:${i.textMaxWidth}px">${n}</code>`);let u={fontSize:s.fontSize,fontWeight:s.fontWeight,fontFamily:s.fontFamily},f=(0,a.PX)(c,u),g={content:c,width:x?f.width/3:f.width,height:f.height};return o.Rm.debug(`[${e.name}] ${e.entityIdentifier} text`,g),g}function A(e,t){let i=E(t.frame),n={width:t.textProps.width+2*k.boxTextPadding,height:t.textProps.height+2*k.boxTextPadding};return[{$kind:m,frame:t.frame,index:t.index,visual:i,dimension:n,textProps:t.textProps}]}function T(e,t,i){return void 0===t?k.contentStartX:t.index===e.index&&e.r?e.r+k.boxPadding:void 0===i?k.contentStartX:i.r-k.boxOverlap+k.boxPadding}function W(e,t){return Math.max(...e.map(e=>e.r),t)}function D(e){return Object.values(e).sort((e,t)=>e.index-t.index)}function H(e,t){let i,n=R(t.frame,e.swimlanes);i=n.index in e.swimlanes?e.swimlanes[n.index]:{index:n.index,label:n.label,r:0,y:n.index*k.swimlaneMinHeight+k.swimlaneGap,height:k.swimlaneMinHeight,maxHeight:k.swimlaneMinHeight};let a=e.boxes.length>0?e.boxes[e.boxes.length-1]:void 0,r=void 0!==e.previousSwimlaneNumber?e.swimlanes[e.previousSwimlaneNumber]:void 0,o={width:Math.max(k.boxMinWidth,Math.min(k.boxMaxWidth,t.dimension.width))+2*k.boxPadding,height:Math.max(k.boxMinHeight,Math.min(k.boxMaxHeight,t.dimension.height))+2*k.boxPadding},l=T(i,r,a),d=l+o.width+k.boxPadding,s=W(Object.values(e.swimlanes),d);i.r=l+o.width,i.maxHeight=Math.max(i.maxHeight,o.height),i.height=Math.max(k.swimlaneMinHeight,i.maxHeight)+2*k.swimlanePadding;let m={x:l,y:k.swimlanePadding+i.y,r:d,dimension:o,leftSibling:!1,swimlane:i,visual:t.visual,text:t.textProps.content,frame:t.frame,index:t.index},c={...e,boxes:[...e.boxes,m],swimlanes:{...e.swimlanes,[`${i.index}`]:i},previousSwimlaneNumber:n.index,previousFrame:t.frame,maxR:s},x=D(c.swimlanes);x.length>0&&(x[0].y=0);for(let e=1;e<x.length;e++){let t=x[e],i=x[e-1];t.y=i.y+i.height+k.swimlaneGap}return c}function I(e,t){return 0===e&&0===t.sourceFrames.length}function C(e){return void 0!==e.sourceFrames&&null!==e.sourceFrames&&e.sourceFrames.length>0}function O(e,t){if(null!=t)return e.find(e=>e.frame.name===t.name)}function j(e,t,i){if(!(i<0))for(let n=i;n>=0;n--){let i=e[n];if(i.swimlane.index!==t)return i}}function N(e,t){let i;if((0,l.F5)(t.frame)||I(t.index,t.frame))return[];let n=O(e.boxes,t.frame);if(void 0===n)throw Error(`Target box not found for frame ${t.frame.name}`);return void 0===(i=t.sourceFrame?O(e.boxes,t.sourceFrame):j(e.boxes,n.swimlane.index,t.index-1))?[]:[{$kind:x,frame:t.frame,index:t.index,sourceBox:i,targetBox:n}]}function U(e,t){let i={visual:{fill:"none",stroke:"#000"},source:{x:t.sourceBox.x,y:t.sourceBox.y},target:{x:t.targetBox.x,y:t.targetBox.y},sourceBox:t.sourceBox,targetBox:t.targetBox};return{...e,relations:[...e.relations,i]}}(0,o.K2)(K,"extractNamespace"),(0,o.K2)(S,"extractName"),(0,o.K2)(B,"findSwimlaneByNamespace"),(0,o.K2)(F,"findNextAvailableIndex"),(0,o.K2)(R,"calculateSwimlaneProps"),(0,o.K2)(E,"calculateEntityVisualProps"),(0,o.K2)($,"calculateTextProps"),(0,o.K2)(A,"decidePositionFrame"),(0,o.K2)(T,"calculateX"),(0,o.K2)(W,"calculateMaxRight"),(0,o.K2)(D,"sortedSwimlanesArray"),(0,o.K2)(H,"evolveFramePositioned"),(0,o.K2)(I,"isFirstFrame"),(0,o.K2)(C,"hasSourceFrame"),(0,o.K2)(O,"findBoxByFrame"),(0,o.K2)(j,"findBoxByLineIndex"),(0,o.K2)(N,"decidePositionRelation"),(0,o.K2)(U,"evolveRelationPositioned");var z={[s]:A,[c]:N},X={[m]:H,[x]:U};function V(e,t){let i=z[t.$kind];if(null==i)return[];let n=i(e,t);return o.Rm.debug("decided events",n),n}function _(e,t){let i=t.reduce((e,t)=>{let i=X[t.$kind];return null==i?e:i(e,t)},e);return o.Rm.debug("evolve events",{state:e,newState:i,events:t}),i}function G(e,t){let i=V(e,t);return _(e,i)}(0,o.K2)(V,"decide"),(0,o.K2)(_,"evolve"),(0,o.K2)(G,"dispatch");var L={getConfig:p,setOptions:u,getOptions:f,clear:g,setAccTitle:r.SV,getAccTitle:r.iN,getAccDescription:r.m7,setAccDescription:r.EI,setDiagramTitle:r.ke,getDiagramTitle:r.ab,setAst:y,getDiagramProps:P,getState:v},Z={parse:(0,o.K2)(async e=>{let t=await (0,l.qg)("eventmodeling",e);o.Rm.debug(t),L.setAst(t),(0,n.S)(t,L)},"parse")},Y=(0,r.D7)(),q=Y?.eventmodeling;function J(e,t){return i=>{let n=i.swimlane.y+t.swimlanePadding,a=e.append("g").attr("class","em-box");a.append("rect").attr("x",i.x).attr("y",n).attr("rx","3").attr("width",i.dimension.width).attr("height",i.dimension.height).attr("stroke",i.visual.stroke).attr("fill",i.visual.fill),a.append("foreignObject").attr("x",i.x+t.boxPadding).attr("y",n+10).attr("width",i.dimension.width-2*t.boxPadding).attr("height",i.dimension.height-2*t.boxPadding).append("xhtml:div").style("display","table").style("height","100%").style("width","100%").append("span").style("display","table-cell").style("text-align","center").style("vertical-align","middle").html(i.text)}}function Q(e,t){return e>t}function ee(e,t,i,n){return a=>{let r,l,d=a.sourceBox.swimlane.y+t.swimlanePadding,s=a.targetBox.swimlane.y+t.swimlanePadding,m=Q(d,s),c=a.sourceBox.x+2*a.sourceBox.dimension.width/3,x=a.targetBox.x+a.targetBox.dimension.width/3;o.Rm.debug(`rendering relation up=${m} for `,{sourceBox:a.sourceBox,targetBox:a.targetBox}),m?(r=d,l=s+a.targetBox.dimension.height):(r=d+a.sourceBox.dimension.height,l=s);let u=n.emRelationStroke??a.visual.stroke;e.append("path").attr("class","em-relation").attr("fill",a.visual.fill).attr("stroke",u).attr("stroke-width","1").attr("marker-end",`url(#${i})`).attr("d",`M${c} ${r} L${x} ${l}`)}}function et(e,t,i,n){return a=>{let r=e.append("g").attr("class","em-swimlane"),o=n.emSwimlaneBackgroundOdd??"rgb(250,250,250)",l=n.emSwimlaneBackgroundStroke??"rgb(240,240,240)";r.append("rect").attr("x",0).attr("y",a.y).attr("rx","3").attr("width",t+i.swimlanePadding).attr("height",a.height).attr("fill",o).attr("stroke",l),r.append("text").attr("font-weight",i.swimlaneTextFontWeight).attr("x",30).attr("y",a.y+30).text(a.label)}}(0,o.K2)(J,"renderD3Box"),(0,o.K2)(Q,"dirUpwards"),(0,o.K2)(ee,"renderD3Relation"),(0,o.K2)(et,"renderD3Swimlane");var ei={parser:Z,db:L,renderer:{draw:(0,o.K2)(function(e,t,i,n){if(o.Rm.debug("in eventmodeling renderer",e+"\n","id:",t,i),!q)throw Error("EventModeling config not found");let a=n.db,{themeVariables:l,eventmodeling:s}=(0,r.D7)(),m=(0,d.Ltv)(`[id="${t}"]`),c=a.getDiagramProps(),x=a.getState(),u=`em-arrowhead-${t}`,f=l.emArrowhead??"#000000";x.sortedSwimlanesArray.forEach(et(m,x.maxR,c,l)),x.boxes.forEach(J(m,c)),x.relations.forEach(ee(m,c,u,l)),m.append("defs").append("marker").attr("id",u).attr("markerWidth","10").attr("markerHeight","7").attr("refX","10").attr("refY","3.5").attr("orient","auto").append("polygon").attr("points","0 0, 10 3.5, 0 7").attr("fill",f),(0,r.mj)(void 0,m,s?.padding??30,s?.useMaxWidth)},"draw")},styles:(0,o.K2)(e=>"","getStyles")}},7566:(e,t,i)=>{function n(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}i.d(t,{S:()=>n}),(0,i(316).K2)(n,"populateCommonDb")}}]);
_next/static/chunks/2619-3c9e02e22d10480a.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2619],{2296:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{DecodeError:function(){return h},MiddlewareNotFoundError:function(){return b},MissingStaticPage:function(){return m},NormalizeError:function(){return y},PageNotFoundError:function(){return g},SP:function(){return p},ST:function(){return d},WEB_VITALS:function(){return r},execOnce:function(){return n},getDisplayName:function(){return l},getLocationOrigin:function(){return a},getURL:function(){return i},isAbsoluteUrl:function(){return u},isResSent:function(){return f},loadGetInitialProps:function(){return s},normalizeRepeatedSlashes:function(){return c},stringifyError:function(){return P}});let r=["CLS","FCP","FID","INP","LCP","TTFB"];function n(e){let t,r=!1;return function(){for(var n=arguments.length,o=Array(n),u=0;u<n;u++)o[u]=arguments[u];return r||(r=!0,t=e(...o)),t}}let o=/^[a-zA-Z][a-zA-Z\d+\-.]*?:/,u=e=>o.test(e);function a(){let{protocol:e,hostname:t,port:r}=window.location;return e+"//"+t+(r?":"+r:"")}function i(){let{href:e}=window.location,t=a();return e.substring(t.length)}function l(e){return"string"==typeof e?e:e.displayName||e.name||"Unknown"}function f(e){return e.finished||e.headersSent}function c(e){let t=e.split("?");return t[0].replace(/\\/g,"/").replace(/\/\/+/g,"/")+(t[1]?"?"+t.slice(1).join("?"):"")}async function s(e,t){let r=t.res||t.ctx&&t.ctx.res;if(!e.getInitialProps)return t.ctx&&t.Component?{pageProps:await s(t.Component,t.ctx)}:{};let n=await e.getInitialProps(t);if(r&&f(r))return n;if(!n)throw Object.defineProperty(Error('"'+l(e)+'.getInitialProps()" should resolve to an object. But found "'+n+'" instead.'),"__NEXT_ERROR_CODE",{value:"E394",enumerable:!1,configurable:!0});return n}let p="undefined"!=typeof performance,d=p&&["mark","measure","getEntriesByName"].every(e=>"function"==typeof performance[e]);class h extends Error{}class y extends Error{}class g extends Error{constructor(e){super(),this.code="ENOENT",this.name="PageNotFoundError",this.message="Cannot find module for page: "+e}}class m extends Error{constructor(e,t){super(),this.message="Failed to load static file for page: "+e+" "+t}}class b extends Error{constructor(){super(),this.code="ENOENT",this.message="Cannot find the middleware module"}}function P(e){return JSON.stringify({message:e.message,stack:e.stack})}},2619:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{default:function(){return g},useLinkStatus:function(){return b}});let n=r(9417),o=r(5155),u=n._(r(2115)),a=r(7670),i=r(6752),l=r(3011),f=r(2296),c=r(6058);r(4781);let s=r(3499),p=r(8607),d=r(1807);r(7045);let h=r(6048);function y(e){return"string"==typeof e?e:(0,a.formatUrl)(e)}function g(e){var t;let r,n,a,[g,b]=(0,u.useOptimistic)(s.IDLE_LINK_STATUS),P=(0,u.useRef)(null),{href:_,as:v,children:E,prefetch:O=null,passHref:j,replace:S,shallow:C,scroll:N,onClick:T,onMouseEnter:x,onTouchStart:A,legacyBehavior:M=!1,onNavigate:R,ref:L,unstable_dynamicOnHover:k,...I}=e;r=E,M&&("string"==typeof r||"number"==typeof r)&&(r=(0,o.jsx)("a",{children:r}));let U=u.default.useContext(i.AppRouterContext),w=!1!==O,F=!1!==O?null===(t=O)||"auto"===t?h.FetchStrategy.PPR:h.FetchStrategy.Full:h.FetchStrategy.PPR,{href:D,as:K}=u.default.useMemo(()=>{let e=y(_);return{href:e,as:v?y(v):e}},[_,v]);M&&(n=u.default.Children.only(r));let B=M?n&&"object"==typeof n&&n.ref:L,z=u.default.useCallback(e=>(null!==U&&(P.current=(0,s.mountLinkInstance)(e,D,U,F,w,b)),()=>{P.current&&((0,s.unmountLinkForCurrentNavigation)(P.current),P.current=null),(0,s.unmountPrefetchableInstance)(e)}),[w,D,U,F,b]),Q={ref:(0,l.useMergedRef)(z,B),onClick(e){M||"function"!=typeof T||T(e),M&&n.props&&"function"==typeof n.props.onClick&&n.props.onClick(e),U&&(e.defaultPrevented||function(e,t,r,n,o,a,i){let{nodeName:l}=e.currentTarget;if(!("A"===l.toUpperCase()&&function(e){let t=e.currentTarget.getAttribute("target");return t&&"_self"!==t||e.metaKey||e.ctrlKey||e.shiftKey||e.altKey||e.nativeEvent&&2===e.nativeEvent.which}(e)||e.currentTarget.hasAttribute("download"))){if(!(0,p.isLocalURL)(t)){o&&(e.preventDefault(),location.replace(t));return}if(e.preventDefault(),i){let e=!1;if(i({preventDefault:()=>{e=!0}}),e)return}u.default.startTransition(()=>{(0,d.dispatchNavigateAction)(r||t,o?"replace":"push",null==a||a,n.current)})}}(e,D,K,P,S,N,R))},onMouseEnter(e){M||"function"!=typeof x||x(e),M&&n.props&&"function"==typeof n.props.onMouseEnter&&n.props.onMouseEnter(e),U&&w&&(0,s.onNavigationIntent)(e.currentTarget,!0===k)},onTouchStart:function(e){M||"function"!=typeof A||A(e),M&&n.props&&"function"==typeof n.props.onTouchStart&&n.props.onTouchStart(e),U&&w&&(0,s.onNavigationIntent)(e.currentTarget,!0===k)}};return(0,f.isAbsoluteUrl)(K)?Q.href=K:M&&!j&&("a"!==n.type||"href"in n.props)||(Q.href=(0,c.addBasePath)(K)),a=M?u.default.cloneElement(n,Q):(0,o.jsx)("a",{...I,...Q,children:r}),(0,o.jsx)(m.Provider,{value:g,children:a})}let m=(0,u.createContext)(s.IDLE_LINK_STATUS),b=()=>(0,u.useContext)(m);("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},3011:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"useMergedRef",{enumerable:!0,get:function(){return o}});let n=r(2115);function o(e,t){let r=(0,n.useRef)(null),o=(0,n.useRef)(null);return(0,n.useCallback)(n=>{if(null===n){let e=r.current;e&&(r.current=null,e());let t=o.current;t&&(o.current=null,t())}else e&&(r.current=u(e,n)),t&&(o.current=u(t,n))},[e,t])}function u(e,t){if("function"!=typeof e)return e.current=t,()=>{e.current=null};{let r=e(t);return"function"==typeof r?r:()=>e(null)}}("function"==typeof t.default||"object"==typeof t.default&&null!==t.default)&&void 0===t.default.__esModule&&(Object.defineProperty(t.default,"__esModule",{value:!0}),Object.assign(t.default,t),e.exports=t.default)},3078:(e,t)=>{function r(e){let t={};for(let[r,n]of e.entries()){let e=t[r];void 0===e?t[r]=n:Array.isArray(e)?e.push(n):t[r]=[e,n]}return t}function n(e){return"string"==typeof e?e:("number"!=typeof e||isNaN(e))&&"boolean"!=typeof e?"":String(e)}function o(e){let t=new URLSearchParams;for(let[r,o]of Object.entries(e))if(Array.isArray(o))for(let e of o)t.append(r,n(e));else t.set(r,n(o));return t}function u(e){for(var t=arguments.length,r=Array(t>1?t-1:0),n=1;n<t;n++)r[n-1]=arguments[n];for(let t of r){for(let r of t.keys())e.delete(r);for(let[r,n]of t.entries())e.append(r,n)}return e}Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{assign:function(){return u},searchParamsToUrlQuery:function(){return r},urlQueryToSearchParams:function(){return o}})},7045:(e,t)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"errorOnce",{enumerable:!0,get:function(){return r}});let r=e=>{}},7670:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),!function(e,t){for(var r in t)Object.defineProperty(e,r,{enumerable:!0,get:t[r]})}(t,{formatUrl:function(){return u},formatWithValidation:function(){return i},urlObjectKeys:function(){return a}});let n=r(9417)._(r(3078)),o=/https?|ftp|gopher|file/;function u(e){let{auth:t,hostname:r}=e,u=e.protocol||"",a=e.pathname||"",i=e.hash||"",l=e.query||"",f=!1;t=t?encodeURIComponent(t).replace(/%3A/i,":")+"@":"",e.host?f=t+e.host:r&&(f=t+(~r.indexOf(":")?"["+r+"]":r),e.port&&(f+=":"+e.port)),l&&"object"==typeof l&&(l=String(n.urlQueryToSearchParams(l)));let c=e.search||l&&"?"+l||"";return u&&!u.endsWith(":")&&(u+=":"),e.slashes||(!u||o.test(u))&&!1!==f?(f="//"+(f||""),a&&"/"!==a[0]&&(a="/"+a)):f||(f=""),i&&"#"!==i[0]&&(i="#"+i),c&&"?"!==c[0]&&(c="?"+c),""+u+f+(a=a.replace(/[?#]/g,encodeURIComponent))+(c=c.replace("#","%23"))+i}let a=["auth","hash","host","hostname","href","path","pathname","port","protocol","query","search","slashes"];function i(e){return u(e)}},8607:(e,t,r)=>{Object.defineProperty(t,"__esModule",{value:!0}),Object.defineProperty(t,"isLocalURL",{enumerable:!0,get:function(){return u}});let n=r(2296),o=r(2929);function u(e){if(!(0,n.isAbsoluteUrl)(e))return!0;try{let t=(0,n.getLocationOrigin)(),r=new URL(e,t);return r.origin===t&&(0,o.hasBasePath)(r.pathname)}catch(e){return!1}}}}]);
_next/static/chunks/2796.74619ac320f56d15.js ADDED
@@ -0,0 +1,29 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2796],{2796:(e,t,a)=>{a.d(t,{diagram:()=>b});var i=a(2667),l=a(7566),r=a(3736),s=a(669),n=a(316),o=a(4290),c=a(5508),p=s.UI.pie,d={sections:new Map,showData:!1,config:p},u=d.sections,g=d.showData,h=structuredClone(p),f=(0,n.K2)(()=>structuredClone(h),"getConfig"),m=(0,n.K2)(()=>{u=new Map,g=d.showData,(0,s.IU)()},"clear"),x=(0,n.K2)(({label:e,value:t})=>{if(t<0)throw Error(`"${e}" has invalid value: ${t}. Negative values are not allowed in pie charts. All slice values must be >= 0.`);u.has(e)||(u.set(e,t),n.Rm.debug(`added new section: ${e}, with value: ${t}`))},"addSection"),w=(0,n.K2)(()=>u,"getSections"),S=(0,n.K2)(e=>{g=e},"setShowData"),$=(0,n.K2)(()=>g,"getShowData"),D={getConfig:f,clear:m,setDiagramTitle:s.ke,getDiagramTitle:s.ab,setAccTitle:s.SV,getAccTitle:s.iN,setAccDescription:s.EI,getAccDescription:s.m7,addSection:x,getSections:w,setShowData:S,getShowData:$},T=(0,n.K2)((e,t)=>{(0,l.S)(e,t),t.setShowData(e.showData),e.sections.map(t.addSection)},"populateDb"),y={parse:(0,n.K2)(async e=>{let t=await (0,o.qg)("pie",e);n.Rm.debug(t),T(t,D)},"parse")},C=(0,n.K2)(e=>`
2
+ .pieCircle{
3
+ stroke: ${e.pieStrokeColor};
4
+ stroke-width : ${e.pieStrokeWidth};
5
+ opacity : ${e.pieOpacity};
6
+ }
7
+ .pieOuterCircle{
8
+ stroke: ${e.pieOuterStrokeColor};
9
+ stroke-width: ${e.pieOuterStrokeWidth};
10
+ fill: none;
11
+ }
12
+ .pieTitleText {
13
+ text-anchor: middle;
14
+ font-size: ${e.pieTitleTextSize};
15
+ fill: ${e.pieTitleTextColor};
16
+ font-family: ${e.fontFamily};
17
+ }
18
+ .slice {
19
+ font-family: ${e.fontFamily};
20
+ fill: ${e.pieSectionTextColor};
21
+ font-size:${e.pieSectionTextSize};
22
+ // fill: white;
23
+ }
24
+ .legend text {
25
+ fill: ${e.pieLegendTextColor};
26
+ font-family: ${e.fontFamily};
27
+ font-size: ${e.pieLegendTextSize};
28
+ }
29
+ `,"getStyles"),k=(0,n.K2)(e=>{let t=[...e.values()].reduce((e,t)=>e+t,0),a=[...e.entries()].map(([e,t])=>({label:e,value:t})).filter(e=>e.value/t*100>=1);return(0,c.rLf)().value(e=>e.value).sort(null)(a)},"createPieArcs"),b={parser:y,db:D,renderer:{draw:(0,n.K2)((e,t,a,l)=>{n.Rm.debug("rendering pie chart\n"+e);let o=l.db,p=(0,s.D7)(),d=(0,r.$t)(o.getConfig(),p.pie),u=(0,i.D)(t),g=u.append("g");g.attr("transform","translate(225,225)");let{themeVariables:h}=p,[f]=(0,r.I5)(h.pieOuterStrokeWidth);f??=2;let m=d.textPosition,x=(0,c.JLW)().innerRadius(0).outerRadius(185),w=(0,c.JLW)().innerRadius(185*m).outerRadius(185*m);g.append("circle").attr("cx",0).attr("cy",0).attr("r",185+f/2).attr("class","pieOuterCircle");let S=o.getSections(),$=k(S),D=[h.pie1,h.pie2,h.pie3,h.pie4,h.pie5,h.pie6,h.pie7,h.pie8,h.pie9,h.pie10,h.pie11,h.pie12],T=0;S.forEach(e=>{T+=e});let y=$.filter(e=>"0"!==(e.data.value/T*100).toFixed(0)),C=(0,c.UMr)(D).domain([...S.keys()]);g.selectAll("mySlices").data(y).enter().append("path").attr("d",x).attr("fill",e=>C(e.data.label)).attr("class","pieCircle"),g.selectAll("mySlices").data(y).enter().append("text").text(e=>(e.data.value/T*100).toFixed(0)+"%").attr("transform",e=>"translate("+w.centroid(e)+")").style("text-anchor","middle").attr("class","slice");let b=g.append("text").text(o.getDiagramTitle()).attr("x",0).attr("y",-200).attr("class","pieTitleText"),v=[...S.entries()].map(([e,t])=>({label:e,value:t})),A=g.selectAll(".legend").data(v).enter().append("g").attr("class","legend").attr("transform",(e,t)=>"translate(216,"+(22*t-22*v.length/2)+")");A.append("rect").attr("width",18).attr("height",18).style("fill",e=>C(e.label)).style("stroke",e=>C(e.label)),A.append("text").attr("x",22).attr("y",14).text(e=>o.getShowData()?`${e.label} [${e.value}]`:e.label);let K=Math.max(...A.selectAll("text").nodes().map(e=>e?.getBoundingClientRect().width??0)),R=b.node()?.getBoundingClientRect().width??0,M=Math.min(0,225-R/2),z=Math.max(512+K,225+R/2)-M;u.attr("viewBox",`${M} 0 ${z} 450`),(0,s.a$)(u,450,z,d.useMaxWidth)},"draw")},styles:C}},7566:(e,t,a)=>{function i(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}a.d(t,{S:()=>i}),(0,a(316).K2)(i,"populateCommonDb")}}]);
_next/static/chunks/2918becc.5ded705da9835bd2.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/3384.6a7edf5cc56172fd.js ADDED
@@ -0,0 +1,226 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3384],{1184:(t,e,s)=>{s.d(e,{A:()=>n});var i=s(316),r=s(5508),n=(0,i.K2)((t,e)=>{let s;return"sandbox"===e&&(s=(0,r.Ltv)("#i"+t)),("sandbox"===e?(0,r.Ltv)(s.nodes()[0].contentDocument.body):(0,r.Ltv)("body")).select(`[id="${t}"]`)},"getDiagramElement")},2888:(t,e,s)=>{s.d(e,{P:()=>n});var i=s(669),r=s(316),n=(0,r.K2)((t,e,s,n)=>{t.attr("class",s);let{width:l,height:c,x:h,y:d}=a(t,e);(0,i.a$)(t,c,l,n);let u=o(h,d,l,c,e);t.attr("viewBox",u),r.Rm.debug(`viewBox configured: ${u} with padding: ${e}`)},"setupViewPortForSVG"),a=(0,r.K2)((t,e)=>{let s=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:s.width+2*e,height:s.height+2*e,x:s.x,y:s.y}},"calculateDimensionsWithPadding"),o=(0,r.K2)((t,e,s,i,r)=>`${t-r} ${e-r} ${s} ${i}`,"createViewBox")},3384:(t,e,s)=>{s.d(e,{Zk:()=>h,q7:()=>Y,tM:()=>tt,u4:()=>Q});var i=s(1184),r=s(2888),n=s(1593),a=s(3736),o=s(669),l=s(316),c=function(){var t=(0,l.K2)(function(t,e,s,i){for(s=s||{},i=t.length;i--;s[t[i]]=e);return s},"o"),e=[1,2],s=[1,3],i=[1,4],r=[2,4],n=[1,9],a=[1,11],o=[1,16],c=[1,17],h=[1,18],d=[1,19],u=[1,33],p=[1,20],y=[1,21],g=[1,22],m=[1,23],f=[1,24],S=[1,26],_=[1,27],T=[1,28],k=[1,29],b=[1,30],E=[1,31],D=[1,32],$=[1,35],x=[1,36],C=[1,37],L=[1,38],I=[1,34],A=[1,4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],v=[1,4,5,14,15,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,39,40,41,45,48,51,52,53,54,57],R=[4,5,16,17,19,21,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],w={trace:(0,l.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,SPACE:4,NL:5,SD:6,document:7,line:8,statement:9,classDefStatement:10,styleStatement:11,cssClassStatement:12,idStatement:13,DESCR:14,"--\x3e":15,HIDE_EMPTY:16,scale:17,WIDTH:18,COMPOSIT_STATE:19,STRUCT_START:20,STRUCT_STOP:21,STATE_DESCR:22,AS:23,ID:24,FORK:25,JOIN:26,CHOICE:27,CONCURRENT:28,note:29,notePosition:30,NOTE_TEXT:31,direction:32,acc_title:33,acc_title_value:34,acc_descr:35,acc_descr_value:36,acc_descr_multiline_value:37,CLICK:38,STRING:39,HREF:40,classDef:41,CLASSDEF_ID:42,CLASSDEF_STYLEOPTS:43,DEFAULT:44,style:45,STYLE_IDS:46,STYLEDEF_STYLEOPTS:47,class:48,CLASSENTITY_IDS:49,STYLECLASS:50,direction_tb:51,direction_bt:52,direction_rl:53,direction_lr:54,eol:55,";":56,EDGE_STATE:57,STYLE_SEPARATOR:58,left_of:59,right_of:60,$accept:0,$end:1},terminals_:{2:"error",4:"SPACE",5:"NL",6:"SD",14:"DESCR",15:"--\x3e",16:"HIDE_EMPTY",17:"scale",18:"WIDTH",19:"COMPOSIT_STATE",20:"STRUCT_START",21:"STRUCT_STOP",22:"STATE_DESCR",23:"AS",24:"ID",25:"FORK",26:"JOIN",27:"CHOICE",28:"CONCURRENT",29:"note",31:"NOTE_TEXT",33:"acc_title",34:"acc_title_value",35:"acc_descr",36:"acc_descr_value",37:"acc_descr_multiline_value",38:"CLICK",39:"STRING",40:"HREF",41:"classDef",42:"CLASSDEF_ID",43:"CLASSDEF_STYLEOPTS",44:"DEFAULT",45:"style",46:"STYLE_IDS",47:"STYLEDEF_STYLEOPTS",48:"class",49:"CLASSENTITY_IDS",50:"STYLECLASS",51:"direction_tb",52:"direction_bt",53:"direction_rl",54:"direction_lr",56:";",57:"EDGE_STATE",58:"STYLE_SEPARATOR",59:"left_of",60:"right_of"},productions_:[0,[3,2],[3,2],[3,2],[7,0],[7,2],[8,2],[8,1],[8,1],[9,1],[9,1],[9,1],[9,1],[9,2],[9,3],[9,4],[9,1],[9,2],[9,1],[9,4],[9,3],[9,6],[9,1],[9,1],[9,1],[9,1],[9,4],[9,4],[9,1],[9,2],[9,2],[9,1],[9,5],[9,5],[10,3],[10,3],[11,3],[12,3],[32,1],[32,1],[32,1],[32,1],[55,1],[55,1],[13,1],[13,1],[13,3],[13,3],[30,1],[30,1]],performAction:(0,l.K2)(function(t,e,s,i,r,n,a){var o=n.length-1;switch(r){case 3:return i.setRootDoc(n[o]),n[o];case 4:this.$=[];break;case 5:"nl"!=n[o]&&(n[o-1].push(n[o]),this.$=n[o-1]);break;case 6:case 7:case 12:this.$=n[o];break;case 8:this.$="nl";break;case 13:let l=n[o-1];l.description=i.trimColon(n[o]),this.$=l;break;case 14:this.$={stmt:"relation",state1:n[o-2],state2:n[o]};break;case 15:let c=i.trimColon(n[o]);this.$={stmt:"relation",state1:n[o-3],state2:n[o-1],description:c};break;case 19:this.$={stmt:"state",id:n[o-3],type:"default",description:"",doc:n[o-1]};break;case 20:var h=n[o],d=n[o-2].trim();if(n[o].match(":")){var u=n[o].split(":");h=u[0],d=[d,u[1]]}this.$={stmt:"state",id:h,type:"default",description:d};break;case 21:this.$={stmt:"state",id:n[o-3],type:"default",description:n[o-5],doc:n[o-1]};break;case 22:this.$={stmt:"state",id:n[o],type:"fork"};break;case 23:this.$={stmt:"state",id:n[o],type:"join"};break;case 24:this.$={stmt:"state",id:n[o],type:"choice"};break;case 25:this.$={stmt:"state",id:i.getDividerId(),type:"divider"};break;case 26:this.$={stmt:"state",id:n[o-1].trim(),note:{position:n[o-2].trim(),text:n[o].trim()}};break;case 29:this.$=n[o].trim(),i.setAccTitle(this.$);break;case 30:case 31:this.$=n[o].trim(),i.setAccDescription(this.$);break;case 32:this.$={stmt:"click",id:n[o-3],url:n[o-2],tooltip:n[o-1]};break;case 33:this.$={stmt:"click",id:n[o-3],url:n[o-1],tooltip:""};break;case 34:case 35:this.$={stmt:"classDef",id:n[o-1].trim(),classes:n[o].trim()};break;case 36:this.$={stmt:"style",id:n[o-1].trim(),styleClass:n[o].trim()};break;case 37:this.$={stmt:"applyClass",id:n[o-1].trim(),styleClass:n[o].trim()};break;case 38:i.setDirection("TB"),this.$={stmt:"dir",value:"TB"};break;case 39:i.setDirection("BT"),this.$={stmt:"dir",value:"BT"};break;case 40:i.setDirection("RL"),this.$={stmt:"dir",value:"RL"};break;case 41:i.setDirection("LR"),this.$={stmt:"dir",value:"LR"};break;case 44:case 45:this.$={stmt:"state",id:n[o].trim(),type:"default",description:""};break;case 46:case 47:this.$={stmt:"state",id:n[o-2].trim(),classes:[n[o].trim()],type:"default",description:""}}},"anonymous"),table:[{3:1,4:e,5:s,6:i},{1:[3]},{3:5,4:e,5:s,6:i},{3:6,4:e,5:s,6:i},t([1,4,5,16,17,19,22,24,25,26,27,28,29,33,35,37,38,41,45,48,51,52,53,54,57],r,{7:7}),{1:[2,1]},{1:[2,2]},{1:[2,3],4:n,5:a,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:c,19:h,22:d,24:u,25:p,26:y,27:g,28:m,29:f,32:25,33:S,35:_,37:T,38:k,41:b,45:E,48:D,51:$,52:x,53:C,54:L,57:I},t(A,[2,5]),{9:39,10:12,11:13,12:14,13:15,16:o,17:c,19:h,22:d,24:u,25:p,26:y,27:g,28:m,29:f,32:25,33:S,35:_,37:T,38:k,41:b,45:E,48:D,51:$,52:x,53:C,54:L,57:I},t(A,[2,7]),t(A,[2,8]),t(A,[2,9]),t(A,[2,10]),t(A,[2,11]),t(A,[2,12],{14:[1,40],15:[1,41]}),t(A,[2,16]),{18:[1,42]},t(A,[2,18],{20:[1,43]}),{23:[1,44]},t(A,[2,22]),t(A,[2,23]),t(A,[2,24]),t(A,[2,25]),{30:45,31:[1,46],59:[1,47],60:[1,48]},t(A,[2,28]),{34:[1,49]},{36:[1,50]},t(A,[2,31]),{13:51,24:u,57:I},{42:[1,52],44:[1,53]},{46:[1,54]},{49:[1,55]},t(v,[2,44],{58:[1,56]}),t(v,[2,45],{58:[1,57]}),t(A,[2,38]),t(A,[2,39]),t(A,[2,40]),t(A,[2,41]),t(A,[2,6]),t(A,[2,13]),{13:58,24:u,57:I},t(A,[2,17]),t(R,r,{7:59}),{24:[1,60]},{24:[1,61]},{23:[1,62]},{24:[2,48]},{24:[2,49]},t(A,[2,29]),t(A,[2,30]),{39:[1,63],40:[1,64]},{43:[1,65]},{43:[1,66]},{47:[1,67]},{50:[1,68]},{24:[1,69]},{24:[1,70]},t(A,[2,14],{14:[1,71]}),{4:n,5:a,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:c,19:h,21:[1,72],22:d,24:u,25:p,26:y,27:g,28:m,29:f,32:25,33:S,35:_,37:T,38:k,41:b,45:E,48:D,51:$,52:x,53:C,54:L,57:I},t(A,[2,20],{20:[1,73]}),{31:[1,74]},{24:[1,75]},{39:[1,76]},{39:[1,77]},t(A,[2,34]),t(A,[2,35]),t(A,[2,36]),t(A,[2,37]),t(v,[2,46]),t(v,[2,47]),t(A,[2,15]),t(A,[2,19]),t(R,r,{7:78}),t(A,[2,26]),t(A,[2,27]),{5:[1,79]},{5:[1,80]},{4:n,5:a,8:8,9:10,10:12,11:13,12:14,13:15,16:o,17:c,19:h,21:[1,81],22:d,24:u,25:p,26:y,27:g,28:m,29:f,32:25,33:S,35:_,37:T,38:k,41:b,45:E,48:D,51:$,52:x,53:C,54:L,57:I},t(A,[2,32]),t(A,[2,33]),t(A,[2,21])],defaultActions:{5:[2,1],6:[2,2],47:[2,48],48:[2,49]},parseError:(0,l.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var s=Error(t);throw s.hash=e,s}},"parseError"),parse:(0,l.K2)(function(t){var e=this,s=[0],i=[],r=[null],n=[],a=this.table,o="",c=0,h=0,d=0,u=n.slice.call(arguments,1),p=Object.create(this.lexer),y={};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(y[g]=this.yy[g]);p.setInput(t,y),y.lexer=p,y.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;n.push(m);var f=p.options&&p.options.ranges;function S(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof y.parseError?this.parseError=y.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,l.K2)(function(t){s.length=s.length-2*t,r.length=r.length-t,n.length=n.length-t},"popStack"),(0,l.K2)(S,"lex");for(var _,T,k,b,E,D,$,x,C,L={};;){if(k=s[s.length-1],this.defaultActions[k]?b=this.defaultActions[k]:(null==_&&(_=S()),b=a[k]&&a[k][_]),void 0===b||!b.length||!b[0]){var I="";for(D in C=[],a[k])this.terminals_[D]&&D>2&&C.push("'"+this.terminals_[D]+"'");I=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+C.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==_?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(I,{text:p.match,token:this.terminals_[_]||_,line:p.yylineno,loc:m,expected:C})}if(b[0]instanceof Array&&b.length>1)throw Error("Parse Error: multiple actions possible at state: "+k+", token: "+_);switch(b[0]){case 1:s.push(_),r.push(p.yytext),n.push(p.yylloc),s.push(b[1]),_=null,T?(_=T,T=null):(h=p.yyleng,o=p.yytext,c=p.yylineno,m=p.yylloc,d>0&&d--);break;case 2:if($=this.productions_[b[1]][1],L.$=r[r.length-$],L._$={first_line:n[n.length-($||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-($||1)].first_column,last_column:n[n.length-1].last_column},f&&(L._$.range=[n[n.length-($||1)].range[0],n[n.length-1].range[1]]),void 0!==(E=this.performAction.apply(L,[o,h,c,y,b[1],r,n].concat(u))))return E;$&&(s=s.slice(0,-1*$*2),r=r.slice(0,-1*$),n=n.slice(0,-1*$)),s.push(this.productions_[b[1]][0]),r.push(L.$),n.push(L._$),x=a[s[s.length-2]][s[s.length-1]],s.push(x);break;case 3:return!0}}return!0},"parse")};function N(){this.yy={}}return w.lexer={EOF:1,parseError:(0,l.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,l.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,l.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,l.K2)(function(t){var e=t.length,s=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),s.length-1&&(this.yylineno-=s.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:s?(s.length===i.length?this.yylloc.first_column:0)+i[i.length-s.length].length-s[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,l.K2)(function(){return this._more=!0,this},"more"),reject:(0,l.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,l.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,l.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,l.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,l.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,l.K2)(function(t,e){var s,i,r;if(this.options.backtrack_lexer&&(r={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&&(r.yylloc.range=this.yylloc.range.slice(0))),(i=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],s=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s)return s;if(this._backtrack)for(var n in r)this[n]=r[n];return!1},"test_match"),next:(0,l.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,s,i,r=this._currentRules(),n=0;n<r.length;n++)if((s=this._input.match(this.rules[r[n]]))&&(!e||s[0].length>e[0].length)){if(e=s,i=n,this.options.backtrack_lexer){if(!1!==(t=this.test_match(s,r[n])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,r[i]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,l.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,l.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,l.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,l.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,l.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,l.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,l.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,l.K2)(function(t,e,s,i){function r(){let s=e.yytext.indexOf("%%");if(0===s)return!1;if(s>0){let i=e.yytext.slice(0,s),r=e.yytext.slice(s);r&&t.lexer.unput(r),e.yytext=i}return!0}switch((0,l.K2)(r,"processId"),s){case 0:return 38;case 1:return 40;case 2:return 39;case 3:return 44;case 4:case 43:return 51;case 5:case 44:return 52;case 6:case 45:return 53;case 7:case 46:return 54;case 8:case 77:return 5;case 9:case 10:case 11:case 12:case 56:case 62:break;case 13:case 33:return this.pushState("SCALE"),17;case 14:case 34:return 18;case 15:case 21:case 35:case 50:case 53:this.popState();break;case 16:return this.begin("acc_title"),33;case 17:return this.popState(),"acc_title_value";case 18:return this.begin("acc_descr"),35;case 19:return this.popState(),"acc_descr_value";case 20:this.begin("acc_descr_multiline");break;case 22:return"acc_descr_multiline_value";case 23:return this.pushState("CLASSDEF"),41;case 24:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 25:return this.popState(),this.pushState("CLASSDEFID"),42;case 26:return this.popState(),43;case 27:return this.pushState("CLASS"),48;case 28:return this.popState(),this.pushState("CLASS_STYLE"),49;case 29:return this.popState(),50;case 30:return this.pushState("STYLE"),45;case 31:return this.popState(),this.pushState("STYLEDEF_STYLES"),46;case 32:return this.popState(),47;case 36:this.pushState("STATE");break;case 37:case 40:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),25;case 38:case 41:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),26;case 39:case 42:return this.popState(),e.yytext=e.yytext.slice(0,-10).trim(),27;case 47:this.pushState("STATE_STRING");break;case 48:return this.pushState("STATE_ID"),"AS";case 49:case 64:if(!r())return;return this.popState(),"ID";case 51:return"STATE_DESCR";case 52:return 19;case 54:return this.popState(),this.pushState("struct"),20;case 55:return this.popState(),21;case 57:return this.begin("NOTE"),29;case 58:return this.popState(),this.pushState("NOTE_ID"),59;case 59:return this.popState(),this.pushState("NOTE_ID"),60;case 60:this.popState(),this.pushState("FLOATING_NOTE");break;case 61:return this.popState(),this.pushState("FLOATING_NOTE_ID"),"AS";case 63:return"NOTE_TEXT";case 65:if(!r())return;return this.popState(),this.pushState("NOTE_TEXT"),24;case 66:return this.popState(),e.yytext=e.yytext.substr(2).trim(),31;case 67:return this.popState(),e.yytext=e.yytext.slice(0,-8).trim(),31;case 68:case 69:return 6;case 70:return 16;case 71:return 57;case 72:if(!r())return;return 24;case 73:return e.yytext=e.yytext.trim(),14;case 74:return 15;case 75:return 28;case 76:return 58;case 78:return"INVALID"}},"anonymous"),rules:[/^(?:click\b)/i,/^(?:href\b)/i,/^(?:"[^"]*")/i,/^(?:default\b)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:((?!\n)\s)+)/i,/^(?:#[^\n]*)/i,/^(?:%%(?!\{)[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:classDef\s+)/i,/^(?:DEFAULT\s+)/i,/^(?:\w+\s+)/i,/^(?:[^\n]*)/i,/^(?:class\s+)/i,/^(?:(\w+)+((,\s*\w+)*))/i,/^(?:[^\n]*)/i,/^(?:style\s+)/i,/^(?:[\w,]+\s+)/i,/^(?:[^\n]*)/i,/^(?:scale\s+)/i,/^(?:\d+)/i,/^(?:\s+width\b)/i,/^(?:state\s+)/i,/^(?:.*<<fork>>)/i,/^(?:.*<<join>>)/i,/^(?:.*<<choice>>)/i,/^(?:.*\[\[fork\]\])/i,/^(?:.*\[\[join\]\])/i,/^(?:.*\[\[choice\]\])/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:["])/i,/^(?:\s*as\s+)/i,/^(?:[^\n\{]*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n\s\{]+)/i,/^(?:\n)/i,/^(?:\{)/i,/^(?:\})/i,/^(?:[\n])/i,/^(?:note\s+)/i,/^(?:left of\b)/i,/^(?:right of\b)/i,/^(?:")/i,/^(?:\s*as\s*)/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[^\n]*)/i,/^(?:\s*[^:\n\s\-]+)/i,/^(?:\s*:[^:\n;]+)/i,/^(?:[\s\S]*?\n\s*end note\b)/i,/^(?:stateDiagram\s+)/i,/^(?:stateDiagram-v2\s+)/i,/^(?:hide empty description\b)/i,/^(?:\[\*\])/i,/^(?:[^:\n\s\-\{]+)/i,/^(?:\s*:(?:[^:\n;]|:[^:\n;])+)/i,/^(?:-->)/i,/^(?:--)/i,/^(?::::)/i,/^(?:$)/i,/^(?:.)/i],conditions:{LINE:{rules:[10,11,12],inclusive:!1},struct:{rules:[10,11,12,23,27,30,36,43,44,45,46,55,56,57,71,72,73,74,75,76],inclusive:!1},FLOATING_NOTE_ID:{rules:[64],inclusive:!1},FLOATING_NOTE:{rules:[61,62,63],inclusive:!1},NOTE_TEXT:{rules:[66,67],inclusive:!1},NOTE_ID:{rules:[65],inclusive:!1},NOTE:{rules:[58,59,60],inclusive:!1},STYLEDEF_STYLEOPTS:{rules:[],inclusive:!1},STYLEDEF_STYLES:{rules:[32],inclusive:!1},STYLE_IDS:{rules:[],inclusive:!1},STYLE:{rules:[31],inclusive:!1},CLASS_STYLE:{rules:[29],inclusive:!1},CLASS:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[26],inclusive:!1},CLASSDEF:{rules:[24,25],inclusive:!1},acc_descr_multiline:{rules:[21,22],inclusive:!1},acc_descr:{rules:[19],inclusive:!1},acc_title:{rules:[17],inclusive:!1},SCALE:{rules:[14,15,34,35],inclusive:!1},ALIAS:{rules:[],inclusive:!1},STATE_ID:{rules:[49],inclusive:!1},STATE_STRING:{rules:[50,51],inclusive:!1},FORK_STATE:{rules:[],inclusive:!1},STATE:{rules:[10,11,12,37,38,39,40,41,42,47,48,52,53,54],inclusive:!1},ID:{rules:[10,11,12],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,12,13,16,18,20,23,27,30,33,36,54,57,68,69,70,71,72,73,74,76,77,78],inclusive:!0}}},(0,l.K2)(N,"Parser"),N.prototype=w,w.Parser=N,new N}();c.parser=c;var h=c,d="TB",u="state",p="root",y="relation",g="default",m="divider",f="fill:none",S="fill: #333",_="markdown",T="normal",k="rect",b="rectWithTitle",E="divider",D="roundedWithTitle",$="statediagram",x=`${$}-state`,C="transition",L=`${C} note-edge`,I=`${$}-note`,A=`${$}-cluster`,v=`${$}-cluster-alt`,R="parent",w="note",N="----",O=`${N}${w}`,K=`${N}${R}`,B=(0,l.K2)((t,e=d)=>{if(!t.doc)return e;let s=e;for(let e of t.doc)"dir"===e.stmt&&(s=e.value);return s},"getDir"),Y={getClasses:(0,l.K2)(function(t,e){return e.db.getClasses()},"getClasses"),draw:(0,l.K2)(async function(t,e,s,c){l.Rm.info("REF0:"),l.Rm.info("Drawing state diagram (v2)",e);let{securityLevel:h,state:d,layout:u}=(0,o.D7)();c.db.extract(c.db.getRootDocV2());let p=c.db.getData(),y=(0,i.A)(e,h);p.type=c.type,p.layoutAlgorithm=u,p.nodeSpacing=d?.nodeSpacing||50,p.rankSpacing=d?.rankSpacing||50,"neo"===(0,o.D7)().look?p.markers=["barbNeo"]:p.markers=["barb"],p.diagramId=e,await (0,n.XX)(p,y);try{("function"==typeof c.db.getLinks?c.db.getLinks():new Map).forEach((t,e)=>{let s,i="string"==typeof e?e:"string"==typeof e?.id?e.id:"";if(!i)return void l.Rm.warn("⚠️ Invalid or missing stateId from key:",JSON.stringify(e));let r=y.node()?.querySelectorAll("g");if(r?.forEach(t=>{t.textContent?.trim()===i&&(s=t)}),!s)return void l.Rm.warn("⚠️ Could not find node matching text:",i);let n=s.parentNode;if(!n)return void l.Rm.warn("⚠️ Node has no parent, cannot wrap:",i);let a=document.createElementNS("http://www.w3.org/2000/svg","a"),o=t.url.replace(/^"+|"+$/g,"");if(a.setAttributeNS("http://www.w3.org/1999/xlink","xlink:href",o),a.setAttribute("target","_blank"),t.tooltip){let e=t.tooltip.replace(/^"+|"+$/g,"");a.setAttribute("title",e)}n.replaceChild(a,s),a.appendChild(s),l.Rm.info("\uD83D\uDD17 Wrapped node in <a> tag for:",i,t.url)})}catch(t){l.Rm.error("❌ Error injecting clickable links:",t)}a._K.insertTitle(y,"statediagramTitleText",d?.titleTopMargin??25,c.db.getDiagramTitle()),(0,r.P)(y,8,$,d?.useMaxWidth??!0)},"draw"),getDir:B},F=new Map,P=0;function G(t="",e=0,s="",i=N){let r=null!==s&&s.length>0?`${i}${s}`:"";return`state-${t}${r}-${e}`}(0,l.K2)(G,"stateDomId");var W=(0,l.K2)((t,e,s,i,r,n,a,c)=>{l.Rm.trace("items",e),e.forEach(e=>{switch(e.stmt){case u:case g:V(t,e,s,i,r,n,a,c);break;case y:{V(t,e.state1,s,i,r,n,a,c),V(t,e.state2,s,i,r,n,a,c);let l="neo"===a,h={id:"edge"+P,start:e.state1.id,end:e.state2.id,arrowhead:"normal",arrowTypeEnd:l?"arrow_barb_neo":"arrow_barb",style:f,labelStyle:"",label:o.Y2.sanitizeText(e.description??"",(0,o.D7)()),arrowheadStyle:S,labelpos:"c",labelType:_,thickness:T,classes:C,look:a};r.push(h),P++}}})},"setupDoc"),j=(0,l.K2)((t,e=d)=>{let s=e;if(t.doc)for(let e of t.doc)"dir"===e.stmt&&(s=e.value);return s},"getDir");function z(t,e,s){if(!e.id||"</join></fork>"===e.id||"</choice>"===e.id)return;e.cssClasses&&(Array.isArray(e.cssCompiledStyles)||(e.cssCompiledStyles=[]),e.cssClasses.split(" ").forEach(t=>{let i=s.get(t);i&&(e.cssCompiledStyles=[...e.cssCompiledStyles??[],...i.styles])}));let i=t.find(t=>t.id===e.id);i?Object.assign(i,e):t.push(e)}function M(t){return t?.classes?.join(" ")??""}function U(t){return t?.styles??[]}(0,l.K2)(z,"insertOrUpdateNode"),(0,l.K2)(M,"getClassesFromDbInfo"),(0,l.K2)(U,"getStylesFromDbInfo");var V=(0,l.K2)((t,e,s,i,r,n,a,c)=>{let h=e.id,d=s.get(h),u=M(d),p=U(d),y=(0,o.D7)();if(l.Rm.info("dataFetcher parsedItem",e,d,p),"root"!==h){let s=k;!0===e.start?s="stateStart":!1===e.start&&(s="stateEnd"),e.type!==g&&(s=e.type),F.get(h)||F.set(h,{id:h,shape:s,description:o.Y2.sanitizeText(h,y),cssClasses:`${u} ${x}`,cssStyles:p});let d=F.get(h);e.description&&(Array.isArray(d.description)?(d.shape=b,d.description.push(e.description)):d.description?.length&&d.description.length>0?(d.shape=b,d.description===h?d.description=[e.description]:d.description=[d.description,e.description]):(d.shape=k,d.description=e.description),d.description=o.Y2.sanitizeTextOrArray(d.description,y)),d.description?.length===1&&d.shape===b&&("group"===d.type?d.shape=D:d.shape=k),!d.type&&e.doc&&(l.Rm.info("Setting cluster for XCX",h,j(e)),d.type="group",d.isGroup=!0,d.dir=j(e),d.shape=e.type===m?E:D,d.cssClasses=`${d.cssClasses} ${A} ${n?v:""}`);let $={labelStyle:"",shape:d.shape,label:d.description,cssClasses:d.cssClasses,cssCompiledStyles:[],cssStyles:d.cssStyles,id:h,dir:d.dir,domId:G(h,P),type:d.type,isGroup:"group"===d.type,padding:8,rx:10,ry:10,look:a,labelType:"markdown"};if($.shape===E&&($.label=""),t&&"root"!==t.id&&(l.Rm.trace("Setting node ",h," to be child of its parent ",t.id),$.parentId=t.id),$.centerLabel=!0,e.note){let t={labelStyle:"",shape:"note",label:e.note.text,labelType:"markdown",cssClasses:I,cssStyles:[],cssCompiledStyles:[],id:h+O+"-"+P,domId:G(h,P,w),type:d.type,isGroup:"group"===d.type,padding:y.flowchart?.padding,look:a,position:e.note.position},s=h+K,n={labelStyle:"",shape:"noteGroup",label:e.note.text,cssClasses:d.cssClasses,cssStyles:[],id:h+K,domId:G(h,P,R),type:"group",isGroup:!0,padding:16,look:a,position:e.note.position};P++,n.id=s,t.parentId=s,z(i,n,c),z(i,t,c),z(i,$,c);let o=h,l=t.id;"left of"===e.note.position&&(o=t.id,l=h),r.push({id:o+"-"+l,start:o,end:l,arrowhead:"none",arrowTypeEnd:"",style:f,labelStyle:"",classes:L,arrowheadStyle:S,labelpos:"c",labelType:_,thickness:T,look:a})}else z(i,$,c)}e.doc&&(l.Rm.trace("Adding nodes children "),W(e,e.doc,s,i,r,!n,a,c))},"dataFetcher"),X=(0,l.K2)(()=>{F.clear(),P=0},"reset"),H={START_NODE:"[*]",START_TYPE:"start",END_NODE:"[*]",END_TYPE:"end",COLOR_KEYWORD:"color",FILL_KEYWORD:"fill",BG_FILL:"bgFill",STYLECLASS_SEP:","},J=(0,l.K2)(()=>new Map,"newClassesList"),q=(0,l.K2)(()=>({relations:[],states:new Map,documents:{}}),"newDoc"),Z=(0,l.K2)(t=>JSON.parse(JSON.stringify(t)),"clone"),Q=class{constructor(t){this.version=t,this.nodes=[],this.edges=[],this.rootDoc=[],this.classes=J(),this.documents={root:q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.dividerCnt=0,this.links=new Map,this.getAccTitle=o.iN,this.setAccTitle=o.SV,this.getAccDescription=o.m7,this.setAccDescription=o.EI,this.setDiagramTitle=o.ke,this.getDiagramTitle=o.ab,this.clear(),this.setRootDoc=this.setRootDoc.bind(this),this.getDividerId=this.getDividerId.bind(this),this.setDirection=this.setDirection.bind(this),this.trimColon=this.trimColon.bind(this)}static{(0,l.K2)(this,"StateDB")}static{this.relationType={AGGREGATION:0,EXTENSION:1,COMPOSITION:2,DEPENDENCY:3}}extract(t){for(let e of(this.clear(!0),Array.isArray(t)?t:t.doc))switch(e.stmt){case u:this.addState(e.id.trim(),e.type,e.doc,e.description,e.note);break;case y:this.addRelation(e.state1,e.state2,e.description);break;case"classDef":this.addStyleClass(e.id.trim(),e.classes);break;case"style":this.handleStyleDef(e);break;case"applyClass":this.setCssClass(e.id.trim(),e.styleClass);break;case"click":this.addLink(e.id,e.url,e.tooltip)}let e=this.getStates(),s=(0,o.D7)();for(let t of(X(),V(void 0,this.getRootDocV2(),e,this.nodes,this.edges,!0,s.look,this.classes),this.nodes))if(Array.isArray(t.label)){if(t.description=t.label.slice(1),t.isGroup&&t.description.length>0)throw Error(`Group nodes can only have label. Remove the additional description for node [${t.id}]`);t.label=t.label[0]}}handleStyleDef(t){let e=t.id.trim().split(","),s=t.styleClass.split(",");for(let t of e){let e=this.getState(t);if(!e){let s=t.trim();this.addState(s),e=this.getState(s)}e&&(e.styles=s.map(t=>t.replace(/;/g,"")?.trim()))}}setRootDoc(t){l.Rm.info("Setting root doc",t),this.rootDoc=t,1===this.version?this.extract(t):this.extract(this.getRootDocV2())}docTranslator(t,e,s){if(e.stmt===y){this.docTranslator(t,e.state1,!0),this.docTranslator(t,e.state2,!1);return}if(e.stmt===u&&(e.id===H.START_NODE?(e.id=t.id+(s?"_start":"_end"),e.start=s):e.id=e.id.trim()),e.stmt!==p&&e.stmt!==u||!e.doc)return;let i=[],r=[];for(let t of e.doc)if(t.type===m){let e=Z(t);e.doc=Z(r),i.push(e),r=[]}else r.push(t);if(i.length>0&&r.length>0){let t={stmt:u,id:(0,a.$C)(),type:"divider",doc:Z(r)};i.push(Z(t)),e.doc=i}e.doc.forEach(t=>this.docTranslator(e,t,!0))}getRootDocV2(){return this.docTranslator({id:p,stmt:p},{id:p,stmt:p,doc:this.rootDoc},!0),{id:p,doc:this.rootDoc}}addState(t,e=g,s,i,r,n,a,c){let h=t?.trim();if(this.currentDocument.states.has(h)){let t=this.currentDocument.states.get(h);if(!t)throw Error(`State not found: ${h}`);t.doc||(t.doc=s),t.type||(t.type=e)}else l.Rm.info("Adding state ",h,i),this.currentDocument.states.set(h,{stmt:u,id:h,descriptions:[],type:e,doc:s,note:r,classes:[],styles:[],textStyles:[]});if(i&&(l.Rm.info("Setting state description",h,i),(Array.isArray(i)?i:[i]).forEach(t=>this.addDescription(h,t.trim()))),r){let t=this.currentDocument.states.get(h);if(!t)throw Error(`State not found: ${h}`);t.note=r,t.note.text=o.Y2.sanitizeText(t.note.text,(0,o.D7)())}n&&(l.Rm.info("Setting state classes",h,n),(Array.isArray(n)?n:[n]).forEach(t=>this.setCssClass(h,t.trim()))),a&&(l.Rm.info("Setting state styles",h,a),(Array.isArray(a)?a:[a]).forEach(t=>this.setStyle(h,t.trim()))),c&&(l.Rm.info("Setting state styles",h,a),(Array.isArray(c)?c:[c]).forEach(t=>this.setTextStyle(h,t.trim())))}clear(t){this.nodes=[],this.edges=[],this.documents={root:q()},this.currentDocument=this.documents.root,this.startEndCount=0,this.classes=J(),t||(this.links=new Map,(0,o.IU)())}getState(t){return this.currentDocument.states.get(t)}getStates(){return this.currentDocument.states}logDocuments(){l.Rm.info("Documents = ",this.documents)}getRelations(){return this.currentDocument.relations}addLink(t,e,s){this.links.set(t,{url:e,tooltip:s}),l.Rm.warn("Adding link",t,e,s)}getLinks(){return this.links}startIdIfNeeded(t=""){return t===H.START_NODE?(this.startEndCount++,`${H.START_TYPE}${this.startEndCount}`):t}startTypeIfNeeded(t="",e=g){return t===H.START_NODE?H.START_TYPE:e}endIdIfNeeded(t=""){return t===H.END_NODE?(this.startEndCount++,`${H.END_TYPE}${this.startEndCount}`):t}endTypeIfNeeded(t="",e=g){return t===H.END_NODE?H.END_TYPE:e}addRelationObjs(t,e,s=""){let i=this.startIdIfNeeded(t.id.trim()),r=this.startTypeIfNeeded(t.id.trim(),t.type),n=this.startIdIfNeeded(e.id.trim()),a=this.startTypeIfNeeded(e.id.trim(),e.type);this.addState(i,r,t.doc,t.description,t.note,t.classes,t.styles,t.textStyles),this.addState(n,a,e.doc,e.description,e.note,e.classes,e.styles,e.textStyles),this.currentDocument.relations.push({id1:i,id2:n,relationTitle:o.Y2.sanitizeText(s,(0,o.D7)())})}addRelation(t,e,s){if("object"==typeof t&&"object"==typeof e)this.addRelationObjs(t,e,s);else if("string"==typeof t&&"string"==typeof e){let i=this.startIdIfNeeded(t.trim()),r=this.startTypeIfNeeded(t),n=this.endIdIfNeeded(e.trim()),a=this.endTypeIfNeeded(e);this.addState(i,r),this.addState(n,a),this.currentDocument.relations.push({id1:i,id2:n,relationTitle:s?o.Y2.sanitizeText(s,(0,o.D7)()):void 0})}}addDescription(t,e){let s=this.currentDocument.states.get(t),i=e.startsWith(":")?e.replace(":","").trim():e;s?.descriptions?.push(o.Y2.sanitizeText(i,(0,o.D7)()))}cleanupLabel(t){return t.startsWith(":")?t.slice(2).trim():t.trim()}getDividerId(){return this.dividerCnt++,`divider-id-${this.dividerCnt}`}addStyleClass(t,e=""){this.classes.has(t)||this.classes.set(t,{id:t,styles:[],textStyles:[]});let s=this.classes.get(t);e&&s&&e.split(H.STYLECLASS_SEP).forEach(t=>{let e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(H.COLOR_KEYWORD).exec(t)){let t=e.replace(H.FILL_KEYWORD,H.BG_FILL).replace(H.COLOR_KEYWORD,H.FILL_KEYWORD);s.textStyles.push(t)}s.styles.push(e)})}getClasses(){return this.classes}setCssClass(t,e){t.split(",").forEach(t=>{let s=this.getState(t);if(!s){let e=t.trim();this.addState(e),s=this.getState(e)}s?.classes?.push(e)})}setStyle(t,e){this.getState(t)?.styles?.push(e)}setTextStyle(t,e){this.getState(t)?.textStyles?.push(e)}getDirectionStatement(){return this.rootDoc.find(t=>"dir"===t.stmt)}getDirection(){return this.getDirectionStatement()?.value??"TB"}setDirection(t){let e=this.getDirectionStatement();e?e.value=t:this.rootDoc.unshift({stmt:"dir",value:t})}trimColon(t){return t.startsWith(":")?t.slice(1).trim():t.trim()}getData(){let t=(0,o.D7)();return{nodes:this.nodes,edges:this.edges,other:{},config:t,direction:B(this.getRootDocV2())}}getConfig(){return(0,o.D7)().state}},tt=(0,l.K2)(t=>`
2
+ defs [id$="-barbEnd"] {
3
+ fill: ${t.transitionColor};
4
+ stroke: ${t.transitionColor};
5
+ }
6
+ g.stateGroup text {
7
+ fill: ${t.nodeBorder};
8
+ stroke: none;
9
+ font-size: 10px;
10
+ }
11
+ g.stateGroup text {
12
+ fill: ${t.textColor};
13
+ stroke: none;
14
+ font-size: 10px;
15
+
16
+ }
17
+ g.stateGroup .state-title {
18
+ font-weight: bolder;
19
+ fill: ${t.stateLabelColor};
20
+ }
21
+
22
+ g.stateGroup rect {
23
+ fill: ${t.mainBkg};
24
+ stroke: ${t.nodeBorder};
25
+ }
26
+
27
+ g.stateGroup line {
28
+ stroke: ${t.lineColor};
29
+ stroke-width: ${t.strokeWidth||1};
30
+ }
31
+
32
+ .transition {
33
+ stroke: ${t.transitionColor};
34
+ stroke-width: ${t.strokeWidth||1};
35
+ fill: none;
36
+ }
37
+
38
+ .stateGroup .composit {
39
+ fill: ${t.background};
40
+ border-bottom: 1px
41
+ }
42
+
43
+ .stateGroup .alt-composit {
44
+ fill: #e0e0e0;
45
+ border-bottom: 1px
46
+ }
47
+
48
+ .state-note {
49
+ stroke: ${t.noteBorderColor};
50
+ fill: ${t.noteBkgColor};
51
+
52
+ text {
53
+ fill: ${t.noteTextColor};
54
+ stroke: none;
55
+ font-size: 10px;
56
+ }
57
+ }
58
+
59
+ .stateLabel .box {
60
+ stroke: none;
61
+ stroke-width: 0;
62
+ fill: ${t.mainBkg};
63
+ opacity: 0.5;
64
+ }
65
+
66
+ .edgeLabel .label rect {
67
+ fill: ${t.labelBackgroundColor};
68
+ opacity: 0.5;
69
+ }
70
+ .edgeLabel {
71
+ background-color: ${t.edgeLabelBackground};
72
+ p {
73
+ background-color: ${t.edgeLabelBackground};
74
+ }
75
+ rect {
76
+ opacity: 0.5;
77
+ background-color: ${t.edgeLabelBackground};
78
+ fill: ${t.edgeLabelBackground};
79
+ }
80
+ text-align: center;
81
+ }
82
+ .edgeLabel .label text {
83
+ fill: ${t.transitionLabelColor||t.tertiaryTextColor};
84
+ }
85
+ .label div .edgeLabel {
86
+ color: ${t.transitionLabelColor||t.tertiaryTextColor};
87
+ }
88
+
89
+ .stateLabel text {
90
+ fill: ${t.stateLabelColor};
91
+ font-size: 10px;
92
+ font-weight: bold;
93
+ }
94
+
95
+ .node circle.state-start {
96
+ fill: ${t.specialStateColor};
97
+ stroke: ${t.specialStateColor};
98
+ }
99
+
100
+ .node .fork-join {
101
+ fill: ${t.specialStateColor};
102
+ stroke: ${t.specialStateColor};
103
+ }
104
+
105
+ .node circle.state-end {
106
+ fill: ${t.innerEndBackground};
107
+ stroke: ${t.background};
108
+ stroke-width: 1.5
109
+ }
110
+ .end-state-inner {
111
+ fill: ${t.compositeBackground||t.background};
112
+ // stroke: ${t.background};
113
+ stroke-width: 1.5
114
+ }
115
+
116
+ .node rect {
117
+ fill: ${t.stateBkg||t.mainBkg};
118
+ stroke: ${t.stateBorder||t.nodeBorder};
119
+ stroke-width: ${t.strokeWidth||1}px;
120
+ }
121
+ .node polygon {
122
+ fill: ${t.mainBkg};
123
+ stroke: ${t.stateBorder||t.nodeBorder};;
124
+ stroke-width: ${t.strokeWidth||1}px;
125
+ }
126
+ [id$="-barbEnd"] {
127
+ fill: ${t.lineColor};
128
+ }
129
+
130
+ .statediagram-cluster rect {
131
+ fill: ${t.compositeTitleBackground};
132
+ stroke: ${t.stateBorder||t.nodeBorder};
133
+ stroke-width: ${t.strokeWidth||1}px;
134
+ }
135
+
136
+ .cluster-label, .nodeLabel {
137
+ color: ${t.stateLabelColor};
138
+ // line-height: 1;
139
+ }
140
+
141
+ .statediagram-cluster rect.outer {
142
+ rx: 5px;
143
+ ry: 5px;
144
+ }
145
+ .statediagram-state .divider {
146
+ stroke: ${t.stateBorder||t.nodeBorder};
147
+ }
148
+
149
+ .statediagram-state .title-state {
150
+ rx: 5px;
151
+ ry: 5px;
152
+ }
153
+ .statediagram-cluster.statediagram-cluster .inner {
154
+ fill: ${t.compositeBackground||t.background};
155
+ }
156
+ .statediagram-cluster.statediagram-cluster-alt .inner {
157
+ fill: ${t.altBackground?t.altBackground:"#efefef"};
158
+ }
159
+
160
+ .statediagram-cluster .inner {
161
+ rx:0;
162
+ ry:0;
163
+ }
164
+
165
+ .statediagram-state rect.basic {
166
+ rx: 5px;
167
+ ry: 5px;
168
+ }
169
+ .statediagram-state rect.divider {
170
+ stroke-dasharray: 10,10;
171
+ fill: ${t.altBackground?t.altBackground:"#efefef"};
172
+ }
173
+
174
+ .note-edge {
175
+ stroke-dasharray: 5;
176
+ }
177
+
178
+ .statediagram-note rect {
179
+ fill: ${t.noteBkgColor};
180
+ stroke: ${t.noteBorderColor};
181
+ stroke-width: 1px;
182
+ rx: 0;
183
+ ry: 0;
184
+ }
185
+ .statediagram-note rect {
186
+ fill: ${t.noteBkgColor};
187
+ stroke: ${t.noteBorderColor};
188
+ stroke-width: 1px;
189
+ rx: 0;
190
+ ry: 0;
191
+ }
192
+
193
+ .statediagram-note text {
194
+ fill: ${t.noteTextColor};
195
+ }
196
+
197
+ .statediagram-note .nodeLabel {
198
+ color: ${t.noteTextColor};
199
+ }
200
+ .statediagram .edgeLabel {
201
+ color: red; // ${t.noteTextColor};
202
+ }
203
+
204
+ [id$="-dependencyStart"], [id$="-dependencyEnd"] {
205
+ fill: ${t.lineColor};
206
+ stroke: ${t.lineColor};
207
+ stroke-width: ${t.strokeWidth||1};
208
+ }
209
+
210
+ .statediagramTitleText {
211
+ text-anchor: middle;
212
+ font-size: 18px;
213
+ fill: ${t.textColor};
214
+ }
215
+
216
+ [data-look="neo"].statediagram-cluster rect {
217
+ fill: ${t.mainBkg};
218
+ stroke: ${t.useGradient?"url("+t.svgId+"-gradient)":t.stateBorder||t.nodeBorder};
219
+ stroke-width: ${t.strokeWidth??1};
220
+ }
221
+ [data-look="neo"].statediagram-cluster rect.outer {
222
+ rx: ${t.radius}px;
223
+ ry: ${t.radius}px;
224
+ filter: ${t.dropShadow?t.dropShadow.replace("url(#drop-shadow)",`url(${t.svgId}-drop-shadow)`):"none"}
225
+ }
226
+ `,"getStyles")}}]);
_next/static/chunks/3580.e76fc55d57dae2f8.js ADDED
@@ -0,0 +1,80 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3580],{1184:(t,e,i)=>{i.d(e,{A:()=>r});var s=i(316),n=i(5508),r=(0,s.K2)((t,e)=>{let i;return"sandbox"===e&&(i=(0,n.Ltv)("#i"+t)),("sandbox"===e?(0,n.Ltv)(i.nodes()[0].contentDocument.body):(0,n.Ltv)("body")).select(`[id="${t}"]`)},"getDiagramElement")},1199:(t,e,i)=>{i.d(e,{diagram:()=>f});var s=i(1184),n=i(2888),r=i(1593);i(4982),i(1431),i(5407),i(7920),i(3148),i(1538);var a=i(3736),o=i(669),c=i(316),l=i(5508),h=i(4808),u=i(8247),d=function(){var t=(0,c.K2)(function(t,e,i,s){for(i=i||{},s=t.length;s--;i[t[s]]=e);return i},"o"),e=[6,8,10,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52],i=[1,10],s=[1,11],n=[1,12],r=[1,13],a=[1,23],o=[1,24],l=[1,25],h=[1,26],u=[1,27],d=[1,19],y=[1,28],p=[1,29],_=[1,20],g=[1,18],b=[1,21],m=[1,22],f=[1,36],E=[1,37],k=[1,38],T=[1,39],O=[1,40],S=[6,8,10,13,15,17,20,21,22,24,26,28,33,34,35,36,37,40,43,44,48,50,51,52,65,66,67,68,69],A=[1,45],N=[1,46],R=[1,55],I=[40,48,50,51,52,70,71],$=[1,66],C=[1,64],x=[1,61],D=[1,65],v=[1,67],L=[6,8,10,13,17,22,24,26,28,33,34,35,36,37,40,41,42,43,44,48,49,50,51,52,65,66,67,68,69],K=[65,66,67,68,69],w=[1,84],M=[1,83],B=[1,81],F=[1,82],Y=[6,10,42,47],P=[6,10,13,41,42,47,48,49],z=[1,92],G=[1,91],U=[1,90],Z=[19,58],j=[1,101],W=[1,100],X=[19,58,60,62],V={trace:(0,c.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ER_DIAGRAM:4,document:5,EOF:6,line:7,SPACE:8,statement:9,NEWLINE:10,entityName:11,relSpec:12,COLON:13,role:14,STYLE_SEPARATOR:15,idList:16,BLOCK_START:17,attributes:18,BLOCK_STOP:19,SQS:20,SQE:21,title:22,title_value:23,acc_title:24,acc_title_value:25,acc_descr:26,acc_descr_value:27,acc_descr_multiline_value:28,direction:29,classDefStatement:30,classStatement:31,styleStatement:32,direction_tb:33,direction_bt:34,direction_rl:35,direction_lr:36,CLASSDEF:37,stylesOpt:38,separator:39,UNICODE_TEXT:40,STYLE_TEXT:41,COMMA:42,CLASS:43,STYLE:44,style:45,styleComponent:46,SEMI:47,NUM:48,BRKT:49,ENTITY_NAME:50,DECIMAL_NUM:51,ENTITY_ONE:52,attribute:53,attributeType:54,attributeName:55,attributeKeyTypeList:56,attributeComment:57,ATTRIBUTE_WORD:58,attributeKeyType:59,",":60,ATTRIBUTE_KEY:61,COMMENT:62,cardinality:63,relType:64,ZERO_OR_ONE:65,ZERO_OR_MORE:66,ONE_OR_MORE:67,ONLY_ONE:68,MD_PARENT:69,NON_IDENTIFYING:70,IDENTIFYING:71,WORD:72,$accept:0,$end:1},terminals_:{2:"error",4:"ER_DIAGRAM",6:"EOF",8:"SPACE",10:"NEWLINE",13:"COLON",15:"STYLE_SEPARATOR",17:"BLOCK_START",19:"BLOCK_STOP",20:"SQS",21:"SQE",22:"title",23:"title_value",24:"acc_title",25:"acc_title_value",26:"acc_descr",27:"acc_descr_value",28:"acc_descr_multiline_value",33:"direction_tb",34:"direction_bt",35:"direction_rl",36:"direction_lr",37:"CLASSDEF",40:"UNICODE_TEXT",41:"STYLE_TEXT",42:"COMMA",43:"CLASS",44:"STYLE",47:"SEMI",48:"NUM",49:"BRKT",50:"ENTITY_NAME",51:"DECIMAL_NUM",52:"ENTITY_ONE",58:"ATTRIBUTE_WORD",60:",",61:"ATTRIBUTE_KEY",62:"COMMENT",65:"ZERO_OR_ONE",66:"ZERO_OR_MORE",67:"ONE_OR_MORE",68:"ONLY_ONE",69:"MD_PARENT",70:"NON_IDENTIFYING",71:"IDENTIFYING",72:"WORD"},productions_:[0,[3,3],[5,0],[5,2],[7,2],[7,1],[7,1],[7,1],[9,5],[9,9],[9,7],[9,7],[9,4],[9,6],[9,3],[9,5],[9,1],[9,3],[9,7],[9,9],[9,6],[9,8],[9,4],[9,6],[9,2],[9,2],[9,2],[9,1],[9,1],[9,1],[9,1],[9,1],[29,1],[29,1],[29,1],[29,1],[30,4],[16,1],[16,1],[16,3],[16,3],[31,3],[32,4],[38,1],[38,3],[45,1],[45,2],[39,1],[39,1],[39,1],[46,1],[46,1],[46,1],[46,1],[11,1],[11,1],[11,1],[11,1],[11,1],[18,1],[18,2],[53,2],[53,3],[53,3],[53,4],[54,1],[55,1],[56,1],[56,3],[59,1],[57,1],[12,3],[63,1],[63,1],[63,1],[63,1],[63,1],[64,1],[64,1],[14,1],[14,1],[14,1]],performAction:(0,c.K2)(function(t,e,i,s,n,r,a){var o=r.length-1;switch(n){case 1:break;case 2:case 6:case 7:this.$=[];break;case 3:r[o-1].push(r[o]),this.$=r[o-1];break;case 4:case 5:case 55:case 56:case 57:case 58:case 81:case 65:case 66:case 69:this.$=r[o];break;case 8:s.addEntity(r[o-4]),s.addEntity(r[o-2]),s.addRelationship(r[o-4],r[o],r[o-2],r[o-3]);break;case 9:s.addEntity(r[o-8]),s.addEntity(r[o-4]),s.addRelationship(r[o-8],r[o],r[o-4],r[o-5]),s.setClass([r[o-8]],r[o-6]),s.setClass([r[o-4]],r[o-2]);break;case 10:s.addEntity(r[o-6]),s.addEntity(r[o-2]),s.addRelationship(r[o-6],r[o],r[o-2],r[o-3]),s.setClass([r[o-6]],r[o-4]);break;case 11:s.addEntity(r[o-6]),s.addEntity(r[o-4]),s.addRelationship(r[o-6],r[o],r[o-4],r[o-5]),s.setClass([r[o-4]],r[o-2]);break;case 12:s.addEntity(r[o-3]),s.addAttributes(r[o-3],r[o-1]);break;case 13:s.addEntity(r[o-5]),s.addAttributes(r[o-5],r[o-1]),s.setClass([r[o-5]],r[o-3]);break;case 14:s.addEntity(r[o-2]);break;case 15:s.addEntity(r[o-4]),s.setClass([r[o-4]],r[o-2]);break;case 16:s.addEntity(r[o]);break;case 17:s.addEntity(r[o-2]),s.setClass([r[o-2]],r[o]);break;case 18:s.addEntity(r[o-6],r[o-4]),s.addAttributes(r[o-6],r[o-1]);break;case 19:s.addEntity(r[o-8],r[o-6]),s.addAttributes(r[o-8],r[o-1]),s.setClass([r[o-8]],r[o-3]);break;case 20:s.addEntity(r[o-5],r[o-3]);break;case 21:s.addEntity(r[o-7],r[o-5]),s.setClass([r[o-7]],r[o-2]);break;case 22:s.addEntity(r[o-3],r[o-1]);break;case 23:s.addEntity(r[o-5],r[o-3]),s.setClass([r[o-5]],r[o]);break;case 24:case 25:this.$=r[o].trim(),s.setAccTitle(this.$);break;case 26:case 27:this.$=r[o].trim(),s.setAccDescription(this.$);break;case 32:s.setDirection("TB");break;case 33:s.setDirection("BT");break;case 34:s.setDirection("RL");break;case 35:s.setDirection("LR");break;case 36:this.$=r[o-3],s.addClass(r[o-2],r[o-1]);break;case 37:case 38:case 59:case 67:case 43:this.$=[r[o]];break;case 39:case 40:this.$=r[o-2].concat([r[o]]);break;case 41:this.$=r[o-2],s.setClass(r[o-1],r[o]);break;case 42:this.$=r[o-3],s.addCssStyles(r[o-2],r[o-1]);break;case 44:case 68:r[o-2].push(r[o]),this.$=r[o-2];break;case 46:this.$=r[o-1]+r[o];break;case 54:case 79:case 80:case 70:this.$=r[o].replace(/"/g,"");break;case 60:r[o].push(r[o-1]),this.$=r[o];break;case 61:this.$={type:r[o-1],name:r[o]};break;case 62:this.$={type:r[o-2],name:r[o-1],keys:r[o]};break;case 63:this.$={type:r[o-2],name:r[o-1],comment:r[o]};break;case 64:this.$={type:r[o-3],name:r[o-2],keys:r[o-1],comment:r[o]};break;case 71:this.$={cardA:r[o],relType:r[o-1],cardB:r[o-2]};break;case 72:this.$=s.Cardinality.ZERO_OR_ONE;break;case 73:this.$=s.Cardinality.ZERO_OR_MORE;break;case 74:this.$=s.Cardinality.ONE_OR_MORE;break;case 75:this.$=s.Cardinality.ONLY_ONE;break;case 76:this.$=s.Cardinality.MD_PARENT;break;case 77:this.$=s.Identification.NON_IDENTIFYING;break;case 78:this.$=s.Identification.IDENTIFYING}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},t(e,[2,2],{5:3}),{6:[1,4],7:5,8:[1,6],9:7,10:[1,8],11:9,22:i,24:s,26:n,28:r,29:14,30:15,31:16,32:17,33:a,34:o,35:l,36:h,37:u,40:d,43:y,44:p,48:_,50:g,51:b,52:m},t(e,[2,7],{1:[2,1]}),t(e,[2,3]),{9:30,11:9,22:i,24:s,26:n,28:r,29:14,30:15,31:16,32:17,33:a,34:o,35:l,36:h,37:u,40:d,43:y,44:p,48:_,50:g,51:b,52:m},t(e,[2,5]),t(e,[2,6]),t(e,[2,16],{12:31,63:35,15:[1,32],17:[1,33],20:[1,34],65:f,66:E,67:k,68:T,69:O}),{23:[1,41]},{25:[1,42]},{27:[1,43]},t(e,[2,27]),t(e,[2,28]),t(e,[2,29]),t(e,[2,30]),t(e,[2,31]),t(S,[2,54]),t(S,[2,55]),t(S,[2,56]),t(S,[2,57]),t(S,[2,58]),t(e,[2,32]),t(e,[2,33]),t(e,[2,34]),t(e,[2,35]),{16:44,40:A,41:N},{16:47,40:A,41:N},{16:48,40:A,41:N},t(e,[2,4]),{11:49,40:d,48:_,50:g,51:b,52:m},{16:50,40:A,41:N},{18:51,19:[1,52],53:53,54:54,58:R},{11:56,40:d,48:_,50:g,51:b,52:m},{64:57,70:[1,58],71:[1,59]},t(I,[2,72]),t(I,[2,73]),t(I,[2,74]),t(I,[2,75]),t(I,[2,76]),t(e,[2,24]),t(e,[2,25]),t(e,[2,26]),{13:$,38:60,41:C,42:x,45:62,46:63,48:D,49:v},t(L,[2,37]),t(L,[2,38]),{16:68,40:A,41:N,42:x},{13:$,38:69,41:C,42:x,45:62,46:63,48:D,49:v},{13:[1,70],15:[1,71]},t(e,[2,17],{63:35,12:72,17:[1,73],42:x,65:f,66:E,67:k,68:T,69:O}),{19:[1,74]},t(e,[2,14]),{18:75,19:[2,59],53:53,54:54,58:R},{55:76,58:[1,77]},{58:[2,65]},{21:[1,78]},{63:79,65:f,66:E,67:k,68:T,69:O},t(K,[2,77]),t(K,[2,78]),{6:w,10:M,39:80,42:B,47:F},{40:[1,85],41:[1,86]},t(Y,[2,43],{46:87,13:$,41:C,48:D,49:v}),t(P,[2,45]),t(P,[2,50]),t(P,[2,51]),t(P,[2,52]),t(P,[2,53]),t(e,[2,41],{42:x}),{6:w,10:M,39:88,42:B,47:F},{14:89,40:z,50:G,72:U},{16:93,40:A,41:N},{11:94,40:d,48:_,50:g,51:b,52:m},{18:95,19:[1,96],53:53,54:54,58:R},t(e,[2,12]),{19:[2,60]},t(Z,[2,61],{56:97,57:98,59:99,61:j,62:W}),t([19,58,61,62],[2,66]),t(e,[2,22],{15:[1,103],17:[1,102]}),t([40,48,50,51,52],[2,71]),t(e,[2,36]),{13:$,41:C,45:104,46:63,48:D,49:v},t(e,[2,47]),t(e,[2,48]),t(e,[2,49]),t(L,[2,39]),t(L,[2,40]),t(P,[2,46]),t(e,[2,42]),t(e,[2,8]),t(e,[2,79]),t(e,[2,80]),t(e,[2,81]),{13:[1,105],42:x},{13:[1,107],15:[1,106]},{19:[1,108]},t(e,[2,15]),t(Z,[2,62],{57:109,60:[1,110],62:W}),t(Z,[2,63]),t(X,[2,67]),t(Z,[2,70]),t(X,[2,69]),{18:111,19:[1,112],53:53,54:54,58:R},{16:113,40:A,41:N},t(Y,[2,44],{46:87,13:$,41:C,48:D,49:v}),{14:114,40:z,50:G,72:U},{16:115,40:A,41:N},{14:116,40:z,50:G,72:U},t(e,[2,13]),t(Z,[2,64]),{59:117,61:j},{19:[1,118]},t(e,[2,20]),t(e,[2,23],{17:[1,119],42:x}),t(e,[2,11]),{13:[1,120],42:x},t(e,[2,10]),t(X,[2,68]),t(e,[2,18]),{18:121,19:[1,122],53:53,54:54,58:R},{14:123,40:z,50:G,72:U},{19:[1,124]},t(e,[2,21]),t(e,[2,9]),t(e,[2,19])],defaultActions:{55:[2,65],75:[2,60]},parseError:(0,c.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,c.K2)(function(t){var e=this,i=[0],s=[],n=[null],r=[],a=this.table,o="",l=0,h=0,u=0,d=r.slice.call(arguments,1),y=Object.create(this.lexer),p={};for(var _ in this.yy)Object.prototype.hasOwnProperty.call(this.yy,_)&&(p[_]=this.yy[_]);y.setInput(t,p),p.lexer=y,p.parser=this,void 0===y.yylloc&&(y.yylloc={});var g=y.yylloc;r.push(g);var b=y.options&&y.options.ranges;function m(){var t;return"number"!=typeof(t=s.pop()||y.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof p.parseError?this.parseError=p.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,c.K2)(function(t){i.length=i.length-2*t,n.length=n.length-t,r.length=r.length-t},"popStack"),(0,c.K2)(m,"lex");for(var f,E,k,T,O,S,A,N,R,I={};;){if(k=i[i.length-1],this.defaultActions[k]?T=this.defaultActions[k]:(null==f&&(f=m()),T=a[k]&&a[k][f]),void 0===T||!T.length||!T[0]){var $="";for(S in R=[],a[k])this.terminals_[S]&&S>2&&R.push("'"+this.terminals_[S]+"'");$=y.showPosition?"Parse error on line "+(l+1)+":\n"+y.showPosition()+"\nExpecting "+R.join(", ")+", got '"+(this.terminals_[f]||f)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==f?"end of input":"'"+(this.terminals_[f]||f)+"'"),this.parseError($,{text:y.match,token:this.terminals_[f]||f,line:y.yylineno,loc:g,expected:R})}if(T[0]instanceof Array&&T.length>1)throw Error("Parse Error: multiple actions possible at state: "+k+", token: "+f);switch(T[0]){case 1:i.push(f),n.push(y.yytext),r.push(y.yylloc),i.push(T[1]),f=null,E?(f=E,E=null):(h=y.yyleng,o=y.yytext,l=y.yylineno,g=y.yylloc,u>0&&u--);break;case 2:if(A=this.productions_[T[1]][1],I.$=n[n.length-A],I._$={first_line:r[r.length-(A||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(A||1)].first_column,last_column:r[r.length-1].last_column},b&&(I._$.range=[r[r.length-(A||1)].range[0],r[r.length-1].range[1]]),void 0!==(O=this.performAction.apply(I,[o,h,l,p,T[1],n,r].concat(d))))return O;A&&(i=i.slice(0,-1*A*2),n=n.slice(0,-1*A),r=r.slice(0,-1*A)),i.push(this.productions_[T[1]][0]),n.push(I.$),r.push(I._$),N=a[i[i.length-2]][i[i.length-1]],i.push(N);break;case 3:return!0}}return!0},"parse")};function Q(){this.yy={}}return V.lexer={EOF:1,parseError:(0,c.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,c.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,c.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,c.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var n=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===s.length?this.yylloc.first_column:0)+s[s.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[n[0],n[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,c.K2)(function(){return this._more=!0,this},"more"),reject:(0,c.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,c.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,c.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,c.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,c.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,c.K2)(function(t,e){var i,s,n;if(this.options.backtrack_lexer&&(n={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&&(n.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var r in n)this[r]=n[r];return!1},"test_match"),next:(0,c.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,s,n=this._currentRules(),r=0;r<n.length;r++)if((i=this._input.match(this.rules[n[r]]))&&(!e||i[0].length>e[0].length)){if(e=i,s=r,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,n[r])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,n[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,c.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,c.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,c.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,c.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,c.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,c.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,c.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,c.K2)(function(t,e,i,s){switch(i){case 0:return this.begin("acc_title"),24;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),26;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return 33;case 8:return 34;case 9:return 35;case 10:return 36;case 11:return 10;case 12:case 23:case 28:case 35:break;case 13:return 8;case 14:return 50;case 15:return 72;case 16:return 4;case 17:return this.begin("block"),17;case 18:case 19:case 38:return 49;case 20:case 37:return 42;case 21:return 15;case 22:case 36:return 13;case 24:return 61;case 25:case 26:return 58;case 27:return 62;case 29:return this.popState(),19;case 30:case 77:return e.yytext[0];case 31:return 20;case 32:return 21;case 33:return this.begin("style"),44;case 34:return this.popState(),10;case 39:return this.begin("style"),37;case 40:return 43;case 41:case 45:case 46:case 64:return 65;case 42:case 43:case 44:case 52:case 54:case 66:return 67;case 47:case 48:case 49:case 50:case 51:case 53:case 65:return 66;case 55:case 56:case 58:case 59:case 60:case 63:return 68;case 57:return 51;case 61:return 52;case 62:return 48;case 67:return 69;case 68:case 71:case 72:case 73:return 70;case 69:case 70:return 71;case 74:return 41;case 75:return 47;case 76:return 40;case 78:return 6}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:[\s]+)/i,/^(?:"[^"%\r\n\v\b\\]+")/i,/^(?:"[^"]*")/i,/^(?:erDiagram\b)/i,/^(?:\{)/i,/^(?:#)/i,/^(?:#)/i,/^(?:,)/i,/^(?::::)/i,/^(?::)/i,/^(?:\s+)/i,/^(?:\b((?:PK)|(?:FK)|(?:UK))\b)/i,/^(?:([^\s]*)[~].*[~]([^\s]*))/i,/^(?:([\*A-Za-z_\u00C0-\uFFFF][A-Za-z0-9\-\_\[\]\(\)\u00C0-\uFFFF\*]*))/i,/^(?:"[^"]*")/i,/^(?:[\n]+)/i,/^(?:\})/i,/^(?:.)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:style\b)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?::)/i,/^(?:,)/i,/^(?:#)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:one or zero\b)/i,/^(?:one or more\b)/i,/^(?:one or many\b)/i,/^(?:1\+)/i,/^(?:\|o\b)/i,/^(?:zero or one\b)/i,/^(?:zero or more\b)/i,/^(?:zero or many\b)/i,/^(?:0\+)/i,/^(?:\}o\b)/i,/^(?:many\(0\))/i,/^(?:many\(1\))/i,/^(?:many\b)/i,/^(?:\}\|)/i,/^(?:one\b)/i,/^(?:only one\b)/i,/^(?:[0-9]+\.[0-9]+)/i,/^(?:1(?=\s+[A-Za-z_"']))/i,/^(?:1(?=\s+[0-9]))/i,/^(?:1(?=(--|\.\.|\.-|-\.)))/i,/^(?:1\b)/i,/^(?:[0-9]+)/i,/^(?:\|\|)/i,/^(?:o\|)/i,/^(?:o\{)/i,/^(?:\|\{)/i,/^(?:u(?=[\.\-\|]))/i,/^(?:\.\.)/i,/^(?:--)/i,/^(?:to\b)/i,/^(?:optionally to\b)/i,/^(?:\.-)/i,/^(?:-\.)/i,/^(?:([^\x00-\x7F]|\w|-|\*)+)/i,/^(?:;)/i,/^(?:([^\x00-\x7F]|\w|-|\*|\.)+)/i,/^(?:.)/i,/^(?:$)/i],conditions:{style:{rules:[34,35,36,37,38,74,75],inclusive:!1},acc_descr_multiline:{rules:[5,6],inclusive:!1},acc_descr:{rules:[3],inclusive:!1},acc_title:{rules:[1],inclusive:!1},block:{rules:[23,24,25,26,27,28,29,30],inclusive:!1},INITIAL:{rules:[0,2,4,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,31,32,33,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,76,77,78],inclusive:!0}}},(0,c.K2)(Q,"Parser"),Q.prototype=V,V.Parser=Q,new Q}();d.parser=d;var y=class{constructor(){this.entities=new Map,this.relationships=[],this.classes=new Map,this.direction="TB",this.Cardinality={ZERO_OR_ONE:"ZERO_OR_ONE",ZERO_OR_MORE:"ZERO_OR_MORE",ONE_OR_MORE:"ONE_OR_MORE",ONLY_ONE:"ONLY_ONE",MD_PARENT:"MD_PARENT"},this.Identification={NON_IDENTIFYING:"NON_IDENTIFYING",IDENTIFYING:"IDENTIFYING"},this.setAccTitle=o.SV,this.getAccTitle=o.iN,this.setAccDescription=o.EI,this.getAccDescription=o.m7,this.setDiagramTitle=o.ke,this.getDiagramTitle=o.ab,this.getConfig=(0,c.K2)(()=>(0,o.D7)().er,"getConfig"),this.clear(),this.addEntity=this.addEntity.bind(this),this.addAttributes=this.addAttributes.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setDirection=this.setDirection.bind(this),this.addCssStyles=this.addCssStyles.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,c.K2)(this,"ErDB")}addEntity(t,e=""){return this.entities.has(t)?!this.entities.get(t)?.alias&&e&&(this.entities.get(t).alias=e,c.Rm.info(`Add alias '${e}' to entity '${t}'`)):(this.entities.set(t,{id:`entity-${t}-${this.entities.size}`,label:t,attributes:[],alias:e,shape:"erBox",look:(0,o.D7)().look??"default",cssClasses:"default",cssStyles:[],labelType:"markdown"}),c.Rm.info("Added new entity :",t)),this.entities.get(t)}getEntity(t){return this.entities.get(t)}getEntities(){return this.entities}getClasses(){return this.classes}addAttributes(t,e){let i,s=this.addEntity(t);for(i=e.length-1;i>=0;i--)e[i].keys||(e[i].keys=[]),e[i].comment||(e[i].comment=""),s.attributes.push(e[i]),c.Rm.debug("Added attribute ",e[i].name)}addRelationship(t,e,i,s){let n=this.entities.get(t),r=this.entities.get(i);if(!n||!r)return;let a={entityA:n.id,roleA:e,entityB:r.id,relSpec:s};this.relationships.push(a),c.Rm.debug("Added new relationship :",a)}getRelationships(){return this.relationships}getDirection(){return this.direction}setDirection(t){this.direction=t}getCompiledStyles(t){let e=[];for(let i of t){let t=this.classes.get(i);t?.styles&&(e=[...e,...t.styles??[]].map(t=>t.trim())),t?.textStyles&&(e=[...e,...t.textStyles??[]].map(t=>t.trim()))}return e}addCssStyles(t,e){for(let i of t){let t=this.entities.get(i);if(!e||!t)return;for(let i of e)t.cssStyles.push(i)}}addClass(t,e){t.forEach(t=>{let i=this.classes.get(t);void 0===i&&(i={id:t,styles:[],textStyles:[]},this.classes.set(t,i)),e&&e.forEach(function(t){if(/color/.exec(t)){let e=t.replace("fill","bgFill");i.textStyles.push(e)}i.styles.push(t)})})}setClass(t,e){for(let i of t){let t=this.entities.get(i);if(t)for(let i of e)t.cssClasses+=" "+i}}clear(){this.entities=new Map,this.classes=new Map,this.relationships=[],(0,o.IU)()}getData(){let t=[],e=[],i=(0,o.D7)(),s=0;for(let e of this.entities.keys()){let i=this.entities.get(e);i&&(i.cssCompiledStyles=this.getCompiledStyles(i.cssClasses.split(" ")),i.colorIndex=s++,t.push(i))}let n=0;for(let t of this.relationships){let s={id:(0,a.rY)(t.entityA,t.entityB,{prefix:"id",counter:n++}),type:"normal",curve:"basis",start:t.entityA,end:t.entityB,label:t.roleA,labelpos:"c",thickness:"normal",classes:"relationshipLine",arrowTypeStart:t.relSpec.cardB.toLowerCase(),arrowTypeEnd:t.relSpec.cardA.toLowerCase(),pattern:"IDENTIFYING"==t.relSpec.relType?"solid":"dashed",look:i.look,labelType:"markdown"};e.push(s)}return{nodes:t,edges:e,other:{},config:i,direction:"TB"}}},p={};(0,c.VA)(p,{draw:()=>_});var _=(0,c.K2)(async function(t,e,i,h){c.Rm.info("REF0:"),c.Rm.info("Drawing er diagram (unified)",e);let{securityLevel:u,er:d,layout:y}=(0,o.D7)(),p=h.db.getData(),_=(0,s.A)(e,u);p.type=h.type,p.layoutAlgorithm=(0,r.q7)(y),p.config.flowchart.nodeSpacing=d?.nodeSpacing||140,p.config.flowchart.rankSpacing=d?.rankSpacing||80,p.direction=h.db.getDirection();let{config:g}=p,{look:b}=g;"neo"===b?p.markers=["only_one_neo","zero_or_one_neo","one_or_more_neo","zero_or_more_neo"]:p.markers=["only_one","zero_or_one","one_or_more","zero_or_more"],p.diagramId=e,await (0,r.XX)(p,_),"elk"===p.layoutAlgorithm&&_.select(".edges").lower();let m=_.selectAll('[id*="-background"]');Array.from(m).length>0&&m.each(function(){let t=(0,l.Ltv)(this),e=t.attr("id").replace("-background",""),i=_.select(`#${CSS.escape(e)}`);if(!i.empty()){let e=i.attr("transform");t.attr("transform",e)}}),a._K.insertTitle(_,"erDiagramTitleText",d?.titleTopMargin??25,h.db.getDiagramTitle()),(0,n.P)(_,8,"erDiagram",d?.useMaxWidth??!0)},"draw"),g=(0,c.K2)((t,e)=>{let i=h.A,s=i(t,"r"),n=i(t,"g"),r=i(t,"b");return u.A(s,n,r,e)},"fade"),b=new Set(["redux-color","redux-dark-color"]),m=(0,c.K2)(t=>{let{theme:e,look:i,bkgColorArray:s,borderColorArray:n}=t;if(!b.has(e))return"";let r=s?.length>0,a="";for(let e=0;e<t.THEME_COLOR_LIMIT;e++)a+=`
2
+
3
+ [data-look="${i}"][data-color-id="color-${e}"].node path {
4
+ stroke: ${n[e]};
5
+ ${r?`fill: ${s[e]};`:""}
6
+ }
7
+
8
+ [data-look="${i}"][data-color-id="color-${e}"].node rect {
9
+ stroke: ${n[e]};
10
+ ${r?`fill: ${s[e]};`:""}
11
+ }
12
+ `;return a},"genColor"),f={parser:d,get db(){return new y},renderer:p,styles:(0,c.K2)(t=>{let{look:e,theme:i,erEdgeLabelBackground:s,strokeWidth:n}=t;return`
13
+ ${m(t)}
14
+ .entityBox {
15
+ fill: ${t.mainBkg};
16
+ stroke: ${t.nodeBorder};
17
+ }
18
+
19
+ .relationshipLabelBox {
20
+ fill: ${t.tertiaryColor};
21
+ opacity: 0.7;
22
+ background-color: ${t.tertiaryColor};
23
+ rect {
24
+ opacity: 0.5;
25
+ }
26
+ }
27
+
28
+ .labelBkg {
29
+ background-color: ${b.has(i)&&s?s:g(t.tertiaryColor,.5)};
30
+ }
31
+
32
+ .edgeLabel {
33
+ background-color: ${b.has(i)&&s?s:t.edgeLabelBackground};
34
+ }
35
+ .edgeLabel .label rect {
36
+ fill: ${b.has(i)&&s?s:t.edgeLabelBackground};
37
+ }
38
+ .edgeLabel .label text {
39
+ fill: ${t.textColor};
40
+ }
41
+
42
+ .edgeLabel .label {
43
+ fill: ${t.nodeBorder};
44
+ font-size: 14px;
45
+ }
46
+
47
+ .label {
48
+ font-family: ${t.fontFamily};
49
+ color: ${t.nodeTextColor||t.textColor};
50
+ }
51
+
52
+ .edge-pattern-dashed {
53
+ stroke-dasharray: 8,8;
54
+ }
55
+
56
+ .node rect,
57
+ .node circle,
58
+ .node ellipse,
59
+ .node polygon
60
+ {
61
+ fill: ${t.mainBkg};
62
+ stroke: ${t.nodeBorder};
63
+ stroke-width: ${"neo"===e?n:"1px"};
64
+ }
65
+
66
+ .relationshipLine {
67
+ stroke: ${t.lineColor};
68
+ stroke-width: ${"neo"===e?n:"1px"};
69
+ fill: none;
70
+ }
71
+
72
+ .marker {
73
+ fill: none !important;
74
+ stroke: ${t.lineColor} !important;
75
+ stroke-width: 1;
76
+ }
77
+ [data-look=neo].labelBkg {
78
+ background-color: ${g(t.tertiaryColor,.5)};
79
+ }
80
+ `},"getStyles")}},2888:(t,e,i)=>{i.d(e,{P:()=>r});var s=i(669),n=i(316),r=(0,n.K2)((t,e,i,r)=>{t.attr("class",i);let{width:c,height:l,x:h,y:u}=a(t,e);(0,s.a$)(t,l,c,r);let d=o(h,u,c,l,e);t.attr("viewBox",d),n.Rm.debug(`viewBox configured: ${d} with padding: ${e}`)},"setupViewPortForSVG"),a=(0,n.K2)((t,e)=>{let i=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:i.width+2*e,height:i.height+2*e,x:i.x,y:i.y}},"calculateDimensionsWithPadding"),o=(0,n.K2)((t,e,i,s,n)=>`${t-n} ${e-n} ${i} ${s}`,"createViewBox")},4808:(t,e,i)=>{i.d(e,{A:()=>r});var s=i(5525),n=i(4984);let r=(t,e)=>s.A.lang.round(n.A.parse(t)[e])}}]);
_next/static/chunks/3627.baa361f72a00cf7e.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[3627],{3627:(e,a,r)=>{r.d(a,{diagram:()=>o});var t=r(2667),n=r(669),s=r(316),d=r(4290),i={parse:(0,s.K2)(async e=>{let a=await (0,d.qg)("info",e);s.Rm.debug(a)},"parse")},p={version:"11.15.0"},g=(0,s.K2)(()=>p.version,"getVersion"),o={parser:i,db:{getVersion:g},renderer:{draw:(0,s.K2)((e,a,r)=>{s.Rm.debug("rendering info diagram\n"+e);let d=(0,t.D)(a);(0,n.a$)(d,100,400,!0),d.append("g").append("text").attr("x",100).attr("y",40).attr("class","version").attr("font-size",32).style("text-anchor","middle").text(`v${r}`)},"draw")}}}}]);
_next/static/chunks/4162.6f781ac1e3d4e682.js ADDED
@@ -0,0 +1,215 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4162],{1184:(t,e,s)=>{s.d(e,{A:()=>n});var i=s(316),a=s(5508),n=(0,i.K2)((t,e)=>{let s;return"sandbox"===e&&(s=(0,a.Ltv)("#i"+t)),("sandbox"===e?(0,a.Ltv)(s.nodes()[0].contentDocument.body):(0,a.Ltv)("body")).select(`[id="${t}"]`)},"getDiagramElement")},2888:(t,e,s)=>{s.d(e,{P:()=>n});var i=s(669),a=s(316),n=(0,a.K2)((t,e,s,n)=>{t.attr("class",s);let{width:u,height:o,x:c,y:h}=r(t,e);(0,i.a$)(t,o,u,n);let d=l(c,h,u,o,e);t.attr("viewBox",d),a.Rm.debug(`viewBox configured: ${d} with padding: ${e}`)},"setupViewPortForSVG"),r=(0,a.K2)((t,e)=>{let s=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:s.width+2*e,height:s.height+2*e,x:s.x,y:s.y}},"calculateDimensionsWithPadding"),l=(0,a.K2)((t,e,s,i,a)=>`${t-a} ${e-a} ${s} ${i}`,"createViewBox")},3062:(t,e,s)=>{s.d(e,{CP:()=>h,Ck:()=>A,HT:()=>p,PB:()=>d,aC:()=>c,lC:()=>u,m:()=>o,tk:()=>l});var i=s(669),a=s(316),n=s(3572),r=s(5508),l=(0,a.K2)((t,e)=>{let s=t.append("rect");if(s.attr("x",e.x),s.attr("y",e.y),s.attr("fill",e.fill),s.attr("stroke",e.stroke),s.attr("width",e.width),s.attr("height",e.height),e.name&&s.attr("name",e.name),e.rx&&s.attr("rx",e.rx),e.ry&&s.attr("ry",e.ry),void 0!==e.attrs)for(let t in e.attrs)s.attr(t,e.attrs[t]);return e.class&&s.attr("class",e.class),s},"drawRect"),u=(0,a.K2)((t,e)=>{l(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"}).lower()},"drawBackgroundRect"),o=(0,a.K2)((t,e)=>{let s=e.text.replace(i.H1," "),a=t.append("text");a.attr("x",e.x),a.attr("y",e.y),a.attr("class","legend"),a.style("text-anchor",e.anchor),e.class&&a.attr("class",e.class);let n=a.append("tspan");return n.attr("x",e.x+2*e.textMargin),n.text(s),a},"drawText"),c=(0,a.K2)((t,e,s,i)=>{let a=t.append("image");a.attr("x",e),a.attr("y",s);let r=(0,n.J)(i);a.attr("xlink:href",r)},"drawImage"),h=(0,a.K2)((t,e,s,i)=>{let a=t.append("use");a.attr("x",e),a.attr("y",s);let r=(0,n.J)(i);a.attr("xlink:href",`#${r}`)},"drawEmbeddedImage"),d=(0,a.K2)(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),p=(0,a.K2)(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj"),A=(0,a.K2)(()=>{let t=(0,r.Ltv)(".mermaidTooltip");return t.empty()&&(t=(0,r.Ltv)("body").append("div").attr("class","mermaidTooltip").style("opacity",0).style("position","absolute").style("text-align","center").style("max-width","200px").style("padding","2px").style("font-size","12px").style("background","#ffffde").style("border","1px solid #333").style("border-radius","2px").style("pointer-events","none").style("z-index","100")),t},"createTooltip")},3580:(t,e,s)=>{s.d(e,{o:()=>i});var i=(0,s(316).K2)(()=>`
2
+ /* Font Awesome icon styling - consolidated */
3
+ .label-icon {
4
+ display: inline-block;
5
+ height: 1em;
6
+ overflow: visible;
7
+ vertical-align: -0.125em;
8
+ }
9
+
10
+ .node .label-icon path {
11
+ fill: currentColor;
12
+ stroke: revert;
13
+ stroke-width: revert;
14
+ }
15
+ `,"getIconStyles")},4162:(t,e,s)=>{s.d(e,{Lh:()=>T,NM:()=>k,_$:()=>A,tM:()=>E});var i=s(3580),a=s(3062),n=s(1184),r=s(2888),l=s(1593),u=s(3736),o=s(669),c=s(316),h=s(5508),d=s(2931),p=function(){var t=(0,c.K2)(function(t,e,s,i){for(s=s||{},i=t.length;i--;s[t[i]]=e);return s},"o"),e=[1,18],s=[1,19],i=[1,20],a=[1,41],n=[1,26],r=[1,42],l=[1,24],u=[1,25],o=[1,32],h=[1,33],d=[1,34],p=[1,45],A=[1,35],y=[1,36],g=[1,37],m=[1,38],b=[1,27],C=[1,28],k=[1,29],E=[1,30],f=[1,31],T=[1,44],D=[1,46],F=[1,43],B=[1,47],_=[1,9],$=[1,8,9],x=[1,58],S=[1,59],N=[1,60],L=[1,61],v=[1,62],I=[1,63],O=[1,64],w=[1,8,9,41],R=[1,77],K=[1,8,9,12,13,22,39,41,44,46,68,69,70,71,72,73,74,79,81],P=[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],M=[13,60,86,100,102,103],G=[13,60,73,74,86,100,102,103],U=[13,60,68,69,70,71,72,86,100,102,103],Y=[1,103],z=[1,121],Q=[1,117],W=[1,113],j=[1,119],X=[1,114],H=[1,115],V=[1,116],q=[1,118],J=[1,120],Z=[22,50,60,61,82,86,87,88,89,90],tt=[1,128],te=[12,39],ts=[1,8,9,39,41,44,46],ti=[1,8,9,22],ta=[1,153],tn=[1,8,9,61],tr=[1,8,9,22,50,60,61,82,86,87,88,89,90],tl={trace:(0,c.K2)(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:(0,c.K2)(function(t,e,s,i,a,n,r){var l=n.length-1;switch(a){case 8:this.$=n[l-1];break;case 9:case 10:case 13:case 15:case 46:this.$=n[l];break;case 11:case 14:this.$=n[l-2]+"."+n[l];break;case 12:case 16:case 110:this.$=n[l-1]+n[l];break;case 17:case 18:this.$=n[l-1]+"~"+n[l]+"~";break;case 19:i.addRelation(n[l]);break;case 20:n[l-1].title=i.cleanupLabel(n[l]),i.addRelation(n[l-1]);break;case 31:this.$=n[l].trim(),i.setAccTitle(this.$);break;case 32:case 33:this.$=n[l].trim(),i.setAccDescription(this.$);break;case 34:i.addClassesToNamespace(n[l-3],n[l-1][0],n[l-1][1]),i.popNamespace();break;case 35:i.addClassesToNamespace(n[l-4],n[l-1][0],n[l-1][1]),i.popNamespace();break;case 36:this.$=i.addNamespace(n[l]);break;case 37:this.$=i.addNamespace(n[l-1],n[l]);break;case 38:this.$=[[n[l]],[]];break;case 39:this.$=[[n[l-1]],[]];break;case 40:n[l][0].unshift(n[l-2]),this.$=n[l];break;case 41:this.$=[[],[n[l]]];break;case 42:this.$=[[],[n[l-1]]];break;case 43:n[l][1].unshift(n[l-2]),this.$=n[l];break;case 44:case 45:this.$=[[],[]];break;case 48:i.setCssClass(n[l-2],n[l]);break;case 49:i.addMembers(n[l-3],n[l-1]);break;case 51:i.setCssClass(n[l-5],n[l-3]),i.addMembers(n[l-5],n[l-1]);break;case 52:i.addAnnotation(n[l-3],n[l-1]);break;case 53:i.addAnnotation(n[l-6],n[l-4]),i.addMembers(n[l-6],n[l-1]);break;case 54:i.addAnnotation(n[l-5],n[l-3]);break;case 55:this.$=n[l],i.addClass(n[l]);break;case 56:this.$=n[l-1],i.addClass(n[l-1]),i.setClassLabel(n[l-1],n[l]);break;case 60:i.addAnnotation(n[l],n[l-2]);break;case 61:case 74:case 107:this.$=[n[l]];break;case 62:n[l].push(n[l-1]),this.$=n[l];break;case 63:case 65:case 66:break;case 64:i.addMember(n[l-1],i.cleanupLabel(n[l]));break;case 67:this.$={id1:n[l-2],id2:n[l],relation:n[l-1],relationTitle1:"none",relationTitle2:"none"};break;case 68:this.$={id1:n[l-3],id2:n[l],relation:n[l-1],relationTitle1:n[l-2],relationTitle2:"none"};break;case 69:this.$={id1:n[l-3],id2:n[l],relation:n[l-2],relationTitle1:"none",relationTitle2:n[l-1]};break;case 70:this.$={id1:n[l-4],id2:n[l],relation:n[l-2],relationTitle1:n[l-3],relationTitle2:n[l-1]};break;case 71:this.$=i.addNote(n[l],n[l-1]);break;case 72:this.$=i.addNote(n[l]);break;case 73:this.$=n[l-2],i.defineClass(n[l-1],n[l]);break;case 75:this.$=n[l-2].concat([n[l]]);break;case 76:i.setDirection("TB");break;case 77:i.setDirection("BT");break;case 78:i.setDirection("RL");break;case 79:i.setDirection("LR");break;case 80:this.$={type1:n[l-2],type2:n[l],lineType:n[l-1]};break;case 81:this.$={type1:"none",type2:n[l],lineType:n[l-1]};break;case 82:this.$={type1:n[l-1],type2:"none",lineType:n[l]};break;case 83:this.$={type1:"none",type2:"none",lineType:n[l]};break;case 84:this.$=i.relationType.AGGREGATION;break;case 85:this.$=i.relationType.EXTENSION;break;case 86:this.$=i.relationType.COMPOSITION;break;case 87:this.$=i.relationType.DEPENDENCY;break;case 88:this.$=i.relationType.LOLLIPOP;break;case 89:this.$=i.lineType.LINE;break;case 90:this.$=i.lineType.DOTTED_LINE;break;case 91:case 97:this.$=n[l-2],i.setClickEvent(n[l-1],n[l]);break;case 92:case 98:this.$=n[l-3],i.setClickEvent(n[l-2],n[l-1]),i.setTooltip(n[l-2],n[l]);break;case 93:this.$=n[l-2],i.setLink(n[l-1],n[l]);break;case 94:this.$=n[l-3],i.setLink(n[l-2],n[l-1],n[l]);break;case 95:this.$=n[l-3],i.setLink(n[l-2],n[l-1]),i.setTooltip(n[l-2],n[l]);break;case 96:this.$=n[l-4],i.setLink(n[l-3],n[l-2],n[l]),i.setTooltip(n[l-3],n[l-1]);break;case 99:this.$=n[l-3],i.setClickEvent(n[l-2],n[l-1],n[l]);break;case 100:this.$=n[l-4],i.setClickEvent(n[l-3],n[l-2],n[l-1]),i.setTooltip(n[l-3],n[l]);break;case 101:this.$=n[l-3],i.setLink(n[l-2],n[l]);break;case 102:this.$=n[l-4],i.setLink(n[l-3],n[l-1],n[l]);break;case 103:this.$=n[l-4],i.setLink(n[l-3],n[l-1]),i.setTooltip(n[l-3],n[l]);break;case 104:this.$=n[l-5],i.setLink(n[l-4],n[l-2],n[l]),i.setTooltip(n[l-4],n[l-1]);break;case 105:this.$=n[l-2],i.setCssStyle(n[l-1],n[l]);break;case 106:i.setCssClass(n[l-1],n[l]);break;case 108:n[l-2].push(n[l]),this.$=n[l-2]}},"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:e,35:s,37:i,38:22,42:a,43:23,46:n,48:r,51:l,52:u,54:o,56:h,57:d,60:p,62:A,63:y,64:g,65:m,75:b,76:C,78:k,82:E,83:f,86:T,100:D,102:F,103:B},{1:[3]},{1:[2,1]},{1:[2,2]},{1:[2,3]},t(_,[2,5],{8:[1,48]}),{8:[1,49]},t($,[2,19],{22:[1,50]}),t($,[2,21]),t($,[2,22]),t($,[2,23]),t($,[2,24]),t($,[2,25]),t($,[2,26]),t($,[2,27]),t($,[2,28]),t($,[2,29]),t($,[2,30]),{34:[1,51]},{36:[1,52]},t($,[2,33]),t($,[2,63],{53:53,66:56,67:57,13:[1,54],22:[1,55],68:x,69:S,70:N,71:L,72:v,73:I,74:O}),{39:[1,65]},t(w,[2,47],{39:[1,67],44:[1,66],46:[1,68]}),t($,[2,65]),t($,[2,66]),{16:69,60:p,86:T,100:D,102:F},{16:39,17:40,19:70,60:p,86:T,100:D,102:F,103:B},{16:39,17:40,19:71,60:p,86:T,100:D,102:F,103:B},{16:39,17:40,19:72,60:p,86:T,100:D,102:F,103:B},{60:[1,73]},{13:[1,74]},{16:39,17:40,19:75,60:p,86:T,100:D,102:F,103:B},{13:R,55:76},{58:78,60:[1,79]},t($,[2,76]),t($,[2,77]),t($,[2,78]),t($,[2,79]),t(K,[2,13],{16:39,17:40,19:81,18:[1,80],20:[1,82],60:p,86:T,100:D,102:F,103:B}),t(K,[2,15],{20:[1,83]}),{15:84,16:85,17:86,60:p,86:T,100:D,102:F,103:B},{16:39,17:40,19:87,60:p,86:T,100:D,102:F,103:B},t(P,[2,133]),t(P,[2,134]),t(P,[2,135]),t(P,[2,136]),t([1,8,9,12,13,20,22,39,41,44,46,68,69,70,71,72,73,74,79,81],[2,137]),t(_,[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:e,35:s,37:i,42:a,46:n,48:r,51:l,52:u,54:o,56:h,57:d,60:p,62:A,63:y,64:g,65:m,75:b,76:C,78:k,82:E,83:f,86:T,100:D,102:F,103:B}),{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:e,35:s,37:i,38:22,42:a,43:23,46:n,48:r,51:l,52:u,54:o,56:h,57:d,60:p,62:A,63:y,64:g,65:m,75:b,76:C,78:k,82:E,83:f,86:T,100:D,102:F,103:B},t($,[2,20]),t($,[2,31]),t($,[2,32]),{13:[1,91],16:39,17:40,19:90,60:p,86:T,100:D,102:F,103:B},{53:92,66:56,67:57,68:x,69:S,70:N,71:L,72:v,73:I,74:O},t($,[2,64]),{67:93,73:I,74:O},t(M,[2,83],{66:94,68:x,69:S,70:N,71:L,72:v}),t(G,[2,84]),t(G,[2,85]),t(G,[2,86]),t(G,[2,87]),t(G,[2,88]),t(U,[2,89]),t(U,[2,90]),{8:[1,96],23:99,24:97,30:98,38:22,40:95,42:a,43:23,48:r,54:o,56:h},{16:100,60:p,86:T,100:D,102:F},{41:[1,102],45:101,51:Y},{16:104,60:p,86:T,100:D,102:F},{47:[1,105]},{13:[1,106]},{13:[1,107]},{79:[1,108],81:[1,109]},{22:z,50:Q,59:110,60:W,82:j,84:111,85:112,86:X,87:H,88:V,89:q,90:J},{60:[1,122]},{13:R,55:123},t(w,[2,72]),t(w,[2,138]),{22:z,50:Q,59:124,60:W,61:[1,125],82:j,84:111,85:112,86:X,87:H,88:V,89:q,90:J},t(Z,[2,74]),{16:39,17:40,19:126,60:p,86:T,100:D,102:F,103:B},t(K,[2,16]),t(K,[2,17]),t(K,[2,18]),{11:127,12:tt,39:[2,36]},t(te,[2,9],{16:85,17:86,15:130,18:[1,129],60:p,86:T,100:D,102:F,103:B}),t(te,[2,10]),t(ts,[2,55],{11:131,12:tt}),t(_,[2,7]),{9:[1,132]},t(ti,[2,67]),{16:39,17:40,19:133,60:p,86:T,100:D,102:F,103:B},{13:[1,135],16:39,17:40,19:134,60:p,86:T,100:D,102:F,103:B},t(M,[2,82],{66:136,68:x,69:S,70:N,71:L,72:v}),t(M,[2,81]),{41:[1,137]},{23:99,24:97,30:98,38:22,40:138,42:a,43:23,48:r,54:o,56:h},{8:[1,139],41:[2,38]},{8:[1,140],41:[2,41]},{8:[1,141],41:[2,44]},t(w,[2,48],{39:[1,142]}),{41:[1,143]},t(w,[2,50]),{41:[2,61],45:144,51:Y},{47:[1,145]},{16:39,17:40,19:146,60:p,86:T,100:D,102:F,103:B},t($,[2,91],{13:[1,147]}),t($,[2,93],{13:[1,149],77:[1,148]}),t($,[2,97],{13:[1,150],80:[1,151]}),{13:[1,152]},t($,[2,105],{61:ta}),t(tn,[2,107],{85:154,22:z,50:Q,60:W,82:j,86:X,87:H,88:V,89:q,90:J}),t(tr,[2,109]),t(tr,[2,111]),t(tr,[2,112]),t(tr,[2,113]),t(tr,[2,114]),t(tr,[2,115]),t(tr,[2,116]),t(tr,[2,117]),t(tr,[2,118]),t(tr,[2,119]),t($,[2,106]),t(w,[2,71]),t($,[2,73],{61:ta}),{60:[1,155]},t(K,[2,14]),{39:[2,37]},{13:[1,156]},{15:157,16:85,17:86,60:p,86:T,100:D,102:F,103:B},t(te,[2,12]),t(ts,[2,56]),{1:[2,4]},t(ti,[2,69]),t(ti,[2,68]),{16:39,17:40,19:158,60:p,86:T,100:D,102:F,103:B},t(M,[2,80]),t(w,[2,34]),{41:[1,159]},{23:99,24:97,30:98,38:22,40:160,41:[2,39],42:a,43:23,48:r,54:o,56:h},{23:99,24:97,30:98,38:22,40:161,41:[2,42],42:a,43:23,48:r,54:o,56:h},{23:99,24:97,30:98,38:22,40:162,41:[2,45],42:a,43:23,48:r,54:o,56:h},{45:163,51:Y},t(w,[2,49]),{41:[2,62]},t(w,[2,52],{39:[1,164]}),t($,[2,60]),t($,[2,92]),t($,[2,94]),t($,[2,95],{77:[1,165]}),t($,[2,98]),t($,[2,99],{13:[1,166]}),t($,[2,101],{13:[1,168],77:[1,167]}),{22:z,50:Q,60:W,82:j,84:169,85:112,86:X,87:H,88:V,89:q,90:J},t(tr,[2,110]),t(Z,[2,75]),{14:[1,170]},t(te,[2,11]),t(ti,[2,70]),t(w,[2,35]),{41:[2,40]},{41:[2,43]},{41:[2,46]},{41:[1,171]},{41:[1,173],45:172,51:Y},t($,[2,96]),t($,[2,100]),t($,[2,102]),t($,[2,103],{77:[1,174]}),t(tn,[2,108],{85:154,22:z,50:Q,60:W,82:j,86:X,87:H,88:V,89:q,90:J}),t(ts,[2,8]),t(w,[2,51]),{41:[1,175]},t(w,[2,54]),t($,[2,104]),t(w,[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:(0,c.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var s=Error(t);throw s.hash=e,s}},"parseError"),parse:(0,c.K2)(function(t){var e=this,s=[0],i=[],a=[null],n=[],r=this.table,l="",u=0,o=0,h=0,d=n.slice.call(arguments,1),p=Object.create(this.lexer),A={};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(A[y]=this.yy[y]);p.setInput(t,A),A.lexer=p,A.parser=this,void 0===p.yylloc&&(p.yylloc={});var g=p.yylloc;n.push(g);var m=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof A.parseError?this.parseError=A.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,c.K2)(function(t){s.length=s.length-2*t,a.length=a.length-t,n.length=n.length-t},"popStack"),(0,c.K2)(b,"lex");for(var C,k,E,f,T,D,F,B,_,$={};;){if(E=s[s.length-1],this.defaultActions[E]?f=this.defaultActions[E]:(null==C&&(C=b()),f=r[E]&&r[E][C]),void 0===f||!f.length||!f[0]){var x="";for(D in _=[],r[E])this.terminals_[D]&&D>2&&_.push("'"+this.terminals_[D]+"'");x=p.showPosition?"Parse error on line "+(u+1)+":\n"+p.showPosition()+"\nExpecting "+_.join(", ")+", got '"+(this.terminals_[C]||C)+"'":"Parse error on line "+(u+1)+": Unexpected "+(1==C?"end of input":"'"+(this.terminals_[C]||C)+"'"),this.parseError(x,{text:p.match,token:this.terminals_[C]||C,line:p.yylineno,loc:g,expected:_})}if(f[0]instanceof Array&&f.length>1)throw Error("Parse Error: multiple actions possible at state: "+E+", token: "+C);switch(f[0]){case 1:s.push(C),a.push(p.yytext),n.push(p.yylloc),s.push(f[1]),C=null,k?(C=k,k=null):(o=p.yyleng,l=p.yytext,u=p.yylineno,g=p.yylloc,h>0&&h--);break;case 2:if(F=this.productions_[f[1]][1],$.$=a[a.length-F],$._$={first_line:n[n.length-(F||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(F||1)].first_column,last_column:n[n.length-1].last_column},m&&($._$.range=[n[n.length-(F||1)].range[0],n[n.length-1].range[1]]),void 0!==(T=this.performAction.apply($,[l,o,u,A,f[1],a,n].concat(d))))return T;F&&(s=s.slice(0,-1*F*2),a=a.slice(0,-1*F),n=n.slice(0,-1*F)),s.push(this.productions_[f[1]][0]),a.push($.$),n.push($._$),B=r[s[s.length-2]][s[s.length-1]],s.push(B);break;case 3:return!0}}return!0},"parse")};function tu(){this.yy={}}return tl.lexer={EOF:1,parseError:(0,c.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,c.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,c.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,c.K2)(function(t){var e=t.length,s=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),s.length-1&&(this.yylineno-=s.length-1);var a=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:s?(s.length===i.length?this.yylloc.first_column:0)+i[i.length-s.length].length-s[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[a[0],a[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,c.K2)(function(){return this._more=!0,this},"more"),reject:(0,c.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,c.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,c.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,c.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,c.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,c.K2)(function(t,e){var s,i,a;if(this.options.backtrack_lexer&&(a={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&&(a.yylloc.range=this.yylloc.range.slice(0))),(i=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],s=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s)return s;if(this._backtrack)for(var n in a)this[n]=a[n];return!1},"test_match"),next:(0,c.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,s,i,a=this._currentRules(),n=0;n<a.length;n++)if((s=this._input.match(this.rules[a[n]]))&&(!e||s[0].length>e[0].length)){if(e=s,i=n,this.options.backtrack_lexer){if(!1!==(t=this.test_match(s,a[n])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,a[i]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,c.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,c.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,c.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,c.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,c.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,c.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,c.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:(0,c.K2)(function(t,e,s,i){switch(s){case 0:return 62;case 1:return 63;case 2:return 64;case 3:return 65;case 4:case 5:case 14:case 31:case 37:case 41:case 48:break;case 6:return this.begin("acc_title"),33;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),35;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:case 19:case 22:case 24:case 59:case 62:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:case 36:return 8;case 15:case 16:return 7;case 17:case 38:case 46:return"EDGE_STATE";case 18:this.begin("callback_name");break;case 20:this.popState(),this.begin("callback_args");break;case 21:return 79;case 23:return 80;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;case 30:case 40:return this.popState(),8;case 32:return this.begin("namespace-body"),39;case 33:this.popState(),this.less(0);break;case 34:case 44:return this.popState(),41;case 35:case 45:return"EOF_IN_STRUCT";case 39:return this.begin("class"),48;case 42:return this.popState(),this.popState(),41;case 43:return this.begin("class-body"),39;case 47:return"OPEN_IN_STRUCT";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 60:return"GENERICTYPE";case 61:this.begin("generic");break;case 63:return"BQUOTE_STR";case 64:this.begin("bqstring");break;case 65:case 66:case 67:case 68:return 77;case 69:case 70:return 69;case 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:case 86:return 89;case 87:return 90;case 88: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: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}}},(0,c.K2)(tu,"Parser"),tu.prototype=tl,tl.Parser=tu,new tu}();p.parser=p;var A=p,y=["#","+","~","-",""],g=class{static{(0,c.K2)(this,"ClassMember")}constructor(t,e){this.memberType=e,this.visibility="",this.classifier="",this.text="";let s=(0,o.jZ)(t,(0,o.D7)());this.parseMember(s)}getDisplayDetails(){let t=this.visibility+(0,o.QO)(this.id);return"method"===this.memberType&&(t+=`(${(0,o.QO)(this.parameters.trim())})`,this.returnType&&(t+=" : "+(0,o.QO)(this.returnType))),{displayText:t=t.trim(),cssStyle:this.parseClassifier()}}parseMember(t){let e="";if("method"===this.memberType){let s=/([#+~-])?(.+)\((.*)\)([\s$*])?(.*)([$*])?/.exec(t);if(s){let t=s[1]?s[1].trim():"";if(y.includes(t)&&(this.visibility=t),this.id=s[2],this.parameters=s[3]?s[3].trim():"",e=s[4]?s[4].trim():"",this.returnType=s[5]?s[5].trim():"",""===e){let t=this.returnType.substring(this.returnType.length-1);/[$*]/.exec(t)&&(e=t,this.returnType=this.returnType.substring(0,this.returnType.length-1))}}}else{let s=t.length,i=t.substring(0,1),a=t.substring(s-1);y.includes(i)&&(this.visibility=i),/[$*]/.exec(a)&&(e=a),this.id=t.substring(+(""!==this.visibility),""===e?s:s-1)}this.classifier=e,this.id=this.id.startsWith(" ")?" "+this.id.trim():this.id.trim();let s=`${this.visibility?"\\"+this.visibility:""}${(0,o.QO)(this.id)}${"method"===this.memberType?`(${(0,o.QO)(this.parameters)})${this.returnType?" : "+(0,o.QO)(this.returnType):""}`:""}`;this.text=s.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""}}},m="classId-",b=0,C=(0,c.K2)(t=>o.Y2.sanitizeText(t,(0,o.D7)()),"sanitizeText"),k=class t{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=(0,c.K2)(t=>{let e=(0,a.Ck)();(0,h.Ltv)(t).select("svg").selectAll("g").filter(function(){return null!==(0,h.Ltv)(this).attr("title")}).on("mouseover",t=>{let s=(0,h.Ltv)(t.currentTarget),i=s.attr("title");if(!i)return;let a=t.currentTarget.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.html(d.A.sanitize(i)).style("left",`${window.scrollX+a.left+a.width/2}px`).style("top",`${window.scrollY+a.bottom+4}px`),s.classed("hover",!0)}).on("mouseout",t=>{e.transition().duration(500).style("opacity",0),(0,h.Ltv)(t.currentTarget).classed("hover",!1)})},"setupToolTips"),this.direction="TB",this.setAccTitle=o.SV,this.getAccTitle=o.iN,this.setAccDescription=o.EI,this.getAccDescription=o.m7,this.setDiagramTitle=o.ke,this.getDiagramTitle=o.ab,this.getConfig=(0,c.K2)(()=>(0,o.D7)().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{(0,c.K2)(this,"ClassDB")}splitClassNameAndType(t){let e=o.Y2.sanitizeText(t,(0,o.D7)()),s="",i=e;if(e.indexOf("~")>0){let t=e.split("~");i=C(t[0]),s=C(t[1])}return{className:i,type:s}}setClassLabel(t,e){let s=o.Y2.sanitizeText(t,(0,o.D7)());e&&(e=C(e));let{className:i}=this.splitClassNameAndType(s);this.classes.get(i).label=e,this.classes.get(i).text=`${e}${this.classes.get(i).type?`<${this.classes.get(i).type}>`:""}`}addClass(t){let e=o.Y2.sanitizeText(t,(0,o.D7)()),{className:s,type:i}=this.splitClassNameAndType(e);if(this.classes.has(s))return;let a=o.Y2.sanitizeText(s,(0,o.D7)());this.classes.set(a,{id:a,type:i,label:a,text:`${a}${i?`&lt;${i}&gt;`:""}`,shape:"classBox",cssClasses:"default",methods:[],members:[],annotations:[],styles:[],domId:m+a+"-"+b}),b++}addInterface(t,e){let s={id:`interface${this.interfaces.length}`,label:t,classId:e};this.interfaces.push(s)}setDiagramId(t){this.diagramId=t}lookUpDomId(t){let e=o.Y2.sanitizeText(t,(0,o.D7)());if(this.classes.has(e)){let t=this.classes.get(e).domId;return this.diagramId?`${this.diagramId}-${t}`:t}throw Error("Class not found: "+e)}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",(0,o.IU)()}getClass(t){return this.classes.get(t)}getClasses(){return this.classes}getRelations(){return this.relations}getNote(t){let e="number"==typeof t?`note${t}`:t;return this.notes.get(e)}getNotes(){return this.notes}addRelation(t){c.Rm.debug("Adding relation: "+JSON.stringify(t));let e=[this.relationType.LOLLIPOP,this.relationType.AGGREGATION,this.relationType.COMPOSITION,this.relationType.DEPENDENCY,this.relationType.EXTENSION];t.relation.type1!==this.relationType.LOLLIPOP||e.includes(t.relation.type2)?t.relation.type2!==this.relationType.LOLLIPOP||e.includes(t.relation.type1)?(this.addClass(t.id1),this.addClass(t.id2)):(this.addClass(t.id1),this.addInterface(t.id2,t.id1),t.id2=`interface${this.interfaces.length-1}`):(this.addClass(t.id2),this.addInterface(t.id1,t.id2),t.id1=`interface${this.interfaces.length-1}`),t.id1=this.splitClassNameAndType(t.id1).className,t.id2=this.splitClassNameAndType(t.id2).className,t.relationTitle1=o.Y2.sanitizeText(t.relationTitle1.trim(),(0,o.D7)()),t.relationTitle2=o.Y2.sanitizeText(t.relationTitle2.trim(),(0,o.D7)()),this.relations.push(t)}addAnnotation(t,e){let s=this.splitClassNameAndType(t).className;this.classes.get(s).annotations.push(e)}addMember(t,e){this.addClass(t);let s=this.splitClassNameAndType(t).className,i=this.classes.get(s);if("string"==typeof e){let t=e.trim();t.startsWith("<<")&&t.endsWith(">>")?i.annotations.push(C(t.substring(2,t.length-2))):t.indexOf(")")>0?i.methods.push(new g(t,"method")):t&&i.members.push(new g(t,"attribute"))}}addMembers(t,e){Array.isArray(e)&&(e.reverse(),e.forEach(e=>this.addMember(t,e)))}addNote(t,e){let s=this.notes.size,i={id:`note${s}`,class:e,text:t,index:s};return this.notes.set(i.id,i),i.id}cleanupLabel(t){return t.startsWith(":")&&(t=t.substring(1)),C(t.trim())}setCssClass(t,e){t.split(",").forEach(t=>{let s=t;/\d/.exec(t[0])&&(s=m+s);let i=this.classes.get(s);i&&(i.cssClasses+=" "+e)})}defineClass(t,e){for(let s of t){let t=this.styleClasses.get(s);void 0===t&&(t={id:s,styles:[],textStyles:[]},this.styleClasses.set(s,t)),e&&e.forEach(e=>{if(/color/.exec(e)){let s=e.replace("fill","bgFill");t.textStyles.push(s)}t.styles.push(e)}),this.classes.forEach(t=>{t.cssClasses.includes(s)&&t.styles.push(...e.flatMap(t=>t.split(",")))})}}setTooltip(t,e){t.split(",").forEach(t=>{void 0!==e&&(this.classes.get(t).tooltip=C(e))})}getTooltip(t,e){return e&&this.namespaces.has(e)?this.namespaces.get(e).classes.get(t).tooltip:this.classes.get(t).tooltip}setLink(t,e,s){let i=(0,o.D7)();t.split(",").forEach(t=>{let a=t;/\d/.exec(t[0])&&(a=m+a);let n=this.classes.get(a);n&&(n.link=u._K.formatUrl(e,i),"sandbox"===i.securityLevel?n.linkTarget="_top":"string"==typeof s?n.linkTarget=C(s):n.linkTarget="_blank")}),this.setCssClass(t,"clickable")}setClickEvent(t,e,s){t.split(",").forEach(t=>{this.setClickFunc(t,e,s),this.classes.get(t).haveCallback=!0}),this.setCssClass(t,"clickable")}setClickFunc(t,e,s){let i=o.Y2.sanitizeText(t,(0,o.D7)());if("loose"===(0,o.D7)().securityLevel&&void 0!==e&&this.classes.has(i)){let t=[];if("string"==typeof s){t=s.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let e=0;e<t.length;e++){let s=t[e].trim();s.startsWith('"')&&s.endsWith('"')&&(s=s.substr(1,s.length-2)),t[e]=s}}0===t.length&&t.push(i),this.functions.push(()=>{let s=this.lookUpDomId(i),a=document.querySelector(`[id="${s}"]`);null!==a&&a.addEventListener("click",()=>{u._K.runFunc(e,...t)},!1)})}}bindFunctions(t){this.functions.forEach(e=>{e(t)})}escapeHtml(t){return t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}getDirection(){return this.direction}setDirection(t){this.direction=t}static resolveQualifiedId(t,e){let s=e.at(-1);return s?`${s}.${t}`:t}static getAncestorIds(t){let e=t.split("."),s=Array(e.length);s[0]=e[0];for(let t=1;t<e.length;t++)s[t]=`${s[t-1]}.${e[t]}`;return s}createNamespaceNode(t,e,s,i=!1){return{id:t,label:e,classes:new Map,notes:new Map,children:new Map,domId:m+t+"-"+this.namespaceCounter++,parent:s,explicit:i}}linkParentChild(t,e){let s=this.namespaces.get(t),i=this.namespaces.get(e);s&&i&&(s.children.has(e)||s.children.set(e,i),i.parent??=t)}addNamespace(e,s){let i=t.resolveQualifiedId(e,this.namespaceStack);if(this.namespaceStack.push(i),this.namespaces.has(i)){let t=this.namespaces.get(i);return t.explicit=!0,s&&(t.label=s),i}let a=i.split("."),n=t.getAncestorIds(i);for(let t=0;t<n.length;t++){let e=n[t],i=t>0?n[t-1]:void 0,r=t===n.length-1,l=r&&s?s:a[t];this.namespaces.has(e)?r&&(this.namespaces.get(e).explicit=!0):this.namespaces.set(e,this.createNamespaceNode(e,l,i,r)),i&&this.linkParentChild(i,e)}return i}popNamespace(){this.namespaceStack.pop()}getNamespace(t){return this.namespaces.get(t)}getNamespaces(){return this.namespaces}addClassesToNamespace(t,e,s){if(this.namespaces.has(t)){for(let s of e){let{className:e}=this.splitClassNameAndType(s),i=this.getClass(e);i.parent=t,this.namespaces.get(t).classes.set(e,i)}for(let e of s){let s=this.getNote(e);s.parent=t,this.namespaces.get(t).notes.set(e,s)}}}setCssStyle(t,e){let s=this.classes.get(t);if(e&&s)for(let t of e)t.includes(",")?s.styles.push(...t.split(",")):s.styles.push(t)}getArrowMarker(t){let e;switch(t){case 0:e="aggregation";break;case 1:e="extension";break;case 2:e="composition";break;case 3:e="dependency";break;case 4:e="lollipop";break;default:e="none"}return e}resolveExplicitAncestor(t){let e=t;for(;e;){let t=this.namespaces.get(e);if(!t)break;if(t.explicit)return e;e=t.parent}}getData(){let t=[],e=[],s=(0,o.D7)(),i=s.class?.hierarchicalNamespaces??!0;for(let e of this.namespaces.values()){if(!i&&!e.explicit)continue;let a={id:e.id,label:i?e.label:e.id,isGroup:!0,padding:s.class.padding??16,shape:"rect",cssStyles:[],look:s.look,parentId:i?e.parent:void 0};t.push(a)}for(let e of this.classes.values()){let a=i?e.parent:this.resolveExplicitAncestor(e.parent),n={...e,type:void 0,isGroup:!1,parentId:a,look:s.look};t.push(n)}for(let a of this.notes.values()){let n=i?a.parent:this.resolveExplicitAncestor(a.parent),r={id:a.id,label:a.text,isGroup:!1,shape:"note",padding:s.class.padding??6,cssStyles:["text-align: left","white-space: nowrap",`fill: ${s.themeVariables.noteBkgColor}`,`stroke: ${s.themeVariables.noteBorderColor}`],look:s.look,parentId:n,labelType:"markdown"};t.push(r);let l=this.classes.get(a.class)?.id;if(l){let t={id:`edgeNote${a.index}`,start:a.id,end:l,type:"normal",thickness:"normal",classes:"relation",arrowTypeStart:"none",arrowTypeEnd:"none",arrowheadStyle:"",labelStyle:[""],style:["fill: none"],pattern:"dotted",look:s.look};e.push(t)}}for(let e of this.interfaces){let i={id:e.id,label:e.label,isGroup:!1,shape:"rect",cssStyles:["opacity: 0;"],look:s.look};t.push(i)}let a=0;for(let t of this.relations){a++;let i={id:(0,u.rY)(t.id1,t.id2,{prefix:"id",counter:a}),start:t.id1,end:t.id2,type:"normal",label:t.title,labelpos:"c",thickness:"normal",classes:"relation",arrowTypeStart:this.getArrowMarker(t.relation.type1),arrowTypeEnd:this.getArrowMarker(t.relation.type2),startLabelRight:"none"===t.relationTitle1?"":t.relationTitle1,endLabelLeft:"none"===t.relationTitle2?"":t.relationTitle2,arrowheadStyle:"",labelStyle:["display: inline-block"],style:t.style||"",pattern:1==t.relation.lineType?"dashed":"solid",look:s.look,labelType:"markdown"};e.push(i)}return{nodes:t,edges:e,other:{},config:s,direction:this.getDirection()}}},E=(0,c.K2)(t=>`g.classGroup text {
16
+ fill: ${t.nodeBorder||t.classText};
17
+ stroke: none;
18
+ font-family: ${t.fontFamily};
19
+ font-size: 10px;
20
+
21
+ .title {
22
+ font-weight: bolder;
23
+ }
24
+
25
+ }
26
+
27
+ .cluster-label text {
28
+ fill: ${t.titleColor};
29
+ }
30
+ .cluster-label span {
31
+ color: ${t.titleColor};
32
+ }
33
+ .cluster-label span p {
34
+ background-color: transparent;
35
+ }
36
+
37
+ .cluster rect {
38
+ fill: ${t.clusterBkg};
39
+ stroke: ${t.clusterBorder};
40
+ stroke-width: 1px;
41
+ }
42
+
43
+ .cluster text {
44
+ fill: ${t.titleColor};
45
+ }
46
+
47
+ .cluster span {
48
+ color: ${t.titleColor};
49
+ }
50
+
51
+ .nodeLabel, .edgeLabel {
52
+ color: ${t.classText};
53
+ }
54
+
55
+ .noteLabel .nodeLabel, .noteLabel .edgeLabel {
56
+ color: ${t.noteTextColor};
57
+ }
58
+ .edgeLabel .label rect {
59
+ fill: ${t.mainBkg};
60
+ }
61
+ .label text {
62
+ fill: ${t.classText};
63
+ }
64
+
65
+ .labelBkg {
66
+ background: ${t.mainBkg};
67
+ }
68
+ .edgeLabel .label span {
69
+ background: ${t.mainBkg};
70
+ }
71
+
72
+ .classTitle {
73
+ font-weight: bolder;
74
+ }
75
+ .node rect,
76
+ .node circle,
77
+ .node ellipse,
78
+ .node polygon,
79
+ .node path {
80
+ fill: ${t.mainBkg};
81
+ stroke: ${t.nodeBorder};
82
+ stroke-width: ${t.strokeWidth};
83
+ }
84
+
85
+
86
+ .divider {
87
+ stroke: ${t.nodeBorder};
88
+ stroke-width: 1;
89
+ }
90
+
91
+ g.clickable {
92
+ cursor: pointer;
93
+ }
94
+
95
+ g.classGroup rect {
96
+ fill: ${t.mainBkg};
97
+ stroke: ${t.nodeBorder};
98
+ }
99
+
100
+ g.classGroup line {
101
+ stroke: ${t.nodeBorder};
102
+ stroke-width: 1;
103
+ }
104
+
105
+ .classLabel .box {
106
+ stroke: none;
107
+ stroke-width: 0;
108
+ fill: ${t.mainBkg};
109
+ opacity: 0.5;
110
+ }
111
+
112
+ .classLabel .label {
113
+ fill: ${t.nodeBorder};
114
+ font-size: 10px;
115
+ }
116
+
117
+ .relation {
118
+ stroke: ${t.lineColor};
119
+ stroke-width: ${t.strokeWidth};
120
+ fill: none;
121
+ }
122
+
123
+ .dashed-line{
124
+ stroke-dasharray: 3;
125
+ }
126
+
127
+ .dotted-line{
128
+ stroke-dasharray: 1 2;
129
+ }
130
+
131
+ [id$="-compositionStart"], .composition {
132
+ fill: ${t.lineColor} !important;
133
+ stroke: ${t.lineColor} !important;
134
+ stroke-width: 1;
135
+ }
136
+
137
+ [id$="-compositionEnd"], .composition {
138
+ fill: ${t.lineColor} !important;
139
+ stroke: ${t.lineColor} !important;
140
+ stroke-width: 1;
141
+ }
142
+
143
+ [id$="-dependencyStart"], .dependency {
144
+ fill: ${t.lineColor} !important;
145
+ stroke: ${t.lineColor} !important;
146
+ stroke-width: 1;
147
+ }
148
+
149
+ [id$="-dependencyEnd"], .dependency {
150
+ fill: ${t.lineColor} !important;
151
+ stroke: ${t.lineColor} !important;
152
+ stroke-width: 1;
153
+ }
154
+
155
+ [id$="-extensionStart"], .extension {
156
+ fill: transparent !important;
157
+ stroke: ${t.lineColor} !important;
158
+ stroke-width: 1;
159
+ }
160
+
161
+ [id$="-extensionEnd"], .extension {
162
+ fill: transparent !important;
163
+ stroke: ${t.lineColor} !important;
164
+ stroke-width: 1;
165
+ }
166
+
167
+ [id$="-aggregationStart"], .aggregation {
168
+ fill: transparent !important;
169
+ stroke: ${t.lineColor} !important;
170
+ stroke-width: 1;
171
+ }
172
+
173
+ [id$="-aggregationEnd"], .aggregation {
174
+ fill: transparent !important;
175
+ stroke: ${t.lineColor} !important;
176
+ stroke-width: 1;
177
+ }
178
+
179
+ [id$="-lollipopStart"], .lollipop {
180
+ fill: ${t.mainBkg} !important;
181
+ stroke: ${t.lineColor} !important;
182
+ stroke-width: 1;
183
+ }
184
+
185
+ [id$="-lollipopEnd"], .lollipop {
186
+ fill: ${t.mainBkg} !important;
187
+ stroke: ${t.lineColor} !important;
188
+ stroke-width: 1;
189
+ }
190
+
191
+ .edgeTerminals {
192
+ font-size: 11px;
193
+ line-height: initial;
194
+ }
195
+
196
+ .classTitleText {
197
+ text-anchor: middle;
198
+ font-size: 18px;
199
+ fill: ${t.textColor};
200
+ }
201
+
202
+ .edgeLabel[data-look="neo"] {
203
+ background-color: ${t.edgeLabelBackground};
204
+ p {
205
+ background-color: ${t.edgeLabelBackground};
206
+ }
207
+ rect {
208
+ opacity: 0.5;
209
+ background-color: ${t.edgeLabelBackground};
210
+ fill: ${t.edgeLabelBackground};
211
+ }
212
+ text-align: center;
213
+ }
214
+ ${(0,i.o)()}
215
+ `,"getStyles"),f=(0,c.K2)((t,e="TB")=>{if(!t.doc)return e;let s=e;for(let e of t.doc)"dir"===e.stmt&&(s=e.value);return s},"getDir"),T={getClasses:(0,c.K2)(function(t,e){return e.db.getClasses()},"getClasses"),draw:(0,c.K2)(async function(t,e,s,i){c.Rm.info("REF0:"),c.Rm.info("Drawing class diagram (v3)",e);let{securityLevel:a,state:h,layout:d}=(0,o.D7)();i.db.setDiagramId(e);let p=i.db.getData(),A=(0,n.A)(e,a);p.type=i.type,p.layoutAlgorithm=(0,l.q7)(d),p.nodeSpacing=h?.nodeSpacing||50,p.rankSpacing=h?.rankSpacing||50,p.markers=["aggregation","extension","composition","dependency","lollipop"],p.diagramId=e,await (0,l.XX)(p,A),u._K.insertTitle(A,"classDiagramTitleText",h?.titleTopMargin??25,i.db.getDiagramTitle()),(0,r.P)(A,8,"classDiagram",h?.useMaxWidth??!0)},"draw"),getDir:f}}}]);
_next/static/chunks/4290.6ee778437eacd4f3.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4290],{1163:(e,r,t)=>{t.d(r,{I:()=>o});var a=t(4839),n=class extends a.dg{static{(0,a.K2)(this,"TreeViewValueConverter")}runCustomConverter(e,r,t){return"INDENTATION"===e.name?r?.length||0:"STRING2"===e.name?r.substring(1,r.length-1):void 0}},i=class extends a.mR{static{(0,a.K2)(this,"TreeViewTokenBuilder")}constructor(){super(["treeView-beta"])}},s={parser:{TokenBuilder:(0,a.K2)(()=>new i,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new n,"ValueConverter")}};function o(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.CZ,s);return r.ServiceRegistry.register(t),{shared:r,TreeView:t}}(0,a.K2)(o,"createTreeViewServices")},1345:(e,r,t)=>{t.d(r,{$:()=>s});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"PacketTokenBuilder")}constructor(){super(["packet"])}},i={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new a.Tm,"ValueConverter")}};function s(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.p5,i);return r.ServiceRegistry.register(t),{shared:r,Packet:t}}(0,a.K2)(s,"createPacketServices")},1516:(e,r,t)=>{t.d(r,{J:()=>s});var a=t(4839),n=class extends a.dg{static{(0,a.K2)(this,"WardleyValueConverter")}runCustomConverter(e,r,t){return"LINK_LABEL"===e.name.toUpperCase()?r.substring(1).trim():void 0}},i={parser:{ValueConverter:(0,a.K2)(()=>new n,"ValueConverter")}};function s(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.Xr,i);return r.ServiceRegistry.register(t),{shared:r,Wardley:t}}(0,a.K2)(s,"createWardleyServices")},1669:(e,r,t)=>{t.d(r,{f:()=>o});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"PieTokenBuilder")}constructor(){super(["pie","showData"])}},i=class extends a.dg{static{(0,a.K2)(this,"PieValueConverter")}runCustomConverter(e,r,t){if("PIE_SECTION_LABEL"===e.name)return r.replace(/"/g,"").trim()}},s={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new i,"ValueConverter")}};function o(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.D_,s);return r.ServiceRegistry.register(t),{shared:r,Pie:t}}(0,a.K2)(o,"createPieServices")},3281:(e,r,t)=>{t.d(r,{S:()=>o});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"ArchitectureTokenBuilder")}constructor(){super(["architecture"])}},i=class extends a.dg{static{(0,a.K2)(this,"ArchitectureValueConverter")}runCustomConverter(e,r,t){if("ARCH_ICON"===e.name)return r.replace(/[()]/g,"").trim();if("ARCH_TEXT_ICON"===e.name)return r.replace(/["()]/g,"");if("ARCH_TITLE"===e.name){let e=r.replace(/^\[|]$/g,"").trim();return(e.startsWith('"')&&e.endsWith('"')||e.startsWith("'")&&e.endsWith("'"))&&(e=(e=e.slice(1,-1)).replace(/\\"/g,'"').replace(/\\'/g,"'")),e.trim()}}},s={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new i,"ValueConverter")}};function o(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.wV,s);return r.ServiceRegistry.register(t),{shared:r,Architecture:t}}(0,a.K2)(o,"createArchitectureServices")},4290:(e,r,t)=>{t.d(r,{F5:()=>a.F5,qg:()=>s}),t(5625),t(4752),t(1516),t(4511),t(9854),t(1345),t(1669),t(1163),t(3281),t(6934);var a=t(4839),n={},i={info:(0,a.K2)(async()=>{let{createInfoServices:e}=await t.e(921).then(t.bind(t,921));n.info=e().Info.parser.LangiumParser},"info"),packet:(0,a.K2)(async()=>{let{createPacketServices:e}=await t.e(9869).then(t.bind(t,9869));n.packet=e().Packet.parser.LangiumParser},"packet"),pie:(0,a.K2)(async()=>{let{createPieServices:e}=await t.e(104).then(t.bind(t,104));n.pie=e().Pie.parser.LangiumParser},"pie"),treeView:(0,a.K2)(async()=>{let{createTreeViewServices:e}=await t.e(7635).then(t.bind(t,7635));n.treeView=e().TreeView.parser.LangiumParser},"treeView"),architecture:(0,a.K2)(async()=>{let{createArchitectureServices:e}=await t.e(6091).then(t.bind(t,6091));n.architecture=e().Architecture.parser.LangiumParser},"architecture"),gitGraph:(0,a.K2)(async()=>{let{createGitGraphServices:e}=await t.e(5198).then(t.bind(t,5198));n.gitGraph=e().GitGraph.parser.LangiumParser},"gitGraph"),eventmodeling:(0,a.K2)(async()=>{let{createEventModelingServices:e}=await t.e(1166).then(t.bind(t,1166));n.eventmodeling=e().EventModel.parser.LangiumParser},"eventmodeling"),radar:(0,a.K2)(async()=>{let{createRadarServices:e}=await t.e(2065).then(t.bind(t,2065));n.radar=e().Radar.parser.LangiumParser},"radar"),treemap:(0,a.K2)(async()=>{let{createTreemapServices:e}=await t.e(2487).then(t.bind(t,2487));n.treemap=e().Treemap.parser.LangiumParser},"treemap"),wardley:(0,a.K2)(async()=>{let{createWardleyServices:e}=await t.e(8050).then(t.bind(t,8050));n.wardley=e().Wardley.parser.LangiumParser},"wardley")};async function s(e,r){let t=i[e];if(!t)throw Error(`Unknown diagram type: ${e}`);n[e]||await t();let a=n[e].parse(r);if(a.lexerErrors.length>0||a.parserErrors.length>0)throw new o(a);return a.value}(0,a.K2)(s,"parse");var o=class extends Error{constructor(e){super(`Parsing failed: ${e.lexerErrors.map(e=>{let r=void 0===e.line||isNaN(e.line)?"?":e.line,t=void 0===e.column||isNaN(e.column)?"?":e.column;return`Lexer error on line ${r}, column ${t}: ${e.message}`}).join("\n")} ${e.parserErrors.map(e=>{let r=void 0===e.token.startLine||isNaN(e.token.startLine)?"?":e.token.startLine,t=void 0===e.token.startColumn||isNaN(e.token.startColumn)?"?":e.token.startColumn;return`Parse error on line ${r}, column ${t}: ${e.message}`}).join("\n")}`),this.result=e}static{(0,a.K2)(this,"MermaidParseError")}}},4511:(e,r,t)=>{t.d(r,{b:()=>s});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"GitGraphTokenBuilder")}constructor(){super(["gitGraph"])}},i={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new a.Tm,"ValueConverter")}};function s(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.d$,i);return r.ServiceRegistry.register(t),{shared:r,GitGraph:t}}(0,a.K2)(s,"createGitGraphServices")},4752:(e,r,t)=>{t.d(r,{d:()=>u});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"TreemapTokenBuilder")}constructor(){super(["treemap"])}},i=/classDef\s+([A-Z_a-z]\w+)(?:\s+([^\n\r;]*))?;?/,s=class extends a.dg{static{(0,a.K2)(this,"TreemapValueConverter")}runCustomConverter(e,r,t){if("NUMBER2"===e.name)return parseFloat(r.replace(/,/g,""));if("SEPARATOR"===e.name)return r.substring(1,r.length-1);if("STRING2"===e.name)return r.substring(1,r.length-1);if("INDENTATION"===e.name)return r.length;if("ClassDef"===e.name){if("string"!=typeof r)return r;let e=i.exec(r);if(e)return{$type:"ClassDefStatement",className:e[1],styleText:e[2]||void 0}}}};function o(e){let r=e.validation.TreemapValidator,t=e.validation.ValidationRegistry;if(t){let e={Treemap:r.checkSingleRoot.bind(r)};t.register(e,r)}}(0,a.K2)(o,"registerValidationChecks");var l=class{static{(0,a.K2)(this,"TreemapValidator")}checkSingleRoot(e,r){let t;for(let a of e.TreemapRows)a.item&&(void 0===t&&void 0===a.indent?t=0:void 0===a.indent?r("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}):void 0!==t&&t>=parseInt(a.indent,10)&&r("error","Multiple root nodes are not allowed in a treemap.",{node:a,property:"item"}))}},c={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new s,"ValueConverter")},validation:{TreemapValidator:(0,a.K2)(()=>new l,"TreemapValidator")}};function u(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.XE,c);return r.ServiceRegistry.register(t),o(t),{shared:r,Treemap:t}}(0,a.K2)(u,"createTreemapServices")},5625:(e,r,t)=>{t.d(r,{f:()=>s});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"RadarTokenBuilder")}constructor(){super(["radar-beta"])}},i={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new a.Tm,"ValueConverter")}};function s(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.Bg,i);return r.ServiceRegistry.register(t),{shared:r,Radar:t}}(0,a.K2)(s,"createRadarServices")},6934:(e,r,t)=>{t.d(r,{g:()=>v});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"EventModelingTokenBuilder")}constructor(){super(["eventmodeling"])}},i=new Set(["cmd","command"]),s=new Set(["evt","event"]),o=new Set(["rmo","readmodel"]),l=new Set(["pcr","processor"]),c=new Set(["ui"]);function u(e){let r=e.validation.EventModelingValidator,t=e.validation.ValidationRegistry;if(t){let e={EmTimeFrame:r.checkSourceFrameTypes.bind(r),EmResetFrame:r.checkSourceFrameTypes.bind(r)};t.register(e,r)}}(0,a.K2)(u,"registerValidationChecks");var d=class{static{(0,a.K2)(this,"EventModelingValidator")}checkSourceFrameTypes(e,r){0!==e.sourceFrames.length&&(i.has(e.modelEntityType)?this.validateSources(e,new Set([...c,...l]),"command","ui or processor",r):s.has(e.modelEntityType)?this.validateSources(e,i,"event","command",r):o.has(e.modelEntityType)?this.validateSources(e,s,"read model","event",r):l.has(e.modelEntityType)?this.validateSources(e,o,"processor","read model",r):c.has(e.modelEntityType)&&this.validateSources(e,o,"ui","read model",r))}validateSources(e,r,t,a,n){for(let i of e.sourceFrames){let s=i.ref;void 0===s||r.has(s.modelEntityType)||n("error",`A ${t} can only receive input from a ${a}, not from '${s.modelEntityType}'.`,{node:e,property:"sourceFrames"})}}},m={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new a.Tm,"ValueConverter")},validation:{EventModelingValidator:(0,a.K2)(()=>new d,"EventModelingValidator")}};function v(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.x0,m);return r.ServiceRegistry.register(t),u(t),{shared:r,EventModel:t}}(0,a.K2)(v,"createEventModelingServices")},9854:(e,r,t)=>{t.d(r,{v:()=>s});var a=t(4839),n=class extends a.mR{static{(0,a.K2)(this,"InfoTokenBuilder")}constructor(){super(["info","showInfo"])}},i={parser:{TokenBuilder:(0,a.K2)(()=>new n,"TokenBuilder"),ValueConverter:(0,a.K2)(()=>new a.Tm,"ValueConverter")}};function s(e=a.DD){let r=(0,a.WQ)((0,a.uM)(e),a.sr),t=(0,a.WQ)((0,a.tG)({shared:r}),a.FZ,i);return r.ServiceRegistry.register(t),{shared:r,Info:t}}(0,a.K2)(s,"createInfoServices")}}]);
_next/static/chunks/4460.f9ae9bbf1d459b8b.js ADDED
@@ -0,0 +1,79 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4460],{1184:(e,t,s)=>{s.d(t,{A:()=>n});var i=s(316),r=s(5508),n=(0,i.K2)((e,t)=>{let s;return"sandbox"===t&&(s=(0,r.Ltv)("#i"+e)),("sandbox"===t?(0,r.Ltv)(s.nodes()[0].contentDocument.body):(0,r.Ltv)("body")).select(`[id="${e}"]`)},"getDiagramElement")},2888:(e,t,s)=>{s.d(t,{P:()=>n});var i=s(669),r=s(316),n=(0,r.K2)((e,t,s,n)=>{e.attr("class",s);let{width:o,height:c,x:h,y:u}=a(e,t);(0,i.a$)(e,c,o,n);let y=l(h,u,o,c,t);e.attr("viewBox",y),r.Rm.debug(`viewBox configured: ${y} with padding: ${t}`)},"setupViewPortForSVG"),a=(0,r.K2)((e,t)=>{let s=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:s.width+2*t,height:s.height+2*t,x:s.x,y:s.y}},"calculateDimensionsWithPadding"),l=(0,r.K2)((e,t,s,i,r)=>`${e-r} ${t-r} ${s} ${i}`,"createViewBox")},4460:(e,t,s)=>{s.d(t,{diagram:()=>E});var i=s(1184),r=s(2888),n=s(1593);s(4982),s(1431),s(5407),s(7920),s(3148),s(1538);var a=s(3736),l=s(669),o=s(316),c=function(){var e=(0,o.K2)(function(e,t,s,i){for(s=s||{},i=e.length;i--;s[e[i]]=t);return s},"o"),t=[1,3],s=[1,4],i=[1,5],r=[1,6],n=[5,6,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],a=[1,22],l=[2,7],c=[1,26],h=[1,27],u=[1,28],y=[1,29],m=[1,33],d=[1,34],E=[1,35],p=[1,36],R=[1,37],g=[1,38],_=[1,24],f=[1,31],S=[1,32],I=[1,30],b=[1,39],T=[1,40],k=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,77,89,90],N=[1,61],q=[89,90],C=[5,8,9,11,13,21,22,23,24,27,29,41,42,43,44,45,46,54,61,63,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],A=[27,29],L=[1,70],$=[1,71],v=[1,72],x=[1,73],w=[1,74],O=[1,75],D=[1,76],M=[1,83],F=[1,80],K=[1,84],P=[1,85],V=[1,86],U=[1,87],Y=[1,88],B=[1,89],Q=[1,90],H=[1,91],W=[1,92],j=[5,8,9,11,13,21,22,23,24,27,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],z=[63,64],G=[1,101],X=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,76,77,89,90],J=[5,8,9,11,13,21,22,23,24,41,42,43,44,45,46,54,72,74,75,76,77,80,81,82,83,84,85,86,87,88,89,90],Z=[1,110],ee=[1,106],et=[1,107],es=[1,108],ei=[1,109],er=[1,111],en=[1,116],ea=[1,117],el=[1,114],eo=[1,115],ec={trace:(0,o.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,directive:4,NEWLINE:5,RD:6,diagram:7,EOF:8,acc_title:9,acc_title_value:10,acc_descr:11,acc_descr_value:12,acc_descr_multiline_value:13,requirementDef:14,elementDef:15,relationshipDef:16,direction:17,styleStatement:18,classDefStatement:19,classStatement:20,direction_tb:21,direction_bt:22,direction_rl:23,direction_lr:24,requirementType:25,requirementName:26,STRUCT_START:27,requirementBody:28,STYLE_SEPARATOR:29,idList:30,ID:31,COLONSEP:32,id:33,TEXT:34,text:35,RISK:36,riskLevel:37,VERIFYMTHD:38,verifyType:39,STRUCT_STOP:40,REQUIREMENT:41,FUNCTIONAL_REQUIREMENT:42,INTERFACE_REQUIREMENT:43,PERFORMANCE_REQUIREMENT:44,PHYSICAL_REQUIREMENT:45,DESIGN_CONSTRAINT:46,LOW_RISK:47,MED_RISK:48,HIGH_RISK:49,VERIFY_ANALYSIS:50,VERIFY_DEMONSTRATION:51,VERIFY_INSPECTION:52,VERIFY_TEST:53,ELEMENT:54,elementName:55,elementBody:56,TYPE:57,type:58,DOCREF:59,ref:60,END_ARROW_L:61,relationship:62,LINE:63,END_ARROW_R:64,CONTAINS:65,COPIES:66,DERIVES:67,SATISFIES:68,VERIFIES:69,REFINES:70,TRACES:71,CLASSDEF:72,stylesOpt:73,CLASS:74,ALPHA:75,COMMA:76,STYLE:77,style:78,styleComponent:79,NUM:80,COLON:81,UNIT:82,SPACE:83,BRKT:84,PCT:85,MINUS:86,LABEL:87,SEMICOLON:88,unqString:89,qString:90,$accept:0,$end:1},terminals_:{2:"error",5:"NEWLINE",6:"RD",8:"EOF",9:"acc_title",10:"acc_title_value",11:"acc_descr",12:"acc_descr_value",13:"acc_descr_multiline_value",21:"direction_tb",22:"direction_bt",23:"direction_rl",24:"direction_lr",27:"STRUCT_START",29:"STYLE_SEPARATOR",31:"ID",32:"COLONSEP",34:"TEXT",36:"RISK",38:"VERIFYMTHD",40:"STRUCT_STOP",41:"REQUIREMENT",42:"FUNCTIONAL_REQUIREMENT",43:"INTERFACE_REQUIREMENT",44:"PERFORMANCE_REQUIREMENT",45:"PHYSICAL_REQUIREMENT",46:"DESIGN_CONSTRAINT",47:"LOW_RISK",48:"MED_RISK",49:"HIGH_RISK",50:"VERIFY_ANALYSIS",51:"VERIFY_DEMONSTRATION",52:"VERIFY_INSPECTION",53:"VERIFY_TEST",54:"ELEMENT",57:"TYPE",59:"DOCREF",61:"END_ARROW_L",63:"LINE",64:"END_ARROW_R",65:"CONTAINS",66:"COPIES",67:"DERIVES",68:"SATISFIES",69:"VERIFIES",70:"REFINES",71:"TRACES",72:"CLASSDEF",74:"CLASS",75:"ALPHA",76:"COMMA",77:"STYLE",80:"NUM",81:"COLON",82:"UNIT",83:"SPACE",84:"BRKT",85:"PCT",86:"MINUS",87:"LABEL",88:"SEMICOLON",89:"unqString",90:"qString"},productions_:[0,[3,3],[3,2],[3,4],[4,2],[4,2],[4,1],[7,0],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[17,1],[17,1],[17,1],[17,1],[14,5],[14,7],[28,5],[28,5],[28,5],[28,5],[28,2],[28,1],[25,1],[25,1],[25,1],[25,1],[25,1],[25,1],[37,1],[37,1],[37,1],[39,1],[39,1],[39,1],[39,1],[15,5],[15,7],[56,5],[56,5],[56,2],[56,1],[16,5],[16,5],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[62,1],[19,3],[20,3],[20,3],[30,1],[30,3],[30,1],[30,3],[18,3],[73,1],[73,3],[78,1],[78,2],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[79,1],[26,1],[26,1],[33,1],[33,1],[35,1],[35,1],[55,1],[55,1],[58,1],[58,1],[60,1],[60,1]],performAction:(0,o.K2)(function(e,t,s,i,r,n,a){var l=n.length-1;switch(r){case 4:this.$=n[l].trim(),i.setAccTitle(this.$);break;case 5:case 6:this.$=n[l].trim(),i.setAccDescription(this.$);break;case 7:this.$=[];break;case 17:i.setDirection("TB");break;case 18:i.setDirection("BT");break;case 19:i.setDirection("RL");break;case 20:i.setDirection("LR");break;case 21:i.addRequirement(n[l-3],n[l-4]);break;case 22:i.addRequirement(n[l-5],n[l-6]),i.setClass([n[l-5]],n[l-3]);break;case 23:i.setNewReqId(n[l-2]);break;case 24:i.setNewReqText(n[l-2]);break;case 25:i.setNewReqRisk(n[l-2]);break;case 26:i.setNewReqVerifyMethod(n[l-2]);break;case 29:this.$=i.RequirementType.REQUIREMENT;break;case 30:this.$=i.RequirementType.FUNCTIONAL_REQUIREMENT;break;case 31:this.$=i.RequirementType.INTERFACE_REQUIREMENT;break;case 32:this.$=i.RequirementType.PERFORMANCE_REQUIREMENT;break;case 33:this.$=i.RequirementType.PHYSICAL_REQUIREMENT;break;case 34:this.$=i.RequirementType.DESIGN_CONSTRAINT;break;case 35:this.$=i.RiskLevel.LOW_RISK;break;case 36:this.$=i.RiskLevel.MED_RISK;break;case 37:this.$=i.RiskLevel.HIGH_RISK;break;case 38:this.$=i.VerifyType.VERIFY_ANALYSIS;break;case 39:this.$=i.VerifyType.VERIFY_DEMONSTRATION;break;case 40:this.$=i.VerifyType.VERIFY_INSPECTION;break;case 41:this.$=i.VerifyType.VERIFY_TEST;break;case 42:i.addElement(n[l-3]);break;case 43:i.addElement(n[l-5]),i.setClass([n[l-5]],n[l-3]);break;case 44:i.setNewElementType(n[l-2]);break;case 45:i.setNewElementDocRef(n[l-2]);break;case 48:i.addRelationship(n[l-2],n[l],n[l-4]);break;case 49:i.addRelationship(n[l-2],n[l-4],n[l]);break;case 50:this.$=i.Relationships.CONTAINS;break;case 51:this.$=i.Relationships.COPIES;break;case 52:this.$=i.Relationships.DERIVES;break;case 53:this.$=i.Relationships.SATISFIES;break;case 54:this.$=i.Relationships.VERIFIES;break;case 55:this.$=i.Relationships.REFINES;break;case 56:this.$=i.Relationships.TRACES;break;case 57:this.$=n[l-2],i.defineClass(n[l-1],n[l]);break;case 58:i.setClass(n[l-1],n[l]);break;case 59:i.setClass([n[l-2]],n[l]);break;case 60:case 62:case 65:this.$=[n[l]];break;case 61:case 63:this.$=n[l-2].concat([n[l]]);break;case 64:this.$=n[l-2],i.setCssStyle(n[l-1],n[l]);break;case 66:n[l-2].push(n[l]),this.$=n[l-2];break;case 68:this.$=n[l-1]+n[l]}},"anonymous"),table:[{3:1,4:2,6:t,9:s,11:i,13:r},{1:[3]},{3:8,4:2,5:[1,7],6:t,9:s,11:i,13:r},{5:[1,9]},{10:[1,10]},{12:[1,11]},e(n,[2,6]),{3:12,4:2,6:t,9:s,11:i,13:r},{1:[2,2]},{4:17,5:a,7:13,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},e(n,[2,4]),e(n,[2,5]),{1:[2,1]},{8:[1,41]},{4:17,5:a,7:42,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:43,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:44,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:45,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:46,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:47,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:48,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:49,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{4:17,5:a,7:50,8:l,9:s,11:i,13:r,14:14,15:15,16:16,17:18,18:19,19:20,20:21,21:c,22:h,23:u,24:y,25:23,33:25,41:m,42:d,43:E,44:p,45:R,46:g,54:_,72:f,74:S,77:I,89:b,90:T},{26:51,89:[1,52],90:[1,53]},{55:54,89:[1,55],90:[1,56]},{29:[1,59],61:[1,57],63:[1,58]},e(k,[2,17]),e(k,[2,18]),e(k,[2,19]),e(k,[2,20]),{30:60,33:62,75:N,89:b,90:T},{30:63,33:62,75:N,89:b,90:T},{30:64,33:62,75:N,89:b,90:T},e(q,[2,29]),e(q,[2,30]),e(q,[2,31]),e(q,[2,32]),e(q,[2,33]),e(q,[2,34]),e(C,[2,81]),e(C,[2,82]),{1:[2,3]},{8:[2,8]},{8:[2,9]},{8:[2,10]},{8:[2,11]},{8:[2,12]},{8:[2,13]},{8:[2,14]},{8:[2,15]},{8:[2,16]},{27:[1,65],29:[1,66]},e(A,[2,79]),e(A,[2,80]),{27:[1,67],29:[1,68]},e(A,[2,85]),e(A,[2,86]),{62:69,65:L,66:$,67:v,68:x,69:w,70:O,71:D},{62:77,65:L,66:$,67:v,68:x,69:w,70:O,71:D},{30:78,33:62,75:N,89:b,90:T},{73:79,75:M,76:F,78:81,79:82,80:K,81:P,82:V,83:U,84:Y,85:B,86:Q,87:H,88:W},e(j,[2,60]),e(j,[2,62]),{73:93,75:M,76:F,78:81,79:82,80:K,81:P,82:V,83:U,84:Y,85:B,86:Q,87:H,88:W},{30:94,33:62,75:N,76:F,89:b,90:T},{5:[1,95]},{30:96,33:62,75:N,89:b,90:T},{5:[1,97]},{30:98,33:62,75:N,89:b,90:T},{63:[1,99]},e(z,[2,50]),e(z,[2,51]),e(z,[2,52]),e(z,[2,53]),e(z,[2,54]),e(z,[2,55]),e(z,[2,56]),{64:[1,100]},e(k,[2,59],{76:F}),e(k,[2,64],{76:G}),{33:103,75:[1,102],89:b,90:T},e(X,[2,65],{79:104,75:M,80:K,81:P,82:V,83:U,84:Y,85:B,86:Q,87:H,88:W}),e(J,[2,67]),e(J,[2,69]),e(J,[2,70]),e(J,[2,71]),e(J,[2,72]),e(J,[2,73]),e(J,[2,74]),e(J,[2,75]),e(J,[2,76]),e(J,[2,77]),e(J,[2,78]),e(k,[2,57],{76:G}),e(k,[2,58],{76:F}),{5:Z,28:105,31:ee,34:et,36:es,38:ei,40:er},{27:[1,112],76:F},{5:en,40:ea,56:113,57:el,59:eo},{27:[1,118],76:F},{33:119,89:b,90:T},{33:120,89:b,90:T},{75:M,78:121,79:82,80:K,81:P,82:V,83:U,84:Y,85:B,86:Q,87:H,88:W},e(j,[2,61]),e(j,[2,63]),e(J,[2,68]),e(k,[2,21]),{32:[1,122]},{32:[1,123]},{32:[1,124]},{32:[1,125]},{5:Z,28:126,31:ee,34:et,36:es,38:ei,40:er},e(k,[2,28]),{5:[1,127]},e(k,[2,42]),{32:[1,128]},{32:[1,129]},{5:en,40:ea,56:130,57:el,59:eo},e(k,[2,47]),{5:[1,131]},e(k,[2,48]),e(k,[2,49]),e(X,[2,66],{79:104,75:M,80:K,81:P,82:V,83:U,84:Y,85:B,86:Q,87:H,88:W}),{33:132,89:b,90:T},{35:133,89:[1,134],90:[1,135]},{37:136,47:[1,137],48:[1,138],49:[1,139]},{39:140,50:[1,141],51:[1,142],52:[1,143],53:[1,144]},e(k,[2,27]),{5:Z,28:145,31:ee,34:et,36:es,38:ei,40:er},{58:146,89:[1,147],90:[1,148]},{60:149,89:[1,150],90:[1,151]},e(k,[2,46]),{5:en,40:ea,56:152,57:el,59:eo},{5:[1,153]},{5:[1,154]},{5:[2,83]},{5:[2,84]},{5:[1,155]},{5:[2,35]},{5:[2,36]},{5:[2,37]},{5:[1,156]},{5:[2,38]},{5:[2,39]},{5:[2,40]},{5:[2,41]},e(k,[2,22]),{5:[1,157]},{5:[2,87]},{5:[2,88]},{5:[1,158]},{5:[2,89]},{5:[2,90]},e(k,[2,43]),{5:Z,28:159,31:ee,34:et,36:es,38:ei,40:er},{5:Z,28:160,31:ee,34:et,36:es,38:ei,40:er},{5:Z,28:161,31:ee,34:et,36:es,38:ei,40:er},{5:Z,28:162,31:ee,34:et,36:es,38:ei,40:er},{5:en,40:ea,56:163,57:el,59:eo},{5:en,40:ea,56:164,57:el,59:eo},e(k,[2,23]),e(k,[2,24]),e(k,[2,25]),e(k,[2,26]),e(k,[2,44]),e(k,[2,45])],defaultActions:{8:[2,2],12:[2,1],41:[2,3],42:[2,8],43:[2,9],44:[2,10],45:[2,11],46:[2,12],47:[2,13],48:[2,14],49:[2,15],50:[2,16],134:[2,83],135:[2,84],137:[2,35],138:[2,36],139:[2,37],141:[2,38],142:[2,39],143:[2,40],144:[2,41],147:[2,87],148:[2,88],150:[2,89],151:[2,90]},parseError:(0,o.K2)(function(e,t){if(t.recoverable)this.trace(e);else{var s=Error(e);throw s.hash=t,s}},"parseError"),parse:(0,o.K2)(function(e){var t=this,s=[0],i=[],r=[null],n=[],a=this.table,l="",c=0,h=0,u=0,y=n.slice.call(arguments,1),m=Object.create(this.lexer),d={};for(var E in this.yy)Object.prototype.hasOwnProperty.call(this.yy,E)&&(d[E]=this.yy[E]);m.setInput(e,d),d.lexer=m,d.parser=this,void 0===m.yylloc&&(m.yylloc={});var p=m.yylloc;n.push(p);var R=m.options&&m.options.ranges;function g(){var e;return"number"!=typeof(e=i.pop()||m.lex()||1)&&(e instanceof Array&&(e=(i=e).pop()),e=t.symbols_[e]||e),e}"function"==typeof d.parseError?this.parseError=d.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,o.K2)(function(e){s.length=s.length-2*e,r.length=r.length-e,n.length=n.length-e},"popStack"),(0,o.K2)(g,"lex");for(var _,f,S,I,b,T,k,N,q,C={};;){if(S=s[s.length-1],this.defaultActions[S]?I=this.defaultActions[S]:(null==_&&(_=g()),I=a[S]&&a[S][_]),void 0===I||!I.length||!I[0]){var A="";for(T in q=[],a[S])this.terminals_[T]&&T>2&&q.push("'"+this.terminals_[T]+"'");A=m.showPosition?"Parse error on line "+(c+1)+":\n"+m.showPosition()+"\nExpecting "+q.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==_?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(A,{text:m.match,token:this.terminals_[_]||_,line:m.yylineno,loc:p,expected:q})}if(I[0]instanceof Array&&I.length>1)throw Error("Parse Error: multiple actions possible at state: "+S+", token: "+_);switch(I[0]){case 1:s.push(_),r.push(m.yytext),n.push(m.yylloc),s.push(I[1]),_=null,f?(_=f,f=null):(h=m.yyleng,l=m.yytext,c=m.yylineno,p=m.yylloc,u>0&&u--);break;case 2:if(k=this.productions_[I[1]][1],C.$=r[r.length-k],C._$={first_line:n[n.length-(k||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(k||1)].first_column,last_column:n[n.length-1].last_column},R&&(C._$.range=[n[n.length-(k||1)].range[0],n[n.length-1].range[1]]),void 0!==(b=this.performAction.apply(C,[l,h,c,d,I[1],r,n].concat(y))))return b;k&&(s=s.slice(0,-1*k*2),r=r.slice(0,-1*k),n=n.slice(0,-1*k)),s.push(this.productions_[I[1]][0]),r.push(C.$),n.push(C._$),N=a[s[s.length-2]][s[s.length-1]],s.push(N);break;case 3:return!0}}return!0},"parse")};function eh(){this.yy={}}return ec.lexer={EOF:1,parseError:(0,o.K2)(function(e,t){if(this.yy.parser)this.yy.parser.parseError(e,t);else throw Error(e)},"parseError"),setInput:(0,o.K2)(function(e,t){return this.yy=t||this.yy||{},this._input=e,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,o.K2)(function(){var e=this._input[0];return this.yytext+=e,this.yyleng++,this.offset++,this.match+=e,this.matched+=e,e.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),e},"input"),unput:(0,o.K2)(function(e){var t=e.length,s=e.split(/(?:\r\n?|\n)/g);this._input=e+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-t),this.offset-=t;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),s.length-1&&(this.yylineno-=s.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:s?(s.length===i.length?this.yylloc.first_column:0)+i[i.length-s.length].length-s[0].length:this.yylloc.first_column-t},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-t]),this.yyleng=this.yytext.length,this},"unput"),more:(0,o.K2)(function(){return this._more=!0,this},"more"),reject:(0,o.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,o.K2)(function(e){this.unput(this.match.slice(e))},"less"),pastInput:(0,o.K2)(function(){var e=this.matched.substr(0,this.matched.length-this.match.length);return(e.length>20?"...":"")+e.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,o.K2)(function(){var e=this.match;return e.length<20&&(e+=this._input.substr(0,20-e.length)),(e.substr(0,20)+(e.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,o.K2)(function(){var e=this.pastInput(),t=Array(e.length+1).join("-");return e+this.upcomingInput()+"\n"+t+"^"},"showPosition"),test_match:(0,o.K2)(function(e,t){var s,i,r;if(this.options.backtrack_lexer&&(r={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&&(r.yylloc.range=this.yylloc.range.slice(0))),(i=e[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+e[0].length},this.yytext+=e[0],this.match+=e[0],this.matches=e,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(e[0].length),this.matched+=e[0],s=this.performAction.call(this,this.yy,this,t,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s)return s;if(this._backtrack)for(var n in r)this[n]=r[n];return!1},"test_match"),next:(0,o.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var e,t,s,i,r=this._currentRules(),n=0;n<r.length;n++)if((s=this._input.match(this.rules[r[n]]))&&(!t||s[0].length>t[0].length)){if(t=s,i=n,this.options.backtrack_lexer){if(!1!==(e=this.test_match(s,r[n])))return e;if(!this._backtrack)return!1;t=!1;continue}if(!this.options.flex)break}return t?!1!==(e=this.test_match(t,r[i]))&&e:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,o.K2)(function(){var e=this.next();return e||this.lex()},"lex"),begin:(0,o.K2)(function(e){this.conditionStack.push(e)},"begin"),popState:(0,o.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,o.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,o.K2)(function(e){return(e=this.conditionStack.length-1-Math.abs(e||0))>=0?this.conditionStack[e]:"INITIAL"},"topState"),pushState:(0,o.K2)(function(e){this.begin(e)},"pushState"),stateStackSize:(0,o.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,o.K2)(function(e,t,s,i){switch(s){case 0:return"title";case 1:return this.begin("acc_title"),9;case 2:return this.popState(),"acc_title_value";case 3:return this.begin("acc_descr"),11;case 4:return this.popState(),"acc_descr_value";case 5:this.begin("acc_descr_multiline");break;case 6:case 58:case 65:this.popState();break;case 7:return"acc_descr_multiline_value";case 8:return 21;case 9:return 22;case 10:return 23;case 11:return 24;case 12:return 5;case 13:case 14:case 15:case 56:break;case 16:return 8;case 17:return 6;case 18:return 27;case 19:return 40;case 20:return 29;case 21:return 32;case 22:return 31;case 23:return 34;case 24:return 36;case 25:return 38;case 26:return 41;case 27:return 42;case 28:return 43;case 29:return 44;case 30:return 45;case 31:return 46;case 32:return 47;case 33:return 48;case 34:return 49;case 35:return 50;case 36:return 51;case 37:return 52;case 38:return 53;case 39:return 54;case 40:return 65;case 41:return 66;case 42:return 67;case 43:return 68;case 44:return 69;case 45:return 70;case 46:return 71;case 47:return 57;case 48:return 59;case 49:return this.begin("style"),77;case 50:case 68:return 75;case 51:return 81;case 52:return 88;case 53:return"PERCENT";case 54:return 86;case 55:return 84;case 57:case 64:this.begin("string");break;case 59:return this.begin("style"),72;case 60:return this.begin("style"),74;case 61:return 61;case 62:return 64;case 63:return 63;case 66:return"qString";case 67:return t.yytext=t.yytext.trim(),89;case 69:return 80;case 70:return 76}},"anonymous"),rules:[/^(?:title\s[^#\n;]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:.*direction\s+TB[^\n]*)/i,/^(?:.*direction\s+BT[^\n]*)/i,/^(?:.*direction\s+RL[^\n]*)/i,/^(?:.*direction\s+LR[^\n]*)/i,/^(?:(\r?\n)+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:%[^\n]*)/i,/^(?:$)/i,/^(?:requirementDiagram\b)/i,/^(?:\{)/i,/^(?:\})/i,/^(?::{3})/i,/^(?::)/i,/^(?:id\b)/i,/^(?:text\b)/i,/^(?:risk\b)/i,/^(?:verifyMethod\b)/i,/^(?:requirement\b)/i,/^(?:functionalRequirement\b)/i,/^(?:interfaceRequirement\b)/i,/^(?:performanceRequirement\b)/i,/^(?:physicalRequirement\b)/i,/^(?:designConstraint\b)/i,/^(?:low\b)/i,/^(?:medium\b)/i,/^(?:high\b)/i,/^(?:analysis\b)/i,/^(?:demonstration\b)/i,/^(?:inspection\b)/i,/^(?:test\b)/i,/^(?:element\b)/i,/^(?:contains\b)/i,/^(?:copies\b)/i,/^(?:derives\b)/i,/^(?:satisfies\b)/i,/^(?:verifies\b)/i,/^(?:refines\b)/i,/^(?:traces\b)/i,/^(?:type\b)/i,/^(?:docref\b)/i,/^(?:style\b)/i,/^(?:\w+)/i,/^(?::)/i,/^(?:;)/i,/^(?:%)/i,/^(?:-)/i,/^(?:#)/i,/^(?: )/i,/^(?:["])/i,/^(?:\n)/i,/^(?:classDef\b)/i,/^(?:class\b)/i,/^(?:<-)/i,/^(?:->)/i,/^(?:-)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:[\w][^:,\r\n\{\<\>\-\=]*)/i,/^(?:\w+)/i,/^(?:[0-9]+)/i,/^(?:,)/i],conditions:{acc_descr_multiline:{rules:[6,7,68,69,70],inclusive:!1},acc_descr:{rules:[4,68,69,70],inclusive:!1},acc_title:{rules:[2,68,69,70],inclusive:!1},style:{rules:[50,51,52,53,54,55,56,57,58,68,69,70],inclusive:!1},unqString:{rules:[68,69,70],inclusive:!1},token:{rules:[68,69,70],inclusive:!1},string:{rules:[65,66,68,69,70],inclusive:!1},INITIAL:{rules:[0,1,3,5,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,59,60,61,62,63,64,67,68,69,70],inclusive:!0}}},(0,o.K2)(eh,"Parser"),eh.prototype=ec,ec.Parser=eh,new eh}();c.parser=c;var h=class{constructor(){this.relations=[],this.latestRequirement=this.getInitialRequirement(),this.requirements=new Map,this.latestElement=this.getInitialElement(),this.elements=new Map,this.classes=new Map,this.direction="TB",this.RequirementType={REQUIREMENT:"Requirement",FUNCTIONAL_REQUIREMENT:"Functional Requirement",INTERFACE_REQUIREMENT:"Interface Requirement",PERFORMANCE_REQUIREMENT:"Performance Requirement",PHYSICAL_REQUIREMENT:"Physical Requirement",DESIGN_CONSTRAINT:"Design Constraint"},this.RiskLevel={LOW_RISK:"Low",MED_RISK:"Medium",HIGH_RISK:"High"},this.VerifyType={VERIFY_ANALYSIS:"Analysis",VERIFY_DEMONSTRATION:"Demonstration",VERIFY_INSPECTION:"Inspection",VERIFY_TEST:"Test"},this.Relationships={CONTAINS:"contains",COPIES:"copies",DERIVES:"derives",SATISFIES:"satisfies",VERIFIES:"verifies",REFINES:"refines",TRACES:"traces"},this.setAccTitle=l.SV,this.getAccTitle=l.iN,this.setAccDescription=l.EI,this.getAccDescription=l.m7,this.setDiagramTitle=l.ke,this.getDiagramTitle=l.ab,this.getConfig=(0,o.K2)(()=>(0,l.D7)().requirement,"getConfig"),this.clear(),this.setDirection=this.setDirection.bind(this),this.addRequirement=this.addRequirement.bind(this),this.setNewReqId=this.setNewReqId.bind(this),this.setNewReqRisk=this.setNewReqRisk.bind(this),this.setNewReqText=this.setNewReqText.bind(this),this.setNewReqVerifyMethod=this.setNewReqVerifyMethod.bind(this),this.addElement=this.addElement.bind(this),this.setNewElementType=this.setNewElementType.bind(this),this.setNewElementDocRef=this.setNewElementDocRef.bind(this),this.addRelationship=this.addRelationship.bind(this),this.setCssStyle=this.setCssStyle.bind(this),this.setClass=this.setClass.bind(this),this.defineClass=this.defineClass.bind(this),this.setAccTitle=this.setAccTitle.bind(this),this.setAccDescription=this.setAccDescription.bind(this)}static{(0,o.K2)(this,"RequirementDB")}getDirection(){return this.direction}setDirection(e){this.direction=e}resetLatestRequirement(){this.latestRequirement=this.getInitialRequirement()}resetLatestElement(){this.latestElement=this.getInitialElement()}getInitialRequirement(){return{requirementId:"",text:"",risk:"",verifyMethod:"",name:"",type:"",cssStyles:[],classes:["default"]}}getInitialElement(){return{name:"",type:"",docRef:"",cssStyles:[],classes:["default"]}}addRequirement(e,t){return this.requirements.has(e)||this.requirements.set(e,{name:e,type:t,requirementId:this.latestRequirement.requirementId,text:this.latestRequirement.text,risk:this.latestRequirement.risk,verifyMethod:this.latestRequirement.verifyMethod,cssStyles:[],classes:["default"]}),this.resetLatestRequirement(),this.requirements.get(e)}getRequirements(){return this.requirements}setNewReqId(e){void 0!==this.latestRequirement&&(this.latestRequirement.requirementId=e)}setNewReqText(e){void 0!==this.latestRequirement&&(this.latestRequirement.text=e)}setNewReqRisk(e){void 0!==this.latestRequirement&&(this.latestRequirement.risk=e)}setNewReqVerifyMethod(e){void 0!==this.latestRequirement&&(this.latestRequirement.verifyMethod=e)}addElement(e){return this.elements.has(e)||(this.elements.set(e,{name:e,type:this.latestElement.type,docRef:this.latestElement.docRef,cssStyles:[],classes:["default"]}),o.Rm.info("Added new element: ",e)),this.resetLatestElement(),this.elements.get(e)}getElements(){return this.elements}setNewElementType(e){void 0!==this.latestElement&&(this.latestElement.type=e)}setNewElementDocRef(e){void 0!==this.latestElement&&(this.latestElement.docRef=e)}addRelationship(e,t,s){this.relations.push({type:e,src:t,dst:s})}getRelationships(){return this.relations}clear(){this.relations=[],this.resetLatestRequirement(),this.requirements=new Map,this.resetLatestElement(),this.elements=new Map,this.classes=new Map,(0,l.IU)()}setCssStyle(e,t){for(let s of e){let e=this.requirements.get(s)??this.elements.get(s);if(!t||!e)return;for(let s of t)s.includes(",")?e.cssStyles.push(...s.split(",")):e.cssStyles.push(s)}}setClass(e,t){for(let s of e){let e=this.requirements.get(s)??this.elements.get(s);if(e)for(let s of t){e.classes.push(s);let t=this.classes.get(s)?.styles;t&&e.cssStyles.push(...t)}}}defineClass(e,t){for(let s of e){let e=this.classes.get(s);void 0===e&&(e={id:s,styles:[],textStyles:[]},this.classes.set(s,e)),t&&t.forEach(function(t){if(/color/.exec(t)){let s=t.replace("fill","bgFill");e.textStyles.push(s)}e.styles.push(t)}),this.requirements.forEach(e=>{e.classes.includes(s)&&e.cssStyles.push(...t.flatMap(e=>e.split(",")))}),this.elements.forEach(e=>{e.classes.includes(s)&&e.cssStyles.push(...t.flatMap(e=>e.split(",")))})}}getClasses(){return this.classes}getData(){let e=(0,l.D7)(),t=[],s=[];for(let s of this.requirements.values())s.id=s.name,s.cssStyles=s.cssStyles,s.cssClasses=s.classes.join(" "),s.shape="requirementBox",s.look=e.look,s.colorIndex=t.length,t.push(s);for(let s of this.elements.values())s.shape="requirementBox",s.look=e.look,s.id=s.name,s.cssStyles=s.cssStyles,s.cssClasses=s.classes.join(" "),s.colorIndex=t.length,t.push(s);for(let t of this.relations){let i=0,r=t.type===this.Relationships.CONTAINS,n={id:`${t.src}-${t.dst}-${i}`,start:this.requirements.get(t.src)?.name??this.elements.get(t.src)?.name,end:this.requirements.get(t.dst)?.name??this.elements.get(t.dst)?.name,label:`&lt;&lt;${t.type}&gt;&gt;`,classes:"relationshipLine",style:["fill:none",r?"":"stroke-dasharray: 10,7"],labelpos:"c",thickness:"normal",type:"normal",pattern:r?"normal":"dashed",arrowTypeStart:r?"requirement_contains":"",arrowTypeEnd:r?"":"requirement_arrow",look:e.look,labelType:"markdown"};s.push(n),i++}return{nodes:t,edges:s,other:{},config:e,direction:this.getDirection()}}},u=(0,o.K2)(e=>{let{themeVariables:t,look:s}=(0,l.zj)(),{bkgColorArray:i,borderColorArray:r}=t;if(!r?.length)return"";let n="";for(let t=0;t<e.THEME_COLOR_LIMIT;t++)n+=`
2
+
3
+ [data-look="${s}"][data-color-id="color-${t}"].node path {
4
+ stroke: ${r[t]};
5
+ fill: ${i?.length?i[t]:""};
6
+ }
7
+
8
+ [data-look="${s}"][data-color-id="color-${t}"].node rect {
9
+ stroke: ${r[t]};
10
+ fill: ${i?.length?i[t]:""};
11
+ }
12
+ `;return n},"genColor"),y=(0,o.K2)(e=>{let{look:t,themeVariables:s}=(0,l.zj)(),{requirementEdgeLabelBackground:i}=s;return`
13
+ ${u(e)}
14
+ marker {
15
+ fill: ${e.relationColor};
16
+ stroke: ${e.relationColor};
17
+ }
18
+
19
+ marker.cross {
20
+ stroke: ${e.lineColor};
21
+ }
22
+
23
+ svg {
24
+ font-family: ${e.fontFamily};
25
+ font-size: ${e.fontSize};
26
+ }
27
+
28
+ .reqBox {
29
+ fill: ${e.requirementBackground};
30
+ fill-opacity: 1.0;
31
+ stroke: ${e.requirementBorderColor};
32
+ stroke-width: ${e.requirementBorderSize};
33
+ }
34
+
35
+ .reqTitle, .reqLabel{
36
+ fill: ${e.requirementTextColor};
37
+ }
38
+ .reqLabelBox {
39
+ fill: ${e.relationLabelBackground};
40
+ fill-opacity: 1.0;
41
+ }
42
+
43
+ .req-title-line {
44
+ stroke: ${e.requirementBorderColor};
45
+ stroke-width: ${e.requirementBorderSize};
46
+ }
47
+ .relationshipLine {
48
+ stroke: ${e.relationColor};
49
+ stroke-width: ${"neo"===t?e.strokeWidth:"1px"};
50
+ }
51
+ .relationshipLabel {
52
+ fill: ${e.relationLabelColor};
53
+ }
54
+ .edgeLabel {
55
+ background-color: ${e.edgeLabelBackground};
56
+ }
57
+ .edgeLabel .label rect {
58
+ fill: ${e.edgeLabelBackground};
59
+ }
60
+ .edgeLabel .label text {
61
+ fill: ${e.relationLabelColor};
62
+ }
63
+ .divider {
64
+ stroke: ${e.nodeBorder};
65
+ stroke-width: 1;
66
+ }
67
+ .label {
68
+ font-family: ${e.fontFamily};
69
+ color: ${e.nodeTextColor||e.textColor};
70
+ }
71
+ .label text,span {
72
+ fill: ${e.nodeTextColor||e.textColor};
73
+ color: ${e.nodeTextColor||e.textColor};
74
+ }
75
+ .labelBkg {
76
+ background-color: ${i??e.edgeLabelBackground};
77
+ }
78
+
79
+ `},"getStyles"),m={};(0,o.VA)(m,{draw:()=>d});var d=(0,o.K2)(async function(e,t,s,c){o.Rm.info("REF0:"),o.Rm.info("Drawing requirement diagram (unified)",t);let{securityLevel:h,state:u,layout:y,look:m}=(0,l.D7)(),d=c.db.getData(),E=(0,i.A)(t,h);d.type=c.type,d.layoutAlgorithm=(0,n.q7)(y),d.nodeSpacing=u?.nodeSpacing??50,d.rankSpacing=u?.rankSpacing??50,d.markers="neo"===m?["requirement_contains_neo","requirement_arrow_neo"]:["requirement_contains","requirement_arrow"],d.diagramId=t,await (0,n.XX)(d,E),a._K.insertTitle(E,"requirementDiagramTitleText",u?.titleTopMargin??25,c.db.getDiagramTitle()),(0,r.P)(E,8,"requirementDiagram",u?.useMaxWidth??!0)},"draw"),E={parser:c,get db(){return new h},renderer:m,styles:y}}}]);
_next/static/chunks/4603.762146ef732cf6a2.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4603],{131:(e,n,r)=>{r.d(n,{A:()=>u});var t=r(2557),o=r(2719),i=r(4721),a=r(4536);let u=function(e,n){return((0,a.A)(e)?t.A:i.A)(e,(0,o.A)(n,3))}},3048:(e,n,r)=>{r.d(n,{A:()=>J});var t=r(8816),o=r(1760),i=r(7386),a=r(9294),u=r(9431),c=r(8046),d=r(7939),f=r(7998),s=r(329),v=r(113),l=r(9614),h=r(7896),g=Object.getOwnPropertySymbols?function(e){for(var n=[];e;)(0,v.A)(n,(0,s.A)(e)),e=(0,l.A)(e);return n}:h.A,A=r(2275),p=r(2977);let b=function(e){return(0,p.A)(e,c.A,g)};var w=r(3967),y=Object.prototype.hasOwnProperty;let m=function(e){var n=e.length,r=new e.constructor(n);return n&&"string"==typeof e[0]&&y.call(e,"index")&&(r.index=e.index,r.input=e.input),r};var j=r(7988);let x=function(e,n){var r=n?(0,j.A)(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.byteLength)};var k=/\w*$/;let O=function(e){var n=new e.constructor(e.source,k.exec(e));return n.lastIndex=e.lastIndex,n};var E=r(3e3),_=E.A?E.A.prototype:void 0,P=_?_.valueOf:void 0,N=r(4280);let M=function(e,n,r){var t=e.constructor;switch(n){case"[object ArrayBuffer]":return(0,j.A)(e);case"[object Boolean]":case"[object Date]":return new t(+e);case"[object DataView]":return x(e,r);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return(0,N.A)(e,r);case"[object Map]":case"[object Set]":return new t;case"[object Number]":case"[object String]":return new t(e);case"[object RegExp]":return O(e);case"[object Symbol]":return P?Object(P.call(e)):{}}};var R=r(7294),L=r(4536),C=r(2092),T=r(1331),S=r(5668),B=r(8272),I=B.A&&B.A.isMap,G=I?(0,S.A)(I):function(e){return(0,T.A)(e)&&"[object Map]"==(0,w.A)(e)},F=r(3476),U=B.A&&B.A.isSet,q=U?(0,S.A)(U):function(e){return(0,T.A)(e)&&"[object Set]"==(0,w.A)(e)},D="[object Arguments]",z="[object Function]",V="[object Object]",$={};$[D]=$["[object Array]"]=$["[object ArrayBuffer]"]=$["[object DataView]"]=$["[object Boolean]"]=$["[object Date]"]=$["[object Float32Array]"]=$["[object Float64Array]"]=$["[object Int8Array]"]=$["[object Int16Array]"]=$["[object Int32Array]"]=$["[object Map]"]=$["[object Number]"]=$[V]=$["[object RegExp]"]=$["[object Set]"]=$["[object String]"]=$["[object Symbol]"]=$["[object Uint8Array]"]=$["[object Uint8ClampedArray]"]=$["[object Uint16Array]"]=$["[object Uint32Array]"]=!0,$["[object Error]"]=$[z]=$["[object WeakMap]"]=!1;let J=function e(n,r,v,l,h,p){var y,j=1&r,x=2&r,k=4&r;if(v&&(y=h?v(n,l,h,p):v(n)),void 0!==y)return y;if(!(0,F.A)(n))return n;var O=(0,L.A)(n);if(O){if(y=m(n),!j)return(0,f.A)(n,y)}else{var E,_,P,N,T=(0,w.A)(n),S=T==z||"[object GeneratorFunction]"==T;if((0,C.A)(n))return(0,d.A)(n,j);if(T==V||T==D||S&&!h){if(y=x||S?{}:(0,R.A)(n),!j)return x?(_=(E=y)&&(0,a.A)(n,(0,c.A)(n),E),(0,a.A)(n,g(n),_)):(N=(P=y)&&(0,a.A)(n,(0,u.A)(n),P),(0,a.A)(n,(0,s.A)(n),N))}else{if(!$[T])return h?n:{};y=M(n,T,j)}}p||(p=new t.A);var B=p.get(n);if(B)return B;p.set(n,y),q(n)?n.forEach(function(t){y.add(e(t,r,v,t,n,p))}):G(n)&&n.forEach(function(t,o){y.set(o,e(t,r,v,o,n,p))});var I=k?x?b:A.A:x?c.A:u.A,U=O?void 0:I(n);return(0,o.A)(U||n,function(t,o){U&&(t=n[o=t]),(0,i.A)(y,o,e(t,r,v,o,n,p))}),y}},4280:(e,n,r)=>{r.d(n,{A:()=>o});var t=r(7988);let o=function(e,n){var r=n?(0,t.A)(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}},4603:(e,n,r)=>{r.d(n,{Zp:()=>n$});var t,o=r(8555),i=r(6321),a=0;let u=function(e){var n=++a;return(0,i.A)(e)+n};var c=r(3439),d=r(3175);let f=function(e){return(null==e?0:e.length)?(0,d.A)(e,1):[]};var s=r(131),v=Math.ceil,l=Math.max;let h=function(e,n,r,t){for(var o=-1,i=l(v((n-e)/(r||1)),0),a=Array(i);i--;)a[t?i:++o]=e,e+=r;return a};var g=r(7537),A=r(1383),p=r(904),b=r(3476);let w=function(e,n,r){if(!(0,b.A)(r))return!1;var t=typeof n;return("number"==t?!!((0,A.A)(r)&&(0,p.A)(n,r.length)):"string"==t&&n in r)&&(0,g.A)(r[n],e)};var y=/\s/;let m=function(e){for(var n=e.length;n--&&y.test(e.charAt(n)););return n};var j=/^\s+/,x=r(9027),k=0/0,O=/^[-+]0x[0-9a-f]+$/i,E=/^0b[01]+$/i,_=/^0o[0-7]+$/i,P=parseInt;let N=function(e){if("number"==typeof e)return e;if((0,x.A)(e))return k;if((0,b.A)(e)){var n,r="function"==typeof e.valueOf?e.valueOf():e;e=(0,b.A)(r)?r+"":r}if("string"!=typeof e)return 0===e?e:+e;e=(n=e)?n.slice(0,m(n)+1).replace(j,""):n;var t=E.test(e);return t||_.test(e)?P(e.slice(2),t?2:8):O.test(e)?k:+e};var M=1/0;let R=function(e){return e?(e=N(e))===M||e===-M?(e<0?-1:1)*17976931348623157e292:e==e?e:0:0===e?e:0},L=function(e,n,r){return r&&"number"!=typeof r&&w(e,n,r)&&(n=r=void 0),e=R(e),void 0===n?(n=e,e=0):n=R(n),r=void 0===r?e<n?1:-1:R(r),h(e,n,r,void 0)};var C=r(9856);class T{constructor(){var e={};e._next=e._prev=e,this._sentinel=e}dequeue(){var e=this._sentinel,n=e._prev;if(n!==e)return S(n),n}enqueue(e){var n=this._sentinel;e._prev&&e._next&&S(e),e._next=n._next,n._next._prev=e,n._next=e,e._prev=n}toString(){for(var e=[],n=this._sentinel,r=n._prev;r!==n;)e.push(JSON.stringify(r,B)),r=r._prev;return"["+e.join(", ")+"]"}}function S(e){e._prev._next=e._next,e._next._prev=e._prev,delete e._next,delete e._prev}function B(e,n){if("_next"!==e&&"_prev"!==e)return n}var I=c.A(1);function G(e,n,r,t,i){var a=i?[]:void 0;return o.A(e.inEdges(t.v),function(t){var o=e.edge(t),u=e.node(t.v);i&&a.push({v:t.v,w:t.w}),u.out-=o,F(n,r,u)}),o.A(e.outEdges(t.v),function(t){var o=e.edge(t),i=t.w,a=e.node(i);a.in-=o,F(n,r,a)}),e.removeNode(t.v),a}function F(e,n,r){r.out?r.in?e[r.out-r.in+n].enqueue(r):e[e.length-1].enqueue(r):e[0].enqueue(r)}var U=r(8816),q=r(5041);let D=function(e,n,r){(void 0===r||(0,g.A)(e[n],r))&&(void 0!==r||n in e)||(0,q.A)(e,n,r)};var z=r(3166),V=r(7939),$=r(4280),J=r(7998),W=r(7294),Z=r(4875),H=r(4536),K=r(972),Q=r(2092),X=r(1851),Y=r(5582),ee=r(9614),en=r(1331),er=Object.prototype,et=Function.prototype.toString,eo=er.hasOwnProperty,ei=et.call(Object);let ea=function(e){if(!(0,en.A)(e)||"[object Object]"!=(0,Y.A)(e))return!1;var n=(0,ee.A)(e);if(null===n)return!0;var r=eo.call(n,"constructor")&&n.constructor;return"function"==typeof r&&r instanceof r&&et.call(r)==ei};var eu=r(7822);let ec=function(e,n){if(("constructor"!==n||"function"!=typeof e[n])&&"__proto__"!=n)return e[n]};var ed=r(9294),ef=r(8046);let es=function(e,n,r,t,o,i,a){var u=ec(e,r),c=ec(n,r),d=a.get(c);if(d)return void D(e,r,d);var f=i?i(u,c,r+"",e,n,a):void 0,s=void 0===f;if(s){var v=(0,H.A)(c),l=!v&&(0,Q.A)(c),h=!v&&!l&&(0,eu.A)(c);(f=c,v||l||h)?(0,H.A)(u)?f=u:(0,K.A)(u)?f=(0,J.A)(u):l?(s=!1,f=(0,V.A)(c,!0)):h?(s=!1,f=(0,$.A)(c,!0)):f=[]:ea(c)||(0,Z.A)(c)?(f=u,(0,Z.A)(u))?f=(0,ed.A)(u,(0,ef.A)(u)):(!(0,b.A)(u)||(0,X.A)(u))&&(f=(0,W.A)(c)):s=!1}s&&(a.set(c,f),o(f,c,t,i,a),a.delete(c)),D(e,r,f)},ev=function e(n,r,t,o,i){n!==r&&(0,z.A)(r,function(a,u){if(i||(i=new U.A),(0,b.A)(a))es(n,r,u,t,e,o,i);else{var c=o?o(ec(n,u),a,u+"",n,r,i):void 0;void 0===c&&(c=a),D(n,u,c)}},ef.A)};var el=r(3679),eh=function(e){return(0,el.A)(function(n,r){var t=-1,o=r.length,i=o>1?r[o-1]:void 0,a=o>2?r[2]:void 0;for(i=e.length>3&&"function"==typeof i?(o--,i):void 0,a&&w(r[0],r[1],a)&&(i=o<3?void 0:i,o=1),n=Object(n);++t<o;){var u=r[t];u&&e(n,u,t,i)}return n})}(function(e,n,r){ev(e,n,r)}),eg=r(551),eA=r(7386),ep=r(3918),eb=r(2964);let ew=function(e,n,r,t){if(!(0,b.A)(e))return e;n=(0,ep.A)(n,e);for(var o=-1,i=n.length,a=i-1,u=e;null!=u&&++o<i;){var c=(0,eb.A)(n[o]),d=r;if("__proto__"===c||"constructor"===c||"prototype"===c)break;if(o!=a){var f=u[c];void 0===(d=t?t(f,c,u):void 0)&&(d=(0,b.A)(f)?f:(0,p.A)(n[o+1])?[]:{})}(0,eA.A)(u,c,d),u=u[c]}return e},ey=function(e,n,r){for(var t=-1,o=n.length,i={};++t<o;){var a=n[t],u=(0,eg.A)(e,a);r(u,a)&&ew(i,(0,ep.A)(a,e),u)}return i};var em=r(3416),ej=r(5844),ex=r(2734),ek=function(e){return(0,ex.A)((0,ej.A)(e,void 0,f),e+"")}(function(e,n){return null==e?{}:ey(e,n,function(n,r){return(0,em.A)(e,r)})}),eO=Object.prototype,eE=eO.hasOwnProperty,e_=(0,el.A)(function(e,n){e=Object(e);var r=-1,t=n.length,o=t>2?n[2]:void 0;for(o&&w(n[0],n[1],o)&&(t=1);++r<t;)for(var i=n[r],a=(0,ef.A)(i),u=-1,c=a.length;++u<c;){var d=a[u],f=e[d];(void 0===f||(0,g.A)(f,eO[d])&&!eE.call(e,d))&&(e[d]=i[d])}return e});let eP=function(e,n,r){for(var t=-1,o=e.length;++t<o;){var i=e[t],a=n(i);if(null!=a&&(void 0===u?a==a&&!(0,x.A)(a):r(a,u)))var u=a,c=i}return c},eN=function(e,n){return e>n};var eM=r(2729);let eR=function(e){return e&&e.length?eP(e,eM.A,eN):void 0},eL=function(e){var n=null==e?0:e.length;return n?e[n-1]:void 0};var eC=r(7424),eT=r(2719);let eS=function(e,n){var r={};return n=(0,eT.A)(n,3),(0,eC.A)(e,function(e,t,o){(0,q.A)(r,t,n(e,t,o))}),r};var eB=r(2945);let eI=function(e,n){return e<n},eG=function(e){return e&&e.length?eP(e,eM.A,eI):void 0};var eF=Object.prototype.hasOwnProperty;let eU=function(e,n){return null!=e&&eF.call(e,n)};var eq=r(5404);let eD=function(e,n){return null!=e&&(0,eq.A)(e,n,eU)};var ez=r(2308);let eV=function(){return ez.A.Date.now()};function e$(e,n,r,t){var o;do o=u(t);while(e.hasNode(o));return r.dummy=n,e.setNode(o,r),o}function eJ(e){var n=new C.T({multigraph:e.isMultigraph()}).setGraph(e.graph());return o.A(e.nodes(),function(r){e.children(r).length||n.setNode(r,e.node(r))}),o.A(e.edges(),function(r){n.setEdge(r,e.edge(r))}),n}function eW(e,n){var r,t,o=e.x,i=e.y,a=n.x-o,u=n.y-i,c=e.width/2,d=e.height/2;if(!a&&!u)throw Error("Not possible to find intersection inside of the rectangle");return Math.abs(u)*c>Math.abs(a)*d?(u<0&&(d=-d),r=d*a/u,t=d):(a<0&&(c=-c),r=c,t=c*u/a),{x:o+r,y:i+t}}function eZ(e){var n=s.A(L(eK(e)+1),function(){return[]});return o.A(e.nodes(),function(r){var t=e.node(r),o=t.rank;eB.A(o)||(n[o][t.order]=r)}),n}function eH(e,n,r,t){var o={width:0,height:0};return arguments.length>=4&&(o.rank=r,o.order=t),e$(e,"border",o,n)}function eK(e){return eR(s.A(e.nodes(),function(n){var r=e.node(n).rank;if(!eB.A(r))return r}))}function eQ(e,n){var r=eV();try{return n()}finally{console.log(e+" time: "+(eV()-r)+"ms")}}function eX(e,n){return n()}function eY(e,n,r,t,o,i){var a=o[n][i-1],u=e$(e,"border",{width:0,height:0,rank:i,borderType:n},r);o[n][i]=u,e.setParent(u,t),a&&e.setEdge(a,u,{weight:1})}function e0(e){o.A(e.nodes(),function(n){e1(e.node(n))}),o.A(e.edges(),function(n){e1(e.edge(n))})}function e1(e){var n=e.width;e.width=e.height,e.height=n}function e2(e){e.y=-e.y}function e3(e){var n=e.x;e.x=e.y,e.y=n}let e4=function(e,n){return e&&e.length?eP(e,(0,eT.A)(n,2),eI):void 0};function e8(e){var n={};o.A(e.sources(),function r(t){var o=e.node(t);if(Object.prototype.hasOwnProperty.call(n,t))return o.rank;n[t]=!0;var i=eG(s.A(e.outEdges(t),function(n){return r(n.w)-e.edge(n).minlen}));return(i===1/0||null==i)&&(i=0),o.rank=i})}function e7(e,n){return e.node(n.w).rank-e.node(n.v).rank-e.edge(n).minlen}function e9(e){var n,r,t,i,a=new C.T({directed:!1}),u=e.nodes()[0],c=e.nodeCount();for(a.setNode(u,{});n=a,r=e,o.A(n.nodes(),function e(t){o.A(r.nodeEdges(t),function(o){var i=o.v,a=t===i?o.w:i;n.hasNode(a)||e7(r,o)||(n.setNode(a,{}),n.setEdge(t,a,{}),e(a))})}),n.nodeCount()<c;)t=function(e,n){return e4(n.edges(),function(r){if(e.hasNode(r.v)!==e.hasNode(r.w))return e7(n,r)})}(a,e),i=a.hasNode(t.v)?e7(e,t):-e7(e,t),function(e,n,r){o.A(e.nodes(),function(e){n.node(e).rank+=r})}(a,e,i);return a}var e6=r(9431),e5=r(7818);let ne=function(e){var n=R(e),r=n%1;return n==n?r?n-r:n:0};var nn=Math.max,nr=(t=function(e,n,r){var t=null==e?0:e.length;if(!t)return -1;var o=null==r?0:ne(r);return o<0&&(o=nn(t+o,0)),(0,e5.A)(e,(0,eT.A)(n,3),o)},function(e,n,r){var o=Object(e);if(!(0,A.A)(e)){var i=(0,eT.A)(n,3);e=(0,e6.A)(e),n=function(e){return i(o[e],e,o)}}var a=t(e,n,r);return a>-1?o[i?e[a]:a]:void 0}),nt=r(3594);c.A(1),c.A(1);var no=r(1496),ni=r(3967),na=(0,r(7604).A)("length"),nu=RegExp("[\\u200d\ud800-\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]"),nc="\ud800-\udfff",nd="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",nf="\ud83c[\udffb-\udfff]",ns="[^"+nc+"]",nv="(?:\ud83c[\udde6-\uddff]){2}",nl="[\ud800-\udbff][\udc00-\udfff]",nh="(?:"+nd+"|"+nf+")?",ng="[\\ufe0e\\ufe0f]?",nA="(?:\\u200d(?:"+[ns,nv,nl].join("|")+")"+ng+nh+")*",np=RegExp(nf+"(?="+nf+")|"+("(?:"+[ns+nd+"?",nd,nv,nl,"["+nc+"]"].join("|"))+")"+(ng+nh+nA),"g");function nb(){}function nw(e,n,r){H.A(n)||(n=[n]);var t=(e.isDirected()?e.successors:e.neighbors).bind(e),i=[],a={};return o.A(n,function(n){if(!e.hasNode(n))throw Error("Graph does not have node: "+n);!function e(n,r,t,i,a,u){!Object.prototype.hasOwnProperty.call(i,r)&&(i[r]=!0,t||u.push(r),o.A(a(r),function(r){e(n,r,t,i,a,u)}),t&&u.push(r))}(e,n,"post"===r,a,t,i)}),i}function ny(e){n=e,r=new C.T().setGraph(n.graph()),o.A(n.nodes(),function(e){r.setNode(e,n.node(e))}),o.A(n.edges(),function(e){var t=r.edge(e.v,e.w)||{weight:0,minlen:1},o=n.edge(e);r.setEdge(e.v,e.w,{weight:t.weight+o.weight,minlen:Math.max(t.minlen,o.minlen)})}),e8(e=r);var n,r,t,i,a=e9(e);for(nx(a),nm(a,e);t=nk(a);)i=nO(a,e,t),nE(a,e,t,i)}function nm(e,n){var r=nw(e,e.nodes(),"post");r=r.slice(0,r.length-1),o.A(r,function(r){var t,o,i,a;t=e,o=n,i=r,a=t.node(i).parent,t.edge(i,a).cutvalue=nj(t,o,i)})}function nj(e,n,r){var t=e.node(r).parent,i=!0,a=n.edge(r,t),u=0;return a||(i=!1,a=n.edge(t,r)),u=a.weight,o.A(n.nodeEdges(r),function(o){var a=o.v===r,c=a?o.w:o.v;if(c!==t){var d,f,s,v=a===i,l=n.edge(o).weight;if(u+=v?l:-l,d=e,f=r,s=c,d.hasEdge(f,s)){var h=e.edge(r,c).cutvalue;u+=v?-h:h}}}),u}function nx(e,n){arguments.length<2&&(n=e.nodes()[0]),function e(n,r,t,i,a){var u=t,c=n.node(i);return r[i]=!0,o.A(n.neighbors(i),function(o){Object.prototype.hasOwnProperty.call(r,o)||(t=e(n,r,t,o,i))}),c.low=u,c.lim=t++,a?c.parent=a:delete c.parent,t}(e,{},1,n)}function nk(e){return nr(e.edges(),function(n){return e.edge(n).cutvalue<0})}function nO(e,n,r){var t=r.v,o=r.w;n.hasEdge(t,o)||(t=r.w,o=r.v);var i=e.node(t),a=e.node(o),u=i,c=!1;return i.lim>a.lim&&(u=a,c=!0),e4(nt.A(n.edges(),function(n){return c===n_(e,e.node(n.v),u)&&c!==n_(e,e.node(n.w),u)}),function(e){return e7(n,e)})}function nE(e,n,r,t){var i,a,u,c,d=r.v,f=r.w;e.removeEdge(d,f),e.setEdge(t.v,t.w,{}),nx(e),nm(e,n),i=e,a=n,u=nr(i.nodes(),function(e){return!a.node(e).parent}),c=(c=nw(i,u,"pre")).slice(1),o.A(c,function(e){var n=i.node(e).parent,r=a.edge(e,n),t=!1;r||(r=a.edge(n,e),t=!0),a.node(e).rank=a.node(n).rank+(t?r.minlen:-r.minlen)})}function n_(e,n,r){return r.low<=n.lim&&n.lim<=r.lim}nb.prototype=Error(),r(7585),ny.initLowLimValues=nx,ny.initCutValues=nm,ny.calcCutValue=nj,ny.leaveEdge=nk,ny.enterEdge=nO,ny.exchangeEdges=nE;var nP=r(3308),nN=r(7864),nM=r(3048);let nR=function(e,n,r){for(var t=-1,o=e.length,i=n.length,a={};++t<o;){var u=t<i?n[t]:void 0;r(a,e[t],u)}return a};var nL=r(2557),nC=r(4721);let nT=function(e,n){var r=e.length;for(e.sort(n);r--;)e[r]=e[r].value;return e};var nS=r(5668);let nB=function(e,n){if(e!==n){var r=void 0!==e,t=null===e,o=e==e,i=(0,x.A)(e),a=void 0!==n,u=null===n,c=n==n,d=(0,x.A)(n);if(!u&&!d&&!i&&e>n||i&&a&&c&&!u&&!d||t&&a&&c||!r&&c||!o)return 1;if(!t&&!i&&!d&&e<n||d&&r&&o&&!t&&!i||u&&r&&o||!a&&o||!c)return -1}return 0},nI=function(e,n,r){for(var t=-1,o=e.criteria,i=n.criteria,a=o.length,u=r.length;++t<a;){var c=nB(o[t],i[t]);if(c){if(t>=u)return c;return c*("desc"==r[t]?-1:1)}}return e.index-n.index},nG=function(e,n,r){n=n.length?(0,nL.A)(n,function(e){return(0,H.A)(e)?function(n){return(0,eg.A)(n,1===e.length?e[0]:e)}:e}):[eM.A];var t=-1;return n=(0,nL.A)(n,(0,nS.A)(eT.A)),nT((0,nC.A)(e,function(e,r,o){return{criteria:(0,nL.A)(n,function(n){return n(e)}),index:++t,value:e}}),function(e,n){return nI(e,n,r)})};var nF=(0,el.A)(function(e,n){if(null==e)return[];var r=n.length;return r>1&&w(e,n[0],n[1])?n=[]:r>2&&w(n[0],n[1],n[2])&&(n=[n[0]]),nG(e,(0,d.A)(n,1),[])});function nU(e,n,r){for(var t;n.length&&(t=eL(n)).i<=r;)n.pop(),e.push(t.vs),r++;return r}function nq(e,n,r){return s.A(n,function(n){var t,i;return t=function(e){for(var n;e.hasNode(n=u("_root")););return n}(e),i=new C.T({compound:!0}).setGraph({root:t}).setDefaultNodeLabel(function(n){return e.node(n)}),o.A(e.nodes(),function(a){var u=e.node(a),c=e.parent(a);(u.rank===n||u.minRank<=n&&n<=u.maxRank)&&(i.setNode(a),i.setParent(a,c||t),o.A(e[r](a),function(n){var r=n.v===a?n.w:n.v,t=i.edge(r,a),o=eB.A(t)?0:t.weight;i.setEdge(r,a,{weight:e.edge(n).weight+o})}),Object.prototype.hasOwnProperty.call(u,"minRank")&&i.setNode(a,{borderLeft:u.borderLeft[n],borderRight:u.borderRight[n]}))}),i})}function nD(e,n){o.A(n,function(n){o.A(n,function(n,r){e.node(n).order=r})})}var nz=r(603);function nV(e,n,r){if(n>r){var t=n;n=r,r=t}Object.prototype.hasOwnProperty.call(e,n)||Object.defineProperty(e,n,{enumerable:!0,configurable:!0,value:{},writable:!0}),Object.defineProperty(e[n],r,{enumerable:!0,configurable:!0,value:!0,writable:!0})}function n$(e,n){var r=n&&n.debugTiming?eQ:eX;r("layout",()=>{var n=r(" buildLayoutGraph",()=>{var n,r,t;return n=e,r=new C.T({multigraph:!0,compound:!0}),t=n1(n.graph()),r.setGraph(eh({},nW,n0(t,nJ),ek(t,nZ))),o.A(n.nodes(),function(e){var t=n1(n.node(e));r.setNode(e,e_(n0(t,nH),nK)),r.setParent(e,n.parent(e))}),o.A(n.edges(),function(e){var t=n1(n.edge(e));r.setEdge(e,eh({},nX,n0(t,nQ),ek(t,nY)))}),r});r(" runLayout",()=>{var e,t;return e=n,void((t=r)(" makeSpaceForEdgeLabels",()=>{var n,r;return r=(n=e).graph(),void(r.ranksep/=2,o.A(n.edges(),function(e){var t=n.edge(e);t.minlen*=2,"c"!==t.labelpos.toLowerCase()&&("TB"===r.rankdir||"BT"===r.rankdir?t.width+=t.labeloffset:t.height+=t.labeloffset)}))}),t(" removeSelfEdges",()=>{var n;return n=e,void o.A(n.edges(),function(e){if(e.v===e.w){var r=n.node(e.v);r.selfEdges||(r.selfEdges=[]),r.selfEdges.push({e:e,label:n.edge(e)}),n.removeEdge(e)}})}),t(" acyclic",()=>{var n,r,t,i,a,c;return n="greedy"===e.graph().acyclicer?function(e,n){if(1>=e.nodeCount())return[];var r,t,i,a,u,c,d,v=(r=e,t=n||I,i=new C.T,a=0,u=0,o.A(r.nodes(),function(e){i.setNode(e,{v:e,in:0,out:0})}),o.A(r.edges(),function(e){var n=i.edge(e.v,e.w)||0,r=t(e);i.setEdge(e.v,e.w,n+r),u=Math.max(u,i.node(e.v).out+=r),a=Math.max(a,i.node(e.w).in+=r)}),c=L(u+a+3).map(function(){return new T}),d=a+1,o.A(i.nodes(),function(e){F(c,d,i.node(e))}),{graph:i,buckets:c,zeroIdx:d}),l=function(e,n,r){for(var t,o=[],i=n[n.length-1],a=n[0];e.nodeCount();){for(;t=a.dequeue();)G(e,n,r,t);for(;t=i.dequeue();)G(e,n,r,t);if(e.nodeCount()){for(var u=n.length-2;u>0;--u)if(t=n[u].dequeue()){o=o.concat(G(e,n,r,t,!0));break}}}return o}(v.graph,v.buckets,v.zeroIdx);return f(s.A(l,function(n){return e.outEdges(n.v,n.w)}))}(e,(r=e,function(e){return r.edge(e).weight})):(t=e,i=[],a={},c={},o.A(t.nodes(),function e(n){Object.prototype.hasOwnProperty.call(c,n)||(c[n]=!0,a[n]=!0,o.A(t.outEdges(n),function(n){Object.prototype.hasOwnProperty.call(a,n.w)?i.push(n):e(n.w)}),delete a[n])}),i),void o.A(n,function(n){var r=e.edge(n);e.removeEdge(n),r.forwardName=n.name,r.reversed=!0,e.setEdge(n.w,n.v,r,u("rev"))})}),t(" nestingGraph.run",()=>{var n,r,t,i,a,u,c,d;return n=e$(e,"root",{},"_root"),u=e,c={},o.A(u.children(),function(e){!function e(n,r){var t=u.children(n);t&&t.length&&o.A(t,function(n){e(n,r+1)}),c[n]=r}(e,1)}),r=c,i=2*(t=eR(nP.A(r))-1)+1,e.graph().nestingRoot=n,o.A(e.edges(),function(n){e.edge(n).minlen*=i}),a=(d=e,nN.A(d.edges(),function(e,n){return e+d.edge(n).weight},0)+1),void(o.A(e.children(),function(u){!function e(n,r,t,i,a,u,c){var d=n.children(c);if(!d.length){c!==r&&n.setEdge(r,c,{weight:0,minlen:t});return}var f=eH(n,"_bt"),s=eH(n,"_bb"),v=n.node(c);n.setParent(f,c),v.borderTop=f,n.setParent(s,c),v.borderBottom=s,o.A(d,function(o){e(n,r,t,i,a,u,o);var d=n.node(o),v=d.borderTop?d.borderTop:o,l=d.borderBottom?d.borderBottom:o,h=d.borderTop?i:2*i,g=v!==l?1:a-u[c]+1;n.setEdge(f,v,{weight:h,minlen:g,nestingEdge:!0}),n.setEdge(l,s,{weight:h,minlen:g,nestingEdge:!0})}),n.parent(c)||n.setEdge(r,f,{weight:0,minlen:a+u[c]})}(e,n,i,a,t,r,u)}),e.graph().nodeRankFactor=i)}),t(" rank",()=>(function(e){switch(e.graph().ranker){case"network-simplex":default:ny(e);break;case"tight-tree":var n;e8(n=e),e9(n);break;case"longest-path":e8(e)}})(eJ(e))),t(" injectEdgeLabelProxies",()=>{var n;return n=e,void o.A(n.edges(),function(e){var r=n.edge(e);if(r.width&&r.height){var t=n.node(e.v),o={rank:(n.node(e.w).rank-t.rank)/2+t.rank,e:e};e$(n,"edge-proxy",o,"_ep")}})}),t(" removeEmptyRanks",()=>{var n,r,t,i;return n=eG(s.A(e.nodes(),function(n){return e.node(n).rank})),r=[],o.A(e.nodes(),function(t){var o=e.node(t).rank-n;r[o]||(r[o]=[]),r[o].push(t)}),t=0,i=e.graph().nodeRankFactor,void o.A(r,function(n,r){eB.A(n)&&r%i!=0?--t:t&&o.A(n,function(n){e.node(n).rank+=t})})}),t(" nestingGraph.cleanup",()=>{var n;return n=e.graph(),void(e.removeNode(n.nestingRoot),delete n.nestingRoot,o.A(e.edges(),function(n){e.edge(n).nestingEdge&&e.removeEdge(n)}))}),t(" normalizeRanks",()=>{var n;return n=eG(s.A(e.nodes(),function(n){return e.node(n).rank})),void o.A(e.nodes(),function(r){var t=e.node(r);eD(t,"rank")&&(t.rank-=n)})}),t(" assignRankMinMax",()=>{var n,r;return n=e,r=0,void(o.A(n.nodes(),function(e){var t=n.node(e);t.borderTop&&(t.minRank=n.node(t.borderTop).rank,t.maxRank=n.node(t.borderBottom).rank,r=eR(r,t.maxRank))}),n.graph().maxRank=r)}),t(" removeEdgeLabelProxies",()=>{var n;return n=e,void o.A(n.nodes(),function(e){var r=n.node(e);"edge-proxy"===r.dummy&&(n.edge(r.e).labelRank=r.rank,n.removeNode(e))})}),t(" normalize.run",()=>{e.graph().dummyChains=[],o.A(e.edges(),function(n){!function(e,n){var r,t,o=n.v,i=e.node(o).rank,a=n.w,u=e.node(a).rank,c=n.name,d=e.edge(n),f=d.labelRank;if(u!==i+1){e.removeEdge(n);var s=void 0;for(t=0,++i;i<u;++t,++i)d.points=[],r=e$(e,"edge",s={width:0,height:0,edgeLabel:d,edgeObj:n,rank:i},"_d"),i===f&&(s.width=d.width,s.height=d.height,s.dummy="edge-label",s.labelpos=d.labelpos),e.setEdge(o,r,{weight:d.weight},c),0===t&&e.graph().dummyChains.push(r),o=r;e.setEdge(o,a,{weight:d.weight},c)}}(e,n)})}),t(" parentDummyChains",()=>{var n,r,t,i;return r=e,t={},i=0,o.A(r.children(),function e(n){var a=i;o.A(r.children(n),e),t[n]={low:a,lim:i++}}),n=t,void o.A(e.graph().dummyChains,function(r){for(var t=e.node(r),o=t.edgeObj,i=function(e,n,r,t){var o,i,a=[],u=[],c=Math.min(n[r].low,n[t].low),d=Math.max(n[r].lim,n[t].lim);o=r;do a.push(o=e.parent(o));while(o&&(n[o].low>c||d>n[o].lim));for(i=o,o=t;(o=e.parent(o))!==i;)u.push(o);return{path:a.concat(u.reverse()),lca:i}}(e,n,o.v,o.w),a=i.path,u=i.lca,c=0,d=a[0],f=!0;r!==o.w;){if(t=e.node(r),f){for(;(d=a[c])!==u&&e.node(d).maxRank<t.rank;)c++;d===u&&(f=!1)}if(!f){for(;c<a.length-1&&e.node(d=a[c+1]).minRank<=t.rank;)c++;d=a[c]}e.setParent(r,d),r=e.successors(r)[0]}})}),t(" addBorderSegments",()=>{o.A(e.children(),function n(r){var t=e.children(r),i=e.node(r);if(t.length&&o.A(t,n),Object.prototype.hasOwnProperty.call(i,"minRank")){i.borderLeft=[],i.borderRight=[];for(var a=i.minRank,u=i.maxRank+1;a<u;++a)eY(e,"borderLeft","_bl",r,i,a),eY(e,"borderRight","_br",r,i,a)}})}),t(" order",()=>(function(e){var n=eK(e),r=nq(e,L(1,n+1),"inEdges"),t=nq(e,L(n-1,-1,-1),"outEdges"),i=(a={},u=nt.A(e.nodes(),function(n){return!e.children(n).length}),c=eR(s.A(u,function(n){return e.node(n).rank})),d=s.A(L(c+1),function(){return[]}),v=nF(u,function(n){return e.node(n).rank}),o.A(v,function n(r){eD(a,r)||(a[r]=!0,d[e.node(r).rank].push(r),o.A(e.successors(r),n))}),d);nD(e,i);for(var a,u,c,d,v,l,h=1/0,g=0,A=0;A<4;++g,++A){(function(e,n){var r=new C.T;o.A(e,function(e){var t,i,a,u=e.graph().root,c=function e(n,r,t,i){var a,u,c,d,v,l,h,g,A,p,b,w,y=n.children(r),m=n.node(r),j=m?m.borderLeft:void 0,x=m?m.borderRight:void 0,k={};j&&(y=nt.A(y,function(e){return e!==j&&e!==x}));var O=(a=y,s.A(a,function(e){var r=n.inEdges(e);if(!r.length)return{v:e};var t=nN.A(r,function(e,r){var t=n.edge(r),o=n.node(r.v);return{sum:e.sum+t.weight*o.order,weight:e.weight+t.weight}},{sum:0,weight:0});return{v:e,barycenter:t.sum/t.weight,weight:t.weight}}));o.A(O,function(r){if(n.children(r.v).length){var o,a,u=e(n,r.v,t,i);k[r.v]=u,Object.prototype.hasOwnProperty.call(u,"barycenter")&&(o=r,a=u,eB.A(o.barycenter)?(o.barycenter=a.barycenter,o.weight=a.weight):(o.barycenter=(o.barycenter*o.weight+a.barycenter*a.weight)/(o.weight+a.weight),o.weight+=a.weight))}});var E=(u={},o.A(O,function(e,n){var r=u[e.v]={indegree:0,in:[],out:[],vs:[e.v],i:n};eB.A(e.barycenter)||(r.barycenter=e.barycenter,r.weight=e.weight)}),o.A(t.edges(),function(e){var n=u[e.v],r=u[e.w];eB.A(n)||eB.A(r)||(r.indegree++,n.out.push(u[e.w]))}),function(e){for(var n=[];e.length;){var r=e.pop();n.push(r),o.A(r.in.reverse(),function(e){return function(n){!n.merged&&(eB.A(n.barycenter)||eB.A(e.barycenter)||n.barycenter>=e.barycenter)&&function(e,n){var r=0,t=0;e.weight&&(r+=e.barycenter*e.weight,t+=e.weight),n.weight&&(r+=n.barycenter*n.weight,t+=n.weight),e.vs=n.vs.concat(e.vs),e.barycenter=r/t,e.weight=t,e.i=Math.min(n.i,e.i),n.merged=!0}(e,n)}}(r)),o.A(r.out,function(n){return function(r){r.in.push(n),0==--r.indegree&&e.push(r)}}(r))}return s.A(nt.A(n,function(e){return!e.merged}),function(e){return ek(e,["vs","i","barycenter","weight"])})}(nt.A(u,function(e){return!e.indegree})));!function(e,n){o.A(e,function(e){e.vs=f(e.vs.map(function(e){return n[e]?n[e].vs:e}))})}(E,k);var _=(l=(c=function(e){return Object.prototype.hasOwnProperty.call(e,"barycenter")},d={lhs:[],rhs:[]},o.A(E,function(e){c(e)?d.lhs.push(e):d.rhs.push(e)}),v=d).lhs,h=nF(v.rhs,function(e){return-e.i}),g=[],A=0,p=0,b=0,l.sort(function(e){return function(n,r){return n.barycenter<r.barycenter?-1:n.barycenter>r.barycenter?1:e?r.i-n.i:n.i-r.i}}(!!i)),b=nU(g,h,b),o.A(l,function(e){b+=e.vs.length,g.push(e.vs),A+=e.barycenter*e.weight,p+=e.weight,b=nU(g,h,b)}),w={vs:f(g)},p&&(w.barycenter=A/p,w.weight=p),w);if(j&&(_.vs=f([j,_.vs,x]),n.predecessors(j).length)){var P=n.node(n.predecessors(j)[0]),N=n.node(n.predecessors(x)[0]);Object.prototype.hasOwnProperty.call(_,"barycenter")||(_.barycenter=0,_.weight=0),_.barycenter=(_.barycenter*_.weight+P.order+N.order)/(_.weight+2),_.weight+=2}return _}(e,u,r,n);o.A(c.vs,function(n,r){e.node(n).order=r}),t=c.vs,a={},o.A(t,function(n){for(var t,o,u=e.parent(n);u;){if((t=e.parent(u))?(o=a[t],a[t]=u):(o=i,i=u),o&&o!==u)return void r.setEdge(o,u);u=t}})})})(g%2?r:t,g%4>=2),i=eZ(e);var p,b=function(e,n){for(var r=0,t=1;t<n.length;++t)r+=function(e,n,r){for(var t=nR(r||[],s.A(r,function(e,n){return n})||[],eA.A),i=f(s.A(n,function(n){return nF(s.A(e.outEdges(n),function(n){return{pos:t[n.w],weight:e.edge(n).weight}}),"pos")})),a=1;a<r.length;)a<<=1;var u=2*a-1;a-=1;var c=s.A(Array(u),function(){return 0}),d=0;return o.A(i.forEach(function(e){var n=e.pos+a;c[n]+=e.weight;for(var r=0;n>0;)n%2&&(r+=c[n+1]),n=n-1>>1,c[n]+=e.weight;d+=e.weight*r})),d}(e,n[t-1],n[t]);return r}(e,i);b<h&&(A=0,p=i,l=(0,nM.A)(p,5),h=b)}nD(e,l)})(e)),t(" insertSelfEdges",()=>{var n,r;return r=eZ(n=e),void o.A(r,function(e){var r=0;o.A(e,function(e,t){var i=n.node(e);i.order=t+r,o.A(i.selfEdges,function(e){e$(n,"selfedge",{width:e.label.width,height:e.label.height,rank:i.rank,order:t+ ++r,e:e.e,label:e.label},"_se")}),delete i.selfEdges})})}),t(" adjustCoordinateSystem",()=>{var n;("lr"===(n=e.graph().rankdir.toLowerCase())||"rl"===n)&&e0(e)}),t(" position",()=>{var n,r,t,i,a,u,c,d,f,v,l,h,g,A,p,b,w;p=eZ(A=n=eJ(n=e)),b=A.graph().ranksep,w=0,o.A(p,function(e){var n=eR(s.A(e,function(e){return A.node(e).height}));o.A(e,function(e){A.node(e).y=w+n/2}),w+=n+b}),i=eZ(r=n),u=eh((a={},nN.A(i,function(e,n){var t=0,i=0,u=e.length,c=eL(n);return o.A(n,function(e,d){var f=function(e,n){if(e.node(n).dummy)return nr(e.predecessors(n),function(n){return e.node(n).dummy})}(r,e),s=f?r.node(f).order:u;(f||e===c)&&(o.A(n.slice(i,d+1),function(e){o.A(r.predecessors(e),function(n){var o=r.node(n),i=o.order;(i<t||s<i)&&!(o.dummy&&r.node(e).dummy)&&nV(a,n,e)})}),i=d+1,t=s)}),n}),a),function(e,n){var r={};function t(n,t,i,a,u){var c;o.A(L(t,i),function(t){c=n[t],e.node(c).dummy&&o.A(e.predecessors(c),function(n){var t=e.node(n);t.dummy&&(t.order<a||t.order>u)&&nV(r,n,c)})})}return nN.A(n,function(n,r){var i,a=-1,u=0;return o.A(r,function(o,c){if("border"===e.node(o).dummy){var d=e.predecessors(o);d.length&&(i=e.node(d[0]).order,t(r,u,c,a,i),u=c,a=i)}t(r,u,r.length,i,n.length)}),r}),r}(r,i)),c={},o.A(["u","d"],function(e){t="u"===e?i:nP.A(i).reverse(),o.A(["l","r"],function(n){"r"===n&&(t=s.A(t,function(e){return nP.A(e).reverse()}));var i,a,d,f,v=("u"===e?r.predecessors:r.successors).bind(r),l=(i=t,a={},d={},f={},o.A(i,function(e){o.A(e,function(e,n){a[e]=e,d[e]=e,f[e]=n})}),o.A(i,function(e){var n=-1;o.A(e,function(e){var r=v(e);if(r.length)for(var t=((r=nF(r,function(e){return f[e]})).length-1)/2,o=Math.floor(t),i=Math.ceil(t);o<=i;++o){var c=r[o];d[e]===e&&n<f[c]&&!function(e,n,r){if(n>r){var t=n;n=r,r=t}return!!e[n]&&Object.prototype.hasOwnProperty.call(e[n],r)}(u,e,c)&&(d[c]=e,d[e]=a[e]=a[c],n=f[c])}})}),{root:a,align:d}),h=function(e,n,r,t,i){var a,u,c,d,f,s,v,l,h,g,A={},p=(a=e,u=n,c=r,d=i,l=new C.T,g=(f=(h=a.graph()).nodesep,s=h.edgesep,v=d,function(e,n,r){var t,o,i=e.node(n),a=e.node(r);if(t=0+i.width/2,Object.prototype.hasOwnProperty.call(i,"labelpos"))switch(i.labelpos.toLowerCase()){case"l":o=-i.width/2;break;case"r":o=i.width/2}if(o&&(t+=v?o:-o),o=0,t+=(i.dummy?s:f)/2,t+=(a.dummy?s:f)/2,t+=a.width/2,Object.prototype.hasOwnProperty.call(a,"labelpos"))switch(a.labelpos.toLowerCase()){case"l":o=a.width/2;break;case"r":o=-a.width/2}return o&&(t+=v?o:-o),o=0,t}),o.A(u,function(e){var n;o.A(e,function(e){var r=c[e];if(l.setNode(r),n){var t=c[n],o=l.edge(t,r);l.setEdge(t,r,Math.max(g(a,e,n),o||0))}n=e})}),l),b=i?"borderLeft":"borderRight";function w(e,n){for(var r=p.nodes(),t=r.pop(),o={};t;)o[t]?e(t):(o[t]=!0,r.push(t),r=r.concat(n(t))),t=r.pop()}return w(function(e){A[e]=p.inEdges(e).reduce(function(e,n){return Math.max(e,A[n.v]+p.edge(n))},0)},p.predecessors.bind(p)),w(function(n){var r=p.outEdges(n).reduce(function(e,n){return Math.min(e,A[n.w]-p.edge(n))},1/0),t=e.node(n);r!==1/0&&t.borderType!==b&&(A[n]=Math.max(A[n],r))},p.successors.bind(p)),o.A(t,function(e){A[e]=A[r[e]]}),A}(r,t,l.root,l.align,"r"===n);"r"===n&&(h=eS(h,function(e){return-e})),c[e+n]=h})}),d=e4(nP.A(c),function(e){var n,t=-1/0,o=1/0;return n=function(e,n){var i,a,u=(i=r,a=n,i.node(a).width/2);t=Math.max(e+u,t),o=Math.min(e-u,o)},null==e||(0,z.A)(e,(0,nz.A)(n),ef.A),t-o}),v=eG(f=nP.A(d)),l=eR(f),o.A(["u","d"],function(e){o.A(["l","r"],function(n){var r,t=e+n,o=c[t];if(o!==d){var i=nP.A(o);(r="l"===n?v-eG(i):l-eR(i))&&(c[t]=eS(o,function(e){return e+r}))}})}),h=r.graph().align,g=eS(c.ul,function(e,n){if(h)return c[h.toLowerCase()][n];var r=nF(s.A(c,n));return(r[1]+r[2])/2}),g&&(0,eC.A)(g,(0,nz.A)(function(e,r){n.node(r).x=e}))}),t(" positionSelfEdges",()=>{var n;return n=e,void o.A(n.nodes(),function(e){var r=n.node(e);if("selfedge"===r.dummy){var t=n.node(r.e.v),o=t.x+t.width/2,i=t.y,a=r.x-o,u=t.height/2;n.setEdge(r.e,r.label),n.removeNode(e),r.label.points=[{x:o+2*a/3,y:i-u},{x:o+5*a/6,y:i-u},{x:o+a,y:i},{x:o+5*a/6,y:i+u},{x:o+2*a/3,y:i+u}],r.label.x=r.x,r.label.y=r.y}})}),t(" removeBorderNodes",()=>{var n;return n=e,void(o.A(n.nodes(),function(e){if(n.children(e).length){var r=n.node(e),t=n.node(r.borderTop),o=n.node(r.borderBottom),i=n.node(eL(r.borderLeft)),a=n.node(eL(r.borderRight));r.width=Math.abs(a.x-i.x),r.height=Math.abs(o.y-t.y),r.x=i.x+r.width/2,r.y=t.y+r.height/2}}),o.A(n.nodes(),function(e){"border"===n.node(e).dummy&&n.removeNode(e)}))}),t(" normalize.undo",()=>{o.A(e.graph().dummyChains,function(n){var r,t=e.node(n),o=t.edgeLabel;for(e.setEdge(t.edgeObj,o);t.dummy;)r=e.successors(n)[0],e.removeNode(n),o.points.push({x:t.x,y:t.y}),"edge-label"===t.dummy&&(o.x=t.x,o.y=t.y,o.width=t.width,o.height=t.height),n=r,t=e.node(n)})}),t(" fixupEdgeLabelCoords",()=>{var n;return n=e,void o.A(n.edges(),function(e){var r=n.edge(e);if(Object.prototype.hasOwnProperty.call(r,"x"))switch(("l"===r.labelpos||"r"===r.labelpos)&&(r.width-=r.labeloffset),r.labelpos){case"l":r.x-=r.width/2+r.labeloffset;break;case"r":r.x+=r.width/2+r.labeloffset}})}),t(" undoCoordinateSystem",()=>{var n,r,t;("bt"===(n=e.graph().rankdir.toLowerCase())||"rl"===n)&&(r=e,o.A(r.nodes(),function(e){e2(r.node(e))}),o.A(r.edges(),function(e){var n=r.edge(e);o.A(n.points,e2),Object.prototype.hasOwnProperty.call(n,"y")&&e2(n)})),("lr"===n||"rl"===n)&&(t=e,o.A(t.nodes(),function(e){e3(t.node(e))}),o.A(t.edges(),function(e){var n=t.edge(e);o.A(n.points,e3),Object.prototype.hasOwnProperty.call(n,"x")&&e3(n)}),e0(e))}),t(" translateGraph",()=>(function(e){var n=1/0,r=0,t=1/0,i=0,a=e.graph(),u=a.marginx||0,c=a.marginy||0;function d(e){var o=e.x,a=e.y,u=e.width,c=e.height;n=Math.min(n,o-u/2),r=Math.max(r,o+u/2),t=Math.min(t,a-c/2),i=Math.max(i,a+c/2)}o.A(e.nodes(),function(n){d(e.node(n))}),o.A(e.edges(),function(n){var r=e.edge(n);Object.prototype.hasOwnProperty.call(r,"x")&&d(r)}),n-=u,t-=c,o.A(e.nodes(),function(r){var o=e.node(r);o.x-=n,o.y-=t}),o.A(e.edges(),function(r){var i=e.edge(r);o.A(i.points,function(e){e.x-=n,e.y-=t}),Object.prototype.hasOwnProperty.call(i,"x")&&(i.x-=n),Object.prototype.hasOwnProperty.call(i,"y")&&(i.y-=t)}),a.width=r-n+u,a.height=i-t+c})(e)),t(" assignNodeIntersects",()=>{var n;return n=e,void o.A(n.edges(),function(e){var r,t,o=n.edge(e),i=n.node(e.v),a=n.node(e.w);o.points?(r=o.points[0],t=o.points[o.points.length-1]):(o.points=[],r=a,t=i),o.points.unshift(eW(i,r)),o.points.push(eW(a,t))})}),t(" reversePoints",()=>{var n;return n=e,void o.A(n.edges(),function(e){var r=n.edge(e);r.reversed&&r.points.reverse()})}),t(" acyclic.undo",()=>{o.A(e.edges(),function(n){var r=e.edge(n);if(r.reversed){e.removeEdge(n);var t=r.forwardName;delete r.reversed,delete r.forwardName,e.setEdge(n.w,n.v,r,t)}})}))}),r(" updateInputGraph",()=>{var r,t;return r=e,t=n,void(o.A(r.nodes(),function(e){var n=r.node(e),o=t.node(e);n&&(n.x=o.x,n.y=o.y,t.children(e).length&&(n.width=o.width,n.height=o.height))}),o.A(r.edges(),function(e){var n=r.edge(e),o=t.edge(e);n.points=o.points,Object.prototype.hasOwnProperty.call(o,"x")&&(n.x=o.x,n.y=o.y)}),r.graph().width=t.graph().width,r.graph().height=t.graph().height)})})}var nJ=["nodesep","edgesep","ranksep","marginx","marginy"],nW={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},nZ=["acyclicer","ranker","rankdir","align"],nH=["width","height"],nK={width:0,height:0},nQ=["minlen","weight","width","height","labeloffset"],nX={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},nY=["labelpos"];function n0(e,n){return eS(ek(e,n),Number)}function n1(e){var n={};return o.A(e,function(e,r){n[r.toLowerCase()]=e}),n}},4721:(e,n,r)=>{r.d(n,{A:()=>i});var t=r(936),o=r(1383);let i=function(e,n){var r=-1,i=(0,o.A)(e)?Array(e.length):[];return(0,t.A)(e,function(e,t,o){i[++r]=n(e,t,o)}),i}},5041:(e,n,r)=>{r.d(n,{A:()=>o});var t=r(6778);let o=function(e,n,r){"__proto__"==n&&t.A?(0,t.A)(e,n,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[n]=r}},7294:(e,n,r)=>{r.d(n,{A:()=>c});var t=r(3476),o=Object.create,i=function(){function e(){}return function(n){if(!(0,t.A)(n))return{};if(o)return o(n);e.prototype=n;var r=new e;return e.prototype=void 0,r}}(),a=r(9614),u=r(3798);let c=function(e){return"function"!=typeof e.constructor||(0,u.A)(e)?{}:i((0,a.A)(e))}},7386:(e,n,r)=>{r.d(n,{A:()=>a});var t=r(5041),o=r(7537),i=Object.prototype.hasOwnProperty;let a=function(e,n,r){var a=e[n];i.call(e,n)&&(0,o.A)(a,r)&&(void 0!==r||n in e)||(0,t.A)(e,n,r)}},7939:(e,n,r)=>{r.d(n,{A:()=>c});var t=r(2308),o="object"==typeof exports&&exports&&!exports.nodeType&&exports,i=o&&"object"==typeof module&&module&&!module.nodeType&&module,a=i&&i.exports===o?t.A.Buffer:void 0,u=a?a.allocUnsafe:void 0;let c=function(e,n){if(n)return e.slice();var r=e.length,t=u?u(r):new e.constructor(r);return e.copy(t),t}},7988:(e,n,r)=>{r.d(n,{A:()=>o});var t=r(4573);let o=function(e){var n=new e.constructor(e.byteLength);return new t.A(n).set(new t.A(e)),n}},7998:(e,n,r)=>{r.d(n,{A:()=>t});let t=function(e,n){var r=-1,t=e.length;for(n||(n=Array(t));++r<t;)n[r]=e[r];return n}},8046:(e,n,r)=>{r.d(n,{A:()=>f});var t=r(9584),o=r(3476),i=r(3798);let a=function(e){var n=[];if(null!=e)for(var r in Object(e))n.push(r);return n};var u=Object.prototype.hasOwnProperty;let c=function(e){if(!(0,o.A)(e))return a(e);var n=(0,i.A)(e),r=[];for(var t in e)"constructor"==t&&(n||!u.call(e,t))||r.push(t);return r};var d=r(1383);let f=function(e){return(0,d.A)(e)?(0,t.A)(e,!0):c(e)}},9294:(e,n,r)=>{r.d(n,{A:()=>i});var t=r(7386),o=r(5041);let i=function(e,n,r,i){var a=!r;r||(r={});for(var u=-1,c=n.length;++u<c;){var d=n[u],f=i?i(r[d],e[d],d,r,e):void 0;void 0===f&&(f=e[d]),a?(0,o.A)(r,d,f):(0,t.A)(r,d,f)}return r}},9614:(e,n,r)=>{r.d(n,{A:()=>t});let t=(0,r(454).A)(Object.getPrototypeOf,Object)}}]);
_next/static/chunks/4bd1b696-f785427dddbba9fb.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/5090.850b2168c1a2a9a5.js ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5090],{2888:(e,t,a)=>{a.d(t,{P:()=>s});var l=a(669),r=a(316),s=(0,r.K2)((e,t,a,s)=>{e.attr("class",a);let{width:o,height:c,x:d,y:p}=i(e,t);(0,l.a$)(e,c,o,s);let h=n(d,p,o,c,t);e.attr("viewBox",h),r.Rm.debug(`viewBox configured: ${h} with padding: ${t}`)},"setupViewPortForSVG"),i=(0,r.K2)((e,t)=>{let a=e.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:a.width+2*t,height:a.height+2*t,x:a.x,y:a.y}},"calculateDimensionsWithPadding"),n=(0,r.K2)((e,t,a,l,r)=>`${e-r} ${t-r} ${a} ${l}`,"createViewBox")},5090:(e,t,a)=>{a.d(t,{diagram:()=>$});var l=a(2667),r=a(2888),s=a(3148),i=a(7566),n=a(3736),o=a(669),c=a(316),d=a(4290),p=a(5508),h=class{constructor(){this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.setAccTitle=o.SV,this.getAccTitle=o.iN,this.setDiagramTitle=o.ke,this.getDiagramTitle=o.ab,this.getAccDescription=o.m7,this.setAccDescription=o.EI}static{(0,c.K2)(this,"TreeMapDB")}getNodes(){return this.nodes}getConfig(){let e=o.UI,t=(0,o.zj)();return(0,n.$t)({...e.treemap,...t.treemap??{}})}addNode(e,t){this.nodes.push(e),this.levels.set(e,t),0===t&&(this.outerNodes.push(e),this.root??=e)}getRoot(){return{name:"",children:this.outerNodes}}addClass(e,t){let a=this.classes.get(e)??{id:e,styles:[],textStyles:[]},l=t.replace(/\\,/g,"\xa7\xa7\xa7").replace(/,/g,";").replace(/§§§/g,",").split(";");l&&l.forEach(e=>{(0,s.KX)(e)&&(a?.textStyles?a.textStyles.push(e):a.textStyles=[e]),a?.styles?a.styles.push(e):a.styles=[e]}),this.classes.set(e,a)}getClasses(){return this.classes}getStylesForClass(e){return this.classes.get(e)?.styles??[]}clear(){(0,o.IU)(),this.nodes=[],this.levels=new Map,this.outerNodes=[],this.classes=new Map,this.root=void 0}};function m(e){if(!e.length)return[];let t=[],a=[];return e.forEach(e=>{let l={name:e.name,children:"Leaf"===e.type?void 0:[]};for(l.classSelector=e?.classSelector,e?.cssCompiledStyles&&(l.cssCompiledStyles=e.cssCompiledStyles),"Leaf"===e.type&&void 0!==e.value&&(l.value=e.value);a.length>0&&a[a.length-1].level>=e.level;)a.pop();if(0===a.length)t.push(l);else{let e=a[a.length-1].node;e.children?e.children.push(l):e.children=[l]}"Leaf"!==e.type&&a.push({node:l,level:e.level})}),t}(0,c.K2)(m,"buildHierarchy");var y=(0,c.K2)((e,t)=>{(0,i.S)(e,t);let a=[];for(let a of e.TreemapRows??[])"ClassDefStatement"===a.$type&&t.addClass(a.className??"",a.styleText??"");for(let l of e.TreemapRows??[]){let e=l.item;if(!e)continue;let r=l.indent?parseInt(l.indent):0,s=f(e),i=e.classSelector?t.getStylesForClass(e.classSelector):[],n=i.length>0?i:void 0,o={level:r,name:s,type:e.$type,value:e.value,classSelector:e.classSelector,cssCompiledStyles:n};a.push(o)}let l=m(a),r=(0,c.K2)((e,a)=>{for(let l of e)t.addNode(l,a),l.children&&l.children.length>0&&r(l.children,a+1)},"addNodesRecursively");r(l,0)},"populate"),f=(0,c.K2)(e=>e.name?String(e.name):"","getItemName"),u={parser:{yy:void 0},parse:(0,c.K2)(async e=>{try{let t=d.qg,a=await t("treemap",e);c.Rm.debug("Treemap AST:",a);let l=u.parser?.yy;if(!(l instanceof h))throw Error("parser.parser?.yy was not a TreemapDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");y(a,l)}catch(e){throw c.Rm.error("Error parsing treemap:",e),e}},"parse")},S=(0,c.K2)((e,t,a,i)=>{let n,d=i.db,h=d.getConfig(),m=h.padding??10,y=d.getDiagramTitle(),f=d.getRoot(),{themeVariables:u}=(0,o.zj)();if(!f)return;let S=30*!!y,g=(0,l.D)(t),x=h.nodeWidth?10*h.nodeWidth:960,$=h.nodeHeight?10*h.nodeHeight:500,b=$+S;g.attr("viewBox",`0 0 ${x} ${b}`),(0,o.a$)(g,b,x,h.useMaxWidth);try{let e=h.valueFormat||",";if("$0,0"===e)n=(0,c.K2)(e=>"$"+(0,p.GPZ)(",")(e),"valueFormat");else if(e.startsWith("$")&&e.includes(",")){let t=/\.\d+/.exec(e),a=t?t[0]:"";n=(0,c.K2)(e=>"$"+(0,p.GPZ)(","+a)(e),"valueFormat")}else if(e.startsWith("$")){let t=e.substring(1);n=(0,c.K2)(e=>"$"+(0,p.GPZ)(t||"")(e),"valueFormat")}else n=(0,p.GPZ)(e)}catch(e){c.Rm.error("Error creating format function:",e),n=(0,p.GPZ)(",")}let v=(0,p.UMr)().range(["transparent",u.cScale0,u.cScale1,u.cScale2,u.cScale3,u.cScale4,u.cScale5,u.cScale6,u.cScale7,u.cScale8,u.cScale9,u.cScale10,u.cScale11]),C=(0,p.UMr)().range(["transparent",u.cScalePeer0,u.cScalePeer1,u.cScalePeer2,u.cScalePeer3,u.cScalePeer4,u.cScalePeer5,u.cScalePeer6,u.cScalePeer7,u.cScalePeer8,u.cScalePeer9,u.cScalePeer10,u.cScalePeer11]),w=(0,p.UMr)().range([u.cScaleLabel0,u.cScaleLabel1,u.cScaleLabel2,u.cScaleLabel3,u.cScaleLabel4,u.cScaleLabel5,u.cScaleLabel6,u.cScaleLabel7,u.cScaleLabel8,u.cScaleLabel9,u.cScaleLabel10,u.cScaleLabel11]);y&&g.append("text").attr("x",x/2).attr("y",S/2).attr("class","treemapTitle").attr("text-anchor","middle").attr("dominant-baseline","middle").text(y);let L=g.append("g").attr("transform",`translate(0, ${S})`).attr("class","treemapContainer"),k=(0,p.Sk5)(f).sum(e=>e.value??0).sort((e,t)=>(t.value??0)-(e.value??0)),T=(0,p.hkb)().size([x,$]).paddingTop(e=>e.children&&e.children.length>0?35:0).paddingInner(m).paddingLeft(e=>e.children&&e.children.length>0?10:0).paddingRight(e=>e.children&&e.children.length>0?10:0).paddingBottom(e=>e.children&&e.children.length>0?10:0).round(!0)(k),P=T.descendants().filter(e=>e.children&&e.children.length>0),M=L.selectAll(".treemapSection").data(P).enter().append("g").attr("class","treemapSection").attr("transform",e=>`translate(${e.x0},${e.y0})`);M.append("rect").attr("width",e=>e.x1-e.x0).attr("height",25).attr("class","treemapSectionHeader").attr("fill","none").attr("fill-opacity",.6).attr("stroke-width",.6).attr("style",e=>0===e.depth?"display: none;":""),M.append("clipPath").attr("id",(e,a)=>`clip-section-${t}-${a}`).append("rect").attr("width",e=>Math.max(0,e.x1-e.x0-12)).attr("height",25),M.append("rect").attr("width",e=>e.x1-e.x0).attr("height",e=>e.y1-e.y0).attr("class",(e,t)=>`treemapSection section${t}`).attr("fill",e=>v(e.data.name)).attr("fill-opacity",.6).attr("stroke",e=>C(e.data.name)).attr("stroke-width",2).attr("stroke-opacity",.4).attr("style",e=>{if(0===e.depth)return"display: none;";let t=(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles});return t.nodeStyles+";"+t.borderStyles.join(";")}),M.append("text").attr("class","treemapSectionLabel").attr("x",6).attr("y",12.5).attr("dominant-baseline","middle").text(e=>0===e.depth?"":e.data.name).attr("font-weight","bold").attr("style",e=>0===e.depth?"display: none;":"dominant-baseline: middle; font-size: 12px; fill:"+w(e.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;"+(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).each(function(e){if(0===e.depth)return;let t=(0,p.Ltv)(this),a=e.data.name;t.text(a);let l=e.x1-e.x0,r=Math.max(15,!1!==h.showValues&&e.value?l-10-30-10-6:l-6-6),s=t.node();if(s.getComputedTextLength()>r){let e=a;for(;e.length>0;){if(0===(e=a.substring(0,e.length-1)).length){t.text("..."),s.getComputedTextLength()>r&&t.text("");break}if(t.text(e+"..."),s.getComputedTextLength()<=r)break}}}),!1!==h.showValues&&M.append("text").attr("class","treemapSectionValue").attr("x",e=>e.x1-e.x0-10).attr("y",12.5).attr("text-anchor","end").attr("dominant-baseline","middle").text(e=>e.value?n(e.value):"").attr("font-style","italic").attr("style",e=>0===e.depth?"display: none;":"text-anchor: end; dominant-baseline: middle; font-size: 10px; fill:"+w(e.data.name)+"; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;"+(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:"));let z=T.leaves(),F=L.selectAll(".treemapLeafGroup").data(z).enter().append("g").attr("class",(e,t)=>`treemapNode treemapLeafGroup leaf${t}${e.data.classSelector?` ${e.data.classSelector}`:""}x`).attr("transform",e=>`translate(${e.x0},${e.y0})`);F.append("rect").attr("width",e=>e.x1-e.x0).attr("height",e=>e.y1-e.y0).attr("class","treemapLeaf").attr("fill",e=>e.parent?v(e.parent.data.name):v(e.data.name)).attr("style",e=>(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles}).nodeStyles).attr("fill-opacity",.3).attr("stroke",e=>e.parent?v(e.parent.data.name):v(e.data.name)).attr("stroke-width",3),F.append("clipPath").attr("id",(e,a)=>`clip-${t}-${a}`).append("rect").attr("width",e=>Math.max(0,e.x1-e.x0-4)).attr("height",e=>Math.max(0,e.y1-e.y0-4)),F.append("text").attr("class","treemapLabel").attr("x",e=>(e.x1-e.x0)/2).attr("y",e=>(e.y1-e.y0)/2).attr("style",e=>"text-anchor: middle; dominant-baseline: middle; font-size: 38px;fill:"+w(e.data.name)+";"+(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).attr("clip-path",(e,a)=>`url(#clip-${t}-${a})`).text(e=>e.data.name).each(function(e){let t=(0,p.Ltv)(this),a=e.x1-e.x0,l=e.y1-e.y0,r=t.node(),s=a-8,i=l-8;if(s<10||i<10)return void t.style("display","none");let n=parseInt(t.style("font-size"),10);for(;r.getComputedTextLength()>s&&n>8;)n--,t.style("font-size",`${n}px`);let o=Math.max(6,Math.min(28,Math.round(.6*n))),c=n+2+o;for(;c>i&&n>8&&(!((o=Math.max(6,Math.min(28,Math.round(.6*--n))))<6)||8!==n);)t.style("font-size",`${n}px`),c=n+2+o;t.style("font-size",`${n}px`),(r.getComputedTextLength()>s||n<8||i<n)&&t.style("display","none")}),!1!==h.showValues&&F.append("text").attr("class","treemapValue").attr("x",e=>(e.x1-e.x0)/2).attr("y",function(e){return(e.y1-e.y0)/2}).attr("style",e=>"text-anchor: middle; dominant-baseline: hanging; font-size: 28px;fill:"+w(e.data.name)+";"+(0,s.GX)({cssCompiledStyles:e.data.cssCompiledStyles}).labelStyles.replace("color:","fill:")).attr("clip-path",(e,a)=>`url(#clip-${t}-${a})`).text(e=>e.value?n(e.value):"").each(function(e){let t=(0,p.Ltv)(this),a=this.parentNode;if(!a)return void t.style("display","none");let l=(0,p.Ltv)(a).select(".treemapLabel");if(l.empty()||"none"===l.style("display"))return void t.style("display","none");let r=parseFloat(l.style("font-size")),s=Math.max(6,Math.min(28,Math.round(.6*r)));t.style("font-size",`${s}px`);let i=(e.y1-e.y0)/2+r/2+2;t.attr("y",i);let n=e.x1-e.x0,o=e.y1-e.y0;t.node().getComputedTextLength()>n-8||i+s>o-4||s<6?t.style("display","none"):t.style("display",null)});let K=h.diagramPadding??8;(0,r.P)(g,K,"flowchart",h?.useMaxWidth||!1)},"draw"),g=(0,c.K2)(function(e,t){return t.db.getClasses()},"getClasses"),x={sectionStrokeColor:"black",sectionStrokeWidth:"1",sectionFillColor:"#efefef",leafStrokeColor:"black",leafStrokeWidth:"1",leafFillColor:"#efefef",labelFontSize:"12px",valueFontSize:"10px",titleFontSize:"14px"},$={parser:u,get db(){return new h},renderer:{draw:S,getClasses:g},styles:(0,c.K2)(({treemap:e}={})=>{let t=(0,o.P$)(),a=(0,o.zj)(),l=(0,n.$t)(t,a.themeVariables),r=(0,n.$t)(x,e),s=r.titleColor??l.titleColor,i=r.labelColor??l.textColor,c=r.valueColor??l.textColor;return`
2
+ .treemapNode.section {
3
+ stroke: ${r.sectionStrokeColor};
4
+ stroke-width: ${r.sectionStrokeWidth};
5
+ fill: ${r.sectionFillColor};
6
+ }
7
+ .treemapNode.leaf {
8
+ stroke: ${r.leafStrokeColor};
9
+ stroke-width: ${r.leafStrokeWidth};
10
+ fill: ${r.leafFillColor};
11
+ }
12
+ .treemapLabel {
13
+ fill: ${i};
14
+ font-size: ${r.labelFontSize};
15
+ }
16
+ .treemapValue {
17
+ fill: ${c};
18
+ font-size: ${r.valueFontSize};
19
+ }
20
+ .treemapTitle {
21
+ fill: ${s};
22
+ font-size: ${r.titleFontSize};
23
+ }
24
+ `},"getStyles")}},7566:(e,t,a)=>{function l(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}a.d(t,{S:()=>l}),(0,a(316).K2)(l,"populateCommonDb")}}]);
_next/static/chunks/5198.eaf564cf731be65e.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5198],{5198:(e,s,a)=>{a.d(s,{createGitGraphServices:()=>c.b});var c=a(4511);a(4839)}}]);
_next/static/chunks/5244.25924b6e2254ceb0.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/5294.2ba6d8370ce6373a.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5294],{3062:(t,e,r)=>{r.d(e,{CP:()=>p,Ck:()=>h,HT:()=>y,PB:()=>c,aC:()=>x,lC:()=>d,m:()=>o,tk:()=>n});var a=r(669),s=r(316),l=r(3572),i=r(5508),n=(0,s.K2)((t,e)=>{let r=t.append("rect");if(r.attr("x",e.x),r.attr("y",e.y),r.attr("fill",e.fill),r.attr("stroke",e.stroke),r.attr("width",e.width),r.attr("height",e.height),e.name&&r.attr("name",e.name),e.rx&&r.attr("rx",e.rx),e.ry&&r.attr("ry",e.ry),void 0!==e.attrs)for(let t in e.attrs)r.attr(t,e.attrs[t]);return e.class&&r.attr("class",e.class),r},"drawRect"),d=(0,s.K2)((t,e)=>{n(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"}).lower()},"drawBackgroundRect"),o=(0,s.K2)((t,e)=>{let r=e.text.replace(a.H1," "),s=t.append("text");s.attr("x",e.x),s.attr("y",e.y),s.attr("class","legend"),s.style("text-anchor",e.anchor),e.class&&s.attr("class",e.class);let l=s.append("tspan");return l.attr("x",e.x+2*e.textMargin),l.text(r),s},"drawText"),x=(0,s.K2)((t,e,r,a)=>{let s=t.append("image");s.attr("x",e),s.attr("y",r);let i=(0,l.J)(a);s.attr("xlink:href",i)},"drawImage"),p=(0,s.K2)((t,e,r,a)=>{let s=t.append("use");s.attr("x",e),s.attr("y",r);let i=(0,l.J)(a);s.attr("xlink:href",`#${i}`)},"drawEmbeddedImage"),c=(0,s.K2)(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),y=(0,s.K2)(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj"),h=(0,s.K2)(()=>{let t=(0,i.Ltv)(".mermaidTooltip");return t.empty()&&(t=(0,i.Ltv)("body").append("div").attr("class","mermaidTooltip").style("opacity",0).style("position","absolute").style("text-align","center").style("max-width","200px").style("padding","2px").style("font-size","12px").style("background","#ffffde").style("border","1px solid #333").style("border-radius","2px").style("pointer-events","none").style("z-index","100")),t},"createTooltip")},3259:(t,e,r)=>{r.d(e,{m:()=>s});var a=r(316),s=class{constructor(t){this.init=t,this.records=this.init()}static{(0,a.K2)(this,"ImperativeState")}reset(){this.records=this.init()}}}}]);
_next/static/chunks/533.caf5b2430c4c7b94.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[533],{533:(t,i,e)=>{e.d(i,{diagram:()=>ti});var s,a=e(2667),n=e(1538),h=e(3736),o=e(669),r=e(316),l=e(5508),c=function(){var t=(0,r.K2)(function(t,i,e,s){for(e=e||{},s=t.length;s--;e[t[s]]=i);return e},"o"),i=[1,10,12,14,16,18,19,21,23],e=[2,6],s=[1,3],a=[1,5],n=[1,6],h=[1,7],o=[1,5,10,12,14,16,18,19,21,23,34,35,36],l=[1,25],c=[1,26],g=[1,28],u=[1,29],x=[1,30],d=[1,31],p=[1,32],f=[1,33],m=[1,34],y=[1,35],b=[1,36],A=[1,37],w=[1,43],S=[1,42],C=[1,47],k=[1,50],_=[1,10,12,14,16,18,19,21,23,34,35,36],T=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36],R=[1,10,12,14,16,18,19,21,23,24,26,27,28,34,35,36,41,42,43,44,45,46,47,48,49,50],D=[1,64],L={trace:(0,r.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,eol:4,XYCHART:5,chartConfig:6,document:7,CHART_ORIENTATION:8,statement:9,title:10,text:11,X_AXIS:12,parseXAxis:13,Y_AXIS:14,parseYAxis:15,LINE:16,plotData:17,BAR:18,acc_title:19,acc_title_value:20,acc_descr:21,acc_descr_value:22,acc_descr_multiline_value:23,SQUARE_BRACES_START:24,commaSeparatedNumbers:25,SQUARE_BRACES_END:26,NUMBER_WITH_DECIMAL:27,COMMA:28,xAxisData:29,bandData:30,ARROW_DELIMITER:31,commaSeparatedTexts:32,yAxisData:33,NEWLINE:34,SEMI:35,EOF:36,alphaNum:37,STR:38,MD_STR:39,alphaNumToken:40,AMP:41,NUM:42,ALPHA:43,PLUS:44,EQUALS:45,MULT:46,DOT:47,BRKT:48,MINUS:49,UNDERSCORE:50,$accept:0,$end:1},terminals_:{2:"error",5:"XYCHART",8:"CHART_ORIENTATION",10:"title",12:"X_AXIS",14:"Y_AXIS",16:"LINE",18:"BAR",19:"acc_title",20:"acc_title_value",21:"acc_descr",22:"acc_descr_value",23:"acc_descr_multiline_value",24:"SQUARE_BRACES_START",26:"SQUARE_BRACES_END",27:"NUMBER_WITH_DECIMAL",28:"COMMA",31:"ARROW_DELIMITER",34:"NEWLINE",35:"SEMI",36:"EOF",38:"STR",39:"MD_STR",41:"AMP",42:"NUM",43:"ALPHA",44:"PLUS",45:"EQUALS",46:"MULT",47:"DOT",48:"BRKT",49:"MINUS",50:"UNDERSCORE"},productions_:[0,[3,2],[3,3],[3,2],[3,1],[6,1],[7,0],[7,2],[9,2],[9,2],[9,2],[9,2],[9,2],[9,3],[9,2],[9,3],[9,2],[9,2],[9,1],[17,3],[25,3],[25,1],[13,1],[13,2],[13,1],[29,1],[29,3],[30,3],[32,3],[32,1],[15,1],[15,2],[15,1],[33,3],[4,1],[4,1],[4,1],[11,1],[11,1],[11,1],[37,1],[37,2],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1],[40,1]],performAction:(0,r.K2)(function(t,i,e,s,a,n,h){var o=n.length-1;switch(a){case 5:s.setOrientation(n[o]);break;case 9:s.setDiagramTitle(n[o].text.trim());break;case 12:s.setLineData({text:"",type:"text"},n[o]);break;case 13:s.setLineData(n[o-1],n[o]);break;case 14:s.setBarData({text:"",type:"text"},n[o]);break;case 15:s.setBarData(n[o-1],n[o]);break;case 16:this.$=n[o].trim(),s.setAccTitle(this.$);break;case 17:case 18:this.$=n[o].trim(),s.setAccDescription(this.$);break;case 19:case 27:this.$=n[o-1];break;case 20:this.$=[Number(n[o-2]),...n[o]];break;case 21:this.$=[Number(n[o])];break;case 22:s.setXAxisTitle(n[o]);break;case 23:s.setXAxisTitle(n[o-1]);break;case 24:s.setXAxisTitle({type:"text",text:""});break;case 25:s.setXAxisBand(n[o]);break;case 26:s.setXAxisRangeData(Number(n[o-2]),Number(n[o]));break;case 28:this.$=[n[o-2],...n[o]];break;case 29:this.$=[n[o]];break;case 30:s.setYAxisTitle(n[o]);break;case 31:s.setYAxisTitle(n[o-1]);break;case 32:s.setYAxisTitle({type:"text",text:""});break;case 33:s.setYAxisRangeData(Number(n[o-2]),Number(n[o]));break;case 37:case 38:this.$={text:n[o],type:"text"};break;case 39:this.$={text:n[o],type:"markdown"};break;case 40:this.$=n[o];break;case 41:this.$=n[o-1]+""+n[o]}},"anonymous"),table:[t(i,e,{3:1,4:2,7:4,5:s,34:a,35:n,36:h}),{1:[3]},t(i,e,{4:2,7:4,3:8,5:s,34:a,35:n,36:h}),t(i,e,{4:2,7:4,6:9,3:10,5:s,8:[1,11],34:a,35:n,36:h}),{1:[2,4],9:12,10:[1,13],12:[1,14],14:[1,15],16:[1,16],18:[1,17],19:[1,18],21:[1,19],23:[1,20]},t(o,[2,34]),t(o,[2,35]),t(o,[2,36]),{1:[2,1]},t(i,e,{4:2,7:4,3:21,5:s,34:a,35:n,36:h}),{1:[2,3]},t(o,[2,5]),t(i,[2,7],{4:22,34:a,35:n,36:h}),{11:23,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},{11:39,13:38,24:w,27:S,29:40,30:41,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},{11:45,15:44,27:C,33:46,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},{11:49,17:48,24:k,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},{11:52,17:51,24:k,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},{20:[1,53]},{22:[1,54]},t(_,[2,18]),{1:[2,2]},t(_,[2,8]),t(_,[2,9]),t(T,[2,37],{40:55,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A}),t(T,[2,38]),t(T,[2,39]),t(R,[2,40]),t(R,[2,42]),t(R,[2,43]),t(R,[2,44]),t(R,[2,45]),t(R,[2,46]),t(R,[2,47]),t(R,[2,48]),t(R,[2,49]),t(R,[2,50]),t(R,[2,51]),t(_,[2,10]),t(_,[2,22],{30:41,29:56,24:w,27:S}),t(_,[2,24]),t(_,[2,25]),{31:[1,57]},{11:59,32:58,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},t(_,[2,11]),t(_,[2,30],{33:60,27:C}),t(_,[2,32]),{31:[1,61]},t(_,[2,12]),{17:62,24:k},{25:63,27:D},t(_,[2,14]),{17:65,24:k},t(_,[2,16]),t(_,[2,17]),t(R,[2,41]),t(_,[2,23]),{27:[1,66]},{26:[1,67]},{26:[2,29],28:[1,68]},t(_,[2,31]),{27:[1,69]},t(_,[2,13]),{26:[1,70]},{26:[2,21],28:[1,71]},t(_,[2,15]),t(_,[2,26]),t(_,[2,27]),{11:59,32:72,37:24,38:l,39:c,40:27,41:g,42:u,43:x,44:d,45:p,46:f,47:m,48:y,49:b,50:A},t(_,[2,33]),t(_,[2,19]),{25:73,27:D},{26:[2,28]},{26:[2,20]}],defaultActions:{8:[2,1],10:[2,3],21:[2,2],72:[2,28],73:[2,20]},parseError:(0,r.K2)(function(t,i){if(i.recoverable)this.trace(t);else{var e=Error(t);throw e.hash=i,e}},"parseError"),parse:(0,r.K2)(function(t){var i=this,e=[0],s=[],a=[null],n=[],h=this.table,o="",l=0,c=0,g=0,u=n.slice.call(arguments,1),x=Object.create(this.lexer),d={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(d[p]=this.yy[p]);x.setInput(t,d),d.lexer=x,d.parser=this,void 0===x.yylloc&&(x.yylloc={});var f=x.yylloc;n.push(f);var m=x.options&&x.options.ranges;function y(){var t;return"number"!=typeof(t=s.pop()||x.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=i.symbols_[t]||t),t}"function"==typeof d.parseError?this.parseError=d.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.K2)(function(t){e.length=e.length-2*t,a.length=a.length-t,n.length=n.length-t},"popStack"),(0,r.K2)(y,"lex");for(var b,A,w,S,C,k,_,T,R,D={};;){if(w=e[e.length-1],this.defaultActions[w]?S=this.defaultActions[w]:(null==b&&(b=y()),S=h[w]&&h[w][b]),void 0===S||!S.length||!S[0]){var L="";for(k in R=[],h[w])this.terminals_[k]&&k>2&&R.push("'"+this.terminals_[k]+"'");L=x.showPosition?"Parse error on line "+(l+1)+":\n"+x.showPosition()+"\nExpecting "+R.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==b?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(L,{text:x.match,token:this.terminals_[b]||b,line:x.yylineno,loc:f,expected:R})}if(S[0]instanceof Array&&S.length>1)throw Error("Parse Error: multiple actions possible at state: "+w+", token: "+b);switch(S[0]){case 1:e.push(b),a.push(x.yytext),n.push(x.yylloc),e.push(S[1]),b=null,A?(b=A,A=null):(c=x.yyleng,o=x.yytext,l=x.yylineno,f=x.yylloc,g>0&&g--);break;case 2:if(_=this.productions_[S[1]][1],D.$=a[a.length-_],D._$={first_line:n[n.length-(_||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(_||1)].first_column,last_column:n[n.length-1].last_column},m&&(D._$.range=[n[n.length-(_||1)].range[0],n[n.length-1].range[1]]),void 0!==(C=this.performAction.apply(D,[o,c,l,d,S[1],a,n].concat(u))))return C;_&&(e=e.slice(0,-1*_*2),a=a.slice(0,-1*_),n=n.slice(0,-1*_)),e.push(this.productions_[S[1]][0]),a.push(D.$),n.push(D._$),T=h[e[e.length-2]][e[e.length-1]],e.push(T);break;case 3:return!0}}return!0},"parse")};function P(){this.yy={}}return L.lexer={EOF:1,parseError:(0,r.K2)(function(t,i){if(this.yy.parser)this.yy.parser.parseError(t,i);else throw Error(t)},"parseError"),setInput:(0,r.K2)(function(t,i){return this.yy=i||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,r.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,r.K2)(function(t){var i=t.length,e=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-i),this.offset-=i;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),e.length-1&&(this.yylineno-=e.length-1);var a=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:e?(e.length===s.length?this.yylloc.first_column:0)+s[s.length-e.length].length-e[0].length:this.yylloc.first_column-i},this.options.ranges&&(this.yylloc.range=[a[0],a[0]+this.yyleng-i]),this.yyleng=this.yytext.length,this},"unput"),more:(0,r.K2)(function(){return this._more=!0,this},"more"),reject:(0,r.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,r.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,r.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,r.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,r.K2)(function(){var t=this.pastInput(),i=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+i+"^"},"showPosition"),test_match:(0,r.K2)(function(t,i){var e,s,a;if(this.options.backtrack_lexer&&(a={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&&(a.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],e=this.performAction.call(this,this.yy,this,i,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),e)return e;if(this._backtrack)for(var n in a)this[n]=a[n];return!1},"test_match"),next:(0,r.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,i,e,s,a=this._currentRules(),n=0;n<a.length;n++)if((e=this._input.match(this.rules[a[n]]))&&(!i||e[0].length>i[0].length)){if(i=e,s=n,this.options.backtrack_lexer){if(!1!==(t=this.test_match(e,a[n])))return t;if(!this._backtrack)return!1;i=!1;continue}if(!this.options.flex)break}return i?!1!==(t=this.test_match(i,a[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,r.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,r.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,r.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,r.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,r.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,r.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,r.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.K2)(function(t,i,e,s){switch(e){case 0:case 1:case 5:case 44:break;case 2:case 3:return this.popState(),34;case 4:return 34;case 6:return 10;case 7:return this.pushState("acc_title"),19;case 8:return this.popState(),"acc_title_value";case 9:return this.pushState("acc_descr"),21;case 10:return this.popState(),"acc_descr_value";case 11:this.pushState("acc_descr_multiline");break;case 12:case 26:case 28:this.popState();break;case 13:return"acc_descr_multiline_value";case 14:case 15:return 5;case 16:return 8;case 17:return this.pushState("axis_data"),"X_AXIS";case 18:return this.pushState("axis_data"),"Y_AXIS";case 19:return this.pushState("axis_band_data"),24;case 20:return 31;case 21:return this.pushState("data"),16;case 22:return this.pushState("data"),18;case 23:return this.pushState("data_inner"),24;case 24:return 27;case 25:return this.popState(),26;case 27:this.pushState("string");break;case 29:return"STR";case 30:return 24;case 31:return 26;case 32:return 43;case 33:return"COLON";case 34:return 44;case 35:return 28;case 36:return 45;case 37:return 46;case 38:return 48;case 39:return 50;case 40:return 47;case 41:return 41;case 42:return 49;case 43:return 42;case 45:return 35;case 46:return 36}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:(\r?\n))/i,/^(?:(\r?\n))/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:\})/i,/^(?:[^\}]*)/i,/^(?:xychart-beta\b)/i,/^(?:xychart\b)/i,/^(?:(?:vertical|horizontal))/i,/^(?:x-axis\b)/i,/^(?:y-axis\b)/i,/^(?:\[)/i,/^(?:-->)/i,/^(?:line\b)/i,/^(?:bar\b)/i,/^(?:\[)/i,/^(?:[+-]?(?:\d+(?:\.\d+)?|\.\d+))/i,/^(?:\])/i,/^(?:(?:`\) \{ this\.pushState\(md_string\); \}\n<md_string>\(\?:\(\?!`"\)\.\)\+ \{ return MD_STR; \}\n<md_string>\(\?:`))/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?:\[)/i,/^(?:\])/i,/^(?:[A-Za-z]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s+)/i,/^(?:;)/i,/^(?:$)/i],conditions:{data_inner:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,24,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},data:{rules:[0,1,3,4,5,6,7,9,11,14,15,16,17,18,21,22,23,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_band_data:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,25,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},axis_data:{rules:[0,1,2,4,5,6,7,9,11,14,15,16,17,18,19,20,21,22,24,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0},acc_descr_multiline:{rules:[12,13],inclusive:!1},acc_descr:{rules:[10],inclusive:!1},acc_title:{rules:[8],inclusive:!1},title:{rules:[],inclusive:!1},md_string:{rules:[],inclusive:!1},string:{rules:[28,29],inclusive:!1},INITIAL:{rules:[0,1,4,5,6,7,9,11,14,15,16,17,18,21,22,26,27,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46],inclusive:!0}}},(0,r.K2)(P,"Parser"),P.prototype=L,L.Parser=P,new P}();function g(t){return"bar"===t.type}function u(t){return"band"===t.type}function x(t){return"linear"===t.type}c.parser=c,(0,r.K2)(g,"isBarPlot"),(0,r.K2)(u,"isBandAxisData"),(0,r.K2)(x,"isLinearAxisData");var d=class{constructor(t){this.parentGroup=t}static{(0,r.K2)(this,"TextDimensionCalculatorWithFont")}getMaxDimension(t,i){if(!this.parentGroup)return{width:t.reduce((t,i)=>Math.max(i.length,t),0)*i,height:i};let e={width:0,height:0},s=this.parentGroup.append("g").attr("visibility","hidden").attr("font-size",i);for(let a of t){let t=(0,n.W6)(s,1,a),h=t?t.width:a.length*i,o=t?t.height:i;e.width=Math.max(e.width,h),e.height=Math.max(e.height,o)}return s.remove(),e}},p=class{constructor(t,i,e,s){this.axisConfig=t,this.title=i,this.textDimensionCalculator=e,this.axisThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left",this.showTitle=!1,this.showLabel=!1,this.showTick=!1,this.showAxisLine=!1,this.outerPadding=0,this.titleTextHeight=0,this.labelTextHeight=0,this.range=[0,10],this.boundingRect={x:0,y:0,width:0,height:0},this.axisPosition="left"}static{(0,r.K2)(this,"BaseAxis")}setRange(t){this.range=t,"left"===this.axisPosition||"right"===this.axisPosition?this.boundingRect.height=t[1]-t[0]:this.boundingRect.width=t[1]-t[0],this.recalculateScale()}getRange(){return[this.range[0]+this.outerPadding,this.range[1]-this.outerPadding]}setAxisPosition(t){this.axisPosition=t,this.setRange(this.range)}getTickDistance(){let t=this.getRange();return Math.abs(t[0]-t[1])/this.getTickValues().length}getAxisOuterPadding(){return this.outerPadding}getLabelDimension(){return this.textDimensionCalculator.getMaxDimension(this.getTickValues().map(t=>t.toString()),this.axisConfig.labelFontSize)}recalculateOuterPaddingToDrawBar(){.7*this.getTickDistance()>2*this.outerPadding&&(this.outerPadding=Math.floor(.7*this.getTickDistance()/2)),this.recalculateScale()}calculateSpaceIfDrawnHorizontally(t){let i=t.height;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let e=this.getLabelDimension(),s=.2*t.width;this.outerPadding=Math.min(e.width/2,s);let a=e.height+2*this.axisConfig.labelPadding;this.labelTextHeight=e.height,a<=i&&(i-=a,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),e=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,e<=i&&(i-=e,this.showTitle=!0)}this.boundingRect.width=t.width,this.boundingRect.height=t.height-i}calculateSpaceIfDrawnVertical(t){let i=t.width;if(this.axisConfig.showAxisLine&&i>this.axisConfig.axisLineWidth&&(i-=this.axisConfig.axisLineWidth,this.showAxisLine=!0),this.axisConfig.showLabel){let e=this.getLabelDimension(),s=.2*t.height;this.outerPadding=Math.min(e.height/2,s);let a=e.width+2*this.axisConfig.labelPadding;a<=i&&(i-=a,this.showLabel=!0)}if(this.axisConfig.showTick&&i>=this.axisConfig.tickLength&&(this.showTick=!0,i-=this.axisConfig.tickLength),this.axisConfig.showTitle&&this.title){let t=this.textDimensionCalculator.getMaxDimension([this.title],this.axisConfig.titleFontSize),e=t.height+2*this.axisConfig.titlePadding;this.titleTextHeight=t.height,e<=i&&(i-=e,this.showTitle=!0)}this.boundingRect.width=t.width-i,this.boundingRect.height=t.height}calculateSpace(t){return"left"===this.axisPosition||"right"===this.axisPosition?this.calculateSpaceIfDrawnVertical(t):this.calculateSpaceIfDrawnHorizontally(t),this.recalculateScale(),{width:this.boundingRect.width,height:this.boundingRect.height}}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}getDrawableElementsForLeftAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.x+this.boundingRect.width-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["left-axis","axisl-line"],data:[{path:`M ${i},${this.boundingRect.y} L ${i},${this.boundingRect.y+this.boundingRect.height} `,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["left-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.boundingRect.x+this.boundingRect.width-(this.showLabel?this.axisConfig.labelPadding:0)-(this.showTick?this.axisConfig.tickLength:0)-(this.showAxisLine?this.axisConfig.axisLineWidth:0),y:this.getScaleValue(t),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"middle",horizontalPos:"right"}))}),this.showTick){let i=this.boundingRect.x+this.boundingRect.width-(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["left-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${i},${this.getScaleValue(t)} L ${i-this.axisConfig.tickLength},${this.getScaleValue(t)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["left-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.axisConfig.titlePadding,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:270,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForBottomAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.y+this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["bottom-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["bottom-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+this.axisConfig.labelPadding+(this.showTick?this.axisConfig.tickLength:0)+(this.showAxisLine?this.axisConfig.axisLineWidth:0),fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let i=this.boundingRect.y+(this.showAxisLine?this.axisConfig.axisLineWidth:0);t.push({type:"path",groupTexts:["bottom-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${this.getScaleValue(t)},${i} L ${this.getScaleValue(t)},${i+this.axisConfig.tickLength}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["bottom-axis","title"],data:[{text:this.title,x:this.range[0]+(this.range[1]-this.range[0])/2,y:this.boundingRect.y+this.boundingRect.height-this.axisConfig.titlePadding-this.titleTextHeight,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElementsForTopAxis(){let t=[];if(this.showAxisLine){let i=this.boundingRect.y+this.boundingRect.height-this.axisConfig.axisLineWidth/2;t.push({type:"path",groupTexts:["top-axis","axis-line"],data:[{path:`M ${this.boundingRect.x},${i} L ${this.boundingRect.x+this.boundingRect.width},${i}`,strokeFill:this.axisThemeConfig.axisLineColor,strokeWidth:this.axisConfig.axisLineWidth}]})}if(this.showLabel&&t.push({type:"text",groupTexts:["top-axis","label"],data:this.getTickValues().map(t=>({text:t.toString(),x:this.getScaleValue(t),y:this.boundingRect.y+(this.showTitle?this.titleTextHeight+2*this.axisConfig.titlePadding:0)+this.axisConfig.labelPadding,fill:this.axisThemeConfig.labelColor,fontSize:this.axisConfig.labelFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}))}),this.showTick){let i=this.boundingRect.y;t.push({type:"path",groupTexts:["top-axis","ticks"],data:this.getTickValues().map(t=>({path:`M ${this.getScaleValue(t)},${i+this.boundingRect.height-(this.showAxisLine?this.axisConfig.axisLineWidth:0)} L ${this.getScaleValue(t)},${i+this.boundingRect.height-this.axisConfig.tickLength-(this.showAxisLine?this.axisConfig.axisLineWidth:0)}`,strokeFill:this.axisThemeConfig.tickColor,strokeWidth:this.axisConfig.tickWidth}))})}return this.showTitle&&t.push({type:"text",groupTexts:["top-axis","title"],data:[{text:this.title,x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.axisConfig.titlePadding,fill:this.axisThemeConfig.titleColor,fontSize:this.axisConfig.titleFontSize,rotation:0,verticalPos:"top",horizontalPos:"center"}]}),t}getDrawableElements(){if("left"===this.axisPosition)return this.getDrawableElementsForLeftAxis();if("right"===this.axisPosition)throw Error("Drawing of right axis is not implemented");return"bottom"===this.axisPosition?this.getDrawableElementsForBottomAxis():"top"===this.axisPosition?this.getDrawableElementsForTopAxis():[]}},f=class extends p{static{(0,r.K2)(this,"BandAxis")}constructor(t,i,e,s,a){super(t,s,a,i),this.categories=e,this.scale=(0,l.WH)().domain(this.categories).range(this.getRange())}setRange(t){super.setRange(t)}recalculateScale(){this.scale=(0,l.WH)().domain(this.categories).range(this.getRange()).paddingInner(1).paddingOuter(0).align(.5),r.Rm.trace("BandAxis axis final categories, range: ",this.categories,this.getRange())}getTickValues(){return this.categories}getScaleValue(t){return this.scale(t)??this.getRange()[0]}},m=class extends p{static{(0,r.K2)(this,"LinearAxis")}constructor(t,i,e,s,a){super(t,s,a,i),this.domain=e,this.scale=(0,l.m4Y)().domain(this.domain).range(this.getRange())}getTickValues(){return this.scale.ticks()}recalculateScale(){let t=[...this.domain];"left"===this.axisPosition&&t.reverse(),this.scale=(0,l.m4Y)().domain(t).range(this.getRange())}getScaleValue(t){return this.scale(t)}};function y(t,i,e,s){let a=new d(s);return u(t)?new f(i,e,t.categories,t.title,a):new m(i,e,[t.min,t.max],t.title,a)}(0,r.K2)(y,"getAxis");var b=class{constructor(t,i,e,s){this.textDimensionCalculator=t,this.chartConfig=i,this.chartData=e,this.chartThemeConfig=s,this.boundingRect={x:0,y:0,width:0,height:0},this.showChartTitle=!1}static{(0,r.K2)(this,"ChartTitle")}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){let i=this.textDimensionCalculator.getMaxDimension([this.chartData.title],this.chartConfig.titleFontSize),e=Math.max(i.width,t.width),s=i.height+2*this.chartConfig.titlePadding;return i.width<=e&&i.height<=s&&this.chartConfig.showTitle&&this.chartData.title&&(this.boundingRect.width=e,this.boundingRect.height=s,this.showChartTitle=!0),{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){let t=[];return this.showChartTitle&&t.push({groupTexts:["chart-title"],type:"text",data:[{fontSize:this.chartConfig.titleFontSize,text:this.chartData.title,verticalPos:"middle",horizontalPos:"center",x:this.boundingRect.x+this.boundingRect.width/2,y:this.boundingRect.y+this.boundingRect.height/2,fill:this.chartThemeConfig.titleColor,rotation:0}]}),t}};function A(t,i,e,s){return new b(new d(s),t,i,e)}(0,r.K2)(A,"getChartTitleComponent");var w=class{constructor(t,i,e,s,a){this.plotData=t,this.xAxis=i,this.yAxis=e,this.orientation=s,this.plotIndex=a}static{(0,r.K2)(this,"LinePlot")}getDrawableElement(){let t,i=this.plotData.data.map(t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])]);return(t="horizontal"===this.orientation?(0,l.n8j)().y(t=>t[0]).x(t=>t[1])(i):(0,l.n8j)().x(t=>t[0]).y(t=>t[1])(i))?[{groupTexts:["plot",`line-plot-${this.plotIndex}`],type:"path",data:[{path:t,strokeFill:this.plotData.strokeFill,strokeWidth:this.plotData.strokeWidth}]}]:[]}},S=class{constructor(t,i,e,s,a,n){this.barData=t,this.boundingRect=i,this.xAxis=e,this.yAxis=s,this.orientation=a,this.plotIndex=n}static{(0,r.K2)(this,"BarPlot")}getDrawableElement(){let t=this.barData.data.map(t=>[this.xAxis.getScaleValue(t[0]),this.yAxis.getScaleValue(t[1])]),i=.95*Math.min(2*this.xAxis.getAxisOuterPadding(),this.xAxis.getTickDistance()),e=i/2;return"horizontal"===this.orientation?[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(t=>({x:this.boundingRect.x,y:t[0]-e,height:i,width:t[1]-this.boundingRect.x,fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]:[{groupTexts:["plot",`bar-plot-${this.plotIndex}`],type:"rect",data:t.map(t=>({x:t[0]-e,y:t[1],width:i,height:this.boundingRect.y+this.boundingRect.height-t[1],fill:this.barData.fill,strokeWidth:0,strokeFill:this.barData.fill}))}]}},C=class{constructor(t,i,e){this.chartConfig=t,this.chartData=i,this.chartThemeConfig=e,this.boundingRect={x:0,y:0,width:0,height:0}}static{(0,r.K2)(this,"BasePlot")}setAxes(t,i){this.xAxis=t,this.yAxis=i}setBoundingBoxXY(t){this.boundingRect.x=t.x,this.boundingRect.y=t.y}calculateSpace(t){return this.boundingRect.width=t.width,this.boundingRect.height=t.height,{width:this.boundingRect.width,height:this.boundingRect.height}}getDrawableElements(){if(!(this.xAxis&&this.yAxis))throw Error("Axes must be passed to render Plots");let t=[];for(let[i,e]of this.chartData.plots.entries())switch(e.type){case"line":{let s=new w(e,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...s.getDrawableElement())}break;case"bar":{let s=new S(e,this.boundingRect,this.xAxis,this.yAxis,this.chartConfig.chartOrientation,i);t.push(...s.getDrawableElement())}}return t}};function k(t,i,e){return new C(t,i,e)}(0,r.K2)(k,"getPlotComponent");var _=class{constructor(t,i,e,s){this.chartConfig=t,this.chartData=i,this.componentStore={title:A(t,i,e,s),plot:k(t,i,e),xAxis:y(i.xAxis,t.xAxis,{titleColor:e.xAxisTitleColor,labelColor:e.xAxisLabelColor,tickColor:e.xAxisTickColor,axisLineColor:e.xAxisLineColor},s),yAxis:y(i.yAxis,t.yAxis,{titleColor:e.yAxisTitleColor,labelColor:e.yAxisLabelColor,tickColor:e.yAxisTickColor,axisLineColor:e.yAxisLineColor},s)}}static{(0,r.K2)(this,"Orchestrator")}calculateVerticalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,e=0,s=0,a=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),n=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),h=this.componentStore.plot.calculateSpace({width:a,height:n});t-=h.width,i-=h.height,s=(h=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i})).height,i-=h.height,this.componentStore.xAxis.setAxisPosition("bottom"),h=this.componentStore.xAxis.calculateSpace({width:t,height:i}),i-=h.height,this.componentStore.yAxis.setAxisPosition("left"),e=(h=this.componentStore.yAxis.calculateSpace({width:t,height:i})).width,(t-=h.width)>0&&(a+=t,t=0),i>0&&(n+=i,i=0),this.componentStore.plot.calculateSpace({width:a,height:n}),this.componentStore.plot.setBoundingBoxXY({x:e,y:s}),this.componentStore.xAxis.setRange([e,e+a]),this.componentStore.xAxis.setBoundingBoxXY({x:e,y:s+n}),this.componentStore.yAxis.setRange([s,s+n]),this.componentStore.yAxis.setBoundingBoxXY({x:0,y:s}),this.chartData.plots.some(t=>g(t))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateHorizontalSpace(){let t=this.chartConfig.width,i=this.chartConfig.height,e=0,s=0,a=0,n=Math.floor(t*this.chartConfig.plotReservedSpacePercent/100),h=Math.floor(i*this.chartConfig.plotReservedSpacePercent/100),o=this.componentStore.plot.calculateSpace({width:n,height:h});t-=o.width,i-=o.height,e=(o=this.componentStore.title.calculateSpace({width:this.chartConfig.width,height:i})).height,i-=o.height,this.componentStore.xAxis.setAxisPosition("left"),o=this.componentStore.xAxis.calculateSpace({width:t,height:i}),t-=o.width,s=o.width,this.componentStore.yAxis.setAxisPosition("top"),o=this.componentStore.yAxis.calculateSpace({width:t,height:i}),i-=o.height,a=e+o.height,t>0&&(n+=t,t=0),i>0&&(h+=i,i=0),this.componentStore.plot.calculateSpace({width:n,height:h}),this.componentStore.plot.setBoundingBoxXY({x:s,y:a}),this.componentStore.yAxis.setRange([s,s+n]),this.componentStore.yAxis.setBoundingBoxXY({x:s,y:e}),this.componentStore.xAxis.setRange([a,a+h]),this.componentStore.xAxis.setBoundingBoxXY({x:0,y:a}),this.chartData.plots.some(t=>g(t))&&this.componentStore.xAxis.recalculateOuterPaddingToDrawBar()}calculateSpace(){"horizontal"===this.chartConfig.chartOrientation?this.calculateHorizontalSpace():this.calculateVerticalSpace()}getDrawableElement(){this.calculateSpace();let t=[];for(let i of(this.componentStore.plot.setAxes(this.componentStore.xAxis,this.componentStore.yAxis),Object.values(this.componentStore)))t.push(...i.getDrawableElements());return t}},T=class{static{(0,r.K2)(this,"XYChartBuilder")}static build(t,i,e,s){return new _(t,i,e,s).getDrawableElement()}},R=0,D=$(),L=I(),P=M(),E=L.plotColorPalette.split(",").map(t=>t.trim()),K=!1,v=!1;function I(){let t=(0,o.P$)(),i=(0,o.zj)();return(0,h.$t)(t.xyChart,i.themeVariables.xyChart)}function $(){let t=(0,o.zj)();return(0,h.$t)(o.UI.xyChart,t.xyChart)}function M(){return{yAxis:{type:"linear",title:"",min:1/0,max:-1/0},xAxis:{type:"band",title:"",categories:[]},title:"",plots:[]}}function z(t){let i=(0,o.zj)();return(0,o.jZ)(t.trim(),i)}function B(t){s=t}function W(t){"horizontal"===t?D.chartOrientation="horizontal":D.chartOrientation="vertical"}function O(t){P.xAxis.title=z(t.text)}function F(t,i){P.xAxis={type:"linear",title:P.xAxis.title,min:t,max:i},K=!0}function N(t){P.xAxis={type:"band",title:P.xAxis.title,categories:t.map(t=>z(t.text))},K=!0}function V(t){P.yAxis.title=z(t.text)}function X(t,i){P.yAxis={type:"linear",title:P.yAxis.title,min:t,max:i},v=!0}function Y(t){let i=Math.min(...t),e=Math.max(...t),s=x(P.yAxis)?P.yAxis.min:1/0,a=x(P.yAxis)?P.yAxis.max:-1/0;P.yAxis={type:"linear",title:P.yAxis.title,min:Math.min(s,i),max:Math.max(a,e)}}function H(t){let i=[];if(0===t.length)return i;if(K||F(Math.min(x(P.xAxis)?P.xAxis.min:1/0,1),Math.max(x(P.xAxis)?P.xAxis.max:-1/0,t.length)),v||Y(t),u(P.xAxis)&&(i=P.xAxis.categories.map((i,e)=>[i,t[e]])),x(P.xAxis)){let e=P.xAxis.min,s=P.xAxis.max,a=(s-e)/(t.length-1),n=[];for(let t=e;t<=s;t+=a)n.push(`${t}`);i=n.map((i,e)=>[i,t[e]])}return i}function U(t){return E[0===t?0:t%E.length]}function j(t,i){let e=H(i);P.plots.push({type:"line",strokeFill:U(R),strokeWidth:2,data:e}),R++}function G(t,i){let e=H(i);P.plots.push({type:"bar",fill:U(R),data:e}),R++}function Q(){if(0===P.plots.length)throw Error("No Plot to render, please provide a plot with some data");return P.title=(0,o.ab)(),T.build(D,P,L,s)}function Z(){return L}function q(){return D}function J(){return P}(0,r.K2)(I,"getChartDefaultThemeConfig"),(0,r.K2)($,"getChartDefaultConfig"),(0,r.K2)(M,"getChartDefaultData"),(0,r.K2)(z,"textSanitizer"),(0,r.K2)(B,"setTmpSVGG"),(0,r.K2)(W,"setOrientation"),(0,r.K2)(O,"setXAxisTitle"),(0,r.K2)(F,"setXAxisRangeData"),(0,r.K2)(N,"setXAxisBand"),(0,r.K2)(V,"setYAxisTitle"),(0,r.K2)(X,"setYAxisRangeData"),(0,r.K2)(Y,"setYAxisRangeFromPlotData"),(0,r.K2)(H,"transformDataWithoutCategory"),(0,r.K2)(U,"getPlotColorFromPalette"),(0,r.K2)(j,"setLineData"),(0,r.K2)(G,"setBarData"),(0,r.K2)(Q,"getDrawableElem"),(0,r.K2)(Z,"getChartThemeConfig"),(0,r.K2)(q,"getChartConfig"),(0,r.K2)(J,"getXYChartData");var tt={getDrawableElem:Q,clear:(0,r.K2)(function(){(0,o.IU)(),R=0,D=$(),P=M(),E=(L=I()).plotColorPalette.split(",").map(t=>t.trim()),K=!1,v=!1},"clear"),setAccTitle:o.SV,getAccTitle:o.iN,setDiagramTitle:o.ke,getDiagramTitle:o.ab,getAccDescription:o.m7,setAccDescription:o.EI,setOrientation:W,setXAxisTitle:O,setXAxisRangeData:F,setXAxisBand:N,setYAxisTitle:V,setYAxisRangeData:X,setLineData:j,setBarData:G,setTmpSVGG:B,getChartThemeConfig:Z,getChartConfig:q,getXYChartData:J},ti={parser:c,db:tt,renderer:{draw:(0,r.K2)((t,i,e,s)=>{let n=s.db,h=n.getChartThemeConfig(),l=n.getChartConfig(),c=n.getXYChartData().plots[0].data.map(t=>t[1]);function g(t){return"top"===t?"text-before-edge":"middle"}function u(t){return"left"===t?"start":"right"===t?"end":"middle"}function x(t){return`translate(${t.x}, ${t.y}) rotate(${t.rotation||0})`}(0,r.K2)(g,"getDominantBaseLine"),(0,r.K2)(u,"getTextAnchor"),(0,r.K2)(x,"getTextTransformation"),r.Rm.debug("Rendering xychart chart\n"+t);let d=(0,a.D)(i),p=d.append("g").attr("class","main"),f=p.append("rect").attr("width",l.width).attr("height",l.height).attr("class","background");(0,o.a$)(d,l.height,l.width,!0),d.attr("viewBox",`0 0 ${l.width} ${l.height}`),f.attr("fill",h.backgroundColor),n.setTmpSVGG(d.append("g").attr("class","mermaid-tmp-group"));let m=n.getDrawableElem(),y={};function b(t){let i=p,e="";for(let[s]of t.entries()){let a=p;s>0&&y[e]&&(a=y[e]),e+=t[s],(i=y[e])||(i=y[e]=a.append("g").attr("class",t[s]))}return i}for(let t of((0,r.K2)(b,"getGroup"),m)){if(0===t.data.length)continue;let i=b(t.groupTexts);switch(t.type){case"rect":if(i.selectAll("rect").data(t.data).enter().append("rect").attr("x",t=>t.x).attr("y",t=>t.y).attr("width",t=>t.width).attr("height",t=>t.height).attr("fill",t=>t.fill).attr("stroke",t=>t.strokeFill).attr("stroke-width",t=>t.strokeWidth),l.showDataLabel){let e=l.showDataLabelOutsideBar;if("horizontal"===l.chartOrientation){let s=function(t,i){let{data:e,label:s}=t;return i*s.length*a<=e.width-n};(0,r.K2)(s,"fitsHorizontally");let a=.7,n=10,o=t.data.map((t,i)=>({data:t,label:c[i].toString()})).filter(t=>t.data.width>0&&t.data.height>0),l=Math.floor(Math.min(...o.map(t=>{let{data:i}=t,e=.7*i.height;for(;!s(t,e)&&e>0;)e-=1;return e}))),g=(0,r.K2)(t=>e?t.data.x+t.data.width+n:t.data.x+t.data.width-n,"determineLabelXPosition");i.selectAll("text").data(o).enter().append("text").attr("x",g).attr("y",t=>t.data.y+t.data.height/2).attr("text-anchor",e?"start":"end").attr("dominant-baseline","middle").attr("fill",h.dataLabelColor).attr("font-size",`${l}px`).text(t=>t.label)}else{let s=function(t,i,e){let{data:s,label:a}=t,n=i*a.length*.7,h=s.x+s.width/2,o=h-n/2,r=h+n/2,l=o>=s.x&&r<=s.x+s.width,c=s.y+e+i<=s.y+s.height;return l&&c};(0,r.K2)(s,"fitsInBar");let a=t.data.map((t,i)=>({data:t,label:c[i].toString()})).filter(t=>t.data.width>0&&t.data.height>0),n=Math.floor(Math.min(...a.map(t=>{let{data:i,label:e}=t,a=i.width/(.7*e.length);for(;!s(t,a,10)&&a>0;)a-=1;return a}))),o=(0,r.K2)(t=>e?t.data.y-10:t.data.y+10,"determineLabelYPosition");i.selectAll("text").data(a).enter().append("text").attr("x",t=>t.data.x+t.data.width/2).attr("y",o).attr("text-anchor","middle").attr("dominant-baseline",e?"auto":"hanging").attr("fill",h.dataLabelColor).attr("font-size",`${n}px`).text(t=>t.label)}}break;case"text":i.selectAll("text").data(t.data).enter().append("text").attr("x",0).attr("y",0).attr("fill",t=>t.fill).attr("font-size",t=>t.fontSize).attr("dominant-baseline",t=>g(t.verticalPos)).attr("text-anchor",t=>u(t.horizontalPos)).attr("transform",t=>x(t)).text(t=>t.text);break;case"path":i.selectAll("path").data(t.data).enter().append("path").attr("d",t=>t.path).attr("fill",t=>t.fill?t.fill:"none").attr("stroke",t=>t.strokeFill).attr("stroke-width",t=>t.strokeWidth)}}},"draw")}}}}]);
_next/static/chunks/5375.c699ec4a5c55285d.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5375],{5375:(r,e,s)=>{s.d(e,{diagram:()=>l});var a=s(4162);s(3580),s(3062),s(1184),s(2888),s(1593),s(4982),s(1431),s(5407),s(7920),s(3148),s(1538),s(3736),s(669);var t=s(316),l={parser:a._$,get db(){return new a.NM},renderer:a.Lh,styles:a.tM,init:(0,t.K2)(r=>{r.class||(r.class={}),r.class.arrowMarkerAbsolute=r.arrowMarkerAbsolute},"init")}}}]);
_next/static/chunks/5785.c376d430e74f953c.js ADDED
@@ -0,0 +1,9 @@
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5785],{3259:(e,t,i)=>{i.d(t,{m:()=>a});var r=i(316),a=class{constructor(e){this.init=e,this.records=this.init()}static{(0,r.K2)(this,"ImperativeState")}reset(){this.records=this.init()}}},5785:(e,t,i)=>{i.d(t,{diagram:()=>D});var r=i(2667),a=i(7566),n=i(3259),s=i(3736),c=i(669),d=i(316),l=i(4290),o=new n.m(()=>({cnt:1,stack:[{id:0,level:-1,name:"/",children:[]}]})),g=(0,d.K2)(()=>{o.reset(),(0,c.IU)()},"clear"),h=(0,d.K2)(()=>o.records.stack[0],"getRoot"),p=(0,d.K2)(()=>o.records.cnt,"getCount"),k=c.UI.treeView,w=(0,d.K2)(()=>(0,s.$t)(k,(0,c.zj)().treeView),"getConfig"),m={clear:g,addNode:(0,d.K2)((e,t)=>{for(;e<=o.records.stack[o.records.stack.length-1].level;)o.records.stack.pop();let i={id:o.records.cnt++,level:e,name:t,children:[]};o.records.stack[o.records.stack.length-1].children.push(i),o.records.stack.push(i)},"addNode"),getRoot:h,getCount:p,getConfig:w,getAccTitle:c.iN,getAccDescription:c.m7,getDiagramTitle:c.ab,setAccDescription:c.EI,setAccTitle:c.SV,setDiagramTitle:c.ke},b=(0,d.K2)(e=>{(0,a.S)(e,m),e.nodes.map(e=>m.addNode(e.indent?parseInt(e.indent):0,e.name))},"populate"),u={parse:(0,d.K2)(async e=>{let t=await (0,l.qg)("treeView",e);d.Rm.debug(t),b(t)},"parse")},K=(0,d.K2)((e,t,i,r,a)=>{let n=r.append("text").text(i.name).attr("dominant-baseline","middle").attr("class","treeView-node-label"),{height:s,width:c}=n.node().getBBox(),d=s+2*a.paddingY,l=c+2*a.paddingX;n.attr("x",e+a.paddingX),n.attr("y",t+d/2),i.BBox={x:e,y:t,width:l,height:d}},"positionLabel"),x=(0,d.K2)((e,t,i,r,a,n)=>e.append("line").attr("x1",t).attr("y1",i).attr("x2",r).attr("y2",a).attr("stroke-width",n).attr("class","treeView-node-line"),"positionLine"),T=(0,d.K2)((e,t,i)=>{let r=0,a=0,n=(0,d.K2)((e,t,i,n)=>{let s=n*(i.rowIndent+i.paddingX);K(s,r,t,e,i);let{height:c,width:d}=t.BBox;x(e,s-i.rowIndent,r+c/2,s,r+c/2,i.lineThickness),a=Math.max(a,s+d),r+=c},"drawNode"),s=(0,d.K2)((t,r=0)=>{n(e,t,i,r),t.children.forEach(e=>{s(e,r+1)});let{x:a,y:c,height:d}=t.BBox;if(t.children.length){let{y:r,height:n}=t.children[t.children.length-1].BBox;x(e,a+i.paddingX,c+d,a+i.paddingX,r+n/2+i.lineThickness/2,i.lineThickness)}},"processNode");return s(t),{totalHeight:r,totalWidth:a}},"drawTree"),f=(0,d.K2)((e,t,i,a)=>{d.Rm.debug("Rendering treeView diagram\n"+e);let n=a.db,s=n.getRoot(),l=n.getConfig(),o=(0,r.D)(t),g=o.append("g");g.attr("class","tree-view");let{totalHeight:h,totalWidth:p}=T(g,s,l);o.attr("viewBox",`-${l.lineThickness/2} 0 ${p} ${h}`),(0,c.a$)(o,h,p,l.useMaxWidth)},"draw"),B={labelFontSize:"16px",labelColor:"black",lineColor:"black"},D={db:m,renderer:{draw:f},parser:u,styles:(0,d.K2)(({treeView:e})=>{let{labelFontSize:t,labelColor:i,lineColor:r}=(0,s.$t)(B,e);return`
2
+ .treeView-node-label {
3
+ font-size: ${t};
4
+ fill: ${i};
5
+ }
6
+ .treeView-node-line {
7
+ stroke: ${r};
8
+ }
9
+ `},"styles")}},7566:(e,t,i)=>{function r(e,t){e.accDescr&&t.setAccDescription?.(e.accDescr),e.accTitle&&t.setAccTitle?.(e.accTitle),e.title&&t.setDiagramTitle?.(e.title)}i.d(t,{S:()=>r}),(0,i(316).K2)(r,"populateCommonDb")}}]);
_next/static/chunks/58bb9007.15ec71a3d64fa897.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/6091.9cda211185ade55d.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6091],{6091:(e,c,r)=>{r.d(c,{createArchitectureServices:()=>s.S});var s=r(3281);r(4839)}}]);
_next/static/chunks/6215.17b66e816cb5b1c5.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6215],{6215:(t,e,i)=>{i.d(e,{diagram:()=>I});var a=i(669),n=i(316),s=i(5508),r=function(){var t=(0,n.K2)(function(t,e,i,a){for(i=i||{},a=t.length;a--;i[t[a]]=e);return i},"o"),e=[1,3],i=[1,4],a=[1,5],s=[1,6],r=[1,7],l=[1,4,5,10,12,13,14,15,18,25,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],o=[1,4,5,10,12,13,14,15,18,25,28,35,37,39,41,42,48,50,51,52,53,54,55,56,57,60,61,63,64,65,66,67],h=[55,56,57],c=[2,36],d=[1,37],u=[1,36],x=[1,38],g=[1,35],f=[1,43],p=[1,41],y=[1,45],m=[1,14],T=[1,23],_=[1,18],q=[1,19],A=[1,20],b=[1,21],k=[1,22],S=[1,24],F=[1,25],P=[1,26],C=[1,27],v=[1,28],L=[1,29],I=[1,32],E=[1,33],D=[1,34],z=[1,39],K=[1,40],U=[1,42],w=[1,44],N=[1,63],R=[1,62],B=[4,5,8,10,12,13,14,15,18,44,47,49,55,56,57,63,64,65,66,67],$=[1,66],W=[1,67],O=[1,68],Q=[1,69],X=[1,70],M=[1,71],Y=[1,72],H=[1,73],j=[1,74],G=[1,75],Z=[1,76],V=[1,77],J=[4,5,6,7,8,9,10,11,12,13,14,15,18],tt=[1,91],te=[1,92],ti=[1,93],ta=[1,100],tn=[1,94],ts=[1,97],tr=[1,95],tl=[1,96],to=[1,98],th=[1,99],tc=[1,103],td=[10,55,56,57],tu=[4,5,6,8,10,11,13,17,18,19,20,55,56,57],tx={trace:(0,n.K2)(function(){},"trace"),yy:{},symbols_:{error:2,idStringToken:3,ALPHA:4,NUM:5,NODE_STRING:6,DOWN:7,MINUS:8,DEFAULT:9,COMMA:10,COLON:11,AMP:12,BRKT:13,MULT:14,UNICODE_TEXT:15,styleComponent:16,UNIT:17,SPACE:18,STYLE:19,PCT:20,idString:21,style:22,stylesOpt:23,classDefStatement:24,CLASSDEF:25,start:26,eol:27,QUADRANT:28,document:29,line:30,statement:31,axisDetails:32,quadrantDetails:33,points:34,title:35,title_value:36,acc_title:37,acc_title_value:38,acc_descr:39,acc_descr_value:40,acc_descr_multiline_value:41,section:42,text:43,point_start:44,point_x:45,point_y:46,class_name:47,"X-AXIS":48,"AXIS-TEXT-DELIMITER":49,"Y-AXIS":50,QUADRANT_1:51,QUADRANT_2:52,QUADRANT_3:53,QUADRANT_4:54,NEWLINE:55,SEMI:56,EOF:57,alphaNumToken:58,textNoTagsToken:59,STR:60,MD_STR:61,alphaNum:62,PUNCTUATION:63,PLUS:64,EQUALS:65,DOT:66,UNDERSCORE:67,$accept:0,$end:1},terminals_:{2:"error",4:"ALPHA",5:"NUM",6:"NODE_STRING",7:"DOWN",8:"MINUS",9:"DEFAULT",10:"COMMA",11:"COLON",12:"AMP",13:"BRKT",14:"MULT",15:"UNICODE_TEXT",17:"UNIT",18:"SPACE",19:"STYLE",20:"PCT",25:"CLASSDEF",28:"QUADRANT",35:"title",36:"title_value",37:"acc_title",38:"acc_title_value",39:"acc_descr",40:"acc_descr_value",41:"acc_descr_multiline_value",42:"section",44:"point_start",45:"point_x",46:"point_y",47:"class_name",48:"X-AXIS",49:"AXIS-TEXT-DELIMITER",50:"Y-AXIS",51:"QUADRANT_1",52:"QUADRANT_2",53:"QUADRANT_3",54:"QUADRANT_4",55:"NEWLINE",56:"SEMI",57:"EOF",60:"STR",61:"MD_STR",63:"PUNCTUATION",64:"PLUS",65:"EQUALS",66:"DOT",67:"UNDERSCORE"},productions_:[0,[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[3,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[16,1],[21,1],[21,2],[22,1],[22,2],[23,1],[23,3],[24,5],[26,2],[26,2],[26,2],[29,0],[29,2],[30,2],[31,0],[31,1],[31,2],[31,1],[31,1],[31,1],[31,2],[31,2],[31,2],[31,1],[31,1],[34,4],[34,5],[34,5],[34,6],[32,4],[32,3],[32,2],[32,4],[32,3],[32,2],[33,2],[33,2],[33,2],[33,2],[27,1],[27,1],[27,1],[43,1],[43,2],[43,1],[43,1],[62,1],[62,2],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[58,1],[59,1],[59,1],[59,1]],performAction:(0,n.K2)(function(t,e,i,a,n,s,r){var l=s.length-1;switch(n){case 23:case 68:this.$=s[l];break;case 24:case 69:this.$=s[l-1]+""+s[l];break;case 26:this.$=s[l-1]+s[l];break;case 27:this.$=[s[l].trim()];break;case 28:s[l-2].push(s[l].trim()),this.$=s[l-2];break;case 29:this.$=s[l-4],a.addClass(s[l-2],s[l]);break;case 37:this.$=[];break;case 42:this.$=s[l].trim(),a.setDiagramTitle(this.$);break;case 43:this.$=s[l].trim(),a.setAccTitle(this.$);break;case 44:case 45:this.$=s[l].trim(),a.setAccDescription(this.$);break;case 46:a.addSection(s[l].substr(8)),this.$=s[l].substr(8);break;case 47:a.addPoint(s[l-3],"",s[l-1],s[l],[]);break;case 48:a.addPoint(s[l-4],s[l-3],s[l-1],s[l],[]);break;case 49:a.addPoint(s[l-4],"",s[l-2],s[l-1],s[l]);break;case 50:a.addPoint(s[l-5],s[l-4],s[l-2],s[l-1],s[l]);break;case 51:a.setXAxisLeftText(s[l-2]),a.setXAxisRightText(s[l]);break;case 52:s[l-1].text+=" ⟶ ",a.setXAxisLeftText(s[l-1]);break;case 53:a.setXAxisLeftText(s[l]);break;case 54:a.setYAxisBottomText(s[l-2]),a.setYAxisTopText(s[l]);break;case 55:s[l-1].text+=" ⟶ ",a.setYAxisBottomText(s[l-1]);break;case 56:a.setYAxisBottomText(s[l]);break;case 57:a.setQuadrant1Text(s[l]);break;case 58:a.setQuadrant2Text(s[l]);break;case 59:a.setQuadrant3Text(s[l]);break;case 60:a.setQuadrant4Text(s[l]);break;case 64:case 66:this.$={text:s[l],type:"text"};break;case 65:this.$={text:s[l-1].text+""+s[l],type:s[l-1].type};break;case 67:this.$={text:s[l],type:"markdown"}}},"anonymous"),table:[{18:e,26:1,27:2,28:i,55:a,56:s,57:r},{1:[3]},{18:e,26:8,27:2,28:i,55:a,56:s,57:r},{18:e,26:9,27:2,28:i,55:a,56:s,57:r},t(l,[2,33],{29:10}),t(o,[2,61]),t(o,[2,62]),t(o,[2,63]),{1:[2,30]},{1:[2,31]},t(h,c,{30:11,31:12,24:13,32:15,33:16,34:17,43:30,58:31,1:[2,32],4:d,5:u,10:x,12:g,13:f,14:p,15:y,18:m,25:T,35:_,37:q,39:A,41:b,42:k,48:S,50:F,51:P,52:C,53:v,54:L,60:I,61:E,63:D,64:z,65:K,66:U,67:w}),t(l,[2,34]),{27:46,55:a,56:s,57:r},t(h,[2,37]),t(h,c,{24:13,32:15,33:16,34:17,43:30,58:31,31:47,4:d,5:u,10:x,12:g,13:f,14:p,15:y,18:m,25:T,35:_,37:q,39:A,41:b,42:k,48:S,50:F,51:P,52:C,53:v,54:L,60:I,61:E,63:D,64:z,65:K,66:U,67:w}),t(h,[2,39]),t(h,[2,40]),t(h,[2,41]),{36:[1,48]},{38:[1,49]},{40:[1,50]},t(h,[2,45]),t(h,[2,46]),{18:[1,51]},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:52,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:53,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:54,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:55,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:56,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,10:x,12:g,13:f,14:p,15:y,43:57,58:31,60:I,61:E,63:D,64:z,65:K,66:U,67:w},{4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,44:[1,58],47:[1,59],58:61,59:60,63:D,64:z,65:K,66:U,67:w},t(B,[2,64]),t(B,[2,66]),t(B,[2,67]),t(B,[2,70]),t(B,[2,71]),t(B,[2,72]),t(B,[2,73]),t(B,[2,74]),t(B,[2,75]),t(B,[2,76]),t(B,[2,77]),t(B,[2,78]),t(B,[2,79]),t(B,[2,80]),t(B,[2,81]),t(l,[2,35]),t(h,[2,38]),t(h,[2,42]),t(h,[2,43]),t(h,[2,44]),{3:65,4:$,5:W,6:O,7:Q,8:X,9:M,10:Y,11:H,12:j,13:G,14:Z,15:V,21:64},t(h,[2,53],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,49:[1,78],63:D,64:z,65:K,66:U,67:w}),t(h,[2,56],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,49:[1,79],63:D,64:z,65:K,66:U,67:w}),t(h,[2,57],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),t(h,[2,58],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),t(h,[2,59],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),t(h,[2,60],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),{45:[1,80]},{44:[1,81]},t(B,[2,65]),t(B,[2,82]),t(B,[2,83]),t(B,[2,84]),{3:83,4:$,5:W,6:O,7:Q,8:X,9:M,10:Y,11:H,12:j,13:G,14:Z,15:V,18:[1,82]},t(J,[2,23]),t(J,[2,1]),t(J,[2,2]),t(J,[2,3]),t(J,[2,4]),t(J,[2,5]),t(J,[2,6]),t(J,[2,7]),t(J,[2,8]),t(J,[2,9]),t(J,[2,10]),t(J,[2,11]),t(J,[2,12]),t(h,[2,52],{58:31,43:84,4:d,5:u,10:x,12:g,13:f,14:p,15:y,60:I,61:E,63:D,64:z,65:K,66:U,67:w}),t(h,[2,55],{58:31,43:85,4:d,5:u,10:x,12:g,13:f,14:p,15:y,60:I,61:E,63:D,64:z,65:K,66:U,67:w}),{46:[1,86]},{45:[1,87]},{4:tt,5:te,6:ti,8:ta,11:tn,13:ts,16:90,17:tr,18:tl,19:to,20:th,22:89,23:88},t(J,[2,24]),t(h,[2,51],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),t(h,[2,54],{59:60,58:61,4:d,5:u,8:N,10:x,12:g,13:f,14:p,15:y,18:R,63:D,64:z,65:K,66:U,67:w}),t(h,[2,47],{22:89,16:90,23:101,4:tt,5:te,6:ti,8:ta,11:tn,13:ts,17:tr,18:tl,19:to,20:th}),{46:[1,102]},t(h,[2,29],{10:tc}),t(td,[2,27],{16:104,4:tt,5:te,6:ti,8:ta,11:tn,13:ts,17:tr,18:tl,19:to,20:th}),t(tu,[2,25]),t(tu,[2,13]),t(tu,[2,14]),t(tu,[2,15]),t(tu,[2,16]),t(tu,[2,17]),t(tu,[2,18]),t(tu,[2,19]),t(tu,[2,20]),t(tu,[2,21]),t(tu,[2,22]),t(h,[2,49],{10:tc}),t(h,[2,48],{22:89,16:90,23:105,4:tt,5:te,6:ti,8:ta,11:tn,13:ts,17:tr,18:tl,19:to,20:th}),{4:tt,5:te,6:ti,8:ta,11:tn,13:ts,16:90,17:tr,18:tl,19:to,20:th,22:106},t(tu,[2,26]),t(h,[2,50],{10:tc}),t(td,[2,28],{16:104,4:tt,5:te,6:ti,8:ta,11:tn,13:ts,17:tr,18:tl,19:to,20:th})],defaultActions:{8:[2,30],9:[2,31]},parseError:(0,n.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,n.K2)(function(t){var e=this,i=[0],a=[],s=[null],r=[],l=this.table,o="",h=0,c=0,d=0,u=r.slice.call(arguments,1),x=Object.create(this.lexer),g={};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g[f]=this.yy[f]);x.setInput(t,g),g.lexer=x,g.parser=this,void 0===x.yylloc&&(x.yylloc={});var p=x.yylloc;r.push(p);var y=x.options&&x.options.ranges;function m(){var t;return"number"!=typeof(t=a.pop()||x.lex()||1)&&(t instanceof Array&&(t=(a=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.parseError?this.parseError=g.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,n.K2)(function(t){i.length=i.length-2*t,s.length=s.length-t,r.length=r.length-t},"popStack"),(0,n.K2)(m,"lex");for(var T,_,q,A,b,k,S,F,P,C={};;){if(q=i[i.length-1],this.defaultActions[q]?A=this.defaultActions[q]:(null==T&&(T=m()),A=l[q]&&l[q][T]),void 0===A||!A.length||!A[0]){var v="";for(k in P=[],l[q])this.terminals_[k]&&k>2&&P.push("'"+this.terminals_[k]+"'");v=x.showPosition?"Parse error on line "+(h+1)+":\n"+x.showPosition()+"\nExpecting "+P.join(", ")+", got '"+(this.terminals_[T]||T)+"'":"Parse error on line "+(h+1)+": Unexpected "+(1==T?"end of input":"'"+(this.terminals_[T]||T)+"'"),this.parseError(v,{text:x.match,token:this.terminals_[T]||T,line:x.yylineno,loc:p,expected:P})}if(A[0]instanceof Array&&A.length>1)throw Error("Parse Error: multiple actions possible at state: "+q+", token: "+T);switch(A[0]){case 1:i.push(T),s.push(x.yytext),r.push(x.yylloc),i.push(A[1]),T=null,_?(T=_,_=null):(c=x.yyleng,o=x.yytext,h=x.yylineno,p=x.yylloc,d>0&&d--);break;case 2:if(S=this.productions_[A[1]][1],C.$=s[s.length-S],C._$={first_line:r[r.length-(S||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(S||1)].first_column,last_column:r[r.length-1].last_column},y&&(C._$.range=[r[r.length-(S||1)].range[0],r[r.length-1].range[1]]),void 0!==(b=this.performAction.apply(C,[o,c,h,g,A[1],s,r].concat(u))))return b;S&&(i=i.slice(0,-1*S*2),s=s.slice(0,-1*S),r=r.slice(0,-1*S)),i.push(this.productions_[A[1]][0]),s.push(C.$),r.push(C._$),F=l[i[i.length-2]][i[i.length-1]],i.push(F);break;case 3:return!0}}return!0},"parse")};function tg(){this.yy={}}return tx.lexer={EOF:1,parseError:(0,n.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,n.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,n.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,n.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var n=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===a.length?this.yylloc.first_column:0)+a[a.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[n[0],n[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,n.K2)(function(){return this._more=!0,this},"more"),reject:(0,n.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,n.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,n.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,n.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,n.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,n.K2)(function(t,e){var i,a,n;if(this.options.backtrack_lexer&&(n={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&&(n.yylloc.range=this.yylloc.range.slice(0))),(a=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var s in n)this[s]=n[s];return!1},"test_match"),next:(0,n.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,a,n=this._currentRules(),s=0;s<n.length;s++)if((i=this._input.match(this.rules[n[s]]))&&(!e||i[0].length>e[0].length)){if(e=i,a=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,n[s])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,n[a]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,n.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,n.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,n.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,n.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,n.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,n.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,n.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,n.K2)(function(t,e,i,a){switch(i){case 0:case 1:case 3:break;case 2:return 55;case 4:return this.begin("title"),35;case 5:return this.popState(),"title_value";case 6:return this.begin("acc_title"),37;case 7:return this.popState(),"acc_title_value";case 8:return this.begin("acc_descr"),39;case 9:return this.popState(),"acc_descr_value";case 10:this.begin("acc_descr_multiline");break;case 11:case 23:case 25:case 31:this.popState();break;case 12:return"acc_descr_multiline_value";case 13:return 48;case 14:return 50;case 15:return 49;case 16:return 51;case 17:return 52;case 18:return 53;case 19:return 54;case 20:return 25;case 21:this.begin("md_string");break;case 22:return"MD_STR";case 24:this.begin("string");break;case 26:return"STR";case 27:this.begin("class_name");break;case 28:return this.popState(),47;case 29:return this.begin("point_start"),44;case 30:return this.begin("point_x"),45;case 32:this.popState(),this.begin("point_y");break;case 33:return this.popState(),46;case 34:return 28;case 35:return 4;case 36:return 15;case 37:return 11;case 38:return 64;case 39:return 10;case 40:case 41:return 65;case 42:return 14;case 43:return 13;case 44:return 67;case 45:return 66;case 46:return 12;case 47:return 8;case 48:return 5;case 49:return 18;case 50:return 56;case 51:return 63;case 52:return 57}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:title\b)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?: *x-axis *)/i,/^(?: *y-axis *)/i,/^(?: *--+> *)/i,/^(?: *quadrant-1 *)/i,/^(?: *quadrant-2 *)/i,/^(?: *quadrant-3 *)/i,/^(?: *quadrant-4 *)/i,/^(?:classDef\b)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^"]*)/i,/^(?::::)/i,/^(?:^\w+)/i,/^(?:\s*:\s*\[\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?:\s*\] *)/i,/^(?:\s*,\s*)/i,/^(?:(1)|(0(.\d+)?))/i,/^(?: *quadrantChart *)/i,/^(?:[A-Za-z]+)/i,/^(?:[^\x00-\x7F]+)/i,/^(?::)/i,/^(?:\+)/i,/^(?:,)/i,/^(?:=)/i,/^(?:=)/i,/^(?:\*)/i,/^(?:#)/i,/^(?:[\_])/i,/^(?:\.)/i,/^(?:&)/i,/^(?:-)/i,/^(?:[0-9]+)/i,/^(?:\s)/i,/^(?:;)/i,/^(?:[!"#$%&'*+,-.`?\\_/])/i,/^(?:$)/i],conditions:{class_name:{rules:[28],inclusive:!1},point_y:{rules:[33],inclusive:!1},point_x:{rules:[32],inclusive:!1},point_start:{rules:[30,31],inclusive:!1},acc_descr_multiline:{rules:[11,12],inclusive:!1},acc_descr:{rules:[9],inclusive:!1},acc_title:{rules:[7],inclusive:!1},title:{rules:[5],inclusive:!1},md_string:{rules:[22,23],inclusive:!1},string:{rules:[25,26],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,6,8,10,13,14,15,16,17,18,19,20,21,24,27,29,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52],inclusive:!0}}},(0,n.K2)(tg,"Parser"),tg.prototype=tx,tx.Parser=tg,new tg}();r.parser=r;var l=(0,a.P$)(),o=class{constructor(){this.classes=new Map,this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData()}static{(0,n.K2)(this,"QuadrantBuilder")}getDefaultData(){return{titleText:"",quadrant1Text:"",quadrant2Text:"",quadrant3Text:"",quadrant4Text:"",xAxisLeftText:"",xAxisRightText:"",yAxisBottomText:"",yAxisTopText:"",points:[]}}getDefaultConfig(){return{showXAxis:!0,showYAxis:!0,showTitle:!0,chartHeight:a.UI.quadrantChart?.chartWidth||500,chartWidth:a.UI.quadrantChart?.chartHeight||500,titlePadding:a.UI.quadrantChart?.titlePadding||10,titleFontSize:a.UI.quadrantChart?.titleFontSize||20,quadrantPadding:a.UI.quadrantChart?.quadrantPadding||5,xAxisLabelPadding:a.UI.quadrantChart?.xAxisLabelPadding||5,yAxisLabelPadding:a.UI.quadrantChart?.yAxisLabelPadding||5,xAxisLabelFontSize:a.UI.quadrantChart?.xAxisLabelFontSize||16,yAxisLabelFontSize:a.UI.quadrantChart?.yAxisLabelFontSize||16,quadrantLabelFontSize:a.UI.quadrantChart?.quadrantLabelFontSize||16,quadrantTextTopPadding:a.UI.quadrantChart?.quadrantTextTopPadding||5,pointTextPadding:a.UI.quadrantChart?.pointTextPadding||5,pointLabelFontSize:a.UI.quadrantChart?.pointLabelFontSize||12,pointRadius:a.UI.quadrantChart?.pointRadius||5,xAxisPosition:a.UI.quadrantChart?.xAxisPosition||"top",yAxisPosition:a.UI.quadrantChart?.yAxisPosition||"left",quadrantInternalBorderStrokeWidth:a.UI.quadrantChart?.quadrantInternalBorderStrokeWidth||1,quadrantExternalBorderStrokeWidth:a.UI.quadrantChart?.quadrantExternalBorderStrokeWidth||2}}getDefaultThemeConfig(){return{quadrant1Fill:l.quadrant1Fill,quadrant2Fill:l.quadrant2Fill,quadrant3Fill:l.quadrant3Fill,quadrant4Fill:l.quadrant4Fill,quadrant1TextFill:l.quadrant1TextFill,quadrant2TextFill:l.quadrant2TextFill,quadrant3TextFill:l.quadrant3TextFill,quadrant4TextFill:l.quadrant4TextFill,quadrantPointFill:l.quadrantPointFill,quadrantPointTextFill:l.quadrantPointTextFill,quadrantXAxisTextFill:l.quadrantXAxisTextFill,quadrantYAxisTextFill:l.quadrantYAxisTextFill,quadrantTitleFill:l.quadrantTitleFill,quadrantInternalBorderStrokeFill:l.quadrantInternalBorderStrokeFill,quadrantExternalBorderStrokeFill:l.quadrantExternalBorderStrokeFill}}clear(){this.config=this.getDefaultConfig(),this.themeConfig=this.getDefaultThemeConfig(),this.data=this.getDefaultData(),this.classes=new Map,n.Rm.info("clear called")}setData(t){this.data={...this.data,...t}}addPoints(t){this.data.points=[...t,...this.data.points]}addClass(t,e){this.classes.set(t,e)}setConfig(t){n.Rm.trace("setConfig called with: ",t),this.config={...this.config,...t}}setThemeConfig(t){n.Rm.trace("setThemeConfig called with: ",t),this.themeConfig={...this.themeConfig,...t}}calculateSpace(t,e,i,a){let n=2*this.config.xAxisLabelPadding+this.config.xAxisLabelFontSize,s={top:"top"===t&&e?n:0,bottom:"bottom"===t&&e?n:0},r=2*this.config.yAxisLabelPadding+this.config.yAxisLabelFontSize,l={left:"left"===this.config.yAxisPosition&&i?r:0,right:"right"===this.config.yAxisPosition&&i?r:0},o=this.config.titleFontSize+2*this.config.titlePadding,h={top:a?o:0},c=this.config.quadrantPadding+l.left,d=this.config.quadrantPadding+s.top+h.top,u=this.config.chartWidth-2*this.config.quadrantPadding-l.left-l.right,x=this.config.chartHeight-2*this.config.quadrantPadding-s.top-s.bottom-h.top;return{xAxisSpace:s,yAxisSpace:l,titleSpace:h,quadrantSpace:{quadrantLeft:c,quadrantTop:d,quadrantWidth:u,quadrantHalfWidth:u/2,quadrantHeight:x,quadrantHalfHeight:x/2}}}getAxisLabels(t,e,i,a){let{quadrantSpace:n,titleSpace:s}=a,{quadrantHalfHeight:r,quadrantHeight:l,quadrantLeft:o,quadrantHalfWidth:h,quadrantTop:c,quadrantWidth:d}=n,u=!!this.data.xAxisRightText,x=!!this.data.yAxisTopText,g=[];return this.data.xAxisLeftText&&e&&g.push({text:this.data.xAxisLeftText,fill:this.themeConfig.quadrantXAxisTextFill,x:o+(u?h/2:0),y:"top"===t?this.config.xAxisLabelPadding+s.top:this.config.xAxisLabelPadding+c+l+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:u?"center":"left",horizontalPos:"top",rotation:0}),this.data.xAxisRightText&&e&&g.push({text:this.data.xAxisRightText,fill:this.themeConfig.quadrantXAxisTextFill,x:o+h+(u?h/2:0),y:"top"===t?this.config.xAxisLabelPadding+s.top:this.config.xAxisLabelPadding+c+l+this.config.quadrantPadding,fontSize:this.config.xAxisLabelFontSize,verticalPos:u?"center":"left",horizontalPos:"top",rotation:0}),this.data.yAxisBottomText&&i&&g.push({text:this.data.yAxisBottomText,fill:this.themeConfig.quadrantYAxisTextFill,x:"left"===this.config.yAxisPosition?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+o+d+this.config.quadrantPadding,y:c+l-(x?r/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:x?"center":"left",horizontalPos:"top",rotation:-90}),this.data.yAxisTopText&&i&&g.push({text:this.data.yAxisTopText,fill:this.themeConfig.quadrantYAxisTextFill,x:"left"===this.config.yAxisPosition?this.config.yAxisLabelPadding:this.config.yAxisLabelPadding+o+d+this.config.quadrantPadding,y:c+r-(x?r/2:0),fontSize:this.config.yAxisLabelFontSize,verticalPos:x?"center":"left",horizontalPos:"top",rotation:-90}),g}getQuadrants(t){let{quadrantSpace:e}=t,{quadrantHalfHeight:i,quadrantLeft:a,quadrantHalfWidth:n,quadrantTop:s}=e,r=[{text:{text:this.data.quadrant1Text,fill:this.themeConfig.quadrant1TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:a+n,y:s,width:n,height:i,fill:this.themeConfig.quadrant1Fill},{text:{text:this.data.quadrant2Text,fill:this.themeConfig.quadrant2TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:a,y:s,width:n,height:i,fill:this.themeConfig.quadrant2Fill},{text:{text:this.data.quadrant3Text,fill:this.themeConfig.quadrant3TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:a,y:s+i,width:n,height:i,fill:this.themeConfig.quadrant3Fill},{text:{text:this.data.quadrant4Text,fill:this.themeConfig.quadrant4TextFill,x:0,y:0,fontSize:this.config.quadrantLabelFontSize,verticalPos:"center",horizontalPos:"middle",rotation:0},x:a+n,y:s+i,width:n,height:i,fill:this.themeConfig.quadrant4Fill}];for(let t of r)t.text.x=t.x+t.width/2,0===this.data.points.length?(t.text.y=t.y+t.height/2,t.text.horizontalPos="middle"):(t.text.y=t.y+this.config.quadrantTextTopPadding,t.text.horizontalPos="top");return r}getQuadrantPoints(t){let{quadrantSpace:e}=t,{quadrantHeight:i,quadrantLeft:a,quadrantTop:n,quadrantWidth:r}=e,l=(0,s.m4Y)().domain([0,1]).range([a,r+a]),o=(0,s.m4Y)().domain([0,1]).range([i+n,n]);return this.data.points.map(t=>{let e=this.classes.get(t.className);return e&&(t={...e,...t}),{x:l(t.x),y:o(t.y),fill:t.color??this.themeConfig.quadrantPointFill,radius:t.radius??this.config.pointRadius,text:{text:t.text,fill:this.themeConfig.quadrantPointTextFill,x:l(t.x),y:o(t.y)+this.config.pointTextPadding,verticalPos:"center",horizontalPos:"top",fontSize:this.config.pointLabelFontSize,rotation:0},strokeColor:t.strokeColor??this.themeConfig.quadrantPointFill,strokeWidth:t.strokeWidth??"0px"}})}getBorders(t){let e=this.config.quadrantExternalBorderStrokeWidth/2,{quadrantSpace:i}=t,{quadrantHalfHeight:a,quadrantHeight:n,quadrantLeft:s,quadrantHalfWidth:r,quadrantTop:l,quadrantWidth:o}=i;return[{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:s-e,y1:l,x2:s+o+e,y2:l},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:s+o,y1:l+e,x2:s+o,y2:l+n-e},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:s-e,y1:l+n,x2:s+o+e,y2:l+n},{strokeFill:this.themeConfig.quadrantExternalBorderStrokeFill,strokeWidth:this.config.quadrantExternalBorderStrokeWidth,x1:s,y1:l+e,x2:s,y2:l+n-e},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:s+r,y1:l+e,x2:s+r,y2:l+n-e},{strokeFill:this.themeConfig.quadrantInternalBorderStrokeFill,strokeWidth:this.config.quadrantInternalBorderStrokeWidth,x1:s+e,y1:l+a,x2:s+o-e,y2:l+a}]}getTitle(t){if(t)return{text:this.data.titleText,fill:this.themeConfig.quadrantTitleFill,fontSize:this.config.titleFontSize,horizontalPos:"top",verticalPos:"center",rotation:0,y:this.config.titlePadding,x:this.config.chartWidth/2}}build(){let t=this.config.showXAxis&&!!(this.data.xAxisLeftText||this.data.xAxisRightText),e=this.config.showYAxis&&!!(this.data.yAxisTopText||this.data.yAxisBottomText),i=this.config.showTitle&&!!this.data.titleText,a=this.data.points.length>0?"bottom":this.config.xAxisPosition,n=this.calculateSpace(a,t,e,i);return{points:this.getQuadrantPoints(n),quadrants:this.getQuadrants(n),axisLabels:this.getAxisLabels(a,t,e,n),borderLines:this.getBorders(n),title:this.getTitle(i)}}},h=class extends Error{static{(0,n.K2)(this,"InvalidStyleError")}constructor(t,e,i){super(`value for ${t} ${e} is invalid, please use a valid ${i}`),this.name="InvalidStyleError"}};function c(t){return!/^#?([\dA-Fa-f]{6}|[\dA-Fa-f]{3})$/.test(t)}function d(t){return!/^\d+$/.test(t)}function u(t){return!/^\d+px$/.test(t)}(0,n.K2)(c,"validateHexCode"),(0,n.K2)(d,"validateNumber"),(0,n.K2)(u,"validateSizeInPixels");var x=(0,a.D7)();function g(t){return(0,a.jZ)(t.trim(),x)}(0,n.K2)(g,"textSanitizer");var f=new o;function p(t){f.setData({quadrant1Text:g(t.text)})}function y(t){f.setData({quadrant2Text:g(t.text)})}function m(t){f.setData({quadrant3Text:g(t.text)})}function T(t){f.setData({quadrant4Text:g(t.text)})}function _(t){f.setData({xAxisLeftText:g(t.text)})}function q(t){f.setData({xAxisRightText:g(t.text)})}function A(t){f.setData({yAxisTopText:g(t.text)})}function b(t){f.setData({yAxisBottomText:g(t.text)})}function k(t){let e={};for(let i of t){let[t,a]=i.trim().split(/\s*:\s*/);if("radius"===t){if(d(a))throw new h(t,a,"number");e.radius=parseInt(a)}else if("color"===t){if(c(a))throw new h(t,a,"hex code");e.color=a}else if("stroke-color"===t){if(c(a))throw new h(t,a,"hex code");e.strokeColor=a}else if("stroke-width"===t){if(u(a))throw new h(t,a,"number of pixels (eg. 10px)");e.strokeWidth=a}else throw Error(`style named ${t} is not supported.`)}return e}function S(t,e,i,a,n){let s=k(n);f.addPoints([{x:i,y:a,text:g(t.text),className:e,...s}])}function F(t,e){f.addClass(t,k(e))}function P(t){f.setConfig({chartWidth:t})}function C(t){f.setConfig({chartHeight:t})}function v(){let{themeVariables:t,quadrantChart:e}=(0,a.D7)();return e&&f.setConfig(e),f.setThemeConfig({quadrant1Fill:t.quadrant1Fill,quadrant2Fill:t.quadrant2Fill,quadrant3Fill:t.quadrant3Fill,quadrant4Fill:t.quadrant4Fill,quadrant1TextFill:t.quadrant1TextFill,quadrant2TextFill:t.quadrant2TextFill,quadrant3TextFill:t.quadrant3TextFill,quadrant4TextFill:t.quadrant4TextFill,quadrantPointFill:t.quadrantPointFill,quadrantPointTextFill:t.quadrantPointTextFill,quadrantXAxisTextFill:t.quadrantXAxisTextFill,quadrantYAxisTextFill:t.quadrantYAxisTextFill,quadrantExternalBorderStrokeFill:t.quadrantExternalBorderStrokeFill,quadrantInternalBorderStrokeFill:t.quadrantInternalBorderStrokeFill,quadrantTitleFill:t.quadrantTitleFill}),f.setData({titleText:(0,a.ab)()}),f.build()}(0,n.K2)(p,"setQuadrant1Text"),(0,n.K2)(y,"setQuadrant2Text"),(0,n.K2)(m,"setQuadrant3Text"),(0,n.K2)(T,"setQuadrant4Text"),(0,n.K2)(_,"setXAxisLeftText"),(0,n.K2)(q,"setXAxisRightText"),(0,n.K2)(A,"setYAxisTopText"),(0,n.K2)(b,"setYAxisBottomText"),(0,n.K2)(k,"parseStyles"),(0,n.K2)(S,"addPoint"),(0,n.K2)(F,"addClass"),(0,n.K2)(P,"setWidth"),(0,n.K2)(C,"setHeight"),(0,n.K2)(v,"getQuadrantData");var L={setWidth:P,setHeight:C,setQuadrant1Text:p,setQuadrant2Text:y,setQuadrant3Text:m,setQuadrant4Text:T,setXAxisLeftText:_,setXAxisRightText:q,setYAxisTopText:A,setYAxisBottomText:b,parseStyles:k,addPoint:S,addClass:F,getQuadrantData:v,clear:(0,n.K2)(function(){f.clear(),(0,a.IU)()},"clear"),setAccTitle:a.SV,getAccTitle:a.iN,setDiagramTitle:a.ke,getDiagramTitle:a.ab,getAccDescription:a.m7,setAccDescription:a.EI},I={parser:r,db:L,renderer:{draw:(0,n.K2)((t,e,i,r)=>{let l;function o(t){return"top"===t?"hanging":"middle"}function h(t){return"left"===t?"start":"middle"}function c(t){return`translate(${t.x}, ${t.y}) rotate(${t.rotation||0})`}(0,n.K2)(o,"getDominantBaseLine"),(0,n.K2)(h,"getTextAnchor"),(0,n.K2)(c,"getTransformation");let d=(0,a.D7)();n.Rm.debug("Rendering quadrant chart\n"+t);let u=d.securityLevel;"sandbox"===u&&(l=(0,s.Ltv)("#i"+e));let x=("sandbox"===u?(0,s.Ltv)(l.nodes()[0].contentDocument.body):(0,s.Ltv)("body")).select(`[id="${e}"]`),g=x.append("g").attr("class","main"),f=d.quadrantChart?.chartWidth??500,p=d.quadrantChart?.chartHeight??500;(0,a.a$)(x,p,f,d.quadrantChart?.useMaxWidth??!0),x.attr("viewBox","0 0 "+f+" "+p),r.db.setHeight(p),r.db.setWidth(f);let y=r.db.getQuadrantData(),m=g.append("g").attr("class","quadrants"),T=g.append("g").attr("class","border"),_=g.append("g").attr("class","data-points"),q=g.append("g").attr("class","labels"),A=g.append("g").attr("class","title");y.title&&A.append("text").attr("x",0).attr("y",0).attr("fill",y.title.fill).attr("font-size",y.title.fontSize).attr("dominant-baseline",o(y.title.horizontalPos)).attr("text-anchor",h(y.title.verticalPos)).attr("transform",c(y.title)).text(y.title.text),y.borderLines&&T.selectAll("line").data(y.borderLines).enter().append("line").attr("x1",t=>t.x1).attr("y1",t=>t.y1).attr("x2",t=>t.x2).attr("y2",t=>t.y2).style("stroke",t=>t.strokeFill).style("stroke-width",t=>t.strokeWidth);let b=m.selectAll("g.quadrant").data(y.quadrants).enter().append("g").attr("class","quadrant");b.append("rect").attr("x",t=>t.x).attr("y",t=>t.y).attr("width",t=>t.width).attr("height",t=>t.height).attr("fill",t=>t.fill),b.append("text").attr("x",0).attr("y",0).attr("fill",t=>t.text.fill).attr("font-size",t=>t.text.fontSize).attr("dominant-baseline",t=>o(t.text.horizontalPos)).attr("text-anchor",t=>h(t.text.verticalPos)).attr("transform",t=>c(t.text)).text(t=>t.text.text),q.selectAll("g.label").data(y.axisLabels).enter().append("g").attr("class","label").append("text").attr("x",0).attr("y",0).text(t=>t.text).attr("fill",t=>t.fill).attr("font-size",t=>t.fontSize).attr("dominant-baseline",t=>o(t.horizontalPos)).attr("text-anchor",t=>h(t.verticalPos)).attr("transform",t=>c(t));let k=_.selectAll("g.data-point").data(y.points).enter().append("g").attr("class","data-point");k.append("circle").attr("cx",t=>t.x).attr("cy",t=>t.y).attr("r",t=>t.radius).attr("fill",t=>t.fill).attr("stroke",t=>t.strokeColor).attr("stroke-width",t=>t.strokeWidth),k.append("text").attr("x",0).attr("y",0).text(t=>t.text.text).attr("fill",t=>t.text.fill).attr("font-size",t=>t.text.fontSize).attr("dominant-baseline",t=>o(t.text.horizontalPos)).attr("text-anchor",t=>h(t.text.verticalPos)).attr("transform",t=>c(t.text))},"draw")},styles:(0,n.K2)(()=>"","styles")}}}]);
_next/static/chunks/6386.543ffeae6a482fb1.js ADDED
@@ -0,0 +1,93 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6386],{3580:(t,e,i)=>{i.d(e,{o:()=>n});var n=(0,i(316).K2)(()=>`
2
+ /* Font Awesome icon styling - consolidated */
3
+ .label-icon {
4
+ display: inline-block;
5
+ height: 1em;
6
+ overflow: visible;
7
+ vertical-align: -0.125em;
8
+ }
9
+
10
+ .node .label-icon path {
11
+ fill: currentColor;
12
+ stroke: revert;
13
+ stroke-width: revert;
14
+ }
15
+ `,"getIconStyles")},6386:(t,e,i)=>{i.d(e,{diagram:()=>A});var n=i(2667),s=i(3580),r=i(2482),o=i(5407);i(7920),i(3148),i(1538),i(3736);var a=i(669),l=i(316),c=i(9258),h=i(7048),u=i(2118),g=function(){var t=(0,l.K2)(function(t,e,i,n){for(i=i||{},n=t.length;n--;i[t[n]]=e);return i},"o"),e=[1,4],i=[1,13],n=[1,12],s=[1,15],r=[1,16],o=[1,20],a=[1,19],c=[6,7,8],h=[1,26],u=[1,24],g=[1,25],d=[6,7,11],p=[1,31],y=[6,7,11,24],f=[1,6,13,16,17,20,23],m=[1,35],b=[1,36],_=[1,6,7,11,13,16,17,20,23],k=[1,38],E={trace:(0,l.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,mindMap:4,spaceLines:5,SPACELINE:6,NL:7,KANBAN:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,node:14,shapeData:15,ICON:16,CLASS:17,nodeWithId:18,nodeWithoutId:19,NODE_DSTART:20,NODE_DESCR:21,NODE_DEND:22,NODE_ID:23,SHAPE_DATA:24,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"KANBAN",11:"EOF",13:"SPACELIST",16:"ICON",17:"CLASS",20:"NODE_DSTART",21:"NODE_DESCR",22:"NODE_DEND",23:"NODE_ID",24:"SHAPE_DATA"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,3],[12,2],[12,2],[12,2],[12,1],[12,2],[12,1],[12,1],[12,1],[12,1],[14,1],[14,1],[19,3],[18,1],[18,4],[15,2],[15,1]],performAction:(0,l.K2)(function(t,e,i,n,s,r,o){var a=r.length-1;switch(s){case 6:case 7:return n;case 8:n.getLogger().trace("Stop NL ");break;case 9:n.getLogger().trace("Stop EOF ");break;case 11:n.getLogger().trace("Stop NL2 ");break;case 12:n.getLogger().trace("Stop EOF2 ");break;case 15:n.getLogger().info("Node: ",r[a-1].id),n.addNode(r[a-2].length,r[a-1].id,r[a-1].descr,r[a-1].type,r[a]);break;case 16:n.getLogger().info("Node: ",r[a].id),n.addNode(r[a-1].length,r[a].id,r[a].descr,r[a].type);break;case 17:n.getLogger().trace("Icon: ",r[a]),n.decorateNode({icon:r[a]});break;case 18:case 23:n.decorateNode({class:r[a]});break;case 19:n.getLogger().trace("SPACELIST");break;case 20:n.getLogger().trace("Node: ",r[a-1].id),n.addNode(0,r[a-1].id,r[a-1].descr,r[a-1].type,r[a]);break;case 21:n.getLogger().trace("Node: ",r[a].id),n.addNode(0,r[a].id,r[a].descr,r[a].type);break;case 22:n.decorateNode({icon:r[a]});break;case 27:n.getLogger().trace("node found ..",r[a-2]),this.$={id:r[a-1],descr:r[a-1],type:n.getType(r[a-2],r[a])};break;case 28:this.$={id:r[a],descr:r[a],type:0};break;case 29:n.getLogger().trace("node found ..",r[a-3]),this.$={id:r[a-3],descr:r[a-1],type:n.getType(r[a-2],r[a])};break;case 30:this.$=r[a-1]+r[a];break;case 31:this.$=r[a]}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:i,7:[1,10],9:9,12:11,13:n,14:14,16:s,17:r,18:17,19:18,20:o,23:a},t(c,[2,3]),{1:[2,2]},t(c,[2,4]),t(c,[2,5]),{1:[2,6],6:i,12:21,13:n,14:14,16:s,17:r,18:17,19:18,20:o,23:a},{6:i,9:22,12:11,13:n,14:14,16:s,17:r,18:17,19:18,20:o,23:a},{6:h,7:u,10:23,11:g},t(d,[2,24],{18:17,19:18,14:27,16:[1,28],17:[1,29],20:o,23:a}),t(d,[2,19]),t(d,[2,21],{15:30,24:p}),t(d,[2,22]),t(d,[2,23]),t(y,[2,25]),t(y,[2,26]),t(y,[2,28],{20:[1,32]}),{21:[1,33]},{6:h,7:u,10:34,11:g},{1:[2,7],6:i,12:21,13:n,14:14,16:s,17:r,18:17,19:18,20:o,23:a},t(f,[2,14],{7:m,11:b}),t(_,[2,8]),t(_,[2,9]),t(_,[2,10]),t(d,[2,16],{15:37,24:p}),t(d,[2,17]),t(d,[2,18]),t(d,[2,20],{24:k}),t(y,[2,31]),{21:[1,39]},{22:[1,40]},t(f,[2,13],{7:m,11:b}),t(_,[2,11]),t(_,[2,12]),t(d,[2,15],{24:k}),t(y,[2,30]),{22:[1,41]},t(y,[2,27]),t(y,[2,29])],defaultActions:{2:[2,1],6:[2,2]},parseError:(0,l.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,l.K2)(function(t){var e=this,i=[0],n=[],s=[null],r=[],o=this.table,a="",c=0,h=0,u=0,g=r.slice.call(arguments,1),d=Object.create(this.lexer),p={};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(p[y]=this.yy[y]);d.setInput(t,p),p.lexer=d,p.parser=this,void 0===d.yylloc&&(d.yylloc={});var f=d.yylloc;r.push(f);var m=d.options&&d.options.ranges;function b(){var t;return"number"!=typeof(t=n.pop()||d.lex()||1)&&(t instanceof Array&&(t=(n=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof p.parseError?this.parseError=p.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,l.K2)(function(t){i.length=i.length-2*t,s.length=s.length-t,r.length=r.length-t},"popStack"),(0,l.K2)(b,"lex");for(var _,k,E,S,N,x,D,L,I,v={};;){if(E=i[i.length-1],this.defaultActions[E]?S=this.defaultActions[E]:(null==_&&(_=b()),S=o[E]&&o[E][_]),void 0===S||!S.length||!S[0]){var C="";for(x in I=[],o[E])this.terminals_[x]&&x>2&&I.push("'"+this.terminals_[x]+"'");C=d.showPosition?"Parse error on line "+(c+1)+":\n"+d.showPosition()+"\nExpecting "+I.join(", ")+", got '"+(this.terminals_[_]||_)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==_?"end of input":"'"+(this.terminals_[_]||_)+"'"),this.parseError(C,{text:d.match,token:this.terminals_[_]||_,line:d.yylineno,loc:f,expected:I})}if(S[0]instanceof Array&&S.length>1)throw Error("Parse Error: multiple actions possible at state: "+E+", token: "+_);switch(S[0]){case 1:i.push(_),s.push(d.yytext),r.push(d.yylloc),i.push(S[1]),_=null,k?(_=k,k=null):(h=d.yyleng,a=d.yytext,c=d.yylineno,f=d.yylloc,u>0&&u--);break;case 2:if(D=this.productions_[S[1]][1],v.$=s[s.length-D],v._$={first_line:r[r.length-(D||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(D||1)].first_column,last_column:r[r.length-1].last_column},m&&(v._$.range=[r[r.length-(D||1)].range[0],r[r.length-1].range[1]]),void 0!==(N=this.performAction.apply(v,[a,h,c,p,S[1],s,r].concat(g))))return N;D&&(i=i.slice(0,-1*D*2),s=s.slice(0,-1*D),r=r.slice(0,-1*D)),i.push(this.productions_[S[1]][0]),s.push(v.$),r.push(v._$),L=o[i[i.length-2]][i[i.length-1]],i.push(L);break;case 3:return!0}}return!0},"parse")};function S(){this.yy={}}return E.lexer={EOF:1,parseError:(0,l.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,l.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,l.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,l.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var n=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var s=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===n.length?this.yylloc.first_column:0)+n[n.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[s[0],s[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,l.K2)(function(){return this._more=!0,this},"more"),reject:(0,l.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,l.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,l.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,l.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,l.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,l.K2)(function(t,e){var i,n,s;if(this.options.backtrack_lexer&&(s={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&&(s.yylloc.range=this.yylloc.range.slice(0))),(n=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var r in s)this[r]=s[r];return!1},"test_match"),next:(0,l.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,n,s=this._currentRules(),r=0;r<s.length;r++)if((i=this._input.match(this.rules[s[r]]))&&(!e||i[0].length>e[0].length)){if(e=i,n=r,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,s[r])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,s[n]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,l.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,l.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,l.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,l.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,l.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,l.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,l.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,l.K2)(function(t,e,i,n){switch(i){case 0:return this.pushState("shapeData"),e.yytext="",24;case 1:return this.pushState("shapeDataStr"),24;case 2:return this.popState(),24;case 3:return e.yytext=e.yytext.replace(/\n\s*/g,"<br/>"),24;case 4:return 24;case 5:case 10:case 29:case 32:this.popState();break;case 6:return t.getLogger().trace("Found comment",e.yytext),6;case 7:return 8;case 8:this.begin("CLASS");break;case 9:return this.popState(),17;case 11:t.getLogger().trace("Begin icon"),this.begin("ICON");break;case 12:return t.getLogger().trace("SPACELINE"),6;case 13:return 7;case 14:return 16;case 15:t.getLogger().trace("end icon"),this.popState();break;case 16:return t.getLogger().trace("Exploding node"),this.begin("NODE"),20;case 17:return t.getLogger().trace("Cloud"),this.begin("NODE"),20;case 18:return t.getLogger().trace("Explosion Bang"),this.begin("NODE"),20;case 19:return t.getLogger().trace("Cloud Bang"),this.begin("NODE"),20;case 20:case 21:case 22:case 23:return this.begin("NODE"),20;case 24:return 13;case 25:return 23;case 26:return 11;case 27:this.begin("NSTR2");break;case 28:return"NODE_DESCR";case 30:t.getLogger().trace("Starting NSTR"),this.begin("NSTR");break;case 31:return t.getLogger().trace("description:",e.yytext),"NODE_DESCR";case 33:return this.popState(),t.getLogger().trace("node end ))"),"NODE_DEND";case 34:return this.popState(),t.getLogger().trace("node end )"),"NODE_DEND";case 35:return this.popState(),t.getLogger().trace("node end ...",e.yytext),"NODE_DEND";case 36:case 39:case 40:return this.popState(),t.getLogger().trace("node end (("),"NODE_DEND";case 37:case 38:return this.popState(),t.getLogger().trace("node end (-"),"NODE_DEND";case 41:case 42:return t.getLogger().trace("Long description:",e.yytext),21}},"anonymous"),rules:[/^(?:@\{)/i,/^(?:["])/i,/^(?:["])/i,/^(?:[^\"]+)/i,/^(?:[^}^"]+)/i,/^(?:\})/i,/^(?:\s*%%.*)/i,/^(?:kanban\b)/i,/^(?::::)/i,/^(?:.+)/i,/^(?:\n)/i,/^(?:::icon\()/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[^\)]+)/i,/^(?:\))/i,/^(?:-\))/i,/^(?:\(-)/i,/^(?:\)\))/i,/^(?:\))/i,/^(?:\(\()/i,/^(?:\{\{)/i,/^(?:\()/i,/^(?:\[)/i,/^(?:[\s]+)/i,/^(?:[^\(\[\n\)\{\}@]+)/i,/^(?:$)/i,/^(?:["][`])/i,/^(?:[^`"]+)/i,/^(?:[`]["])/i,/^(?:["])/i,/^(?:[^"]+)/i,/^(?:["])/i,/^(?:[\)]\))/i,/^(?:[\)])/i,/^(?:[\]])/i,/^(?:\}\})/i,/^(?:\(-)/i,/^(?:-\))/i,/^(?:\(\()/i,/^(?:\()/i,/^(?:[^\)\]\(\}]+)/i,/^(?:.+(?!\(\())/i],conditions:{shapeDataEndBracket:{rules:[],inclusive:!1},shapeDataStr:{rules:[2,3],inclusive:!1},shapeData:{rules:[1,4,5],inclusive:!1},CLASS:{rules:[9,10],inclusive:!1},ICON:{rules:[14,15],inclusive:!1},NSTR2:{rules:[28,29],inclusive:!1},NSTR:{rules:[31,32],inclusive:!1},NODE:{rules:[27,30,33,34,35,36,37,38,39,40,41,42],inclusive:!1},INITIAL:{rules:[0,6,7,8,11,12,13,16,17,18,19,20,21,22,23,24,25,26],inclusive:!0}}},(0,l.K2)(S,"Parser"),S.prototype=E,E.Parser=S,new S}();g.parser=g;var d=[],p=[],y=0,f={},m=(0,l.K2)(()=>{d=[],p=[],y=0,f={}},"clear"),b=(0,l.K2)(t=>{if(0===d.length)return null;let e=d[0].level,i=null;for(let t=d.length-1;t>=0;t--)if(d[t].level!==e||i||(i=d[t]),d[t].level<e)throw Error('Items without section detected, found section ("'+d[t].label+'")');return t===i?.level?null:i},"getSection"),_=(0,l.K2)(function(){return p},"getSections"),k=(0,l.K2)(function(){let t=[],e=_(),i=(0,a.D7)();for(let n of e){let e={id:n.id,label:(0,a.jZ)(n.label??"",i),labelType:"markdown",isGroup:!0,ticket:n.ticket,shape:"kanbanSection",level:n.level,look:i.look};for(let s of(t.push(e),d.filter(t=>t.parentId===n.id))){let e={id:s.id,parentId:n.id,label:(0,a.jZ)(s.label??"",i),labelType:"markdown",isGroup:!1,ticket:s?.ticket,priority:s?.priority,assigned:s?.assigned,icon:s?.icon,shape:"kanbanItem",level:s.level,rx:5,ry:5,cssStyles:["text-align: left"]};t.push(e)}}return{nodes:t,edges:[],other:{},config:(0,a.D7)()}},"getData"),E=(0,l.K2)((t,e,i,n,s)=>{let o=(0,a.D7)(),l=o.mindmap?.padding??a.UI.mindmap.padding;switch(n){case S.ROUNDED_RECT:case S.RECT:case S.HEXAGON:l*=2}let c={id:(0,a.jZ)(e,o)||"kbn"+y++,level:t,label:(0,a.jZ)(i,o),width:o.mindmap?.maxNodeWidth??a.UI.mindmap.maxNodeWidth,padding:l,isGroup:!1};if(void 0!==s){let t;t=s.includes("\n")?s+"\n":"{\n"+s+"\n}";let e=(0,r.H)(t,{schema:r.r});if(e.shape&&(e.shape!==e.shape.toLowerCase()||e.shape.includes("_")))throw Error(`No such shape: ${e.shape}. Shape names should be lowercase.`);e?.shape&&"kanbanItem"===e.shape&&(c.shape=e?.shape),e?.label&&(c.label=e?.label),e?.icon&&(c.icon=e?.icon.toString()),e?.assigned&&(c.assigned=e?.assigned.toString()),e?.ticket&&(c.ticket=e?.ticket.toString()),e?.priority&&(c.priority=e?.priority)}let h=b(t);h?c.parentId=h.id||"kbn"+y++:p.push(c),d.push(c)},"addNode"),S={DEFAULT:0,NO_BORDER:0,ROUNDED_RECT:1,RECT:2,CIRCLE:3,CLOUD:4,BANG:5,HEXAGON:6},N=(0,l.K2)((t,e)=>{switch(l.Rm.debug("In get type",t,e),t){case"[":return S.RECT;case"(":return")"===e?S.ROUNDED_RECT:S.CLOUD;case"((":return S.CIRCLE;case")":return S.CLOUD;case"))":return S.BANG;case"{{":return S.HEXAGON;default:return S.DEFAULT}},"getType"),x=(0,l.K2)((t,e)=>{f[t]=e},"setElementForId"),D=(0,l.K2)(t=>{if(!t)return;let e=(0,a.D7)(),i=d[d.length-1];t.icon&&(i.icon=(0,a.jZ)(t.icon,e)),t.class&&(i.cssClasses=(0,a.jZ)(t.class,e))},"decorateNode"),L=(0,l.K2)(t=>{switch(t){case S.DEFAULT:return"no-border";case S.RECT:return"rect";case S.ROUNDED_RECT:return"rounded-rect";case S.CIRCLE:return"circle";case S.CLOUD:return"cloud";case S.BANG:return"bang";case S.HEXAGON:return"hexgon";default:return"no-border"}},"type2Str"),I=(0,l.K2)(()=>l.Rm,"getLogger"),v=(0,l.K2)(t=>f[t],"getElementById"),C=(0,l.K2)(async(t,e,i,s)=>{l.Rm.debug("Rendering kanban diagram\n"+t);let r=s.db.getData(),c=(0,a.D7)();c.htmlLabels=!1;let h=(0,n.D)(e);for(let t of r.nodes)t.domId=`${e}-${t.id}`;let u=h.append("g");u.attr("class","sections");let g=h.append("g");g.attr("class","items");let d=r.nodes.filter(t=>t.isGroup),p=0,y=[],f=25;for(let t of d){let e=c?.kanban?.sectionWidth||200;t.x=e*(p+=1)+(p-1)*10/2,t.width=e,t.y=0,t.height=3*e,t.rx=5,t.ry=5,t.cssClasses=t.cssClasses+" section-"+p;let i=await (0,o.U)(u,t);f=Math.max(f,i?.labelBBox?.height),y.push(i)}let m=0;for(let t of d){let e=y[m];m+=1;let i=c?.kanban?.sectionWidth||200,n=-(3*i)/2+f,s=n;for(let e of r.nodes.filter(e=>e.parentId===t.id)){if(e.isGroup)throw Error("Groups within groups are not allowed in Kanban diagrams");e.x=t.x,e.width=i-15;let n=(await (0,o.on)(g,e,{config:c})).node().getBBox();e.y=s+n.height/2,await (0,o.U_)(e),s=e.y+n.height/2+5}let a=e.cluster.select("rect"),l=Math.max(s-n+30,50)+(f-25);a.attr("height",l)}(0,a.ot)(void 0,h,c.mindmap?.padding??a.UI.kanban.padding,c.mindmap?.useMaxWidth??a.UI.kanban.useMaxWidth)},"draw"),O=(0,l.K2)(t=>{let e="";for(let e=0;e<t.THEME_COLOR_LIMIT;e++)t["lineColor"+e]=t["lineColor"+e]||t["cScaleInv"+e],(0,c.A)(t["lineColor"+e])?t["lineColor"+e]=(0,h.A)(t["lineColor"+e],20):t["lineColor"+e]=(0,u.A)(t["lineColor"+e],20);let i=(0,l.K2)((e,i)=>t.darkMode?(0,u.A)(e,i):(0,h.A)(e,i),"adjuster");for(let n=0;n<t.THEME_COLOR_LIMIT;n++){let s=""+(17-3*n);e+=`
16
+ .section-${n-1} rect, .section-${n-1} path, .section-${n-1} circle, .section-${n-1} polygon, .section-${n-1} path {
17
+ fill: ${i(t["cScale"+n],10)};
18
+ stroke: ${i(t["cScale"+n],10)};
19
+
20
+ }
21
+ .section-${n-1} text {
22
+ fill: ${t["cScaleLabel"+n]};
23
+ }
24
+ .node-icon-${n-1} {
25
+ font-size: 40px;
26
+ color: ${t["cScaleLabel"+n]};
27
+ }
28
+ .section-edge-${n-1}{
29
+ stroke: ${t["cScale"+n]};
30
+ }
31
+ .edge-depth-${n-1}{
32
+ stroke-width: ${s};
33
+ }
34
+ .section-${n-1} line {
35
+ stroke: ${t["cScaleInv"+n]} ;
36
+ stroke-width: 3;
37
+ }
38
+
39
+ .disabled, .disabled circle, .disabled text {
40
+ fill: lightgray;
41
+ }
42
+ .disabled text {
43
+ fill: #efefef;
44
+ }
45
+
46
+ .node rect,
47
+ .node circle,
48
+ .node ellipse,
49
+ .node polygon,
50
+ .node path {
51
+ fill: ${t.background};
52
+ stroke: ${t.nodeBorder};
53
+ stroke-width: 1px;
54
+ }
55
+
56
+ .kanban-ticket-link {
57
+ fill: ${t.background};
58
+ stroke: ${t.nodeBorder};
59
+ text-decoration: underline;
60
+ }
61
+ `}return e},"genSections"),A={db:{clear:m,addNode:E,getSections:_,getData:k,nodeType:S,getType:N,setElementForId:x,decorateNode:D,type2Str:L,getLogger:I,getElementById:v},renderer:{draw:C},parser:g,styles:(0,l.K2)(t=>`
62
+ .edge {
63
+ stroke-width: 3;
64
+ }
65
+ ${O(t)}
66
+ .section-root rect, .section-root path, .section-root circle, .section-root polygon {
67
+ fill: ${t.git0};
68
+ }
69
+ .section-root text {
70
+ fill: ${t.gitBranchLabel0};
71
+ }
72
+ .icon-container {
73
+ height:100%;
74
+ display: flex;
75
+ justify-content: center;
76
+ align-items: center;
77
+ }
78
+ .edge {
79
+ fill: none;
80
+ }
81
+ .cluster-label, .label {
82
+ color: ${t.textColor};
83
+ fill: ${t.textColor};
84
+ }
85
+ .kanban-label {
86
+ dy: 1em;
87
+ alignment-baseline: middle;
88
+ text-anchor: middle;
89
+ dominant-baseline: middle;
90
+ text-align: center;
91
+ }
92
+ ${(0,s.o)()}
93
+ `,"getStyles")}}}]);
_next/static/chunks/6849.d9658296f38abc1c.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6849],{6849:(r,e,s)=>{s.d(e,{diagram:()=>l});var a=s(4162);s(3580),s(3062),s(1184),s(2888),s(1593),s(4982),s(1431),s(5407),s(7920),s(3148),s(1538),s(3736),s(669);var t=s(316),l={parser:a._$,get db(){return new a.NM},renderer:a.Lh,styles:a.tM,init:(0,t.K2)(r=>{r.class||(r.class={}),r.class.arrowMarkerAbsolute=r.arrowMarkerAbsolute},"init")}}}]);
_next/static/chunks/7048.a7719967455ae00c.js ADDED
@@ -0,0 +1,115 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7048],{4667:(t,e,i)=>{i.d(e,{diagram:()=>te});var n=i(2667),r=i(3736),a=i(669),s=i(316),o=i(5508),l=i(9258),c=i(7048),h=i(2118),d=function(){var t=(0,s.K2)(function(t,e,i,n){for(i=i||{},n=t.length;n--;i[t[n]]=e);return i},"o"),e=[6,11,13,14,15,17,19,20,23,24],i=[1,12],n=[1,13],r=[1,14],a=[1,15],o=[1,16],l=[1,19],c=[1,20],h={trace:(0,s.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,timeline_header:4,document:5,EOF:6,timeline:7,timeline_lr:8,timeline_td:9,line:10,SPACE:11,statement:12,NEWLINE:13,title:14,acc_title:15,acc_title_value:16,acc_descr:17,acc_descr_value:18,acc_descr_multiline_value:19,section:20,period_statement:21,event_statement:22,period:23,event:24,$accept:0,$end:1},terminals_:{2:"error",6:"EOF",7:"timeline",8:"timeline_lr",9:"timeline_td",11:"SPACE",13:"NEWLINE",14:"title",15:"acc_title",16:"acc_title_value",17:"acc_descr",18:"acc_descr_value",19:"acc_descr_multiline_value",20:"section",23:"period",24:"event"},productions_:[0,[3,3],[4,1],[4,1],[4,1],[5,0],[5,2],[10,2],[10,1],[10,1],[10,1],[12,1],[12,2],[12,2],[12,1],[12,1],[12,1],[12,1],[21,1],[22,1]],performAction:(0,s.K2)(function(t,e,i,n,r,a,s){var o=a.length-1;switch(r){case 1:return a[o-1];case 3:n.setDirection("LR");break;case 4:n.setDirection("TD");break;case 5:case 9:case 10:this.$=[];break;case 6:a[o-1].push(a[o]),this.$=a[o-1];break;case 7:case 8:this.$=a[o];break;case 11:n.getCommonDb().setDiagramTitle(a[o].substr(6)),this.$=a[o].substr(6);break;case 12:this.$=a[o].trim(),n.getCommonDb().setAccTitle(this.$);break;case 13:case 14:this.$=a[o].trim(),n.getCommonDb().setAccDescription(this.$);break;case 15:n.addSection(a[o].substr(8)),this.$=a[o].substr(8);break;case 18:n.addTask(a[o],0,""),this.$=a[o];break;case 19:n.addEvent(a[o].substr(2)),this.$=a[o]}},"anonymous"),table:[{3:1,4:2,7:[1,3],8:[1,4],9:[1,5]},{1:[3]},t(e,[2,5],{5:6}),t(e,[2,2]),t(e,[2,3]),t(e,[2,4]),{6:[1,7],10:8,11:[1,9],12:10,13:[1,11],14:i,15:n,17:r,19:a,20:o,21:17,22:18,23:l,24:c},t(e,[2,10],{1:[2,1]}),t(e,[2,6]),{12:21,14:i,15:n,17:r,19:a,20:o,21:17,22:18,23:l,24:c},t(e,[2,8]),t(e,[2,9]),t(e,[2,11]),{16:[1,22]},{18:[1,23]},t(e,[2,14]),t(e,[2,15]),t(e,[2,16]),t(e,[2,17]),t(e,[2,18]),t(e,[2,19]),t(e,[2,7]),t(e,[2,12]),t(e,[2,13])],defaultActions:{},parseError:(0,s.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,s.K2)(function(t){var e=this,i=[0],n=[],r=[null],a=[],o=this.table,l="",c=0,h=0,d=0,u=a.slice.call(arguments,1),p=Object.create(this.lexer),g={};for(var f in this.yy)Object.prototype.hasOwnProperty.call(this.yy,f)&&(g[f]=this.yy[f]);p.setInput(t,g),g.lexer=p,g.parser=this,void 0===p.yylloc&&(p.yylloc={});var m=p.yylloc;a.push(m);var y=p.options&&p.options.ranges;function b(){var t;return"number"!=typeof(t=n.pop()||p.lex()||1)&&(t instanceof Array&&(t=(n=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.parseError?this.parseError=g.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,s.K2)(function(t){i.length=i.length-2*t,r.length=r.length-t,a.length=a.length-t},"popStack"),(0,s.K2)(b,"lex");for(var x,k,_,w,$,v,K,S,E,R={};;){if(_=i[i.length-1],this.defaultActions[_]?w=this.defaultActions[_]:(null==x&&(x=b()),w=o[_]&&o[_][x]),void 0===w||!w.length||!w[0]){var I="";for(v in E=[],o[_])this.terminals_[v]&&v>2&&E.push("'"+this.terminals_[v]+"'");I=p.showPosition?"Parse error on line "+(c+1)+":\n"+p.showPosition()+"\nExpecting "+E.join(", ")+", got '"+(this.terminals_[x]||x)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==x?"end of input":"'"+(this.terminals_[x]||x)+"'"),this.parseError(I,{text:p.match,token:this.terminals_[x]||x,line:p.yylineno,loc:m,expected:E})}if(w[0]instanceof Array&&w.length>1)throw Error("Parse Error: multiple actions possible at state: "+_+", token: "+x);switch(w[0]){case 1:i.push(x),r.push(p.yytext),a.push(p.yylloc),i.push(w[1]),x=null,k?(x=k,k=null):(h=p.yyleng,l=p.yytext,c=p.yylineno,m=p.yylloc,d>0&&d--);break;case 2:if(K=this.productions_[w[1]][1],R.$=r[r.length-K],R._$={first_line:a[a.length-(K||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(K||1)].first_column,last_column:a[a.length-1].last_column},y&&(R._$.range=[a[a.length-(K||1)].range[0],a[a.length-1].range[1]]),void 0!==($=this.performAction.apply(R,[l,h,c,g,w[1],r,a].concat(u))))return $;K&&(i=i.slice(0,-1*K*2),r=r.slice(0,-1*K),a=a.slice(0,-1*K)),i.push(this.productions_[w[1]][0]),r.push(R.$),a.push(R._$),S=o[i[i.length-2]][i[i.length-1]],i.push(S);break;case 3:return!0}}return!0},"parse")};function d(){this.yy={}}return h.lexer={EOF:1,parseError:(0,s.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,s.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,s.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,s.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var n=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===n.length?this.yylloc.first_column:0)+n[n.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,s.K2)(function(){return this._more=!0,this},"more"),reject:(0,s.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,s.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,s.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,s.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,s.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,s.K2)(function(t,e){var i,n,r;if(this.options.backtrack_lexer&&(r={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&&(r.yylloc.range=this.yylloc.range.slice(0))),(n=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=n.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:n?n[n.length-1].length-n[n.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var a in r)this[a]=r[a];return!1},"test_match"),next:(0,s.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,n,r=this._currentRules(),a=0;a<r.length;a++)if((i=this._input.match(this.rules[r[a]]))&&(!e||i[0].length>e[0].length)){if(e=i,n=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,r[a])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,r[n]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,s.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,s.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,s.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,s.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,s.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,s.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,s.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,s.K2)(function(t,e,i,n){switch(i){case 0:case 1:case 3:case 4:break;case 2:return 13;case 5:return 8;case 6:return 9;case 7:return 7;case 8:return 14;case 9:return this.begin("acc_title"),15;case 10:return this.popState(),"acc_title_value";case 11:return this.begin("acc_descr"),17;case 12:return this.popState(),"acc_descr_value";case 13:this.begin("acc_descr_multiline");break;case 14:this.popState();break;case 15:return"acc_descr_multiline_value";case 16:return 20;case 17:return 24;case 18:return 23;case 19:return 6;case 20:return"INVALID"}},"anonymous"),rules:[/^(?:%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[\n]+)/i,/^(?:\s+)/i,/^(?:#[^\n]*)/i,/^(?:timeline[ \t]+LR\b)/i,/^(?:timeline[ \t]+TD\b)/i,/^(?:timeline\b)/i,/^(?:title\s[^\n]+)/i,/^(?:accTitle\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*:\s*)/i,/^(?:(?!\n||)*[^\n]*)/i,/^(?:accDescr\s*\{\s*)/i,/^(?:[\}])/i,/^(?:[^\}]*)/i,/^(?:section\s[^:\n]+)/i,/^(?::\s(?:[^:\n]|:(?!\s))+)/i,/^(?:[^#:\n]+)/i,/^(?:$)/i,/^(?:.)/i],conditions:{acc_descr_multiline:{rules:[14,15],inclusive:!1},acc_descr:{rules:[12],inclusive:!1},acc_title:{rules:[10],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,11,13,16,17,18,19,20],inclusive:!0}}},(0,s.K2)(d,"Parser"),d.prototype=h,h.Parser=d,new d}();d.parser=d;var u={};(0,s.VA)(u,{addEvent:()=>E,addSection:()=>$,addTask:()=>S,addTaskOrg:()=>R,clear:()=>k,default:()=>T,getCommonDb:()=>x,getDirection:()=>w,getSections:()=>v,getTasks:()=>K,setDirection:()=>_});var p="",g=0,f="LR",m=[],y=[],b=[],x=(0,s.K2)(()=>a.Wt,"getCommonDb"),k=(0,s.K2)(function(){m.length=0,y.length=0,p="",b.length=0,f="LR",(0,a.IU)()},"clear"),_=(0,s.K2)(function(t){f=t},"setDirection"),w=(0,s.K2)(function(){return f},"getDirection"),$=(0,s.K2)(function(t){p=t,m.push(t)},"addSection"),v=(0,s.K2)(function(){return m},"getSections"),K=(0,s.K2)(function(){let t=I(),e=0;for(;!t&&e<100;)t=I(),e++;return y.push(...b),y},"getTasks"),S=(0,s.K2)(function(t,e,i){let n={id:g++,section:p,type:p,task:t,score:e||0,events:i?[i]:[]};b.push(n)},"addTask"),E=(0,s.K2)(function(t){b.find(t=>t.id===g-1).events.push(t)},"addEvent"),R=(0,s.K2)(function(t){let e={section:p,type:p,description:t,task:t,classes:[]};y.push(e)},"addTaskOrg"),I=(0,s.K2)(function(){let t=(0,s.K2)(function(t){return b[t].processed},"compileTask"),e=!0;for(let[i,n]of b.entries())t(i),e=e&&n.processed;return e},"compileTasks"),T={clear:k,getCommonDb:x,getDirection:w,setDirection:_,addSection:$,getSections:v,getTasks:K,addTask:S,addTaskOrg:R,addEvent:E},M=0,L=(0,s.K2)(function(t,e){let i=t.append("rect");return i.attr("x",e.x),i.attr("y",e.y),i.attr("fill",e.fill),i.attr("stroke",e.stroke),i.attr("width",e.width),i.attr("height",e.height),i.attr("rx",e.rx),i.attr("ry",e.ry),void 0!==e.class&&i.attr("class",e.class),i},"drawRect"),H=(0,s.K2)(function(t,e){let i=t.append("circle").attr("cx",e.cx).attr("cy",e.cy).attr("class","face").attr("r",15).attr("stroke-width",2).attr("overflow","visible"),n=t.append("g");function r(t){let i=(0,o.JLW)().startAngle(Math.PI/2).endAngle(Math.PI/2*3).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",i).attr("transform","translate("+e.cx+","+(e.cy+2)+")")}function a(t){let i=(0,o.JLW)().startAngle(3*Math.PI/2).endAngle(Math.PI/2*5).innerRadius(7.5).outerRadius(15/2.2);t.append("path").attr("class","mouth").attr("d",i).attr("transform","translate("+e.cx+","+(e.cy+7)+")")}function l(t){t.append("line").attr("class","mouth").attr("stroke",2).attr("x1",e.cx-5).attr("y1",e.cy+7).attr("x2",e.cx+5).attr("y2",e.cy+7).attr("class","mouth").attr("stroke-width","1px").attr("stroke","#666")}return n.append("circle").attr("cx",e.cx-5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),n.append("circle").attr("cx",e.cx+5).attr("cy",e.cy-5).attr("r",1.5).attr("stroke-width",2).attr("fill","#666").attr("stroke","#666"),(0,s.K2)(r,"smile"),(0,s.K2)(a,"sad"),(0,s.K2)(l,"ambivalent"),e.score>3?r(n):e.score<3?a(n):l(n),i},"drawFace"),C=(0,s.K2)(function(t,e){let i=e.text.replace(/<br\s*\/?>/gi," "),n=t.append("text");n.attr("x",e.x),n.attr("y",e.y),n.attr("class","legend"),n.style("text-anchor",e.anchor),void 0!==e.class&&n.attr("class",e.class);let r=n.append("tspan");return r.attr("x",e.x+2*e.textMargin),r.text(i),n},"drawText"),N=-1,A=(0,s.K2)(function(){return{x:0,y:0,width:100,anchor:"start",height:100,rx:0,ry:0}},"getNoteRect"),D=function(){function t(t,e,i,r,a,s,o,l){n(e.append("text").attr("x",i+a/2).attr("y",r+s/2+5).style("font-color",l).style("text-anchor","middle").text(t),o)}function e(t,e,i,r,a,s,o,l,c){let{taskFontSize:h,taskFontFamily:d}=l,u=t.split(/<br\s*\/?>/gi);for(let t=0;t<u.length;t++){let l=t*h-h*(u.length-1)/2,p=e.append("text").attr("x",i+a/2).attr("y",r).attr("fill",c).style("text-anchor","middle").style("font-size",h).style("font-family",d);p.append("tspan").attr("x",i+a/2).attr("dy",l).text(u[t]),p.attr("y",r+s/2).attr("dominant-baseline","central").attr("alignment-baseline","central"),n(p,o)}}function i(t,i,r,a,s,o,l,c){let h=i.append("switch"),d=h.append("foreignObject").attr("x",r).attr("y",a).attr("width",s).attr("height",o).attr("position","fixed").append("xhtml:div").style("display","table").style("height","100%").style("width","100%");d.append("div").attr("class","label").style("display","table-cell").style("text-align","center").style("vertical-align","middle").text(t),e(t,h,r,a,s,o,l,c),n(d,l)}function n(t,e){for(let i in e)i in e&&t.attr(i,e[i])}return(0,s.K2)(t,"byText"),(0,s.K2)(e,"byTspan"),(0,s.K2)(i,"byFo"),(0,s.K2)(n,"_setTextAttrs"),function(n){return"fo"===n.textPlacement?i:"old"===n.textPlacement?t:e}}(),O=(0,s.K2)(function(t,e){M=0,N=-1,t.append("defs").append("marker").attr("id",e+"-arrowhead").attr("refX",5).attr("refY",2).attr("markerWidth",6).attr("markerHeight",4).attr("orient","auto").append("path").attr("d","M 0,0 V 4 L6,2 Z")},"initGraphics");function B(t,e){t.each(function(){var t,i=(0,o.Ltv)(this),n=i.text().split(/(\s+|<br>)/).reverse(),r=[],a=i.attr("y"),s=parseFloat(i.attr("dy")),l=i.text(null).append("tspan").attr("x",0).attr("y",a).attr("dy",s+"em");for(let s=0;s<n.length;s++)t=n[n.length-1-s],r.push(t),l.text(r.join(" ").trim()),(l.node().getComputedTextLength()>e||"<br>"===t)&&(r.pop(),l.text(r.join(" ").trim()),r="<br>"===t?[""]:[t],l=i.append("tspan").attr("x",0).attr("y",a).attr("dy","1.1em").text(t))})}(0,s.K2)(B,"wrap");var W=(0,s.K2)(function(t,e,i,n,r,a=!1){let{theme:s,look:l}=n,c=s?.includes("redux"),h=i%(n?.themeVariables?.THEME_COLOR_LIMIT??12)-1,d=t.append("g");e.section=h,d.attr("class",(e.class?e.class+" ":"")+"timeline-node section-"+h);let u=d.append("g"),p=d.append("g"),g=p.append("text").text(e.descr).attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle").call(B,e.width).node().getBBox(),f=n.fontSize?.replace?n.fontSize.replace("px",""):n.fontSize;if(e.height=g.height+1.1*f*.5+e.padding,e.height=Math.max(e.height,e.maxHeight),e.width=e.width+2*e.padding,p.attr("transform","translate("+e.width/2+", "+e.padding/2+")"),c&&p.attr("transform",`translate(${e.width/2}, ${a?e.padding/2+3:e.padding})`),z(u,e,h,r,n),"neo"===l&&(d.attr("data-look","neo"),c)){let e=s.includes("dark"),i=t.node()?.ownerSVGElement??t.node(),n=(0,o.Ltv)(i),r=n.attr("id")??"",a=r?`${r}-drop-shadow`:"drop-shadow";if(n.select(`#${a}`).empty()){let t=n.select("defs");(t.empty()?n.append("defs"):t).append("filter").attr("id",a).attr("height","130%").attr("width","130%").append("feDropShadow").attr("dx","4").attr("dy","4").attr("stdDeviation",0).attr("flood-opacity",e?"0.2":"0.06").attr("flood-color",e?"#FFFFFF":"#000000")}}return e},"drawNode"),P=(0,s.K2)(function(t,e,i){let n=t.append("g"),r=n.append("text").text(e.descr).attr("dy","1em").attr("alignment-baseline","middle").attr("dominant-baseline","middle").attr("text-anchor","middle").call(B,e.width).node().getBBox(),a=i.fontSize?.replace?i.fontSize.replace("px",""):i.fontSize;return n.remove(),r.height+1.1*a*.5+e.padding},"getVirtualNodeHeight"),z=(0,s.K2)(function(t,e,i,n,r){let{theme:a}=r,s=5*!a?.includes("redux"),o=s>0?`M0 ${e.height-5} v${-e.height+10} q0,-${s},${s},-${s} h${e.width-10} q${s},0,${s},${s} v${e.height-5} H0 Z`:`M0 ${e.height-5} v${-(e.height-5)} h${e.width} v${e.height} H0 Z`;t.append("path").attr("id",n+"-node-"+M++).attr("class","node-bkg node-"+e.type).attr("d",o),a?.includes("redux")||t.append("line").attr("class","node-line-"+i).attr("x1",0).attr("y1",e.height).attr("x2",e.width).attr("y2",e.height)},"defaultBkg"),j={initGraphics:O,drawNode:W,getVirtualNodeHeight:P},F=(0,s.K2)(function(t,e,i,n){let r,l=(0,a.D7)(),{look:c,theme:h,themeVariables:d}=l,{useGradient:u,gradientStart:p,gradientStop:g}=d,f=l.timeline?.leftMargin??50;s.Rm.debug("timeline",n.db);let m=l.securityLevel;"sandbox"===m&&(r=(0,o.Ltv)("#i"+e));let y=("sandbox"===m?(0,o.Ltv)(r.nodes()[0].contentDocument.body):(0,o.Ltv)("body")).select("#"+e);y.append("g");let b=n.db.getTasks(),x=n.db.getCommonDb().getDiagramTitle();s.Rm.debug("task",b),j.initGraphics(y,e);let k=n.db.getSections();s.Rm.debug("sections",k);let _=0,w=0,$=0,v=0,K=50+f,S=50;v=50;let E=0,R=!0;k.forEach(function(t){let e={number:E,descr:t,section:E,width:150,padding:20,maxHeight:_},i=j.getVirtualNodeHeight(y,e,l);s.Rm.debug("sectionHeight before draw",i),_=Math.max(_,i+20)});let I=0,T=0;for(let[t,e]of(s.Rm.debug("tasks.length",b.length),b.entries())){let i={number:t,descr:e,section:e.section,width:150,padding:20,maxHeight:w},n=j.getVirtualNodeHeight(y,i,l);s.Rm.debug("taskHeight before draw",n),w=Math.max(w,n+20),I=Math.max(I,e.events.length);let r=0;for(let t of e.events){let i={descr:t,section:e.section,number:e.section,width:150,padding:20,maxHeight:50};r+=j.getVirtualNodeHeight(y,i,l)}e.events.length>0&&(r+=(e.events.length-1)*10),T=Math.max(T,r)}s.Rm.debug("maxSectionHeight before draw",_),s.Rm.debug("maxTaskHeight before draw",w),k&&k.length>0?k.forEach(t=>{let i=b.filter(e=>e.section===t),n={number:E,descr:t,section:E,width:200*Math.max(i.length,1)-50,padding:20,maxHeight:_};s.Rm.debug("sectionNode",n);let r=y.append("g"),a=j.drawNode(r,n,E,l,e);s.Rm.debug("sectionNode output",a),r.attr("transform",`translate(${K}, ${v})`),S+=_+50,i.length>0&&V(y,i,E,K,S,w,l,I,T,_,!1,e),K+=200*Math.max(i.length,1),S=v,E++}):(R=!1,V(y,b,E,K,S,w,l,I,T,_,!0,e));let M=y.node().getBBox();if(s.Rm.debug("bounds",M),x&&y.append("text").text(x).attr("x","neo"===c?2*M.x+f:M.width/2-f).attr("font-size","4ex").attr("font-weight","bold").attr("y",20),$=R?_+w+150:w+100,y.append("g").attr("class","lineWrapper").append("line").attr("x1",f).attr("y1",$).attr("x2",M.width+3*f).attr("y2",$).attr("stroke-width",4).attr("stroke","black").attr("marker-end",`url(#${e}-arrowhead)`),"neo"===c&&u&&"neutral"!==h){let t=y.select("defs"),e=(t.empty()?y.append("defs"):t).append("linearGradient").attr("id",y.attr("id")+"-gradient").attr("gradientUnits","objectBoundingBox").attr("x1","0%").attr("y1","0%").attr("x2","100%").attr("y2","0%");e.append("stop").attr("offset","0%").attr("stop-color",p).attr("stop-opacity",1),e.append("stop").attr("offset","100%").attr("stop-color",g).attr("stop-opacity",1)}(0,a.ot)(void 0,y,l.timeline?.padding??50,l.timeline?.useMaxWidth??!1)},"draw"),V=(0,s.K2)(function(t,e,i,n,r,a,o,l,c,h,d,u){for(let l of e){let e={descr:l.task,section:i,number:i,width:150,padding:20,maxHeight:a};s.Rm.debug("taskNode",e);let h=t.append("g").attr("class","taskWrapper"),p=j.drawNode(h,e,i,o,u).height;if(s.Rm.debug("taskHeight after draw",p),h.attr("transform",`translate(${n}, ${r})`),a=Math.max(a,p),l.events){let e=t.append("g").attr("class","lineWrapper");r+=100,G(t,l.events,i,n,r,o,u),r-=100,e.append("line").attr("x1",n+95).attr("y1",r+a).attr("x2",n+95).attr("y2",r+a+100+c+100).attr("stroke-width",2).attr("stroke","black").attr("marker-end",`url(#${u}-arrowhead)`).attr("stroke-dasharray","5,5")}n+=200,d&&!o.timeline?.disableMulticolor&&i++}},"drawTasks"),G=(0,s.K2)(function(t,e,i,n,r,a,o){let l=0,c=r;for(let c of(r+=100,e)){let e={descr:c,section:i,number:i,width:150,padding:20,maxHeight:50};s.Rm.debug("eventNode",e);let h=t.append("g").attr("class","eventWrapper"),d=j.drawNode(h,e,i,a,o,!0).height;l+=d,h.attr("transform",`translate(${n}, ${r})`),r=r+10+d}return r=c,l},"drawEvents"),U={setConf:(0,s.K2)(()=>{},"setConf"),draw:F},Z=(0,s.K2)(function(t,e,i,o){let l=(0,a.D7)(),c=l.timeline?.leftMargin??50;s.Rm.debug("timeline",o.db);let h=(0,n.D)(e);h.append("g");let d=o.db.getTasks(),u=o.db.getCommonDb().getDiagramTitle();s.Rm.debug("task",d),j.initGraphics(h);let p=o.db.getSections();s.Rm.debug("sections",p);let g=0,f=0,m=50,y=230,b=0,x=p&&p.length>0,k=50+c+y,_=Math.max(50,y+360-10);p.forEach(function(t){let e={number:b,descr:t,section:b,width:_,padding:5,maxHeight:g},i=j.getVirtualNodeHeight(h,e,l);s.Rm.debug("sectionHeight before draw",i),g=Math.max(g,i)});let w=0;for(let[t,e]of(s.Rm.debug("tasks.length",d.length),d.entries())){let i={number:t,descr:e,section:e.section,width:200,padding:5,maxHeight:f},n=j.getVirtualNodeHeight(h,i,l);s.Rm.debug("taskHeight before draw",n),f=Math.max(f,n);let r=0;for(let t of e.events){let i={descr:t,section:e.section,number:e.section,width:300,padding:5,maxHeight:50};r+=j.getVirtualNodeHeight(h,i,l)}e.events.length>0&&(r+=(e.events.length-1)*10),w=Math.max(w,r)+0}s.Rm.debug("maxSectionHeight before draw",g),s.Rm.debug("maxTaskHeight before draw",f);let $=Math.max(f,w)+30;x?p.forEach(t=>{let e=d.filter(e=>e.section===t),i={number:b,descr:t,section:b,width:_,padding:5,maxHeight:g};s.Rm.debug("sectionNode",i);let n=h.append("g"),r=j.drawNode(n,i,b,l);s.Rm.debug("sectionNode output",r);let a=k-y;n.attr("transform",`translate(${a}, ${m})`);let o=m+r.height+20;e.length>0&&q(h,e,b,k,o,f,l,$,!1);let c=e.length,u=r.height+20+$*Math.max(c,1)-60*(c>0);m+=u,b++}):q(h,d,b,k,m,f,l,$,!0);let v=h.node()?.getBBox();if(!v)throw Error("bbox not found");if(s.Rm.debug("bounds",v),u){if(h.append("text").text(u).attr("x",v.width/2-c).attr("font-size","4ex").attr("font-weight","bold").attr("y",20),!(v=h.node()?.getBBox()))throw Error("bbox not found");s.Rm.debug("bounds after title",v)}let[K]=(0,r.I5)(l.fontSize),S=h.append("g").attr("class","lineWrapper");S.append("line").attr("x1",k).attr("y1",50-(K??16)*2).attr("x2",k).attr("y2",v.y+v.height+((K??16)*.5+20)).attr("stroke-width",4).attr("stroke","black").attr("marker-end","url(#arrowhead)"),S.lower(),(0,a.ot)(void 0,h,l.timeline?.padding??50,l.timeline?.useMaxWidth??!1)},"draw"),q=(0,s.K2)(function(t,e,i,n,r,a,o,l,c){for(let h of e){let e={descr:h.task,section:i,number:i,width:200,padding:5,maxHeight:a};s.Rm.debug("taskNode",e);let d=t.append("g").attr("class","taskWrapper"),u=j.drawNode(d,e,i,o),p=u.height;s.Rm.debug("taskHeight after draw",p);let g=n-20-u.width;if(d.attr("transform",`translate(${g}, ${r})`),a=Math.max(a,p),h.events&&h.events.length>0){let e=r,a=n+50;J(t,h.events,i,n,a,e,o)}r+=l,c&&!o.timeline?.disableMulticolor&&i++}},"drawTasks"),J=(0,s.K2)(function(t,e,i,n,r,a,o){let l=a;for(let a of e){let e={descr:a,section:i,number:i,width:300,padding:5,maxHeight:0};s.Rm.debug("eventNode",e);let c=t.append("g").attr("class","eventWrapper"),h=j.drawNode(c,e,i,o).height;c.attr("transform",`translate(${r}, ${l})`);let d=t.append("g").attr("class","lineWrapper"),u=l+h/2;d.append("line").attr("x1",n).attr("y1",u).attr("x2",r).attr("y2",u).attr("stroke-width",2).attr("stroke","black").attr("marker-end","url(#arrowhead)").attr("stroke-dasharray","5,5"),l=l+h+10}return l-a},"drawEvents"),Y={setConf:(0,s.K2)(()=>{},"setConf"),draw:Z},X=(0,s.K2)(t=>{let{theme:e}=(0,a.zj)(),i=e?.includes("dark"),n=e?.includes("color"),r=t.svgId?.replace(/^#/,"")??"",s=r?`url(#${r}-drop-shadow)`:t.dropShadow??"none",o="";for(let e=0;e<t.THEME_COLOR_LIMIT;e++){let r=`${17-3*e}`,a=n?t.borderColorArray[e]:t.mainBkg,l=n?t.borderColorArray[e]:t.nodeBorder;o+=`
2
+ .section-${e-1} rect,
3
+ .section-${e-1} path,
4
+ .section-${e-1} circle {
5
+ fill: ${i&&n?t.mainBkg:a};
6
+ stroke: ${l};
7
+ stroke-width: ${t.strokeWidth};
8
+ filter: ${s};
9
+ }
10
+
11
+ .section-${e-1} text {
12
+ fill: ${t.nodeBorder};
13
+ font-weight: ${t.fontWeight}
14
+ }
15
+
16
+ .node-icon-${e-1} {
17
+ font-size: 40px;
18
+ color: ${t["cScaleLabel"+e]};
19
+ }
20
+
21
+ .section-edge-${e-1} {
22
+ stroke: ${t["cScale"+e]};
23
+ }
24
+
25
+ .edge-depth-${e-1} {
26
+ stroke-width: ${r};
27
+ }
28
+
29
+ .section-${e-1} line {
30
+ stroke: ${t["cScaleInv"+e]};
31
+ stroke-width: 3;
32
+ }
33
+
34
+ .lineWrapper line {
35
+ stroke: ${t.nodeBorder};
36
+ stroke-width:${t.strokeWidth}
37
+ }
38
+
39
+ .disabled,
40
+ .disabled circle,
41
+ .disabled text {
42
+ fill: ${t.tertiaryColor??"lightgray"};
43
+ }
44
+
45
+ .disabled text {
46
+ fill: ${t.clusterBorder??"#efefef"};
47
+ }
48
+ `}return o},"genReduxSections"),Q=(0,s.K2)(t=>{let e="";for(let e=0;e<t.THEME_COLOR_LIMIT;e++)t["lineColor"+e]=t["lineColor"+e]||t["cScaleInv"+e],(0,l.A)(t["lineColor"+e])?t["lineColor"+e]=(0,c.A)(t["lineColor"+e],20):t["lineColor"+e]=(0,h.A)(t["lineColor"+e],20);for(let i=0;i<t.THEME_COLOR_LIMIT;i++){let n=""+(17-3*i);e+=`
49
+ .section-${i-1} rect, .section-${i-1} path, .section-${i-1} circle, .section-${i-1} path {
50
+ fill: ${t["cScale"+i]};
51
+ }
52
+ .section-${i-1} text {
53
+ fill: ${t["cScaleLabel"+i]};
54
+ }
55
+ .node-icon-${i-1} {
56
+ font-size: 40px;
57
+ color: ${t["cScaleLabel"+i]};
58
+ }
59
+ .section-edge-${i-1}{
60
+ stroke: ${t["cScale"+i]};
61
+ }
62
+ .edge-depth-${i-1}{
63
+ stroke-width: ${n};
64
+ }
65
+ .section-${i-1} line {
66
+ stroke: ${t["cScaleInv"+i]} ;
67
+ stroke-width: 3;
68
+ }
69
+
70
+ .lineWrapper line{
71
+ stroke: ${t["cScaleLabel"+i]} ;
72
+ }
73
+
74
+ .disabled, .disabled circle, .disabled text {
75
+ fill: ${t.tertiaryColor??"lightgray"};
76
+ }
77
+ .disabled text {
78
+ fill: ${t.clusterBorder??"#efefef"};
79
+ }
80
+ `}return e},"genSections"),tt=(0,s.K2)(t=>{let{theme:e}=(0,a.zj)(),i=e?.includes("redux"),n="neutral"===e,r=t.svgId?.replace(/^#/,"")??"",s="";if(t.useGradient&&r&&t.THEME_COLOR_LIMIT&&!n)for(let e=0;e<t.THEME_COLOR_LIMIT;e++)s+=`
81
+ .section-${e-1}[data-look="neo"] rect,
82
+ .section-${e-1}[data-look="neo"] path,
83
+ .section-${e-1}[data-look="neo"] circle {
84
+ fill: ${t.mainBkg};
85
+ stroke: url(#${r}-gradient);
86
+ stroke-width: 2;
87
+ }
88
+ .section-${e-1}[data-look="neo"] line {
89
+ stroke: url(#${r}-gradient);
90
+ stroke-width: 2;
91
+ }`;return`
92
+ .edge {
93
+ stroke-width: 3;
94
+ }
95
+ ${i?X(t):Q(t)}
96
+ ${s}
97
+ .section-root rect, .section-root path, .section-root circle {
98
+ fill: ${t.git0};
99
+ }
100
+ .section-root text {
101
+ fill: ${t.gitBranchLabel0};
102
+ }
103
+ .icon-container {
104
+ height:100%;
105
+ display: flex;
106
+ justify-content: center;
107
+ align-items: center;
108
+ }
109
+ .edge {
110
+ fill: none;
111
+ }
112
+ .eventWrapper {
113
+ filter: brightness(120%);
114
+ }
115
+ `},"getStyles"),te={db:u,renderer:{setConf:(0,s.K2)(()=>{},"setConf"),draw:(0,s.K2)((t,e,i,n)=>"TD"===(n?.db?.getDirection?.()??"LR")?Y.draw(t,e,i,n):U.draw(t,e,i,n),"draw")},parser:d,styles:tt}}}]);
_next/static/chunks/7286.a9914678c7734135.js ADDED
@@ -0,0 +1,34 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7286],{7286:(t,e,n)=>{n.d(e,{diagram:()=>te});var i=n(669),r=n(316),s=n(5508);function o(t,e){let n;if(void 0===e)for(let e of t)null!=e&&(n>e||void 0===n&&e>=e)&&(n=e);else{let i=-1;for(let r of t)null!=(r=e(r,++i,t))&&(n>r||void 0===n&&r>=r)&&(n=r)}return n}function l(t){return t.target.depth}function a(t,e){return t.sourceLinks.length?t.depth:e-1}function h(t,e){let n=0;if(void 0===e)for(let e of t)(e*=1)&&(n+=e);else{let i=-1;for(let r of t)(r=+e(r,++i,t))&&(n+=r)}return n}function c(t,e){let n;if(void 0===e)for(let e of t)null!=e&&(n<e||void 0===n&&e>=e)&&(n=e);else{let i=-1;for(let r of t)null!=(r=e(r,++i,t))&&(n<r||void 0===n&&r>=r)&&(n=r)}return n}function u(t){return function(){return t}}function f(t,e){return d(t.source,e.source)||t.index-e.index}function y(t,e){return d(t.target,e.target)||t.index-e.index}function d(t,e){return t.y0-e.y0}function p(t){return t.value}function g(t){return t.index}function _(t){return t.nodes}function x(t){return t.links}function k(t,e){let n=t.get(e);if(!n)throw Error("missing: "+e);return n}function m({nodes:t}){for(let e of t){let t=e.y0,n=t;for(let n of e.sourceLinks)n.y0=t+n.width/2,t+=n.width;for(let t of e.targetLinks)t.y1=n+t.width/2,n+=t.width}}var b=Math.PI,v=2*b,S=v-1e-6;function E(){this._x0=this._y0=this._x1=this._y1=null,this._=""}function w(){return new E}E.prototype=w.prototype={constructor:E,moveTo:function(t,e){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)},closePath:function(){null!==this._x1&&(this._x1=this._x0,this._y1=this._y0,this._+="Z")},lineTo:function(t,e){this._+="L"+(this._x1=+t)+","+(this._y1=+e)},quadraticCurveTo:function(t,e,n,i){this._+="Q"+ +t+","+ +e+","+(this._x1=+n)+","+(this._y1=+i)},bezierCurveTo:function(t,e,n,i,r,s){this._+="C"+ +t+","+ +e+","+ +n+","+ +i+","+(this._x1=+r)+","+(this._y1=+s)},arcTo:function(t,e,n,i,r){t*=1,e*=1,n*=1,i*=1,r*=1;var s=this._x1,o=this._y1,l=n-t,a=i-e,h=s-t,c=o-e,u=h*h+c*c;if(r<0)throw Error("negative radius: "+r);if(null===this._x1)this._+="M"+(this._x1=t)+","+(this._y1=e);else if(u>1e-6)if(Math.abs(c*l-a*h)>1e-6&&r){var f=n-s,y=i-o,d=l*l+a*a,p=Math.sqrt(d),g=Math.sqrt(u),_=r*Math.tan((b-Math.acos((d+u-(f*f+y*y))/(2*p*g)))/2),x=_/g,k=_/p;Math.abs(x-1)>1e-6&&(this._+="L"+(t+x*h)+","+(e+x*c)),this._+="A"+r+","+r+",0,0,"+ +(c*f>h*y)+","+(this._x1=t+k*l)+","+(this._y1=e+k*a)}else this._+="L"+(this._x1=t)+","+(this._y1=e)},arc:function(t,e,n,i,r,s){t*=1,e*=1,n*=1,s=!!s;var o=n*Math.cos(i),l=n*Math.sin(i),a=t+o,h=e+l,c=1^s,u=s?i-r:r-i;if(n<0)throw Error("negative radius: "+n);null===this._x1?this._+="M"+a+","+h:(Math.abs(this._x1-a)>1e-6||Math.abs(this._y1-h)>1e-6)&&(this._+="L"+a+","+h),n&&(u<0&&(u=u%v+v),u>S?this._+="A"+n+","+n+",0,1,"+c+","+(t-o)+","+(e-l)+"A"+n+","+n+",0,1,"+c+","+(this._x1=a)+","+(this._y1=h):u>1e-6&&(this._+="A"+n+","+n+",0,"+ +(u>=b)+","+c+","+(this._x1=t+n*Math.cos(r))+","+(this._y1=e+n*Math.sin(r))))},rect:function(t,e,n,i){this._+="M"+(this._x0=this._x1=+t)+","+(this._y0=this._y1=+e)+"h"+ +n+"v"+ +i+"h"+-n+"Z"},toString:function(){return this._}};var K=Array.prototype.slice;function L(t){return function(){return t}}function A(t){return t[0]}function M(t){return t[1]}function I(t){return t.source}function T(t){return t.target}function N(t,e,n,i,r){t.moveTo(e,n),t.bezierCurveTo(e=(e+i)/2,n,e,r,i,r)}function P(t){return[t.source.x1,t.y0]}function C(t){return[t.target.x0,t.y1]}var $=function(){var t=(0,r.K2)(function(t,e,n,i){for(n=n||{},i=t.length;i--;n[t[i]]=e);return n},"o"),e=[1,9],n=[1,10],i=[1,5,10,12],s={trace:(0,r.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,SANKEY:4,NEWLINE:5,csv:6,opt_eof:7,record:8,csv_tail:9,EOF:10,"field[source]":11,COMMA:12,"field[target]":13,"field[value]":14,field:15,escaped:16,non_escaped:17,DQUOTE:18,ESCAPED_TEXT:19,NON_ESCAPED_TEXT:20,$accept:0,$end:1},terminals_:{2:"error",4:"SANKEY",5:"NEWLINE",10:"EOF",11:"field[source]",12:"COMMA",13:"field[target]",14:"field[value]",18:"DQUOTE",19:"ESCAPED_TEXT",20:"NON_ESCAPED_TEXT"},productions_:[0,[3,4],[6,2],[9,2],[9,0],[7,1],[7,0],[8,5],[15,1],[15,1],[16,3],[17,1]],performAction:(0,r.K2)(function(t,e,n,i,r,s,o){var l=s.length-1;switch(r){case 7:let a=i.findOrCreateNode(s[l-4].trim().replaceAll('""','"')),h=i.findOrCreateNode(s[l-2].trim().replaceAll('""','"')),c=parseFloat(s[l].trim());i.addLink(a,h,c);break;case 8:case 9:case 11:this.$=s[l];break;case 10:this.$=s[l-1]}},"anonymous"),table:[{3:1,4:[1,2]},{1:[3]},{5:[1,3]},{6:4,8:5,15:6,16:7,17:8,18:e,20:n},{1:[2,6],7:11,10:[1,12]},t(n,[2,4],{9:13,5:[1,14]}),{12:[1,15]},t(i,[2,8]),t(i,[2,9]),{19:[1,16]},t(i,[2,11]),{1:[2,1]},{1:[2,5]},t(n,[2,2]),{6:17,8:5,15:6,16:7,17:8,18:e,20:n},{15:18,16:7,17:8,18:e,20:n},{18:[1,19]},t(n,[2,3]),{12:[1,20]},t(i,[2,10]),{15:21,16:7,17:8,18:e,20:n},t([1,5,10],[2,7])],defaultActions:{11:[2,1],12:[2,5]},parseError:(0,r.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var n=Error(t);throw n.hash=e,n}},"parseError"),parse:(0,r.K2)(function(t){var e=this,n=[0],i=[],s=[null],o=[],l=this.table,a="",h=0,c=0,u=0,f=o.slice.call(arguments,1),y=Object.create(this.lexer),d={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(d[p]=this.yy[p]);y.setInput(t,d),d.lexer=y,d.parser=this,void 0===y.yylloc&&(y.yylloc={});var g=y.yylloc;o.push(g);var _=y.options&&y.options.ranges;function x(){var t;return"number"!=typeof(t=i.pop()||y.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof d.parseError?this.parseError=d.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.K2)(function(t){n.length=n.length-2*t,s.length=s.length-t,o.length=o.length-t},"popStack"),(0,r.K2)(x,"lex");for(var k,m,b,v,S,E,w,K,L,A={};;){if(b=n[n.length-1],this.defaultActions[b]?v=this.defaultActions[b]:(null==k&&(k=x()),v=l[b]&&l[b][k]),void 0===v||!v.length||!v[0]){var M="";for(E in L=[],l[b])this.terminals_[E]&&E>2&&L.push("'"+this.terminals_[E]+"'");M=y.showPosition?"Parse error on line "+(h+1)+":\n"+y.showPosition()+"\nExpecting "+L.join(", ")+", got '"+(this.terminals_[k]||k)+"'":"Parse error on line "+(h+1)+": Unexpected "+(1==k?"end of input":"'"+(this.terminals_[k]||k)+"'"),this.parseError(M,{text:y.match,token:this.terminals_[k]||k,line:y.yylineno,loc:g,expected:L})}if(v[0]instanceof Array&&v.length>1)throw Error("Parse Error: multiple actions possible at state: "+b+", token: "+k);switch(v[0]){case 1:n.push(k),s.push(y.yytext),o.push(y.yylloc),n.push(v[1]),k=null,m?(k=m,m=null):(c=y.yyleng,a=y.yytext,h=y.yylineno,g=y.yylloc,u>0&&u--);break;case 2:if(w=this.productions_[v[1]][1],A.$=s[s.length-w],A._$={first_line:o[o.length-(w||1)].first_line,last_line:o[o.length-1].last_line,first_column:o[o.length-(w||1)].first_column,last_column:o[o.length-1].last_column},_&&(A._$.range=[o[o.length-(w||1)].range[0],o[o.length-1].range[1]]),void 0!==(S=this.performAction.apply(A,[a,c,h,d,v[1],s,o].concat(f))))return S;w&&(n=n.slice(0,-1*w*2),s=s.slice(0,-1*w),o=o.slice(0,-1*w)),n.push(this.productions_[v[1]][0]),s.push(A.$),o.push(A._$),K=l[n[n.length-2]][n[n.length-1]],n.push(K);break;case 3:return!0}}return!0},"parse")};function o(){this.yy={}}return s.lexer={EOF:1,parseError:(0,r.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,r.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,r.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,r.K2)(function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===i.length?this.yylloc.first_column:0)+i[i.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,r.K2)(function(){return this._more=!0,this},"more"),reject:(0,r.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,r.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,r.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,r.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,r.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,r.K2)(function(t,e){var n,i,r;if(this.options.backtrack_lexer&&(r={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&&(r.yylloc.range=this.yylloc.range.slice(0))),(i=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack)for(var s in r)this[s]=r[s];return!1},"test_match"),next:(0,r.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,n,i,r=this._currentRules(),s=0;s<r.length;s++)if((n=this._input.match(this.rules[r[s]]))&&(!e||n[0].length>e[0].length)){if(e=n,i=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,r[s])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,r[i]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,r.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,r.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,r.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,r.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,r.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,r.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,r.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.K2)(function(t,e,n,i){switch(n){case 0:case 1:return this.pushState("csv"),4;case 2:return 10;case 3:return 5;case 4:return 12;case 5:return this.pushState("escaped_text"),18;case 6:return 20;case 7:return this.popState("escaped_text"),18;case 8:return 19}},"anonymous"),rules:[/^(?:sankey-beta\b)/i,/^(?:sankey\b)/i,/^(?:$)/i,/^(?:((\u000D\u000A)|(\u000A)))/i,/^(?:(\u002C))/i,/^(?:(\u0022))/i,/^(?:([\u0020-\u0021\u0023-\u002B\u002D-\u007E])*)/i,/^(?:(\u0022)(?!(\u0022)))/i,/^(?:(([\u0020-\u0021\u0023-\u002B\u002D-\u007E])|(\u002C)|(\u000D)|(\u000A)|(\u0022)(\u0022))*)/i],conditions:{csv:{rules:[2,3,4,5,6,7,8],inclusive:!1},escaped_text:{rules:[7,8],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8],inclusive:!0}}},(0,r.K2)(o,"Parser"),o.prototype=s,s.Parser=o,new o}();$.parser=$;var D=[],O=[],j=new Map,z=(0,r.K2)(()=>{D=[],O=[],j=new Map,(0,i.IU)()},"clear"),F=class{constructor(t,e,n=0){this.source=t,this.target=e,this.value=n}static{(0,r.K2)(this,"SankeyLink")}},U=(0,r.K2)((t,e,n)=>{D.push(new F(t,e,n))},"addLink"),W=class{constructor(t){this.ID=t}static{(0,r.K2)(this,"SankeyNode")}},V=(0,r.K2)(t=>{t=i.Y2.sanitizeText(t,(0,i.D7)());let e=j.get(t);return void 0===e&&(e=new W(t),j.set(t,e),O.push(e)),e},"findOrCreateNode"),G=(0,r.K2)(()=>O,"getNodes"),X=(0,r.K2)(()=>D,"getLinks"),Y=(0,r.K2)(()=>({nodes:O.map(t=>({id:t.ID})),links:D.map(t=>({source:t.source.ID,target:t.target.ID,value:t.value}))}),"getGraph"),q={nodesMap:j,getConfig:(0,r.K2)(()=>(0,i.D7)().sankey,"getConfig"),getNodes:G,getLinks:X,getGraph:Y,addLink:U,findOrCreateNode:V,getAccTitle:i.iN,setAccTitle:i.SV,getAccDescription:i.m7,setAccDescription:i.EI,getDiagramTitle:i.ab,setDiagramTitle:i.ke,clear:z},B=class t{static{(0,r.K2)(this,"Uid")}static{this.count=0}static next(e){return new t(e+ ++t.count)}constructor(t){this.id=t,this.href=`#${t}`}toString(){return"url("+this.href+")"}},Q={left:function(t){return t.depth},right:function(t,e){return e-1-t.height},center:function(t){return t.targetLinks.length?t.depth:t.sourceLinks.length?o(t.sourceLinks,l)-1:0},justify:a},R=(0,r.K2)(t=>{let e=0,n=0;for(let i of t){let t=i.value??0;t>e&&(e=t,n=i.layer??0)}return n},"findCentralNodeLayer"),Z=(0,r.K2)(function(t,e,n,l){let b,v,{securityLevel:S,sankey:E}=(0,i.D7)(),$=i.ME.sankey;"sandbox"===S&&(b=(0,s.Ltv)("#i"+e));let D="sandbox"===S?(0,s.Ltv)(b.nodes()[0].contentDocument.body):(0,s.Ltv)("body"),O="sandbox"===S?D.select(`[id="${e}"]`):(0,s.Ltv)(`[id="${e}"]`),j=E?.width??$.width,z=E?.height??$.width,F=E?.useMaxWidth??$.useMaxWidth,U=E?.nodeAlignment??$.nodeAlignment,W=E?.prefix??$.prefix,V=E?.suffix??$.suffix,G=E?.showValues??$.showValues,X=E?.nodeWidth??$.nodeWidth??10,Y=E?.nodePadding??$.nodePadding??12,q=E?.labelStyle??$.labelStyle??"legacy",Z=E?.nodeColors??{},H=l.db.getGraph(),J=Q[U];(function(){let t,e,n=0,i=0,r=1,s=1,l=24,b=8,v,S=g,E=a,w=_,K=x,L=6;function A(){let a={nodes:w.apply(null,arguments),links:K.apply(null,arguments)};return function({nodes:t,links:n}){for(let[e,n]of t.entries())n.index=e,n.sourceLinks=[],n.targetLinks=[];let i=new Map(t.map((e,n)=>[S(e,n,t),e]));for(let[t,e]of n.entries()){e.index=t;let{source:n,target:r}=e;"object"!=typeof n&&(n=e.source=k(i,n)),"object"!=typeof r&&(r=e.target=k(i,r)),n.sourceLinks.push(e),r.targetLinks.push(e)}if(null!=e)for(let{sourceLinks:n,targetLinks:i}of t)n.sort(e),i.sort(e)}(a),function({nodes:t}){for(let e of t)e.value=void 0===e.fixedValue?Math.max(h(e.sourceLinks,p),h(e.targetLinks,p)):e.fixedValue}(a),function({nodes:t}){let e=t.length,n=new Set(t),i=new Set,r=0;for(;n.size;){for(let t of n)for(let{target:e}of(t.depth=r,t.sourceLinks))i.add(e);if(++r>e)throw Error("circular link");n=i,i=new Set}}(a),function({nodes:t}){let e=t.length,n=new Set(t),i=new Set,r=0;for(;n.size;){for(let t of n)for(let{source:e}of(t.height=r,t.targetLinks))i.add(e);if(++r>e)throw Error("circular link");n=i,i=new Set}}(a),function(a){let u=function({nodes:e}){let i=c(e,t=>t.depth)+1,s=(r-n-l)/(i-1),o=Array(i);for(let t of e){let e=Math.max(0,Math.min(i-1,Math.floor(E.call(null,t,i))));t.layer=e,t.x0=n+e*s,t.x1=t.x0+l,o[e]?o[e].push(t):o[e]=[t]}if(t)for(let e of o)e.sort(t);return o}(a);v=Math.min(b,(s-i)/(c(u,t=>t.length)-1));let g=o(u,t=>(s-i-(t.length-1)*v)/h(t,p));for(let t of u){let n=i;for(let e of t)for(let t of(e.y0=n,e.y1=n+e.value*g,n=e.y1+v,e.sourceLinks))t.width=t.value*g;n=(s-n+v)/(t.length+1);for(let e=0;e<t.length;++e){let i=t[e];i.y0+=n*(e+1),i.y1+=n*(e+1)}var _=t;if(void 0===e)for(let{sourceLinks:t,targetLinks:e}of _)t.sort(y),e.sort(f)}for(let e=0;e<L;++e){let n=Math.pow(.99,e),i=Math.max(1-n,(e+1)/L);(function(e,n,i){for(let r=e.length,s=r-2;s>=0;--s){let r=e[s];for(let t of r){let e=0,i=0;for(let{target:n,value:r}of t.sourceLinks){let s=r*(n.layer-t.layer);e+=function(t,e){let n=e.y0-(e.targetLinks.length-1)*v/2;for(let{source:i,width:r}of e.targetLinks){if(i===t)break;n+=r+v}for(let{target:i,width:r}of t.sourceLinks){if(i===e)break;n-=r}return n}(t,n)*s,i+=s}if(!(i>0))continue;let r=(e/i-t.y0)*n;t.y0+=r,t.y1+=r,N(t)}void 0===t&&r.sort(d),M(r,i)}})(u,n,i),function(e,n,i){for(let r=1,s=e.length;r<s;++r){let s=e[r];for(let t of s){let e=0,i=0;for(let{source:n,value:r}of t.targetLinks){let s=r*(t.layer-n.layer);e+=function(t,e){let n=t.y0-(t.sourceLinks.length-1)*v/2;for(let{target:i,width:r}of t.sourceLinks){if(i===e)break;n+=r+v}for(let{source:i,width:r}of e.targetLinks){if(i===t)break;n-=r}return n}(n,t)*s,i+=s}if(!(i>0))continue;let r=(e/i-t.y0)*n;t.y0+=r,t.y1+=r,N(t)}void 0===t&&s.sort(d),M(s,i)}}(u,n,i)}}(a),m(a),a}function M(t,e){let n=t.length>>1,r=t[n];T(t,r.y0-v,n-1,e),I(t,r.y1+v,n+1,e),T(t,s,t.length-1,e),I(t,i,0,e)}function I(t,e,n,i){for(;n<t.length;++n){let r=t[n],s=(e-r.y0)*i;s>1e-6&&(r.y0+=s,r.y1+=s),e=r.y1+v}}function T(t,e,n,i){for(;n>=0;--n){let r=t[n],s=(r.y1-e)*i;s>1e-6&&(r.y0-=s,r.y1-=s),e=r.y0-v}}function N({sourceLinks:t,targetLinks:n}){if(void 0===e){for(let{source:{sourceLinks:t}}of n)t.sort(y);for(let{target:{targetLinks:e}}of t)e.sort(f)}}return A.update=function(t){return m(t),t},A.nodeId=function(t){return arguments.length?(S="function"==typeof t?t:u(t),A):S},A.nodeAlign=function(t){return arguments.length?(E="function"==typeof t?t:u(t),A):E},A.nodeSort=function(e){return arguments.length?(t=e,A):t},A.nodeWidth=function(t){return arguments.length?(l=+t,A):l},A.nodePadding=function(t){return arguments.length?(b=v=+t,A):b},A.nodes=function(t){return arguments.length?(w="function"==typeof t?t:u(t),A):w},A.links=function(t){return arguments.length?(K="function"==typeof t?t:u(t),A):K},A.linkSort=function(t){return arguments.length?(e=t,A):e},A.size=function(t){return arguments.length?(n=i=0,r=+t[0],s=+t[1],A):[r-n,s-i]},A.extent=function(t){return arguments.length?(n=+t[0][0],r=+t[1][0],i=+t[0][1],s=+t[1][1],A):[[n,i],[r,s]]},A.iterations=function(t){return arguments.length?(L=+t,A):L},A})().nodeId(t=>t.id).nodeWidth(X).nodePadding(Y+15*!!G).nodeAlign(J).extent([[0,0],[j,z]])(H);let tt=R(H.nodes),te=(0,s.UMr)(s.zt),tn=(0,r.K2)(t=>Z[t]??te(t),"getNodeColor");O.append("g").attr("class","nodes").selectAll(".node").data(H.nodes).join("g").attr("class","node").attr("id",t=>(t.uid=B.next("node-")).id).attr("transform",function(t){return"translate("+t.x0+","+t.y0+")"}).attr("x",t=>t.x0).attr("y",t=>t.y0).append("rect").attr("height",t=>t.y1-t.y0).attr("width",t=>t.x1-t.x0).attr("fill",t=>tn(t.id));let ti=(0,r.K2)(({id:t,value:e})=>G?`${t}
2
+ ${W}${Math.round(100*e)/100}${V}`:t,"getText"),tr=(0,r.K2)(t=>"outlined"===q?(t.layer??0)<tt?{x:t.x0-6,anchor:"end"}:{x:t.x1+6,anchor:"start"}:t.x0<j/2?{x:t.x1+6,anchor:"start"}:{x:t.x0-6,anchor:"end"},"getLabelPosition"),ts=O.append("g").attr("class","node-labels").attr("font-size",14),to=(0,r.K2)(t=>ts.selectAll(t?`.${t}`:"text").data(H.nodes).join("text").attr("class",t??null).attr("x",t=>tr(t).x).attr("y",t=>(t.y1+t.y0)/2).attr("dy",`${G?"0":"0.35"}em`).attr("text-anchor",t=>tr(t).anchor).text(ti),"appendLabel");"outlined"===q?(to("sankey-label-bg"),to("sankey-label-fg")):to();let tl=O.append("g").attr("class","links").attr("fill","none").attr("stroke-opacity",.5).selectAll(".link").data(H.links).join("g").attr("class","link").style("mix-blend-mode","multiply"),ta=E?.linkColor??"gradient";if("gradient"===ta){let t=tl.append("linearGradient").attr("id",t=>(t.uid=B.next("linearGradient-")).id).attr("gradientUnits","userSpaceOnUse").attr("x1",t=>t.source.x1).attr("x2",t=>t.target.x0);t.append("stop").attr("offset","0%").attr("stop-color",t=>tn(t.source.id)),t.append("stop").attr("offset","100%").attr("stop-color",t=>tn(t.target.id))}switch(ta){case"gradient":v=(0,r.K2)(t=>t.uid,"coloring");break;case"source":v=(0,r.K2)(t=>tn(t.source.id),"coloring");break;case"target":v=(0,r.K2)(t=>tn(t.target.id),"coloring");break;default:v=ta}tl.append("path").attr("d",(function(t){var e=I,n=T,i=A,r=M,s=null;function o(){var o,l=K.call(arguments),a=e.apply(this,l),h=n.apply(this,l);if(s||(s=o=w()),t(s,+i.apply(this,(l[0]=a,l)),+r.apply(this,l),+i.apply(this,(l[0]=h,l)),+r.apply(this,l)),o)return s=null,o+""||null}return o.source=function(t){return arguments.length?(e=t,o):e},o.target=function(t){return arguments.length?(n=t,o):n},o.x=function(t){return arguments.length?(i="function"==typeof t?t:L(+t),o):i},o.y=function(t){return arguments.length?(r="function"==typeof t?t:L(+t),o):r},o.context=function(t){return arguments.length?(s=null==t?null:t,o):s},o})(N).source(P).target(C)).attr("stroke",v).attr("stroke-width",t=>Math.max(1,t.width)),(0,i.ot)(void 0,O,0,F)},"draw"),H=(0,r.K2)(t=>t.replaceAll(/^[^\S\n\r]+|[^\S\n\r]+$/g,"").replaceAll(/([\n\r])+/g,"\n").trim(),"prepareTextForParsing"),J=(0,r.K2)(t=>`.label {
3
+ font-family: ${t.fontFamily};
4
+ }
5
+
6
+ .node-labels {
7
+ font-family: ${t.fontFamily};
8
+ }
9
+
10
+ /* Outlined label style - background stroke for better readability */
11
+ .sankey-label-bg {
12
+ stroke: ${t.mainBkg||t.background||"#fff"};
13
+ stroke-width: 4px;
14
+ stroke-linejoin: round;
15
+ paint-order: stroke;
16
+ }
17
+
18
+ /* Foreground label text */
19
+ .sankey-label-fg {
20
+ fill: ${t.textColor};
21
+ }
22
+
23
+ /* Node styling */
24
+ .node rect {
25
+ shape-rendering: crispEdges;
26
+ }
27
+
28
+ /* Link styling */
29
+ .link {
30
+ fill: none;
31
+ stroke-opacity: 0.5;
32
+ mix-blend-mode: multiply;
33
+ }
34
+ `,"getStyles"),tt=$.parse.bind($);$.parse=t=>tt(H(t));var te={styles:J,parser:$,db:q,renderer:{draw:Z}}}}]);
_next/static/chunks/7378.06f6c0e4bb90b63a.js ADDED
@@ -0,0 +1,24 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7378],{7378:(t,e,a)=>{a.d(e,{diagram:()=>u});var r=a(2667),i=a(7566),l=a(3736),o=a(669),s=a(316),c=a(4290),n=o.UI.packet,d=class{constructor(){this.packet=[],this.setAccTitle=o.SV,this.getAccTitle=o.iN,this.setDiagramTitle=o.ke,this.getDiagramTitle=o.ab,this.getAccDescription=o.m7,this.setAccDescription=o.EI}static{(0,s.K2)(this,"PacketDB")}getConfig(){let t=(0,l.$t)({...n,...(0,o.zj)().packet});return t.showBits&&(t.paddingY+=10),t}getPacket(){return this.packet}pushWord(t){t.length>0&&this.packet.push(t)}clear(){(0,o.IU)(),this.packet=[]}},k=(0,s.K2)((t,e)=>{(0,i.S)(t,e);let a=-1,r=[],l=1,{bitsPerRow:o}=e.getConfig();for(let{start:i,end:c,bits:n,label:d}of t.blocks){if(void 0!==i&&void 0!==c&&c<i)throw Error(`Packet block ${i} - ${c} is invalid. End must be greater than start.`);if((i??=a+1)!==a+1)throw Error(`Packet block ${i} - ${c??i} is not contiguous. It should start from ${a+1}.`);if(0===n)throw Error(`Packet block ${i} is invalid. Cannot have a zero bit field.`);for(c??=i+(n??1)-1,n??=c-i+1,a=c,s.Rm.debug(`Packet block ${i} - ${a} with label ${d}`);r.length<=o+1&&e.getPacket().length<1e4;){let[t,a]=p({start:i,end:c,bits:n,label:d},l,o);if(r.push(t),t.end+1===l*o&&(e.pushWord(r),r=[],l++),!a)break;({start:i,end:c,bits:n,label:d}=a)}}e.pushWord(r)},"populate"),p=(0,s.K2)((t,e,a)=>{if(void 0===t.start)throw Error("start should have been set during first phase");if(void 0===t.end)throw Error("end should have been set during first phase");if(t.start>t.end)throw Error(`Block start ${t.start} is greater than block end ${t.end}.`);if(t.end+1<=e*a)return[t,void 0];let r=e*a-1,i=e*a;return[{start:t.start,end:r,label:t.label,bits:r-t.start},{start:i,end:t.end,label:t.label,bits:t.end-i}]},"getNextFittingBlock"),h={parser:{yy:void 0},parse:(0,s.K2)(async t=>{let e=await (0,c.qg)("packet",t),a=h.parser?.yy;if(!(a instanceof d))throw Error("parser.parser?.yy was not a PacketDB. This is due to a bug within Mermaid, please report this issue at https://github.com/mermaid-js/mermaid/issues.");s.Rm.debug(e),k(e,a)},"parse")},b=(0,s.K2)((t,e,a,i)=>{let l=i.db,s=l.getConfig(),{rowHeight:c,paddingY:n,bitWidth:d,bitsPerRow:k}=s,p=l.getPacket(),h=l.getDiagramTitle(),b=c+n,g=b*(p.length+1)-(h?0:c),u=d*k+2,m=(0,r.D)(e);for(let[t,e]of(m.attr("viewBox",`0 0 ${u} ${g}`),(0,o.a$)(m,g,u,s.useMaxWidth),p.entries()))f(m,e,t,s);m.append("text").text(h).attr("x",u/2).attr("y",g-b/2).attr("dominant-baseline","middle").attr("text-anchor","middle").attr("class","packetTitle")},"draw"),f=(0,s.K2)((t,e,a,{rowHeight:r,paddingX:i,paddingY:l,bitWidth:o,bitsPerRow:s,showBits:c})=>{let n=t.append("g"),d=a*(r+l)+l;for(let t of e){let e=t.start%s*o+1,a=(t.end-t.start+1)*o-i;if(n.append("rect").attr("x",e).attr("y",d).attr("width",a).attr("height",r).attr("class","packetBlock"),n.append("text").attr("x",e+a/2).attr("y",d+r/2).attr("class","packetLabel").attr("dominant-baseline","middle").attr("text-anchor","middle").text(t.label),!c)continue;let l=t.end===t.start,k=d-2;n.append("text").attr("x",e+(l?a/2:0)).attr("y",k).attr("class","packetByte start").attr("dominant-baseline","auto").attr("text-anchor",l?"middle":"start").text(t.start),l||n.append("text").attr("x",e+a).attr("y",k).attr("class","packetByte end").attr("dominant-baseline","auto").attr("text-anchor","end").text(t.end)}},"drawWord"),g={byteFontSize:"10px",startByteColor:"black",endByteColor:"black",labelColor:"black",labelFontSize:"12px",titleColor:"black",titleFontSize:"14px",blockStrokeColor:"black",blockStrokeWidth:"1",blockFillColor:"#efefef"},u={parser:h,get db(){return new d},renderer:{draw:b},styles:(0,s.K2)(({packet:t}={})=>{let e=(0,l.$t)(g,t);return`
2
+ .packetByte {
3
+ font-size: ${e.byteFontSize};
4
+ }
5
+ .packetByte.start {
6
+ fill: ${e.startByteColor};
7
+ }
8
+ .packetByte.end {
9
+ fill: ${e.endByteColor};
10
+ }
11
+ .packetLabel {
12
+ fill: ${e.labelColor};
13
+ font-size: ${e.labelFontSize};
14
+ }
15
+ .packetTitle {
16
+ fill: ${e.titleColor};
17
+ font-size: ${e.titleFontSize};
18
+ }
19
+ .packetBlock {
20
+ stroke: ${e.blockStrokeColor};
21
+ stroke-width: ${e.blockStrokeWidth};
22
+ fill: ${e.blockFillColor};
23
+ }
24
+ `},"styles")}},7566:(t,e,a)=>{function r(t,e){t.accDescr&&e.setAccDescription?.(t.accDescr),t.accTitle&&e.setAccTitle?.(t.accTitle),t.title&&e.setDiagramTitle?.(t.title)}a.d(e,{S:()=>r}),(0,a(316).K2)(r,"populateCommonDb")}}]);
_next/static/chunks/73972abe.45f878fbba31a82b.js ADDED
The diff for this file is too large to render. See raw diff
 
_next/static/chunks/7423.e21816ef40efbfb4.js ADDED
@@ -0,0 +1,23 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7423],{7423:(t,e,n)=>{n.d(e,{diagram:()=>tg});var s,i=n(2667),r=n(3736),l=n(669),a=n(316),o=n(5508),h=n(9258),c=n(5749);let u=(t,e)=>(0,c.A)(t,"a",-e);var f=n(7048),d=n(2118);function y(t,e){let n=function(t){let e=[];for(let n=0;n<t.length;++n)for(let s=n+1;s<t.length;++s)for(let i of m(t[n],t[s]))i.parentIndex=[n,s],e.push(i);return e}(t),s=n.filter(e=>{var n;return n=e,t.every(t=>g(n,t)<t.radius+1e-10)}),i=0,r=0,l=[];if(s.length>1){let e=b(s);for(let t=0;t<s.length;++t){let n=s[t];n.angle=Math.atan2(n.x-e.x,n.y-e.y)}s.sort((t,e)=>e.angle-t.angle);let n=s[s.length-1];for(let e=0;e<s.length;++e){let a=s[e];r+=(n.x+a.x)*(a.y-n.y);let o={x:(a.x+n.x)/2,y:(a.y+n.y)/2},h=null;for(let e=0;e<a.parentIndex.length;++e)if(n.parentIndex.includes(a.parentIndex[e])){let s=t[a.parentIndex[e]],i=Math.atan2(a.x-s.x,a.y-s.y),r=Math.atan2(n.x-s.x,n.y-s.y),l=r-i;l<0&&(l+=2*Math.PI);let c=r-l/2,u=g(o,{x:s.x+s.radius*Math.sin(c),y:s.y+s.radius*Math.cos(c)});u>2*s.radius&&(u=2*s.radius),(null==h||h.width>u)&&(h={circle:s,width:u,p1:a,p2:n,large:u>s.radius,sweep:!0})}null!=h&&(l.push(h),i+=x(h.circle.radius,h.width),n=a)}}else{let e=t[0];for(let n=1;n<t.length;++n)t[n].radius<e.radius&&(e=t[n]);let n=!1;for(let s=0;s<t.length;++s)if(g(t[s],e)>Math.abs(e.radius-t[s].radius)){n=!0;break}n?i=r=0:(i=e.radius*e.radius*Math.PI,l.push({circle:e,p1:{x:e.x,y:e.y+e.radius},p2:{x:e.x-1e-10,y:e.y+e.radius},width:2*e.radius,large:!0,sweep:!0}))}return r/=2,e&&(e.area=i+r,e.arcArea=i,e.polygonArea=r,e.arcs=l,e.innerPoints=s,e.intersectionPoints=n),i+r}function x(t,e){return t*t*Math.acos(1-e/t)-(t-e)*Math.sqrt(e*(2*t-e))}function g(t,e){return Math.sqrt((t.x-e.x)*(t.x-e.x)+(t.y-e.y)*(t.y-e.y))}function p(t,e,n){return n>=t+e?0:n<=Math.abs(t-e)?Math.PI*Math.min(t,e)*Math.min(t,e):x(t,t-(n*n-e*e+t*t)/(2*n))+x(e,e-(n*n-t*t+e*e)/(2*n))}function m(t,e){let n=g(t,e),s=t.radius,i=e.radius;if(n>=s+i||n<=Math.abs(s-i))return[];let r=(s*s-i*i+n*n)/(2*n),l=Math.sqrt(s*s-r*r),a=t.x+r*(e.x-t.x)/n,o=t.y+r*(e.y-t.y)/n,h=-(e.y-t.y)*(l/n),c=-(e.x-t.x)*(l/n);return[{x:a+h,y:o-c},{x:a-h,y:o+c}]}function b(t){let e={x:0,y:0};for(let n of t)e.x+=n.x,e.y+=n.y;return e.x/=t.length,e.y/=t.length,e}function v(t){let e=Array(t);for(let n=0;n<t;++n)e[n]=0;return e}function M(t,e){return v(t).map(()=>v(e))}function I(t,e){let n=0;for(let s=0;s<t.length;++s)n+=t[s]*e[s];return n}function k(t){return Math.sqrt(I(t,t))}function _(t,e,n){for(let s=0;s<e.length;++s)t[s]=e[s]*n}function w(t,e,n,s,i){for(let r=0;r<t.length;++r)t[r]=e*n[r]+s*i[r]}function E(t,e,n){let s,i=(n=n||{}).maxIterations||200*e.length,r=n.nonZeroDelta||1.05,l=n.zeroDelta||.001,a=n.minErrorDelta||1e-6,o=n.minErrorDelta||1e-5,h=void 0!==n.rho?n.rho:1,c=void 0!==n.chi?n.chi:2,u=void 0!==n.psi?n.psi:-.5,f=void 0!==n.sigma?n.sigma:.5,d=e.length,y=Array(d+1);y[0]=e,y[0].fx=t(e),y[0].id=0;for(let n=0;n<d;++n){let s=e.slice();s[n]=s[n]?s[n]*r:l,y[n+1]=s,y[n+1].fx=t(s),y[n+1].id=n+1}function x(t){for(let e=0;e<t.length;e++)y[d][e]=t[e];y[d].fx=t.fx}let g=(t,e)=>t.fx-e.fx,p=e.slice(),m=e.slice(),b=e.slice(),v=e.slice();for(let e=0;e<i;++e){if(y.sort(g),n.history){let t=y.map(t=>{let e=t.slice();return e.fx=t.fx,e.id=t.id,e});t.sort((t,e)=>t.id-e.id),n.history.push({x:y[0].slice(),fx:y[0].fx,simplex:t})}s=0;for(let t=0;t<d;++t)s=Math.max(s,Math.abs(y[0][t]-y[1][t]));if(Math.abs(y[0].fx-y[d].fx)<a&&s<o)break;for(let t=0;t<d;++t){p[t]=0;for(let e=0;e<d;++e)p[t]+=y[e][t];p[t]/=d}let e=y[d];if(w(m,1+h,p,-h,e),m.fx=t(m),m.fx<y[0].fx)w(v,1+c,p,-c,e),v.fx=t(v),x(v.fx<m.fx?v:m);else if(m.fx>=y[d-1].fx){let n=!1;if(m.fx>e.fx?(w(b,1+u,p,-u,e),b.fx=t(b),b.fx<e.fx?x(b):n=!0):(w(b,1-u*h,p,u*h,e),b.fx=t(b),b.fx<m.fx?x(b):n=!0),n){if(f>=1)break;for(let e=1;e<y.length;++e)w(y[e],1-f,y[0],f,y[e]),y[e].fx=t(y[e])}}else x(m)}return y.sort(g),{fx:y[0].fx,x:y[0]}}function S(t,e={}){e.maxIterations=e.maxIterations||500;let n=e.initialLayout||z,s=e.lossFunction||A,i=function(t,e={}){let n=e.distinct,s=t.map(t=>Object.assign({},t));function i(t){return t.join(";")}if(n){let t=new Map;for(let e of s)for(let n=0;n<e.sets.length;n++){let s=String(e.sets[n]);t.set(s,e.size+(t.get(s)||0));for(let i=n+1;i<e.sets.length;i++){let n=String(e.sets[i]),r=`${s};${n}`,l=`${n};${s}`;t.set(r,e.size+(t.get(r)||0)),t.set(l,e.size+(t.get(l)||0))}}for(let e of s)e.sets.length<3&&(e.size=t.get(i(e.sets)))}let r=[],l=new Set;for(let t of s)if(1===t.sets.length)r.push(t.sets[0]);else if(2===t.sets.length){let e=t.sets[0],n=t.sets[1];l.add(i(t.sets)),l.add(i([n,e]))}r.sort((t,e)=>t===e?0:t<e?-1:1);for(let t=0;t<r.length;++t){let e=r[t];for(let n=t+1;n<r.length;++n){let t=r[n];l.has(i([e,t]))||s.push({sets:[e,t],size:0})}}return s}(t,e),r=n(i,e),l=Object.keys(r),a=[];for(let t of l)a.push(r[t].x),a.push(r[t].y);let o=E(t=>{let e={};for(let n=0;n<l.length;++n){let s=l[n];e[s]={x:t[2*n],y:t[2*n+1],radius:r[s].radius}}return s(e,i)},a,e).x;for(let t=0;t<l.length;++t){let e=l[t];r[e].x=o[2*t],r[e].y=o[2*t+1]}return r}function T(t,e,n){return Math.min(t,e)*Math.min(t,e)*Math.PI<=n+1e-10?Math.abs(t-e):function(t,e,n,s){let i=(s=s||{}).maxIterations||100,r=s.tolerance||1e-10,l=t(e),a=t(n),o=n-e;if(l*a>0)throw"Initial bisect points must have opposite signs";if(0===l)return e;if(0===a)return n;for(let n=0;n<i;++n){let n=e+(o/=2),s=t(n);if(s*l>=0&&(e=n),Math.abs(o)<r||0===s)return n}return e+o}(s=>p(t,e,s)-n,0,t+e)}function z(t,e={}){let n=function(t,e){let n=e&&e.lossFunction?e.lossFunction:A,s={},i={};for(let e of t)if(1===e.sets.length){let t=e.sets[0];s[t]={x:1e10,y:1e10,rowid:s.length,size:e.size,radius:Math.sqrt(e.size/Math.PI)},i[t]=[]}for(let e of t=t.filter(t=>2===t.sets.length)){let t=null!=e.weight?e.weight:1,n=e.sets[0],r=e.sets[1];e.size+1e-10>=Math.min(s[n].size,s[r].size)&&(t=0),i[n].push({set:r,size:e.size,weight:t}),i[r].push({set:n,size:e.size,weight:t})}let r=[];function l(t,e){return e.size-t.size}Object.keys(i).forEach(t=>{let e=0;for(let n=0;n<i[t].length;++n)e+=i[t][n].size*i[t][n].weight;r.push({set:t,size:e})}),r.sort(l);let a={};function o(t){return t.set in a}function h(t,e){s[e].x=t.x,s[e].y=t.y,a[e]=!0}h({x:0,y:0},r[0].set);for(let e=1;e<r.length;++e){let a=r[e].set,u=i[a].filter(o),f=s[a];if(u.sort(l),0===u.length)throw"ERROR: missing pairwise overlap information";let d=[];for(var c=0;c<u.length;++c){let t=s[u[c].set],e=T(f.radius,t.radius,u[c].size);d.push({x:t.x+e,y:t.y}),d.push({x:t.x-e,y:t.y}),d.push({y:t.y+e,x:t.x}),d.push({y:t.y-e,x:t.x});for(let n=c+1;n<u.length;++n){let i=s[u[n].set],r=T(f.radius,i.radius,u[n].size),l=m({x:t.x,y:t.y,radius:e},{x:i.x,y:i.y,radius:r});d.push(...l)}}let y=1e50,x=d[0];for(let e of d){s[a].x=e.x,s[a].y=e.y;let i=n(s,t);i<y&&(y=i,x=e)}h(x,a)}return s}(t,e),s=e.lossFunction||A;if(t.length>=8){let i=function(t,e={}){let n=e.restarts||10,s=[],i={};for(let e of t)1===e.sets.length&&(i[e.sets[0]]=s.length,s.push(e));let{distances:r,constraints:l}=function(t,e,n){let s=M(e.length,e.length),i=M(e.length,e.length);return t.filter(t=>2===t.sets.length).forEach(t=>{let r=n[t.sets[0]],l=n[t.sets[1]],a=T(Math.sqrt(e[r].size/Math.PI),Math.sqrt(e[l].size/Math.PI),t.size);s[r][l]=s[l][r]=a;let o=0;t.size+1e-10>=Math.min(e[r].size,e[l].size)?o=1:t.size<=1e-10&&(o=-1),i[r][l]=i[l][r]=o}),{distances:s,constraints:i}}(t,s,i),a=k(r.map(k))/r.length;r=r.map(t=>t.map(t=>t/a));let o=(t,e)=>(function(t,e,n,s){for(let t=0;t<e.length;++t)e[t]=0;let i=0;for(let r=0;r<n.length;++r){let l=t[2*r],a=t[2*r+1];for(let o=r+1;o<n.length;++o){let h=t[2*o],c=t[2*o+1],u=n[r][o],f=s[r][o],d=(h-l)*(h-l)+(c-a)*(c-a),y=Math.sqrt(d),x=d-u*u;f>0&&y<=u||f<0&&y>=u||(i+=2*x*x,e[2*r]+=4*x*(l-h),e[2*r+1]+=4*x*(a-c),e[2*o]+=4*x*(h-l),e[2*o+1]+=4*x*(c-a))}}return i})(t,e,r,l),h=null;for(let t=0;t<n;++t){let t=function(t,e,n){let s,i,r,l={x:e.slice(),fx:0,fxprime:e.slice()},a={x:e.slice(),fx:0,fxprime:e.slice()},o=e.slice(),h=1;r=(n=n||{}).maxIterations||20*e.length,l.fx=t(l.x,l.fxprime),_(s=l.fxprime.slice(),l.fxprime,-1);for(let e=0;e<r;++e){if(h=function(t,e,n,s,i,r,l){let a=n.fx,o=I(n.fxprime,e),h=a,c=a,u=o,f=0;function d(c,f,d){for(let y=0;y<16;++y)if(i=(c+f)/2,w(s.x,1,n.x,i,e),h=s.fx=t(s.x,s.fxprime),u=I(s.fxprime,e),h>a+r*i*o||h>=d)f=i;else{if(Math.abs(u)<=-l*o)return i;u*(f-c)>=0&&(f=c),c=i,d=h}return 0}i=i||1,r=r||1e-6,l=l||.1;for(let y=0;y<10;++y){if(w(s.x,1,n.x,i,e),h=s.fx=t(s.x,s.fxprime),u=I(s.fxprime,e),h>a+r*i*o||y&&h>=c)return d(f,i,c);if(Math.abs(u)<=-l*o)break;if(u>=0)return d(i,f,h);c=h,f=i,i*=2}return i}(t,s,l,a,h),n.history&&n.history.push({x:l.x.slice(),fx:l.fx,fxprime:l.fxprime.slice(),alpha:h}),h){w(o,1,a.fxprime,-1,l.fxprime);let t=I(l.fxprime,l.fxprime);w(s,Math.max(0,I(o,a.fxprime)/t),s,-1,a.fxprime),i=l,l=a,a=i}else _(s,l.fxprime,-1);if(1e-5>=k(l.fxprime))break}return n.history&&n.history.push({x:l.x.slice(),fx:l.fx,fxprime:l.fxprime.slice(),alpha:h}),l}(o,v(2*r.length).map(Math.random),e);(!h||t.fx<h.fx)&&(h=t)}let c=h.x,u={};for(let t=0;t<s.length;++t){let e=s[t];u[e.sets[0]]={x:c[2*t]*a,y:c[2*t+1]*a,radius:Math.sqrt(e.size/Math.PI)}}if(e.history)for(let t of e.history)_(t.x,a);return u}(t,e);s(i,t)+1e-8<s(n,t)&&(n=i)}return n}function A(t,e){let n=0;for(let s of e){let e;if(1!==s.sets.length){if(2===s.sets.length){let n=t[s.sets[0]],i=t[s.sets[1]];e=p(n.radius,i.radius,g(n,i))}else e=y(s.sets.map(e=>t[e]));n+=(null!=s.weight?s.weight:1)*(e-s.size)*(e-s.size)}}return n}function K(t,e){let n=0;for(let s of e){let e;if(1===s.sets.length)continue;if(2===s.sets.length){let n=t[s.sets[0]],i=t[s.sets[1]];e=p(n.radius,i.radius,g(n,i))}else e=y(s.sets.map(e=>t[e]));let i=null!=s.weight?s.weight:1,r=Math.log((e+1)/(s.size+1));n+=i*r*r}return n}function R(t){let e=e=>({max:t.reduce((t,n)=>Math.max(t,n[e]+n.radius),-1/0),min:t.reduce((t,n)=>Math.min(t,n[e]-n.radius),1/0)});return{xRange:e("x"),yRange:e("y")}}function $(t,e,n){null==e&&(e=Math.PI/2);let s=C(t).map(t=>Object.assign({},t)),i=function(t){function e(t){return t.parent!==t&&(t.parent=e(t.parent)),t.parent}t.forEach(t=>{t.parent=t});for(let i=0;i<t.length;++i)for(let r=i+1;r<t.length;++r){var n,s;let l=t[i].radius+t[r].radius;g(t[i],t[r])+1e-10<l&&(n=t[r],s=t[i],e(n).parent=e(s))}let i=new Map;for(let n=0;n<t.length;++n){let s=e(t[n]).parent.setid;i.has(s)||i.set(s,[]),i.get(s).push(t[n])}return t.forEach(t=>{delete t.parent}),Array.from(i.values())}(s);for(let t of i){!function(t,e,n){if(null==n?t.sort((t,e)=>e.radius-t.radius):t.sort(n),t.length>0){let e=t[0].x,n=t[0].y;for(let s of t)s.x-=e,s.y-=n}if(2===t.length&&g(t[0],t[1])<Math.abs(t[1].radius-t[0].radius)&&(t[1].x=t[0].x+t[0].radius-t[1].radius-1e-10,t[1].y=t[0].y),t.length>1){let n=Math.atan2(t[1].x,t[1].y)-e,s=Math.cos(n),i=Math.sin(n);for(let e of t){let t=e.x,n=e.y;e.x=s*t-i*n,e.y=i*t+s*n}}if(t.length>2){let n=Math.atan2(t[2].x,t[2].y)-e;for(;n<0;)n+=2*Math.PI;for(;n>2*Math.PI;)n-=2*Math.PI;if(n>Math.PI){let e=t[1].y/(1e-10+t[1].x);for(let n of t){var s=(n.x+e*n.y)/(1+e*e);n.x=2*s-n.x,n.y=2*s*e-n.y}}}}(t,e,n);let s=R(t);t.size=(s.xRange.max-s.xRange.min)*(s.yRange.max-s.yRange.min),t.bounds=s}i.sort((t,e)=>e.size-t.size);let r=(s=i[0]).bounds,l=(r.xRange.max-r.xRange.min)/50;function a(t,e,n){let i,a;if(!t)return;let o=t.bounds;if(e)i=r.xRange.max-o.xRange.min+l;else{i=r.xRange.max-o.xRange.max;let t=(o.xRange.max-o.xRange.min)/2-(r.xRange.max-r.xRange.min)/2;t<0&&(i+=t)}if(n)a=r.yRange.max-o.yRange.min+l;else{a=r.yRange.max-o.yRange.max;let t=(o.yRange.max-o.yRange.min)/2-(r.yRange.max-r.yRange.min)/2;t<0&&(a+=t)}for(let e of t)e.x+=i,e.y+=a,s.push(e)}let o=1;for(;o<i.length;)a(i[o],!0,!1),a(i[o+1],!1,!0),a(i[o+2],!0,!0),o+=3,r=R(s);return O(s)}function N(t,e,n,s,i){let r,l,a=C(t);e-=2*s,n-=2*s;let{xRange:o,yRange:h}=R(a);if(o.max===o.min||h.max===h.min)return console.log("not scaling solution: zero size detected"),t;if(i){let t=2*Math.sqrt(i/Math.PI);r=e/t,l=n/t}else r=e/(o.max-o.min),l=n/(h.max-h.min);let c=Math.min(l,r),u=(e-(o.max-o.min)*c)/2,f=(n-(h.max-h.min)*c)/2;return O(a.map(t=>({radius:c*t.radius,x:s+u+(t.x-o.min)*c,y:s+f+(t.y-h.min)*c,setid:t.setid})))}function O(t){let e={};for(let n of t)e[n.setid]=n;return e}function C(t){return Object.keys(t).map(e=>Object.assign(t[e],{setid:e}))}function D(t,e){return function(n){let s=this,i=t[n.sets[0]].radius||50,r=e(n)||"",l=r.split(/\s+/).reverse(),a=(r.length+l.length)/3,o=l.pop(),h=[o],c=0;s.textContent=null;let u=[];function f(t){let e=s.ownerDocument.createElementNS(s.namespaceURI,"tspan");return e.textContent=t,u.push(e),s.append(e),e}let d=f(o);for(;o=l.pop();){h.push(o);let t=h.join(" ");d.textContent=t,t.length>a&&d.getComputedTextLength()>i&&(h.pop(),d.textContent=h.join(" "),h=[o],d=f(o),c++)}let y=.35-1.1*c/2,x=s.getAttribute("x"),g=s.getAttribute("y");u.forEach((t,e)=>{t.setAttribute("x",x),t.setAttribute("y",g),t.setAttribute("dy",`${y+1.1*e}em`)})}}function F(t,e,n){let s=e[0].radius-g(e[0],t);for(let n=1;n<e.length;++n){let i=e[n].radius-g(e[n],t);i<=s&&(s=i)}for(let e=0;e<n.length;++e){let i=g(n[e],t)-n[e].radius;i<=s&&(s=i)}return s}function L(t,e,n){let s={},i=function(t){let e={},n=Object.keys(t);for(let t of n)e[t]=[];for(let s=0;s<n.length;s++){let i=n[s],r=t[i];for(let l=s+1;l<n.length;++l){let s=n[l],a=t[s],o=g(r,a);o+a.radius<=r.radius+1e-10?e[s].push(i):o+r.radius<=a.radius+1e-10&&e[i].push(s)}}return e}(t);for(let r=0;r<e.length;++r){let l=e[r].sets,a={},o={};for(let t=0;t<l.length;++t){a[l[t]]=!0;let e=i[l[t]];for(let t=0;t<e.length;++t)o[e[t]]=!0}let h=[],c=[];for(let e in t)e in a?h.push(t[e]):e in o||c.push(t[e]);let u=function t(e,n,s){let i=[];for(let t of e)i.push({x:t.x,y:t.y}),i.push({x:t.x+t.radius/2,y:t.y}),i.push({x:t.x-t.radius/2,y:t.y}),i.push({x:t.x,y:t.y+t.radius/2}),i.push({x:t.x,y:t.y-t.radius/2});let r=i[0],l=F(i[0],e,n);for(let t=1;t<i.length;++t){let s=F(i[t],e,n);s>=l&&(r=i[t],l=s)}let a=E(t=>-1*F({x:t[0],y:t[1]},e,n),[r.x,r.y],{maxIterations:500,minErrorDelta:1e-10}).x,o={x:s?0:a[0],y:a[1]},h=!0;for(let t of e)if(g(o,t)>t.radius){h=!1;break}for(let t of n)if(g(o,t)<t.radius){h=!1;break}if(h)return o;if(1==e.length)return{x:e[0].x,y:e[0].y};let c={};return(y(e,c),0===c.arcs.length)?{x:0,y:-1e3,disjoint:!0}:1==c.arcs.length?{x:c.arcs[0].circle.x,y:c.arcs[0].circle.y}:n.length?t(e,[]):b(c.arcs.map(t=>t.p1))}(h,c,n);s[l]=u,u.disjoint&&e[r].size>0&&console.log("WARNING: area "+l+" not represented on screen")}return s}function j(t){if(0===t.length)return[];let e={};return y(t,e),e.arcs}function P(t,e){if(0===t.length)return"M 0 0";let n=Math.pow(10,e||0),s=null!=e?t=>Math.round(t*n)/n:t=>t;if(1==t.length){let e=t[0].circle;return function(t,e,n){let s=[];return s.push("\nM",t,e),s.push("\nm",-n,0),s.push("\na",n,n,0,1,0,2*n,0),s.push("\na",n,n,0,1,0,-(2*n),0),s.join(" ")}(s(e.x),s(e.y),s(e.radius))}let i=["\nM",s(t[0].p2.x),s(t[0].p2.y)];for(let e of t){let t=s(e.circle.radius);i.push("\nA",t,t,0,+!!e.large,+!!e.sweep,s(e.p1.x),s(e.p1.y))}return i.join(" ")}var U=n(2454),q=function(){var t=(0,a.K2)(function(t,e,n,s){for(n=n||{},s=t.length;s--;n[t[s]]=e);return n},"o"),e=[5,8],n=[7,8,11,12,17,19,22,24],s=[1,17],i=[1,18],r=[7,8,11,12,14,15,16,17,19,20,21,22,24,27],l=[1,31],o=[1,39],h=[7,8,11,12,17,19,22,24,27],c=[1,57],u=[1,56],f=[1,58],d=[1,59],y=[1,60],x=[7,8,11,12,16,17,19,20,22,24,27,31,32,33],g={trace:(0,a.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,optNewlines:4,VENN:5,document:6,EOF:7,NEWLINE:8,line:9,statement:10,TITLE:11,SET:12,identifier:13,BRACKET_LABEL:14,COLON:15,NUMERIC:16,UNION:17,identifierList:18,TEXT:19,IDENTIFIER:20,STRING:21,INDENT_TEXT:22,indentedTextTail:23,STYLE:24,stylesOpt:25,styleField:26,COMMA:27,styleValue:28,valueTokens:29,valueToken:30,HEXCOLOR:31,RGBCOLOR:32,RGBACOLOR:33,$accept:0,$end:1},terminals_:{2:"error",5:"VENN",7:"EOF",8:"NEWLINE",11:"TITLE",12:"SET",14:"BRACKET_LABEL",15:"COLON",16:"NUMERIC",17:"UNION",19:"TEXT",20:"IDENTIFIER",21:"STRING",22:"INDENT_TEXT",24:"STYLE",27:"COMMA",31:"HEXCOLOR",32:"RGBCOLOR",33:"RGBACOLOR"},productions_:[0,[3,4],[4,0],[4,2],[6,0],[6,2],[9,1],[9,1],[10,1],[10,2],[10,3],[10,4],[10,5],[10,2],[10,3],[10,4],[10,5],[10,3],[10,3],[10,3],[10,4],[10,4],[10,2],[10,3],[23,1],[23,1],[23,1],[23,2],[23,2],[25,1],[25,3],[26,3],[28,1],[28,1],[29,1],[29,2],[30,1],[30,1],[30,1],[30,1],[30,1],[18,1],[18,3],[13,1],[13,1]],performAction:(0,a.K2)(function(t,e,n,s,i,r,l){var a=r.length-1;switch(i){case 1:return r[a-1];case 2:case 3:case 4:case 6:this.$=[];break;case 5:case 35:r[a-1].push(r[a]),this.$=r[a-1];break;case 7:case 22:case 32:case 36:case 37:case 38:case 39:case 40:case 43:case 44:this.$=r[a];break;case 8:s.setDiagramTitle(r[a].substr(6)),this.$=r[a].substr(6);break;case 9:s.addSubsetData([r[a]],void 0,void 0),s.setIndentMode&&s.setIndentMode(!0);break;case 10:s.addSubsetData([r[a-1]],r[a],void 0),s.setIndentMode&&s.setIndentMode(!0);break;case 11:s.addSubsetData([r[a-2]],void 0,parseFloat(r[a])),s.setIndentMode&&s.setIndentMode(!0);break;case 12:s.addSubsetData([r[a-3]],r[a-2],parseFloat(r[a])),s.setIndentMode&&s.setIndentMode(!0);break;case 13:if(r[a].length<2)throw Error("union requires multiple identifiers");s.validateUnionIdentifiers&&s.validateUnionIdentifiers(r[a]),s.addSubsetData(r[a],void 0,void 0),s.setIndentMode&&s.setIndentMode(!0);break;case 14:if(r[a-1].length<2)throw Error("union requires multiple identifiers");s.validateUnionIdentifiers&&s.validateUnionIdentifiers(r[a-1]),s.addSubsetData(r[a-1],r[a],void 0),s.setIndentMode&&s.setIndentMode(!0);break;case 15:if(r[a-2].length<2)throw Error("union requires multiple identifiers");s.validateUnionIdentifiers&&s.validateUnionIdentifiers(r[a-2]),s.addSubsetData(r[a-2],void 0,parseFloat(r[a])),s.setIndentMode&&s.setIndentMode(!0);break;case 16:if(r[a-3].length<2)throw Error("union requires multiple identifiers");s.validateUnionIdentifiers&&s.validateUnionIdentifiers(r[a-3]),s.addSubsetData(r[a-3],r[a-2],parseFloat(r[a])),s.setIndentMode&&s.setIndentMode(!0);break;case 17:case 18:case 19:s.addTextData(r[a-1],r[a],void 0);break;case 20:case 21:s.addTextData(r[a-2],r[a-1],r[a]);break;case 23:s.addStyleData(r[a-1],r[a]);break;case 24:case 25:case 26:var o=s.getCurrentSets();if(!o)throw Error("text requires set");s.addTextData(o,r[a],void 0);break;case 27:case 28:var o=s.getCurrentSets();if(!o)throw Error("text requires set");s.addTextData(o,r[a-1],r[a]);break;case 29:case 41:case 34:this.$=[r[a]];break;case 30:case 42:this.$=[...r[a-2],r[a]];break;case 31:this.$=[r[a-2],r[a]];break;case 33:this.$=r[a].join(" ")}},"anonymous"),table:[t(e,[2,2],{3:1,4:2}),{1:[3]},{5:[1,3],8:[1,4]},t(n,[2,4],{6:5}),t(e,[2,3]),{7:[1,6],8:[1,8],9:7,10:9,11:[1,10],12:[1,11],17:[1,12],19:[1,13],22:[1,14],24:[1,15]},{1:[2,1]},t(n,[2,5]),t(n,[2,6]),t(n,[2,7]),t(n,[2,8]),{13:16,20:s,21:i},{13:20,18:19,20:s,21:i},{13:20,18:21,20:s,21:i},{16:[1,25],20:[1,23],21:[1,24],23:22},{13:20,18:26,20:s,21:i},t(n,[2,9],{14:[1,27],15:[1,28]}),t(r,[2,43]),t(r,[2,44]),t(n,[2,13],{14:[1,29],15:[1,30],27:l}),t(r,[2,41]),{16:[1,34],20:[1,32],21:[1,33],27:l},t(n,[2,22]),t(n,[2,24],{14:[1,35]}),t(n,[2,25],{14:[1,36]}),t(n,[2,26]),{20:o,25:37,26:38,27:l},t(n,[2,10],{15:[1,40]}),{16:[1,41]},t(n,[2,14],{15:[1,42]}),{16:[1,43]},{13:44,20:s,21:i},t(n,[2,17],{14:[1,45]}),t(n,[2,18],{14:[1,46]}),t(n,[2,19]),t(n,[2,27]),t(n,[2,28]),t(n,[2,23],{27:[1,47]}),t(h,[2,29]),{15:[1,48]},{16:[1,49]},t(n,[2,11]),{16:[1,50]},t(n,[2,15]),t(r,[2,42]),t(n,[2,20]),t(n,[2,21]),{20:o,26:51},{16:c,20:u,21:[1,53],28:52,29:54,30:55,31:f,32:d,33:y},t(n,[2,12]),t(n,[2,16]),t(h,[2,30]),t(h,[2,31]),t(h,[2,32]),t(h,[2,33],{30:61,16:c,20:u,31:f,32:d,33:y}),t(x,[2,34]),t(x,[2,36]),t(x,[2,37]),t(x,[2,38]),t(x,[2,39]),t(x,[2,40]),t(x,[2,35])],defaultActions:{6:[2,1]},parseError:(0,a.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var n=Error(t);throw n.hash=e,n}},"parseError"),parse:(0,a.K2)(function(t){var e=this,n=[0],s=[],i=[null],r=[],l=this.table,o="",h=0,c=0,u=0,f=r.slice.call(arguments,1),d=Object.create(this.lexer),y={};for(var x in this.yy)Object.prototype.hasOwnProperty.call(this.yy,x)&&(y[x]=this.yy[x]);d.setInput(t,y),y.lexer=d,y.parser=this,void 0===d.yylloc&&(d.yylloc={});var g=d.yylloc;r.push(g);var p=d.options&&d.options.ranges;function m(){var t;return"number"!=typeof(t=s.pop()||d.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof y.parseError?this.parseError=y.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,a.K2)(function(t){n.length=n.length-2*t,i.length=i.length-t,r.length=r.length-t},"popStack"),(0,a.K2)(m,"lex");for(var b,v,M,I,k,_,w,E,S,T={};;){if(M=n[n.length-1],this.defaultActions[M]?I=this.defaultActions[M]:(null==b&&(b=m()),I=l[M]&&l[M][b]),void 0===I||!I.length||!I[0]){var z="";for(_ in S=[],l[M])this.terminals_[_]&&_>2&&S.push("'"+this.terminals_[_]+"'");z=d.showPosition?"Parse error on line "+(h+1)+":\n"+d.showPosition()+"\nExpecting "+S.join(", ")+", got '"+(this.terminals_[b]||b)+"'":"Parse error on line "+(h+1)+": Unexpected "+(1==b?"end of input":"'"+(this.terminals_[b]||b)+"'"),this.parseError(z,{text:d.match,token:this.terminals_[b]||b,line:d.yylineno,loc:g,expected:S})}if(I[0]instanceof Array&&I.length>1)throw Error("Parse Error: multiple actions possible at state: "+M+", token: "+b);switch(I[0]){case 1:n.push(b),i.push(d.yytext),r.push(d.yylloc),n.push(I[1]),b=null,v?(b=v,v=null):(c=d.yyleng,o=d.yytext,h=d.yylineno,g=d.yylloc,u>0&&u--);break;case 2:if(w=this.productions_[I[1]][1],T.$=i[i.length-w],T._$={first_line:r[r.length-(w||1)].first_line,last_line:r[r.length-1].last_line,first_column:r[r.length-(w||1)].first_column,last_column:r[r.length-1].last_column},p&&(T._$.range=[r[r.length-(w||1)].range[0],r[r.length-1].range[1]]),void 0!==(k=this.performAction.apply(T,[o,c,h,y,I[1],i,r].concat(f))))return k;w&&(n=n.slice(0,-1*w*2),i=i.slice(0,-1*w),r=r.slice(0,-1*w)),n.push(this.productions_[I[1]][0]),i.push(T.$),r.push(T._$),E=l[n[n.length-2]][n[n.length-1]],n.push(E);break;case 3:return!0}}return!0},"parse")};function p(){this.yy={}}return g.lexer={EOF:1,parseError:(0,a.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,a.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,a.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,a.K2)(function(t){var e=t.length,n=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),n.length-1&&(this.yylineno-=n.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:n?(n.length===s.length?this.yylloc.first_column:0)+s[s.length-n.length].length-n[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,a.K2)(function(){return this._more=!0,this},"more"),reject:(0,a.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,a.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,a.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,a.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,a.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,a.K2)(function(t,e){var n,s,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],n=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),n)return n;if(this._backtrack)for(var r in i)this[r]=i[r];return!1},"test_match"),next:(0,a.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,n,s,i=this._currentRules(),r=0;r<i.length;r++)if((n=this._input.match(this.rules[i[r]]))&&(!e||n[0].length>e[0].length)){if(e=n,s=r,this.options.backtrack_lexer){if(!1!==(t=this.test_match(n,i[r])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,a.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,a.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,a.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,a.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,a.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,a.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,a.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,a.K2)(function(t,e,n,s){switch(n){case 0:case 1:case 2:case 4:case 7:case 8:break;case 3:if(t.getIndentMode&&t.getIndentMode())return t.consumeIndentText=!0,this.begin("INITIAL"),22;break;case 5:t.setIndentMode&&t.setIndentMode(!1),this.begin("INITIAL"),this.unput(e.yytext);break;case 6:return this.begin("bol"),8;case 9:return 7;case 10:return 11;case 11:return 5;case 12:return 12;case 13:return 17;case 14:if(!t.consumeIndentText)return 19;t.consumeIndentText=!1;break;case 15:return 24;case 16:return e.yytext=e.yytext.slice(2,-2),14;case 17:return e.yytext=e.yytext.slice(1,-1).trim(),14;case 18:return 16;case 19:return 31;case 20:return 33;case 21:return 32;case 22:return 20;case 23:return 21;case 24:return 27;case 25:return 15}},"anonymous"),rules:[/^(?:%%(?!\{)[^\n]*)/i,/^(?:[^\}]%%[^\n]*)/i,/^(?:[ \t]+(?=[\n\r]))/i,/^(?:[ \t]+(?=text\b))/i,/^(?:[ \t]+)/i,/^(?:[^ \t\n\r])/i,/^(?:[\n\r]+)/i,/^(?:%%[^\n]*)/i,/^(?:[ \t]+)/i,/^(?:$)/i,/^(?:title\s[^#\n;]+)/i,/^(?:venn-beta\b)/i,/^(?:set\b)/i,/^(?:union\b)/i,/^(?:text\b)/i,/^(?:style\b)/i,/^(?:\["[^\"]*"\])/i,/^(?:\[[^\]\"]+\])/i,/^(?:[+-]?(\d+(\.\d+)?|\.\d+))/i,/^(?:#[0-9a-fA-F]{3,8})/i,/^(?:rgba\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:rgb\(\s*[0-9.]+\s*[,]\s*[0-9.]+\s*[,]\s*[0-9.]+\s*\))/i,/^(?:[A-Za-z_][A-Za-z0-9\-_]*)/i,/^(?:"[^\"]*")/i,/^(?:,)/i,/^(?::)/i],conditions:{bol:{rules:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0},INITIAL:{rules:[0,1,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25],inclusive:!0}}},(0,a.K2)(p,"Parser"),p.prototype=g,g.Parser=p,new p}();q.parser=q;var B=[],G=[],W=[],V=new Set,X=!1,Y=(0,a.K2)((t,e,n)=>{let i=tn(t).sort(),r=n??10/Math.pow(t.length,2);s=i,1===i.length&&V.add(i[0]),B.push({sets:i,size:r,label:e?H(e):void 0})},"addSubsetData"),Z=(0,a.K2)(()=>B,"getSubsetData"),H=(0,a.K2)(t=>{let e=t.trim();return e.length>=2&&e.startsWith('"')&&e.endsWith('"')?e.slice(1,-1):e},"normalizeText"),J=(0,a.K2)(t=>t?H(t):t,"normalizeStyleValue"),Q=(0,a.K2)((t,e,n)=>{let s=H(e);G.push({sets:tn(t).sort(),id:s,label:n?H(n):void 0})},"addTextData"),tt=(0,a.K2)((t,e)=>{let n=tn(t).sort(),s={};for(let[t,n]of e)s[t]=J(n)??n;W.push({targets:n,styles:s})},"addStyleData"),te=(0,a.K2)(()=>W,"getStyleData"),tn=(0,a.K2)(t=>t.map(t=>H(t)),"normalizeIdentifierList"),ts=(0,a.K2)(t=>{let e=tn(t).filter(t=>!V.has(t));if(e.length>0)throw Error(`unknown set identifier: ${e.join(", ")}`)},"validateUnionIdentifiers"),ti=(0,a.K2)(()=>G,"getTextData"),tr=(0,a.K2)(()=>s,"getCurrentSets"),tl=(0,a.K2)(()=>X,"getIndentMode"),ta=(0,a.K2)(t=>{X=t},"setIndentMode"),to=l.UI.venn;function th(){return(0,r.$t)(to,(0,l.zj)().venn)}(0,a.K2)(th,"getConfig");var tc={getConfig:th,clear:(0,a.K2)(()=>{(0,l.IU)(),B.length=0,G.length=0,W.length=0,V.clear(),s=void 0,X=!1},"customClear"),setAccTitle:l.SV,getAccTitle:l.iN,setDiagramTitle:l.ke,getDiagramTitle:l.ab,getAccDescription:l.m7,setAccDescription:l.EI,addSubsetData:Y,getSubsetData:Z,addTextData:Q,addStyleData:tt,validateUnionIdentifiers:ts,getTextData:ti,getStyleData:te,getCurrentSets:tr,getIndentMode:tl,setIndentMode:ta},tu=(0,a.K2)(t=>`
2
+ .venn-title {
3
+ font-size: 32px;
4
+ fill: ${t.vennTitleTextColor};
5
+ font-family: ${t.fontFamily};
6
+ }
7
+
8
+ .venn-circle text {
9
+ font-size: 48px;
10
+ font-family: ${t.fontFamily};
11
+ }
12
+
13
+ .venn-intersection text {
14
+ font-size: 48px;
15
+ fill: ${t.vennSetTextColor};
16
+ font-family: ${t.fontFamily};
17
+ }
18
+
19
+ .venn-text-node {
20
+ font-family: ${t.fontFamily};
21
+ color: ${t.vennSetTextColor};
22
+ }
23
+ `,"getStyles");function tf(t){let e=new Map;for(let n of t){let t=n.targets.join("|"),s=e.get(t);s?Object.assign(s,n.styles):e.set(t,{...n.styles})}return e}(0,a.K2)(tf,"buildStyleByKey");var td=(0,a.K2)((t,e,n,s)=>{let r=s.db,a=r.getConfig?.(),{themeVariables:c,look:y,handDrawnSeed:x}=(0,l.zj)(),g="handDrawn"===y,p=[c.venn1,c.venn2,c.venn3,c.venn4,c.venn5,c.venn6,c.venn7,c.venn8].filter(Boolean),m=r.getDiagramTitle?.(),b=r.getSubsetData(),v=r.getTextData(),M=tf(r.getStyleData()),I=a?.width??800,k=a?.height??450,_=I/1600,w=m?48*_:0,E=c.primaryTextColor??c.textColor,T=(0,i.D)(e);T.attr("viewBox",`0 0 ${I} ${k}`),m&&T.append("text").text(m).attr("class","venn-title").attr("font-size",`${32*_}px`).attr("text-anchor","middle").attr("dominant-baseline","middle").attr("x","50%").attr("y",32*_).style("fill",c.vennTitleTextColor||c.titleColor);let z=(0,o.Ltv)(document.createElement("div")),R=(function(t={}){let e=!1,n=600,s=350,i=15,r=1e3,l=Math.PI/2,a=!0,o=null,h=!0,c=!0,u=null,f=null,d=!1,y=null,x=!!t&&!!t.symmetricalTextCentre&&t.symmetricalTextCentre,g={},p=t&&t.colourScheme?t.colourScheme:t&&t.colorScheme?t.colorScheme:["#1f77b4","#ff7f0e","#2ca02c","#d62728","#9467bd","#8c564b","#e377c2","#7f7f7f","#bcbd22","#17becf"],m=0,b=function(t){if(t in g)return g[t];var e=g[t]=p[m];return(m+=1)>=p.length&&(m=0),e},v=S,M=A;function I(g){let p=g.datum(),m=new Set;p.forEach(t=>{0==t.size&&1==t.sets.length&&m.add(t.sets[0])});let I={},k={};if((p=p.filter(t=>!t.sets.some(t=>m.has(t)))).length>0){let t=v(p,{lossFunction:M,distinct:d});a&&(t=$(t,l,f)),k=L(I=N(t,n,s,i,o),p,x)}let _={};function w(t){return t.sets in _?_[t.sets]:1==t.sets.length?""+t.sets[0]:void 0}p.forEach(t=>{t.label&&(_[t.sets]=t.label)}),g.selectAll("svg").data([I]).enter().append("svg");let E=g.select("svg");e?E.attr("viewBox",`0 0 ${n} ${s}`):E.attr("width",n).attr("height",s);let S={},T=!1;function z(t){return e=>{var i,r;return i=t.sets.map(t=>{let i=S[t],r=I[t];return i||(i={x:n/2,y:s/2,radius:1}),r||(r={x:n/2,y:s/2,radius:1}),{x:i.x*(1-e)+r.x*e,y:i.y*(1-e)+r.y*e,radius:i.radius*(1-e)+r.radius*e}}),r=y,P(j(i),r)}}E.selectAll(".venn-area path").each(function(t){let e=this.getAttribute("d");1==t.sets.length&&e&&!d&&(T=!0,S[t.sets[0]]=function(t){let e=t.split(" ");return{x:Number.parseFloat(e[1]),y:Number.parseFloat(e[2]),radius:-Number.parseFloat(e[4])}}(e))});let A=E.selectAll(".venn-area").data(p,t=>t.sets),K=A.enter().append("g").attr("class",t=>`venn-area venn-${1==t.sets.length?"circle":"intersection"}${t.colour||t.color?" venn-coloured":""}`).attr("data-venn-sets",t=>t.sets.join("_")),R=K.append("path"),O=K.append("text").attr("class","label").text(t=>w(t)).attr("text-anchor","middle").attr("dy",".35em").attr("x",n/2).attr("y",s/2);function C(t){return"function"==typeof t.transition?t.transition("venn").duration(r):t}c&&(R.style("fill-opacity","0").filter(t=>1==t.sets.length).style("fill",t=>t.colour?t.colour:t.color?t.color:b(t.sets)).style("fill-opacity",".25"),O.style("fill",e=>e.colour||e.color?"#FFF":t.textFill?t.textFill:1==e.sets.length?b(e.sets):"#444"));let F=g;T&&"function"==typeof F.transition?(F=C(g)).selectAll("path").attrTween("d",z):F.selectAll("path").attr("d",t=>P(j(t.sets.map(t=>I[t])),void 0),y);let U=F.selectAll("text").filter(t=>t.sets in k).text(t=>w(t)).attr("x",t=>Math.floor(k[t.sets].x)).attr("y",t=>Math.floor(k[t.sets].y));h&&(T?"on"in U?U.on("end",D(I,w)):U.each("end",D(I,w)):U.each(D(I,w)));let q=C(A.exit()).remove();"function"==typeof A.transition&&q.selectAll("path").attrTween("d",z);let B=q.selectAll("text").attr("x",n/2).attr("y",s/2);return null!==u&&(O.style("font-size","0px"),U.style("font-size",u),B.style("font-size","0px")),{circles:I,textCentres:k,nodes:A,enter:K,update:F,exit:q}}return I.wrap=function(t){return arguments.length?(h=t,I):h},I.useViewBox=function(){return e=!0,I},I.width=function(t){return arguments.length?(n=t,I):n},I.height=function(t){return arguments.length?(s=t,I):s},I.padding=function(t){return arguments.length?(i=t,I):i},I.distinct=function(t){return arguments.length?(d=t,I):d},I.colours=function(t){return arguments.length?(b=t,I):b},I.colors=function(t){return arguments.length?(b=t,I):b},I.fontSize=function(t){return arguments.length?(u=t,I):u},I.round=function(t){return arguments.length?(y=t,I):y},I.duration=function(t){return arguments.length?(r=t,I):r},I.layoutFunction=function(t){return arguments.length?(v=t,I):v},I.normalize=function(t){return arguments.length?(a=t,I):a},I.scaleToFit=function(t){return arguments.length?(o=t,I):o},I.styled=function(t){return arguments.length?(c=t,I):c},I.orientation=function(t){return arguments.length?(l=t,I):l},I.orientationOrder=function(t){return arguments.length?(f=t,I):f},I.lossFunction=function(t){return arguments.length?(M="default"===t?A:"logRatio"===t?K:t,I):M},I})().width(I).height(k-w);z.datum(b).call(R);let O=g?U.A.svg(z.select("svg").node()):void 0,C=function(t,e={}){let{lossFunction:n,layoutFunction:s=S,normalize:i=!0,orientation:r=Math.PI/2,orientationOrder:l,width:a=600,height:o=350,padding:h=15,scaleToFit:c=!1,symmetricalTextCentre:u=!1,distinct:f,round:d=2}=e,y=s(t,{lossFunction:"default"!==n&&n?"logRatio"===n?K:n:A,distinct:f});i&&(y=$(y,r,l));let x=N(y,a,o,h,c),g=L(x,t,u),p=new Map(Object.keys(x).map(t=>[t,{set:t,x:x[t].x,y:x[t].y,radius:x[t].radius}])),m=t.map(t=>{let e=t.sets.map(t=>p.get(t)),n=j(e),s=P(n,d);return{circles:e,arcs:n,path:s,area:t,has:new Set(t.sets)}});return m.map(({circles:t,arcs:e,path:n,area:s})=>({data:s,text:g[s.sets],circles:t,arcs:e,path:n,distinctPath:n+function(t){let e="";for(let n of m)n.has.size>t.length&&t.every(t=>n.has.has(t))&&(e+=" "+n.path);return e}(s.sets)}))}(b,{width:I,height:k-w,padding:a?.padding??15}),F=new Map;for(let t of C){let e=ty([...t.data.sets].sort());F.set(e,t)}v.length>0&&tx(a,F,z,v,_,M);let q=(0,h.A)(c.background||"#f4f4f4");z.selectAll(".venn-circle").each(function(t,e){let n=(0,o.Ltv)(this),s=ty([...t.sets].sort()),i=M.get(s),r=i?.fill||p[e%p.length]||c.primaryColor;n.classed(`venn-set-${e%8}`,!0);let l=i?.["fill-opacity"]??.1,a=i?.stroke||r,h=i?.["stroke-width"]||`${5*_}`;if(g&&O){let t=F.get(s);if(t&&t.circles.length>0){let s=t.circles[0],i=O.circle(s.x,s.y,2*s.radius,{roughness:.7,seed:x,fill:u(r,.7),fillStyle:"hachure",fillWeight:2,hachureGap:8,hachureAngle:-41+60*e,stroke:a,strokeWidth:parseFloat(String(h))});n.select("path").remove(),n.node()?.insertBefore(i,n.select("text").node())}}else n.select("path").style("fill",r).style("fill-opacity",l).style("stroke",a).style("stroke-width",h).style("stroke-opacity",.95);let y=i?.color||(q?(0,f.A)(r,30):(0,d.A)(r,30));n.select("text").style("font-size",`${48*_}px`).style("fill",y)}),g&&O?z.selectAll(".venn-intersection").each(function(t){let e=(0,o.Ltv)(this),n=ty([...t.sets].sort()),s=M.get(n),i=s?.fill;if(i){let t=e.select("path"),n=t.attr("d");if(n){let e=O.path(n,{roughness:.7,seed:x,fill:u(i,.3),fillStyle:"cross-hatch",fillWeight:2,hachureGap:6,hachureAngle:60,stroke:"none"}),s=t.node();s?.parentNode?.insertBefore(e,s),t.remove()}}else e.select("path").style("fill-opacity",0);e.select("text").style("font-size",`${48*_}px`).style("fill",s?.color??c.vennSetTextColor??E)}):(z.selectAll(".venn-intersection text").style("font-size",`${48*_}px`).style("fill",t=>{let e=ty([...t.sets].sort());return M.get(e)?.color??c.vennSetTextColor??E}),z.selectAll(".venn-intersection path").style("fill-opacity",t=>{let e=ty([...t.sets].sort());return+!!M.get(e)?.fill}).style("fill",t=>{let e=ty([...t.sets].sort());return M.get(e)?.fill??"transparent"}));let B=T.append("g").attr("transform",`translate(0, ${w})`),G=z.select("svg").node();if(G&&"childNodes"in G)for(let t of[...G.childNodes])B.node()?.appendChild(t);(0,l.a$)(T,k,I,a?.useMaxWidth??!0)},"draw");function ty(t){return t.join("|")}function tx(t,e,n,s,i,r){let l=t?.useDebugLayout??!1,a=n.select("svg").append("g").attr("class","venn-text-nodes"),o=new Map;for(let t of s){let e=ty(t.sets),n=o.get(e);n?n.push(t):o.set(e,[t])}for(let[t,n]of o.entries()){let s=e.get(t);if(!s?.text)continue;let o=s.text.x,h=s.text.y,c=Math.min(...s.circles.map(t=>t.radius)),u=Math.min(...s.circles.map(t=>t.radius-Math.hypot(o-t.x,h-t.y))),f=Number.isFinite(u)?Math.max(0,u):0;0===f&&Number.isFinite(c)&&(f=.6*c);let d=a.append("g").attr("class","venn-text-area").attr("font-size",`${40*i}px`);l&&d.append("circle").attr("class","venn-text-debug-circle").attr("cx",o).attr("cy",h).attr("r",f).attr("fill","none").attr("stroke","purple").attr("stroke-width",1.5*i).attr("stroke-dasharray",`${6*i} ${4*i}`);let y=Math.max(80*i,2*f*.95),x=Math.max(60*i,2*f*.95),g=(s.data.label&&s.data.label.length>0?Math.min(32*i,.25*f):0)+(n.length<=2?30*i:0),p=o-y/2,m=h-x/2+g,b=Math.max(1,Math.ceil(Math.sqrt(n.length))),v=Math.max(1,Math.ceil(n.length/b)),M=y/b,I=x/v;for(let[t,e]of n.entries()){let n=t%b,s=Math.floor(t/b),a=p+M*(n+.5),o=m+I*(s+.5);l&&d.append("rect").attr("class","venn-text-debug-cell").attr("x",p+M*n).attr("y",m+I*s).attr("width",M).attr("height",I).attr("fill","none").attr("stroke","teal").attr("stroke-width",+i).attr("stroke-dasharray",`${4*i} ${3*i}`);let h=.9*M,c=.9*I,u=d.append("foreignObject").attr("class","venn-text-node-fo").attr("width",h).attr("height",c).attr("x",a-h/2).attr("y",o-c/2).attr("overflow","visible"),f=r.get(e.id)?.color,y=u.append("xhtml:span").attr("class","venn-text-node").style("display","flex").style("width","100%").style("height","100%").style("white-space","normal").style("align-items","center").style("justify-content","center").style("text-align","center").style("overflow-wrap","normal").style("word-break","normal").text(e.label??e.id);f&&y.style("color",f)}}}(0,a.K2)(ty,"stableSetsKey"),(0,a.K2)(tx,"renderTextNodes");var tg={parser:q,db:tc,renderer:{draw:td},styles:tu}}}]);
_next/static/chunks/7635.40c4d6f768cf3c32.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7635],{7635:(e,s,c)=>{c.d(s,{createTreeViewServices:()=>r.I});var r=c(1163);c(4839)}}]);
_next/static/chunks/7882.4d29af0e3f9c85c5.js ADDED
@@ -0,0 +1,166 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7882],{1184:(t,e,s)=>{s.d(e,{A:()=>a});var i=s(316),r=s(5508),a=(0,i.K2)((t,e)=>{let s;return"sandbox"===e&&(s=(0,r.Ltv)("#i"+t)),("sandbox"===e?(0,r.Ltv)(s.nodes()[0].contentDocument.body):(0,r.Ltv)("body")).select(`[id="${t}"]`)},"getDiagramElement")},2888:(t,e,s)=>{s.d(e,{P:()=>a});var i=s(669),r=s(316),a=(0,r.K2)((t,e,s,a)=>{t.attr("class",s);let{width:l,height:o,x:c,y:h}=n(t,e);(0,i.a$)(t,o,l,a);let d=u(c,h,l,o,e);t.attr("viewBox",d),r.Rm.debug(`viewBox configured: ${d} with padding: ${e}`)},"setupViewPortForSVG"),n=(0,r.K2)((t,e)=>{let s=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:s.width+2*e,height:s.height+2*e,x:s.x,y:s.y}},"calculateDimensionsWithPadding"),u=(0,r.K2)((t,e,s,i,r)=>`${t-r} ${e-r} ${s} ${i}`,"createViewBox")},3062:(t,e,s)=>{s.d(e,{CP:()=>h,Ck:()=>g,HT:()=>p,PB:()=>d,aC:()=>c,lC:()=>l,m:()=>o,tk:()=>u});var i=s(669),r=s(316),a=s(3572),n=s(5508),u=(0,r.K2)((t,e)=>{let s=t.append("rect");if(s.attr("x",e.x),s.attr("y",e.y),s.attr("fill",e.fill),s.attr("stroke",e.stroke),s.attr("width",e.width),s.attr("height",e.height),e.name&&s.attr("name",e.name),e.rx&&s.attr("rx",e.rx),e.ry&&s.attr("ry",e.ry),void 0!==e.attrs)for(let t in e.attrs)s.attr(t,e.attrs[t]);return e.class&&s.attr("class",e.class),s},"drawRect"),l=(0,r.K2)((t,e)=>{u(t,{x:e.startx,y:e.starty,width:e.stopx-e.startx,height:e.stopy-e.starty,fill:e.fill,stroke:e.stroke,class:"rect"}).lower()},"drawBackgroundRect"),o=(0,r.K2)((t,e)=>{let s=e.text.replace(i.H1," "),r=t.append("text");r.attr("x",e.x),r.attr("y",e.y),r.attr("class","legend"),r.style("text-anchor",e.anchor),e.class&&r.attr("class",e.class);let a=r.append("tspan");return a.attr("x",e.x+2*e.textMargin),a.text(s),r},"drawText"),c=(0,r.K2)((t,e,s,i)=>{let r=t.append("image");r.attr("x",e),r.attr("y",s);let n=(0,a.J)(i);r.attr("xlink:href",n)},"drawImage"),h=(0,r.K2)((t,e,s,i)=>{let r=t.append("use");r.attr("x",e),r.attr("y",s);let n=(0,a.J)(i);r.attr("xlink:href",`#${n}`)},"drawEmbeddedImage"),d=(0,r.K2)(()=>({x:0,y:0,width:100,height:100,fill:"#EDF2AE",stroke:"#666",anchor:"start",rx:0,ry:0}),"getNoteRect"),p=(0,r.K2)(()=>({x:0,y:0,width:100,height:100,"text-anchor":"start",style:"#666",textMargin:0,rx:0,ry:0,tspan:!0}),"getTextObj"),g=(0,r.K2)(()=>{let t=(0,n.Ltv)(".mermaidTooltip");return t.empty()&&(t=(0,n.Ltv)("body").append("div").attr("class","mermaidTooltip").style("opacity",0).style("position","absolute").style("text-align","center").style("max-width","200px").style("padding","2px").style("font-size","12px").style("background","#ffffde").style("border","1px solid #333").style("border-radius","2px").style("pointer-events","none").style("z-index","100")),t},"createTooltip")},3580:(t,e,s)=>{s.d(e,{o:()=>i});var i=(0,s(316).K2)(()=>`
2
+ /* Font Awesome icon styling - consolidated */
3
+ .label-icon {
4
+ display: inline-block;
5
+ height: 1em;
6
+ overflow: visible;
7
+ vertical-align: -0.125em;
8
+ }
9
+
10
+ .node .label-icon path {
11
+ fill: currentColor;
12
+ stroke: revert;
13
+ stroke-width: revert;
14
+ }
15
+ `,"getIconStyles")},4808:(t,e,s)=>{s.d(e,{A:()=>a});var i=s(5525),r=s(4984);let a=(t,e)=>i.A.lang.round(r.A.parse(t)[e])},7882:(t,e,s)=>{s.d(e,{diagram:()=>D});var i=s(3580),r=s(2482),a=s(3062),n=s(1184),u=s(2888),l=s(1593);s(4982),s(1431);var o=s(5407);s(7920),s(3148),s(1538);var c=s(3736),h=s(669),d=s(316),p=s(5508),g=s(2931),A=s(4808),y=s(8247),b=class{constructor(){this.vertexCounter=0,this.config=(0,h.D7)(),this.diagramId="",this.vertices=new Map,this.edges=[],this.classes=new Map,this.subGraphs=[],this.subGraphLookup=new Map,this.tooltips=new Map,this.subCount=0,this.firstGraphFlag=!0,this.secCount=-1,this.posCrossRef=[],this.funs=[],this.setAccTitle=h.SV,this.setAccDescription=h.EI,this.setDiagramTitle=h.ke,this.getAccTitle=h.iN,this.getAccDescription=h.m7,this.getDiagramTitle=h.ab,this.funs.push(this.setupToolTips.bind(this)),this.addVertex=this.addVertex.bind(this),this.firstGraph=this.firstGraph.bind(this),this.setDirection=this.setDirection.bind(this),this.addSubGraph=this.addSubGraph.bind(this),this.addLink=this.addLink.bind(this),this.setLink=this.setLink.bind(this),this.updateLink=this.updateLink.bind(this),this.addClass=this.addClass.bind(this),this.setClass=this.setClass.bind(this),this.destructLink=this.destructLink.bind(this),this.setClickEvent=this.setClickEvent.bind(this),this.setTooltip=this.setTooltip.bind(this),this.updateLinkInterpolate=this.updateLinkInterpolate.bind(this),this.setClickFun=this.setClickFun.bind(this),this.bindFunctions=this.bindFunctions.bind(this),this.lex={firstGraph:this.firstGraph.bind(this)},this.clear(),this.setGen("gen-2")}static{(0,d.K2)(this,"FlowDB")}sanitizeText(t){return h.Y2.sanitizeText(t,this.config)}sanitizeNodeLabelType(t){switch(t){case"markdown":case"string":case"text":return t;default:return"markdown"}}setDiagramId(t){this.diagramId=t}lookUpDomId(t){for(let e of this.vertices.values())if(e.id===t)return this.diagramId?`${this.diagramId}-${e.domId}`:e.domId;return this.diagramId?`${this.diagramId}-${t}`:t}addVertex(t,e,s,i,a,n,u={},l){let c,p;if(!t||0===t.trim().length)return;if(void 0!==l){let t;t=l.includes("\n")?l+"\n":"{\n"+l+"\n}",c=(0,r.H)(t,{schema:r.r})}let g=this.edges.find(e=>e.id===t);if(g){let t=c;t?.animate!==void 0&&(g.animate=t.animate),t?.animation!==void 0&&(g.animation=t.animation),t?.curve!==void 0&&(g.interpolate=t.curve);return}let A=this.vertices.get(t);if(void 0===A&&(void 0===e&&void 0===s&&null!=i&&d.Rm.warn(`Style applied to unknown node "${t}". This may indicate a typo. The node will be created automatically.`),A={id:t,labelType:"text",domId:"flowchart-"+t+"-"+this.vertexCounter,styles:[],classes:[]},this.vertices.set(t,A)),this.vertexCounter++,void 0!==e?(this.config=(0,h.D7)(),p=this.sanitizeText(e.text.trim()),A.labelType=e.type,p.startsWith('"')&&p.endsWith('"')&&(p=p.substring(1,p.length-1)),A.text=p):void 0===A.text&&(A.text=t),void 0!==s&&(A.type=s),null!=i&&i.forEach(t=>{A.styles.push(t)}),null!=a&&a.forEach(t=>{A.classes.push(t)}),void 0!==n&&(A.dir=n),void 0===A.props?A.props=u:void 0!==u&&Object.assign(A.props,u),void 0!==c){if(c.shape){if(c.shape!==c.shape.toLowerCase()||c.shape.includes("_"))throw Error(`No such shape: ${c.shape}. Shape names should be lowercase.`);if(!(0,o.aP)(c.shape))throw Error(`No such shape: ${c.shape}.`);A.type=c?.shape}c?.label&&(A.text=c?.label,A.labelType=this.sanitizeNodeLabelType(c?.labelType)),c?.icon&&(A.icon=c?.icon,c.label?.trim()||A.text!==t||(A.text="")),c?.form&&(A.form=c?.form),c?.pos&&(A.pos=c?.pos),c?.img&&(A.img=c?.img,c.label?.trim()||A.text!==t||(A.text="")),c?.constraint&&(A.constraint=c.constraint),c.w&&(A.assetWidth=Number(c.w)),c.h&&(A.assetHeight=Number(c.h))}}addSingleLink(t,e,s,i){let r={start:t,end:e,type:void 0,text:"",labelType:"text",classes:[],isUserDefinedId:!1,interpolate:this.edges.defaultInterpolate};d.Rm.info("abc78 Got edge...",r);let a=s.text;if(void 0!==a&&(r.text=this.sanitizeText(a.text.trim()),r.text.startsWith('"')&&r.text.endsWith('"')&&(r.text=r.text.substring(1,r.text.length-1)),r.labelType=this.sanitizeNodeLabelType(a.type)),void 0!==s&&(r.type=s.type,r.stroke=s.stroke,r.length=s.length>10?10:s.length),i&&!this.edges.some(t=>t.id===i))r.id=i,r.isUserDefinedId=!0;else{let t=this.edges.filter(t=>t.start===r.start&&t.end===r.end);0===t.length?r.id=(0,c.rY)(r.start,r.end,{counter:0,prefix:"L"}):r.id=(0,c.rY)(r.start,r.end,{counter:t.length+1,prefix:"L"})}if(this.edges.length<(this.config.maxEdges??500))d.Rm.info("Pushing edge..."),this.edges.push(r);else throw Error(`Edge limit exceeded. ${this.edges.length} edges found, but the limit is ${this.config.maxEdges}.
16
+
17
+ Initialize mermaid with maxEdges set to a higher number to allow more edges.
18
+ You cannot set this config via configuration inside the diagram as it is a secure config.
19
+ You have to call mermaid.initialize.`)}isLinkData(t){return null!==t&&"object"==typeof t&&"id"in t&&"string"==typeof t.id}addLink(t,e,s){let i=this.isLinkData(s)?s.id.replace("@",""):void 0;for(let r of(d.Rm.info("addLink",t,e,i),t))for(let a of e){let n=r===t[t.length-1],u=a===e[0];n&&u?this.addSingleLink(r,a,s,i):this.addSingleLink(r,a,s,void 0)}}updateLinkInterpolate(t,e){t.forEach(t=>{"default"===t?this.edges.defaultInterpolate=e:this.edges[t].interpolate=e})}updateLink(t,e){t.forEach(t=>{if("number"==typeof t&&t>=this.edges.length)throw Error(`The index ${t} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${this.edges.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);"default"===t?this.edges.defaultStyle=e:(this.edges[t].style=e,(this.edges[t]?.style?.length??0)>0&&!this.edges[t]?.style?.some(t=>t?.startsWith("fill"))&&this.edges[t]?.style?.push("fill:none"))})}addClass(t,e){let s=e.join().replace(/\\,/g,"\xa7\xa7\xa7").replace(/,/g,";").replace(/§§§/g,",").split(";");t.split(",").forEach(t=>{let e=this.classes.get(t);void 0===e&&(e={id:t,styles:[],textStyles:[]},this.classes.set(t,e)),null!=s&&s.forEach(t=>{if(/color/.exec(t)){let s=t.replace("fill","bgFill");e.textStyles.push(s)}e.styles.push(t)})})}setDirection(t){this.direction=t.trim(),/.*</.exec(this.direction)&&(this.direction="RL"),/.*\^/.exec(this.direction)&&(this.direction="BT"),/.*>/.exec(this.direction)&&(this.direction="LR"),/.*v/.exec(this.direction)&&(this.direction="TB"),"TD"===this.direction&&(this.direction="TB")}setClass(t,e){for(let s of t.split(",")){let t=this.vertices.get(s);t&&t.classes.push(e);let i=this.edges.find(t=>t.id===s);i&&i.classes.push(e);let r=this.subGraphLookup.get(s);r&&r.classes.push(e)}}setTooltip(t,e){if(void 0!==e)for(let s of(e=this.sanitizeText(e),t.split(",")))this.tooltips.set("gen-1"===this.version?this.lookUpDomId(s):s,e)}setClickFun(t,e,s){if("loose"!==(0,h.D7)().securityLevel||void 0===e)return;let i=[];if("string"==typeof s){i=s.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let t=0;t<i.length;t++){let e=i[t].trim();e.startsWith('"')&&e.endsWith('"')&&(e=e.substr(1,e.length-2)),i[t]=e}}0===i.length&&i.push(t);let r=this.vertices.get(t);r&&(r.haveCallback=!0,this.funs.push(()=>{let s=this.lookUpDomId(t),r=document.querySelector(`[id="${s}"]`);null!==r&&r.addEventListener("click",()=>{c._K.runFunc(e,...i)},!1)}))}setLink(t,e,s){t.split(",").forEach(t=>{let i=this.vertices.get(t);void 0!==i&&(i.link=c._K.formatUrl(e,this.config),i.linkTarget=s)}),this.setClass(t,"clickable")}getTooltip(t){return this.tooltips.get(t)}setClickEvent(t,e,s){t.split(",").forEach(t=>{this.setClickFun(t,e,s)}),this.setClass(t,"clickable")}bindFunctions(t){this.funs.forEach(e=>{e(t)})}getDirection(){return this.direction?.trim()}getVertices(){return this.vertices}getEdges(){return this.edges}getClasses(){return this.classes}setupToolTips(t){let e=(0,a.Ck)();(0,p.Ltv)(t).select("svg").selectAll("g.node").on("mouseover",t=>{let s=(0,p.Ltv)(t.currentTarget),i=s.attr("title");if(null===i)return;let r=t.currentTarget?.getBoundingClientRect();e.transition().duration(200).style("opacity",".9"),e.text(s.attr("title")).style("left",window.scrollX+r.left+(r.right-r.left)/2+"px").style("top",window.scrollY+r.bottom+"px"),e.html(g.A.sanitize(i)),s.classed("hover",!0)}).on("mouseout",t=>{e.transition().duration(500).style("opacity",0),(0,p.Ltv)(t.currentTarget).classed("hover",!1)})}clear(t="gen-2"){this.vertices=new Map,this.classes=new Map,this.edges=[],this.funs=[this.setupToolTips.bind(this)],this.diagramId="",this.subGraphs=[],this.subGraphLookup=new Map,this.subCount=0,this.tooltips=new Map,this.firstGraphFlag=!0,this.version=t,this.config=(0,h.D7)(),(0,h.IU)()}setGen(t){this.version=t||"gen-2"}defaultStyle(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"}addSubGraph(t,e,s){let i=t.text.trim(),r=s.text;t===s&&/\s/.exec(s.text)&&(i=void 0);let a=(0,d.K2)(t=>{let e,s={boolean:{},number:{},string:{}},i=[];return{nodeList:t.filter(function(t){let r=typeof t;return t.stmt&&"dir"===t.stmt?(e=t.value,!1):""!==t.trim()&&(r in s?!s[r].hasOwnProperty(t)&&(s[r][t]=!0):!i.includes(t)&&i.push(t))}),dir:e}},"uniq")(e.flat()),n=a.nodeList,u=a.dir,l=(0,h.D7)().flowchart??{};if(u=u??(l.inheritDir?this.getDirection()??(0,h.D7)().direction??void 0:void 0),"gen-1"===this.version)for(let t=0;t<n.length;t++)n[t]=this.lookUpDomId(n[t]);i=i??"subGraph"+this.subCount,r=r||"",r=this.sanitizeText(r),this.subCount=this.subCount+1;let o={id:i,nodes:n,title:r.trim(),classes:[],dir:u,labelType:this.sanitizeNodeLabelType(s?.type)};return d.Rm.info("Adding",o.id,o.nodes,o.dir),o.nodes=this.makeUniq(o,this.subGraphs).nodes,this.subGraphs.push(o),this.subGraphLookup.set(i,o),i}getPosForId(t){for(let[e,s]of this.subGraphs.entries())if(s.id===t)return e;return -1}indexNodes2(t,e){let s=this.subGraphs[e].nodes;if(this.secCount=this.secCount+1,this.secCount>2e3)return{result:!1,count:0};if(this.posCrossRef[this.secCount]=e,this.subGraphs[e].id===t)return{result:!0,count:0};let i=0,r=1;for(;i<s.length;){let e=this.getPosForId(s[i]);if(e>=0){let s=this.indexNodes2(t,e);if(s.result)return{result:!0,count:r+s.count};r+=s.count}i+=1}return{result:!1,count:r}}getDepthFirstPos(t){return this.posCrossRef[t]}indexNodes(){this.secCount=-1,this.subGraphs.length>0&&this.indexNodes2("none",this.subGraphs.length-1)}getSubGraphs(){return this.subGraphs}firstGraph(){return!!this.firstGraphFlag&&(this.firstGraphFlag=!1,!0)}destructStartLink(t){let e=t.trim(),s="arrow_open";switch(e[0]){case"<":s="arrow_point",e=e.slice(1);break;case"x":s="arrow_cross",e=e.slice(1);break;case"o":s="arrow_circle",e=e.slice(1)}let i="normal";return e.includes("=")&&(i="thick"),e.includes(".")&&(i="dotted"),{type:s,stroke:i}}countChar(t,e){let s=e.length,i=0;for(let r=0;r<s;++r)e[r]===t&&++i;return i}destructEndLink(t){let e=t.trim(),s=e.slice(0,-1),i="arrow_open";switch(e.slice(-1)){case"x":i="arrow_cross",e.startsWith("x")&&(i="double_"+i,s=s.slice(1));break;case">":i="arrow_point",e.startsWith("<")&&(i="double_"+i,s=s.slice(1));break;case"o":i="arrow_circle",e.startsWith("o")&&(i="double_"+i,s=s.slice(1))}let r="normal",a=s.length-1;s.startsWith("=")&&(r="thick"),s.startsWith("~")&&(r="invisible");let n=this.countChar(".",s);return n&&(r="dotted",a=n),{type:i,stroke:r,length:a}}destructLink(t,e){let s,i=this.destructEndLink(t);if(e){if((s=this.destructStartLink(e)).stroke!==i.stroke)return{type:"INVALID",stroke:"INVALID"};if("arrow_open"===s.type)s.type=i.type;else{if(s.type!==i.type)return{type:"INVALID",stroke:"INVALID"};s.type="double_"+s.type}return"double_arrow"===s.type&&(s.type="double_arrow_point"),s.length=i.length,s}return i}exists(t,e){for(let s of t)if(s.nodes.includes(e))return!0;return!1}makeUniq(t,e){let s=[];return t.nodes.forEach((i,r)=>{this.exists(e,i)||s.push(t.nodes[r])}),{nodes:s}}getTypeFromVertex(t){if(t.img)return"imageSquare";if(t.icon)return"circle"===t.form?"iconCircle":"square"===t.form?"iconSquare":"rounded"===t.form?"iconRounded":"icon";switch(t.type){case"square":case void 0:return"squareRect";case"round":return"roundedRect";case"ellipse":return"ellipse";default:return t.type}}findNode(t,e){return t.find(t=>t.id===e)}destructEdgeType(t){let e="none",s="arrow_point";switch(t){case"arrow_point":case"arrow_circle":case"arrow_cross":s=t;break;case"double_arrow_point":case"double_arrow_circle":case"double_arrow_cross":s=e=t.replace("double_","")}return{arrowTypeStart:e,arrowTypeEnd:s}}addNodeFromVertex(t,e,s,i,r,a){let n=s.get(t.id),u=i.get(t.id)??!1,l=this.findNode(e,t.id);if(l)l.cssStyles=t.styles,l.cssCompiledStyles=this.getCompiledStyles(t.classes),l.cssClasses=t.classes.join(" ");else{let s={id:t.id,label:t.text,labelType:t.labelType,labelStyle:"",parentId:n,padding:r.flowchart?.padding||8,cssStyles:t.styles,cssCompiledStyles:this.getCompiledStyles(["default","node",...t.classes]),cssClasses:"default "+t.classes.join(" "),dir:t.dir,domId:t.domId,look:a,link:t.link,linkTarget:t.linkTarget,tooltip:this.getTooltip(t.id),icon:t.icon,pos:t.pos,img:t.img,assetWidth:t.assetWidth,assetHeight:t.assetHeight,constraint:t.constraint};u?e.push({...s,isGroup:!0,shape:"rect"}):e.push({...s,isGroup:!1,shape:this.getTypeFromVertex(t)})}}getCompiledStyles(t){let e=[];for(let s of t){let t=this.classes.get(s);t?.styles&&(e=[...e,...t.styles??[]].map(t=>t.trim())),t?.textStyles&&(e=[...e,...t.textStyles??[]].map(t=>t.trim()))}return e}getData(){let t=(0,h.D7)(),e=[],s=[],i=this.getSubGraphs(),r=new Map,a=new Map;for(let t=i.length-1;t>=0;t--){let e=i[t];for(let t of(e.nodes.length>0&&a.set(e.id,!0),e.nodes))r.set(t,e.id)}for(let s=i.length-1;s>=0;s--){let a=i[s];e.push({id:a.id,label:a.title,labelStyle:"",labelType:a.labelType,parentId:r.get(a.id),padding:8,cssCompiledStyles:this.getCompiledStyles(a.classes),cssClasses:a.classes.join(" "),shape:"rect",dir:a.dir,isGroup:!0,look:t.look})}this.getVertices().forEach(s=>{this.addNodeFromVertex(s,e,r,a,t,t.look||"classic")});let n=this.getEdges();return n.forEach((e,i)=>{let{arrowTypeStart:r,arrowTypeEnd:a}=this.destructEdgeType(e.type),u=[...n.defaultStyle??[]];e.style&&u.push(...e.style);let l={id:(0,c.rY)(e.start,e.end,{counter:i,prefix:"L"},e.id),isUserDefinedId:e.isUserDefinedId,start:e.start,end:e.end,type:e.type??"normal",label:e.text,labelType:e.labelType,labelpos:"c",thickness:e.stroke,minlen:e.length,classes:e?.stroke==="invisible"?"":"edge-thickness-normal edge-pattern-solid flowchart-link",arrowTypeStart:e?.stroke==="invisible"||e?.type==="arrow_open"?"none":r,arrowTypeEnd:e?.stroke==="invisible"||e?.type==="arrow_open"?"none":a,arrowheadStyle:"fill: #333",cssCompiledStyles:this.getCompiledStyles(e.classes),labelStyle:u,style:u,pattern:e.stroke,look:t.look,animate:e.animate,animation:e.animation,curve:e.interpolate||this.edges.defaultInterpolate||t.flowchart?.curve};s.push(l)}),{nodes:e,edges:s,other:{},config:t}}defaultConfig(){return h.ME.flowchart}},k=(0,d.K2)(function(t,e){return e.db.getClasses()},"getClasses"),f=(0,d.K2)(async function(t,e,s,i){d.Rm.info("REF0:"),d.Rm.info("Drawing state diagram (v2)",e);let{securityLevel:r,flowchart:a,layout:o}=(0,h.D7)();i.db.setDiagramId(e),d.Rm.debug("Before getData: ");let p=i.db.getData();d.Rm.debug("Data: ",p);let g=(0,n.A)(e,r),A=i.db.getDirection();p.type=i.type,p.layoutAlgorithm=(0,l.q7)(o),"dagre"===p.layoutAlgorithm&&"elk"===o&&d.Rm.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback."),p.direction=A,p.nodeSpacing=a?.nodeSpacing||50,p.rankSpacing=a?.rankSpacing||50,p.markers=["point","circle","cross"],p.diagramId=e,d.Rm.debug("REF1:",p),await (0,l.XX)(p,g);let y=p.config.flowchart?.diagramPadding??8;c._K.insertTitle(g,"flowchartTitleText",a?.titleTopMargin||0,i.db.getDiagramTitle()),(0,u.P)(g,y,"flowchart",a?.useMaxWidth||!1)},"draw"),m=function(){var t=(0,d.K2)(function(t,e,s,i){for(s=s||{},i=t.length;i--;s[t[i]]=e);return s},"o"),e=[1,4],s=[1,3],i=[1,5],r=[1,8,9,10,11,27,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],a=[2,2],n=[1,13],u=[1,14],l=[1,15],o=[1,16],c=[1,23],h=[1,25],p=[1,26],g=[1,27],A=[1,50],y=[1,49],b=[1,29],k=[1,30],f=[1,31],m=[1,32],x=[1,33],E=[1,45],D=[1,47],C=[1,43],T=[1,48],F=[1,44],S=[1,51],_=[1,46],v=[1,52],B=[1,53],L=[1,34],w=[1,35],$=[1,36],I=[1,37],R=[1,38],N=[1,58],K=[1,8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],P=[1,62],G=[1,61],O=[1,63],M=[8,9,11,75,77,78],V=[1,79],U=[1,92],W=[1,97],z=[1,96],j=[1,93],Y=[1,89],H=[1,95],X=[1,91],q=[1,98],Q=[1,94],J=[1,99],Z=[1,90],tt=[8,9,10,11,40,75,77,78],te=[8,9,10,11,40,46,75,77,78],ts=[8,9,10,11,29,40,44,46,48,50,52,54,56,58,60,63,65,67,68,70,75,77,78,89,102,105,106,109,111,114,115,116],ti=[8,9,11,44,60,75,77,78,89,102,105,106,109,111,114,115,116],tr=[44,60,89,102,105,106,109,111,114,115,116],ta=[1,122],tn=[1,123],tu=[1,125],tl=[1,124],to=[44,60,62,74,89,102,105,106,109,111,114,115,116],tc=[1,134],th=[1,148],td=[1,149],tp=[1,150],tg=[1,151],tA=[1,136],ty=[1,138],tb=[1,142],tk=[1,143],tf=[1,144],tm=[1,145],tx=[1,146],tE=[1,147],tD=[1,152],tC=[1,153],tT=[1,132],tF=[1,133],tS=[1,140],t_=[1,135],tv=[1,139],tB=[1,137],tL=[8,9,10,11,27,32,34,36,38,44,60,84,85,86,87,88,89,102,105,106,109,111,114,115,116,121,122,123,124,125],tw=[1,155],t$=[1,157],tI=[8,9,11],tR=[8,9,10,11,14,44,60,89,105,106,109,111,114,115,116],tN=[1,177],tK=[1,173],tP=[1,174],tG=[1,178],tO=[1,175],tM=[1,176],tV=[77,116,119],tU=[8,9,10,11,12,14,27,29,32,44,60,75,84,85,86,87,88,89,90,105,109,111,114,115,116],tW=[10,106],tz=[31,49,51,53,55,57,62,64,66,67,69,71,116,117,118],tj=[1,248],tY=[1,246],tH=[1,250],tX=[1,244],tq=[1,245],tQ=[1,247],tJ=[1,249],tZ=[1,251],t1=[1,269],t0=[8,9,11,106],t2=[8,9,10,11,60,84,105,106,109,110,111,112],t8={trace:(0,d.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeparator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,vertexStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,shapeData:39,SHAPE_DATA:40,link:41,node:42,styledVertex:43,AMP:44,vertex:45,STYLE_SEPARATOR:46,idString:47,DOUBLECIRCLESTART:48,DOUBLECIRCLEEND:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,VERTEX_WITH_PROPS_START:58,"NODE_STRING[field]":59,COLON:60,"NODE_STRING[value]":61,PIPE:62,CYLINDERSTART:63,CYLINDEREND:64,DIAMOND_START:65,DIAMOND_STOP:66,TAGEND:67,TRAPSTART:68,TRAPEND:69,INVTRAPSTART:70,INVTRAPEND:71,linkStatement:72,arrowText:73,TESTSTR:74,START_LINK:75,edgeText:76,LINK:77,LINK_ID:78,edgeTextToken:79,STR:80,MD_STR:81,textToken:82,keywords:83,STYLE:84,LINKSTYLE:85,CLASSDEF:86,CLASS:87,CLICK:88,DOWN:89,UP:90,textNoTagsToken:91,stylesOpt:92,"idString[vertex]":93,"idString[class]":94,CALLBACKNAME:95,CALLBACKARGS:96,HREF:97,LINK_TARGET:98,"STR[link]":99,"STR[tooltip]":100,alphaNum:101,DEFAULT:102,numList:103,INTERPOLATE:104,NUM:105,COMMA:106,style:107,styleComponent:108,NODE_STRING:109,UNIT:110,BRKT:111,PCT:112,idStringToken:113,MINUS:114,MULT:115,UNICODE_TEXT:116,TEXT:117,TAGSTART:118,EDGE_TEXT:119,alphaNumToken:120,direction_tb:121,direction_bt:122,direction_rl:123,direction_lr:124,direction_td:125,$accept:0,$end:1},terminals_:{2:"error",8:"SEMI",9:"NEWLINE",10:"SPACE",11:"EOF",12:"GRAPH",13:"NODIR",14:"DIR",27:"subgraph",29:"SQS",31:"SQE",32:"end",34:"acc_title",35:"acc_title_value",36:"acc_descr",37:"acc_descr_value",38:"acc_descr_multiline_value",40:"SHAPE_DATA",44:"AMP",46:"STYLE_SEPARATOR",48:"DOUBLECIRCLESTART",49:"DOUBLECIRCLEEND",50:"PS",51:"PE",52:"(-",53:"-)",54:"STADIUMSTART",55:"STADIUMEND",56:"SUBROUTINESTART",57:"SUBROUTINEEND",58:"VERTEX_WITH_PROPS_START",59:"NODE_STRING[field]",60:"COLON",61:"NODE_STRING[value]",62:"PIPE",63:"CYLINDERSTART",64:"CYLINDEREND",65:"DIAMOND_START",66:"DIAMOND_STOP",67:"TAGEND",68:"TRAPSTART",69:"TRAPEND",70:"INVTRAPSTART",71:"INVTRAPEND",74:"TESTSTR",75:"START_LINK",77:"LINK",78:"LINK_ID",80:"STR",81:"MD_STR",84:"STYLE",85:"LINKSTYLE",86:"CLASSDEF",87:"CLASS",88:"CLICK",89:"DOWN",90:"UP",93:"idString[vertex]",94:"idString[class]",95:"CALLBACKNAME",96:"CALLBACKARGS",97:"HREF",98:"LINK_TARGET",99:"STR[link]",100:"STR[tooltip]",102:"DEFAULT",104:"INTERPOLATE",105:"NUM",106:"COMMA",109:"NODE_STRING",110:"UNIT",111:"BRKT",112:"PCT",114:"MINUS",115:"MULT",116:"UNICODE_TEXT",117:"TEXT",118:"TAGSTART",119:"EDGE_TEXT",121:"direction_tb",122:"direction_bt",123:"direction_rl",124:"direction_lr",125:"direction_td"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[39,2],[39,1],[20,4],[20,3],[20,4],[20,2],[20,2],[20,1],[42,1],[42,6],[42,5],[43,1],[43,3],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,8],[45,4],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,4],[45,4],[45,1],[41,2],[41,3],[41,3],[41,1],[41,3],[41,4],[76,1],[76,2],[76,1],[76,1],[72,1],[72,2],[73,3],[30,1],[30,2],[30,1],[30,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[83,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[103,1],[103,3],[92,1],[92,3],[107,1],[107,2],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[108,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[113,1],[82,1],[82,1],[82,1],[82,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[91,1],[79,1],[79,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[120,1],[47,1],[47,2],[101,1],[101,2],[33,1],[33,1],[33,1],[33,1],[33,1]],performAction:(0,d.K2)(function(t,e,s,i,r,a,n){var u=a.length-1;switch(r){case 2:case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 3:(!Array.isArray(a[u])||a[u].length>0)&&a[u-1].push(a[u]),this.$=a[u-1];break;case 4:case 183:case 44:case 54:case 76:case 181:this.$=a[u];break;case 11:i.setDirection("TB"),this.$="TB";break;case 12:i.setDirection(a[u-1]),this.$=a[u-1];break;case 27:this.$=a[u-1].nodes;break;case 33:this.$=i.addSubGraph(a[u-6],a[u-1],a[u-4]);break;case 34:this.$=i.addSubGraph(a[u-3],a[u-1],a[u-3]);break;case 35:this.$=i.addSubGraph(void 0,a[u-1],void 0);break;case 37:this.$=a[u].trim(),i.setAccTitle(this.$);break;case 38:case 39:this.$=a[u].trim(),i.setAccDescription(this.$);break;case 43:case 133:this.$=a[u-1]+a[u];break;case 45:i.addVertex(a[u-1][a[u-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[u]),i.addLink(a[u-3].stmt,a[u-1],a[u-2]),this.$={stmt:a[u-1],nodes:a[u-1].concat(a[u-3].nodes)};break;case 46:i.addLink(a[u-2].stmt,a[u],a[u-1]),this.$={stmt:a[u],nodes:a[u].concat(a[u-2].nodes)};break;case 47:i.addLink(a[u-3].stmt,a[u-1],a[u-2]),this.$={stmt:a[u-1],nodes:a[u-1].concat(a[u-3].nodes)};break;case 48:this.$={stmt:a[u-1],nodes:a[u-1]};break;case 49:i.addVertex(a[u-1][a[u-1].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[u]),this.$={stmt:a[u-1],nodes:a[u-1],shapeData:a[u]};break;case 50:this.$={stmt:a[u],nodes:a[u]};break;case 51:case 128:case 130:this.$=[a[u]];break;case 52:i.addVertex(a[u-5][a[u-5].length-1],void 0,void 0,void 0,void 0,void 0,void 0,a[u-4]),this.$=a[u-5].concat(a[u]);break;case 53:this.$=a[u-4].concat(a[u]);break;case 55:this.$=a[u-2],i.setClass(a[u-2],a[u]);break;case 56:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"square");break;case 57:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"doublecircle");break;case 58:this.$=a[u-5],i.addVertex(a[u-5],a[u-2],"circle");break;case 59:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"ellipse");break;case 60:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"stadium");break;case 61:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"subroutine");break;case 62:this.$=a[u-7],i.addVertex(a[u-7],a[u-1],"rect",void 0,void 0,void 0,Object.fromEntries([[a[u-5],a[u-3]]]));break;case 63:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"cylinder");break;case 64:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"round");break;case 65:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"diamond");break;case 66:this.$=a[u-5],i.addVertex(a[u-5],a[u-2],"hexagon");break;case 67:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"odd");break;case 68:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"trapezoid");break;case 69:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"inv_trapezoid");break;case 70:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"lean_right");break;case 71:this.$=a[u-3],i.addVertex(a[u-3],a[u-1],"lean_left");break;case 72:this.$=a[u],i.addVertex(a[u]);break;case 73:a[u-1].text=a[u],this.$=a[u-1];break;case 74:case 75:a[u-2].text=a[u-1],this.$=a[u-2];break;case 77:var l=i.destructLink(a[u],a[u-2]);this.$={type:l.type,stroke:l.stroke,length:l.length,text:a[u-1]};break;case 78:var l=i.destructLink(a[u],a[u-2]);this.$={type:l.type,stroke:l.stroke,length:l.length,text:a[u-1],id:a[u-3]};break;case 79:case 86:case 101:case 103:this.$={text:a[u],type:"text"};break;case 80:case 87:case 102:this.$={text:a[u-1].text+""+a[u],type:a[u-1].type};break;case 81:case 88:this.$={text:a[u],type:"string"};break;case 82:case 89:case 104:this.$={text:a[u],type:"markdown"};break;case 83:var l=i.destructLink(a[u]);this.$={type:l.type,stroke:l.stroke,length:l.length};break;case 84:var l=i.destructLink(a[u]);this.$={type:l.type,stroke:l.stroke,length:l.length,id:a[u-1]};break;case 85:this.$=a[u-1];break;case 105:this.$=a[u-4],i.addClass(a[u-2],a[u]);break;case 106:this.$=a[u-4],i.setClass(a[u-2],a[u]);break;case 107:case 115:this.$=a[u-1],i.setClickEvent(a[u-1],a[u]);break;case 108:case 116:this.$=a[u-3],i.setClickEvent(a[u-3],a[u-2]),i.setTooltip(a[u-3],a[u]);break;case 109:this.$=a[u-2],i.setClickEvent(a[u-2],a[u-1],a[u]);break;case 110:this.$=a[u-4],i.setClickEvent(a[u-4],a[u-3],a[u-2]),i.setTooltip(a[u-4],a[u]);break;case 111:this.$=a[u-2],i.setLink(a[u-2],a[u]);break;case 112:this.$=a[u-4],i.setLink(a[u-4],a[u-2]),i.setTooltip(a[u-4],a[u]);break;case 113:this.$=a[u-4],i.setLink(a[u-4],a[u-2],a[u]);break;case 114:this.$=a[u-6],i.setLink(a[u-6],a[u-4],a[u]),i.setTooltip(a[u-6],a[u-2]);break;case 117:this.$=a[u-1],i.setLink(a[u-1],a[u]);break;case 118:this.$=a[u-3],i.setLink(a[u-3],a[u-2]),i.setTooltip(a[u-3],a[u]);break;case 119:this.$=a[u-3],i.setLink(a[u-3],a[u-2],a[u]);break;case 120:this.$=a[u-5],i.setLink(a[u-5],a[u-4],a[u]),i.setTooltip(a[u-5],a[u-2]);break;case 121:this.$=a[u-4],i.addVertex(a[u-2],void 0,void 0,a[u]);break;case 122:this.$=a[u-4],i.updateLink([a[u-2]],a[u]);break;case 123:this.$=a[u-4],i.updateLink(a[u-2],a[u]);break;case 124:this.$=a[u-8],i.updateLinkInterpolate([a[u-6]],a[u-2]),i.updateLink([a[u-6]],a[u]);break;case 125:this.$=a[u-8],i.updateLinkInterpolate(a[u-6],a[u-2]),i.updateLink(a[u-6],a[u]);break;case 126:this.$=a[u-6],i.updateLinkInterpolate([a[u-4]],a[u]);break;case 127:this.$=a[u-6],i.updateLinkInterpolate(a[u-4],a[u]);break;case 129:case 131:a[u-2].push(a[u]),this.$=a[u-2];break;case 182:case 184:this.$=a[u-1]+""+a[u];break;case 185:this.$={stmt:"dir",value:"TB"};break;case 186:this.$={stmt:"dir",value:"BT"};break;case 187:this.$={stmt:"dir",value:"RL"};break;case 188:this.$={stmt:"dir",value:"LR"};break;case 189:this.$={stmt:"dir",value:"TD"}}},"anonymous"),table:[{3:1,4:2,9:e,10:s,12:i},{1:[3]},t(r,a,{5:6}),{4:7,9:e,10:s,12:i},{4:8,9:e,10:s,12:i},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:n,9:u,10:l,11:o,20:17,22:18,23:19,24:20,25:21,26:22,27:c,33:24,34:h,36:p,38:g,42:28,43:39,44:A,45:40,47:41,60:y,84:b,85:k,86:f,87:m,88:x,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B,121:L,122:w,123:$,124:I,125:R},t(r,[2,9]),t(r,[2,10]),t(r,[2,11]),{8:[1,55],9:[1,56],10:N,15:54,18:57},t(K,[2,3]),t(K,[2,4]),t(K,[2,5]),t(K,[2,6]),t(K,[2,7]),t(K,[2,8]),{8:P,9:G,11:O,21:59,41:60,72:64,75:[1,65],77:[1,67],78:[1,66]},{8:P,9:G,11:O,21:68},{8:P,9:G,11:O,21:69},{8:P,9:G,11:O,21:70},{8:P,9:G,11:O,21:71},{8:P,9:G,11:O,21:72},{8:P,9:G,10:[1,73],11:O,21:74},t(K,[2,36]),{35:[1,75]},{37:[1,76]},t(K,[2,39]),t(M,[2,50],{18:77,39:78,10:N,40:V}),{10:[1,80]},{10:[1,81]},{10:[1,82]},{10:[1,83]},{14:U,44:W,60:z,80:[1,87],89:j,95:[1,84],97:[1,85],101:86,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z,120:88},t(K,[2,185]),t(K,[2,186]),t(K,[2,187]),t(K,[2,188]),t(K,[2,189]),t(tt,[2,51]),t(tt,[2,54],{46:[1,100]}),t(te,[2,72],{113:113,29:[1,101],44:A,48:[1,102],50:[1,103],52:[1,104],54:[1,105],56:[1,106],58:[1,107],60:y,63:[1,108],65:[1,109],67:[1,110],68:[1,111],70:[1,112],89:E,102:D,105:C,106:T,109:F,111:S,114:_,115:v,116:B}),t(ts,[2,181]),t(ts,[2,142]),t(ts,[2,143]),t(ts,[2,144]),t(ts,[2,145]),t(ts,[2,146]),t(ts,[2,147]),t(ts,[2,148]),t(ts,[2,149]),t(ts,[2,150]),t(ts,[2,151]),t(ts,[2,152]),t(r,[2,12]),t(r,[2,18]),t(r,[2,19]),{9:[1,114]},t(ti,[2,26],{18:115,10:N}),t(K,[2,27]),{42:116,43:39,44:A,45:40,47:41,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},t(K,[2,40]),t(K,[2,41]),t(K,[2,42]),t(tr,[2,76],{73:117,62:[1,119],74:[1,118]}),{76:120,79:121,80:ta,81:tn,116:tu,119:tl},{75:[1,126],77:[1,127]},t(to,[2,83]),t(K,[2,28]),t(K,[2,29]),t(K,[2,30]),t(K,[2,31]),t(K,[2,32]),{10:tc,12:th,14:td,27:tp,28:128,32:tg,44:tA,60:ty,75:tb,80:[1,130],81:[1,131],83:141,84:tk,85:tf,86:tm,87:tx,88:tE,89:tD,90:tC,91:129,105:tT,109:tF,111:tS,114:t_,115:tv,116:tB},t(tL,a,{5:154}),t(K,[2,37]),t(K,[2,38]),t(M,[2,48],{44:tw}),t(M,[2,49],{18:156,10:N,40:t$}),t(tt,[2,44]),{44:A,47:158,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},{102:[1,159],103:160,105:[1,161]},{44:A,47:162,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},{44:A,47:163,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},t(tI,[2,107],{10:[1,164],96:[1,165]}),{80:[1,166]},t(tI,[2,115],{120:168,10:[1,167],14:U,44:W,60:z,89:j,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z}),t(tI,[2,117],{10:[1,169]}),t(tR,[2,183]),t(tR,[2,170]),t(tR,[2,171]),t(tR,[2,172]),t(tR,[2,173]),t(tR,[2,174]),t(tR,[2,175]),t(tR,[2,176]),t(tR,[2,177]),t(tR,[2,178]),t(tR,[2,179]),t(tR,[2,180]),{44:A,47:170,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},{30:171,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:179,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:181,50:[1,180],67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:182,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:183,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:184,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{109:[1,185]},{30:186,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:187,65:[1,188],67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:189,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:190,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{30:191,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},t(ts,[2,182]),t(r,[2,20]),t(ti,[2,25]),t(M,[2,46],{39:192,18:193,10:N,40:V}),t(tr,[2,73],{10:[1,194]}),{10:[1,195]},{30:196,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{77:[1,197],79:198,116:tu,119:tl},t(tV,[2,79]),t(tV,[2,81]),t(tV,[2,82]),t(tV,[2,168]),t(tV,[2,169]),{76:199,79:121,80:ta,81:tn,116:tu,119:tl},t(to,[2,84]),{8:P,9:G,10:tc,11:O,12:th,14:td,21:201,27:tp,29:[1,200],32:tg,44:tA,60:ty,75:tb,83:141,84:tk,85:tf,86:tm,87:tx,88:tE,89:tD,90:tC,91:202,105:tT,109:tF,111:tS,114:t_,115:tv,116:tB},t(tU,[2,101]),t(tU,[2,103]),t(tU,[2,104]),t(tU,[2,157]),t(tU,[2,158]),t(tU,[2,159]),t(tU,[2,160]),t(tU,[2,161]),t(tU,[2,162]),t(tU,[2,163]),t(tU,[2,164]),t(tU,[2,165]),t(tU,[2,166]),t(tU,[2,167]),t(tU,[2,90]),t(tU,[2,91]),t(tU,[2,92]),t(tU,[2,93]),t(tU,[2,94]),t(tU,[2,95]),t(tU,[2,96]),t(tU,[2,97]),t(tU,[2,98]),t(tU,[2,99]),t(tU,[2,100]),{6:11,7:12,8:n,9:u,10:l,11:o,20:17,22:18,23:19,24:20,25:21,26:22,27:c,32:[1,203],33:24,34:h,36:p,38:g,42:28,43:39,44:A,45:40,47:41,60:y,84:b,85:k,86:f,87:m,88:x,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B,121:L,122:w,123:$,124:I,125:R},{10:N,18:204},{44:[1,205]},t(tt,[2,43]),{10:[1,206],44:A,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:113,114:_,115:v,116:B},{10:[1,207]},{10:[1,208],106:[1,209]},t(tW,[2,128]),{10:[1,210],44:A,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:113,114:_,115:v,116:B},{10:[1,211],44:A,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:113,114:_,115:v,116:B},{80:[1,212]},t(tI,[2,109],{10:[1,213]}),t(tI,[2,111],{10:[1,214]}),{80:[1,215]},t(tR,[2,184]),{80:[1,216],98:[1,217]},t(tt,[2,55],{113:113,44:A,60:y,89:E,102:D,105:C,106:T,109:F,111:S,114:_,115:v,116:B}),{31:[1,218],67:tN,82:219,116:tG,117:tO,118:tM},t(tz,[2,86]),t(tz,[2,88]),t(tz,[2,89]),t(tz,[2,153]),t(tz,[2,154]),t(tz,[2,155]),t(tz,[2,156]),{49:[1,220],67:tN,82:219,116:tG,117:tO,118:tM},{30:221,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{51:[1,222],67:tN,82:219,116:tG,117:tO,118:tM},{53:[1,223],67:tN,82:219,116:tG,117:tO,118:tM},{55:[1,224],67:tN,82:219,116:tG,117:tO,118:tM},{57:[1,225],67:tN,82:219,116:tG,117:tO,118:tM},{60:[1,226]},{64:[1,227],67:tN,82:219,116:tG,117:tO,118:tM},{66:[1,228],67:tN,82:219,116:tG,117:tO,118:tM},{30:229,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},{31:[1,230],67:tN,82:219,116:tG,117:tO,118:tM},{67:tN,69:[1,231],71:[1,232],82:219,116:tG,117:tO,118:tM},{67:tN,69:[1,234],71:[1,233],82:219,116:tG,117:tO,118:tM},t(M,[2,45],{18:156,10:N,40:t$}),t(M,[2,47],{44:tw}),t(tr,[2,75]),t(tr,[2,74]),{62:[1,235],67:tN,82:219,116:tG,117:tO,118:tM},t(tr,[2,77]),t(tV,[2,80]),{77:[1,236],79:198,116:tu,119:tl},{30:237,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},t(tL,a,{5:238}),t(tU,[2,102]),t(K,[2,35]),{43:239,44:A,45:40,47:41,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},{10:N,18:240},{10:tj,60:tY,84:tH,92:241,105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},{10:tj,60:tY,84:tH,92:252,104:[1,253],105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},{10:tj,60:tY,84:tH,92:254,104:[1,255],105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},{105:[1,256]},{10:tj,60:tY,84:tH,92:257,105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},{44:A,47:258,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},t(tI,[2,108]),{80:[1,259]},{80:[1,260],98:[1,261]},t(tI,[2,116]),t(tI,[2,118],{10:[1,262]}),t(tI,[2,119]),t(te,[2,56]),t(tz,[2,87]),t(te,[2,57]),{51:[1,263],67:tN,82:219,116:tG,117:tO,118:tM},t(te,[2,64]),t(te,[2,59]),t(te,[2,60]),t(te,[2,61]),{109:[1,264]},t(te,[2,63]),t(te,[2,65]),{66:[1,265],67:tN,82:219,116:tG,117:tO,118:tM},t(te,[2,67]),t(te,[2,68]),t(te,[2,70]),t(te,[2,69]),t(te,[2,71]),t([10,44,60,89,102,105,106,109,111,114,115,116],[2,85]),t(tr,[2,78]),{31:[1,266],67:tN,82:219,116:tG,117:tO,118:tM},{6:11,7:12,8:n,9:u,10:l,11:o,20:17,22:18,23:19,24:20,25:21,26:22,27:c,32:[1,267],33:24,34:h,36:p,38:g,42:28,43:39,44:A,45:40,47:41,60:y,84:b,85:k,86:f,87:m,88:x,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B,121:L,122:w,123:$,124:I,125:R},t(tt,[2,53]),{43:268,44:A,45:40,47:41,60:y,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B},t(tI,[2,121],{106:t1}),t(t0,[2,130],{108:270,10:tj,60:tY,84:tH,105:tX,109:tq,110:tQ,111:tJ,112:tZ}),t(t2,[2,132]),t(t2,[2,134]),t(t2,[2,135]),t(t2,[2,136]),t(t2,[2,137]),t(t2,[2,138]),t(t2,[2,139]),t(t2,[2,140]),t(t2,[2,141]),t(tI,[2,122],{106:t1}),{10:[1,271]},t(tI,[2,123],{106:t1}),{10:[1,272]},t(tW,[2,129]),t(tI,[2,105],{106:t1}),t(tI,[2,106],{113:113,44:A,60:y,89:E,102:D,105:C,106:T,109:F,111:S,114:_,115:v,116:B}),t(tI,[2,110]),t(tI,[2,112],{10:[1,273]}),t(tI,[2,113]),{98:[1,274]},{51:[1,275]},{62:[1,276]},{66:[1,277]},{8:P,9:G,11:O,21:278},t(K,[2,34]),t(tt,[2,52]),{10:tj,60:tY,84:tH,105:tX,107:279,108:243,109:tq,110:tQ,111:tJ,112:tZ},t(t2,[2,133]),{14:U,44:W,60:z,89:j,101:280,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z,120:88},{14:U,44:W,60:z,89:j,101:281,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z,120:88},{98:[1,282]},t(tI,[2,120]),t(te,[2,58]),{30:283,67:tN,80:tK,81:tP,82:172,116:tG,117:tO,118:tM},t(te,[2,66]),t(tL,a,{5:284}),t(t0,[2,131],{108:270,10:tj,60:tY,84:tH,105:tX,109:tq,110:tQ,111:tJ,112:tZ}),t(tI,[2,126],{120:168,10:[1,285],14:U,44:W,60:z,89:j,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z}),t(tI,[2,127],{120:168,10:[1,286],14:U,44:W,60:z,89:j,105:Y,106:H,109:X,111:q,114:Q,115:J,116:Z}),t(tI,[2,114]),{31:[1,287],67:tN,82:219,116:tG,117:tO,118:tM},{6:11,7:12,8:n,9:u,10:l,11:o,20:17,22:18,23:19,24:20,25:21,26:22,27:c,32:[1,288],33:24,34:h,36:p,38:g,42:28,43:39,44:A,45:40,47:41,60:y,84:b,85:k,86:f,87:m,88:x,89:E,102:D,105:C,106:T,109:F,111:S,113:42,114:_,115:v,116:B,121:L,122:w,123:$,124:I,125:R},{10:tj,60:tY,84:tH,92:289,105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},{10:tj,60:tY,84:tH,92:290,105:tX,107:242,108:243,109:tq,110:tQ,111:tJ,112:tZ},t(te,[2,62]),t(K,[2,33]),t(tI,[2,124],{106:t1}),t(tI,[2,125],{106:t1})],defaultActions:{},parseError:(0,d.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var s=Error(t);throw s.hash=e,s}},"parseError"),parse:(0,d.K2)(function(t){var e=this,s=[0],i=[],r=[null],a=[],n=this.table,u="",l=0,o=0,c=0,h=a.slice.call(arguments,1),p=Object.create(this.lexer),g={};for(var A in this.yy)Object.prototype.hasOwnProperty.call(this.yy,A)&&(g[A]=this.yy[A]);p.setInput(t,g),g.lexer=p,g.parser=this,void 0===p.yylloc&&(p.yylloc={});var y=p.yylloc;a.push(y);var b=p.options&&p.options.ranges;function k(){var t;return"number"!=typeof(t=i.pop()||p.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof g.parseError?this.parseError=g.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,d.K2)(function(t){s.length=s.length-2*t,r.length=r.length-t,a.length=a.length-t},"popStack"),(0,d.K2)(k,"lex");for(var f,m,x,E,D,C,T,F,S,_={};;){if(x=s[s.length-1],this.defaultActions[x]?E=this.defaultActions[x]:(null==f&&(f=k()),E=n[x]&&n[x][f]),void 0===E||!E.length||!E[0]){var v="";for(C in S=[],n[x])this.terminals_[C]&&C>2&&S.push("'"+this.terminals_[C]+"'");v=p.showPosition?"Parse error on line "+(l+1)+":\n"+p.showPosition()+"\nExpecting "+S.join(", ")+", got '"+(this.terminals_[f]||f)+"'":"Parse error on line "+(l+1)+": Unexpected "+(1==f?"end of input":"'"+(this.terminals_[f]||f)+"'"),this.parseError(v,{text:p.match,token:this.terminals_[f]||f,line:p.yylineno,loc:y,expected:S})}if(E[0]instanceof Array&&E.length>1)throw Error("Parse Error: multiple actions possible at state: "+x+", token: "+f);switch(E[0]){case 1:s.push(f),r.push(p.yytext),a.push(p.yylloc),s.push(E[1]),f=null,m?(f=m,m=null):(o=p.yyleng,u=p.yytext,l=p.yylineno,y=p.yylloc,c>0&&c--);break;case 2:if(T=this.productions_[E[1]][1],_.$=r[r.length-T],_._$={first_line:a[a.length-(T||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(T||1)].first_column,last_column:a[a.length-1].last_column},b&&(_._$.range=[a[a.length-(T||1)].range[0],a[a.length-1].range[1]]),void 0!==(D=this.performAction.apply(_,[u,o,l,g,E[1],r,a].concat(h))))return D;T&&(s=s.slice(0,-1*T*2),r=r.slice(0,-1*T),a=a.slice(0,-1*T)),s.push(this.productions_[E[1]][0]),r.push(_.$),a.push(_._$),F=n[s[s.length-2]][s[s.length-1]],s.push(F);break;case 3:return!0}}return!0},"parse")};function t6(){this.yy={}}return t8.lexer={EOF:1,parseError:(0,d.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,d.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,d.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,d.K2)(function(t){var e=t.length,s=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var i=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),s.length-1&&(this.yylineno-=s.length-1);var r=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:s?(s.length===i.length?this.yylloc.first_column:0)+i[i.length-s.length].length-s[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[r[0],r[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,d.K2)(function(){return this._more=!0,this},"more"),reject:(0,d.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,d.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,d.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,d.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,d.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,d.K2)(function(t,e){var s,i,r;if(this.options.backtrack_lexer&&(r={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&&(r.yylloc.range=this.yylloc.range.slice(0))),(i=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=i.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:i?i[i.length-1].length-i[i.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],s=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),s)return s;if(this._backtrack)for(var a in r)this[a]=r[a];return!1},"test_match"),next:(0,d.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,s,i,r=this._currentRules(),a=0;a<r.length;a++)if((s=this._input.match(this.rules[r[a]]))&&(!e||s[0].length>e[0].length)){if(e=s,i=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(s,r[a])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,r[i]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,d.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,d.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,d.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,d.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,d.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,d.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,d.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:(0,d.K2)(function(t,e,s,i){switch(s){case 0:return this.begin("acc_title"),34;case 1:return this.popState(),"acc_title_value";case 2:return this.begin("acc_descr"),36;case 3:return this.popState(),"acc_descr_value";case 4:this.begin("acc_descr_multiline");break;case 5:case 12:case 14:case 17:case 20:case 23:case 33:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return this.pushState("shapeData"),e.yytext="",40;case 8:return this.pushState("shapeDataStr"),40;case 9:return this.popState(),40;case 10:return e.yytext=e.yytext.replace(/\n\s*/g,"<br/>"),40;case 11:return 40;case 13:this.begin("callbackname");break;case 15:this.popState(),this.begin("callbackargs");break;case 16:return 95;case 18:return 96;case 19:return"MD_STR";case 21:this.begin("md_string");break;case 22:return"STR";case 24:this.pushState("string");break;case 25:return 84;case 26:return 102;case 27:return 85;case 28:return 104;case 29:return 86;case 30:return 87;case 31:return 97;case 32:this.begin("click");break;case 34:return 88;case 35:case 36:case 37:return t.lex.firstGraph()&&this.begin("dir"),12;case 38:return 27;case 39:return 32;case 40:case 41:case 42:case 43:return 98;case 44:return this.popState(),13;case 45:case 46:case 47:case 48:case 49:case 50:case 51:case 52:case 53:case 54:return this.popState(),14;case 55:return 121;case 56:return 122;case 57:return 123;case 58:return 124;case 59:return 125;case 60:return 78;case 61:return 105;case 62:case 103:return 111;case 63:return 46;case 64:return 60;case 65:case 104:return 44;case 66:return 8;case 67:return 106;case 68:case 102:return 115;case 69:case 72:case 75:return this.popState(),77;case 70:return this.pushState("edgeText"),75;case 71:case 74:case 77:return 119;case 73:return this.pushState("thickEdgeText"),75;case 76:return this.pushState("dottedEdgeText"),75;case 78:return 77;case 79:return this.popState(),53;case 80:case 116:return"TEXT";case 81:return this.pushState("ellipseText"),52;case 82:return this.popState(),55;case 83:return this.pushState("text"),54;case 84:return this.popState(),57;case 85:return this.pushState("text"),56;case 86:return 58;case 87:return this.pushState("text"),67;case 88:return this.popState(),64;case 89:return this.pushState("text"),63;case 90:return this.popState(),49;case 91:return this.pushState("text"),48;case 92:return this.popState(),69;case 93:return this.popState(),71;case 94:return 117;case 95:return this.pushState("trapText"),68;case 96:return this.pushState("trapText"),70;case 97:return 118;case 98:return 67;case 99:return 90;case 100:return"SEP";case 101:return 89;case 105:return 109;case 106:return 114;case 107:return 116;case 108:return this.popState(),62;case 109:return this.pushState("text"),62;case 110:return this.popState(),51;case 111:return this.pushState("text"),50;case 112:return this.popState(),31;case 113:return this.pushState("text"),29;case 114:return this.popState(),66;case 115:return this.pushState("text"),65;case 117:return"QUOTE";case 118:return 9;case 119:return 10;case 120:return 11}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:.*direction\s+TD[^\n]*)/,/^(?:[^\s\"]+@(?=[^\{\"]))/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-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])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},shapeData:{rules:[8,11,12,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},callbackargs:{rules:[17,18,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},callbackname:{rules:[14,15,16,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},href:{rules:[21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},click:{rules:[21,24,33,34,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},dottedEdgeText:{rules:[21,24,75,77,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},thickEdgeText:{rules:[21,24,72,74,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},edgeText:{rules:[21,24,69,71,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},trapText:{rules:[21,24,78,81,83,85,89,91,92,93,94,95,96,109,111,113,115],inclusive:!1},ellipseText:{rules:[21,24,78,79,80,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},text:{rules:[21,24,78,81,82,83,84,85,88,89,90,91,95,96,108,109,110,111,112,113,114,115,116],inclusive:!1},vertex:{rules:[21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},acc_descr:{rules:[3,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},acc_title:{rules:[1,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},md_string:{rules:[19,20,21,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},string:{rules:[21,22,23,24,78,81,83,85,89,91,95,96,109,111,113,115],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,72,73,75,76,78,81,83,85,86,87,89,91,95,96,97,98,99,100,101,102,103,104,105,106,107,109,111,113,115,117,118,119,120],inclusive:!0}}},(0,d.K2)(t6,"Parser"),t6.prototype=t8,t8.Parser=t6,new t6}();m.parser=m;var x=Object.assign({},m);x.parse=t=>{let e=t.replace(/}\s*\n/g,"}\n");return m.parse(e)};var E=(0,d.K2)((t,e)=>{let s=A.A,i=s(t,"r"),r=s(t,"g"),a=s(t,"b");return y.A(i,r,a,e)},"fade"),D={parser:x,get db(){return new b},renderer:{getClasses:k,draw:f},styles:(0,d.K2)(t=>`.label {
20
+ font-family: ${t.fontFamily};
21
+ color: ${t.nodeTextColor||t.textColor};
22
+ }
23
+ .cluster-label text {
24
+ fill: ${t.titleColor};
25
+ }
26
+ .cluster-label span {
27
+ color: ${t.titleColor};
28
+ }
29
+ .cluster-label span p {
30
+ background-color: transparent;
31
+ }
32
+
33
+ .label text,span {
34
+ fill: ${t.nodeTextColor||t.textColor};
35
+ color: ${t.nodeTextColor||t.textColor};
36
+ }
37
+
38
+ .node rect,
39
+ .node circle,
40
+ .node ellipse,
41
+ .node polygon,
42
+ .node path {
43
+ fill: ${t.mainBkg};
44
+ stroke: ${t.nodeBorder};
45
+ stroke-width: ${t.strokeWidth??1}px;
46
+ }
47
+ .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label {
48
+ text-anchor: middle;
49
+ }
50
+ // .flowchart-label .text-outer-tspan {
51
+ // text-anchor: middle;
52
+ // }
53
+ // .flowchart-label .text-inner-tspan {
54
+ // text-anchor: start;
55
+ // }
56
+
57
+ .node .katex path {
58
+ fill: #000;
59
+ stroke: #000;
60
+ stroke-width: 1px;
61
+ }
62
+
63
+ .rough-node .label,.node .label, .image-shape .label, .icon-shape .label {
64
+ text-align: center;
65
+ }
66
+ .node.clickable {
67
+ cursor: pointer;
68
+ }
69
+
70
+
71
+ .root .anchor path {
72
+ fill: ${t.lineColor} !important;
73
+ stroke-width: 0;
74
+ stroke: ${t.lineColor};
75
+ }
76
+
77
+ .arrowheadPath {
78
+ fill: ${t.arrowheadColor};
79
+ }
80
+
81
+ .edgePath .path {
82
+ stroke: ${t.lineColor};
83
+ stroke-width: ${t.strokeWidth??2}px;
84
+ }
85
+
86
+ .flowchart-link {
87
+ stroke: ${t.lineColor};
88
+ fill: none;
89
+ }
90
+
91
+ .edgeLabel {
92
+ background-color: ${t.edgeLabelBackground};
93
+ p {
94
+ background-color: ${t.edgeLabelBackground};
95
+ }
96
+ rect {
97
+ opacity: 0.5;
98
+ background-color: ${t.edgeLabelBackground};
99
+ fill: ${t.edgeLabelBackground};
100
+ }
101
+ text-align: center;
102
+ }
103
+
104
+ /* For html labels only */
105
+ .labelBkg {
106
+ background-color: ${E(t.edgeLabelBackground,.5)};
107
+ // background-color:
108
+ }
109
+
110
+ .cluster rect {
111
+ fill: ${t.clusterBkg};
112
+ stroke: ${t.clusterBorder};
113
+ stroke-width: 1px;
114
+ }
115
+
116
+ .cluster text {
117
+ fill: ${t.titleColor};
118
+ }
119
+
120
+ .cluster span {
121
+ color: ${t.titleColor};
122
+ }
123
+ /* .cluster div {
124
+ color: ${t.titleColor};
125
+ } */
126
+
127
+ div.mermaidTooltip {
128
+ position: absolute;
129
+ text-align: center;
130
+ max-width: 200px;
131
+ padding: 2px;
132
+ font-family: ${t.fontFamily};
133
+ font-size: 12px;
134
+ background: ${t.tertiaryColor};
135
+ border: 1px solid ${t.border2};
136
+ border-radius: 2px;
137
+ pointer-events: none;
138
+ z-index: 100;
139
+ }
140
+
141
+ .flowchartTitleText {
142
+ text-anchor: middle;
143
+ font-size: 18px;
144
+ fill: ${t.textColor};
145
+ }
146
+
147
+ rect.text {
148
+ fill: none;
149
+ stroke-width: 0;
150
+ }
151
+
152
+ .icon-shape, .image-shape {
153
+ background-color: ${t.edgeLabelBackground};
154
+ p {
155
+ background-color: ${t.edgeLabelBackground};
156
+ padding: 2px;
157
+ }
158
+ .label rect {
159
+ opacity: 0.5;
160
+ background-color: ${t.edgeLabelBackground};
161
+ fill: ${t.edgeLabelBackground};
162
+ }
163
+ text-align: center;
164
+ }
165
+ ${(0,i.o)()}
166
+ `,"getStyles"),init:(0,d.K2)(t=>{t.flowchart||(t.flowchart={}),t.layout&&(0,h.XV)({layout:t.layout}),t.flowchart.arrowMarkerAbsolute=t.arrowMarkerAbsolute,(0,h.XV)({flowchart:{arrowMarkerAbsolute:t.arrowMarkerAbsolute}})},"init")}}}]);
_next/static/chunks/802.112d13381f11bef6.js ADDED
@@ -0,0 +1,141 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[802],{802:(t,e,r)=>{r.d(e,{diagram:()=>eb});var a=r(3580),i=r(1431),s=r(7920),n=r(1538),l=r(3736),o=r(669),c=r(316),d=r(2511),h=r(1652),g=r(9403),u=r(62);function y(t,e){for(let r in e)Object.hasOwn(e,r)&&(t[r]=e[r])}var p=r(4808),x=r(8247),b=r(5508),f=r(9856),m=function(){var t=(0,c.K2)(function(t,e,r,a){for(r=r||{},a=t.length;a--;r[t[a]]=e);return r},"o"),e=[1,15],r=[1,7],a=[1,13],i=[1,14],s=[1,19],n=[1,16],l=[1,17],o=[1,18],d=[8,30],h=[8,10,21,28,29,30,31,39,43,46],g=[1,23],u=[1,24],y=[8,10,15,16,21,28,29,30,31,39,43,46],p=[8,10,15,16,21,27,28,29,30,31,39,43,46],x=[1,49],b={trace:(0,c.K2)(function(){},"trace"),yy:{},symbols_:{error:2,spaceLines:3,SPACELINE:4,NL:5,separator:6,SPACE:7,EOF:8,start:9,BLOCK_DIAGRAM_KEY:10,document:11,stop:12,statement:13,link:14,LINK:15,START_LINK:16,LINK_LABEL:17,STR:18,nodeStatement:19,columnsStatement:20,SPACE_BLOCK:21,blockStatement:22,classDefStatement:23,cssClassStatement:24,styleStatement:25,node:26,SIZE:27,COLUMNS:28,"id-block":29,end:30,NODE_ID:31,nodeShapeNLabel:32,dirList:33,DIR:34,NODE_DSTART:35,NODE_DEND:36,BLOCK_ARROW_START:37,BLOCK_ARROW_END:38,classDef:39,CLASSDEF_ID:40,CLASSDEF_STYLEOPTS:41,DEFAULT:42,class:43,CLASSENTITY_IDS:44,STYLECLASS:45,style:46,STYLE_ENTITY_IDS:47,STYLE_DEFINITION_DATA:48,$accept:0,$end:1},terminals_:{2:"error",4:"SPACELINE",5:"NL",7:"SPACE",8:"EOF",10:"BLOCK_DIAGRAM_KEY",15:"LINK",16:"START_LINK",17:"LINK_LABEL",18:"STR",21:"SPACE_BLOCK",27:"SIZE",28:"COLUMNS",29:"id-block",30:"end",31:"NODE_ID",34:"DIR",35:"NODE_DSTART",36:"NODE_DEND",37:"BLOCK_ARROW_START",38:"BLOCK_ARROW_END",39:"classDef",40:"CLASSDEF_ID",41:"CLASSDEF_STYLEOPTS",42:"DEFAULT",43:"class",44:"CLASSENTITY_IDS",45:"STYLECLASS",46:"style",47:"STYLE_ENTITY_IDS",48:"STYLE_DEFINITION_DATA"},productions_:[0,[3,1],[3,2],[3,2],[6,1],[6,1],[6,1],[9,3],[12,1],[12,1],[12,2],[12,2],[11,1],[11,2],[14,1],[14,4],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[13,1],[19,3],[19,2],[19,1],[20,1],[22,4],[22,3],[26,1],[26,2],[33,1],[33,2],[32,3],[32,4],[23,3],[23,3],[24,3],[25,3]],performAction:(0,c.K2)(function(t,e,r,a,i,s,n){var l=s.length-1;switch(i){case 4:a.getLogger().debug("Rule: separator (NL) ");break;case 5:a.getLogger().debug("Rule: separator (Space) ");break;case 6:a.getLogger().debug("Rule: separator (EOF) ");break;case 7:a.getLogger().debug("Rule: hierarchy: ",s[l-1]),a.setHierarchy(s[l-1]);break;case 8:a.getLogger().debug("Stop NL ");break;case 9:a.getLogger().debug("Stop EOF ");break;case 10:a.getLogger().debug("Stop NL2 ");break;case 11:a.getLogger().debug("Stop EOF2 ");break;case 12:a.getLogger().debug("Rule: statement: ",s[l]),"number"==typeof s[l].length?this.$=s[l]:this.$=[s[l]];break;case 13:a.getLogger().debug("Rule: statement #2: ",s[l-1]),this.$=[s[l-1]].concat(s[l]);break;case 14:a.getLogger().debug("Rule: link: ",s[l],t),this.$={edgeTypeStr:s[l],label:""};break;case 15:a.getLogger().debug("Rule: LABEL link: ",s[l-3],s[l-1],s[l]),this.$={edgeTypeStr:s[l],label:s[l-1]};break;case 18:let o=parseInt(s[l]),c=a.generateId();this.$={id:c,type:"space",label:"",width:o,children:[]};break;case 23:a.getLogger().debug("Rule: (nodeStatement link node) ",s[l-2],s[l-1],s[l]," typestr: ",s[l-1].edgeTypeStr);let d=a.edgeStrToEdgeData(s[l-1].edgeTypeStr),h=a.edgeStrToEdgeStartData(s[l-1].edgeTypeStr),g=a.edgeStrToThickness(s[l-1].edgeTypeStr),u=a.edgeStrToPattern(s[l-1].edgeTypeStr);this.$=[{id:s[l-2].id,label:s[l-2].label,type:s[l-2].type,directions:s[l-2].directions},{id:s[l-2].id+"-"+s[l].id,start:s[l-2].id,end:s[l].id,label:s[l-1].label,type:"edge",thickness:g,pattern:u,directions:s[l].directions,arrowTypeEnd:d,arrowTypeStart:h},{id:s[l].id,label:s[l].label,type:a.typeStr2Type(s[l].typeStr),directions:s[l].directions}];break;case 24:a.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[l-1],s[l]),this.$={id:s[l-1].id,label:s[l-1].label,type:a.typeStr2Type(s[l-1].typeStr),directions:s[l-1].directions,widthInColumns:parseInt(s[l],10)};break;case 25:a.getLogger().debug("Rule: nodeStatement (node) ",s[l]),this.$={id:s[l].id,label:s[l].label,type:a.typeStr2Type(s[l].typeStr),directions:s[l].directions,widthInColumns:1};break;case 26:a.getLogger().debug("APA123",this?this:"na"),a.getLogger().debug("COLUMNS: ",s[l]),this.$={type:"column-setting",columns:"auto"===s[l]?-1:parseInt(s[l])};break;case 27:a.getLogger().debug("Rule: id-block statement : ",s[l-2],s[l-1]),a.generateId(),this.$={...s[l-2],type:"composite",children:s[l-1]};break;case 28:a.getLogger().debug("Rule: blockStatement : ",s[l-2],s[l-1],s[l]);let y=a.generateId();this.$={id:y,type:"composite",label:"",children:s[l-1]};break;case 29:a.getLogger().debug("Rule: node (NODE_ID separator): ",s[l]),this.$={id:s[l]};break;case 30:a.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[l-1],s[l]),this.$={id:s[l-1],label:s[l].label,typeStr:s[l].typeStr,directions:s[l].directions};break;case 31:a.getLogger().debug("Rule: dirList: ",s[l]),this.$=[s[l]];break;case 32:a.getLogger().debug("Rule: dirList: ",s[l-1],s[l]),this.$=[s[l-1]].concat(s[l]);break;case 33:a.getLogger().debug("Rule: nodeShapeNLabel: ",s[l-2],s[l-1],s[l]),this.$={typeStr:s[l-2]+s[l],label:s[l-1]};break;case 34:a.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[l-3],s[l-2]," #3:",s[l-1],s[l]),this.$={typeStr:s[l-3]+s[l],label:s[l-2],directions:s[l-1]};break;case 35:case 36:this.$={type:"classDef",id:s[l-1].trim(),css:s[l].trim()};break;case 37:this.$={type:"applyClass",id:s[l-1].trim(),styleClass:s[l].trim()};break;case 38:this.$={type:"applyStyles",id:s[l-1].trim(),stylesStr:s[l].trim()}}},"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{10:e,11:3,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,39:n,43:l,46:o},{8:[1,20]},t(d,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,10:e,21:r,28:a,29:i,31:s,39:n,43:l,46:o}),t(h,[2,16],{14:22,15:g,16:u}),t(h,[2,17]),t(h,[2,18]),t(h,[2,19]),t(h,[2,20]),t(h,[2,21]),t(h,[2,22]),t(y,[2,25],{27:[1,25]}),t(h,[2,26]),{19:26,26:12,31:s},{10:e,11:27,13:4,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,39:n,43:l,46:o},{40:[1,28],42:[1,29]},{44:[1,30]},{47:[1,31]},t(p,[2,29],{32:32,35:[1,33],37:[1,34]}),{1:[2,7]},t(d,[2,13]),{26:35,31:s},{31:[2,14]},{17:[1,36]},t(y,[2,24]),{10:e,11:37,13:4,14:22,15:g,16:u,19:5,20:6,21:r,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,39:n,43:l,46:o},{30:[1,38]},{41:[1,39]},{41:[1,40]},{45:[1,41]},{48:[1,42]},t(p,[2,30]),{18:[1,43]},{18:[1,44]},t(y,[2,23]),{18:[1,45]},{30:[1,46]},t(h,[2,28]),t(h,[2,35]),t(h,[2,36]),t(h,[2,37]),t(h,[2,38]),{36:[1,47]},{33:48,34:x},{15:[1,50]},t(h,[2,27]),t(p,[2,33]),{38:[1,51]},{33:52,34:x,38:[2,31]},{31:[2,15]},t(p,[2,34]),{38:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:(0,c.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var r=Error(t);throw r.hash=e,r}},"parseError"),parse:(0,c.K2)(function(t){var e=this,r=[0],a=[],i=[null],s=[],n=this.table,l="",o=0,d=0,h=0,g=s.slice.call(arguments,1),u=Object.create(this.lexer),y={};for(var p in this.yy)Object.prototype.hasOwnProperty.call(this.yy,p)&&(y[p]=this.yy[p]);u.setInput(t,y),y.lexer=u,y.parser=this,void 0===u.yylloc&&(u.yylloc={});var x=u.yylloc;s.push(x);var b=u.options&&u.options.ranges;function f(){var t;return"number"!=typeof(t=a.pop()||u.lex()||1)&&(t instanceof Array&&(t=(a=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof y.parseError?this.parseError=y.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,c.K2)(function(t){r.length=r.length-2*t,i.length=i.length-t,s.length=s.length-t},"popStack"),(0,c.K2)(f,"lex");for(var m,w,k,L,S,_,E,D,R,K={};;){if(k=r[r.length-1],this.defaultActions[k]?L=this.defaultActions[k]:(null==m&&(m=f()),L=n[k]&&n[k][m]),void 0===L||!L.length||!L[0]){var v="";for(_ in R=[],n[k])this.terminals_[_]&&_>2&&R.push("'"+this.terminals_[_]+"'");v=u.showPosition?"Parse error on line "+(o+1)+":\n"+u.showPosition()+"\nExpecting "+R.join(", ")+", got '"+(this.terminals_[m]||m)+"'":"Parse error on line "+(o+1)+": Unexpected "+(1==m?"end of input":"'"+(this.terminals_[m]||m)+"'"),this.parseError(v,{text:u.match,token:this.terminals_[m]||m,line:u.yylineno,loc:x,expected:R})}if(L[0]instanceof Array&&L.length>1)throw Error("Parse Error: multiple actions possible at state: "+k+", token: "+m);switch(L[0]){case 1:r.push(m),i.push(u.yytext),s.push(u.yylloc),r.push(L[1]),m=null,w?(m=w,w=null):(d=u.yyleng,l=u.yytext,o=u.yylineno,x=u.yylloc,h>0&&h--);break;case 2:if(E=this.productions_[L[1]][1],K.$=i[i.length-E],K._$={first_line:s[s.length-(E||1)].first_line,last_line:s[s.length-1].last_line,first_column:s[s.length-(E||1)].first_column,last_column:s[s.length-1].last_column},b&&(K._$.range=[s[s.length-(E||1)].range[0],s[s.length-1].range[1]]),void 0!==(S=this.performAction.apply(K,[l,d,o,y,L[1],i,s].concat(g))))return S;E&&(r=r.slice(0,-1*E*2),i=i.slice(0,-1*E),s=s.slice(0,-1*E)),r.push(this.productions_[L[1]][0]),i.push(K.$),s.push(K._$),D=n[r[r.length-2]][r[r.length-1]],r.push(D);break;case 3:return!0}}return!0},"parse")};function f(){this.yy={}}return b.lexer={EOF:1,parseError:(0,c.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,c.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,c.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,c.K2)(function(t){var e=t.length,r=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),r.length-1&&(this.yylineno-=r.length-1);var i=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:r?(r.length===a.length?this.yylloc.first_column:0)+a[a.length-r.length].length-r[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[i[0],i[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,c.K2)(function(){return this._more=!0,this},"more"),reject:(0,c.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,c.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,c.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,c.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,c.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,c.K2)(function(t,e){var r,a,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(a=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],r=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack)for(var s in i)this[s]=i[s];return!1},"test_match"),next:(0,c.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,r,a,i=this._currentRules(),s=0;s<i.length;s++)if((r=this._input.match(this.rules[i[s]]))&&(!e||r[0].length>e[0].length)){if(e=r,a=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(r,i[s])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[a]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,c.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,c.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,c.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,c.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,c.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,c.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,c.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:(0,c.K2)(function(t,e,r,a){switch(r){case 0:return t.getLogger().debug("Found block-beta"),10;case 1:return t.getLogger().debug("Found id-block"),29;case 2:return t.getLogger().debug("Found block"),10;case 3:t.getLogger().debug(".",e.yytext);break;case 4:t.getLogger().debug("_",e.yytext);break;case 5:return 5;case 6:return e.yytext=-1,28;case 7:return e.yytext=e.yytext.replace(/columns\s+/,""),t.getLogger().debug("COLUMNS (LEX)",e.yytext),28;case 8:case 76:case 77:case 99:this.pushState("md_string");break;case 9:return"MD_STR";case 10:case 34:case 79:this.popState();break;case 11:this.pushState("string");break;case 12:t.getLogger().debug("LEX: POPPING STR:",e.yytext),this.popState();break;case 13:return t.getLogger().debug("LEX: STR end:",e.yytext),"STR";case 14:return e.yytext=e.yytext.replace(/space\:/,""),t.getLogger().debug("SPACE NUM (LEX)",e.yytext),21;case 15:return e.yytext="1",t.getLogger().debug("COLUMNS (LEX)",e.yytext),21;case 16:return 42;case 17:return"LINKSTYLE";case 18:return"INTERPOLATE";case 19:return this.pushState("CLASSDEF"),39;case 20:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 21:return this.popState(),this.pushState("CLASSDEFID"),40;case 22:return this.popState(),41;case 23:return this.pushState("CLASS"),43;case 24:return this.popState(),this.pushState("CLASS_STYLE"),44;case 25:return this.popState(),45;case 26:return this.pushState("STYLE_STMNT"),46;case 27:return this.popState(),this.pushState("STYLE_DEFINITION"),47;case 28:return this.popState(),48;case 29:return this.pushState("acc_title"),"acc_title";case 30:return this.popState(),"acc_title_value";case 31:return this.pushState("acc_descr"),"acc_descr";case 32:return this.popState(),"acc_descr_value";case 33:this.pushState("acc_descr_multiline");break;case 35:return"acc_descr_multiline_value";case 36:return 30;case 37:case 38:case 40:case 41:case 44:return this.popState(),t.getLogger().debug("Lex: (("),"NODE_DEND";case 39:return this.popState(),t.getLogger().debug("Lex: ))"),"NODE_DEND";case 42:return this.popState(),t.getLogger().debug("Lex: (-"),"NODE_DEND";case 43:return this.popState(),t.getLogger().debug("Lex: -)"),"NODE_DEND";case 45:return this.popState(),t.getLogger().debug("Lex: ]]"),"NODE_DEND";case 46:return this.popState(),t.getLogger().debug("Lex: ("),"NODE_DEND";case 47:return this.popState(),t.getLogger().debug("Lex: ])"),"NODE_DEND";case 48:case 49:return this.popState(),t.getLogger().debug("Lex: /]"),"NODE_DEND";case 50:return this.popState(),t.getLogger().debug("Lex: )]"),"NODE_DEND";case 51:return this.popState(),t.getLogger().debug("Lex: )"),"NODE_DEND";case 52:return this.popState(),t.getLogger().debug("Lex: ]>"),"NODE_DEND";case 53:return this.popState(),t.getLogger().debug("Lex: ]"),"NODE_DEND";case 54:return t.getLogger().debug("Lexa: -)"),this.pushState("NODE"),35;case 55:return t.getLogger().debug("Lexa: (-"),this.pushState("NODE"),35;case 56:return t.getLogger().debug("Lexa: ))"),this.pushState("NODE"),35;case 57:case 59:case 60:case 61:case 64:return t.getLogger().debug("Lexa: )"),this.pushState("NODE"),35;case 58:return t.getLogger().debug("Lex: ((("),this.pushState("NODE"),35;case 62:return t.getLogger().debug("Lexc: >"),this.pushState("NODE"),35;case 63:return t.getLogger().debug("Lexa: (["),this.pushState("NODE"),35;case 65:case 66:case 67:case 68:case 69:case 70:case 71:return this.pushState("NODE"),35;case 72:return t.getLogger().debug("Lexa: ["),this.pushState("NODE"),35;case 73:return this.pushState("BLOCK_ARROW"),t.getLogger().debug("LEX ARR START"),37;case 74:return t.getLogger().debug("Lex: NODE_ID",e.yytext),31;case 75:return t.getLogger().debug("Lex: EOF",e.yytext),8;case 78:return"NODE_DESCR";case 80:t.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 81:t.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 82:return t.getLogger().debug("LEX: NODE_DESCR:",e.yytext),"NODE_DESCR";case 83:t.getLogger().debug("LEX POPPING"),this.popState();break;case 84:t.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 85:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (right): dir:",e.yytext),"DIR";case 86:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (left):",e.yytext),"DIR";case 87:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (x):",e.yytext),"DIR";case 88:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (y):",e.yytext),"DIR";case 89:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (up):",e.yytext),"DIR";case 90:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (down):",e.yytext),"DIR";case 91:return e.yytext="]>",t.getLogger().debug("Lex (ARROW_DIR end):",e.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 92:return t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 93:case 94:case 95:return t.getLogger().debug("Lex: LINK",e.yytext),15;case 96:case 97:case 98:return t.getLogger().debug("Lex: START_LINK",e.yytext),this.pushState("LLABEL"),16;case 100:return t.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 101:return this.popState(),t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 102:case 103:return this.popState(),t.getLogger().debug("Lex: LINK",e.yytext),15;case 104:return t.getLogger().debug("Lex: COLON",e.yytext),e.yytext=e.yytext.slice(1),27}},"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block:)/,/^(?:block\b)/,/^(?:[\s]+)/,/^(?:[\n]+)/,/^(?:((\u000D\u000A)|(\u000A)))/,/^(?:columns\s+auto\b)/,/^(?:columns\s+[\d]+)/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]*)/,/^(?:space[:]\d+)/,/^(?:space\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\s+)/,/^(?:DEFAULT\s+)/,/^(?:\w+\s+)/,/^(?:[^\n]*)/,/^(?:class\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:style\s+)/,/^(?:(\w+)+((,\s*\w+)*))/,/^(?:[^\n]*)/,/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:end\b\s*)/,/^(?:\(\(\()/,/^(?:\)\)\))/,/^(?:[\)]\))/,/^(?:\}\})/,/^(?:\})/,/^(?:\(-)/,/^(?:-\))/,/^(?:\(\()/,/^(?:\]\])/,/^(?:\()/,/^(?:\]\))/,/^(?:\\\])/,/^(?:\/\])/,/^(?:\)\])/,/^(?:[\)])/,/^(?:\]>)/,/^(?:[\]])/,/^(?:-\))/,/^(?:\(-)/,/^(?:\)\))/,/^(?:\))/,/^(?:\(\(\()/,/^(?:\(\()/,/^(?:\{\{)/,/^(?:\{)/,/^(?:>)/,/^(?:\(\[)/,/^(?:\()/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\[\\)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:\[)/,/^(?:<\[)/,/^(?:[^\(\[\n\-\)\{\}\s\<\>:=]+)/,/^(?:$)/,/^(?:["][`])/,/^(?:["][`])/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["])/,/^(?:["])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:\]>\s*\()/,/^(?:,?\s*right\s*)/,/^(?:,?\s*left\s*)/,/^(?:,?\s*x\s*)/,/^(?:,?\s*y\s*)/,/^(?:,?\s*up\s*)/,/^(?:,?\s*down\s*)/,/^(?:\)\s*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*~~[\~]+\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:["][`])/,/^(?:["])/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?::\d+)/],conditions:{STYLE_DEFINITION:{rules:[28],inclusive:!1},STYLE_STMNT:{rules:[27],inclusive:!1},CLASSDEFID:{rules:[22],inclusive:!1},CLASSDEF:{rules:[20,21],inclusive:!1},CLASS_STYLE:{rules:[25],inclusive:!1},CLASS:{rules:[24],inclusive:!1},LLABEL:{rules:[99,100,101,102,103],inclusive:!1},ARROW_DIR:{rules:[85,86,87,88,89,90,91],inclusive:!1},BLOCK_ARROW:{rules:[76,81,84],inclusive:!1},NODE:{rules:[37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,77,80],inclusive:!1},md_string:{rules:[9,10,78,79],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[12,13,82,83],inclusive:!1},acc_descr_multiline:{rules:[34,35],inclusive:!1},acc_descr:{rules:[32],inclusive:!1},acc_title:{rules:[30],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,11,14,15,16,17,18,19,23,26,29,31,33,36,54,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,92,93,94,95,96,97,98,104],inclusive:!0}}},(0,c.K2)(f,"Parser"),f.prototype=b,b.Parser=f,new f}();m.parser=m;var w=new Map,k=[],L=new Map,S="color",_="fill",E=(0,o.D7)(),D=new Map,R="",K=(0,c.K2)(t=>o.Y2.sanitizeText(t,E),"sanitizeText"),v=(0,c.K2)(function(t,e=""){let r=D.get(t);r||(r={id:t,styles:[],textStyles:[]},D.set(t,r)),null!=e&&e.split(",").forEach(t=>{let e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(S).exec(t)){let t=e.replace(_,"bgFill").replace(S,_);r.textStyles.push(t)}r.styles.push(e)})},"addStyleClass"),$=(0,c.K2)(function(t,e=""){let r=w.get(t);null!=e&&(r.styles=e.split(","))},"addStyle2Node"),T=(0,c.K2)(function(t,e){t.split(",").forEach(function(t){let r=w.get(t);if(void 0===r){let e=t.trim();r={id:e,type:"na",children:[]},w.set(e,r)}r.classes||(r.classes=[]),r.classes.push(e)})},"setCssClass"),I=(0,c.K2)((t,e)=>{let r=t.flat(),a=[],i=r.find(t=>t?.type==="column-setting"),s=i?.columns??-1;for(let t of r){if("number"==typeof s&&s>0&&"column-setting"!==t.type&&"number"==typeof t.widthInColumns&&t.widthInColumns>s&&c.Rm.warn(`Block ${t.id} width ${t.widthInColumns} exceeds configured column width ${s}`),t.label&&(t.label=K(t.label)),"classDef"===t.type){v(t.id,t.css);continue}if("applyClass"===t.type){T(t.id,t?.styleClass??"");continue}if("applyStyles"===t.type){t?.stylesStr&&$(t.id,t?.stylesStr);continue}if("column-setting"===t.type)e.columns=t.columns??-1;else if("edge"===t.type){let e=(L.get(t.id)??0)+1;L.set(t.id,e),t.id=e+"-"+t.id,k.push(t)}else{t.label||("composite"===t.type?t.label="":t.label=t.id);let e=w.get(t.id);if(void 0===e?w.set(t.id,t):("na"!==t.type&&(e.type=t.type),t.label!==t.id&&(e.label=t.label)),t.children&&I(t.children,t),"space"===t.type){let e=t.width??1;for(let r=0;r<e;r++){let e=function(t){if((0,d.s)(t))return t;let e=(0,h.b)(t);if(!function(t){switch((0,h.b)(t)){case g.R_:case g.Uw:case g.cT:case g.iq:case g.$V:case g.vC:case g.ri:case g.ML:case g.XZ:case g.i1:case g._u:case g.pj:case g.kj:case g.GX:case g.Av:case g.NA:case g.OG:case g.VP:case g.Qb:case g.q:case g.x6:case g.ZR:return!0;default:return!1}}(t))return{};if(Array.isArray(t)){let e=Array.from(t);return t.length>0&&"string"==typeof t[0]&&Object.hasOwn(t,"index")&&(e.index=t.index,e.input=t.input),e}if((0,u.i)(t))return new t.constructor(t.buffer,t.byteOffset,t.length);if("[object ArrayBuffer]"===e)return new ArrayBuffer(t.byteLength);if("[object DataView]"===e){let e=t.buffer,r=t.byteOffset,a=t.byteLength,i=new ArrayBuffer(a),s=new Uint8Array(e,r,a);return new Uint8Array(i).set(s),new DataView(i)}if("[object Boolean]"===e||"[object Number]"===e||"[object String]"===e){let r=new t.constructor(t.valueOf());return"[object String]"===e?function(t,e){let r=e.valueOf().length;for(let a in e)Object.hasOwn(e,a)&&(Number.isNaN(Number(a))||Number(a)>=r)&&(t[a]=e[a])}(r,t):y(r,t),r}if("[object Date]"===e)return new Date(Number(t));if("[object RegExp]"===e){let e=new RegExp(t.source,t.flags);return e.lastIndex=t.lastIndex,e}if("[object Symbol]"===e)return Object(Symbol.prototype.valueOf.call(t));if("[object Map]"===e){let e=new Map;return t.forEach((t,r)=>{e.set(r,t)}),e}if("[object Set]"===e){let e=new Set;return t.forEach(t=>{e.add(t)}),e}if("[object Arguments]"===e){let e={};return y(e,t),e.length=t.length,e[Symbol.iterator]=t[Symbol.iterator],e}let r={};return function(t,e){let r=Object.getPrototypeOf(e);null!==r&&"function"==typeof e.constructor&&Object.setPrototypeOf(t,r)}(r,t),y(r,t),function(t,e){let r=Object.getOwnPropertySymbols(e);for(let a=0;a<r.length;a++){let i=r[a];Object.prototype.propertyIsEnumerable.call(e,i)&&(t[i]=e[i])}}(r,t),r}(t);e.id=e.id+"-"+r,w.set(e.id,e),a.push(e)}}else void 0===e&&a.push(t)}}e.children=a},"populateBlockDatabase"),N=[],C={id:"root",type:"composite",children:[],columns:-1},B=(0,c.K2)(()=>{c.Rm.debug("Clear called"),(0,o.IU)(),w=new Map([["root",C={id:"root",type:"composite",children:[],columns:-1}]]),N=[],D=new Map,k=[],L=new Map,R=""},"clear");function O(t){switch(c.Rm.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return c.Rm.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}function z(t){return(c.Rm.debug("typeStr2Type",t),"=="===t)?"thick":"normal"}function A(t){switch(t.trim().slice(-1)){case"x":return"arrow_cross";case"o":return"arrow_circle";case">":return"arrow_point";default:return""}}function M(t){switch(t.trim().charAt(0)){case"x":return"arrow_cross";case"o":return"arrow_circle";case"<":return"arrow_point";default:return"arrow_open"}}function P(t){return t.includes("==")?"thick":"normal"}function j(t){return t.includes(".-")?"dotted":"solid"}(0,c.K2)(O,"typeStr2Type"),(0,c.K2)(z,"edgeTypeStr2Type"),(0,c.K2)(A,"edgeStrToEdgeData"),(0,c.K2)(M,"edgeStrToEdgeStartData"),(0,c.K2)(P,"edgeStrToThickness"),(0,c.K2)(j,"edgeStrToPattern");var W=0,Y=(0,c.K2)(()=>(W++,"id-"+Math.random().toString(36).substr(2,12)+"-"+W),"generateId"),F=(0,c.K2)(t=>{C.children=t,I(t,C),N=C.children},"setHierarchy"),X=(0,c.K2)(t=>{let e=w.get(t);return e?e.columns?e.columns:e.children?e.children.length:-1:-1},"getColumns"),U=(0,c.K2)(()=>[...w.values()],"getBlocksFlat"),H=(0,c.K2)(()=>N||[],"getBlocks"),Z=(0,c.K2)(()=>k,"getEdges"),q=(0,c.K2)(t=>w.get(t),"getBlock"),G=(0,c.K2)(t=>{w.set(t.id,t)},"setBlock"),V=(0,c.K2)(t=>{R=t},"setDiagramId"),J=(0,c.K2)(()=>R,"getDiagramId"),Q=(0,c.K2)(()=>c.Rm,"getLogger"),tt=(0,c.K2)(function(){return D},"getClasses"),te={getConfig:(0,c.K2)(()=>(0,o.zj)().block,"getConfig"),typeStr2Type:O,edgeTypeStr2Type:z,edgeStrToEdgeData:A,edgeStrToEdgeStartData:M,edgeStrToThickness:P,edgeStrToPattern:j,getLogger:Q,getBlocksFlat:U,getBlocks:H,getEdges:Z,setHierarchy:F,getBlock:q,setBlock:G,getColumns:X,getClasses:tt,clear:B,generateId:Y,setDiagramId:V,getDiagramId:J},tr=(0,c.K2)((t,e)=>{let r=p.A,a=r(t,"r"),i=r(t,"g"),s=r(t,"b");return x.A(a,i,s,e)},"fade"),ta=(0,c.K2)(t=>`.label {
2
+ font-family: ${t.fontFamily};
3
+ color: ${t.nodeTextColor||t.textColor};
4
+ }
5
+ .cluster-label text {
6
+ fill: ${t.titleColor};
7
+ }
8
+ .cluster-label span,p {
9
+ color: ${t.titleColor};
10
+ }
11
+
12
+
13
+
14
+ .label text,span,p {
15
+ fill: ${t.nodeTextColor||t.textColor};
16
+ color: ${t.nodeTextColor||t.textColor};
17
+ }
18
+
19
+ .node rect,
20
+ .node circle,
21
+ .node ellipse,
22
+ .node polygon,
23
+ .node path {
24
+ fill: ${t.mainBkg};
25
+ stroke: ${t.nodeBorder};
26
+ stroke-width: 1px;
27
+ }
28
+ .flowchart-label text {
29
+ text-anchor: middle;
30
+ }
31
+ // .flowchart-label .text-outer-tspan {
32
+ // text-anchor: middle;
33
+ // }
34
+ // .flowchart-label .text-inner-tspan {
35
+ // text-anchor: start;
36
+ // }
37
+
38
+ .node .label {
39
+ text-align: center;
40
+ }
41
+ .node.clickable {
42
+ cursor: pointer;
43
+ }
44
+
45
+ .arrowheadPath {
46
+ fill: ${t.arrowheadColor};
47
+ }
48
+
49
+ .edgePath .path {
50
+ stroke: ${t.lineColor};
51
+ stroke-width: 2.0px;
52
+ }
53
+
54
+ .flowchart-link {
55
+ stroke: ${t.lineColor};
56
+ fill: none;
57
+ }
58
+
59
+ .edgeLabel {
60
+ background-color: ${t.edgeLabelBackground};
61
+ /*
62
+ * This is for backward compatibility with existing code that didn't
63
+ * add a \`<p>\` around edge labels.
64
+ *
65
+ * TODO: We should probably remove this in a future release.
66
+ */
67
+ p {
68
+ margin: 0;
69
+ padding: 0;
70
+ display: inline;
71
+ }
72
+ rect {
73
+ opacity: 0.5;
74
+ background-color: ${t.edgeLabelBackground};
75
+ fill: ${t.edgeLabelBackground};
76
+ }
77
+ text-align: center;
78
+ }
79
+
80
+ /* For html labels only */
81
+ .labelBkg {
82
+ background-color: ${t.edgeLabelBackground};
83
+ }
84
+
85
+ .node .cluster {
86
+ // fill: ${tr(t.mainBkg,.5)};
87
+ fill: ${tr(t.clusterBkg,.5)};
88
+ stroke: ${tr(t.clusterBorder,.2)};
89
+ box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;
90
+ stroke-width: 1px;
91
+ }
92
+
93
+ .cluster text {
94
+ fill: ${t.titleColor};
95
+ }
96
+
97
+ .cluster span,p {
98
+ color: ${t.titleColor};
99
+ }
100
+ /* .cluster div {
101
+ color: ${t.titleColor};
102
+ } */
103
+
104
+ div.mermaidTooltip {
105
+ position: absolute;
106
+ text-align: center;
107
+ max-width: 200px;
108
+ padding: 2px;
109
+ font-family: ${t.fontFamily};
110
+ font-size: 12px;
111
+ background: ${t.tertiaryColor};
112
+ border: 1px solid ${t.border2};
113
+ border-radius: 2px;
114
+ pointer-events: none;
115
+ z-index: 100;
116
+ }
117
+
118
+ .flowchartTitleText {
119
+ text-anchor: middle;
120
+ font-size: 18px;
121
+ fill: ${t.textColor};
122
+ }
123
+ ${(0,a.o)()}
124
+ `,"getStyles"),ti=(0,c.K2)((t,e,r,a)=>{e.forEach(e=>{tg[e](t,r,a)})},"insertMarkers"),ts=(0,c.K2)((t,e,r)=>{c.Rm.trace("Making markers for ",r),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},"extension"),tn=(0,c.K2)((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),tl=(0,c.K2)((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),to=(0,c.K2)((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),tc=(0,c.K2)((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},"lollipop"),td=(0,c.K2)((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",6).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",r+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"point"),th=(0,c.K2)((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",r+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"circle"),tg={extension:ts,composition:tn,aggregation:tl,dependency:to,lollipop:tc,point:td,circle:th,cross:(0,c.K2)((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-crossEnd").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),t.append("marker").attr("id",r+"_"+e+"-crossStart").attr("class","marker cross "+e).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},"cross"),barb:(0,c.K2)((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","strokeWidth").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb")},tu=(0,o.D7)()?.block?.padding??8;function ty(t,e){if(0===t||!Number.isInteger(t))throw Error("Columns must be an integer !== 0.");if(e<0||!Number.isInteger(e))throw Error("Position must be a non-negative integer."+e);return t<0?{px:e,py:0}:1===t?{px:0,py:e}:{px:e%t,py:Math.floor(e/t)}}(0,c.K2)(ty,"calculateBlockPosition");var tp=(0,c.K2)(t=>{let e=0,r=0;for(let a of t.children){let{width:t,height:i,x:s,y:n}=a.size??{width:0,height:0,x:0,y:0};if(c.Rm.debug("getMaxChildSize abc95 child:",a.id,"width:",t,"height:",i,"x:",s,"y:",n,a.type),"space"===a.type)continue;let l=t/(a.widthInColumns??1);l>e&&(e=l),i>r&&(r=i)}return{width:e,height:r}},"getMaxChildSize");function tx(t,e,r=0,a=0){c.Rm.debug("setBlockSizes abc95 (start)",t.id,t?.size?.x,"block width =",t?.size,"siblingWidth",r),t?.size?.width||(t.size={width:r,height:a,x:0,y:0});let i=0,s=0;if(t.children?.length>0){for(let r of t.children)tx(r,e);let n=tp(t);for(let e of(i=n.width,s=n.height,c.Rm.debug("setBlockSizes abc95 maxWidth of",t.id,":s children is ",i,s),t.children))e.size&&(c.Rm.debug(`abc95 Setting size of children of ${t.id} id=${e.id} ${i} ${s} ${JSON.stringify(e.size)}`),e.size.width=i*(e.widthInColumns??1)+tu*((e.widthInColumns??1)-1),e.size.height=s,e.size.x=0,e.size.y=0,c.Rm.debug(`abc95 updating size of ${t.id} children child:${e.id} maxWidth:${i} maxHeight:${s}`));for(let r of t.children)tx(r,e,i,s);let l=t.columns??-1,o=0;for(let e of t.children)o+=e.widthInColumns??1;let d=t.children.length;l>0&&l<o&&(d=l);let h=Math.ceil(o/d),g=d*(i+tu)+tu,u=h*(s+tu)+tu;if(g<r){c.Rm.debug(`Detected to small sibling: abc95 ${t.id} siblingWidth ${r} siblingHeight ${a} width ${g}`),g=r,u=a;let e=(r-d*tu-tu)/d,n=(a-h*tu-tu)/h;for(let r of(c.Rm.debug("Size indata abc88",t.id,"childWidth",e,"maxWidth",i),c.Rm.debug("Size indata abc88",t.id,"childHeight",n,"maxHeight",s),c.Rm.debug("Size indata abc88 xSize",d,"padding",tu),t.children))r.size&&(r.size.width=e,r.size.height=n,r.size.x=0,r.size.y=0)}if(c.Rm.debug(`abc95 (finale calc) ${t.id} xSize ${d} ySize ${h} columns ${l}${t.children.length} width=${Math.max(g,t.size?.width||0)}`),g<(t?.size?.width||0)){g=t?.size?.width||0;let e=l>0?Math.min(t.children.length,l):t.children.length;if(e>0){let r=(g-e*tu-tu)/e;for(let e of(c.Rm.debug("abc95 (growing to fit) width",t.id,g,t.size?.width,r),t.children))e.size&&(e.size.width=r)}}t.size={width:g,height:u,x:0,y:0}}c.Rm.debug("setBlockSizes abc94 (done)",t.id,t?.size?.x,t?.size?.width,t?.size?.y,t?.size?.height)}function tb(t,e){c.Rm.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`);let r=t.columns??-1;if(c.Rm.debug("layoutBlocks columns abc95",t.id,"=>",r,t),t.children&&t.children.length>0){let a=t?.children[0]?.size?.width??0,i=t.children.length*a+(t.children.length-1)*tu;c.Rm.debug("widthOfChildren 88",i,"posX");let s=new Map;{let e=0;for(let a of t.children){if(!a.size)continue;let{py:t}=ty(r,e),i=s.get(t)??0;a.size.height>i&&s.set(t,a.size.height);let n=a?.widthInColumns??1;r>0&&(n=Math.min(n,r-e%r)),e+=n}}let n=new Map;{let t=0;for(let e of[...s.keys()].sort((t,e)=>t-e))n.set(e,t),t+=(s.get(e)??0)+tu}let l=0;c.Rm.debug("abc91 block?.size?.x",t.id,t?.size?.x);let o=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-tu,d=0;for(let a of t.children){if(!a.size)continue;let{width:i,height:h}=a.size,{px:g,py:u}=ty(r,l);if(u!=d&&(d=u,o=t?.size?.x?t?.size?.x+(-t?.size?.width/2||0):-tu,c.Rm.debug("New row in layout for block",t.id," and child ",a.id,d)),c.Rm.debug(`abc89 layout blocks (child) id: ${a.id} Pos: ${l} (px, py) ${g},${u} (${t?.size?.x},${t?.size?.y}) parent: ${t.id} width: ${i}${tu}`),t.size){let e=i/2;a.size.x=o+tu+e,c.Rm.debug(`abc91 layout blocks (calc) px, pyid:${a.id} startingPos=X${o} new startingPosX${a.size.x} ${e} padding=${tu} width=${i} halfWidth=${e} => x:${a.size.x} y:${a.size.y} ${a.widthInColumns} (width * (child?.w || 1)) / 2 ${i*(a?.widthInColumns??1)/2}`),o=a.size.x+e;let r=n.get(u)??0,l=s.get(u)??h;a.size.y=t.size.y-t.size.height/2+r+l/2+tu,c.Rm.debug(`abc88 layout blocks (calc) px, pyid:${a.id}startingPosX${o}${tu}${e}=>x:${a.size.x}y:${a.size.y}${a.widthInColumns}(width * (child?.w || 1)) / 2${i*(a?.widthInColumns??1)/2}`)}a.children&&tb(a,e);let y=a?.widthInColumns??1;r>0&&(y=Math.min(y,r-l%r)),l+=y,c.Rm.debug("abc88 columnsPos",a,l)}}c.Rm.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${t?.size?.x} y: ${t?.size?.y} width: ${t?.size?.width}`)}function tf(t,{minX:e,minY:r,maxX:a,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(t.size&&"root"!==t.id){let{x:s,y:n,width:l,height:o}=t.size;s-l/2<e&&(e=s-l/2),n-o/2<r&&(r=n-o/2),s+l/2>a&&(a=s+l/2),n+o/2>i&&(i=n+o/2)}if(t.children)for(let s of t.children)({minX:e,minY:r,maxX:a,maxY:i}=tf(s,{minX:e,minY:r,maxX:a,maxY:i}));return{minX:e,minY:r,maxX:a,maxY:i}}function tm(t){let e=t.getBlock("root");if(!e)return;tx(e,t,0,0),tb(e,t),c.Rm.debug("getBlocks",JSON.stringify(e,null,2));let{minX:r,minY:a,maxX:i,maxY:s}=tf(e);return{x:r,y:a,width:i-r,height:s-a}}(0,c.K2)(tx,"setBlockSizes"),(0,c.K2)(tb,"layoutBlocks"),(0,c.K2)(tf,"findBounds"),(0,c.K2)(tm,"layout");var tw=(0,c.K2)(async(t,e,r,a=!1,i=!1)=>{let s=e||"";"object"==typeof s&&(s=s[0]);let l=(0,o.D7)(),c=(0,o.E)(l);return await (0,n.GZ)(t,s,{style:r,isTitle:a,useHtmlLabels:c,markdown:!1,isNode:i,width:1/0},l)},"createLabel"),tk=(0,c.K2)((t,e,r,a,i)=>{e.arrowTypeStart&&tS(t,"start",e.arrowTypeStart,r,a,i),e.arrowTypeEnd&&tS(t,"end",e.arrowTypeEnd,r,a,i)},"addEdgeMarkers"),tL={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},tS=(0,c.K2)((t,e,r,a,i,s)=>{let n=tL[r];if(!n)return void c.Rm.warn(`Unknown arrow type: ${r}`);t.attr(`marker-${e}`,`url(${a}#${i}_${s}-${n}${"start"===e?"Start":"End"})`)},"addEdgeMarker"),t_={},tE={},tD=(0,c.K2)(async(t,e)=>{let r,a=(0,o.D7)(),s=(0,o.E)(a),l=t.insert("g").attr("class","edgeLabel"),c=l.insert("g").attr("class","label"),d="markdown"===e.labelType,h=await (0,n.GZ)(t,e.label,{style:e.labelStyle,useHtmlLabels:s,addSvgBackground:d,isNode:!1,markdown:d,width:d?void 0:1/0},a);c.node().appendChild(h);let g=h.getBBox(),u=g;if(s){let t=h.children[0],e=(0,b.Ltv)(h);u=g=t.getBoundingClientRect(),e.attr("width",g.width),e.attr("height",g.height)}else{let t=(0,b.Ltv)(h).select("text").node();t&&"function"==typeof t.getBBox&&(u=t.getBBox())}if(c.attr("transform",(0,i.Wg)(u,s)),t_[e.id]=l,e.width=g.width,e.height=g.height,e.startLabelLeft){let a=t.insert("g").attr("class","edgeTerminals"),n=a.insert("g").attr("class","inner"),l=await tw(n,e.startLabelLeft,e.labelStyle);r=l;let o=l.getBBox();if(s){let t=l.children[0],e=(0,b.Ltv)(l);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}n.attr("transform",(0,i.Wg)(o,s)),tE[e.id]||(tE[e.id]={}),tE[e.id].startLeft=a,tR(r,e.startLabelLeft)}if(e.startLabelRight){let a=t.insert("g").attr("class","edgeTerminals"),n=a.insert("g").attr("class","inner"),l=await tw(n,e.startLabelRight,e.labelStyle);r=l;let o=l.getBBox();if(s){let t=l.children[0],e=(0,b.Ltv)(l);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}n.attr("transform",(0,i.Wg)(o,s)),tE[e.id]||(tE[e.id]={}),tE[e.id].startRight=a,tR(r,e.startLabelRight)}if(e.endLabelLeft){let a=t.insert("g").attr("class","edgeTerminals"),n=a.insert("g").attr("class","inner"),l=await tw(a,e.endLabelLeft,e.labelStyle);r=l;let o=l.getBBox();if(s){let t=l.children[0],e=(0,b.Ltv)(l);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}n.attr("transform",(0,i.Wg)(o,s)),tE[e.id]||(tE[e.id]={}),tE[e.id].endLeft=a,tR(r,e.endLabelLeft)}if(e.endLabelRight){let a=t.insert("g").attr("class","edgeTerminals"),n=a.insert("g").attr("class","inner"),l=await tw(a,e.endLabelRight,e.labelStyle);r=l;let o=l.getBBox();if(s){let t=l.children[0],e=(0,b.Ltv)(l);o=t.getBoundingClientRect(),e.attr("width",o.width),e.attr("height",o.height)}n.attr("transform",(0,i.Wg)(o,s)),tE[e.id]||(tE[e.id]={}),tE[e.id].endRight=a,tR(r,e.endLabelRight)}return h},"insertEdgeLabel");function tR(t,e){(0,o.E)((0,o.D7)())&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}(0,c.K2)(tR,"setTerminalWidth");var tK=(0,c.K2)((t,e)=>{c.Rm.debug("Moving label abc88 ",t.id,t.label,t_[t.id],e);let r=e.updatedPath?e.updatedPath:e.originalPath,a=(0,o.D7)(),{subGraphTitleTotalMargin:i}=(0,s.O)(a);if(t.label){let a=t_[t.id],s=t.x,n=t.y;if(r){let a=l._K.calcLabelPosition(r);c.Rm.debug("Moving label "+t.label+" from (",s,",",n,") to (",a.x,",",a.y,") abc88"),e.updatedPath&&(s=a.x,n=a.y)}a.attr("transform",`translate(${s}, ${n+i/2})`)}if(t.startLabelLeft){let e=tE[t.id].startLeft,a=t.x,i=t.y;if(r){let e=l._K.calcTerminalLabelPosition(10*!!t.arrowTypeStart,"start_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.startLabelRight){let e=tE[t.id].startRight,a=t.x,i=t.y;if(r){let e=l._K.calcTerminalLabelPosition(10*!!t.arrowTypeStart,"start_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelLeft){let e=tE[t.id].endLeft,a=t.x,i=t.y;if(r){let e=l._K.calcTerminalLabelPosition(10*!!t.arrowTypeEnd,"end_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelRight){let e=tE[t.id].endRight,a=t.x,i=t.y;if(r){let e=l._K.calcTerminalLabelPosition(10*!!t.arrowTypeEnd,"end_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}},"positionEdgeLabel"),tv=(0,c.K2)((t,e)=>{let r=t.x,a=t.y,i=Math.abs(e.x-r),s=Math.abs(e.y-a),n=t.width/2,l=t.height/2;return!!(i>=n)||!!(s>=l)},"outsideNode"),t$=(0,c.K2)((t,e,r)=>{c.Rm.debug(`intersection calc abc89:
125
+ outsidePoint: ${JSON.stringify(e)}
126
+ insidePoint : ${JSON.stringify(r)}
127
+ node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);let a=t.x,i=t.y,s=Math.abs(a-r.x),n=t.width/2,l=r.x<e.x?n-s:n+s,o=t.height/2,d=Math.abs(e.y-r.y),h=Math.abs(e.x-r.x);if(Math.abs(i-e.y)*n>Math.abs(a-e.x)*o){let t=r.y<e.y?e.y-o-i:i-o-e.y;l=h*t/d;let a={x:r.x<e.x?r.x+l:r.x-h+l,y:r.y<e.y?r.y+d-t:r.y-d+t};return 0===l&&(a.x=e.x,a.y=e.y),0===h&&(a.x=e.x),0===d&&(a.y=e.y),c.Rm.debug(`abc89 topp/bott calc, Q ${d}, q ${t}, R ${h}, r ${l}`,a),a}{let t=d*(l=r.x<e.x?e.x-n-a:a-n-e.x)/h,i=r.x<e.x?r.x+h-l:r.x-h+l,s=r.y<e.y?r.y+t:r.y-t;return c.Rm.debug(`sides calc abc89, Q ${d}, q ${t}, R ${h}, r ${l}`,{_x:i,_y:s}),0===l&&(i=e.x,s=e.y),0===h&&(i=e.x),0===d&&(s=e.y),{x:i,y:s}}},"intersection"),tT=(0,c.K2)((t,e)=>{c.Rm.debug("abc88 cutPathAtIntersect",t,e);let r=[],a=t[0],i=!1;return t.forEach(t=>{if(tv(e,t)||i)a=t,i||r.push(t);else{let s=t$(e,a,t),n=!1;r.forEach(t=>{n=n||t.x===s.x&&t.y===s.y}),r.some(t=>t.x===s.x&&t.y===s.y)||r.push(s),i=!0}}),r},"cutPathAtIntersect"),tI=(0,c.K2)(function(t,e,r,a,s,n,l){let d,h=r.points;c.Rm.debug("abc88 InsertEdge: edge=",r,"e=",e);let g=!1,u=n.node(e.v);var y=n.node(e.w);y?.intersect&&u?.intersect&&((h=h.slice(1,r.points.length-1)).unshift(u.intersect(h[0])),h.push(y.intersect(h[h.length-1]))),r.toCluster&&(c.Rm.debug("to cluster abc88",a[r.toCluster]),h=tT(r.points,a[r.toCluster].node),g=!0),r.fromCluster&&(c.Rm.debug("from cluster abc88",a[r.fromCluster]),h=tT(h.reverse(),a[r.fromCluster].node).reverse(),g=!0);let p=h.filter(t=>!Number.isNaN(t.y)),x=b.qrM;r.curve&&("graph"===s||"flowchart"===s)&&(x=r.curve);let{x:f,y:m}=(0,i.RI)(r),w=(0,b.n8j)().x(f).y(m).curve(x);switch(r.thickness){case"normal":d="edge-thickness-normal";break;case"thick":case"invisible":d="edge-thickness-thick";break;default:d=""}switch(r.pattern){case"solid":d+=" edge-pattern-solid";break;case"dotted":d+=" edge-pattern-dotted";break;case"dashed":d+=" edge-pattern-dashed"}let k=t.append("path").attr("d",w(p)).attr("id",r.id).attr("class"," "+d+(r.classes?" "+r.classes:"")).attr("style",r.style),L="";((0,o.D7)().flowchart.arrowMarkerAbsolute||(0,o.D7)().state.arrowMarkerAbsolute)&&(L=(0,o.ID)(!0)),tk(k,r,L,l,s);let S={};return g&&(S.updatedPath=h),S.originalPath=r.points,S},"insertEdge"),tN=(0,c.K2)(t=>{let e=new Set;for(let r of t)switch(r){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(r)}return e},"expandAndDeduplicateDirections"),tC=(0,c.K2)((t,e,r,a)=>{let i=tN(t),s=e.height+2*r.padding,n=s/2,l=a??e.width+2*n+r.padding,o=r.padding/2;return i.has("right")&&i.has("left")&&i.has("up")&&i.has("down")?[{x:0,y:0},{x:n,y:0},{x:l/2,y:2*o},{x:l-n,y:0},{x:l,y:0},{x:l,y:-s/3},{x:l+2*o,y:-s/2},{x:l,y:-2*s/3},{x:l,y:-s},{x:l-n,y:-s},{x:l/2,y:-s-2*o},{x:n,y:-s},{x:0,y:-s},{x:0,y:-2*s/3},{x:-2*o,y:-s/2},{x:0,y:-s/3}]:i.has("right")&&i.has("left")&&i.has("up")?[{x:n,y:0},{x:l-n,y:0},{x:l,y:-s/2},{x:l-n,y:-s},{x:n,y:-s},{x:0,y:-s/2}]:i.has("right")&&i.has("left")&&i.has("down")?[{x:0,y:0},{x:n,y:-s},{x:l-n,y:-s},{x:l,y:0}]:i.has("right")&&i.has("up")&&i.has("down")?[{x:0,y:0},{x:l,y:-n},{x:l,y:-s+n},{x:0,y:-s}]:i.has("left")&&i.has("up")&&i.has("down")?[{x:l,y:0},{x:0,y:-n},{x:0,y:-s+n},{x:l,y:-s}]:i.has("right")&&i.has("left")?[{x:n,y:0},{x:n,y:-o},{x:l-n,y:-o},{x:l-n,y:0},{x:l,y:-s/2},{x:l-n,y:-s},{x:l-n,y:-s+o},{x:n,y:-s+o},{x:n,y:-s},{x:0,y:-s/2}]:i.has("up")&&i.has("down")?[{x:l/2,y:0},{x:0,y:-o},{x:n,y:-o},{x:n,y:-s+o},{x:0,y:-s+o},{x:l/2,y:-s},{x:l,y:-s+o},{x:l-n,y:-s+o},{x:l-n,y:-o},{x:l,y:-o}]:i.has("right")&&i.has("up")?[{x:0,y:0},{x:l,y:-n},{x:0,y:-s}]:i.has("right")&&i.has("down")?[{x:0,y:0},{x:l,y:0},{x:0,y:-s}]:i.has("left")&&i.has("up")?[{x:l,y:0},{x:0,y:-n},{x:l,y:-s}]:i.has("left")&&i.has("down")?[{x:l,y:0},{x:0,y:0},{x:l,y:-s}]:i.has("right")?[{x:n,y:-o},{x:n,y:-o},{x:l-n,y:-o},{x:l-n,y:0},{x:l,y:-s/2},{x:l-n,y:-s},{x:l-n,y:-s+o},{x:n,y:-s+o},{x:n,y:-s+o}]:i.has("left")?[{x:n,y:0},{x:n,y:-o},{x:l-n,y:-o},{x:l-n,y:-s+o},{x:n,y:-s+o},{x:n,y:-s},{x:0,y:-s/2}]:i.has("up")?[{x:n,y:-o},{x:n,y:-s+o},{x:0,y:-s+o},{x:l/2,y:-s},{x:l,y:-s+o},{x:l-n,y:-s+o},{x:l-n,y:-o}]:i.has("down")?[{x:l/2,y:0},{x:0,y:-o},{x:n,y:-o},{x:n,y:-s+o},{x:l-n,y:-s+o},{x:l-n,y:-o},{x:l,y:-o}]:[{x:0,y:0}]},"getArrowPoints");function tB(t,e,r,a){var i=t.x,s=t.y,n=i-a.x,l=s-a.y,o=Math.sqrt(e*e*l*l+r*r*n*n),c=Math.abs(e*r*n/o);a.x<i&&(c=-c);var d=Math.abs(e*r*l/o);return a.y<s&&(d=-d),{x:i+c,y:s+d}}function tO(t,e,r){return tB(t,e,e,r)}function tz(t,e,r,a){var i,s,n,l,o,c,d,h,g,u,y,p,x;if(i=e.y-t.y,n=t.x-e.x,o=e.x*t.y-t.x*e.y,g=i*r.x+n*r.y+o,u=i*a.x+n*a.y+o,!(0!==g&&0!==u&&tA(g,u))){if((s=a.y-r.y,l=r.x-a.x,c=a.x*r.y-r.x*a.y,d=s*t.x+l*t.y+c,h=s*e.x+l*e.y+c,!(0!==d&&0!==h&&tA(d,h)))&&0!=(y=i*l-s*n))return p=Math.abs(y/2),{x:(x=n*c-l*o)<0?(x-p)/y:(x+p)/y,y:(x=s*o-i*c)<0?(x-p)/y:(x+p)/y}}}function tA(t,e){return t*e>0}function tM(t,e,r){var a=t.x,i=t.y,s=[],n=1/0,l=1/0;"function"==typeof e.forEach?e.forEach(function(t){n=Math.min(n,t.x),l=Math.min(l,t.y)}):(n=Math.min(n,e.x),l=Math.min(l,e.y));for(var o=a-t.width/2-n,c=i-t.height/2-l,d=0;d<e.length;d++){var h=e[d],g=e[d<e.length-1?d+1:0],u=tz(t,r,{x:o+h.x,y:c+h.y},{x:o+g.x,y:c+g.y});u&&s.push(u)}return s.length?(s.length>1&&s.sort(function(t,e){var a=t.x-r.x,i=t.y-r.y,s=Math.sqrt(a*a+i*i),n=e.x-r.x,l=e.y-r.y,o=Math.sqrt(n*n+l*l);return s<o?-1:+(s!==o)}),s[0]):t}(0,c.K2)(function(t,e){return t.intersect(e)},"intersectNode"),(0,c.K2)(tB,"intersectEllipse"),(0,c.K2)(tO,"intersectCircle"),(0,c.K2)(tz,"intersectLine"),(0,c.K2)(tA,"sameSign"),(0,c.K2)(tM,"intersectPolygon");var tP={circle:tO,polygon:tM,rect:(0,c.K2)((t,e)=>{var r,a,i=t.x,s=t.y,n=e.x-i,l=e.y-s,o=t.width/2,c=t.height/2;return Math.abs(l)*o>Math.abs(n)*c?(l<0&&(c=-c),r=0===l?0:c*n/l,a=c):(n<0&&(o=-o),r=o,a=0===n?0:o*l/n),{x:i+r,y:s+a}},"intersectRect")},tj=(0,c.K2)(async(t,e,r,a)=>{let i,c,d=(0,o.D7)(),h=e.useHtmlLabels||(0,o.E)(d),g=t.insert("g").attr("class",r||"node default").attr("id",e.domId||e.id),u=g.insert("g").attr("class","label").attr("style",e.labelStyle);i=void 0===e.labelText?"":"string"==typeof e.labelText?e.labelText:e.labelText[0];let y=(c="markdown"===e.labelType?(0,n.GZ)(u,(0,o.jZ)((0,l.Sm)(i),d),{useHtmlLabels:h,width:e.width||d.flowchart.wrappingWidth,classes:"markdown-node-label"},d):await tw(u,(0,o.jZ)((0,l.Sm)(i),d),e.labelStyle,!1,a)).getBBox(),p=e.padding/2;if((0,o.E)(d)){let t=c.children[0],e=(0,b.Ltv)(c);await (0,s.X)(t,i),y=t.getBoundingClientRect(),e.attr("width",y.width),e.attr("height",y.height)}return h?u.attr("transform","translate("+-y.width/2+", "+-y.height/2+")"):u.attr("transform","translate(0, "+-y.height/2+")"),e.centerLabel&&u.attr("transform","translate("+-y.width/2+", "+-y.height/2+")"),u.insert("rect",":first-child"),{shapeSvg:g,bbox:y,halfPadding:p,label:u}},"labelHelper"),tW=(0,c.K2)((t,e)=>{let r=e.node().getBBox();t.width=r.width,t.height=r.height},"updateNodeBounds");function tY(t,e,r,a){return t.insert("polygon",":first-child").attr("points",a.map(function(t){return t.x+","+t.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+r/2+")")}(0,c.K2)(tY,"insertPolygonShape");var tF=(0,c.K2)(async(t,e)=>{e.useHtmlLabels||(0,o.E)((0,o.D7)())||(e.centerLabel=!0);let{shapeSvg:r,bbox:a,halfPadding:i}=await tj(t,e,"node "+e.classes,!0);c.Rm.info("Classes = ",e.classes);let s=r.insert("rect",":first-child");return s.attr("rx",e.rx).attr("ry",e.ry).attr("x",-a.width/2-i).attr("y",-a.height/2-i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),tW(e,s),e.intersect=function(t){return tP.rect(e,t)},r},"note"),tX=(0,c.K2)(t=>t?" "+t:"","formatClass"),tU=(0,c.K2)((t,e)=>`${e||"node default"}${tX(t.classes)} ${tX(t.class)}`,"getClassesFromNode"),tH=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding+(a.height+e.padding),s=[{x:i/2,y:0},{x:i,y:-i/2},{x:i/2,y:-i},{x:0,y:-i/2}];c.Rm.info("Question main (Circle)");let n=tY(r,i,i,s);return n.attr("style",e.style),tW(e,n),e.intersect=function(t){return c.Rm.warn("Intersect called"),tP.polygon(e,s,t)},r},"question"),tZ=(0,c.K2)((t,e)=>{let r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);return r.insert("polygon",":first-child").attr("points",[{x:0,y:14},{x:14,y:0},{x:0,y:-14},{x:-14,y:0}].map(function(t){return t.x+","+t.y}).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),e.width=28,e.height=28,e.intersect=function(t){return tP.circle(e,14,t)},r},"choice"),tq=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=e.positioned?e.height:a.height+e.padding,s=i/4,n=e.positioned?e.width:a.width+2*s+e.padding,l=[{x:s,y:0},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}],o=tY(r,n,i,l);return o.attr("style",e.style),tW(e,o),e.intersect=function(t){return tP.polygon(e,l,t)},r},"hexagon"),tG=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,void 0,!0),i=a.height+2*e.padding,s=i/2,n=a.width+2*s+e.padding,l=e.positioned&&(e.widthInColumns??1)>1&&e.width>n?e.width:n,o=tC(e.directions,a,e,l),c=tY(r,l,i,o);return c.attr("style",e.style),tW(e,c),e.intersect=function(t){return tP.polygon(e,o,t)},r},"block_arrow"),tV=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-s/2,y:0},{x:i,y:0},{x:i,y:-s},{x:-s/2,y:-s},{x:0,y:-s/2}];return tY(r,i,s,n).attr("style",e.style),e.width=i+s,e.height=s,e.intersect=function(t){return tP.polygon(e,n,t)},r},"rect_left_inv_arrow"),tJ=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:s/6,y:-s}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"lean_right"),tQ=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:2*s/6,y:0},{x:i+s/6,y:0},{x:i-2*s/6,y:-s},{x:-s/6,y:-s}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"lean_left"),t0=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i+2*s/6,y:0},{x:i-s/6,y:-s},{x:s/6,y:-s}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"trapezoid"),t1=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:-2*s/6,y:-s}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"inv_trapezoid"),t2=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i+s/2,y:0},{x:i,y:-s/2},{x:i+s/2,y:-s},{x:0,y:-s}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"rect_right_inv_arrow"),t3=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=i/2,n=s/(2.5+i/50),l=a.height+n+e.padding,o="M 0,"+n+" a "+s+","+n+" 0,0,0 "+i+" 0 a "+s+","+n+" 0,0,0 "+-i+" 0 l 0,"+l+" a "+s+","+n+" 0,0,0 "+i+" 0 l 0,"+-l,c=r.attr("label-offset-y",n).insert("path",":first-child").attr("style",e.style).attr("d",o).attr("transform","translate("+-i/2+","+-(l/2+n)+")");return tW(e,c),e.intersect=function(t){let r=tP.rect(e,t),a=r.x-e.x;if(0!=s&&(Math.abs(a)<e.width/2||Math.abs(a)==e.width/2&&Math.abs(r.y-e.y)>e.height/2-n)){let i=n*n*(1-a*a/(s*s));0!=i&&(i=Math.sqrt(i)),i=n-i,t.y-e.y>0&&(i=-i),r.y+=i}return r},r},"cylinder"),t4=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a,halfPadding:i}=await tj(t,e,"node "+e.classes+" "+e.class,!0),s=r.insert("rect",":first-child"),n=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,o=e.positioned?-n/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(s.attr("class","basic label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",o).attr("y",d).attr("width",n).attr("height",l),e.props){let t=new Set(Object.keys(e.props));e.props.borders&&(t9(s,e.props.borders,n,l),t.delete("borders")),t.forEach(t=>{c.Rm.warn(`Unknown node property ${t}`)})}return tW(e,s),e.intersect=function(t){return tP.rect(e,t)},r},"rect"),t8=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a,halfPadding:i}=await tj(t,e,"node "+e.classes,!0),s=r.insert("rect",":first-child"),n=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,o=e.positioned?-n/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(s.attr("class","basic cluster composite label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",o).attr("y",d).attr("width",n).attr("height",l),e.props){let t=new Set(Object.keys(e.props));e.props.borders&&(t9(s,e.props.borders,n,l),t.delete("borders")),t.forEach(t=>{c.Rm.warn(`Unknown node property ${t}`)})}return tW(e,s),e.intersect=function(t){return tP.rect(e,t)},r},"composite"),t5=(0,c.K2)(async(t,e)=>{let{shapeSvg:r}=await tj(t,e,"label",!0);c.Rm.trace("Classes = ",e.class);let a=r.insert("rect",":first-child");if(a.attr("width",0).attr("height",0),r.attr("class","label edgeLabel"),e.props){let t=new Set(Object.keys(e.props));e.props.borders&&(t9(a,e.props.borders,0,0),t.delete("borders")),t.forEach(t=>{c.Rm.warn(`Unknown node property ${t}`)})}return tW(e,a),e.intersect=function(t){return tP.rect(e,t)},r},"labelRect");function t9(t,e,r,a){let i=[],s=(0,c.K2)(t=>{i.push(t,0)},"addBorder"),n=(0,c.K2)(t=>{i.push(0,t)},"skipBorder");e.includes("t")?(c.Rm.debug("add top border"),s(r)):n(r),e.includes("r")?(c.Rm.debug("add right border"),s(a)):n(a),e.includes("b")?(c.Rm.debug("add bottom border"),s(r)):n(r),e.includes("l")?(c.Rm.debug("add left border"),s(a)):n(a),t.attr("stroke-dasharray",i.join(" "))}(0,c.K2)(t9,"applyNodePropertyBorders");var t7=(0,c.K2)(async(t,e)=>{let r;r=e.classes?"node "+e.classes:"node default";let a=t.insert("g").attr("class",r).attr("id",e.domId||e.id),i=a.insert("rect",":first-child"),s=a.insert("line"),n=a.insert("g").attr("class","label"),l=e.labelText.flat?e.labelText.flat():e.labelText,d="";d="object"==typeof l?l[0]:l,c.Rm.info("Label text abc79",d,l,"object"==typeof l);let h=await tw(n,d,e.labelStyle,!0,!0),g={width:0,height:0};if((0,o.E)((0,o.D7)())){let t=h.children[0],e=(0,b.Ltv)(h);g=t.getBoundingClientRect(),e.attr("width",g.width),e.attr("height",g.height)}c.Rm.info("Text 2",l);let u=l.slice(1,l.length),y=h.getBBox(),p=await tw(n,u.join?u.join("<br/>"):u,e.labelStyle,!0,!0);if((0,o.E)((0,o.D7)())){let t=p.children[0],e=(0,b.Ltv)(p);g=t.getBoundingClientRect(),e.attr("width",g.width),e.attr("height",g.height)}let x=e.padding/2;return(0,b.Ltv)(p).attr("transform","translate( "+(g.width>y.width?0:(y.width-g.width)/2)+", "+(y.height+x+5)+")"),(0,b.Ltv)(h).attr("transform","translate( "+(g.width<y.width?0:-(y.width-g.width)/2)+", 0)"),g=n.node().getBBox(),n.attr("transform","translate("+-g.width/2+", "+(-g.height/2-x+3)+")"),i.attr("class","outer title-state").attr("x",-g.width/2-x).attr("y",-g.height/2-x).attr("width",g.width+e.padding).attr("height",g.height+e.padding),s.attr("class","divider").attr("x1",-g.width/2-x).attr("x2",g.width/2+x).attr("y1",-g.height/2-x+y.height+x).attr("y2",-g.height/2-x+y.height+x),tW(e,i),e.intersect=function(t){return tP.rect(e,t)},a},"rectWithTitle"),t6=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.height+e.padding,s=a.width+i/4+e.padding,n=r.insert("rect",":first-child").attr("style",e.style).attr("rx",i/2).attr("ry",i/2).attr("x",-s/2).attr("y",-i/2).attr("width",s).attr("height",i);return tW(e,n),e.intersect=function(t){return tP.rect(e,t)},r},"stadium"),et=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a,halfPadding:i}=await tj(t,e,tU(e,void 0),!0),s=r.insert("circle",":first-child");return s.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),c.Rm.info("Circle main"),tW(e,s),e.intersect=function(t){return c.Rm.info("Circle intersect",e,a.width/2+i,t),tP.circle(e,a.width/2+i,t)},r},"circle"),ee=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a,halfPadding:i}=await tj(t,e,tU(e,void 0),!0),s=r.insert("g",":first-child"),n=s.insert("circle"),l=s.insert("circle");return s.attr("class",e.class),n.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i+5).attr("width",a.width+e.padding+10).attr("height",a.height+e.padding+10),l.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),c.Rm.info("DoubleCircle main"),tW(e,n),e.intersect=function(t){return c.Rm.info("DoubleCircle intersect",e,a.width/2+i+5,t),tP.circle(e,a.width/2+i+5,t)},r},"doublecircle"),er=(0,c.K2)(async(t,e)=>{let{shapeSvg:r,bbox:a}=await tj(t,e,tU(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i,y:0},{x:i,y:-s},{x:0,y:-s},{x:0,y:0},{x:-8,y:0},{x:i+8,y:0},{x:i+8,y:-s},{x:-8,y:-s},{x:-8,y:0}],l=tY(r,i,s,n);return l.attr("style",e.style),tW(e,l),e.intersect=function(t){return tP.polygon(e,n,t)},r},"subroutine"),ea=(0,c.K2)((t,e)=>{let r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child");return a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),tW(e,a),e.intersect=function(t){return tP.circle(e,7,t)},r},"start"),ei=(0,c.K2)((t,e,r)=>{let a=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),i=70,s=10;return"LR"===r&&(i=10,s=70),tW(e,a.append("rect").attr("x",-1*i/2).attr("y",-1*s/2).attr("width",i).attr("height",s).attr("class","fork-join")),e.height=e.height+e.padding/2,e.width=e.width+e.padding/2,e.intersect=function(t){return tP.rect(e,t)},a},"forkJoin"),es={rhombus:tH,composite:t8,question:tH,rect:t4,labelRect:t5,rectWithTitle:t7,choice:tZ,circle:et,doublecircle:ee,stadium:t6,hexagon:tq,block_arrow:tG,rect_left_inv_arrow:tV,lean_right:tJ,lean_left:tQ,trapezoid:t0,inv_trapezoid:t1,rect_right_inv_arrow:t2,cylinder:t3,start:ea,end:(0,c.K2)((t,e)=>{let r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child"),i=r.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),a.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),tW(e,i),e.intersect=function(t){return tP.circle(e,7,t)},r},"end"),note:tF,subroutine:er,fork:ei,join:ei,class_box:(0,c.K2)(async(t,e)=>{let r,a=e.padding/2;r=e.classes?"node "+e.classes:"node default";let i=t.insert("g").attr("class",r).attr("id",e.domId||e.id),s=i.insert("rect",":first-child"),n=i.insert("line"),l=i.insert("line"),c=0,d=4,h=i.insert("g").attr("class","label"),g=0,u=e.classData.annotations?.[0],y=e.classData.annotations[0]?"\xab"+e.classData.annotations[0]+"\xbb":"",p=await tw(h,y,e.labelStyle,!0,!0),x=p.getBBox();if((0,o.E)((0,o.D7)())){let t=p.children[0],e=(0,b.Ltv)(p);x=t.getBoundingClientRect(),e.attr("width",x.width),e.attr("height",x.height)}e.classData.annotations[0]&&(d+=x.height+4,c+=x.width);let f=e.classData.label;void 0!==e.classData.type&&""!==e.classData.type&&((0,o.E)((0,o.D7)())?f+="&lt;"+e.classData.type+"&gt;":f+="<"+e.classData.type+">");let m=await tw(h,f,e.labelStyle,!0,!0);(0,b.Ltv)(m).attr("class","classTitle");let w=m.getBBox();if((0,o.E)((0,o.D7)())){let t=m.children[0],e=(0,b.Ltv)(m);w=t.getBoundingClientRect(),e.attr("width",w.width),e.attr("height",w.height)}d+=w.height+4,w.width>c&&(c=w.width);let k=[];e.classData.members.forEach(async t=>{let r=t.getDisplayDetails(),a=r.displayText;(0,o.E)((0,o.D7)())&&(a=a.replace(/</g,"&lt;").replace(/>/g,"&gt;"));let i=await tw(h,a,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0),s=i.getBBox();if((0,o.E)((0,o.D7)())){let t=i.children[0],e=(0,b.Ltv)(i);s=t.getBoundingClientRect(),e.attr("width",s.width),e.attr("height",s.height)}s.width>c&&(c=s.width),d+=s.height+4,k.push(i)}),d+=8;let L=[];if(e.classData.methods.forEach(async t=>{let r=t.getDisplayDetails(),a=r.displayText;(0,o.E)((0,o.D7)())&&(a=a.replace(/</g,"&lt;").replace(/>/g,"&gt;"));let i=await tw(h,a,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0),s=i.getBBox();if((0,o.E)((0,o.D7)())){let t=i.children[0],e=(0,b.Ltv)(i);s=t.getBoundingClientRect(),e.attr("width",s.width),e.attr("height",s.height)}s.width>c&&(c=s.width),d+=s.height+4,L.push(i)}),d+=8,u){let t=(c-x.width)/2;(0,b.Ltv)(p).attr("transform","translate( "+(-1*c/2+t)+", "+-1*d/2+")"),g=x.height+4}let S=(c-w.width)/2;return(0,b.Ltv)(m).attr("transform","translate( "+(-1*c/2+S)+", "+(-1*d/2+g)+")"),g+=w.height+4,n.attr("class","divider").attr("x1",-c/2-a).attr("x2",c/2+a).attr("y1",-d/2-a+8+g).attr("y2",-d/2-a+8+g),g+=8,k.forEach(t=>{(0,b.Ltv)(t).attr("transform","translate( "+-c/2+", "+(-1*d/2+g+4)+")");let e=t?.getBBox();g+=(e?.height??0)+4}),g+=8,l.attr("class","divider").attr("x1",-c/2-a).attr("x2",c/2+a).attr("y1",-d/2-a+8+g).attr("y2",-d/2-a+8+g),g+=8,L.forEach(t=>{(0,b.Ltv)(t).attr("transform","translate( "+-c/2+", "+(-1*d/2+g)+")");let e=t?.getBBox();g+=(e?.height??0)+4}),s.attr("style",e.style).attr("class","outer title-state").attr("x",-c/2-a).attr("y",-(d/2)-a).attr("width",c+e.padding).attr("height",d+e.padding),tW(e,s),e.intersect=function(t){return tP.rect(e,t)},i},"class_box")},en={},el=(0,c.K2)(async(t,e,r)=>{let a,i;if(e.link){let s;"sandbox"===(0,o.D7)().securityLevel?s="_top":e.linkTarget&&(s=e.linkTarget||"_blank"),a=t.insert("svg:a").attr("xlink:href",e.link).attr("target",s),i=await es[e.shape](a,e,r)}else a=i=await es[e.shape](t,e,r);return e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),en[e.id]=a,e.haveCallback&&en[e.id].attr("class",en[e.id].attr("class")+" clickable"),a},"insertNode"),eo=(0,c.K2)(t=>{let e=en[t.id];c.Rm.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");let r=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+r-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),r},"positionNode");function ec(t,e,r=!1){let a,i="default";(t?.classes?.length||0)>0&&(i=(t?.classes??[]).join(" ")),i+=" flowchart-label";let s=0,n="";switch(t.type){case"round":s=5,n="rect";break;case"composite":s=0,n="composite",a=0;break;case"square":case"group":default:n="rect";break;case"diamond":n="question";break;case"hexagon":n="hexagon";break;case"block_arrow":n="block_arrow";break;case"odd":case"rect_left_inv_arrow":n="rect_left_inv_arrow";break;case"lean_right":n="lean_right";break;case"lean_left":n="lean_left";break;case"trapezoid":n="trapezoid";break;case"inv_trapezoid":n="inv_trapezoid";break;case"circle":n="circle";break;case"ellipse":n="ellipse";break;case"stadium":n="stadium";break;case"subroutine":n="subroutine";break;case"cylinder":n="cylinder";break;case"doublecircle":n="doublecircle"}let c=(0,l.sM)(t?.styles??[]),d=t.label,h=t.size??{width:0,height:0,x:0,y:0},g=e.getDiagramId();return{labelStyle:c.labelStyle,shape:n,labelText:d,rx:s,ry:s,class:i,style:c.style,id:t.id,domId:g?`${g}-${t.id}`:t.id,directions:t.directions,width:h.width,height:h.height,x:h.x,y:h.y,positioned:r,intersect:void 0,type:t.type,padding:a??(0,o.zj)()?.block?.padding??0,widthInColumns:t.widthInColumns??1}}async function ed(t,e,r){let a=ec(e,r,!1);if("group"===a.type)return;let i=(0,o.zj)(),s=await el(t,a,{config:i}),n=s.node().getBBox(),l=r.getBlock(a.id);l.size={width:n.width,height:n.height,x:0,y:0,node:s},r.setBlock(l),s.remove()}async function eh(t,e,r){let a=ec(e,r,!0);if("space"!==r.getBlock(a.id).type){let r=(0,o.zj)();await el(t,a,{config:r}),e.intersect=a?.intersect,eo(a)}}async function eg(t,e,r,a){for(let i of e)await a(t,i,r),i.children&&await eg(t,i.children,r,a)}async function eu(t,e,r){await eg(t,e,r,ed)}async function ey(t,e,r){await eg(t,e,r,eh)}async function ep(t,e,r,a,i){let s=new f.T({multigraph:!0,compound:!0});for(let t of(s.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8}),r))t.size&&s.setNode(t.id,{width:t.size.width,height:t.size.height,intersect:t.intersect});for(let r of e)if(r.start&&r.end){let e=a.getBlock(r.start),n=a.getBlock(r.end);if(e?.size&&n?.size){let a=e.size,l=n.size,o=[{x:a.x,y:a.y},{x:a.x+(l.x-a.x)/2,y:a.y+(l.y-a.y)/2},{x:l.x,y:l.y}],c=i?`${i}-${r.id}`:r.id,d="thick"===r.thickness?"edge-thickness-thick":"edge-thickness-normal",h="dotted"===r.pattern?"edge-pattern-dotted":"edge-pattern-solid",g=`${d} ${h} flowchart-link LS-a1 LE-b1`;tI(t,{v:r.start,w:r.end,name:c},{...r,id:c,arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:o,classes:g},void 0,"block",s,i),r.label&&(await tD(t,{...r,label:r.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:r.arrowTypeEnd,arrowTypeStart:r.arrowTypeStart,points:o,classes:g}),tK({...r,x:o[1].x,y:o[1].y},{originalPath:o}))}}}(0,c.K2)(ec,"getNodeFromBlock"),(0,c.K2)(ed,"calculateBlockSize"),(0,c.K2)(eh,"insertBlockPositioned"),(0,c.K2)(eg,"performOperations"),(0,c.K2)(eu,"calculateBlockSizes"),(0,c.K2)(ey,"insertBlocks"),(0,c.K2)(ep,"insertEdges");var ex=(0,c.K2)(function(t,e){return e.db.getClasses()},"getClasses"),eb={parser:m,db:te,renderer:{draw:(0,c.K2)(async function(t,e,r,a){let i,{securityLevel:s,block:n}=(0,o.zj)(),l=a.db;l.setDiagramId(e),"sandbox"===s&&(i=(0,b.Ltv)("#i"+e));let d="sandbox"===s?(0,b.Ltv)(i.nodes()[0].contentDocument.body):(0,b.Ltv)("body"),h="sandbox"===s?d.select(`[id="${e}"]`):(0,b.Ltv)(`[id="${e}"]`);ti(h,["point","circle","cross"],a.type,e);let g=l.getBlocks(),u=l.getBlocksFlat(),y=l.getEdges(),p=h.insert("g").attr("class","block");await eu(p,g,l);let x=tm(l);if(await ey(p,g,l),await ep(p,y,u,l,e),x){let t=Math.max(1,Math.round(.125*(x.width/x.height))),e=x.height+t+10,r=x.width+10,{useMaxWidth:a}=n;(0,o.a$)(h,e,r,!!a),c.Rm.debug("Here Bounds",x,x),h.attr("viewBox",`${x.x-5} ${x.y-5} ${x.width+10} ${x.height+10}`)}},"draw"),getClasses:ex},styles:ta}},3580:(t,e,r)=>{r.d(e,{o:()=>a});var a=(0,r(316).K2)(()=>`
128
+ /* Font Awesome icon styling - consolidated */
129
+ .label-icon {
130
+ display: inline-block;
131
+ height: 1em;
132
+ overflow: visible;
133
+ vertical-align: -0.125em;
134
+ }
135
+
136
+ .node .label-icon path {
137
+ fill: currentColor;
138
+ stroke: revert;
139
+ stroke-width: revert;
140
+ }
141
+ `,"getIconStyles")},4808:(t,e,r)=>{r.d(e,{A:()=>s});var a=r(5525),i=r(4984);let s=(t,e)=>a.A.lang.round(i.A.parse(t)[e])}}]);
_next/static/chunks/8050.7e59f099df2b9ec2.js ADDED
@@ -0,0 +1 @@
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[8050],{8050:(e,s,a)=>{a.d(s,{createWardleyServices:()=>c.J});var c=a(1516);a(4839)}}]);
_next/static/chunks/806.f53e1370d77cbb73.js ADDED
@@ -0,0 +1,64 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ "use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[806],{806:(t,e,i)=>{i.d(e,{diagram:()=>$});var s=i(2667),n=i(3736),a=i(669),r=i(316),h=i(2454),l=function(){var t=(0,r.K2)(function(t,e,i,s){for(i=i||{},s=t.length;s--;i[t[s]]=e);return i},"o"),e=[1,4],i=[1,14],s=[1,12],n=[1,13],a=[6,7,8],h=[1,20],l=[1,18],o=[1,19],c=[6,7,11],u=[1,6,13,14],d=[1,23],y=[1,24],p=[1,6,7,11,13,14],g={trace:(0,r.K2)(function(){},"trace"),yy:{},symbols_:{error:2,start:3,ishikawa:4,spaceLines:5,SPACELINE:6,NL:7,ISHIKAWA:8,document:9,stop:10,EOF:11,statement:12,SPACELIST:13,TEXT:14,$accept:0,$end:1},terminals_:{2:"error",6:"SPACELINE",7:"NL",8:"ISHIKAWA",11:"EOF",13:"SPACELIST",14:"TEXT"},productions_:[0,[3,1],[3,2],[5,1],[5,2],[5,2],[4,2],[4,3],[10,1],[10,1],[10,1],[10,2],[10,2],[9,3],[9,2],[12,2],[12,1],[12,1],[12,1]],performAction:(0,r.K2)(function(t,e,i,s,n,a,r){var h=a.length-1;switch(n){case 6:case 7:return s;case 15:s.addNode(a[h-1].length,a[h].trim());break;case 16:s.addNode(0,a[h].trim())}},"anonymous"),table:[{3:1,4:2,5:3,6:[1,5],8:e},{1:[3]},{1:[2,1]},{4:6,6:[1,7],7:[1,8],8:e},{6:i,7:[1,10],9:9,12:11,13:s,14:n},t(a,[2,3]),{1:[2,2]},t(a,[2,4]),t(a,[2,5]),{1:[2,6],6:i,12:15,13:s,14:n},{6:i,9:16,12:11,13:s,14:n},{6:h,7:l,10:17,11:o},t(c,[2,18],{14:[1,21]}),t(c,[2,16]),t(c,[2,17]),{6:h,7:l,10:22,11:o},{1:[2,7],6:i,12:15,13:s,14:n},t(u,[2,14],{7:d,11:y}),t(p,[2,8]),t(p,[2,9]),t(p,[2,10]),t(c,[2,15]),t(u,[2,13],{7:d,11:y}),t(p,[2,11]),t(p,[2,12])],defaultActions:{2:[2,1],6:[2,2]},parseError:(0,r.K2)(function(t,e){if(e.recoverable)this.trace(t);else{var i=Error(t);throw i.hash=e,i}},"parseError"),parse:(0,r.K2)(function(t){var e=this,i=[0],s=[],n=[null],a=[],h=this.table,l="",o=0,c=0,u=0,d=a.slice.call(arguments,1),y=Object.create(this.lexer),p={};for(var g in this.yy)Object.prototype.hasOwnProperty.call(this.yy,g)&&(p[g]=this.yy[g]);y.setInput(t,p),p.lexer=y,p.parser=this,void 0===y.yylloc&&(y.yylloc={});var f=y.yylloc;a.push(f);var k=y.options&&y.options.ranges;function m(){var t;return"number"!=typeof(t=s.pop()||y.lex()||1)&&(t instanceof Array&&(t=(s=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof p.parseError?this.parseError=p.parseError:this.parseError=Object.getPrototypeOf(this).parseError,(0,r.K2)(function(t){i.length=i.length-2*t,n.length=n.length-t,a.length=a.length-t},"popStack"),(0,r.K2)(m,"lex");for(var w,x,_,b,v,S,K,$,I,E={};;){if(_=i[i.length-1],this.defaultActions[_]?b=this.defaultActions[_]:(null==w&&(w=m()),b=h[_]&&h[_][w]),void 0===b||!b.length||!b[0]){var A="";for(S in I=[],h[_])this.terminals_[S]&&S>2&&I.push("'"+this.terminals_[S]+"'");A=y.showPosition?"Parse error on line "+(o+1)+":\n"+y.showPosition()+"\nExpecting "+I.join(", ")+", got '"+(this.terminals_[w]||w)+"'":"Parse error on line "+(o+1)+": Unexpected "+(1==w?"end of input":"'"+(this.terminals_[w]||w)+"'"),this.parseError(A,{text:y.match,token:this.terminals_[w]||w,line:y.yylineno,loc:f,expected:I})}if(b[0]instanceof Array&&b.length>1)throw Error("Parse Error: multiple actions possible at state: "+_+", token: "+w);switch(b[0]){case 1:i.push(w),n.push(y.yytext),a.push(y.yylloc),i.push(b[1]),w=null,x?(w=x,x=null):(c=y.yyleng,l=y.yytext,o=y.yylineno,f=y.yylloc,u>0&&u--);break;case 2:if(K=this.productions_[b[1]][1],E.$=n[n.length-K],E._$={first_line:a[a.length-(K||1)].first_line,last_line:a[a.length-1].last_line,first_column:a[a.length-(K||1)].first_column,last_column:a[a.length-1].last_column},k&&(E._$.range=[a[a.length-(K||1)].range[0],a[a.length-1].range[1]]),void 0!==(v=this.performAction.apply(E,[l,c,o,p,b[1],n,a].concat(d))))return v;K&&(i=i.slice(0,-1*K*2),n=n.slice(0,-1*K),a=a.slice(0,-1*K)),i.push(this.productions_[b[1]][0]),n.push(E.$),a.push(E._$),$=h[i[i.length-2]][i[i.length-1]],i.push($);break;case 3:return!0}}return!0},"parse")};function f(){this.yy={}}return g.lexer={EOF:1,parseError:(0,r.K2)(function(t,e){if(this.yy.parser)this.yy.parser.parseError(t,e);else throw Error(t)},"parseError"),setInput:(0,r.K2)(function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:(0,r.K2)(function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t},"input"),unput:(0,r.K2)(function(t){var e=t.length,i=t.split(/(?:\r\n?|\n)/g);this._input=t+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-e),this.offset-=e;var s=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),i.length-1&&(this.yylineno-=i.length-1);var n=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:i?(i.length===s.length?this.yylloc.first_column:0)+s[s.length-i.length].length-i[0].length:this.yylloc.first_column-e},this.options.ranges&&(this.yylloc.range=[n[0],n[0]+this.yyleng-e]),this.yyleng=this.yytext.length,this},"unput"),more:(0,r.K2)(function(){return this._more=!0,this},"more"),reject:(0,r.K2)(function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"reject"),less:(0,r.K2)(function(t){this.unput(this.match.slice(t))},"less"),pastInput:(0,r.K2)(function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:(0,r.K2)(function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:(0,r.K2)(function(){var t=this.pastInput(),e=Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"},"showPosition"),test_match:(0,r.K2)(function(t,e){var i,s,n;if(this.options.backtrack_lexer&&(n={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&&(n.yylloc.range=this.yylloc.range.slice(0))),(s=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=s.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:s?s[s.length-1].length-s[s.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],i=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),i)return i;if(this._backtrack)for(var a in n)this[a]=n[a];return!1},"test_match"),next:(0,r.K2)(function(){if(this.done)return this.EOF;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var t,e,i,s,n=this._currentRules(),a=0;a<n.length;a++)if((i=this._input.match(this.rules[n[a]]))&&(!e||i[0].length>e[0].length)){if(e=i,s=a,this.options.backtrack_lexer){if(!1!==(t=this.test_match(i,n[a])))return t;if(!this._backtrack)return!1;e=!1;continue}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,n[s]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:(0,r.K2)(function(){var t=this.next();return t||this.lex()},"lex"),begin:(0,r.K2)(function(t){this.conditionStack.push(t)},"begin"),popState:(0,r.K2)(function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:(0,r.K2)(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:(0,r.K2)(function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"},"topState"),pushState:(0,r.K2)(function(t){this.begin(t)},"pushState"),stateStackSize:(0,r.K2)(function(){return this.conditionStack.length},"stateStackSize"),options:{"case-insensitive":!0},performAction:(0,r.K2)(function(t,e,i,s){switch(i){case 0:case 3:return 6;case 1:case 2:return 8;case 4:return 7;case 5:return 13;case 6:return 14;case 7:return 11}},"anonymous"),rules:[/^(?:\s*%%.*)/i,/^(?:ishikawa-beta\b)/i,/^(?:ishikawa\b)/i,/^(?:[\s]+[\n])/i,/^(?:[\n]+)/i,/^(?:[\s]+)/i,/^(?:[^\n]+)/i,/^(?:$)/i],conditions:{INITIAL:{rules:[0,1,2,3,4,5,6,7],inclusive:!0}}},(0,r.K2)(f,"Parser"),f.prototype=g,g.Parser=f,new f}();l.parser=l;var o=class{constructor(){this.stack=[],this.clear=this.clear.bind(this),this.addNode=this.addNode.bind(this),this.getRoot=this.getRoot.bind(this)}static{(0,r.K2)(this,"IshikawaDB")}clear(){this.root=void 0,this.stack=[],this.baseLevel=void 0,(0,a.IU)()}getRoot(){return this.root}addNode(t,e){let i=a.Y2.sanitizeText(e,(0,a.D7)());if(!this.root){this.root={text:i,children:[]},this.stack=[{level:0,node:this.root}],(0,a.ke)(i);return}this.baseLevel??=t;let s=t-this.baseLevel+1;for(s<=0&&(s=1);this.stack.length>1&&this.stack[this.stack.length-1].level>=s;)this.stack.pop();let n=this.stack[this.stack.length-1].node,r={text:i,children:[]};n.children.push(r),this.stack.push({level:s,node:r})}getAccTitle(){return(0,a.iN)()}setAccTitle(t){(0,a.SV)(t)}getAccDescription(){return(0,a.m7)()}setAccDescription(t){(0,a.EI)(t)}getDiagramTitle(){return(0,a.ab)()}setDiagramTitle(t){(0,a.ke)(t)}},c=82*Math.PI/180,u=Math.cos(c),d=Math.sin(c),y=(0,r.K2)((t,e,i)=>{let s=t.node().getBBox(),n=s.width+2*e,r=s.height+2*e;(0,a.a$)(t,r,n,i),t.attr("viewBox",`${s.x-e} ${s.y-e} ${n} ${r}`)},"applyPaddedViewBox"),p=(0,r.K2)((t,e,i,r)=>{let l=r.db.getRoot();if(!l)return;let o=(0,a.D7)(),{look:c,handDrawnSeed:u,themeVariables:d}=o,p=(0,n.I5)(o.fontSize)[0]??14,k="handDrawn"===c,m=l.children??[],w=o.ishikawa?.diagramPadding??20,_=o.ishikawa?.useMaxWidth??!1,b=(0,s.D)(e),v=b.append("g").attr("class","ishikawa"),S=k?h.A.svg(b.node()):void 0,$=S?{roughSvg:S,seed:u??0,lineColor:d?.lineColor??"#333",fillColor:d?.mainBkg??"#fff"}:void 0,I=`ishikawa-arrow-${e}`;k||v.append("defs").append("marker").attr("id",I).attr("viewBox","0 0 10 10").attr("refX",0).attr("refY",5).attr("markerWidth",6).attr("markerHeight",6).attr("orient","auto").append("path").attr("d","M 10 0 L 0 5 L 10 10 Z").attr("class","ishikawa-arrow");let E=0,A=250,C=k?void 0:K(v,E,A,E,A,"ishikawa-spine");if(f(v,E,A,l.text,p,$),!m.length){k&&K(v,E,A,E,A,"ishikawa-spine",$),y(b,w,_);return}E-=20;let L=m.filter((t,e)=>e%2==0),M=m.filter((t,e)=>e%2==1),P=g(L),T=g(M),B=P.total+T.total,N=250,D=250;B>0&&(N=Math.max(75,500*(P.total/B)),D=Math.max(75,500*(T.total/B)));let O=2*p;N=Math.max(N,P.max*O),D=Math.max(D,T.max*O),A=Math.max(N,250),C&&C.attr("y1",A).attr("y2",A),v.select(".ishikawa-head-group").attr("transform",`translate(0,${A})`);let W=Math.ceil(m.length/2);for(let t=0;t<W;t++){let e=v.append("g").attr("class","ishikawa-pair");for(let[i,s,n]of[[m[2*t],-1,N],[m[2*t+1],1,D]])i&&x(e,i,E,A,s,n,p,$);E=e.selectAll("text").nodes().reduce((t,e)=>Math.min(t,e.getBBox().x),1/0)}if(k)K(v,E,A,0,A,"ishikawa-spine",$);else{C.attr("x1",E);let t=`url(#${I})`;v.selectAll("line.ishikawa-branch, line.ishikawa-sub-branch").attr("marker-start",t)}y(b,w,_)},"draw"),g=(0,r.K2)(t=>{let e=(0,r.K2)(t=>t.children.reduce((t,i)=>t+1+e(i),0),"countDescendants");return t.reduce((t,i)=>{let s=e(i);return t.total+=s,t.max=Math.max(t.max,s),t},{total:0,max:0})},"sideStats"),f=(0,r.K2)((t,e,i,s,n,a)=>{let r=Math.max(6,Math.floor(110/(.6*n))),h=t.append("g").attr("class","ishikawa-head-group").attr("transform",`translate(${e},${i})`),l=v(h,b(s,r),0,0,"ishikawa-head-label","start",n),o=l.node().getBBox(),c=Math.max(60,o.width+6),u=Math.max(40,2*o.height+40),d=`M 0 ${-u/2} L 0 ${u/2} Q ${2.4*c} 0 0 ${-u/2} Z`;if(a){let t=a.roughSvg.path(d,{roughness:1.5,seed:a.seed,fill:a.fillColor,fillStyle:"hachure",fillWeight:2.5,hachureGap:5,stroke:a.lineColor,strokeWidth:2});h.insert(()=>t,":first-child").attr("class","ishikawa-head")}else h.insert("path",":first-child").attr("class","ishikawa-head").attr("d",d);l.attr("transform",`translate(${(c-o.width)/2-o.x+3},${-o.y-o.height/2})`)},"drawHead"),k=(0,r.K2)((t,e)=>{let i=[],s=[],n=(0,r.K2)((t,a,r)=>{for(let h of -1===e?[...t].reverse():t){let t=i.length,e=h.children??[];i.push({depth:r,text:b(h.text,15),parentIndex:a,childCount:e.length}),r%2==0?(s.push(t),e.length&&n(e,t,r+1)):(e.length&&n(e,t,r+1),s.push(t))}},"walk");return n(t,-1,2),{entries:i,yOrder:s}},"flattenTree"),m=(0,r.K2)((t,e,i,s,n,a,r)=>{let h=t.append("g").attr("class","ishikawa-label-group"),l=v(h,e,i,s+11*n,"ishikawa-label cause","middle",a).node().getBBox();if(r){let t=r.roughSvg.rectangle(l.x-20,l.y-2,l.width+40,l.height+4,{roughness:1.5,seed:r.seed,fill:r.fillColor,fillStyle:"hachure",fillWeight:2.5,hachureGap:5,stroke:r.lineColor,strokeWidth:2});h.insert(()=>t,":first-child").attr("class","ishikawa-label-box")}else h.insert("rect",":first-child").attr("class","ishikawa-label-box").attr("x",l.x-20).attr("y",l.y-2).attr("width",l.width+40).attr("height",l.height+4)},"drawCauseLabel"),w=(0,r.K2)((t,e,i,s,n,a)=>{let r=Math.sqrt(s*s+n*n);if(0===r)return;let h=s/r,l=n/r,o=-(6*l),c=6*h,u=`M ${e} ${i} L ${e-6*h*2+o} ${i-6*l*2+c} L ${e-6*h*2-o} ${i-6*l*2-c} Z`,d=a.roughSvg.path(u,{roughness:1,seed:a.seed,fill:a.lineColor,fillStyle:"solid",stroke:a.lineColor,strokeWidth:1});t.append(()=>d)},"drawArrowMarker"),x=(0,r.K2)((t,e,i,s,n,a,r,h)=>{let l=e.children??[],o=a*(l.length?1:.2),c=d*o*n,y=i+-u*o,p=s+c;if(K(t,i,s,y,p,"ishikawa-branch",h),h&&w(t,i,s,i-y,s-p,h),m(t,e.text,y,p,n,r,h),!l.length)return;let{entries:g,yOrder:f}=k(l,n),x=g.length,_=Array(x);for(let[t,e]of f.entries())_[e]=s+(t+1)/(x+1)*c;let b=new Map;b.set(-1,{x0:i,y0:s,x1:y,y1:p,childCount:l.length,childrenDrawn:0});let $=-u,I=d*n,E=n<0?"ishikawa-label up":"ishikawa-label down";for(let[e,i]of g.entries()){let s=_[e],n=b.get(i.parentIndex),a=t.append("g").attr("class","ishikawa-sub-group"),l=0,o=0,c=0;if(i.depth%2==0){let t=n.y1-n.y0;l=S(n.x0,n.x1,t?(s-n.y0)/t:.5),o=s,c=l-(i.childCount>0?60+5*i.childCount:30),K(a,l,s,c,s,"ishikawa-sub-branch",h),h&&w(a,l,s,1,0,h),v(a,i.text,c,s,"ishikawa-label align","end",r)}else{let t=n.childrenDrawn++;c=(l=S(n.x0,n.x1,(n.childCount-t)/(n.childCount+1)))+(s-(o=n.y0))/I*$,K(a,l,o,c,s,"ishikawa-sub-branch",h),h&&w(a,l,o,l-c,o-s,h),v(a,i.text,c,s,E,"end",r)}i.childCount>0&&b.set(e,{x0:l,y0:o,x1:c,y1:s,childCount:i.childCount,childrenDrawn:0})}},"drawBranch"),_=(0,r.K2)(t=>t.split(/<br\s*\/?>|\n/),"splitLines"),b=(0,r.K2)((t,e)=>{if(t.length<=e)return t;let i=[];for(let s of t.split(/\s+/)){let t=i.length-1;t>=0&&i[t].length+1+s.length<=e?i[t]+=" "+s:i.push(s)}return i.join("\n")},"wrapText"),v=(0,r.K2)((t,e,i,s,n,a,r)=>{let h=_(e),l=1.05*r,o=t.append("text").attr("class",n).attr("text-anchor",a).attr("x",i).attr("y",s-(h.length-1)*l/2);for(let[t,e]of h.entries())o.append("tspan").attr("x",i).attr("dy",0===t?0:l).text(e);return o},"drawMultilineText"),S=(0,r.K2)((t,e,i)=>t+(e-t)*i,"lerp"),K=(0,r.K2)((t,e,i,s,n,a,r)=>{if(r){let h=r.roughSvg.line(e,i,s,n,{roughness:1.5,seed:r.seed,stroke:r.lineColor,strokeWidth:2});t.append(()=>h).attr("class",a);return}return t.append("line").attr("class",a).attr("x1",e).attr("y1",i).attr("x2",s).attr("y2",n)},"drawLine"),$={parser:l,get db(){return new o},renderer:{draw:p},styles:(0,r.K2)(t=>`
2
+ .ishikawa .ishikawa-spine,
3
+ .ishikawa .ishikawa-branch,
4
+ .ishikawa .ishikawa-sub-branch {
5
+ stroke: ${t.lineColor};
6
+ stroke-width: 2;
7
+ fill: none;
8
+ }
9
+
10
+ .ishikawa .ishikawa-sub-branch {
11
+ stroke-width: 1;
12
+ }
13
+
14
+ .ishikawa .ishikawa-arrow {
15
+ fill: ${t.lineColor};
16
+ }
17
+
18
+ .ishikawa .ishikawa-head {
19
+ fill: ${t.mainBkg};
20
+ stroke: ${t.lineColor};
21
+ stroke-width: 2;
22
+ }
23
+
24
+ .ishikawa .ishikawa-label-box {
25
+ fill: ${t.mainBkg};
26
+ stroke: ${t.lineColor};
27
+ stroke-width: 2;
28
+ }
29
+
30
+ .ishikawa text {
31
+ font-family: ${t.fontFamily};
32
+ font-size: ${t.fontSize};
33
+ fill: ${t.textColor};
34
+ }
35
+
36
+ .ishikawa .ishikawa-head-label {
37
+ font-weight: 600;
38
+ text-anchor: middle;
39
+ dominant-baseline: middle;
40
+ font-size: 14px;
41
+ }
42
+
43
+ .ishikawa .ishikawa-label {
44
+ text-anchor: end;
45
+ }
46
+
47
+ .ishikawa .ishikawa-label.cause {
48
+ text-anchor: middle;
49
+ dominant-baseline: middle;
50
+ }
51
+
52
+ .ishikawa .ishikawa-label.align {
53
+ text-anchor: end;
54
+ dominant-baseline: middle;
55
+ }
56
+
57
+ .ishikawa .ishikawa-label.up {
58
+ dominant-baseline: baseline;
59
+ }
60
+
61
+ .ishikawa .ishikawa-label.down {
62
+ dominant-baseline: hanging;
63
+ }
64
+ `,"getStyles")}}}]);
_next/static/chunks/821-19aed8db548f58e8.js ADDED
@@ -0,0 +1 @@
 
 
1
+ (self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[821],{126:(e,a,r)=>{"use strict";r.d(a,{gK:()=>c,ty:()=>n,uu:()=>i});var t=r(5155),s=r(2115);let l=(0,s.createContext)(null),n=e=>{let{sources:a,children:r}=e,s=new Map(a.map((e,a)=>[e.id,a+1]));return(0,t.jsx)(l.Provider,{value:{sources:a,numberFor:e=>{var a;return null!=(a=s.get(e))?a:null}},children:r})};function c(){let e=(0,s.useContext)(l);if(!e)throw Error("useCitations must be used within a CitationProvider");return e}let i=e=>{let{id:a}=e,{numberFor:r}=c(),s=r(a);return(0,t.jsx)("sup",{className:"paper-cite",children:(0,t.jsxs)("a",{href:"#ref-".concat(a),"aria-label":s?"Reference ".concat(s):"Missing reference",children:["[",null!=s?s:"?","]"]})})}},245:(e,a,r)=>{"use strict";r.d(a,{F:()=>m});var t=r(5155),s=r(2115),l=r(2619),n=r.n(l);let c=(0,r(1847).A)("arrow-left",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);var i=r(126),o=r(3601),d=r(5655);let p=()=>{let{sources:e}=(0,i.gK)();return 0===e.length?null:(0,t.jsxs)("section",{className:"paper-bibliography","aria-labelledby":"references-heading",children:[(0,t.jsx)("h2",{id:"references-heading","data-toc":"References",children:"References"}),(0,t.jsx)("ol",{className:"paper-ref-list",children:e.map((e,a)=>(0,t.jsxs)("li",{id:"ref-".concat(e.id),className:"paper-ref",children:[(0,t.jsxs)("span",{className:"paper-ref-num",children:["[",a+1,"]"]})," ",(0,t.jsxs)("span",{className:"paper-ref-body",children:[e.authors,". ",(0,t.jsx)("span",{className:"paper-ref-title",children:e.title}),"."," ",(0,t.jsx)("span",{className:"paper-ref-venue",children:e.venue}),", ",e.year,"."," ",(0,t.jsx)("a",{href:e.url,target:"_blank",rel:"noopener noreferrer",children:e.url}),e.accessed?" (accessed ".concat(e.accessed,")."):"."]})]},e.id))})]})};function h(){let[e,a]=(0,s.useState)(0);return(0,s.useEffect)(()=>{let e=()=>{let e=document.documentElement,r=e.scrollHeight-e.clientHeight;a(r>0?e.scrollTop/r*100:0)};return e(),window.addEventListener("scroll",e,{passive:!0}),()=>window.removeEventListener("scroll",e)},[]),(0,t.jsx)("div",{className:"paper-progress","aria-hidden":!0,children:(0,t.jsx)("div",{className:"paper-progress-fill",style:{width:"".concat(e,"%")}})})}function u(){let[e,a]=(0,s.useState)([]),[r,l]=(0,s.useState)("");return((0,s.useEffect)(()=>{let e=Array.from(document.querySelectorAll("article.paper-article h2[data-toc]"));a(e.map(e=>{let a=e.getAttribute("data-toc")||e.textContent||"";return e.id||(e.id=a.toLowerCase().replace(/[^a-z0-9]+/g,"-").replace(/(^-|-$)/g,"")),{id:e.id,label:a}}));let r=new IntersectionObserver(e=>{let a=e.filter(e=>e.isIntersecting).sort((e,a)=>e.boundingClientRect.top-a.boundingClientRect.top);a[0]&&l(a[0].target.id)},{rootMargin:"-10% 0px -75% 0px",threshold:0});return e.forEach(e=>r.observe(e)),()=>r.disconnect()},[]),0===e.length)?null:(0,t.jsxs)("nav",{className:"paper-toc","aria-label":"Table of contents",children:[(0,t.jsx)("p",{className:"paper-toc-title",children:"Contents"}),(0,t.jsx)("ol",{children:e.map(e=>(0,t.jsx)("li",{className:r===e.id?"active":"",children:(0,t.jsx)("a",{href:"#".concat(e.id),children:e.label})},e.id))})]})}let m=e=>{let{title:a,abstract:r,authors:s,publishedAt:l,slug:m,sources:x,readingTimeMinutes:j,children:f}=e,g=new Date(l),v="tmls:".concat(m,":").concat(g.getUTCFullYear(),"-").concat(String(g.getUTCMonth()+1).padStart(2,"0")),y=g.toLocaleDateString("en-US",{year:"numeric",month:"long",day:"numeric",timeZone:"UTC"}),b="@techreport{".concat(m.replace(/-/g,"")).concat(g.getUTCFullYear(),",\n title = {").concat(a,"},\n author = {").concat(s.join(" and "),"},\n institution = {TMLS AI Research},\n year = {").concat(g.getUTCFullYear(),"},\n type = {Research Report},\n number = {").concat(v,"},\n url = {https://tmls.nyc/research/").concat(m,"}\n}");return(0,t.jsx)(i.ty,{sources:x,children:(0,t.jsx)(o.s,{children:(0,t.jsxs)(d.yT,{children:[(0,t.jsx)(h,{}),(0,t.jsx)("div",{className:"paper-root",children:(0,t.jsxs)("div",{className:"paper-shell",children:[(0,t.jsxs)("aside",{className:"paper-sidebar",children:[(0,t.jsxs)(n(),{href:"/index.html",className:"paper-back",children:[(0,t.jsx)(c,{className:"w-4 h-4"}),"Research"]}),(0,t.jsx)(u,{})]}),(0,t.jsxs)("article",{className:"paper-article",children:[(0,t.jsxs)("header",{className:"paper-header",children:[(0,t.jsx)("p",{className:"paper-doi",children:v}),(0,t.jsx)("h1",{className:"paper-title",children:a}),(0,t.jsxs)("div",{className:"paper-meta",children:[(0,t.jsx)("span",{children:s.join(", ")}),(0,t.jsx)("span",{"aria-hidden":!0,children:"\xb7"}),(0,t.jsx)("time",{dateTime:g.toISOString(),children:y}),(0,t.jsx)("span",{"aria-hidden":!0,children:"\xb7"}),(0,t.jsxs)("span",{children:[j," min read"]})]}),(0,t.jsxs)("div",{className:"paper-abstract",children:[(0,t.jsx)("p",{className:"paper-abstract-label",children:"Abstract"}),(0,t.jsx)("p",{children:r})]})]}),f,(0,t.jsxs)("footer",{className:"paper-footer",children:[(0,t.jsx)(p,{}),(0,t.jsxs)("section",{className:"paper-howtocite",children:[(0,t.jsx)("h2",{"data-toc":"How to cite",children:"How to cite"}),(0,t.jsxs)("p",{children:[s.join(", "),". “",a,".” TMLS AI Research, ",y,". ",v,"."]}),(0,t.jsx)("pre",{className:"paper-bibtex",children:b})]}),(0,t.jsxs)("div",{className:"paper-colophon",children:[(0,t.jsx)("span",{className:"paper-colophon-mark",children:"TMLS AI Research"}),(0,t.jsx)("a",{href:"https://tmls.nyc/research",children:"tmls.nyc/research"})]})]})]})]})})]})})})}},987:(e,a,r)=>{"use strict";r.d(a,{P:()=>i});var t=r(5155);r(2115);var s=r(1847);let l=(0,s.A)("lightbulb",[["path",{d:"M15 14c.2-1 .7-1.7 1.5-2.5 1-.9 1.5-2.2 1.5-3.5A6 6 0 0 0 6 8c0 1 .2 2.2 1.5 3.5.7.7 1.3 1.5 1.5 2.5",key:"1gvzjb"}],["path",{d:"M9 18h6",key:"x1upvd"}],["path",{d:"M10 22h4",key:"ceow96"}]]),n=(0,s.A)("triangle-alert",[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]]),c={"cio-takeaway":{label:"CIO takeaway",Icon:l},warning:{label:"Warning",Icon:n},"case-study":{label:"Case study",Icon:(0,s.A)("flask-conical",[["path",{d:"M14 2v6a2 2 0 0 0 .245.96l5.51 10.08A2 2 0 0 1 18 22H6a2 2 0 0 1-1.755-2.96l5.51-10.08A2 2 0 0 0 10 8V2",key:"18mbvz"}],["path",{d:"M6.453 15h11.094",key:"3shlmq"}],["path",{d:"M8.5 2h7",key:"csnxdl"}]])},definition:{label:"Definition",Icon:(0,s.A)("book-marked",[["path",{d:"M10 2v8l3-3 3 3V2",key:"sqw3rj"}],["path",{d:"M4 19.5v-15A2.5 2.5 0 0 1 6.5 2H19a1 1 0 0 1 1 1v18a1 1 0 0 1-1 1H6.5a1 1 0 0 1 0-5H20",key:"k3hazp"}]])}},i=e=>{let{variant:a,title:r,children:s}=e,{label:l,Icon:n}=c[a];return(0,t.jsxs)("aside",{className:"paper-callout paper-callout-".concat(a),children:[(0,t.jsxs)("div",{className:"paper-callout-head",children:[(0,t.jsx)(n,{className:"paper-callout-icon"}),(0,t.jsx)("span",{className:"paper-callout-label",children:null!=r?r:l})]}),(0,t.jsx)("div",{className:"paper-callout-body",children:s})]})}},1847:(e,a,r)=>{"use strict";r.d(a,{A:()=>i});var t=r(2115);let s=e=>{let a=e.replace(/^([A-Z])|[\s-_]+(\w)/g,(e,a,r)=>r?r.toUpperCase():a.toLowerCase());return a.charAt(0).toUpperCase()+a.slice(1)},l=function(){for(var e=arguments.length,a=Array(e),r=0;r<e;r++)a[r]=arguments[r];return a.filter((e,a,r)=>!!e&&""!==e.trim()&&r.indexOf(e)===a).join(" ").trim()};var n={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};let c=(0,t.forwardRef)((e,a)=>{let{color:r="currentColor",size:s=24,strokeWidth:c=2,absoluteStrokeWidth:i,className:o="",children:d,iconNode:p,...h}=e;return(0,t.createElement)("svg",{ref:a,...n,width:s,height:s,stroke:r,strokeWidth:i?24*Number(c)/Number(s):c,className:l("lucide",o),...!d&&!(e=>{for(let a in e)if(a.startsWith("aria-")||"role"===a||"title"===a)return!0})(h)&&{"aria-hidden":"true"},...h},[...p.map(e=>{let[a,r]=e;return(0,t.createElement)(a,r)}),...Array.isArray(d)?d:[d]])}),i=(e,a)=>{let r=(0,t.forwardRef)((r,n)=>{let{className:i,...o}=r;return(0,t.createElement)(c,{ref:n,iconNode:a,className:l("lucide-".concat(s(e).replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase()),"lucide-".concat(e),i),...o})});return r.displayName=s(e),r}},3601:(e,a,r)=>{"use strict";r.d(a,{D:()=>c,s:()=>n});var t=r(5155),s=r(2115);let l=(0,s.createContext)(null),n=e=>{let{children:a}=e,r=(0,s.useRef)(0);return(0,t.jsx)(l.Provider,{value:{next:()=>r.current+=1},children:a})},c=e=>{var a;let{number:r,caption:n,children:c,id:i}=e,o=(0,s.useContext)(l),d=null!=(a=null!=r?r:null==o?void 0:o.next())?a:0;return(0,t.jsxs)("figure",{className:"paper-figure",id:null!=i?i:"figure-".concat(d),children:[(0,t.jsx)("div",{className:"paper-figure-body",children:c}),(0,t.jsxs)("figcaption",{className:"paper-figure-caption",children:[(0,t.jsxs)("span",{className:"paper-figure-label",children:["Figure ",d,"."]})," ",n]})]})}},5655:(e,a,r)=>{"use strict";r.d(a,{Ms:()=>d,yT:()=>c,zq:()=>o});var t=r(5155),s=r(2115),l=r(4739);let n=(0,s.createContext)(null),c=e=>{let{children:a}=e,r=(0,s.useRef)(0);return(0,t.jsx)(n.Provider,{value:{next:()=>r.current+=1},children:a})};function i(e,a){try{return l.default.renderToString(e,{displayMode:a,throwOnError:!1,output:"html"})}catch(a){return e}}let o=e=>{var a;let{tex:r,number:l,id:c}=e,o=(0,s.useContext)(n),d=null!=(a=null!=l?l:null==o?void 0:o.next())?a:0;return(0,t.jsxs)("div",{className:"paper-equation",id:null!=c?c:"eq-".concat(d),children:[(0,t.jsx)("div",{className:"paper-equation-body",dangerouslySetInnerHTML:{__html:i(r,!0)}}),(0,t.jsxs)("span",{className:"paper-equation-number",children:["(",d,")"]})]})},d=e=>{let{tex:a}=e;return(0,t.jsx)("span",{className:"paper-inline-eq",dangerouslySetInnerHTML:{__html:i(a,!1)}})}},6105:()=>{},6874:()=>{},9108:(e,a,r)=>{"use strict";r.d(a,{h:()=>d});var t=r(5155),s=r(2115),l=r(1847);let n=(0,l.A)("maximize-2",[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]]),c=(0,l.A)("x",[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]]),i=null,o=0,d=e=>{let{mermaid:a}=e,[l,d]=(0,s.useState)(""),[p,h]=(0,s.useState)(""),[u,m]=(0,s.useState)(!1),[x,j]=(0,s.useState)(!1),f=(0,s.useRef)("mmd-".concat(++o));return(0,s.useEffect)(()=>{let e=!1;return(!i&&(i=Promise.all([r.e(2941),r.e(2995),r.e(8499)]).then(r.bind(r,4725)).then(e=>{let a=e.default;return a.initialize({startOnLoad:!1,securityLevel:"strict",theme:"base",themeVariables:{background:"#000000",primaryColor:"#141414",primaryBorderColor:"#8b5cf6",primaryTextColor:"#f7f8f8",secondaryColor:"#1a1a1a",tertiaryColor:"#141414",lineColor:"#a3a3a3",textColor:"#f7f8f8",clusterBkg:"#0a0a0a",clusterBorder:"#333333",fontFamily:"ui-monospace, SFMono-Regular, Menlo, Consolas, monospace",fontSize:"14px"}}),a})),i).then(e=>e.render(f.current,a.trim())).then(a=>{let{svg:r}=a;e||d(r)}).catch(a=>{var r;e||h(String(null!=(r=null==a?void 0:a.message)?r:a))}),()=>{e=!0}},[a]),(0,s.useEffect)(()=>{if(!x)return;let e=e=>"Escape"===e.key&&j(!1);return window.addEventListener("keydown",e),document.body.style.overflow="hidden",()=>{window.removeEventListener("keydown",e),document.body.style.overflow=""}},[x]),(0,t.jsxs)("div",{className:"paper-diagram",children:[p?(0,t.jsxs)("pre",{className:"paper-diagram-error",children:["Diagram error: ",p]}):l?(0,t.jsx)("button",{type:"button",className:"paper-diagram-svg",onClick:()=>j(!0),"aria-label":"Zoom diagram",dangerouslySetInnerHTML:{__html:l}}):(0,t.jsx)("div",{className:"paper-diagram-loading",children:"Rendering diagram…"}),l&&!p&&(0,t.jsxs)("button",{type:"button",className:"paper-diagram-zoom",onClick:()=>j(!0),children:[(0,t.jsx)(n,{className:"w-3.5 h-3.5"}),"Zoom"]}),(0,t.jsxs)("details",{className:"paper-diagram-source",open:u,onToggle:e=>m(e.target.open),children:[(0,t.jsx)("summary",{children:"View source"}),(0,t.jsx)("pre",{children:a.trim()})]}),x&&(0,t.jsxs)("div",{className:"paper-diagram-overlay",role:"dialog","aria-modal":"true",onClick:()=>j(!1),children:[(0,t.jsx)("button",{type:"button",className:"paper-diagram-overlay-close",onClick:()=>j(!1),"aria-label":"Close",children:(0,t.jsx)(c,{className:"w-5 h-5"})}),(0,t.jsx)("div",{className:"paper-diagram-overlay-svg",onClick:e=>e.stopPropagation(),dangerouslySetInnerHTML:{__html:l}})]})]})}}}]);