Spaces:
Sleeping
Sleeping
var t,e;import{_ as r,E as a,d as i,l as s,v as n,A as o,c as l,a1 as c,a2 as d,a3 as h,a4 as g,u,j as y,a5 as p,a6 as x,a7 as b,h as f}from"./mermaid-D0MGOvVE.js";import{c as m}from"./clone-DIWvwcEg.js";import{s as w}from"./transform-CdY8z5kT.js";import{G as k}from"./graph-XoNMemoA.js";import{c as L}from"./channel-DSdDJBaV.js";import{l as S,k as _}from"./step-xJWGRC3d.js";import"./index-BiV-b1K2.js";import"./_baseUniq-DUj_-ybn.js";import"./_baseEach-DDZLUgL5.js";var v=function(){var t=r((function(t,e,r,a){for(r=r||{},a=t.length;a--;r[t[a]]=e);return r}),"o"),e=[1,7],a=[1,13],i=[1,14],s=[1,15],n=[1,19],o=[1,16],l=[1,17],c=[1,18],d=[8,30],h=[8,21,28,29,30,31,32,40,44,47],g=[1,23],u=[1,24],y=[8,15,16,21,28,29,30,31,32,40,44,47],p=[8,15,16,21,27,28,29,30,31,32,40,44,47],x=[1,49],b={trace:r((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,block:31,NODE_ID:32,nodeShapeNLabel:33,dirList: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:49,$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:"block",32:"NODE_ID",35:"DIR",36:"NODE_DSTART",37:"NODE_DEND",38:"BLOCK_ARROW_START",39:"BLOCK_ARROW_END",40:"classDef",41:"CLASSDEF_ID",42:"CLASSDEF_STYLEOPTS",43:"DEFAULT",44:"class",45:"CLASSENTITY_IDS",46:"STYLECLASS",47:"style",48:"STYLE_ENTITY_IDS",49:"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],[34,1],[34,2],[33,3],[33,4],[23,3],[23,3],[24,3],[25,3]],performAction:r((function(t,e,r,a,i,s,n){var o=s.length-1;switch(i){case 4:a.getLogger().debug("Rule: separator (NL) ");break;case 5:a.getLogger().debug("Rule: separator (Space) ");break;case 6:a.getLogger().debug("Rule: separator (EOF) ");break;case 7:a.getLogger().debug("Rule: hierarchy: ",s[o-1]),a.setHierarchy(s[o-1]);break;case 8:a.getLogger().debug("Stop NL ");break;case 9:a.getLogger().debug("Stop EOF ");break;case 10:a.getLogger().debug("Stop NL2 ");break;case 11:a.getLogger().debug("Stop EOF2 ");break;case 12:a.getLogger().debug("Rule: statement: ",s[o]),"number"==typeof s[o].length?this.$=s[o]:this.$=[s[o]];break;case 13:a.getLogger().debug("Rule: statement #2: ",s[o-1]),this.$=[s[o-1]].concat(s[o]);break;case 14:a.getLogger().debug("Rule: link: ",s[o],t),this.$={edgeTypeStr:s[o],label:""};break;case 15:a.getLogger().debug("Rule: LABEL link: ",s[o-3],s[o-1],s[o]),this.$={edgeTypeStr:s[o],label:s[o-1]};break;case 18:const e=parseInt(s[o]),r=a.generateId();this.$={id:r,type:"space",label:"",width:e,children:[]};break;case 23:a.getLogger().debug("Rule: (nodeStatement link node) ",s[o-2],s[o-1],s[o]," typestr: ",s[o-1].edgeTypeStr);const i=a.edgeStrToEdgeData(s[o-1].edgeTypeStr);this.$=[{id:s[o-2].id,label:s[o-2].label,type:s[o-2].type,directions:s[o-2].directions},{id:s[o-2].id+"-"+s[o].id,start:s[o-2].id,end:s[o].id,label:s[o-1].label,type:"edge",directions:s[o].directions,arrowTypeEnd:i,arrowTypeStart:"arrow_open"},{id:s[o].id,label:s[o].label,type:a.typeStr2Type(s[o].typeStr),directions:s[o].directions}];break;case 24:a.getLogger().debug("Rule: nodeStatement (abc88 node size) ",s[o-1],s[o]),this.$={id:s[o-1].id,label:s[o-1].label,type:a.typeStr2Type(s[o-1].typeStr),directions:s[o-1].directions,widthInColumns:parseInt(s[o],10)};break;case 25:a.getLogger().debug("Rule: nodeStatement (node) ",s[o]),this.$={id:s[o].id,label:s[o].label,type:a.typeStr2Type(s[o].typeStr),directions:s[o].directions,widthInColumns:1};break;case 26:a.getLogger().debug("APA123",this?this:"na"),a.getLogger().debug("COLUMNS: ",s[o]),this.$={type:"column-setting",columns:"auto"===s[o]?-1:parseInt(s[o])};break;case 27:a.getLogger().debug("Rule: id-block statement : ",s[o-2],s[o-1]),a.generateId(),this.$={...s[o-2],type:"composite",children:s[o-1]};break;case 28:a.getLogger().debug("Rule: blockStatement : ",s[o-2],s[o-1],s[o]);const n=a.generateId();this.$={id:n,type:"composite",label:"",children:s[o-1]};break;case 29:a.getLogger().debug("Rule: node (NODE_ID separator): ",s[o]),this.$={id:s[o]};break;case 30:a.getLogger().debug("Rule: node (NODE_ID nodeShapeNLabel separator): ",s[o-1],s[o]),this.$={id:s[o-1],label:s[o].label,typeStr:s[o].typeStr,directions:s[o].directions};break;case 31:a.getLogger().debug("Rule: dirList: ",s[o]),this.$=[s[o]];break;case 32:a.getLogger().debug("Rule: dirList: ",s[o-1],s[o]),this.$=[s[o-1]].concat(s[o]);break;case 33:a.getLogger().debug("Rule: nodeShapeNLabel: ",s[o-2],s[o-1],s[o]),this.$={typeStr:s[o-2]+s[o],label:s[o-1]};break;case 34:a.getLogger().debug("Rule: BLOCK_ARROW nodeShapeNLabel: ",s[o-3],s[o-2]," #3:",s[o-1],s[o]),this.$={typeStr:s[o-3]+s[o],label:s[o-2],directions:s[o-1]};break;case 35:case 36:this.$={type:"classDef",id:s[o-1].trim(),css:s[o].trim()};break;case 37:this.$={type:"applyClass",id:s[o-1].trim(),styleClass:s[o].trim()};break;case 38:this.$={type:"applyStyles",id:s[o-1].trim(),stylesStr:s[o].trim()}}}),"anonymous"),table:[{9:1,10:[1,2]},{1:[3]},{11:3,13:4,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,32:n,40:o,44:l,47:c},{8:[1,20]},t(d,[2,12],{13:4,19:5,20:6,22:8,23:9,24:10,25:11,26:12,11:21,21:e,28:a,29:i,31:s,32:n,40:o,44:l,47:c}),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,32:n},{11:27,13:4,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,32:n,40:o,44:l,47:c},{41:[1,28],43:[1,29]},{45:[1,30]},{48:[1,31]},t(p,[2,29],{33:32,36:[1,33],38:[1,34]}),{1:[2,7]},t(d,[2,13]),{26:35,32:n},{32:[2,14]},{17:[1,36]},t(y,[2,24]),{11:37,13:4,14:22,15:g,16:u,19:5,20:6,21:e,22:8,23:9,24:10,25:11,26:12,28:a,29:i,31:s,32:n,40:o,44:l,47:c},{30:[1,38]},{42:[1,39]},{42:[1,40]},{46:[1,41]},{49:[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]),{37:[1,47]},{34:48,35:x},{15:[1,50]},t(h,[2,27]),t(p,[2,33]),{39:[1,51]},{34:52,35:x,39:[2,31]},{32:[2,15]},t(p,[2,34]),{39:[2,32]}],defaultActions:{20:[2,7],23:[2,14],50:[2,15],52:[2,32]},parseError:r((function(t,e){if(!e.recoverable){var r=new Error(t);throw r.hash=e,r}this.trace(t)}),"parseError"),parse:r((function(t){var e=this,a=[0],i=[],s=[null],n=[],o=this.table,l="",c=0,d=0,h=n.slice.call(arguments,1),g=Object.create(this.lexer),u={yy:{}};for(var y in this.yy)Object.prototype.hasOwnProperty.call(this.yy,y)&&(u.yy[y]=this.yy[y]);g.setInput(t,u.yy),u.yy.lexer=g,u.yy.parser=this,void 0===g.yylloc&&(g.yylloc={});var p=g.yylloc;n.push(p);var x=g.options&&g.options.ranges;function b(){var t;return"number"!=typeof(t=i.pop()||g.lex()||1)&&(t instanceof Array&&(t=(i=t).pop()),t=e.symbols_[t]||t),t}"function"==typeof u.yy.parseError?this.parseError=u.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError,r((function(t){a.length=a.length-2*t,s.length=s.length-t,n.length=n.length-t}),"popStack"),r(b,"lex");for(var f,m,w,k,L,S,_,v,E={};;){if(m=a[a.length-1],this.defaultActions[m]?w=this.defaultActions[m]:(null==f&&(f=b()),w=o[m]&&o[m][f]),void 0===w||!w.length||!w[0]){var D="";for(L in v=[],o[m])this.terminals_[L]&&L>2&&v.push("'"+this.terminals_[L]+"'");D=g.showPosition?"Parse error on line "+(c+1)+":\n"+g.showPosition()+"\nExpecting "+v.join(", ")+", got '"+(this.terminals_[f]||f)+"'":"Parse error on line "+(c+1)+": Unexpected "+(1==f?"end of input":"'"+(this.terminals_[f]||f)+"'"),this.parseError(D,{text:g.match,token:this.terminals_[f]||f,line:g.yylineno,loc:p,expected:v})}if(w[0]instanceof Array&&w.length>1)throw new Error("Parse Error: multiple actions possible at state: "+m+", token: "+f);switch(w[0]){case 1:a.push(f),s.push(g.yytext),n.push(g.yylloc),a.push(w[1]),f=null,d=g.yyleng,l=g.yytext,c=g.yylineno,p=g.yylloc;break;case 2:if(S=this.productions_[w[1]][1],E.$=s[s.length-S],E._$={first_line:n[n.length-(S||1)].first_line,last_line:n[n.length-1].last_line,first_column:n[n.length-(S||1)].first_column,last_column:n[n.length-1].last_column},x&&(E._$.range=[n[n.length-(S||1)].range[0],n[n.length-1].range[1]]),void 0!==(k=this.performAction.apply(E,[l,d,c,u.yy,w[1],s,n].concat(h))))return k;S&&(a=a.slice(0,-1*S*2),s=s.slice(0,-1*S),n=n.slice(0,-1*S)),a.push(this.productions_[w[1]][0]),s.push(E.$),n.push(E._$),_=o[a[a.length-2]][a[a.length-1]],a.push(_);break;case 3:return!0}}return!0}),"parse")},f=function(){return{EOF:1,parseError:r((function(t,e){if(!this.yy.parser)throw new Error(t);this.yy.parser.parseError(t,e)}),"parseError"),setInput:r((function(t,e){return this.yy=e||this.yy||{},this._input=t,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this}),"setInput"),input:r((function(){var t=this._input[0];return this.yytext+=t,this.yyleng++,this.offset++,this.match+=t,this.matched+=t,t.match(/(?:\r\n?|\n).*/g)?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),t}),"input"),unput:r((function(t){var e=t.length,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:r((function(){return this._more=!0,this}),"more"),reject:r((function(){return this.options.backtrack_lexer?(this._backtrack=!0,this):this.parseError("Lexical error on line "+(this.yylineno+1)+". You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true).\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"reject"),less:r((function(t){this.unput(this.match.slice(t))}),"less"),pastInput:r((function(){var t=this.matched.substr(0,this.matched.length-this.match.length);return(t.length>20?"...":"")+t.substr(-20).replace(/\n/g,"")}),"pastInput"),upcomingInput:r((function(){var t=this.match;return t.length<20&&(t+=this._input.substr(0,20-t.length)),(t.substr(0,20)+(t.length>20?"...":"")).replace(/\n/g,"")}),"upcomingInput"),showPosition:r((function(){var t=this.pastInput(),e=new Array(t.length+1).join("-");return t+this.upcomingInput()+"\n"+e+"^"}),"showPosition"),test_match:r((function(t,e){var r,a,i;if(this.options.backtrack_lexer&&(i={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(i.yylloc.range=this.yylloc.range.slice(0))),(a=t[0].match(/(?:\r\n?|\n).*/g))&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+t[0].length},this.yytext+=t[0],this.match+=t[0],this.matches=t,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(t[0].length),this.matched+=t[0],r=this.performAction.call(this,this.yy,this,e,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),r)return r;if(this._backtrack){for(var s in i)this[s]=i[s];return!1}return!1}),"test_match"),next:r((function(){if(this.done)return this.EOF;var t,e,r,a;this._input||(this.done=!0),this._more||(this.yytext="",this.match="");for(var i=this._currentRules(),s=0;s<i.length;s++)if((r=this._input.match(this.rules[i[s]]))&&(!e||r[0].length>e[0].length)){if(e=r,a=s,this.options.backtrack_lexer){if(!1!==(t=this.test_match(r,i[s])))return t;if(this._backtrack){e=!1;continue}return!1}if(!this.options.flex)break}return e?!1!==(t=this.test_match(e,i[a]))&&t:""===this._input?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+". Unrecognized text.\n"+this.showPosition(),{text:"",token:null,line:this.yylineno})}),"next"),lex:r((function(){var t=this.next();return t||this.lex()}),"lex"),begin:r((function(t){this.conditionStack.push(t)}),"begin"),popState:r((function(){return this.conditionStack.length-1>0?this.conditionStack.pop():this.conditionStack[0]}),"popState"),_currentRules:r((function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules}),"_currentRules"),topState:r((function(t){return(t=this.conditionStack.length-1-Math.abs(t||0))>=0?this.conditionStack[t]:"INITIAL"}),"topState"),pushState:r((function(t){this.begin(t)}),"pushState"),stateStackSize:r((function(){return this.conditionStack.length}),"stateStackSize"),options:{},performAction:r((function(t,e,r,a){switch(r){case 0:return 10;case 1:return t.getLogger().debug("Found space-block"),31;case 2:return t.getLogger().debug("Found nl-block"),31;case 3:return t.getLogger().debug("Found space-block"),29;case 4:t.getLogger().debug(".",e.yytext);break;case 5:t.getLogger().debug("_",e.yytext);break;case 6:return 5;case 7:return e.yytext=-1,28;case 8:return e.yytext=e.yytext.replace(/columns\s+/,""),t.getLogger().debug("COLUMNS (LEX)",e.yytext),28;case 9:case 77:case 78:case 100:this.pushState("md_string");break;case 10:return"MD_STR";case 11:case 35:case 80:this.popState();break;case 12:this.pushState("string");break;case 13:t.getLogger().debug("LEX: POPPING STR:",e.yytext),this.popState();break;case 14:return t.getLogger().debug("LEX: STR end:",e.yytext),"STR";case 15:return e.yytext=e.yytext.replace(/space\:/,""),t.getLogger().debug("SPACE NUM (LEX)",e.yytext),21;case 16:return e.yytext="1",t.getLogger().debug("COLUMNS (LEX)",e.yytext),21;case 17:return 43;case 18:return"LINKSTYLE";case 19:return"INTERPOLATE";case 20:return this.pushState("CLASSDEF"),40;case 21:return this.popState(),this.pushState("CLASSDEFID"),"DEFAULT_CLASSDEF_ID";case 22:return this.popState(),this.pushState("CLASSDEFID"),41;case 23:return this.popState(),42;case 24:return this.pushState("CLASS"),44;case 25:return this.popState(),this.pushState("CLASS_STYLE"),45;case 26:return this.popState(),46;case 27:return this.pushState("STYLE_STMNT"),47;case 28:return this.popState(),this.pushState("STYLE_DEFINITION"),48;case 29:return this.popState(),49;case 30:return this.pushState("acc_title"),"acc_title";case 31:return this.popState(),"acc_title_value";case 32:return this.pushState("acc_descr"),"acc_descr";case 33:return this.popState(),"acc_descr_value";case 34:this.pushState("acc_descr_multiline");break;case 36:return"acc_descr_multiline_value";case 37:return 30;case 38:case 39:case 41:case 42:case 45:return this.popState(),t.getLogger().debug("Lex: (("),"NODE_DEND";case 40:return this.popState(),t.getLogger().debug("Lex: ))"),"NODE_DEND";case 43:return this.popState(),t.getLogger().debug("Lex: (-"),"NODE_DEND";case 44: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:return this.popState(),t.getLogger().debug("Lex: ])"),"NODE_DEND";case 49: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 this.popState(),t.getLogger().debug("Lex: ]"),"NODE_DEND";case 55:return t.getLogger().debug("Lexa: -)"),this.pushState("NODE"),36;case 56:return t.getLogger().debug("Lexa: (-"),this.pushState("NODE"),36;case 57:return t.getLogger().debug("Lexa: ))"),this.pushState("NODE"),36;case 58:case 60:case 61:case 62:case 65:return t.getLogger().debug("Lexa: )"),this.pushState("NODE"),36;case 59:return t.getLogger().debug("Lex: ((("),this.pushState("NODE"),36;case 63:return t.getLogger().debug("Lexc: >"),this.pushState("NODE"),36;case 64:return t.getLogger().debug("Lexa: (["),this.pushState("NODE"),36;case 66:case 67:case 68:case 69:case 70:case 71:case 72:return this.pushState("NODE"),36;case 73:return t.getLogger().debug("Lexa: ["),this.pushState("NODE"),36;case 74:return this.pushState("BLOCK_ARROW"),t.getLogger().debug("LEX ARR START"),38;case 75:return t.getLogger().debug("Lex: NODE_ID",e.yytext),32;case 76:return t.getLogger().debug("Lex: EOF",e.yytext),8;case 79:return"NODE_DESCR";case 81:t.getLogger().debug("Lex: Starting string"),this.pushState("string");break;case 82:t.getLogger().debug("LEX ARR: Starting string"),this.pushState("string");break;case 83:return t.getLogger().debug("LEX: NODE_DESCR:",e.yytext),"NODE_DESCR";case 84:t.getLogger().debug("LEX POPPING"),this.popState();break;case 85:t.getLogger().debug("Lex: =>BAE"),this.pushState("ARROW_DIR");break;case 86:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (right): dir:",e.yytext),"DIR";case 87:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (left):",e.yytext),"DIR";case 88:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (x):",e.yytext),"DIR";case 89:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (y):",e.yytext),"DIR";case 90:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (up):",e.yytext),"DIR";case 91:return e.yytext=e.yytext.replace(/^,\s*/,""),t.getLogger().debug("Lex (down):",e.yytext),"DIR";case 92:return e.yytext="]>",t.getLogger().debug("Lex (ARROW_DIR end):",e.yytext),this.popState(),this.popState(),"BLOCK_ARROW_END";case 93:return t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 94:case 95:case 96:return t.getLogger().debug("Lex: LINK",e.yytext),15;case 97:case 98:case 99:return t.getLogger().debug("Lex: START_LINK",e.yytext),this.pushState("LLABEL"),16;case 101:return t.getLogger().debug("Lex: Starting string"),this.pushState("string"),"LINK_LABEL";case 102:return this.popState(),t.getLogger().debug("Lex: LINK","#"+e.yytext+"#"),15;case 103:case 104:return this.popState(),t.getLogger().debug("Lex: LINK",e.yytext),15;case 105:return t.getLogger().debug("Lex: COLON",e.yytext),e.yytext=e.yytext.slice(1),27}}),"anonymous"),rules:[/^(?:block-beta\b)/,/^(?:block\s+)/,/^(?:block\n+)/,/^(?:block:)/,/^(?:[\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:[29],inclusive:!1},STYLE_STMNT:{rules:[28],inclusive:!1},CLASSDEFID:{rules:[23],inclusive:!1},CLASSDEF:{rules:[21,22],inclusive:!1},CLASS_STYLE:{rules:[26],inclusive:!1},CLASS:{rules:[25],inclusive:!1},LLABEL:{rules:[100,101,102,103,104],inclusive:!1},ARROW_DIR:{rules:[86,87,88,89,90,91,92],inclusive:!1},BLOCK_ARROW:{rules:[77,82,85],inclusive:!1},NODE:{rules:[38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,54,78,81],inclusive:!1},md_string:{rules:[10,11,79,80],inclusive:!1},space:{rules:[],inclusive:!1},string:{rules:[13,14,83,84],inclusive:!1},acc_descr_multiline:{rules:[35,36],inclusive:!1},acc_descr:{rules:[33],inclusive:!1},acc_title:{rules:[31],inclusive:!1},INITIAL:{rules:[0,1,2,3,4,5,6,7,8,9,12,15,16,17,18,19,20,24,27,30,32,34,37,55,56,57,58,59,60,61,62,63,64,65,66,67,68,69,70,71,72,73,74,75,76,93,94,95,96,97,98,99,105],inclusive:!0}}}}();function m(){this.yy={}}return b.lexer=f,r(m,"Parser"),m.prototype=b,b.Parser=m,new m}();v.parser=v;var E=v,D=new Map,$=[],T=new Map,C="color",N="fill",I=l(),B=new Map,z=r((t=>y.sanitizeText(t,I)),"sanitizeText"),R=r((function(t,e=""){let r=B.get(t);r||(r={id:t,styles:[],textStyles:[]},B.set(t,r)),null!=e&&e.split(",").forEach((t=>{const e=t.replace(/([^;]*);/,"$1").trim();if(RegExp(C).exec(t)){const t=e.replace(N,"bgFill").replace(C,N);r.textStyles.push(t)}r.styles.push(e)}))}),"addStyleClass"),O=r((function(t,e=""){const r=D.get(t);null!=e&&(r.styles=e.split(","))}),"addStyle2Node"),A=r((function(t,e){t.split(",").forEach((function(t){let r=D.get(t);if(void 0===r){const e=t.trim();r={id:e,type:"na",children:[]},D.set(e,r)}r.classes||(r.classes=[]),r.classes.push(e)}))}),"setCssClass"),M=r(((t,e)=>{const r=t.flat(),a=[];for(const i of r)if(i.label&&(i.label=z(i.label)),"classDef"!==i.type)if("applyClass"!==i.type)if("applyStyles"!==i.type)if("column-setting"===i.type)e.columns=i.columns??-1;else if("edge"===i.type){const t=(T.get(i.id)??0)+1;T.set(i.id,t),i.id=t+"-"+i.id,$.push(i)}else{i.label||("composite"===i.type?i.label="":i.label=i.id);const t=D.get(i.id);if(void 0===t?D.set(i.id,i):("na"!==i.type&&(t.type=i.type),i.label!==i.id&&(t.label=i.label)),i.children&&M(i.children,i),"space"===i.type){const t=i.width??1;for(let e=0;e<t;e++){const t=m(i);t.id=t.id+"-"+e,D.set(t.id,t),a.push(t)}}else void 0===t&&a.push(i)}else(null==i?void 0:i.stylesStr)&&O(i.id,null==i?void 0:i.stylesStr);else A(i.id,(null==i?void 0:i.styleClass)??"");else R(i.id,i.css);e.children=a}),"populateBlockDatabase"),P=[],Y={id:"root",type:"composite",children:[],columns:-1},X=r((()=>{s.debug("Clear called"),n(),Y={id:"root",type:"composite",children:[],columns:-1},D=new Map([["root",Y]]),P=[],B=new Map,$=[],T=new Map}),"clear");function W(t){switch(s.debug("typeStr2Type",t),t){case"[]":return"square";case"()":return s.debug("we have a round"),"round";case"(())":return"circle";case">]":return"rect_left_inv_arrow";case"{}":return"diamond";case"{{}}":return"hexagon";case"([])":return"stadium";case"[[]]":return"subroutine";case"[()]":return"cylinder";case"((()))":return"doublecircle";case"[//]":return"lean_right";case"[\\\\]":return"lean_left";case"[/\\]":return"trapezoid";case"[\\/]":return"inv_trapezoid";case"<[]>":return"block_arrow";default:return"na"}}function F(t){return s.debug("typeStr2Type",t),"=="===t?"thick":"normal"}function j(t){switch(t.trim()){case"--x":return"arrow_cross";case"--o":return"arrow_circle";default:return"arrow_point"}}r(W,"typeStr2Type"),r(F,"edgeTypeStr2Type"),r(j,"edgeStrToEdgeData");var H=0,U=r((()=>(H++,"id-"+Math.random().toString(36).substr(2,12)+"-"+H)),"generateId"),K=r((t=>{Y.children=t,M(t,Y),P=Y.children}),"setHierarchy"),q=r((t=>{const e=D.get(t);return e?e.columns?e.columns:e.children?e.children.length:-1:-1}),"getColumns"),Z=r((()=>[...D.values()]),"getBlocksFlat"),G=r((()=>P||[]),"getBlocks"),J=r((()=>$),"getEdges"),V=r((t=>D.get(t)),"getBlock"),Q=r((t=>{D.set(t.id,t)}),"setBlock"),tt=r((()=>console),"getLogger"),et=r((function(){return B}),"getClasses"),rt={getConfig:r((()=>a().block),"getConfig"),typeStr2Type:W,edgeTypeStr2Type:F,edgeStrToEdgeData:j,getLogger:tt,getBlocksFlat:Z,getBlocks:G,getEdges:J,setHierarchy:K,getBlock:V,setBlock:Q,getColumns:q,getClasses:et,clear:X,generateId:U},at=r(((t,e)=>{const r=L,a=r(t,"r"),i=r(t,"g"),s=r(t,"b");return o(a,i,s,e)}),"fade"),it=r((t=>`.label {\n font-family: ${t.fontFamily};\n color: ${t.nodeTextColor||t.textColor};\n }\n .cluster-label text {\n fill: ${t.titleColor};\n }\n .cluster-label span,p {\n color: ${t.titleColor};\n }\n\n\n\n .label text,span,p {\n fill: ${t.nodeTextColor||t.textColor};\n color: ${t.nodeTextColor||t.textColor};\n }\n\n .node rect,\n .node circle,\n .node ellipse,\n .node polygon,\n .node path {\n fill: ${t.mainBkg};\n stroke: ${t.nodeBorder};\n stroke-width: 1px;\n }\n .flowchart-label text {\n text-anchor: middle;\n }\n // .flowchart-label .text-outer-tspan {\n // text-anchor: middle;\n // }\n // .flowchart-label .text-inner-tspan {\n // text-anchor: start;\n // }\n\n .node .label {\n text-align: center;\n }\n .node.clickable {\n cursor: pointer;\n }\n\n .arrowheadPath {\n fill: ${t.arrowheadColor};\n }\n\n .edgePath .path {\n stroke: ${t.lineColor};\n stroke-width: 2.0px;\n }\n\n .flowchart-link {\n stroke: ${t.lineColor};\n fill: none;\n }\n\n .edgeLabel {\n background-color: ${t.edgeLabelBackground};\n rect {\n opacity: 0.5;\n background-color: ${t.edgeLabelBackground};\n fill: ${t.edgeLabelBackground};\n }\n text-align: center;\n }\n\n /* For html labels only */\n .labelBkg {\n background-color: ${at(t.edgeLabelBackground,.5)};\n // background-color:\n }\n\n .node .cluster {\n // fill: ${at(t.mainBkg,.5)};\n fill: ${at(t.clusterBkg,.5)};\n stroke: ${at(t.clusterBorder,.2)};\n box-shadow: rgba(50, 50, 93, 0.25) 0px 13px 27px -5px, rgba(0, 0, 0, 0.3) 0px 8px 16px -8px;\n stroke-width: 1px;\n }\n\n .cluster text {\n fill: ${t.titleColor};\n }\n\n .cluster span,p {\n color: ${t.titleColor};\n }\n /* .cluster div {\n color: ${t.titleColor};\n } */\n\n div.mermaidTooltip {\n position: absolute;\n text-align: center;\n max-width: 200px;\n padding: 2px;\n font-family: ${t.fontFamily};\n font-size: 12px;\n background: ${t.tertiaryColor};\n border: 1px solid ${t.border2};\n border-radius: 2px;\n pointer-events: none;\n z-index: 100;\n }\n\n .flowchartTitleText {\n text-anchor: middle;\n font-size: 18px;\n fill: ${t.textColor};\n }\n`),"getStyles"),st=r(((t,e,r,a)=>{e.forEach((e=>{nt[e](t,r,a)}))}),"insertMarkers"),nt={extension:r(((t,e,r)=>{s.trace("Making markers for ",r),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionStart").attr("class","marker extension "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-extensionEnd").attr("class","marker extension "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")}),"extension"),composition:r(((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionStart").attr("class","marker composition "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-compositionEnd").attr("class","marker composition "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"composition"),aggregation:r(((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationStart").attr("class","marker aggregation "+e).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-aggregationEnd").attr("class","marker aggregation "+e).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")}),"aggregation"),dependency:r(((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyStart").attr("class","marker dependency "+e).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),t.append("defs").append("marker").attr("id",r+"_"+e+"-dependencyEnd").attr("class","marker dependency "+e).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")}),"dependency"),lollipop:r(((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopStart").attr("class","marker lollipop "+e).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),t.append("defs").append("marker").attr("id",r+"_"+e+"-lollipopEnd").attr("class","marker lollipop "+e).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)}),"lollipop"),point:r(((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",6).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",r+"_"+e+"-pointStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",12).attr("markerHeight",12).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"point"),circle:r(((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-circleEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),t.append("marker").attr("id",r+"_"+e+"-circleStart").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")}),"circle"),cross:r(((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:r(((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")},ot=st,lt=(null==(e=null==(t=l())?void 0:t.block)?void 0:e.padding)??8;function ct(t,e){if(0===t||!Number.isInteger(t))throw new Error("Columns must be an integer !== 0.");if(e<0||!Number.isInteger(e))throw new Error("Position must be a non-negative integer."+e);if(t<0)return{px:e,py:0};if(1===t)return{px:0,py:e};return{px:e%t,py:Math.floor(e/t)}}r(ct,"calculateBlockPosition");var dt=r((t=>{let e=0,r=0;for(const a of t.children){const{width:i,height:n,x:o,y:l}=a.size??{width:0,height:0,x:0,y:0};s.debug("getMaxChildSize abc95 child:",a.id,"width:",i,"height:",n,"x:",o,"y:",l,a.type),"space"!==a.type&&(i>e&&(e=i/(t.widthInColumns??1)),n>r&&(r=n))}return{width:e,height:r}}),"getMaxChildSize");function ht(t,e,r=0,a=0){var i,n,o,l,c,d,h,g,u,y,p;s.debug("setBlockSizes abc95 (start)",t.id,null==(i=null==t?void 0:t.size)?void 0:i.x,"block width =",null==t?void 0:t.size,"sieblingWidth",r),(null==(n=null==t?void 0:t.size)?void 0:n.width)||(t.size={width:r,height:a,x:0,y:0});let x=0,b=0;if((null==(o=t.children)?void 0:o.length)>0){for(const r of t.children)ht(r,e);const i=dt(t);x=i.width,b=i.height,s.debug("setBlockSizes abc95 maxWidth of",t.id,":s children is ",x,b);for(const e of t.children)e.size&&(s.debug(`abc95 Setting size of children of ${t.id} id=${e.id} ${x} ${b} ${JSON.stringify(e.size)}`),e.size.width=x*(e.widthInColumns??1)+lt*((e.widthInColumns??1)-1),e.size.height=b,e.size.x=0,e.size.y=0,s.debug(`abc95 updating size of ${t.id} children child:${e.id} maxWidth:${x} maxHeight:${b}`));for(const r of t.children)ht(r,e,x,b);const n=t.columns??-1;let o=0;for(const e of t.children)o+=e.widthInColumns??1;let g=t.children.length;n>0&&n<o&&(g=n);const u=Math.ceil(o/g);let y=g*(x+lt)+lt,p=u*(b+lt)+lt;if(y<r){s.debug(`Detected to small siebling: abc95 ${t.id} sieblingWidth ${r} sieblingHeight ${a} width ${y}`),y=r,p=a;const e=(r-g*lt-lt)/g,i=(a-u*lt-lt)/u;s.debug("Size indata abc88",t.id,"childWidth",e,"maxWidth",x),s.debug("Size indata abc88",t.id,"childHeight",i,"maxHeight",b),s.debug("Size indata abc88 xSize",g,"padding",lt);for(const r of t.children)r.size&&(r.size.width=e,r.size.height=i,r.size.x=0,r.size.y=0)}if(s.debug(`abc95 (finale calc) ${t.id} xSize ${g} ySize ${u} columns ${n}${t.children.length} width=${Math.max(y,(null==(l=t.size)?void 0:l.width)||0)}`),y<((null==(c=null==t?void 0:t.size)?void 0:c.width)||0)){y=(null==(d=null==t?void 0:t.size)?void 0:d.width)||0;const e=n>0?Math.min(t.children.length,n):t.children.length;if(e>0){const r=(y-e*lt-lt)/e;s.debug("abc95 (growing to fit) width",t.id,y,null==(h=t.size)?void 0:h.width,r);for(const e of t.children)e.size&&(e.size.width=r)}}t.size={width:y,height:p,x:0,y:0}}s.debug("setBlockSizes abc94 (done)",t.id,null==(g=null==t?void 0:t.size)?void 0:g.x,null==(u=null==t?void 0:t.size)?void 0:u.width,null==(y=null==t?void 0:t.size)?void 0:y.y,null==(p=null==t?void 0:t.size)?void 0:p.height)}function gt(t,e){var r,a,i,n,o,l,c,d,h,g,u,y,p,x,b,f,m;s.debug(`abc85 layout blocks (=>layoutBlocks) ${t.id} x: ${null==(r=null==t?void 0:t.size)?void 0:r.x} y: ${null==(a=null==t?void 0:t.size)?void 0:a.y} width: ${null==(i=null==t?void 0:t.size)?void 0:i.width}`);const w=t.columns??-1;if(s.debug("layoutBlocks columns abc95",t.id,"=>",w,t),t.children&&t.children.length>0){const e=(null==(o=null==(n=null==t?void 0:t.children[0])?void 0:n.size)?void 0:o.width)??0,r=t.children.length*e+(t.children.length-1)*lt;s.debug("widthOfChildren 88",r,"posX");let a=0;s.debug("abc91 block?.size?.x",t.id,null==(l=null==t?void 0:t.size)?void 0:l.x);let i=(null==(c=null==t?void 0:t.size)?void 0:c.x)?(null==(d=null==t?void 0:t.size)?void 0:d.x)+(-(null==(h=null==t?void 0:t.size)?void 0:h.width)/2||0):-lt,b=0;for(const n of t.children){const e=t;if(!n.size)continue;const{width:r,height:o}=n.size,{px:l,py:c}=ct(w,a);if(c!=b&&(b=c,i=(null==(g=null==t?void 0:t.size)?void 0:g.x)?(null==(u=null==t?void 0:t.size)?void 0:u.x)+(-(null==(y=null==t?void 0:t.size)?void 0:y.width)/2||0):-lt,s.debug("New row in layout for block",t.id," and child ",n.id,b)),s.debug(`abc89 layout blocks (child) id: ${n.id} Pos: ${a} (px, py) ${l},${c} (${null==(p=null==e?void 0:e.size)?void 0:p.x},${null==(x=null==e?void 0:e.size)?void 0:x.y}) parent: ${e.id} width: ${r}${lt}`),e.size){const t=r/2;n.size.x=i+lt+t,s.debug(`abc91 layout blocks (calc) px, pyid:${n.id} startingPos=X${i} new startingPosX${n.size.x} ${t} padding=${lt} width=${r} halfWidth=${t} => x:${n.size.x} y:${n.size.y} ${n.widthInColumns} (width * (child?.w || 1)) / 2 ${r*((null==n?void 0:n.widthInColumns)??1)/2}`),i=n.size.x+t,n.size.y=e.size.y-e.size.height/2+c*(o+lt)+o/2+lt,s.debug(`abc88 layout blocks (calc) px, pyid:${n.id}startingPosX${i}${lt}${t}=>x:${n.size.x}y:${n.size.y}${n.widthInColumns}(width * (child?.w || 1)) / 2${r*((null==n?void 0:n.widthInColumns)??1)/2}`)}n.children&>(n),a+=(null==n?void 0:n.widthInColumns)??1,s.debug("abc88 columnsPos",n,a)}}s.debug(`layout blocks (<==layoutBlocks) ${t.id} x: ${null==(b=null==t?void 0:t.size)?void 0:b.x} y: ${null==(f=null==t?void 0:t.size)?void 0:f.y} width: ${null==(m=null==t?void 0:t.size)?void 0:m.width}`)}function ut(t,{minX:e,minY:r,maxX:a,maxY:i}={minX:0,minY:0,maxX:0,maxY:0}){if(t.size&&"root"!==t.id){const{x:s,y:n,width:o,height:l}=t.size;s-o/2<e&&(e=s-o/2),n-l/2<r&&(r=n-l/2),s+o/2>a&&(a=s+o/2),n+l/2>i&&(i=n+l/2)}if(t.children)for(const s of t.children)({minX:e,minY:r,maxX:a,maxY:i}=ut(s,{minX:e,minY:r,maxX:a,maxY:i}));return{minX:e,minY:r,maxX:a,maxY:i}}function yt(t){const e=t.getBlock("root");if(!e)return;ht(e,t,0,0),gt(e),s.debug("getBlocks",JSON.stringify(e,null,2));const{minX:r,minY:a,maxX:i,maxY:n}=ut(e);return{x:r,y:a,width:i-r,height:n-a}}function pt(t,e){e&&t.attr("style",e)}function xt(t){const e=w(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),r=e.append("xhtml:div"),a=t.label,i=t.isNode?"nodeLabel":"edgeLabel",s=r.append("span");return s.html(a),pt(s,t.labelStyle),s.attr("class",i),pt(r,t.labelStyle),r.style("display","inline-block"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),e.node()}r(ht,"setBlockSizes"),r(gt,"layoutBlocks"),r(ut,"findBounds"),r(yt,"layout"),r(pt,"applyStyle"),r(xt,"addHtmlLabel");var bt=r(((t,e,r,a)=>{let i=t||"";if("object"==typeof i&&(i=i[0]),d(l().flowchart.htmlLabels)){i=i.replace(/\\n|\n/g,"<br />"),s.debug("vertexText"+i);return xt({isNode:a,label:p(x(i)),labelStyle:e.replace("fill:","color:")})}{const t=document.createElementNS("http://www.w3.org/2000/svg","text");t.setAttribute("style",e.replace("color:","fill:"));let a=[];a="string"==typeof i?i.split(/\\n|\n|<br\s*\/?>/gi):Array.isArray(i)?i:[];for(const e of a){const a=document.createElementNS("http://www.w3.org/2000/svg","tspan");a.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),a.setAttribute("dy","1em"),a.setAttribute("x","0"),r?a.setAttribute("class","title-row"):a.setAttribute("class","row"),a.textContent=e.trim(),t.appendChild(a)}return t}}),"createLabel"),ft=r(((t,e,r,a,i)=>{e.arrowTypeStart&&wt(t,"start",e.arrowTypeStart,r,a,i),e.arrowTypeEnd&&wt(t,"end",e.arrowTypeEnd,r,a,i)}),"addEdgeMarkers"),mt={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},wt=r(((t,e,r,a,i,n)=>{const o=mt[r];if(!o)return void s.warn(`Unknown arrow type: ${r}`);const l="start"===e?"Start":"End";t.attr(`marker-${e}`,`url(${a}#${i}_${n}-${o}${l})`)}),"addEdgeMarker"),kt={},Lt={},St=r(((t,e)=>{const r=l(),a=d(r.flowchart.htmlLabels),i="markdown"===e.labelType?h(t,e.label,{style:e.labelStyle,useHtmlLabels:a,addSvgBackground:!0},r):bt(e.label,e.labelStyle),s=t.insert("g").attr("class","edgeLabel"),n=s.insert("g").attr("class","label");n.node().appendChild(i);let o,c=i.getBBox();if(a){const t=i.children[0],e=w(i);c=t.getBoundingClientRect(),e.attr("width",c.width),e.attr("height",c.height)}if(n.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),kt[e.id]=s,e.width=c.width,e.height=c.height,e.startLabelLeft){const r=bt(e.startLabelLeft,e.labelStyle),a=t.insert("g").attr("class","edgeTerminals"),i=a.insert("g").attr("class","inner");o=i.node().appendChild(r);const s=r.getBBox();i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),Lt[e.id]||(Lt[e.id]={}),Lt[e.id].startLeft=a,_t(o,e.startLabelLeft)}if(e.startLabelRight){const r=bt(e.startLabelRight,e.labelStyle),a=t.insert("g").attr("class","edgeTerminals"),i=a.insert("g").attr("class","inner");o=a.node().appendChild(r),i.node().appendChild(r);const s=r.getBBox();i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),Lt[e.id]||(Lt[e.id]={}),Lt[e.id].startRight=a,_t(o,e.startLabelRight)}if(e.endLabelLeft){const r=bt(e.endLabelLeft,e.labelStyle),a=t.insert("g").attr("class","edgeTerminals"),i=a.insert("g").attr("class","inner");o=i.node().appendChild(r);const s=r.getBBox();i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),a.node().appendChild(r),Lt[e.id]||(Lt[e.id]={}),Lt[e.id].endLeft=a,_t(o,e.endLabelLeft)}if(e.endLabelRight){const r=bt(e.endLabelRight,e.labelStyle),a=t.insert("g").attr("class","edgeTerminals"),i=a.insert("g").attr("class","inner");o=i.node().appendChild(r);const s=r.getBBox();i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),a.node().appendChild(r),Lt[e.id]||(Lt[e.id]={}),Lt[e.id].endRight=a,_t(o,e.endLabelRight)}return i}),"insertEdgeLabel");function _t(t,e){l().flowchart.htmlLabels&&t&&(t.style.width=9*e.length+"px",t.style.height="12px")}r(_t,"setTerminalWidth");var vt=r(((t,e)=>{s.debug("Moving label abc88 ",t.id,t.label,kt[t.id],e);let r=e.updatedPath?e.updatedPath:e.originalPath;const a=l(),{subGraphTitleTotalMargin:i}=g(a);if(t.label){const a=kt[t.id];let n=t.x,o=t.y;if(r){const a=u.calcLabelPosition(r);s.debug("Moving label "+t.label+" from (",n,",",o,") to (",a.x,",",a.y,") abc88"),e.updatedPath&&(n=a.x,o=a.y)}a.attr("transform",`translate(${n}, ${o+i/2})`)}if(t.startLabelLeft){const e=Lt[t.id].startLeft;let a=t.x,i=t.y;if(r){const e=u.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.startLabelRight){const e=Lt[t.id].startRight;let a=t.x,i=t.y;if(r){const e=u.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelLeft){const e=Lt[t.id].endLeft;let a=t.x,i=t.y;if(r){const e=u.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}if(t.endLabelRight){const e=Lt[t.id].endRight;let a=t.x,i=t.y;if(r){const e=u.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",r);a=e.x,i=e.y}e.attr("transform",`translate(${a}, ${i})`)}}),"positionEdgeLabel"),Et=r(((t,e)=>{const r=t.x,a=t.y,i=Math.abs(e.x-r),s=Math.abs(e.y-a),n=t.width/2,o=t.height/2;return i>=n||s>=o}),"outsideNode"),Dt=r(((t,e,r)=>{s.debug(`intersection calc abc89:\n outsidePoint: ${JSON.stringify(e)}\n insidePoint : ${JSON.stringify(r)}\n node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);const a=t.x,i=t.y,n=Math.abs(a-r.x),o=t.width/2;let l=r.x<e.x?o-n:o+n;const c=t.height/2,d=Math.abs(e.y-r.y),h=Math.abs(e.x-r.x);if(Math.abs(i-e.y)*o>Math.abs(a-e.x)*c){let t=r.y<e.y?e.y-c-i:i-c-e.y;l=h*t/d;const a={x:r.x<e.x?r.x+l:r.x-h+l,y:r.y<e.y?r.y+d-t:r.y-d+t};return 0===l&&(a.x=e.x,a.y=e.y),0===h&&(a.x=e.x),0===d&&(a.y=e.y),s.debug(`abc89 topp/bott calc, Q ${d}, q ${t}, R ${h}, r ${l}`,a),a}{l=r.x<e.x?e.x-o-a:a-o-e.x;let t=d*l/h,i=r.x<e.x?r.x+h-l:r.x-h+l,n=r.y<e.y?r.y+t:r.y-t;return s.debug(`sides calc abc89, Q ${d}, q ${t}, R ${h}, r ${l}`,{_x:i,_y:n}),0===l&&(i=e.x,n=e.y),0===h&&(i=e.x),0===d&&(n=e.y),{x:i,y:n}}}),"intersection"),$t=r(((t,e)=>{s.debug("abc88 cutPathAtIntersect",t,e);let r=[],a=t[0],i=!1;return t.forEach((t=>{if(Et(e,t)||i)a=t,i||r.push(t);else{const s=Dt(e,a,t);let n=!1;r.forEach((t=>{n=n||t.x===s.x&&t.y===s.y})),r.some((t=>t.x===s.x&&t.y===s.y))||r.push(s),i=!0}})),r}),"cutPathAtIntersect"),Tt=r((function(t,e,r,a,i,n,o){let d=r.points;s.debug("abc88 InsertEdge: edge=",r,"e=",e);let h=!1;const g=n.node(e.v);var u=n.node(e.w);(null==u?void 0:u.intersect)&&(null==g?void 0:g.intersect)&&(d=d.slice(1,r.points.length-1),d.unshift(g.intersect(d[0])),d.push(u.intersect(d[d.length-1]))),r.toCluster&&(s.debug("to cluster abc88",a[r.toCluster]),d=$t(r.points,a[r.toCluster].node),h=!0),r.fromCluster&&(s.debug("from cluster abc88",a[r.fromCluster]),d=$t(d.reverse(),a[r.fromCluster].node).reverse(),h=!0);const y=d.filter((t=>!Number.isNaN(t.y)));let p=_;!r.curve||"graph"!==i&&"flowchart"!==i||(p=r.curve);const{x:x,y:b}=c(r),f=S().x(x).y(b).curve(p);let m;switch(r.thickness){case"normal":m="edge-thickness-normal";break;case"thick":case"invisible":m="edge-thickness-thick";break;default:m=""}switch(r.pattern){case"solid":m+=" edge-pattern-solid";break;case"dotted":m+=" edge-pattern-dotted";break;case"dashed":m+=" edge-pattern-dashed"}const w=t.append("path").attr("d",f(y)).attr("id",r.id).attr("class"," "+m+(r.classes?" "+r.classes:"")).attr("style",r.style);let k="";(l().flowchart.arrowMarkerAbsolute||l().state.arrowMarkerAbsolute)&&(k=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,k=k.replace(/\(/g,"\\("),k=k.replace(/\)/g,"\\)")),ft(w,r,k,o,i);let L={};return h&&(L.updatedPath=d),L.originalPath=r.points,L}),"insertEdge"),Ct=r((t=>{const e=new Set;for(const r of t)switch(r){case"x":e.add("right"),e.add("left");break;case"y":e.add("up"),e.add("down");break;default:e.add(r)}return e}),"expandAndDeduplicateDirections"),Nt=r(((t,e,r)=>{const a=Ct(t),i=e.height+2*r.padding,s=i/2,n=e.width+2*s+r.padding,o=r.padding/2;return a.has("right")&&a.has("left")&&a.has("up")&&a.has("down")?[{x:0,y:0},{x:s,y:0},{x:n/2,y:2*o},{x:n-s,y:0},{x:n,y:0},{x:n,y:-i/3},{x:n+2*o,y:-i/2},{x:n,y:-2*i/3},{x:n,y:-i},{x:n-s,y:-i},{x:n/2,y:-i-2*o},{x:s,y:-i},{x:0,y:-i},{x:0,y:-2*i/3},{x:-2*o,y:-i/2},{x:0,y:-i/3}]:a.has("right")&&a.has("left")&&a.has("up")?[{x:s,y:0},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}]:a.has("right")&&a.has("left")&&a.has("down")?[{x:0,y:0},{x:s,y:-i},{x:n-s,y:-i},{x:n,y:0}]:a.has("right")&&a.has("up")&&a.has("down")?[{x:0,y:0},{x:n,y:-s},{x:n,y:-i+s},{x:0,y:-i}]:a.has("left")&&a.has("up")&&a.has("down")?[{x:n,y:0},{x:0,y:-s},{x:0,y:-i+s},{x:n,y:-i}]:a.has("right")&&a.has("left")?[{x:s,y:0},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i},{x:0,y:-i/2}]:a.has("up")&&a.has("down")?[{x:n/2,y:0},{x:0,y:-o},{x:s,y:-o},{x:s,y:-i+o},{x:0,y:-i+o},{x:n/2,y:-i},{x:n,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o},{x:n,y:-o}]:a.has("right")&&a.has("up")?[{x:0,y:0},{x:n,y:-s},{x:0,y:-i}]:a.has("right")&&a.has("down")?[{x:0,y:0},{x:n,y:0},{x:0,y:-i}]:a.has("left")&&a.has("up")?[{x:n,y:0},{x:0,y:-s},{x:n,y:-i}]:a.has("left")&&a.has("down")?[{x:n,y:0},{x:0,y:0},{x:n,y:-i}]:a.has("right")?[{x:s,y:-o},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i+o}]:a.has("left")?[{x:s,y:0},{x:s,y:-o},{x:n-s,y:-o},{x:n-s,y:-i+o},{x:s,y:-i+o},{x:s,y:-i},{x:0,y:-i/2}]:a.has("up")?[{x:s,y:-o},{x:s,y:-i+o},{x:0,y:-i+o},{x:n/2,y:-i},{x:n,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o}]:a.has("down")?[{x:n/2,y:0},{x:0,y:-o},{x:s,y:-o},{x:s,y:-i+o},{x:n-s,y:-i+o},{x:n-s,y:-o},{x:n,y:-o}]:[{x:0,y:0}]}),"getArrowPoints");function It(t,e){return t.intersect(e)}r(It,"intersectNode");var Bt=It;function zt(t,e,r,a){var i=t.x,s=t.y,n=i-a.x,o=s-a.y,l=Math.sqrt(e*e*o*o+r*r*n*n),c=Math.abs(e*r*n/l);a.x<i&&(c=-c);var d=Math.abs(e*r*o/l);return a.y<s&&(d=-d),{x:i+c,y:s+d}}r(zt,"intersectEllipse");var Rt=zt;function Ot(t,e,r){return Rt(t,e,e,r)}r(Ot,"intersectCircle");var At=Ot;function Mt(t,e,r,a){var i,s,n,o,l,c,d,h,g,u,y,p,x;if(i=e.y-t.y,n=t.x-e.x,l=e.x*t.y-t.x*e.y,g=i*r.x+n*r.y+l,u=i*a.x+n*a.y+l,!(0!==g&&0!==u&&Pt(g,u)||(s=a.y-r.y,o=r.x-a.x,c=a.x*r.y-r.x*a.y,d=s*t.x+o*t.y+c,h=s*e.x+o*e.y+c,0!==d&&0!==h&&Pt(d,h)||0==(y=i*o-s*n))))return p=Math.abs(y/2),{x:(x=n*c-o*l)<0?(x-p)/y:(x+p)/y,y:(x=s*l-i*c)<0?(x-p)/y:(x+p)/y}}function Pt(t,e){return t*e>0}r(Mt,"intersectLine"),r(Pt,"sameSign");var Yt=Mt,Xt=Wt;function Wt(t,e,r){var a=t.x,i=t.y,s=[],n=Number.POSITIVE_INFINITY,o=Number.POSITIVE_INFINITY;"function"==typeof e.forEach?e.forEach((function(t){n=Math.min(n,t.x),o=Math.min(o,t.y)})):(n=Math.min(n,e.x),o=Math.min(o,e.y));for(var l=a-t.width/2-n,c=i-t.height/2-o,d=0;d<e.length;d++){var h=e[d],g=e[d<e.length-1?d+1:0],u=Yt(t,r,{x:l+h.x,y:c+h.y},{x:l+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,o=e.y-r.y,l=Math.sqrt(n*n+o*o);return s<l?-1:s===l?0:1})),s[0]):t}r(Wt,"intersectPolygon");var Ft={node:Bt,circle:At,ellipse:Rt,polygon:Xt,rect:r(((t,e)=>{var r,a,i=t.x,s=t.y,n=e.x-i,o=e.y-s,l=t.width/2,c=t.height/2;return Math.abs(o)*l>Math.abs(n)*c?(o<0&&(c=-c),r=0===o?0:c*n/o,a=c):(n<0&&(l=-l),r=l,a=0===n?0:l*o/n),{x:i+r,y:s+a}}),"intersectRect")},jt=r((async(t,e,a,i)=>{const s=l();let n;const o=e.useHtmlLabels||d(s.flowchart.htmlLabels);n=a||"node default";const c=t.insert("g").attr("class",n).attr("id",e.domId||e.id),g=c.insert("g").attr("class","label").attr("style",e.labelStyle);let u;u=void 0===e.labelText?"":"string"==typeof e.labelText?e.labelText:e.labelText[0];const y=g.node();let p;p="markdown"===e.labelType?h(g,f(x(u),s),{useHtmlLabels:o,width:e.width||s.flowchart.wrappingWidth,classes:"markdown-node-label"},s):y.appendChild(bt(f(x(u),s),e.labelStyle,!1,i));let b=p.getBBox();const m=e.padding/2;if(d(s.flowchart.htmlLabels)){const t=p.children[0],e=w(p),a=t.getElementsByTagName("img");if(a){const t=""===u.replace(/<img[^>]*>/g,"").trim();await Promise.all([...a].map((e=>new Promise((a=>{function i(){if(e.style.display="flex",e.style.flexDirection="column",t){const t=s.fontSize?s.fontSize:window.getComputedStyle(document.body).fontSize,r=5,a=parseInt(t,10)*r+"px";e.style.minWidth=a,e.style.maxWidth=a}else e.style.width="100%";a(e)}r(i,"setupImage"),setTimeout((()=>{e.complete&&i()})),e.addEventListener("error",i),e.addEventListener("load",i)})))))}b=t.getBoundingClientRect(),e.attr("width",b.width),e.attr("height",b.height)}return o?g.attr("transform","translate("+-b.width/2+", "+-b.height/2+")"):g.attr("transform","translate(0, "+-b.height/2+")"),e.centerLabel&&g.attr("transform","translate("+-b.width/2+", "+-b.height/2+")"),g.insert("rect",":first-child"),{shapeSvg:c,bbox:b,halfPadding:m,label:g}}),"labelHelper"),Ht=r(((t,e)=>{const r=e.node().getBBox();t.width=r.width,t.height=r.height}),"updateNodeBounds");function Ut(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+")")}r(Ut,"insertPolygonShape");var Kt=r((async(t,e)=>{e.useHtmlLabels||l().flowchart.htmlLabels||(e.centerLabel=!0);const{shapeSvg:r,bbox:a,halfPadding:i}=await jt(t,e,"node "+e.classes,!0);s.info("Classes = ",e.classes);const n=r.insert("rect",":first-child");return n.attr("rx",e.rx).attr("ry",e.ry).attr("x",-a.width/2-i).attr("y",-a.height/2-i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),Ht(e,n),e.intersect=function(t){return Ft.rect(e,t)},r}),"note"),qt=r((t=>t?" "+t:""),"formatClass"),Zt=r(((t,e)=>`${e||"node default"}${qt(t.classes)} ${qt(t.class)}`),"getClassesFromNode"),Gt=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding+(a.height+e.padding),n=[{x:i/2,y:0},{x:i,y:-i/2},{x:i/2,y:-i},{x:0,y:-i/2}];s.info("Question main (Circle)");const o=Ut(r,i,i,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return s.warn("Intersect called"),Ft.polygon(e,n,t)},r}),"question"),Jt=r(((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=[{x:0,y:14},{x:14,y:0},{x:0,y:-14},{x:-14,y:0}];return r.insert("polygon",":first-child").attr("points",a.map((function(t){return t.x+","+t.y})).join(" ")).attr("class","state-start").attr("r",7).attr("width",28).attr("height",28),e.width=28,e.height=28,e.intersect=function(t){return Ft.circle(e,14,t)},r}),"choice"),Vt=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.height+e.padding,s=i/4,n=a.width+2*s+e.padding,o=[{x:s,y:0},{x:n-s,y:0},{x:n,y:-i/2},{x:n-s,y:-i},{x:s,y:-i},{x:0,y:-i/2}],l=Ut(r,n,i,o);return l.attr("style",e.style),Ht(e,l),e.intersect=function(t){return Ft.polygon(e,o,t)},r}),"hexagon"),Qt=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,void 0,!0),i=a.height+2*e.padding,s=i/2,n=a.width+2*s+e.padding,o=Nt(e.directions,a,e),l=Ut(r,n,i,o);return l.attr("style",e.style),Ht(e,l),e.intersect=function(t){return Ft.polygon(e,o,t)},r}),"block_arrow"),te=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(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 Ut(r,i,s,n).attr("style",e.style),e.width=i+s,e.height=s,e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"rect_left_inv_arrow"),ee=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:s/6,y:-s}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"lean_right"),re=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:2*s/6,y:0},{x:i+s/6,y:0},{x:i-2*s/6,y:-s},{x:-s/6,y:-s}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"lean_left"),ae=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:-2*s/6,y:0},{x:i+2*s/6,y:0},{x:i-s/6,y:-s},{x:s/6,y:-s}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"trapezoid"),ie=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:s/6,y:0},{x:i-s/6,y:0},{x:i+2*s/6,y:-s},{x:-2*s/6,y:-s}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"inv_trapezoid"),se=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i+s/2,y:0},{x:i,y:-s/2},{x:i+s/2,y:-s},{x:0,y:-s}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"rect_right_inv_arrow"),ne=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=i/2,n=s/(2.5+i/50),o=a.height+n+e.padding,l="M 0,"+n+" a "+s+","+n+" 0,0,0 "+i+" 0 a "+s+","+n+" 0,0,0 "+-i+" 0 l 0,"+o+" a "+s+","+n+" 0,0,0 "+i+" 0 l 0,"+-o,c=r.attr("label-offset-y",n).insert("path",":first-child").attr("style",e.style).attr("d",l).attr("transform","translate("+-i/2+","+-(o/2+n)+")");return Ht(e,c),e.intersect=function(t){const r=Ft.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"),oe=r((async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await jt(t,e,"node "+e.classes+" "+e.class,!0),n=r.insert("rect",":first-child"),o=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,c=e.positioned?-o/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(n.attr("class","basic label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",d).attr("width",o).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(de(n,e.props.borders,o,l),t.delete("borders")),t.forEach((t=>{s.warn(`Unknown node property ${t}`)}))}return Ht(e,n),e.intersect=function(t){return Ft.rect(e,t)},r}),"rect"),le=r((async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await jt(t,e,"node "+e.classes,!0),n=r.insert("rect",":first-child"),o=e.positioned?e.width:a.width+e.padding,l=e.positioned?e.height:a.height+e.padding,c=e.positioned?-o/2:-a.width/2-i,d=e.positioned?-l/2:-a.height/2-i;if(n.attr("class","basic cluster composite label-container").attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("x",c).attr("y",d).attr("width",o).attr("height",l),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(de(n,e.props.borders,o,l),t.delete("borders")),t.forEach((t=>{s.warn(`Unknown node property ${t}`)}))}return Ht(e,n),e.intersect=function(t){return Ft.rect(e,t)},r}),"composite"),ce=r((async(t,e)=>{const{shapeSvg:r}=await jt(t,e,"label",!0);s.trace("Classes = ",e.class);const a=r.insert("rect",":first-child");if(a.attr("width",0).attr("height",0),r.attr("class","label edgeLabel"),e.props){const t=new Set(Object.keys(e.props));e.props.borders&&(de(a,e.props.borders,0,0),t.delete("borders")),t.forEach((t=>{s.warn(`Unknown node property ${t}`)}))}return Ht(e,a),e.intersect=function(t){return Ft.rect(e,t)},r}),"labelRect");function de(t,e,a,i){const n=[],o=r((t=>{n.push(t,0)}),"addBorder"),l=r((t=>{n.push(0,t)}),"skipBorder");e.includes("t")?(s.debug("add top border"),o(a)):l(a),e.includes("r")?(s.debug("add right border"),o(i)):l(i),e.includes("b")?(s.debug("add bottom border"),o(a)):l(a),e.includes("l")?(s.debug("add left border"),o(i)):l(i),t.attr("stroke-dasharray",n.join(" "))}r(de,"applyNodePropertyBorders");var he=r(((t,e)=>{let r;r=e.classes?"node "+e.classes:"node default";const a=t.insert("g").attr("class",r).attr("id",e.domId||e.id),i=a.insert("rect",":first-child"),n=a.insert("line"),o=a.insert("g").attr("class","label"),c=e.labelText.flat?e.labelText.flat():e.labelText;let h="";h="object"==typeof c?c[0]:c,s.info("Label text abc79",h,c,"object"==typeof c);const g=o.node().appendChild(bt(h,e.labelStyle,!0,!0));let u={width:0,height:0};if(d(l().flowchart.htmlLabels)){const t=g.children[0],e=w(g);u=t.getBoundingClientRect(),e.attr("width",u.width),e.attr("height",u.height)}s.info("Text 2",c);const y=c.slice(1,c.length);let p=g.getBBox();const x=o.node().appendChild(bt(y.join?y.join("<br/>"):y,e.labelStyle,!0,!0));if(d(l().flowchart.htmlLabels)){const t=x.children[0],e=w(x);u=t.getBoundingClientRect(),e.attr("width",u.width),e.attr("height",u.height)}const b=e.padding/2;return w(x).attr("transform","translate( "+(u.width>p.width?0:(p.width-u.width)/2)+", "+(p.height+b+5)+")"),w(g).attr("transform","translate( "+(u.width<p.width?0:-(p.width-u.width)/2)+", 0)"),u=o.node().getBBox(),o.attr("transform","translate("+-u.width/2+", "+(-u.height/2-b+3)+")"),i.attr("class","outer title-state").attr("x",-u.width/2-b).attr("y",-u.height/2-b).attr("width",u.width+e.padding).attr("height",u.height+e.padding),n.attr("class","divider").attr("x1",-u.width/2-b).attr("x2",u.width/2+b).attr("y1",-u.height/2-b+p.height+b).attr("y2",-u.height/2-b+p.height+b),Ht(e,i),e.intersect=function(t){return Ft.rect(e,t)},a}),"rectWithTitle"),ge=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(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 Ht(e,n),e.intersect=function(t){return Ft.rect(e,t)},r}),"stadium"),ue=r((async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await jt(t,e,Zt(e,void 0),!0),n=r.insert("circle",":first-child");return n.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),s.info("Circle main"),Ht(e,n),e.intersect=function(t){return s.info("Circle intersect",e,a.width/2+i,t),Ft.circle(e,a.width/2+i,t)},r}),"circle"),ye=r((async(t,e)=>{const{shapeSvg:r,bbox:a,halfPadding:i}=await jt(t,e,Zt(e,void 0),!0),n=r.insert("g",":first-child"),o=n.insert("circle"),l=n.insert("circle");return n.attr("class",e.class),o.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i+5).attr("width",a.width+e.padding+10).attr("height",a.height+e.padding+10),l.attr("style",e.style).attr("rx",e.rx).attr("ry",e.ry).attr("r",a.width/2+i).attr("width",a.width+e.padding).attr("height",a.height+e.padding),s.info("DoubleCircle main"),Ht(e,o),e.intersect=function(t){return s.info("DoubleCircle intersect",e,a.width/2+i+5,t),Ft.circle(e,a.width/2+i+5,t)},r}),"doublecircle"),pe=r((async(t,e)=>{const{shapeSvg:r,bbox:a}=await jt(t,e,Zt(e,void 0),!0),i=a.width+e.padding,s=a.height+e.padding,n=[{x:0,y:0},{x:i,y:0},{x:i,y:-s},{x:0,y:-s},{x:0,y:0},{x:-8,y:0},{x:i+8,y:0},{x:i+8,y:-s},{x:-8,y:-s},{x:-8,y:0}],o=Ut(r,i,s,n);return o.attr("style",e.style),Ht(e,o),e.intersect=function(t){return Ft.polygon(e,n,t)},r}),"subroutine"),xe=r(((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child");return a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),Ht(e,a),e.intersect=function(t){return Ft.circle(e,7,t)},r}),"start"),be=r(((t,e,r)=>{const a=t.insert("g").attr("class","node default").attr("id",e.domId||e.id);let i=70,s=10;"LR"===r&&(i=10,s=70);const n=a.append("rect").attr("x",-1*i/2).attr("y",-1*s/2).attr("width",i).attr("height",s).attr("class","fork-join");return Ht(e,n),e.height=e.height+e.padding/2,e.width=e.width+e.padding/2,e.intersect=function(t){return Ft.rect(e,t)},a}),"forkJoin"),fe={rhombus:Gt,composite:le,question:Gt,rect:oe,labelRect:ce,rectWithTitle:he,choice:Jt,circle:ue,doublecircle:ye,stadium:ge,hexagon:Vt,block_arrow:Qt,rect_left_inv_arrow:te,lean_right:ee,lean_left:re,trapezoid:ae,inv_trapezoid:ie,rect_right_inv_arrow:se,cylinder:ne,start:xe,end:r(((t,e)=>{const r=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a=r.insert("circle",":first-child"),i=r.insert("circle",":first-child");return i.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14),a.attr("class","state-end").attr("r",5).attr("width",10).attr("height",10),Ht(e,i),e.intersect=function(t){return Ft.circle(e,7,t)},r}),"end"),note:Kt,subroutine:pe,fork:be,join:be,class_box:r(((t,e)=>{var r;const a=e.padding/2;let i;i=e.classes?"node "+e.classes:"node default";const s=t.insert("g").attr("class",i).attr("id",e.domId||e.id),n=s.insert("rect",":first-child"),o=s.insert("line"),c=s.insert("line");let h=0,g=4;const u=s.insert("g").attr("class","label");let y=0;const p=null==(r=e.classData.annotations)?void 0:r[0],x=e.classData.annotations[0]?"«"+e.classData.annotations[0]+"»":"",b=u.node().appendChild(bt(x,e.labelStyle,!0,!0));let f=b.getBBox();if(d(l().flowchart.htmlLabels)){const t=b.children[0],e=w(b);f=t.getBoundingClientRect(),e.attr("width",f.width),e.attr("height",f.height)}e.classData.annotations[0]&&(g+=f.height+4,h+=f.width);let m=e.classData.label;void 0!==e.classData.type&&""!==e.classData.type&&(l().flowchart.htmlLabels?m+="<"+e.classData.type+">":m+="<"+e.classData.type+">");const k=u.node().appendChild(bt(m,e.labelStyle,!0,!0));w(k).attr("class","classTitle");let L=k.getBBox();if(d(l().flowchart.htmlLabels)){const t=k.children[0],e=w(k);L=t.getBoundingClientRect(),e.attr("width",L.width),e.attr("height",L.height)}g+=L.height+4,L.width>h&&(h=L.width);const S=[];e.classData.members.forEach((t=>{const r=t.getDisplayDetails();let a=r.displayText;l().flowchart.htmlLabels&&(a=a.replace(/</g,"<").replace(/>/g,">"));const i=u.node().appendChild(bt(a,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0));let s=i.getBBox();if(d(l().flowchart.htmlLabels)){const t=i.children[0],e=w(i);s=t.getBoundingClientRect(),e.attr("width",s.width),e.attr("height",s.height)}s.width>h&&(h=s.width),g+=s.height+4,S.push(i)})),g+=8;const _=[];if(e.classData.methods.forEach((t=>{const r=t.getDisplayDetails();let a=r.displayText;l().flowchart.htmlLabels&&(a=a.replace(/</g,"<").replace(/>/g,">"));const i=u.node().appendChild(bt(a,r.cssStyle?r.cssStyle:e.labelStyle,!0,!0));let s=i.getBBox();if(d(l().flowchart.htmlLabels)){const t=i.children[0],e=w(i);s=t.getBoundingClientRect(),e.attr("width",s.width),e.attr("height",s.height)}s.width>h&&(h=s.width),g+=s.height+4,_.push(i)})),g+=8,p){let t=(h-f.width)/2;w(b).attr("transform","translate( "+(-1*h/2+t)+", "+-1*g/2+")"),y=f.height+4}let v=(h-L.width)/2;return w(k).attr("transform","translate( "+(-1*h/2+v)+", "+(-1*g/2+y)+")"),y+=L.height+4,o.attr("class","divider").attr("x1",-h/2-a).attr("x2",h/2+a).attr("y1",-g/2-a+8+y).attr("y2",-g/2-a+8+y),y+=8,S.forEach((t=>{w(t).attr("transform","translate( "+-h/2+", "+(-1*g/2+y+4)+")");const e=null==t?void 0:t.getBBox();y+=((null==e?void 0:e.height)??0)+4})),y+=8,c.attr("class","divider").attr("x1",-h/2-a).attr("x2",h/2+a).attr("y1",-g/2-a+8+y).attr("y2",-g/2-a+8+y),y+=8,_.forEach((t=>{w(t).attr("transform","translate( "+-h/2+", "+(-1*g/2+y)+")");const e=null==t?void 0:t.getBBox();y+=((null==e?void 0:e.height)??0)+4})),n.attr("style",e.style).attr("class","outer title-state").attr("x",-h/2-a).attr("y",-g/2-a).attr("width",h+e.padding).attr("height",g+e.padding),Ht(e,n),e.intersect=function(t){return Ft.rect(e,t)},s}),"class_box")},me={},we=r((async(t,e,r)=>{let a,i;if(e.link){let s;"sandbox"===l().securityLevel?s="_top":e.linkTarget&&(s=e.linkTarget||"_blank"),a=t.insert("svg:a").attr("xlink:href",e.link).attr("target",s),i=await fe[e.shape](a,e,r)}else i=await fe[e.shape](t,e,r),a=i;return e.tooltip&&i.attr("title",e.tooltip),e.class&&i.attr("class","node default "+e.class),me[e.id]=a,e.haveCallback&&me[e.id].attr("class",me[e.id].attr("class")+" clickable"),a}),"insertNode"),ke=r((t=>{const e=me[t.id];s.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");const r=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+r-t.width/2)+", "+(t.y-t.height/2-8)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),r}),"positionNode");function Le(t,e,r=!1){var i,s,n;const o=t;let l="default";((null==(i=null==o?void 0:o.classes)?void 0:i.length)||0)>0&&(l=((null==o?void 0:o.classes)??[]).join(" ")),l+=" flowchart-label";let c,d=0,h="";switch(o.type){case"round":d=5,h="rect";break;case"composite":d=0,h="composite",c=0;break;case"square":case"group":default:h="rect";break;case"diamond":h="question";break;case"hexagon":h="hexagon";break;case"block_arrow":h="block_arrow";break;case"odd":case"rect_left_inv_arrow":h="rect_left_inv_arrow";break;case"lean_right":h="lean_right";break;case"lean_left":h="lean_left";break;case"trapezoid":h="trapezoid";break;case"inv_trapezoid":h="inv_trapezoid";break;case"circle":h="circle";break;case"ellipse":h="ellipse";break;case"stadium":h="stadium";break;case"subroutine":h="subroutine";break;case"cylinder":h="cylinder";break;case"doublecircle":h="doublecircle"}const g=b((null==o?void 0:o.styles)??[]),u=o.label,y=o.size??{width:0,height:0,x:0,y:0};return{labelStyle:g.labelStyle,shape:h,labelText:u,rx:d,ry:d,class:l,style:g.style,id:o.id,directions:o.directions,width:y.width,height:y.height,x:y.x,y:y.y,positioned:r,intersect:void 0,type:o.type,padding:c??(null==(n=null==(s=a())?void 0:s.block)?void 0:n.padding)??0}}async function Se(t,e,r){const i=Le(e,0,!1);if("group"===i.type)return;const s=a(),n=await we(t,i,{config:s}),o=n.node().getBBox(),l=r.getBlock(i.id);l.size={width:o.width,height:o.height,x:0,y:0,node:n},r.setBlock(l),n.remove()}async function _e(t,e,r){const i=Le(e,0,!0);if("space"!==r.getBlock(i.id).type){const r=a();await we(t,i,{config:r}),e.intersect=null==i?void 0:i.intersect,ke(i)}}async function ve(t,e,r,a){for(const i of e)await a(t,i,r),i.children&&await ve(t,i.children,r,a)}async function Ee(t,e,r){await ve(t,e,r,Se)}async function De(t,e,r){await ve(t,e,r,_e)}async function $e(t,e,r,a,i){const s=new k({multigraph:!0,compound:!0});s.setGraph({rankdir:"TB",nodesep:10,ranksep:10,marginx:8,marginy:8});for(const n of r)n.size&&s.setNode(n.id,{width:n.size.width,height:n.size.height,intersect:n.intersect});for(const n of e)if(n.start&&n.end){const e=a.getBlock(n.start),r=a.getBlock(n.end);if((null==e?void 0:e.size)&&(null==r?void 0:r.size)){const a=e.size,o=r.size,l=[{x:a.x,y:a.y},{x:a.x+(o.x-a.x)/2,y:a.y+(o.y-a.y)/2},{x:o.x,y:o.y}];Tt(t,{v:n.start,w:n.end,name:n.id},{...n,arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"},void 0,"block",s,i),n.label&&(await St(t,{...n,label:n.label,labelStyle:"stroke: #333; stroke-width: 1.5px;fill:none;",arrowTypeEnd:n.arrowTypeEnd,arrowTypeStart:n.arrowTypeStart,points:l,classes:"edge-thickness-normal edge-pattern-solid flowchart-link LS-a1 LE-b1"}),vt({...n,x:l[1].x,y:l[1].y},{originalPath:l}))}}}r(Le,"getNodeFromBlock"),r(Se,"calculateBlockSize"),r(_e,"insertBlockPositioned"),r(ve,"performOperations"),r(Ee,"calculateBlockSizes"),r(De,"insertBlocks"),r($e,"insertEdges");var Te=r((function(t,e){return e.db.getClasses()}),"getClasses"),Ce={parser:E,db:rt,renderer:{draw:r((async function(t,e,r,n){const{securityLevel:o,block:l}=a(),c=n.db;let d;"sandbox"===o&&(d=w("#i"+e));const h=w("sandbox"===o?d.nodes()[0].contentDocument.body:"body"),g="sandbox"===o?h.select(`[id="${e}"]`):w(`[id="${e}"]`);ot(g,["point","circle","cross"],n.type,e);const u=c.getBlocks(),y=c.getBlocksFlat(),p=c.getEdges(),x=g.insert("g").attr("class","block");await Ee(x,u,c);const b=yt(c);if(await De(x,u,c),await $e(x,p,y,c,e),b){const t=b,e=Math.max(1,Math.round(t.width/t.height*.125)),r=t.height+e+10,a=t.width+10,{useMaxWidth:n}=l;i(g,r,a,!!n),s.debug("Here Bounds",b,t),g.attr("viewBox",`${t.x-5} ${t.y-5} ${t.width+10} ${t.height+10}`)}}),"draw"),getClasses:Te},styles:it};export{Ce as diagram}; | |