.range(i,e[n+2]),text:"---"}),r-=2):(e.splice(n,2,{type:"textord",mode:"text",loc:wo.range(i,e[n+1]),text:"--"}),r-=1)),(a==="'"||a==="`")&&e[n+1].text===a&&(e.splice(n,2,{type:"textord",mode:"text",loc:wo.range(i,e[n+1]),text:a+a}),r-=1)}}parseSymbol(){var e=this.fetch(),r=e.text;if(/^\\verb[^a-zA-Z]/.test(r)){this.consume();var n=r.slice(5),i=n.charAt(0)==="*";if(i&&(n=n.slice(1)),n.length<2||n.charAt(0)!==n.slice(-1))throw new pt(`\\verb assertion failed -- please report what input caused this bug`);return n=n.slice(1,-1),{type:"verb",mode:"text",body:n,star:i}}YV.hasOwnProperty(r[0])&&!Nn[this.mode][r[0]]&&(this.settings.strict&&this.mode==="math"&&this.settings.reportNonstrict("unicodeTextInMathMode",'Accented Unicode text character "'+r[0]+'" used in math mode',e),r=YV[r[0]]+r.slice(1));var a=QEe.exec(r);a&&(r=r.substring(0,a.index),r==="i"?r="\u0131":r==="j"&&(r="\u0237"));var s;if(Nn[this.mode][r]){this.settings.strict&&this.mode==="math"&&h8.indexOf(r)>=0&&this.settings.reportNonstrict("unicodeTextInMathMode",'Latin-1/Unicode text character "'+r[0]+'" used in math mode',e);var o=Nn[this.mode][r].group,l=wo.range(e),u;if(Wke.hasOwnProperty(o)){var h=o;u={type:"atom",mode:this.mode,family:h,loc:l,text:r}}else u={type:o,mode:this.mode,loc:l,text:r};s=u}else if(r.charCodeAt(0)>=128)this.settings.strict&&(jV(r.charCodeAt(0))?this.mode==="math"&&this.settings.reportNonstrict("unicodeTextInMathMode",'Unicode text character "'+r[0]+'" used in math mode',e):this.settings.reportNonstrict("unknownSymbol",'Unrecognized Unicode character "'+r[0]+'"'+(" ("+r.charCodeAt(0)+")"),e)),s={type:"textord",mode:"text",loc:wo.range(e),text:r};else return null;if(this.consume(),a)for(var f=0;f{e.tagName==="A"&&e.hasAttribute("target")&&e.setAttribute(t,e.getAttribute("target")??"")}),tf.addHook("afterSanitizeAttributes",e=>{e.tagName==="A"&&e.hasAttribute(t)&&(e.setAttribute("target",e.getAttribute(t)??""),e.removeAttribute(t),e.getAttribute("target")==="_blank"&&e.setAttribute("rel","noopener"))})}var z8,Gg,rSe,G8,lf,Gv,D5,eW,tW,F8,Gn,N5,I5,ms,nSe,iSe,aSe,sSe,oSe,mp,lSe,cSe,uSe,hSe,Oc,Mc,rW,nW,fSe,hr,zv,dSe,yp,Us,L5,gp,$v,M5,iW,aW,sW,q8,V8,fr,oW,lW,qv,pSe,KU,gSe,cW,uW,vp,mSe,ySe,fW,ZU,ur,vSe,xSe,bSe,wSe,dW,xp,Kr,TSe,kSe,Pc,$8,ESe,SSe,QU,A5,qn,qg,CSe,cf,tt,ASe,_Se,xn,eh,_5,LSe,RSe,pW,O5,U8,W8,H8,Y8,kr,Nr,Ir,Mr,Or,Vr,Pr,JU,DSe,Te,Vv,P5,B5,X8,NSe,R5,Uv,F5,ISe,Er=$(()=>{lr();xo();xo();xo();xo();xo();xo();XA();z8=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,Gg=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,rSe=/\s*%%.*\n/gm,G8=class extends Error{static{x(this,"UnknownDiagramError")}constructor(t){super(t),this.name="UnknownDiagramError"}},lf={},Gv=x(function(t,e){t=t.replace(z8,"").replace(Gg,"").replace(rSe,` `);for(let[r,{detector:n}]of Object.entries(lf))if(n(t,e))return r;throw new G8(`No diagram type detected matching given configuration for text: ${t}`)},"detectType"),D5=x((...t)=>{for(let{id:e,detector:r,loader:n}of t)eW(e,r,n)},"registerLazyLoadedDiagrams"),eW=x((t,e,r)=>{lf[t]&&te.warn(`Detector with key ${t} already exists. Overwriting.`),lf[t]={detector:e,loader:r},te.debug(`Detector with key ${t} added${r?" with loader":""}`)},"addDetector"),tW=x(t=>lf[t].loader,"getDiagramLoader"),F8=x((t,e,{depth:r=2,clobber:n=!1}={})=>{let i={depth:r,clobber:n};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach(a=>F8(t,a,i)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(a=>{t.includes(a)||t.push(a)}),t):t===void 0||r<=0?t!=null&&typeof t=="object"&&typeof e=="object"?Object.assign(t,e):e:(e!==void 0&&typeof t=="object"&&typeof e=="object"&&Object.keys(e).forEach(a=>{typeof e[a]=="object"&&(t[a]===void 0||typeof t[a]=="object")?(t[a]===void 0&&(t[a]=Array.isArray(e[a])?[]:{}),t[a]=F8(t[a],e[a],{depth:r-1,clobber:n})):(n||typeof t[a]!="object"&&typeof e[a]!="object")&&(t[a]=e[a])}),t)},"assignWithDepth"),Gn=F8,N5="#ffffff",I5="#f2f2f2",ms=x((t,e)=>e?Be(t,{s:-40,l:10}):Be(t,{s:-40,l:-10}),"mkBorder"),nSe=class{static{x(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||Be(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||Be(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ms(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ms(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ms(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ms(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||wt(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||wt(this.tertiaryColor),this.lineColor=this.lineColor||wt(this.background),this.arrowheadColor=this.arrowheadColor||wt(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?It(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||It(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||wt(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||At(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.vertLineColor=this.vertLineColor||"navy",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.darkMode?(this.rowOdd=this.rowOdd||It(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||It(this.mainBkg,10)):(this.rowOdd=this.rowOdd||At(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||At(this.mainBkg,5)),this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Be(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Be(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Be(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Be(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Be(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Be(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||Be(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Be(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Be(this.primaryColor,{h:330}),this.darkMode)for(let e=0;e{this[r]=t[r]}),this.updateColors(),e.forEach(r=>{this[r]=t[r]})}},iSe=x(t=>{let e=new nSe;return e.calculate(t),e},"getThemeVariables"),aSe=class{static{x(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=At(this.primaryColor,16),this.tertiaryColor=Be(this.primaryColor,{h:-160}),this.primaryBorderColor=wt(this.background),this.secondaryBorderColor=ms(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ms(this.tertiaryColor,this.darkMode),this.primaryTextColor=wt(this.primaryColor),this.secondaryTextColor=wt(this.secondaryColor),this.tertiaryTextColor=wt(this.tertiaryColor),this.lineColor=wt(this.background),this.textColor=wt(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=At(wt("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=cs(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=It("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=It(this.sectionBkgColor,10),this.taskBorderColor=cs(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=cs(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||At(this.mainBkg,5)||"#ffffff",this.rowEven=this.rowEven||It(this.mainBkg,10),this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){this.secondBkg=At(this.mainBkg,16),this.lineColor=this.mainContrastColor,this.arrowheadColor=this.mainContrastColor,this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.edgeLabelBackground=At(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=At(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=Be(this.primaryColor,{h:64}),this.fillType3=Be(this.secondaryColor,{h:64}),this.fillType4=Be(this.primaryColor,{h:-64}),this.fillType5=Be(this.secondaryColor,{h:-64}),this.fillType6=Be(this.primaryColor,{h:128}),this.fillType7=Be(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Be(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Be(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Be(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Be(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Be(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Be(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Be(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Be(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Be(this.primaryColor,{h:330});for(let t=0;t{this[r]=t[r]}),this.updateColors(),e.forEach(r=>{this[r]=t[r]})}},sSe=x(t=>{let e=new aSe;return e.calculate(t),e},"getThemeVariables"),oSe=class{static{x(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=Be(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=Be(this.primaryColor,{h:-160}),this.primaryBorderColor=ms(this.primaryColor,this.darkMode),this.secondaryBorderColor=ms(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ms(this.tertiaryColor,this.darkMode),this.primaryTextColor=wt(this.primaryColor),this.secondaryTextColor=wt(this.secondaryColor),this.tertiaryTextColor=wt(this.tertiaryColor),this.lineColor=wt(this.background),this.textColor=wt(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.sectionBkgColor=cs(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="navy",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd="calculated",this.rowEven="calculated",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Be(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Be(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Be(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Be(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Be(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Be(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Be(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Be(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Be(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||It(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||It(this.tertiaryColor,40);for(let t=0;t{this[r]==="calculated"&&(this[r]=void 0)}),typeof t!="object"){this.updateColors();return}let e=Object.keys(t);e.forEach(r=>{this[r]=t[r]}),this.updateColors(),e.forEach(r=>{this[r]=t[r]})}},mp=x(t=>{let e=new oSe;return e.calculate(t),e},"getThemeVariables"),lSe=class{static{x(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=At("#cde498",10),this.primaryBorderColor=ms(this.primaryColor,this.darkMode),this.secondaryBorderColor=ms(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ms(this.tertiaryColor,this.darkMode),this.primaryTextColor=wt(this.primaryColor),this.secondaryTextColor=wt(this.secondaryColor),this.tertiaryTextColor=wt(this.primaryColor),this.lineColor=wt(this.background),this.textColor=wt(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.vertLineColor="#00BFFF",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.actorBorder=It(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||Be(this.primaryColor,{h:30}),this.cScale4=this.cScale4||Be(this.primaryColor,{h:60}),this.cScale5=this.cScale5||Be(this.primaryColor,{h:90}),this.cScale6=this.cScale6||Be(this.primaryColor,{h:120}),this.cScale7=this.cScale7||Be(this.primaryColor,{h:150}),this.cScale8=this.cScale8||Be(this.primaryColor,{h:210}),this.cScale9=this.cScale9||Be(this.primaryColor,{h:270}),this.cScale10=this.cScale10||Be(this.primaryColor,{h:300}),this.cScale11=this.cScale11||Be(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||It(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||It(this.tertiaryColor,40);for(let t=0;t{this[r]=t[r]}),this.updateColors(),e.forEach(r=>{this[r]=t[r]})}},cSe=x(t=>{let e=new lSe;return e.calculate(t),e},"getThemeVariables"),uSe=class{static{x(this,"Theme")}constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=At(this.contrast,55),this.background="#ffffff",this.tertiaryColor=Be(this.primaryColor,{h:-160}),this.primaryBorderColor=ms(this.primaryColor,this.darkMode),this.secondaryBorderColor=ms(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ms(this.tertiaryColor,this.darkMode),this.primaryTextColor=wt(this.primaryColor),this.secondaryTextColor=wt(this.secondaryColor),this.tertiaryTextColor=wt(this.tertiaryColor),this.lineColor=wt(this.background),this.textColor=wt(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.vertLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.rowOdd=this.rowOdd||At(this.mainBkg,75)||"#ffffff",this.rowEven=this.rowEven||"#f4f4f4",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.secondBkg=At(this.contrast,55),this.border2=this.contrast,this.actorBorder=At(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let t=0;t{this[r]=t[r]}),this.updateColors(),e.forEach(r=>{this[r]=t[r]})}},hSe=x(t=>{let e=new uSe;return e.calculate(t),e},"getThemeVariables"),Oc={base:{getThemeVariables:iSe},dark:{getThemeVariables:sSe},default:{getThemeVariables:mp},forest:{getThemeVariables:cSe},neutral:{getThemeVariables:hSe}},Mc={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200,inheritDir:!1},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,maxLabelWidth:360,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],titleColor:"",titleFontFamily:'"trebuchet ms", verdana, arial, sans-serif',titleFontSize:"4ex"},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,nodeSpacing:140,rankSpacing:80,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showDataLabel:!1,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200,layoutAlgorithm:"cose-bilkent"},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16},radar:{useMaxWidth:!0,width:600,height:600,marginTop:50,marginRight:50,marginBottom:50,marginLeft:50,axisScaleFactor:1,axisLabelFactor:1.05,curveTension:.17},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1},rW={...Mc,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF",forceNodeModelOrder:!1,considerModelOrder:"NODES_AND_EDGES"},themeCSS:void 0,themeVariables:Oc.default.getThemeVariables(),sequence:{...Mc.sequence,messageFont:x(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:x(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:x(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...Mc.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Mc.c4,useWidth:void 0,personFont:x(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),flowchart:{...Mc.flowchart,inheritDir:!1},external_personFont:x(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:x(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:x(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:x(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:x(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:x(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:x(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:x(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:x(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:x(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:x(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:x(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:x(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:x(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:x(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:x(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:x(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:x(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:x(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:x(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:x(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...Mc.pie,useWidth:984},xyChart:{...Mc.xyChart,useWidth:void 0},requirement:{...Mc.requirement,useWidth:void 0},packet:{...Mc.packet},radar:{...Mc.radar},treemap:{useMaxWidth:!0,padding:10,diagramPadding:8,showValues:!0,nodeWidth:100,nodeHeight:40,borderWidth:1,valueFontSize:12,labelFontSize:14,valueFormat:","}},nW=x((t,e="")=>Object.keys(t).reduce((r,n)=>Array.isArray(t[n])?r:typeof t[n]=="object"&&t[n]!==null?[...r,e+n,...nW(t[n],"")]:[...r,e+n],[]),"keyify"),fSe=new Set(nW(rW,"")),hr=rW,zv=x(t=>{if(te.debug("sanitizeDirective called with",t),!(typeof t!="object"||t==null)){if(Array.isArray(t)){t.forEach(e=>zv(e));return}for(let e of Object.keys(t)){if(te.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!fSe.has(e)||t[e]==null){te.debug("sanitize deleting key: ",e),delete t[e];continue}if(typeof t[e]=="object"){te.debug("sanitizing object",e),zv(t[e]);continue}let r=["themeCSS","fontFamily","altFontFamily"];for(let n of r)e.includes(n)&&(te.debug("sanitizing css option",e),t[e]=dSe(t[e]))}if(t.themeVariables)for(let e of Object.keys(t.themeVariables)){let r=t.themeVariables[e];r?.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}te.debug("After sanitization",t)}},"sanitizeDirective"),dSe=x(t=>{let e=0,r=0;for(let n of t){if(e{let r=Gn({},t),n={};for(let i of e)oW(i),n=Gn(n,i);if(r=Gn(r,n),n.theme&&n.theme in Oc){let i=Gn({},L5),a=Gn(i.themeVariables||{},n.themeVariables);r.theme&&r.theme in Oc&&(r.themeVariables=Oc[r.theme].getThemeVariables(a))}return $v=r,cW($v),$v},"updateCurrentConfig"),iW=x(t=>(Us=Gn({},yp),Us=Gn(Us,t),t.theme&&Oc[t.theme]&&(Us.themeVariables=Oc[t.theme].getThemeVariables(t.themeVariables)),M5(Us,gp),Us),"setSiteConfig"),aW=x(t=>{L5=Gn({},t)},"saveConfigFromInitialize"),sW=x(t=>(Us=Gn(Us,t),M5(Us,gp),Us),"updateSiteConfig"),q8=x(()=>Gn({},Us),"getSiteConfig"),V8=x(t=>(cW(t),Gn($v,t),fr()),"setConfig"),fr=x(()=>Gn({},$v),"getConfig"),oW=x(t=>{t&&(["secure",...Us.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(te.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])}),Object.keys(t).forEach(e=>{e.startsWith("__")&&delete t[e]}),Object.keys(t).forEach(e=>{typeof t[e]=="string"&&(t[e].includes("<")||t[e].includes(">")||t[e].includes("url(data:"))&&delete t[e],typeof t[e]=="object"&&oW(t[e])}))},"sanitize"),lW=x(t=>{zv(t),t.fontFamily&&!t.themeVariables?.fontFamily&&(t.themeVariables={...t.themeVariables,fontFamily:t.fontFamily}),gp.push(t),M5(Us,gp)},"addDirective"),qv=x((t=Us)=>{gp=[],M5(t,gp)},"reset"),pSe={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},KU={},gSe=x(t=>{KU[t]||(te.warn(pSe[t]),KU[t]=!0)},"issueWarning"),cW=x(t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&gSe("LAZY_LOAD_DEPRECATED")},"checkConfig"),uW=x(()=>{let t={};L5&&(t=Gn(t,L5));for(let e of gp)t=Gn(t,e);return t},"getUserDefinedConfig"),vp=//gi,mSe=x(t=>t?dW(t).replace(/\\n/g,"#br#").split("#br#"):[""],"getRows"),ySe=(()=>{let t=!1;return()=>{t||(hW(),t=!0)}})();x(hW,"setupDompurifyHooks");fW=x(t=>(ySe(),tf.sanitize(t)),"removeScript"),ZU=x((t,e)=>{if(e.flowchart?.htmlLabels!==!1){let r=e.securityLevel;r==="antiscript"||r==="strict"?t=fW(t):r!=="loose"&&(t=dW(t),t=t.replace(//g,">"),t=t.replace(/=/g,"="),t=wSe(t))}return t},"sanitizeMore"),ur=x((t,e)=>t&&(e.dompurifyConfig?t=tf.sanitize(ZU(t,e),e.dompurifyConfig).toString():t=tf.sanitize(ZU(t,e),{FORBID_TAGS:["style"]}).toString(),t),"sanitizeText"),vSe=x((t,e)=>typeof t=="string"?ur(t,e):t.flat().map(r=>ur(r,e)),"sanitizeTextOrArray"),xSe=x(t=>vp.test(t),"hasBreaks"),bSe=x(t=>t.split(vp),"splitBreaks"),wSe=x(t=>t.replace(/#br#/g,"
"),"placeholderToBreak"),dW=x(t=>t.replace(vp,"#br#"),"breakToPlaceholder"),xp=x(t=>{let e="";return t&&(e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=CSS.escape(e)),e},"getUrl"),Kr=x(t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),"evaluate"),TSe=x(function(...t){let e=t.filter(r=>!isNaN(r));return Math.max(...e)},"getMax"),kSe=x(function(...t){let e=t.filter(r=>!isNaN(r));return Math.min(...e)},"getMin"),Pc=x(function(t){let e=t.split(/(,)/),r=[];for(let n=0;n0&&n+1Math.max(0,t.split(e).length-1),"countOccurrence"),ESe=x((t,e)=>{let r=$8(t,"~"),n=$8(e,"~");return r===1&&n===1},"shouldCombineSets"),SSe=x(t=>{let e=$8(t,"~"),r=!1;if(e<=1)return t;e%2!==0&&t.startsWith("~")&&(t=t.substring(1),r=!0);let n=[...t],i=n.indexOf("~"),a=n.lastIndexOf("~");for(;i!==-1&&a!==-1&&i!==a;)n[i]="<",n[a]=">",i=n.indexOf("~"),a=n.lastIndexOf("~");return r&&n.unshift("~"),n.join("")},"processSet"),QU=x(()=>window.MathMLElement!==void 0,"isMathMLSupported"),A5=/\$\$(.*)\$\$/g,qn=x(t=>(t.match(A5)?.length??0)>0,"hasKatex"),qg=x(async(t,e)=>{let r=document.createElement("div");r.innerHTML=await cf(t,e),r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0",document.querySelector("body")?.insertAdjacentElement("beforeend",r);let i={width:r.clientWidth,height:r.clientHeight};return r.remove(),i},"calculateMathMLDimensions"),CSe=x(async(t,e)=>{if(!qn(t))return t;if(!(QU()||e.legacyMathML||e.forceLegacyMathML))return t.replace(A5,"MathML is unsupported in this environment.");{let{default:r}=await Promise.resolve().then(()=>(jU(),XU)),n=e.forceLegacyMathML||!QU()&&e.legacyMathML?"htmlAndMathml":"mathml";return t.split(vp).map(i=>qn(i)?`
${i}
`:`
${i}
`).join("").replace(A5,(i,a)=>r.renderToString(a,{throwOnError:!0,displayMode:!0,output:n}).replace(/\n/g," ").replace(//g,""))}return t.replace(A5,"Katex is not supported in @mermaid-js/tiny. Please use the full mermaid library.")},"renderKatexUnsanitized"),cf=x(async(t,e)=>ur(await CSe(t,e),e),"renderKatexSanitized"),tt={getRows:mSe,sanitizeText:ur,sanitizeTextOrArray:vSe,hasBreaks:xSe,splitBreaks:bSe,lineBreakRegex:vp,removeScript:fW,getUrl:xp,evaluate:Kr,getMax:TSe,getMin:kSe},ASe=x(function(t,e){for(let r of e)t.attr(r[0],r[1])},"d3Attrs"),_Se=x(function(t,e,r){let n=new Map;return r?(n.set("width","100%"),n.set("style",`max-width: ${e}px;`)):(n.set("height",t),n.set("width",e)),n},"calculateSvgSizeAttrs"),xn=x(function(t,e,r,n){let i=_Se(e,r,n);ASe(t,i)},"configureSvgSize"),eh=x(function(t,e,r,n){let i=e.node().getBBox(),a=i.width,s=i.height;te.info(`SVG bounds: ${a}x${s}`,i);let o=0,l=0;te.info(`Graph bounds: ${o}x${l}`,t),o=a+r*2,l=s+r*2,te.info(`Calculated bounds: ${o}x${l}`),xn(e,l,o,n);let u=`${i.x-r} ${i.y-r} ${i.width+2*r} ${i.height+2*r}`;e.attr("viewBox",u)},"setupGraphViewbox"),_5={},LSe=x((t,e,r)=>{let n="";return t in _5&&_5[t]?n=_5[t](r):te.warn(`No theme found for ${t}`),` & { font-family: ${r.fontFamily}; font-size: ${r.fontSize}; fill: ${r.textColor} } @keyframes edge-animation-frame { from { stroke-dashoffset: 0; } } @keyframes dash { to { stroke-dashoffset: 0; } } & .edge-animation-slow { stroke-dasharray: 9,5 !important; stroke-dashoffset: 900; animation: dash 50s linear infinite; stroke-linecap: round; } & .edge-animation-fast { stroke-dasharray: 9,5 !important; stroke-dashoffset: 900; animation: dash 20s linear infinite; stroke-linecap: round; } /* Classes common for multiple diagrams */ & .error-icon { fill: ${r.errorBkgColor}; } & .error-text { fill: ${r.errorTextColor}; stroke: ${r.errorTextColor}; } & .edge-thickness-normal { stroke-width: 1px; } & .edge-thickness-thick { stroke-width: 3.5px } & .edge-pattern-solid { stroke-dasharray: 0; } & .edge-thickness-invisible { stroke-width: 0; fill: none; } & .edge-pattern-dashed{ stroke-dasharray: 3; } .edge-pattern-dotted { stroke-dasharray: 2; } & .marker { fill: ${r.lineColor}; stroke: ${r.lineColor}; } & .marker.cross { stroke: ${r.lineColor}; } & svg { font-family: ${r.fontFamily}; font-size: ${r.fontSize}; } & p { margin: 0 } ${n} ${e} `},"getStyles"),RSe=x((t,e)=>{e!==void 0&&(_5[t]=e)},"addStylesForDiagram"),pW=LSe,O5={};Jh(O5,{clear:()=>kr,getAccDescription:()=>Or,getAccTitle:()=>Ir,getDiagramTitle:()=>Pr,setAccDescription:()=>Mr,setAccTitle:()=>Nr,setDiagramTitle:()=>Vr});U8="",W8="",H8="",Y8=x(t=>ur(t,fr()),"sanitizeText"),kr=x(()=>{U8="",H8="",W8=""},"clear"),Nr=x(t=>{U8=Y8(t).replace(/^\s+/g,"")},"setAccTitle"),Ir=x(()=>U8,"getAccTitle"),Mr=x(t=>{H8=Y8(t).replace(/\n\s+/g,` `)},"setAccDescription"),Or=x(()=>H8,"getAccDescription"),Vr=x(t=>{W8=Y8(t)},"setDiagramTitle"),Pr=x(()=>W8,"getDiagramTitle"),JU=te,DSe=vv,Te=fr,Vv=V8,P5=yp,B5=x(t=>ur(t,Te()),"sanitizeText"),X8=eh,NSe=x(()=>O5,"getCommonDb"),R5={},Uv=x((t,e,r)=>{R5[t]&&JU.warn(`Diagram with id ${t} already registered. Overwriting.`),R5[t]=e,r&&eW(t,r),RSe(t,e.styles),e.injectUtils?.(JU,DSe,Te,B5,X8,NSe(),()=>{})},"registerDiagram"),F5=x(t=>{if(t in R5)return R5[t];throw new ISe(t)},"getDiagram"),ISe=class extends Error{static{x(this,"DiagramNotFoundError")}constructor(t){super(`Diagram ${t} not found.`)}}});function bp(t,e){return t==null||e==null?NaN:te?1:t>=e?0:NaN}var j8=$(()=>{});function K8(t,e){return t==null||e==null?NaN:et?1:e>=t?0:NaN}var gW=$(()=>{});function wp(t){let e,r,n;t.length!==2?(e=bp,r=(o,l)=>bp(t(o),l),n=(o,l)=>t(o)-l):(e=t===bp||t===K8?t:MSe,r=t,n=t);function i(o,l,u=0,h=o.length){if(u>>1;r(o[f],l)<0?u=f+1:h=f}while(u>>1;r(o[f],l)<=0?u=f+1:h=f}while(uu&&n(o[f-1],l)>-n(o[f],l)?f-1:f}return{left:i,center:s,right:a}}function MSe(){return 0}var Z8=$(()=>{j8();gW()});function Q8(t){return t===null?NaN:+t}var mW=$(()=>{});var yW,vW,OSe,PSe,J8,xW=$(()=>{j8();Z8();mW();yW=wp(bp),vW=yW.right,OSe=yW.left,PSe=wp(Q8).center,J8=vW});function bW({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):r}function BSe({_intern:t,_key:e},r){let n=e(r);return t.has(n)?t.get(n):(t.set(n,r),r)}function FSe({_intern:t,_key:e},r){let n=e(r);return t.has(n)&&(r=t.get(n),t.delete(n)),r}function $Se(t){return t!==null&&typeof t=="object"?t.valueOf():t}var Vg,wW=$(()=>{Vg=class extends Map{constructor(e,r=$Se){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(let[n,i]of e)this.set(n,i)}get(e){return super.get(bW(this,e))}has(e){return super.has(bW(this,e))}set(e,r){return super.set(BSe(this,e),r)}delete(e){return super.delete(FSe(this,e))}}});function $5(t,e,r){let n=(e-t)/Math.max(0,r),i=Math.floor(Math.log10(n)),a=n/Math.pow(10,i),s=a>=zSe?10:a>=GSe?5:a>=qSe?2:1,o,l,u;return i<0?(u=Math.pow(10,-i)/s,o=Math.round(t*u),l=Math.round(e*u),o/ue&&--l,u=-u):(u=Math.pow(10,i)*s,o=Math.round(t/u),l=Math.round(e/u),o*ue&&--l),l0))return[];if(t===e)return[t];let n=e=i))return[];let o=a-i+1,l=new Array(o);if(n)if(s<0)for(let u=0;u{zSe=Math.sqrt(50),GSe=Math.sqrt(10),qSe=Math.sqrt(2)});function G5(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r=n)&&(r=n);else{let n=-1;for(let i of t)(i=e(i,++n,t))!=null&&(r=i)&&(r=i)}return r}var kW=$(()=>{});function q5(t,e){let r;if(e===void 0)for(let n of t)n!=null&&(r>n||r===void 0&&n>=n)&&(r=n);else{let n=-1;for(let i of t)(i=e(i,++n,t))!=null&&(r>i||r===void 0&&i>=i)&&(r=i)}return r}var EW=$(()=>{});function V5(t,e,r){t=+t,e=+e,r=(i=arguments.length)<2?(e=t,t=0,1):i<3?1:+r;for(var n=-1,i=Math.max(0,Math.ceil((e-t)/r))|0,a=new Array(i);++n{});var uf=$(()=>{xW();Z8();kW();EW();SW();TW();wW()});function CW(t){return t}var AW=$(()=>{});function VSe(t){return"translate("+t+",0)"}function USe(t){return"translate(0,"+t+")"}function WSe(t){return e=>+t(e)}function HSe(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}function YSe(){return!this.__axis}function LW(t,e){var r=[],n=null,i=null,a=6,s=6,o=3,l=typeof window<"u"&&window.devicePixelRatio>1?0:.5,u=t===W5||t===U5?-1:1,h=t===U5||t===e_?"x":"y",f=t===W5||t===t_?VSe:USe;function d(p){var g=n??(e.ticks?e.ticks.apply(e,r):e.domain()),m=i??(e.tickFormat?e.tickFormat.apply(e,r):CW),y=Math.max(a,0)+o,v=e.range(),b=+v[0]+l,w=+v[v.length-1]+l,S=(e.bandwidth?HSe:WSe)(e.copy(),l),T=p.selection?p.selection():p,k=T.selectAll(".domain").data([null]),C=T.selectAll(".tick").data(g,e).order(),L=C.exit(),D=C.enter().append("g").attr("class","tick"),M=C.select("line"),I=C.select("text");k=k.merge(k.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),C=C.merge(D),M=M.merge(D.append("line").attr("stroke","currentColor").attr(h+"2",u*a)),I=I.merge(D.append("text").attr("fill","currentColor").attr(h,u*y).attr("dy",t===W5?"0em":t===t_?"0.71em":"0.32em")),p!==T&&(k=k.transition(p),C=C.transition(p),M=M.transition(p),I=I.transition(p),L=L.transition(p).attr("opacity",_W).attr("transform",function(E){return isFinite(E=S(E))?f(E+l):this.getAttribute("transform")}),D.attr("opacity",_W).attr("transform",function(E){var _=this.parentNode.__axis;return f((_&&isFinite(_=_(E))?_:S(E))+l)})),L.remove(),k.attr("d",t===U5||t===e_?s?"M"+u*s+","+b+"H"+l+"V"+w+"H"+u*s:"M"+l+","+b+"V"+w:s?"M"+b+","+u*s+"V"+l+"H"+w+"V"+u*s:"M"+b+","+l+"H"+w),C.attr("opacity",1).attr("transform",function(E){return f(S(E)+l)}),M.attr(h+"2",u*a),I.attr(h,u*y).text(m),T.filter(YSe).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===e_?"start":t===U5?"end":"middle"),T.each(function(){this.__axis=S})}return d.scale=function(p){return arguments.length?(e=p,d):e},d.ticks=function(){return r=Array.from(arguments),d},d.tickArguments=function(p){return arguments.length?(r=p==null?[]:Array.from(p),d):r.slice()},d.tickValues=function(p){return arguments.length?(n=p==null?null:Array.from(p),d):n&&n.slice()},d.tickFormat=function(p){return arguments.length?(i=p,d):i},d.tickSize=function(p){return arguments.length?(a=s=+p,d):a},d.tickSizeInner=function(p){return arguments.length?(a=+p,d):a},d.tickSizeOuter=function(p){return arguments.length?(s=+p,d):s},d.tickPadding=function(p){return arguments.length?(o=+p,d):o},d.offset=function(p){return arguments.length?(l=+p,d):l},d}function r_(t){return LW(W5,t)}function n_(t){return LW(t_,t)}var W5,e_,t_,U5,_W,RW=$(()=>{AW();W5=1,e_=2,t_=3,U5=4,_W=1e-6});var DW=$(()=>{RW()});function IW(){for(var t=0,e=arguments.length,r={},n;t=0&&(n=r.slice(i+1),r=r.slice(0,i)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:n}})}function KSe(t,e){for(var r=0,n=t.length,i;r{XSe={value:()=>{}};H5.prototype=IW.prototype={constructor:H5,on:function(t,e){var r=this._,n=jSe(t+"",r),i,a=-1,s=n.length;if(arguments.length<2){for(;++a0)for(var r=new Array(i),n=0,i,a;n{MW()});var Y5,s_,o_=$(()=>{Y5="http://www.w3.org/1999/xhtml",s_={svg:"http://www.w3.org/2000/svg",xhtml:Y5,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"}});function th(t){var e=t+="",r=e.indexOf(":");return r>=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),s_.hasOwnProperty(e)?{space:s_[e],local:t}:t}var X5=$(()=>{o_()});function ZSe(t){return function(){var e=this.ownerDocument,r=this.namespaceURI;return r===Y5&&e.documentElement.namespaceURI===Y5?e.createElement(t):e.createElementNS(r,t)}}function QSe(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function j5(t){var e=th(t);return(e.local?QSe:ZSe)(e)}var l_=$(()=>{X5();o_()});function JSe(){}function Tp(t){return t==null?JSe:function(){return this.querySelector(t)}}var K5=$(()=>{});function OW(t){typeof t!="function"&&(t=Tp(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i{$l();K5()});function c_(t){return t==null?[]:Array.isArray(t)?t:Array.from(t)}var BW=$(()=>{});function e6e(){return[]}function Hv(t){return t==null?e6e:function(){return this.querySelectorAll(t)}}var u_=$(()=>{});function t6e(t){return function(){return c_(t.apply(this,arguments))}}function FW(t){typeof t=="function"?t=t6e(t):t=Hv(t);for(var e=this._groups,r=e.length,n=[],i=[],a=0;a{$l();BW();u_()});function Yv(t){return function(){return this.matches(t)}}function Z5(t){return function(e){return e.matches(t)}}var Xv=$(()=>{});function n6e(t){return function(){return r6e.call(this.children,t)}}function i6e(){return this.firstElementChild}function zW(t){return this.select(t==null?i6e:n6e(typeof t=="function"?t:Z5(t)))}var r6e,GW=$(()=>{Xv();r6e=Array.prototype.find});function s6e(){return Array.from(this.children)}function o6e(t){return function(){return a6e.call(this.children,t)}}function qW(t){return this.selectAll(t==null?s6e:o6e(typeof t=="function"?t:Z5(t)))}var a6e,VW=$(()=>{Xv();a6e=Array.prototype.filter});function UW(t){typeof t!="function"&&(t=Yv(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i{$l();Xv()});function Q5(t){return new Array(t.length)}var h_=$(()=>{});function HW(){return new mi(this._enter||this._groups.map(Q5),this._parents)}function jv(t,e){this.ownerDocument=t.ownerDocument,this.namespaceURI=t.namespaceURI,this._next=null,this._parent=t,this.__data__=e}var f_=$(()=>{h_();$l();jv.prototype={constructor:jv,appendChild:function(t){return this._parent.insertBefore(t,this._next)},insertBefore:function(t,e){return this._parent.insertBefore(t,e)},querySelector:function(t){return this._parent.querySelector(t)},querySelectorAll:function(t){return this._parent.querySelectorAll(t)}}});function YW(t){return function(){return t}}var XW=$(()=>{});function l6e(t,e,r,n,i,a){for(var s=0,o,l=e.length,u=a.length;s=w&&(w=b+1);!(T=y[w])&&++w{$l();f_();XW()});function ZW(){return new mi(this._exit||this._groups.map(Q5),this._parents)}var QW=$(()=>{h_();$l()});function JW(t,e,r){var n=this.enter(),i=this,a=this.exit();return typeof t=="function"?(n=t(n),n&&(n=n.selection())):n=n.append(t+""),e!=null&&(i=e(i),i&&(i=i.selection())),r==null?a.remove():r(a),n&&i?n.merge(i).order():i}var eH=$(()=>{});function tH(t){for(var e=t.selection?t.selection():t,r=this._groups,n=e._groups,i=r.length,a=n.length,s=Math.min(i,a),o=new Array(i),l=0;l{$l()});function nH(){for(var t=this._groups,e=-1,r=t.length;++e=0;)(s=n[i])&&(a&&s.compareDocumentPosition(a)^4&&a.parentNode.insertBefore(s,a),a=s);return this}var iH=$(()=>{});function aH(t){t||(t=f6e);function e(f,d){return f&&d?t(f.__data__,d.__data__):!f-!d}for(var r=this._groups,n=r.length,i=new Array(n),a=0;ae?1:t>=e?0:NaN}var sH=$(()=>{$l()});function oH(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}var lH=$(()=>{});function cH(){return Array.from(this)}var uH=$(()=>{});function hH(){for(var t=this._groups,e=0,r=t.length;e{});function dH(){let t=0;for(let e of this)++t;return t}var pH=$(()=>{});function gH(){return!this.node()}var mH=$(()=>{});function yH(t){for(var e=this._groups,r=0,n=e.length;r{});function d6e(t){return function(){this.removeAttribute(t)}}function p6e(t){return function(){this.removeAttributeNS(t.space,t.local)}}function g6e(t,e){return function(){this.setAttribute(t,e)}}function m6e(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}function y6e(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}function v6e(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}function xH(t,e){var r=th(t);if(arguments.length<2){var n=this.node();return r.local?n.getAttributeNS(r.space,r.local):n.getAttribute(r)}return this.each((e==null?r.local?p6e:d6e:typeof e=="function"?r.local?v6e:y6e:r.local?m6e:g6e)(r,e))}var bH=$(()=>{X5()});function J5(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}var d_=$(()=>{});function x6e(t){return function(){this.style.removeProperty(t)}}function b6e(t,e,r){return function(){this.style.setProperty(t,e,r)}}function w6e(t,e,r){return function(){var n=e.apply(this,arguments);n==null?this.style.removeProperty(t):this.style.setProperty(t,n,r)}}function wH(t,e,r){return arguments.length>1?this.each((e==null?x6e:typeof e=="function"?w6e:b6e)(t,e,r??"")):hf(this.node(),t)}function hf(t,e){return t.style.getPropertyValue(e)||J5(t).getComputedStyle(t,null).getPropertyValue(e)}var p_=$(()=>{d_()});function T6e(t){return function(){delete this[t]}}function k6e(t,e){return function(){this[t]=e}}function E6e(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}function TH(t,e){return arguments.length>1?this.each((e==null?T6e:typeof e=="function"?E6e:k6e)(t,e)):this.node()[t]}var kH=$(()=>{});function EH(t){return t.trim().split(/^|\s+/)}function g_(t){return t.classList||new SH(t)}function SH(t){this._node=t,this._names=EH(t.getAttribute("class")||"")}function CH(t,e){for(var r=g_(t),n=-1,i=e.length;++n{SH.prototype={add:function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},remove:function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(t){return this._names.indexOf(t)>=0}}});function _6e(){this.textContent=""}function L6e(t){return function(){this.textContent=t}}function R6e(t){return function(){var e=t.apply(this,arguments);this.textContent=e??""}}function RH(t){return arguments.length?this.each(t==null?_6e:(typeof t=="function"?R6e:L6e)(t)):this.node().textContent}var DH=$(()=>{});function D6e(){this.innerHTML=""}function N6e(t){return function(){this.innerHTML=t}}function I6e(t){return function(){var e=t.apply(this,arguments);this.innerHTML=e??""}}function NH(t){return arguments.length?this.each(t==null?D6e:(typeof t=="function"?I6e:N6e)(t)):this.node().innerHTML}var IH=$(()=>{});function M6e(){this.nextSibling&&this.parentNode.appendChild(this)}function MH(){return this.each(M6e)}var OH=$(()=>{});function O6e(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function PH(){return this.each(O6e)}var BH=$(()=>{});function FH(t){var e=typeof t=="function"?t:j5(t);return this.select(function(){return this.appendChild(e.apply(this,arguments))})}var $H=$(()=>{l_()});function P6e(){return null}function zH(t,e){var r=typeof t=="function"?t:j5(t),n=e==null?P6e:typeof e=="function"?e:Tp(e);return this.select(function(){return this.insertBefore(r.apply(this,arguments),n.apply(this,arguments)||null)})}var GH=$(()=>{l_();K5()});function B6e(){var t=this.parentNode;t&&t.removeChild(this)}function qH(){return this.each(B6e)}var VH=$(()=>{});function F6e(){var t=this.cloneNode(!1),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function $6e(){var t=this.cloneNode(!0),e=this.parentNode;return e?e.insertBefore(t,this.nextSibling):t}function UH(t){return this.select(t?$6e:F6e)}var WH=$(()=>{});function HH(t){return arguments.length?this.property("__data__",t):this.node().__data__}var YH=$(()=>{});function z6e(t){return function(e){t.call(this,e,this.__data__)}}function G6e(t){return t.trim().split(/^|\s+/).map(function(e){var r="",n=e.indexOf(".");return n>=0&&(r=e.slice(n+1),e=e.slice(0,n)),{type:e,name:r}})}function q6e(t){return function(){var e=this.__on;if(e){for(var r=0,n=-1,i=e.length,a;r{});function KH(t,e,r){var n=J5(t),i=n.CustomEvent;typeof i=="function"?i=new i(e,r):(i=n.document.createEvent("Event"),r?(i.initEvent(e,r.bubbles,r.cancelable),i.detail=r.detail):i.initEvent(e,!1,!1)),t.dispatchEvent(i)}function U6e(t,e){return function(){return KH(this,t,e)}}function W6e(t,e){return function(){return KH(this,t,e.apply(this,arguments))}}function ZH(t,e){return this.each((typeof e=="function"?W6e:U6e)(t,e))}var QH=$(()=>{d_()});function*JH(){for(var t=this._groups,e=0,r=t.length;e{});function mi(t,e){this._groups=t,this._parents=e}function tY(){return new mi([[document.documentElement]],m_)}function H6e(){return this}var m_,rh,$l=$(()=>{PW();$W();GW();VW();WW();KW();f_();QW();eH();rH();iH();sH();lH();uH();fH();pH();mH();vH();bH();p_();kH();LH();DH();IH();OH();BH();$H();GH();VH();WH();YH();jH();QH();eY();m_=[null];mi.prototype=tY.prototype={constructor:mi,select:OW,selectAll:FW,selectChild:zW,selectChildren:qW,filter:UW,data:jW,enter:HW,exit:ZW,join:JW,merge:tH,selection:H6e,order:nH,sort:aH,call:oH,nodes:cH,node:hH,size:dH,empty:gH,each:yH,attr:xH,style:wH,property:TH,classed:_H,text:RH,html:NH,raise:MH,lower:PH,append:FH,insert:zH,remove:qH,clone:UH,datum:HH,on:XH,dispatch:ZH,[Symbol.iterator]:JH};rh=tY});function Ye(t){return typeof t=="string"?new mi([[document.querySelector(t)]],[document.documentElement]):new mi([[t]],m_)}var rY=$(()=>{$l()});var zl=$(()=>{Xv();X5();rY();$l();K5();u_();p_()});var nY=$(()=>{});function kp(t,e,r){t.prototype=e.prototype=r,r.constructor=t}function Wg(t,e){var r=Object.create(t.prototype);for(var n in e)r[n]=e[n];return r}var y_=$(()=>{});function ff(){}function aY(){return this.rgb().formatHex()}function eCe(){return this.rgb().formatHex8()}function tCe(){return fY(this).formatHsl()}function sY(){return this.rgb().formatRgb()}function ql(t){var e,r;return t=(t+"").trim().toLowerCase(),(e=Y6e.exec(t))?(r=e[1].length,e=parseInt(e[1],16),r===6?oY(e):r===3?new va(e>>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?ew(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?ew(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=X6e.exec(t))?new va(e[1],e[2],e[3],1):(e=j6e.exec(t))?new va(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=K6e.exec(t))?ew(e[1],e[2],e[3],e[4]):(e=Z6e.exec(t))?ew(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=Q6e.exec(t))?uY(e[1],e[2]/100,e[3]/100,1):(e=J6e.exec(t))?uY(e[1],e[2]/100,e[3]/100,e[4]):iY.hasOwnProperty(t)?oY(iY[t]):t==="transparent"?new va(NaN,NaN,NaN,0):null}function oY(t){return new va(t>>16&255,t>>8&255,t&255,1)}function ew(t,e,r,n){return n<=0&&(t=e=r=NaN),new va(t,e,r,n)}function x_(t){return t instanceof ff||(t=ql(t)),t?(t=t.rgb(),new va(t.r,t.g,t.b,t.opacity)):new va}function Yg(t,e,r,n){return arguments.length===1?x_(t):new va(t,e,r,n??1)}function va(t,e,r,n){this.r=+t,this.g=+e,this.b=+r,this.opacity=+n}function lY(){return`#${Ep(this.r)}${Ep(this.g)}${Ep(this.b)}`}function rCe(){return`#${Ep(this.r)}${Ep(this.g)}${Ep(this.b)}${Ep((isNaN(this.opacity)?1:this.opacity)*255)}`}function cY(){let t=nw(this.opacity);return`${t===1?"rgb(":"rgba("}${Sp(this.r)}, ${Sp(this.g)}, ${Sp(this.b)}${t===1?")":`, ${t})`}`}function nw(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Sp(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Ep(t){return t=Sp(t),(t<16?"0":"")+t.toString(16)}function uY(t,e,r,n){return n<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new Gl(t,e,r,n)}function fY(t){if(t instanceof Gl)return new Gl(t.h,t.s,t.l,t.opacity);if(t instanceof ff||(t=ql(t)),!t)return new Gl;if(t instanceof Gl)return t;t=t.rgb();var e=t.r/255,r=t.g/255,n=t.b/255,i=Math.min(e,r,n),a=Math.max(e,r,n),s=NaN,o=a-i,l=(a+i)/2;return o?(e===a?s=(r-n)/o+(r0&&l<1?0:s,new Gl(s,o,l,t.opacity)}function dY(t,e,r,n){return arguments.length===1?fY(t):new Gl(t,e,r,n??1)}function Gl(t,e,r,n){this.h=+t,this.s=+e,this.l=+r,this.opacity=+n}function hY(t){return t=(t||0)%360,t<0?t+360:t}function tw(t){return Math.max(0,Math.min(1,t||0))}function v_(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}var Kv,rw,Hg,Zv,Bc,Y6e,X6e,j6e,K6e,Z6e,Q6e,J6e,iY,b_=$(()=>{y_();Kv=.7,rw=1/Kv,Hg="\\s*([+-]?\\d+)\\s*",Zv="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",Bc="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",Y6e=/^#([0-9a-f]{3,8})$/,X6e=new RegExp(`^rgb\\(${Hg},${Hg},${Hg}\\)$`),j6e=new RegExp(`^rgb\\(${Bc},${Bc},${Bc}\\)$`),K6e=new RegExp(`^rgba\\(${Hg},${Hg},${Hg},${Zv}\\)$`),Z6e=new RegExp(`^rgba\\(${Bc},${Bc},${Bc},${Zv}\\)$`),Q6e=new RegExp(`^hsl\\(${Zv},${Bc},${Bc}\\)$`),J6e=new RegExp(`^hsla\\(${Zv},${Bc},${Bc},${Zv}\\)$`),iY={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};kp(ff,ql,{copy(t){return Object.assign(new this.constructor,this,t)},displayable(){return this.rgb().displayable()},hex:aY,formatHex:aY,formatHex8:eCe,formatHsl:tCe,formatRgb:sY,toString:sY});kp(va,Yg,Wg(ff,{brighter(t){return t=t==null?rw:Math.pow(rw,t),new va(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Kv:Math.pow(Kv,t),new va(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new va(Sp(this.r),Sp(this.g),Sp(this.b),nw(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:lY,formatHex:lY,formatHex8:rCe,formatRgb:cY,toString:cY}));kp(Gl,dY,Wg(ff,{brighter(t){return t=t==null?rw:Math.pow(rw,t),new Gl(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Kv:Math.pow(Kv,t),new Gl(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,n=r+(r<.5?r:1-r)*e,i=2*r-n;return new va(v_(t>=240?t-240:t+120,i,n),v_(t,i,n),v_(t<120?t+240:t-120,i,n),this.opacity)},clamp(){return new Gl(hY(this.h),tw(this.s),tw(this.l),nw(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let t=nw(this.opacity);return`${t===1?"hsl(":"hsla("}${hY(this.h)}, ${tw(this.s)*100}%, ${tw(this.l)*100}%${t===1?")":`, ${t})`}`}}))});var pY,gY,mY=$(()=>{pY=Math.PI/180,gY=180/Math.PI});function TY(t){if(t instanceof Fc)return new Fc(t.l,t.a,t.b,t.opacity);if(t instanceof nh)return kY(t);t instanceof va||(t=x_(t));var e=E_(t.r),r=E_(t.g),n=E_(t.b),i=w_((.2225045*e+.7168786*r+.0606169*n)/vY),a,s;return e===r&&r===n?a=s=i:(a=w_((.4360747*e+.3850649*r+.1430804*n)/yY),s=w_((.0139322*e+.0971045*r+.7141733*n)/xY)),new Fc(116*i-16,500*(a-i),200*(i-s),t.opacity)}function S_(t,e,r,n){return arguments.length===1?TY(t):new Fc(t,e,r,n??1)}function Fc(t,e,r,n){this.l=+t,this.a=+e,this.b=+r,this.opacity=+n}function w_(t){return t>nCe?Math.pow(t,1/3):t/wY+bY}function T_(t){return t>Xg?t*t*t:wY*(t-bY)}function k_(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}function E_(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function iCe(t){if(t instanceof nh)return new nh(t.h,t.c,t.l,t.opacity);if(t instanceof Fc||(t=TY(t)),t.a===0&&t.b===0)return new nh(NaN,0{y_();b_();mY();iw=18,yY=.96422,vY=1,xY=.82521,bY=4/29,Xg=6/29,wY=3*Xg*Xg,nCe=Xg*Xg*Xg;kp(Fc,S_,Wg(ff,{brighter(t){return new Fc(this.l+iw*(t??1),this.a,this.b,this.opacity)},darker(t){return new Fc(this.l-iw*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,r=isNaN(this.b)?t:t-this.b/200;return e=yY*T_(e),t=vY*T_(t),r=xY*T_(r),new va(k_(3.1338561*e-1.6168667*t-.4906146*r),k_(-.9787684*e+1.9161415*t+.033454*r),k_(.0719453*e-.2289914*t+1.4052427*r),this.opacity)}}));kp(nh,Qv,Wg(ff,{brighter(t){return new nh(this.h,this.c,this.l+iw*(t??1),this.opacity)},darker(t){return new nh(this.h,this.c,this.l-iw*(t??1),this.opacity)},rgb(){return kY(this).rgb()}}))});var jg=$(()=>{b_();EY()});function C_(t,e,r,n,i){var a=t*t,s=a*t;return((1-3*t+3*a-s)*e+(4-6*a+3*s)*r+(1+3*t+3*a-3*s)*n+s*i)/6}function SY(t){var e=t.length-1;return function(r){var n=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),i=t[n],a=t[n+1],s=n>0?t[n-1]:2*i-a,o=n{});function CY(t){var e=t.length;return function(r){var n=Math.floor(((r%=1)<0?++r:r)*e),i=t[(n+e-1)%e],a=t[n%e],s=t[(n+1)%e],o=t[(n+2)%e];return C_((r-n/e)*e,i,a,s,o)}}var AY=$(()=>{A_()});var Kg,__=$(()=>{Kg=t=>()=>t});function _Y(t,e){return function(r){return t+r*e}}function aCe(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(n){return Math.pow(t+n*e,r)}}function LY(t,e){var r=e-t;return r?_Y(t,r>180||r<-180?r-360*Math.round(r/360):r):Kg(isNaN(t)?e:t)}function RY(t){return(t=+t)==1?ih:function(e,r){return r-e?aCe(e,r,t):Kg(isNaN(e)?r:e)}}function ih(t,e){var r=e-t;return r?_Y(t,r):Kg(isNaN(t)?e:t)}var L_=$(()=>{__()});function DY(t){return function(e){var r=e.length,n=new Array(r),i=new Array(r),a=new Array(r),s,o;for(s=0;s{jg();A_();AY();L_();Cp=(function t(e){var r=RY(e);function n(i,a){var s=r((i=Yg(i)).r,(a=Yg(a)).r),o=r(i.g,a.g),l=r(i.b,a.b),u=ih(i.opacity,a.opacity);return function(h){return i.r=s(h),i.g=o(h),i.b=l(h),i.opacity=u(h),i+""}}return n.gamma=t,n})(1);sCe=DY(SY),oCe=DY(CY)});function NY(t,e){e||(e=[]);var r=t?Math.min(e.length,t.length):0,n=e.slice(),i;return function(a){for(i=0;i{});function OY(t,e){var r=e?e.length:0,n=t?Math.min(r,t.length):0,i=new Array(n),a=new Array(r),s;for(s=0;s{aw()});function BY(t,e){var r=new Date;return t=+t,e=+e,function(n){return r.setTime(t*(1-n)+e*n),r}}var FY=$(()=>{});function xa(t,e){return t=+t,e=+e,function(r){return t*(1-r)+e*r}}var Jv=$(()=>{});function $Y(t,e){var r={},n={},i;(t===null||typeof t!="object")&&(t={}),(e===null||typeof e!="object")&&(e={});for(i in e)i in t?r[i]=Ap(t[i],e[i]):n[i]=e[i];return function(a){for(i in r)n[i]=r[i](a);return n}}var zY=$(()=>{aw()});function lCe(t){return function(){return t}}function cCe(t){return function(e){return t(e)+""}}function e2(t,e){var r=N_.lastIndex=D_.lastIndex=0,n,i,a,s=-1,o=[],l=[];for(t=t+"",e=e+"";(n=N_.exec(t))&&(i=D_.exec(e));)(a=i.index)>r&&(a=e.slice(r,a),o[s]?o[s]+=a:o[++s]=a),(n=n[0])===(i=i[0])?o[s]?o[s]+=i:o[++s]=i:(o[++s]=null,l.push({i:s,x:xa(n,i)})),r=D_.lastIndex;return r{Jv();N_=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,D_=new RegExp(N_.source,"g")});function Ap(t,e){var r=typeof e,n;return e==null||r==="boolean"?Kg(e):(r==="number"?xa:r==="string"?(n=ql(e))?(e=n,Cp):e2:e instanceof ql?Cp:e instanceof Date?BY:IY(e)?NY:Array.isArray(e)?OY:typeof e.valueOf!="function"&&typeof e.toString!="function"||isNaN(e)?$Y:xa)(t,e)}var aw=$(()=>{jg();R_();PY();FY();Jv();zY();I_();__();MY()});function M_(t,e){return t=+t,e=+e,function(r){return Math.round(t*(1-r)+e*r)}}var GY=$(()=>{});function O_(t,e,r,n,i,a){var s,o,l;return(s=Math.sqrt(t*t+e*e))&&(t/=s,e/=s),(l=t*r+e*n)&&(r-=t*l,n-=e*l),(o=Math.sqrt(r*r+n*n))&&(r/=o,n/=o,l/=o),t*n{qY=180/Math.PI,sw={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1}});function UY(t){let e=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(t+"");return e.isIdentity?sw:O_(e.a,e.b,e.c,e.d,e.e,e.f)}function WY(t){return t==null?sw:(ow||(ow=document.createElementNS("http://www.w3.org/2000/svg","g")),ow.setAttribute("transform",t),(t=ow.transform.baseVal.consolidate())?(t=t.matrix,O_(t.a,t.b,t.c,t.d,t.e,t.f)):sw)}var ow,HY=$(()=>{VY()});function YY(t,e,r,n){function i(u){return u.length?u.pop()+" ":""}function a(u,h,f,d,p,g){if(u!==f||h!==d){var m=p.push("translate(",null,e,null,r);g.push({i:m-4,x:xa(u,f)},{i:m-2,x:xa(h,d)})}else(f||d)&&p.push("translate("+f+e+d+r)}function s(u,h,f,d){u!==h?(u-h>180?h+=360:h-u>180&&(u+=360),d.push({i:f.push(i(f)+"rotate(",null,n)-2,x:xa(u,h)})):h&&f.push(i(f)+"rotate("+h+n)}function o(u,h,f,d){u!==h?d.push({i:f.push(i(f)+"skewX(",null,n)-2,x:xa(u,h)}):h&&f.push(i(f)+"skewX("+h+n)}function l(u,h,f,d,p,g){if(u!==f||h!==d){var m=p.push(i(p)+"scale(",null,",",null,")");g.push({i:m-4,x:xa(u,f)},{i:m-2,x:xa(h,d)})}else(f!==1||d!==1)&&p.push(i(p)+"scale("+f+","+d+")")}return function(u,h){var f=[],d=[];return u=t(u),h=t(h),a(u.translateX,u.translateY,h.translateX,h.translateY,f,d),s(u.rotate,h.rotate,f,d),o(u.skewX,h.skewX,f,d),l(u.scaleX,u.scaleY,h.scaleX,h.scaleY,f,d),u=h=null,function(p){for(var g=-1,m=d.length,y;++g{Jv();HY();P_=YY(UY,"px, ","px)","deg)"),B_=YY(WY,", ",")",")")});function jY(t){return function(e,r){var n=t((e=Qv(e)).h,(r=Qv(r)).h),i=ih(e.c,r.c),a=ih(e.l,r.l),s=ih(e.opacity,r.opacity);return function(o){return e.h=n(o),e.c=i(o),e.l=a(o),e.opacity=s(o),e+""}}}var F_,uCe,KY=$(()=>{jg();L_();F_=jY(LY),uCe=jY(ih)});var Zg=$(()=>{aw();Jv();GY();I_();XY();R_();KY()});function s2(){return _p||(JY(hCe),_p=i2.now()+uw)}function hCe(){_p=0}function a2(){this._call=this._time=this._next=null}function hw(t,e,r){var n=new a2;return n.restart(t,e,r),n}function eX(){s2(),++Qg;for(var t=lw,e;t;)(e=_p-t._time)>=0&&t._call.call(void 0,e),t=t._next;--Qg}function ZY(){_p=(cw=i2.now())+uw,Qg=r2=0;try{eX()}finally{Qg=0,dCe(),_p=0}}function fCe(){var t=i2.now(),e=t-cw;e>QY&&(uw-=e,cw=t)}function dCe(){for(var t,e=lw,r,n=1/0;e;)e._call?(n>e._time&&(n=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:lw=r);n2=t,$_(n)}function $_(t){if(!Qg){r2&&(r2=clearTimeout(r2));var e=t-_p;e>24?(t<1/0&&(r2=setTimeout(ZY,t-i2.now()-uw)),t2&&(t2=clearInterval(t2))):(t2||(cw=i2.now(),t2=setInterval(fCe,QY)),Qg=1,JY(ZY))}}var Qg,r2,t2,QY,lw,n2,cw,_p,uw,i2,JY,z_=$(()=>{Qg=0,r2=0,t2=0,QY=1e3,cw=0,_p=0,uw=0,i2=typeof performance=="object"&&performance.now?performance:Date,JY=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(t){setTimeout(t,17)};a2.prototype=hw.prototype={constructor:a2,restart:function(t,e,r){if(typeof t!="function")throw new TypeError("callback is not a function");r=(r==null?s2():+r)+(e==null?0:+e),!this._next&&n2!==this&&(n2?n2._next=this:lw=this,n2=this),this._call=t,this._time=r,$_()},stop:function(){this._call&&(this._call=null,this._time=1/0,$_())}}});function fw(t,e,r){var n=new a2;return e=e==null?0:+e,n.restart(i=>{n.stop(),t(i+e)},e,r),n}var tX=$(()=>{z_()});var dw=$(()=>{z_();tX()});function df(t,e,r,n,i,a){var s=t.__transition;if(!s)t.__transition={};else if(r in s)return;mCe(t,r,{name:e,index:n,group:i,on:pCe,tween:gCe,time:a.time,delay:a.delay,duration:a.duration,ease:a.ease,timer:null,state:iX})}function l2(t,e){var r=Gi(t,e);if(r.state>iX)throw new Error("too late; already scheduled");return r}function ba(t,e){var r=Gi(t,e);if(r.state>pw)throw new Error("too late; already running");return r}function Gi(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}function mCe(t,e,r){var n=t.__transition,i;n[e]=r,r.timer=hw(a,0,r.time);function a(u){r.state=rX,r.timer.restart(s,r.delay,r.time),r.delay<=u&&s(u-r.delay)}function s(u){var h,f,d,p;if(r.state!==rX)return l();for(h in n)if(p=n[h],p.name===r.name){if(p.state===pw)return fw(s);p.state===nX?(p.state=o2,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete n[h]):+h{a_();dw();pCe=i_("start","end","cancel","interrupt"),gCe=[],iX=0,rX=1,gw=2,pw=3,nX=4,mw=5,o2=6});function yw(t,e){var r=t.__transition,n,i,a=!0,s;if(r){e=e==null?null:e+"";for(s in r){if((n=r[s]).name!==e){a=!1;continue}i=n.state>gw&&n.state{Ws()});function sX(t){return this.each(function(){yw(this,t)})}var oX=$(()=>{aX()});function yCe(t,e){var r,n;return function(){var i=ba(this,t),a=i.tween;if(a!==r){n=r=a;for(var s=0,o=n.length;s{Ws()});function vw(t,e){var r;return(typeof e=="number"?xa:e instanceof ql?Cp:(r=ql(e))?(e=r,Cp):e2)(t,e)}var G_=$(()=>{jg();Zg()});function xCe(t){return function(){this.removeAttribute(t)}}function bCe(t){return function(){this.removeAttributeNS(t.space,t.local)}}function wCe(t,e,r){var n,i=r+"",a;return function(){var s=this.getAttribute(t);return s===i?null:s===n?a:a=e(n=s,r)}}function TCe(t,e,r){var n,i=r+"",a;return function(){var s=this.getAttributeNS(t.space,t.local);return s===i?null:s===n?a:a=e(n=s,r)}}function kCe(t,e,r){var n,i,a;return function(){var s,o=r(this),l;return o==null?void this.removeAttribute(t):(s=this.getAttribute(t),l=o+"",s===l?null:s===n&&l===i?a:(i=l,a=e(n=s,o)))}}function ECe(t,e,r){var n,i,a;return function(){var s,o=r(this),l;return o==null?void this.removeAttributeNS(t.space,t.local):(s=this.getAttributeNS(t.space,t.local),l=o+"",s===l?null:s===n&&l===i?a:(i=l,a=e(n=s,o)))}}function cX(t,e){var r=th(t),n=r==="transform"?B_:vw;return this.attrTween(t,typeof e=="function"?(r.local?ECe:kCe)(r,n,Jg(this,"attr."+t,e)):e==null?(r.local?bCe:xCe)(r):(r.local?TCe:wCe)(r,n,e))}var uX=$(()=>{Zg();zl();c2();G_()});function SCe(t,e){return function(r){this.setAttribute(t,e.call(this,r))}}function CCe(t,e){return function(r){this.setAttributeNS(t.space,t.local,e.call(this,r))}}function ACe(t,e){var r,n;function i(){var a=e.apply(this,arguments);return a!==n&&(r=(n=a)&&CCe(t,a)),r}return i._value=e,i}function _Ce(t,e){var r,n;function i(){var a=e.apply(this,arguments);return a!==n&&(r=(n=a)&&SCe(t,a)),r}return i._value=e,i}function hX(t,e){var r="attr."+t;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(e==null)return this.tween(r,null);if(typeof e!="function")throw new Error;var n=th(t);return this.tween(r,(n.local?ACe:_Ce)(n,e))}var fX=$(()=>{zl()});function LCe(t,e){return function(){l2(this,t).delay=+e.apply(this,arguments)}}function RCe(t,e){return e=+e,function(){l2(this,t).delay=e}}function dX(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?LCe:RCe)(e,t)):Gi(this.node(),e).delay}var pX=$(()=>{Ws()});function DCe(t,e){return function(){ba(this,t).duration=+e.apply(this,arguments)}}function NCe(t,e){return e=+e,function(){ba(this,t).duration=e}}function gX(t){var e=this._id;return arguments.length?this.each((typeof t=="function"?DCe:NCe)(e,t)):Gi(this.node(),e).duration}var mX=$(()=>{Ws()});function ICe(t,e){if(typeof e!="function")throw new Error;return function(){ba(this,t).ease=e}}function yX(t){var e=this._id;return arguments.length?this.each(ICe(e,t)):Gi(this.node(),e).ease}var vX=$(()=>{Ws()});function MCe(t,e){return function(){var r=e.apply(this,arguments);if(typeof r!="function")throw new Error;ba(this,t).ease=r}}function xX(t){if(typeof t!="function")throw new Error;return this.each(MCe(this._id,t))}var bX=$(()=>{Ws()});function wX(t){typeof t!="function"&&(t=Yv(t));for(var e=this._groups,r=e.length,n=new Array(r),i=0;i{zl();Lp()});function kX(t){if(t._id!==this._id)throw new Error;for(var e=this._groups,r=t._groups,n=e.length,i=r.length,a=Math.min(n,i),s=new Array(n),o=0;o{Lp()});function OCe(t){return(t+"").trim().split(/^|\s+/).every(function(e){var r=e.indexOf(".");return r>=0&&(e=e.slice(0,r)),!e||e==="start"})}function PCe(t,e,r){var n,i,a=OCe(e)?l2:ba;return function(){var s=a(this,t),o=s.on;o!==n&&(i=(n=o).copy()).on(e,r),s.on=i}}function SX(t,e){var r=this._id;return arguments.length<2?Gi(this.node(),r).on.on(t):this.each(PCe(r,t,e))}var CX=$(()=>{Ws()});function BCe(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}function AX(){return this.on("end.remove",BCe(this._id))}var _X=$(()=>{});function LX(t){var e=this._name,r=this._id;typeof t!="function"&&(t=Tp(t));for(var n=this._groups,i=n.length,a=new Array(i),s=0;s{zl();Lp();Ws()});function DX(t){var e=this._name,r=this._id;typeof t!="function"&&(t=Hv(t));for(var n=this._groups,i=n.length,a=[],s=[],o=0;o{zl();Lp();Ws()});function IX(){return new FCe(this._groups,this._parents)}var FCe,MX=$(()=>{zl();FCe=rh.prototype.constructor});function $Ce(t,e){var r,n,i;return function(){var a=hf(this,t),s=(this.style.removeProperty(t),hf(this,t));return a===s?null:a===r&&s===n?i:i=e(r=a,n=s)}}function OX(t){return function(){this.style.removeProperty(t)}}function zCe(t,e,r){var n,i=r+"",a;return function(){var s=hf(this,t);return s===i?null:s===n?a:a=e(n=s,r)}}function GCe(t,e,r){var n,i,a;return function(){var s=hf(this,t),o=r(this),l=o+"";return o==null&&(l=o=(this.style.removeProperty(t),hf(this,t))),s===l?null:s===n&&l===i?a:(i=l,a=e(n=s,o))}}function qCe(t,e){var r,n,i,a="style."+e,s="end."+a,o;return function(){var l=ba(this,t),u=l.on,h=l.value[a]==null?o||(o=OX(e)):void 0;(u!==r||i!==h)&&(n=(r=u).copy()).on(s,i=h),l.on=n}}function PX(t,e,r){var n=(t+="")=="transform"?P_:vw;return e==null?this.styleTween(t,$Ce(t,n)).on("end.style."+t,OX(t)):typeof e=="function"?this.styleTween(t,GCe(t,n,Jg(this,"style."+t,e))).each(qCe(this._id,t)):this.styleTween(t,zCe(t,n,e),r).on("end.style."+t,null)}var BX=$(()=>{Zg();zl();Ws();c2();G_()});function VCe(t,e,r){return function(n){this.style.setProperty(t,e.call(this,n),r)}}function UCe(t,e,r){var n,i;function a(){var s=e.apply(this,arguments);return s!==i&&(n=(i=s)&&VCe(t,s,r)),n}return a._value=e,a}function FX(t,e,r){var n="style."+(t+="");if(arguments.length<2)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;return this.tween(n,UCe(t,e,r??""))}var $X=$(()=>{});function WCe(t){return function(){this.textContent=t}}function HCe(t){return function(){var e=t(this);this.textContent=e??""}}function zX(t){return this.tween("text",typeof t=="function"?HCe(Jg(this,"text",t)):WCe(t==null?"":t+""))}var GX=$(()=>{c2()});function YCe(t){return function(e){this.textContent=t.call(this,e)}}function XCe(t){var e,r;function n(){var i=t.apply(this,arguments);return i!==r&&(e=(r=i)&&YCe(i)),e}return n._value=t,n}function qX(t){var e="text";if(arguments.length<1)return(e=this.tween(e))&&e._value;if(t==null)return this.tween(e,null);if(typeof t!="function")throw new Error;return this.tween(e,XCe(t))}var VX=$(()=>{});function UX(){for(var t=this._name,e=this._id,r=xw(),n=this._groups,i=n.length,a=0;a{Lp();Ws()});function HX(){var t,e,r=this,n=r._id,i=r.size();return new Promise(function(a,s){var o={value:s},l={value:function(){--i===0&&a()}};r.each(function(){var u=ba(this,n),h=u.on;h!==t&&(e=(t=h).copy(),e._.cancel.push(o),e._.interrupt.push(o),e._.end.push(l)),u.on=e}),i===0&&a()})}var YX=$(()=>{Ws()});function ys(t,e,r,n){this._groups=t,this._parents=e,this._name=r,this._id=n}function XX(t){return rh().transition(t)}function xw(){return++jCe}var jCe,ah,Lp=$(()=>{zl();uX();fX();pX();mX();vX();bX();TX();EX();CX();_X();RX();NX();MX();BX();$X();GX();VX();WX();c2();YX();jCe=0;ah=rh.prototype;ys.prototype=XX.prototype={constructor:ys,select:LX,selectAll:DX,selectChild:ah.selectChild,selectChildren:ah.selectChildren,filter:wX,merge:kX,selection:IX,transition:UX,call:ah.call,nodes:ah.nodes,node:ah.node,size:ah.size,empty:ah.empty,each:ah.each,on:SX,attr:cX,attrTween:hX,style:PX,styleTween:FX,text:zX,textTween:qX,remove:AX,tween:lX,delay:dX,duration:gX,ease:yX,easeVarying:xX,end:HX,[Symbol.iterator]:ah[Symbol.iterator]}});function bw(t){return((t*=2)<=1?t*t*t:(t-=2)*t*t+2)/2}var jX=$(()=>{});var q_=$(()=>{jX()});function ZCe(t,e){for(var r;!(r=t.__transition)||!(r=r[e]);)if(!(t=t.parentNode))throw new Error(`transition ${e} not found`);return r}function KX(t){var e,r;t instanceof ys?(e=t._id,t=t._name):(e=xw(),(r=KCe).time=s2(),t=t==null?null:t+"");for(var n=this._groups,i=n.length,a=0;a{Lp();Ws();q_();dw();KCe={time:null,delay:0,duration:250,ease:bw}});var QX=$(()=>{zl();oX();ZX();rh.prototype.interrupt=sX;rh.prototype.transition=KX});var ww=$(()=>{QX()});var JX=$(()=>{});var ej=$(()=>{});var tj=$(()=>{});function rj(t){return[+t[0],+t[1]]}function QCe(t){return[rj(t[0]),rj(t[1])]}function V_(t){return{type:t}}var mmt,ymt,vmt,xmt,bmt,wmt,nj=$(()=>{ww();JX();ej();tj();({abs:mmt,max:ymt,min:vmt}=Math);xmt={name:"x",handles:["w","e"].map(V_),input:function(t,e){return t==null?null:[[+t[0],e[0][1]],[+t[1],e[1][1]]]},output:function(t){return t&&[t[0][0],t[1][0]]}},bmt={name:"y",handles:["n","s"].map(V_),input:function(t,e){return t==null?null:[[e[0][0],+t[0]],[e[1][0],+t[1]]]},output:function(t){return t&&[t[0][1],t[1][1]]}},wmt={name:"xy",handles:["n","w","e","s","nw","ne","sw","se"].map(V_),input:function(t){return t==null?null:QCe(t)},output:function(t){return t}}});var ij=$(()=>{nj()});function aj(t){this._+=t[0];for(let e=1,r=t.length;e=0))throw new Error(`invalid digits: ${t}`);if(e>15)return aj;let r=10**e;return function(n){this._+=n[0];for(let i=1,a=n.length;i{U_=Math.PI,W_=2*U_,Rp=1e-6,JCe=W_-Rp;Dp=class{constructor(e){this._x0=this._y0=this._x1=this._y1=null,this._="",this._append=e==null?aj:e7e(e)}moveTo(e,r){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}`}closePath(){this._x1!==null&&(this._x1=this._x0,this._y1=this._y0,this._append`Z`)}lineTo(e,r){this._append`L${this._x1=+e},${this._y1=+r}`}quadraticCurveTo(e,r,n,i){this._append`Q${+e},${+r},${this._x1=+n},${this._y1=+i}`}bezierCurveTo(e,r,n,i,a,s){this._append`C${+e},${+r},${+n},${+i},${this._x1=+a},${this._y1=+s}`}arcTo(e,r,n,i,a){if(e=+e,r=+r,n=+n,i=+i,a=+a,a<0)throw new Error(`negative radius: ${a}`);let s=this._x1,o=this._y1,l=n-e,u=i-r,h=s-e,f=o-r,d=h*h+f*f;if(this._x1===null)this._append`M${this._x1=e},${this._y1=r}`;else if(d>Rp)if(!(Math.abs(f*l-u*h)>Rp)||!a)this._append`L${this._x1=e},${this._y1=r}`;else{let p=n-s,g=i-o,m=l*l+u*u,y=p*p+g*g,v=Math.sqrt(m),b=Math.sqrt(d),w=a*Math.tan((U_-Math.acos((m+d-y)/(2*v*b)))/2),S=w/b,T=w/v;Math.abs(S-1)>Rp&&this._append`L${e+S*h},${r+S*f}`,this._append`A${a},${a},0,0,${+(f*p>h*g)},${this._x1=e+T*l},${this._y1=r+T*u}`}}arc(e,r,n,i,a,s){if(e=+e,r=+r,n=+n,s=!!s,n<0)throw new Error(`negative radius: ${n}`);let o=n*Math.cos(i),l=n*Math.sin(i),u=e+o,h=r+l,f=1^s,d=s?i-a:a-i;this._x1===null?this._append`M${u},${h}`:(Math.abs(this._x1-u)>Rp||Math.abs(this._y1-h)>Rp)&&this._append`L${u},${h}`,n&&(d<0&&(d=d%W_+W_),d>JCe?this._append`A${n},${n},0,1,${f},${e-o},${r-l}A${n},${n},0,1,${f},${this._x1=u},${this._y1=h}`:d>Rp&&this._append`A${n},${n},0,${+(d>=U_)},${f},${this._x1=e+n*Math.cos(a)},${this._y1=r+n*Math.sin(a)}`)}rect(e,r,n,i){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${n=+n}v${+i}h${-n}Z`}toString(){return this._}};sj.prototype=Dp.prototype});var H_=$(()=>{oj()});var lj=$(()=>{});var cj=$(()=>{});var uj=$(()=>{});var hj=$(()=>{});var fj=$(()=>{});var dj=$(()=>{});var pj=$(()=>{});function gj(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}function Np(t,e){if(!isFinite(t)||t===0)return null;var r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"),n=t.slice(0,r);return[n.length>1?n[0]+n.slice(2):n,+t.slice(r+1)]}var u2=$(()=>{});function $c(t){return t=Np(Math.abs(t)),t?t[1]:NaN}var h2=$(()=>{u2()});function mj(t,e){return function(r,n){for(var i=r.length,a=[],s=0,o=t[0],l=0;i>0&&o>0&&(l+o+1>n&&(o=Math.max(1,n-l)),a.push(r.substring(i-=o,i+o)),!((l+=o+1)>n));)o=t[s=(s+1)%t.length];return a.reverse().join(e)}}var yj=$(()=>{});function vj(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}var xj=$(()=>{});function pf(t){if(!(e=t7e.exec(t)))throw new Error("invalid format: "+t);var e;return new Tw({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}function Tw(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}var t7e,Y_=$(()=>{t7e=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;pf.prototype=Tw.prototype;Tw.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type}});function bj(t){e:for(var e=t.length,r=1,n=-1,i;r0&&(n=0);break}return n>0?t.slice(0,n)+t.slice(i+1):t}var wj=$(()=>{});function Tj(t,e){var r=Np(t,e);if(!r)return f2=void 0,t.toPrecision(e);var n=r[0],i=r[1],a=i-(f2=Math.max(-8,Math.min(8,Math.floor(i/3)))*3)+1,s=n.length;return a===s?n:a>s?n+new Array(a-s+1).join("0"):a>0?n.slice(0,a)+"."+n.slice(a):"0."+new Array(1-a).join("0")+Np(t,Math.max(0,e+a-1))[0]}var f2,X_=$(()=>{u2()});function j_(t,e){var r=Np(t,e);if(!r)return t+"";var n=r[0],i=r[1];return i<0?"0."+new Array(-i).join("0")+n:n.length>i+1?n.slice(0,i+1)+"."+n.slice(i+1):n+new Array(i-n.length+2).join("0")}var kj=$(()=>{u2()});var K_,Ej=$(()=>{u2();X_();kj();K_={"%":(t,e)=>(t*100).toFixed(e),b:t=>Math.round(t).toString(2),c:t=>t+"",d:gj,e:(t,e)=>t.toExponential(e),f:(t,e)=>t.toFixed(e),g:(t,e)=>t.toPrecision(e),o:t=>Math.round(t).toString(8),p:(t,e)=>j_(t*100,e),r:j_,s:Tj,X:t=>Math.round(t).toString(16).toUpperCase(),x:t=>Math.round(t).toString(16)}});function Z_(t){return t}var Sj=$(()=>{});function _j(t){var e=t.grouping===void 0||t.thousands===void 0?Z_:mj(Cj.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",n=t.currency===void 0?"":t.currency[1]+"",i=t.decimal===void 0?".":t.decimal+"",a=t.numerals===void 0?Z_:vj(Cj.call(t.numerals,String)),s=t.percent===void 0?"%":t.percent+"",o=t.minus===void 0?"\u2212":t.minus+"",l=t.nan===void 0?"NaN":t.nan+"";function u(f,d){f=pf(f);var p=f.fill,g=f.align,m=f.sign,y=f.symbol,v=f.zero,b=f.width,w=f.comma,S=f.precision,T=f.trim,k=f.type;k==="n"?(w=!0,k="g"):K_[k]||(S===void 0&&(S=12),T=!0,k="g"),(v||p==="0"&&g==="=")&&(v=!0,p="0",g="=");var C=(d&&d.prefix!==void 0?d.prefix:"")+(y==="$"?r:y==="#"&&/[boxX]/.test(k)?"0"+k.toLowerCase():""),L=(y==="$"?n:/[%p]/.test(k)?s:"")+(d&&d.suffix!==void 0?d.suffix:""),D=K_[k],M=/[defgprs%]/.test(k);S=S===void 0?6:/[gprs]/.test(k)?Math.max(1,Math.min(21,S)):Math.max(0,Math.min(20,S));function I(E){var _=C,A=L,R,N,O;if(k==="c")A=D(E)+A,E="";else{E=+E;var P=E<0||1/E<0;if(E=isNaN(E)?l:D(Math.abs(E),S),T&&(E=bj(E)),P&&+E==0&&m!=="+"&&(P=!1),_=(P?m==="("?m:o:m==="-"||m==="("?"":m)+_,A=(k==="s"&&!isNaN(E)&&f2!==void 0?Aj[8+f2/3]:"")+A+(P&&m==="("?")":""),M){for(R=-1,N=E.length;++RO||O>57){A=(O===46?i+E.slice(R+1):E.slice(R))+A,E=E.slice(0,R);break}}}w&&!v&&(E=e(E,1/0));var B=_.length+E.length+A.length,G=B>1)+_+E+A+G.slice(B);break;default:E=G+_+E+A;break}return a(E)}return I.toString=function(){return f+""},I}function h(f,d){var p=Math.max(-8,Math.min(8,Math.floor($c(d)/3)))*3,g=Math.pow(10,-p),m=u((f=pf(f),f.type="f",f),{suffix:Aj[8+p/3]});return function(y){return m(g*y)}}return{format:u,formatPrefix:h}}var Cj,Aj,Lj=$(()=>{h2();yj();xj();Y_();wj();Ej();X_();Sj();Cj=Array.prototype.map,Aj=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"]});function Q_(t){return kw=_j(t),zc=kw.format,Ew=kw.formatPrefix,kw}var kw,zc,Ew,Rj=$(()=>{Lj();Q_({thousands:",",grouping:[3],currency:["$",""]})});function J_(t){return Math.max(0,-$c(Math.abs(t)))}var Dj=$(()=>{h2()});function eL(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor($c(e)/3)))*3-$c(Math.abs(t)))}var Nj=$(()=>{h2()});function tL(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,$c(e)-$c(t))+1}var Ij=$(()=>{h2()});var rL=$(()=>{Rj();Y_();Dj();Nj();Ij()});var Mj=$(()=>{});function r7e(t){var e=0,r=t.children,n=r&&r.length;if(!n)e=1;else for(;--n>=0;)e+=r[n].value;t.value=e}function Oj(){return this.eachAfter(r7e)}var Pj=$(()=>{});function Bj(t,e){let r=-1;for(let n of this)t.call(e,n,++r,this);return this}var Fj=$(()=>{});function $j(t,e){for(var r=this,n=[r],i,a,s=-1;r=n.pop();)if(t.call(e,r,++s,this),i=r.children)for(a=i.length-1;a>=0;--a)n.push(i[a]);return this}var zj=$(()=>{});function Gj(t,e){for(var r=this,n=[r],i=[],a,s,o,l=-1;r=n.pop();)if(i.push(r),a=r.children)for(s=0,o=a.length;s{});function Vj(t,e){let r=-1;for(let n of this)if(t.call(e,n,++r,this))return n}var Uj=$(()=>{});function Wj(t){return this.eachAfter(function(e){for(var r=+t(e.data)||0,n=e.children,i=n&&n.length;--i>=0;)r+=n[i].value;e.value=r})}var Hj=$(()=>{});function Yj(t){return this.eachBefore(function(e){e.children&&e.children.sort(t)})}var Xj=$(()=>{});function jj(t){for(var e=this,r=n7e(e,t),n=[e];e!==r;)e=e.parent,n.push(e);for(var i=n.length;t!==r;)n.splice(i,0,t),t=t.parent;return n}function n7e(t,e){if(t===e)return t;var r=t.ancestors(),n=e.ancestors(),i=null;for(t=r.pop(),e=n.pop();t===e;)i=t,t=r.pop(),e=n.pop();return i}var Kj=$(()=>{});function Zj(){for(var t=this,e=[t];t=t.parent;)e.push(t);return e}var Qj=$(()=>{});function Jj(){return Array.from(this)}var eK=$(()=>{});function tK(){var t=[];return this.eachBefore(function(e){e.children||t.push(e)}),t}var rK=$(()=>{});function nK(){var t=this,e=[];return t.each(function(r){r!==t&&e.push({source:r.parent,target:r})}),e}var iK=$(()=>{});function*aK(){var t=this,e,r=[t],n,i,a;do for(e=r.reverse(),r=[];t=e.pop();)if(yield t,n=t.children)for(i=0,a=n.length;i{});function em(t,e){t instanceof Map?(t=[void 0,t],e===void 0&&(e=s7e)):e===void 0&&(e=a7e);for(var r=new d2(t),n,i=[r],a,s,o,l;n=i.pop();)if((s=e(n.data))&&(l=(s=Array.from(s)).length))for(n.children=s,o=l-1;o>=0;--o)i.push(a=s[o]=new d2(s[o])),a.parent=n,a.depth=n.depth+1;return r.eachBefore(l7e)}function i7e(){return em(this).eachBefore(o7e)}function a7e(t){return t.children}function s7e(t){return Array.isArray(t)?t[1]:null}function o7e(t){t.data.value!==void 0&&(t.value=t.data.value),t.data=t.data.data}function l7e(t){var e=0;do t.height=e;while((t=t.parent)&&t.height<++e)}function d2(t){this.data=t,this.depth=this.height=0,this.parent=null}var oK=$(()=>{Pj();Fj();zj();qj();Uj();Hj();Xj();Kj();Qj();eK();rK();iK();sK();d2.prototype=em.prototype={constructor:d2,count:Oj,each:Bj,eachAfter:Gj,eachBefore:$j,find:Vj,sum:Wj,sort:Yj,path:jj,ancestors:Zj,descendants:Jj,leaves:tK,links:nK,copy:i7e,[Symbol.iterator]:aK}});function lK(t){if(typeof t!="function")throw new Error;return t}var cK=$(()=>{});function tm(){return 0}function rm(t){return function(){return t}}var uK=$(()=>{});function hK(t){t.x0=Math.round(t.x0),t.y0=Math.round(t.y0),t.x1=Math.round(t.x1),t.y1=Math.round(t.y1)}var fK=$(()=>{});function dK(t,e,r,n,i){for(var a=t.children,s,o=-1,l=a.length,u=t.value&&(n-e)/t.value;++o{});function gK(t,e,r,n,i){for(var a=t.children,s,o=-1,l=a.length,u=t.value&&(i-r)/t.value;++o{});function u7e(t,e,r,n,i,a){for(var s=[],o=e.children,l,u,h=0,f=0,d=o.length,p,g,m=e.value,y,v,b,w,S,T,k;hb&&(b=u),k=y*y*T,w=Math.max(b/k,k/v),w>S){y-=u;break}S=w}s.push(l={value:y,dice:p{pK();mK();c7e=(1+Math.sqrt(5))/2;yK=(function t(e){function r(n,i,a,s,o){u7e(e,n,i,a,s,o)}return r.ratio=function(n){return t((n=+n)>1?n:1)},r})(c7e)});function nL(){var t=yK,e=!1,r=1,n=1,i=[0],a=tm,s=tm,o=tm,l=tm,u=tm;function h(d){return d.x0=d.y0=0,d.x1=r,d.y1=n,d.eachBefore(f),i=[0],e&&d.eachBefore(hK),d}function f(d){var p=i[d.depth],g=d.x0+p,m=d.y0+p,y=d.x1-p,v=d.y1-p;y{fK();vK();cK();uK()});var bK=$(()=>{oK();xK()});var wK=$(()=>{});var TK=$(()=>{});function gf(t,e){switch(arguments.length){case 0:break;case 1:this.range(t);break;default:this.range(e).domain(t);break}return this}var p2=$(()=>{});function ko(){var t=new Vg,e=[],r=[],n=iL;function i(a){let s=t.get(a);if(s===void 0){if(n!==iL)return n;t.set(a,s=e.push(a)-1)}return r[s%r.length]}return i.domain=function(a){if(!arguments.length)return e.slice();e=[],t=new Vg;for(let s of a)t.has(s)||t.set(s,e.push(s)-1);return i},i.range=function(a){return arguments.length?(r=Array.from(a),i):r.slice()},i.unknown=function(a){return arguments.length?(n=a,i):n},i.copy=function(){return ko(e,r).unknown(n)},gf.apply(i,arguments),i}var iL,aL=$(()=>{uf();p2();iL=Symbol("implicit")});function nm(){var t=ko().unknown(void 0),e=t.domain,r=t.range,n=0,i=1,a,s,o=!1,l=0,u=0,h=.5;delete t.unknown;function f(){var d=e().length,p=i{uf();p2();aL()});function sL(t){return function(){return t}}var EK=$(()=>{});function oL(t){return+t}var SK=$(()=>{});function im(t){return t}function lL(t,e){return(e-=t=+t)?function(r){return(r-t)/e}:sL(isNaN(e)?NaN:.5)}function h7e(t,e){var r;return t>e&&(r=t,t=e,e=r),function(n){return Math.max(t,Math.min(e,n))}}function f7e(t,e,r){var n=t[0],i=t[1],a=e[0],s=e[1];return i2?d7e:f7e,l=u=null,f}function f(d){return d==null||isNaN(d=+d)?a:(l||(l=o(t.map(n),e,r)))(n(s(d)))}return f.invert=function(d){return s(i((u||(u=o(e,t.map(n),xa)))(d)))},f.domain=function(d){return arguments.length?(t=Array.from(d,oL),h()):t.slice()},f.range=function(d){return arguments.length?(e=Array.from(d),h()):e.slice()},f.rangeRound=function(d){return e=Array.from(d),r=M_,h()},f.clamp=function(d){return arguments.length?(s=d?!0:im,h()):s!==im},f.interpolate=function(d){return arguments.length?(r=d,h()):r},f.unknown=function(d){return arguments.length?(a=d,f):a},function(d,p){return n=d,i=p,h()}}function g2(){return p7e()(im,im)}var CK,cL=$(()=>{uf();Zg();EK();SK();CK=[0,1]});function uL(t,e,r,n){var i=Ug(t,e,r),a;switch(n=pf(n??",f"),n.type){case"s":{var s=Math.max(Math.abs(t),Math.abs(e));return n.precision==null&&!isNaN(a=eL(i,s))&&(n.precision=a),Ew(n,s)}case"":case"e":case"g":case"p":case"r":{n.precision==null&&!isNaN(a=tL(i,Math.max(Math.abs(t),Math.abs(e))))&&(n.precision=a-(n.type==="e"));break}case"f":case"%":{n.precision==null&&!isNaN(a=J_(i))&&(n.precision=a-(n.type==="%")*2);break}}return zc(n)}var AK=$(()=>{uf();rL()});function g7e(t){var e=t.domain;return t.ticks=function(r){var n=e();return z5(n[0],n[n.length-1],r??10)},t.tickFormat=function(r,n){var i=e();return uL(i[0],i[i.length-1],r??10,n)},t.nice=function(r){r==null&&(r=10);var n=e(),i=0,a=n.length-1,s=n[i],o=n[a],l,u,h=10;for(o0;){if(u=Wv(s,o,r),u===l)return n[i]=s,n[a]=o,e(n);if(u>0)s=Math.floor(s/u)*u,o=Math.ceil(o/u)*u;else if(u<0)s=Math.ceil(s*u)/u,o=Math.floor(o*u)/u;else break;l=u}return t},t}function Vl(){var t=g2();return t.copy=function(){return Sw(t,Vl())},gf.apply(t,arguments),g7e(t)}var _K=$(()=>{uf();cL();p2();AK()});function hL(t,e){t=t.slice();var r=0,n=t.length-1,i=t[r],a=t[n],s;return a{});function An(t,e,r,n){function i(a){return t(a=arguments.length===0?new Date:new Date(+a)),a}return i.floor=a=>(t(a=new Date(+a)),a),i.ceil=a=>(t(a=new Date(a-1)),e(a,1),t(a),a),i.round=a=>{let s=i(a),o=i.ceil(a);return a-s(e(a=new Date(+a),s==null?1:Math.floor(s)),a),i.range=(a,s,o)=>{let l=[];if(a=i.ceil(a),o=o==null?1:Math.floor(o),!(a0))return l;let u;do l.push(u=new Date(+a)),e(a,o),t(a);while(uAn(s=>{if(s>=s)for(;t(s),!a(s);)s.setTime(s-1)},(s,o)=>{if(s>=s)if(o<0)for(;++o<=0;)for(;e(s,-1),!a(s););else for(;--o>=0;)for(;e(s,1),!a(s););}),r&&(i.count=(a,s)=>(fL.setTime(+a),dL.setTime(+s),t(fL),t(dL),Math.floor(r(fL,dL))),i.every=a=>(a=Math.floor(a),!isFinite(a)||!(a>0)?null:a>1?i.filter(n?s=>n(s)%a===0:s=>i.count(0,s)%a===0):i)),i}var fL,dL,sh=$(()=>{fL=new Date,dL=new Date});var Gc,RK,pL=$(()=>{sh();Gc=An(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Gc.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?An(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):Gc);RK=Gc.range});var Eo,DK,gL=$(()=>{sh();Eo=An(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*1e3)},(t,e)=>(e-t)/1e3,t=>t.getUTCSeconds()),DK=Eo.range});var oh,m7e,Cw,y7e,mL=$(()=>{sh();oh=An(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getMinutes()),m7e=oh.range,Cw=An(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getUTCMinutes()),y7e=Cw.range});var lh,v7e,Aw,x7e,yL=$(()=>{sh();lh=An(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3-t.getMinutes()*6e4)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getHours()),v7e=lh.range,Aw=An(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getUTCHours()),x7e=Aw.range});var el,b7e,y2,w7e,_w,T7e,vL=$(()=>{sh();el=An(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*6e4)/864e5,t=>t.getDate()-1),b7e=el.range,y2=An(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>t.getUTCDate()-1),w7e=y2.range,_w=An(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>Math.floor(t/864e5)),T7e=_w.range});function Op(t){return An(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*6e4)/6048e5)}function Pp(t){return An(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/6048e5)}var Ul,mf,Lw,Rw,Vc,Dw,Nw,IK,k7e,E7e,S7e,C7e,A7e,_7e,Bp,am,MK,OK,yf,PK,BK,FK,L7e,R7e,D7e,N7e,I7e,M7e,xL=$(()=>{sh();Ul=Op(0),mf=Op(1),Lw=Op(2),Rw=Op(3),Vc=Op(4),Dw=Op(5),Nw=Op(6),IK=Ul.range,k7e=mf.range,E7e=Lw.range,S7e=Rw.range,C7e=Vc.range,A7e=Dw.range,_7e=Nw.range;Bp=Pp(0),am=Pp(1),MK=Pp(2),OK=Pp(3),yf=Pp(4),PK=Pp(5),BK=Pp(6),FK=Bp.range,L7e=am.range,R7e=MK.range,D7e=OK.range,N7e=yf.range,I7e=PK.range,M7e=BK.range});var ch,O7e,Iw,P7e,bL=$(()=>{sh();ch=An(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+(e.getFullYear()-t.getFullYear())*12,t=>t.getMonth()),O7e=ch.range,Iw=An(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+(e.getUTCFullYear()-t.getUTCFullYear())*12,t=>t.getUTCMonth()),P7e=Iw.range});var So,B7e,Wl,F7e,wL=$(()=>{sh();So=An(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear());So.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:An(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,r)=>{e.setFullYear(e.getFullYear()+r*t)});B7e=So.range,Wl=An(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());Wl.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:An(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});F7e=Wl.range});function zK(t,e,r,n,i,a){let s=[[Eo,1,1e3],[Eo,5,5*1e3],[Eo,15,15*1e3],[Eo,30,30*1e3],[a,1,6e4],[a,5,5*6e4],[a,15,15*6e4],[a,30,30*6e4],[i,1,36e5],[i,3,3*36e5],[i,6,6*36e5],[i,12,12*36e5],[n,1,864e5],[n,2,2*864e5],[r,1,6048e5],[e,1,2592e6],[e,3,3*2592e6],[t,1,31536e6]];function o(u,h,f){let d=hy).right(s,d);if(p===s.length)return t.every(Ug(u/31536e6,h/31536e6,f));if(p===0)return Gc.every(Math.max(Ug(u,h,f),1));let[g,m]=s[d/s[p-1][2]{uf();pL();gL();mL();yL();vL();xL();bL();wL();[z7e,G7e]=zK(Wl,Iw,Bp,_w,Aw,Cw),[TL,kL]=zK(So,ch,Ul,el,lh,oh)});var Mw=$(()=>{pL();gL();mL();yL();vL();xL();bL();wL();GK()});function EL(t){if(0<=t.y&&t.y<100){var e=new Date(-1,t.m,t.d,t.H,t.M,t.S,t.L);return e.setFullYear(t.y),e}return new Date(t.y,t.m,t.d,t.H,t.M,t.S,t.L)}function SL(t){if(0<=t.y&&t.y<100){var e=new Date(Date.UTC(-1,t.m,t.d,t.H,t.M,t.S,t.L));return e.setUTCFullYear(t.y),e}return new Date(Date.UTC(t.y,t.m,t.d,t.H,t.M,t.S,t.L))}function v2(t,e,r){return{y:t,m:e,d:r,H:0,M:0,S:0,L:0}}function CL(t){var e=t.dateTime,r=t.date,n=t.time,i=t.periods,a=t.days,s=t.shortDays,o=t.months,l=t.shortMonths,u=x2(i),h=b2(i),f=x2(a),d=b2(a),p=x2(s),g=b2(s),m=x2(o),y=b2(o),v=x2(l),b=b2(l),w={a:O,A:P,b:B,B:G,c:null,d:YK,e:YK,f:uAe,g:bAe,G:TAe,H:oAe,I:lAe,j:cAe,L:QK,m:hAe,M:fAe,p:F,q,Q:KK,s:ZK,S:dAe,u:pAe,U:gAe,V:mAe,w:yAe,W:vAe,x:null,X:null,y:xAe,Y:wAe,Z:kAe,"%":jK},S={a:j,A:J,b:H,B:he,c:null,d:XK,e:XK,f:AAe,g:BAe,G:$Ae,H:EAe,I:SAe,j:CAe,L:eZ,m:_Ae,M:LAe,p:Z,q:fe,Q:KK,s:ZK,S:RAe,u:DAe,U:NAe,V:IAe,w:MAe,W:OAe,x:null,X:null,y:PAe,Y:FAe,Z:zAe,"%":jK},T={a:M,A:I,b:E,B:_,c:A,d:WK,e:WK,f:nAe,g:UK,G:VK,H:HK,I:HK,j:J7e,L:rAe,m:Q7e,M:eAe,p:D,q:Z7e,Q:aAe,s:sAe,S:tAe,u:H7e,U:Y7e,V:X7e,w:W7e,W:j7e,x:R,X:N,y:UK,Y:VK,Z:K7e,"%":iAe};w.x=k(r,w),w.X=k(n,w),w.c=k(e,w),S.x=k(r,S),S.X=k(n,S),S.c=k(e,S);function k(ne,re){return function(ee){var K=[],le=-1,Q=0,ge=ne.length,ie,we,X;for(ee instanceof Date||(ee=new Date(+ee));++le53)return null;"w"in K||(K.w=1),"Z"in K?(Q=SL(v2(K.y,0,1)),ge=Q.getUTCDay(),Q=ge>4||ge===0?am.ceil(Q):am(Q),Q=y2.offset(Q,(K.V-1)*7),K.y=Q.getUTCFullYear(),K.m=Q.getUTCMonth(),K.d=Q.getUTCDate()+(K.w+6)%7):(Q=EL(v2(K.y,0,1)),ge=Q.getDay(),Q=ge>4||ge===0?mf.ceil(Q):mf(Q),Q=el.offset(Q,(K.V-1)*7),K.y=Q.getFullYear(),K.m=Q.getMonth(),K.d=Q.getDate()+(K.w+6)%7)}else("W"in K||"U"in K)&&("w"in K||(K.w="u"in K?K.u%7:"W"in K?1:0),ge="Z"in K?SL(v2(K.y,0,1)).getUTCDay():EL(v2(K.y,0,1)).getDay(),K.m=0,K.d="W"in K?(K.w+6)%7+K.W*7-(ge+5)%7:K.w+K.U*7-(ge+6)%7);return"Z"in K?(K.H+=K.Z/100|0,K.M+=K.Z%100,SL(K)):EL(K)}}function L(ne,re,ee,K){for(var le=0,Q=re.length,ge=ee.length,ie,we;le=ge)return-1;if(ie=re.charCodeAt(le++),ie===37){if(ie=re.charAt(le++),we=T[ie in qK?re.charAt(le++):ie],!we||(K=we(ne,ee,K))<0)return-1}else if(ie!=ee.charCodeAt(K++))return-1}return K}function D(ne,re,ee){var K=u.exec(re.slice(ee));return K?(ne.p=h.get(K[0].toLowerCase()),ee+K[0].length):-1}function M(ne,re,ee){var K=p.exec(re.slice(ee));return K?(ne.w=g.get(K[0].toLowerCase()),ee+K[0].length):-1}function I(ne,re,ee){var K=f.exec(re.slice(ee));return K?(ne.w=d.get(K[0].toLowerCase()),ee+K[0].length):-1}function E(ne,re,ee){var K=v.exec(re.slice(ee));return K?(ne.m=b.get(K[0].toLowerCase()),ee+K[0].length):-1}function _(ne,re,ee){var K=m.exec(re.slice(ee));return K?(ne.m=y.get(K[0].toLowerCase()),ee+K[0].length):-1}function A(ne,re,ee){return L(ne,e,re,ee)}function R(ne,re,ee){return L(ne,r,re,ee)}function N(ne,re,ee){return L(ne,n,re,ee)}function O(ne){return s[ne.getDay()]}function P(ne){return a[ne.getDay()]}function B(ne){return l[ne.getMonth()]}function G(ne){return o[ne.getMonth()]}function F(ne){return i[+(ne.getHours()>=12)]}function q(ne){return 1+~~(ne.getMonth()/3)}function j(ne){return s[ne.getUTCDay()]}function J(ne){return a[ne.getUTCDay()]}function H(ne){return l[ne.getUTCMonth()]}function he(ne){return o[ne.getUTCMonth()]}function Z(ne){return i[+(ne.getUTCHours()>=12)]}function fe(ne){return 1+~~(ne.getUTCMonth()/3)}return{format:function(ne){var re=k(ne+="",w);return re.toString=function(){return ne},re},parse:function(ne){var re=C(ne+="",!1);return re.toString=function(){return ne},re},utcFormat:function(ne){var re=k(ne+="",S);return re.toString=function(){return ne},re},utcParse:function(ne){var re=C(ne+="",!0);return re.toString=function(){return ne},re}}}function nn(t,e,r){var n=t<0?"-":"",i=(n?-t:t)+"",a=i.length;return n+(a[e.toLowerCase(),r]))}function W7e(t,e,r){var n=Ji.exec(e.slice(r,r+1));return n?(t.w=+n[0],r+n[0].length):-1}function H7e(t,e,r){var n=Ji.exec(e.slice(r,r+1));return n?(t.u=+n[0],r+n[0].length):-1}function Y7e(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.U=+n[0],r+n[0].length):-1}function X7e(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.V=+n[0],r+n[0].length):-1}function j7e(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.W=+n[0],r+n[0].length):-1}function VK(t,e,r){var n=Ji.exec(e.slice(r,r+4));return n?(t.y=+n[0],r+n[0].length):-1}function UK(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.y=+n[0]+(+n[0]>68?1900:2e3),r+n[0].length):-1}function K7e(t,e,r){var n=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return n?(t.Z=n[1]?0:-(n[2]+(n[3]||"00")),r+n[0].length):-1}function Z7e(t,e,r){var n=Ji.exec(e.slice(r,r+1));return n?(t.q=n[0]*3-3,r+n[0].length):-1}function Q7e(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.m=n[0]-1,r+n[0].length):-1}function WK(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.d=+n[0],r+n[0].length):-1}function J7e(t,e,r){var n=Ji.exec(e.slice(r,r+3));return n?(t.m=0,t.d=+n[0],r+n[0].length):-1}function HK(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.H=+n[0],r+n[0].length):-1}function eAe(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.M=+n[0],r+n[0].length):-1}function tAe(t,e,r){var n=Ji.exec(e.slice(r,r+2));return n?(t.S=+n[0],r+n[0].length):-1}function rAe(t,e,r){var n=Ji.exec(e.slice(r,r+3));return n?(t.L=+n[0],r+n[0].length):-1}function nAe(t,e,r){var n=Ji.exec(e.slice(r,r+6));return n?(t.L=Math.floor(n[0]/1e3),r+n[0].length):-1}function iAe(t,e,r){var n=q7e.exec(e.slice(r,r+1));return n?r+n[0].length:-1}function aAe(t,e,r){var n=Ji.exec(e.slice(r));return n?(t.Q=+n[0],r+n[0].length):-1}function sAe(t,e,r){var n=Ji.exec(e.slice(r));return n?(t.s=+n[0],r+n[0].length):-1}function YK(t,e){return nn(t.getDate(),e,2)}function oAe(t,e){return nn(t.getHours(),e,2)}function lAe(t,e){return nn(t.getHours()%12||12,e,2)}function cAe(t,e){return nn(1+el.count(So(t),t),e,3)}function QK(t,e){return nn(t.getMilliseconds(),e,3)}function uAe(t,e){return QK(t,e)+"000"}function hAe(t,e){return nn(t.getMonth()+1,e,2)}function fAe(t,e){return nn(t.getMinutes(),e,2)}function dAe(t,e){return nn(t.getSeconds(),e,2)}function pAe(t){var e=t.getDay();return e===0?7:e}function gAe(t,e){return nn(Ul.count(So(t)-1,t),e,2)}function JK(t){var e=t.getDay();return e>=4||e===0?Vc(t):Vc.ceil(t)}function mAe(t,e){return t=JK(t),nn(Vc.count(So(t),t)+(So(t).getDay()===4),e,2)}function yAe(t){return t.getDay()}function vAe(t,e){return nn(mf.count(So(t)-1,t),e,2)}function xAe(t,e){return nn(t.getFullYear()%100,e,2)}function bAe(t,e){return t=JK(t),nn(t.getFullYear()%100,e,2)}function wAe(t,e){return nn(t.getFullYear()%1e4,e,4)}function TAe(t,e){var r=t.getDay();return t=r>=4||r===0?Vc(t):Vc.ceil(t),nn(t.getFullYear()%1e4,e,4)}function kAe(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+nn(e/60|0,"0",2)+nn(e%60,"0",2)}function XK(t,e){return nn(t.getUTCDate(),e,2)}function EAe(t,e){return nn(t.getUTCHours(),e,2)}function SAe(t,e){return nn(t.getUTCHours()%12||12,e,2)}function CAe(t,e){return nn(1+y2.count(Wl(t),t),e,3)}function eZ(t,e){return nn(t.getUTCMilliseconds(),e,3)}function AAe(t,e){return eZ(t,e)+"000"}function _Ae(t,e){return nn(t.getUTCMonth()+1,e,2)}function LAe(t,e){return nn(t.getUTCMinutes(),e,2)}function RAe(t,e){return nn(t.getUTCSeconds(),e,2)}function DAe(t){var e=t.getUTCDay();return e===0?7:e}function NAe(t,e){return nn(Bp.count(Wl(t)-1,t),e,2)}function tZ(t){var e=t.getUTCDay();return e>=4||e===0?yf(t):yf.ceil(t)}function IAe(t,e){return t=tZ(t),nn(yf.count(Wl(t),t)+(Wl(t).getUTCDay()===4),e,2)}function MAe(t){return t.getUTCDay()}function OAe(t,e){return nn(am.count(Wl(t)-1,t),e,2)}function PAe(t,e){return nn(t.getUTCFullYear()%100,e,2)}function BAe(t,e){return t=tZ(t),nn(t.getUTCFullYear()%100,e,2)}function FAe(t,e){return nn(t.getUTCFullYear()%1e4,e,4)}function $Ae(t,e){var r=t.getUTCDay();return t=r>=4||r===0?yf(t):yf.ceil(t),nn(t.getUTCFullYear()%1e4,e,4)}function zAe(){return"+0000"}function jK(){return"%"}function KK(t){return+t}function ZK(t){return Math.floor(+t/1e3)}var qK,Ji,q7e,V7e,rZ=$(()=>{Mw();qK={"-":"",_:" ",0:"0"},Ji=/^\s*\d+/,q7e=/^%/,V7e=/[\\^$*+?|[\]().{}]/g});function AL(t){return sm=CL(t),Fp=sm.format,nZ=sm.parse,iZ=sm.utcFormat,aZ=sm.utcParse,sm}var sm,Fp,nZ,iZ,aZ,sZ=$(()=>{rZ();AL({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]})});var _L=$(()=>{sZ()});function GAe(t){return new Date(t)}function qAe(t){return t instanceof Date?+t:+new Date(+t)}function oZ(t,e,r,n,i,a,s,o,l,u){var h=g2(),f=h.invert,d=h.domain,p=u(".%L"),g=u(":%S"),m=u("%I:%M"),y=u("%I %p"),v=u("%a %d"),b=u("%b %d"),w=u("%B"),S=u("%Y");function T(k){return(l(k){Mw();_L();cL();p2();LK()});var cZ=$(()=>{kK();_K();aL();lZ()});function uZ(t){for(var e=t.length/6|0,r=new Array(e),n=0;n{});var LL,fZ=$(()=>{hZ();LL=uZ("4e79a7f28e2ce1575976b7b259a14fedc949af7aa1ff9da79c755fbab0ab")});var dZ=$(()=>{fZ()});function Xn(t){return function(){return t}}var Pw=$(()=>{});function gZ(t){return t>1?0:t<-1?om:Math.acos(t)}function DL(t){return t>=1?w2:t<=-1?-w2:Math.asin(t)}var RL,wa,vf,pZ,Bw,Hl,$p,ea,om,w2,lm,Fw=$(()=>{RL=Math.abs,wa=Math.atan2,vf=Math.cos,pZ=Math.max,Bw=Math.min,Hl=Math.sin,$p=Math.sqrt,ea=1e-12,om=Math.PI,w2=om/2,lm=2*om});function $w(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{let n=Math.floor(r);if(!(n>=0))throw new RangeError(`invalid digits: ${r}`);e=n}return t},()=>new Dp(e)}var NL=$(()=>{H_()});function VAe(t){return t.innerRadius}function UAe(t){return t.outerRadius}function WAe(t){return t.startAngle}function HAe(t){return t.endAngle}function YAe(t){return t&&t.padAngle}function XAe(t,e,r,n,i,a,s,o){var l=r-t,u=n-e,h=s-i,f=o-a,d=f*l-h*u;if(!(d*dA*A+R*R&&(L=M,D=I),{cx:L,cy:D,x01:-h,y01:-f,x11:L*(i/T-1),y11:D*(i/T-1)}}function Uc(){var t=VAe,e=UAe,r=Xn(0),n=null,i=WAe,a=HAe,s=YAe,o=null,l=$w(u);function u(){var h,f,d=+t.apply(this,arguments),p=+e.apply(this,arguments),g=i.apply(this,arguments)-w2,m=a.apply(this,arguments)-w2,y=RL(m-g),v=m>g;if(o||(o=h=l()),pea))o.moveTo(0,0);else if(y>lm-ea)o.moveTo(p*vf(g),p*Hl(g)),o.arc(0,0,p,g,m,!v),d>ea&&(o.moveTo(d*vf(m),d*Hl(m)),o.arc(0,0,d,m,g,v));else{var b=g,w=m,S=g,T=m,k=y,C=y,L=s.apply(this,arguments)/2,D=L>ea&&(n?+n.apply(this,arguments):$p(d*d+p*p)),M=Bw(RL(p-d)/2,+r.apply(this,arguments)),I=M,E=M,_,A;if(D>ea){var R=DL(D/d*Hl(L)),N=DL(D/p*Hl(L));(k-=R*2)>ea?(R*=v?1:-1,S+=R,T-=R):(k=0,S=T=(g+m)/2),(C-=N*2)>ea?(N*=v?1:-1,b+=N,w-=N):(C=0,b=w=(g+m)/2)}var O=p*vf(b),P=p*Hl(b),B=d*vf(T),G=d*Hl(T);if(M>ea){var F=p*vf(w),q=p*Hl(w),j=d*vf(S),J=d*Hl(S),H;if(yea?E>ea?(_=zw(j,J,O,P,p,E,v),A=zw(F,q,B,G,p,E,v),o.moveTo(_.cx+_.x01,_.cy+_.y01),Eea)||!(k>ea)?o.lineTo(B,G):I>ea?(_=zw(B,G,F,q,d,-I,v),A=zw(O,P,j,J,d,-I,v),o.lineTo(_.cx+_.x01,_.cy+_.y01),I{Pw();Fw();NL()});function Gw(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}var t2t,IL=$(()=>{t2t=Array.prototype.slice});function yZ(t){this._context=t}function xf(t){return new yZ(t)}var ML=$(()=>{yZ.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:this._context.lineTo(t,e);break}}}});function vZ(t){return t[0]}function xZ(t){return t[1]}var bZ=$(()=>{});function Wc(t,e){var r=Xn(!0),n=null,i=xf,a=null,s=$w(o);t=typeof t=="function"?t:t===void 0?vZ:Xn(t),e=typeof e=="function"?e:e===void 0?xZ:Xn(e);function o(l){var u,h=(l=Gw(l)).length,f,d=!1,p;for(n==null&&(a=i(p=s())),u=0;u<=h;++u)!(u{IL();Pw();ML();NL();bZ()});function TZ(t,e){return et?1:e>=t?0:NaN}var kZ=$(()=>{});function EZ(t){return t}var SZ=$(()=>{});function OL(){var t=EZ,e=TZ,r=null,n=Xn(0),i=Xn(lm),a=Xn(0);function s(o){var l,u=(o=Gw(o)).length,h,f,d=0,p=new Array(u),g=new Array(u),m=+n.apply(this,arguments),y=Math.min(lm,Math.max(-lm,i.apply(this,arguments)-m)),v,b=Math.min(Math.abs(y)/u,a.apply(this,arguments)),w=b*(y<0?-1:1),S;for(l=0;l0&&(d+=S);for(e!=null?p.sort(function(T,k){return e(g[T],g[k])}):r!=null&&p.sort(function(T,k){return r(o[T],o[k])}),l=0,f=d?(y-u*w)/d:0;l0?S*f:0)+w,g[h]={data:o[h],index:l,value:S,startAngle:m,endAngle:v,padAngle:b};return g}return s.value=function(o){return arguments.length?(t=typeof o=="function"?o:Xn(+o),s):t},s.sortValues=function(o){return arguments.length?(e=o,r=null,s):e},s.sort=function(o){return arguments.length?(r=o,e=null,s):r},s.startAngle=function(o){return arguments.length?(n=typeof o=="function"?o:Xn(+o),s):n},s.endAngle=function(o){return arguments.length?(i=typeof o=="function"?o:Xn(+o),s):i},s.padAngle=function(o){return arguments.length?(a=typeof o=="function"?o:Xn(+o),s):a},s}var CZ=$(()=>{IL();Pw();kZ();SZ();Fw()});function T2(t){return new qw(t,!0)}function k2(t){return new qw(t,!1)}var qw,AZ=$(()=>{qw=class{constructor(e,r){this._context=e,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,r){switch(e=+e,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,r):this._context.moveTo(e,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,r,e,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,e,this._y0,e,r);break}}this._x0=e,this._y0=r}}});function tl(){}var E2=$(()=>{});function cm(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}function S2(t){this._context=t}function Yl(t){return new S2(t)}var C2=$(()=>{S2.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){switch(this._point){case 3:cm(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:cm(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}}});function _Z(t){this._context=t}function PL(t){return new _Z(t)}var LZ=$(()=>{E2();C2();_Z.prototype={areaStart:tl,areaEnd:tl,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:cm(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}}});function RZ(t){this._context=t}function BL(t){return new RZ(t)}var DZ=$(()=>{C2();RZ.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+t)/6,n=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,n):this._context.moveTo(r,n);break;case 3:this._point=4;default:cm(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}}});function NZ(t,e){this._basis=new S2(t),this._beta=e}var FL,IZ=$(()=>{C2();NZ.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var n=t[0],i=e[0],a=t[r]-n,s=e[r]-i,o=-1,l;++o<=r;)l=o/r,this._basis.point(this._beta*t[o]+(1-this._beta)*(n+l*a),this._beta*e[o]+(1-this._beta)*(i+l*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};FL=(function t(e){function r(n){return e===1?new S2(n):new NZ(n,e)}return r.beta=function(n){return t(+n)},r})(.85)});function um(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}function Vw(t,e){this._context=t,this._k=(1-e)/6}var A2,_2=$(()=>{Vw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:um(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:um(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};A2=(function t(e){function r(n){return new Vw(n,e)}return r.tension=function(n){return t(+n)},r})(0)});function Uw(t,e){this._context=t,this._k=(1-e)/6}var $L,zL=$(()=>{E2();_2();Uw.prototype={areaStart:tl,areaEnd:tl,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:um(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};$L=(function t(e){function r(n){return new Uw(n,e)}return r.tension=function(n){return t(+n)},r})(0)});function Ww(t,e){this._context=t,this._k=(1-e)/6}var GL,qL=$(()=>{_2();Ww.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:um(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};GL=(function t(e){function r(n){return new Ww(n,e)}return r.tension=function(n){return t(+n)},r})(0)});function L2(t,e,r){var n=t._x1,i=t._y1,a=t._x2,s=t._y2;if(t._l01_a>ea){var o=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,l=3*t._l01_a*(t._l01_a+t._l12_a);n=(n*o-t._x0*t._l12_2a+t._x2*t._l01_2a)/l,i=(i*o-t._y0*t._l12_2a+t._y2*t._l01_2a)/l}if(t._l23_a>ea){var u=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,h=3*t._l23_a*(t._l23_a+t._l12_a);a=(a*u+t._x1*t._l23_2a-e*t._l12_2a)/h,s=(s*u+t._y1*t._l23_2a-r*t._l12_2a)/h}t._context.bezierCurveTo(n,i,a,s,t._x2,t._y2)}function MZ(t,e){this._context=t,this._alpha=e}var R2,Hw=$(()=>{Fw();_2();MZ.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:L2(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};R2=(function t(e){function r(n){return e?new MZ(n,e):new Vw(n,0)}return r.alpha=function(n){return t(+n)},r})(.5)});function OZ(t,e){this._context=t,this._alpha=e}var VL,PZ=$(()=>{zL();E2();Hw();OZ.prototype={areaStart:tl,areaEnd:tl,lineStart:function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:L2(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};VL=(function t(e){function r(n){return e?new OZ(n,e):new Uw(n,0)}return r.alpha=function(n){return t(+n)},r})(.5)});function BZ(t,e){this._context=t,this._alpha=e}var UL,FZ=$(()=>{qL();Hw();BZ.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},lineEnd:function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,n=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+n*n,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:L2(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e}};UL=(function t(e){function r(n){return e?new BZ(n,e):new Ww(n,0)}return r.alpha=function(n){return t(+n)},r})(.5)});function $Z(t){this._context=t}function WL(t){return new $Z(t)}var zZ=$(()=>{E2();$Z.prototype={areaStart:tl,areaEnd:tl,lineStart:function(){this._point=0},lineEnd:function(){this._point&&this._context.closePath()},point:function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))}}});function GZ(t){return t<0?-1:1}function qZ(t,e,r){var n=t._x1-t._x0,i=e-t._x1,a=(t._y1-t._y0)/(n||i<0&&-0),s=(r-t._y1)/(i||n<0&&-0),o=(a*i+s*n)/(n+i);return(GZ(a)+GZ(s))*Math.min(Math.abs(a),Math.abs(s),.5*Math.abs(o))||0}function VZ(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}function HL(t,e,r){var n=t._x0,i=t._y0,a=t._x1,s=t._y1,o=(a-n)/3;t._context.bezierCurveTo(n+o,i+o*e,a-o,s-o*r,a,s)}function Yw(t){this._context=t}function UZ(t){this._context=new WZ(t)}function WZ(t){this._context=t}function D2(t){return new Yw(t)}function N2(t){return new UZ(t)}var HZ=$(()=>{Yw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},lineEnd:function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:HL(this,this._t0,VZ(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},point:function(t,e){var r=NaN;if(t=+t,e=+e,!(t===this._x1&&e===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,HL(this,VZ(this,r=qZ(this,t,e)),r);break;default:HL(this,this._t0,r=qZ(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}}};(UZ.prototype=Object.create(Yw.prototype)).point=function(t,e){Yw.prototype.point.call(this,e,t)};WZ.prototype={moveTo:function(t,e){this._context.moveTo(e,t)},closePath:function(){this._context.closePath()},lineTo:function(t,e){this._context.lineTo(e,t)},bezierCurveTo:function(t,e,r,n,i,a){this._context.bezierCurveTo(e,t,n,r,a,i)}}});function XZ(t){this._context=t}function YZ(t){var e,r=t.length-1,n,i=new Array(r),a=new Array(r),s=new Array(r);for(i[0]=0,a[0]=2,s[0]=t[0]+2*t[1],e=1;e=0;--e)i[e]=(s[e]-i[e+1])/a[e];for(a[r-1]=(t[r]+i[r-1])/2,e=0;e{XZ.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=[],this._y=[]},lineEnd:function(){var t=this._x,e=this._y,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var n=YZ(t),i=YZ(e),a=0,s=1;s{Xw.prototype={areaStart:function(){this._line=0},areaEnd:function(){this._line=NaN},lineStart:function(){this._x=this._y=NaN,this._point=0},lineEnd:function(){0=0&&(this._t=1-this._t,this._line=1-this._line)},point:function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e}}});var ZZ=$(()=>{mZ();wZ();CZ();LZ();DZ();C2();AZ();IZ();zL();qL();_2();PZ();FZ();Hw();zZ();ML();HZ();jZ();KZ()});var QZ=$(()=>{});var JZ=$(()=>{});function bf(t,e,r){this.k=t,this.x=e,this.y=r}function XL(t){for(;!t.__zoom;)if(!(t=t.parentNode))return YL;return t.__zoom}var YL,jL=$(()=>{bf.prototype={constructor:bf,scale:function(t){return t===1?this:new bf(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new bf(this.k,this.x+this.k*t,this.y+this.k*e)},apply:function(t){return[t[0]*this.k+this.x,t[1]*this.k+this.y]},applyX:function(t){return t*this.k+this.x},applyY:function(t){return t*this.k+this.y},invert:function(t){return[(t[0]-this.x)/this.k,(t[1]-this.y)/this.k]},invertX:function(t){return(t-this.x)/this.k},invertY:function(t){return(t-this.y)/this.k},rescaleX:function(t){return t.copy().domain(t.range().map(this.invertX,this).map(t.invert,t))},rescaleY:function(t){return t.copy().domain(t.range().map(this.invertY,this).map(t.invert,t))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};YL=new bf(1,0,0);XL.prototype=bf.prototype});var eQ=$(()=>{});var tQ=$(()=>{ww();QZ();JZ();jL();eQ()});var rQ=$(()=>{tQ();jL()});var pr=$(()=>{uf();DW();ij();lj();jg();cj();uj();a_();nY();hj();q_();fj();pj();rL();Mj();bK();Zg();H_();wK();dj();TK();cZ();dZ();zl();ZZ();Mw();_L();dw();ww();rQ()});var ta,Hc=$(()=>{Er();lr();pr();ta=x(t=>{let{securityLevel:e}=Te(),r=Ye("body");if(e==="sandbox"){let a=Ye(`#i${t}`).node()?.contentDocument??document;r=Ye(a.body)}return r.select(`#${t}`)},"selectSvgElement")});function f9(t){return typeof t>"u"||t===null}function aQ(t){return typeof t=="object"&&t!==null}function sQ(t){return Array.isArray(t)?t:f9(t)?[]:[t]}function oQ(t,e){var r,n,i,a;if(e)for(a=Object.keys(e),r=0,n=a.length;ro&&(a=" ... ",e=n-o+a.length),r-n>o&&(s=" ...",r=n+o-s.length),{str:a+t.slice(e,r).replace(/\t/g,"\u2192")+s,pos:n-e+a.length}}function Kw(t,e){return qi.repeat(" ",e-t.length)+t}function uQ(t,e){if(e=Object.create(e||null),!t.buffer)return null;e.maxLength||(e.maxLength=79),typeof e.indent!="number"&&(e.indent=1),typeof e.linesBefore!="number"&&(e.linesBefore=3),typeof e.linesAfter!="number"&&(e.linesAfter=2);for(var r=/\r?\n|\r|\0/g,n=[0],i=[],a,s=-1;a=r.exec(t.buffer);)i.push(a.index),n.push(a.index+a[0].length),t.position<=a.index&&s<0&&(s=n.length-2);s<0&&(s=n.length-1);var o="",l,u,h=Math.min(t.line+e.linesAfter,i.length).toString().length,f=e.maxLength-(e.indent+h+3);for(l=1;l<=e.linesBefore&&!(s-l<0);l++)u=jw(t.buffer,n[s-l],i[s-l],t.position-(n[s]-n[s-l]),f),o=qi.repeat(" ",e.indent)+Kw((t.line-l+1).toString(),h)+" | "+u.str+` `+o;for(u=jw(t.buffer,n[s],i[s],t.position,f),o+=qi.repeat(" ",e.indent)+Kw((t.line+1).toString(),h)+" | "+u.str+` `,o+=qi.repeat("-",e.indent+h+3+u.pos)+`^ `,l=1;l<=e.linesAfter&&!(s+l>=i.length);l++)u=jw(t.buffer,n[s+l],i[s+l],t.position-(n[s]-n[s+l]),f),o+=qi.repeat(" ",e.indent)+Kw((t.line+l+1).toString(),h)+" | "+u.str+` `;return o.replace(/\n$/,"")}function hQ(t){var e={};return t!==null&&Object.keys(t).forEach(function(r){t[r].forEach(function(n){e[String(n)]=r})}),e}function fQ(t,e){if(e=e||{},Object.keys(e).forEach(function(r){if(r8e.indexOf(r)===-1)throw new Hs('Unknown option "'+r+'" is met in definition of "'+t+'" YAML type.')}),this.options=e,this.tag=t,this.kind=e.kind||null,this.resolve=e.resolve||function(){return!0},this.construct=e.construct||function(r){return r},this.instanceOf=e.instanceOf||null,this.predicate=e.predicate||null,this.represent=e.represent||null,this.representName=e.representName||null,this.defaultStyle=e.defaultStyle||null,this.multi=e.multi||!1,this.styleAliases=hQ(e.styleAliases||null),n8e.indexOf(this.kind)===-1)throw new Hs('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}function ZL(t,e){var r=[];return t[e].forEach(function(n){var i=r.length;r.forEach(function(a,s){a.tag===n.tag&&a.kind===n.kind&&a.multi===n.multi&&(i=s)}),r[i]=n}),r}function dQ(){var t={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},e,r;function n(i){i.multi?(t.multi[i.kind].push(i),t.multi.fallback.push(i)):t[i.kind][i.tag]=t.fallback[i.tag]=i}for(x(n,"collectType"),e=0,r=arguments.length;e=0&&(e=e.slice(1)),e===".inf"?r===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:r*parseFloat(e,10)}function _Q(t,e){var r;if(isNaN(t))switch(e){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===t)switch(e){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===t)switch(e){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(qi.isNegativeZero(t))return"-0.0";return r=t.toString(10),d8e.test(r)?r.replace("e",".e"):r}function LQ(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||qi.isNegativeZero(t))}function IQ(t){return t===null?!1:DQ.exec(t)!==null||NQ.exec(t)!==null}function MQ(t){var e,r,n,i,a,s,o,l=0,u=null,h,f,d;if(e=DQ.exec(t),e===null&&(e=NQ.exec(t)),e===null)throw new Error("Date resolve error");if(r=+e[1],n=+e[2]-1,i=+e[3],!e[4])return new Date(Date.UTC(r,n,i));if(a=+e[4],s=+e[5],o=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(h=+e[10],f=+(e[11]||0),u=(h*60+f)*6e4,e[9]==="-"&&(u=-u)),d=new Date(Date.UTC(r,n,i,a,s,o,l)),u&&d.setTime(d.getTime()-u),d}function OQ(t){return t.toISOString()}function PQ(t){return t==="<<"||t===null}function BQ(t){if(t===null)return!1;var e,r,n=0,i=t.length,a=p9;for(r=0;r64)){if(e<0)return!1;n+=6}return n%8===0}function FQ(t){var e,r,n=t.replace(/[\r\n=]/g,""),i=n.length,a=p9,s=0,o=[];for(e=0;e>16&255),o.push(s>>8&255),o.push(s&255)),s=s<<6|a.indexOf(n.charAt(e));return r=i%4*6,r===0?(o.push(s>>16&255),o.push(s>>8&255),o.push(s&255)):r===18?(o.push(s>>10&255),o.push(s>>2&255)):r===12&&o.push(s>>4&255),new Uint8Array(o)}function $Q(t){var e="",r=0,n,i,a=t.length,s=p9;for(n=0;n>18&63],e+=s[r>>12&63],e+=s[r>>6&63],e+=s[r&63]),r=(r<<8)+t[n];return i=a%3,i===0?(e+=s[r>>18&63],e+=s[r>>12&63],e+=s[r>>6&63],e+=s[r&63]):i===2?(e+=s[r>>10&63],e+=s[r>>4&63],e+=s[r<<2&63],e+=s[64]):i===1&&(e+=s[r>>2&63],e+=s[r<<4&63],e+=s[64],e+=s[64]),e}function zQ(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}function GQ(t){if(t===null)return!0;var e=[],r,n,i,a,s,o=t;for(r=0,n=o.length;r>10)+55296,(t-65536&1023)+56320)}function iJ(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||YQ,this.onWarning=e.onWarning||null,this.legacy=e.legacy||!1,this.json=e.json||!1,this.listener=e.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=t.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}function g9(t,e){var r={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return r.snippet=t8e(r),new Hs(e,r)}function Yt(t,e){throw g9(t,e)}function B2(t,e){t.onWarning&&t.onWarning.call(null,g9(t,e))}function uh(t,e,r,n){var i,a,s,o;if(e1&&(t.result+=qi.repeat(` `,e-1))}function aJ(t,e,r){var n,i,a,s,o,l,u,h,f=t.kind,d=t.result,p;if(p=t.input.charCodeAt(t.position),vs(p)||Gp(p)||p===35||p===38||p===42||p===33||p===124||p===62||p===39||p===34||p===37||p===64||p===96||(p===63||p===45)&&(i=t.input.charCodeAt(t.position+1),vs(i)||r&&Gp(i)))return!1;for(t.kind="scalar",t.result="",a=s=t.position,o=!1;p!==0;){if(p===58){if(i=t.input.charCodeAt(t.position+1),vs(i)||r&&Gp(i))break}else if(p===35){if(n=t.input.charCodeAt(t.position-1),vs(n))break}else{if(t.position===t.lineStart&&G2(t)||r&&Gp(p))break;if(Xl(p))if(l=t.line,u=t.lineStart,h=t.lineIndent,Ei(t,!1,-1),t.lineIndent>=e){o=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=s,t.line=l,t.lineStart=u,t.lineIndent=h;break}}o&&(uh(t,a,s,!1),iT(t,t.line-l),a=s=t.position,o=!1),wf(p)||(s=t.position+1),p=t.input.charCodeAt(++t.position)}return uh(t,a,s,!1),t.result?!0:(t.kind=f,t.result=d,!1)}function sJ(t,e){var r,n,i;if(r=t.input.charCodeAt(t.position),r!==39)return!1;for(t.kind="scalar",t.result="",t.position++,n=i=t.position;(r=t.input.charCodeAt(t.position))!==0;)if(r===39)if(uh(t,n,t.position,!0),r=t.input.charCodeAt(++t.position),r===39)n=t.position,t.position++,i=t.position;else return!0;else Xl(r)?(uh(t,n,i,!0),iT(t,Ei(t,!1,e)),n=i=t.position):t.position===t.lineStart&&G2(t)?Yt(t,"unexpected end of the document within a single quoted scalar"):(t.position++,i=t.position);Yt(t,"unexpected end of the stream within a single quoted scalar")}function oJ(t,e){var r,n,i,a,s,o;if(o=t.input.charCodeAt(t.position),o!==34)return!1;for(t.kind="scalar",t.result="",t.position++,r=n=t.position;(o=t.input.charCodeAt(t.position))!==0;){if(o===34)return uh(t,r,t.position,!0),t.position++,!0;if(o===92){if(uh(t,r,t.position,!0),o=t.input.charCodeAt(++t.position),Xl(o))Ei(t,!1,e);else if(o<256&&rJ[o])t.result+=nJ[o],t.position++;else if((s=JQ(o))>0){for(i=s,a=0;i>0;i--)o=t.input.charCodeAt(++t.position),(s=QQ(o))>=0?a=(a<<4)+s:Yt(t,"expected hexadecimal character");t.result+=tJ(a),t.position++}else Yt(t,"unknown escape sequence");r=n=t.position}else Xl(o)?(uh(t,r,n,!0),iT(t,Ei(t,!1,e)),r=n=t.position):t.position===t.lineStart&&G2(t)?Yt(t,"unexpected end of the document within a double quoted scalar"):(t.position++,n=t.position)}Yt(t,"unexpected end of the stream within a double quoted scalar")}function lJ(t,e){var r=!0,n,i,a,s=t.tag,o,l=t.anchor,u,h,f,d,p,g=Object.create(null),m,y,v,b;if(b=t.input.charCodeAt(t.position),b===91)h=93,p=!1,o=[];else if(b===123)h=125,p=!0,o={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=o),b=t.input.charCodeAt(++t.position);b!==0;){if(Ei(t,!0,e),b=t.input.charCodeAt(t.position),b===h)return t.position++,t.tag=s,t.anchor=l,t.kind=p?"mapping":"sequence",t.result=o,!0;r?b===44&&Yt(t,"expected the node content, but found ','"):Yt(t,"missed comma between flow collection entries"),y=m=v=null,f=d=!1,b===63&&(u=t.input.charCodeAt(t.position+1),vs(u)&&(f=d=!0,t.position++,Ei(t,!0,e))),n=t.line,i=t.lineStart,a=t.position,Vp(t,e,Qw,!1,!0),y=t.tag,m=t.result,Ei(t,!0,e),b=t.input.charCodeAt(t.position),(d||t.line===n)&&b===58&&(f=!0,b=t.input.charCodeAt(++t.position),Ei(t,!0,e),Vp(t,e,Qw,!1,!0),v=t.result),p?qp(t,o,g,y,m,v,n,i,a):f?o.push(qp(t,null,g,y,m,v,n,i,a)):o.push(m),Ei(t,!0,e),b=t.input.charCodeAt(t.position),b===44?(r=!0,b=t.input.charCodeAt(++t.position)):r=!1}Yt(t,"unexpected end of the stream within a flow collection")}function cJ(t,e){var r,n,i=KL,a=!1,s=!1,o=e,l=0,u=!1,h,f;if(f=t.input.charCodeAt(t.position),f===124)n=!1;else if(f===62)n=!0;else return!1;for(t.kind="scalar",t.result="";f!==0;)if(f=t.input.charCodeAt(++t.position),f===43||f===45)KL===i?i=f===43?nQ:C8e:Yt(t,"repeat of a chomping mode identifier");else if((h=eJ(f))>=0)h===0?Yt(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):s?Yt(t,"repeat of an indentation width identifier"):(o=e+h-1,s=!0);else break;if(wf(f)){do f=t.input.charCodeAt(++t.position);while(wf(f));if(f===35)do f=t.input.charCodeAt(++t.position);while(!Xl(f)&&f!==0)}for(;f!==0;){for(nT(t),t.lineIndent=0,f=t.input.charCodeAt(t.position);(!s||t.lineIndento&&(o=t.lineIndent),Xl(f)){l++;continue}if(t.lineIndente)&&l!==0)Yt(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(y&&(s=t.line,o=t.lineStart,l=t.position),Vp(t,e,Jw,!0,i)&&(y?g=t.result:m=t.result),y||(qp(t,f,d,p,g,m,s,o,l),p=g=m=null),Ei(t,!0,-1),b=t.input.charCodeAt(t.position)),(t.line===a||t.lineIndent>e)&&b!==0)Yt(t,"bad indentation of a mapping entry");else if(t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndent tag; it should be "scalar", not "'+t.kind+'"'),f=0,d=t.implicitTypes.length;f"),t.result!==null&&g.kind!==t.kind&&Yt(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+g.kind+'", not "'+t.kind+'"'),g.resolve(t.result,t.tag)?(t.result=g.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):Yt(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||h}function pJ(t){var e=t.position,r,n,i,a=!1,s;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(s=t.input.charCodeAt(t.position))!==0&&(Ei(t,!0,-1),s=t.input.charCodeAt(t.position),!(t.lineIndent>0||s!==37));){for(a=!0,s=t.input.charCodeAt(++t.position),r=t.position;s!==0&&!vs(s);)s=t.input.charCodeAt(++t.position);for(n=t.input.slice(r,t.position),i=[],n.length<1&&Yt(t,"directive name must not be less than one character in length");s!==0;){for(;wf(s);)s=t.input.charCodeAt(++t.position);if(s===35){do s=t.input.charCodeAt(++t.position);while(s!==0&&!Xl(s));break}if(Xl(s))break;for(r=t.position;s!==0&&!vs(s);)s=t.input.charCodeAt(++t.position);i.push(t.input.slice(r,t.position))}s!==0&&nT(t),Tf.call(iQ,n)?iQ[n](t,n,i):B2(t,'unknown document directive "'+n+'"')}if(Ei(t,!0,-1),t.lineIndent===0&&t.input.charCodeAt(t.position)===45&&t.input.charCodeAt(t.position+1)===45&&t.input.charCodeAt(t.position+2)===45?(t.position+=3,Ei(t,!0,-1)):a&&Yt(t,"directives end mark is expected"),Vp(t,t.lineIndent-1,Jw,!1,!0),Ei(t,!0,-1),t.checkLineBreaks&&_8e.test(t.input.slice(e,t.position))&&B2(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&G2(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,Ei(t,!0,-1));return}if(t.position"u"&&(r=e,e=null);var n=m9(t,r);if(typeof e!="function")return n;for(var i=0,a=n.length;i=55296&&r<=56319&&e+1=56320&&n<=57343)?(r-55296)*1024+n-56320+65536:r}function v9(t){var e=/^\n* /;return e.test(t)}function MJ(t,e,r,n,i,a,s,o){var l,u=0,h=null,f=!1,d=!1,p=n!==-1,g=-1,m=LJ(fm(t,0))&&RJ(fm(t,t.length-1));if(e||s)for(l=0;l=65536?l+=2:l++){if(u=fm(t,l),!pm(u))return hm;m=m&&a9(u,h,o),h=u}else{for(l=0;l=65536?l+=2:l++){if(u=fm(t,l),u===F2)f=!0,p&&(d=d||l-g-1>n&&t[g+1]!==" ",g=l);else if(!pm(u))return hm;m=m&&a9(u,h,o),h=u}d=d||p&&l-g-1>n&&t[g+1]!==" "}return!f&&!d?m&&!s&&!i(t)?DJ:a===$2?hm:s9:r>9&&v9(t)?hm:s?a===$2?hm:s9:d?IJ:NJ}function OJ(t,e,r,n,i){t.dump=(function(){if(e.length===0)return t.quotingType===$2?'""':"''";if(!t.noCompatMode&&(X8e.indexOf(e)!==-1||j8e.test(e)))return t.quotingType===$2?'"'+e+'"':"'"+e+"'";var a=t.indent*Math.max(1,r),s=t.lineWidth===-1?-1:Math.max(Math.min(t.lineWidth,40),t.lineWidth-a),o=n||t.flowLevel>-1&&r>=t.flowLevel;function l(u){return _J(t,u)}switch(x(l,"testAmbiguity"),MJ(e,o,t.indent,s,l,t.quotingType,t.forceQuotes&&!n,i)){case DJ:return e;case s9:return"'"+e.replace(/'/g,"''")+"'";case NJ:return"|"+o9(e,t.indent)+l9(n9(e,a));case IJ:return">"+o9(e,t.indent)+l9(n9(PJ(e,s),a));case hm:return'"'+BJ(e)+'"';default:throw new Hs("impossible error: invalid scalar style")}})()}function o9(t,e){var r=v9(t)?String(e):"",n=t[t.length-1]===` `,i=n&&(t[t.length-2]===` `||t===` `),a=i?"+":n?"":"-";return r+a+` `}function l9(t){return t[t.length-1]===` `?t.slice(0,-1):t}function PJ(t,e){for(var r=/(\n+)([^\n]*)/g,n=(function(){var u=t.indexOf(` `);return u=u!==-1?u:t.length,r.lastIndex=u,c9(t.slice(0,u),e)})(),i=t[0]===` `||t[0]===" ",a,s;s=r.exec(t);){var o=s[1],l=s[2];a=l[0]===" ",n+=o+(!i&&!a&&l!==""?` `:"")+c9(l,e),i=a}return n}function c9(t,e){if(t===""||t[0]===" ")return t;for(var r=/ [^ ]/g,n,i=0,a,s=0,o=0,l="";n=r.exec(t);)o=n.index,o-i>e&&(a=s>i?s:o,l+=` `+t.slice(i,a),i=a+1),s=o;return l+=` `,t.length-i>e&&s>i?l+=t.slice(i,s)+` `+t.slice(s+1):l+=t.slice(i),l.slice(1)}function BJ(t){for(var e="",r=0,n,i=0;i=65536?i+=2:i++)r=fm(t,i),n=Wa[r],!n&&pm(r)?(e+=t[i],r>=65536&&(e+=t[i+1])):e+=n||CJ(r);return e}function FJ(t,e,r){var n="",i=t.tag,a,s,o;for(a=0,s=r.length;a"u"&&Yc(t,e,null,!1,!1))&&(n!==""&&(n+=","+(t.condenseFlow?"":" ")),n+=t.dump);t.tag=i,t.dump="["+n+"]"}function u9(t,e,r,n){var i="",a=t.tag,s,o,l;for(s=0,o=r.length;s"u"&&Yc(t,e+1,null,!0,!0,!1,!0))&&((!n||i!=="")&&(i+=tT(t,e)),t.dump&&F2===t.dump.charCodeAt(0)?i+="-":i+="- ",i+=t.dump);t.tag=a,t.dump=i||"[]"}function $J(t,e,r){var n="",i=t.tag,a=Object.keys(r),s,o,l,u,h;for(s=0,o=a.length;s1024&&(h+="? "),h+=t.dump+(t.condenseFlow?'"':"")+":"+(t.condenseFlow?"":" "),Yc(t,e,u,!1,!1)&&(h+=t.dump,n+=h));t.tag=i,t.dump="{"+n+"}"}function zJ(t,e,r,n){var i="",a=t.tag,s=Object.keys(r),o,l,u,h,f,d;if(t.sortKeys===!0)s.sort();else if(typeof t.sortKeys=="function")s.sort(t.sortKeys);else if(t.sortKeys)throw new Hs("sortKeys must be a boolean or a function");for(o=0,l=s.length;o1024,f&&(t.dump&&F2===t.dump.charCodeAt(0)?d+="?":d+="? "),d+=t.dump,f&&(d+=tT(t,e)),Yc(t,e+1,h,!0,f)&&(t.dump&&F2===t.dump.charCodeAt(0)?d+=":":d+=": ",d+=t.dump,i+=d));t.tag=a,t.dump=i||"{}"}function h9(t,e,r){var n,i,a,s,o,l;for(i=r?t.explicitTypes:t.implicitTypes,a=0,s=i.length;a tag resolver accepts not "'+l+'" style');t.dump=n}return!0}return!1}function Yc(t,e,r,n,i,a,s){t.tag=null,t.dump=r,h9(t,r,!1)||h9(t,r,!0);var o=vJ.call(t.dump),l=n,u;n&&(n=t.flowLevel<0||t.flowLevel>e);var h=o==="[object Object]"||o==="[object Array]",f,d;if(h&&(f=t.duplicates.indexOf(r),d=f!==-1),(t.tag!==null&&t.tag!=="?"||d||t.indent!==2&&e>0)&&(i=!1),d&&t.usedDuplicates[f])t.dump="*ref_"+f;else{if(h&&d&&!t.usedDuplicates[f]&&(t.usedDuplicates[f]=!0),o==="[object Object]")n&&Object.keys(t.dump).length!==0?(zJ(t,e,t.dump,i),d&&(t.dump="&ref_"+f+t.dump)):($J(t,e,t.dump),d&&(t.dump="&ref_"+f+" "+t.dump));else if(o==="[object Array]")n&&t.dump.length!==0?(t.noArrayIndent&&!s&&e>0?u9(t,e-1,t.dump,i):u9(t,e,t.dump,i),d&&(t.dump="&ref_"+f+t.dump)):(FJ(t,e,t.dump),d&&(t.dump="&ref_"+f+" "+t.dump));else if(o==="[object String]")t.tag!=="?"&&OJ(t,t.dump,e,a,l);else{if(o==="[object Undefined]")return!1;if(t.skipInvalid)return!1;throw new Hs("unacceptable kind of an object to dump "+o)}t.tag!==null&&t.tag!=="?"&&(u=encodeURI(t.tag[0]==="!"?t.tag.slice(1):t.tag).replace(/!/g,"%21"),t.tag[0]==="!"?u="!"+u:u.slice(0,18)==="tag:yaml.org,2002:"?u="!!"+u.slice(18):u="!<"+u+">",t.dump=u+" "+t.dump)}return!0}function GJ(t,e){var r=[],n=[],i,a;for(rT(t,r,n),i=0,a=n.length;i{lr();x(f9,"isNothing");x(aQ,"isObject");x(sQ,"toArray");x(oQ,"extend");x(lQ,"repeat");x(cQ,"isNegativeZero");jAe=f9,KAe=aQ,ZAe=sQ,QAe=lQ,JAe=cQ,e8e=oQ,qi={isNothing:jAe,isObject:KAe,toArray:ZAe,repeat:QAe,isNegativeZero:JAe,extend:e8e};x(d9,"formatError");x(dm,"YAMLException$1");dm.prototype=Object.create(Error.prototype);dm.prototype.constructor=dm;dm.prototype.toString=x(function(e){return this.name+": "+d9(this,e)},"toString");Hs=dm;x(jw,"getLine");x(Kw,"padStart");x(uQ,"makeSnippet");t8e=uQ,r8e=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],n8e=["scalar","sequence","mapping"];x(hQ,"compileStyleAliases");x(fQ,"Type$1");Ua=fQ;x(ZL,"compileList");x(dQ,"compileMap");x(Zw,"Schema$1");Zw.prototype.extend=x(function(e){var r=[],n=[];if(e instanceof Ua)n.push(e);else if(Array.isArray(e))n=n.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(r=r.concat(e.implicit)),e.explicit&&(n=n.concat(e.explicit));else throw new Hs("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");r.forEach(function(a){if(!(a instanceof Ua))throw new Hs("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(a.loadKind&&a.loadKind!=="scalar")throw new Hs("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(a.multi)throw new Hs("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),n.forEach(function(a){if(!(a instanceof Ua))throw new Hs("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var i=Object.create(Zw.prototype);return i.implicit=(this.implicit||[]).concat(r),i.explicit=(this.explicit||[]).concat(n),i.compiledImplicit=ZL(i,"implicit"),i.compiledExplicit=ZL(i,"explicit"),i.compiledTypeMap=dQ(i.compiledImplicit,i.compiledExplicit),i},"extend");i8e=Zw,a8e=new Ua("tag:yaml.org,2002:str",{kind:"scalar",construct:x(function(t){return t!==null?t:""},"construct")}),s8e=new Ua("tag:yaml.org,2002:seq",{kind:"sequence",construct:x(function(t){return t!==null?t:[]},"construct")}),o8e=new Ua("tag:yaml.org,2002:map",{kind:"mapping",construct:x(function(t){return t!==null?t:{}},"construct")}),l8e=new i8e({explicit:[a8e,s8e,o8e]});x(pQ,"resolveYamlNull");x(gQ,"constructYamlNull");x(mQ,"isNull");c8e=new Ua("tag:yaml.org,2002:null",{kind:"scalar",resolve:pQ,construct:gQ,predicate:mQ,represent:{canonical:x(function(){return"~"},"canonical"),lowercase:x(function(){return"null"},"lowercase"),uppercase:x(function(){return"NULL"},"uppercase"),camelcase:x(function(){return"Null"},"camelcase"),empty:x(function(){return""},"empty")},defaultStyle:"lowercase"});x(yQ,"resolveYamlBoolean");x(vQ,"constructYamlBoolean");x(xQ,"isBoolean");u8e=new Ua("tag:yaml.org,2002:bool",{kind:"scalar",resolve:yQ,construct:vQ,predicate:xQ,represent:{lowercase:x(function(t){return t?"true":"false"},"lowercase"),uppercase:x(function(t){return t?"TRUE":"FALSE"},"uppercase"),camelcase:x(function(t){return t?"True":"False"},"camelcase")},defaultStyle:"lowercase"});x(bQ,"isHexCode");x(wQ,"isOctCode");x(TQ,"isDecCode");x(kQ,"resolveYamlInteger");x(EQ,"constructYamlInteger");x(SQ,"isInteger");h8e=new Ua("tag:yaml.org,2002:int",{kind:"scalar",resolve:kQ,construct:EQ,predicate:SQ,represent:{binary:x(function(t){return t>=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},"binary"),octal:x(function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)},"octal"),decimal:x(function(t){return t.toString(10)},"decimal"),hexadecimal:x(function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),f8e=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");x(CQ,"resolveYamlFloat");x(AQ,"constructYamlFloat");d8e=/^[-+]?[0-9]+e/;x(_Q,"representYamlFloat");x(LQ,"isFloat");p8e=new Ua("tag:yaml.org,2002:float",{kind:"scalar",resolve:CQ,construct:AQ,predicate:LQ,represent:_Q,defaultStyle:"lowercase"}),RQ=l8e.extend({implicit:[c8e,u8e,h8e,p8e]}),g8e=RQ,DQ=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),NQ=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9]?)-([0-9][0-9]?)(?:[Tt]|[ \\t]+)([0-9][0-9]?):([0-9][0-9]):([0-9][0-9])(?:\\.([0-9]*))?(?:[ \\t]*(Z|([-+])([0-9][0-9]?)(?::([0-9][0-9]))?))?$");x(IQ,"resolveYamlTimestamp");x(MQ,"constructYamlTimestamp");x(OQ,"representYamlTimestamp");m8e=new Ua("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:IQ,construct:MQ,instanceOf:Date,represent:OQ});x(PQ,"resolveYamlMerge");y8e=new Ua("tag:yaml.org,2002:merge",{kind:"scalar",resolve:PQ}),p9=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= \r`;x(BQ,"resolveYamlBinary");x(FQ,"constructYamlBinary");x($Q,"representYamlBinary");x(zQ,"isBinary");v8e=new Ua("tag:yaml.org,2002:binary",{kind:"scalar",resolve:BQ,construct:FQ,predicate:zQ,represent:$Q}),x8e=Object.prototype.hasOwnProperty,b8e=Object.prototype.toString;x(GQ,"resolveYamlOmap");x(qQ,"constructYamlOmap");w8e=new Ua("tag:yaml.org,2002:omap",{kind:"sequence",resolve:GQ,construct:qQ}),T8e=Object.prototype.toString;x(VQ,"resolveYamlPairs");x(UQ,"constructYamlPairs");k8e=new Ua("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:VQ,construct:UQ}),E8e=Object.prototype.hasOwnProperty;x(WQ,"resolveYamlSet");x(HQ,"constructYamlSet");S8e=new Ua("tag:yaml.org,2002:set",{kind:"mapping",resolve:WQ,construct:HQ}),YQ=g8e.extend({implicit:[m8e,y8e],explicit:[v8e,w8e,k8e,S8e]}),Tf=Object.prototype.hasOwnProperty,Qw=1,XQ=2,jQ=3,Jw=4,KL=1,C8e=2,nQ=3,A8e=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,_8e=/[\x85\u2028\u2029]/,L8e=/[,\[\]\{\}]/,KQ=/^(?:!|!!|![a-z\-]+!)$/i,ZQ=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;x(QL,"_class");x(Xl,"is_EOL");x(wf,"is_WHITE_SPACE");x(vs,"is_WS_OR_EOL");x(Gp,"is_FLOW_INDICATOR");x(QQ,"fromHexCode");x(JQ,"escapedHexLen");x(eJ,"fromDecimalCode");x(JL,"simpleEscapeSequence");x(tJ,"charFromCodepoint");rJ=new Array(256),nJ=new Array(256);for(zp=0;zp<256;zp++)rJ[zp]=JL(zp)?1:0,nJ[zp]=JL(zp);x(iJ,"State$1");x(g9,"generateError");x(Yt,"throwError");x(B2,"throwWarning");iQ={YAML:x(function(e,r,n){var i,a,s;e.version!==null&&Yt(e,"duplication of %YAML directive"),n.length!==1&&Yt(e,"YAML directive accepts exactly one argument"),i=/^([0-9]+)\.([0-9]+)$/.exec(n[0]),i===null&&Yt(e,"ill-formed argument of the YAML directive"),a=parseInt(i[1],10),s=parseInt(i[2],10),a!==1&&Yt(e,"unacceptable YAML version of the document"),e.version=n[0],e.checkLineBreaks=s<2,s!==1&&s!==2&&B2(e,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:x(function(e,r,n){var i,a;n.length!==2&&Yt(e,"TAG directive accepts exactly two arguments"),i=n[0],a=n[1],KQ.test(i)||Yt(e,"ill-formed tag handle (first argument) of the TAG directive"),Tf.call(e.tagMap,i)&&Yt(e,'there is a previously declared suffix for "'+i+'" tag handle'),ZQ.test(a)||Yt(e,"ill-formed tag prefix (second argument) of the TAG directive");try{a=decodeURIComponent(a)}catch{Yt(e,"tag prefix is malformed: "+a)}e.tagMap[i]=a},"handleTagDirective")};x(uh,"captureSegment");x(e9,"mergeMappings");x(qp,"storeMappingPair");x(nT,"readLineBreak");x(Ei,"skipSeparationSpace");x(G2,"testDocumentSeparator");x(iT,"writeFoldedLines");x(aJ,"readPlainScalar");x(sJ,"readSingleQuotedScalar");x(oJ,"readDoubleQuotedScalar");x(lJ,"readFlowCollection");x(cJ,"readBlockScalar");x(t9,"readBlockSequence");x(uJ,"readBlockMapping");x(hJ,"readTagProperty");x(fJ,"readAnchorProperty");x(dJ,"readAlias");x(Vp,"composeNode");x(pJ,"readDocument");x(m9,"loadDocuments");x(gJ,"loadAll$1");x(mJ,"load$1");R8e=gJ,D8e=mJ,yJ={loadAll:R8e,load:D8e},vJ=Object.prototype.toString,xJ=Object.prototype.hasOwnProperty,y9=65279,N8e=9,F2=10,I8e=13,M8e=32,O8e=33,P8e=34,r9=35,B8e=37,F8e=38,$8e=39,z8e=42,bJ=44,G8e=45,eT=58,q8e=61,V8e=62,U8e=63,W8e=64,wJ=91,TJ=93,H8e=96,kJ=123,Y8e=124,EJ=125,Wa={};Wa[0]="\\0";Wa[7]="\\a";Wa[8]="\\b";Wa[9]="\\t";Wa[10]="\\n";Wa[11]="\\v";Wa[12]="\\f";Wa[13]="\\r";Wa[27]="\\e";Wa[34]='\\"';Wa[92]="\\\\";Wa[133]="\\N";Wa[160]="\\_";Wa[8232]="\\L";Wa[8233]="\\P";X8e=["y","Y","yes","Yes","YES","on","On","ON","n","N","no","No","NO","off","Off","OFF"],j8e=/^[-+]?[0-9_]+(?::[0-9_]+)+(?:\.[0-9_]*)?$/;x(SJ,"compileStyleMap");x(CJ,"encodeHex");K8e=1,$2=2;x(AJ,"State");x(n9,"indentString");x(tT,"generateNextLine");x(_J,"testImplicitResolving");x(z2,"isWhitespace");x(pm,"isPrintable");x(i9,"isNsCharOrWhitespace");x(a9,"isPlainSafe");x(LJ,"isPlainSafeFirst");x(RJ,"isPlainSafeLast");x(fm,"codePointAt");x(v9,"needIndentIndicator");DJ=1,s9=2,NJ=3,IJ=4,hm=5;x(MJ,"chooseScalarStyle");x(OJ,"writeScalar");x(o9,"blockHeader");x(l9,"dropEndingNewline");x(PJ,"foldString");x(c9,"foldLine");x(BJ,"escapeString");x(FJ,"writeFlowSequence");x(u9,"writeBlockSequence");x($J,"writeFlowMapping");x(zJ,"writeBlockMapping");x(h9,"detectType");x(Yc,"writeNode");x(GJ,"getDuplicateReferences");x(rT,"inspectNode");x(qJ,"dump$1");Z8e=qJ,Q8e={dump:Z8e};x(aT,"renamed");kf=RQ,Ef=yJ.load,mbt=yJ.loadAll,ybt=Q8e.dump,vbt=aT("safeLoad","load"),xbt=aT("safeLoadAll","loadAll"),bbt=aT("safeDump","dump");});function V2(t,e){if(t===void 0||e===void 0)return{angle:0,deltaX:0,deltaY:0};t=jn(t),e=jn(e);let[r,n]=[t.x,t.y],[i,a]=[e.x,e.y],s=i-r,o=a-n;return{angle:Math.atan(o/s),deltaX:s,deltaY:o}}var Ta,x9,jn,sT,Co=$(()=>{lr();Ta={aggregation:17.25,extension:17.25,composition:17.25,dependency:6,lollipop:13.5,arrow_point:4},x9={arrow_point:9,arrow_cross:12.5,arrow_circle:12.5};x(V2,"calculateDeltaAndAngle");jn=x(t=>Array.isArray(t)?{x:t[0],y:t[1]}:t,"pointTransformer"),sT=x(t=>({x:x(function(e,r,n){let i=0,a=jn(n[0]).x=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(Ta,t.arrowTypeEnd)){let{angle:p,deltaX:g}=V2(n[n.length-1],n[n.length-2]);i=Ta[t.arrowTypeEnd]*Math.cos(p)*(g>=0?1:-1)}let s=Math.abs(jn(e).x-jn(n[n.length-1]).x),o=Math.abs(jn(e).y-jn(n[n.length-1]).y),l=Math.abs(jn(e).x-jn(n[0]).x),u=Math.abs(jn(e).y-jn(n[0]).y),h=Ta[t.arrowTypeStart],f=Ta[t.arrowTypeEnd],d=1;if(s0&&o0&&u=0?1:-1)}else if(r===n.length-1&&Object.hasOwn(Ta,t.arrowTypeEnd)){let{angle:p,deltaY:g}=V2(n[n.length-1],n[n.length-2]);i=Ta[t.arrowTypeEnd]*Math.abs(Math.sin(p))*(g>=0?1:-1)}let s=Math.abs(jn(e).y-jn(n[n.length-1]).y),o=Math.abs(jn(e).x-jn(n[n.length-1]).x),l=Math.abs(jn(e).y-jn(n[0]).y),u=Math.abs(jn(e).x-jn(n[0]).x),h=Ta[t.arrowTypeStart],f=Ta[t.arrowTypeEnd],d=1;if(s0&&o0&&u{lr();hh=x(({flowchart:t})=>{let e=t?.subGraphTitleMargin?.top??0,r=t?.subGraphTitleMargin?.bottom??0,n=e+r;return{subGraphTitleTopMargin:e,subGraphTitleBottomMargin:r,subGraphTitleTotalMargin:n}},"getSubGraphTitleMargins")});var VJ,Up,J8e,U2,Rt,Ft,e_e,bs=$(()=>{Er();lr();VJ=x(t=>{let{handDrawnSeed:e}=Te();return{fill:t,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:t,seed:e}},"solidStateFill"),Up=x(t=>{let e=J8e([...t.cssCompiledStyles||[],...t.cssStyles||[],...t.labelStyle||[]]);return{stylesMap:e,stylesArray:[...e]}},"compileStyles"),J8e=x(t=>{let e=new Map;return t.forEach(r=>{let[n,i]=r.split(":");e.set(n.trim(),i?.trim())}),e},"styles2Map"),U2=x(t=>t==="color"||t==="font-size"||t==="font-family"||t==="font-weight"||t==="font-style"||t==="text-decoration"||t==="text-align"||t==="text-transform"||t==="line-height"||t==="letter-spacing"||t==="word-spacing"||t==="text-shadow"||t==="text-overflow"||t==="white-space"||t==="word-wrap"||t==="word-break"||t==="overflow-wrap"||t==="hyphens","isLabelStyle"),Rt=x(t=>{let{stylesArray:e}=Up(t),r=[],n=[],i=[],a=[];return e.forEach(s=>{let o=s[0];U2(o)?r.push(s.join(":")+" !important"):(n.push(s.join(":")+" !important"),o.includes("stroke")&&i.push(s.join(":")+" !important"),o==="fill"&&a.push(s.join(":")+" !important"))}),{labelStyles:r.join(";"),nodeStyles:n.join(";"),stylesArray:e,borderStyles:i,backgroundStyles:a}},"styles2String"),Ft=x((t,e)=>{let{themeVariables:r,handDrawnSeed:n}=Te(),{nodeBorder:i,mainBkg:a}=r,{stylesMap:s}=Up(t);return Object.assign({roughness:.7,fill:s.get("fill")||a,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:s.get("stroke")||i,seed:n,strokeWidth:s.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0],strokeLineDash:e_e(s.get("stroke-dasharray"))},e)},"userNodeOverrides"),e_e=x(t=>{if(!t)return[0,0];let e=t.trim().split(/\s+/).map(Number);if(e.length===1){let i=isNaN(e[0])?0:e[0];return[i,i]}let r=isNaN(e[0])?0:e[0],n=isNaN(e[1])?0:e[1];return[r,n]},"getStrokeDashArray")});var UJ=Wt(ra=>{"use strict";Object.defineProperty(ra,"__esModule",{value:!0});ra.BLANK_URL=ra.relativeFirstCharacters=ra.whitespaceEscapeCharsRegex=ra.urlSchemeRegex=ra.ctrlCharactersRegex=ra.htmlCtrlEntityRegex=ra.htmlEntitiesRegex=ra.invalidProtocolRegex=void 0;ra.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im;ra.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g;ra.htmlCtrlEntityRegex=/&(newline|tab);/gi;ra.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim;ra.urlSchemeRegex=/^.+(:|:)/gim;ra.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g;ra.relativeFirstCharacters=[".","/"];ra.BLANK_URL="about:blank"});var gm=Wt(oT=>{"use strict";Object.defineProperty(oT,"__esModule",{value:!0});oT.sanitizeUrl=void 0;var Ha=UJ();function t_e(t){return Ha.relativeFirstCharacters.indexOf(t[0])>-1}function r_e(t){var e=t.replace(Ha.ctrlCharactersRegex,"");return e.replace(Ha.htmlEntitiesRegex,function(r,n){return String.fromCharCode(n)})}function n_e(t){return URL.canParse(t)}function WJ(t){try{return decodeURIComponent(t)}catch{return t}}function i_e(t){if(!t)return Ha.BLANK_URL;var e,r=WJ(t.trim());do r=r_e(r).replace(Ha.htmlCtrlEntityRegex,"").replace(Ha.ctrlCharactersRegex,"").replace(Ha.whitespaceEscapeCharsRegex,"").trim(),r=WJ(r),e=r.match(Ha.ctrlCharactersRegex)||r.match(Ha.htmlEntitiesRegex)||r.match(Ha.htmlCtrlEntityRegex)||r.match(Ha.whitespaceEscapeCharsRegex);while(e&&e.length>0);var n=r;if(!n)return Ha.BLANK_URL;if(t_e(n))return n;var i=n.trimStart(),a=i.match(Ha.urlSchemeRegex);if(!a)return n;var s=a[0].toLowerCase().trim();if(Ha.invalidProtocolRegex.test(s))return Ha.BLANK_URL;var o=i.replace(/\\/g,"/");if(s==="mailto:"||s.includes("://"))return o;if(s==="http:"||s==="https:"){if(!n_e(o))return Ha.BLANK_URL;var l=new URL(o);return l.protocol=l.protocol.toLowerCase(),l.hostname=l.hostname.toLowerCase(),l.toString()}return o}oT.sanitizeUrl=i_e});var a_e,lT,b9=$(()=>{a_e=typeof global=="object"&&global&&global.Object===Object&&global,lT=a_e});var s_e,o_e,yi,rl=$(()=>{b9();s_e=typeof self=="object"&&self&&self.Object===Object&&self,o_e=lT||s_e||Function("return this")(),yi=o_e});var l_e,na,Wp=$(()=>{rl();l_e=yi.Symbol,na=l_e});function h_e(t){var e=c_e.call(t,W2),r=t[W2];try{t[W2]=void 0;var n=!0}catch{}var i=u_e.call(t);return n&&(e?t[W2]=r:delete t[W2]),i}var HJ,c_e,u_e,W2,YJ,XJ=$(()=>{Wp();HJ=Object.prototype,c_e=HJ.hasOwnProperty,u_e=HJ.toString,W2=na?na.toStringTag:void 0;YJ=h_e});function p_e(t){return d_e.call(t)}var f_e,d_e,jJ,KJ=$(()=>{f_e=Object.prototype,d_e=f_e.toString;jJ=p_e});function y_e(t){return t==null?t===void 0?m_e:g_e:ZJ&&ZJ in Object(t)?YJ(t):jJ(t)}var g_e,m_e,ZJ,ka,fh=$(()=>{Wp();XJ();KJ();g_e="[object Null]",m_e="[object Undefined]",ZJ=na?na.toStringTag:void 0;ka=y_e});function v_e(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var _n,Ao=$(()=>{_n=v_e});function k_e(t){if(!_n(t))return!1;var e=ka(t);return e==b_e||e==w_e||e==x_e||e==T_e}var x_e,b_e,w_e,T_e,Ni,H2=$(()=>{fh();Ao();x_e="[object AsyncFunction]",b_e="[object Function]",w_e="[object GeneratorFunction]",T_e="[object Proxy]";Ni=k_e});var E_e,cT,QJ=$(()=>{rl();E_e=yi["__core-js_shared__"],cT=E_e});function S_e(t){return!!JJ&&JJ in t}var JJ,eee,tee=$(()=>{QJ();JJ=(function(){var t=/[^.]+$/.exec(cT&&cT.keys&&cT.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""})();eee=S_e});function __e(t){if(t!=null){try{return A_e.call(t)}catch{}try{return t+""}catch{}}return""}var C_e,A_e,dh,w9=$(()=>{C_e=Function.prototype,A_e=C_e.toString;dh=__e});function P_e(t){if(!_n(t)||eee(t))return!1;var e=Ni(t)?O_e:R_e;return e.test(dh(t))}var L_e,R_e,D_e,N_e,I_e,M_e,O_e,ree,nee=$(()=>{H2();tee();Ao();w9();L_e=/[\\^$.*+?()[\]{}|]/g,R_e=/^\[object .+?Constructor\]$/,D_e=Function.prototype,N_e=Object.prototype,I_e=D_e.toString,M_e=N_e.hasOwnProperty,O_e=RegExp("^"+I_e.call(M_e).replace(L_e,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");ree=P_e});function B_e(t,e){return t?.[e]}var iee,aee=$(()=>{iee=B_e});function F_e(t,e){var r=iee(t,e);return ree(r)?r:void 0}var Ys,Sf=$(()=>{nee();aee();Ys=F_e});var $_e,ph,Y2=$(()=>{Sf();$_e=Ys(Object,"create"),ph=$_e});function z_e(){this.__data__=ph?ph(null):{},this.size=0}var see,oee=$(()=>{Y2();see=z_e});function G_e(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var lee,cee=$(()=>{lee=G_e});function W_e(t){var e=this.__data__;if(ph){var r=e[t];return r===q_e?void 0:r}return U_e.call(e,t)?e[t]:void 0}var q_e,V_e,U_e,uee,hee=$(()=>{Y2();q_e="__lodash_hash_undefined__",V_e=Object.prototype,U_e=V_e.hasOwnProperty;uee=W_e});function X_e(t){var e=this.__data__;return ph?e[t]!==void 0:Y_e.call(e,t)}var H_e,Y_e,fee,dee=$(()=>{Y2();H_e=Object.prototype,Y_e=H_e.hasOwnProperty;fee=X_e});function K_e(t,e){var r=this.__data__;return this.size+=this.has(t)?0:1,r[t]=ph&&e===void 0?j_e:e,this}var j_e,pee,gee=$(()=>{Y2();j_e="__lodash_hash_undefined__";pee=K_e});function mm(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{oee();cee();hee();dee();gee();mm.prototype.clear=see;mm.prototype.delete=lee;mm.prototype.get=uee;mm.prototype.has=fee;mm.prototype.set=pee;T9=mm});function Z_e(){this.__data__=[],this.size=0}var yee,vee=$(()=>{yee=Z_e});function Q_e(t,e){return t===e||t!==t&&e!==e}var nl,Hp=$(()=>{nl=Q_e});function J_e(t,e){for(var r=t.length;r--;)if(nl(t[r][0],e))return r;return-1}var Cf,X2=$(()=>{Hp();Cf=J_e});function rLe(t){var e=this.__data__,r=Cf(e,t);if(r<0)return!1;var n=e.length-1;return r==n?e.pop():tLe.call(e,r,1),--this.size,!0}var eLe,tLe,xee,bee=$(()=>{X2();eLe=Array.prototype,tLe=eLe.splice;xee=rLe});function nLe(t){var e=this.__data__,r=Cf(e,t);return r<0?void 0:e[r][1]}var wee,Tee=$(()=>{X2();wee=nLe});function iLe(t){return Cf(this.__data__,t)>-1}var kee,Eee=$(()=>{X2();kee=iLe});function aLe(t,e){var r=this.__data__,n=Cf(r,t);return n<0?(++this.size,r.push([t,e])):r[n][1]=e,this}var See,Cee=$(()=>{X2();See=aLe});function ym(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{vee();bee();Tee();Eee();Cee();ym.prototype.clear=yee;ym.prototype.delete=xee;ym.prototype.get=wee;ym.prototype.has=kee;ym.prototype.set=See;Af=ym});var sLe,_f,uT=$(()=>{Sf();rl();sLe=Ys(yi,"Map"),_f=sLe});function oLe(){this.size=0,this.__data__={hash:new T9,map:new(_f||Af),string:new T9}}var Aee,_ee=$(()=>{mee();j2();uT();Aee=oLe});function lLe(t){var e=typeof t;return e=="string"||e=="number"||e=="symbol"||e=="boolean"?t!=="__proto__":t===null}var Lee,Ree=$(()=>{Lee=lLe});function cLe(t,e){var r=t.__data__;return Lee(e)?r[typeof e=="string"?"string":"hash"]:r.map}var Lf,K2=$(()=>{Ree();Lf=cLe});function uLe(t){var e=Lf(this,t).delete(t);return this.size-=e?1:0,e}var Dee,Nee=$(()=>{K2();Dee=uLe});function hLe(t){return Lf(this,t).get(t)}var Iee,Mee=$(()=>{K2();Iee=hLe});function fLe(t){return Lf(this,t).has(t)}var Oee,Pee=$(()=>{K2();Oee=fLe});function dLe(t,e){var r=Lf(this,t),n=r.size;return r.set(t,e),this.size+=r.size==n?0:1,this}var Bee,Fee=$(()=>{K2();Bee=dLe});function vm(t){var e=-1,r=t==null?0:t.length;for(this.clear();++e{_ee();Nee();Mee();Pee();Fee();vm.prototype.clear=Aee;vm.prototype.delete=Dee;vm.prototype.get=Iee;vm.prototype.has=Oee;vm.prototype.set=Bee;Yp=vm});function k9(t,e){if(typeof t!="function"||e!=null&&typeof e!="function")throw new TypeError(pLe);var r=function(){var n=arguments,i=e?e.apply(this,n):n[0],a=r.cache;if(a.has(i))return a.get(i);var s=t.apply(this,n);return r.cache=a.set(i,s)||a,s};return r.cache=new(k9.Cache||Yp),r}var pLe,xm,E9=$(()=>{hT();pLe="Expected a function";k9.Cache=Yp;xm=k9});function gLe(){this.__data__=new Af,this.size=0}var $ee,zee=$(()=>{j2();$ee=gLe});function mLe(t){var e=this.__data__,r=e.delete(t);return this.size=e.size,r}var Gee,qee=$(()=>{Gee=mLe});function yLe(t){return this.__data__.get(t)}var Vee,Uee=$(()=>{Vee=yLe});function vLe(t){return this.__data__.has(t)}var Wee,Hee=$(()=>{Wee=vLe});function bLe(t,e){var r=this.__data__;if(r instanceof Af){var n=r.__data__;if(!_f||n.length{j2();uT();hT();xLe=200;Yee=bLe});function bm(t){var e=this.__data__=new Af(t);this.size=e.size}var Xc,Z2=$(()=>{j2();zee();qee();Uee();Hee();Xee();bm.prototype.clear=$ee;bm.prototype.delete=Gee;bm.prototype.get=Vee;bm.prototype.has=Wee;bm.prototype.set=Yee;Xc=bm});var wLe,wm,S9=$(()=>{Sf();wLe=(function(){try{var t=Ys(Object,"defineProperty");return t({},"",{}),t}catch{}})(),wm=wLe});function TLe(t,e,r){e=="__proto__"&&wm?wm(t,e,{configurable:!0,enumerable:!0,value:r,writable:!0}):t[e]=r}var jc,Tm=$(()=>{S9();jc=TLe});function kLe(t,e,r){(r!==void 0&&!nl(t[e],r)||r===void 0&&!(e in t))&&jc(t,e,r)}var Q2,C9=$(()=>{Tm();Hp();Q2=kLe});function ELe(t){return function(e,r,n){for(var i=-1,a=Object(e),s=n(e),o=s.length;o--;){var l=s[t?o:++i];if(r(a[l],l,a)===!1)break}return e}}var jee,Kee=$(()=>{jee=ELe});var SLe,km,fT=$(()=>{Kee();SLe=jee(),km=SLe});function ALe(t,e){if(e)return t.slice();var r=t.length,n=Jee?Jee(r):new t.constructor(r);return t.copy(n),n}var ete,Zee,CLe,Qee,Jee,dT,A9=$(()=>{rl();ete=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Zee=ete&&typeof module=="object"&&module&&!module.nodeType&&module,CLe=Zee&&Zee.exports===ete,Qee=CLe?yi.Buffer:void 0,Jee=Qee?Qee.allocUnsafe:void 0;dT=ALe});var _Le,Em,_9=$(()=>{rl();_Le=yi.Uint8Array,Em=_Le});function LLe(t){var e=new t.constructor(t.byteLength);return new Em(e).set(new Em(t)),e}var Sm,pT=$(()=>{_9();Sm=LLe});function RLe(t,e){var r=e?Sm(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.length)}var gT,L9=$(()=>{pT();gT=RLe});function DLe(t,e){var r=-1,n=t.length;for(e||(e=Array(n));++r{mT=DLe});var tte,NLe,rte,nte=$(()=>{Ao();tte=Object.create,NLe=(function(){function t(){}return function(e){if(!_n(e))return{};if(tte)return tte(e);t.prototype=e;var r=new t;return t.prototype=void 0,r}})(),rte=NLe});function ILe(t,e){return function(r){return t(e(r))}}var yT,D9=$(()=>{yT=ILe});var MLe,Cm,vT=$(()=>{D9();MLe=yT(Object.getPrototypeOf,Object),Cm=MLe});function PLe(t){var e=t&&t.constructor,r=typeof e=="function"&&e.prototype||OLe;return t===r}var OLe,Kc,Am=$(()=>{OLe=Object.prototype;Kc=PLe});function BLe(t){return typeof t.constructor=="function"&&!Kc(t)?rte(Cm(t)):{}}var xT,N9=$(()=>{nte();vT();Am();xT=BLe});function FLe(t){return t!=null&&typeof t=="object"}var ci,il=$(()=>{ci=FLe});function zLe(t){return ci(t)&&ka(t)==$Le}var $Le,I9,ite=$(()=>{fh();il();$Le="[object Arguments]";I9=zLe});var ate,GLe,qLe,VLe,jl,_m=$(()=>{ite();il();ate=Object.prototype,GLe=ate.hasOwnProperty,qLe=ate.propertyIsEnumerable,VLe=I9((function(){return arguments})())?I9:function(t){return ci(t)&&GLe.call(t,"callee")&&!qLe.call(t,"callee")},jl=VLe});var ULe,Mt,Kn=$(()=>{ULe=Array.isArray,Mt=ULe});function HLe(t){return typeof t=="number"&&t>-1&&t%1==0&&t<=WLe}var WLe,Lm,bT=$(()=>{WLe=9007199254740991;Lm=HLe});function YLe(t){return t!=null&&Lm(t.length)&&!Ni(t)}var xi,al=$(()=>{H2();bT();xi=YLe});function XLe(t){return ci(t)&&xi(t)}var Xp,wT=$(()=>{al();il();Xp=XLe});function jLe(){return!1}var ste,ote=$(()=>{ste=jLe});var ute,lte,KLe,cte,ZLe,QLe,Kl,Rm=$(()=>{rl();ote();ute=typeof exports=="object"&&exports&&!exports.nodeType&&exports,lte=ute&&typeof module=="object"&&module&&!module.nodeType&&module,KLe=lte&<e.exports===ute,cte=KLe?yi.Buffer:void 0,ZLe=cte?cte.isBuffer:void 0,QLe=ZLe||ste,Kl=QLe});function i9e(t){if(!ci(t)||ka(t)!=JLe)return!1;var e=Cm(t);if(e===null)return!0;var r=r9e.call(e,"constructor")&&e.constructor;return typeof r=="function"&&r instanceof r&&hte.call(r)==n9e}var JLe,e9e,t9e,hte,r9e,n9e,fte,dte=$(()=>{fh();vT();il();JLe="[object Object]",e9e=Function.prototype,t9e=Object.prototype,hte=e9e.toString,r9e=t9e.hasOwnProperty,n9e=hte.call(Object);fte=i9e});function L9e(t){return ci(t)&&Lm(t.length)&&!!Vn[ka(t)]}var a9e,s9e,o9e,l9e,c9e,u9e,h9e,f9e,d9e,p9e,g9e,m9e,y9e,v9e,x9e,b9e,w9e,T9e,k9e,E9e,S9e,C9e,A9e,_9e,Vn,pte,gte=$(()=>{fh();bT();il();a9e="[object Arguments]",s9e="[object Array]",o9e="[object Boolean]",l9e="[object Date]",c9e="[object Error]",u9e="[object Function]",h9e="[object Map]",f9e="[object Number]",d9e="[object Object]",p9e="[object RegExp]",g9e="[object Set]",m9e="[object String]",y9e="[object WeakMap]",v9e="[object ArrayBuffer]",x9e="[object DataView]",b9e="[object Float32Array]",w9e="[object Float64Array]",T9e="[object Int8Array]",k9e="[object Int16Array]",E9e="[object Int32Array]",S9e="[object Uint8Array]",C9e="[object Uint8ClampedArray]",A9e="[object Uint16Array]",_9e="[object Uint32Array]",Vn={};Vn[b9e]=Vn[w9e]=Vn[T9e]=Vn[k9e]=Vn[E9e]=Vn[S9e]=Vn[C9e]=Vn[A9e]=Vn[_9e]=!0;Vn[a9e]=Vn[s9e]=Vn[v9e]=Vn[o9e]=Vn[x9e]=Vn[l9e]=Vn[c9e]=Vn[u9e]=Vn[h9e]=Vn[f9e]=Vn[d9e]=Vn[p9e]=Vn[g9e]=Vn[m9e]=Vn[y9e]=!1;pte=L9e});function R9e(t){return function(e){return t(e)}}var sl,jp=$(()=>{sl=R9e});var mte,J2,D9e,M9,N9e,ol,ex=$(()=>{b9();mte=typeof exports=="object"&&exports&&!exports.nodeType&&exports,J2=mte&&typeof module=="object"&&module&&!module.nodeType&&module,D9e=J2&&J2.exports===mte,M9=D9e&&lT.process,N9e=(function(){try{var t=J2&&J2.require&&J2.require("util").types;return t||M9&&M9.binding&&M9.binding("util")}catch{}})(),ol=N9e});var yte,I9e,Rf,tx=$(()=>{gte();jp();ex();yte=ol&&ol.isTypedArray,I9e=yte?sl(yte):pte,Rf=I9e});function M9e(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var rx,O9=$(()=>{rx=M9e});function B9e(t,e,r){var n=t[e];(!(P9e.call(t,e)&&nl(n,r))||r===void 0&&!(e in t))&&jc(t,e,r)}var O9e,P9e,Zc,Dm=$(()=>{Tm();Hp();O9e=Object.prototype,P9e=O9e.hasOwnProperty;Zc=B9e});function F9e(t,e,r,n){var i=!r;r||(r={});for(var a=-1,s=e.length;++a{Dm();Tm();ll=F9e});function $9e(t,e){for(var r=-1,n=Array(t);++r{vte=$9e});function q9e(t,e){var r=typeof t;return e=e??z9e,!!e&&(r=="number"||r!="symbol"&&G9e.test(t))&&t>-1&&t%1==0&&t{z9e=9007199254740991,G9e=/^(?:0|[1-9]\d*)$/;Df=q9e});function W9e(t,e){var r=Mt(t),n=!r&&jl(t),i=!r&&!n&&Kl(t),a=!r&&!n&&!i&&Rf(t),s=r||n||i||a,o=s?vte(t.length,String):[],l=o.length;for(var u in t)(e||U9e.call(t,u))&&!(s&&(u=="length"||i&&(u=="offset"||u=="parent")||a&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||Df(u,l)))&&o.push(u);return o}var V9e,U9e,TT,P9=$(()=>{xte();_m();Kn();Rm();nx();tx();V9e=Object.prototype,U9e=V9e.hasOwnProperty;TT=W9e});function H9e(t){var e=[];if(t!=null)for(var r in Object(t))e.push(r);return e}var bte,wte=$(()=>{bte=H9e});function j9e(t){if(!_n(t))return bte(t);var e=Kc(t),r=[];for(var n in t)n=="constructor"&&(e||!X9e.call(t,n))||r.push(n);return r}var Y9e,X9e,Tte,kte=$(()=>{Ao();Am();wte();Y9e=Object.prototype,X9e=Y9e.hasOwnProperty;Tte=j9e});function K9e(t){return xi(t)?TT(t,!0):Tte(t)}var Xs,Nf=$(()=>{P9();kte();al();Xs=K9e});function Z9e(t){return ll(t,Xs(t))}var Ete,Ste=$(()=>{Kp();Nf();Ete=Z9e});function Q9e(t,e,r,n,i,a,s){var o=rx(t,r),l=rx(e,r),u=s.get(l);if(u){Q2(t,r,u);return}var h=a?a(o,l,r+"",t,e,s):void 0,f=h===void 0;if(f){var d=Mt(l),p=!d&&Kl(l),g=!d&&!p&&Rf(l);h=l,d||p||g?Mt(o)?h=o:Xp(o)?h=mT(o):p?(f=!1,h=dT(l,!0)):g?(f=!1,h=gT(l,!0)):h=[]:fte(l)||jl(l)?(h=o,jl(o)?h=Ete(o):(!_n(o)||Ni(o))&&(h=xT(l))):f=!1}f&&(s.set(l,h),i(h,l,n,a,s),s.delete(l)),Q2(t,r,h)}var Cte,Ate=$(()=>{C9();A9();L9();R9();N9();_m();Kn();wT();Rm();H2();Ao();dte();tx();O9();Ste();Cte=Q9e});function _te(t,e,r,n,i){t!==e&&km(e,function(a,s){if(i||(i=new Xc),_n(a))Cte(t,e,s,r,_te,n,i);else{var o=n?n(rx(t,s),a,s+"",t,e,i):void 0;o===void 0&&(o=a),Q2(t,s,o)}},Xs)}var Lte,Rte=$(()=>{Z2();C9();fT();Ate();Ao();Nf();O9();Lte=_te});function J9e(t){return t}var ia,gh=$(()=>{ia=J9e});function eRe(t,e,r){switch(r.length){case 0:return t.call(e);case 1:return t.call(e,r[0]);case 2:return t.call(e,r[0],r[1]);case 3:return t.call(e,r[0],r[1],r[2])}return t.apply(e,r)}var Dte,Nte=$(()=>{Dte=eRe});function tRe(t,e,r){return e=Ite(e===void 0?t.length-1:e,0),function(){for(var n=arguments,i=-1,a=Ite(n.length-e,0),s=Array(a);++i{Nte();Ite=Math.max;kT=tRe});function rRe(t){return function(){return t}}var js,F9=$(()=>{js=rRe});var nRe,Mte,Ote=$(()=>{F9();S9();gh();nRe=wm?function(t,e){return wm(t,"toString",{configurable:!0,enumerable:!1,value:js(e),writable:!0})}:ia,Mte=nRe});function oRe(t){var e=0,r=0;return function(){var n=sRe(),i=aRe-(n-r);if(r=n,i>0){if(++e>=iRe)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var iRe,aRe,sRe,Pte,Bte=$(()=>{iRe=800,aRe=16,sRe=Date.now;Pte=oRe});var lRe,ET,$9=$(()=>{Ote();Bte();lRe=Pte(Mte),ET=lRe});function cRe(t,e){return ET(kT(t,e,ia),t+"")}var Qc,Nm=$(()=>{gh();B9();$9();Qc=cRe});function uRe(t,e,r){if(!_n(r))return!1;var n=typeof e;return(n=="number"?xi(r)&&Df(e,r.length):n=="string"&&e in r)?nl(r[e],t):!1}var _o,Zp=$(()=>{Hp();al();nx();Ao();_o=uRe});function hRe(t){return Qc(function(e,r){var n=-1,i=r.length,a=i>1?r[i-1]:void 0,s=i>2?r[2]:void 0;for(a=t.length>3&&typeof a=="function"?(i--,a):void 0,s&&_o(r[0],r[1],s)&&(a=i<3?void 0:a,i=1),e=Object(e);++n{Nm();Zp();ST=hRe});var fRe,If,G9=$(()=>{Rte();z9();fRe=ST(function(t,e,r){Lte(t,e,r)}),If=fRe});function AT(t,e){if(!t)return e;let r=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return dRe[r]??e}function Vte(t,e){let r=t.trim();if(r)return e.securityLevel!=="loose"?(0,zte.sanitizeUrl)(r):r}function V9(t,e){return!t||!e?0:Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function Ute(t){let e,r=0;t.forEach(i=>{r+=V9(i,e),e=i});let n=r/2;return U9(t,n)}function Wte(t){return t.length===1?t[0]:Ute(t)}function Hte(t,e,r){let n=structuredClone(r);te.info("our points",n),e!=="start_left"&&e!=="start_right"&&n.reverse();let i=25+t,a=U9(n,i),s=10+t*.5,o=Math.atan2(n[0].y-a.y,n[0].x-a.x),l={x:0,y:0};return e==="start_left"?(l.x=Math.sin(o+Math.PI)*s+(n[0].x+a.x)/2,l.y=-Math.cos(o+Math.PI)*s+(n[0].y+a.y)/2):e==="end_right"?(l.x=Math.sin(o-Math.PI)*s+(n[0].x+a.x)/2-5,l.y=-Math.cos(o-Math.PI)*s+(n[0].y+a.y)/2-5):e==="end_left"?(l.x=Math.sin(o)*s+(n[0].x+a.x)/2-5,l.y=-Math.cos(o)*s+(n[0].y+a.y)/2-5):(l.x=Math.sin(o)*s+(n[0].x+a.x)/2,l.y=-Math.cos(o)*s+(n[0].y+a.y)/2),l}function _T(t){let e="",r="";for(let n of t)n!==void 0&&(n.startsWith("color:")||n.startsWith("text-align:")?r=r+n+";":e=e+n+";");return{style:e,labelStyle:r}}function Yte(t){let e="",r="0123456789abcdef",n=r.length;for(let i=0;iMath.round(parseFloat(a)).toString());return i.includes(r.toString())||i.includes(n.toString())}var zte,q9,dRe,pRe,gRe,Gte,qte,mRe,yRe,Fte,U9,vRe,$te,W9,H9,xRe,bRe,Y9,wRe,X9,TRe,CT,kRe,ERe,Jc,Ut,Xte,Ks,eu,bn=$(()=>{Er();lr();zte=ma(gm(),1);pr();E9();G9();q9="\u200B",dRe={curveBasis:Yl,curveBasisClosed:PL,curveBasisOpen:BL,curveBumpX:T2,curveBumpY:k2,curveBundle:FL,curveCardinalClosed:$L,curveCardinalOpen:GL,curveCardinal:A2,curveCatmullRomClosed:VL,curveCatmullRomOpen:UL,curveCatmullRom:R2,curveLinear:xf,curveLinearClosed:WL,curveMonotoneX:D2,curveMonotoneY:N2,curveNatural:I2,curveStep:M2,curveStepAfter:P2,curveStepBefore:O2},pRe=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,gRe=x(function(t,e){let r=Gte(t,/(?:init\b)|(?:initialize\b)/),n={};if(Array.isArray(r)){let s=r.map(o=>o.args);zv(s),n=Gn(n,[...s])}else n=r.args;if(!n)return;let i=Gv(t,e),a="config";return n[a]!==void 0&&(i==="flowchart-v2"&&(i="flowchart"),n[i]=n[a],delete n[a]),n},"detectInit"),Gte=x(function(t,e=null){try{let r=new RegExp(`[%]{2}(?![{]${pRe.source})(?=[}][%]{2}).* `,"ig");t=t.trim().replace(r,"").replace(/'/gm,'"'),te.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let n,i=[];for(;(n=Gg.exec(t))!==null;)if(n.index===Gg.lastIndex&&Gg.lastIndex++,n&&!e||e&&n[1]?.match(e)||e&&n[2]?.match(e)){let a=n[1]?n[1]:n[2],s=n[3]?n[3].trim():n[4]?JSON.parse(n[4].trim()):null;i.push({type:a,args:s})}return i.length===0?{type:t,args:null}:i.length===1?i[0]:i}catch(r){return te.error(`ERROR: ${r.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},"detectDirective"),qte=x(function(t){return t.replace(Gg,"")},"removeDirectives"),mRe=x(function(t,e){for(let[r,n]of e.entries())if(n.match(t))return r;return-1},"isSubstringInArray");x(AT,"interpolateToCurve");x(Vte,"formatUrl");yRe=x((t,...e)=>{let r=t.split("."),n=r.length-1,i=r[n],a=window;for(let s=0;s{let r=Math.pow(10,e);return Math.round(t*r)/r},"roundNumber"),U9=x((t,e)=>{let r,n=e;for(let i of t){if(r){let a=V9(i,r);if(a===0)return r;if(a=1)return{x:i.x,y:i.y};if(s>0&&s<1)return{x:Fte((1-s)*r.x+s*i.x,5),y:Fte((1-s)*r.y+s*i.y,5)}}}r=i}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),vRe=x((t,e,r)=>{te.info(`our points ${JSON.stringify(e)}`),e[0]!==r&&(e=e.reverse());let i=U9(e,25),a=t?10:5,s=Math.atan2(e[0].y-i.y,e[0].x-i.x),o={x:0,y:0};return o.x=Math.sin(s)*a+(e[0].x+i.x)/2,o.y=-Math.cos(s)*a+(e[0].y+i.y)/2,o},"calcCardinalityPosition");x(Hte,"calcTerminalLabelPosition");x(_T,"getStylesFromArray");$te=0,W9=x(()=>($te++,"id-"+Math.random().toString(36).substr(2,12)+"-"+$te),"generateId");x(Yte,"makeRandomHex");H9=x(t=>Yte(t.length),"random"),xRe=x(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),bRe=x(function(t,e){let r=e.text.replace(tt.lineBreakRegex," "),[,n]=Jc(e.fontSize),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.style("font-family",e.fontFamily),i.style("font-size",n),i.style("font-weight",e.fontWeight),i.attr("fill",e.fill),e.class!==void 0&&i.attr("class",e.class);let a=i.append("tspan");return a.attr("x",e.x+e.textMargin*2),a.attr("fill",e.fill),a.text(r),i},"drawSimpleText"),Y9=xm((t,e,r)=>{if(!t||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
"},r),tt.lineBreakRegex.test(t)))return t;let n=t.split(" ").filter(Boolean),i=[],a="";return n.forEach((s,o)=>{let l=Ea(`${s} `,r),u=Ea(a,r);if(l>e){let{hyphenatedStrings:d,remainingWord:p}=wRe(s,e,"-",r);i.push(a,...d),a=p}else u+l>=e?(i.push(a),a=s):a=[a,s].filter(Boolean).join(" ");o+1===n.length&&i.push(a)}),i.filter(s=>s!=="").join(r.joinWith)},(t,e,r)=>`${t}${e}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),wRe=xm((t,e,r="-",n)=>{n=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},n);let i=[...t],a=[],s="";return i.forEach((o,l)=>{let u=`${s}${o}`;if(Ea(u,n)>=e){let f=l+1,d=i.length===f,p=`${u}${r}`;a.push(d?u:p),s=""}else s=u}),{hyphenatedStrings:a,remainingWord:s}},(t,e,r="-",n)=>`${t}${e}${r}${n.fontSize}${n.fontWeight}${n.fontFamily}`);x(ix,"calculateTextHeight");x(Ea,"calculateTextWidth");X9=xm((t,e)=>{let{fontSize:r=12,fontFamily:n="Arial",fontWeight:i=400}=e;if(!t)return{width:0,height:0};let[,a]=Jc(r),s=["sans-serif",n],o=t.split(tt.lineBreakRegex),l=[],u=Ye("body");if(!u.remove)return{width:0,height:0,lineHeight:0};let h=u.append("svg");for(let d of s){let p=0,g={width:0,height:0,lineHeight:0};for(let m of o){let y=xRe();y.text=m||q9;let v=bRe(h,y).style("font-size",a).style("font-weight",i).style("font-family",d),b=(v._groups||v)[0][0].getBBox();if(b.width===0&&b.height===0)throw new Error("svg element not in render tree");g.width=Math.round(Math.max(g.width,b.width)),p=Math.round(b.height),g.height+=p,g.lineHeight=Math.round(Math.max(g.lineHeight,p))}l.push(g)}h.remove();let f=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[f]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`),TRe=class{constructor(t=!1,e){this.count=0,this.count=e?e.length:0,this.next=t?()=>this.count++:()=>Date.now()}static{x(this,"InitIDGenerator")}},kRe=x(function(t){return CT=CT||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),CT.innerHTML=t,unescape(CT.textContent)},"entityDecode");x(LT,"isDetailedError");ERe=x((t,e,r,n)=>{if(!n)return;let i=t.node()?.getBBox();i&&t.append("text").text(n).attr("text-anchor","middle").attr("x",i.x+i.width/2).attr("y",-r).attr("class",e)},"insertTitle"),Jc=x(t=>{if(typeof t=="number")return[t,t+"px"];let e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]},"parseFontSize");x(ui,"cleanAndMerge");Ut={assignWithDepth:Gn,wrapLabel:Y9,calculateTextHeight:ix,calculateTextWidth:Ea,calculateTextDimensions:X9,cleanAndMerge:ui,detectInit:gRe,detectDirective:Gte,isSubstringInArray:mRe,interpolateToCurve:AT,calcLabelPosition:Wte,calcCardinalityPosition:vRe,calcTerminalLabelPosition:Hte,formatUrl:Vte,getStylesFromArray:_T,generateId:W9,random:H9,runFunc:yRe,entityDecode:kRe,insertTitle:ERe,isLabelCoordinateInPath:jte,parseFontSize:Jc,InitIDGenerator:TRe},Xte=x(function(t){let e=t;return e=e.replace(/style.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),e=e.replace(/classDef.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),e=e.replace(/#\w+;/g,function(r){let n=r.substring(1,r.length-1);return/^\+?\d+$/.test(n)?"\uFB02\xB0\xB0"+n+"\xB6\xDF":"\uFB02\xB0"+n+"\xB6\xDF"}),e},"encodeEntities"),Ks=x(function(t){return t.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities"),eu=x((t,e,{counter:r=0,prefix:n,suffix:i},a)=>a||`${n?`${n}_`:""}${t}_${e}_${r}${i?`_${i}`:""}`,"getEdgeId");x(Sa,"handleUndefinedAttr");x(jte,"isLabelCoordinateInPath")});var SRe,Im,j9,Kte,RT=$(()=>{SRe=Object.freeze({left:0,top:0,width:16,height:16}),Im=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),j9=Object.freeze({...SRe,...Im}),Kte=Object.freeze({...j9,body:"",hidden:!1})});var CRe,Zte,Qte=$(()=>{RT();CRe=Object.freeze({width:null,height:null}),Zte=Object.freeze({...CRe,...Im})});var K9,DT,Jte=$(()=>{K9=(t,e,r,n="")=>{let i=t.split(":");if(t.slice(0,1)==="@"){if(i.length<2||i.length>3)return null;n=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){let o=i.pop(),l=i.pop(),u={provider:i.length>0?i[0]:n,prefix:l,name:o};return e&&!DT(u)?null:u}let a=i[0],s=a.split("-");if(s.length>1){let o={provider:n,prefix:s.shift(),name:s.join("-")};return e&&!DT(o)?null:o}if(r&&n===""){let o={provider:n,prefix:"",name:a};return e&&!DT(o,r)?null:o}return null},DT=(t,e)=>t?!!((e&&t.prefix===""||t.prefix)&&t.name):!1});function ere(t,e){let r={};!t.hFlip!=!e.hFlip&&(r.hFlip=!0),!t.vFlip!=!e.vFlip&&(r.vFlip=!0);let n=((t.rotate||0)+(e.rotate||0))%4;return n&&(r.rotate=n),r}var tre=$(()=>{});function Z9(t,e){let r=ere(t,e);for(let n in Kte)n in Im?n in t&&!(n in r)&&(r[n]=Im[n]):n in e?r[n]=e[n]:n in t&&(r[n]=t[n]);return r}var rre=$(()=>{RT();tre()});function nre(t,e){let r=t.icons,n=t.aliases||Object.create(null),i=Object.create(null);function a(s){if(r[s])return i[s]=[];if(!(s in i)){i[s]=null;let o=n[s]&&n[s].parent,l=o&&a(o);l&&(i[s]=[o].concat(l))}return i[s]}return(e||Object.keys(r).concat(Object.keys(n))).forEach(a),i}var ire=$(()=>{});function are(t,e,r){let n=t.icons,i=t.aliases||Object.create(null),a={};function s(o){a=Z9(n[o]||i[o],a)}return s(e),r.forEach(s),Z9(t,a)}function Q9(t,e){if(t.icons[e])return are(t,e,[]);let r=nre(t,[e])[e];return r?are(t,e,r):null}var sre=$(()=>{rre();ire()});function J9(t,e,r){if(e===1)return t;if(r=r||100,typeof t=="number")return Math.ceil(t*e*r)/r;if(typeof t!="string")return t;let n=t.split(ARe);if(n===null||!n.length)return t;let i=[],a=n.shift(),s=_Re.test(a);for(;;){if(s){let o=parseFloat(a);isNaN(o)?i.push(a):i.push(Math.ceil(o*e*r)/r)}else i.push(a);if(a=n.shift(),a===void 0)return i.join("");s=!s}}var ARe,_Re,ore=$(()=>{ARe=/(-?[0-9.]*[0-9]+[0-9.]*)/g,_Re=/^-?[0-9.]*[0-9]+[0-9.]*$/g});function LRe(t,e="defs"){let r="",n=t.indexOf("<"+e);for(;n>=0;){let i=t.indexOf(">",n),a=t.indexOf("",a);if(s===-1)break;r+=t.slice(i+1,a).trim(),t=t.slice(0,n).trim()+t.slice(s+1)}return{defs:r,content:t}}function RRe(t,e){return t?""+t+""+e:e}function lre(t,e,r){let n=LRe(t);return RRe(n.defs,e+n.content+r)}var cre=$(()=>{});function eR(t,e){let r={...j9,...t},n={...Zte,...e},i={left:r.left,top:r.top,width:r.width,height:r.height},a=r.body;[r,n].forEach(m=>{let y=[],v=m.hFlip,b=m.vFlip,w=m.rotate;v?b?w+=2:(y.push("translate("+(i.width+i.left).toString()+" "+(0-i.top).toString()+")"),y.push("scale(-1 1)"),i.top=i.left=0):b&&(y.push("translate("+(0-i.left).toString()+" "+(i.height+i.top).toString()+")"),y.push("scale(1 -1)"),i.top=i.left=0);let S;switch(w<0&&(w-=Math.floor(w/4)*4),w=w%4,w){case 1:S=i.height/2+i.top,y.unshift("rotate(90 "+S.toString()+" "+S.toString()+")");break;case 2:y.unshift("rotate(180 "+(i.width/2+i.left).toString()+" "+(i.height/2+i.top).toString()+")");break;case 3:S=i.width/2+i.left,y.unshift("rotate(-90 "+S.toString()+" "+S.toString()+")");break}w%2===1&&(i.left!==i.top&&(S=i.left,i.left=i.top,i.top=S),i.width!==i.height&&(S=i.width,i.width=i.height,i.height=S)),y.length&&(a=lre(a,'',""))});let s=n.width,o=n.height,l=i.width,u=i.height,h,f;s===null?(f=o===null?"1em":o==="auto"?u:o,h=J9(f,l/u)):(h=s==="auto"?l:s,f=o===null?J9(h,u/l):o==="auto"?u:o);let d={},p=(m,y)=>{DRe(y)||(d[m]=y.toString())};p("width",h),p("height",f);let g=[i.left,i.top,l,u];return d.viewBox=g.join(" "),{attributes:d,viewBox:g,body:a}}var DRe,ure=$(()=>{RT();Qte();ore();cre();DRe=t=>t==="unset"||t==="undefined"||t==="none"});function tR(t,e=IRe){let r=[],n;for(;n=NRe.exec(t);)r.push(n[1]);if(!r.length)return t;let i="suffix"+(Math.random()*16777216|Date.now()).toString(16);return r.forEach(a=>{let s=typeof e=="function"?e(a):e+(MRe++).toString(),o=a.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");t=t.replace(new RegExp('([#;"])('+o+')([")]|\\.[a-z])',"g"),"$1"+s+i+"$3")}),t=t.replace(new RegExp(i,"g"),""),t}var NRe,IRe,MRe,hre=$(()=>{NRe=/\sid="(\S+)"/g,IRe="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16),MRe=0});function rR(t,e){let r=t.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(let n in e)r+=" "+n+'="'+e[n]+'"';return'"+t+""}var fre=$(()=>{});var dre=$(()=>{Jte();sre();ure();hre();fre()});function sR(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}function bre(t){Jp=t}function an(t,e=""){let r=typeof t=="string"?t:t.source,n={replace:(i,a)=>{let s=typeof a=="string"?a:a.source;return s=s.replace(ws.caret,"$1"),r=r.replace(i,s),n},getRegex:()=>new RegExp(r,e)};return n}function tu(t,e){if(e){if(ws.escapeTest.test(t))return t.replace(ws.escapeReplace,mre)}else if(ws.escapeTestNoEncode.test(t))return t.replace(ws.escapeReplaceNoEncode,mre);return t}function yre(t){try{t=encodeURI(t).replace(ws.percentDecode,"%")}catch{return null}return t}function vre(t,e){let r=t.replace(ws.findPipe,(a,s,o)=>{let l=!1,u=s;for(;--u>=0&&o[u]==="\\";)l=!l;return l?"|":" |"}),n=r.split(ws.splitPipe),i=0;if(n[0].trim()||n.shift(),n.length>0&&!n.at(-1)?.trim()&&n.pop(),e)if(n.length>e)n.splice(e);else for(;n.length0?-2:-1}function xre(t,e,r,n,i){let a=e.href,s=e.title||null,o=t[1].replace(i.other.outputLinkReplace,"$1");n.state.inLink=!0;let l={type:t[0].charAt(0)==="!"?"image":"link",raw:r,href:a,title:s,text:o,tokens:n.inlineTokens(o)};return n.state.inLink=!1,l}function mDe(t,e,r){let n=t.match(r.other.indentCodeCompensation);if(n===null)return e;let i=n[1];return e.split(` `).map(a=>{let s=a.match(r.other.beginningSpace);if(s===null)return a;let[o]=s;return o.length>=i.length?a.slice(i.length):a}).join(` `)}function un(t,e){return Qp.parse(t,e)}var Jp,lx,ORe,ws,PRe,BRe,FRe,cx,$Re,oR,wre,Tre,zRe,lR,GRe,cR,qRe,VRe,PT,uR,URe,kre,WRe,hR,pre,HRe,YRe,XRe,jRe,Ere,KRe,BT,fR,Sre,ZRe,Cre,QRe,JRe,eDe,Are,tDe,rDe,_re,nDe,iDe,aDe,sDe,oDe,lDe,cDe,IT,uDe,Lre,Rre,hDe,gre,dR,fDe,nR,dDe,NT,ax,pDe,mre,MT,Zl,OT,pR,Ql,ox,yDe,Qp,HTt,YTt,XTt,jTt,KTt,ZTt,QTt,Dre=$(()=>{Jp=sR();lx={exec:()=>null};ORe=(()=>{try{return!!new RegExp("(?<=1)(?/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] /,listReplaceTask:/^\[[ xX]\] +/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:t=>new RegExp(`^( {0,3}${t})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}#`),htmlBeginRegex:t=>new RegExp(`^ {0,${Math.min(3,t-1)}}<(?:[a-z].*>|!--)`,"i")},PRe=/^(?:[ \t]*(?:\n|$))+/,BRe=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,FRe=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,cx=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,$Re=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,oR=/(?:[*+-]|\d{1,9}[.)])/,wre=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,Tre=an(wre).replace(/bull/g,oR).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),zRe=an(wre).replace(/bull/g,oR).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),lR=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,GRe=/^[^\n]+/,cR=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,qRe=an(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",cR).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),VRe=an(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,oR).getRegex(),PT="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",uR=/|$))/,URe=an("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",uR).replace("tag",PT).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),kre=an(lR).replace("hr",cx).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",PT).getRegex(),WRe=an(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",kre).getRegex(),hR={blockquote:WRe,code:BRe,def:qRe,fences:FRe,heading:$Re,hr:cx,html:URe,lheading:Tre,list:VRe,newline:PRe,paragraph:kre,table:lx,text:GRe},pre=an("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",cx).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",PT).getRegex(),HRe={...hR,lheading:zRe,table:pre,paragraph:an(lR).replace("hr",cx).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",pre).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",PT).getRegex()},YRe={...hR,html:an(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",uR).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:lx,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:an(lR).replace("hr",cx).replace("heading",` *#{1,6} *[^ ]`).replace("lheading",Tre).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},XRe=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,jRe=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Ere=/^( {2,}|\\)\n(?!\s*$)/,KRe=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\`+)[^`]+\k(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",ORe?"(?`+)[^`]+\k(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),Are=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,tDe=an(Are,"u").replace(/punct/g,BT).getRegex(),rDe=an(Are,"u").replace(/punct/g,Cre).getRegex(),_re="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",nDe=an(_re,"gu").replace(/notPunctSpace/g,Sre).replace(/punctSpace/g,fR).replace(/punct/g,BT).getRegex(),iDe=an(_re,"gu").replace(/notPunctSpace/g,JRe).replace(/punctSpace/g,QRe).replace(/punct/g,Cre).getRegex(),aDe=an("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Sre).replace(/punctSpace/g,fR).replace(/punct/g,BT).getRegex(),sDe=an(/\\(punct)/,"gu").replace(/punct/g,BT).getRegex(),oDe=an(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),lDe=an(uR).replace("(?:-->|$)","-->").getRegex(),cDe=an("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",lDe).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),IT=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,uDe=an(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",IT).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Lre=an(/^!?\[(label)\]\[(ref)\]/).replace("label",IT).replace("ref",cR).getRegex(),Rre=an(/^!?\[(ref)\](?:\[\])?/).replace("ref",cR).getRegex(),hDe=an("reflink|nolink(?!\\()","g").replace("reflink",Lre).replace("nolink",Rre).getRegex(),gre=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,dR={_backpedal:lx,anyPunctuation:sDe,autolink:oDe,blockSkip:eDe,br:Ere,code:jRe,del:lx,emStrongLDelim:tDe,emStrongRDelimAst:nDe,emStrongRDelimUnd:aDe,escape:XRe,link:uDe,nolink:Rre,punctuation:ZRe,reflink:Lre,reflinkSearch:hDe,tag:cDe,text:KRe,url:lx},fDe={...dR,link:an(/^!?\[(label)\]\((.*?)\)/).replace("label",IT).getRegex(),reflink:an(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",IT).getRegex()},nR={...dR,emStrongRDelimAst:iDe,emStrongLDelim:rDe,url:an(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",gre).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:an(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\":">",'"':""","'":"'"},mre=t=>pDe[t];MT=class{options;rules;lexer;constructor(t){this.options=t||Jp}space(t){let e=this.rules.block.newline.exec(t);if(e&&e[0].length>0)return{type:"space",raw:e[0]}}code(t){let e=this.rules.block.code.exec(t);if(e){let r=e[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:e[0],codeBlockStyle:"indented",text:this.options.pedantic?r:sx(r,` `)}}}fences(t){let e=this.rules.block.fences.exec(t);if(e){let r=e[0],n=mDe(r,e[3]||"",this.rules);return{type:"code",raw:r,lang:e[2]?e[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):e[2],text:n}}}heading(t){let e=this.rules.block.heading.exec(t);if(e){let r=e[2].trim();if(this.rules.other.endingHash.test(r)){let n=sx(r,"#");(this.options.pedantic||!n||this.rules.other.endingSpaceChar.test(n))&&(r=n.trim())}return{type:"heading",raw:e[0],depth:e[1].length,text:r,tokens:this.lexer.inline(r)}}}hr(t){let e=this.rules.block.hr.exec(t);if(e)return{type:"hr",raw:sx(e[0],` `)}}blockquote(t){let e=this.rules.block.blockquote.exec(t);if(e){let r=sx(e[0],` `).split(` `),n="",i="",a=[];for(;r.length>0;){let s=!1,o=[],l;for(l=0;l1,i={type:"list",raw:"",ordered:n,start:n?+r.slice(0,-1):"",loose:!1,items:[]};r=n?`\\d{1,9}\\${r.slice(-1)}`:`\\${r}`,this.options.pedantic&&(r=n?r:"[*+-]");let a=this.rules.other.listItemRegex(r),s=!1;for(;t;){let l=!1,u="",h="";if(!(e=a.exec(t))||this.rules.block.hr.test(t))break;u=e[0],t=t.substring(u.length);let f=e[2].split(` `,1)[0].replace(this.rules.other.listReplaceTabs,v=>" ".repeat(3*v.length)),d=t.split(` `,1)[0],p=!f.trim(),g=0;if(this.options.pedantic?(g=2,h=f.trimStart()):p?g=e[1].length+1:(g=e[2].search(this.rules.other.nonSpaceChar),g=g>4?1:g,h=f.slice(g),g+=e[1].length),p&&this.rules.other.blankLine.test(d)&&(u+=d+` `,t=t.substring(d.length+1),l=!0),!l){let v=this.rules.other.nextBulletRegex(g),b=this.rules.other.hrRegex(g),w=this.rules.other.fencesBeginRegex(g),S=this.rules.other.headingBeginRegex(g),T=this.rules.other.htmlBeginRegex(g);for(;t;){let k=t.split(` `,1)[0],C;if(d=k,this.options.pedantic?(d=d.replace(this.rules.other.listReplaceNesting," "),C=d):C=d.replace(this.rules.other.tabCharGlobal," "),w.test(d)||S.test(d)||T.test(d)||v.test(d)||b.test(d))break;if(C.search(this.rules.other.nonSpaceChar)>=g||!d.trim())h+=` `+C.slice(g);else{if(p||f.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||w.test(f)||S.test(f)||b.test(f))break;h+=` `+d}!p&&!d.trim()&&(p=!0),u+=k+` `,t=t.substring(k.length+1),f=C.slice(g)}}i.loose||(s?i.loose=!0:this.rules.other.doubleBlankLine.test(u)&&(s=!0));let m=null,y;this.options.gfm&&(m=this.rules.other.listIsTask.exec(h),m&&(y=m[0]!=="[ ] ",h=h.replace(this.rules.other.listReplaceTask,""))),i.items.push({type:"list_item",raw:u,task:!!m,checked:y,loose:!1,text:h,tokens:[]}),i.raw+=u}let o=i.items.at(-1);if(o)o.raw=o.raw.trimEnd(),o.text=o.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let l=0;lf.type==="space"),h=u.length>0&&u.some(f=>this.rules.other.anyLine.test(f.raw));i.loose=h}if(i.loose)for(let l=0;l({text:o,tokens:this.lexer.inline(o),header:!1,align:a.align[l]})));return a}}lheading(t){let e=this.rules.block.lheading.exec(t);if(e)return{type:"heading",raw:e[0],depth:e[2].charAt(0)==="="?1:2,text:e[1],tokens:this.lexer.inline(e[1])}}paragraph(t){let e=this.rules.block.paragraph.exec(t);if(e){let r=e[1].charAt(e[1].length-1)===` `?e[1].slice(0,-1):e[1];return{type:"paragraph",raw:e[0],text:r,tokens:this.lexer.inline(r)}}}text(t){let e=this.rules.block.text.exec(t);if(e)return{type:"text",raw:e[0],text:e[0],tokens:this.lexer.inline(e[0])}}escape(t){let e=this.rules.inline.escape.exec(t);if(e)return{type:"escape",raw:e[0],text:e[1]}}tag(t){let e=this.rules.inline.tag.exec(t);if(e)return!this.lexer.state.inLink&&this.rules.other.startATag.test(e[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(e[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(e[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(e[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:e[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:e[0]}}link(t){let e=this.rules.inline.link.exec(t);if(e){let r=e[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(r)){if(!this.rules.other.endAngleBracket.test(r))return;let a=sx(r.slice(0,-1),"\\");if((r.length-a.length)%2===0)return}else{let a=gDe(e[2],"()");if(a===-2)return;if(a>-1){let s=(e[0].indexOf("!")===0?5:4)+e[1].length+a;e[2]=e[2].substring(0,a),e[0]=e[0].substring(0,s).trim(),e[3]=""}}let n=e[2],i="";if(this.options.pedantic){let a=this.rules.other.pedanticHrefTitle.exec(n);a&&(n=a[1],i=a[3])}else i=e[3]?e[3].slice(1,-1):"";return n=n.trim(),this.rules.other.startAngleBracket.test(n)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(r)?n=n.slice(1):n=n.slice(1,-1)),xre(e,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},e[0],this.lexer,this.rules)}}reflink(t,e){let r;if((r=this.rules.inline.reflink.exec(t))||(r=this.rules.inline.nolink.exec(t))){let n=(r[2]||r[1]).replace(this.rules.other.multipleSpaceGlobal," "),i=e[n.toLowerCase()];if(!i){let a=r[0].charAt(0);return{type:"text",raw:a,text:a}}return xre(r,i,r[0],this.lexer,this.rules)}}emStrong(t,e,r=""){let n=this.rules.inline.emStrongLDelim.exec(t);if(!(!n||n[3]&&r.match(this.rules.other.unicodeAlphaNumeric))&&(!(n[1]||n[2])||!r||this.rules.inline.punctuation.exec(r))){let i=[...n[0]].length-1,a,s,o=i,l=0,u=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(u.lastIndex=0,e=e.slice(-1*t.length+i);(n=u.exec(e))!=null;){if(a=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!a)continue;if(s=[...a].length,n[3]||n[4]){o+=s;continue}else if((n[5]||n[6])&&i%3&&!((i+s)%3)){l+=s;continue}if(o-=s,o>0)continue;s=Math.min(s,s+o+l);let h=[...n[0]][0].length,f=t.slice(0,i+n.index+h+s);if(Math.min(i,s)%2){let p=f.slice(1,-1);return{type:"em",raw:f,text:p,tokens:this.lexer.inlineTokens(p)}}let d=f.slice(2,-2);return{type:"strong",raw:f,text:d,tokens:this.lexer.inlineTokens(d)}}}}codespan(t){let e=this.rules.inline.code.exec(t);if(e){let r=e[2].replace(this.rules.other.newLineCharGlobal," "),n=this.rules.other.nonSpaceChar.test(r),i=this.rules.other.startingSpaceChar.test(r)&&this.rules.other.endingSpaceChar.test(r);return n&&i&&(r=r.substring(1,r.length-1)),{type:"codespan",raw:e[0],text:r}}}br(t){let e=this.rules.inline.br.exec(t);if(e)return{type:"br",raw:e[0]}}del(t){let e=this.rules.inline.del.exec(t);if(e)return{type:"del",raw:e[0],text:e[2],tokens:this.lexer.inlineTokens(e[2])}}autolink(t){let e=this.rules.inline.autolink.exec(t);if(e){let r,n;return e[2]==="@"?(r=e[1],n="mailto:"+r):(r=e[1],n=r),{type:"link",raw:e[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}url(t){let e;if(e=this.rules.inline.url.exec(t)){let r,n;if(e[2]==="@")r=e[0],n="mailto:"+r;else{let i;do i=e[0],e[0]=this.rules.inline._backpedal.exec(e[0])?.[0]??"";while(i!==e[0]);r=e[0],e[1]==="www."?n="http://"+e[0]:n=e[0]}return{type:"link",raw:e[0],text:r,href:n,tokens:[{type:"text",raw:r,text:r}]}}}inlineText(t){let e=this.rules.inline.text.exec(t);if(e){let r=this.lexer.state.inRawBlock;return{type:"text",raw:e[0],text:e[0],escaped:r}}}},Zl=class iR{tokens;options;state;tokenizer;inlineQueue;constructor(e){this.tokens=[],this.tokens.links=Object.create(null),this.options=e||Jp,this.options.tokenizer=this.options.tokenizer||new MT,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let r={other:ws,block:NT.normal,inline:ax.normal};this.options.pedantic?(r.block=NT.pedantic,r.inline=ax.pedantic):this.options.gfm&&(r.block=NT.gfm,this.options.breaks?r.inline=ax.breaks:r.inline=ax.gfm),this.tokenizer.rules=r}static get rules(){return{block:NT,inline:ax}}static lex(e,r){return new iR(r).lex(e)}static lexInline(e,r){return new iR(r).inlineTokens(e)}lex(e){e=e.replace(ws.carriageReturn,` `),this.blockTokens(e,this.tokens);for(let r=0;r(i=s.call({lexer:this},e,r))?(e=e.substring(i.raw.length),r.push(i),!0):!1))continue;if(i=this.tokenizer.space(e)){e=e.substring(i.raw.length);let s=r.at(-1);i.raw.length===1&&s!==void 0?s.raw+=` `:r.push(i);continue}if(i=this.tokenizer.code(e)){e=e.substring(i.raw.length);let s=r.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(` `)?"":` `)+i.raw,s.text+=` `+i.text,this.inlineQueue.at(-1).src=s.text):r.push(i);continue}if(i=this.tokenizer.fences(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.heading(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.hr(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.blockquote(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.list(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.html(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.def(e)){e=e.substring(i.raw.length);let s=r.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(` `)?"":` `)+i.raw,s.text+=` `+i.raw,this.inlineQueue.at(-1).src=s.text):this.tokens.links[i.tag]||(this.tokens.links[i.tag]={href:i.href,title:i.title},r.push(i));continue}if(i=this.tokenizer.table(e)){e=e.substring(i.raw.length),r.push(i);continue}if(i=this.tokenizer.lheading(e)){e=e.substring(i.raw.length),r.push(i);continue}let a=e;if(this.options.extensions?.startBlock){let s=1/0,o=e.slice(1),l;this.options.extensions.startBlock.forEach(u=>{l=u.call({lexer:this},o),typeof l=="number"&&l>=0&&(s=Math.min(s,l))}),s<1/0&&s>=0&&(a=e.substring(0,s+1))}if(this.state.top&&(i=this.tokenizer.paragraph(a))){let s=r.at(-1);n&&s?.type==="paragraph"?(s.raw+=(s.raw.endsWith(` `)?"":` `)+i.raw,s.text+=` `+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):r.push(i),n=a.length!==e.length,e=e.substring(i.raw.length);continue}if(i=this.tokenizer.text(e)){e=e.substring(i.raw.length);let s=r.at(-1);s?.type==="text"?(s.raw+=(s.raw.endsWith(` `)?"":` `)+i.raw,s.text+=` `+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):r.push(i);continue}if(e){let s="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(s);break}else throw new Error(s)}}return this.state.top=!0,r}inline(e,r=[]){return this.inlineQueue.push({src:e,tokens:r}),r}inlineTokens(e,r=[]){let n=e,i=null;if(this.tokens.links){let l=Object.keys(this.tokens.links);if(l.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(n))!=null;)l.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(n=n.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+n.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(i=this.tokenizer.rules.inline.anyPunctuation.exec(n))!=null;)n=n.slice(0,i.index)+"++"+n.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let a;for(;(i=this.tokenizer.rules.inline.blockSkip.exec(n))!=null;)a=i[2]?i[2].length:0,n=n.slice(0,i.index+a)+"["+"a".repeat(i[0].length-a-2)+"]"+n.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);n=this.options.hooks?.emStrongMask?.call({lexer:this},n)??n;let s=!1,o="";for(;e;){s||(o=""),s=!1;let l;if(this.options.extensions?.inline?.some(h=>(l=h.call({lexer:this},e,r))?(e=e.substring(l.raw.length),r.push(l),!0):!1))continue;if(l=this.tokenizer.escape(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.tag(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.link(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(l.raw.length);let h=r.at(-1);l.type==="text"&&h?.type==="text"?(h.raw+=l.raw,h.text+=l.text):r.push(l);continue}if(l=this.tokenizer.emStrong(e,n,o)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.codespan(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.br(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.del(e)){e=e.substring(l.raw.length),r.push(l);continue}if(l=this.tokenizer.autolink(e)){e=e.substring(l.raw.length),r.push(l);continue}if(!this.state.inLink&&(l=this.tokenizer.url(e))){e=e.substring(l.raw.length),r.push(l);continue}let u=e;if(this.options.extensions?.startInline){let h=1/0,f=e.slice(1),d;this.options.extensions.startInline.forEach(p=>{d=p.call({lexer:this},f),typeof d=="number"&&d>=0&&(h=Math.min(h,d))}),h<1/0&&h>=0&&(u=e.substring(0,h+1))}if(l=this.tokenizer.inlineText(u)){e=e.substring(l.raw.length),l.raw.slice(-1)!=="_"&&(o=l.raw.slice(-1)),s=!0;let h=r.at(-1);h?.type==="text"?(h.raw+=l.raw,h.text+=l.text):r.push(l);continue}if(e){let h="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(h);break}else throw new Error(h)}}return r}},OT=class{options;parser;constructor(t){this.options=t||Jp}space(t){return""}code({text:t,lang:e,escaped:r}){let n=(e||"").match(ws.notSpaceStart)?.[0],i=t.replace(ws.endingNewline,"")+` `;return n?'
'+(r?i:tu(i,!0))+`
`:"
"+(r?i:tu(i,!0))+`
`}blockquote({tokens:t}){return`
${this.parser.parse(t)}
`}html({text:t}){return t}def(t){return""}heading({tokens:t,depth:e}){return`${this.parser.parseInline(t)} `}hr(t){return`
`}list(t){let e=t.ordered,r=t.start,n="";for(let s=0;s `+n+" `}listitem(t){let e="";if(t.task){let r=this.checkbox({checked:!!t.checked});t.loose?t.tokens[0]?.type==="paragraph"?(t.tokens[0].text=r+" "+t.tokens[0].text,t.tokens[0].tokens&&t.tokens[0].tokens.length>0&&t.tokens[0].tokens[0].type==="text"&&(t.tokens[0].tokens[0].text=r+" "+tu(t.tokens[0].tokens[0].text),t.tokens[0].tokens[0].escaped=!0)):t.tokens.unshift({type:"text",raw:r+" ",text:r+" ",escaped:!0}):e+=r+" "}return e+=this.parser.parse(t.tokens,!!t.loose),`
  • ${e}
  • `}checkbox({checked:t}){return"'}paragraph({tokens:t}){return`

    ${this.parser.parseInline(t)}

    `}table(t){let e="",r="";for(let i=0;i${n}`),` `+e+` `+n+`
    `}tablerow({text:t}){return` ${t} `}tablecell(t){let e=this.parser.parseInline(t.tokens),r=t.header?"th":"td";return(t.align?`<${r} align="${t.align}">`:`<${r}>`)+e+` `}strong({tokens:t}){return`${this.parser.parseInline(t)}`}em({tokens:t}){return`${this.parser.parseInline(t)}`}codespan({text:t}){return`${tu(t,!0)}`}br(t){return"
    "}del({tokens:t}){return`${this.parser.parseInline(t)}`}link({href:t,title:e,tokens:r}){let n=this.parser.parseInline(r),i=yre(t);if(i===null)return n;t=i;let a='
    ",a}image({href:t,title:e,text:r,tokens:n}){n&&(r=this.parser.parseInline(n,this.parser.textRenderer));let i=yre(t);if(i===null)return tu(r);t=i;let a=`${r}{let s=i[a].flat(1/0);r=r.concat(this.walkTokens(s,e))}):i.tokens&&(r=r.concat(this.walkTokens(i.tokens,e)))}}return r}use(...t){let e=this.defaults.extensions||{renderers:{},childTokens:{}};return t.forEach(r=>{let n={...r};if(n.async=this.defaults.async||n.async||!1,r.extensions&&(r.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let a=e.renderers[i.name];a?e.renderers[i.name]=function(...s){let o=i.renderer.apply(this,s);return o===!1&&(o=a.apply(this,s)),o}:e.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let a=e[i.level];a?a.unshift(i.tokenizer):e[i.level]=[i.tokenizer],i.start&&(i.level==="block"?e.startBlock?e.startBlock.push(i.start):e.startBlock=[i.start]:i.level==="inline"&&(e.startInline?e.startInline.push(i.start):e.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(e.childTokens[i.name]=i.childTokens)}),n.extensions=e),r.renderer){let i=this.defaults.renderer||new OT(this.defaults);for(let a in r.renderer){if(!(a in i))throw new Error(`renderer '${a}' does not exist`);if(["options","parser"].includes(a))continue;let s=a,o=r.renderer[s],l=i[s];i[s]=(...u)=>{let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),h||""}}n.renderer=i}if(r.tokenizer){let i=this.defaults.tokenizer||new MT(this.defaults);for(let a in r.tokenizer){if(!(a in i))throw new Error(`tokenizer '${a}' does not exist`);if(["options","rules","lexer"].includes(a))continue;let s=a,o=r.tokenizer[s],l=i[s];i[s]=(...u)=>{let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),h}}n.tokenizer=i}if(r.hooks){let i=this.defaults.hooks||new ox;for(let a in r.hooks){if(!(a in i))throw new Error(`hook '${a}' does not exist`);if(["options","block"].includes(a))continue;let s=a,o=r.hooks[s],l=i[s];ox.passThroughHooks.has(a)?i[s]=u=>{if(this.defaults.async&&ox.passThroughHooksRespectAsync.has(a))return(async()=>{let f=await o.call(i,u);return l.call(i,f)})();let h=o.call(i,u);return l.call(i,h)}:i[s]=(...u)=>{if(this.defaults.async)return(async()=>{let f=await o.apply(i,u);return f===!1&&(f=await l.apply(i,u)),f})();let h=o.apply(i,u);return h===!1&&(h=l.apply(i,u)),h}}n.hooks=i}if(r.walkTokens){let i=this.defaults.walkTokens,a=r.walkTokens;n.walkTokens=function(s){let o=[];return o.push(a.call(this,s)),i&&(o=o.concat(i.call(this,s))),o}}this.defaults={...this.defaults,...n}}),this}setOptions(t){return this.defaults={...this.defaults,...t},this}lexer(t,e){return Zl.lex(t,e??this.defaults)}parser(t,e){return Ql.parse(t,e??this.defaults)}parseMarkdown(t){return(e,r)=>{let n={...r},i={...this.defaults,...n},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&n.async===!1)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof e>"u"||e===null)return a(new Error("marked(): input parameter is undefined or null"));if(typeof e!="string")return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(e)+", string expected"));if(i.hooks&&(i.hooks.options=i,i.hooks.block=t),i.async)return(async()=>{let s=i.hooks?await i.hooks.preprocess(e):e,o=await(i.hooks?await i.hooks.provideLexer():t?Zl.lex:Zl.lexInline)(s,i),l=i.hooks?await i.hooks.processAllTokens(o):o;i.walkTokens&&await Promise.all(this.walkTokens(l,i.walkTokens));let u=await(i.hooks?await i.hooks.provideParser():t?Ql.parse:Ql.parseInline)(l,i);return i.hooks?await i.hooks.postprocess(u):u})().catch(a);try{i.hooks&&(e=i.hooks.preprocess(e));let s=(i.hooks?i.hooks.provideLexer():t?Zl.lex:Zl.lexInline)(e,i);i.hooks&&(s=i.hooks.processAllTokens(s)),i.walkTokens&&this.walkTokens(s,i.walkTokens);let o=(i.hooks?i.hooks.provideParser():t?Ql.parse:Ql.parseInline)(s,i);return i.hooks&&(o=i.hooks.postprocess(o)),o}catch(s){return a(s)}}}onError(t,e){return r=>{if(r.message+=` Please report this to https://github.com/markedjs/marked.`,t){let n="

    An error occurred:

    "+tu(r.message+"",!0)+"
    ";return e?Promise.resolve(n):n}if(e)return Promise.reject(r);throw r}}},Qp=new yDe;un.options=un.setOptions=function(t){return Qp.setOptions(t),un.defaults=Qp.defaults,bre(un.defaults),un};un.getDefaults=sR;un.defaults=Jp;un.use=function(...t){return Qp.use(...t),un.defaults=Qp.defaults,bre(un.defaults),un};un.walkTokens=function(t,e){return Qp.walkTokens(t,e)};un.parseInline=Qp.parseInline;un.Parser=Ql;un.parser=Ql.parse;un.Renderer=OT;un.TextRenderer=pR;un.Lexer=Zl;un.lexer=Zl.lex;un.Tokenizer=MT;un.Hooks=ox;un.parse=un;HTt=un.options,YTt=un.setOptions,XTt=un.use,jTt=un.walkTokens,KTt=un.parseInline,ZTt=Ql.parse,QTt=Zl.lex});function FT(t){for(var e=[],r=1;r{});function Mre(t,{markdownAutoWrap:e}){let n=t.replace(//g,` `).replace(/\n{2,}/g,` `),i=FT(n);return e===!1?i.replace(/ /g," "):i}function Ore(t,e={}){let r=Mre(t,e),n=un.lexer(r),i=[[]],a=0;function s(o,l="normal"){o.type==="text"?o.text.split(` `).forEach((h,f)=>{f!==0&&(a++,i.push([])),h.split(" ").forEach(d=>{d=d.replace(/'/g,"'"),d&&i[a].push({content:d,type:l})})}):o.type==="strong"||o.type==="em"?o.tokens.forEach(u=>{s(u,o.type)}):o.type==="html"&&i[a].push({content:o.text,type:"normal"})}return x(s,"processNode"),n.forEach(o=>{o.type==="paragraph"?o.tokens?.forEach(l=>{s(l)}):o.type==="html"?i[a].push({content:o.text,type:"normal"}):i[a].push({content:o.raw,type:"normal"})}),i}function Pre(t,{markdownAutoWrap:e}={}){let r=un.lexer(t);function n(i){return i.type==="text"?e===!1?i.text.replace(/\n */g,"
    ").replace(/ /g," "):i.text.replace(/\n */g,"
    "):i.type==="strong"?`${i.tokens?.map(n).join("")}`:i.type==="em"?`${i.tokens?.map(n).join("")}`:i.type==="paragraph"?`

    ${i.tokens?.map(n).join("")}

    `:i.type==="space"?"":i.type==="html"?`${i.text}`:i.type==="escape"?i.text:(te.warn(`Unsupported markdown: ${i.type}`),i.raw)}return x(n,"output"),r.map(n).join("")}function Bre(t){return Intl.Segmenter?[...new Intl.Segmenter().segment(t)].map(e=>e.segment):[...t]}function Fre(t,e){let r=Bre(e.content);return xR(t,[],r,e.type)}function xR(t,e,r,n){if(r.length===0)return[{content:e.join(""),type:n},{content:"",type:n}];let[i,...a]=r,s=[...e,i];return t([{content:s.join(""),type:n}])?xR(t,s,a,n):(e.length===0&&i&&(e.push(i),r.shift()),[{content:e.join(""),type:n},{content:r.join(""),type:n}])}function $re(t,e){if(t.some(({content:r})=>r.includes(` `)))throw new Error("splitLineToFitWidth does not support newlines in the line");return $T(t,e)}function $T(t,e,r=[],n=[]){if(t.length===0)return n.length>0&&r.push(n),r.length>0?r:[];let i="";t[0].content===" "&&(i=" ",t.shift());let a=t.shift()??{content:" ",type:"normal"},s=[...n];if(i!==""&&s.push({content:i,type:"normal"}),s.push(a),e(s))return $T(t,e,r,s);if(n.length>0)r.push(n),t.unshift(a);else if(a.content){let[o,l]=Fre(e,a);r.push([o]),l.content&&t.unshift(l)}return $T(t,e,r)}function yR(t,e){e&&t.attr("style",e)}async function zre(t,e,r,n,i=!1,a=fr()){let s=t.append("foreignObject");s.attr("width",`${10*r}px`),s.attr("height",`${10*r}px`);let o=s.append("xhtml:div"),l=qn(e.label)?await cf(e.label.replace(tt.lineBreakRegex,` `),a):ur(e.label,a),u=e.isNode?"nodeLabel":"edgeLabel",h=o.append("span");h.html(l),yR(h,e.labelStyle),h.attr("class",`${u} ${n}`),yR(o,e.labelStyle),o.style("display","table-cell"),o.style("white-space","nowrap"),o.style("line-height","1.5"),o.style("max-width",r+"px"),o.style("text-align","center"),o.attr("xmlns","http://www.w3.org/1999/xhtml"),i&&o.attr("class","labelBkg");let f=o.node().getBoundingClientRect();return f.width===r&&(o.style("display","table"),o.style("white-space","break-spaces"),o.style("width",r+"px"),f=o.node().getBoundingClientRect()),s.node()}function GT(t,e,r){return t.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*r-.1+"em").attr("dy",r+"em")}function Gre(t,e,r){let n=t.append("text"),i=GT(n,1,e);qT(i,r);let a=i.node().getComputedTextLength();return n.remove(),a}function bR(t,e,r){let n=t.append("text"),i=GT(n,1,e);qT(i,[{content:r,type:"normal"}]);let a=i.node()?.getBoundingClientRect();return a&&n.remove(),a}function qre(t,e,r,n=!1){let a=e.append("g"),s=a.insert("rect").attr("class","background").attr("style","stroke: none"),o=a.append("text").attr("y","-10.1"),l=0;for(let u of r){let h=x(d=>Gre(a,1.1,d)<=t,"checkWidth"),f=h(u)?[u]:$re(u,h);for(let d of f){let p=GT(o,l,1.1);qT(p,d),l++}}if(n){let u=o.node().getBBox(),h=2;return s.attr("x",u.x-h).attr("y",u.y-h).attr("width",u.width+2*h).attr("height",u.height+2*h),a.node()}else return o.node()}function qT(t,e){t.text(""),e.forEach((r,n)=>{let i=t.append("tspan").attr("font-style",r.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",r.type==="strong"?"bold":"normal");n===0?i.text(r.content):i.text(" "+r.content)})}async function VT(t,e={}){let r=[];t.replace(/(fa[bklrs]?):fa-([\w-]+)/g,(i,a,s)=>(r.push((async()=>{let o=`${a}:${s}`;return await vDe(o)?await ru(o,void 0,{class:"label-icon"}):``})()),i));let n=await Promise.all(r);return t.replace(/(fa[bklrs]?):fa-([\w-]+)/g,()=>n.shift()??"")}var vR,mR,Nre,zT,Ire,vDe,ru,Ca,Aa=$(()=>{bn();Er();lr();dre();pr();Dre();gR();vR={body:'?',height:80,width:80},mR=new Map,Nre=new Map,zT=x(t=>{for(let e of t){if(!e.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(te.debug("Registering icon pack:",e.name),"loader"in e)Nre.set(e.name,e.loader);else if("icons"in e)mR.set(e.name,e.icons);else throw te.error("Invalid icon loader:",e),new Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),Ire=x(async(t,e)=>{let r=K9(t,!0,e!==void 0);if(!r)throw new Error(`Invalid icon name: ${t}`);let n=r.prefix||e;if(!n)throw new Error(`Icon name must contain a prefix: ${t}`);let i=mR.get(n);if(!i){let s=Nre.get(n);if(!s)throw new Error(`Icon set not found: ${r.prefix}`);try{i={...await s(),prefix:n},mR.set(n,i)}catch(o){throw te.error(o),new Error(`Failed to load icon set: ${r.prefix}`)}}let a=Q9(i,r.name);if(!a)throw new Error(`Icon not found: ${t}`);return a},"getRegisteredIconData"),vDe=x(async t=>{try{return await Ire(t),!0}catch{return!1}},"isIconAvailable"),ru=x(async(t,e,r)=>{let n;try{n=await Ire(t,e?.fallbackPrefix)}catch(s){te.error(s),n=vR}let i=eR(n,e),a=rR(tR(i.body),{...i.attributes,...r});return ur(a,fr())},"getIconSVG");x(Mre,"preprocessMarkdown");x(Ore,"markdownToLines");x(Pre,"markdownToHTML");x(Bre,"splitTextToChars");x(Fre,"splitWordToFitWidth");x(xR,"splitWordToFitWidthRecursion");x($re,"splitLineToFitWidth");x($T,"splitLineToFitWidthRecursion");x(yR,"applyStyle");x(zre,"addHtmlSpan");x(GT,"createTspan");x(Gre,"computeWidthOfText");x(bR,"computeDimensionOfText");x(qre,"createFormattedText");x(qT,"updateTextContentAndStyles");x(VT,"replaceIconSubstring");Ca=x(async(t,e="",{style:r="",isTitle:n=!1,classes:i="",useHtmlLabels:a=!0,isNode:s=!0,width:o=200,addSvgBackground:l=!1}={},u)=>{if(te.debug("XYZ createText",e,r,n,i,a,s,"addSvgBackground: ",l),a){let h=Pre(e,u),f=await VT(Ks(h),u),d=e.replace(/\\\\/g,"\\"),p={isNode:s,label:qn(e)?d:f,labelStyle:r.replace("fill:","color:")};return await zre(t,p,o,i,l,u)}else{let h=e.replace(//g,"
    "),f=Ore(h.replace("
    ","
    "),u),d=qre(o,t,f,e?l:!1);if(s){/stroke:/.exec(r)&&(r=r.replace("stroke:","lineColor:"));let p=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");Ye(d).attr("style",p)}else{let p=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");Ye(d).select("rect").attr("style",p.replace(/background:/g,"fill:"));let g=r.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");Ye(d).select("text").attr("style",g)}return d}},"createText")});function wR(t,e,r){if(t&&t.length){let[n,i]=e,a=Math.PI/180*r,s=Math.cos(a),o=Math.sin(a);for(let l of t){let[u,h]=l;l[0]=(u-n)*s-(h-i)*o+n,l[1]=(u-n)*o+(h-i)*s+i}}}function xDe(t,e){return t[0]===e[0]&&t[1]===e[1]}function bDe(t,e,r,n=1){let i=r,a=Math.max(e,.1),s=t[0]&&t[0][0]&&typeof t[0][0]=="number"?[t]:t,o=[0,0];if(i)for(let u of s)wR(u,o,i);let l=(function(u,h,f){let d=[];for(let b of u){let w=[...b];xDe(w[0],w[w.length-1])||w.push([w[0][0],w[0][1]]),w.length>2&&d.push(w)}let p=[];h=Math.max(h,.1);let g=[];for(let b of d)for(let w=0;wb.yminw.ymin?1:b.xw.x?1:b.ymax===w.ymax?0:(b.ymax-w.ymax)/Math.abs(b.ymax-w.ymax))),!g.length)return p;let m=[],y=g[0].ymin,v=0;for(;m.length||g.length;){if(g.length){let b=-1;for(let w=0;wy);w++)b=w;g.splice(0,b+1).forEach((w=>{m.push({s:y,edge:w})}))}if(m=m.filter((b=>!(b.edge.ymax<=y))),m.sort(((b,w)=>b.edge.x===w.edge.x?0:(b.edge.x-w.edge.x)/Math.abs(b.edge.x-w.edge.x))),(f!==1||v%h==0)&&m.length>1)for(let b=0;b=m.length)break;let S=m[b].edge,T=m[w].edge;p.push([[Math.round(S.x),y],[Math.round(T.x),y]])}y+=f,m.forEach((b=>{b.edge.x=b.edge.x+f*b.edge.islope})),v++}return p})(s,a,n);if(i){for(let u of s)wR(u,o,-i);(function(u,h,f){let d=[];u.forEach((p=>d.push(...p))),wR(d,h,f)})(l,o,-i)}return l}function dx(t,e){var r;let n=e.hachureAngle+90,i=e.hachureGap;i<0&&(i=4*e.strokeWidth),i=Math.round(Math.max(i,.1));let a=1;return e.roughness>=1&&(((r=e.randomizer)===null||r===void 0?void 0:r.next())||Math.random())>.7&&(a=i),bDe(t,i,n,a||1)}function QT(t){let e=t[0],r=t[1];return Math.sqrt(Math.pow(e[0]-r[0],2)+Math.pow(e[1]-r[1],2))}function kR(t,e){return t.type===e}function BR(t){let e=[],r=(function(s){let o=new Array;for(;s!=="";)if(s.match(/^([ \t\r\n,]+)/))s=s.substr(RegExp.$1.length);else if(s.match(/^([aAcChHlLmMqQsStTvVzZ])/))o[o.length]={type:wDe,text:RegExp.$1},s=s.substr(RegExp.$1.length);else{if(!s.match(/^(([-+]?[0-9]+(\.[0-9]*)?|[-+]?\.[0-9]+)([eE][-+]?[0-9]+)?)/))return[];o[o.length]={type:TR,text:`${parseFloat(RegExp.$1)}`},s=s.substr(RegExp.$1.length)}return o[o.length]={type:Vre,text:""},o})(t),n="BOD",i=0,a=r[i];for(;!kR(a,Vre);){let s=0,o=[];if(n==="BOD"){if(a.text!=="M"&&a.text!=="m")return BR("M0,0"+t);i++,s=UT[a.text],n=a.text}else kR(a,TR)?s=UT[n]:(i++,s=UT[a.text],n=a.text);if(!(i+sh%2?u+r:u+e));a.push({key:"C",data:l}),e=l[4],r=l[5];break}case"Q":a.push({key:"Q",data:[...o]}),e=o[2],r=o[3];break;case"q":{let l=o.map(((u,h)=>h%2?u+r:u+e));a.push({key:"Q",data:l}),e=l[2],r=l[3];break}case"A":a.push({key:"A",data:[...o]}),e=o[5],r=o[6];break;case"a":e+=o[5],r+=o[6],a.push({key:"A",data:[o[0],o[1],o[2],o[3],o[4],e,r]});break;case"H":a.push({key:"H",data:[...o]}),e=o[0];break;case"h":e+=o[0],a.push({key:"H",data:[e]});break;case"V":a.push({key:"V",data:[...o]}),r=o[0];break;case"v":r+=o[0],a.push({key:"V",data:[r]});break;case"S":a.push({key:"S",data:[...o]}),e=o[2],r=o[3];break;case"s":{let l=o.map(((u,h)=>h%2?u+r:u+e));a.push({key:"S",data:l}),e=l[2],r=l[3];break}case"T":a.push({key:"T",data:[...o]}),e=o[0],r=o[1];break;case"t":e+=o[0],r+=o[1],a.push({key:"T",data:[e,r]});break;case"Z":case"z":a.push({key:"Z",data:[]}),e=n,r=i}return a}function Qre(t){let e=[],r="",n=0,i=0,a=0,s=0,o=0,l=0;for(let{key:u,data:h}of t){switch(u){case"M":e.push({key:"M",data:[...h]}),[n,i]=h,[a,s]=h;break;case"C":e.push({key:"C",data:[...h]}),n=h[4],i=h[5],o=h[2],l=h[3];break;case"L":e.push({key:"L",data:[...h]}),[n,i]=h;break;case"H":n=h[0],e.push({key:"L",data:[n,i]});break;case"V":i=h[0],e.push({key:"L",data:[n,i]});break;case"S":{let f=0,d=0;r==="C"||r==="S"?(f=n+(n-o),d=i+(i-l)):(f=n,d=i),e.push({key:"C",data:[f,d,...h]}),o=h[0],l=h[1],n=h[2],i=h[3];break}case"T":{let[f,d]=h,p=0,g=0;r==="Q"||r==="T"?(p=n+(n-o),g=i+(i-l)):(p=n,g=i);let m=n+2*(p-n)/3,y=i+2*(g-i)/3,v=f+2*(p-f)/3,b=d+2*(g-d)/3;e.push({key:"C",data:[m,y,v,b,f,d]}),o=p,l=g,n=f,i=d;break}case"Q":{let[f,d,p,g]=h,m=n+2*(f-n)/3,y=i+2*(d-i)/3,v=p+2*(f-p)/3,b=g+2*(d-g)/3;e.push({key:"C",data:[m,y,v,b,p,g]}),o=f,l=d,n=p,i=g;break}case"A":{let f=Math.abs(h[0]),d=Math.abs(h[1]),p=h[2],g=h[3],m=h[4],y=h[5],v=h[6];f===0||d===0?(e.push({key:"C",data:[n,i,y,v,y,v]}),n=y,i=v):(n!==y||i!==v)&&(Jre(n,i,y,v,f,d,p,g,m).forEach((function(b){e.push({key:"C",data:b})})),n=y,i=v);break}case"Z":e.push({key:"Z",data:[]}),n=a,i=s}r=u}return e}function ux(t,e,r){return[t*Math.cos(r)-e*Math.sin(r),t*Math.sin(r)+e*Math.cos(r)]}function Jre(t,e,r,n,i,a,s,o,l,u){let h=(f=s,Math.PI*f/180);var f;let d=[],p=0,g=0,m=0,y=0;if(u)[p,g,m,y]=u;else{[t,e]=ux(t,e,-h),[r,n]=ux(r,n,-h);let _=(t-r)/2,A=(e-n)/2,R=_*_/(i*i)+A*A/(a*a);R>1&&(R=Math.sqrt(R),i*=R,a*=R);let N=i*i,O=a*a,P=N*O-N*A*A-O*_*_,B=N*A*A+O*_*_,G=(o===l?-1:1)*Math.sqrt(Math.abs(P/B));m=G*i*A/a+(t+r)/2,y=G*-a*_/i+(e+n)/2,p=Math.asin(parseFloat(((e-y)/a).toFixed(9))),g=Math.asin(parseFloat(((n-y)/a).toFixed(9))),tg&&(p-=2*Math.PI),!l&&g>p&&(g-=2*Math.PI)}let v=g-p;if(Math.abs(v)>120*Math.PI/180){let _=g,A=r,R=n;g=l&&g>p?p+120*Math.PI/180*1:p+120*Math.PI/180*-1,d=Jre(r=m+i*Math.cos(g),n=y+a*Math.sin(g),A,R,i,a,s,0,l,[g,_,m,y])}v=g-p;let b=Math.cos(p),w=Math.sin(p),S=Math.cos(g),T=Math.sin(g),k=Math.tan(v/4),C=4/3*i*k,L=4/3*a*k,D=[t,e],M=[t+C*w,e-L*b],I=[r+C*T,n-L*S],E=[r,n];if(M[0]=2*D[0]-M[0],M[1]=2*D[1]-M[1],u)return[M,I,E].concat(d);{d=[M,I,E].concat(d);let _=[];for(let A=0;A2){let i=[];for(let a=0;a2*Math.PI&&(p=0,g=2*Math.PI);let m=2*Math.PI/l.curveStepCount,y=Math.min(m/2,(g-p)/2),v=jre(y,u,h,f,d,p,g,1,l);if(!l.disableMultiStroke){let b=jre(y,u,h,f,d,p,g,1.5,l);v.push(...b)}return s&&(o?v.push(...Mf(u,h,u+f*Math.cos(p),h+d*Math.sin(p),l),...Mf(u,h,u+f*Math.cos(g),h+d*Math.sin(g),l)):v.push({op:"lineTo",data:[u,h]},{op:"lineTo",data:[u+f*Math.cos(p),h+d*Math.sin(p)]})),{type:"path",ops:v}}function Hre(t,e){let r=Qre(Zre(BR(t))),n=[],i=[0,0],a=[0,0];for(let{key:s,data:o}of r)switch(s){case"M":a=[o[0],o[1]],i=[o[0],o[1]];break;case"L":n.push(...Mf(a[0],a[1],o[0],o[1],e)),a=[o[0],o[1]];break;case"C":{let[l,u,h,f,d,p]=o;n.push(...EDe(l,u,h,f,d,p,a,e)),a=[d,p];break}case"Z":n.push(...Mf(a[0],a[1],i[0],i[1],e)),a=[i[0],i[1]]}return{type:"path",ops:n}}function ER(t,e){let r=[];for(let n of t)if(n.length){let i=e.maxRandomnessOffset||0,a=n.length;if(a>2){r.push({op:"move",data:[n[0][0]+ir(i,e),n[0][1]+ir(i,e)]});for(let s=1;s500?.4:-.0016668*l+1.233334;let h=i.maxRandomnessOffset||0;h*h*100>o&&(h=l/10);let f=h/2,d=.2+.2*rne(i),p=i.bowing*i.maxRandomnessOffset*(n-e)/200,g=i.bowing*i.maxRandomnessOffset*(t-r)/200;p=ir(p,i,u),g=ir(g,i,u);let m=[],y=()=>ir(f,i,u),v=()=>ir(h,i,u),b=i.preserveVertices;return a&&(s?m.push({op:"move",data:[t+(b?0:y()),e+(b?0:y())]}):m.push({op:"move",data:[t+(b?0:ir(h,i,u)),e+(b?0:ir(h,i,u))]})),s?m.push({op:"bcurveTo",data:[p+t+(r-t)*d+y(),g+e+(n-e)*d+y(),p+t+2*(r-t)*d+y(),g+e+2*(n-e)*d+y(),r+(b?0:y()),n+(b?0:y())]}):m.push({op:"bcurveTo",data:[p+t+(r-t)*d+v(),g+e+(n-e)*d+v(),p+t+2*(r-t)*d+v(),g+e+2*(n-e)*d+v(),r+(b?0:v()),n+(b?0:v())]}),m}function WT(t,e,r){if(!t.length)return[];let n=[];n.push([t[0][0]+ir(e,r),t[0][1]+ir(e,r)]),n.push([t[0][0]+ir(e,r),t[0][1]+ir(e,r)]);for(let i=1;i3){let a=[],s=1-r.curveTightness;i.push({op:"move",data:[t[1][0],t[1][1]]});for(let o=1;o+21&&i.push(o)):i.push(o),i.push(t[e+3])}else{let l=t[e+0],u=t[e+1],h=t[e+2],f=t[e+3],d=e0(l,u,.5),p=e0(u,h,.5),g=e0(h,f,.5),m=e0(d,p,.5),y=e0(p,g,.5),v=e0(m,y,.5);MR([l,d,m,v],0,r,i),MR([v,y,g,f],0,r,i)}var a,s;return i}function CDe(t,e){return ZT(t,0,t.length,e)}function ZT(t,e,r,n,i){let a=i||[],s=t[e],o=t[r-1],l=0,u=1;for(let h=e+1;hl&&(l=f,u=h)}return Math.sqrt(l)>n?(ZT(t,e,u+1,n,a),ZT(t,u,r,n,a)):(a.length||a.push(s),a.push(o)),a}function SR(t,e=.15,r){let n=[],i=(t.length-1)/3;for(let a=0;a0?ZT(n,0,n.length,r):n}var fx,CR,AR,_R,LR,RR,Zs,DR,wDe,TR,Vre,UT,TDe,Lo,Om,OR,HT,PR,Ze,zt=$(()=>{fx=class{constructor(e){this.helper=e}fillPolygons(e,r){return this._fillPolygons(e,r)}_fillPolygons(e,r){let n=dx(e,r);return{type:"fillSketch",ops:this.renderLines(n,r)}}renderLines(e,r){let n=[];for(let i of e)n.push(...this.helper.doubleLineOps(i[0][0],i[0][1],i[1][0],i[1][1],r));return n}};CR=class extends fx{fillPolygons(e,r){let n=r.hachureGap;n<0&&(n=4*r.strokeWidth),n=Math.max(n,.1);let i=dx(e,Object.assign({},r,{hachureGap:n})),a=Math.PI/180*r.hachureAngle,s=[],o=.5*n*Math.cos(a),l=.5*n*Math.sin(a);for(let[u,h]of i)QT([u,h])&&s.push([[u[0]-o,u[1]+l],[...h]],[[u[0]+o,u[1]-l],[...h]]);return{type:"fillSketch",ops:this.renderLines(s,r)}}},AR=class extends fx{fillPolygons(e,r){let n=this._fillPolygons(e,r),i=Object.assign({},r,{hachureAngle:r.hachureAngle+90}),a=this._fillPolygons(e,i);return n.ops=n.ops.concat(a.ops),n}},_R=class{constructor(e){this.helper=e}fillPolygons(e,r){let n=dx(e,r=Object.assign({},r,{hachureAngle:0}));return this.dotsOnLines(n,r)}dotsOnLines(e,r){let n=[],i=r.hachureGap;i<0&&(i=4*r.strokeWidth),i=Math.max(i,.1);let a=r.fillWeight;a<0&&(a=r.strokeWidth/2);let s=i/4;for(let o of e){let l=QT(o),u=l/i,h=Math.ceil(u)-1,f=l-h*i,d=(o[0][0]+o[1][0])/2-i/4,p=Math.min(o[0][1],o[1][1]);for(let g=0;g{let o=QT(s),l=Math.floor(o/(n+i)),u=(o+i-l*(n+i))/2,h=s[0],f=s[1];h[0]>f[0]&&(h=s[1],f=s[0]);let d=Math.atan((f[1]-h[1])/(f[0]-h[0]));for(let p=0;p{let s=QT(a),o=Math.round(s/(2*r)),l=a[0],u=a[1];l[0]>u[0]&&(l=a[1],u=a[0]);let h=Math.atan((u[1]-l[1])/(u[0]-l[0]));for(let f=0;f2*Math.PI&&(C=0,L=2*Math.PI);let D=(L-C)/b.curveStepCount,M=[];for(let I=C;I<=L;I+=D)M.push([w+T*Math.cos(I),S+k*Math.sin(I)]);return M.push([w+T*Math.cos(L),S+k*Math.sin(L)]),M.push([w,S]),Mm([M],b)})(e,r,n,i,a,s,u));return u.stroke!==Lo&&h.push(f),this._d("arc",h,u)}curve(e,r){let n=this._o(r),i=[],a=Ure(e,n);if(n.fill&&n.fill!==Lo)if(n.fillStyle==="solid"){let s=Ure(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(s.ops)})}else{let s=[],o=e;if(o.length){let l=typeof o[0][0]=="number"?[o]:o;for(let u of l)u.length<3?s.push(...u):u.length===3?s.push(...SR(Kre([u[0],u[0],u[1],u[2]]),10,(1+n.roughness)/2)):s.push(...SR(Kre(u),10,(1+n.roughness)/2))}s.length&&i.push(Mm([s],n))}return n.stroke!==Lo&&i.push(a),this._d("curve",i,n)}polygon(e,r){let n=this._o(r),i=[],a=YT(e,!0,n);return n.fill&&(n.fillStyle==="solid"?i.push(ER([e],n)):i.push(Mm([e],n))),n.stroke!==Lo&&i.push(a),this._d("polygon",i,n)}path(e,r){let n=this._o(r),i=[];if(!e)return this._d("path",i,n);e=(e||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");let a=n.fill&&n.fill!=="transparent"&&n.fill!==Lo,s=n.stroke!==Lo,o=!!(n.simplification&&n.simplification<1),l=(function(h,f,d){let p=Qre(Zre(BR(h))),g=[],m=[],y=[0,0],v=[],b=()=>{v.length>=4&&m.push(...SR(v,f)),v=[]},w=()=>{b(),m.length&&(g.push(m),m=[])};for(let{key:T,data:k}of p)switch(T){case"M":w(),y=[k[0],k[1]],m.push(y);break;case"L":b(),m.push([k[0],k[1]]);break;case"C":if(!v.length){let C=m.length?m[m.length-1]:y;v.push([C[0],C[1]])}v.push([k[0],k[1]]),v.push([k[2],k[3]]),v.push([k[4],k[5]]);break;case"Z":b(),m.push([y[0],y[1]])}if(w(),!d)return g;let S=[];for(let T of g){let k=CDe(T,d);k.length&&S.push(k)}return S})(e,1,o?4-4*(n.simplification||1):(1+n.roughness)/2),u=Hre(e,n);if(a)if(n.fillStyle==="solid")if(l.length===1){let h=Hre(e,Object.assign(Object.assign({},n),{disableMultiStroke:!0,roughness:n.roughness?n.roughness+n.fillShapeRoughnessGain:0}));i.push({type:"fillPath",ops:this._mergedShape(h.ops)})}else i.push(ER(l,n));else i.push(Mm(l,n));return s&&(o?l.forEach((h=>{i.push(YT(h,!1,n))})):i.push(u)),this._d("path",i,n)}opsToPath(e,r){let n="";for(let i of e.ops){let a=typeof r=="number"&&r>=0?i.data.map((s=>+s.toFixed(r))):i.data;switch(i.op){case"move":n+=`M${a[0]} ${a[1]} `;break;case"bcurveTo":n+=`C${a[0]} ${a[1]}, ${a[2]} ${a[3]}, ${a[4]} ${a[5]} `;break;case"lineTo":n+=`L${a[0]} ${a[1]} `}}return n.trim()}toPaths(e){let r=e.sets||[],n=e.options||this.defaultOptions,i=[];for(let a of r){let s=null;switch(a.type){case"path":s={d:this.opsToPath(a),stroke:n.stroke,strokeWidth:n.strokeWidth,fill:Lo};break;case"fillPath":s={d:this.opsToPath(a),stroke:Lo,strokeWidth:0,fill:n.fill||Lo};break;case"fillSketch":s=this.fillSketch(a,n)}s&&i.push(s)}return i}fillSketch(e,r){let n=r.fillWeight;return n<0&&(n=r.strokeWidth/2),{d:this.opsToPath(e),stroke:r.fill||Lo,strokeWidth:n,fill:Lo}}_mergedShape(e){return e.filter(((r,n)=>n===0||r.op!=="move"))}},OR=class{constructor(e,r){this.canvas=e,this.ctx=this.canvas.getContext("2d"),this.gen=new Om(r)}draw(e){let r=e.sets||[],n=e.options||this.getDefaultOptions(),i=this.ctx,a=e.options.fixedDecimalPlaceDigits;for(let s of r)switch(s.type){case"path":i.save(),i.strokeStyle=n.stroke==="none"?"transparent":n.stroke,i.lineWidth=n.strokeWidth,n.strokeLineDash&&i.setLineDash(n.strokeLineDash),n.strokeLineDashOffset&&(i.lineDashOffset=n.strokeLineDashOffset),this._drawToContext(i,s,a),i.restore();break;case"fillPath":{i.save(),i.fillStyle=n.fill||"";let o=e.shape==="curve"||e.shape==="polygon"||e.shape==="path"?"evenodd":"nonzero";this._drawToContext(i,s,a,o),i.restore();break}case"fillSketch":this.fillSketch(i,s,n)}}fillSketch(e,r,n){let i=n.fillWeight;i<0&&(i=n.strokeWidth/2),e.save(),n.fillLineDash&&e.setLineDash(n.fillLineDash),n.fillLineDashOffset&&(e.lineDashOffset=n.fillLineDashOffset),e.strokeStyle=n.fill||"",e.lineWidth=i,this._drawToContext(e,r,n.fixedDecimalPlaceDigits),e.restore()}_drawToContext(e,r,n,i="nonzero"){e.beginPath();for(let a of r.ops){let s=typeof n=="number"&&n>=0?a.data.map((o=>+o.toFixed(n))):a.data;switch(a.op){case"move":e.moveTo(s[0],s[1]);break;case"bcurveTo":e.bezierCurveTo(s[0],s[1],s[2],s[3],s[4],s[5]);break;case"lineTo":e.lineTo(s[0],s[1])}}r.type==="fillPath"?e.fill(i):e.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(e,r,n,i,a){let s=this.gen.line(e,r,n,i,a);return this.draw(s),s}rectangle(e,r,n,i,a){let s=this.gen.rectangle(e,r,n,i,a);return this.draw(s),s}ellipse(e,r,n,i,a){let s=this.gen.ellipse(e,r,n,i,a);return this.draw(s),s}circle(e,r,n,i){let a=this.gen.circle(e,r,n,i);return this.draw(a),a}linearPath(e,r){let n=this.gen.linearPath(e,r);return this.draw(n),n}polygon(e,r){let n=this.gen.polygon(e,r);return this.draw(n),n}arc(e,r,n,i,a,s,o=!1,l){let u=this.gen.arc(e,r,n,i,a,s,o,l);return this.draw(u),u}curve(e,r){let n=this.gen.curve(e,r);return this.draw(n),n}path(e,r){let n=this.gen.path(e,r);return this.draw(n),n}},HT="http://www.w3.org/2000/svg",PR=class{constructor(e,r){this.svg=e,this.gen=new Om(r)}draw(e){let r=e.sets||[],n=e.options||this.getDefaultOptions(),i=this.svg.ownerDocument||window.document,a=i.createElementNS(HT,"g"),s=e.options.fixedDecimalPlaceDigits;for(let o of r){let l=null;switch(o.type){case"path":l=i.createElementNS(HT,"path"),l.setAttribute("d",this.opsToPath(o,s)),l.setAttribute("stroke",n.stroke),l.setAttribute("stroke-width",n.strokeWidth+""),l.setAttribute("fill","none"),n.strokeLineDash&&l.setAttribute("stroke-dasharray",n.strokeLineDash.join(" ").trim()),n.strokeLineDashOffset&&l.setAttribute("stroke-dashoffset",`${n.strokeLineDashOffset}`);break;case"fillPath":l=i.createElementNS(HT,"path"),l.setAttribute("d",this.opsToPath(o,s)),l.setAttribute("stroke","none"),l.setAttribute("stroke-width","0"),l.setAttribute("fill",n.fill||""),e.shape!=="curve"&&e.shape!=="polygon"||l.setAttribute("fill-rule","evenodd");break;case"fillSketch":l=this.fillSketch(i,o,n)}l&&a.appendChild(l)}return a}fillSketch(e,r,n){let i=n.fillWeight;i<0&&(i=n.strokeWidth/2);let a=e.createElementNS(HT,"path");return a.setAttribute("d",this.opsToPath(r,n.fixedDecimalPlaceDigits)),a.setAttribute("stroke",n.fill||""),a.setAttribute("stroke-width",i+""),a.setAttribute("fill","none"),n.fillLineDash&&a.setAttribute("stroke-dasharray",n.fillLineDash.join(" ").trim()),n.fillLineDashOffset&&a.setAttribute("stroke-dashoffset",`${n.fillLineDashOffset}`),a}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(e,r){return this.gen.opsToPath(e,r)}line(e,r,n,i,a){let s=this.gen.line(e,r,n,i,a);return this.draw(s)}rectangle(e,r,n,i,a){let s=this.gen.rectangle(e,r,n,i,a);return this.draw(s)}ellipse(e,r,n,i,a){let s=this.gen.ellipse(e,r,n,i,a);return this.draw(s)}circle(e,r,n,i){let a=this.gen.circle(e,r,n,i);return this.draw(a)}linearPath(e,r){let n=this.gen.linearPath(e,r);return this.draw(n)}polygon(e,r){let n=this.gen.polygon(e,r);return this.draw(n)}arc(e,r,n,i,a,s,o=!1,l){let u=this.gen.arc(e,r,n,i,a,s,o,l);return this.draw(u)}curve(e,r){let n=this.gen.curve(e,r);return this.draw(n)}path(e,r){let n=this.gen.path(e,r);return this.draw(n)}},Ze={canvas:(t,e)=>new OR(t,e),svg:(t,e)=>new PR(t,e),generator:t=>new Om(t),newSeed:()=>Om.newSeed()}});function Br(t){let e=t.map((r,n)=>`${n===0?"M":"L"}${r.x},${r.y}`);return e.push("Z"),e.join(" ")}function Of(t,e,r,n,i,a){let s=[],l=r-t,u=n-e,h=l/a,f=2*Math.PI/h,d=e+u/2;for(let p=0;p<=50;p++){let g=p/50,m=t+g*l,y=d+i*Math.sin(f*(m-t));s.push({x:m,y})}return s}function mx(t,e,r,n,i,a){let s=[],o=i*Math.PI/180,h=(a*Math.PI/180-o)/(n-1);for(let f=0;f"+i+"";return r.html(ur(s,n)),nne(r,t.labelStyle),r.style("display","inline-block"),r.style("padding-right","1px"),r.style("white-space","nowrap"),r.attr("xmlns","http://www.w3.org/1999/xhtml"),e.node()}function lne(t,e){return t.intersect(e)}function cne(t,e,r,n){var i=t.x,a=t.y,s=i-n.x,o=a-n.y,l=Math.sqrt(e*e*o*o+r*r*s*s),u=Math.abs(e*r*s/l);n.x0}function dne(t,e,r){let n=t.x,i=t.y,a=[],s=Number.POSITIVE_INFINITY,o=Number.POSITIVE_INFINITY;typeof e.forEach=="function"?e.forEach(function(h){s=Math.min(s,h.x),o=Math.min(o,h.y)}):(s=Math.min(s,e.x),o=Math.min(o,e.y));let l=n-t.width/2-s,u=i-t.height/2-o;for(let h=0;h1&&a.sort(function(h,f){let d=h.x-r.x,p=h.y-r.y,g=Math.sqrt(d*d+p*p),m=f.x-r.x,y=f.y-r.y,v=Math.sqrt(m*m+y*y);return gh,":first-child");return f.attr("class","anchor").attr("style",Sa(o)),$t(e,f),e.intersect=function(d){return te.info("Circle intersect",e,s,d),Dt.circle(e,s,d)},a}function zR(t,e,r,n,i,a,s){let l=(t+r)/2,u=(e+n)/2,h=Math.atan2(n-e,r-t),f=(r-t)/2,d=(n-e)/2,p=f/i,g=d/a,m=Math.sqrt(p**2+g**2);if(m>1)throw new Error("The given radii are too small to create an arc between the points.");let y=Math.sqrt(1-m**2),v=l+y*a*Math.sin(h)*(s?-1:1),b=u-y*i*Math.cos(h)*(s?-1:1),w=Math.atan2((e-b)/a,(t-v)/i),T=Math.atan2((n-b)/a,(r-v)/i)-w;s&&T<0&&(T+=2*Math.PI),!s&&T>0&&(T-=2*Math.PI);let k=[];for(let C=0;C<20;C++){let L=C/19,D=w+L*T,M=v+i*Math.cos(D),I=b+a*Math.sin(D);k.push({x:M,y:I})}return k}async function gne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.width+e.padding+20,o=a.height+e.padding,l=o/2,u=l/(2.5+o/50),{cssStyles:h}=e,f=[{x:s/2,y:-o/2},{x:-s/2,y:-o/2},...zR(-s/2,-o/2,-s/2,o/2,u,l,!1),{x:s/2,y:o/2},...zR(s/2,o/2,s/2,-o/2,u,l,!0)],d=Ze.svg(i),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=Br(f),m=d.path(g,p),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),h&&e.look!=="handDrawn"&&y.selectAll("path").attr("style",h),n&&e.look!=="handDrawn"&&y.selectAll("path").attr("style",n),y.attr("transform",`translate(${u/2}, 0)`),$t(e,y),e.intersect=function(v){return Dt.polygon(e,f,v)},i}function Ff(t,e,r,n){return t.insert("polygon",":first-child").attr("points",n.map(function(i){return i.x+","+i.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-e/2+","+r/2+")")}async function mne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.height+e.padding,o=12,l=a.width+e.padding+o,u=0,h=l,f=-s,d=0,p=[{x:u+o,y:f},{x:h,y:f},{x:h,y:d},{x:u,y:d},{x:u,y:f+o},{x:u+o,y:f}],g,{cssStyles:m}=e;if(e.look==="handDrawn"){let y=Ze.svg(i),v=Ft(e,{}),b=Br(p),w=y.path(b,v);g=i.insert(()=>w,":first-child").attr("transform",`translate(${-l/2}, ${s/2})`),m&&g.attr("style",m)}else g=Ff(i,l,s,p);return n&&g.attr("style",n),$t(e,g),e.intersect=function(y){return Dt.polygon(e,p,y)},i}function yne(t,e){let{nodeStyles:r}=Rt(e);e.label="";let n=t.insert("g").attr("class",Zt(e)).attr("id",e.domId??e.id),{cssStyles:i}=e,a=Math.max(28,e.width??0),s=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],o=Ze.svg(n),l=Ft(e,{});e.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");let u=Br(s),h=o.path(u,l),f=n.insert(()=>h,":first-child");return i&&e.look!=="handDrawn"&&f.selectAll("path").attr("style",i),r&&e.look!=="handDrawn"&&f.selectAll("path").attr("style",r),e.width=28,e.height=28,e.intersect=function(d){return Dt.polygon(e,s,d)},n}async function GR(t,e,r){let{labelStyles:n,nodeStyles:i}=Rt(e);e.labelStyle=n;let{shapeSvg:a,bbox:s,halfPadding:o}=await er(t,e,Zt(e)),l=r?.padding??o,u=s.width/2+l,h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Ze.svg(a),p=Ft(e,{}),g=d.circle(0,0,u*2,p);h=a.insert(()=>g,":first-child"),h.attr("class","basic label-container").attr("style",Sa(f))}else h=a.insert("circle",":first-child").attr("class","basic label-container").attr("style",i).attr("r",u).attr("cx",0).attr("cy",0);return $t(e,h),e.calcIntersect=function(d,p){let g=d.width/2;return Dt.circle(d,g,p)},e.intersect=function(d){return te.info("Circle intersect",e,u,d),Dt.circle(e,u,d)},a}function vne(t){let e=Math.cos(Math.PI/4),r=Math.sin(Math.PI/4),n=t*2,i={x:n/2*e,y:n/2*r},a={x:-(n/2)*e,y:n/2*r},s={x:-(n/2)*e,y:-(n/2)*r},o={x:n/2*e,y:-(n/2)*r};return`M ${a.x},${a.y} L ${o.x},${o.y} M ${i.x},${i.y} L ${s.x},${s.y}`}function xne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r,e.label="";let i=t.insert("g").attr("class",Zt(e)).attr("id",e.domId??e.id),a=Math.max(30,e?.width??0),{cssStyles:s}=e,o=Ze.svg(i),l=Ft(e,{});e.look!=="handDrawn"&&(l.roughness=0,l.fillStyle="solid");let u=o.circle(0,0,a*2,l),h=vne(a),f=o.path(h,l),d=i.insert(()=>u,":first-child");return d.insert(()=>f),s&&e.look!=="handDrawn"&&d.selectAll("path").attr("style",s),n&&e.look!=="handDrawn"&&d.selectAll("path").attr("style",n),$t(e,d),e.intersect=function(p){return te.info("crossedCircle intersect",e,{radius:a,point:p}),Dt.circle(e,a,p)},i}function mh(t,e,r,n=100,i=0,a=180){let s=[],o=i*Math.PI/180,h=(a*Math.PI/180-o)/(n-1);for(let f=0;fw,":first-child").attr("stroke-opacity",0),S.insert(()=>v,":first-child"),S.attr("class","text"),h&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",h),n&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",n),S.attr("transform",`translate(${u}, 0)`),s.attr("transform",`translate(${-o/2+u-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),$t(e,S),e.intersect=function(T){return Dt.polygon(e,d,T)},i}function yh(t,e,r,n=100,i=0,a=180){let s=[],o=i*Math.PI/180,h=(a*Math.PI/180-o)/(n-1);for(let f=0;fw,":first-child").attr("stroke-opacity",0),S.insert(()=>v,":first-child"),S.attr("class","text"),h&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",h),n&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",n),S.attr("transform",`translate(${-u}, 0)`),s.attr("transform",`translate(${-o/2+(e.padding??0)/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),$t(e,S),e.intersect=function(T){return Dt.polygon(e,d,T)},i}function _a(t,e,r,n=100,i=0,a=180){let s=[],o=i*Math.PI/180,h=(a*Math.PI/180-o)/(n-1);for(let f=0;fC,":first-child").attr("stroke-opacity",0),L.insert(()=>b,":first-child"),L.insert(()=>T,":first-child"),L.attr("class","text"),h&&e.look!=="handDrawn"&&L.selectAll("path").attr("style",h),n&&e.look!=="handDrawn"&&L.selectAll("path").attr("style",n),L.attr("transform",`translate(${u-u/4}, 0)`),s.attr("transform",`translate(${-o/2+(e.padding??0)/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)/2-(a.y-(a.top??0))})`),$t(e,L),e.intersect=function(D){return Dt.polygon(e,p,D)},i}async function kne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=80,o=20,l=Math.max(s,(a.width+(e.padding??0)*2)*1.25,e?.width??0),u=Math.max(o,a.height+(e.padding??0)*2,e?.height??0),h=u/2,{cssStyles:f}=e,d=Ze.svg(i),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=l,m=u,y=g-h,v=m/4,b=[{x:y,y:0},{x:v,y:0},{x:0,y:m/2},{x:v,y:m},{x:y,y:m},...mx(-y,-m/2,h,50,270,90)],w=Br(b),S=d.path(w,p),T=i.insert(()=>S,":first-child");return T.attr("class","basic label-container"),f&&e.look!=="handDrawn"&&T.selectChildren("path").attr("style",f),n&&e.look!=="handDrawn"&&T.selectChildren("path").attr("style",n),T.attr("transform",`translate(${-l/2}, ${-u/2})`),$t(e,T),e.intersect=function(k){return Dt.polygon(e,b,k)},i}async function Ene(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+e.padding,e.width??0),l=o/2,u=l/(2.5+o/50),h=Math.max(a.height+u+e.padding,e.height??0),f,{cssStyles:d}=e;if(e.look==="handDrawn"){let p=Ze.svg(i),g=zDe(0,0,o,h,l,u),m=GDe(0,u,o,h,l,u),y=p.path(g,Ft(e,{})),v=p.path(m,Ft(e,{fill:"none"}));f=i.insert(()=>v,":first-child"),f=i.insert(()=>y,":first-child"),f.attr("class","basic label-container"),d&&f.attr("style",d)}else{let p=$De(0,0,o,h,l,u);f=i.insert("path",":first-child").attr("d",p).attr("class","basic label-container").attr("style",Sa(d)).attr("style",n)}return f.attr("label-offset-y",u),f.attr("transform",`translate(${-o/2}, ${-(h/2+u)})`),$t(e,f),s.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)+(e.padding??0)/1.5-(a.y-(a.top??0))})`),e.intersect=function(p){let g=Dt.rect(e,p),m=g.x-(e.x??0);if(l!=0&&(Math.abs(m)<(e.width??0)/2||Math.abs(m)==(e.width??0)/2&&Math.abs(g.y-(e.y??0))>(e.height??0)/2-u)){let y=u*u*(1-m*m/(l*l));y>0&&(y=Math.sqrt(y)),y=u-y,p.y-(e.y??0)>0&&(y=-y),g.y+=y}return g},i}async function Sne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=a.width+e.padding,l=a.height+e.padding,u=l*.2,h=-o/2,f=-l/2-u/2,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{});e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let m=[{x:h,y:f+u},{x:-h,y:f+u},{x:-h,y:-f},{x:h,y:-f},{x:h,y:f},{x:-h,y:f},{x:-h,y:f+u}],y=p.polygon(m.map(b=>[b.x,b.y]),g),v=i.insert(()=>y,":first-child");return v.attr("class","basic label-container"),d&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",d),n&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",n),s.attr("transform",`translate(${h+(e.padding??0)/2-(a.x-(a.left??0))}, ${f+u+(e.padding??0)/2-(a.y-(a.top??0))})`),$t(e,v),e.intersect=function(b){return Dt.rect(e,b)},i}async function Cne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,halfPadding:s}=await er(t,e,Zt(e)),l=a.width/2+s+5,u=a.width/2+s,h,{cssStyles:f}=e;if(e.look==="handDrawn"){let d=Ze.svg(i),p=Ft(e,{roughness:.2,strokeWidth:2.5}),g=Ft(e,{roughness:.2,strokeWidth:1.5}),m=d.circle(0,0,l*2,p),y=d.circle(0,0,u*2,g);h=i.insert("g",":first-child"),h.attr("class",Sa(e.cssClasses)).attr("style",Sa(f)),h.node()?.appendChild(m),h.node()?.appendChild(y)}else{h=i.insert("g",":first-child");let d=h.insert("circle",":first-child"),p=h.insert("circle");h.attr("class","basic label-container").attr("style",n),d.attr("class","outer-circle").attr("style",n).attr("r",l).attr("cx",0).attr("cy",0),p.attr("class","inner-circle").attr("style",n).attr("r",u).attr("cx",0).attr("cy",0)}return $t(e,h),e.intersect=function(d){return te.info("DoubleCircle intersect",e,l,d),Dt.circle(e,l,d)},i}function Ane(t,e,{config:{themeVariables:r}}){let{labelStyles:n,nodeStyles:i}=Rt(e);e.label="",e.labelStyle=n;let a=t.insert("g").attr("class",Zt(e)).attr("id",e.domId??e.id),s=7,{cssStyles:o}=e,l=Ze.svg(a),{nodeBorder:u}=r,h=Ft(e,{fillStyle:"solid"});e.look!=="handDrawn"&&(h.roughness=0);let f=l.circle(0,0,s*2,h),d=a.insert(()=>f,":first-child");return d.selectAll("path").attr("style",`fill: ${u} !important;`),o&&o.length>0&&e.look!=="handDrawn"&&d.selectAll("path").attr("style",o),i&&e.look!=="handDrawn"&&d.selectAll("path").attr("style",i),$t(e,d),e.intersect=function(p){return te.info("filledCircle intersect",e,{radius:s,point:p}),Dt.circle(e,s,p)},a}async function _ne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=a.width+(e.padding??0),l=o+a.height,u=o+a.height,h=[{x:0,y:-l},{x:u,y:-l},{x:u/2,y:0}],{cssStyles:f}=e,d=Ze.svg(i),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=Br(h),m=d.path(g,p),y=i.insert(()=>m,":first-child").attr("transform",`translate(${-l/2}, ${l/2})`);return f&&e.look!=="handDrawn"&&y.selectChildren("path").attr("style",f),n&&e.look!=="handDrawn"&&y.selectChildren("path").attr("style",n),e.width=o,e.height=l,$t(e,y),s.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${-l/2+(e.padding??0)/2+(a.y-(a.top??0))})`),e.intersect=function(v){return te.info("Triangle intersect",e,h,v),Dt.polygon(e,h,v)},i}function Lne(t,e,{dir:r,config:{state:n,themeVariables:i}}){let{nodeStyles:a}=Rt(e);e.label="";let s=t.insert("g").attr("class",Zt(e)).attr("id",e.domId??e.id),{cssStyles:o}=e,l=Math.max(70,e?.width??0),u=Math.max(10,e?.height??0);r==="LR"&&(l=Math.max(10,e?.width??0),u=Math.max(70,e?.height??0));let h=-1*l/2,f=-1*u/2,d=Ze.svg(s),p=Ft(e,{stroke:i.lineColor,fill:i.lineColor});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=d.rectangle(h,f,l,u,p),m=s.insert(()=>g,":first-child");o&&e.look!=="handDrawn"&&m.selectAll("path").attr("style",o),a&&e.look!=="handDrawn"&&m.selectAll("path").attr("style",a),$t(e,m);let y=n?.padding??0;return e.width&&e.height&&(e.width+=y/2||0,e.height+=y/2||0),e.intersect=function(v){return Dt.rect(e,v)},s}async function Rne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let i=80,a=50,{shapeSvg:s,bbox:o}=await er(t,e,Zt(e)),l=Math.max(i,o.width+(e.padding??0)*2,e?.width??0),u=Math.max(a,o.height+(e.padding??0)*2,e?.height??0),h=u/2,{cssStyles:f}=e,d=Ze.svg(s),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=[{x:-l/2,y:-u/2},{x:l/2-h,y:-u/2},...mx(-l/2+h,0,h,50,90,270),{x:l/2-h,y:u/2},{x:-l/2,y:u/2}],m=Br(g),y=d.path(m,p),v=s.insert(()=>y,":first-child");return v.attr("class","basic label-container"),f&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",f),n&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",n),$t(e,v),e.intersect=function(b){return te.info("Pill intersect",e,{radius:h,point:b}),Dt.polygon(e,g,b)},s}async function Dne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.height+(e.padding??0),o=a.width+(e.padding??0)*2.5,{cssStyles:l}=e,u=Ze.svg(i),h=Ft(e,{});e.look!=="handDrawn"&&(h.roughness=0,h.fillStyle="solid");let f=o/2,d=f/6;f=f+d;let p=s/2,g=p/2,m=f-g,y=[{x:-m,y:-p},{x:0,y:-p},{x:m,y:-p},{x:f,y:0},{x:m,y:p},{x:0,y:p},{x:-m,y:p},{x:-f,y:0}],v=Br(y),b=u.path(v,h),w=i.insert(()=>b,":first-child");return w.attr("class","basic label-container"),l&&e.look!=="handDrawn"&&w.selectChildren("path").attr("style",l),n&&e.look!=="handDrawn"&&w.selectChildren("path").attr("style",n),e.width=o,e.height=s,$t(e,w),e.intersect=function(S){return Dt.polygon(e,y,S)},i}async function Nne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.label="",e.labelStyle=r;let{shapeSvg:i}=await er(t,e,Zt(e)),a=Math.max(30,e?.width??0),s=Math.max(30,e?.height??0),{cssStyles:o}=e,l=Ze.svg(i),u=Ft(e,{});e.look!=="handDrawn"&&(u.roughness=0,u.fillStyle="solid");let h=[{x:0,y:0},{x:a,y:0},{x:0,y:s},{x:a,y:s}],f=Br(h),d=l.path(f,u),p=i.insert(()=>d,":first-child");return p.attr("class","basic label-container"),o&&e.look!=="handDrawn"&&p.selectChildren("path").attr("style",o),n&&e.look!=="handDrawn"&&p.selectChildren("path").attr("style",n),p.attr("transform",`translate(${-a/2}, ${-s/2})`),$t(e,p),e.intersect=function(g){return te.info("Pill intersect",e,{points:h}),Dt.polygon(e,h,g)},i}async function Ine(t,e,{config:{themeVariables:r,flowchart:n}}){let{labelStyles:i}=Rt(e);e.labelStyle=i;let a=e.assetHeight??48,s=e.assetWidth??48,o=Math.max(a,s),l=n?.wrappingWidth;e.width=Math.max(o,l??0);let{shapeSvg:u,bbox:h,label:f}=await er(t,e,"icon-shape default"),d=e.pos==="t",p=o,g=o,{nodeBorder:m}=r,{stylesMap:y}=Up(e),v=-g/2,b=-p/2,w=e.label?8:0,S=Ze.svg(u),T=Ft(e,{stroke:"none",fill:"none"});e.look!=="handDrawn"&&(T.roughness=0,T.fillStyle="solid");let k=S.rectangle(v,b,g,p,T),C=Math.max(g,h.width),L=p+h.height+w,D=S.rectangle(-C/2,-L/2,C,L,{...T,fill:"transparent",stroke:"none"}),M=u.insert(()=>k,":first-child"),I=u.insert(()=>D);if(e.icon){let E=u.append("g");E.html(`${await ru(e.icon,{height:o,width:o,fallbackPrefix:""})}`);let _=E.node().getBBox(),A=_.width,R=_.height,N=_.x,O=_.y;E.attr("transform",`translate(${-A/2-N},${d?h.height/2+w/2-R/2-O:-h.height/2-w/2-R/2-O})`),E.attr("style",`color: ${y.get("stroke")??m};`)}return f.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${d?-L/2:L/2-h.height})`),M.attr("transform",`translate(0,${d?h.height/2+w/2:-h.height/2-w/2})`),$t(e,I),e.intersect=function(E){if(te.info("iconSquare intersect",e,E),!e.label)return Dt.rect(e,E);let _=e.x??0,A=e.y??0,R=e.height??0,N=[];return d?N=[{x:_-h.width/2,y:A-R/2},{x:_+h.width/2,y:A-R/2},{x:_+h.width/2,y:A-R/2+h.height+w},{x:_+g/2,y:A-R/2+h.height+w},{x:_+g/2,y:A+R/2},{x:_-g/2,y:A+R/2},{x:_-g/2,y:A-R/2+h.height+w},{x:_-h.width/2,y:A-R/2+h.height+w}]:N=[{x:_-g/2,y:A-R/2},{x:_+g/2,y:A-R/2},{x:_+g/2,y:A-R/2+p},{x:_+h.width/2,y:A-R/2+p},{x:_+h.width/2/2,y:A+R/2},{x:_-h.width/2,y:A+R/2},{x:_-h.width/2,y:A-R/2+p},{x:_-g/2,y:A-R/2+p}],Dt.polygon(e,N,E)},u}async function Mne(t,e,{config:{themeVariables:r,flowchart:n}}){let{labelStyles:i}=Rt(e);e.labelStyle=i;let a=e.assetHeight??48,s=e.assetWidth??48,o=Math.max(a,s),l=n?.wrappingWidth;e.width=Math.max(o,l??0);let{shapeSvg:u,bbox:h,label:f}=await er(t,e,"icon-shape default"),d=20,p=e.label?8:0,g=e.pos==="t",{nodeBorder:m,mainBkg:y}=r,{stylesMap:v}=Up(e),b=Ze.svg(u),w=Ft(e,{});e.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");let S=v.get("fill");w.stroke=S??y;let T=u.append("g");e.icon&&T.html(`${await ru(e.icon,{height:o,width:o,fallbackPrefix:""})}`);let k=T.node().getBBox(),C=k.width,L=k.height,D=k.x,M=k.y,I=Math.max(C,L)*Math.SQRT2+d*2,E=b.circle(0,0,I,w),_=Math.max(I,h.width),A=I+h.height+p,R=b.rectangle(-_/2,-A/2,_,A,{...w,fill:"transparent",stroke:"none"}),N=u.insert(()=>E,":first-child"),O=u.insert(()=>R);return T.attr("transform",`translate(${-C/2-D},${g?h.height/2+p/2-L/2-M:-h.height/2-p/2-L/2-M})`),T.attr("style",`color: ${v.get("stroke")??m};`),f.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${g?-A/2:A/2-h.height})`),N.attr("transform",`translate(0,${g?h.height/2+p/2:-h.height/2-p/2})`),$t(e,O),e.intersect=function(P){return te.info("iconSquare intersect",e,P),Dt.rect(e,P)},u}async function One(t,e,{config:{themeVariables:r,flowchart:n}}){let{labelStyles:i}=Rt(e);e.labelStyle=i;let a=e.assetHeight??48,s=e.assetWidth??48,o=Math.max(a,s),l=n?.wrappingWidth;e.width=Math.max(o,l??0);let{shapeSvg:u,bbox:h,halfPadding:f,label:d}=await er(t,e,"icon-shape default"),p=e.pos==="t",g=o+f*2,m=o+f*2,{nodeBorder:y,mainBkg:v}=r,{stylesMap:b}=Up(e),w=-m/2,S=-g/2,T=e.label?8:0,k=Ze.svg(u),C=Ft(e,{});e.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");let L=b.get("fill");C.stroke=L??v;let D=k.path(Bf(w,S,m,g,5),C),M=Math.max(m,h.width),I=g+h.height+T,E=k.rectangle(-M/2,-I/2,M,I,{...C,fill:"transparent",stroke:"none"}),_=u.insert(()=>D,":first-child").attr("class","icon-shape2"),A=u.insert(()=>E);if(e.icon){let R=u.append("g");R.html(`${await ru(e.icon,{height:o,width:o,fallbackPrefix:""})}`);let N=R.node().getBBox(),O=N.width,P=N.height,B=N.x,G=N.y;R.attr("transform",`translate(${-O/2-B},${p?h.height/2+T/2-P/2-G:-h.height/2-T/2-P/2-G})`),R.attr("style",`color: ${b.get("stroke")??y};`)}return d.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${p?-I/2:I/2-h.height})`),_.attr("transform",`translate(0,${p?h.height/2+T/2:-h.height/2-T/2})`),$t(e,A),e.intersect=function(R){if(te.info("iconSquare intersect",e,R),!e.label)return Dt.rect(e,R);let N=e.x??0,O=e.y??0,P=e.height??0,B=[];return p?B=[{x:N-h.width/2,y:O-P/2},{x:N+h.width/2,y:O-P/2},{x:N+h.width/2,y:O-P/2+h.height+T},{x:N+m/2,y:O-P/2+h.height+T},{x:N+m/2,y:O+P/2},{x:N-m/2,y:O+P/2},{x:N-m/2,y:O-P/2+h.height+T},{x:N-h.width/2,y:O-P/2+h.height+T}]:B=[{x:N-m/2,y:O-P/2},{x:N+m/2,y:O-P/2},{x:N+m/2,y:O-P/2+g},{x:N+h.width/2,y:O-P/2+g},{x:N+h.width/2/2,y:O+P/2},{x:N-h.width/2,y:O+P/2},{x:N-h.width/2,y:O-P/2+g},{x:N-m/2,y:O-P/2+g}],Dt.polygon(e,B,R)},u}async function Pne(t,e,{config:{themeVariables:r,flowchart:n}}){let{labelStyles:i}=Rt(e);e.labelStyle=i;let a=e.assetHeight??48,s=e.assetWidth??48,o=Math.max(a,s),l=n?.wrappingWidth;e.width=Math.max(o,l??0);let{shapeSvg:u,bbox:h,halfPadding:f,label:d}=await er(t,e,"icon-shape default"),p=e.pos==="t",g=o+f*2,m=o+f*2,{nodeBorder:y,mainBkg:v}=r,{stylesMap:b}=Up(e),w=-m/2,S=-g/2,T=e.label?8:0,k=Ze.svg(u),C=Ft(e,{});e.look!=="handDrawn"&&(C.roughness=0,C.fillStyle="solid");let L=b.get("fill");C.stroke=L??v;let D=k.path(Bf(w,S,m,g,.1),C),M=Math.max(m,h.width),I=g+h.height+T,E=k.rectangle(-M/2,-I/2,M,I,{...C,fill:"transparent",stroke:"none"}),_=u.insert(()=>D,":first-child"),A=u.insert(()=>E);if(e.icon){let R=u.append("g");R.html(`${await ru(e.icon,{height:o,width:o,fallbackPrefix:""})}`);let N=R.node().getBBox(),O=N.width,P=N.height,B=N.x,G=N.y;R.attr("transform",`translate(${-O/2-B},${p?h.height/2+T/2-P/2-G:-h.height/2-T/2-P/2-G})`),R.attr("style",`color: ${b.get("stroke")??y};`)}return d.attr("transform",`translate(${-h.width/2-(h.x-(h.left??0))},${p?-I/2:I/2-h.height})`),_.attr("transform",`translate(0,${p?h.height/2+T/2:-h.height/2-T/2})`),$t(e,A),e.intersect=function(R){if(te.info("iconSquare intersect",e,R),!e.label)return Dt.rect(e,R);let N=e.x??0,O=e.y??0,P=e.height??0,B=[];return p?B=[{x:N-h.width/2,y:O-P/2},{x:N+h.width/2,y:O-P/2},{x:N+h.width/2,y:O-P/2+h.height+T},{x:N+m/2,y:O-P/2+h.height+T},{x:N+m/2,y:O+P/2},{x:N-m/2,y:O+P/2},{x:N-m/2,y:O-P/2+h.height+T},{x:N-h.width/2,y:O-P/2+h.height+T}]:B=[{x:N-m/2,y:O-P/2},{x:N+m/2,y:O-P/2},{x:N+m/2,y:O-P/2+g},{x:N+h.width/2,y:O-P/2+g},{x:N+h.width/2/2,y:O+P/2},{x:N-h.width/2,y:O+P/2},{x:N-h.width/2,y:O-P/2+g},{x:N-m/2,y:O-P/2+g}],Dt.polygon(e,B,R)},u}async function Bne(t,e,{config:{flowchart:r}}){let n=new Image;n.src=e?.img??"",await n.decode();let i=Number(n.naturalWidth.toString().replace("px","")),a=Number(n.naturalHeight.toString().replace("px",""));e.imageAspectRatio=i/a;let{labelStyles:s}=Rt(e);e.labelStyle=s;let o=r?.wrappingWidth;e.defaultWidth=r?.wrappingWidth;let l=Math.max(e.label?o??0:0,e?.assetWidth??i),u=e.constraint==="on"&&e?.assetHeight?e.assetHeight*e.imageAspectRatio:l,h=e.constraint==="on"?u/e.imageAspectRatio:e?.assetHeight??a;e.width=Math.max(u,o??0);let{shapeSvg:f,bbox:d,label:p}=await er(t,e,"image-shape default"),g=e.pos==="t",m=-u/2,y=-h/2,v=e.label?8:0,b=Ze.svg(f),w=Ft(e,{});e.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");let S=b.rectangle(m,y,u,h,w),T=Math.max(u,d.width),k=h+d.height+v,C=b.rectangle(-T/2,-k/2,T,k,{...w,fill:"none",stroke:"none"}),L=f.insert(()=>S,":first-child"),D=f.insert(()=>C);if(e.img){let M=f.append("image");M.attr("href",e.img),M.attr("width",u),M.attr("height",h),M.attr("preserveAspectRatio","none"),M.attr("transform",`translate(${-u/2},${g?k/2-h:-k/2})`)}return p.attr("transform",`translate(${-d.width/2-(d.x-(d.left??0))},${g?-h/2-d.height/2-v/2:h/2-d.height/2+v/2})`),L.attr("transform",`translate(0,${g?d.height/2+v/2:-d.height/2-v/2})`),$t(e,D),e.intersect=function(M){if(te.info("iconSquare intersect",e,M),!e.label)return Dt.rect(e,M);let I=e.x??0,E=e.y??0,_=e.height??0,A=[];return g?A=[{x:I-d.width/2,y:E-_/2},{x:I+d.width/2,y:E-_/2},{x:I+d.width/2,y:E-_/2+d.height+v},{x:I+u/2,y:E-_/2+d.height+v},{x:I+u/2,y:E+_/2},{x:I-u/2,y:E+_/2},{x:I-u/2,y:E-_/2+d.height+v},{x:I-d.width/2,y:E-_/2+d.height+v}]:A=[{x:I-u/2,y:E-_/2},{x:I+u/2,y:E-_/2},{x:I+u/2,y:E-_/2+h},{x:I+d.width/2,y:E-_/2+h},{x:I+d.width/2/2,y:E+_/2},{x:I-d.width/2,y:E+_/2},{x:I-d.width/2,y:E-_/2+h},{x:I-u/2,y:E-_/2+h}],Dt.polygon(e,A,M)},f}async function Fne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=Math.max(a.width+(e.padding??0)*2,e?.width??0),o=Math.max(a.height+(e.padding??0)*2,e?.height??0),l=[{x:0,y:0},{x:s,y:0},{x:s+3*o/6,y:-o},{x:-3*o/6,y:-o}],u,{cssStyles:h}=e;if(e.look==="handDrawn"){let f=Ze.svg(i),d=Ft(e,{}),p=Br(l),g=f.path(p,d);u=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),h&&u.attr("style",h)}else u=Ff(i,s,o,l);return n&&u.attr("style",n),e.width=s,e.height=o,$t(e,u),e.intersect=function(f){return Dt.polygon(e,l,f)},i}async function JT(t,e,r){let{labelStyles:n,nodeStyles:i}=Rt(e);e.labelStyle=n;let{shapeSvg:a,bbox:s}=await er(t,e,Zt(e)),o=Math.max(s.width+r.labelPaddingX*2,e?.width||0),l=Math.max(s.height+r.labelPaddingY*2,e?.height||0),u=-o/2,h=-l/2,f,{rx:d,ry:p}=e,{cssStyles:g}=e;if(r?.rx&&r.ry&&(d=r.rx,p=r.ry),e.look==="handDrawn"){let m=Ze.svg(a),y=Ft(e,{}),v=d||p?m.path(Bf(u,h,o,l,d||0),y):m.rectangle(u,h,o,l,y);f=a.insert(()=>v,":first-child"),f.attr("class","basic label-container").attr("style",Sa(g))}else f=a.insert("rect",":first-child"),f.attr("class","basic label-container").attr("style",i).attr("rx",Sa(d)).attr("ry",Sa(p)).attr("x",u).attr("y",h).attr("width",o).attr("height",l);return $t(e,f),e.calcIntersect=function(m,y){return Dt.rect(m,y)},e.intersect=function(m){return Dt.rect(e,m)},a}async function $ne(t,e){let{shapeSvg:r,bbox:n,label:i}=await er(t,e,"label"),a=r.insert("rect",":first-child");return a.attr("width",.1).attr("height",.1),r.attr("class","label edgeLabel"),i.attr("transform",`translate(${-(n.width/2)-(n.x-(n.left??0))}, ${-(n.height/2)-(n.y-(n.top??0))})`),$t(e,a),e.intersect=function(l){return Dt.rect(e,l)},r}async function zne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=Math.max(a.width+(e.padding??0),e?.width??0),o=Math.max(a.height+(e.padding??0),e?.height??0),l=[{x:0,y:0},{x:s+3*o/6,y:0},{x:s,y:-o},{x:-(3*o)/6,y:-o}],u,{cssStyles:h}=e;if(e.look==="handDrawn"){let f=Ze.svg(i),d=Ft(e,{}),p=Br(l),g=f.path(p,d);u=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),h&&u.attr("style",h)}else u=Ff(i,s,o,l);return n&&u.attr("style",n),e.width=s,e.height=o,$t(e,u),e.intersect=function(f){return Dt.polygon(e,l,f)},i}async function Gne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=Math.max(a.width+(e.padding??0),e?.width??0),o=Math.max(a.height+(e.padding??0),e?.height??0),l=[{x:-3*o/6,y:0},{x:s,y:0},{x:s+3*o/6,y:-o},{x:0,y:-o}],u,{cssStyles:h}=e;if(e.look==="handDrawn"){let f=Ze.svg(i),d=Ft(e,{}),p=Br(l),g=f.path(p,d);u=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),h&&u.attr("style",h)}else u=Ff(i,s,o,l);return n&&u.attr("style",n),e.width=s,e.height=o,$t(e,u),e.intersect=function(f){return Dt.polygon(e,l,f)},i}function qne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.label="",e.labelStyle=r;let i=t.insert("g").attr("class",Zt(e)).attr("id",e.domId??e.id),{cssStyles:a}=e,s=Math.max(35,e?.width??0),o=Math.max(35,e?.height??0),l=7,u=[{x:s,y:0},{x:0,y:o+l/2},{x:s-2*l,y:o+l/2},{x:0,y:2*o},{x:s,y:o-l/2},{x:2*l,y:o-l/2}],h=Ze.svg(i),f=Ft(e,{});e.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");let d=Br(u),p=h.path(d,f),g=i.insert(()=>p,":first-child");return a&&e.look!=="handDrawn"&&g.selectAll("path").attr("style",a),n&&e.look!=="handDrawn"&&g.selectAll("path").attr("style",n),g.attr("transform",`translate(-${s/2},${-o})`),$t(e,g),e.intersect=function(m){return te.info("lightningBolt intersect",e,m),Dt.polygon(e,u,m)},i}async function Vne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0),e.width??0),l=o/2,u=l/(2.5+o/50),h=Math.max(a.height+u+(e.padding??0),e.height??0),f=h*.1,d,{cssStyles:p}=e;if(e.look==="handDrawn"){let g=Ze.svg(i),m=VDe(0,0,o,h,l,u,f),y=UDe(0,u,o,h,l,u),v=Ft(e,{}),b=g.path(m,v),w=g.path(y,v);i.insert(()=>w,":first-child").attr("class","line"),d=i.insert(()=>b,":first-child"),d.attr("class","basic label-container"),p&&d.attr("style",p)}else{let g=qDe(0,0,o,h,l,u,f);d=i.insert("path",":first-child").attr("d",g).attr("class","basic label-container").attr("style",Sa(p)).attr("style",n)}return d.attr("label-offset-y",u),d.attr("transform",`translate(${-o/2}, ${-(h/2+u)})`),$t(e,d),s.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)+u-(a.y-(a.top??0))})`),e.intersect=function(g){let m=Dt.rect(e,g),y=m.x-(e.x??0);if(l!=0&&(Math.abs(y)<(e.width??0)/2||Math.abs(y)==(e.width??0)/2&&Math.abs(m.y-(e.y??0))>(e.height??0)/2-u)){let v=u*u*(1-y*y/(l*l));v>0&&(v=Math.sqrt(v)),v=u-v,g.y-(e.y??0)>0&&(v=-v),m.y+=v}return m},i}async function Une(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=l/4,h=l+u,{cssStyles:f}=e,d=Ze.svg(i),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=[{x:-o/2-o/2*.1,y:-h/2},{x:-o/2-o/2*.1,y:h/2},...Of(-o/2-o/2*.1,h/2,o/2+o/2*.1,h/2,u,.8),{x:o/2+o/2*.1,y:-h/2},{x:-o/2-o/2*.1,y:-h/2},{x:-o/2,y:-h/2},{x:-o/2,y:h/2*1.1},{x:-o/2,y:-h/2}],m=d.polygon(g.map(v=>[v.x,v.y]),p),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),f&&e.look!=="handDrawn"&&y.selectAll("path").attr("style",f),n&&e.look!=="handDrawn"&&y.selectAll("path").attr("style",n),y.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)+o/2*.1/2-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u/2-(a.y-(a.top??0))})`),$t(e,y),e.intersect=function(v){return Dt.polygon(e,g,v)},i}async function Wne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=5,h=-o/2,f=-l/2,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{}),m=[{x:h-u,y:f+u},{x:h-u,y:f+l+u},{x:h+o-u,y:f+l+u},{x:h+o-u,y:f+l},{x:h+o,y:f+l},{x:h+o,y:f+l-u},{x:h+o+u,y:f+l-u},{x:h+o+u,y:f-u},{x:h+u,y:f-u},{x:h+u,y:f},{x:h,y:f},{x:h,y:f+u}],y=[{x:h,y:f+u},{x:h+o-u,y:f+u},{x:h+o-u,y:f+l},{x:h+o,y:f+l},{x:h+o,y:f},{x:h,y:f}];e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let v=Br(m),b=p.path(v,g),w=Br(y),S=p.path(w,{...g,fill:"none"}),T=i.insert(()=>S,":first-child");return T.insert(()=>b,":first-child"),T.attr("class","basic label-container"),d&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",d),n&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",n),s.attr("transform",`translate(${-(a.width/2)-u-(a.x-(a.left??0))}, ${-(a.height/2)+u-(a.y-(a.top??0))})`),$t(e,T),e.intersect=function(k){return Dt.polygon(e,m,k)},i}async function Hne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=l/4,h=l+u,f=-o/2,d=-h/2,p=5,{cssStyles:g}=e,m=Of(f-p,d+h+p,f+o-p,d+h+p,u,.8),y=m?.[m.length-1],v=[{x:f-p,y:d+p},{x:f-p,y:d+h+p},...m,{x:f+o-p,y:y.y-p},{x:f+o,y:y.y-p},{x:f+o,y:y.y-2*p},{x:f+o+p,y:y.y-2*p},{x:f+o+p,y:d-p},{x:f+p,y:d-p},{x:f+p,y:d},{x:f,y:d},{x:f,y:d+p}],b=[{x:f,y:d+p},{x:f+o-p,y:d+p},{x:f+o-p,y:y.y-p},{x:f+o,y:y.y-p},{x:f+o,y:d},{x:f,y:d}],w=Ze.svg(i),S=Ft(e,{});e.look!=="handDrawn"&&(S.roughness=0,S.fillStyle="solid");let T=Br(v),k=w.path(T,S),C=Br(b),L=w.path(C,S),D=i.insert(()=>k,":first-child");return D.insert(()=>L),D.attr("class","basic label-container"),g&&e.look!=="handDrawn"&&D.selectAll("path").attr("style",g),n&&e.look!=="handDrawn"&&D.selectAll("path").attr("style",n),D.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-(a.width/2)-p-(a.x-(a.left??0))}, ${-(a.height/2)+p-u/2-(a.y-(a.top??0))})`),$t(e,D),e.intersect=function(M){return Dt.polygon(e,v,M)},i}async function Yne(t,e,{config:{themeVariables:r}}){let{labelStyles:n,nodeStyles:i}=Rt(e);e.labelStyle=n,e.useHtmlLabels||fr().flowchart?.htmlLabels!==!1||(e.centerLabel=!0);let{shapeSvg:s,bbox:o,label:l}=await er(t,e,Zt(e)),u=Math.max(o.width+(e.padding??0)*2,e?.width??0),h=Math.max(o.height+(e.padding??0)*2,e?.height??0),f=-u/2,d=-h/2,{cssStyles:p}=e,g=Ze.svg(s),m=Ft(e,{fill:r.noteBkgColor,stroke:r.noteBorderColor});e.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let y=g.rectangle(f,d,u,h,m),v=s.insert(()=>y,":first-child");return v.attr("class","basic label-container"),p&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",p),i&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",i),l.attr("transform",`translate(${-o.width/2-(o.x-(o.left??0))}, ${-(o.height/2)-(o.y-(o.top??0))})`),$t(e,v),e.intersect=function(b){return Dt.rect(e,b)},s}async function Xne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.width+e.padding,o=a.height+e.padding,l=s+o,u=.5,h=[{x:l/2,y:0},{x:l,y:-l/2},{x:l/2,y:-l},{x:0,y:-l/2}],f,{cssStyles:d}=e;if(e.look==="handDrawn"){let p=Ze.svg(i),g=Ft(e,{}),m=WDe(0,0,l),y=p.path(m,g);f=i.insert(()=>y,":first-child").attr("transform",`translate(${-l/2+u}, ${l/2})`),d&&f.attr("style",d)}else f=Ff(i,l,l,h),f.attr("transform",`translate(${-l/2+u}, ${l/2})`);return n&&f.attr("style",n),$t(e,f),e.calcIntersect=function(p,g){let m=p.width,y=[{x:m/2,y:0},{x:m,y:-m/2},{x:m/2,y:-m},{x:0,y:-m/2}],v=Dt.polygon(p,y,g);return{x:v.x-.5,y:v.y-.5}},e.intersect=function(p){return this.calcIntersect(e,p)},i}async function jne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0),e?.width??0),l=Math.max(a.height+(e.padding??0),e?.height??0),u=-o/2,h=-l/2,f=h/2,d=[{x:u+f,y:h},{x:u,y:0},{x:u+f,y:-h},{x:-u,y:-h},{x:-u,y:h}],{cssStyles:p}=e,g=Ze.svg(i),m=Ft(e,{});e.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let y=Br(d),v=g.path(y,m),b=i.insert(()=>v,":first-child");return b.attr("class","basic label-container"),p&&e.look!=="handDrawn"&&b.selectAll("path").attr("style",p),n&&e.look!=="handDrawn"&&b.selectAll("path").attr("style",n),b.attr("transform",`translate(${-f/2},0)`),s.attr("transform",`translate(${-f/2-a.width/2-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),$t(e,b),e.intersect=function(w){return Dt.polygon(e,d,w)},i}async function Kne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let i;e.cssClasses?i="node "+e.cssClasses:i="node default";let a=t.insert("g").attr("class",i).attr("id",e.domId||e.id),s=a.insert("g"),o=a.insert("g").attr("class","label").attr("style",n),l=e.description,u=e.label,h=o.node().appendChild(await Pf(u,e.labelStyle,!0,!0)),f={width:0,height:0};if(Kr(Te()?.flowchart?.htmlLabels)){let L=h.children[0],D=Ye(h);f=L.getBoundingClientRect(),D.attr("width",f.width),D.attr("height",f.height)}te.info("Text 2",l);let d=l||[],p=h.getBBox(),g=o.node().appendChild(await Pf(d.join?d.join("
    "):d,e.labelStyle,!0,!0)),m=g.children[0],y=Ye(g);f=m.getBoundingClientRect(),y.attr("width",f.width),y.attr("height",f.height);let v=(e.padding||0)/2;Ye(g).attr("transform","translate( "+(f.width>p.width?0:(p.width-f.width)/2)+", "+(p.height+v+5)+")"),Ye(h).attr("transform","translate( "+(f.width(te.debug("Rough node insert CXC",M),I),":first-child"),k=a.insert(()=>(te.debug("Rough node insert CXC",M),M),":first-child")}else k=s.insert("rect",":first-child"),C=s.insert("line"),k.attr("class","outer title-state").attr("style",n).attr("x",-f.width/2-v).attr("y",-f.height/2-v).attr("width",f.width+(e.padding||0)).attr("height",f.height+(e.padding||0)),C.attr("class","divider").attr("x1",-f.width/2-v).attr("x2",f.width/2+v).attr("y1",-f.height/2-v+p.height+v).attr("y2",-f.height/2-v+p.height+v);return $t(e,k),e.intersect=function(L){return Dt.rect(e,L)},a}function px(t,e,r,n,i,a,s){let l=(t+r)/2,u=(e+n)/2,h=Math.atan2(n-e,r-t),f=(r-t)/2,d=(n-e)/2,p=f/i,g=d/a,m=Math.sqrt(p**2+g**2);if(m>1)throw new Error("The given radii are too small to create an arc between the points.");let y=Math.sqrt(1-m**2),v=l+y*a*Math.sin(h)*(s?-1:1),b=u-y*i*Math.cos(h)*(s?-1:1),w=Math.atan2((e-b)/a,(t-v)/i),T=Math.atan2((n-b)/a,(r-v)/i)-w;s&&T<0&&(T+=2*Math.PI),!s&&T>0&&(T-=2*Math.PI);let k=[];for(let C=0;C<20;C++){let L=C/19,D=w+L*T,M=v+i*Math.cos(D),I=b+a*Math.sin(D);k.push({x:M,y:I})}return k}async function Zne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=e?.padding??0,o=e?.padding??0,l=(e?.width?e?.width:a.width)+s*2,u=(e?.height?e?.height:a.height)+o*2,h=e.radius||5,f=e.taper||5,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{});e.stroke&&(g.stroke=e.stroke),e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let m=[{x:-l/2+f,y:-u/2},{x:l/2-f,y:-u/2},...px(l/2-f,-u/2,l/2,-u/2+f,h,h,!0),{x:l/2,y:-u/2+f},{x:l/2,y:u/2-f},...px(l/2,u/2-f,l/2-f,u/2,h,h,!0),{x:l/2-f,y:u/2},{x:-l/2+f,y:u/2},...px(-l/2+f,u/2,-l/2,u/2-f,h,h,!0),{x:-l/2,y:u/2-f},{x:-l/2,y:-u/2+f},...px(-l/2,-u/2+f,-l/2+f,-u/2,h,h,!0)],y=Br(m),v=p.path(y,g),b=i.insert(()=>v,":first-child");return b.attr("class","basic label-container outer-path"),d&&e.look!=="handDrawn"&&b.selectChildren("path").attr("style",d),n&&e.look!=="handDrawn"&&b.selectChildren("path").attr("style",n),$t(e,b),e.intersect=function(w){return Dt.polygon(e,m,w)},i}async function Qne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=e?.padding??0,l=Math.max(a.width+(e.padding??0)*2,e?.width??0),u=Math.max(a.height+(e.padding??0)*2,e?.height??0),h=-a.width/2-o,f=-a.height/2-o,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{});e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let m=[{x:h,y:f},{x:h+l+8,y:f},{x:h+l+8,y:f+u},{x:h-8,y:f+u},{x:h-8,y:f},{x:h,y:f},{x:h,y:f+u}],y=p.polygon(m.map(b=>[b.x,b.y]),g),v=i.insert(()=>y,":first-child");return v.attr("class","basic label-container").attr("style",Sa(d)),n&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",n),d&&e.look!=="handDrawn"&&v.selectAll("path").attr("style",n),s.attr("transform",`translate(${-l/2+4+(e.padding??0)-(a.x-(a.left??0))},${-u/2+(e.padding??0)-(a.y-(a.top??0))})`),$t(e,v),e.intersect=function(b){return Dt.rect(e,b)},i}async function Jne(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=-o/2,h=-l/2,{cssStyles:f}=e,d=Ze.svg(i),p=Ft(e,{});e.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let g=[{x:u,y:h},{x:u,y:h+l},{x:u+o,y:h+l},{x:u+o,y:h-l/2}],m=Br(g),y=d.path(m,p),v=i.insert(()=>y,":first-child");return v.attr("class","basic label-container"),f&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",f),n&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",n),v.attr("transform",`translate(0, ${l/4})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))}, ${-l/4+(e.padding??0)-(a.y-(a.top??0))})`),$t(e,v),e.intersect=function(b){return Dt.polygon(e,g,b)},i}async function eie(t,e){let r={rx:0,ry:0,classes:"",labelPaddingX:e.labelPaddingX??(e?.padding||0)*2,labelPaddingY:(e?.padding||0)*1};return JT(t,e,r)}async function tie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.height+e.padding,o=a.width+s/4+e.padding,l=s/2,{cssStyles:u}=e,h=Ze.svg(i),f=Ft(e,{});e.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");let d=[{x:-o/2+l,y:-s/2},{x:o/2-l,y:-s/2},...mx(-o/2+l,0,l,50,90,270),{x:o/2-l,y:s/2},...mx(o/2-l,0,l,50,270,450)],p=Br(d),g=h.path(p,f),m=i.insert(()=>g,":first-child");return m.attr("class","basic label-container outer-path"),u&&e.look!=="handDrawn"&&m.selectChildren("path").attr("style",u),n&&e.look!=="handDrawn"&&m.selectChildren("path").attr("style",n),$t(e,m),e.intersect=function(y){return Dt.polygon(e,d,y)},i}async function rie(t,e){return JT(t,e,{rx:5,ry:5,classes:"flowchart-node"})}function nie(t,e,{config:{themeVariables:r}}){let{labelStyles:n,nodeStyles:i}=Rt(e);e.labelStyle=n;let{cssStyles:a}=e,{lineColor:s,stateBorder:o,nodeBorder:l}=r,u=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),h=Ze.svg(u),f=Ft(e,{});e.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");let d=h.circle(0,0,14,{...f,stroke:s,strokeWidth:2}),p=o??l,g=h.circle(0,0,5,{...f,fill:p,stroke:p,strokeWidth:2,fillStyle:"solid"}),m=u.insert(()=>d,":first-child");return m.insert(()=>g),a&&m.selectAll("path").attr("style",a),i&&m.selectAll("path").attr("style",i),$t(e,m),e.intersect=function(y){return Dt.circle(e,7,y)},u}function iie(t,e,{config:{themeVariables:r}}){let{lineColor:n}=r,i=t.insert("g").attr("class","node default").attr("id",e.domId||e.id),a;if(e.look==="handDrawn"){let o=Ze.svg(i).circle(0,0,14,VJ(n));a=i.insert(()=>o),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14)}else a=i.insert("circle",":first-child"),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14);return $t(e,a),e.intersect=function(s){return Dt.circle(e,7,s)},i}async function aie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=(e?.padding||0)/2,o=a.width+e.padding,l=a.height+e.padding,u=-a.width/2-s,h=-a.height/2-s,f=[{x:0,y:0},{x:o,y:0},{x:o,y:-l},{x:0,y:-l},{x:0,y:0},{x:-8,y:0},{x:o+8,y:0},{x:o+8,y:-l},{x:-8,y:-l},{x:-8,y:0}];if(e.look==="handDrawn"){let d=Ze.svg(i),p=Ft(e,{}),g=d.rectangle(u-8,h,o+16,l,p),m=d.line(u,h,u,h+l,p),y=d.line(u+o,h,u+o,h+l,p);i.insert(()=>m,":first-child"),i.insert(()=>y,":first-child");let v=i.insert(()=>g,":first-child"),{cssStyles:b}=e;v.attr("class","basic label-container").attr("style",Sa(b)),$t(e,v)}else{let d=Ff(i,o,l,f);n&&d.attr("style",n),$t(e,d)}return e.intersect=function(d){return Dt.polygon(e,f,d)},i}async function sie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=Math.max(a.width+(e.padding??0)*2,e?.width??0),o=Math.max(a.height+(e.padding??0)*2,e?.height??0),l=-s/2,u=-o/2,h=.2*o,f=.2*o,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{}),m=[{x:l-h/2,y:u},{x:l+s+h/2,y:u},{x:l+s+h/2,y:u+o},{x:l-h/2,y:u+o}],y=[{x:l+s-h/2,y:u+o},{x:l+s+h/2,y:u+o},{x:l+s+h/2,y:u+o-f}];e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let v=Br(m),b=p.path(v,g),w=Br(y),S=p.path(w,{...g,fillStyle:"solid"}),T=i.insert(()=>S,":first-child");return T.insert(()=>b,":first-child"),T.attr("class","basic label-container"),d&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",d),n&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",n),$t(e,T),e.intersect=function(k){return Dt.polygon(e,m,k)},i}async function oie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=l/4,h=.2*o,f=.2*l,d=l+u,{cssStyles:p}=e,g=Ze.svg(i),m=Ft(e,{});e.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let y=[{x:-o/2-o/2*.1,y:d/2},...Of(-o/2-o/2*.1,d/2,o/2+o/2*.1,d/2,u,.8),{x:o/2+o/2*.1,y:-d/2},{x:-o/2-o/2*.1,y:-d/2}],v=-o/2+o/2*.1,b=-d/2-f*.4,w=[{x:v+o-h,y:(b+l)*1.4},{x:v+o,y:b+l-f},{x:v+o,y:(b+l)*.9},...Of(v+o,(b+l)*1.3,v+o-h,(b+l)*1.5,-l*.03,.5)],S=Br(y),T=g.path(S,m),k=Br(w),C=g.path(k,{...m,fillStyle:"solid"}),L=i.insert(()=>C,":first-child");return L.insert(()=>T,":first-child"),L.attr("class","basic label-container"),p&&e.look!=="handDrawn"&&L.selectAll("path").attr("style",p),n&&e.look!=="handDrawn"&&L.selectAll("path").attr("style",n),L.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u/2-(a.y-(a.top??0))})`),$t(e,L),e.intersect=function(D){return Dt.polygon(e,y,D)},i}async function lie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=Math.max(a.width+e.padding,e?.width||0),o=Math.max(a.height+e.padding,e?.height||0),l=-s/2,u=-o/2,h=i.insert("rect",":first-child");return h.attr("class","text").attr("style",n).attr("rx",0).attr("ry",0).attr("x",l).attr("y",u).attr("width",s).attr("height",o),$t(e,h),e.intersect=function(f){return Dt.rect(e,f)},i}async function cie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s,halfPadding:o}=await er(t,e,Zt(e)),l=e.look==="neo"?o*2:o,u=a.height+l,h=u/2,f=h/(2.5+u/50),d=a.width+f+l,{cssStyles:p}=e,g;if(e.look==="handDrawn"){let m=Ze.svg(i),y=YDe(0,0,d,u,f,h),v=XDe(0,0,d,u,f,h),b=m.path(y,Ft(e,{})),w=m.path(v,Ft(e,{fill:"none"}));g=i.insert(()=>w,":first-child"),g=i.insert(()=>b,":first-child"),g.attr("class","basic label-container"),p&&g.attr("style",p)}else{let m=HDe(0,0,d,u,f,h);g=i.insert("path",":first-child").attr("d",m).attr("class","basic label-container").attr("style",Sa(p)).attr("style",n),g.attr("class","basic label-container"),p&&g.selectAll("path").attr("style",p),n&&g.selectAll("path").attr("style",n)}return g.attr("label-offset-x",f),g.attr("transform",`translate(${-d/2}, ${u/2} )`),s.attr("transform",`translate(${-(a.width/2)-f-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),$t(e,g),e.intersect=function(m){let y=Dt.rect(e,m),v=y.y-(e.y??0);if(h!=0&&(Math.abs(v)<(e.height??0)/2||Math.abs(v)==(e.height??0)/2&&Math.abs(y.x-(e.x??0))>(e.width??0)/2-f)){let b=f*f*(1-v*v/(h*h));b!=0&&(b=Math.sqrt(Math.abs(b))),b=f-b,m.x-(e.x??0)>0&&(b=-b),y.x+=b}return y},i}async function uie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=a.width+e.padding,o=a.height+e.padding,l=[{x:-3*o/6,y:0},{x:s+3*o/6,y:0},{x:s,y:-o},{x:0,y:-o}],u,{cssStyles:h}=e;if(e.look==="handDrawn"){let f=Ze.svg(i),d=Ft(e,{}),p=Br(l),g=f.path(p,d);u=i.insert(()=>g,":first-child").attr("transform",`translate(${-s/2}, ${o/2})`),h&&u.attr("style",h)}else u=Ff(i,s,o,l);return n&&u.attr("style",n),e.width=s,e.height=o,$t(e,u),e.intersect=function(f){return Dt.polygon(e,l,f)},i}async function hie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=60,o=20,l=Math.max(s,a.width+(e.padding??0)*2,e?.width??0),u=Math.max(o,a.height+(e.padding??0)*2,e?.height??0),{cssStyles:h}=e,f=Ze.svg(i),d=Ft(e,{});e.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");let p=[{x:-l/2*.8,y:-u/2},{x:l/2*.8,y:-u/2},{x:l/2,y:-u/2*.6},{x:l/2,y:u/2},{x:-l/2,y:u/2},{x:-l/2,y:-u/2*.6}],g=Br(p),m=f.path(g,d),y=i.insert(()=>m,":first-child");return y.attr("class","basic label-container"),h&&e.look!=="handDrawn"&&y.selectChildren("path").attr("style",h),n&&e.look!=="handDrawn"&&y.selectChildren("path").attr("style",n),$t(e,y),e.intersect=function(v){return Dt.polygon(e,p,v)},i}async function fie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Kr(Te().flowchart?.htmlLabels),l=a.width+(e.padding??0),u=l+a.height,h=l+a.height,f=[{x:0,y:0},{x:h,y:0},{x:h/2,y:-u}],{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{});e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let m=Br(f),y=p.path(m,g),v=i.insert(()=>y,":first-child").attr("transform",`translate(${-u/2}, ${u/2})`);return d&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",d),n&&e.look!=="handDrawn"&&v.selectChildren("path").attr("style",n),e.width=l,e.height=u,$t(e,v),s.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${u/2-(a.height+(e.padding??0)/(o?2:1)-(a.y-(a.top??0)))})`),e.intersect=function(b){return te.info("Triangle intersect",e,f,b),Dt.polygon(e,f,b)},i}async function die(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=l/8,h=l+u,{cssStyles:f}=e,p=70-o,g=p>0?p/2:0,m=Ze.svg(i),y=Ft(e,{});e.look!=="handDrawn"&&(y.roughness=0,y.fillStyle="solid");let v=[{x:-o/2-g,y:h/2},...Of(-o/2-g,h/2,o/2+g,h/2,u,.8),{x:o/2+g,y:-h/2},{x:-o/2-g,y:-h/2}],b=Br(v),w=m.path(b,y),S=i.insert(()=>w,":first-child");return S.attr("class","basic label-container"),f&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",f),n&&e.look!=="handDrawn"&&S.selectAll("path").attr("style",n),S.attr("transform",`translate(0,${-u/2})`),s.attr("transform",`translate(${-o/2+(e.padding??0)-(a.x-(a.left??0))},${-l/2+(e.padding??0)-u-(a.y-(a.top??0))})`),$t(e,S),e.intersect=function(T){return Dt.polygon(e,v,T)},i}async function pie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a}=await er(t,e,Zt(e)),s=100,o=50,l=Math.max(a.width+(e.padding??0)*2,e?.width??0),u=Math.max(a.height+(e.padding??0)*2,e?.height??0),h=l/u,f=l,d=u;f>d*h?d=f/h:f=d*h,f=Math.max(f,s),d=Math.max(d,o);let p=Math.min(d*.2,d/4),g=d+p*2,{cssStyles:m}=e,y=Ze.svg(i),v=Ft(e,{});e.look!=="handDrawn"&&(v.roughness=0,v.fillStyle="solid");let b=[{x:-f/2,y:g/2},...Of(-f/2,g/2,f/2,g/2,p,1),{x:f/2,y:-g/2},...Of(f/2,-g/2,-f/2,-g/2,p,-1)],w=Br(b),S=y.path(w,v),T=i.insert(()=>S,":first-child");return T.attr("class","basic label-container"),m&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",m),n&&e.look!=="handDrawn"&&T.selectAll("path").attr("style",n),$t(e,T),e.intersect=function(k){return Dt.polygon(e,b,k)},i}async function gie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,label:s}=await er(t,e,Zt(e)),o=Math.max(a.width+(e.padding??0)*2,e?.width??0),l=Math.max(a.height+(e.padding??0)*2,e?.height??0),u=5,h=-o/2,f=-l/2,{cssStyles:d}=e,p=Ze.svg(i),g=Ft(e,{}),m=[{x:h-u,y:f-u},{x:h-u,y:f+l},{x:h+o,y:f+l},{x:h+o,y:f-u}],y=`M${h-u},${f-u} L${h+o},${f-u} L${h+o},${f+l} L${h-u},${f+l} L${h-u},${f-u} M${h-u},${f} L${h+o},${f} M${h},${f-u} L${h},${f+l}`;e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let v=p.path(y,g),b=i.insert(()=>v,":first-child");return b.attr("transform",`translate(${u/2}, ${u/2})`),b.attr("class","basic label-container"),d&&e.look!=="handDrawn"&&b.selectAll("path").attr("style",d),n&&e.look!=="handDrawn"&&b.selectAll("path").attr("style",n),s.attr("transform",`translate(${-(a.width/2)+u/2-(a.x-(a.left??0))}, ${-(a.height/2)+u/2-(a.y-(a.top??0))})`),$t(e,b),e.intersect=function(w){return Dt.polygon(e,m,w)},i}async function qR(t,e){let r=e;if(r.alias&&(e.label=r.alias),e.look==="handDrawn"){let{themeVariables:q}=fr(),{background:j}=q,J={...e,id:e.id+"-background",look:"default",cssStyles:["stroke: none",`fill: ${j}`]};await qR(t,J)}let n=fr();e.useHtmlLabels=n.htmlLabels;let i=n.er?.diagramPadding??10,a=n.er?.entityPadding??6,{cssStyles:s}=e,{labelStyles:o,nodeStyles:l}=Rt(e);if(r.attributes.length===0&&e.label){let q={rx:0,ry:0,labelPaddingX:i,labelPaddingY:i*1.5,classes:""};Ea(e.label,n)+q.labelPaddingX*20){let q=f.width+i*2-(m+y+v+b);m+=q/T,y+=q/T,v>0&&(v+=q/T),b>0&&(b+=q/T)}let C=m+y+v+b,L=Ze.svg(h),D=Ft(e,{});e.look!=="handDrawn"&&(D.roughness=0,D.fillStyle="solid");let M=0;g.length>0&&(M=g.reduce((q,j)=>q+(j?.rowHeight??0),0));let I=Math.max(k.width+i*2,e?.width||0,C),E=Math.max((M??0)+f.height,e?.height||0),_=-I/2,A=-E/2;h.selectAll("g:not(:first-child)").each((q,j,J)=>{let H=Ye(J[j]),he=H.attr("transform"),Z=0,fe=0;if(he){let re=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(he);re&&(Z=parseFloat(re[1]),fe=parseFloat(re[2]),H.attr("class").includes("attribute-name")?Z+=m:H.attr("class").includes("attribute-keys")?Z+=m+y:H.attr("class").includes("attribute-comment")&&(Z+=m+y+v))}H.attr("transform",`translate(${_+i/2+Z}, ${fe+A+f.height+a/2})`)}),h.select(".name").attr("transform","translate("+-f.width/2+", "+(A+a/2)+")");let R=L.rectangle(_,A,I,E,D),N=h.insert(()=>R,":first-child").attr("style",s.join("")),{themeVariables:O}=fr(),{rowEven:P,rowOdd:B,nodeBorder:G}=O;p.push(0);for(let[q,j]of g.entries()){let H=(q+1)%2===0&&j.yOffset!==0,he=L.rectangle(_,f.height+A+j?.yOffset,I,j?.rowHeight,{...D,fill:H?P:B,stroke:G});h.insert(()=>he,"g.label").attr("style",s.join("")).attr("class",`row-rect-${H?"even":"odd"}`)}let F=L.line(_,f.height+A,I+_,f.height+A,D);h.insert(()=>F).attr("class","divider"),F=L.line(m+_,f.height+A,m+_,E+A,D),h.insert(()=>F).attr("class","divider"),w&&(F=L.line(m+y+_,f.height+A,m+y+_,E+A,D),h.insert(()=>F).attr("class","divider")),S&&(F=L.line(m+y+v+_,f.height+A,m+y+v+_,E+A,D),h.insert(()=>F).attr("class","divider"));for(let q of p)F=L.line(_,f.height+A+q,I+_,f.height+A+q,D),h.insert(()=>F).attr("class","divider");if($t(e,N),l&&e.look!=="handDrawn"){let j=l.split(";")?.filter(J=>J.includes("stroke"))?.map(J=>`${J}`).join("; ");h.selectAll("path").attr("style",j??""),h.selectAll(".row-rect-even path").attr("style",l)}return e.intersect=function(q){return Dt.rect(e,q)},h}async function Pm(t,e,r,n=0,i=0,a=[],s=""){let o=t.insert("g").attr("class",`label ${a.join(" ")}`).attr("transform",`translate(${n}, ${i})`).attr("style",s);e!==Pc(e)&&(e=Pc(e),e=e.replaceAll("<","<").replaceAll(">",">"));let l=o.node().appendChild(await Ca(o,e,{width:Ea(e,r)+100,style:s,useHtmlLabels:r.htmlLabels},r));if(e.includes("<")||e.includes(">")){let h=l.children[0];for(h.textContent=h.textContent.replaceAll("<","<").replaceAll(">",">");h.childNodes[0];)h=h.childNodes[0],h.textContent=h.textContent.replaceAll("<","<").replaceAll(">",">")}let u=l.getBBox();if(Kr(r.htmlLabels)){let h=l.children[0];h.style.textAlign="start";let f=Ye(l);u=h.getBoundingClientRect(),f.attr("width",u.width),f.attr("height",u.height)}return u}async function mie(t,e,r,n,i=r.class.padding??12){let a=n?0:3,s=t.insert("g").attr("class",Zt(e)).attr("id",e.domId||e.id),o=null,l=null,u=null,h=null,f=0,d=0,p=0;if(o=s.insert("g").attr("class","annotation-group text"),e.annotations.length>0){let b=e.annotations[0];await gx(o,{text:`\xAB${b}\xBB`},0),f=o.node().getBBox().height}l=s.insert("g").attr("class","label-group text"),await gx(l,e,0,["font-weight: bolder"]);let g=l.node().getBBox();d=g.height,u=s.insert("g").attr("class","members-group text");let m=0;for(let b of e.members){let w=await gx(u,b,m,[b.parseClassifier()]);m+=w+a}p=u.node().getBBox().height,p<=0&&(p=i/2),h=s.insert("g").attr("class","methods-group text");let y=0;for(let b of e.methods){let w=await gx(h,b,y,[b.parseClassifier()]);y+=w+a}let v=s.node().getBBox();if(o!==null){let b=o.node().getBBox();o.attr("transform",`translate(${-b.width/2})`)}return l.attr("transform",`translate(${-g.width/2}, ${f})`),v=s.node().getBBox(),u.attr("transform",`translate(0, ${f+d+i*2})`),v=s.node().getBBox(),h.attr("transform",`translate(0, ${f+d+(p?p+i*4:i*2)})`),v=s.node().getBBox(),{shapeSvg:s,bbox:v}}async function gx(t,e,r,n=[]){let i=t.insert("g").attr("class","label").attr("style",n.join("; ")),a=fr(),s="useHtmlLabels"in e?e.useHtmlLabels:Kr(a.htmlLabels)??!0,o="";"text"in e?o=e.text:o=e.label,!s&&o.startsWith("\\")&&(o=o.substring(1)),qn(o)&&(s=!0);let l=await Ca(i,B5(Ks(o)),{width:Ea(o,a)+50,classes:"markdown-node-label",useHtmlLabels:s},a),u,h=1;if(s){let f=l.children[0],d=Ye(l);h=f.innerHTML.split("
    ").length,f.innerHTML.includes("")&&(h+=f.innerHTML.split("").length-1);let p=f.getElementsByTagName("img");if(p){let g=o.replace(/]*>/g,"").trim()==="";await Promise.all([...p].map(m=>new Promise(y=>{function v(){if(m.style.display="flex",m.style.flexDirection="column",g){let b=a.fontSize?.toString()??window.getComputedStyle(document.body).fontSize,S=parseInt(b,10)*5+"px";m.style.minWidth=S,m.style.maxWidth=S}else m.style.width="100%";y(m)}x(v,"setupImage"),setTimeout(()=>{m.complete&&v()}),m.addEventListener("error",v),m.addEventListener("load",v)})))}u=f.getBoundingClientRect(),d.attr("width",u.width),d.attr("height",u.height)}else{n.includes("font-weight: bolder")&&Ye(l).selectAll("tspan").attr("font-weight",""),h=l.children.length;let f=l.children[0];(l.textContent===""||l.textContent.includes(">"))&&(f.textContent=o[0]+o.substring(1).replaceAll(">",">").replaceAll("<","<").trim(),o[1]===" "&&(f.textContent=f.textContent[0]+" "+f.textContent.substring(1))),f.textContent==="undefined"&&(f.textContent=""),u=l.getBBox()}return i.attr("transform","translate(0,"+(-u.height/(2*h)+r)+")"),u.height}async function yie(t,e){let r=Te(),n=r.class.padding??12,i=n,a=e.useHtmlLabels??Kr(r.htmlLabels)??!0,s=e;s.annotations=s.annotations??[],s.members=s.members??[],s.methods=s.methods??[];let{shapeSvg:o,bbox:l}=await mie(t,e,r,a,i),{labelStyles:u,nodeStyles:h}=Rt(e);e.labelStyle=u,e.cssStyles=s.styles||"";let f=s.styles?.join(";")||h||"";e.cssStyles||(e.cssStyles=f.replaceAll("!important","").split(";"));let d=s.members.length===0&&s.methods.length===0&&!r.class?.hideEmptyMembersBox,p=Ze.svg(o),g=Ft(e,{});e.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let m=l.width,y=l.height;s.members.length===0&&s.methods.length===0?y+=i:s.members.length>0&&s.methods.length===0&&(y+=i*2);let v=-m/2,b=-y/2,w=p.rectangle(v-n,b-n-(d?n:s.members.length===0&&s.methods.length===0?-n/2:0),m+2*n,y+2*n+(d?n*2:s.members.length===0&&s.methods.length===0?-n:0),g),S=o.insert(()=>w,":first-child");S.attr("class","basic label-container");let T=S.node().getBBox();o.selectAll(".text").each((D,M,I)=>{let E=Ye(I[M]),_=E.attr("transform"),A=0;if(_){let P=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(_);P&&(A=parseFloat(P[2]))}let R=A+b+n-(d?n:s.members.length===0&&s.methods.length===0?-n/2:0);a||(R-=4);let N=v;(E.attr("class").includes("label-group")||E.attr("class").includes("annotation-group"))&&(N=-E.node()?.getBBox().width/2||0,o.selectAll("text").each(function(O,P,B){window.getComputedStyle(B[P]).textAnchor==="middle"&&(N=0)})),E.attr("transform",`translate(${N}, ${R})`)});let k=o.select(".annotation-group").node().getBBox().height-(d?n/2:0)||0,C=o.select(".label-group").node().getBBox().height-(d?n/2:0)||0,L=o.select(".members-group").node().getBBox().height-(d?n/2:0)||0;if(s.members.length>0||s.methods.length>0||d){let D=p.line(T.x,k+C+b+n,T.x+T.width,k+C+b+n,g);o.insert(()=>D).attr("class","divider").attr("style",f)}if(d||s.members.length>0||s.methods.length>0){let D=p.line(T.x,k+C+L+b+i*2+n,T.x+T.width,k+C+L+b+n+i*2,g);o.insert(()=>D).attr("class","divider").attr("style",f)}if(s.look!=="handDrawn"&&o.selectAll("path").attr("style",f),S.select(":nth-child(2)").attr("style",f),o.selectAll(".divider").select("path").attr("style",f),e.labelStyle?o.selectAll("span").attr("style",e.labelStyle):o.selectAll("span").attr("style",f),!a){let D=RegExp(/color\s*:\s*([^;]*)/),M=D.exec(f);if(M){let I=M[0].replace("color","fill");o.selectAll("tspan").attr("style",I)}else if(u){let I=D.exec(u);if(I){let E=I[0].replace("color","fill");o.selectAll("tspan").attr("style",E)}}}return $t(e,S),e.intersect=function(D){return Dt.rect(e,D)},o}async function vie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let i=e,a=e,s=20,o=20,l="verifyMethod"in e,u=Zt(e),h=t.insert("g").attr("class",u).attr("id",e.domId??e.id),f;l?f=await nu(h,`<<${i.type}>>`,0,e.labelStyle):f=await nu(h,"<<Element>>",0,e.labelStyle);let d=f,p=await nu(h,i.name,d,e.labelStyle+"; font-weight: bold;");if(d+=p+o,l){let k=await nu(h,`${i.requirementId?`ID: ${i.requirementId}`:""}`,d,e.labelStyle);d+=k;let C=await nu(h,`${i.text?`Text: ${i.text}`:""}`,d,e.labelStyle);d+=C;let L=await nu(h,`${i.risk?`Risk: ${i.risk}`:""}`,d,e.labelStyle);d+=L,await nu(h,`${i.verifyMethod?`Verification: ${i.verifyMethod}`:""}`,d,e.labelStyle)}else{let k=await nu(h,`${a.type?`Type: ${a.type}`:""}`,d,e.labelStyle);d+=k,await nu(h,`${a.docRef?`Doc Ref: ${a.docRef}`:""}`,d,e.labelStyle)}let g=(h.node()?.getBBox().width??200)+s,m=(h.node()?.getBBox().height??200)+s,y=-g/2,v=-m/2,b=Ze.svg(h),w=Ft(e,{});e.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");let S=b.rectangle(y,v,g,m,w),T=h.insert(()=>S,":first-child");if(T.attr("class","basic label-container").attr("style",n),h.selectAll(".label").each((k,C,L)=>{let D=Ye(L[C]),M=D.attr("transform"),I=0,E=0;if(M){let N=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(M);N&&(I=parseFloat(N[1]),E=parseFloat(N[2]))}let _=E-m/2,A=y+s/2;(C===0||C===1)&&(A=I),D.attr("transform",`translate(${A}, ${_+s})`)}),d>f+p+o){let k=b.line(y,v+f+p+o,y+g,v+f+p+o,w);h.insert(()=>k).attr("style",n)}return $t(e,T),e.intersect=function(k){return Dt.rect(e,k)},h}async function nu(t,e,r,n=""){if(e==="")return 0;let i=t.insert("g").attr("class","label").attr("style",n),a=Te(),s=a.htmlLabels??!0,o=await Ca(i,B5(Ks(e)),{width:Ea(e,a)+50,classes:"markdown-node-label",useHtmlLabels:s,style:n},a),l;if(s){let u=o.children[0],h=Ye(o);l=u.getBoundingClientRect(),h.attr("width",l.width),h.attr("height",l.height)}else{let u=o.children[0];for(let h of u.children)h.textContent=h.textContent.replaceAll(">",">").replaceAll("<","<"),n&&h.setAttribute("style",n);l=o.getBBox(),l.height+=6}return i.attr("transform",`translate(${-l.width/2},${-l.height/2+r})`),l.height}async function xie(t,e,{config:r}){let{labelStyles:n,nodeStyles:i}=Rt(e);e.labelStyle=n||"";let a=10,s=e.width;e.width=(e.width??200)-10;let{shapeSvg:o,bbox:l,label:u}=await er(t,e,Zt(e)),h=e.padding||10,f="",d;"ticket"in e&&e.ticket&&r?.kanban?.ticketBaseUrl&&(f=r?.kanban?.ticketBaseUrl.replace("#TICKET#",e.ticket),d=o.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",f).attr("target","_blank"));let p={useHtmlLabels:e.useHtmlLabels,labelStyle:e.labelStyle||"",width:e.width,img:e.img,padding:e.padding||8,centerLabel:!1},g,m;d?{label:g,bbox:m}=await FR(d,"ticket"in e&&e.ticket||"",p):{label:g,bbox:m}=await FR(o,"ticket"in e&&e.ticket||"",p);let{label:y,bbox:v}=await FR(o,"assigned"in e&&e.assigned||"",p);e.width=s;let b=10,w=e?.width||0,S=Math.max(m.height,v.height)/2,T=Math.max(l.height+b*2,e?.height||0)+S,k=-w/2,C=-T/2;u.attr("transform","translate("+(h-w/2)+", "+(-S-l.height/2)+")"),g.attr("transform","translate("+(h-w/2)+", "+(-S+l.height/2)+")"),y.attr("transform","translate("+(h+w/2-v.width-2*a)+", "+(-S+l.height/2)+")");let L,{rx:D,ry:M}=e,{cssStyles:I}=e;if(e.look==="handDrawn"){let E=Ze.svg(o),_=Ft(e,{}),A=D||M?E.path(Bf(k,C,w,T,D||0),_):E.rectangle(k,C,w,T,_);L=o.insert(()=>A,":first-child"),L.attr("class","basic label-container").attr("style",I||null)}else{L=o.insert("rect",":first-child"),L.attr("class","basic label-container __APA__").attr("style",i).attr("rx",D??5).attr("ry",M??5).attr("x",k).attr("y",C).attr("width",w).attr("height",T);let E="priority"in e&&e.priority;if(E){let _=o.append("line"),A=k+2,R=C+Math.floor((D??0)/2),N=C+T-Math.floor((D??0)/2);_.attr("x1",A).attr("y1",R).attr("x2",A).attr("y2",N).attr("stroke-width","4").attr("stroke",jDe(E))}}return $t(e,L),e.height=T,e.intersect=function(E){return Dt.rect(e,E)},o}async function bie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,halfPadding:s,label:o}=await er(t,e,Zt(e)),l=a.width+10*s,u=a.height+8*s,h=.15*l,{cssStyles:f}=e,d=a.width+20,p=a.height+20,g=Math.max(l,d),m=Math.max(u,p);o.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`);let y,v=`M0 0 a${h},${h} 1 0,0 ${g*.25},${-1*m*.1} a${h},${h} 1 0,0 ${g*.25},0 a${h},${h} 1 0,0 ${g*.25},0 a${h},${h} 1 0,0 ${g*.25},${m*.1} a${h},${h} 1 0,0 ${g*.15},${m*.33} a${h*.8},${h*.8} 1 0,0 0,${m*.34} a${h},${h} 1 0,0 ${-1*g*.15},${m*.33} a${h},${h} 1 0,0 ${-1*g*.25},${m*.15} a${h},${h} 1 0,0 ${-1*g*.25},0 a${h},${h} 1 0,0 ${-1*g*.25},0 a${h},${h} 1 0,0 ${-1*g*.25},${-1*m*.15} a${h},${h} 1 0,0 ${-1*g*.1},${-1*m*.33} a${h*.8},${h*.8} 1 0,0 0,${-1*m*.34} a${h},${h} 1 0,0 ${g*.1},${-1*m*.33} H0 V0 Z`;if(e.look==="handDrawn"){let b=Ze.svg(i),w=Ft(e,{}),S=b.path(v,w);y=i.insert(()=>S,":first-child"),y.attr("class","basic label-container").attr("style",Sa(f))}else y=i.insert("path",":first-child").attr("class","basic label-container").attr("style",n).attr("d",v);return y.attr("transform",`translate(${-g/2}, ${-m/2})`),$t(e,y),e.calcIntersect=function(b,w){return Dt.rect(b,w)},e.intersect=function(b){return te.info("Bang intersect",e,b),Dt.rect(e,b)},i}async function wie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,halfPadding:s,label:o}=await er(t,e,Zt(e)),l=a.width+2*s,u=a.height+2*s,h=.15*l,f=.25*l,d=.35*l,p=.2*l,{cssStyles:g}=e,m,y=`M0 0 a${h},${h} 0 0,1 ${l*.25},${-1*l*.1} a${d},${d} 1 0,1 ${l*.4},${-1*l*.1} a${f},${f} 1 0,1 ${l*.35},${l*.2} a${h},${h} 1 0,1 ${l*.15},${u*.35} a${p},${p} 1 0,1 ${-1*l*.15},${u*.65} a${f},${h} 1 0,1 ${-1*l*.25},${l*.15} a${d},${d} 1 0,1 ${-1*l*.5},0 a${h},${h} 1 0,1 ${-1*l*.25},${-1*l*.15} a${h},${h} 1 0,1 ${-1*l*.1},${-1*u*.35} a${p},${p} 1 0,1 ${l*.1},${-1*u*.65} H0 V0 Z`;if(e.look==="handDrawn"){let v=Ze.svg(i),b=Ft(e,{}),w=v.path(y,b);m=i.insert(()=>w,":first-child"),m.attr("class","basic label-container").attr("style",Sa(g))}else m=i.insert("path",":first-child").attr("class","basic label-container").attr("style",n).attr("d",y);return o.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`),m.attr("transform",`translate(${-l/2}, ${-u/2})`),$t(e,m),e.calcIntersect=function(v,b){return Dt.rect(v,b)},e.intersect=function(v){return te.info("Cloud intersect",e,v),Dt.rect(e,v)},i}async function Tie(t,e){let{labelStyles:r,nodeStyles:n}=Rt(e);e.labelStyle=r;let{shapeSvg:i,bbox:a,halfPadding:s,label:o}=await er(t,e,Zt(e)),l=a.width+8*s,u=a.height+2*s,h=5,f=` M${-l/2} ${u/2-h} v${-u+2*h} q0,-${h} ${h},-${h} h${l-2*h} q${h},0 ${h},${h} v${u-2*h} q0,${h} -${h},${h} h${-l+2*h} q-${h},0 -${h},-${h} Z `,d=i.append("path").attr("id","node-"+e.id).attr("class","node-bkg node-"+e.type).attr("style",n).attr("d",f);return i.append("line").attr("class","node-line-").attr("x1",-l/2).attr("y1",u/2).attr("x2",l/2).attr("y2",u/2),o.attr("transform",`translate(${-a.width/2}, ${-a.height/2})`),i.append(()=>o.node()),$t(e,d),e.calcIntersect=function(p,g){return Dt.rect(p,g)},e.intersect=function(p){return Dt.rect(e,p)},i}async function kie(t,e){let r={padding:e.padding??0};return GR(t,e,r)}function VR(t){return t in Eie}async function t0(t,e,r){let n,i;e.shape==="rect"&&(e.rx&&e.ry?e.shape="roundedRect":e.shape="squareRect");let a=e.shape?Eie[e.shape]:void 0;if(!a)throw new Error(`No such shape: ${e.shape}. Please check your syntax.`);if(e.link){let s;r.config.securityLevel==="sandbox"?s="_top":e.linkTarget&&(s=e.linkTarget||"_blank"),n=t.insert("svg:a").attr("xlink:href",e.link).attr("target",s??null),i=await a(n,e,r)}else i=await a(t,e,r),n=i;return e.tooltip&&i.attr("title",e.tooltip),ek.set(e.id,n),e.haveCallback&&n.attr("class",n.attr("class")+" clickable"),n}var er,FR,$t,Zt,ADe,Bm,_De,Pf,Bf,ane,LDe,RDe,DDe,NDe,IDe,MDe,sne,Fm,one,ODe,une,PDe,BDe,FDe,Dt,$De,zDe,GDe,qDe,VDe,UDe,WDe,HDe,YDe,XDe,jDe,KDe,ZDe,Eie,ek,Sie,Cie,yx,Qs=$(()=>{xs();bs();Aa();bn();Er();lr();pr();pr();zt();pr();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();pr();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();zt();pr();pr();zt();pr();zt();pr();zt();zt();zt();er=x(async(t,e,r)=>{let n,i=e.useHtmlLabels||Kr(Te()?.htmlLabels);r?n=r:n="node default";let a=t.insert("g").attr("class",n).attr("id",e.domId||e.id),s=a.insert("g").attr("class","label").attr("style",Sa(e.labelStyle)),o;e.label===void 0?o="":o=typeof e.label=="string"?e.label:e.label[0];let l=await Ca(s,ur(Ks(o),Te()),{useHtmlLabels:i,width:e.width||Te().flowchart?.wrappingWidth,cssClasses:"markdown-node-label",style:e.labelStyle,addSvgBackground:!!e.icon||!!e.img}),u=l.getBBox(),h=(e?.padding??0)/2;if(i){let f=l.children[0],d=Ye(l),p=f.getElementsByTagName("img");if(p){let g=o.replace(/]*>/g,"").trim()==="";await Promise.all([...p].map(m=>new Promise(y=>{function v(){if(m.style.display="flex",m.style.flexDirection="column",g){let b=Te().fontSize?Te().fontSize:window.getComputedStyle(document.body).fontSize,w=5,[S=hr.fontSize]=Jc(b),T=S*w+"px";m.style.minWidth=T,m.style.maxWidth=T}else m.style.width="100%";y(m)}x(v,"setupImage"),setTimeout(()=>{m.complete&&v()}),m.addEventListener("error",v),m.addEventListener("load",v)})))}u=f.getBoundingClientRect(),d.attr("width",u.width),d.attr("height",u.height)}return i?s.attr("transform","translate("+-u.width/2+", "+-u.height/2+")"):s.attr("transform","translate(0, "+-u.height/2+")"),e.centerLabel&&s.attr("transform","translate("+-u.width/2+", "+-u.height/2+")"),s.insert("rect",":first-child"),{shapeSvg:a,bbox:u,halfPadding:h,label:s}},"labelHelper"),FR=x(async(t,e,r)=>{let n=r.useHtmlLabels||Kr(Te()?.flowchart?.htmlLabels),i=t.insert("g").attr("class","label").attr("style",r.labelStyle||""),a=await Ca(i,ur(Ks(e),Te()),{useHtmlLabels:n,width:r.width||Te()?.flowchart?.wrappingWidth,style:r.labelStyle,addSvgBackground:!!r.icon||!!r.img}),s=a.getBBox(),o=r.padding/2;if(Kr(Te()?.flowchart?.htmlLabels)){let l=a.children[0],u=Ye(a);s=l.getBoundingClientRect(),u.attr("width",s.width),u.attr("height",s.height)}return n?i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"):i.attr("transform","translate(0, "+-s.height/2+")"),r.centerLabel&&i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),i.insert("rect",":first-child"),{shapeSvg:t,bbox:s,halfPadding:o,label:i}},"insertLabel"),$t=x((t,e)=>{let r=e.node().getBBox();t.width=r.width,t.height=r.height},"updateNodeBounds"),Zt=x((t,e)=>(t.look==="handDrawn"?"rough-node":"node")+" "+t.cssClasses+" "+(e||""),"getNodeClasses");x(Br,"createPathFromPoints");x(Of,"generateFullSineWavePoints");x(mx,"generateCirclePoints");ADe=x((t,e)=>{var r=t.x,n=t.y,i=e.x-r,a=e.y-n,s=t.width/2,o=t.height/2,l,u;return Math.abs(a)*s>Math.abs(i)*o?(a<0&&(o=-o),l=a===0?0:o*i/a,u=o):(i<0&&(s=-s),l=s,u=i===0?0:s*a/i),{x:r+l,y:n+u}},"intersectRect"),Bm=ADe;x(nne,"applyStyle");x(ine,"addHtmlLabel");_De=x(async(t,e,r,n)=>{let i=t||"";if(typeof i=="object"&&(i=i[0]),Kr(Te().flowchart.htmlLabels)){i=i.replace(/\\n|\n/g,"
    "),te.info("vertexText"+i);let a={isNode:n,label:Ks(i).replace(/fa[blrs]?:fa-[\w-]+/g,o=>``),labelStyle:e&&e.replace("fill:","color:")};return await ine(a)}else{let a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttribute("style",e.replace("color:","fill:"));let s=[];typeof i=="string"?s=i.split(/\\n|\n|/gi):Array.isArray(i)?s=i:s=[];for(let o of s){let l=document.createElementNS("http://www.w3.org/2000/svg","tspan");l.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),l.setAttribute("dy","1em"),l.setAttribute("x","0"),r?l.setAttribute("class","title-row"):l.setAttribute("class","row"),l.textContent=o.trim(),a.appendChild(l)}return a}},"createLabel"),Pf=_De,Bf=x((t,e,r,n,i)=>["M",t+i,e,"H",t+r-i,"A",i,i,0,0,1,t+r,e+i,"V",e+n-i,"A",i,i,0,0,1,t+r-i,e+n,"H",t+i,"A",i,i,0,0,1,t,e+n-i,"V",e+i,"A",i,i,0,0,1,t+i,e,"Z"].join(" "),"createRoundedRectPathD"),ane=x(async(t,e)=>{te.info("Creating subgraph rect for ",e.id,e);let r=Te(),{themeVariables:n,handDrawnSeed:i}=r,{clusterBkg:a,clusterBorder:s}=n,{labelStyles:o,nodeStyles:l,borderStyles:u,backgroundStyles:h}=Rt(e),f=t.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.id).attr("data-look",e.look),d=Kr(r.flowchart.htmlLabels),p=f.insert("g").attr("class","cluster-label "),g=await Ca(p,e.label,{style:e.labelStyle,useHtmlLabels:d,isNode:!0}),m=g.getBBox();if(Kr(r.flowchart.htmlLabels)){let C=g.children[0],L=Ye(g);m=C.getBoundingClientRect(),L.attr("width",m.width),L.attr("height",m.height)}let y=e.width<=m.width+e.padding?m.width+e.padding:e.width;e.width<=m.width+e.padding?e.diff=(y-e.width)/2-e.padding:e.diff=-e.padding;let v=e.height,b=e.x-y/2,w=e.y-v/2;te.trace("Data ",e,JSON.stringify(e));let S;if(e.look==="handDrawn"){let C=Ze.svg(f),L=Ft(e,{roughness:.7,fill:a,stroke:s,fillWeight:3,seed:i}),D=C.path(Bf(b,w,y,v,0),L);S=f.insert(()=>(te.debug("Rough node insert CXC",D),D),":first-child"),S.select("path:nth-child(2)").attr("style",u.join(";")),S.select("path").attr("style",h.join(";").replace("fill","stroke"))}else S=f.insert("rect",":first-child"),S.attr("style",l).attr("rx",e.rx).attr("ry",e.ry).attr("x",b).attr("y",w).attr("width",y).attr("height",v);let{subGraphTitleTopMargin:T}=hh(r);if(p.attr("transform",`translate(${e.x-m.width/2}, ${e.y-e.height/2+T})`),o){let C=p.select("span");C&&C.attr("style",o)}let k=S.node().getBBox();return e.offsetX=0,e.width=k.width,e.height=k.height,e.offsetY=m.height-e.padding/2,e.intersect=function(C){return Bm(e,C)},{cluster:f,labelBBox:m}},"rect"),LDe=x((t,e)=>{let r=t.insert("g").attr("class","note-cluster").attr("id",e.id),n=r.insert("rect",":first-child"),i=0*e.padding,a=i/2;n.attr("rx",e.rx).attr("ry",e.ry).attr("x",e.x-e.width/2-a).attr("y",e.y-e.height/2-a).attr("width",e.width+i).attr("height",e.height+i).attr("fill","none");let s=n.node().getBBox();return e.width=s.width,e.height=s.height,e.intersect=function(o){return Bm(e,o)},{cluster:r,labelBBox:{width:0,height:0}}},"noteGroup"),RDe=x(async(t,e)=>{let r=Te(),{themeVariables:n,handDrawnSeed:i}=r,{altBackground:a,compositeBackground:s,compositeTitleBackground:o,nodeBorder:l}=n,u=t.insert("g").attr("class",e.cssClasses).attr("id",e.id).attr("data-id",e.id).attr("data-look",e.look),h=u.insert("g",":first-child"),f=u.insert("g").attr("class","cluster-label"),d=u.append("rect"),p=f.node().appendChild(await Pf(e.label,e.labelStyle,void 0,!0)),g=p.getBBox();if(Kr(r.flowchart.htmlLabels)){let D=p.children[0],M=Ye(p);g=D.getBoundingClientRect(),M.attr("width",g.width),M.attr("height",g.height)}let m=0*e.padding,y=m/2,v=(e.width<=g.width+e.padding?g.width+e.padding:e.width)+m;e.width<=g.width+e.padding?e.diff=(v-e.width)/2-e.padding:e.diff=-e.padding;let b=e.height+m,w=e.height+m-g.height-6,S=e.x-v/2,T=e.y-b/2;e.width=v;let k=e.y-e.height/2-y+g.height+2,C;if(e.look==="handDrawn"){let D=e.cssClasses.includes("statediagram-cluster-alt"),M=Ze.svg(u),I=e.rx||e.ry?M.path(Bf(S,T,v,b,10),{roughness:.7,fill:o,fillStyle:"solid",stroke:l,seed:i}):M.rectangle(S,T,v,b,{seed:i});C=u.insert(()=>I,":first-child");let E=M.rectangle(S,k,v,w,{fill:D?a:s,fillStyle:D?"hachure":"solid",stroke:l,seed:i});C=u.insert(()=>I,":first-child"),d=u.insert(()=>E)}else C=h.insert("rect",":first-child"),C.attr("class","outer").attr("x",S).attr("y",T).attr("width",v).attr("height",b).attr("data-look",e.look),d.attr("class","inner").attr("x",S).attr("y",k).attr("width",v).attr("height",w);f.attr("transform",`translate(${e.x-g.width/2}, ${T+1-(Kr(r.flowchart.htmlLabels)?0:3)})`);let L=C.node().getBBox();return e.height=L.height,e.offsetX=0,e.offsetY=g.height-e.padding/2,e.labelBBox=g,e.intersect=function(D){return Bm(e,D)},{cluster:u,labelBBox:g}},"roundedWithTitle"),DDe=x(async(t,e)=>{te.info("Creating subgraph rect for ",e.id,e);let r=Te(),{themeVariables:n,handDrawnSeed:i}=r,{clusterBkg:a,clusterBorder:s}=n,{labelStyles:o,nodeStyles:l,borderStyles:u,backgroundStyles:h}=Rt(e),f=t.insert("g").attr("class","cluster "+e.cssClasses).attr("id",e.id).attr("data-look",e.look),d=Kr(r.flowchart.htmlLabels),p=f.insert("g").attr("class","cluster-label "),g=await Ca(p,e.label,{style:e.labelStyle,useHtmlLabels:d,isNode:!0,width:e.width}),m=g.getBBox();if(Kr(r.flowchart.htmlLabels)){let C=g.children[0],L=Ye(g);m=C.getBoundingClientRect(),L.attr("width",m.width),L.attr("height",m.height)}let y=e.width<=m.width+e.padding?m.width+e.padding:e.width;e.width<=m.width+e.padding?e.diff=(y-e.width)/2-e.padding:e.diff=-e.padding;let v=e.height,b=e.x-y/2,w=e.y-v/2;te.trace("Data ",e,JSON.stringify(e));let S;if(e.look==="handDrawn"){let C=Ze.svg(f),L=Ft(e,{roughness:.7,fill:a,stroke:s,fillWeight:4,seed:i}),D=C.path(Bf(b,w,y,v,e.rx),L);S=f.insert(()=>(te.debug("Rough node insert CXC",D),D),":first-child"),S.select("path:nth-child(2)").attr("style",u.join(";")),S.select("path").attr("style",h.join(";").replace("fill","stroke"))}else S=f.insert("rect",":first-child"),S.attr("style",l).attr("rx",e.rx).attr("ry",e.ry).attr("x",b).attr("y",w).attr("width",y).attr("height",v);let{subGraphTitleTopMargin:T}=hh(r);if(p.attr("transform",`translate(${e.x-m.width/2}, ${e.y-e.height/2+T})`),o){let C=p.select("span");C&&C.attr("style",o)}let k=S.node().getBBox();return e.offsetX=0,e.width=k.width,e.height=k.height,e.offsetY=m.height-e.padding/2,e.intersect=function(C){return Bm(e,C)},{cluster:f,labelBBox:m}},"kanbanSection"),NDe=x((t,e)=>{let r=Te(),{themeVariables:n,handDrawnSeed:i}=r,{nodeBorder:a}=n,s=t.insert("g").attr("class",e.cssClasses).attr("id",e.id).attr("data-look",e.look),o=s.insert("g",":first-child"),l=0*e.padding,u=e.width+l;e.diff=-e.padding;let h=e.height+l,f=e.x-u/2,d=e.y-h/2;e.width=u;let p;if(e.look==="handDrawn"){let y=Ze.svg(s).rectangle(f,d,u,h,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:a,seed:i});p=s.insert(()=>y,":first-child")}else p=o.insert("rect",":first-child"),p.attr("class","divider").attr("x",f).attr("y",d).attr("width",u).attr("height",h).attr("data-look",e.look);let g=p.node().getBBox();return e.height=g.height,e.offsetX=0,e.offsetY=0,e.intersect=function(m){return Bm(e,m)},{cluster:s,labelBBox:{}}},"divider"),IDe=ane,MDe={rect:ane,squareRect:IDe,roundedWithTitle:RDe,noteGroup:LDe,divider:NDe,kanbanSection:DDe},sne=new Map,Fm=x(async(t,e)=>{let r=e.shape||"rect",n=await MDe[r](t,e);return sne.set(e.id,n),n},"insertCluster"),one=x(()=>{sne=new Map},"clear");x(lne,"intersectNode");ODe=lne;x(cne,"intersectEllipse");une=cne;x(hne,"intersectCircle");PDe=hne;x(fne,"intersectLine");x($R,"sameSign");BDe=fne;x(dne,"intersectPolygon");FDe=dne,Dt={node:ODe,circle:PDe,ellipse:une,polygon:FDe,rect:Bm};x(pne,"anchor");x(zR,"generateArcPoints");x(gne,"bowTieRect");x(Ff,"insertPolygonShape");x(mne,"card");x(yne,"choice");x(GR,"circle");x(vne,"createLine");x(xne,"crossedCircle");x(mh,"generateCirclePoints");x(bne,"curlyBraceLeft");x(yh,"generateCirclePoints");x(wne,"curlyBraceRight");x(_a,"generateCirclePoints");x(Tne,"curlyBraces");x(kne,"curvedTrapezoid");$De=x((t,e,r,n,i,a)=>[`M${t},${e+a}`,`a${i},${a} 0,0,0 ${r},0`,`a${i},${a} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${a} 0,0,0 ${r},0`,`l0,${-n}`].join(" "),"createCylinderPathD"),zDe=x((t,e,r,n,i,a)=>[`M${t},${e+a}`,`M${t+r},${e+a}`,`a${i},${a} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${a} 0,0,0 ${r},0`,`l0,${-n}`].join(" "),"createOuterCylinderPathD"),GDe=x((t,e,r,n,i,a)=>[`M${t-r/2},${-n/2}`,`a${i},${a} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");x(Ene,"cylinder");x(Sne,"dividedRectangle");x(Cne,"doublecircle");x(Ane,"filledCircle");x(_ne,"flippedTriangle");x(Lne,"forkJoin");x(Rne,"halfRoundedRectangle");x(Dne,"hexagon");x(Nne,"hourglass");x(Ine,"icon");x(Mne,"iconCircle");x(One,"iconRounded");x(Pne,"iconSquare");x(Bne,"imageSquare");x(Fne,"inv_trapezoid");x(JT,"drawRect");x($ne,"labelRect");x(zne,"lean_left");x(Gne,"lean_right");x(qne,"lightningBolt");qDe=x((t,e,r,n,i,a,s)=>[`M${t},${e+a}`,`a${i},${a} 0,0,0 ${r},0`,`a${i},${a} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${a} 0,0,0 ${r},0`,`l0,${-n}`,`M${t},${e+a+s}`,`a${i},${a} 0,0,0 ${r},0`].join(" "),"createCylinderPathD"),VDe=x((t,e,r,n,i,a,s)=>[`M${t},${e+a}`,`M${t+r},${e+a}`,`a${i},${a} 0,0,0 ${-r},0`,`l0,${n}`,`a${i},${a} 0,0,0 ${r},0`,`l0,${-n}`,`M${t},${e+a+s}`,`a${i},${a} 0,0,0 ${r},0`].join(" "),"createOuterCylinderPathD"),UDe=x((t,e,r,n,i,a)=>[`M${t-r/2},${-n/2}`,`a${i},${a} 0,0,0 ${r},0`].join(" "),"createInnerCylinderPathD");x(Vne,"linedCylinder");x(Une,"linedWaveEdgedRect");x(Wne,"multiRect");x(Hne,"multiWaveEdgedRectangle");x(Yne,"note");WDe=x((t,e,r)=>[`M${t+r/2},${e}`,`L${t+r},${e-r/2}`,`L${t+r/2},${e-r}`,`L${t},${e-r/2}`,"Z"].join(" "),"createDecisionBoxPathD");x(Xne,"question");x(jne,"rect_left_inv_arrow");x(Kne,"rectWithTitle");x(px,"generateArcPoints");x(Zne,"roundedRect");x(Qne,"shadedProcess");x(Jne,"slopedRect");x(eie,"squareRect");x(tie,"stadium");x(rie,"state");x(nie,"stateEnd");x(iie,"stateStart");x(aie,"subroutine");x(sie,"taggedRect");x(oie,"taggedWaveEdgedRectangle");x(lie,"text");HDe=x((t,e,r,n,i,a)=>`M${t},${e} a${i},${a} 0,0,1 0,${-n} l${r},0 a${i},${a} 0,0,1 0,${n} M${r},${-n} a${i},${a} 0,0,0 0,${n} l${-r},0`,"createCylinderPathD"),YDe=x((t,e,r,n,i,a)=>[`M${t},${e}`,`M${t+r},${e}`,`a${i},${a} 0,0,0 0,${-n}`,`l${-r},0`,`a${i},${a} 0,0,0 0,${n}`,`l${r},0`].join(" "),"createOuterCylinderPathD"),XDe=x((t,e,r,n,i,a)=>[`M${t+r/2},${-n/2}`,`a${i},${a} 0,0,0 0,${n}`].join(" "),"createInnerCylinderPathD");x(cie,"tiltedCylinder");x(uie,"trapezoid");x(hie,"trapezoidalPentagon");x(fie,"triangle");x(die,"waveEdgedRectangle");x(pie,"waveRectangle");x(gie,"windowPane");x(qR,"erBox");x(Pm,"addText");x(mie,"textHelper");x(gx,"addText");x(yie,"classBox");x(vie,"requirementBox");x(nu,"addText");jDe=x(t=>{switch(t){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");x(xie,"kanbanItem");x(bie,"bang");x(wie,"cloud");x(Tie,"defaultMindmapNode");x(kie,"mindmapCircle");KDe=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:eie},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:Zne},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:tie},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:aie},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:Ene},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:GR},{semanticName:"Bang",name:"Bang",shortName:"bang",description:"Bang",aliases:["bang"],handler:bie},{semanticName:"Cloud",name:"Cloud",shortName:"cloud",description:"cloud",aliases:["cloud"],handler:wie},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:Xne},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:Dne},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:Gne},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:zne},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:uie},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:Fne},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:Cne},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:lie},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:mne},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:Qne},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:iie},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:nie},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:Lne},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:Nne},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:bne},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:wne},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:Tne},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:qne},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:die},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:Rne},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:cie},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:Vne},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:kne},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:Sne},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:fie},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:gie},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:Ane},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:hie},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:_ne},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:Jne},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:Hne},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:Wne},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:gne},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:xne},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:oie},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:sie},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:pie},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:jne},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:Une}],ZDe=x(()=>{let e=[...Object.entries({state:rie,choice:yne,note:Yne,rectWithTitle:Kne,labelRect:$ne,iconSquare:Pne,iconCircle:Mne,icon:Ine,iconRounded:One,imageSquare:Bne,anchor:pne,kanbanItem:xie,mindmapCircle:kie,defaultMindmapNode:Tie,classBox:yie,erBox:qR,requirementBox:vie}),...KDe.flatMap(r=>[r.shortName,..."aliases"in r?r.aliases:[],..."internalAliases"in r?r.internalAliases:[]].map(i=>[i,r.handler]))];return Object.fromEntries(e)},"generateShapeMap"),Eie=ZDe();x(VR,"isValidShape");ek=new Map;x(t0,"insertNode");Sie=x((t,e)=>{ek.set(e.id,t)},"setNodeElem"),Cie=x(()=>{ek.clear()},"clear"),yx=x(t=>{let e=ek.get(t.id);te.trace("Transforming node",t.diff,t,"translate("+(t.x-t.width/2-5)+", "+t.width/2+")");let r=8,n=t.diff||0;return t.clusterNode?e.attr("transform","translate("+(t.x+n-t.width/2)+", "+(t.y-t.height/2-r)+")"):e.attr("transform","translate("+t.x+", "+t.y+")"),n},"positionNode")});function vx(t,e){Te().flowchart.htmlLabels&&t&&(t.style.width=e.length*9+"px",t.style.height="12px")}function Die(t){let e=[],r=[];for(let n=1;n5&&Math.abs(a.y-i.y)>5||i.y===a.y&&a.x===s.x&&Math.abs(a.x-i.x)>5&&Math.abs(a.y-s.y)>5)&&(e.push(a),r.push(n))}return{cornerPoints:e,cornerPointPositions:r}}function Nie(t,e){if(t.length<2)return"";let r="",n=t.length,i=1e-5;for(let a=0;a({...i}));if(t.length>=2&&Ta[e.arrowTypeStart]){let i=Ta[e.arrowTypeStart],a=t[0],s=t[1],{angle:o}=UR(a,s),l=i*Math.cos(o),u=i*Math.sin(o);r[0].x=a.x+l,r[0].y=a.y+u}let n=t.length;if(n>=2&&Ta[e.arrowTypeEnd]){let i=Ta[e.arrowTypeEnd],a=t[n-1],s=t[n-2],{angle:o}=UR(s,a),l=i*Math.cos(o),u=i*Math.sin(o);r[n-1].x=a.x-l,r[n-1].y=a.y-u}return r}var QDe,JDe,Aie,rk,La,Rie,tk,nk,ik,eNe,tNe,_ie,Lie,rNe,nNe,ak,iNe,aNe,sNe,oNe,lNe,cNe,uNe,hNe,fNe,dNe,pNe,gNe,mNe,yNe,vNe,xNe,bNe,sk,cl=$(()=>{Co();Qs();xs();bs();Aa();bn();Er();lr();pr();zt();QDe=x((t,e,r,n,i,a)=>{e.arrowTypeStart&&Aie(t,"start",e.arrowTypeStart,r,n,i,a),e.arrowTypeEnd&&Aie(t,"end",e.arrowTypeEnd,r,n,i,a)},"addEdgeMarkers"),JDe={arrow_cross:{type:"cross",fill:!1},arrow_point:{type:"point",fill:!0},arrow_barb:{type:"barb",fill:!0},arrow_circle:{type:"circle",fill:!1},aggregation:{type:"aggregation",fill:!1},extension:{type:"extension",fill:!1},composition:{type:"composition",fill:!0},dependency:{type:"dependency",fill:!0},lollipop:{type:"lollipop",fill:!1},only_one:{type:"onlyOne",fill:!1},zero_or_one:{type:"zeroOrOne",fill:!1},one_or_more:{type:"oneOrMore",fill:!1},zero_or_more:{type:"zeroOrMore",fill:!1},requirement_arrow:{type:"requirement_arrow",fill:!1},requirement_contains:{type:"requirement_contains",fill:!1}},Aie=x((t,e,r,n,i,a,s)=>{let o=JDe[r];if(!o){te.warn(`Unknown arrow type: ${r}`);return}let l=o.type,h=`${i}_${a}-${l}${e==="start"?"Start":"End"}`;if(s&&s.trim()!==""){let f=s.replace(/[^\dA-Za-z]/g,"_"),d=`${h}_${f}`;if(!document.getElementById(d)){let p=document.getElementById(h);if(p){let g=p.cloneNode(!0);g.id=d,g.querySelectorAll("path, circle, line").forEach(y=>{y.setAttribute("stroke",s),o.fill&&y.setAttribute("fill",s)}),p.parentNode?.appendChild(g)}}t.attr(`marker-${e}`,`url(${n}#${d})`)}else t.attr(`marker-${e}`,`url(${n}#${h})`)},"addEdgeMarker"),rk=new Map,La=new Map,Rie=x(()=>{rk.clear(),La.clear()},"clear"),tk=x(t=>t?t.reduce((r,n)=>r+";"+n,""):"","getLabelStyles"),nk=x(async(t,e)=>{let r=Kr(Te().flowchart.htmlLabels),{labelStyles:n}=Rt(e);e.labelStyle=n;let i=await Ca(t,e.label,{style:e.labelStyle,useHtmlLabels:r,addSvgBackground:!0,isNode:!1});te.info("abc82",e,e.labelType);let a=t.insert("g").attr("class","edgeLabel"),s=a.insert("g").attr("class","label").attr("data-id",e.id);s.node().appendChild(i);let o=i.getBBox();if(r){let u=i.children[0],h=Ye(i);o=u.getBoundingClientRect(),h.attr("width",o.width),h.attr("height",o.height)}s.attr("transform","translate("+-o.width/2+", "+-o.height/2+")"),rk.set(e.id,a),e.width=o.width,e.height=o.height;let l;if(e.startLabelLeft){let u=await Pf(e.startLabelLeft,tk(e.labelStyle)),h=t.insert("g").attr("class","edgeTerminals"),f=h.insert("g").attr("class","inner");l=f.node().appendChild(u);let d=u.getBBox();f.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),La.get(e.id)||La.set(e.id,{}),La.get(e.id).startLeft=h,vx(l,e.startLabelLeft)}if(e.startLabelRight){let u=await Pf(e.startLabelRight,tk(e.labelStyle)),h=t.insert("g").attr("class","edgeTerminals"),f=h.insert("g").attr("class","inner");l=h.node().appendChild(u),f.node().appendChild(u);let d=u.getBBox();f.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),La.get(e.id)||La.set(e.id,{}),La.get(e.id).startRight=h,vx(l,e.startLabelRight)}if(e.endLabelLeft){let u=await Pf(e.endLabelLeft,tk(e.labelStyle)),h=t.insert("g").attr("class","edgeTerminals"),f=h.insert("g").attr("class","inner");l=f.node().appendChild(u);let d=u.getBBox();f.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),h.node().appendChild(u),La.get(e.id)||La.set(e.id,{}),La.get(e.id).endLeft=h,vx(l,e.endLabelLeft)}if(e.endLabelRight){let u=await Pf(e.endLabelRight,tk(e.labelStyle)),h=t.insert("g").attr("class","edgeTerminals"),f=h.insert("g").attr("class","inner");l=f.node().appendChild(u);let d=u.getBBox();f.attr("transform","translate("+-d.width/2+", "+-d.height/2+")"),h.node().appendChild(u),La.get(e.id)||La.set(e.id,{}),La.get(e.id).endRight=h,vx(l,e.endLabelRight)}return i},"insertEdgeLabel");x(vx,"setTerminalWidth");ik=x((t,e)=>{te.debug("Moving label abc88 ",t.id,t.label,rk.get(t.id),e);let r=e.updatedPath?e.updatedPath:e.originalPath,n=Te(),{subGraphTitleTotalMargin:i}=hh(n);if(t.label){let a=rk.get(t.id),s=t.x,o=t.y;if(r){let l=Ut.calcLabelPosition(r);te.debug("Moving label "+t.label+" from (",s,",",o,") to (",l.x,",",l.y,") abc88"),e.updatedPath&&(s=l.x,o=l.y)}a.attr("transform",`translate(${s}, ${o+i/2})`)}if(t.startLabelLeft){let a=La.get(t.id).startLeft,s=t.x,o=t.y;if(r){let l=Ut.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_left",r);s=l.x,o=l.y}a.attr("transform",`translate(${s}, ${o})`)}if(t.startLabelRight){let a=La.get(t.id).startRight,s=t.x,o=t.y;if(r){let l=Ut.calcTerminalLabelPosition(t.arrowTypeStart?10:0,"start_right",r);s=l.x,o=l.y}a.attr("transform",`translate(${s}, ${o})`)}if(t.endLabelLeft){let a=La.get(t.id).endLeft,s=t.x,o=t.y;if(r){let l=Ut.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_left",r);s=l.x,o=l.y}a.attr("transform",`translate(${s}, ${o})`)}if(t.endLabelRight){let a=La.get(t.id).endRight,s=t.x,o=t.y;if(r){let l=Ut.calcTerminalLabelPosition(t.arrowTypeEnd?10:0,"end_right",r);s=l.x,o=l.y}a.attr("transform",`translate(${s}, ${o})`)}},"positionEdgeLabel"),eNe=x((t,e)=>{let r=t.x,n=t.y,i=Math.abs(e.x-r),a=Math.abs(e.y-n),s=t.width/2,o=t.height/2;return i>=s||a>=o},"outsideNode"),tNe=x((t,e,r)=>{te.debug(`intersection calc abc89: outsidePoint: ${JSON.stringify(e)} insidePoint : ${JSON.stringify(r)} node : x:${t.x} y:${t.y} w:${t.width} h:${t.height}`);let n=t.x,i=t.y,a=Math.abs(n-r.x),s=t.width/2,o=r.xMath.abs(n-e.x)*l){let f=r.y{te.warn("abc88 cutPathAtIntersect",t,e);let r=[],n=t[0],i=!1;return t.forEach(a=>{if(te.info("abc88 checking point",a,e),!eNe(e,a)&&!i){let s=tNe(e,n,a);te.debug("abc88 inside",a,n,s),te.debug("abc88 intersection",s,e);let o=!1;r.forEach(l=>{o=o||l.x===s.x&&l.y===s.y}),r.some(l=>l.x===s.x&&l.y===s.y)?te.warn("abc88 no intersect",s,r):r.push(s),i=!0}else te.warn("abc88 outside",a,n),n=a,i||r.push(a)}),te.debug("returning points",r),r},"cutPathAtIntersect");x(Die,"extractCornerPoints");Lie=x(function(t,e,r){let n=e.x-t.x,i=e.y-t.y,a=Math.sqrt(n*n+i*i),s=r/a;return{x:e.x-s*n,y:e.y-s*i}},"findAdjacentPoint"),rNe=x(function(t){let{cornerPointPositions:e}=Die(t),r=[];for(let n=0;n10&&Math.abs(a.y-i.y)>=10){te.debug("Corner point fixing",Math.abs(a.x-i.x),Math.abs(a.y-i.y));let p=5;s.x===o.x?d={x:u<0?o.x-p+f:o.x+p-f,y:h<0?o.y-f:o.y+f}:d={x:u<0?o.x-f:o.x+f,y:h<0?o.y-p+f:o.y+p-f}}else te.debug("Corner point skipping fixing",Math.abs(a.x-i.x),Math.abs(a.y-i.y));r.push(d,l)}else r.push(t[n]);return r},"fixCorners"),nNe=x((t,e,r)=>{let n=t-e-r,i=2,a=2,s=i+a,o=Math.floor(n/s),l=Array(o).fill(`${i} ${a}`).join(" ");return`0 ${e} ${l} ${r}`},"generateDashArray"),ak=x(function(t,e,r,n,i,a,s,o=!1){let{handDrawnSeed:l}=Te(),u=e.points,h=!1,f=i;var d=a;let p=[];for(let A in e.cssCompiledStyles)U2(A)||p.push(e.cssCompiledStyles[A]);te.debug("UIO intersect check",e.points,d.x,f.x),d.intersect&&f.intersect&&!o&&(u=u.slice(1,e.points.length-1),u.unshift(f.intersect(u[0])),te.debug("Last point UIO",e.start,"-->",e.end,u[u.length-1],d,d.intersect(u[u.length-1])),u.push(d.intersect(u[u.length-1])));let g=btoa(JSON.stringify(u));e.toCluster&&(te.info("to cluster abc88",r.get(e.toCluster)),u=_ie(e.points,r.get(e.toCluster).node),h=!0),e.fromCluster&&(te.debug("from cluster abc88",r.get(e.fromCluster),JSON.stringify(u,null,2)),u=_ie(u.reverse(),r.get(e.fromCluster).node).reverse(),h=!0);let m=u.filter(A=>!Number.isNaN(A.y));m=rNe(m);let y=Yl;switch(y=xf,e.curve){case"linear":y=xf;break;case"basis":y=Yl;break;case"cardinal":y=A2;break;case"bumpX":y=T2;break;case"bumpY":y=k2;break;case"catmullRom":y=R2;break;case"monotoneX":y=D2;break;case"monotoneY":y=N2;break;case"natural":y=I2;break;case"step":y=M2;break;case"stepAfter":y=P2;break;case"stepBefore":y=O2;break;default:y=Yl}let{x:v,y:b}=sT(e),w=Wc().x(v).y(b).curve(y),S;switch(e.thickness){case"normal":S="edge-thickness-normal";break;case"thick":S="edge-thickness-thick";break;case"invisible":S="edge-thickness-invisible";break;default:S="edge-thickness-normal"}switch(e.pattern){case"solid":S+=" edge-pattern-solid";break;case"dotted":S+=" edge-pattern-dotted";break;case"dashed":S+=" edge-pattern-dashed";break;default:S+=" edge-pattern-solid"}let T,k=e.curve==="rounded"?Nie(Iie(m,e),5):w(m),C=Array.isArray(e.style)?e.style:[e.style],L=C.find(A=>A?.startsWith("stroke:")),D=!1;if(e.look==="handDrawn"){let A=Ze.svg(t);Object.assign([],m);let R=A.path(k,{roughness:.3,seed:l});S+=" transition",T=Ye(R).select("path").attr("id",e.id).attr("class"," "+S+(e.classes?" "+e.classes:"")).attr("style",C?C.reduce((O,P)=>O+";"+P,""):"");let N=T.attr("d");T.attr("d",N),t.node().appendChild(T.node())}else{let A=p.join(";"),R=C?C.reduce((q,j)=>q+j+";",""):"",N="";e.animate&&(N=" edge-animation-fast"),e.animation&&(N=" edge-animation-"+e.animation);let O=(A?A+";"+R+";":R)+";"+(C?C.reduce((q,j)=>q+";"+j,""):"");T=t.append("path").attr("d",k).attr("id",e.id).attr("class"," "+S+(e.classes?" "+e.classes:"")+(N??"")).attr("style",O),L=O.match(/stroke:([^;]+)/)?.[1],D=e.animate===!0||!!e.animation||A.includes("animation");let P=T.node(),B=typeof P.getTotalLength=="function"?P.getTotalLength():0,G=x9[e.arrowTypeStart]||0,F=x9[e.arrowTypeEnd]||0;if(e.look==="neo"&&!D){let j=`stroke-dasharray: ${e.pattern==="dotted"||e.pattern==="dashed"?nNe(B,G,F):`0 ${G} ${B-G-F} ${F}`}; stroke-dashoffset: 0;`;T.attr("style",j+T.attr("style"))}}T.attr("data-edge",!0),T.attr("data-et","edge"),T.attr("data-id",e.id),T.attr("data-points",g),e.showPoints&&m.forEach(A=>{t.append("circle").style("stroke","red").style("fill","red").attr("r",1).attr("cx",A.x).attr("cy",A.y)});let M="";(Te().flowchart.arrowMarkerAbsolute||Te().state.arrowMarkerAbsolute)&&(M=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,M=M.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),te.info("arrowTypeStart",e.arrowTypeStart),te.info("arrowTypeEnd",e.arrowTypeEnd),QDe(T,e,M,s,n,L);let I=Math.floor(u.length/2),E=u[I];Ut.isLabelCoordinateInPath(E,T.attr("d"))||(h=!0);let _={};return h&&(_.updatedPath=u),_.originalPath=e.points,_},"insertEdge");x(Nie,"generateRoundedPath");x(UR,"calculateDeltaAndAngle");x(Iie,"applyMarkerOffsetsToPoints");iNe=x((t,e,r,n)=>{e.forEach(i=>{bNe[i](t,r,n)})},"insertMarkers"),aNe=x((t,e,r)=>{te.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"),sNe=x((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"),oNe=x((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"),lNe=x((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"),cNe=x((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"),uNe=x((t,e,r)=>{t.append("marker").attr("id",r+"_"+e+"-pointEnd").attr("class","marker "+e).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).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",8).attr("markerHeight",8).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"),hNe=x((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"),fNe=x((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"),dNe=x((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","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),pNe=x((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-onlyOneStart").attr("class","marker onlyOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M9,0 L9,18 M15,0 L15,18"),t.append("defs").append("marker").attr("id",r+"_"+e+"-onlyOneEnd").attr("class","marker onlyOne "+e).attr("refX",18).attr("refY",9).attr("markerWidth",18).attr("markerHeight",18).attr("orient","auto").append("path").attr("d","M3,0 L3,18 M9,0 L9,18")},"only_one"),gNe=x((t,e,r)=>{let n=t.append("defs").append("marker").attr("id",r+"_"+e+"-zeroOrOneStart").attr("class","marker zeroOrOne "+e).attr("refX",0).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");n.append("circle").attr("fill","white").attr("cx",21).attr("cy",9).attr("r",6),n.append("path").attr("d","M9,0 L9,18");let i=t.append("defs").append("marker").attr("id",r+"_"+e+"-zeroOrOneEnd").attr("class","marker zeroOrOne "+e).attr("refX",30).attr("refY",9).attr("markerWidth",30).attr("markerHeight",18).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",9).attr("r",6),i.append("path").attr("d","M21,0 L21,18")},"zero_or_one"),mNe=x((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-oneOrMoreStart").attr("class","marker oneOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M0,18 Q 18,0 36,18 Q 18,36 0,18 M42,9 L42,27"),t.append("defs").append("marker").attr("id",r+"_"+e+"-oneOrMoreEnd").attr("class","marker oneOrMore "+e).attr("refX",27).attr("refY",18).attr("markerWidth",45).attr("markerHeight",36).attr("orient","auto").append("path").attr("d","M3,9 L3,27 M9,18 Q27,0 45,18 Q27,36 9,18")},"one_or_more"),yNe=x((t,e,r)=>{let n=t.append("defs").append("marker").attr("id",r+"_"+e+"-zeroOrMoreStart").attr("class","marker zeroOrMore "+e).attr("refX",18).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");n.append("circle").attr("fill","white").attr("cx",48).attr("cy",18).attr("r",6),n.append("path").attr("d","M0,18 Q18,0 36,18 Q18,36 0,18");let i=t.append("defs").append("marker").attr("id",r+"_"+e+"-zeroOrMoreEnd").attr("class","marker zeroOrMore "+e).attr("refX",39).attr("refY",18).attr("markerWidth",57).attr("markerHeight",36).attr("orient","auto");i.append("circle").attr("fill","white").attr("cx",9).attr("cy",18).attr("r",6),i.append("path").attr("d","M21,18 Q39,0 57,18 Q39,36 21,18")},"zero_or_more"),vNe=x((t,e,r)=>{t.append("defs").append("marker").attr("id",r+"_"+e+"-requirement_arrowEnd").attr("refX",20).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("path").attr("d",`M0,0 L20,10 M20,10 L0,20`)},"requirement_arrow"),xNe=x((t,e,r)=>{let n=t.append("defs").append("marker").attr("id",r+"_"+e+"-requirement_containsStart").attr("refX",0).attr("refY",10).attr("markerWidth",20).attr("markerHeight",20).attr("orient","auto").append("g");n.append("circle").attr("cx",10).attr("cy",10).attr("r",9).attr("fill","none"),n.append("line").attr("x1",1).attr("x2",19).attr("y1",10).attr("y2",10),n.append("line").attr("y1",1).attr("y2",19).attr("x1",10).attr("x2",10)},"requirement_contains"),bNe={extension:aNe,composition:sNe,aggregation:oNe,dependency:lNe,lollipop:cNe,point:uNe,circle:hNe,cross:fNe,barb:dNe,only_one:pNe,zero_or_one:gNe,one_or_more:mNe,zero_or_more:yNe,requirement_arrow:vNe,requirement_contains:xNe},sk=iNe});function TNe(t){return typeof t=="symbol"||ci(t)&&ka(t)==wNe}var wNe,Ro,r0=$(()=>{fh();il();wNe="[object Symbol]";Ro=TNe});function kNe(t,e){for(var r=-1,n=t==null?0:t.length,i=Array(n);++r{Js=kNe});function Pie(t){if(typeof t=="string")return t;if(Mt(t))return Js(t,Pie)+"";if(Ro(t))return Oie?Oie.call(t):"";var e=t+"";return e=="0"&&1/t==-ENe?"-0":e}var ENe,Mie,Oie,Bie,Fie=$(()=>{Wp();n0();Kn();r0();ENe=1/0,Mie=na?na.prototype:void 0,Oie=Mie?Mie.toString:void 0;Bie=Pie});function CNe(t){for(var e=t.length;e--&&SNe.test(t.charAt(e)););return e}var SNe,$ie,zie=$(()=>{SNe=/\s/;$ie=CNe});function _Ne(t){return t&&t.slice(0,$ie(t)+1).replace(ANe,"")}var ANe,Gie,qie=$(()=>{zie();ANe=/^\s+/;Gie=_Ne});function INe(t){if(typeof t=="number")return t;if(Ro(t))return Vie;if(_n(t)){var e=typeof t.valueOf=="function"?t.valueOf():t;t=_n(e)?e+"":e}if(typeof t!="string")return t===0?t:+t;t=Gie(t);var r=RNe.test(t);return r||DNe.test(t)?NNe(t.slice(2),r?2:8):LNe.test(t)?Vie:+t}var Vie,LNe,RNe,DNe,NNe,Uie,Wie=$(()=>{qie();Ao();r0();Vie=NaN,LNe=/^[-+]0x[0-9a-f]+$/i,RNe=/^0b[01]+$/i,DNe=/^0o[0-7]+$/i,NNe=parseInt;Uie=INe});function ONe(t){if(!t)return t===0?t:0;if(t=Uie(t),t===Hie||t===-Hie){var e=t<0?-1:1;return e*MNe}return t===t?t:0}var Hie,MNe,$m,WR=$(()=>{Wie();Hie=1/0,MNe=17976931348623157e292;$m=ONe});function PNe(t){var e=$m(t),r=e%1;return e===e?r?e-r:e:0}var iu,zm=$(()=>{WR();iu=PNe});var BNe,ok,Yie=$(()=>{Sf();rl();BNe=Ys(yi,"WeakMap"),ok=BNe});function FNe(){}var hi,HR=$(()=>{hi=FNe});function $Ne(t,e){for(var r=-1,n=t==null?0:t.length;++r{lk=$Ne});function zNe(t,e,r,n){for(var i=t.length,a=r+(n?1:-1);n?a--:++a{ck=zNe});function GNe(t){return t!==t}var Xie,jie=$(()=>{Xie=GNe});function qNe(t,e,r){for(var n=r-1,i=t.length;++n{Kie=qNe});function VNe(t,e,r){return e===e?Kie(t,e,r):ck(t,Xie,r)}var Gm,uk=$(()=>{XR();jie();Zie();Gm=VNe});function UNe(t,e){var r=t==null?0:t.length;return!!r&&Gm(t,e,0)>-1}var hk,jR=$(()=>{uk();hk=UNe});var WNe,Qie,Jie=$(()=>{D9();WNe=yT(Object.keys,Object),Qie=WNe});function XNe(t){if(!Kc(t))return Qie(t);var e=[];for(var r in Object(t))YNe.call(t,r)&&r!="constructor"&&e.push(r);return e}var HNe,YNe,qm,fk=$(()=>{Am();Jie();HNe=Object.prototype,YNe=HNe.hasOwnProperty;qm=XNe});function jNe(t){return xi(t)?TT(t):qm(t)}var Zr,au=$(()=>{P9();fk();al();Zr=jNe});var KNe,ZNe,QNe,Ra,eae=$(()=>{Dm();Kp();z9();al();Am();au();KNe=Object.prototype,ZNe=KNe.hasOwnProperty,QNe=ST(function(t,e){if(Kc(e)||xi(e)){ll(e,Zr(e),t);return}for(var r in e)ZNe.call(e,r)&&Zc(t,r,e[r])}),Ra=QNe});function tIe(t,e){if(Mt(t))return!1;var r=typeof t;return r=="number"||r=="symbol"||r=="boolean"||t==null||Ro(t)?!0:eIe.test(t)||!JNe.test(t)||e!=null&&t in Object(e)}var JNe,eIe,Vm,dk=$(()=>{Kn();r0();JNe=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,eIe=/^\w*$/;Vm=tIe});function nIe(t){var e=xm(t,function(n){return r.size===rIe&&r.clear(),n}),r=e.cache;return e}var rIe,tae,rae=$(()=>{E9();rIe=500;tae=nIe});var iIe,aIe,sIe,nae,iae=$(()=>{rae();iIe=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,aIe=/\\(\\)?/g,sIe=tae(function(t){var e=[];return t.charCodeAt(0)===46&&e.push(""),t.replace(iIe,function(r,n,i,a){e.push(i?a.replace(aIe,"$1"):n||r)}),e}),nae=sIe});function oIe(t){return t==null?"":Bie(t)}var pk,KR=$(()=>{Fie();pk=oIe});function lIe(t,e){return Mt(t)?t:Vm(t,e)?[t]:nae(pk(t))}var $f,xx=$(()=>{Kn();dk();iae();KR();$f=lIe});function uIe(t){if(typeof t=="string"||Ro(t))return t;var e=t+"";return e=="0"&&1/t==-cIe?"-0":e}var cIe,su,Um=$(()=>{r0();cIe=1/0;su=uIe});function hIe(t,e){e=$f(e,t);for(var r=0,n=e.length;t!=null&&r{xx();Um();zf=hIe});function fIe(t,e,r){var n=t==null?void 0:zf(t,e);return n===void 0?r:n}var aae,sae=$(()=>{bx();aae=fIe});function dIe(t,e){for(var r=-1,n=e.length,i=t.length;++r{Wm=dIe});function pIe(t){return Mt(t)||jl(t)||!!(oae&&t&&t[oae])}var oae,lae,cae=$(()=>{Wp();_m();Kn();oae=na?na.isConcatSpreadable:void 0;lae=pIe});function uae(t,e,r,n,i){var a=-1,s=t.length;for(r||(r=lae),i||(i=[]);++a0&&r(o)?e>1?uae(o,e-1,r,n,i):Wm(i,o):n||(i[i.length]=o)}return i}var ou,Hm=$(()=>{gk();cae();ou=uae});function gIe(t){var e=t==null?0:t.length;return e?ou(t,1):[]}var sn,mk=$(()=>{Hm();sn=gIe});function mIe(t){return ET(kT(t,void 0,sn),t+"")}var hae,fae=$(()=>{mk();B9();$9();hae=mIe});function yIe(t,e,r){var n=-1,i=t.length;e<0&&(e=-e>i?0:i+e),r=r>i?i:r,r<0&&(r+=i),i=e>r?0:r-e>>>0,e>>>=0;for(var a=Array(i);++n{yk=yIe});function CIe(t){return SIe.test(t)}var vIe,xIe,bIe,wIe,TIe,kIe,EIe,SIe,dae,pae=$(()=>{vIe="\\ud800-\\udfff",xIe="\\u0300-\\u036f",bIe="\\ufe20-\\ufe2f",wIe="\\u20d0-\\u20ff",TIe=xIe+bIe+wIe,kIe="\\ufe0e\\ufe0f",EIe="\\u200d",SIe=RegExp("["+EIe+vIe+TIe+kIe+"]");dae=CIe});function AIe(t,e,r,n){var i=-1,a=t==null?0:t.length;for(n&&a&&(r=t[++i]);++i{gae=AIe});function _Ie(t,e){return t&&ll(e,Zr(e),t)}var yae,vae=$(()=>{Kp();au();yae=_Ie});function LIe(t,e){return t&&ll(e,Xs(e),t)}var xae,bae=$(()=>{Kp();Nf();xae=LIe});function RIe(t,e){for(var r=-1,n=t==null?0:t.length,i=0,a=[];++r{Ym=RIe});function DIe(){return[]}var xk,QR=$(()=>{xk=DIe});var NIe,IIe,wae,MIe,Xm,bk=$(()=>{vk();QR();NIe=Object.prototype,IIe=NIe.propertyIsEnumerable,wae=Object.getOwnPropertySymbols,MIe=wae?function(t){return t==null?[]:(t=Object(t),Ym(wae(t),function(e){return IIe.call(t,e)}))}:xk,Xm=MIe});function OIe(t,e){return ll(t,Xm(t),e)}var Tae,kae=$(()=>{Kp();bk();Tae=OIe});var PIe,BIe,wk,JR=$(()=>{gk();vT();bk();QR();PIe=Object.getOwnPropertySymbols,BIe=PIe?function(t){for(var e=[];t;)Wm(e,Xm(t)),t=Cm(t);return e}:xk,wk=BIe});function FIe(t,e){return ll(t,wk(t),e)}var Eae,Sae=$(()=>{Kp();JR();Eae=FIe});function $Ie(t,e,r){var n=e(t);return Mt(t)?n:Wm(n,r(t))}var Tk,eD=$(()=>{gk();Kn();Tk=$Ie});function zIe(t){return Tk(t,Zr,Xm)}var wx,tD=$(()=>{eD();bk();au();wx=zIe});function GIe(t){return Tk(t,Xs,wk)}var kk,rD=$(()=>{eD();JR();Nf();kk=GIe});var qIe,Ek,Cae=$(()=>{Sf();rl();qIe=Ys(yi,"DataView"),Ek=qIe});var VIe,Sk,Aae=$(()=>{Sf();rl();VIe=Ys(yi,"Promise"),Sk=VIe});var UIe,Gf,nD=$(()=>{Sf();rl();UIe=Ys(yi,"Set"),Gf=UIe});var _ae,WIe,Lae,Rae,Dae,Nae,HIe,YIe,XIe,jIe,KIe,i0,Do,a0=$(()=>{Cae();uT();Aae();nD();Yie();fh();w9();_ae="[object Map]",WIe="[object Object]",Lae="[object Promise]",Rae="[object Set]",Dae="[object WeakMap]",Nae="[object DataView]",HIe=dh(Ek),YIe=dh(_f),XIe=dh(Sk),jIe=dh(Gf),KIe=dh(ok),i0=ka;(Ek&&i0(new Ek(new ArrayBuffer(1)))!=Nae||_f&&i0(new _f)!=_ae||Sk&&i0(Sk.resolve())!=Lae||Gf&&i0(new Gf)!=Rae||ok&&i0(new ok)!=Dae)&&(i0=function(t){var e=ka(t),r=e==WIe?t.constructor:void 0,n=r?dh(r):"";if(n)switch(n){case HIe:return Nae;case YIe:return _ae;case XIe:return Lae;case jIe:return Rae;case KIe:return Dae}return e});Do=i0});function JIe(t){var e=t.length,r=new t.constructor(e);return e&&typeof t[0]=="string"&&QIe.call(t,"index")&&(r.index=t.index,r.input=t.input),r}var ZIe,QIe,Iae,Mae=$(()=>{ZIe=Object.prototype,QIe=ZIe.hasOwnProperty;Iae=JIe});function eMe(t,e){var r=e?Sm(t.buffer):t.buffer;return new t.constructor(r,t.byteOffset,t.byteLength)}var Oae,Pae=$(()=>{pT();Oae=eMe});function rMe(t){var e=new t.constructor(t.source,tMe.exec(t));return e.lastIndex=t.lastIndex,e}var tMe,Bae,Fae=$(()=>{tMe=/\w*$/;Bae=rMe});function nMe(t){return zae?Object(zae.call(t)):{}}var $ae,zae,Gae,qae=$(()=>{Wp();$ae=na?na.prototype:void 0,zae=$ae?$ae.valueOf:void 0;Gae=nMe});function kMe(t,e,r){var n=t.constructor;switch(e){case fMe:return Sm(t);case iMe:case aMe:return new n(+t);case dMe:return Oae(t,r);case pMe:case gMe:case mMe:case yMe:case vMe:case xMe:case bMe:case wMe:case TMe:return gT(t,r);case sMe:return new n;case oMe:case uMe:return new n(t);case lMe:return Bae(t);case cMe:return new n;case hMe:return Gae(t)}}var iMe,aMe,sMe,oMe,lMe,cMe,uMe,hMe,fMe,dMe,pMe,gMe,mMe,yMe,vMe,xMe,bMe,wMe,TMe,Vae,Uae=$(()=>{pT();Pae();Fae();qae();L9();iMe="[object Boolean]",aMe="[object Date]",sMe="[object Map]",oMe="[object Number]",lMe="[object RegExp]",cMe="[object Set]",uMe="[object String]",hMe="[object Symbol]",fMe="[object ArrayBuffer]",dMe="[object DataView]",pMe="[object Float32Array]",gMe="[object Float64Array]",mMe="[object Int8Array]",yMe="[object Int16Array]",vMe="[object Int32Array]",xMe="[object Uint8Array]",bMe="[object Uint8ClampedArray]",wMe="[object Uint16Array]",TMe="[object Uint32Array]";Vae=kMe});function SMe(t){return ci(t)&&Do(t)==EMe}var EMe,Wae,Hae=$(()=>{a0();il();EMe="[object Map]";Wae=SMe});var Yae,CMe,Xae,jae=$(()=>{Hae();jp();ex();Yae=ol&&ol.isMap,CMe=Yae?sl(Yae):Wae,Xae=CMe});function _Me(t){return ci(t)&&Do(t)==AMe}var AMe,Kae,Zae=$(()=>{a0();il();AMe="[object Set]";Kae=_Me});var Qae,LMe,Jae,ese=$(()=>{Zae();jp();ex();Qae=ol&&ol.isSet,LMe=Qae?sl(Qae):Kae,Jae=LMe});function Ck(t,e,r,n,i,a){var s,o=e&RMe,l=e&DMe,u=e&NMe;if(r&&(s=i?r(t,n,i,a):r(t)),s!==void 0)return s;if(!_n(t))return t;var h=Mt(t);if(h){if(s=Iae(t),!o)return mT(t,s)}else{var f=Do(t),d=f==rse||f==BMe;if(Kl(t))return dT(t,o);if(f==nse||f==tse||d&&!i){if(s=l||d?{}:xT(t),!o)return l?Eae(t,xae(s,t)):Tae(t,yae(s,t))}else{if(!In[f])return i?t:{};s=Vae(t,f,o)}}a||(a=new Xc);var p=a.get(t);if(p)return p;a.set(t,s),Jae(t)?t.forEach(function(y){s.add(Ck(y,e,r,y,t,a))}):Xae(t)&&t.forEach(function(y,v){s.set(v,Ck(y,e,r,v,t,a))});var g=u?l?kk:wx:l?Xs:Zr,m=h?void 0:g(t);return lk(m||t,function(y,v){m&&(v=y,y=t[v]),Zc(s,v,Ck(y,e,r,v,t,a))}),s}var RMe,DMe,NMe,tse,IMe,MMe,OMe,PMe,rse,BMe,FMe,$Me,nse,zMe,GMe,qMe,VMe,UMe,WMe,HMe,YMe,XMe,jMe,KMe,ZMe,QMe,JMe,eOe,tOe,In,Ak,iD=$(()=>{Z2();YR();Dm();vae();bae();A9();R9();kae();Sae();tD();rD();a0();Mae();Uae();N9();Kn();Rm();jae();Ao();ese();au();Nf();RMe=1,DMe=2,NMe=4,tse="[object Arguments]",IMe="[object Array]",MMe="[object Boolean]",OMe="[object Date]",PMe="[object Error]",rse="[object Function]",BMe="[object GeneratorFunction]",FMe="[object Map]",$Me="[object Number]",nse="[object Object]",zMe="[object RegExp]",GMe="[object Set]",qMe="[object String]",VMe="[object Symbol]",UMe="[object WeakMap]",WMe="[object ArrayBuffer]",HMe="[object DataView]",YMe="[object Float32Array]",XMe="[object Float64Array]",jMe="[object Int8Array]",KMe="[object Int16Array]",ZMe="[object Int32Array]",QMe="[object Uint8Array]",JMe="[object Uint8ClampedArray]",eOe="[object Uint16Array]",tOe="[object Uint32Array]",In={};In[tse]=In[IMe]=In[WMe]=In[HMe]=In[MMe]=In[OMe]=In[YMe]=In[XMe]=In[jMe]=In[KMe]=In[ZMe]=In[FMe]=In[$Me]=In[nse]=In[zMe]=In[GMe]=In[qMe]=In[VMe]=In[QMe]=In[JMe]=In[eOe]=In[tOe]=!0;In[PMe]=In[rse]=In[UMe]=!1;Ak=Ck});function nOe(t){return Ak(t,rOe)}var rOe,fn,aD=$(()=>{iD();rOe=4;fn=nOe});function sOe(t){return Ak(t,iOe|aOe)}var iOe,aOe,sD,ise=$(()=>{iD();iOe=1,aOe=4;sD=sOe});function oOe(t){for(var e=-1,r=t==null?0:t.length,n=0,i=[];++e{lu=oOe});function cOe(t){return this.__data__.set(t,lOe),this}var lOe,sse,ose=$(()=>{lOe="__lodash_hash_undefined__";sse=cOe});function uOe(t){return this.__data__.has(t)}var lse,cse=$(()=>{lse=uOe});function _k(t){var e=-1,r=t==null?0:t.length;for(this.__data__=new Yp;++e{hT();ose();cse();_k.prototype.add=_k.prototype.push=sse;_k.prototype.has=lse;jm=_k});function hOe(t,e){for(var r=-1,n=t==null?0:t.length;++r{Rk=hOe});function fOe(t,e){return t.has(e)}var Km,Dk=$(()=>{Km=fOe});function gOe(t,e,r,n,i,a){var s=r&dOe,o=t.length,l=e.length;if(o!=l&&!(s&&l>o))return!1;var u=a.get(t),h=a.get(e);if(u&&h)return u==e&&h==t;var f=-1,d=!0,p=r&pOe?new jm:void 0;for(a.set(t,e),a.set(e,t);++f{Lk();oD();Dk();dOe=1,pOe=2;Nk=gOe});function mOe(t){var e=-1,r=Array(t.size);return t.forEach(function(n,i){r[++e]=[i,n]}),r}var use,hse=$(()=>{use=mOe});function yOe(t){var e=-1,r=Array(t.size);return t.forEach(function(n){r[++e]=n}),r}var Zm,Ik=$(()=>{Zm=yOe});function DOe(t,e,r,n,i,a,s){switch(r){case ROe:if(t.byteLength!=e.byteLength||t.byteOffset!=e.byteOffset)return!1;t=t.buffer,e=e.buffer;case LOe:return!(t.byteLength!=e.byteLength||!a(new Em(t),new Em(e)));case bOe:case wOe:case EOe:return nl(+t,+e);case TOe:return t.name==e.name&&t.message==e.message;case SOe:case AOe:return t==e+"";case kOe:var o=use;case COe:var l=n&vOe;if(o||(o=Zm),t.size!=e.size&&!l)return!1;var u=s.get(t);if(u)return u==e;n|=xOe,s.set(t,e);var h=Nk(o(t),o(e),n,i,a,s);return s.delete(t),h;case _Oe:if(cD)return cD.call(t)==cD.call(e)}return!1}var vOe,xOe,bOe,wOe,TOe,kOe,EOe,SOe,COe,AOe,_Oe,LOe,ROe,fse,cD,dse,pse=$(()=>{Wp();_9();Hp();lD();hse();Ik();vOe=1,xOe=2,bOe="[object Boolean]",wOe="[object Date]",TOe="[object Error]",kOe="[object Map]",EOe="[object Number]",SOe="[object RegExp]",COe="[object Set]",AOe="[object String]",_Oe="[object Symbol]",LOe="[object ArrayBuffer]",ROe="[object DataView]",fse=na?na.prototype:void 0,cD=fse?fse.valueOf:void 0;dse=DOe});function OOe(t,e,r,n,i,a){var s=r&NOe,o=wx(t),l=o.length,u=wx(e),h=u.length;if(l!=h&&!s)return!1;for(var f=l;f--;){var d=o[f];if(!(s?d in e:MOe.call(e,d)))return!1}var p=a.get(t),g=a.get(e);if(p&&g)return p==e&&g==t;var m=!0;a.set(t,e),a.set(e,t);for(var y=s;++f{tD();NOe=1,IOe=Object.prototype,MOe=IOe.hasOwnProperty;gse=OOe});function FOe(t,e,r,n,i,a){var s=Mt(t),o=Mt(e),l=s?vse:Do(t),u=o?vse:Do(e);l=l==yse?Mk:l,u=u==yse?Mk:u;var h=l==Mk,f=u==Mk,d=l==u;if(d&&Kl(t)){if(!Kl(e))return!1;s=!0,h=!1}if(d&&!h)return a||(a=new Xc),s||Rf(t)?Nk(t,e,r,n,i,a):dse(t,e,l,r,n,i,a);if(!(r&POe)){var p=h&&xse.call(t,"__wrapped__"),g=f&&xse.call(e,"__wrapped__");if(p||g){var m=p?t.value():t,y=g?e.value():e;return a||(a=new Xc),i(m,y,r,n,a)}}return d?(a||(a=new Xc),gse(t,e,r,n,i,a)):!1}var POe,yse,vse,Mk,BOe,xse,bse,wse=$(()=>{Z2();lD();pse();mse();a0();Kn();Rm();tx();POe=1,yse="[object Arguments]",vse="[object Array]",Mk="[object Object]",BOe=Object.prototype,xse=BOe.hasOwnProperty;bse=FOe});function Tse(t,e,r,n,i){return t===e?!0:t==null||e==null||!ci(t)&&!ci(e)?t!==t&&e!==e:bse(t,e,r,n,Tse,i)}var Ok,uD=$(()=>{wse();il();Ok=Tse});function GOe(t,e,r,n){var i=r.length,a=i,s=!n;if(t==null)return!a;for(t=Object(t);i--;){var o=r[i];if(s&&o[2]?o[1]!==t[o[0]]:!(o[0]in t))return!1}for(;++i{Z2();uD();$Oe=1,zOe=2;kse=GOe});function qOe(t){return t===t&&!_n(t)}var Pk,hD=$(()=>{Ao();Pk=qOe});function VOe(t){for(var e=Zr(t),r=e.length;r--;){var n=e[r],i=t[n];e[r]=[n,i,Pk(i)]}return e}var Sse,Cse=$(()=>{hD();au();Sse=VOe});function UOe(t,e){return function(r){return r==null?!1:r[t]===e&&(e!==void 0||t in Object(r))}}var Bk,fD=$(()=>{Bk=UOe});function WOe(t){var e=Sse(t);return e.length==1&&e[0][2]?Bk(e[0][0],e[0][1]):function(r){return r===t||kse(r,t,e)}}var Ase,_se=$(()=>{Ese();Cse();fD();Ase=WOe});function HOe(t,e){return t!=null&&e in Object(t)}var Lse,Rse=$(()=>{Lse=HOe});function YOe(t,e,r){e=$f(e,t);for(var n=-1,i=e.length,a=!1;++n{xx();_m();Kn();nx();bT();Um();Fk=YOe});function XOe(t,e){return t!=null&&Fk(t,e,Lse)}var $k,pD=$(()=>{Rse();dD();$k=XOe});function ZOe(t,e){return Vm(t)&&Pk(e)?Bk(su(t),e):function(r){var n=aae(r,t);return n===void 0&&n===e?$k(r,t):Ok(e,n,jOe|KOe)}}var jOe,KOe,Dse,Nse=$(()=>{uD();sae();pD();dk();hD();fD();Um();jOe=1,KOe=2;Dse=ZOe});function QOe(t){return function(e){return e?.[t]}}var zk,gD=$(()=>{zk=QOe});function JOe(t){return function(e){return zf(e,t)}}var Ise,Mse=$(()=>{bx();Ise=JOe});function ePe(t){return Vm(t)?zk(su(t)):Ise(t)}var Ose,Pse=$(()=>{gD();Mse();dk();Um();Ose=ePe});function tPe(t){return typeof t=="function"?t:t==null?ia:typeof t=="object"?Mt(t)?Dse(t[0],t[1]):Ase(t):Ose(t)}var En,Ts=$(()=>{_se();Nse();gh();Kn();Pse();En=tPe});function rPe(t,e,r,n){for(var i=-1,a=t==null?0:t.length;++i{Bse=rPe});function nPe(t,e){return t&&km(t,e,Zr)}var Qm,Gk=$(()=>{fT();au();Qm=nPe});function iPe(t,e){return function(r,n){if(r==null)return r;if(!xi(r))return t(r,n);for(var i=r.length,a=e?i:-1,s=Object(r);(e?a--:++a{al();$se=iPe});var aPe,eo,qf=$(()=>{Gk();zse();aPe=$se(Qm),eo=aPe});function sPe(t,e,r,n){return eo(t,function(i,a,s){e(n,i,r(i),s)}),n}var Gse,qse=$(()=>{qf();Gse=sPe});function oPe(t,e){return function(r,n){var i=Mt(r)?Bse:Gse,a=e?e():{};return i(r,t,En(n,2),a)}}var Vse,Use=$(()=>{Fse();qse();Ts();Kn();Vse=oPe});var lPe,qk,Wse=$(()=>{rl();lPe=function(){return yi.Date.now()},qk=lPe});var Hse,cPe,uPe,Vf,Yse=$(()=>{Nm();Hp();Zp();Nf();Hse=Object.prototype,cPe=Hse.hasOwnProperty,uPe=Qc(function(t,e){t=Object(t);var r=-1,n=e.length,i=n>2?e[2]:void 0;for(i&&_o(e[0],e[1],i)&&(n=1);++r{Vk=hPe});function dPe(t,e,r,n){var i=-1,a=hk,s=!0,o=t.length,l=[],u=e.length;if(!o)return l;r&&(e=Js(e,sl(r))),n?(a=Vk,s=!1):e.length>=fPe&&(a=Km,s=!1,e=new jm(e));e:for(;++i{Lk();jR();mD();n0();jp();Dk();fPe=200;Xse=dPe});var pPe,Uf,Kse=$(()=>{jse();Hm();Nm();wT();pPe=Qc(function(t,e){return Xp(t)?Xse(t,ou(e,1,Xp,!0)):[]}),Uf=pPe});function gPe(t){var e=t==null?0:t.length;return e?t[e-1]:void 0}var aa,Zse=$(()=>{aa=gPe});function mPe(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:iu(e),yk(t,e<0?0:e,n)):[]}var Si,Qse=$(()=>{ZR();zm();Si=mPe});function yPe(t,e,r){var n=t==null?0:t.length;return n?(e=r||e===void 0?1:iu(e),e=n-e,yk(t,0,e<0?0:e)):[]}var vh,Jse=$(()=>{ZR();zm();vh=yPe});function vPe(t){return typeof t=="function"?t:ia}var Jm,Uk=$(()=>{gh();Jm=vPe});function xPe(t,e){var r=Mt(t)?lk:eo;return r(t,Jm(e))}var Re,Wk=$(()=>{YR();qf();Uk();Kn();Re=xPe});var eoe=$(()=>{Wk()});function bPe(t,e){for(var r=-1,n=t==null?0:t.length;++r{toe=bPe});function wPe(t,e){var r=!0;return eo(t,function(n,i,a){return r=!!e(n,i,a),r}),r}var noe,ioe=$(()=>{qf();noe=wPe});function TPe(t,e,r){var n=Mt(t)?toe:noe;return r&&_o(t,e,r)&&(e=void 0),n(t,En(e,3))}var Ya,aoe=$(()=>{roe();ioe();Ts();Kn();Zp();Ya=TPe});function kPe(t,e){var r=[];return eo(t,function(n,i,a){e(n,i,a)&&r.push(n)}),r}var Hk,yD=$(()=>{qf();Hk=kPe});function EPe(t,e){var r=Mt(t)?Ym:Hk;return r(t,En(e,3))}var on,vD=$(()=>{vk();yD();Ts();Kn();on=EPe});function SPe(t){return function(e,r,n){var i=Object(e);if(!xi(e)){var a=En(r,3);e=Zr(e),r=function(o){return a(i[o],o,i)}}var s=t(e,r,n);return s>-1?i[a?e[s]:s]:void 0}}var soe,ooe=$(()=>{Ts();al();au();soe=SPe});function APe(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var i=r==null?0:iu(r);return i<0&&(i=CPe(n+i,0)),ck(t,En(e,3),i)}var CPe,loe,coe=$(()=>{XR();Ts();zm();CPe=Math.max;loe=APe});var _Pe,ks,uoe=$(()=>{ooe();coe();_Pe=soe(loe),ks=_Pe});function LPe(t){return t&&t.length?t[0]:void 0}var sa,hoe=$(()=>{sa=LPe});var foe=$(()=>{hoe()});function RPe(t,e){var r=-1,n=xi(t)?Array(t.length):[];return eo(t,function(i,a,s){n[++r]=e(i,a,s)}),n}var Yk,xD=$(()=>{qf();al();Yk=RPe});function DPe(t,e){var r=Mt(t)?Js:Yk;return r(t,En(e,3))}var et,e1=$(()=>{n0();Ts();xD();Kn();et=DPe});function NPe(t,e){return ou(et(t,e),1)}var Da,bD=$(()=>{Hm();e1();Da=NPe});function IPe(t,e){return t==null?t:km(t,Jm(e),Xs)}var wD,doe=$(()=>{fT();Uk();Nf();wD=IPe});function MPe(t,e){return t&&Qm(t,Jm(e))}var TD,poe=$(()=>{Gk();Uk();TD=MPe});var OPe,PPe,BPe,kD,goe=$(()=>{Tm();Use();OPe=Object.prototype,PPe=OPe.hasOwnProperty,BPe=Vse(function(t,e,r){PPe.call(t,r)?t[r].push(e):jc(t,r,[e])}),kD=BPe});function FPe(t,e){return t>e}var moe,yoe=$(()=>{moe=FPe});function GPe(t,e){return t!=null&&zPe.call(t,e)}var $Pe,zPe,voe,xoe=$(()=>{$Pe=Object.prototype,zPe=$Pe.hasOwnProperty;voe=GPe});function qPe(t,e){return t!=null&&Fk(t,e,voe)}var Ot,boe=$(()=>{xoe();dD();Ot=qPe});function UPe(t){return typeof t=="string"||!Mt(t)&&ci(t)&&ka(t)==VPe}var VPe,Ci,Xk=$(()=>{fh();Kn();il();VPe="[object String]";Ci=UPe});function WPe(t,e){return Js(e,function(r){return t[r]})}var woe,Toe=$(()=>{n0();woe=WPe});function HPe(t){return t==null?[]:woe(t,Zr(t))}var br,ED=$(()=>{Toe();au();br=HPe});function XPe(t,e,r,n){t=xi(t)?t:br(t),r=r&&!n?iu(r):0;var i=t.length;return r<0&&(r=YPe(i+r,0)),Ci(t)?r<=i&&t.indexOf(e,r)>-1:!!i&&Gm(t,e,r)>-1}var YPe,Zn,koe=$(()=>{uk();al();Xk();zm();ED();YPe=Math.max;Zn=XPe});function KPe(t,e,r){var n=t==null?0:t.length;if(!n)return-1;var i=r==null?0:iu(r);return i<0&&(i=jPe(n+i,0)),Gm(t,e,i)}var jPe,jk,Eoe=$(()=>{uk();zm();jPe=Math.max;jk=KPe});function tBe(t){if(t==null)return!0;if(xi(t)&&(Mt(t)||typeof t=="string"||typeof t.splice=="function"||Kl(t)||Rf(t)||jl(t)))return!t.length;var e=Do(t);if(e==ZPe||e==QPe)return!t.size;if(Kc(t))return!qm(t).length;for(var r in t)if(eBe.call(t,r))return!1;return!0}var ZPe,QPe,JPe,eBe,dr,Kk=$(()=>{fk();a0();_m();Kn();al();Rm();Am();tx();ZPe="[object Map]",QPe="[object Set]",JPe=Object.prototype,eBe=JPe.hasOwnProperty;dr=tBe});function nBe(t){return ci(t)&&ka(t)==rBe}var rBe,Soe,Coe=$(()=>{fh();il();rBe="[object RegExp]";Soe=nBe});var Aoe,iBe,ul,_oe=$(()=>{Coe();jp();ex();Aoe=ol&&ol.isRegExp,iBe=Aoe?sl(Aoe):Soe,ul=iBe});function aBe(t){return t===void 0}var mr,Loe=$(()=>{mr=aBe});function sBe(t,e){return t{Zk=sBe});function oBe(t,e){var r={};return e=En(e,3),Qm(t,function(n,i,a){jc(r,i,e(n,i,a))}),r}var s0,Roe=$(()=>{Tm();Gk();Ts();s0=oBe});function lBe(t,e,r){for(var n=-1,i=t.length;++n{r0();t1=lBe});function cBe(t){return t&&t.length?t1(t,ia,moe):void 0}var to,Doe=$(()=>{Qk();yoe();gh();to=cBe});function uBe(t){return t&&t.length?t1(t,ia,Zk):void 0}var Jl,CD=$(()=>{Qk();SD();gh();Jl=uBe});function hBe(t,e){return t&&t.length?t1(t,En(e,2),Zk):void 0}var o0,Noe=$(()=>{Qk();Ts();SD();o0=hBe});function dBe(t){if(typeof t!="function")throw new TypeError(fBe);return function(){var e=arguments;switch(e.length){case 0:return!t.call(this);case 1:return!t.call(this,e[0]);case 2:return!t.call(this,e[0],e[1]);case 3:return!t.call(this,e[0],e[1],e[2])}return!t.apply(this,e)}}var fBe,Ioe,Moe=$(()=>{fBe="Expected a function";Ioe=dBe});function pBe(t,e,r,n){if(!_n(t))return t;e=$f(e,t);for(var i=-1,a=e.length,s=a-1,o=t;o!=null&&++i{Dm();xx();nx();Ao();Um();Ooe=pBe});function gBe(t,e,r){for(var n=-1,i=e.length,a={};++n{bx();Poe();xx();Jk=gBe});function mBe(t,e){if(t==null)return{};var r=Js(kk(t),function(n){return[n]});return e=En(e),Jk(t,r,function(n,i){return e(n,i[0])})}var ro,Boe=$(()=>{n0();Ts();AD();rD();ro=mBe});function yBe(t,e){var r=t.length;for(t.sort(e);r--;)t[r]=t[r].value;return t}var Foe,$oe=$(()=>{Foe=yBe});function vBe(t,e){if(t!==e){var r=t!==void 0,n=t===null,i=t===t,a=Ro(t),s=e!==void 0,o=e===null,l=e===e,u=Ro(e);if(!o&&!u&&!a&&t>e||a&&s&&l&&!o&&!u||n&&s&&l||!r&&l||!i)return 1;if(!n&&!a&&!u&&t{r0();zoe=vBe});function xBe(t,e,r){for(var n=-1,i=t.criteria,a=e.criteria,s=i.length,o=r.length;++n=o)return l;var u=r[n];return l*(u=="desc"?-1:1)}}return t.index-e.index}var qoe,Voe=$(()=>{Goe();qoe=xBe});function bBe(t,e,r){e.length?e=Js(e,function(a){return Mt(a)?function(s){return zf(s,a.length===1?a[0]:a)}:a}):e=[ia];var n=-1;e=Js(e,sl(En));var i=Yk(t,function(a,s,o){var l=Js(e,function(u){return u(a)});return{criteria:l,index:++n,value:a}});return Foe(i,function(a,s){return qoe(a,s,r)})}var Uoe,Woe=$(()=>{n0();bx();Ts();xD();$oe();jp();Voe();gh();Kn();Uoe=bBe});var wBe,Hoe,Yoe=$(()=>{gD();wBe=zk("length"),Hoe=wBe});function IBe(t){for(var e=Xoe.lastIndex=0;Xoe.test(t);)++e;return e}var joe,TBe,kBe,EBe,SBe,CBe,ABe,_D,LD,_Be,Koe,Zoe,Qoe,LBe,Joe,ele,RBe,DBe,NBe,Xoe,tle,rle=$(()=>{joe="\\ud800-\\udfff",TBe="\\u0300-\\u036f",kBe="\\ufe20-\\ufe2f",EBe="\\u20d0-\\u20ff",SBe=TBe+kBe+EBe,CBe="\\ufe0e\\ufe0f",ABe="["+joe+"]",_D="["+SBe+"]",LD="\\ud83c[\\udffb-\\udfff]",_Be="(?:"+_D+"|"+LD+")",Koe="[^"+joe+"]",Zoe="(?:\\ud83c[\\udde6-\\uddff]){2}",Qoe="[\\ud800-\\udbff][\\udc00-\\udfff]",LBe="\\u200d",Joe=_Be+"?",ele="["+CBe+"]?",RBe="(?:"+LBe+"(?:"+[Koe,Zoe,Qoe].join("|")+")"+ele+Joe+")*",DBe=ele+Joe+RBe,NBe="(?:"+[Koe+_D+"?",_D,Zoe,Qoe,ABe].join("|")+")",Xoe=RegExp(LD+"(?="+LD+")|"+NBe+DBe,"g");tle=IBe});function MBe(t){return dae(t)?tle(t):Hoe(t)}var nle,ile=$(()=>{Yoe();pae();rle();nle=MBe});function OBe(t,e){return Jk(t,e,function(r,n){return $k(t,n)})}var ale,sle=$(()=>{AD();pD();ale=OBe});var PBe,l0,ole=$(()=>{sle();fae();PBe=hae(function(t,e){return t==null?{}:ale(t,e)}),l0=PBe});function $Be(t,e,r,n){for(var i=-1,a=FBe(BBe((e-t)/(r||1)),0),s=Array(a);a--;)s[n?a:++i]=t,t+=r;return s}var BBe,FBe,lle,cle=$(()=>{BBe=Math.ceil,FBe=Math.max;lle=$Be});function zBe(t){return function(e,r,n){return n&&typeof n!="number"&&_o(e,r,n)&&(r=n=void 0),e=$m(e),r===void 0?(r=e,e=0):r=$m(r),n=n===void 0?e{cle();Zp();WR();ule=zBe});var GBe,hl,fle=$(()=>{hle();GBe=ule(),hl=GBe});function qBe(t,e,r,n,i){return i(t,function(a,s,o){r=n?(n=!1,a):e(r,a,s,o)}),r}var dle,ple=$(()=>{dle=qBe});function VBe(t,e,r){var n=Mt(t)?gae:dle,i=arguments.length<3;return n(t,En(e,4),r,i,eo)}var ln,RD=$(()=>{mae();qf();Ts();ple();Kn();ln=VBe});function UBe(t,e){var r=Mt(t)?Ym:Hk;return r(t,Ioe(En(e,3)))}var Wf,gle=$(()=>{vk();yD();Ts();Kn();Moe();Wf=UBe});function YBe(t){if(t==null)return 0;if(xi(t))return Ci(t)?nle(t):t.length;var e=Do(t);return e==WBe||e==HBe?t.size:qm(t).length}var WBe,HBe,DD,mle=$(()=>{fk();a0();al();Xk();ile();WBe="[object Map]",HBe="[object Set]";DD=YBe});function XBe(t,e){var r;return eo(t,function(n,i,a){return r=e(n,i,a),!r}),!!r}var yle,vle=$(()=>{qf();yle=XBe});function jBe(t,e,r){var n=Mt(t)?Rk:yle;return r&&_o(t,e,r)&&(e=void 0),n(t,En(e,3))}var Tx,xle=$(()=>{oD();Ts();vle();Kn();Zp();Tx=jBe});var KBe,cu,ble=$(()=>{Hm();Woe();Nm();Zp();KBe=Qc(function(t,e){if(t==null)return[];var r=e.length;return r>1&&_o(t,e[0],e[1])?e=[]:r>2&&_o(e[0],e[1],e[2])&&(e=[e[0]]),Uoe(t,ou(e,1),[])}),cu=KBe});var ZBe,QBe,wle,Tle=$(()=>{nD();HR();Ik();ZBe=1/0,QBe=Gf&&1/Zm(new Gf([,-0]))[1]==ZBe?function(t){return new Gf(t)}:hi,wle=QBe});function eFe(t,e,r){var n=-1,i=hk,a=t.length,s=!0,o=[],l=o;if(r)s=!1,i=Vk;else if(a>=JBe){var u=e?null:wle(t);if(u)return Zm(u);s=!1,i=Km,l=new jm}else l=e?[]:o;e:for(;++n{Lk();jR();mD();Dk();Tle();Ik();JBe=200;r1=eFe});var tFe,ND,kle=$(()=>{Hm();Nm();eE();wT();tFe=Qc(function(t){return r1(ou(t,1,Xp,!0))}),ND=tFe});function rFe(t){return t&&t.length?r1(t):[]}var n1,Ele=$(()=>{eE();n1=rFe});function nFe(t,e){return t&&t.length?r1(t,En(e,2)):[]}var Sle,Cle=$(()=>{Ts();eE();Sle=nFe});function aFe(t){var e=++iFe;return pk(t)+e}var iFe,c0,Ale=$(()=>{KR();iFe=0;c0=aFe});function sFe(t,e,r){for(var n=-1,i=t.length,a=e.length,s={};++n{_le=sFe});function oFe(t,e){return _le(t||[],e||[],Zc)}var tE,Rle=$(()=>{Dm();Lle();tE=oFe});var Vt=$(()=>{eae();aD();ise();ase();F9();Yse();Kse();Qse();Jse();eoe();aoe();vD();uoe();foe();bD();mk();Wk();doe();poe();goe();boe();gh();koe();Eoe();Kn();Kk();H2();Ao();_oe();Xk();Loe();au();Zse();e1();Roe();Doe();G9();CD();Noe();HR();Wse();ole();Boe();fle();RD();gle();mle();xle();ble();kle();Ele();Ale();ED();Rle();});function Nle(t,e){t[e]?t[e]++:t[e]=1}function Ile(t,e){--t[e]||delete t[e]}function kx(t,e,r,n){var i=""+e,a=""+r;if(!t&&i>a){var s=i;i=a,a=s}return i+Dle+a+Dle+(mr(n)?lFe:n)}function cFe(t,e,r,n){var i=""+e,a=""+r;if(!t&&i>a){var s=i;i=a,a=s}var o={v:i,w:a};return n&&(o.name=n),o}function ID(t,e){return kx(t,e.v,e.w,e.name)}var lFe,u0,Dle,dn,rE=$(()=>{Vt();lFe="\0",u0="\0",Dle="