import{M as rl}from"./chunk-S4VUQJ4A-2dd298b0.js";import{p as No,j as b}from"./jsx-runtime-0fbb5865.js";import{r as qn,R as nl}from"./index-ddd2a731.js";import{_ as z}from"./iframe-781efd05.js";import{d as ol}from"./index-356e4a49.js";import{d as sl}from"./dayjs.min-1b995edc.js";import{d as al,b as ll,c as hl,a as cl,k as ul,h as dl,f as fl,m as Pr}from"./_getTag-edecb89a.js";import{i as pl}from"./toString-25ea340b.js";import{C as gl}from"./Table-e1731fc3.js";import{c as ml}from"./parseCss-20e8fd4a.js";import{c as _l}from"./_color-087aa1f8.js";import{u as Do}from"./index-e6b2d23a.js";var yl="[object Map]",Cl="[object Set]",xl=Object.prototype,bl=xl.hasOwnProperty;function cr(t){if(t==null)return!0;if(al(t)&&(pl(t)||typeof t=="string"||typeof t.splice=="function"||ll(t)||hl(t)||cl(t)))return!t.length;var e=ul(t);if(e==yl||e==Cl)return!t.size;if(dl(t))return!fl(t).length;for(var i in t)if(bl.call(t,i))return!1;return!0}var zr={};Object.defineProperty(zr,"__esModule",{value:!0});var Ro=zr.sanitizeUrl=void 0,Tl=/^([^\w]*)(javascript|data|vbscript)/im,kl=/&#(\w+)(^\w|;)?/g,Sl=/&(newline|tab);/gi,vl=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,wl=/^.+(:|:)/gim,Bl=[".","/"];function Ll(t){return Bl.indexOf(t[0])>-1}function Fl(t){return t.replace(kl,function(e,i){return String.fromCharCode(i)})}function El(t){var e=Fl(t||"").replace(Sl,"").replace(vl,"").trim();if(!e)return"about:blank";if(Ll(e))return e;var i=e.match(wl);if(!i)return e;var r=i[0];return Tl.test(r)?"about:blank":e}Ro=zr.sanitizeUrl=El;var Al={value:()=>{}};function qo(){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}})}ri.prototype=qo.prototype={constructor:ri,on:function(t,e){var i=this._,r=Il(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)),Pn.hasOwnProperty(e)?{space:Pn[e],local:t}:t}function Ol(t){return function(){var e=this.ownerDocument,i=this.namespaceURI;return i===vr&&e.documentElement.namespaceURI===vr?e.createElement(t):e.createElementNS(i,t)}}function Nl(t){return function(){return this.ownerDocument.createElementNS(t.space,t.local)}}function $o(t){var e=Ni(t);return(e.local?Nl:Ol)(e)}function Dl(){}function Wr(t){return t==null?Dl:function(){return this.querySelector(t)}}function Rl(t){typeof t!="function"&&(t=Wr(t));for(var e=this._groups,i=e.length,r=new Array(i),n=0;n=A&&(A=C+1);!(W=F[A])&&++A<_;);R._next=W||null}}return s=new ot(s,r),s._enter=a,s._exit=l,s}function rh(t){return typeof t=="object"&&"length"in t?t:Array.from(t)}function nh(){return new ot(this._exit||this._groups.map(Ho),this._parents)}function oh(t,e,i){var r=this.enter(),n=this,o=this.exit();return typeof t=="function"?(r=t(r),r&&(r=r.selection())):r=r.append(t+""),e!=null&&(n=e(n),n&&(n=n.selection())),i==null?o.remove():i(o),r&&n?r.merge(n).order():n}function sh(t){for(var e=t.selection?t.selection():t,i=this._groups,r=e._groups,n=i.length,o=r.length,s=Math.min(n,o),a=new Array(n),l=0;l=0;)(s=r[n])&&(o&&s.compareDocumentPosition(o)^4&&o.parentNode.insertBefore(s,o),o=s);return this}function lh(t){t||(t=hh);function e(f,g){return f&&g?t(f.__data__,g.__data__):!f-!g}for(var i=this._groups,r=i.length,n=new Array(r),o=0;oe?1:t>=e?0:NaN}function ch(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}function uh(){return Array.from(this)}function dh(){for(var t=this._groups,e=0,i=t.length;e1?this.each((e==null?kh:typeof e=="function"?vh:Sh)(t,e,i??"")):oe(this.node(),t)}function oe(t,e){return t.style.getPropertyValue(e)||jo(t).getComputedStyle(t,null).getPropertyValue(e)}function Bh(t){return function(){delete this[t]}}function Lh(t,e){return function(){this[t]=e}}function Fh(t,e){return function(){var i=e.apply(this,arguments);i==null?delete this[t]:this[t]=i}}function Eh(t,e){return arguments.length>1?this.each((e==null?Bh:typeof e=="function"?Fh:Lh)(t,e)):this.node()[t]}function Uo(t){return t.trim().split(/^|\s+/)}function Hr(t){return t.classList||new Yo(t)}function Yo(t){this._node=t,this._names=Uo(t.getAttribute("class")||"")}Yo.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 Vo(t,e){for(var i=Hr(t),r=-1,n=e.length;++r=0&&(i=e.slice(r+1),e=e.slice(0,r)),{type:e,name:i}})}function nc(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?Ge(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):i===4?Ge(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=fc.exec(t))?new tt(e[1],e[2],e[3],1):(e=pc.exec(t))?new tt(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=gc.exec(t))?Ge(e[1],e[2],e[3],e[4]):(e=mc.exec(t))?Ge(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=_c.exec(t))?Vn(e[1],e[2]/100,e[3]/100,1):(e=yc.exec(t))?Vn(e[1],e[2]/100,e[3]/100,e[4]):zn.hasOwnProperty(t)?jn(zn[t]):t==="transparent"?new tt(NaN,NaN,NaN,0):null}function jn(t){return new tt(t>>16&255,t>>8&255,t&255,1)}function Ge(t,e,i,r){return r<=0&&(t=e=i=NaN),new tt(t,e,i,r)}function bc(t){return t instanceof $e||(t=Ee(t)),t?(t=t.rgb(),new tt(t.r,t.g,t.b,t.opacity)):new tt}function wr(t,e,i,r){return arguments.length===1?bc(t):new tt(t,e,i,r??1)}function tt(t,e,i,r){this.r=+t,this.g=+e,this.b=+i,this.opacity=+r}jr(tt,wr,Zo($e,{brighter(t){return t=t==null?_i:Math.pow(_i,t),new tt(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Le:Math.pow(Le,t),new tt(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new tt(Ht(this.r),Ht(this.g),Ht(this.b),yi(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:Un,formatHex:Un,formatHex8:Tc,formatRgb:Yn,toString:Yn}));function Un(){return`#${Wt(this.r)}${Wt(this.g)}${Wt(this.b)}`}function Tc(){return`#${Wt(this.r)}${Wt(this.g)}${Wt(this.b)}${Wt((isNaN(this.opacity)?1:this.opacity)*255)}`}function Yn(){const t=yi(this.opacity);return`${t===1?"rgb(":"rgba("}${Ht(this.r)}, ${Ht(this.g)}, ${Ht(this.b)}${t===1?")":`, ${t})`}`}function yi(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}function Ht(t){return Math.max(0,Math.min(255,Math.round(t)||0))}function Wt(t){return t=Ht(t),(t<16?"0":"")+t.toString(16)}function Vn(t,e,i,r){return r<=0?t=e=i=NaN:i<=0||i>=1?t=e=NaN:e<=0&&(t=NaN),new dt(t,e,i,r)}function Jo(t){if(t instanceof dt)return new dt(t.h,t.s,t.l,t.opacity);if(t instanceof $e||(t=Ee(t)),!t)return new dt;if(t instanceof dt)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 dt(s,a,l,t.opacity)}function kc(t,e,i,r){return arguments.length===1?Jo(t):new dt(t,e,i,r??1)}function dt(t,e,i,r){this.h=+t,this.s=+e,this.l=+i,this.opacity=+r}jr(dt,kc,Zo($e,{brighter(t){return t=t==null?_i:Math.pow(_i,t),new dt(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Le:Math.pow(Le,t),new dt(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 tt(ur(t>=240?t-240:t+120,n,r),ur(t,n,r),ur(t<120?t+240:t-120,n,r),this.opacity)},clamp(){return new dt(Gn(this.h),Xe(this.s),Xe(this.l),yi(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=yi(this.opacity);return`${t===1?"hsl(":"hsla("}${Gn(this.h)}, ${Xe(this.s)*100}%, ${Xe(this.l)*100}%${t===1?")":`, ${t})`}`}}));function Gn(t){return t=(t||0)%360,t<0?t+360:t}function Xe(t){return Math.max(0,Math.min(1,t||0))}function ur(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 Ur=t=>()=>t;function Qo(t,e){return function(i){return t+i*e}}function Sc(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 ny(t,e){var i=e-t;return i?Qo(t,i>180||i<-180?i-360*Math.round(i/360):i):Ur(isNaN(t)?e:t)}function vc(t){return(t=+t)==1?ts:function(e,i){return i-e?Sc(e,i,t):Ur(isNaN(e)?i:e)}}function ts(t,e){var i=e-t;return i?Qo(t,i):Ur(isNaN(t)?e:t)}const Xn=function t(e){var i=vc(e);function r(n,o){var s=i((n=wr(n)).r,(o=wr(o)).r),a=i(n.g,o.g),l=i(n.b,o.b),h=ts(n.opacity,o.opacity);return function(c){return n.r=s(c),n.g=a(c),n.b=l(c),n.opacity=h(c),n+""}}return r.gamma=t,r}(1);function Ot(t,e){return t=+t,e=+e,function(i){return t*(1-i)+e*i}}var Br=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,dr=new RegExp(Br.source,"g");function wc(t){return function(){return t}}function Bc(t){return function(e){return t(e)+""}}function Lc(t,e){var i=Br.lastIndex=dr.lastIndex=0,r,n,o,s=-1,a=[],l=[];for(t=t+"",e=e+"";(r=Br.exec(t))&&(n=dr.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:Ot(r,n)})),i=dr.lastIndex;return i180?c+=360:c-h>180&&(h+=360),g.push({i:f.push(n(f)+"rotate(",null,r)-2,x:Ot(h,c)})):c&&f.push(n(f)+"rotate("+c+r)}function a(h,c,f,g){h!==c?g.push({i:f.push(n(f)+"skewX(",null,r)-2,x:Ot(h,c)}):c&&f.push(n(f)+"skewX("+c+r)}function l(h,c,f,g,p,_){if(h!==f||c!==g){var k=p.push(n(p)+"scale(",null,",",null,")");_.push({i:k-4,x:Ot(h,f)},{i:k-2,x:Ot(c,g)})}else(f!==1||g!==1)&&p.push(n(p)+"scale("+f+","+g+")")}return function(h,c){var f=[],g=[];return h=t(h),c=t(c),o(h.translateX,h.translateY,c.translateX,c.translateY,f,g),s(h.rotate,c.rotate,f,g),a(h.skewX,c.skewX,f,g),l(h.scaleX,h.scaleY,c.scaleX,c.scaleY,f,g),h=c=null,function(p){for(var _=-1,k=g.length,F;++_=0&&t._call.call(void 0,e),t=t._next;--se}function Zn(){Yt=(xi=Ae.now())+Di,se=Te=0;try{Oc()}finally{se=0,Dc(),Yt=0}}function Nc(){var t=Ae.now(),e=t-xi;e>rs&&(Di-=e,xi=t)}function Dc(){for(var t,e=Ci,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:Ci=i);ke=t,Fr(r)}function Fr(t){if(!se){Te&&(Te=clearTimeout(Te));var e=t-Yt;e>24?(t<1/0&&(Te=setTimeout(Zn,t-Ae.now()-Di)),Ce&&(Ce=clearInterval(Ce))):(Ce||(xi=Ae.now(),Ce=setInterval(Nc,rs)),se=1,ns(Zn))}}function Jn(t,e,i){var r=new bi;return e=e==null?0:+e,r.restart(n=>{r.stop(),t(n+e)},e,i),r}var Rc=qo("start","end","cancel","interrupt"),qc=[],ss=0,Qn=1,Er=2,ni=3,to=4,Ar=5,oi=6;function Ri(t,e,i,r,n,o){var s=t.__transition;if(!s)t.__transition={};else if(i in s)return;$c(t,i,{name:e,index:r,group:n,on:Rc,tween:qc,time:o.time,delay:o.delay,duration:o.duration,ease:o.ease,timer:null,state:ss})}function Vr(t,e){var i=gt(t,e);if(i.state>ss)throw new Error("too late; already scheduled");return i}function bt(t,e){var i=gt(t,e);if(i.state>ni)throw new Error("too late; already running");return i}function gt(t,e){var i=t.__transition;if(!i||!(i=i[e]))throw new Error("transition not found");return i}function $c(t,e,i){var r=t.__transition,n;r[e]=i,i.timer=os(o,0,i.time);function o(h){i.state=Qn,i.timer.restart(s,i.delay,i.time),i.delay<=h&&s(h-i.delay)}function s(h){var c,f,g,p;if(i.state!==Qn)return l();for(c in r)if(p=r[c],p.name===i.name){if(p.state===ni)return Jn(s);p.state===to?(p.state=oi,p.timer.stop(),p.on.call("interrupt",t,t.__data__,p.index,p.group),delete r[c]):+cEr&&r.state=0&&(e=e.slice(0,i)),!e||e==="start"})}function mu(t,e,i){var r,n,o=gu(e)?Vr:bt;return function(){var s=o(this,t),a=s.on;a!==r&&(n=(r=a).copy()).on(e,i),s.on=n}}function _u(t,e){var i=this._id;return arguments.length<2?gt(this.node(),i).on.on(t):this.each(mu(i,t,e))}function yu(t){return function(){var e=this.parentNode;for(var i in this.__transition)if(+i!==t)return;e&&e.removeChild(this)}}function Cu(){return this.on("end.remove",yu(this._id))}function xu(t){var e=this._name,i=this._id;typeof t!="function"&&(t=Wr(t));for(var r=this._groups,n=r.length,o=new Array(n),s=0;s1?0:t<-1?Xr:Math.acos(t)}function py(t){return t>=1?io:t<=-1?-io:Math.asin(t)}function cs(t){this._context=t}cs.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 Uu(t){return new cs(t)}class us{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 Yu(t){return new us(t,!0)}function Vu(t){return new us(t,!1)}function Dt(){}function Ti(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 qi(t){this._context=t}qi.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:Ti(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:Ti(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Gu(t){return new qi(t)}function ds(t){this._context=t}ds.prototype={areaStart:Dt,areaEnd:Dt,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:Ti(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Xu(t){return new ds(t)}function fs(t){this._context=t}fs.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:Ti(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e}};function Ku(t){return new fs(t)}function ps(t,e){this._basis=new qi(t),this._beta=e}ps.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 Zu=function t(e){function i(r){return e===1?new qi(r):new ps(r,e)}return i.beta=function(r){return t(+r)},i}(.85);function ki(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 Kr(t,e){this._context=t,this._k=(1-e)/6}Kr.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:ki(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:ki(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 Ju=function t(e){function i(r){return new Kr(r,e)}return i.tension=function(r){return t(+r)},i}(0);function Zr(t,e){this._context=t,this._k=(1-e)/6}Zr.prototype={areaStart:Dt,areaEnd:Dt,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:ki(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 Qu=function t(e){function i(r){return new Zr(r,e)}return i.tension=function(r){return t(+r)},i}(0);function Jr(t,e){this._context=t,this._k=(1-e)/6}Jr.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:ki(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 td=function t(e){function i(r){return new Jr(r,e)}return i.tension=function(r){return t(+r)},i}(0);function Qr(t,e,i){var r=t._x1,n=t._y1,o=t._x2,s=t._y2;if(t._l01_a>eo){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>eo){var h=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,c=3*t._l23_a*(t._l23_a+t._l12_a);o=(o*h+t._x1*t._l23_2a-e*t._l12_2a)/c,s=(s*h+t._y1*t._l23_2a-i*t._l12_2a)/c}t._context.bezierCurveTo(r,n,o,s,t._x2,t._y2)}function gs(t,e){this._context=t,this._alpha=e}gs.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:Qr(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 ed=function t(e){function i(r){return e?new gs(r,e):new Kr(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function ms(t,e){this._context=t,this._alpha=e}ms.prototype={areaStart:Dt,areaEnd:Dt,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:Qr(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 id=function t(e){function i(r){return e?new ms(r,e):new Zr(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function _s(t,e){this._context=t,this._alpha=e}_s.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:Qr(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 rd=function t(e){function i(r){return e?new _s(r,e):new Jr(r,0)}return i.alpha=function(r){return t(+r)},i}(.5);function ys(t){this._context=t}ys.prototype={areaStart:Dt,areaEnd:Dt,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 nd(t){return new ys(t)}function ro(t){return t<0?-1:1}function no(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(ro(o)+ro(s))*Math.min(Math.abs(o),Math.abs(s),.5*Math.abs(a))||0}function oo(t,e){var i=t._x1-t._x0;return i?(3*(t._y1-t._y0)/i-e)/2:e}function fr(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 Si(t){this._context=t}Si.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:fr(this,this._t0,oo(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,fr(this,oo(this,i=no(this,t,e)),i);break;default:fr(this,this._t0,i=no(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=i}}};function Cs(t){this._context=new xs(t)}(Cs.prototype=Object.create(Si.prototype)).point=function(t,e){Si.prototype.point.call(this,e,t)};function xs(t){this._context=t}xs.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 od(t){return new Si(t)}function sd(t){return new Cs(t)}function bs(t){this._context=t}bs.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=so(t),n=so(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 ld(t){return new $i(t,.5)}function hd(t){return new $i(t,0)}function cd(t){return new $i(t,1)}function Se(t,e,i){this.k=t,this.x=e,this.y=i}Se.prototype={constructor:Se,scale:function(t){return t===1?this:new Se(this.k*t,this.x,this.y)},translate:function(t,e){return t===0&e===0?this:new Se(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+")"}};Se.prototype;/*! @license DOMPurify 3.0.5 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.5/LICENSE */const{entries:Ts,setPrototypeOf:ao,isFrozen:ud,getPrototypeOf:dd,getOwnPropertyDescriptor:fd}=Object;let{freeze:J,seal:pt,create:pd}=Object,{apply:Ir,construct:Mr}=typeof Reflect<"u"&&Reflect;Ir||(Ir=function(e,i,r){return e.apply(i,r)});J||(J=function(e){return e});pt||(pt=function(e){return e});Mr||(Mr=function(e,i){return new e(...i)});const gd=lt(Array.prototype.forEach),lo=lt(Array.prototype.pop),xe=lt(Array.prototype.push),si=lt(String.prototype.toLowerCase),pr=lt(String.prototype.toString),md=lt(String.prototype.match),ut=lt(String.prototype.replace),_d=lt(String.prototype.indexOf),yd=lt(String.prototype.trim),nt=lt(RegExp.prototype.test),be=Cd(TypeError);function lt(t){return function(e){for(var i=arguments.length,r=new Array(i>1?i-1:0),n=1;n/gm),Sd=pt(/\${[\w\W]*}/gm),vd=pt(/^data-[\-\w.\u00B7-\uFFFF]/),wd=pt(/^aria-[\-\w]+$/),ks=pt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Bd=pt(/^(?:\w+script|data):/i),Ld=pt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),Ss=pt(/^html$/i);var po=Object.freeze({__proto__:null,MUSTACHE_EXPR:Td,ERB_EXPR:kd,TMPLIT_EXPR:Sd,DATA_ATTR:vd,ARIA_ATTR:wd,IS_ALLOWED_URI:ks,IS_SCRIPT_OR_DATA:Bd,ATTR_WHITESPACE:Ld,DOCTYPE_NAME:Ss});const Fd=()=>typeof window>"u"?null:window,Ed=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}};function vs(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Fd();const e=S=>vs(S);if(e.version="3.0.5",e.removed=[],!t||!t.document||t.document.nodeType!==9)return e.isSupported=!1,e;const i=t.document,r=i.currentScript;let{document:n}=t;const{DocumentFragment:o,HTMLTemplateElement:s,Node:a,Element:l,NodeFilter:h,NamedNodeMap:c=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:f,DOMParser:g,trustedTypes:p}=t,_=l.prototype,k=Ze(_,"cloneNode"),F=Ze(_,"nextSibling"),I=Ze(_,"childNodes"),C=Ze(_,"parentNode");if(typeof s=="function"){const S=n.createElement("template");S.content&&S.content.ownerDocument&&(n=S.content.ownerDocument)}let A,R="";const{implementation:W,createNodeIterator:X,createDocumentFragment:M,getElementsByTagName:Ki}=n,{importNode:Zi}=i;let it={};e.isSupported=typeof Ts=="function"&&typeof C=="function"&&W&&W.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:fe,ERB_EXPR:pe,TMPLIT_EXPR:ge,DATA_ATTR:Tt,ARIA_ATTR:mn,IS_SCRIPT_OR_DATA:me,ATTR_WHITESPACE:rt}=po;let{IS_ALLOWED_URI:ze}=po,q=null;const _n=E({},[...ho,...gr,...mr,..._r,...co]);let H=null;const yn=E({},[...uo,...yr,...fo,...Je]);let D=Object.seal(Object.create(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}})),_e=null,Ji=null,Cn=!0,Qi=!0,xn=!1,bn=!0,Gt=!1,qt=!1,tr=!1,er=!1,Xt=!1,We=!1,He=!1,Tn=!0,kn=!1;const Ga="user-content-";let ir=!0,ye=!1,Kt={},Zt=null;const Sn=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 vn=null;const wn=E({},["audio","video","img","source","image","track"]);let rr=null;const Bn=E({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),je="http://www.w3.org/1998/Math/MathML",Ue="http://www.w3.org/2000/svg",kt="http://www.w3.org/1999/xhtml";let Jt=kt,nr=!1,or=null;const Xa=E({},[je,Ue,kt],pr);let $t;const Ka=["application/xhtml+xml","text/html"],Za="text/html";let j,Qt=null;const Ja=n.createElement("form"),Ln=function(u){return u instanceof RegExp||u instanceof Function},sr=function(u){if(!(Qt&&Qt===u)){if((!u||typeof u!="object")&&(u={}),u=te(u),$t=Ka.indexOf(u.PARSER_MEDIA_TYPE)===-1?$t=Za:$t=u.PARSER_MEDIA_TYPE,j=$t==="application/xhtml+xml"?pr:si,q="ALLOWED_TAGS"in u?E({},u.ALLOWED_TAGS,j):_n,H="ALLOWED_ATTR"in u?E({},u.ALLOWED_ATTR,j):yn,or="ALLOWED_NAMESPACES"in u?E({},u.ALLOWED_NAMESPACES,pr):Xa,rr="ADD_URI_SAFE_ATTR"in u?E(te(Bn),u.ADD_URI_SAFE_ATTR,j):Bn,vn="ADD_DATA_URI_TAGS"in u?E(te(wn),u.ADD_DATA_URI_TAGS,j):wn,Zt="FORBID_CONTENTS"in u?E({},u.FORBID_CONTENTS,j):Sn,_e="FORBID_TAGS"in u?E({},u.FORBID_TAGS,j):{},Ji="FORBID_ATTR"in u?E({},u.FORBID_ATTR,j):{},Kt="USE_PROFILES"in u?u.USE_PROFILES:!1,Cn=u.ALLOW_ARIA_ATTR!==!1,Qi=u.ALLOW_DATA_ATTR!==!1,xn=u.ALLOW_UNKNOWN_PROTOCOLS||!1,bn=u.ALLOW_SELF_CLOSE_IN_ATTR!==!1,Gt=u.SAFE_FOR_TEMPLATES||!1,qt=u.WHOLE_DOCUMENT||!1,Xt=u.RETURN_DOM||!1,We=u.RETURN_DOM_FRAGMENT||!1,He=u.RETURN_TRUSTED_TYPE||!1,er=u.FORCE_BODY||!1,Tn=u.SANITIZE_DOM!==!1,kn=u.SANITIZE_NAMED_PROPS||!1,ir=u.KEEP_CONTENT!==!1,ye=u.IN_PLACE||!1,ze=u.ALLOWED_URI_REGEXP||ks,Jt=u.NAMESPACE||kt,D=u.CUSTOM_ELEMENT_HANDLING||{},u.CUSTOM_ELEMENT_HANDLING&&Ln(u.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(D.tagNameCheck=u.CUSTOM_ELEMENT_HANDLING.tagNameCheck),u.CUSTOM_ELEMENT_HANDLING&&Ln(u.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(D.attributeNameCheck=u.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),u.CUSTOM_ELEMENT_HANDLING&&typeof u.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(D.allowCustomizedBuiltInElements=u.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),Gt&&(Qi=!1),We&&(Xt=!0),Kt&&(q=E({},[...co]),H=[],Kt.html===!0&&(E(q,ho),E(H,uo)),Kt.svg===!0&&(E(q,gr),E(H,yr),E(H,Je)),Kt.svgFilters===!0&&(E(q,mr),E(H,yr),E(H,Je)),Kt.mathMl===!0&&(E(q,_r),E(H,fo),E(H,Je))),u.ADD_TAGS&&(q===_n&&(q=te(q)),E(q,u.ADD_TAGS,j)),u.ADD_ATTR&&(H===yn&&(H=te(H)),E(H,u.ADD_ATTR,j)),u.ADD_URI_SAFE_ATTR&&E(rr,u.ADD_URI_SAFE_ATTR,j),u.FORBID_CONTENTS&&(Zt===Sn&&(Zt=te(Zt)),E(Zt,u.FORBID_CONTENTS,j)),ir&&(q["#text"]=!0),qt&&E(q,["html","head","body"]),q.table&&(E(q,["tbody"]),delete _e.tbody),u.TRUSTED_TYPES_POLICY){if(typeof u.TRUSTED_TYPES_POLICY.createHTML!="function")throw be('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof u.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw be('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');A=u.TRUSTED_TYPES_POLICY,R=A.createHTML("")}else A===void 0&&(A=Ed(p,r)),A!==null&&typeof R=="string"&&(R=A.createHTML(""));J&&J(u),Qt=u}},Fn=E({},["mi","mo","mn","ms","mtext"]),En=E({},["foreignobject","desc","title","annotation-xml"]),Qa=E({},["title","style","font","a","script"]),Ye=E({},gr);E(Ye,mr),E(Ye,xd);const ar=E({},_r);E(ar,bd);const tl=function(u){let m=C(u);(!m||!m.tagName)&&(m={namespaceURI:Jt,tagName:"template"});const x=si(u.tagName),O=si(m.tagName);return or[u.namespaceURI]?u.namespaceURI===Ue?m.namespaceURI===kt?x==="svg":m.namespaceURI===je?x==="svg"&&(O==="annotation-xml"||Fn[O]):!!Ye[x]:u.namespaceURI===je?m.namespaceURI===kt?x==="math":m.namespaceURI===Ue?x==="math"&&En[O]:!!ar[x]:u.namespaceURI===kt?m.namespaceURI===Ue&&!En[O]||m.namespaceURI===je&&!Fn[O]?!1:!ar[x]&&(Qa[x]||!Ye[x]):!!($t==="application/xhtml+xml"&&or[u.namespaceURI]):!1},Pt=function(u){xe(e.removed,{element:u});try{u.parentNode.removeChild(u)}catch{u.remove()}},lr=function(u,m){try{xe(e.removed,{attribute:m.getAttributeNode(u),from:m})}catch{xe(e.removed,{attribute:null,from:m})}if(m.removeAttribute(u),u==="is"&&!H[u])if(Xt||We)try{Pt(m)}catch{}else try{m.setAttribute(u,"")}catch{}},An=function(u){let m,x;if(er)u=""+u;else{const st=md(u,/^[\r\n\t ]+/);x=st&&st[0]}$t==="application/xhtml+xml"&&Jt===kt&&(u=''+u+"");const O=A?A.createHTML(u):u;if(Jt===kt)try{m=new g().parseFromString(O,$t)}catch{}if(!m||!m.documentElement){m=W.createDocument(Jt,"template",null);try{m.documentElement.innerHTML=nr?R:O}catch{}}const U=m.body||m.documentElement;return u&&x&&U.insertBefore(n.createTextNode(x),U.childNodes[0]||null),Jt===kt?Ki.call(m,qt?"html":"body")[0]:qt?m.documentElement:U},In=function(u){return X.call(u.ownerDocument||u,u,h.SHOW_ELEMENT|h.SHOW_COMMENT|h.SHOW_TEXT,null,!1)},el=function(u){return u instanceof f&&(typeof u.nodeName!="string"||typeof u.textContent!="string"||typeof u.removeChild!="function"||!(u.attributes instanceof c)||typeof u.removeAttribute!="function"||typeof u.setAttribute!="function"||typeof u.namespaceURI!="string"||typeof u.insertBefore!="function"||typeof u.hasChildNodes!="function")},Ve=function(u){return typeof a=="object"?u instanceof a:u&&typeof u=="object"&&typeof u.nodeType=="number"&&typeof u.nodeName=="string"},St=function(u,m,x){it[u]&&gd(it[u],O=>{O.call(e,m,x,Qt)})},Mn=function(u){let m;if(St("beforeSanitizeElements",u,null),el(u))return Pt(u),!0;const x=j(u.nodeName);if(St("uponSanitizeElement",u,{tagName:x,allowedTags:q}),u.hasChildNodes()&&!Ve(u.firstElementChild)&&(!Ve(u.content)||!Ve(u.content.firstElementChild))&&nt(/<[/\w]/g,u.innerHTML)&&nt(/<[/\w]/g,u.textContent))return Pt(u),!0;if(!q[x]||_e[x]){if(!_e[x]&&Nn(x)&&(D.tagNameCheck instanceof RegExp&&nt(D.tagNameCheck,x)||D.tagNameCheck instanceof Function&&D.tagNameCheck(x)))return!1;if(ir&&!Zt[x]){const O=C(u)||u.parentNode,U=I(u)||u.childNodes;if(U&&O){const st=U.length;for(let N=st-1;N>=0;--N)O.insertBefore(k(U[N],!0),F(u))}}return Pt(u),!0}return u instanceof l&&!tl(u)||(x==="noscript"||x==="noembed"||x==="noframes")&&nt(/<\/no(script|embed|frames)/i,u.innerHTML)?(Pt(u),!0):(Gt&&u.nodeType===3&&(m=u.textContent,m=ut(m,fe," "),m=ut(m,pe," "),m=ut(m,ge," "),u.textContent!==m&&(xe(e.removed,{element:u.cloneNode()}),u.textContent=m)),St("afterSanitizeElements",u,null),!1)},On=function(u,m,x){if(Tn&&(m==="id"||m==="name")&&(x in n||x in Ja))return!1;if(!(Qi&&!Ji[m]&&nt(Tt,m))){if(!(Cn&&nt(mn,m))){if(!H[m]||Ji[m]){if(!(Nn(u)&&(D.tagNameCheck instanceof RegExp&&nt(D.tagNameCheck,u)||D.tagNameCheck instanceof Function&&D.tagNameCheck(u))&&(D.attributeNameCheck instanceof RegExp&&nt(D.attributeNameCheck,m)||D.attributeNameCheck instanceof Function&&D.attributeNameCheck(m))||m==="is"&&D.allowCustomizedBuiltInElements&&(D.tagNameCheck instanceof RegExp&&nt(D.tagNameCheck,x)||D.tagNameCheck instanceof Function&&D.tagNameCheck(x))))return!1}else if(!rr[m]){if(!nt(ze,ut(x,rt,""))){if(!((m==="src"||m==="xlink:href"||m==="href")&&u!=="script"&&_d(x,"data:")===0&&vn[u])){if(!(xn&&!nt(me,ut(x,rt,"")))){if(x)return!1}}}}}}return!0},Nn=function(u){return u.indexOf("-")>0},Dn=function(u){let m,x,O,U;St("beforeSanitizeAttributes",u,null);const{attributes:st}=u;if(!st)return;const N={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:H};for(U=st.length;U--;){m=st[U];const{name:mt,namespaceURI:hr}=m;if(x=mt==="value"?m.value:yd(m.value),O=j(mt),N.attrName=O,N.attrValue=x,N.keepAttr=!0,N.forceKeepAttr=void 0,St("uponSanitizeAttribute",u,N),x=N.attrValue,N.forceKeepAttr||(lr(mt,u),!N.keepAttr))continue;if(!bn&&nt(/\/>/i,x)){lr(mt,u);continue}Gt&&(x=ut(x,fe," "),x=ut(x,pe," "),x=ut(x,ge," "));const Rn=j(u.nodeName);if(On(Rn,O,x)){if(kn&&(O==="id"||O==="name")&&(lr(mt,u),x=Ga+x),A&&typeof p=="object"&&typeof p.getAttributeType=="function"&&!hr)switch(p.getAttributeType(Rn,O)){case"TrustedHTML":{x=A.createHTML(x);break}case"TrustedScriptURL":{x=A.createScriptURL(x);break}}try{hr?u.setAttributeNS(hr,mt,x):u.setAttribute(mt,x),lo(e.removed)}catch{}}}St("afterSanitizeAttributes",u,null)},il=function S(u){let m;const x=In(u);for(St("beforeSanitizeShadowDOM",u,null);m=x.nextNode();)St("uponSanitizeShadowNode",m,null),!Mn(m)&&(m.content instanceof o&&S(m.content),Dn(m));St("afterSanitizeShadowDOM",u,null)};return e.sanitize=function(S){let u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},m,x,O,U;if(nr=!S,nr&&(S=""),typeof S!="string"&&!Ve(S))if(typeof S.toString=="function"){if(S=S.toString(),typeof S!="string")throw be("dirty is not a string, aborting")}else throw be("toString is not a function");if(!e.isSupported)return S;if(tr||sr(u),e.removed=[],typeof S=="string"&&(ye=!1),ye){if(S.nodeName){const mt=j(S.nodeName);if(!q[mt]||_e[mt])throw be("root node is forbidden and cannot be sanitized in-place")}}else if(S instanceof a)m=An(""),x=m.ownerDocument.importNode(S,!0),x.nodeType===1&&x.nodeName==="BODY"||x.nodeName==="HTML"?m=x:m.appendChild(x);else{if(!Xt&&!Gt&&!qt&&S.indexOf("<")===-1)return A&&He?A.createHTML(S):S;if(m=An(S),!m)return Xt?null:He?R:""}m&&er&&Pt(m.firstChild);const st=In(ye?S:m);for(;O=st.nextNode();)Mn(O)||(O.content instanceof o&&il(O.content),Dn(O));if(ye)return S;if(Xt){if(We)for(U=M.call(m.ownerDocument);m.firstChild;)U.appendChild(m.firstChild);else U=m;return(H.shadowroot||H.shadowrootmode)&&(U=Zi.call(i,U,!0)),U}let N=qt?m.outerHTML:m.innerHTML;return qt&&q["!doctype"]&&m.ownerDocument&&m.ownerDocument.doctype&&m.ownerDocument.doctype.name&&nt(Ss,m.ownerDocument.doctype.name)&&(N=" `+N),Gt&&(N=ut(N,fe," "),N=ut(N,pe," "),N=ut(N,ge," ")),A&&He?A.createHTML(N):N},e.setConfig=function(S){sr(S),tr=!0},e.clearConfig=function(){Qt=null,tr=!1},e.isValidAttribute=function(S,u,m){Qt||sr({});const x=j(S),O=j(u);return On(x,O,m)},e.addHook=function(S,u){typeof u=="function"&&(it[S]=it[S]||[],xe(it[S],u))},e.removeHook=function(S){if(it[S])return lo(it[S])},e.removeHooks=function(S){it[S]&&(it[S]=[])},e.removeAllHooks=function(){it={}},e}var vi=vs();const ai={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 ai.hue2rgb(o,n,t+1/3)*255;case"g":return ai.hue2rgb(o,n,t)*255;case"b":return ai.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},Md=Id,Od={dec2hex:t=>{const e=Math.round(t).toString(16);return e.length>1?e:`0${e}`}},Nd=Od,Dd={channel:Ad,lang:Md,unit:Nd},L=Dd,Mt={};for(let t=0;t<=255;t++)Mt[t]=L.unit.dec2hex(t);const Y={ALL:0,RGB:1,HSL:2};class Rd{constructor(){this.type=Y.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=Y.ALL}is(e){return this.type===e}}const qd=Rd;class $d{constructor(e,i){this.color=i,this.changed=!1,this.data=e,this.type=new qd}set(e,i){return this.color=i,this.changed=!1,this.data=e,this.type.type=Y.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(Y.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(Y.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(Y.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(Y.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(Y.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(Y.RGB)&&i!==void 0?i:(this._ensureRGB(),L.channel.rgb2hsl(e,"l"))}get a(){return this.data.a}set r(e){this.type.set(Y.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(Y.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(Y.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(Y.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(Y.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(Y.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}const Pd=$d,zd=new Pd({r:0,g:0,b:0,a:0},"transparent"),Pi=zd,ws={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:t=>{if(t.charCodeAt(0)!==35)return;const e=t.match(ws.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,c=s?255:15;return Pi.set({r:(r>>l*(h+3)&c)*a,g:(r>>l*(h+2)&c)*a,b:(r>>l*(h+1)&c)*a,a:o?(r&c)*a/255:1},t)},stringify:t=>{const{r:e,g:i,b:r,a:n}=t;return n<1?`#${Mt[Math.round(e)]}${Mt[Math.round(i)]}${Mt[Math.round(r)]}${Mt[Math.round(n*255)]}`:`#${Mt[Math.round(e)]}${Mt[Math.round(i)]}${Mt[Math.round(r)]}`}},ve=ws,li={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(li.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(li.re);if(!i)return;const[,r,n,o,s,a]=i;return Pi.set({h:li._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)}%)`}},Qe=li,hi={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=hi.colors[t];if(e)return ve.parse(e)},stringify:t=>{const e=ve.stringify(t);for(const i in hi.colors)if(hi.colors[i]===e)return i}},go=hi,Bs={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(Bs.re);if(!i)return;const[,r,n,o,s,a,l,h,c]=i;return Pi.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(c?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)})`}},ti=Bs,Wd={format:{keyword:go,hex:ve,rgb:ti,rgba:ti,hsl:Qe,hsla:Qe},parse:t=>{if(typeof t!="string")return t;const e=ve.parse(t)||ti.parse(t)||Qe.parse(t)||go.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},stringify:t=>!t.changed&&t.color?t.color:t.type.is(Y.HSL)||t.data.r===void 0?Qe.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?ti.stringify(t):ve.stringify(t)},xt=Wd,Hd=(t,e)=>{const i=xt.parse(t);for(const r in e)i[r]=L.channel.clamp[r](e[r]);return xt.stringify(i)},Ls=Hd,jd=(t,e,i=0,r=1)=>{if(typeof t!="number")return Ls(t,{a:e});const n=Pi.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 xt.stringify(n)},we=jd,Ud=t=>{const{r:e,g:i,b:r}=xt.parse(t),n=.2126*L.channel.toLinear(e)+.7152*L.channel.toLinear(i)+.0722*L.channel.toLinear(r);return L.lang.round(n)},Yd=Ud,Vd=t=>Yd(t)>=.5,Gd=Vd,Xd=t=>!Gd(t),Pe=Xd,Kd=(t,e,i)=>{const r=xt.parse(t),n=r[e],o=L.channel.clamp[e](n+i);return n!==o&&(r[e]=o),xt.stringify(r)},Fs=Kd,Zd=(t,e)=>Fs(t,"l",e),v=Zd,Jd=(t,e)=>Fs(t,"l",-e),B=Jd,Qd=(t,e)=>{const i=xt.parse(t),r={};for(const n in e)e[n]&&(r[n]=i[n]+e[n]);return Ls(t,r)},d=Qd,tf=(t,e,i=50)=>{const{r,g:n,b:o,a:s}=xt.parse(t),{r:a,g:l,b:h,a:c}=xt.parse(e),f=i/100,g=f*2-1,p=s-c,k=((g*p===-1?g:(g+p)/(1+g*p))+1)/2,F=1-k,I=r*k+a*F,C=n*k+l*F,A=o*k+h*F,R=s*f+c*(1-f);return we(I,C,A,R)},ef=tf,rf=(t,e=100)=>{const i=xt.parse(t);return i.r=255-i.r,i.g=255-i.g,i.b=255-i.b,ef(i,t,e)},y=rf;var Es="comm",As="rule",Is="decl",nf="@import",of="@keyframes",sf="@layer",af=Math.abs,tn=String.fromCharCode;function Ms(t){return t.trim()}function ci(t,e,i){return t.replace(e,i)}function lf(t,e){return t.indexOf(e)}function Ie(t,e){return t.charCodeAt(e)|0}function Me(t,e,i){return t.slice(e,i)}function Bt(t){return t.length}function hf(t){return t.length}function ei(t,e){return e.push(t),t}var zi=1,ae=1,Os=0,ht=0,$=0,de="";function en(t,e,i,r,n,o,s,a){return{value:t,root:e,parent:i,type:r,props:n,children:o,line:zi,column:ae,length:s,return:"",siblings:a}}function cf(){return $}function uf(){return $=ht>0?Ie(de,--ht):0,ae--,$===10&&(ae=1,zi--),$}function ft(){return $=ht2||Or($)>3?"":" "}function gf(t,e){for(;--e&&ft()&&!($<48||$>102||$>57&&$<65||$>70&&$<97););return Wi(t,ui()+(e<6&&jt()==32&&ft()==32))}function Nr(t){for(;ft();)switch($){case t:return ht;case 34:case 39:t!==34&&t!==39&&Nr($);break;case 40:t===41&&Nr(t);break;case 92:ft();break}return ht}function mf(t,e){for(;ft()&&t+$!==47+10;)if(t+$===42+42&&jt()===47)break;return"/*"+Wi(e,ht-1)+"*"+tn(t===47?t:ft())}function _f(t){for(;!Or(jt());)ft();return Wi(t,ht)}function yf(t){return ff(di("",null,null,null,[""],t=df(t),0,[0],t))}function di(t,e,i,r,n,o,s,a,l){for(var h=0,c=0,f=s,g=0,p=0,_=0,k=1,F=1,I=1,C=0,A="",R=n,W=o,X=r,M=A;F;)switch(_=C,C=ft()){case 40:if(_!=108&&Ie(M,f-1)==58){lf(M+=ci(Cr(C),"&","&\f"),"&\f")!=-1&&(I=-1);break}case 34:case 39:case 91:M+=Cr(C);break;case 9:case 10:case 13:case 32:M+=pf(_);break;case 92:M+=gf(ui()-1,7);continue;case 47:switch(jt()){case 42:case 47:ei(Cf(mf(ft(),ui()),e,i,l),l);break;default:M+="/"}break;case 123*k:a[h++]=Bt(M)*I;case 125*k:case 59:case 0:switch(C){case 0:case 125:F=0;case 59+c:I==-1&&(M=ci(M,/\f/g,"")),p>0&&Bt(M)-f&&ei(p>32?_o(M+";",r,i,f-1,l):_o(ci(M," ","")+";",r,i,f-2,l),l);break;case 59:M+=";";default:if(ei(X=mo(M,e,i,h,c,n,a,A,R=[],W=[],f,o),o),C===123)if(c===0)di(M,e,X,X,R,o,f,a,W);else switch(g===99&&Ie(M,3)===110?100:g){case 100:case 108:case 109:case 115:di(t,X,X,r&&ei(mo(t,X,X,0,0,n,a,A,n,R=[],f,W),W),n,W,f,a,r?R:W);break;default:di(M,X,X,X,[""],W,0,a,W)}}h=c=p=0,k=I=1,A=M="",f=s;break;case 58:f=1+Bt(M),p=_;default:if(k<1){if(C==123)--k;else if(C==125&&k++==0&&uf()==125)continue}switch(M+=tn(C),C*k){case 38:I=c>0?1:(M+="\f",-1);break;case 44:a[h++]=(Bt(M)-1)*I,I=1;break;case 64:jt()===45&&(M+=Cr(ft())),g=jt(),c=f=Bt(A=M+=_f(ui())),C++;break;case 45:_===45&&Bt(M)==2&&(k=0)}}return o}function mo(t,e,i,r,n,o,s,a,l,h,c,f){for(var g=n-1,p=n===0?o:[""],_=hf(p),k=0,F=0,I=0;k0?p[C]+" "+A:ci(A,/&\f/g,p[C])))&&(l[I++]=R);return en(t,e,i,n===0?As:a,l,h,c,f)}function Cf(t,e,i,r){return en(t,e,i,Es,tn(cf()),Me(t,2,-2),0,r)}function _o(t,e,i,r,n){return en(t,e,i,Is,Me(t,0,r),Me(t,r+1,-1),r,n)}function Dr(t,e){for(var i="",r=0;r{},debug:(...t)=>{},info:(...t)=>{},warn:(...t)=>{},error:(...t)=>{},fatal:(...t)=>{}},rn=function(t="fatal"){let e=wt.fatal;typeof t=="string"?(t=t.toLowerCase(),t in wt&&(e=wt[t])):typeof t=="number"&&(e=t),T.trace=()=>{},T.debug=()=>{},T.info=()=>{},T.warn=()=>{},T.error=()=>{},T.fatal=()=>{},e<=wt.fatal&&(T.fatal=console.error?console.error.bind(console,at("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",at("FATAL"))),e<=wt.error&&(T.error=console.error?console.error.bind(console,at("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",at("ERROR"))),e<=wt.warn&&(T.warn=console.warn?console.warn.bind(console,at("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",at("WARN"))),e<=wt.info&&(T.info=console.info?console.info.bind(console,at("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",at("INFO"))),e<=wt.debug&&(T.debug=console.debug?console.debug.bind(console,at("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",at("DEBUG"))),e<=wt.trace&&(T.trace=console.debug?console.debug.bind(console,at("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",at("TRACE")))},at=t=>`%c${sl().format("ss.SSS")} : ${t} : `,Hi=//gi,bf=t=>t?Ds(t).replace(/\\n/g,"#br#").split("#br#"):[""],Ns=t=>vi.sanitize(t),yo=(t,e)=>{var i;if(((i=e.flowchart)==null?void 0:i.htmlLabels)!==!1){const r=e.securityLevel;r==="antiscript"||r==="strict"?t=Ns(t):r!=="loose"&&(t=Ds(t),t=t.replace(//g,">"),t=t.replace(/=/g,"="),t=vf(t))}return t},Oe=(t,e)=>t&&(e.dompurifyConfig?t=vi.sanitize(yo(t,e),e.dompurifyConfig).toString():t=vi.sanitize(yo(t,e),{FORBID_TAGS:["style"]}).toString(),t),Tf=(t,e)=>typeof t=="string"?Oe(t,e):t.flat().map(i=>Oe(i,e)),kf=t=>Hi.test(t),Sf=t=>t.split(Hi),vf=t=>t.replace(/#br#/g,"
"),Ds=t=>t.replace(Hi,"#br#"),wf=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},Rs=t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),Bf=function(...t){const e=t.filter(i=>!isNaN(i));return Math.max(...e)},Lf=function(...t){const e=t.filter(i=>!isNaN(i));return Math.min(...e)},Ff=function(t){let e=t;if(t.split("~").length-1>=2){let i=e;do e=i,i=e.replace(/~([^\s,:;]+)~/,"<$1>");while(i!=e);return Ff(i)}else return e},nn={getRows:bf,sanitizeText:Oe,sanitizeTextOrArray:Tf,hasBreaks:kf,splitBreaks:Sf,lineBreakRegex:Hi,removeScript:Ns,getUrl:wf,evaluate:Rs,getMax:Bf,getMin:Lf},Z=(t,e)=>e?d(t,{s:-40,l:10}):d(t,{s:-40,l:-10}),ji="#ffffff",Ui="#f2f2f2";let Ef=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(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||d(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||d(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||Z(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||Z(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||Z(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||Z(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||y(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||y(this.tertiaryColor),this.lineColor=this.lineColor||y(this.background),this.arrowheadColor=this.arrowheadColor||y(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?B(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||B(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||y(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||v(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||d(this.primaryColor,{h:30}),this.cScale4=this.cScale4||d(this.primaryColor,{h:60}),this.cScale5=this.cScale5||d(this.primaryColor,{h:90}),this.cScale6=this.cScale6||d(this.primaryColor,{h:120}),this.cScale7=this.cScale7||d(this.primaryColor,{h:150}),this.cScale8=this.cScale8||d(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||d(this.primaryColor,{h:270}),this.cScale10=this.cScale10||d(this.primaryColor,{h:300}),this.cScale11=this.cScale11||d(this.primaryColor,{h:330}),this.darkMode)for(let i=0;i{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Af=t=>{const e=new Ef;return e.calculate(t),e};let If=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=v(this.primaryColor,16),this.tertiaryColor=d(this.primaryColor,{h:-160}),this.primaryBorderColor=y(this.background),this.secondaryBorderColor=Z(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Z(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=v(y("#323D47"),10),this.lineColor="calculated",this.border1="#81B1DB",this.border2=we(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=B("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=B(this.sectionBkgColor,10),this.taskBorderColor=we(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=we(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(){this.secondBkg=v(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=v(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=v(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=d(this.primaryColor,{h:64}),this.fillType3=d(this.secondaryColor,{h:64}),this.fillType4=d(this.primaryColor,{h:-64}),this.fillType5=d(this.secondaryColor,{h:-64}),this.fillType6=d(this.primaryColor,{h:128}),this.fillType7=d(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||d(this.primaryColor,{h:30}),this.cScale4=this.cScale4||d(this.primaryColor,{h:60}),this.cScale5=this.cScale5||d(this.primaryColor,{h:90}),this.cScale6=this.cScale6||d(this.primaryColor,{h:120}),this.cScale7=this.cScale7||d(this.primaryColor,{h:150}),this.cScale8=this.cScale8||d(this.primaryColor,{h:210}),this.cScale9=this.cScale9||d(this.primaryColor,{h:270}),this.cScale10=this.cScale10||d(this.primaryColor,{h:300}),this.cScale11=this.cScale11||d(this.primaryColor,{h:330});for(let e=0;e{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Mf=t=>{const e=new If;return e.calculate(t),e};let Of=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=d(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=d(this.primaryColor,{h:-160}),this.primaryBorderColor=Z(this.primaryColor,this.darkMode),this.secondaryBorderColor=Z(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Z(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(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=we(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(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||d(this.primaryColor,{h:30}),this.cScale4=this.cScale4||d(this.primaryColor,{h:60}),this.cScale5=this.cScale5||d(this.primaryColor,{h:90}),this.cScale6=this.cScale6||d(this.primaryColor,{h:120}),this.cScale7=this.cScale7||d(this.primaryColor,{h:150}),this.cScale8=this.cScale8||d(this.primaryColor,{h:210}),this.cScale9=this.cScale9||d(this.primaryColor,{h:270}),this.cScale10=this.cScale10||d(this.primaryColor,{h:300}),this.cScale11=this.cScale11||d(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||B(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||B(this.tertiaryColor,40);for(let e=0;e{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Nf=t=>{const e=new Of;return e.calculate(t),e};let Df=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=v("#cde498",10),this.primaryBorderColor=Z(this.primaryColor,this.darkMode),this.secondaryBorderColor=Z(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Z(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.primaryColor),this.lineColor=y(this.background),this.textColor=y(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(){this.actorBorder=B(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||d(this.primaryColor,{h:30}),this.cScale4=this.cScale4||d(this.primaryColor,{h:60}),this.cScale5=this.cScale5||d(this.primaryColor,{h:90}),this.cScale6=this.cScale6||d(this.primaryColor,{h:120}),this.cScale7=this.cScale7||d(this.primaryColor,{h:150}),this.cScale8=this.cScale8||d(this.primaryColor,{h:210}),this.cScale9=this.cScale9||d(this.primaryColor,{h:270}),this.cScale10=this.cScale10||d(this.primaryColor,{h:300}),this.cScale11=this.cScale11||d(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||B(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||B(this.tertiaryColor,40);for(let e=0;e{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Rf=t=>{const e=new Df;return e.calculate(t),e};class qf{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=v(this.contrast,55),this.background="#ffffff",this.tertiaryColor=d(this.primaryColor,{h:-160}),this.primaryBorderColor=Z(this.primaryColor,this.darkMode),this.secondaryBorderColor=Z(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=Z(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(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(){this.secondBkg=v(this.contrast,55),this.border2=this.contrast,this.actorBorder=v(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 e=0;e{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}}const $f=t=>{const e=new qf;return e.calculate(t),e},Ft={base:{getThemeVariables:Af},dark:{getThemeVariables:Mf},default:{getThemeVariables:Nf},forest:{getThemeVariables:Rf},neutral:{getThemeVariables:$f}},It={flowchart:{useMaxWidth:!0,titleTopMargin:25,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},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,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"},theme:"default",maxTextSize:5e4,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize"],deterministicIds:!1,fontSize:16},qs={...It,deterministicIDSeed:void 0,themeCSS:void 0,themeVariables:Ft.default.getThemeVariables(),sequence:{...It.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:{...It.gantt,tickInterval:void 0,useWidth:void 0},c4:{...It.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:{...It.pie,useWidth:void 0},requirement:{...It.requirement,useWidth:void 0},gitGraph:{...It.gitGraph,useMaxWidth:!1},sankey:{...It.sankey,useMaxWidth:!1}},$s=(t,e="")=>Object.keys(t).reduce((i,r)=>Array.isArray(t[r])?i:typeof t[r]=="object"&&t[r]!==null?[...i,e+r,...$s(t[r],"")]:[...i,e+r],[]),Pf=$s(qs,""),zf=qs;/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function Ps(t){return typeof t>"u"||t===null}function Wf(t){return typeof t=="object"&&t!==null}function Hf(t){return Array.isArray(t)?t:Ps(t)?[]:[t]}function jf(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 br(t,e){return K.repeat(" ",e-t.length)+t}function Qf(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,c=Math.min(t.line+e.linesAfter,n.length).toString().length,f=e.maxLength-(e.indent+c+3);for(l=1;l<=e.linesBefore&&!(s-l<0);l++)h=xr(t.buffer,r[s-l],n[s-l],t.position-(r[s]-r[s-l]),f),a=K.repeat(" ",e.indent)+br((t.line-l+1).toString(),c)+" | "+h.str+` `+a;for(h=xr(t.buffer,r[s],n[s],t.position,f),a+=K.repeat(" ",e.indent)+br((t.line+1).toString(),c)+" | "+h.str+` `,a+=K.repeat("-",e.indent+c+3+h.pos)+`^ `,l=1;l<=e.linesAfter&&!(s+l>=n.length);l++)h=xr(t.buffer,r[s+l],n[s+l],t.position-(r[s]-r[s+l]),f),a+=K.repeat(" ",e.indent)+br((t.line+l+1).toString(),c)+" | "+h.str+` `;return a.replace(/\n$/,"")}var tp=Qf,ep=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],ip=["scalar","sequence","mapping"];function rp(t){var e={};return t!==null&&Object.keys(t).forEach(function(i){t[i].forEach(function(r){e[String(r)]=i})}),e}function np(t,e){if(e=e||{},Object.keys(e).forEach(function(i){if(ep.indexOf(i)===-1)throw new Lt('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=rp(e.styleAliases||null),ip.indexOf(this.kind)===-1)throw new Lt('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var G=np;function Co(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 op(){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"]}}),vp=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function wp(t){return!(t===null||!vp.test(t)||t[t.length-1]==="_")}function Bp(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 Lp=/^[-+]?[0-9]+e/;function Fp(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(K.isNegativeZero(t))return"-0.0";return i=t.toString(10),Lp.test(i)?i.replace("e",".e"):i}function Ep(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||K.isNegativeZero(t))}var Ap=new G("tag:yaml.org,2002:float",{kind:"scalar",resolve:wp,construct:Bp,predicate:Ep,represent:Fp,defaultStyle:"lowercase"}),Ip=Ws.extend({implicit:[fp,_p,Sp,Ap]}),Mp=Ip,Hs=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),js=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 Op(t){return t===null?!1:Hs.exec(t)!==null||js.exec(t)!==null}function Np(t){var e,i,r,n,o,s,a,l=0,h=null,c,f,g;if(e=Hs.exec(t),e===null&&(e=js.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]&&(c=+e[10],f=+(e[11]||0),h=(c*60+f)*6e4,e[9]==="-"&&(h=-h)),g=new Date(Date.UTC(i,r,n,o,s,a,l)),h&&g.setTime(g.getTime()-h),g}function Dp(t){return t.toISOString()}var Rp=new G("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:Op,construct:Np,instanceOf:Date,represent:Dp});function qp(t){return t==="<<"||t===null}var $p=new G("tag:yaml.org,2002:merge",{kind:"scalar",resolve:qp}),on=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= \r`;function Pp(t){if(t===null)return!1;var e,i,r=0,n=t.length,o=on;for(i=0;i64)){if(e<0)return!1;r+=6}return r%8===0}function zp(t){var e,i,r=t.replace(/[\r\n=]/g,""),n=r.length,o=on,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 Wp(t){var e="",i=0,r,n,o=t.length,s=on;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 Hp(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var jp=new G("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Pp,construct:zp,predicate:Hp,represent:Wp}),Up=Object.prototype.hasOwnProperty,Yp=Object.prototype.toString;function Vp(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 Xs=new Array(256),Ks=new Array(256);for(var ee=0;ee<256;ee++)Xs[ee]=To(ee)?1:0,Ks[ee]=To(ee);function fg(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||ng,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 Zs(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=tp(i),new Lt(e,i)}function w(t,e){throw Zs(t,e)}function Li(t,e){t.onWarning&&t.onWarning.call(null,Zs(t,e))}var ko={YAML:function(e,i,r){var n,o,s;e.version!==null&&w(e,"duplication of %YAML directive"),r.length!==1&&w(e,"YAML directive accepts exactly one argument"),n=/^([0-9]+)\.([0-9]+)$/.exec(r[0]),n===null&&w(e,"ill-formed argument of the YAML directive"),o=parseInt(n[1],10),s=parseInt(n[2],10),o!==1&&w(e,"unacceptable YAML version of the document"),e.version=r[0],e.checkLineBreaks=s<2,s!==1&&s!==2&&Li(e,"unsupported YAML version of the document")},TAG:function(e,i,r){var n,o;r.length!==2&&w(e,"TAG directive accepts exactly two arguments"),n=r[0],o=r[1],Vs.test(n)||w(e,"ill-formed tag handle (first argument) of the TAG directive"),Rt.call(e.tagMap,n)&&w(e,'there is a previously declared suffix for "'+n+'" tag handle'),Gs.test(o)||w(e,"ill-formed tag prefix (second argument) of the TAG directive");try{o=decodeURIComponent(o)}catch{w(e,"tag prefix is malformed: "+o)}e.tagMap[n]=o}};function Nt(t,e,i,r){var n,o,s,a;if(e1&&(t.result+=K.repeat(` `,e-1))}function pg(t,e,i){var r,n,o,s,a,l,h,c,f=t.kind,g=t.result,p;if(p=t.input.charCodeAt(t.position),et(p)||ie(p)||p===35||p===38||p===42||p===33||p===124||p===62||p===39||p===34||p===37||p===64||p===96||(p===63||p===45)&&(n=t.input.charCodeAt(t.position+1),et(n)||i&&ie(n)))return!1;for(t.kind="scalar",t.result="",o=s=t.position,a=!1;p!==0;){if(p===58){if(n=t.input.charCodeAt(t.position+1),et(n)||i&&ie(n))break}else if(p===35){if(r=t.input.charCodeAt(t.position-1),et(r))break}else{if(t.position===t.lineStart&&Yi(t)||i&&ie(p))break;if(Ct(p))if(l=t.line,h=t.lineStart,c=t.lineIndent,P(t,!1,-1),t.lineIndent>=e){a=!0,p=t.input.charCodeAt(t.position);continue}else{t.position=s,t.line=l,t.lineStart=h,t.lineIndent=c;break}}a&&(Nt(t,o,s,!1),an(t,t.line-l),o=s=t.position,a=!1),Ut(p)||(s=t.position+1),p=t.input.charCodeAt(++t.position)}return Nt(t,o,s,!1),t.result?!0:(t.kind=f,t.result=g,!1)}function gg(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(Nt(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 Ct(i)?(Nt(t,r,n,!0),an(t,P(t,!1,e)),r=n=t.position):t.position===t.lineStart&&Yi(t)?w(t,"unexpected end of the document within a single quoted scalar"):(t.position++,n=t.position);w(t,"unexpected end of the stream within a single quoted scalar")}function mg(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 Nt(t,i,t.position,!0),t.position++,!0;if(a===92){if(Nt(t,i,t.position,!0),a=t.input.charCodeAt(++t.position),Ct(a))P(t,!1,e);else if(a<256&&Xs[a])t.result+=Ks[a],t.position++;else if((s=cg(a))>0){for(n=s,o=0;n>0;n--)a=t.input.charCodeAt(++t.position),(s=hg(a))>=0?o=(o<<4)+s:w(t,"expected hexadecimal character");t.result+=dg(o),t.position++}else w(t,"unknown escape sequence");i=r=t.position}else Ct(a)?(Nt(t,i,r,!0),an(t,P(t,!1,e)),i=r=t.position):t.position===t.lineStart&&Yi(t)?w(t,"unexpected end of the document within a double quoted scalar"):(t.position++,r=t.position)}w(t,"unexpected end of the stream within a double quoted scalar")}function _g(t,e){var i=!0,r,n,o,s=t.tag,a,l=t.anchor,h,c,f,g,p,_=Object.create(null),k,F,I,C;if(C=t.input.charCodeAt(t.position),C===91)c=93,p=!1,a=[];else if(C===123)c=125,p=!0,a={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=a),C=t.input.charCodeAt(++t.position);C!==0;){if(P(t,!0,e),C=t.input.charCodeAt(t.position),C===c)return t.position++,t.tag=s,t.anchor=l,t.kind=p?"mapping":"sequence",t.result=a,!0;i?C===44&&w(t,"expected the node content, but found ','"):w(t,"missed comma between flow collection entries"),F=k=I=null,f=g=!1,C===63&&(h=t.input.charCodeAt(t.position+1),et(h)&&(f=g=!0,t.position++,P(t,!0,e))),r=t.line,n=t.lineStart,o=t.position,le(t,e,wi,!1,!0),F=t.tag,k=t.result,P(t,!0,e),C=t.input.charCodeAt(t.position),(g||t.line===r)&&C===58&&(f=!0,C=t.input.charCodeAt(++t.position),P(t,!0,e),le(t,e,wi,!1,!0),I=t.result),p?re(t,a,_,F,k,I,r,n,o):f?a.push(re(t,null,_,F,k,I,r,n,o)):a.push(k),P(t,!0,e),C=t.input.charCodeAt(t.position),C===44?(i=!0,C=t.input.charCodeAt(++t.position)):i=!1}w(t,"unexpected end of the stream within a flow collection")}function yg(t,e){var i,r,n=Tr,o=!1,s=!1,a=e,l=0,h=!1,c,f;if(f=t.input.charCodeAt(t.position),f===124)r=!1;else if(f===62)r=!0;else return!1;for(t.kind="scalar",t.result="";f!==0;)if(f=t.input.charCodeAt(++t.position),f===43||f===45)Tr===n?n=f===43?xo:og:w(t,"repeat of a chomping mode identifier");else if((c=ug(f))>=0)c===0?w(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):s?w(t,"repeat of an indentation width identifier"):(a=e+c-1,s=!0);else break;if(Ut(f)){do f=t.input.charCodeAt(++t.position);while(Ut(f));if(f===35)do f=t.input.charCodeAt(++t.position);while(!Ct(f)&&f!==0)}for(;f!==0;){for(sn(t),t.lineIndent=0,f=t.input.charCodeAt(t.position);(!s||t.lineIndenta&&(a=t.lineIndent),Ct(f)){l++;continue}if(t.lineIndente)&&l!==0)w(t,"bad indentation of a sequence entry");else if(t.lineIndente)&&(F&&(s=t.line,a=t.lineStart,l=t.position),le(t,e,Bi,!0,n)&&(F?_=t.result:k=t.result),F||(re(t,f,g,p,_,k,s,a,l),p=_=k=null),P(t,!0,-1),C=t.input.charCodeAt(t.position)),(t.line===o||t.lineIndent>e)&&C!==0)w(t,"bad indentation of a mapping entry");else if(t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndente?l=1:t.lineIndent===e?l=0:t.lineIndent tag; it should be "scalar", not "'+t.kind+'"'),f=0,g=t.implicitTypes.length;f"),t.result!==null&&_.kind!==t.kind&&w(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+_.kind+'", not "'+t.kind+'"'),_.resolve(t.result,t.tag)?(t.result=_.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):w(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||c}function kg(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&&(P(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&&!et(s);)s=t.input.charCodeAt(++t.position);for(r=t.input.slice(i,t.position),n=[],r.length<1&&w(t,"directive name must not be less than one character in length");s!==0;){for(;Ut(s);)s=t.input.charCodeAt(++t.position);if(s===35){do s=t.input.charCodeAt(++t.position);while(s!==0&&!Ct(s));break}if(Ct(s))break;for(i=t.position;s!==0&&!et(s);)s=t.input.charCodeAt(++t.position);n.push(t.input.slice(i,t.position))}s!==0&&sn(t),Rt.call(ko,r)?ko[r](t,r,n):Li(t,'unknown document directive "'+r+'"')}if(P(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,P(t,!0,-1)):o&&w(t,"directives end mark is expected"),le(t,t.lineIndent-1,Bi,!1,!0),P(t,!0,-1),t.checkLineBreaks&&ag.test(t.input.slice(e,t.position))&&Li(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Yi(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,P(t,!0,-1));return}if(t.position"u"&&(i=e,e=null);var r=Js(t,i);if(typeof e!="function")return r;for(var n=0,o=r.length;nqr(t,o,i)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(o=>{t.includes(o)||t.push(o)}),t):t===void 0||r<=0?t!=null&&typeof t=="object"&&typeof e=="object"?Object.assign(t,e):e:(e!==void 0&&typeof t=="object"&&typeof e=="object"&&Object.keys(e).forEach(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]=qr(t[o],e[o],{depth:r-1,clobber:n})):(n||typeof t[o]!="object"&&typeof e[o]!="object")&&(t[o]=e[o])}),t)},V=qr,De=Object.freeze(zf);let Q=V({},De),ta,he=[],Be=V({},De);const Vi=(t,e)=>{let i=V({},t),r={};for(const n of e)ia(n),r=V(r,n);if(i=V(i,r),r.theme&&r.theme in Ft){const n=V({},ta),o=V(n.themeVariables||{},r.themeVariables);i.theme&&i.theme in Ft&&(i.themeVariables=Ft[i.theme].getThemeVariables(o))}return Be=i,na(Be),Be},Ig=t=>(Q=V({},De),Q=V(Q,t),t.theme&&Ft[t.theme]&&(Q.themeVariables=Ft[t.theme].getThemeVariables(t.themeVariables)),Vi(Q,he),Q),Mg=t=>{ta=V({},t)},Og=t=>(Q=V(Q,t),Vi(Q,he),Q),ea=()=>V({},Q),Ng=t=>(na(t),V(Be,t),At()),At=()=>V({},Be),ia=t=>{["secure",...Q.secure??[]].forEach(e=>{t[e]!==void 0&&(T.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])}),Object.keys(t).forEach(e=>{e.indexOf("__")===0&&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"&&ia(t[e])})},ra=t=>{t.fontFamily&&(t.themeVariables?t.themeVariables.fontFamily||(t.themeVariables={fontFamily:t.fontFamily}):t.themeVariables={fontFamily:t.fontFamily}),he.push(t),Vi(Q,he)},Fi=(t=Q)=>{he=[],Vi(t,he)},Dg={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},wo={},Rg=t=>{wo[t]||(T.warn(Dg[t]),wo[t]=!0)},na=t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&Rg("LAZY_LOAD_DEPRECATED")},qg=function(t,e){for(let i of e)t.attr(i[0],i[1])},$g=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},Pg=function(t,e,i,r){const n=$g(e,i,r);qg(t,n)},zg=function(t,e,i,r){const n=e.node().getBBox(),o=n.width,s=n.height;T.info(`SVG bounds: ${o}x${s}`,n);let a=0,l=0;T.info(`Graph bounds: ${a}x${l}`,t),a=o+i*2,l=s+i*2,T.info(`Calculated bounds: ${a}x${l}`),Pg(e,l,a,r);const h=`${n.x-i} ${n.y-i} ${n.width+2*i} ${n.height+2*i}`;e.attr("viewBox",h)},fi={},Wg=(t,e,i)=>{let r="";return t in fi&&fi[t]?r=fi[t](i):T.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} `},Hg=(t,e)=>{e!==void 0&&(fi[t]=e)},jg=Wg;let ln="",Gi="",hn="";const cn=t=>Oe(t,At()),oa=function(){ln="",hn="",Gi=""},sa=function(t){ln=cn(t).replace(/^\s+/g,"")},aa=function(){return ln||Gi},la=function(t){hn=cn(t).replace(/\n\s+/g,` `)},ha=function(){return hn},ca=function(t){Gi=cn(t)},ua=function(){return Gi},Ug={getAccTitle:aa,setAccTitle:sa,getDiagramTitle:ua,setDiagramTitle:ca,getAccDescription:ha,setAccDescription:la,clear:oa},Yg=Object.freeze(Object.defineProperty({__proto__:null,clear:oa,default:Ug,getAccDescription:ha,getAccTitle:aa,getDiagramTitle:ua,setAccDescription:la,setAccTitle:sa,setDiagramTitle:ca},Symbol.toStringTag,{value:"Module"}));let zt={};const da=function(t,e,i,r){T.debug("parseDirective is being called",e,i,r);try{if(e!==void 0)switch(e=e.trim(),i){case"open_directive":zt={};break;case"type_directive":if(!zt)throw new Error("currentDirective is undefined");zt.type=e.toLowerCase();break;case"arg_directive":if(!zt)throw new Error("currentDirective is undefined");zt.args=JSON.parse(e);break;case"close_directive":Vg(t,zt,r),zt=void 0;break}}catch(n){T.error(`Error while rendering sequenceDiagram directive: ${e} jison context: ${i}`),T.error(n.message)}},Vg=function(t,e,i){switch(T.info(`Directive type=${e.type} with args:`,e.args),e.type){case"init":case"initialize":{["config"].forEach(r=>{e.args[r]!==void 0&&(i==="flowchart-v2"&&(i="flowchart"),e.args[i]=e.args[r],delete e.args[r])}),T.info("sanitize in handleDirective",e.args),ue(e.args),T.info("sanitize in handleDirective (done)",e.args),ra(e.args);break}case"wrap":case"nowrap":t&&t.setWrap&&t.setWrap(e.type==="wrap");break;case"themeCss":T.warn("themeCss encountered");break;default:T.warn(`Unhandled directive: source: '%%{${e.type}: ${JSON.stringify(e.args?e.args:{})}}%%`,e);break}},Gg=T,Xg=rn,fa=At,Kg=t=>Oe(t,fa()),Zg=zg,Jg=()=>Yg,Qg=(t,e,i,r)=>da(t,e,i,r),Ei={},Ai=(t,e,i)=>{if(Ei[t])throw new Error(`Diagram ${t} already registered.`);Ei[t]=e,i&&ma(t,i),Hg(t,e.styles),e.injectUtils&&e.injectUtils(Gg,Xg,fa,Kg,Zg,Jg(),Qg)},un=t=>{if(t in Ei)return Ei[t];throw new Error(`Diagram ${t} not found.`)};class pa extends Error{constructor(e){super(e),this.name="UnknownDiagramError"}}const tm=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,em=/\s*%%.*\n/gm,ce={},Xi=function(t,e){t=t.replace(Qs,"").replace(tm,"").replace(em,` `);for(const[i,{detector:r}]of Object.entries(ce))if(r(t,e))return i;throw new pa(`No diagram type detected matching given configuration for text: ${t}`)},ga=(...t)=>{for(const{id:e,detector:i,loader:r}of t)ma(e,i,r)},im=async()=>{T.debug("Loading registered diagrams");const e=(await Promise.allSettled(Object.entries(ce).map(async([i,{detector:r,loader:n}])=>{if(n)try{un(i)}catch{try{const{diagram:s,id:a}=await n();Ai(a,s,r)}catch(s){throw T.error(`Failed to load external diagram with key ${i}. Removing from detectors.`),delete ce[i],s}}}))).filter(i=>i.status==="rejected");if(e.length>0){T.error(`Failed to load ${e.length} external diagrams`);for(const i of e)T.error(i);throw new Error(`Failed to load ${e.length} external diagrams`)}},ma=(t,e,i)=>{ce[t]?T.error(`Detector with key ${t} already exists`):ce[t]={detector:e,loader:i},T.debug(`Detector with key ${t} added${i?" with loader":""}`)},rm=t=>ce[t].loader,nm="​",om={curveBasis:Gu,curveBasisClosed:Xu,curveBasisOpen:Ku,curveBumpX:Yu,curveBumpY:Vu,curveBundle:Zu,curveCardinalClosed:Qu,curveCardinalOpen:td,curveCardinal:Ju,curveCatmullRomClosed:id,curveCatmullRomOpen:rd,curveCatmullRom:ed,curveLinear:Uu,curveLinearClosed:nd,curveMonotoneX:od,curveMonotoneY:sd,curveNatural:ad,curveStep:ld,curveStepAfter:cd,curveStepBefore:hd},kr=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,sm=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,am=function(t,e){const i=_a(t,/(?:init\b)|(?:initialize\b)/);let r={};if(Array.isArray(i)){const n=i.map(o=>o.args);ue(n),r=V(r,[...n])}else r=i.args;if(r){let n=Xi(t,e);["config"].forEach(o=>{r[o]!==void 0&&(n==="flowchart-v2"&&(n="flowchart"),r[n]=r[o],delete r[o])})}return r},_a=function(t,e=null){try{const i=new RegExp(`[%]{2}(?![{]${sm.source})(?=[}][%]{2}).* `,"ig");t=t.trim().replace(i,"").replace(/'/gm,'"'),T.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let r;const n=[];for(;(r=kr.exec(t))!==null;)if(r.index===kr.lastIndex&&kr.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&&n.push({type:t,args:null}),n.length===1?n[0]:n}catch(i){return T.error(`ERROR: ${i.message} - Unable to parse directive ${e!==null?" type:"+e:""} based on the text:${t}`),{type:null,args:null}}},lm=function(t,e){for(const[i,r]of e.entries())if(r.match(t))return i;return-1};function hm(t,e){if(!t)return e;const i=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return om[i]||e}function cm(t,e){const i=t.trim();if(i)return e.securityLevel!=="loose"?Ro(i):i}const um=(t,...e)=>{const i=t.split("."),r=i.length-1,n=i[r];let o=window;for(let s=0;s{i+=Ii(o,e),e=o});let r=i/2,n;return e=void 0,t.forEach(o=>{if(e&&!n){const s=Ii(o,e);if(s=1&&(n={x:o.x,y:o.y}),a>0&&a<1&&(n={x:(1-a)*e.x+a*o.x,y:(1-a)*e.y+a*o.y})}}e=o}),n}function fm(t){return t.length===1?t[0]:dm(t)}const pm=(t,e,i)=>{let r;T.info(`our points ${JSON.stringify(e)}`),e[0]!==i&&(e=e.reverse());let o=25,s;r=void 0,e.forEach(c=>{if(r&&!s){const f=Ii(c,r);if(f=1&&(s={x:c.x,y:c.y}),g>0&&g<1&&(s={x:(1-g)*r.x+g*c.x,y:(1-g)*r.y+g*c.y})}}r=c});const a=t?10:5,l=Math.atan2(e[0].y-s.y,e[0].x-s.x),h={x:0,y:0};return h.x=Math.sin(l)*a+(e[0].x+s.x)/2,h.y=-Math.cos(l)*a+(e[0].y+s.y)/2,h};function gm(t,e,i){let r=JSON.parse(JSON.stringify(i)),n;T.info("our points",r),e!=="start_left"&&e!=="start_right"&&(r=r.reverse()),r.forEach(f=>{n=f});let s=25+t,a;n=void 0,r.forEach(f=>{if(n&&!a){const g=Ii(f,n);if(g=1&&(a={x:f.x,y:f.y}),p>0&&p<1&&(a={x:(1-p)*n.x+p*f.x,y:(1-p)*n.y+p*f.y})}}n=f});const l=10+t*.5,h=Math.atan2(r[0].y-a.y,r[0].x-a.x),c={x:0,y:0};return c.x=Math.sin(h)*l+(r[0].x+a.x)/2,c.y=-Math.cos(h)*l+(r[0].y+a.y)/2,e==="start_left"&&(c.x=Math.sin(h+Math.PI)*l+(r[0].x+a.x)/2,c.y=-Math.cos(h+Math.PI)*l+(r[0].y+a.y)/2),e==="end_right"&&(c.x=Math.sin(h-Math.PI)*l+(r[0].x+a.x)/2-5,c.y=-Math.cos(h-Math.PI)*l+(r[0].y+a.y)/2-5),e==="end_left"&&(c.x=Math.sin(h)*l+(r[0].x+a.x)/2-5,c.y=-Math.cos(h)*l+(r[0].y+a.y)/2-5),c}function mm(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 Bo=0;const _m=()=>(Bo++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Bo);function ym(t){let e="";const i="0123456789abcdef",r=i.length;for(let n=0;nym(t.length),xm=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}},bm=function(t,e){const i=e.text.replace(nn.lineBreakRegex," "),[,r]=fn(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},Tm=Pr((t,e,i)=>{if(!t||(i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
"},i),nn.lineBreakRegex.test(t)))return t;const r=t.split(" "),n=[];let o="";return r.forEach((s,a)=>{const l=Mi(`${s} `,i),h=Mi(o,i);if(l>e){const{hyphenatedStrings:g,remainingWord:p}=km(s,e,"-",i);n.push(o,...g),o=p}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}`),km=Pr((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(Mi(h,r)>=e){const f=l+1,g=n.length===f,p=`${h}${i}`;o.push(g?h:p),s=""}else s=h}),{hyphenatedStrings:o,remainingWord:s}},(t,e,i="-",r)=>`${t}${e}${i}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function Sm(t,e){return e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:15},e),dn(t,e).height}function Mi(t,e){return e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial"},e),dn(t,e).width}const dn=Pr((t,e)=>{e=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial"},e);const{fontSize:i,fontFamily:r,fontWeight:n}=e;if(!t)return{width:0,height:0};const[,o]=fn(i),s=["sans-serif",r],a=t.split(nn.lineBreakRegex),l=[],h=_t("body");if(!h.remove)return{width:0,height:0,lineHeight:0};const c=h.append("svg");for(const g of s){let p=0;const _={width:0,height:0,lineHeight:0};for(const k of a){const F=xm();F.text=k||nm;const I=bm(c,F).style("font-size",o).style("font-weight",n).style("font-family",g),C=(I._groups||I)[0][0].getBBox();if(C.width===0&&C.height===0)throw new Error("svg element not in render tree");_.width=Math.round(Math.max(_.width,C.width)),p=Math.round(C.height),_.height+=p,_.lineHeight=Math.round(Math.max(_.lineHeight,p))}l.push(_)}c.remove();const f=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[f]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`),vm=class{constructor(e,i){this.deterministic=e,this.seed=i,this.count=i?i.length:0}next(){return this.deterministic?this.count++:Date.now()}};let ii;const wm=function(t){return ii=ii||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),ii.innerHTML=t,unescape(ii.textContent)},ue=t=>{if(T.debug("directiveSanitizer called with",t),typeof t=="object"&&(t.length?t.forEach(e=>ue(e)):Object.keys(t).forEach(e=>{T.debug("Checking key",e),e.startsWith("__")&&(T.debug("sanitize deleting __ option",e),delete t[e]),e.includes("proto")&&(T.debug("sanitize deleting proto option",e),delete t[e]),e.includes("constr")&&(T.debug("sanitize deleting constr option",e),delete t[e]),e.includes("themeCSS")&&(T.debug("sanitizing themeCss option"),t[e]=pi(t[e])),e.includes("fontFamily")&&(T.debug("sanitizing fontFamily option"),t[e]=pi(t[e])),e.includes("altFontFamily")&&(T.debug("sanitizing altFontFamily option"),t[e]=pi(t[e])),Pf.includes(e)?typeof t[e]=="object"&&(T.debug("sanitize deleting object",e),ue(t[e])):(T.debug("sanitize deleting option",e),delete t[e])})),t.themeVariables){const e=Object.keys(t.themeVariables);for(const i of e){const r=t.themeVariables[i];r&&r.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[i]="")}}T.debug("After sanitization",t)},pi=t=>{let e=0,i=0;for(const r of t){if(e{if(!r)return;const n=t.node().getBBox();t.append("text").text(r).attr("x",n.x+n.width/2).attr("y",-i).attr("class",e)},fn=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]},gi={assignWithDepth:V,wrapLabel:Tm,calculateTextHeight:Sm,calculateTextWidth:Mi,calculateTextDimensions:dn,detectInit:am,detectDirective:_a,isSubstringInArray:lm,interpolateToCurve:hm,calcLabelPosition:fm,calcCardinalityPosition:pm,calcTerminalLabelPosition:gm,formatUrl:cm,getStylesFromArray:mm,generateId:_m,random:Cm,runFunc:um,entityDecode:wm,initIdGenerator:vm,directiveSanitizer:ue,sanitizeCss:pi,insertTitle:Lm,parseFontSize:fn},Lo="10.3.0",Ca="c4",Fm=t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),Em=async()=>{const{diagram:t}=await z(()=>import("./c4Diagram-36d27044-d5fb0f5c.js"),["./c4Diagram-36d27044-d5fb0f5c.js","./svgDrawCommon-f26cad39-5f96db4d.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ca,diagram:t}},Am={id:Ca,detector:Fm,loader:Em},Im=Am,xa="flowchart",Mm=(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)},Om=async()=>{const{diagram:t}=await z(()=>import("./flowDiagram-698c8d5d-56c35d97.js"),["./flowDiagram-698c8d5d-56c35d97.js","./flowDb-8f9fc471-1b7e3ffe.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./styles-ff678862-20dd68c2.js","./index-4c4adb72-df482cff.js","./edges-b00f0ec2-1facac8e.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:xa,diagram:t}},Nm={id:xa,detector:Mm,loader:Om},Dm=Nm,ba="flowchart-v2",Rm=(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)},qm=async()=>{const{diagram:t}=await z(()=>import("./flowDiagram-v2-d6437390-f38cd2e0.js"),["./flowDiagram-v2-d6437390-f38cd2e0.js","./flowDb-8f9fc471-1b7e3ffe.js","./styles-ff678862-20dd68c2.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./index-4c4adb72-df482cff.js","./edges-b00f0ec2-1facac8e.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:ba,diagram:t}},$m={id:ba,detector:Rm,loader:qm},Pm=$m,Ta="er",zm=t=>/^\s*erDiagram/.test(t),Wm=async()=>{const{diagram:t}=await z(()=>import("./erDiagram-0ccc0425-6ade5cc9.js"),["./erDiagram-0ccc0425-6ade5cc9.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./dayjs.min-1b995edc.js","./stringify-ec884b6d.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ta,diagram:t}},Hm={id:Ta,detector:zm,loader:Wm},jm=Hm,ka="gitGraph",Um=t=>/^\s*gitGraph/.test(t),Ym=async()=>{const{diagram:t}=await z(()=>import("./gitGraphDiagram-a13ae597-7cef966a.js"),["./gitGraphDiagram-a13ae597-7cef966a.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:ka,diagram:t}},Vm={id:ka,detector:Um,loader:Ym},Gm=Vm,Sa="gantt",Xm=t=>/^\s*gantt/.test(t),Km=async()=>{const{diagram:t}=await z(()=>import("./ganttDiagram-60845bff-7213ad1d.js"),["./ganttDiagram-60845bff-7213ad1d.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./advancedFormat-ebff0a45.js","./linear-983f04a5.js","./init-77b53fdd.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Sa,diagram:t}},Zm={id:Sa,detector:Xm,loader:Km},Jm=Zm,va="info",Qm=t=>/^\s*info/.test(t),t0=async()=>{const{diagram:t}=await z(()=>import("./infoDiagram-c976a9ed-cce975d6.js"),["./infoDiagram-c976a9ed-cce975d6.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:va,diagram:t}},e0={id:va,detector:Qm,loader:t0},wa="pie",i0=t=>/^\s*pie/.test(t),r0=async()=>{const{diagram:t}=await z(()=>import("./pieDiagram-5efcb91d-7eb75b88.js"),["./pieDiagram-5efcb91d-7eb75b88.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./ordinal-ba9b4969.js","./init-77b53fdd.js","./array-9f3ba611.js","./path-53f90ab3.js","./arc-2dce2b31.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:wa,diagram:t}},n0={id:wa,detector:i0,loader:r0},o0=n0,Ba="quadrantChart",s0=t=>/^\s*quadrantChart/.test(t),a0=async()=>{const{diagram:t}=await z(()=>import("./quadrantDiagram-559115c7-4442c1e8.js"),["./quadrantDiagram-559115c7-4442c1e8.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./linear-983f04a5.js","./init-77b53fdd.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ba,diagram:t}},l0={id:Ba,detector:s0,loader:a0},h0=l0,La="requirement",c0=t=>/^\s*requirement(Diagram)?/.test(t),u0=async()=>{const{diagram:t}=await z(()=>import("./requirementDiagram-b2d6a344-b6d196c0.js"),["./requirementDiagram-b2d6a344-b6d196c0.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./dayjs.min-1b995edc.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:La,diagram:t}},d0={id:La,detector:c0,loader:u0},f0=d0,Fa="sequence",p0=t=>/^\s*sequenceDiagram/.test(t),g0=async()=>{const{diagram:t}=await z(()=>import("./sequenceDiagram-583eee82-2c88b6ae.js"),["./sequenceDiagram-583eee82-2c88b6ae.js","./svgDrawCommon-f26cad39-5f96db4d.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Fa,diagram:t}},m0={id:Fa,detector:p0,loader:g0},_0=m0,Ea="class",y0=(t,e)=>{var i;return((i=e==null?void 0:e.class)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(t)},C0=async()=>{const{diagram:t}=await z(()=>import("./classDiagram-5e843ae7-d00b7024.js"),["./classDiagram-5e843ae7-d00b7024.js","./styles-88ad4441-6b7221be.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ea,diagram:t}},x0={id:Ea,detector:y0,loader:C0},b0=x0,Aa="classDiagram",T0=(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)},k0=async()=>{const{diagram:t}=await z(()=>import("./classDiagram-v2-8c3b3e6a-8b97f004.js"),["./classDiagram-v2-8c3b3e6a-8b97f004.js","./styles-88ad4441-6b7221be.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./index-4c4adb72-df482cff.js","./edges-b00f0ec2-1facac8e.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Aa,diagram:t}},S0={id:Aa,detector:T0,loader:k0},v0=S0,Ia="state",w0=(t,e)=>{var i;return((i=e==null?void 0:e.state)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(t)},B0=async()=>{const{diagram:t}=await z(()=>import("./stateDiagram-b1c07dc6-fb1cdfe2.js"),["./stateDiagram-b1c07dc6-fb1cdfe2.js","./styles-f626f8de-b95cdc7c.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./dayjs.min-1b995edc.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ia,diagram:t}},L0={id:Ia,detector:w0,loader:B0},F0=L0,Ma="stateDiagram",E0=(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")},A0=async()=>{const{diagram:t}=await z(()=>import("./stateDiagram-v2-7c93469e-98b7d7a7.js"),["./stateDiagram-v2-7c93469e-98b7d7a7.js","./styles-f626f8de-b95cdc7c.js","./layout-aa38af50.js","./_baseSet-db0c20a6.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./index-ddd2a731.js","./iframe-781efd05.js","./_commonjsHelpers-de833af9.js","./index-d37d4223.js","./now-bd49f550.js","./index-4c4adb72-df482cff.js","./edges-b00f0ec2-1facac8e.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./Table-e1731fc3.js","./Table-1c296241.css","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ma,diagram:t}},I0={id:Ma,detector:E0,loader:A0},M0=I0,Oa="journey",O0=t=>/^\s*journey/.test(t),N0=async()=>{const{diagram:t}=await z(()=>import("./journeyDiagram-5120ee2f-b367af45.js"),["./journeyDiagram-5120ee2f-b367af45.js","./svgDrawCommon-f26cad39-5f96db4d.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./arc-2dce2b31.js","./path-53f90ab3.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Oa,diagram:t}},D0={id:Oa,detector:O0,loader:N0},R0=D0,q0=()=>"",$0=q0,P0=function(){},z0=(t,e,i)=>{try{T.debug(`Renering svg for syntax error `);const r=_t("#"+e),n=r.append("g");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),r.attr("height",100),r.attr("width",500),r.attr("viewBox","768 0 912 512")}catch(r){T.error("Error while rendering info diagram"),T.error(Bm(r))}},Na={setConf:P0,draw:z0},W0={db:{clear:()=>{}},styles:$0,renderer:Na,parser:{parser:{yy:{}},parse:()=>{}},init:()=>{}},H0=W0,Da="flowchart-elk",j0=(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")},U0=async()=>{const{diagram:t}=await z(()=>import("./flowchart-elk-definition-6f4e6aa0-1ffe6798.js"),["./flowchart-elk-definition-6f4e6aa0-1ffe6798.js","./flowDb-8f9fc471-1b7e3ffe.js","./edges-b00f0ec2-1facac8e.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./svgDraw-5d8a058e-46269cff.js","./line-932cce81.js","./array-9f3ba611.js","./path-53f90ab3.js","./_commonjsHelpers-de833af9.js","./index-ddd2a731.js","./iframe-781efd05.js","./index-d37d4223.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Da,diagram:t}},Y0={id:Da,detector:j0,loader:U0},V0=Y0,Ra="timeline",G0=t=>/^\s*timeline/.test(t),X0=async()=>{const{diagram:t}=await z(()=>import("./timeline-definition-491ea63c-63c287f4.js"),["./timeline-definition-491ea63c-63c287f4.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./arc-2dce2b31.js","./path-53f90ab3.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:Ra,diagram:t}},K0={id:Ra,detector:G0,loader:X0},Z0=K0,qa="mindmap",J0=t=>/^\s*mindmap/.test(t),Q0=async()=>{const{diagram:t}=await z(()=>import("./mindmap-definition-0ab67801-94f1bb03.js"),["./mindmap-definition-0ab67801-94f1bb03.js","./createText-285e50b4-e0ee916f.js","./index-356e4a49.js","./_commonjsHelpers-de833af9.js","./dayjs.min-1b995edc.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:qa,diagram:t}},t_={id:qa,detector:J0,loader:Q0},e_=t_,$a="sankey",i_=t=>/^\s*sankey-beta/.test(t),r_=async()=>{const{diagram:t}=await z(()=>import("./sankeyDiagram-e679478d-94ffd3f0.js"),["./sankeyDiagram-e679478d-94ffd3f0.js","./dayjs.min-1b995edc.js","./_commonjsHelpers-de833af9.js","./ordinal-ba9b4969.js","./init-77b53fdd.js","./chunk-S4VUQJ4A-2dd298b0.js","./iframe-781efd05.js","./index-ddd2a731.js","./index-d37d4223.js","./index-e04ae519.js","./index-356e4a49.js","./jsx-runtime-0fbb5865.js","./_getTag-edecb89a.js","./isSymbol-50749e90.js","./isObject-32699ff3.js","./toString-25ea340b.js","./Table-e1731fc3.js","./Table-1c296241.css","./parseCss-20e8fd4a.js","./index-d22d6f20.js","./_color-087aa1f8.js","./index-e6b2d23a.js"],import.meta.url);return{id:$a,diagram:t}},n_={id:$a,detector:i_,loader:r_},o_=n_;let Fo=!1;const pn=()=>{Fo||(Fo=!0,Ai("error",H0,t=>t.toLowerCase().trim()==="error"),Ai("---",{db:{clear:()=>{}},styles:{},renderer:{},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("---")),ga(Im,v0,b0,jm,Jm,e0,o0,f0,_0,V0,Pm,Dm,e_,Z0,Gm,M0,F0,R0,h0,o_))},s_=t=>t.trimStart().replace(/^\s*%%(?!{)[^\n]+\n?/gm,"");class Pa{constructor(e){var i,r;this.text=e,this.type="graph",this.text+=` `;const n=At();try{this.type=Xi(e,n)}catch(a){this.type="error",this.detectError=a}const o=un(this.type);T.debug("Type "+this.type),this.db=o.db,(r=(i=this.db).clear)==null||r.call(i),this.renderer=o.renderer,this.parser=o.parser;const s=this.parser.parse.bind(this.parser);this.parser.parse=a=>s(s_(Ag(a,this.db))),this.parser.parser.yy=this.db,o.init&&(o.init(n),T.info("Initialized diagram "+this.type,n)),this.parse()}parse(){var e,i;if(this.detectError)throw this.detectError;(i=(e=this.db).clear)==null||i.call(e),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 gn=async t=>{const e=Xi(t,At());try{un(e)}catch{const r=rm(e);if(!r)throw new pa(`Diagram ${e} not found.`);const{id:n,diagram:o}=await r();Ai(n,o)}return new Pa(t)};let $r=[];const xy=t=>{$r.push(t)},a_=()=>{$r.forEach(t=>{t()}),$r=[]},l_="graphics-document document";function h_(t,e){t.attr("role",l_),e!==""&&t.attr("aria-roledescription",e)}function c_(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 za=["graph","flowchart","flowchart-v2","flowchart-elk","stateDiagram","stateDiagram-v2"],u_=5e4,d_="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",f_="sandbox",p_="loose",g_="http://www.w3.org/2000/svg",m_="http://www.w3.org/1999/xlink",__="http://www.w3.org/1999/xhtml",y_="100%",C_="100%",x_="border:0;margin:0;",b_="margin:0",T_="allow-top-navigation-by-user-activation allow-popups",k_='The "iframe" tag is not supported by your browser.',S_=["foreignobject"],v_=["dominant-baseline"];async function w_(t,e){pn();try{(await gn(t)).parse()}catch(i){if(e!=null&&e.suppressErrors)return!1;throw i}return!0}const B_=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},L_=function(t){return t.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},Eo=(t,e,i=[])=>` .${t} ${e} { ${i.join(" !important; ")} !important; }`,F_=(t,e,i={})=>{var r;let n="";if(t.themeCSS!==void 0&&(n+=` ${t.themeCSS}`),t.fontFamily!==void 0&&(n+=` :root { --mermaid-font-family: ${t.fontFamily}}`),t.altFontFamily!==void 0&&(n+=` :root { --mermaid-alt-font-family: ${t.altFontFamily}}`),!cr(i)&&za.includes(e)){const l=t.htmlLabels||((r=t.flowchart)==null?void 0:r.htmlLabels)?["> *","span"]:["rect","polygon","ellipse","circle","path"];for(const h in i){const c=i[h];cr(c.styles)||l.forEach(f=>{n+=Eo(c.id,f,c.styles)}),cr(c.textStyles)||(n+=Eo(c.id,"tspan",c.textStyles))}}return n},E_=(t,e,i,r)=>{const n=F_(t,e,i),o=jg(e,n,t.themeVariables);return Dr(yf(`${r}{${o}}`),xf)},A_=(t="",e,i)=>{let r=t;return!i&&!e&&(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),r=L_(r),r=r.replace(/
/g,"
"),r},I_=(t="",e)=>{const i=e?e.viewBox.baseVal.height+"px":C_,r=btoa(''+t+"");return``},Ao=(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",g_);return n&&s.attr("xmlns:xlink",n),s.append("g"),t};function Io(t,e){return t.append("iframe").attr("id",e).attr("style","width: 100%; height: 100%;").attr("sandbox","")}const M_=(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()},O_=async function(t,e,i){var r,n,o,s;pn(),Fi();const a=gi.detectInit(e);a&&(ue(a),ra(a));const l=At();T.debug(l),e.length>((l==null?void 0:l.maxTextSize)??u_)&&(e=d_),e=e.replace(/\r\n?/g,` `),e=e.replace(/<(\w+)([^>]*)>/g,(rt,ze,q)=>"<"+ze+q.replace(/="([^"]*)"/g,"='$1'")+">");const h="#"+t,c="i"+t,f="#"+c,g="d"+t,p="#"+g;let _=_t("body");const k=l.securityLevel===f_,F=l.securityLevel===p_,I=l.fontFamily;if(i!==void 0){if(i&&(i.innerHTML=""),k){const rt=Io(_t(i),c);_=_t(rt.nodes()[0].contentDocument.body),_.node().style.margin=0}else _=_t(i);Ao(_,t,g,`font-family: ${I}`,m_)}else{if(M_(document,t,g,c),k){const rt=Io(_t("body"),c);_=_t(rt.nodes()[0].contentDocument.body),_.node().style.margin=0}else _=_t("body");Ao(_,t,g)}e=B_(e);let C,A;try{C=await gn(e)}catch(rt){C=new Pa("error"),A=rt}const R=_.select(p).node(),W=C.type,X=R.firstChild,M=X.firstChild,Ki=za.includes(W)?C.renderer.getClasses(e,C):{},Zi=E_(l,W,Ki,h),it=document.createElement("style");it.innerHTML=Zi,X.insertBefore(it,M);try{await C.renderer.draw(e,t,Lo,C)}catch(rt){throw Na.draw(e,t,Lo),rt}const fe=_.select(`${p} svg`),pe=(n=(r=C.db).getAccTitle)==null?void 0:n.call(r),ge=(s=(o=C.db).getAccDescription)==null?void 0:s.call(o);D_(W,fe,pe,ge),_.select(`[id="${t}"]`).selectAll("foreignobject > *").attr("xmlns",__);let Tt=_.select(p).node().innerHTML;if(T.debug("config.arrowMarkerAbsolute",l.arrowMarkerAbsolute),Tt=A_(Tt,k,Rs(l.arrowMarkerAbsolute)),k){const rt=_.select(p+" svg").node();Tt=I_(Tt,rt)}else F||(Tt=vi.sanitize(Tt,{ADD_TAGS:S_,ADD_ATTR:v_}));if(a_(),A)throw A;const me=_t(k?f:p).node();return me&&"remove"in me&&me.remove(),{svg:Tt,bindFunctions:C.db.bindFunctions}};function N_(t={}){var e;t!=null&&t.fontFamily&&!((e=t.themeVariables)!=null&&e.fontFamily)&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),Mg(t),t!=null&&t.theme&&t.theme in Ft?t.themeVariables=Ft[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=Ft.default.getThemeVariables(t.themeVariables));const i=typeof t=="object"?Ig(t):ea();rn(i.logLevel),pn()}function D_(t,e,i,r){h_(e,t),c_(e,i,r,e.attr("id"))}const Vt=Object.freeze({render:O_,parse:w_,parseDirective:da,getDiagramFromText:gn,initialize:N_,getConfig:At,setConfig:Ng,getSiteConfig:ea,updateSiteConfig:Og,reset:()=>{Fi()},globalReset:()=>{Fi(De)},defaultConfig:De});rn(At().logLevel);Fi(At());const R_=(t,e,i)=>{T.warn(t),ya(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}))},Wa=async function(t={querySelector:".mermaid"}){try{await q_(t)}catch(e){if(ya(e)&&T.error(e.str),ct.parseError&&ct.parseError(e),!t.suppressErrors)throw T.error("Use the suppressErrors option to suppress these errors"),e}},q_=async function({postRenderCallback:t,querySelector:e,nodes:i}={querySelector:".mermaid"}){const r=Vt.getConfig();T.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");T.debug(`Found ${n.length} diagrams`),(r==null?void 0:r.startOnLoad)!==void 0&&(T.debug("Start On Load: "+(r==null?void 0:r.startOnLoad)),Vt.updateSiteConfig({startOnLoad:r==null?void 0:r.startOnLoad}));const o=new gi.initIdGenerator(r.deterministicIds,r.deterministicIDSeed);let s;const a=[];for(const l of Array.from(n)){T.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=ol(gi.entityDecode(s)).trim().replace(//gi,"
");const c=gi.detectInit(s);c&&T.debug("Detected early reinit: ",c);try{const{svg:f,bindFunctions:g}=await Ya(h,s,l);l.innerHTML=f,t&&await t(h),g&&g(l)}catch(f){R_(f,a,ct.parseError)}}if(a.length>0)throw a[0]},Ha=function(t){Vt.initialize(t)},$_=async function(t,e,i){T.warn("mermaid.init is deprecated. Please use run instead."),t&&Ha(t);const r={postRenderCallback:i,querySelector:".mermaid"};typeof e=="string"?r.querySelector=e:e&&(e instanceof HTMLElement?r.nodes=[e]:r.nodes=e),await Wa(r)},P_=async(t,{lazyLoad:e=!0}={})=>{ga(...t),e===!1&&await im()},ja=function(){if(ct.startOnLoad){const{startOnLoad:t}=Vt.getConfig();t&&ct.run().catch(e=>T.error("Mermaid failed to initialize",e))}};if(typeof document<"u"){/*! * Wait for document loaded before starting the execution */window.addEventListener("load",ja,!1)}const z_=function(t){ct.parseError=t},Oi=[];let Sr=!1;const Ua=async()=>{if(!Sr){for(Sr=!0;Oi.length>0;){const t=Oi.shift();if(t)try{await t()}catch(e){T.error("Error executing queue",e)}}Sr=!1}},W_=async(t,e)=>new Promise((i,r)=>{const n=()=>new Promise((o,s)=>{Vt.parse(t,e).then(a=>{o(a),i(a)},a=>{var l;T.error("Error parsing",a),(l=ct.parseError)==null||l.call(ct,a),s(a),r(a)})});Oi.push(n),Ua().catch(r)}),Ya=(t,e,i)=>new Promise((r,n)=>{const o=()=>new Promise((s,a)=>{Vt.render(t,e,i).then(l=>{s(l),r(l)},l=>{var h;T.error("Error parsing",l),(h=ct.parseError)==null||h.call(ct,l),a(l),n(l)})});Oi.push(o),Ua().catch(n)}),ct={startOnLoad:!0,mermaidAPI:Vt,parse:W_,render:Ya,init:$_,run:Wa,registerExternalDiagrams:P_,initialize:Ha,parseError:void 0,contentLoaded:ja,setParseErrorHandler:z_,detectType:Xi};ct.initialize({startOnLoad:!1});function Mo(t){const{code:e,name:i}=t,[r,n]=qn.useState(null);return qn.useEffect(()=>{if(!e)return;(async s=>{try{const{svg:a}=await ct.render(i,s||"");n(a)}catch(a){n(""),console.error("Invalid mermaid syntax: %o",a)}})(e)},[e]),nl.createElement("div",{className:"storybook-mermaid-graph",dangerouslySetInnerHTML:{__html:r||""}})}function Oo(t){const e=Object.assign({p:"p",img:"img",h1:"h1",h2:"h2",code:"code",blockquote:"blockquote",strong:"strong",em:"em",h3:"h3",pre:"pre"},Do(),t.components);return b.jsxs(b.Fragment,{children:[` `,` `,b.jsx(rl,{title:"Styles/Tokens/Intro",parameters:{...No}}),` `,b.jsx(e.p,{children:b.jsx(e.img,{src:"https://graphics.thomsonreuters.com/style-assets/images/logos/reuters-graphics-logo/svg/graphics-logo-color-dark.svg",alt:""})}),` `,b.jsx(e.h1,{id:"style-tokens",children:"Style tokens"}),` `,b.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."}),` `,b.jsx(e.p,{children:"You can use the style tokens to help shortcut the time you spend writing CSS and reinventing solid design conventions."}),` `,b.jsx(e.h2,{id:"whats-a-token",children:`What's a "token"?`}),` `,b.jsxs(e.p,{children:["A token represents the value for an individual style rule, like ",b.jsx(e.code,{children:"font-size"})," or ",b.jsx(e.code,{children:"color"}),". Each token sets just one style rule, and multiple tokens are combined together to style an element, like a ",b.jsx(e.code,{children:"
"}),"."]}),` `,b.jsx(Mo,{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/>"); `}),` `,b.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."}),` `,b.jsx(Mo,{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;"); `}),` `,b.jsx(e.h2,{id:"using-style-tokens",children:"Using style tokens"}),` `,b.jsxs(e.blockquote,{children:[` `,b.jsxs(e.p,{children:["Whether you use style tokens or write your own custom CSS in your project is ",b.jsx(e.strong,{children:"entirely up to you"}),"."]}),` `,b.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 ",b.jsx(e.strong,{children:"will absolutely save you time"}),", so we recommend giving them a try."]}),` `,b.jsxs(e.p,{children:[b.jsx(e.strong,{children:"That said"}),", we ",b.jsx(e.em,{children:"do recommend"})," using tokens for styling typography, especially ",b.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.)"]}),` `]}),` `,b.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."}),` `,b.jsx(e.h3,{id:"for-example",children:"For example..."}),` `,b.jsxs(e.p,{children:["Here's our table of text colour tokens, which set the ",b.jsx(e.code,{children:"text-color"})," style."]}),` `,b.jsx(gl,{title:"Colour",mdnLink:"color",header:["Class","Include","Properties"],body:ml(_l,!0),copyable:[!0,i=>`@include ${i};`,!1]}),` `,b.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.)"}),` `,b.jsxs(e.p,{children:["To use the token that sets the ",b.jsx(e.code,{children:"color"}),` style to our "primary" text colour (i.e., black), you'd use the `,b.jsx(e.code,{children:"Class"})," token like this:"]}),` `,b.jsx(e.pre,{children:b.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

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

Lorem ipsum...

`})}),` `,b.jsxs(e.blockquote,{children:[` `,b.jsxs(e.p,{children:[b.jsx(e.strong,{children:"Note:"})," If you're writing SCSS ",b.jsx(e.em,{children:"inside a component"}),", the ",b.jsx(e.code,{children:"@import"})," above is required. If you're writing in ",b.jsx(e.code,{children:"global.scss"}),", this is already included for you."]}),` `]}),` `,b.jsx(e.p,{children:"To use multiple tokens, you'd simply add another class or include:"}),` `,b.jsx(e.pre,{children:b.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,b.jsx(e.pre,{children:b.jsx(e.code,{className:"language-scss",children:`p { @include text-primary; @include font-bold; } `})}),` `,b.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!"}),` `,b.jsxs(e.h3,{id:"important-modifier",children:[b.jsx(e.code,{children:"!important"})," modifier"]}),` `,b.jsxs(e.p,{children:["Most of our tokens can be used with an ",b.jsx(e.code,{children:"!important"})," modifier simply by adding an ",b.jsx(e.code,{children:"!"}),". So for the class token that controls ",b.jsx(e.code,{children:"font-weight"}),", you'd make it important like:"]}),` `,b.jsx(e.pre,{children:b.jsx(e.code,{className:"language-svelte",children:`

Lorem ipsum...

`})}),` `,b.jsxs(e.p,{children:["For SCSS includes, the concept is the same, but you need to escape the ",b.jsx(e.code,{children:"!"})," by adding an extra ",b.jsx(e.code,{children:"\\"})," to make it valid syntax:"]}),` `,b.jsx(e.pre,{children:b.jsx(e.code,{className:"language-scss",children:`p { @include \\!font-bold; } `})})]})}function H_(t={}){const{wrapper:e}=Object.assign({},Do(),t.components);return e?b.jsx(e,{...t,children:b.jsx(Oo,{...t})}):Oo(t)}const Va=()=>{throw new Error("Docs-only story")};Va.parameters={docsOnly:!0};const Re={title:"Styles/Tokens/Intro",parameters:{...No},tags:["stories-mdx"],includeStories:["__page"]};Re.parameters=Re.parameters||{};Re.parameters.docs={...Re.parameters.docs||{},page:H_};const j_=["__page"],by=Object.freeze(Object.defineProperty({__proto__:null,__namedExportsOrder:j_,__page:Va,default:Re},Symbol.toStringTag,{value:"Module"}));export{da as $,fa as A,Zg as B,Cm as C,Xr as D,ay as E,cy as F,io as G,eo as H,dy as I,uy as J,hy as K,oy as L,sy as M,py as N,fy as O,ly as P,Nf as Q,zf as R,fn as S,xy as T,zg as U,hm as V,Uu as W,mm as X,_m as Y,nm as Z,Yg as _,ha as a,Pe as a0,v as a1,B as a2,ot as a3,Ko as a4,ql as a5,L as a6,xt as a7,we as a8,jr as a9,Zo as aa,tt as ab,$e as ac,bc as ad,ts as ae,ny as af,Ur as ag,Ot as ah,Ee as ai,Xn as aj,Lc as ak,cr as al,by as am,la as b,At as c,Oe as d,V as e,Mi as f,aa as g,_t as h,Pg as i,nn as j,Sm as k,T as l,Vt as m,Ro as n,De as o,ca as p,ua as q,oa as r,sa as s,Rs as t,gi as u,L_ as v,Tm as w,Gu as x,Ff as y,Ng as z}; //# sourceMappingURL=intro.stories-e147d254.js.map