const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./c4Diagram-c83219d4-D6p8ypCm.js","./svgDrawCommon-b86b1483-Dm0q296R.js","./dayjs.min-CfWDS3UC.js","./_commonjsHelpers-D6-XlEtG.js","./index-bIIEL2MP.js","./iframe-CzjIX-qr.js","./index-CO-0pc0F.js","./index-Z-6k0Xrj.js","./index-aQYXhgXp.js","./index-DrFu-skq.js","./docsPage-CT2vyZOj.js","./Table-F-lkejrq.js","./Table-edLoc1LA.css","./parseCss-DFN8Q8fx.js","./index-D7HDsfES.js","./_color-UiaLB_4F.js","./flowDiagram-50d868cf-TwIyXXXF.js","./flowDb-c6c81e3f-Xo4IlFVb.js","./graph-dRcR-yLk.js","./layout-B3-ufvKb.js","./styles-d45a18b0-KIbkKEsH.js","./index-5325376f-DOibkmr3.js","./clone-BQyYyzoF.js","./edges-96097737-bcIN93B1.js","./createText-1719965b-BPRaF8Mh.js","./line-B-avEjkP.js","./array-BKyUJesY.js","./path-CbwjOpE9.js","./channel-D_sSfY1t.js","./flowDiagram-v2-4f6560a1-BVBLmLuF.js","./erDiagram-0228fc6a-CT6sGbRt.js","./stringify-DnirLPRY.js","./gitGraphDiagram-82fe8481-DyQm-Zjm.js","./ganttDiagram-a2739b55-8AQg64kz.js","./advancedFormat-DF-l3-BJ.js","./linear-TSojd4iL.js","./init-Gi6I4Gst.js","./infoDiagram-8eee0895-GyJkJkHf.js","./pieDiagram-a8764435-CmM5L_IY.js","./arc-DK_-n-_I.js","./ordinal-Cboi1Yqb.js","./quadrantDiagram-1e28029f-OhwuIbQk.js","./xychartDiagram-f5964ef8-DQiAksJb.js","./requirementDiagram-08caed73-D_DgsmVt.js","./sequenceDiagram-c5b8d532-SNdJCDu6.js","./classDiagram-beda092f-DG-1z2TN.js","./styles-b4e223ce-CWhd-5nP.js","./classDiagram-v2-2358418a-Cz8b4ol9.js","./stateDiagram-1ecb1508-BLLG6eEq.js","./styles-ca3715f6-BIgVj4Uz.js","./stateDiagram-v2-c2b004d7-CKQXzi9j.js","./journeyDiagram-c64418c1-DOkECmb-.js","./flowchart-elk-definition-6af322e1-BXfcLmB9.js","./timeline-definition-faaaa080-BNeUvLCv.js","./mindmap-definition-8da855dc-DuBe1rA6.js","./sankeyDiagram-a04cb91d-oat-2JMp.js","./Tableau10-B-NsZVaP.js","./blockDiagram-c4efeb88-CFDJCMbj.js"])))=>i.map(i=>d[i]); import{r as Mo,R as Sh,j as T}from"./index-bIIEL2MP.js";import{useMDXComponents as Js}from"./index-CO-0pc0F.js";import{M as wh}from"./index-Z-6k0Xrj.js";import{p as Bh}from"./docsPage-CT2vyZOj.js";import{_ as N}from"./iframe-CzjIX-qr.js";import{d as Ah}from"./index-DrFu-skq.js";import{d as Lh}from"./dayjs.min-CfWDS3UC.js";import{C as Fh}from"./Table-F-lkejrq.js";import{c as Eh}from"./parseCss-DFN8Q8fx.js";import{c as Oh}from"./_color-UiaLB_4F.js";var zr={},Io;function Mh(){return Io||(Io=1,function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.sanitizeUrl=t.BLANK_URL=void 0;var e=/^([^\w]*)(javascript|data|vbscript)/im,i=/&#(\w+)(^\w|;)?/g,r=/&(newline|tab);/gi,n=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,o=/^.+(:|:)/gim,s=[".","/"];t.BLANK_URL="about:blank";function a(u){return s.indexOf(u[0])>-1}function l(u){var d=u.replace(n,"");return d.replace(i,function(c,g){return String.fromCharCode(g)})}function h(u){if(!u)return t.BLANK_URL;var d=l(u).replace(r,"").replace(n,"").trim();if(!d)return t.BLANK_URL;if(a(d))return d;var c=d.match(o);if(!c)return d;var g=c[0];return e.test(g)?t.BLANK_URL:d}t.sanitizeUrl=h}(zr)),zr}var Ih=Mh(),Dh={value:()=>{}};function Qs(){for(var t=0,e=arguments.length,i={},r;t=0&&(r=i.slice(n+1),i=i.slice(0,n)),i&&!e.hasOwnProperty(i))throw new Error("unknown type: "+i);return{type:i,name:r}})}Ei.prototype=Qs.prototype={constructor:Ei,on:function(t,e){var i=this._,r=Nh(t+"",i),n,o=-1,s=r.length;if(arguments.length<2){for(;++o0)for(var i=new Array(n),r=0,n,o;r=0&&(e=t.slice(0,i))!=="xmlns"&&(t=t.slice(i+1)),No.hasOwnProperty(e)?{space:No[e],local:t}:t}function Ph(t){return function(){var e=this.ownerDocument,i=this.namespaceURI;return i===sn&&e.documentElement.namespaceURI===sn?e.createElement(t):e.createElementNS(i,t)}}function $h(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function ta(t){var e=lr(t);return(e.local?$h:Ph)(e)}function qh(){}function An(t){return t==null?qh:function(){return this.querySelector(t)}}function zh(t){typeof t!="function"&&(t=An(t));for(var e=this._groups,i=e.length,r=new Array(i),n=0;n=R&&(R=x+1);!(P=v[R])&&++R=0;)(s=r[n])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function fc(t){t||(t=dc);function e(d,c){return d&&c?t(d.__data__,c.__data__):!d-!c}for(var i=this._groups,r=i.length,n=new Array(r),o=0;oe?1:t>=e?0:NaN}function pc(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function gc(){return Array.from(this)}function mc(){for(var t=this._groups,e=0,i=t.length;e1?this.each((e==null?Bc:typeof e=="function"?Lc:Ac)(t,e,i??"")):be(this.node(),t)}function be(t,e){return t.style.getPropertyValue(e)||oa(t).getComputedStyle(t,null).getPropertyValue(e)}function Ec(t){return function(){delete this[t]}}function Oc(t,e){return function(){this[t]=e}}function Mc(t,e){return function(){var i=e.apply(this,arguments);i==null?delete this[t]:this[t]=i}}function Ic(t,e){return arguments.length>1?this.each((e==null?Ec:typeof e=="function"?Mc:Oc)(t,e)):this.node()[t]}function sa(t){return t.trim().split(/^|\s+/)}function Ln(t){return t.classList||new aa(t)}function aa(t){this._node=t,this._names=sa(t.getAttribute("class")||"")}aa.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 la(t,e){for(var i=Ln(t),r=-1,n=e.length;++r=0&&(i=e.slice(r+1),e=e.slice(0,r)),{type:e,name:i}})}function lu(t){return function(){var e=this.__on;if(e){for(var i=0,r=-1,n=e.length,o;i>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):i===8?ki(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):i===4?ki(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=_u.exec(t))?new st(e[1],e[2],e[3],1):(e=yu.exec(t))?new st(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=Cu.exec(t))?ki(e[1],e[2],e[3],e[4]):(e=xu.exec(t))?ki(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=bu.exec(t))?jo(e[1],e[2]/100,e[3]/100,1):(e=Tu.exec(t))?jo(e[1],e[2]/100,e[3]/100,e[4]):Ro.hasOwnProperty(t)?qo(Ro[t]):t==="transparent"?new st(NaN,NaN,NaN,0):null}function qo(t){return new st(t>>16&255,t>>8&255,t&255,1)}function ki(t,e,i,r){return r<=0&&(t=e=i=NaN),new st(t,e,i,r)}function Su(t){return t instanceof ui||(t=ni(t)),t?(t=t.rgb(),new st(t.r,t.g,t.b,t.opacity)):new st}function an(t,e,i,r){return arguments.length===1?Su(t):new st(t,e,i,r??1)}function st(t,e,i,r){this.r=+t,this.g=+e,this.b=+i,this.opacity=+r}Fn(st,an,fa(ui,{brighter(t){return t=t==null?zi:Math.pow(zi,t),new st(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?ii:Math.pow(ii,t),new st(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new st(Jt(this.r),Jt(this.g),Jt(this.b),Wi(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:zo,formatHex:zo,formatHex8:wu,formatRgb:Wo,toString:Wo}));function zo(){return`#${Kt(this.r)}${Kt(this.g)}${Kt(this.b)}`}function wu(){return`#${Kt(this.r)}${Kt(this.g)}${Kt(this.b)}${Kt((isNaN(this.opacity)?1:this.opacity)*255)}`}function Wo(){const t=Wi(this.opacity);return`${t===1?"rgb(":"rgba("}${Jt(this.r)}, ${Jt(this.g)}, ${Jt(this.b)}${t===1?")":`, ${t})`}`}function Wi(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Jt(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Kt(t){return t=Jt(t),(t<16?"0":"")+t.toString(16)}function jo(t,e,i,r){return r<=0?t=e=i=NaN:i<=0||i>=1?t=e=NaN:e<=0&&(t=NaN),new mt(t,e,i,r)}function da(t){if(t instanceof mt)return new mt(t.h,t.s,t.l,t.opacity);if(t instanceof ui||(t=ni(t)),!t)return new mt;if(t instanceof mt)return t;t=t.rgb();var e=t.r/255,i=t.g/255,r=t.b/255,n=Math.min(e,i,r),o=Math.max(e,i,r),s=NaN,a=o-n,l=(o+n)/2;return a?(e===o?s=(i-r)/a+(i0&&l<1?0:s,new mt(s,a,l,t.opacity)}function Bu(t,e,i,r){return arguments.length===1?da(t):new mt(t,e,i,r??1)}function mt(t,e,i,r){this.h=+t,this.s=+e,this.l=+i,this.opacity=+r}Fn(mt,Bu,fa(ui,{brighter(t){return t=t==null?zi:Math.pow(zi,t),new mt(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?ii:Math.pow(ii,t),new mt(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,i=this.l,r=i+(i<.5?i:1-i)*e,n=2*i-r;return new st(Wr(t>=240?t-240:t+120,n,r),Wr(t,n,r),Wr(t<120?t+240:t-120,n,r),this.opacity)},clamp(){return new mt(Ho(this.h),Si(this.s),Si(this.l),Wi(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(){const t=Wi(this.opacity);return`${t===1?"hsl(":"hsla("}${Ho(this.h)}, ${Si(this.s)*100}%, ${Si(this.l)*100}%${t===1?")":`, ${t})`}`}}));function Ho(t){return t=(t||0)%360,t<0?t+360:t}function Si(t){return Math.max(0,Math.min(1,t||0))}function Wr(t,e,i){return(t<60?e+(i-e)*t/60:t<180?i:t<240?e+(i-e)*(240-t)/60:e)*255}const En=t=>()=>t;function pa(t,e){return function(i){return t+i*e}}function Au(t,e,i){return t=Math.pow(t,i),e=Math.pow(e,i)-t,i=1/i,function(r){return Math.pow(t+r*e,i)}}function Yb(t,e){var i=e-t;return i?pa(t,i>180||i<-180?i-360*Math.round(i/360):i):En(isNaN(t)?e:t)}function Lu(t){return(t=+t)==1?ga:function(e,i){return i-e?Au(e,i,t):En(isNaN(e)?i:e)}}function ga(t,e){var i=e-t;return i?pa(t,i):En(isNaN(t)?e:t)}const Uo=function t(e){var i=Lu(e);function r(n,o){var s=i((n=an(n)).r,(o=an(o)).r),a=i(n.g,o.g),l=i(n.b,o.b),h=ga(n.opacity,o.opacity);return function(u){return n.r=s(u),n.g=a(u),n.b=l(u),n.opacity=h(u),n+""}}return r.gamma=t,r}(1);function zt(t,e){return t=+t,e=+e,function(i){return t*(1-i)+e*i}}var ln=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,jr=new RegExp(ln.source,"g");function Fu(t){return function(){return t}}function Eu(t){return function(e){return t(e)+""}}function Ou(t,e){var i=ln.lastIndex=jr.lastIndex=0,r,n,o,s=-1,a=[],l=[];for(t=t+"",e=e+"";(r=ln.exec(t))&&(n=jr.exec(e));)(o=n.index)>i&&(o=e.slice(i,o),a[s]?a[s]+=o:a[++s]=o),(r=r[0])===(n=n[0])?a[s]?a[s]+=n:a[++s]=n:(a[++s]=null,l.push({i:s,x:zt(r,n)})),i=jr.lastIndex;return i180?u+=360:u-h>180&&(h+=360),c.push({i:d.push(n(d)+"rotate(",null,r)-2,x:zt(h,u)})):u&&d.push(n(d)+"rotate("+u+r)}function a(h,u,d,c){h!==u?c.push({i:d.push(n(d)+"skewX(",null,r)-2,x:zt(h,u)}):u&&d.push(n(d)+"skewX("+u+r)}function l(h,u,d,c,g,y){if(h!==d||u!==c){var C=g.push(n(g)+"scale(",null,",",null,")");y.push({i:C-4,x:zt(h,d)},{i:C-2,x:zt(u,c)})}else(d!==1||c!==1)&&g.push(n(g)+"scale("+d+","+c+")")}return function(h,u){var d=[],c=[];return h=t(h),u=t(u),o(h.translateX,h.translateY,u.translateX,u.translateY,d,c),s(h.rotate,u.rotate,d,c),a(h.skewX,u.skewX,d,c),l(h.scaleX,h.scaleY,u.scaleX,u.scaleY,d,c),h=u=null,function(g){for(var y=-1,C=c.length,v;++y=0&&t._call.call(void 0,e),t=t._next;--Te}function Go(){te=(Hi=oi.now())+hr,Te=Ye=0;try{Pu()}finally{Te=0,qu(),te=0}}function $u(){var t=oi.now(),e=t-Hi;e>ya&&(hr-=e,Hi=t)}function qu(){for(var t,e=ji,i,r=1/0;e;)e._call?(r>e._time&&(r=e._time),t=e,e=e._next):(i=e._next,e._next=null,e=t?t._next=i:ji=i);Ge=t,cn(r)}function cn(t){if(!Te){Ye&&(Ye=clearTimeout(Ye));var e=t-te;e>24?(t<1/0&&(Ye=setTimeout(Go,t-oi.now()-hr)),$e&&($e=clearInterval($e))):($e||(Hi=oi.now(),$e=setInterval($u,ya)),Te=1,Ca(Go))}}function Vo(t,e,i){var r=new Ui;return e=e==null?0:+e,r.restart(n=>{r.stop(),t(n+e)},e,i),r}var zu=Qs("start","end","cancel","interrupt"),Wu=[],ba=0,Xo=1,un=2,Oi=3,Ko=4,fn=5,Mi=6;function cr(t,e,i,r,n,o){var s=t.__transition;if(!s)t.__transition={};else if(i in s)return;ju(t,i,{name:e,index:r,group:n,on:zu,tween:Wu,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:ba})}function Mn(t,e){var i=yt(t,e);if(i.state>ba)throw new Error("too late; already scheduled");return i}function Bt(t,e){var i=yt(t,e);if(i.state>Oi)throw new Error("too late; already running");return i}function yt(t,e){var i=t.__transition;if(!i||!(i=i[e]))throw new Error("transition not found");return i}function ju(t,e,i){var r=t.__transition,n;r[e]=i,i.timer=xa(o,0,i.time);function o(h){i.state=Xo,i.timer.restart(s,i.delay,i.time),i.delay<=h&&s(h-i.delay)}function s(h){var u,d,c,g;if(i.state!==Xo)return l();for(u in r)if(g=r[u],g.name===i.name){if(g.state===Oi)return Vo(s);g.state===Ko?(g.state=Mi,g.timer.stop(),g.on.call("interrupt",t,t.__data__,g.index,g.group),delete r[u]):+uun&&r.state=0&&(e=e.slice(0,i)),!e||e==="start"})}function bf(t,e,i){var r,n,o=xf(e)?Mn:Bt;return function(){var s=o(this,t),a=s.on;a!==r&&(n=(r=a).copy()).on(e,i),s.on=n}}function Tf(t,e){var i=this._id;return arguments.length<2?yt(this.node(),i).on.on(t):this.each(bf(i,t,e))}function vf(t){return function(){var e=this.parentNode;for(var i in this.__transition)if(+i!==t)return;e&&e.removeChild(this)}}function kf(){return this.on("end.remove",vf(this._id))}function Sf(t){var e=this._name,i=this._id;typeof t!="function"&&(t=An(t));for(var r=this._groups,n=r.length,o=new Array(n),s=0;s1?0:t<-1?Dn:Math.acos(t)}function i1(t){return t>=1?Jo:t<=-1?-Jo:Math.asin(t)}function Sa(t){this._context=t}Sa.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 Kf(t){return new Sa(t)}class wa{constructor(e,i){this._context=e,this._x=i}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,i){switch(e=+e,i=+i,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,i):this._context.moveTo(e,i);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,i,e,i):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+i)/2,e,this._y0,e,i);break}}this._x0=e,this._y0=i}}function Zf(t){return new wa(t,!0)}function Jf(t){return new wa(t,!1)}function Ht(){}function Yi(t,e,i){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+i)/6)}function ur(t){this._context=t}ur.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:Yi(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:Yi(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Qf(t){return new ur(t)}function Ba(t){this._context=t}Ba.prototype={areaStart:Ht,areaEnd:Ht,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:Yi(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function td(t){return new Ba(t)}function Aa(t){this._context=t}Aa.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 i=(this._x0+4*this._x1+t)/6,r=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(i,r):this._context.moveTo(i,r);break;case 3:this._point=4;default:Yi(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function ed(t){return new Aa(t)}function La(t,e){this._basis=new ur(t),this._beta=e}La.prototype={lineStart:function(){this._x=[],this._y=[],this._basis.lineStart()},lineEnd:function(){var t=this._x,e=this._y,i=t.length-1;if(i>0)for(var r=t[0],n=e[0],o=t[i]-r,s=e[i]-n,a=-1,l;++a<=i;)l=a/i,this._basis.point(this._beta*t[a]+(1-this._beta)*(r+l*o),this._beta*e[a]+(1-this._beta)*(n+l*s));this._x=this._y=null,this._basis.lineEnd()},point:function(t,e){this._x.push(+t),this._y.push(+e)}};const id=function t(e){function i(r){return e===1?new ur(r):new La(r,e)}return i.beta=function(r){return t(+r)},i}(.85);function Gi(t,e,i){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-i),t._x2,t._y2)}function Nn(t,e){this._context=t,this._k=(1-e)/6}Nn.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:Gi(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:Gi(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}};const rd=function t(e){function i(r){return new Nn(r,e)}return i.tension=function(r){return t(+r)},i}(0);function Rn(t,e){this._context=t,this._k=(1-e)/6}Rn.prototype={areaStart:Ht,areaEnd:Ht,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:Gi(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}};const nd=function t(e){function i(r){return new Rn(r,e)}return i.tension=function(r){return t(+r)},i}(0);function Pn(t,e){this._context=t,this._k=(1-e)/6}Pn.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:Gi(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}};const od=function t(e){function i(r){return new Pn(r,e)}return i.tension=function(r){return t(+r)},i}(0);function $n(t,e,i){var r=t._x1,n=t._y1,o=t._x2,s=t._y2;if(t._l01_a>Zo){var a=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);r=(r*a-t._x0*t._l12_2a+t._x2*t._l01_2a)/l,n=(n*a-t._y0*t._l12_2a+t._y2*t._l01_2a)/l}if(t._l23_a>Zo){var h=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,u=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*h+t._x1*t._l23_2a-e*t._l12_2a)/u,s=(s*h+t._y1*t._l23_2a-i*t._l12_2a)/u}t._context.bezierCurveTo(r,n,o,s,t._x2,t._y2)}function Fa(t,e){this._context=t,this._alpha=e}Fa.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 i=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+r*r,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:$n(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}};const sd=function t(e){function i(r){return e?new Fa(r,e):new Nn(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function Ea(t,e){this._context=t,this._alpha=e}Ea.prototype={areaStart:Ht,areaEnd:Ht,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 i=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+r*r,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:$n(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}};const ad=function t(e){function i(r){return e?new Ea(r,e):new Rn(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function Oa(t,e){this._context=t,this._alpha=e}Oa.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 i=this._x2-t,r=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(i*i+r*r,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:$n(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}};const ld=function t(e){function i(r){return e?new Oa(r,e):new Pn(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function Ma(t){this._context=t}Ma.prototype={areaStart:Ht,areaEnd:Ht,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 hd(t){return new Ma(t)}function Qo(t){return t<0?-1:1}function ts(t,e,i){var r=t._x1-t._x0,n=e-t._x1,o=(t._y1-t._y0)/(r||n<0&&-0),s=(i-t._y1)/(n||r<0&&-0),a=(o*n+s*r)/(r+n);return(Qo(o)+Qo(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function es(t,e){var i=t._x1-t._x0;return i?(3*(t._y1-t._y0)/i-e)/2:e}function Hr(t,e,i){var r=t._x0,n=t._y0,o=t._x1,s=t._y1,a=(o-r)/3;t._context.bezierCurveTo(r+a,n+a*e,o-a,s-a*i,o,s)}function Vi(t){this._context=t}Vi.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:Hr(this,this._t0,es(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 i=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,Hr(this,es(this,i=ts(this,t,e)),i);break;default:Hr(this,this._t0,i=ts(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=i}}};function Ia(t){this._context=new Da(t)}(Ia.prototype=Object.create(Vi.prototype)).point=function(t,e){Vi.prototype.point.call(this,e,t)};function Da(t){this._context=t}Da.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,i,r,n,o){this._context.bezierCurveTo(e,t,r,i,o,n)}};function cd(t){return new Vi(t)}function ud(t){return new Ia(t)}function Na(t){this._context=t}Na.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,i=t.length;if(i)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),i===2)this._context.lineTo(t[1],e[1]);else for(var r=is(t),n=is(e),o=0,s=1;s=0;--e)n[e]=(s[e]-n[e+1])/o[e];for(o[i-1]=(t[i]+n[i-1])/2,e=0;e=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 i=this._x*(1-this._t)+t*this._t;this._context.lineTo(i,this._y),this._context.lineTo(i,e)}break}}this._x=t,this._y=e}};function dd(t){return new fr(t,.5)}function pd(t){return new fr(t,0)}function gd(t){return new fr(t,1)}function Ve(t,e,i){this.k=t,this.x=e,this.y=i}Ve.prototype={constructor:Ve,scale:function(t){return t===1?this:new Ve(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new Ve(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+")"}};Ve.prototype;/*! @license DOMPurify 3.3.1 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.3.1/LICENSE */const{entries:Ra,setPrototypeOf:rs,isFrozen:md,getPrototypeOf:_d,getOwnPropertyDescriptor:yd}=Object;let{freeze:it,seal:ut,create:dn}=Object,{apply:pn,construct:gn}=typeof Reflect<"u"&&Reflect;it||(it=function(e){return e});ut||(ut=function(e){return e});pn||(pn=function(e,i){for(var r=arguments.length,n=new Array(r>2?r-2:0),o=2;o1?i-1:0),n=1;n1?i-1:0),n=1;n2&&arguments[2]!==void 0?arguments[2]:Ii;rs&&rs(t,null);let r=e.length;for(;r--;){let n=e[r];if(typeof n=="string"){const o=i(n);o!==n&&(md(e)||(e[r]=o),n=o)}t[n]=!0}return t}function kd(t){for(let e=0;e/gm),Ld=ut(/\$\{[\w\W]*/gm),Fd=ut(/^data-[\-\w.\u00B7-\uFFFF]+$/),Ed=ut(/^aria-[\-\w]+$/),Pa=ut(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Od=ut(/^(?:\w+script|data):/i),Md=ut(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),$a=ut(/^html$/i),Id=ut(/^[a-z][.\w]*(-[.\w]+)+$/i);var hs=Object.freeze({__proto__:null,ARIA_ATTR:Ed,ATTR_WHITESPACE:Md,CUSTOM_ELEMENT:Id,DATA_ATTR:Fd,DOCTYPE_NAME:$a,ERB_EXPR:Ad,IS_ALLOWED_URI:Pa,IS_SCRIPT_OR_DATA:Od,MUSTACHE_EXPR:Bd,TMPLIT_EXPR:Ld});const He={element:1,text:3,progressingInstruction:7,comment:8,document:9},Dd=function(){return typeof window>"u"?null:window},Nd=function(e,i){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let r=null;const n="data-tt-policy-suffix";i&&i.hasAttribute(n)&&(r=i.getAttribute(n));const o="dompurify"+(r?"#"+r:"");try{return e.createPolicy(o,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+o+" could not be created."),null}},cs=function(){return{afterSanitizeAttributes:[],afterSanitizeElements:[],afterSanitizeShadowDOM:[],beforeSanitizeAttributes:[],beforeSanitizeElements:[],beforeSanitizeShadowDOM:[],uponSanitizeAttribute:[],uponSanitizeElement:[],uponSanitizeShadowNode:[]}};function qa(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Dd();const e=w=>qa(w);if(e.version="3.3.1",e.removed=[],!t||!t.document||t.document.nodeType!==He.document||!t.Element)return e.isSupported=!1,e;let{document:i}=t;const r=i,n=r.currentScript,{DocumentFragment:o,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:h,NamedNodeMap:u=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:c,trustedTypes:g}=t,y=l.prototype,C=je(y,"cloneNode"),v=je(y,"remove"),O=je(y,"nextSibling"),x=je(y,"childNodes"),R=je(y,"parentNode");if(typeof s=="function"){const w=i.createElement("template");w.content&&w.content.ownerDocument&&(i=w.content.ownerDocument)}let F,P="";const{implementation:V,createNodeIterator:M,createDocumentFragment:mi,getElementsByTagName:wr}=i,{importNode:Br}=r;let U=cs();e.isSupported=typeof Ra=="function"&&typeof R=="function"&&V&&V.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:se,ERB_EXPR:Ie,TMPLIT_EXPR:De,DATA_ATTR:Ar,ARIA_ATTR:Lt,IS_SCRIPT_OR_DATA:lo,ATTR_WHITESPACE:ae,CUSTOM_ELEMENT:pt}=hs;let{IS_ALLOWED_URI:ho}=hs,H=null;const co=E({},[...os,...Gr,...Vr,...Xr,...ss]);let Y=null;const uo=E({},[...as,...Kr,...ls,...Ai]);let $=Object.seal(dn(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),Ne=null,Lr=null;const le=Object.seal(dn(null,{tagCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeCheck:{writable:!0,configurable:!1,enumerable:!0,value:null}}));let fo=!0,Fr=!0,po=!1,go=!0,he=!1,_i=!0,Gt=!1,Er=!1,Or=!1,ce=!1,yi=!1,Ci=!1,mo=!0,_o=!1;const _h="user-content-";let Mr=!0,Re=!1,ue={},Ct=null;const Ir=E({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let yo=null;const Co=E({},["audio","video","img","source","image","track"]);let Dr=null;const xo=E({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),xi="http://www.w3.org/1998/Math/MathML",bi="http://www.w3.org/2000/svg",Ft="http://www.w3.org/1999/xhtml";let fe=Ft,Nr=!1,Rr=null;const yh=E({},[xi,bi,Ft],Ur);let Ti=E({},["mi","mo","mn","ms","mtext"]),vi=E({},["annotation-xml"]);const Ch=E({},["title","style","font","a","script"]);let Pe=null;const xh=["application/xhtml+xml","text/html"],bh="text/html";let j=null,de=null;const Th=i.createElement("form"),bo=function(f){return f instanceof RegExp||f instanceof Function},Pr=function(){let f=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(de&&de===f)){if((!f||typeof f!="object")&&(f={}),f=bt(f),Pe=xh.indexOf(f.PARSER_MEDIA_TYPE)===-1?bh:f.PARSER_MEDIA_TYPE,j=Pe==="application/xhtml+xml"?Ur:Ii,H=gt(f,"ALLOWED_TAGS")?E({},f.ALLOWED_TAGS,j):co,Y=gt(f,"ALLOWED_ATTR")?E({},f.ALLOWED_ATTR,j):uo,Rr=gt(f,"ALLOWED_NAMESPACES")?E({},f.ALLOWED_NAMESPACES,Ur):yh,Dr=gt(f,"ADD_URI_SAFE_ATTR")?E(bt(xo),f.ADD_URI_SAFE_ATTR,j):xo,yo=gt(f,"ADD_DATA_URI_TAGS")?E(bt(Co),f.ADD_DATA_URI_TAGS,j):Co,Ct=gt(f,"FORBID_CONTENTS")?E({},f.FORBID_CONTENTS,j):Ir,Ne=gt(f,"FORBID_TAGS")?E({},f.FORBID_TAGS,j):bt({}),Lr=gt(f,"FORBID_ATTR")?E({},f.FORBID_ATTR,j):bt({}),ue=gt(f,"USE_PROFILES")?f.USE_PROFILES:!1,fo=f.ALLOW_ARIA_ATTR!==!1,Fr=f.ALLOW_DATA_ATTR!==!1,po=f.ALLOW_UNKNOWN_PROTOCOLS||!1,go=f.ALLOW_SELF_CLOSE_IN_ATTR!==!1,he=f.SAFE_FOR_TEMPLATES||!1,_i=f.SAFE_FOR_XML!==!1,Gt=f.WHOLE_DOCUMENT||!1,ce=f.RETURN_DOM||!1,yi=f.RETURN_DOM_FRAGMENT||!1,Ci=f.RETURN_TRUSTED_TYPE||!1,Or=f.FORCE_BODY||!1,mo=f.SANITIZE_DOM!==!1,_o=f.SANITIZE_NAMED_PROPS||!1,Mr=f.KEEP_CONTENT!==!1,Re=f.IN_PLACE||!1,ho=f.ALLOWED_URI_REGEXP||Pa,fe=f.NAMESPACE||Ft,Ti=f.MATHML_TEXT_INTEGRATION_POINTS||Ti,vi=f.HTML_INTEGRATION_POINTS||vi,$=f.CUSTOM_ELEMENT_HANDLING||{},f.CUSTOM_ELEMENT_HANDLING&&bo(f.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&($.tagNameCheck=f.CUSTOM_ELEMENT_HANDLING.tagNameCheck),f.CUSTOM_ELEMENT_HANDLING&&bo(f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&($.attributeNameCheck=f.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),f.CUSTOM_ELEMENT_HANDLING&&typeof f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&($.allowCustomizedBuiltInElements=f.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),he&&(Fr=!1),yi&&(ce=!0),ue&&(H=E({},ss),Y=[],ue.html===!0&&(E(H,os),E(Y,as)),ue.svg===!0&&(E(H,Gr),E(Y,Kr),E(Y,Ai)),ue.svgFilters===!0&&(E(H,Vr),E(Y,Kr),E(Y,Ai)),ue.mathMl===!0&&(E(H,Xr),E(Y,ls),E(Y,Ai))),f.ADD_TAGS&&(typeof f.ADD_TAGS=="function"?le.tagCheck=f.ADD_TAGS:(H===co&&(H=bt(H)),E(H,f.ADD_TAGS,j))),f.ADD_ATTR&&(typeof f.ADD_ATTR=="function"?le.attributeCheck=f.ADD_ATTR:(Y===uo&&(Y=bt(Y)),E(Y,f.ADD_ATTR,j))),f.ADD_URI_SAFE_ATTR&&E(Dr,f.ADD_URI_SAFE_ATTR,j),f.FORBID_CONTENTS&&(Ct===Ir&&(Ct=bt(Ct)),E(Ct,f.FORBID_CONTENTS,j)),f.ADD_FORBID_CONTENTS&&(Ct===Ir&&(Ct=bt(Ct)),E(Ct,f.ADD_FORBID_CONTENTS,j)),Mr&&(H["#text"]=!0),Gt&&E(H,["html","head","body"]),H.table&&(E(H,["tbody"]),delete Ne.tbody),f.TRUSTED_TYPES_POLICY){if(typeof f.TRUSTED_TYPES_POLICY.createHTML!="function")throw We('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof f.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw We('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');F=f.TRUSTED_TYPES_POLICY,P=F.createHTML("")}else F===void 0&&(F=Nd(g,n)),F!==null&&typeof P=="string"&&(P=F.createHTML(""));it&&it(f),de=f}},To=E({},[...Gr,...Vr,...Sd]),vo=E({},[...Xr,...wd]),vh=function(f){let m=R(f);(!m||!m.tagName)&&(m={namespaceURI:fe,tagName:"template"});const b=Ii(f.tagName),D=Ii(m.tagName);return Rr[f.namespaceURI]?f.namespaceURI===bi?m.namespaceURI===Ft?b==="svg":m.namespaceURI===xi?b==="svg"&&(D==="annotation-xml"||Ti[D]):!!To[b]:f.namespaceURI===xi?m.namespaceURI===Ft?b==="math":m.namespaceURI===bi?b==="math"&&vi[D]:!!vo[b]:f.namespaceURI===Ft?m.namespaceURI===bi&&!vi[D]||m.namespaceURI===xi&&!Ti[D]?!1:!vo[b]&&(Ch[b]||!To[b]):!!(Pe==="application/xhtml+xml"&&Rr[f.namespaceURI]):!1},xt=function(f){qe(e.removed,{element:f});try{R(f).removeChild(f)}catch{v(f)}},Vt=function(f,m){try{qe(e.removed,{attribute:m.getAttributeNode(f),from:m})}catch{qe(e.removed,{attribute:null,from:m})}if(m.removeAttribute(f),f==="is")if(ce||yi)try{xt(m)}catch{}else try{m.setAttribute(f,"")}catch{}},ko=function(f){let m=null,b=null;if(Or)f=""+f;else{const q=Yr(f,/^[\r\n\t ]+/);b=q&&q[0]}Pe==="application/xhtml+xml"&&fe===Ft&&(f=''+f+"");const D=F?F.createHTML(f):f;if(fe===Ft)try{m=new c().parseFromString(D,Pe)}catch{}if(!m||!m.documentElement){m=V.createDocument(fe,"template",null);try{m.documentElement.innerHTML=Nr?P:D}catch{}}const X=m.body||m.documentElement;return f&&b&&X.insertBefore(i.createTextNode(b),X.childNodes[0]||null),fe===Ft?wr.call(m,Gt?"html":"body")[0]:Gt?m.documentElement:X},So=function(f){return M.call(f.ownerDocument||f,f,h.SHOW_ELEMENT|h.SHOW_COMMENT|h.SHOW_TEXT|h.SHOW_PROCESSING_INSTRUCTION|h.SHOW_CDATA_SECTION,null)},$r=function(f){return f instanceof d&&(typeof f.nodeName!="string"||typeof f.textContent!="string"||typeof f.removeChild!="function"||!(f.attributes instanceof u)||typeof f.removeAttribute!="function"||typeof f.setAttribute!="function"||typeof f.namespaceURI!="string"||typeof f.insertBefore!="function"||typeof f.hasChildNodes!="function")},wo=function(f){return typeof a=="function"&&f instanceof a};function Et(w,f,m){Bi(w,b=>{b.call(e,f,m,de)})}const Bo=function(f){let m=null;if(Et(U.beforeSanitizeElements,f,null),$r(f))return xt(f),!0;const b=j(f.nodeName);if(Et(U.uponSanitizeElement,f,{tagName:b,allowedTags:H}),_i&&f.hasChildNodes()&&!wo(f.firstElementChild)&&Q(/<[/\w!]/g,f.innerHTML)&&Q(/<[/\w!]/g,f.textContent)||f.nodeType===He.progressingInstruction||_i&&f.nodeType===He.comment&&Q(/<[/\w]/g,f.data))return xt(f),!0;if(!(le.tagCheck instanceof Function&&le.tagCheck(b))&&(!H[b]||Ne[b])){if(!Ne[b]&&Lo(b)&&($.tagNameCheck instanceof RegExp&&Q($.tagNameCheck,b)||$.tagNameCheck instanceof Function&&$.tagNameCheck(b)))return!1;if(Mr&&!Ct[b]){const D=R(f)||f.parentNode,X=x(f)||f.childNodes;if(X&&D){const q=X.length;for(let nt=q-1;nt>=0;--nt){const Ot=C(X[nt],!0);Ot.__removalCount=(f.__removalCount||0)+1,D.insertBefore(Ot,O(f))}}}return xt(f),!0}return f instanceof l&&!vh(f)||(b==="noscript"||b==="noembed"||b==="noframes")&&Q(/<\/no(script|embed|frames)/i,f.innerHTML)?(xt(f),!0):(he&&f.nodeType===He.text&&(m=f.textContent,Bi([se,Ie,De],D=>{m=ze(m,D," ")}),f.textContent!==m&&(qe(e.removed,{element:f.cloneNode()}),f.textContent=m)),Et(U.afterSanitizeElements,f,null),!1)},Ao=function(f,m,b){if(mo&&(m==="id"||m==="name")&&(b in i||b in Th))return!1;if(!(Fr&&!Lr[m]&&Q(Ar,m))){if(!(fo&&Q(Lt,m))){if(!(le.attributeCheck instanceof Function&&le.attributeCheck(m,f))){if(!Y[m]||Lr[m]){if(!(Lo(f)&&($.tagNameCheck instanceof RegExp&&Q($.tagNameCheck,f)||$.tagNameCheck instanceof Function&&$.tagNameCheck(f))&&($.attributeNameCheck instanceof RegExp&&Q($.attributeNameCheck,m)||$.attributeNameCheck instanceof Function&&$.attributeNameCheck(m,f))||m==="is"&&$.allowCustomizedBuiltInElements&&($.tagNameCheck instanceof RegExp&&Q($.tagNameCheck,b)||$.tagNameCheck instanceof Function&&$.tagNameCheck(b))))return!1}else if(!Dr[m]){if(!Q(ho,ze(b,ae,""))){if(!((m==="src"||m==="xlink:href"||m==="href")&&f!=="script"&&bd(b,"data:")===0&&yo[f])){if(!(po&&!Q(lo,ze(b,ae,"")))){if(b)return!1}}}}}}}return!0},Lo=function(f){return f!=="annotation-xml"&&Yr(f,pt)},Fo=function(f){Et(U.beforeSanitizeAttributes,f,null);const{attributes:m}=f;if(!m||$r(f))return;const b={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:Y,forceKeepAttr:void 0};let D=m.length;for(;D--;){const X=m[D],{name:q,namespaceURI:nt,value:Ot}=X,pe=j(q),qr=Ot;let G=q==="value"?qr:Td(qr);if(b.attrName=pe,b.attrValue=G,b.keepAttr=!0,b.forceKeepAttr=void 0,Et(U.uponSanitizeAttribute,f,b),G=b.attrValue,_o&&(pe==="id"||pe==="name")&&(Vt(q,f),G=_h+G),_i&&Q(/((--!?|])>)|<\/(style|title|textarea)/i,G)){Vt(q,f);continue}if(pe==="attributename"&&Yr(G,"href")){Vt(q,f);continue}if(b.forceKeepAttr)continue;if(!b.keepAttr){Vt(q,f);continue}if(!go&&Q(/\/>/i,G)){Vt(q,f);continue}he&&Bi([se,Ie,De],Oo=>{G=ze(G,Oo," ")});const Eo=j(f.nodeName);if(!Ao(Eo,pe,G)){Vt(q,f);continue}if(F&&typeof g=="object"&&typeof g.getAttributeType=="function"&&!nt)switch(g.getAttributeType(Eo,pe)){case"TrustedHTML":{G=F.createHTML(G);break}case"TrustedScriptURL":{G=F.createScriptURL(G);break}}if(G!==qr)try{nt?f.setAttributeNS(nt,q,G):f.setAttribute(q,G),$r(f)?xt(f):ns(e.removed)}catch{Vt(q,f)}}Et(U.afterSanitizeAttributes,f,null)},kh=function w(f){let m=null;const b=So(f);for(Et(U.beforeSanitizeShadowDOM,f,null);m=b.nextNode();)Et(U.uponSanitizeShadowNode,m,null),Bo(m),Fo(m),m.content instanceof o&&w(m.content);Et(U.afterSanitizeShadowDOM,f,null)};return e.sanitize=function(w){let f=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},m=null,b=null,D=null,X=null;if(Nr=!w,Nr&&(w=""),typeof w!="string"&&!wo(w))if(typeof w.toString=="function"){if(w=w.toString(),typeof w!="string")throw We("dirty is not a string, aborting")}else throw We("toString is not a function");if(!e.isSupported)return w;if(Er||Pr(f),e.removed=[],typeof w=="string"&&(Re=!1),Re){if(w.nodeName){const Ot=j(w.nodeName);if(!H[Ot]||Ne[Ot])throw We("root node is forbidden and cannot be sanitized in-place")}}else if(w instanceof a)m=ko(""),b=m.ownerDocument.importNode(w,!0),b.nodeType===He.element&&b.nodeName==="BODY"||b.nodeName==="HTML"?m=b:m.appendChild(b);else{if(!ce&&!he&&!Gt&&w.indexOf("<")===-1)return F&&Ci?F.createHTML(w):w;if(m=ko(w),!m)return ce?null:Ci?P:""}m&&Or&&xt(m.firstChild);const q=So(Re?w:m);for(;D=q.nextNode();)Bo(D),Fo(D),D.content instanceof o&&kh(D.content);if(Re)return w;if(ce){if(yi)for(X=mi.call(m.ownerDocument);m.firstChild;)X.appendChild(m.firstChild);else X=m;return(Y.shadowroot||Y.shadowrootmode)&&(X=Br.call(r,X,!0)),X}let nt=Gt?m.outerHTML:m.innerHTML;return Gt&&H["!doctype"]&&m.ownerDocument&&m.ownerDocument.doctype&&m.ownerDocument.doctype.name&&Q($a,m.ownerDocument.doctype.name)&&(nt=" `+nt),he&&Bi([se,Ie,De],Ot=>{nt=ze(nt,Ot," ")}),F&&Ci?F.createHTML(nt):nt},e.setConfig=function(){let w=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Pr(w),Er=!0},e.clearConfig=function(){de=null,Er=!1},e.isValidAttribute=function(w,f,m){de||Pr({});const b=j(w),D=j(f);return Ao(b,D,m)},e.addHook=function(w,f){typeof f=="function"&&qe(U[w],f)},e.removeHook=function(w,f){if(f!==void 0){const m=Cd(U[w],f);return m===-1?void 0:xd(U[w],m,1)[0]}return ns(U[w])},e.removeHooks=function(w){U[w]=[]},e.removeAllHooks=function(){U=cs()},e}var ve=qa();const Di={min:{r:0,g:0,b:0,s:0,l:0,a:0},max:{r:255,g:255,b:255,h:360,s:100,l:100,a:1},clamp:{r:t=>t>=255?255:t<0?0:t,g:t=>t>=255?255:t<0?0:t,b:t=>t>=255?255:t<0?0:t,h:t=>t%360,s:t=>t>=100?100:t<0?0:t,l:t=>t>=100?100:t<0?0:t,a:t=>t>=1?1:t<0?0:t},toLinear:t=>{const e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},hue2rgb:(t,e,i)=>(i<0&&(i+=1),i>1&&(i-=1),i<1/6?t+(e-t)*6*i:i<1/2?e:i<2/3?t+(e-t)*(2/3-i)*6:t),hsl2rgb:({h:t,s:e,l:i},r)=>{if(!e)return i*2.55;t/=360,e/=100,i/=100;const n=i<.5?i*(1+e):i+e-i*e,o=2*i-n;switch(r){case"r":return Di.hue2rgb(o,n,t+1/3)*255;case"g":return Di.hue2rgb(o,n,t)*255;case"b":return Di.hue2rgb(o,n,t-1/3)*255}},rgb2hsl:({r:t,g:e,b:i},r)=>{t/=255,e/=255,i/=255;const n=Math.max(t,e,i),o=Math.min(t,e,i),s=(n+o)/2;if(r==="l")return s*100;if(n===o)return 0;const a=n-o,l=s>.5?a/(2-n-o):a/(n+o);if(r==="s")return l*100;switch(n){case t:return((e-i)/a+(ee>i?Math.min(e,Math.max(i,t)):Math.min(i,Math.max(e,t)),round:t=>Math.round(t*1e10)/1e10},Pd={dec2hex:t=>{const e=Math.round(t).toString(16);return e.length>1?e:`0${e}`}},L={channel:Di,lang:Rd,unit:Pd},qt={};for(let t=0;t<=255;t++)qt[t]=L.unit.dec2hex(t);const K={ALL:0,RGB:1,HSL:2};class $d{constructor(){this.type=K.ALL}get(){return this.type}set(e){if(this.type&&this.type!==e)throw new Error("Cannot change both RGB and HSL channels at the same time");this.type=e}reset(){this.type=K.ALL}is(e){return this.type===e}}class qd{constructor(e,i){this.color=i,this.changed=!1,this.data=e,this.type=new $d}set(e,i){return this.color=i,this.changed=!1,this.data=e,this.type.type=K.ALL,this}_ensureHSL(){const e=this.data,{h:i,s:r,l:n}=e;i===void 0&&(e.h=L.channel.rgb2hsl(e,"h")),r===void 0&&(e.s=L.channel.rgb2hsl(e,"s")),n===void 0&&(e.l=L.channel.rgb2hsl(e,"l"))}_ensureRGB(){const e=this.data,{r:i,g:r,b:n}=e;i===void 0&&(e.r=L.channel.hsl2rgb(e,"r")),r===void 0&&(e.g=L.channel.hsl2rgb(e,"g")),n===void 0&&(e.b=L.channel.hsl2rgb(e,"b"))}get r(){const e=this.data,i=e.r;return!this.type.is(K.HSL)&&i!==void 0?i:(this._ensureHSL(),L.channel.hsl2rgb(e,"r"))}get g(){const e=this.data,i=e.g;return!this.type.is(K.HSL)&&i!==void 0?i:(this._ensureHSL(),L.channel.hsl2rgb(e,"g"))}get b(){const e=this.data,i=e.b;return!this.type.is(K.HSL)&&i!==void 0?i:(this._ensureHSL(),L.channel.hsl2rgb(e,"b"))}get h(){const e=this.data,i=e.h;return!this.type.is(K.RGB)&&i!==void 0?i:(this._ensureRGB(),L.channel.rgb2hsl(e,"h"))}get s(){const e=this.data,i=e.s;return!this.type.is(K.RGB)&&i!==void 0?i:(this._ensureRGB(),L.channel.rgb2hsl(e,"s"))}get l(){const e=this.data,i=e.l;return!this.type.is(K.RGB)&&i!==void 0?i:(this._ensureRGB(),L.channel.rgb2hsl(e,"l"))}get a(){return this.data.a}set r(e){this.type.set(K.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(K.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(K.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(K.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(K.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(K.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}const dr=new qd({r:0,g:0,b:0,a:0},"transparent"),Ce={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:t=>{if(t.charCodeAt(0)!==35)return;const e=t.match(Ce.re);if(!e)return;const i=e[1],r=parseInt(i,16),n=i.length,o=n%4===0,s=n>4,a=s?1:17,l=s?8:4,h=o?0:-1,u=s?255:15;return dr.set({r:(r>>l*(h+3)&u)*a,g:(r>>l*(h+2)&u)*a,b:(r>>l*(h+1)&u)*a,a:o?(r&u)*a/255:1},t)},stringify:t=>{const{r:e,g:i,b:r,a:n}=t;return n<1?`#${qt[Math.round(e)]}${qt[Math.round(i)]}${qt[Math.round(r)]}${qt[Math.round(n*255)]}`:`#${qt[Math.round(e)]}${qt[Math.round(i)]}${qt[Math.round(r)]}`}},Zt={re:/^hsla?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(?:deg|grad|rad|turn)?)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?%)(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e-?\d+)?(%)?))?\s*?\)$/i,hueRe:/^(.+?)(deg|grad|rad|turn)$/i,_hue2deg:t=>{const e=t.match(Zt.hueRe);if(e){const[,i,r]=e;switch(r){case"grad":return L.channel.clamp.h(parseFloat(i)*.9);case"rad":return L.channel.clamp.h(parseFloat(i)*180/Math.PI);case"turn":return L.channel.clamp.h(parseFloat(i)*360)}}return L.channel.clamp.h(parseFloat(t))},parse:t=>{const e=t.charCodeAt(0);if(e!==104&&e!==72)return;const i=t.match(Zt.re);if(!i)return;const[,r,n,o,s,a]=i;return dr.set({h:Zt._hue2deg(r),s:L.channel.clamp.s(parseFloat(n)),l:L.channel.clamp.l(parseFloat(o)),a:s?L.channel.clamp.a(a?parseFloat(s)/100:parseFloat(s)):1},t)},stringify:t=>{const{h:e,s:i,l:r,a:n}=t;return n<1?`hsla(${L.lang.round(e)}, ${L.lang.round(i)}%, ${L.lang.round(r)}%, ${n})`:`hsl(${L.lang.round(e)}, ${L.lang.round(i)}%, ${L.lang.round(r)}%)`}},Ke={colors:{aliceblue:"#f0f8ff",antiquewhite:"#faebd7",aqua:"#00ffff",aquamarine:"#7fffd4",azure:"#f0ffff",beige:"#f5f5dc",bisque:"#ffe4c4",black:"#000000",blanchedalmond:"#ffebcd",blue:"#0000ff",blueviolet:"#8a2be2",brown:"#a52a2a",burlywood:"#deb887",cadetblue:"#5f9ea0",chartreuse:"#7fff00",chocolate:"#d2691e",coral:"#ff7f50",cornflowerblue:"#6495ed",cornsilk:"#fff8dc",crimson:"#dc143c",cyanaqua:"#00ffff",darkblue:"#00008b",darkcyan:"#008b8b",darkgoldenrod:"#b8860b",darkgray:"#a9a9a9",darkgreen:"#006400",darkgrey:"#a9a9a9",darkkhaki:"#bdb76b",darkmagenta:"#8b008b",darkolivegreen:"#556b2f",darkorange:"#ff8c00",darkorchid:"#9932cc",darkred:"#8b0000",darksalmon:"#e9967a",darkseagreen:"#8fbc8f",darkslateblue:"#483d8b",darkslategray:"#2f4f4f",darkslategrey:"#2f4f4f",darkturquoise:"#00ced1",darkviolet:"#9400d3",deeppink:"#ff1493",deepskyblue:"#00bfff",dimgray:"#696969",dimgrey:"#696969",dodgerblue:"#1e90ff",firebrick:"#b22222",floralwhite:"#fffaf0",forestgreen:"#228b22",fuchsia:"#ff00ff",gainsboro:"#dcdcdc",ghostwhite:"#f8f8ff",gold:"#ffd700",goldenrod:"#daa520",gray:"#808080",green:"#008000",greenyellow:"#adff2f",grey:"#808080",honeydew:"#f0fff0",hotpink:"#ff69b4",indianred:"#cd5c5c",indigo:"#4b0082",ivory:"#fffff0",khaki:"#f0e68c",lavender:"#e6e6fa",lavenderblush:"#fff0f5",lawngreen:"#7cfc00",lemonchiffon:"#fffacd",lightblue:"#add8e6",lightcoral:"#f08080",lightcyan:"#e0ffff",lightgoldenrodyellow:"#fafad2",lightgray:"#d3d3d3",lightgreen:"#90ee90",lightgrey:"#d3d3d3",lightpink:"#ffb6c1",lightsalmon:"#ffa07a",lightseagreen:"#20b2aa",lightskyblue:"#87cefa",lightslategray:"#778899",lightslategrey:"#778899",lightsteelblue:"#b0c4de",lightyellow:"#ffffe0",lime:"#00ff00",limegreen:"#32cd32",linen:"#faf0e6",magenta:"#ff00ff",maroon:"#800000",mediumaquamarine:"#66cdaa",mediumblue:"#0000cd",mediumorchid:"#ba55d3",mediumpurple:"#9370db",mediumseagreen:"#3cb371",mediumslateblue:"#7b68ee",mediumspringgreen:"#00fa9a",mediumturquoise:"#48d1cc",mediumvioletred:"#c71585",midnightblue:"#191970",mintcream:"#f5fffa",mistyrose:"#ffe4e1",moccasin:"#ffe4b5",navajowhite:"#ffdead",navy:"#000080",oldlace:"#fdf5e6",olive:"#808000",olivedrab:"#6b8e23",orange:"#ffa500",orangered:"#ff4500",orchid:"#da70d6",palegoldenrod:"#eee8aa",palegreen:"#98fb98",paleturquoise:"#afeeee",palevioletred:"#db7093",papayawhip:"#ffefd5",peachpuff:"#ffdab9",peru:"#cd853f",pink:"#ffc0cb",plum:"#dda0dd",powderblue:"#b0e0e6",purple:"#800080",rebeccapurple:"#663399",red:"#ff0000",rosybrown:"#bc8f8f",royalblue:"#4169e1",saddlebrown:"#8b4513",salmon:"#fa8072",sandybrown:"#f4a460",seagreen:"#2e8b57",seashell:"#fff5ee",sienna:"#a0522d",silver:"#c0c0c0",skyblue:"#87ceeb",slateblue:"#6a5acd",slategray:"#708090",slategrey:"#708090",snow:"#fffafa",springgreen:"#00ff7f",tan:"#d2b48c",teal:"#008080",thistle:"#d8bfd8",transparent:"#00000000",turquoise:"#40e0d0",violet:"#ee82ee",wheat:"#f5deb3",white:"#ffffff",whitesmoke:"#f5f5f5",yellow:"#ffff00",yellowgreen:"#9acd32"},parse:t=>{t=t.toLowerCase();const e=Ke.colors[t];if(e)return Ce.parse(e)},stringify:t=>{const e=Ce.stringify(t);for(const i in Ke.colors)if(Ke.colors[i]===e)return i}},Xe={re:/^rgba?\(\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))\s*?(?:,|\s)\s*?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?))(?:\s*?(?:,|\/)\s*?\+?(-?(?:\d+(?:\.\d+)?|(?:\.\d+))(?:e\d+)?(%?)))?\s*?\)$/i,parse:t=>{const e=t.charCodeAt(0);if(e!==114&&e!==82)return;const i=t.match(Xe.re);if(!i)return;const[,r,n,o,s,a,l,h,u]=i;return dr.set({r:L.channel.clamp.r(n?parseFloat(r)*2.55:parseFloat(r)),g:L.channel.clamp.g(s?parseFloat(o)*2.55:parseFloat(o)),b:L.channel.clamp.b(l?parseFloat(a)*2.55:parseFloat(a)),a:h?L.channel.clamp.a(u?parseFloat(h)/100:parseFloat(h)):1},t)},stringify:t=>{const{r:e,g:i,b:r,a:n}=t;return n<1?`rgba(${L.lang.round(e)}, ${L.lang.round(i)}, ${L.lang.round(r)}, ${L.lang.round(n)})`:`rgb(${L.lang.round(e)}, ${L.lang.round(i)}, ${L.lang.round(r)})`}},St={format:{keyword:Ke,hex:Ce,rgb:Xe,rgba:Xe,hsl:Zt,hsla:Zt},parse:t=>{if(typeof t!="string")return t;const e=Ce.parse(t)||Xe.parse(t)||Zt.parse(t)||Ke.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},stringify:t=>!t.changed&&t.color?t.color:t.type.is(K.HSL)||t.data.r===void 0?Zt.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?Xe.stringify(t):Ce.stringify(t)},za=(t,e)=>{const i=St.parse(t);for(const r in e)i[r]=L.channel.clamp[r](e[r]);return St.stringify(i)},Ze=(t,e,i=0,r=1)=>{if(typeof t!="number")return za(t,{a:e});const n=dr.set({r:L.channel.clamp.r(t),g:L.channel.clamp.g(e),b:L.channel.clamp.b(i),a:L.channel.clamp.a(r)});return St.stringify(n)},zd=t=>{const{r:e,g:i,b:r}=St.parse(t),n=.2126*L.channel.toLinear(e)+.7152*L.channel.toLinear(i)+.0722*L.channel.toLinear(r);return L.lang.round(n)},Wd=t=>zd(t)>=.5,fi=t=>!Wd(t),Wa=(t,e,i)=>{const r=St.parse(t),n=r[e],o=L.channel.clamp[e](n+i);return n!==o&&(r[e]=o),St.stringify(r)},k=(t,e)=>Wa(t,"l",e),A=(t,e)=>Wa(t,"l",-e),p=(t,e)=>{const i=St.parse(t),r={};for(const n in e)e[n]&&(r[n]=i[n]+e[n]);return za(t,r)},jd=(t,e,i=50)=>{const{r,g:n,b:o,a:s}=St.parse(t),{r:a,g:l,b:h,a:u}=St.parse(e),d=i/100,c=d*2-1,g=s-u,C=((c*g===-1?c:(c+g)/(1+c*g))+1)/2,v=1-C,O=r*C+a*v,x=n*C+l*v,R=o*C+h*v,F=s*d+u*(1-d);return Ze(O,x,R,F)},_=(t,e=100)=>{const i=St.parse(t);return i.r=255-i.r,i.g=255-i.g,i.b=255-i.b,jd(i,t,e)};var ja=typeof global=="object"&&global&&global.Object===Object&&global,Hd=typeof self=="object"&&self&&self.Object===Object&&self,At=ja||Hd||Function("return this")(),Xi=At.Symbol,Ha=Object.prototype,Ud=Ha.hasOwnProperty,Yd=Ha.toString,Ue=Xi?Xi.toStringTag:void 0;function Gd(t){var e=Ud.call(t,Ue),i=t[Ue];try{t[Ue]=void 0;var r=!0}catch{}var n=Yd.call(t);return r&&(e?t[Ue]=i:delete t[Ue]),n}var Vd=Object.prototype,Xd=Vd.toString;function Kd(t){return Xd.call(t)}var Zd="[object Null]",Jd="[object Undefined]",us=Xi?Xi.toStringTag:void 0;function Ee(t){return t==null?t===void 0?Jd:Zd:us&&us in Object(t)?Gd(t):Kd(t)}function re(t){var e=typeof t;return t!=null&&(e=="object"||e=="function")}var Qd="[object AsyncFunction]",tp="[object Function]",ep="[object GeneratorFunction]",ip="[object Proxy]";function qn(t){if(!re(t))return!1;var e=Ee(t);return e==tp||e==ep||e==Qd||e==ip}var Zr=At["__core-js_shared__"],fs=function(){var t=/[^.]+$/.exec(Zr&&Zr.keys&&Zr.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function rp(t){return!!fs&&fs in t}var np=Function.prototype,op=np.toString;function ne(t){if(t!=null){try{return op.call(t)}catch{}try{return t+""}catch{}}return""}var sp=/[\\^$.*+?()[\]{}|]/g,ap=/^\[object .+?Constructor\]$/,lp=Function.prototype,hp=Object.prototype,cp=lp.toString,up=hp.hasOwnProperty,fp=RegExp("^"+cp.call(up).replace(sp,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function dp(t){if(!re(t)||rp(t))return!1;var e=qn(t)?fp:ap;return e.test(ne(t))}function pp(t,e){return t==null?void 0:t[e]}function oe(t,e){var i=pp(t,e);return dp(i)?i:void 0}var si=oe(Object,"create");function gp(){this.__data__=si?si(null):{},this.size=0}function mp(t){var e=this.has(t)&&delete this.__data__[t];return this.size-=e?1:0,e}var _p="__lodash_hash_undefined__",yp=Object.prototype,Cp=yp.hasOwnProperty;function xp(t){var e=this.__data__;if(si){var i=e[t];return i===_p?void 0:i}return Cp.call(e,t)?e[t]:void 0}var bp=Object.prototype,Tp=bp.hasOwnProperty;function vp(t){var e=this.__data__;return si?e[t]!==void 0:Tp.call(e,t)}var kp="__lodash_hash_undefined__";function Sp(t,e){var i=this.__data__;return this.size+=this.has(t)?0:1,i[t]=si&&e===void 0?kp:e,this}function ee(t){var e=-1,i=t==null?0:t.length;for(this.clear();++e-1}function Op(t,e){var i=this.__data__,r=gr(i,t);return r<0?(++this.size,i.push([t,e])):i[r][1]=e,this}function $t(t){var e=-1,i=t==null?0:t.length;for(this.clear();++e-1&&t%1==0&&t<=og}function yr(t){return t!=null&&Xa(t.length)&&!qn(t)}function sg(t){return pi(t)&&yr(t)}function ag(){return!1}var Ka=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Cs=Ka&&typeof module=="object"&&module&&!module.nodeType&&module,lg=Cs&&Cs.exports===Ka,xs=lg?At.Buffer:void 0,hg=xs?xs.isBuffer:void 0,Wn=hg||ag,cg="[object Object]",ug=Function.prototype,fg=Object.prototype,Za=ug.toString,dg=fg.hasOwnProperty,pg=Za.call(Object);function gg(t){if(!pi(t)||Ee(t)!=cg)return!1;var e=Ga(t);if(e===null)return!0;var i=dg.call(e,"constructor")&&e.constructor;return typeof i=="function"&&i instanceof i&&Za.call(i)==pg}var mg="[object Arguments]",_g="[object Array]",yg="[object Boolean]",Cg="[object Date]",xg="[object Error]",bg="[object Function]",Tg="[object Map]",vg="[object Number]",kg="[object Object]",Sg="[object RegExp]",wg="[object Set]",Bg="[object String]",Ag="[object WeakMap]",Lg="[object ArrayBuffer]",Fg="[object DataView]",Eg="[object Float32Array]",Og="[object Float64Array]",Mg="[object Int8Array]",Ig="[object Int16Array]",Dg="[object Int32Array]",Ng="[object Uint8Array]",Rg="[object Uint8ClampedArray]",Pg="[object Uint16Array]",$g="[object Uint32Array]",I={};I[Eg]=I[Og]=I[Mg]=I[Ig]=I[Dg]=I[Ng]=I[Rg]=I[Pg]=I[$g]=!0;I[mg]=I[_g]=I[Lg]=I[yg]=I[Fg]=I[Cg]=I[xg]=I[bg]=I[Tg]=I[vg]=I[kg]=I[Sg]=I[wg]=I[Bg]=I[Ag]=!1;function qg(t){return pi(t)&&Xa(t.length)&&!!I[Ee(t)]}function zg(t){return function(e){return t(e)}}var Ja=typeof exports=="object"&&exports&&!exports.nodeType&&exports,Je=Ja&&typeof module=="object"&&module&&!module.nodeType&&module,Wg=Je&&Je.exports===Ja,Jr=Wg&&ja.process,bs=function(){try{var t=Je&&Je.require&&Je.require("util").types;return t||Jr&&Jr.binding&&Jr.binding("util")}catch{}}(),Ts=bs&&bs.isTypedArray,jn=Ts?zg(Ts):qg;function _n(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}var jg=Object.prototype,Hg=jg.hasOwnProperty;function Ug(t,e,i){var r=t[e];(!(Hg.call(t,e)&&pr(r,i))||i===void 0&&!(e in t))&&zn(t,e,i)}function Yg(t,e,i,r){var n=!i;i||(i={});for(var o=-1,s=e.length;++o-1&&t%1==0&&t0){if(++e>=hm)return arguments[0]}else e=0;return t.apply(void 0,arguments)}}var dm=fm(lm);function pm(t,e){return dm(sm(t,e,il),t+"")}function gm(t,e,i){if(!re(i))return!1;var r=typeof e;return(r=="number"?yr(i)&&Qa(e,i.length):r=="string"&&e in i)?pr(i[e],t):!1}function mm(t){return pm(function(e,i){var r=-1,n=i.length,o=n>1?i[n-1]:void 0,s=n>2?i[2]:void 0;for(o=t.length>3&&typeof o=="function"?(n--,o):void 0,s&&gm(i[0],i[1],s)&&(o=n<3?void 0:o,n=1),e=Object(e);++r0?xe(Me,--ft):0,Se--,z===10&&(Se=1,Cr--),z}function _t(){return z=ft2||li(z)>3?"":" "}function Lm(t,e){for(;--e&&_t()&&!(z<48||z>102||z>57&&z<65||z>70&&z<97););return xr(t,Ri()+(e<6&&Wt()==32&&_t()==32))}function yn(t){for(;_t();)switch(z){case t:return ft;case 34:case 39:t!==34&&t!==39&&yn(z);break;case 40:t===41&&yn(t);break;case 92:_t();break}return ft}function Fm(t,e){for(;_t()&&t+z!==57;)if(t+z===84&&Wt()===47)break;return"/*"+xr(e,ft-1)+"*"+Hn(t===47?t:_t())}function Em(t){for(;!li(Wt());)_t();return xr(t,ft)}function Om(t){return Bm(Pi("",null,null,null,[""],t=wm(t),0,[0],t))}function Pi(t,e,i,r,n,o,s,a,l){for(var h=0,u=0,d=s,c=0,g=0,y=0,C=1,v=1,O=1,x=0,R="",F=n,P=o,V=r,M=R;v;)switch(y=x,x=_t()){case 40:if(y!=108&&xe(M,d-1)==58){Tm(M+=Ni(Qr(x),"&","&\f"),"&\f",sl(h?a[h-1]:0))!=-1&&(O=-1);break}case 34:case 39:case 91:M+=Qr(x);break;case 9:case 10:case 13:case 32:M+=Am(y);break;case 92:M+=Lm(Ri()-1,7);continue;case 47:switch(Wt()){case 42:case 47:Li(Mm(Fm(_t(),Ri()),e,i,l),l),(li(y||1)==5||li(Wt()||1)==5)&&Tt(M)&&ke(M,-1,void 0)!==" "&&(M+=" ");break;default:M+="/"}break;case 123*C:a[h++]=Tt(M)*O;case 125*C:case 59:case 0:switch(x){case 0:case 125:v=0;case 59+u:O==-1&&(M=Ni(M,/\f/g,"")),g>0&&(Tt(M)-d||C===0&&y===47)&&Li(g>32?Ss(M+";",r,i,d-1,l):Ss(Ni(M," ","")+";",r,i,d-2,l),l);break;case 59:M+=";";default:if(Li(V=ks(M,e,i,h,u,n,a,R,F=[],P=[],d,o),o),x===123)if(u===0)Pi(M,e,V,V,F,o,d,a,P);else{switch(c){case 99:if(xe(M,3)===110)break;case 108:if(xe(M,2)===97)break;default:u=0;case 100:case 109:case 115:}u?Pi(t,V,V,r&&Li(ks(t,V,V,0,0,n,a,R,n,F=[],d,P),P),n,P,d,a,r?F:P):Pi(M,V,V,V,[""],P,0,a,P)}}h=u=g=0,C=O=1,R=M="",d=s;break;case 58:d=1+Tt(M),g=y;default:if(C<1){if(x==123)--C;else if(x==125&&C++==0&&Sm()==125)continue}switch(M+=Hn(x),x*C){case 38:O=u>0?1:(M+="\f",-1);break;case 44:a[h++]=(Tt(M)-1)*O,O=1;break;case 64:Wt()===45&&(M+=Qr(_t())),c=Wt(),u=d=Tt(R=M+=Em(Ri())),x++;break;case 45:y===45&&Tt(M)==2&&(C=0)}}return o}function ks(t,e,i,r,n,o,s,a,l,h,u,d){for(var c=n-1,g=n===0?o:[""],y=vm(g),C=0,v=0,O=0;C0?g[x]+" "+R:Ni(R,/&\f/g,g[x])))&&(l[O++]=F);return Un(t,e,i,n===0?nl:a,l,h,u,d)}function Mm(t,e,i,r){return Un(t,e,i,rl,Hn(km()),ke(t,2,-2),0,r)}function Ss(t,e,i,r,n){return Un(t,e,i,ol,ke(t,0,r),ke(t,r+1,-1),r,n)}function Cn(t,e){for(var i="",r=0;r{},debug:(...t)=>{},info:(...t)=>{},warn:(...t)=>{},error:(...t)=>{},fatal:(...t)=>{}},Yn=function(t="fatal"){let e=It.fatal;typeof t=="string"?(t=t.toLowerCase(),t in It&&(e=It[t])):typeof t=="number"&&(e=t),B.trace=()=>{},B.debug=()=>{},B.info=()=>{},B.warn=()=>{},B.error=()=>{},B.fatal=()=>{},e<=It.fatal&&(B.fatal=console.error?console.error.bind(console,ht("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",ht("FATAL"))),e<=It.error&&(B.error=console.error?console.error.bind(console,ht("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",ht("ERROR"))),e<=It.warn&&(B.warn=console.warn?console.warn.bind(console,ht("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",ht("WARN"))),e<=It.info&&(B.info=console.info?console.info.bind(console,ht("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",ht("INFO"))),e<=It.debug&&(B.debug=console.debug?console.debug.bind(console,ht("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ht("DEBUG"))),e<=It.trace&&(B.trace=console.debug?console.debug.bind(console,ht("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ht("TRACE")))},ht=t=>`%c${Lh().format("ss.SSS")} : ${t} : `,gi=//gi,Xm=t=>t?cl(t).replace(/\\n/g,"#br#").split("#br#"):[""],Km=(()=>{let t=!1;return()=>{t||(Zm(),t=!0)}})();function Zm(){const t="data-temp-href-target";ve.addHook("beforeSanitizeAttributes",e=>{e.tagName==="A"&&e.hasAttribute("target")&&e.setAttribute(t,e.getAttribute("target")??"")}),ve.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"))})}const hl=t=>(Km(),ve.sanitize(t)),Es=(t,e)=>{var i;if(((i=e.flowchart)==null?void 0:i.htmlLabels)!==!1){const r=e.securityLevel;r==="antiscript"||r==="strict"?t=hl(t):r!=="loose"&&(t=cl(t),t=t.replace(//g,">"),t=t.replace(/=/g,"="),t=e0(t))}return t},we=(t,e)=>t&&(e.dompurifyConfig?t=ve.sanitize(Es(t,e),e.dompurifyConfig).toString():t=ve.sanitize(Es(t,e),{FORBID_TAGS:["style"]}).toString(),t),Jm=(t,e)=>typeof t=="string"?we(t,e):t.flat().map(i=>we(i,e)),Qm=t=>gi.test(t),t0=t=>t.split(gi),e0=t=>t.replace(/#br#/g,"
"),cl=t=>t.replace(gi,"#br#"),i0=t=>{let e="";return t&&(e=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,e=e.replaceAll(/\(/g,"\\("),e=e.replaceAll(/\)/g,"\\)")),e},ul=t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),r0=function(...t){const e=t.filter(i=>!isNaN(i));return Math.max(...e)},n0=function(...t){const e=t.filter(i=>!isNaN(i));return Math.min(...e)},r1=function(t){const e=t.split(/(,)/),i=[];for(let r=0;r0&&r+1Math.max(0,t.split(e).length-1),o0=(t,e)=>{const i=kn(t,"~"),r=kn(e,"~");return i===1&&r===1},s0=t=>{const e=kn(t,"~");let i=!1;if(e<=1)return t;e%2!==0&&t.startsWith("~")&&(t=t.substring(1),i=!0);const r=[...t];let n=r.indexOf("~"),o=r.lastIndexOf("~");for(;n!==-1&&o!==-1&&n!==o;)r[n]="<",r[o]=">",n=r.indexOf("~"),o=r.lastIndexOf("~");return i&&r.unshift("~"),r.join("")},Os=()=>window.MathMLElement!==void 0,Sn=/\$\$(.*)\$\$/g,Ms=t=>{var e;return(((e=t.match(Sn))==null?void 0:e.length)??0)>0},n1=async(t,e)=>{const i=document.createElement("div");i.innerHTML=await l0(t,e),i.id="katex-temp",i.style.visibility="hidden",i.style.position="absolute",i.style.top="0";const r=document.querySelector("body");r==null||r.insertAdjacentElement("beforeend",i);const n={width:i.clientWidth,height:i.clientHeight};return i.remove(),n},a0=async(t,e)=>{if(!Ms(t))return t;if(!Os()&&!e.legacyMathML)return t.replace(Sn,"MathML is unsupported in this environment.");const{default:i}=await N(async()=>{const{default:r}=await import("./katex-BlHpptmG.js");return{default:r}},[],import.meta.url);return t.split(gi).map(r=>Ms(r)?`
${r}
`:`
${r}
`).join("").replace(Sn,(r,n)=>i.renderToString(n,{throwOnError:!0,displayMode:!0,output:Os()?"mathml":"htmlAndMathml"}).replace(/\n/g," ").replace(//g,""))},l0=async(t,e)=>we(await a0(t,e),e),Gn={getRows:Xm,sanitizeText:we,sanitizeTextOrArray:Jm,hasBreaks:Qm,splitBreaks:t0,lineBreakRegex:gi,removeScript:hl,getUrl:i0,evaluate:ul,getMax:r0,getMin:n0},et=(t,e)=>e?p(t,{s:-40,l:10}):p(t,{s:-40,l:-10}),br="#ffffff",Tr="#f2f2f2";let h0=class{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(){var e,i,r,n,o,s,a,l,h,u,d;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||p(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||p(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||et(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||et(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||et(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||et(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||_(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||_(this.tertiaryColor),this.lineColor=this.lineColor||_(this.background),this.arrowheadColor=this.arrowheadColor||_(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?A(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||"grey",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||A(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||_(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||k(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.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.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||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.darkMode)for(let g=0;g{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const c0=t=>{const e=new h0;return e.calculate(t),e};let u0=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=k(this.primaryColor,16),this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=_(this.background),this.secondaryBorderColor=et(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=et(this.tertiaryColor,this.darkMode),this.primaryTextColor=_(this.primaryColor),this.secondaryTextColor=_(this.secondaryColor),this.tertiaryTextColor=_(this.tertiaryColor),this.lineColor=_(this.background),this.textColor=_(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=k(_("#323D47"),10),this.lineColor="calculated",this.border1="#81B1DB",this.border2=Ze(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=A("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=A(this.sectionBkgColor,10),this.taskBorderColor=Ze(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=Ze(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.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){var e,i,r,n,o,s,a,l,h,u,d;this.secondBkg=k(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=k(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.mainContrastColor,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=k(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.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=p(this.primaryColor,{h:64}),this.fillType3=p(this.secondaryColor,{h:64}),this.fillType4=p(this.primaryColor,{h:-64}),this.fillType5=p(this.secondaryColor,{h:-64}),this.fillType6=p(this.primaryColor,{h:128}),this.fillType7=p(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||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330});for(let c=0;c{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const f0=t=>{const e=new u0;return e.calculate(t),e};let d0=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=p(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=et(this.primaryColor,this.darkMode),this.secondaryBorderColor=et(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=et(this.tertiaryColor,this.darkMode),this.primaryTextColor=_(this.primaryColor),this.secondaryTextColor=_(this.secondaryColor),this.tertiaryTextColor=_(this.tertiaryColor),this.lineColor=_(this.background),this.textColor=_(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="#e8e8e8",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="grey",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.sectionBkgColor=Ze(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.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){var e,i,r,n,o,s,a,l,h,u,d;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||A(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||A(this.tertiaryColor,40);for(let c=0;c{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const p0=t=>{const e=new d0;return e.calculate(t),e};let g0=class{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=k("#cde498",10),this.primaryBorderColor=et(this.primaryColor,this.darkMode),this.secondaryBorderColor=et(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=et(this.tertiaryColor,this.darkMode),this.primaryTextColor=_(this.primaryColor),this.secondaryTextColor=_(this.secondaryColor),this.tertiaryTextColor=_(this.primaryColor),this.lineColor=_(this.background),this.textColor=_(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="grey",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.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,i,r,n,o,s,a,l,h,u,d;this.actorBorder=A(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.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||A(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||A(this.tertiaryColor,40);for(let c=0;c{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const m0=t=>{const e=new g0;return e.calculate(t),e};class _0{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=k(this.contrast,55),this.background="#ffffff",this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=et(this.primaryColor,this.darkMode),this.secondaryBorderColor=et(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=et(this.tertiaryColor,this.darkMode),this.primaryTextColor=_(this.primaryColor),this.secondaryTextColor=_(this.secondaryColor),this.tertiaryTextColor=_(this.tertiaryColor),this.lineColor=_(this.background),this.textColor=_(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="calculated",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.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,i,r,n,o,s,a,l,h,u,d;this.secondBkg=k(this.contrast,55),this.border2=this.contrast,this.actorBorder=k(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.lineColor,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 c=0;c{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}}const y0=t=>{const e=new _0;return e.calculate(t),e},Rt={base:{getThemeVariables:c0},dark:{getThemeVariables:f0},default:{getThemeVariables:p0},forest:{getThemeVariables:m0},neutral:{getThemeVariables:y0}},Dt={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},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,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"]},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!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,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,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},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},theme:"default",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","maxEdges"],legacyMathML:!1,deterministicIds:!1,fontSize:16},fl={...Dt,deterministicIDSeed:void 0,themeCSS:void 0,themeVariables:Rt.default.getThemeVariables(),sequence:{...Dt.sequence,messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},noteFont:function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},actorFont:function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}}},gantt:{...Dt.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Dt.c4,useWidth:void 0,personFont:function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},external_personFont:function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},systemFont:function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},external_systemFont:function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},system_dbFont:function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},external_system_dbFont:function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},system_queueFont:function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},external_system_queueFont:function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},containerFont:function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},external_containerFont:function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},container_dbFont:function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},external_container_dbFont:function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},container_queueFont:function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},external_container_queueFont:function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},componentFont:function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},external_componentFont:function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},component_dbFont:function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},external_component_dbFont:function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},component_queueFont:function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},external_component_queueFont:function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},boundaryFont:function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},messageFont:function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}}},pie:{...Dt.pie,useWidth:984},xyChart:{...Dt.xyChart,useWidth:void 0},requirement:{...Dt.requirement,useWidth:void 0},gitGraph:{...Dt.gitGraph,useMaxWidth:!1},sankey:{...Dt.sankey,useMaxWidth:!1}},dl=(t,e="")=>Object.keys(t).reduce((i,r)=>Array.isArray(t[r])?i:typeof t[r]=="object"&&t[r]!==null?[...i,e+r,...dl(t[r],"")]:[...i,e+r],[]),C0=new Set(dl(fl,"")),x0=fl,Qi=t=>{if(B.debug("sanitizeDirective called with",t),!(typeof t!="object"||t==null)){if(Array.isArray(t)){t.forEach(e=>Qi(e));return}for(const e of Object.keys(t)){if(B.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!C0.has(e)||t[e]==null){B.debug("sanitize deleting key: ",e),delete t[e];continue}if(typeof t[e]=="object"){B.debug("sanitizing object",e),Qi(t[e]);continue}const i=["themeCSS","fontFamily","altFontFamily"];for(const r of i)e.includes(r)&&(B.debug("sanitizing css option",e),t[e]=b0(t[e]))}if(t.themeVariables)for(const e of Object.keys(t.themeVariables)){const i=t.themeVariables[e];i!=null&&i.match&&!i.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}B.debug("After sanitization",t)}},b0=t=>{let e=0,i=0;for(const r of t){if(e{for(const{id:e,detector:i,loader:r}of t)_l(e,i,r)},_l=(t,e,i)=>{Be[t]?B.error(`Detector with key ${t} already exists`):Be[t]={detector:e,loader:i},B.debug(`Detector with key ${t} added${i?" with loader":""}`)},v0=t=>Be[t].loader,wn=(t,e,{depth:i=2,clobber:r=!1}={})=>{const n={depth:i,clobber:r};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach(o=>wn(t,o,n)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(o=>{t.includes(o)||t.push(o)}),t):t===void 0||i<=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(o=>{typeof e[o]=="object"&&(t[o]===void 0||typeof t[o]=="object")?(t[o]===void 0&&(t[o]=Array.isArray(e[o])?[]:{}),t[o]=wn(t[o],e[o],{depth:i-1,clobber:r})):(r||typeof t[o]!="object"&&typeof e[o]!="object")&&(t[o]=e[o])}),t)},Z=wn,k0="​",S0={curveBasis:Qf,curveBasisClosed:td,curveBasisOpen:ed,curveBumpX:Zf,curveBumpY:Jf,curveBundle:id,curveCardinalClosed:nd,curveCardinalOpen:od,curveCardinal:rd,curveCatmullRomClosed:ad,curveCatmullRomOpen:ld,curveCatmullRom:sd,curveLinear:Kf,curveLinearClosed:hd,curveMonotoneX:cd,curveMonotoneY:ud,curveNatural:fd,curveStep:dd,curveStepAfter:gd,curveStepBefore:pd},w0=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,B0=function(t,e){const i=yl(t,/(?:init\b)|(?:initialize\b)/);let r={};if(Array.isArray(i)){const s=i.map(a=>a.args);Qi(s),r=Z(r,[...s])}else r=i.args;if(!r)return;let n=vr(t,e);const o="config";return r[o]!==void 0&&(n==="flowchart-v2"&&(n="flowchart"),r[n]=r[o],delete r[o]),r},yl=function(t,e=null){try{const i=new RegExp(`[%]{2}(?![{]${w0.source})(?=[}][%]{2}).* `,"ig");t=t.trim().replace(i,"").replace(/'/gm,'"'),B.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let r;const n=[];for(;(r=Qe.exec(t))!==null;)if(r.index===Qe.lastIndex&&Qe.lastIndex++,r&&!e||e&&r[1]&&r[1].match(e)||e&&r[2]&&r[2].match(e)){const o=r[1]?r[1]:r[2],s=r[3]?r[3].trim():r[4]?JSON.parse(r[4].trim()):null;n.push({type:o,args:s})}return n.length===0?{type:t,args:null}:n.length===1?n[0]:n}catch(i){return B.error(`ERROR: ${i.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},A0=function(t){return t.replace(Qe,"")},L0=function(t,e){for(const[i,r]of e.entries())if(r.match(t))return i;return-1};function F0(t,e){if(!t)return e;const i=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return S0[i]??e}function E0(t,e){const i=t.trim();if(i)return e.securityLevel!=="loose"?Ih.sanitizeUrl(i):i}const O0=(t,...e)=>{const i=t.split("."),r=i.length-1,n=i[r];let o=window;for(let s=0;s{i+=Cl(n,e),e=n});const r=i/2;return Vn(t,r)}function I0(t){return t.length===1?t[0]:M0(t)}const Is=(t,e=2)=>{const i=Math.pow(10,e);return Math.round(t*i)/i},Vn=(t,e)=>{let i,r=e;for(const n of t){if(i){const o=Cl(n,i);if(o=1)return{x:n.x,y:n.y};if(s>0&&s<1)return{x:Is((1-s)*i.x+s*n.x,5),y:Is((1-s)*i.y+s*n.y,5)}}}i=n}throw new Error("Could not find a suitable point for the given distance")},D0=(t,e,i)=>{B.info(`our points ${JSON.stringify(e)}`),e[0]!==i&&(e=e.reverse());const n=Vn(e,25),o=t?10:5,s=Math.atan2(e[0].y-n.y,e[0].x-n.x),a={x:0,y:0};return a.x=Math.sin(s)*o+(e[0].x+n.x)/2,a.y=-Math.cos(s)*o+(e[0].y+n.y)/2,a};function N0(t,e,i){const r=structuredClone(i);B.info("our points",r),e!=="start_left"&&e!=="start_right"&&r.reverse();const n=25+t,o=Vn(r,n),s=10+t*.5,a=Math.atan2(r[0].y-o.y,r[0].x-o.x),l={x:0,y:0};return e==="start_left"?(l.x=Math.sin(a+Math.PI)*s+(r[0].x+o.x)/2,l.y=-Math.cos(a+Math.PI)*s+(r[0].y+o.y)/2):e==="end_right"?(l.x=Math.sin(a-Math.PI)*s+(r[0].x+o.x)/2-5,l.y=-Math.cos(a-Math.PI)*s+(r[0].y+o.y)/2-5):e==="end_left"?(l.x=Math.sin(a)*s+(r[0].x+o.x)/2-5,l.y=-Math.cos(a)*s+(r[0].y+o.y)/2-5):(l.x=Math.sin(a)*s+(r[0].x+o.x)/2,l.y=-Math.cos(a)*s+(r[0].y+o.y)/2),l}function R0(t){let e="",i="";for(const r of t)r!==void 0&&(r.startsWith("color:")||r.startsWith("text-align:")?i=i+r+";":e=e+r+";");return{style:e,labelStyle:i}}let Ds=0;const P0=()=>(Ds++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Ds);function $0(t){let e="";const i="0123456789abcdef",r=i.length;for(let n=0;n$0(t.length),z0=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:""}},W0=function(t,e){const i=e.text.replace(Gn.lineBreakRegex," "),[,r]=Kn(e.fontSize),n=t.append("text");n.attr("x",e.x),n.attr("y",e.y),n.style("text-anchor",e.anchor),n.style("font-family",e.fontFamily),n.style("font-size",r),n.style("font-weight",e.fontWeight),n.attr("fill",e.fill),e.class!==void 0&&n.attr("class",e.class);const o=n.append("tspan");return o.attr("x",e.x+e.textMargin*2),o.attr("fill",e.fill),o.text(i),n},j0=di((t,e,i)=>{if(!t||(i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
"},i),Gn.lineBreakRegex.test(t)))return t;const r=t.split(" "),n=[];let o="";return r.forEach((s,a)=>{const l=tr(`${s} `,i),h=tr(o,i);if(l>e){const{hyphenatedStrings:c,remainingWord:g}=H0(s,e,"-",i);n.push(o,...c),o=g}else h+l>=e?(n.push(o),o=s):o=[o,s].filter(Boolean).join(" ");a+1===r.length&&n.push(o)}),n.filter(s=>s!=="").join(i.joinWith)},(t,e,i)=>`${t}${e}${i.fontSize}${i.fontWeight}${i.fontFamily}${i.joinWith}`),H0=di((t,e,i="-",r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},r);const n=[...t],o=[];let s="";return n.forEach((a,l)=>{const h=`${s}${a}`;if(tr(h,r)>=e){const d=l+1,c=n.length===d,g=`${h}${i}`;o.push(c?h:g),s=""}else s=h}),{hyphenatedStrings:o,remainingWord:s}},(t,e,i="-",r)=>`${t}${e}${i}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function U0(t,e){return Xn(t,e).height}function tr(t,e){return Xn(t,e).width}const Xn=di((t,e)=>{const{fontSize:i=12,fontFamily:r="Arial",fontWeight:n=400}=e;if(!t)return{width:0,height:0};const[,o]=Kn(i),s=["sans-serif",r],a=t.split(Gn.lineBreakRegex),l=[],h=ct("body");if(!h.remove)return{width:0,height:0,lineHeight:0};const u=h.append("svg");for(const c of s){let g=0;const y={width:0,height:0,lineHeight:0};for(const C of a){const v=z0();v.text=C||k0;const O=W0(u,v).style("font-size",o).style("font-weight",n).style("font-family",c),x=(O._groups||O)[0][0].getBBox();if(x.width===0&&x.height===0)throw new Error("svg element not in render tree");y.width=Math.round(Math.max(y.width,x.width)),g=Math.round(x.height),y.height+=g,y.lineHeight=Math.round(Math.max(y.lineHeight,g))}l.push(y)}u.remove();const d=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[d]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`);class Y0{constructor(e=!1,i){this.count=0,this.count=i?i.length:0,this.next=e?()=>this.count++:()=>Date.now()}}let Fi;const G0=function(t){return Fi=Fi||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),Fi.innerHTML=t,unescape(Fi.textContent)};function xl(t){return"str"in t}const V0=(t,e,i,r)=>{var n;if(!r)return;const o=(n=t.node())==null?void 0:n.getBBox();o&&t.append("text").text(r).attr("x",o.x+o.width/2).attr("y",-i).attr("class",e)},Kn=t=>{if(typeof t=="number")return[t,t+"px"];const e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]};function bl(t,e){return _m({},t,e)}const ti={assignWithDepth:Z,wrapLabel:j0,calculateTextHeight:U0,calculateTextWidth:tr,calculateTextDimensions:Xn,cleanAndMerge:bl,detectInit:B0,detectDirective:yl,isSubstringInArray:L0,interpolateToCurve:F0,calcLabelPosition:I0,calcCardinalityPosition:D0,calcTerminalLabelPosition:N0,formatUrl:E0,getStylesFromArray:R0,generateId:P0,random:q0,runFunc:O0,entityDecode:G0,insertTitle:V0,parseFontSize:Kn,InitIDGenerator:Y0},X0=function(t){let e=t;return e=e.replace(/style.*:\S*#.*;/g,function(i){return i.substring(0,i.length-1)}),e=e.replace(/classDef.*:\S*#.*;/g,function(i){return i.substring(0,i.length-1)}),e=e.replace(/#\w+;/g,function(i){const r=i.substring(1,i.length-1);return/^\+?\d+$/.test(r)?"fl°°"+r+"¶ß":"fl°"+r+"¶ß"}),e},K0=function(t){return t.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},Ns="10.9.5",Ae=Object.freeze(x0);let ot=Z({},Ae),Tl,Le=[],ei=Z({},Ae);const kr=(t,e)=>{let i=Z({},t),r={};for(const n of e)Sl(n),r=Z(r,n);if(i=Z(i,r),r.theme&&r.theme in Rt){const n=Z({},Tl),o=Z(n.themeVariables||{},r.themeVariables);i.theme&&i.theme in Rt&&(i.themeVariables=Rt[i.theme].getThemeVariables(o))}return ei=i,wl(ei),ei},Z0=t=>(ot=Z({},Ae),ot=Z(ot,t),t.theme&&Rt[t.theme]&&(ot.themeVariables=Rt[t.theme].getThemeVariables(t.themeVariables)),kr(ot,Le),ot),J0=t=>{Tl=Z({},t)},Q0=t=>(ot=Z(ot,t),kr(ot,Le),ot),vl=()=>Z({},ot),kl=t=>(wl(t),Z(ei,t),wt()),wt=()=>Z({},ei),Sl=t=>{t&&(["secure",...ot.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(B.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"&&Sl(t[e])}))},t_=t=>{Qi(t),t.fontFamily&&(!t.themeVariables||!t.themeVariables.fontFamily)&&(t.themeVariables={fontFamily:t.fontFamily}),Le.push(t),kr(ot,Le)},er=(t=ot)=>{Le=[],kr(t,Le)},e_={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},Rs={},i_=t=>{Rs[t]||(B.warn(e_[t]),Rs[t]=!0)},wl=t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&i_("LAZY_LOAD_DEPRECATED")},Bl="c4",r_=t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),n_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./c4Diagram-c83219d4-D6p8ypCm.js");return{diagram:e}},__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Bl,diagram:t}},o_={id:Bl,detector:r_,loader:n_},s_=o_,Al="flowchart",a_=(t,e)=>{var i,r;return((i=e==null?void 0:e.flowchart)==null?void 0:i.defaultRenderer)==="dagre-wrapper"||((r=e==null?void 0:e.flowchart)==null?void 0:r.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)},l_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./flowDiagram-50d868cf-TwIyXXXF.js");return{diagram:e}},__vite__mapDeps([16,17,18,19,20,21,22,23,24,9,25,26,27,28,2,3,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Al,diagram:t}},h_={id:Al,detector:a_,loader:l_},c_=h_,Ll="flowchart-v2",u_=(t,e)=>{var i,r,n;return((i=e==null?void 0:e.flowchart)==null?void 0:i.defaultRenderer)==="dagre-d3"||((r=e==null?void 0:e.flowchart)==null?void 0:r.defaultRenderer)==="elk"?!1:/^\s*graph/.test(t)&&((n=e==null?void 0:e.flowchart)==null?void 0:n.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(t)},f_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./flowDiagram-v2-4f6560a1-BVBLmLuF.js");return{diagram:e}},__vite__mapDeps([29,17,20,18,21,19,22,23,24,9,25,26,27,28,2,3,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Ll,diagram:t}},d_={id:Ll,detector:u_,loader:f_},p_=d_,Fl="er",g_=t=>/^\s*erDiagram/.test(t),m_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./erDiagram-0228fc6a-CT6sGbRt.js");return{diagram:e}},__vite__mapDeps([30,18,19,2,3,31,25,26,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Fl,diagram:t}},__={id:Fl,detector:g_,loader:m_},y_=__,El="gitGraph",C_=t=>/^\s*gitGraph/.test(t),x_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./gitGraphDiagram-82fe8481-DyQm-Zjm.js");return{diagram:e}},__vite__mapDeps([32,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:El,diagram:t}},b_={id:El,detector:C_,loader:x_},T_=b_,Ol="gantt",v_=t=>/^\s*gantt/.test(t),k_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./ganttDiagram-a2739b55-8AQg64kz.js");return{diagram:e}},__vite__mapDeps([33,2,3,34,35,36,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Ol,diagram:t}},S_={id:Ol,detector:v_,loader:k_},w_=S_,Ml="info",B_=t=>/^\s*info/.test(t),A_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./infoDiagram-8eee0895-GyJkJkHf.js");return{diagram:e}},__vite__mapDeps([37,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Ml,diagram:t}},L_={id:Ml,detector:B_,loader:A_},Il="pie",F_=t=>/^\s*pie/.test(t),E_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./pieDiagram-a8764435-CmM5L_IY.js");return{diagram:e}},__vite__mapDeps([38,2,3,39,27,40,36,26,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Il,diagram:t}},O_={id:Il,detector:F_,loader:E_},Dl="quadrantChart",M_=t=>/^\s*quadrantChart/.test(t),I_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./quadrantDiagram-1e28029f-OhwuIbQk.js");return{diagram:e}},__vite__mapDeps([41,2,3,35,36,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Dl,diagram:t}},D_={id:Dl,detector:M_,loader:I_},N_=D_,Nl="xychart",R_=t=>/^\s*xychart-beta/.test(t),P_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./xychartDiagram-f5964ef8-DQiAksJb.js");return{diagram:e}},__vite__mapDeps([42,24,9,2,3,36,40,35,25,26,27,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Nl,diagram:t}},$_={id:Nl,detector:R_,loader:P_},q_=$_,Rl="requirement",z_=t=>/^\s*requirement(Diagram)?/.test(t),W_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./requirementDiagram-08caed73-D_DgsmVt.js");return{diagram:e}},__vite__mapDeps([43,18,19,2,3,25,26,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Rl,diagram:t}},j_={id:Rl,detector:z_,loader:W_},H_=j_,Pl="sequence",U_=t=>/^\s*sequenceDiagram/.test(t),Y_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./sequenceDiagram-c5b8d532-SNdJCDu6.js");return{diagram:e}},__vite__mapDeps([44,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Pl,diagram:t}},G_={id:Pl,detector:U_,loader:Y_},V_=G_,$l="class",X_=(t,e)=>{var i;return((i=e==null?void 0:e.class)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(t)},K_=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./classDiagram-beda092f-DG-1z2TN.js");return{diagram:e}},__vite__mapDeps([45,46,18,19,2,3,25,26,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:$l,diagram:t}},Z_={id:$l,detector:X_,loader:K_},J_=Z_,ql="classDiagram",Q_=(t,e)=>{var i;return/^\s*classDiagram/.test(t)&&((i=e==null?void 0:e.class)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!0:/^\s*classDiagram-v2/.test(t)},ty=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./classDiagram-v2-2358418a-Cz8b4ol9.js");return{diagram:e}},__vite__mapDeps([47,46,18,21,19,22,23,24,9,25,26,27,2,3,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:ql,diagram:t}},ey={id:ql,detector:Q_,loader:ty},iy=ey,zl="state",ry=(t,e)=>{var i;return((i=e==null?void 0:e.state)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(t)},ny=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./stateDiagram-1ecb1508-BLLG6eEq.js");return{diagram:e}},__vite__mapDeps([48,49,18,19,2,3,25,26,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:zl,diagram:t}},oy={id:zl,detector:ry,loader:ny},sy=oy,Wl="stateDiagram",ay=(t,e)=>{var i;return!!(/^\s*stateDiagram-v2/.test(t)||/^\s*stateDiagram/.test(t)&&((i=e==null?void 0:e.state)==null?void 0:i.defaultRenderer)==="dagre-wrapper")},ly=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./stateDiagram-v2-c2b004d7-CKQXzi9j.js");return{diagram:e}},__vite__mapDeps([50,49,18,21,19,22,23,24,9,25,26,27,2,3,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Wl,diagram:t}},hy={id:Wl,detector:ay,loader:ly},cy=hy,jl="journey",uy=t=>/^\s*journey/.test(t),fy=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./journeyDiagram-c64418c1-DOkECmb-.js");return{diagram:e}},__vite__mapDeps([51,1,2,3,39,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:jl,diagram:t}},dy={id:jl,detector:uy,loader:fy},py=dy,gy=function(t,e){for(let i of e)t.attr(i[0],i[1])},my=function(t,e,i){let r=new Map;return i?(r.set("width","100%"),r.set("style",`max-width: ${e}px;`)):(r.set("height",t),r.set("width",e)),r},Hl=function(t,e,i,r){const n=my(e,i,r);gy(t,n)},_y=function(t,e,i,r){const n=e.node().getBBox(),o=n.width,s=n.height;B.info(`SVG bounds: ${o}x${s}`,n);let a=0,l=0;B.info(`Graph bounds: ${a}x${l}`,t),a=o+i*2,l=s+i*2,B.info(`Calculated bounds: ${a}x${l}`),Hl(e,l,a,r);const h=`${n.x-i} ${n.y-i} ${n.width+2*i} ${n.height+2*i}`;e.attr("viewBox",h)},$i={},yy=(t,e,i)=>{let r="";return t in $i&&$i[t]?r=$i[t](i):B.warn(`No theme found for ${t}`),` & { font-family: ${i.fontFamily}; font-size: ${i.fontSize}; fill: ${i.textColor} } /* Classes common for multiple diagrams */ & .error-icon { fill: ${i.errorBkgColor}; } & .error-text { fill: ${i.errorTextColor}; stroke: ${i.errorTextColor}; } & .edge-thickness-normal { stroke-width: 2px; } & .edge-thickness-thick { stroke-width: 3.5px } & .edge-pattern-solid { stroke-dasharray: 0; } & .edge-pattern-dashed{ stroke-dasharray: 3; } .edge-pattern-dotted { stroke-dasharray: 2; } & .marker { fill: ${i.lineColor}; stroke: ${i.lineColor}; } & .marker.cross { stroke: ${i.lineColor}; } & svg { font-family: ${i.fontFamily}; font-size: ${i.fontSize}; } ${r} ${e} `},Cy=(t,e)=>{e!==void 0&&($i[t]=e)},xy=yy;let Zn="",Jn="",Qn="";const to=t=>we(t,wt()),by=()=>{Zn="",Qn="",Jn=""},Ty=t=>{Zn=to(t).replace(/^\s+/g,"")},vy=()=>Zn,ky=t=>{Qn=to(t).replace(/\n\s+/g,` `)},Sy=()=>Qn,wy=t=>{Jn=to(t)},By=()=>Jn,Ay=Object.freeze(Object.defineProperty({__proto__:null,clear:by,getAccDescription:Sy,getAccTitle:vy,getDiagramTitle:By,setAccDescription:ky,setAccTitle:Ty,setDiagramTitle:wy},Symbol.toStringTag,{value:"Module"})),Ly=B,Fy=Yn,eo=wt,h1=kl,c1=Ae,Ey=t=>we(t,eo()),Oy=_y,My=()=>Ay,ir={},rr=(t,e,i)=>{var r;if(ir[t])throw new Error(`Diagram ${t} already registered.`);ir[t]=e,i&&_l(t,i),Cy(t,e.styles),(r=e.injectUtils)==null||r.call(e,Ly,Fy,eo,Ey,Oy,My(),()=>{})},io=t=>{if(t in ir)return ir[t];throw new Iy(t)};class Iy extends Error{constructor(e){super(`Diagram ${e} not found.`)}}const Dy=t=>{var e;const{securityLevel:i}=eo();let r=ct("body");if(i==="sandbox"){const s=((e=ct(`#i${t}`).node())==null?void 0:e.contentDocument)??document;r=ct(s.body)}return r.select(`#${t}`)},Ny=(t,e,i)=>{B.debug(`rendering svg for syntax error `);const r=Dy(e),n=r.append("g");r.attr("viewBox","0 0 2412 512"),Hl(r,100,512,!0),n.append("path").attr("class","error-icon").attr("d","m411.313,123.313c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32-9.375,9.375-20.688-20.688c-12.484-12.5-32.766-12.5-45.25,0l-16,16c-1.261,1.261-2.304,2.648-3.31,4.051-21.739-8.561-45.324-13.426-70.065-13.426-105.867,0-192,86.133-192,192s86.133,192 192,192 192-86.133 192-192c0-24.741-4.864-48.327-13.426-70.065 1.402-1.007 2.79-2.049 4.051-3.31l16-16c12.5-12.492 12.5-32.758 0-45.25l-20.688-20.688 9.375-9.375 32.001-31.999zm-219.313,100.687c-52.938,0-96,43.063-96,96 0,8.836-7.164,16-16,16s-16-7.164-16-16c0-70.578 57.422-128 128-128 8.836,0 16,7.164 16,16s-7.164,16-16,16z"),n.append("path").attr("class","error-icon").attr("d","m459.02,148.98c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l16,16c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16.001-16z"),n.append("path").attr("class","error-icon").attr("d","m340.395,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688 6.25-6.25 6.25-16.375 0-22.625l-16-16c-6.25-6.25-16.375-6.25-22.625,0s-6.25,16.375 0,22.625l15.999,16z"),n.append("path").attr("class","error-icon").attr("d","m400,64c8.844,0 16-7.164 16-16v-32c0-8.836-7.156-16-16-16-8.844,0-16,7.164-16,16v32c0,8.836 7.156,16 16,16z"),n.append("path").attr("class","error-icon").attr("d","m496,96.586h-32c-8.844,0-16,7.164-16,16 0,8.836 7.156,16 16,16h32c8.844,0 16-7.164 16-16 0-8.836-7.156-16-16-16z"),n.append("path").attr("class","error-icon").attr("d","m436.98,75.605c3.125,3.125 7.219,4.688 11.313,4.688 4.094,0 8.188-1.563 11.313-4.688l32-32c6.25-6.25 6.25-16.375 0-22.625s-16.375-6.25-22.625,0l-32,32c-6.251,6.25-6.251,16.375-0.001,22.625z"),n.append("text").attr("class","error-text").attr("x",1440).attr("y",250).attr("font-size","150px").style("text-anchor","middle").text("Syntax error in text"),n.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${i}`)},Ul={draw:Ny},Ry=Ul,Py={db:{},renderer:Ul,parser:{parser:{yy:{}},parse:()=>{}}},$y=Py,Yl="flowchart-elk",qy=(t,e)=>{var i;return!!(/^\s*flowchart-elk/.test(t)||/^\s*flowchart|graph/.test(t)&&((i=e==null?void 0:e.flowchart)==null?void 0:i.defaultRenderer)==="elk")},zy=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./flowchart-elk-definition-6af322e1-BXfcLmB9.js");return{diagram:e}},__vite__mapDeps([52,17,23,24,9,25,26,27,3,13,14,2,4,5,6,7,8,10,11,12,15]),import.meta.url);return{id:Yl,diagram:t}},Wy={id:Yl,detector:qy,loader:zy},jy=Wy,Gl="timeline",Hy=t=>/^\s*timeline/.test(t),Uy=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./timeline-definition-faaaa080-BNeUvLCv.js");return{diagram:e}},__vite__mapDeps([53,2,3,39,27,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Gl,diagram:t}},Yy={id:Gl,detector:Hy,loader:Uy},Gy=Yy,Vl="mindmap",Vy=t=>/^\s*mindmap/.test(t),Xy=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./mindmap-definition-8da855dc-DuBe1rA6.js");return{diagram:e}},__vite__mapDeps([54,3,24,9,2,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Vl,diagram:t}},Ky={id:Vl,detector:Vy,loader:Xy},Zy=Ky,Xl="sankey",Jy=t=>/^\s*sankey-beta/.test(t),Qy=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./sankeyDiagram-a04cb91d-oat-2JMp.js");return{diagram:e}},__vite__mapDeps([55,2,3,40,36,56,4,5,6,7,8,9,10,11,12,13,14,15]),import.meta.url);return{id:Xl,diagram:t}},tC={id:Xl,detector:Jy,loader:Qy},eC=tC,Kl="block",iC=t=>/^\s*block-beta/.test(t),rC=async()=>{const{diagram:t}=await N(async()=>{const{diagram:e}=await import("./blockDiagram-c4efeb88-CFDJCMbj.js");return{diagram:e}},__vite__mapDeps([57,22,18,23,24,9,25,26,27,2,3,28,40,36,56,4,5,6,7,8,10,11,12,13,14,15]),import.meta.url);return{id:Kl,diagram:t}},nC={id:Kl,detector:iC,loader:rC},oC=nC;let Ps=!1;const ro=()=>{Ps||(Ps=!0,rr("error",$y,t=>t.toLowerCase().trim()==="error"),rr("---",{db:{clear:()=>{}},styles:{},renderer:{draw:()=>{}},parser:{parser:{yy:{}},parse:()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")}},init:()=>null},t=>t.toLowerCase().trimStart().startsWith("---")),ml(s_,iy,J_,y_,w_,L_,O_,H_,V_,jy,p_,c_,Zy,Gy,T_,cy,sy,py,N_,eC,q_,oC))};class Zl{constructor(e,i={}){this.text=e,this.metadata=i,this.type="graph",this.text=X0(e),this.text+=` `;const r=wt();try{this.type=vr(e,r)}catch(o){this.type="error",this.detectError=o}const n=io(this.type);B.debug("Type "+this.type),this.db=n.db,this.renderer=n.renderer,this.parser=n.parser,this.parser.parser.yy=this.db,this.init=n.init,this.parse()}parse(){var e,i,r,n,o;if(this.detectError)throw this.detectError;(i=(e=this.db).clear)==null||i.call(e);const s=wt();(r=this.init)==null||r.call(this,s),this.metadata.title&&((o=(n=this.db).setDiagramTitle)==null||o.call(n,this.metadata.title)),this.parser.parse(this.text)}async render(e,i){await this.renderer.draw(this.text,e,i,this)}getParser(){return this.parser}getType(){return this.type}}const sC=async(t,e={})=>{const i=vr(t,wt());try{io(i)}catch{const n=v0(i);if(!n)throw new gl(`Diagram ${i} not found.`);const{id:o,diagram:s}=await n();rr(o,s)}return new Zl(t,e)};let $s=[];const aC=()=>{$s.forEach(t=>{t()}),$s=[]},lC="graphics-document document";function hC(t,e){t.attr("role",lC),e!==""&&t.attr("aria-roledescription",e)}function cC(t,e,i,r){if(t.insert!==void 0){if(i){const n=`chart-desc-${r}`;t.attr("aria-describedby",n),t.insert("desc",":first-child").attr("id",n).text(i)}if(e){const n=`chart-title-${r}`;t.attr("aria-labelledby",n),t.insert("title",":first-child").attr("id",n).text(e)}}}const uC=t=>t.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart();/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function Jl(t){return typeof t>"u"||t===null}function fC(t){return typeof t=="object"&&t!==null}function dC(t){return Array.isArray(t)?t:Jl(t)?[]:[t]}function pC(t,e){var i,r,n,o;if(e)for(o=Object.keys(e),i=0,r=o.length;ia&&(o=" ... ",e=r-a+o.length),i-r>a&&(s=" ...",i=r+a-s.length),{str:o+t.slice(e,i).replace(/\t/g,"→")+s,pos:r-e+o.length}}function rn(t,e){return tt.repeat(" ",e-t.length)+t}function vC(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 i=/\r?\n|\r|\0/g,r=[0],n=[],o,s=-1;o=i.exec(t.buffer);)n.push(o.index),r.push(o.index+o[0].length),t.position<=o.index&&s<0&&(s=r.length-2);s<0&&(s=r.length-1);var a="",l,h,u=Math.min(t.line+e.linesAfter,n.length).toString().length,d=e.maxLength-(e.indent+u+3);for(l=1;l<=e.linesBefore&&!(s-l<0);l++)h=en(t.buffer,r[s-l],n[s-l],t.position-(r[s]-r[s-l]),d),a=tt.repeat(" ",e.indent)+rn((t.line-l+1).toString(),u)+" | "+h.str+` `+a;for(h=en(t.buffer,r[s],n[s],t.position,d),a+=tt.repeat(" ",e.indent)+rn((t.line+1).toString(),u)+" | "+h.str+` `,a+=tt.repeat("-",e.indent+u+3+h.pos)+`^ `,l=1;l<=e.linesAfter&&!(s+l>=n.length);l++)h=en(t.buffer,r[s+l],n[s+l],t.position-(r[s]-r[s+l]),d),a+=tt.repeat(" ",e.indent)+rn((t.line+l+1).toString(),u)+" | "+h.str+` `;return a.replace(/\n$/,"")}var kC=vC,SC=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],wC=["scalar","sequence","mapping"];function BC(t){var e={};return t!==null&&Object.keys(t).forEach(function(i){t[i].forEach(function(r){e[String(r)]=i})}),e}function AC(t,e){if(e=e||{},Object.keys(e).forEach(function(i){if(SC.indexOf(i)===-1)throw new Nt('Unknown option "'+i+'" 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(i){return i},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=BC(e.styleAliases||null),wC.indexOf(this.kind)===-1)throw new Nt('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var J=AC;function qs(t,e){var i=[];return t[e].forEach(function(r){var n=i.length;i.forEach(function(o,s){o.tag===r.tag&&o.kind===r.kind&&o.multi===r.multi&&(n=s)}),i[n]=r}),i}function LC(){var t={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},e,i;function r(n){n.multi?(t.multi[n.kind].push(n),t.multi.fallback.push(n)):t[n.kind][n.tag]=t.fallback[n.tag]=n}for(e=0,i=arguments.length;e=0?"0b"+t.toString(2):"-0b"+t.toString(2).slice(1)},octal:function(t){return t>=0?"0o"+t.toString(8):"-0o"+t.toString(8).slice(1)},decimal:function(t){return t.toString(10)},hexadecimal:function(t){return t>=0?"0x"+t.toString(16).toUpperCase():"-0x"+t.toString(16).toUpperCase().slice(1)}},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),KC=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function ZC(t){return!(t===null||!KC.test(t)||t[t.length-1]==="_")}function JC(t){var e,i;return e=t.replace(/_/g,"").toLowerCase(),i=e[0]==="-"?-1:1,"+-".indexOf(e[0])>=0&&(e=e.slice(1)),e===".inf"?i===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:e===".nan"?NaN:i*parseFloat(e,10)}var QC=/^[-+]?[0-9]+e/;function tx(t,e){var i;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(tt.isNegativeZero(t))return"-0.0";return i=t.toString(10),QC.test(i)?i.replace("e",".e"):i}function ex(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||tt.isNegativeZero(t))}var ix=new J("tag:yaml.org,2002:float",{kind:"scalar",resolve:ZC,construct:JC,predicate:ex,represent:tx,defaultStyle:"lowercase"}),th=IC.extend({implicit:[PC,WC,XC,ix]}),rx=th,eh=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),ih=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]))?))?$");function nx(t){return t===null?!1:eh.exec(t)!==null||ih.exec(t)!==null}function ox(t){var e,i,r,n,o,s,a,l=0,h=null,u,d,c;if(e=eh.exec(t),e===null&&(e=ih.exec(t)),e===null)throw new Error("Date resolve error");if(i=+e[1],r=+e[2]-1,n=+e[3],!e[4])return new Date(Date.UTC(i,r,n));if(o=+e[4],s=+e[5],a=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(u=+e[10],d=+(e[11]||0),h=(u*60+d)*6e4,e[9]==="-"&&(h=-h)),c=new Date(Date.UTC(i,r,n,o,s,a,l)),h&&c.setTime(c.getTime()-h),c}function sx(t){return t.toISOString()}var ax=new J("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:nx,construct:ox,instanceOf:Date,represent:sx});function lx(t){return t==="<<"||t===null}var hx=new J("tag:yaml.org,2002:merge",{kind:"scalar",resolve:lx}),no=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= \r`;function cx(t){if(t===null)return!1;var e,i,r=0,n=t.length,o=no;for(i=0;i64)){if(e<0)return!1;r+=6}return r%8===0}function ux(t){var e,i,r=t.replace(/[\r\n=]/g,""),n=r.length,o=no,s=0,a=[];for(e=0;e>16&255),a.push(s>>8&255),a.push(s&255)),s=s<<6|o.indexOf(r.charAt(e));return i=n%4*6,i===0?(a.push(s>>16&255),a.push(s>>8&255),a.push(s&255)):i===18?(a.push(s>>10&255),a.push(s>>2&255)):i===12&&a.push(s>>4&255),new Uint8Array(a)}function fx(t){var e="",i=0,r,n,o=t.length,s=no;for(r=0;r>18&63],e+=s[i>>12&63],e+=s[i>>6&63],e+=s[i&63]),i=(i<<8)+t[r];return n=o%3,n===0?(e+=s[i>>18&63],e+=s[i>>12&63],e+=s[i>>6&63],e+=s[i&63]):n===2?(e+=s[i>>10&63],e+=s[i>>4&63],e+=s[i<<2&63],e+=s[64]):n===1&&(e+=s[i>>2&63],e+=s[i<<4&63],e+=s[64],e+=s[64]),e}function dx(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var px=new J("tag:yaml.org,2002:binary",{kind:"scalar",resolve:cx,construct:ux,predicate:dx,represent:fx}),gx=Object.prototype.hasOwnProperty,mx=Object.prototype.toString;function _x(t){if(t===null)return!0;var e=[],i,r,n,o,s,a=t;for(i=0,r=a.length;i>10)+55296,(t-65536&1023)+56320)}var ah=new Array(256),lh=new Array(256);for(var ge=0;ge<256;ge++)ah[ge]=js(ge)?1:0,lh[ge]=js(ge);function Rx(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||Ax,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 hh(t,e){var i={name:t.filename,buffer:t.input.slice(0,-1),position:t.position,line:t.line,column:t.position-t.lineStart};return i.snippet=kC(i),new Nt(e,i)}function S(t,e){throw hh(t,e)}function sr(t,e){t.onWarning&&t.onWarning.call(null,hh(t,e))}var Hs={YAML:function(e,i,r){var n,o,s;e.version!==null&&S(e,"duplication of %YAML directive"),r.length!==1&&S(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(r[0]),n===null&&S(e,"ill-formed argument of the YAML directive"),o=parseInt(n[1],10),s=parseInt(n[2],10),o!==1&&S(e,"unacceptable YAML version of the document"),e.version=r[0],e.checkLineBreaks=s<2,s!==1&&s!==2&&sr(e,"unsupported YAML version of the document")},TAG:function(e,i,r){var n,o;r.length!==2&&S(e,"TAG directive accepts exactly two arguments"),n=r[0],o=r[1],oh.test(n)||S(e,"ill-formed tag handle (first argument) of the TAG directive"),Ut.call(e.tagMap,n)&&S(e,'there is a previously declared suffix for "'+n+'" tag handle'),sh.test(o)||S(e,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch{S(e,"tag prefix is malformed: "+o)}e.tagMap[n]=o}};function jt(t,e,i,r){var n,o,s,a;if(e1&&(t.result+=tt.repeat(` `,e-1))}function Px(t,e,i){var r,n,o,s,a,l,h,u,d=t.kind,c=t.result,g;if(g=t.input.charCodeAt(t.position),at(g)||me(g)||g===35||g===38||g===42||g===33||g===124||g===62||g===39||g===34||g===37||g===64||g===96||(g===63||g===45)&&(n=t.input.charCodeAt(t.position+1),at(n)||i&&me(n)))return!1;for(t.kind="scalar",t.result="",o=s=t.position,a=!1;g!==0;){if(g===58){if(n=t.input.charCodeAt(t.position+1),at(n)||i&&me(n))break}else if(g===35){if(r=t.input.charCodeAt(t.position-1),at(r))break}else{if(t.position===t.lineStart&&Sr(t)||i&&me(g))break;if(kt(g))if(l=t.line,h=t.lineStart,u=t.lineIndent,W(t,!1,-1),t.lineIndent>=e){a=!0,g=t.input.charCodeAt(t.position);continue}else{t.position=s,t.line=l,t.lineStart=h,t.lineIndent=u;break}}a&&(jt(t,o,s,!1),so(t,t.line-l),o=s=t.position,a=!1),Qt(g)||(s=t.position+1),g=t.input.charCodeAt(++t.position)}return jt(t,o,s,!1),t.result?!0:(t.kind=d,t.result=c,!1)}function $x(t,e){var i,r,n;if(i=t.input.charCodeAt(t.position),i!==39)return!1;for(t.kind="scalar",t.result="",t.position++,r=n=t.position;(i=t.input.charCodeAt(t.position))!==0;)if(i===39)if(jt(t,r,t.position,!0),i=t.input.charCodeAt(++t.position),i===39)r=t.position,t.position++,n=t.position;else return!0;else kt(i)?(jt(t,r,n,!0),so(t,W(t,!1,e)),r=n=t.position):t.position===t.lineStart&&Sr(t)?S(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);S(t,"unexpected end of the stream within a single quoted scalar")}function qx(t,e){var i,r,n,o,s,a;if(a=t.input.charCodeAt(t.position),a!==34)return!1;for(t.kind="scalar",t.result="",t.position++,i=r=t.position;(a=t.input.charCodeAt(t.position))!==0;){if(a===34)return jt(t,i,t.position,!0),t.position++,!0;if(a===92){if(jt(t,i,t.position,!0),a=t.input.charCodeAt(++t.position),kt(a))W(t,!1,e);else if(a<256&&ah[a])t.result+=lh[a],t.position++;else if((s=Ix(a))>0){for(n=s,o=0;n>0;n--)a=t.input.charCodeAt(++t.position),(s=Mx(a))>=0?o=(o<<4)+s:S(t,"expected hexadecimal character");t.result+=Nx(o),t.position++}else S(t,"unknown escape sequence");i=r=t.position}else kt(a)?(jt(t,i,r,!0),so(t,W(t,!1,e)),i=r=t.position):t.position===t.lineStart&&Sr(t)?S(t,"unexpected end of the document within a double quoted scalar"):(t.position++,r=t.position)}S(t,"unexpected end of the stream within a double quoted scalar")}function zx(t,e){var i=!0,r,n,o,s=t.tag,a,l=t.anchor,h,u,d,c,g,y=Object.create(null),C,v,O,x;if(x=t.input.charCodeAt(t.position),x===91)u=93,g=!1,a=[];else if(x===123)u=125,g=!0,a={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=a),x=t.input.charCodeAt(++t.position);x!==0;){if(W(t,!0,e),x=t.input.charCodeAt(t.position),x===u)return t.position++,t.tag=s,t.anchor=l,t.kind=g?"mapping":"sequence",t.result=a,!0;i?x===44&&S(t,"expected the node content, but found ','"):S(t,"missed comma between flow collection entries"),v=C=O=null,d=c=!1,x===63&&(h=t.input.charCodeAt(t.position+1),at(h)&&(d=c=!0,t.position++,W(t,!0,e))),r=t.line,n=t.lineStart,o=t.position,Fe(t,e,nr,!1,!0),v=t.tag,C=t.result,W(t,!0,e),x=t.input.charCodeAt(t.position),(c||t.line===r)&&x===58&&(d=!0,x=t.input.charCodeAt(++t.position),W(t,!0,e),Fe(t,e,nr,!1,!0),O=t.result),g?_e(t,a,y,v,C,O,r,n,o):d?a.push(_e(t,null,y,v,C,O,r,n,o)):a.push(C),W(t,!0,e),x=t.input.charCodeAt(t.position),x===44?(i=!0,x=t.input.charCodeAt(++t.position)):i=!1}S(t,"unexpected end of the stream within a flow collection")}function Wx(t,e){var i,r,n=nn,o=!1,s=!1,a=e,l=0,h=!1,u,d;if(d=t.input.charCodeAt(t.position),d===124)r=!1;else if(d===62)r=!0;else return!1;for(t.kind="scalar",t.result="";d!==0;)if(d=t.input.charCodeAt(++t.position),d===43||d===45)nn===n?n=d===43?zs:Lx:S(t,"repeat of a chomping mode identifier");else if((u=Dx(d))>=0)u===0?S(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):s?S(t,"repeat of an indentation width identifier"):(a=e+u-1,s=!0);else break;if(Qt(d)){do d=t.input.charCodeAt(++t.position);while(Qt(d));if(d===35)do d=t.input.charCodeAt(++t.position);while(!kt(d)&&d!==0)}for(;d!==0;){for(oo(t),t.lineIndent=0,d=t.input.charCodeAt(t.position);(!s||t.lineIndenta&&(a=t.lineIndent),kt(d)){l++;continue}if(t.lineIndente)&&l!==0)S(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(v&&(s=t.line,a=t.lineStart,l=t.position),Fe(t,e,or,!0,n)&&(v?y=t.result:C=t.result),v||(_e(t,d,c,g,y,C,s,a,l),g=y=C=null),W(t,!0,-1),x=t.input.charCodeAt(t.position)),(t.line===o||t.lineIndent>e)&&x!==0)S(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+'"'),d=0,c=t.implicitTypes.length;d"),t.result!==null&&y.kind!==t.kind&&S(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+y.kind+'", not "'+t.kind+'"'),y.resolve(t.result,t.tag)?(t.result=y.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):S(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||u}function Gx(t){var e=t.position,i,r,n,o=!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&&(W(t,!0,-1),s=t.input.charCodeAt(t.position),!(t.lineIndent>0||s!==37));){for(o=!0,s=t.input.charCodeAt(++t.position),i=t.position;s!==0&&!at(s);)s=t.input.charCodeAt(++t.position);for(r=t.input.slice(i,t.position),n=[],r.length<1&&S(t,"directive name must not be less than one character in length");s!==0;){for(;Qt(s);)s=t.input.charCodeAt(++t.position);if(s===35){do s=t.input.charCodeAt(++t.position);while(s!==0&&!kt(s));break}if(kt(s))break;for(i=t.position;s!==0&&!at(s);)s=t.input.charCodeAt(++t.position);n.push(t.input.slice(i,t.position))}s!==0&&oo(t),Ut.call(Hs,r)?Hs[r](t,r,n):sr(t,'unknown document directive "'+r+'"')}if(W(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,W(t,!0,-1)):o&&S(t,"directives end mark is expected"),Fe(t,t.lineIndent-1,or,!1,!0),W(t,!0,-1),t.checkLineBreaks&&Ex.test(t.input.slice(e,t.position))&&sr(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Sr(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,W(t,!0,-1));return}if(t.positiont.replace(/\r\n?/g,` `).replace(/<(\w+)([^>]*)>/g,(e,i,r)=>"<"+i+r.replace(/="([^"]*)"/g,"='$1'")+">"),ib=t=>{const{text:e,metadata:i}=tb(t),{displayMode:r,title:n,config:o={}}=i;return r&&(o.gantt||(o.gantt={}),o.gantt.displayMode=r),{title:n,config:o,text:e}},rb=t=>{const e=ti.detectInit(t)??{},i=ti.detectDirective(t,"wrap");return Array.isArray(i)?e.wrap=i.some(({type:r})=>{}):(i==null?void 0:i.type)==="wrap"&&(e.wrap=!0),{text:A0(t),directive:e}};function ch(t){const e=eb(t),i=ib(e),r=rb(i.text),n=bl(i.config,r.directive);return t=uC(r.text),{code:t,title:i.title,config:n}}const nb=5e4,ob="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",sb="sandbox",ab="loose",lb="http://www.w3.org/2000/svg",hb="http://www.w3.org/1999/xlink",cb="http://www.w3.org/1999/xhtml",ub="100%",fb="100%",db="border:0;margin:0;",pb="margin:0",gb="allow-top-navigation-by-user-activation allow-popups",mb='The "iframe" tag is not supported by your browser.',_b=["foreignobject"],yb=["dominant-baseline"];function uh(t){const e=ch(t);return er(),t_(e.config??{}),e}async function Cb(t,e){ro(),t=uh(t).code;try{await ao(t)}catch(i){if(e!=null&&e.suppressErrors)return!1;throw i}return!0}const Gs=(t,e,i=[])=>` .${t} ${e} { ${i.join(" !important; ")} !important; }`,xb=(t,e={})=>{var i;let r="";if(t.themeCSS!==void 0&&(r+=` ${t.themeCSS}`),t.fontFamily!==void 0&&(r+=` :root { --mermaid-font-family: ${t.fontFamily}}`),t.altFontFamily!==void 0&&(r+=` :root { --mermaid-alt-font-family: ${t.altFontFamily}}`),!tn(e)){const a=t.htmlLabels||((i=t.flowchart)==null?void 0:i.htmlLabels)?["> *","span"]:["rect","polygon","ellipse","circle","path"];for(const l in e){const h=e[l];tn(h.styles)||a.forEach(u=>{r+=Gs(h.id,u,h.styles)}),tn(h.textStyles)||(r+=Gs(h.id,"tspan",h.textStyles))}}return r},bb=(t,e,i,r)=>{const n=xb(t,i),o=xy(e,n,t.themeVariables);return Cn(Om(`${r}{${o}}`),Im)},Tb=(t="",e,i)=>{let r=t;return!i&&!e&&(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),r=K0(r),r=r.replace(/
/g,"
"),r},vb=(t="",e)=>{var i,r;const n=(r=(i=e==null?void 0:e.viewBox)==null?void 0:i.baseVal)!=null&&r.height?e.viewBox.baseVal.height+"px":fb,o=btoa(''+t+"");return``},Vs=(t,e,i,r,n)=>{const o=t.append("div");o.attr("id",i),r&&o.attr("style",r);const s=o.append("svg").attr("id",e).attr("width","100%").attr("xmlns",lb);return n&&s.attr("xmlns:xlink",n),s.append("g"),t};function Xs(t,e){return t.append("iframe").attr("id",e).attr("style","width: 100%; height: 100%;").attr("sandbox","")}const kb=(t,e,i,r)=>{var n,o,s;(n=t.getElementById(e))==null||n.remove(),(o=t.getElementById(i))==null||o.remove(),(s=t.getElementById(r))==null||s.remove()},Sb=async function(t,e,i){var r,n,o,s,a,l;ro();const h=uh(e);e=h.code;const u=wt();B.debug(u),e.length>((u==null?void 0:u.maxTextSize)??nb)&&(e=ob);const d="#"+t,c="i"+t,g="#"+c,y="d"+t,C="#"+y;let v=ct("body");const O=u.securityLevel===sb,x=u.securityLevel===ab,R=u.fontFamily;if(i!==void 0){if(i&&(i.innerHTML=""),O){const pt=Xs(ct(i),c);v=ct(pt.nodes()[0].contentDocument.body),v.node().style.margin=0}else v=ct(i);Vs(v,t,y,`font-family: ${R}`,hb)}else{if(kb(document,t,y,c),O){const pt=Xs(ct("body"),c);v=ct(pt.nodes()[0].contentDocument.body),v.node().style.margin=0}else v=ct("body");Vs(v,t,y)}let F,P;try{F=await ao(e,{title:h.title})}catch(pt){F=new Zl("error"),P=pt}const V=v.select(C).node(),M=F.type,mi=V.firstChild,wr=mi.firstChild,Br=(n=(r=F.renderer).getClasses)==null?void 0:n.call(r,e,F),U=bb(u,M,Br,d),se=document.createElement("style");se.innerHTML=U,mi.insertBefore(se,wr);try{await F.renderer.draw(e,t,Ns,F)}catch(pt){throw Ry.draw(e,t,Ns),pt}const Ie=v.select(`${C} svg`),De=(s=(o=F.db).getAccTitle)==null?void 0:s.call(o),Ar=(l=(a=F.db).getAccDescription)==null?void 0:l.call(a);Bb(M,Ie,De,Ar),v.select(`[id="${t}"]`).selectAll("foreignobject > *").attr("xmlns",cb);let Lt=v.select(C).node().innerHTML;if(B.debug("config.arrowMarkerAbsolute",u.arrowMarkerAbsolute),Lt=Tb(Lt,O,ul(u.arrowMarkerAbsolute)),O){const pt=v.select(C+" svg").node();Lt=vb(Lt,pt)}else x||(Lt=ve.sanitize(Lt,{ADD_TAGS:_b,ADD_ATTR:yb,HTML_INTEGRATION_POINTS:{foreignobject:!0}}));if(aC(),P)throw P;const ae=ct(O?g:C).node();return ae&&"remove"in ae&&ae.remove(),{svg:Lt,bindFunctions:F.db.bindFunctions}};function wb(t={}){var e;t!=null&&t.fontFamily&&!((e=t.themeVariables)!=null&&e.fontFamily)&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),J0(t),t!=null&&t.theme&&t.theme in Rt?t.themeVariables=Rt[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=Rt.default.getThemeVariables(t.themeVariables));const i=typeof t=="object"?Z0(t):vl();Yn(i.logLevel),ro()}const ao=(t,e={})=>{const{code:i}=ch(t);return sC(i,e)};function Bb(t,e,i,r){hC(e,t),cC(e,i,r,e.attr("id"))}const ie=Object.freeze({render:Sb,parse:Cb,getDiagramFromText:ao,initialize:wb,getConfig:wt,setConfig:kl,getSiteConfig:vl,updateSiteConfig:Q0,reset:()=>{er()},globalReset:()=>{er(Ae)},defaultConfig:Ae});Yn(wt().logLevel);er(wt());const Ab=async()=>{B.debug("Loading registered diagrams");const e=(await Promise.allSettled(Object.entries(Be).map(async([i,{detector:r,loader:n}])=>{if(n)try{io(i)}catch{try{const{diagram:s,id:a}=await n();rr(a,s,r)}catch(s){throw B.error(`Failed to load external diagram with key ${i}. Removing from detectors.`),delete Be[i],s}}}))).filter(i=>i.status==="rejected");if(e.length>0){B.error(`Failed to load ${e.length} external diagrams`);for(const i of e)B.error(i);throw new Error(`Failed to load ${e.length} external diagrams`)}},Lb=(t,e,i)=>{B.warn(t),xl(t)?(i&&i(t.str,t.hash),e.push({...t,message:t.str,error:t})):(i&&i(t),t instanceof Error&&e.push({str:t.message,message:t.message,hash:t.name,error:t}))},fh=async function(t={querySelector:".mermaid"}){try{await Fb(t)}catch(e){if(xl(e)&&B.error(e.str),dt.parseError&&dt.parseError(e),!t.suppressErrors)throw B.error("Use the suppressErrors option to suppress these errors"),e}},Fb=async function({postRenderCallback:t,querySelector:e,nodes:i}={querySelector:".mermaid"}){const r=ie.getConfig();B.debug(`${t?"":"No "}Callback function found`);let n;if(i)n=i;else if(e)n=document.querySelectorAll(e);else throw new Error("Nodes and querySelector are both undefined");B.debug(`Found ${n.length} diagrams`),(r==null?void 0:r.startOnLoad)!==void 0&&(B.debug("Start On Load: "+(r==null?void 0:r.startOnLoad)),ie.updateSiteConfig({startOnLoad:r==null?void 0:r.startOnLoad}));const o=new ti.InitIDGenerator(r.deterministicIds,r.deterministicIDSeed);let s;const a=[];for(const l of Array.from(n)){B.info("Rendering diagram: "+l.id);/*! Check if previously processed */if(l.getAttribute("data-processed"))continue;l.setAttribute("data-processed","true");const h=`mermaid-${o.next()}`;s=l.innerHTML,s=Ah(ti.entityDecode(s)).trim().replace(//gi,"
");const u=ti.detectInit(s);u&&B.debug("Detected early reinit: ",u);try{const{svg:d,bindFunctions:c}=await mh(h,s,l);l.innerHTML=d,t&&await t(h),c&&c(l)}catch(d){Lb(d,a,dt.parseError)}}if(a.length>0)throw a[0]},dh=function(t){ie.initialize(t)},Eb=async function(t,e,i){B.warn("mermaid.init is deprecated. Please use run instead."),t&&dh(t);const r={postRenderCallback:i,querySelector:".mermaid"};typeof e=="string"?r.querySelector=e:e&&(e instanceof HTMLElement?r.nodes=[e]:r.nodes=e),await fh(r)},Ob=async(t,{lazyLoad:e=!0}={})=>{ml(...t),e===!1&&await Ab()},ph=function(){if(dt.startOnLoad){const{startOnLoad:t}=ie.getConfig();t&&dt.run().catch(e=>B.error("Mermaid failed to initialize",e))}};if(typeof document<"u"){/*! * Wait for document loaded before starting the execution */window.addEventListener("load",ph,!1)}const Mb=function(t){dt.parseError=t},ar=[];let on=!1;const gh=async()=>{if(!on){for(on=!0;ar.length>0;){const t=ar.shift();if(t)try{await t()}catch(e){B.error("Error executing queue",e)}}on=!1}},Ib=async(t,e)=>new Promise((i,r)=>{const n=()=>new Promise((o,s)=>{ie.parse(t,e).then(a=>{o(a),i(a)},a=>{var l;B.error("Error parsing",a),(l=dt.parseError)==null||l.call(dt,a),s(a),r(a)})});ar.push(n),gh().catch(r)}),mh=(t,e,i)=>new Promise((r,n)=>{const o=()=>new Promise((s,a)=>{ie.render(t,e,i).then(l=>{s(l),r(l)},l=>{var h;B.error("Error parsing",l),(h=dt.parseError)==null||h.call(dt,l),a(l),n(l)})});ar.push(o),gh().catch(n)}),dt={startOnLoad:!0,mermaidAPI:ie,parse:Ib,render:mh,init:Eb,run:fh,registerExternalDiagrams:Ob,initialize:dh,parseError:void 0,contentLoaded:ph,setParseErrorHandler:Mb,detectType:vr};dt.initialize({startOnLoad:!1});function Ks(t){const{code:e,name:i}=t,[r,n]=Mo.useState(null);return Mo.useEffect(()=>{if(!e)return;(async s=>{try{const{svg:a}=await dt.render(i,s||"");n(a)}catch(a){n(""),console.error("Invalid mermaid syntax: %o",a)}})(e)},[e]),Sh.createElement("div",{className:"storybook-mermaid-graph",dangerouslySetInnerHTML:{__html:r||""}})}function Zs(t){const e={blockquote:"blockquote",code:"code",em:"em",h1:"h1",h2:"h2",h3:"h3",p:"p",pre:"pre",strong:"strong",...Js(),...t.components};return T.jsxs(T.Fragment,{children:[T.jsx(wh,{title:"Styles/Tokens/Intro",parameters:{...Bh}}),` `,T.jsx(e.h1,{id:"style-tokens",children:"Style tokens"}),` `,T.jsx(e.p,{children:"All of the components in this library have been styled using a system of tokens. The style tokens give us a lot of flexibility and ultimately make for the most concise CSS possible."}),` `,T.jsx(e.p,{children:"You can use the style tokens to help shortcut the time you spend writing CSS and reinventing solid design conventions."}),` `,T.jsx(e.h2,{id:"whats-a-token",children:`What's a "token"?`}),` `,T.jsxs(e.p,{children:["A token represents the value for an individual style rule, like ",T.jsx(e.code,{children:"font-size"})," or ",T.jsx(e.code,{children:"color"}),". Each token sets just one style rule, and multiple tokens are combined together to style an element, like a ",T.jsx(e.code,{children:"
"}),"."]}),` `,T.jsx(Ks,{name:"token-graph",code:` graph LR; A(Token)-->|1rem|B; B(Style rule)-->|font-size|Y; C(Token)-->|bold|D; D(Style rule)-->|font-weight|Y; E(Token)-->|serif|F; F(Style rule)-->|font-family|Y; Y(HTML Element)-->|"<div/>"|Z("<Component/>"); `}),` `,T.jsx(e.p,{children:"Each set of tokens has several levels that represent the different values a style rule can take in our design system and are grouped in how they're named to make them easier to remember."}),` `,T.jsx(Ks,{name:"individual-graph",code:` graph LR; TD("\`**Text align tokens**\`")---TA; TD---TB; TD---TC; TA(text-left)-->TX("text-align: left;"); TB(text-center)-->TY("text-align: center;"); TC(text-right)-->TZ("text-align: right;"); `}),` `,T.jsx(e.h2,{id:"using-style-tokens",children:"Using style tokens"}),` `,T.jsxs(e.blockquote,{children:[` `,T.jsxs(e.p,{children:["Whether you use style tokens or write your own custom CSS in your project is ",T.jsx(e.strong,{children:"entirely up to you"}),"."]}),` `,T.jsxs(e.p,{children:["There are hundreds of tokens, so they can be a little daunting at first. But learning the tokens for the styles you have to write most often ",T.jsx(e.strong,{children:"will absolutely save you time"}),", so we recommend giving them a try."]}),` `,T.jsxs(e.p,{children:[T.jsx(e.strong,{children:"That said"}),", we ",T.jsx(e.em,{children:"do recommend"})," using tokens for styling typography, especially ",T.jsx(e.code,{children:"font-size"}),". (Our typography size tokens use a fluid scale so your text will look great whether a reader is on a mobile phone or giant desktop.)"]}),` `]}),` `,T.jsx(e.p,{children:"All of our style tokens can be used through either a class name, an SCSS mixin or both. Use the tables throughout this section of the docs to see what's available for each token."}),` `,T.jsx(e.h3,{id:"for-example",children:"For example..."}),` `,T.jsxs(e.p,{children:["Here's our table of text colour tokens, which set the ",T.jsx(e.code,{children:"text-color"})," style."]}),` `,T.jsx(Fh,{title:"Colour",mdnLink:"color",header:["Class","Include","Properties"],body:Eh(Oh,!0),copyable:[!0,i=>`@include mixins.${i};`,!1]}),` `,T.jsx(e.p,{children:"This table's tokens can be used through either a class or an SCSS mixin. (The table lets you click-to-copy for either.)"}),` `,T.jsxs(e.p,{children:["To use the token that sets the ",T.jsx(e.code,{children:"color"}),` style to our "primary" text colour (i.e., black), you'd use the `,T.jsx(e.code,{children:"Class"})," token like this:"]}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,T.jsxs(e.p,{children:["If you'd like to set the style in SCSS, you'd use the ",T.jsx(e.code,{children:"Include"})," token like this:"]}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,T.jsx(e.p,{children:"To use multiple tokens, you'd simply add another class or include:"}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-scss",children:`p { @include mixins.text-primary; @include mixins.font-bold; } `})}),` `,T.jsx(e.p,{children:"It's normal that not every style is accounted for by our tokens, so even if you use them expect you'll still have to write your own SCSS at times. But using the pre-made tokens will shortcut a lot of time spent tweaking styles to make designs consistent across your page. The styles set by our tokens have been pre-harmonised for you!"}),` `,T.jsxs(e.h3,{id:"important-modifier",children:[T.jsx(e.code,{children:"!important"})," modifier"]}),` `,T.jsxs(e.p,{children:["Most of our tokens can be used with an ",T.jsx(e.code,{children:"!important"})," modifier simply by adding an ",T.jsx(e.code,{children:"!"}),". So for the class token that controls ",T.jsx(e.code,{children:"font-weight"}),", you'd make it important like:"]}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,T.jsxs(e.p,{children:["For SCSS includes, the concept is the same, but you need to escape the ",T.jsx(e.code,{children:"!"})," by adding an extra ",T.jsx(e.code,{children:"\\"})," to make it valid syntax:"]}),` `,T.jsx(e.pre,{children:T.jsx(e.code,{className:"language-scss",children:`p { @include mixins.\\!font-bold; } `})})]})}function Db(t={}){const{wrapper:e}={...Js(),...t.components};return e?T.jsx(e,{...t,children:T.jsx(Zs,{...t})}):Zs(t)}const u1=Object.freeze(Object.defineProperty({__proto__:null,default:Db},Symbol.toStringTag,{value:"Module"}));export{R0 as $,q0 as A,Dy as B,St as C,Dn as D,Xb as E,Jb as F,Jo as G,Zo as H,t1 as I,Qb as J,Zb as K,Gb as L,Vb as M,i1 as N,Kb as O,e1 as P,x0 as Q,p0 as R,Ms as S,n1 as T,L as U,Kn as V,l0 as W,wt as X,r1 as Y,k0 as Z,_y as _,Sy as a,jn as a$,F0 as a0,Kf as a1,P0 as a2,fi as a3,k as a4,A as a5,Ay as a6,Ze as a7,bl as a8,lt as a9,zn as aA,il as aB,Qa as aC,Ug as aD,zg as aE,am as aF,_m as aG,pi as aH,Ee as aI,Xi as aJ,Jg as aK,Pm as aL,di as aM,Zi as aN,Yg as aO,Ga as aP,Kp as aQ,Zp as aR,Xt as aS,bs as aT,Jp as aU,Wn as aV,Xp as aW,eg as aX,Oe as aY,Yt as aZ,ms as a_,ua as aa,Wh as ab,gg as ac,qn as ad,st as ae,Su as af,Fn as ag,fa as ah,ui as ai,ga as aj,Yb as ak,En as al,zt as am,Uo as an,Ou as ao,ni as ap,re as aq,dm as ar,sm as as,pm as at,gm as au,tl as av,pr as aw,yr as ax,Ji as ay,Gp as az,vy as b,Xa as b0,Tn as b1,sg as b2,tn as b3,u1 as b4,Ty as c,ct as d,Hl as e,Z as f,eo as g,tr as h,we as i,Ih as j,Gn as k,B as l,U0 as m,gi as n,By as o,wy as p,c1 as q,by as r,ky as s,Qf as t,ti as u,ul as v,j0 as w,K0 as x,h1 as y,Oy as z};