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

Lorem ipsum...

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

Lorem ipsum...

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

Lorem ipsum...

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

Lorem ipsum...

`})}),` `,S.jsxs(r.p,{children:["For SCSS includes, the concept is the same, but you need to escape the ",S.jsx(r.code,{children:"!"})," by adding an extra ",S.jsx(r.code,{children:"\\"})," to make it valid syntax:"]}),` `,S.jsx(r.pre,{children:S.jsx(r.code,{className:"language-scss",children:`p { @include \\!font-bold; } `})})]})}}const Va=()=>{throw new Error("Docs-only story")};Va.parameters={docsOnly:!0};const Xe={title:"Styles/Tokens/Intro",parameters:{...$o},tags:["stories-mdx"],includeStories:["__page"]};Xe.parameters=Xe.parameters||{};Xe.parameters.docs={...Xe.parameters.docs||{},page:Y_};const V_=["__page"],Sy=Object.freeze(Object.defineProperty({__proto__:null,__namedExportsOrder:V_,__page:Va,default:Xe},Symbol.toStringTag,{value:"Module"}));export{da as $,fa as A,tm as B,Tm as C,en as D,cy as E,fy as F,ro as G,io as H,gy as I,py as J,dy as K,ly as L,hy as M,_y as N,my as O,uy as P,Rf as Q,jf as R,Cn as S,ky as T,jg as U,dm as V,Gu as W,Cm as X,xm as Y,am as Z,Xg as _,ha as a,Je as a0,E as a1,M as a2,_t as a3,Ko as a4,zl as a5,$ as a6,Dt as a7,Re as a8,Kr as a9,Zo as aa,ft as ab,Ze as ac,Sc as ad,ts as ae,ay as af,Sl as ag,Zr as ah,Qt as ai,We as aj,Kn as ak,Ac as al,mr as am,Sy as an,la as b,Vt as c,Ye as d,st as e,ji as f,aa as g,It as h,Hg as i,cn as j,Bm as k,v as l,ue as m,No as n,Ge as o,ca as p,ua as q,oa as r,sa as s,Ns as t,wi as u,A_ as v,vm as w,Zu as x,Mf as y,Rg as z}; //# sourceMappingURL=intro.stories-bf4e7cdc.js.map