function __vite__mapDeps(indexes) {
  if (!__vite__mapDeps.viteFileDeps) {
    __vite__mapDeps.viteFileDeps = ["./c4Diagram-b947cdbb-D_dFMgJl.js","./index-CEF9hIqL.js","./index-CyHipq39.css","./svgDrawCommon-0ee1b4e9-B1UZ1wAD.js","./flowDiagram-d949d7c1-CpCOJ_ws.js","./flowDb-d35e309a-C2X_gYsC.js","./graph-DrS_sYJI.js","./layout-C1pBysyn.js","./styles-7383a064-Bn4mPjAG.js","./index-8fae9850-sZtITwy3.js","./clone-B9tAIzPU.js","./edges-d417c7a0-ICDbbxt4.js","./createText-423428c9-BcZ1Y8MF.js","./channel-DFwcSz_I.js","./flowDiagram-v2-49332944-ReNEJkVq.js","./erDiagram-0ea73325-OlIck4_b.js","./gitGraphDiagram-b9d81de9-DgdIAVAK.js","./ganttDiagram-5c869e3b-BbmKbJhj.js","./infoDiagram-db7b18fc-Bcku8sL_.js","./pieDiagram-b0208e96-B4JAG5bu.js","./quadrantDiagram-0332be45-CUt6OQ2s.js","./xychartDiagram-e50adddc-XDQqkwi5.js","./requirementDiagram-bf7890df-BJKKwdtl.js","./sequenceDiagram-c18d009d-C5ESA_ph.js","./classDiagram-35230388-Hss2RVoj.js","./styles-6860f46c-CQUcT_7H.js","./classDiagram-v2-412acd34-C1qrd5aU.js","./stateDiagram-43596fc0-CoVmyqxt.js","./styles-b2c874b6-D3ZbeK9O.js","./stateDiagram-v2-2ead4f9c-yh7lRxiw.js","./journeyDiagram-d5636530-CtaWqvtb.js","./flowchart-elk-definition-27cc417a-D3n0yIVA.js","./timeline-definition-d977decf-DbaNuXC4.js","./mindmap-definition-377f8f1f-acoaSzZy.js","./sankeyDiagram-0acdec17-SNYbWGRM.js","./Tableau10-B-NsZVaP.js","./blockDiagram-6b2b5046-CuDrjI8z.js"]
  }
  return indexes.map((i) => __vite__mapDeps.viteFileDeps[i])
}
import{i as He,d as hr,e as Pr,b as Sn,c as Bn,f as _i,h as ki,j as vn,o as Ln,k as zr,l as Fn,m as An,U as cr,n as Nr,q as Wr,s as fi,t as gi,u as En,v as wn,S as On,w as Mn,x as In,y as Dn,g as $n,z as Si,A as gt,B as Rn,C as qn,D as Pn,E as zn,F as Nn,G as Wn,H as Hn,I as jn,J as Un,K as Yn,L as Gn,M as Vn,N as Xn,O as Kn,P as Zn,Q as Jn,T as Qn,W as ta,X as ea,Y as ia,Z as ra,_ as Y,r as oa,$ as na,a0 as aa,a1 as sa,a2 as la}from"./index-CEF9hIqL.js";var ur=Object.create,ha=function(){function t(){}return function(e){if(!He(e))return{};if(ur)return ur(e);t.prototype=e;var i=new t;return t.prototype=void 0,i}}();function ca(t,e){var i=-1,r=t.length;for(e||(e=Array(r));++i<r;)e[i]=t[i];return e}function Bi(t,e,i){e=="__proto__"&&hr?hr(t,e,{configurable:!0,enumerable:!0,value:i,writable:!0}):t[e]=i}var ua=Object.prototype,da=ua.hasOwnProperty;function fa(t,e,i){var r=t[e];(!(da.call(t,e)&&Pr(r,i))||i===void 0&&!(e in t))&&Bi(t,e,i)}function ga(t,e,i,r){var o=!i;i||(i={});for(var n=-1,a=e.length;++n<a;){var s=e[n],l=r?r(i[s],t[s],s,i,t):void 0;l===void 0&&(l=t[s]),o?Bi(i,s,l):fa(i,s,l)}return i}function pa(t){return Sn(function(e,i){var r=-1,o=i.length,n=o>1?i[o-1]:void 0,a=o>2?i[2]:void 0;for(n=t.length>3&&typeof n=="function"?(o--,n):void 0,a&&Bn(i[0],i[1],a)&&(n=o<3?void 0:n,o=1),e=Object(e);++r<o;){var s=i[r];s&&t(e,s,r,n)}return e})}function ma(t){var e=[];if(t!=null)for(var i in Object(t))e.push(i);return e}var Ca=Object.prototype,ya=Ca.hasOwnProperty;function ba(t){if(!He(t))return ma(t);var e=_i(t),i=[];for(var r in t)r=="constructor"&&(e||!ya.call(t,r))||i.push(r);return i}function Hr(t){return ki(t)?vn(t,!0):ba(t)}var jr=Ln(Object.getPrototypeOf,Object),xa="[object Object]",Ta=Function.prototype,_a=Object.prototype,Ur=Ta.toString,ka=_a.hasOwnProperty,Sa=Ur.call(Object);function Ba(t){if(!zr(t)||Fn(t)!=xa)return!1;var e=jr(t);if(e===null)return!0;var i=ka.call(e,"constructor")&&e.constructor;return typeof i=="function"&&i instanceof i&&Ur.call(i)==Sa}var Yr=typeof exports=="object"&&exports&&!exports.nodeType&&exports,dr=Yr&&typeof module=="object"&&module&&!module.nodeType&&module,va=dr&&dr.exports===Yr,fr=va?An.Buffer:void 0,gr=fr?fr.allocUnsafe:void 0;function La(t,e){if(e)return t.slice();var i=t.length,r=gr?gr(i):new t.constructor(i);return t.copy(r),r}function Fa(t){var e=new t.constructor(t.byteLength);return new cr(e).set(new cr(t)),e}function Aa(t,e){var i=e?Fa(t.buffer):t.buffer;return new t.constructor(i,t.byteOffset,t.length)}function Ea(t){return typeof t.constructor=="function"&&!_i(t)?ha(jr(t)):{}}function pi(t,e,i){(i!==void 0&&!Pr(t[e],i)||i===void 0&&!(e in t))&&Bi(t,e,i)}function wa(t){return zr(t)&&ki(t)}function mi(t,e){if(!(e==="constructor"&&typeof t[e]=="function")&&e!="__proto__")return t[e]}function Oa(t){return ga(t,Hr(t))}function Ma(t,e,i,r,o,n,a){var s=mi(t,i),l=mi(e,i),g=a.get(l);if(g){pi(t,i,g);return}var p=n?n(s,l,i+"",t,e,a):void 0,d=p===void 0;if(d){var h=fi(l),f=!h&&Nr(l),L=!h&&!f&&Wr(l);p=l,h||f||L?fi(s)?p=s:wa(s)?p=ca(s):f?(d=!1,p=La(l,!0)):L?(d=!1,p=Aa(l,!0)):p=[]:Ba(l)||gi(l)?(p=s,gi(s)?p=Oa(s):(!He(s)||En(s))&&(p=Ea(l))):d=!1}d&&(a.set(l,p),o(p,l,r,n,a),a.delete(l)),pi(t,i,p)}function Gr(t,e,i,r,o){t!==e&&wn(e,function(n,a){if(o||(o=new On),He(n))Ma(t,e,a,i,Gr,r,o);else{var s=r?r(mi(t,a),n,a+"",t,e,o):void 0;s===void 0&&(s=n),pi(t,a,s)}},Hr)}var Ia="[object Map]",Da="[object Set]",$a=Object.prototype,Ra=$a.hasOwnProperty;function ri(t){if(t==null)return!0;if(ki(t)&&(fi(t)||typeof t=="string"||typeof t.splice=="function"||Nr(t)||Wr(t)||gi(t)))return!t.length;var e=Mn(t);if(e==Ia||e==Da)return!t.size;if(_i(t))return!In(t).length;for(var i in t)if(Ra.call(t,i))return!1;return!0}var qa=pa(function(t,e,i){Gr(t,e,i)});class Vr{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 Pa(t){return new Vr(t,!0)}function za(t){return new Vr(t,!1)}function Na(t){for(var e=[],i=1;i<arguments.length;i++)e[i-1]=arguments[i];var r=Array.from(typeof t=="string"?[t]:t);r[r.length-1]=r[r.length-1].replace(/\r?\n([\t ]*)$/,"");var o=r.reduce(function(s,l){var g=l.match(/\n([\t ]+|(?!\s).)/g);return g?s.concat(g.map(function(p){var d,h;return(h=(d=p.match(/[\t ]/g))===null||d===void 0?void 0:d.length)!==null&&h!==void 0?h:0})):s},[]);if(o.length){var n=new RegExp(`
[	 ]{`+Math.min.apply(Math,o)+"}","g");r=r.map(function(s){return s.replace(n,`
`)})}r[0]=r[0].replace(/^\r?\n/,"");var a=r[0];return e.forEach(function(s,l){var g=a.match(/(?:^|\n)( *)$/),p=g?g[1]:"",d=s;typeof s=="string"&&s.includes(`
`)&&(d=String(s).split(`
`).map(function(h,f){return f===0?h:""+p+h}).join(`
`)),a+=d+r[l+1]}),a}var Xr={exports:{}};(function(t,e){(function(i,r){t.exports=r()})(Dn,function(){var i=1e3,r=6e4,o=36e5,n="millisecond",a="second",s="minute",l="hour",g="day",p="week",d="month",h="quarter",f="year",L="date",R="Invalid Date",O=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,N=/\[([^\]]+)]|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,M={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(E){var T=["th","st","nd","rd"],C=E%100;return"["+E+(T[(C-20)%10]||T[C]||T[0])+"]"}},j=function(E,T,C){var k=String(E);return!k||k.length>=T?E:""+Array(T+1-k.length).join(C)+E},V={s:j,z:function(E){var T=-E.utcOffset(),C=Math.abs(T),k=Math.floor(C/60),b=C%60;return(T<=0?"+":"-")+j(k,2,"0")+":"+j(b,2,"0")},m:function E(T,C){if(T.date()<C.date())return-E(C,T);var k=12*(C.year()-T.year())+(C.month()-T.month()),b=T.clone().add(k,d),x=C-b<0,D=T.clone().add(k+(x?-1:1),d);return+(-(k+(C-b)/(x?b-D:D-b))||0)},a:function(E){return E<0?Math.ceil(E)||0:Math.floor(E)},p:function(E){return{M:d,y:f,w:p,d:g,D:L,h:l,m:s,s:a,ms:n,Q:h}[E]||String(E||"").toLowerCase().replace(/s$/,"")},u:function(E){return E===void 0}},ut="en",Ct={};Ct[ut]=M;var Nt="$isDayjsObject",Mt=function(E){return E instanceof yt||!(!E||!E[Nt])},It=function E(T,C,k){var b;if(!T)return ut;if(typeof T=="string"){var x=T.toLowerCase();Ct[x]&&(b=x),C&&(Ct[x]=C,b=x);var D=T.split("-");if(!b&&D.length>1)return E(D[0])}else{var I=T.name;Ct[I]=T,b=I}return!k&&b&&(ut=b),b||!k&&ut},z=function(E,T){if(Mt(E))return E.clone();var C=typeof T=="object"?T:{};return C.date=E,C.args=arguments,new yt(C)},P=V;P.l=It,P.i=Mt,P.w=function(E,T){return z(E,{locale:T.$L,utc:T.$u,x:T.$x,$offset:T.$offset})};var yt=function(){function E(C){this.$L=It(C.locale,null,!0),this.parse(C),this.$x=this.$x||C.x||{},this[Nt]=!0}var T=E.prototype;return T.parse=function(C){this.$d=function(k){var b=k.date,x=k.utc;if(b===null)return new Date(NaN);if(P.u(b))return new Date;if(b instanceof Date)return new Date(b);if(typeof b=="string"&&!/Z$/i.test(b)){var D=b.match(O);if(D){var I=D[2]-1||0,H=(D[7]||"0").substring(0,3);return x?new Date(Date.UTC(D[1],I,D[3]||1,D[4]||0,D[5]||0,D[6]||0,H)):new Date(D[1],I,D[3]||1,D[4]||0,D[5]||0,D[6]||0,H)}}return new Date(b)}(C),this.init()},T.init=function(){var C=this.$d;this.$y=C.getFullYear(),this.$M=C.getMonth(),this.$D=C.getDate(),this.$W=C.getDay(),this.$H=C.getHours(),this.$m=C.getMinutes(),this.$s=C.getSeconds(),this.$ms=C.getMilliseconds()},T.$utils=function(){return P},T.isValid=function(){return this.$d.toString()!==R},T.isSame=function(C,k){var b=z(C);return this.startOf(k)<=b&&b<=this.endOf(k)},T.isAfter=function(C,k){return z(C)<this.startOf(k)},T.isBefore=function(C,k){return this.endOf(k)<z(C)},T.$g=function(C,k,b){return P.u(C)?this[k]:this.set(b,C)},T.unix=function(){return Math.floor(this.valueOf()/1e3)},T.valueOf=function(){return this.$d.getTime()},T.startOf=function(C,k){var b=this,x=!!P.u(k)||k,D=P.p(C),I=function(Tt,G){var J=P.w(b.$u?Date.UTC(b.$y,G,Tt):new Date(b.$y,G,Tt),b);return x?J:J.endOf(g)},H=function(Tt,G){return P.w(b.toDate()[Tt].apply(b.toDate("s"),(x?[0,0,0,0]:[23,59,59,999]).slice(G)),b)},$=this.$W,U=this.$M,Z=this.$D,Bt="set"+(this.$u?"UTC":"");switch(D){case f:return x?I(1,0):I(31,11);case d:return x?I(1,U):I(0,U+1);case p:var bt=this.$locale().weekStart||0,$t=($<bt?$+7:$)-bt;return I(x?Z-$t:Z+(6-$t),U);case g:case L:return H(Bt+"Hours",0);case l:return H(Bt+"Minutes",1);case s:return H(Bt+"Seconds",2);case a:return H(Bt+"Milliseconds",3);default:return this.clone()}},T.endOf=function(C){return this.startOf(C,!1)},T.$set=function(C,k){var b,x=P.p(C),D="set"+(this.$u?"UTC":""),I=(b={},b[g]=D+"Date",b[L]=D+"Date",b[d]=D+"Month",b[f]=D+"FullYear",b[l]=D+"Hours",b[s]=D+"Minutes",b[a]=D+"Seconds",b[n]=D+"Milliseconds",b)[x],H=x===g?this.$D+(k-this.$W):k;if(x===d||x===f){var $=this.clone().set(L,1);$.$d[I](H),$.init(),this.$d=$.set(L,Math.min(this.$D,$.daysInMonth())).$d}else I&&this.$d[I](H);return this.init(),this},T.set=function(C,k){return this.clone().$set(C,k)},T.get=function(C){return this[P.p(C)]()},T.add=function(C,k){var b,x=this;C=Number(C);var D=P.p(k),I=function(U){var Z=z(x);return P.w(Z.date(Z.date()+Math.round(U*C)),x)};if(D===d)return this.set(d,this.$M+C);if(D===f)return this.set(f,this.$y+C);if(D===g)return I(1);if(D===p)return I(7);var H=(b={},b[s]=r,b[l]=o,b[a]=i,b)[D]||1,$=this.$d.getTime()+C*H;return P.w($,this)},T.subtract=function(C,k){return this.add(-1*C,k)},T.format=function(C){var k=this,b=this.$locale();if(!this.isValid())return b.invalidDate||R;var x=C||"YYYY-MM-DDTHH:mm:ssZ",D=P.z(this),I=this.$H,H=this.$m,$=this.$M,U=b.weekdays,Z=b.months,Bt=b.meridiem,bt=function(G,J,vt,Rt){return G&&(G[J]||G(k,x))||vt[J].slice(0,Rt)},$t=function(G){return P.s(I%12||12,G,"0")},Tt=Bt||function(G,J,vt){var Rt=G<12?"AM":"PM";return vt?Rt.toLowerCase():Rt};return x.replace(N,function(G,J){return J||function(vt){switch(vt){case"YY":return String(k.$y).slice(-2);case"YYYY":return P.s(k.$y,4,"0");case"M":return $+1;case"MM":return P.s($+1,2,"0");case"MMM":return bt(b.monthsShort,$,Z,3);case"MMMM":return bt(Z,$);case"D":return k.$D;case"DD":return P.s(k.$D,2,"0");case"d":return String(k.$W);case"dd":return bt(b.weekdaysMin,k.$W,U,2);case"ddd":return bt(b.weekdaysShort,k.$W,U,3);case"dddd":return U[k.$W];case"H":return String(I);case"HH":return P.s(I,2,"0");case"h":return $t(1);case"hh":return $t(2);case"a":return Tt(I,H,!0);case"A":return Tt(I,H,!1);case"m":return String(H);case"mm":return P.s(H,2,"0");case"s":return String(k.$s);case"ss":return P.s(k.$s,2,"0");case"SSS":return P.s(k.$ms,3,"0");case"Z":return D}return null}(G)||D.replace(":","")})},T.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},T.diff=function(C,k,b){var x,D=this,I=P.p(k),H=z(C),$=(H.utcOffset()-this.utcOffset())*r,U=this-H,Z=function(){return P.m(D,H)};switch(I){case f:x=Z()/12;break;case d:x=Z();break;case h:x=Z()/3;break;case p:x=(U-$)/6048e5;break;case g:x=(U-$)/864e5;break;case l:x=U/o;break;case s:x=U/r;break;case a:x=U/i;break;default:x=U}return b?x:P.a(x)},T.daysInMonth=function(){return this.endOf(d).$D},T.$locale=function(){return Ct[this.$L]},T.locale=function(C,k){if(!C)return this.$L;var b=this.clone(),x=It(C,k,!0);return x&&(b.$L=x),b},T.clone=function(){return P.w(this.$d,this)},T.toDate=function(){return new Date(this.valueOf())},T.toJSON=function(){return this.isValid()?this.toISOString():null},T.toISOString=function(){return this.$d.toISOString()},T.toString=function(){return this.$d.toUTCString()},E}(),Dt=yt.prototype;return z.prototype=Dt,[["$ms",n],["$s",a],["$m",s],["$H",l],["$W",g],["$M",d],["$y",f],["$D",L]].forEach(function(E){Dt[E[1]]=function(T){return this.$g(T,E[0],E[1])}}),z.extend=function(E,T){return E.$i||(E(T,yt,z),E.$i=!0),z},z.locale=It,z.isDayjs=Mt,z.unix=function(E){return z(1e3*E)},z.en=Ct[ut],z.Ls=Ct,z.p={},z})})(Xr);var Wa=Xr.exports;const Ha=$n(Wa);var Kr={};(function(t){Object.defineProperty(t,"__esModule",{value:!0}),t.sanitizeUrl=t.BLANK_URL=void 0;var e=/^([^\w]*)(javascript|data|vbscript)/im,i=/&#(\w+)(^\w|;)?/g,r=/&(newline|tab);/gi,o=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim,n=/^.+(:|&colon;)/gim,a=[".","/"];t.BLANK_URL="about:blank";function s(p){return a.indexOf(p[0])>-1}function l(p){var d=p.replace(o,"");return d.replace(i,function(h,f){return String.fromCharCode(f)})}function g(p){if(!p)return t.BLANK_URL;var d=l(p).replace(r,"").replace(o,"").trim();if(!d)return t.BLANK_URL;if(s(d))return d;var h=d.match(n);if(!h)return d;var f=h[0];return e.test(f)?t.BLANK_URL:d}t.sanitizeUrl=g})(Kr);/*! @license DOMPurify 3.0.8 | (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.8/LICENSE */const{entries:Zr,setPrototypeOf:pr,isFrozen:ja,getPrototypeOf:Ua,getOwnPropertyDescriptor:vi}=Object;let{freeze:at,seal:xt,create:Jr}=Object,{apply:Ci,construct:yi}=typeof Reflect<"u"&&Reflect;at||(at=function(e){return e});xt||(xt=function(e){return e});Ci||(Ci=function(e,i,r){return e.apply(i,r)});yi||(yi=function(e,i){return new e(...i)});const Le=pt(Array.prototype.forEach),mr=pt(Array.prototype.pop),ue=pt(Array.prototype.push),we=pt(String.prototype.toLowerCase),oi=pt(String.prototype.toString),Ya=pt(String.prototype.match),de=pt(String.prototype.replace),Ga=pt(String.prototype.indexOf),Va=pt(String.prototype.trim),dt=pt(RegExp.prototype.test),fe=Xa(TypeError);function pt(t){return function(e){for(var i=arguments.length,r=new Array(i>1?i-1:0),o=1;o<i;o++)r[o-1]=arguments[o];return Ci(t,e,r)}}function Xa(t){return function(){for(var e=arguments.length,i=new Array(e),r=0;r<e;r++)i[r]=arguments[r];return yi(t,i)}}function q(t,e){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:we;pr&&pr(t,null);let r=e.length;for(;r--;){let o=e[r];if(typeof o=="string"){const n=i(o);n!==o&&(ja(e)||(e[r]=n),o=n)}t[o]=!0}return t}function Ka(t){for(let e=0;e<t.length;e++)vi(t,e)===void 0&&(t[e]=null);return t}function jt(t){const e=Jr(null);for(const[i,r]of Zr(t))vi(t,i)!==void 0&&(Array.isArray(r)?e[i]=Ka(r):r&&typeof r=="object"&&r.constructor===Object?e[i]=jt(r):e[i]=r);return e}function Fe(t,e){for(;t!==null;){const r=vi(t,e);if(r){if(r.get)return pt(r.get);if(typeof r.value=="function")return pt(r.value)}t=Ua(t)}function i(r){return console.warn("fallback value for",r),null}return i}const Cr=at(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),ni=at(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),ai=at(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Za=at(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),si=at(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Ja=at(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),yr=at(["#text"]),br=at(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),li=at(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),xr=at(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Ae=at(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Qa=xt(/\{\{[\w\W]*|[\w\W]*\}\}/gm),ts=xt(/<%[\w\W]*|[\w\W]*%>/gm),es=xt(/\${[\w\W]*}/gm),is=xt(/^data-[\-\w.\u00B7-\uFFFF]/),rs=xt(/^aria-[\-\w]+$/),Qr=xt(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),os=xt(/^(?:\w+script|data):/i),ns=xt(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),to=xt(/^html$/i);var Tr=Object.freeze({__proto__:null,MUSTACHE_EXPR:Qa,ERB_EXPR:ts,TMPLIT_EXPR:es,DATA_ATTR:is,ARIA_ATTR:rs,IS_ALLOWED_URI:Qr,IS_SCRIPT_OR_DATA:os,ATTR_WHITESPACE:ns,DOCTYPE_NAME:to});const as=function(){return typeof window>"u"?null:window},ss=function(e,i){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let r=null;const o="data-tt-policy-suffix";i&&i.hasAttribute(o)&&(r=i.getAttribute(o));const n="dompurify"+(r?"#"+r:"");try{return e.createPolicy(n,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+n+" could not be created."),null}};function eo(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:as();const e=S=>eo(S);if(e.version="3.0.8",e.removed=[],!t||!t.document||t.document.nodeType!==9)return e.isSupported=!1,e;let{document:i}=t;const r=i,o=r.currentScript,{DocumentFragment:n,HTMLTemplateElement:a,Node:s,Element:l,NodeFilter:g,NamedNodeMap:p=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:h,trustedTypes:f}=t,L=l.prototype,R=Fe(L,"cloneNode"),O=Fe(L,"nextSibling"),N=Fe(L,"childNodes"),M=Fe(L,"parentNode");if(typeof a=="function"){const S=i.createElement("template");S.content&&S.content.ownerDocument&&(i=S.content.ownerDocument)}let j,V="";const{implementation:ut,createNodeIterator:Ct,createDocumentFragment:Nt,getElementsByTagName:Mt}=i,{importNode:It}=r;let z={};e.isSupported=typeof Zr=="function"&&typeof M=="function"&&ut&&ut.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:P,ERB_EXPR:yt,TMPLIT_EXPR:Dt,DATA_ATTR:E,ARIA_ATTR:T,IS_SCRIPT_OR_DATA:C,ATTR_WHITESPACE:k}=Tr;let{IS_ALLOWED_URI:b}=Tr,x=null;const D=q({},[...Cr,...ni,...ai,...si,...yr]);let I=null;const H=q({},[...br,...li,...xr,...Ae]);let $=Object.seal(Jr(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}})),U=null,Z=null,Bt=!0,bt=!0,$t=!1,Tt=!0,G=!1,J=!1,vt=!1,Rt=!1,Vt=!1,ke=!1,Se=!1,Hi=!0,ji=!1;const pn="user-content-";let Ze=!0,le=!1,Xt={},Kt=null;const Ui=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 Yi=null;const Gi=q({},["audio","video","img","source","image","track"]);let Je=null;const Vi=q({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),Be="http://www.w3.org/1998/Math/MathML",ve="http://www.w3.org/2000/svg",Lt="http://www.w3.org/1999/xhtml";let Zt=Lt,Qe=!1,ti=null;const mn=q({},[Be,ve,Lt],oi);let he=null;const Cn=["application/xhtml+xml","text/html"],yn="text/html";let K=null,Jt=null;const bn=i.createElement("form"),Xi=function(c){return c instanceof RegExp||c instanceof Function},ei=function(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Jt&&Jt===c)){if((!c||typeof c!="object")&&(c={}),c=jt(c),he=Cn.indexOf(c.PARSER_MEDIA_TYPE)===-1?yn:c.PARSER_MEDIA_TYPE,K=he==="application/xhtml+xml"?oi:we,x="ALLOWED_TAGS"in c?q({},c.ALLOWED_TAGS,K):D,I="ALLOWED_ATTR"in c?q({},c.ALLOWED_ATTR,K):H,ti="ALLOWED_NAMESPACES"in c?q({},c.ALLOWED_NAMESPACES,oi):mn,Je="ADD_URI_SAFE_ATTR"in c?q(jt(Vi),c.ADD_URI_SAFE_ATTR,K):Vi,Yi="ADD_DATA_URI_TAGS"in c?q(jt(Gi),c.ADD_DATA_URI_TAGS,K):Gi,Kt="FORBID_CONTENTS"in c?q({},c.FORBID_CONTENTS,K):Ui,U="FORBID_TAGS"in c?q({},c.FORBID_TAGS,K):{},Z="FORBID_ATTR"in c?q({},c.FORBID_ATTR,K):{},Xt="USE_PROFILES"in c?c.USE_PROFILES:!1,Bt=c.ALLOW_ARIA_ATTR!==!1,bt=c.ALLOW_DATA_ATTR!==!1,$t=c.ALLOW_UNKNOWN_PROTOCOLS||!1,Tt=c.ALLOW_SELF_CLOSE_IN_ATTR!==!1,G=c.SAFE_FOR_TEMPLATES||!1,J=c.WHOLE_DOCUMENT||!1,Vt=c.RETURN_DOM||!1,ke=c.RETURN_DOM_FRAGMENT||!1,Se=c.RETURN_TRUSTED_TYPE||!1,Rt=c.FORCE_BODY||!1,Hi=c.SANITIZE_DOM!==!1,ji=c.SANITIZE_NAMED_PROPS||!1,Ze=c.KEEP_CONTENT!==!1,le=c.IN_PLACE||!1,b=c.ALLOWED_URI_REGEXP||Qr,Zt=c.NAMESPACE||Lt,$=c.CUSTOM_ELEMENT_HANDLING||{},c.CUSTOM_ELEMENT_HANDLING&&Xi(c.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&($.tagNameCheck=c.CUSTOM_ELEMENT_HANDLING.tagNameCheck),c.CUSTOM_ELEMENT_HANDLING&&Xi(c.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&($.attributeNameCheck=c.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),c.CUSTOM_ELEMENT_HANDLING&&typeof c.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&($.allowCustomizedBuiltInElements=c.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),G&&(bt=!1),ke&&(Vt=!0),Xt&&(x=q({},yr),I=[],Xt.html===!0&&(q(x,Cr),q(I,br)),Xt.svg===!0&&(q(x,ni),q(I,li),q(I,Ae)),Xt.svgFilters===!0&&(q(x,ai),q(I,li),q(I,Ae)),Xt.mathMl===!0&&(q(x,si),q(I,xr),q(I,Ae))),c.ADD_TAGS&&(x===D&&(x=jt(x)),q(x,c.ADD_TAGS,K)),c.ADD_ATTR&&(I===H&&(I=jt(I)),q(I,c.ADD_ATTR,K)),c.ADD_URI_SAFE_ATTR&&q(Je,c.ADD_URI_SAFE_ATTR,K),c.FORBID_CONTENTS&&(Kt===Ui&&(Kt=jt(Kt)),q(Kt,c.FORBID_CONTENTS,K)),Ze&&(x["#text"]=!0),J&&q(x,["html","head","body"]),x.table&&(q(x,["tbody"]),delete U.tbody),c.TRUSTED_TYPES_POLICY){if(typeof c.TRUSTED_TYPES_POLICY.createHTML!="function")throw fe('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof c.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw fe('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');j=c.TRUSTED_TYPES_POLICY,V=j.createHTML("")}else j===void 0&&(j=ss(f,o)),j!==null&&typeof V=="string"&&(V=j.createHTML(""));at&&at(c),Jt=c}},Ki=q({},["mi","mo","mn","ms","mtext"]),Zi=q({},["foreignobject","desc","title","annotation-xml"]),xn=q({},["title","style","font","a","script"]),Ji=q({},[...ni,...ai,...Za]),Qi=q({},[...si,...Ja]),Tn=function(c){let m=M(c);(!m||!m.tagName)&&(m={namespaceURI:Zt,tagName:"template"});const _=we(c.tagName),W=we(m.tagName);return ti[c.namespaceURI]?c.namespaceURI===ve?m.namespaceURI===Lt?_==="svg":m.namespaceURI===Be?_==="svg"&&(W==="annotation-xml"||Ki[W]):!!Ji[_]:c.namespaceURI===Be?m.namespaceURI===Lt?_==="math":m.namespaceURI===ve?_==="math"&&Zi[W]:!!Qi[_]:c.namespaceURI===Lt?m.namespaceURI===ve&&!Zi[W]||m.namespaceURI===Be&&!Ki[W]?!1:!Qi[_]&&(xn[_]||!Ji[_]):!!(he==="application/xhtml+xml"&&ti[c.namespaceURI]):!1},Wt=function(c){ue(e.removed,{element:c});try{c.parentNode.removeChild(c)}catch{c.remove()}},ii=function(c,m){try{ue(e.removed,{attribute:m.getAttributeNode(c),from:m})}catch{ue(e.removed,{attribute:null,from:m})}if(m.removeAttribute(c),c==="is"&&!I[c])if(Vt||ke)try{Wt(m)}catch{}else try{m.setAttribute(c,"")}catch{}},tr=function(c){let m=null,_=null;if(Rt)c="<remove></remove>"+c;else{const tt=Ya(c,/^[\r\n\t ]+/);_=tt&&tt[0]}he==="application/xhtml+xml"&&Zt===Lt&&(c='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+c+"</body></html>");const W=j?j.createHTML(c):c;if(Zt===Lt)try{m=new h().parseFromString(W,he)}catch{}if(!m||!m.documentElement){m=ut.createDocument(Zt,"template",null);try{m.documentElement.innerHTML=Qe?V:W}catch{}}const Q=m.body||m.documentElement;return c&&_&&Q.insertBefore(i.createTextNode(_),Q.childNodes[0]||null),Zt===Lt?Mt.call(m,J?"html":"body")[0]:J?m.documentElement:Q},er=function(c){return Ct.call(c.ownerDocument||c,c,g.SHOW_ELEMENT|g.SHOW_COMMENT|g.SHOW_TEXT,null)},_n=function(c){return c instanceof d&&(typeof c.nodeName!="string"||typeof c.textContent!="string"||typeof c.removeChild!="function"||!(c.attributes instanceof p)||typeof c.removeAttribute!="function"||typeof c.setAttribute!="function"||typeof c.namespaceURI!="string"||typeof c.insertBefore!="function"||typeof c.hasChildNodes!="function")},ir=function(c){return typeof s=="function"&&c instanceof s},Ft=function(c,m,_){z[c]&&Le(z[c],W=>{W.call(e,m,_,Jt)})},rr=function(c){let m=null;if(Ft("beforeSanitizeElements",c,null),_n(c))return Wt(c),!0;const _=K(c.nodeName);if(Ft("uponSanitizeElement",c,{tagName:_,allowedTags:x}),c.hasChildNodes()&&!ir(c.firstElementChild)&&dt(/<[/\w]/g,c.innerHTML)&&dt(/<[/\w]/g,c.textContent))return Wt(c),!0;if(!x[_]||U[_]){if(!U[_]&&nr(_)&&($.tagNameCheck instanceof RegExp&&dt($.tagNameCheck,_)||$.tagNameCheck instanceof Function&&$.tagNameCheck(_)))return!1;if(Ze&&!Kt[_]){const W=M(c)||c.parentNode,Q=N(c)||c.childNodes;if(Q&&W){const tt=Q.length;for(let st=tt-1;st>=0;--st)W.insertBefore(R(Q[st],!0),O(c))}}return Wt(c),!0}return c instanceof l&&!Tn(c)||(_==="noscript"||_==="noembed"||_==="noframes")&&dt(/<\/no(script|embed|frames)/i,c.innerHTML)?(Wt(c),!0):(G&&c.nodeType===3&&(m=c.textContent,Le([P,yt,Dt],W=>{m=de(m,W," ")}),c.textContent!==m&&(ue(e.removed,{element:c.cloneNode()}),c.textContent=m)),Ft("afterSanitizeElements",c,null),!1)},or=function(c,m,_){if(Hi&&(m==="id"||m==="name")&&(_ in i||_ in bn))return!1;if(!(bt&&!Z[m]&&dt(E,m))){if(!(Bt&&dt(T,m))){if(!I[m]||Z[m]){if(!(nr(c)&&($.tagNameCheck instanceof RegExp&&dt($.tagNameCheck,c)||$.tagNameCheck instanceof Function&&$.tagNameCheck(c))&&($.attributeNameCheck instanceof RegExp&&dt($.attributeNameCheck,m)||$.attributeNameCheck instanceof Function&&$.attributeNameCheck(m))||m==="is"&&$.allowCustomizedBuiltInElements&&($.tagNameCheck instanceof RegExp&&dt($.tagNameCheck,_)||$.tagNameCheck instanceof Function&&$.tagNameCheck(_))))return!1}else if(!Je[m]){if(!dt(b,de(_,k,""))){if(!((m==="src"||m==="xlink:href"||m==="href")&&c!=="script"&&Ga(_,"data:")===0&&Yi[c])){if(!($t&&!dt(C,de(_,k,"")))){if(_)return!1}}}}}}return!0},nr=function(c){return c.indexOf("-")>0},ar=function(c){Ft("beforeSanitizeAttributes",c,null);const{attributes:m}=c;if(!m)return;const _={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:I};let W=m.length;for(;W--;){const Q=m[W],{name:tt,namespaceURI:st,value:Ht}=Q,ce=K(tt);let lt=tt==="value"?Ht:Va(Ht);if(_.attrName=ce,_.attrValue=lt,_.keepAttr=!0,_.forceKeepAttr=void 0,Ft("uponSanitizeAttribute",c,_),lt=_.attrValue,_.forceKeepAttr||(ii(tt,c),!_.keepAttr))continue;if(!Tt&&dt(/\/>/i,lt)){ii(tt,c);continue}G&&Le([P,yt,Dt],lr=>{lt=de(lt,lr," ")});const sr=K(c.nodeName);if(or(sr,ce,lt)){if(ji&&(ce==="id"||ce==="name")&&(ii(tt,c),lt=pn+lt),j&&typeof f=="object"&&typeof f.getAttributeType=="function"&&!st)switch(f.getAttributeType(sr,ce)){case"TrustedHTML":{lt=j.createHTML(lt);break}case"TrustedScriptURL":{lt=j.createScriptURL(lt);break}}try{st?c.setAttributeNS(st,tt,lt):c.setAttribute(tt,lt),mr(e.removed)}catch{}}}Ft("afterSanitizeAttributes",c,null)},kn=function S(c){let m=null;const _=er(c);for(Ft("beforeSanitizeShadowDOM",c,null);m=_.nextNode();)Ft("uponSanitizeShadowNode",m,null),!rr(m)&&(m.content instanceof n&&S(m.content),ar(m));Ft("afterSanitizeShadowDOM",c,null)};return e.sanitize=function(S){let c=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},m=null,_=null,W=null,Q=null;if(Qe=!S,Qe&&(S="<!-->"),typeof S!="string"&&!ir(S))if(typeof S.toString=="function"){if(S=S.toString(),typeof S!="string")throw fe("dirty is not a string, aborting")}else throw fe("toString is not a function");if(!e.isSupported)return S;if(vt||ei(c),e.removed=[],typeof S=="string"&&(le=!1),le){if(S.nodeName){const Ht=K(S.nodeName);if(!x[Ht]||U[Ht])throw fe("root node is forbidden and cannot be sanitized in-place")}}else if(S instanceof s)m=tr("<!---->"),_=m.ownerDocument.importNode(S,!0),_.nodeType===1&&_.nodeName==="BODY"||_.nodeName==="HTML"?m=_:m.appendChild(_);else{if(!Vt&&!G&&!J&&S.indexOf("<")===-1)return j&&Se?j.createHTML(S):S;if(m=tr(S),!m)return Vt?null:Se?V:""}m&&Rt&&Wt(m.firstChild);const tt=er(le?S:m);for(;W=tt.nextNode();)rr(W)||(W.content instanceof n&&kn(W.content),ar(W));if(le)return S;if(Vt){if(ke)for(Q=Nt.call(m.ownerDocument);m.firstChild;)Q.appendChild(m.firstChild);else Q=m;return(I.shadowroot||I.shadowrootmode)&&(Q=It.call(r,Q,!0)),Q}let st=J?m.outerHTML:m.innerHTML;return J&&x["!doctype"]&&m.ownerDocument&&m.ownerDocument.doctype&&m.ownerDocument.doctype.name&&dt(to,m.ownerDocument.doctype.name)&&(st="<!DOCTYPE "+m.ownerDocument.doctype.name+`>
`+st),G&&Le([P,yt,Dt],Ht=>{st=de(st,Ht," ")}),j&&Se?j.createHTML(st):st},e.setConfig=function(){let S=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};ei(S),vt=!0},e.clearConfig=function(){Jt=null,vt=!1},e.isValidAttribute=function(S,c,m){Jt||ei({});const _=K(S),W=K(c);return or(_,W,m)},e.addHook=function(S,c){typeof c=="function"&&(z[S]=z[S]||[],ue(z[S],c))},e.removeHook=function(S){if(z[S])return mr(z[S])},e.removeHooks=function(S){z[S]&&(z[S]=[])},e.removeAllHooks=function(){z={}},e}var re=eo();const Oe={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 o=i<.5?i*(1+e):i+e-i*e,n=2*i-o;switch(r){case"r":return Oe.hue2rgb(n,o,t+1/3)*255;case"g":return Oe.hue2rgb(n,o,t)*255;case"b":return Oe.hue2rgb(n,o,t-1/3)*255}},rgb2hsl:({r:t,g:e,b:i},r)=>{t/=255,e/=255,i/=255;const o=Math.max(t,e,i),n=Math.min(t,e,i),a=(o+n)/2;if(r==="l")return a*100;if(o===n)return 0;const s=o-n,l=a>.5?s/(2-o-n):s/(o+n);if(r==="s")return l*100;switch(o){case t:return((e-i)/s+(e<i?6:0))*60;case e:return((i-t)/s+2)*60;case i:return((t-e)/s+4)*60;default:return-1}}},ls={clamp:(t,e,i)=>e>i?Math.min(e,Math.max(i,t)):Math.min(i,Math.max(e,t)),round:t=>Math.round(t*1e10)/1e10},hs=ls,cs={dec2hex:t=>{const e=Math.round(t).toString(16);return e.length>1?e:`0${e}`}},us=cs,w={channel:Oe,lang:hs,unit:us},qt={};for(let t=0;t<=255;t++)qt[t]=w.unit.dec2hex(t);const et={ALL:0,RGB:1,HSL:2};class ds{constructor(){this.type=et.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=et.ALL}is(e){return this.type===e}}class fs{constructor(e,i){this.color=i,this.changed=!1,this.data=e,this.type=new ds}set(e,i){return this.color=i,this.changed=!1,this.data=e,this.type.type=et.ALL,this}_ensureHSL(){const e=this.data,{h:i,s:r,l:o}=e;i===void 0&&(e.h=w.channel.rgb2hsl(e,"h")),r===void 0&&(e.s=w.channel.rgb2hsl(e,"s")),o===void 0&&(e.l=w.channel.rgb2hsl(e,"l"))}_ensureRGB(){const e=this.data,{r:i,g:r,b:o}=e;i===void 0&&(e.r=w.channel.hsl2rgb(e,"r")),r===void 0&&(e.g=w.channel.hsl2rgb(e,"g")),o===void 0&&(e.b=w.channel.hsl2rgb(e,"b"))}get r(){const e=this.data,i=e.r;return!this.type.is(et.HSL)&&i!==void 0?i:(this._ensureHSL(),w.channel.hsl2rgb(e,"r"))}get g(){const e=this.data,i=e.g;return!this.type.is(et.HSL)&&i!==void 0?i:(this._ensureHSL(),w.channel.hsl2rgb(e,"g"))}get b(){const e=this.data,i=e.b;return!this.type.is(et.HSL)&&i!==void 0?i:(this._ensureHSL(),w.channel.hsl2rgb(e,"b"))}get h(){const e=this.data,i=e.h;return!this.type.is(et.RGB)&&i!==void 0?i:(this._ensureRGB(),w.channel.rgb2hsl(e,"h"))}get s(){const e=this.data,i=e.s;return!this.type.is(et.RGB)&&i!==void 0?i:(this._ensureRGB(),w.channel.rgb2hsl(e,"s"))}get l(){const e=this.data,i=e.l;return!this.type.is(et.RGB)&&i!==void 0?i:(this._ensureRGB(),w.channel.rgb2hsl(e,"l"))}get a(){return this.data.a}set r(e){this.type.set(et.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(et.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(et.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(et.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(et.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(et.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}}const gs=fs,je=new gs({r:0,g:0,b:0,a:0},"transparent"),ie={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:t=>{if(t.charCodeAt(0)!==35)return;const e=t.match(ie.re);if(!e)return;const i=e[1],r=parseInt(i,16),o=i.length,n=o%4===0,a=o>4,s=a?1:17,l=a?8:4,g=n?0:-1,p=a?255:15;return je.set({r:(r>>l*(g+3)&p)*s,g:(r>>l*(g+2)&p)*s,b:(r>>l*(g+1)&p)*s,a:n?(r&p)*s/255:1},t)},stringify:t=>{const{r:e,g:i,b:r,a:o}=t;return o<1?`#${qt[Math.round(e)]}${qt[Math.round(i)]}${qt[Math.round(r)]}${qt[Math.round(o*255)]}`:`#${qt[Math.round(e)]}${qt[Math.round(i)]}${qt[Math.round(r)]}`}},Ut={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(Ut.hueRe);if(e){const[,i,r]=e;switch(r){case"grad":return w.channel.clamp.h(parseFloat(i)*.9);case"rad":return w.channel.clamp.h(parseFloat(i)*180/Math.PI);case"turn":return w.channel.clamp.h(parseFloat(i)*360)}}return w.channel.clamp.h(parseFloat(t))},parse:t=>{const e=t.charCodeAt(0);if(e!==104&&e!==72)return;const i=t.match(Ut.re);if(!i)return;const[,r,o,n,a,s]=i;return je.set({h:Ut._hue2deg(r),s:w.channel.clamp.s(parseFloat(o)),l:w.channel.clamp.l(parseFloat(n)),a:a?w.channel.clamp.a(s?parseFloat(a)/100:parseFloat(a)):1},t)},stringify:t=>{const{h:e,s:i,l:r,a:o}=t;return o<1?`hsla(${w.lang.round(e)}, ${w.lang.round(i)}%, ${w.lang.round(r)}%, ${o})`:`hsl(${w.lang.round(e)}, ${w.lang.round(i)}%, ${w.lang.round(r)}%)`}},pe={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=pe.colors[t];if(e)return ie.parse(e)},stringify:t=>{const e=ie.stringify(t);for(const i in pe.colors)if(pe.colors[i]===e)return i}},ge={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(ge.re);if(!i)return;const[,r,o,n,a,s,l,g,p]=i;return je.set({r:w.channel.clamp.r(o?parseFloat(r)*2.55:parseFloat(r)),g:w.channel.clamp.g(a?parseFloat(n)*2.55:parseFloat(n)),b:w.channel.clamp.b(l?parseFloat(s)*2.55:parseFloat(s)),a:g?w.channel.clamp.a(p?parseFloat(g)/100:parseFloat(g)):1},t)},stringify:t=>{const{r:e,g:i,b:r,a:o}=t;return o<1?`rgba(${w.lang.round(e)}, ${w.lang.round(i)}, ${w.lang.round(r)}, ${w.lang.round(o)})`:`rgb(${w.lang.round(e)}, ${w.lang.round(i)}, ${w.lang.round(r)})`}},kt={format:{keyword:pe,hex:ie,rgb:ge,rgba:ge,hsl:Ut,hsla:Ut},parse:t=>{if(typeof t!="string")return t;const e=ie.parse(t)||ge.parse(t)||Ut.parse(t)||pe.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},stringify:t=>!t.changed&&t.color?t.color:t.type.is(et.HSL)||t.data.r===void 0?Ut.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?ge.stringify(t):ie.stringify(t)},io=(t,e)=>{const i=kt.parse(t);for(const r in e)i[r]=w.channel.clamp[r](e[r]);return kt.stringify(i)},me=(t,e,i=0,r=1)=>{if(typeof t!="number")return io(t,{a:e});const o=je.set({r:w.channel.clamp.r(t),g:w.channel.clamp.g(e),b:w.channel.clamp.b(i),a:w.channel.clamp.a(r)});return kt.stringify(o)},ps=t=>{const{r:e,g:i,b:r}=kt.parse(t),o=.2126*w.channel.toLinear(e)+.7152*w.channel.toLinear(i)+.0722*w.channel.toLinear(r);return w.lang.round(o)},ms=t=>ps(t)>=.5,Cs=ms,_e=t=>!Cs(t),ro=(t,e,i)=>{const r=kt.parse(t),o=r[e],n=w.channel.clamp[e](o+i);return o!==n&&(r[e]=n),kt.stringify(r)},B=(t,e)=>ro(t,"l",e),A=(t,e)=>ro(t,"l",-e),u=(t,e)=>{const i=kt.parse(t),r={};for(const o in e)e[o]&&(r[o]=i[o]+e[o]);return io(t,r)},ys=(t,e,i=50)=>{const{r,g:o,b:n,a}=kt.parse(t),{r:s,g:l,b:g,a:p}=kt.parse(e),d=i/100,h=d*2-1,f=a-p,R=((h*f===-1?h:(h+f)/(1+h*f))+1)/2,O=1-R,N=r*R+s*O,M=o*R+l*O,j=n*R+g*O,V=a*d+p*(1-d);return me(N,M,j,V)},y=(t,e=100)=>{const i=kt.parse(t);return i.r=255-i.r,i.g=255-i.g,i.b=255-i.b,ys(i,t,e)},At={trace:0,debug:1,info:2,warn:3,error:4,fatal:5},F={trace:(...t)=>{},debug:(...t)=>{},info:(...t)=>{},warn:(...t)=>{},error:(...t)=>{},fatal:(...t)=>{}},Li=function(t="fatal"){let e=At.fatal;typeof t=="string"?(t=t.toLowerCase(),t in At&&(e=At[t])):typeof t=="number"&&(e=t),F.trace=()=>{},F.debug=()=>{},F.info=()=>{},F.warn=()=>{},F.error=()=>{},F.fatal=()=>{},e<=At.fatal&&(F.fatal=console.error?console.error.bind(console,ft("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",ft("FATAL"))),e<=At.error&&(F.error=console.error?console.error.bind(console,ft("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",ft("ERROR"))),e<=At.warn&&(F.warn=console.warn?console.warn.bind(console,ft("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",ft("WARN"))),e<=At.info&&(F.info=console.info?console.info.bind(console,ft("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",ft("INFO"))),e<=At.debug&&(F.debug=console.debug?console.debug.bind(console,ft("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ft("DEBUG"))),e<=At.trace&&(F.trace=console.debug?console.debug.bind(console,ft("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",ft("TRACE")))},ft=t=>`%c${Ha().format("ss.SSS")} : ${t} : `,Ue=/<br\s*\/?>/gi,bs=t=>t?no(t).replace(/\\n/g,"#br#").split("#br#"):[""],xs=(()=>{let t=!1;return()=>{t||(Ts(),t=!0)}})();function Ts(){const t="data-temp-href-target";re.addHook("beforeSanitizeAttributes",e=>{e.tagName==="A"&&e.hasAttribute("target")&&e.setAttribute(t,e.getAttribute("target")||"")}),re.addHook("afterSanitizeAttributes",e=>{e.tagName==="A"&&e.hasAttribute(t)&&(e.setAttribute("target",e.getAttribute(t)||""),e.removeAttribute(t),e.getAttribute("target")==="_blank"&&e.setAttribute("rel","noopener"))})}const oo=t=>(xs(),re.sanitize(t)),_r=(t,e)=>{var i;if(((i=e.flowchart)==null?void 0:i.htmlLabels)!==!1){const r=e.securityLevel;r==="antiscript"||r==="strict"?t=oo(t):r!=="loose"&&(t=no(t),t=t.replace(/</g,"&lt;").replace(/>/g,"&gt;"),t=t.replace(/=/g,"&equals;"),t=Bs(t))}return t},xe=(t,e)=>t&&(e.dompurifyConfig?t=re.sanitize(_r(t,e),e.dompurifyConfig).toString():t=re.sanitize(_r(t,e),{FORBID_TAGS:["style"]}).toString(),t),_s=(t,e)=>typeof t=="string"?xe(t,e):t.flat().map(i=>xe(i,e)),ks=t=>Ue.test(t),Ss=t=>t.split(Ue),Bs=t=>t.replace(/#br#/g,"<br/>"),no=t=>t.replace(Ue,"#br#"),vs=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},ao=t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),Ls=function(...t){const e=t.filter(i=>!isNaN(i));return Math.max(...e)},Fs=function(...t){const e=t.filter(i=>!isNaN(i));return Math.min(...e)},hf=function(t){const e=t.split(/(,)/),i=[];for(let r=0;r<e.length;r++){let o=e[r];if(o===","&&r>0&&r+1<e.length){const n=e[r-1],a=e[r+1];As(n,a)&&(o=n+","+a,r++,i.pop())}i.push(Es(o))}return i.join("")},bi=(t,e)=>Math.max(0,t.split(e).length-1),As=(t,e)=>{const i=bi(t,"~"),r=bi(e,"~");return i===1&&r===1},Es=t=>{const e=bi(t,"~");let i=!1;if(e<=1)return t;e%2!==0&&t.startsWith("~")&&(t=t.substring(1),i=!0);const r=[...t];let o=r.indexOf("~"),n=r.lastIndexOf("~");for(;o!==-1&&n!==-1&&o!==n;)r[o]="<",r[n]=">",o=r.indexOf("~"),n=r.lastIndexOf("~");return i&&r.unshift("~"),r.join("")},Fi={getRows:bs,sanitizeText:xe,sanitizeTextOrArray:_s,hasBreaks:ks,splitBreaks:Ss,lineBreakRegex:Ue,removeScript:oo,getUrl:vs,evaluate:ao,getMax:Ls,getMin:Fs},nt=(t,e)=>e?u(t,{s:-40,l:10}):u(t,{s:-40,l:-10}),Ye="#ffffff",Ge="#f2f2f2";let ws=class{constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){var e,i,r,o,n,a,s,l,g,p,d;if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||u(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||u(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||nt(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||nt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||nt(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||nt(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||y(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||y(this.tertiaryColor),this.lineColor=this.lineColor||y(this.background),this.arrowheadColor=this.arrowheadColor||y(this.background),this.textColor=this.textColor||this.primaryTextColor,this.border2=this.border2||this.tertiaryBorderColor,this.nodeBkg=this.nodeBkg||this.primaryColor,this.mainBkg=this.mainBkg||this.primaryColor,this.nodeBorder=this.nodeBorder||this.primaryBorderColor,this.clusterBkg=this.clusterBkg||this.tertiaryColor,this.clusterBorder=this.clusterBorder||this.tertiaryBorderColor,this.defaultLinkColor=this.defaultLinkColor||this.lineColor,this.titleColor=this.titleColor||this.tertiaryTextColor,this.edgeLabelBackground=this.edgeLabelBackground||(this.darkMode?A(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||"grey",this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||A(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||y(this.lineColor),this.sectionBkgColor=this.sectionBkgColor||this.tertiaryColor,this.altSectionBkgColor=this.altSectionBkgColor||"white",this.sectionBkgColor=this.sectionBkgColor||this.secondaryColor,this.sectionBkgColor2=this.sectionBkgColor2||this.primaryColor,this.excludeBkgColor=this.excludeBkgColor||"#eeeeee",this.taskBorderColor=this.taskBorderColor||this.primaryBorderColor,this.taskBkgColor=this.taskBkgColor||this.primaryColor,this.activeTaskBorderColor=this.activeTaskBorderColor||this.primaryColor,this.activeTaskBkgColor=this.activeTaskBkgColor||B(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||u(this.primaryColor,{h:30}),this.cScale4=this.cScale4||u(this.primaryColor,{h:60}),this.cScale5=this.cScale5||u(this.primaryColor,{h:90}),this.cScale6=this.cScale6||u(this.primaryColor,{h:120}),this.cScale7=this.cScale7||u(this.primaryColor,{h:150}),this.cScale8=this.cScale8||u(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||u(this.primaryColor,{h:270}),this.cScale10=this.cScale10||u(this.primaryColor,{h:300}),this.cScale11=this.cScale11||u(this.primaryColor,{h:330}),this.darkMode)for(let f=0;f<this.THEME_COLOR_LIMIT;f++)this["cScale"+f]=A(this["cScale"+f],75);else for(let f=0;f<this.THEME_COLOR_LIMIT;f++)this["cScale"+f]=A(this["cScale"+f],25);for(let f=0;f<this.THEME_COLOR_LIMIT;f++)this["cScaleInv"+f]=this["cScaleInv"+f]||y(this["cScale"+f]);for(let f=0;f<this.THEME_COLOR_LIMIT;f++)this.darkMode?this["cScalePeer"+f]=this["cScalePeer"+f]||B(this["cScale"+f],10):this["cScalePeer"+f]=this["cScalePeer"+f]||A(this["cScale"+f],10);this.scaleLabelColor=this.scaleLabelColor||this.labelTextColor;for(let f=0;f<this.THEME_COLOR_LIMIT;f++)this["cScaleLabel"+f]=this["cScaleLabel"+f]||this.scaleLabelColor;const h=this.darkMode?-4:-1;for(let f=0;f<5;f++)this["surface"+f]=this["surface"+f]||u(this.mainBkg,{h:180,s:-15,l:h*(5+f*3)}),this["surfacePeer"+f]=this["surfacePeer"+f]||u(this.mainBkg,{h:180,s:-15,l:h*(8+f*3)});this.classText=this.classText||this.textColor,this.fillType0=this.fillType0||this.primaryColor,this.fillType1=this.fillType1||this.secondaryColor,this.fillType2=this.fillType2||u(this.primaryColor,{h:64}),this.fillType3=this.fillType3||u(this.secondaryColor,{h:64}),this.fillType4=this.fillType4||u(this.primaryColor,{h:-64}),this.fillType5=this.fillType5||u(this.secondaryColor,{h:-64}),this.fillType6=this.fillType6||u(this.primaryColor,{h:128}),this.fillType7=this.fillType7||u(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||u(this.primaryColor,{l:-10}),this.pie5=this.pie5||u(this.secondaryColor,{l:-10}),this.pie6=this.pie6||u(this.tertiaryColor,{l:-10}),this.pie7=this.pie7||u(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||u(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||u(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||u(this.primaryColor,{h:60,l:-20}),this.pie11=this.pie11||u(this.primaryColor,{h:-60,l:-20}),this.pie12=this.pie12||u(this.primaryColor,{h:120,l:-10}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||u(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||u(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||u(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||u(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||u(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||u(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||_e(this.quadrant1Fill)?B(this.quadrant1Fill):A(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((e=this.xyChart)==null?void 0:e.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((r=this.xyChart)==null?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((a=this.xyChart)==null?void 0:a.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((s=this.xyChart)==null?void 0:s.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((l=this.xyChart)==null?void 0:l.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((g=this.xyChart)==null?void 0:g.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((d=this.xyChart)==null?void 0:d.plotColorPalette)||"#FFF4DD,#FFD8B1,#FFA07A,#ECEFF1,#D6DBDF,#C3E0A8,#FFB6A4,#FFD74D,#738FA7,#FFFFF0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?A(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||u(this.primaryColor,{h:-30}),this.git4=this.git4||u(this.primaryColor,{h:-60}),this.git5=this.git5||u(this.primaryColor,{h:-90}),this.git6=this.git6||u(this.primaryColor,{h:60}),this.git7=this.git7||u(this.primaryColor,{h:120}),this.darkMode?(this.git0=B(this.git0,25),this.git1=B(this.git1,25),this.git2=B(this.git2,25),this.git3=B(this.git3,25),this.git4=B(this.git4,25),this.git5=B(this.git5,25),this.git6=B(this.git6,25),this.git7=B(this.git7,25)):(this.git0=A(this.git0,25),this.git1=A(this.git1,25),this.git2=A(this.git2,25),this.git3=A(this.git3,25),this.git4=A(this.git4,25),this.git5=A(this.git5,25),this.git6=A(this.git6,25),this.git7=A(this.git7,25)),this.gitInv0=this.gitInv0||y(this.git0),this.gitInv1=this.gitInv1||y(this.git1),this.gitInv2=this.gitInv2||y(this.git2),this.gitInv3=this.gitInv3||y(this.git3),this.gitInv4=this.gitInv4||y(this.git4),this.gitInv5=this.gitInv5||y(this.git5),this.gitInv6=this.gitInv6||y(this.git6),this.gitInv7=this.gitInv7||y(this.git7),this.branchLabelColor=this.branchLabelColor||(this.darkMode?"black":this.labelTextColor),this.gitBranchLabel0=this.gitBranchLabel0||this.branchLabelColor,this.gitBranchLabel1=this.gitBranchLabel1||this.branchLabelColor,this.gitBranchLabel2=this.gitBranchLabel2||this.branchLabelColor,this.gitBranchLabel3=this.gitBranchLabel3||this.branchLabelColor,this.gitBranchLabel4=this.gitBranchLabel4||this.branchLabelColor,this.gitBranchLabel5=this.gitBranchLabel5||this.branchLabelColor,this.gitBranchLabel6=this.gitBranchLabel6||this.branchLabelColor,this.gitBranchLabel7=this.gitBranchLabel7||this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ye,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ge}calculate(e){if(typeof e!="object"){this.updateColors();return}const i=Object.keys(e);i.forEach(r=>{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Os=t=>{const e=new ws;return e.calculate(t),e};let Ms=class{constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=B(this.primaryColor,16),this.tertiaryColor=u(this.primaryColor,{h:-160}),this.primaryBorderColor=y(this.background),this.secondaryBorderColor=nt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=nt(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=B(y("#323D47"),10),this.lineColor="calculated",this.border1="#81B1DB",this.border2=me(255,255,255,.25),this.arrowheadColor="calculated",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#181818",this.textColor="#ccc",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#F9FFFE",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="calculated",this.activationBkgColor="calculated",this.sequenceNumberColor="black",this.sectionBkgColor=A("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=A(this.sectionBkgColor,10),this.taskBorderColor=me(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=me(255,255,255,50),this.activeTaskBkgColor="#81B1DB",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="grey",this.critBorderColor="#E83737",this.critBkgColor="#E83737",this.taskTextDarkColor="calculated",this.todayLineColor="#DB5757",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){var e,i,r,o,n,a,s,l,g,p,d;this.secondBkg=B(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=B(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=B(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=u(this.primaryColor,{h:64}),this.fillType3=u(this.secondaryColor,{h:64}),this.fillType4=u(this.primaryColor,{h:-64}),this.fillType5=u(this.secondaryColor,{h:-64}),this.fillType6=u(this.primaryColor,{h:128}),this.fillType7=u(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||u(this.primaryColor,{h:30}),this.cScale4=this.cScale4||u(this.primaryColor,{h:60}),this.cScale5=this.cScale5||u(this.primaryColor,{h:90}),this.cScale6=this.cScale6||u(this.primaryColor,{h:120}),this.cScale7=this.cScale7||u(this.primaryColor,{h:150}),this.cScale8=this.cScale8||u(this.primaryColor,{h:210}),this.cScale9=this.cScale9||u(this.primaryColor,{h:270}),this.cScale10=this.cScale10||u(this.primaryColor,{h:300}),this.cScale11=this.cScale11||u(this.primaryColor,{h:330});for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleInv"+h]=this["cScaleInv"+h]||y(this["cScale"+h]);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScalePeer"+h]=this["cScalePeer"+h]||B(this["cScale"+h],10);for(let h=0;h<5;h++)this["surface"+h]=this["surface"+h]||u(this.mainBkg,{h:30,s:-30,l:-(-10+h*4)}),this["surfacePeer"+h]=this["surfacePeer"+h]||u(this.mainBkg,{h:30,s:-30,l:-(-7+h*4)});this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleLabel"+h]=this["cScaleLabel"+h]||this.scaleLabelColor;for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["pie"+h]=this["cScale"+h];this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||u(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||u(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||u(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||u(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||u(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||u(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||_e(this.quadrant1Fill)?B(this.quadrant1Fill):A(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((e=this.xyChart)==null?void 0:e.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((r=this.xyChart)==null?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((a=this.xyChart)==null?void 0:a.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((s=this.xyChart)==null?void 0:s.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((l=this.xyChart)==null?void 0:l.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((g=this.xyChart)==null?void 0:g.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((d=this.xyChart)==null?void 0:d.plotColorPalette)||"#3498db,#2ecc71,#e74c3c,#f1c40f,#bdc3c7,#ffffff,#34495e,#9b59b6,#1abc9c,#e67e22"},this.classText=this.primaryTextColor,this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||(this.darkMode?A(this.secondaryColor,30):this.secondaryColor),this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=B(this.secondaryColor,20),this.git1=B(this.pie2||this.secondaryColor,20),this.git2=B(this.pie3||this.tertiaryColor,20),this.git3=B(this.pie4||u(this.primaryColor,{h:-30}),20),this.git4=B(this.pie5||u(this.primaryColor,{h:-60}),20),this.git5=B(this.pie6||u(this.primaryColor,{h:-90}),10),this.git6=B(this.pie7||u(this.primaryColor,{h:60}),10),this.git7=B(this.pie8||u(this.primaryColor,{h:120}),20),this.gitInv0=this.gitInv0||y(this.git0),this.gitInv1=this.gitInv1||y(this.git1),this.gitInv2=this.gitInv2||y(this.git2),this.gitInv3=this.gitInv3||y(this.git3),this.gitInv4=this.gitInv4||y(this.git4),this.gitInv5=this.gitInv5||y(this.git5),this.gitInv6=this.gitInv6||y(this.git6),this.gitInv7=this.gitInv7||y(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||y(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||y(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||B(this.background,12),this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||B(this.background,2)}calculate(e){if(typeof e!="object"){this.updateColors();return}const i=Object.keys(e);i.forEach(r=>{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const Is=t=>{const e=new Ms;return e.calculate(t),e};let Ds=class{constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=u(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=u(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.primaryColor,this.darkMode),this.secondaryBorderColor=nt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=nt(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="#e8e8e8",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.sectionBkgColor=me(102,102,255,.49),this.altSectionBkgColor="white",this.sectionBkgColor2="#fff400",this.taskBorderColor="#534fbc",this.taskBkgColor="#8a90dd",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="#534fbc",this.activeTaskBkgColor="#bfc7ff",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){var e,i,r,o,n,a,s,l,g,p,d;this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||u(this.primaryColor,{h:30}),this.cScale4=this.cScale4||u(this.primaryColor,{h:60}),this.cScale5=this.cScale5||u(this.primaryColor,{h:90}),this.cScale6=this.cScale6||u(this.primaryColor,{h:120}),this.cScale7=this.cScale7||u(this.primaryColor,{h:150}),this.cScale8=this.cScale8||u(this.primaryColor,{h:210}),this.cScale9=this.cScale9||u(this.primaryColor,{h:270}),this.cScale10=this.cScale10||u(this.primaryColor,{h:300}),this.cScale11=this.cScale11||u(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||A(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||A(this.tertiaryColor,40);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScale"+h]=A(this["cScale"+h],10),this["cScalePeer"+h]=this["cScalePeer"+h]||A(this["cScale"+h],25);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleInv"+h]=this["cScaleInv"+h]||u(this["cScale"+h],{h:180});for(let h=0;h<5;h++)this["surface"+h]=this["surface"+h]||u(this.mainBkg,{h:30,l:-(5+h*5)}),this["surfacePeer"+h]=this["surfacePeer"+h]||u(this.mainBkg,{h:30,l:-(7+h*5)});if(this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor,this.labelTextColor!=="calculated"){this.cScaleLabel0=this.cScaleLabel0||y(this.labelTextColor),this.cScaleLabel3=this.cScaleLabel3||y(this.labelTextColor);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleLabel"+h]=this["cScaleLabel"+h]||this.labelTextColor}this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.textColor,this.edgeLabelBackground=this.labelBackground,this.actorBorder=B(this.border1,23),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.signalColor=this.textColor,this.signalTextColor=this.textColor,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,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||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=u(this.primaryColor,{h:64}),this.fillType3=u(this.secondaryColor,{h:64}),this.fillType4=u(this.primaryColor,{h:-64}),this.fillType5=u(this.secondaryColor,{h:-64}),this.fillType6=u(this.primaryColor,{h:128}),this.fillType7=u(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||u(this.tertiaryColor,{l:-40}),this.pie4=this.pie4||u(this.primaryColor,{l:-10}),this.pie5=this.pie5||u(this.secondaryColor,{l:-30}),this.pie6=this.pie6||u(this.tertiaryColor,{l:-20}),this.pie7=this.pie7||u(this.primaryColor,{h:60,l:-20}),this.pie8=this.pie8||u(this.primaryColor,{h:-60,l:-40}),this.pie9=this.pie9||u(this.primaryColor,{h:120,l:-40}),this.pie10=this.pie10||u(this.primaryColor,{h:60,l:-40}),this.pie11=this.pie11||u(this.primaryColor,{h:-90,l:-40}),this.pie12=this.pie12||u(this.primaryColor,{h:120,l:-30}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||u(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||u(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||u(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||u(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||u(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||u(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||_e(this.quadrant1Fill)?B(this.quadrant1Fill):A(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((e=this.xyChart)==null?void 0:e.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((r=this.xyChart)==null?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((a=this.xyChart)==null?void 0:a.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((s=this.xyChart)==null?void 0:s.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((l=this.xyChart)==null?void 0:l.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((g=this.xyChart)==null?void 0:g.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((d=this.xyChart)==null?void 0:d.plotColorPalette)||"#ECECFF,#8493A6,#FFC3A0,#DCDDE1,#B8E994,#D1A36F,#C3CDE6,#FFB6C1,#496078,#F8F3E3"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.labelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||u(this.primaryColor,{h:-30}),this.git4=this.git4||u(this.primaryColor,{h:-60}),this.git5=this.git5||u(this.primaryColor,{h:-90}),this.git6=this.git6||u(this.primaryColor,{h:60}),this.git7=this.git7||u(this.primaryColor,{h:120}),this.darkMode?(this.git0=B(this.git0,25),this.git1=B(this.git1,25),this.git2=B(this.git2,25),this.git3=B(this.git3,25),this.git4=B(this.git4,25),this.git5=B(this.git5,25),this.git6=B(this.git6,25),this.git7=B(this.git7,25)):(this.git0=A(this.git0,25),this.git1=A(this.git1,25),this.git2=A(this.git2,25),this.git3=A(this.git3,25),this.git4=A(this.git4,25),this.git5=A(this.git5,25),this.git6=A(this.git6,25),this.git7=A(this.git7,25)),this.gitInv0=this.gitInv0||A(y(this.git0),25),this.gitInv1=this.gitInv1||y(this.git1),this.gitInv2=this.gitInv2||y(this.git2),this.gitInv3=this.gitInv3||y(this.git3),this.gitInv4=this.gitInv4||y(this.git4),this.gitInv5=this.gitInv5||y(this.git5),this.gitInv6=this.gitInv6||y(this.git6),this.gitInv7=this.gitInv7||y(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||y(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||y(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ye,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ge}calculate(e){if(typeof e!="object"){this.updateColors();return}const i=Object.keys(e);i.forEach(r=>{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const $s=t=>{const e=new Ds;return e.calculate(t),e};let Rs=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=B("#cde498",10),this.primaryBorderColor=nt(this.primaryColor,this.darkMode),this.secondaryBorderColor=nt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=nt(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.primaryColor),this.lineColor=y(this.background),this.textColor=y(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="grey",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,i,r,o,n,a,s,l,g,p,d;this.actorBorder=A(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||u(this.primaryColor,{h:30}),this.cScale4=this.cScale4||u(this.primaryColor,{h:60}),this.cScale5=this.cScale5||u(this.primaryColor,{h:90}),this.cScale6=this.cScale6||u(this.primaryColor,{h:120}),this.cScale7=this.cScale7||u(this.primaryColor,{h:150}),this.cScale8=this.cScale8||u(this.primaryColor,{h:210}),this.cScale9=this.cScale9||u(this.primaryColor,{h:270}),this.cScale10=this.cScale10||u(this.primaryColor,{h:300}),this.cScale11=this.cScale11||u(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||A(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||A(this.tertiaryColor,40);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScale"+h]=A(this["cScale"+h],10),this["cScalePeer"+h]=this["cScalePeer"+h]||A(this["cScale"+h],25);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleInv"+h]=this["cScaleInv"+h]||u(this["cScale"+h],{h:180});this.scaleLabelColor=this.scaleLabelColor!=="calculated"&&this.scaleLabelColor?this.scaleLabelColor:this.labelTextColor;for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleLabel"+h]=this["cScaleLabel"+h]||this.scaleLabelColor;for(let h=0;h<5;h++)this["surface"+h]=this["surface"+h]||u(this.mainBkg,{h:30,s:-30,l:-(5+h*5)}),this["surfacePeer"+h]=this["surfacePeer"+h]||u(this.mainBkg,{h:30,s:-30,l:-(8+h*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.taskBorderColor=this.border1,this.taskTextColor=this.taskTextLightColor,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=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||"#f0f0f0",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor=this.lineColor,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=u(this.primaryColor,{h:64}),this.fillType3=u(this.secondaryColor,{h:64}),this.fillType4=u(this.primaryColor,{h:-64}),this.fillType5=u(this.secondaryColor,{h:-64}),this.fillType6=u(this.primaryColor,{h:128}),this.fillType7=u(this.secondaryColor,{h:128}),this.pie1=this.pie1||this.primaryColor,this.pie2=this.pie2||this.secondaryColor,this.pie3=this.pie3||this.tertiaryColor,this.pie4=this.pie4||u(this.primaryColor,{l:-30}),this.pie5=this.pie5||u(this.secondaryColor,{l:-30}),this.pie6=this.pie6||u(this.tertiaryColor,{h:40,l:-40}),this.pie7=this.pie7||u(this.primaryColor,{h:60,l:-10}),this.pie8=this.pie8||u(this.primaryColor,{h:-60,l:-10}),this.pie9=this.pie9||u(this.primaryColor,{h:120,l:0}),this.pie10=this.pie10||u(this.primaryColor,{h:60,l:-50}),this.pie11=this.pie11||u(this.primaryColor,{h:-60,l:-50}),this.pie12=this.pie12||u(this.primaryColor,{h:120,l:-50}),this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||u(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||u(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||u(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||u(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||u(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||u(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||_e(this.quadrant1Fill)?B(this.quadrant1Fill):A(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((e=this.xyChart)==null?void 0:e.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((r=this.xyChart)==null?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((a=this.xyChart)==null?void 0:a.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((s=this.xyChart)==null?void 0:s.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((l=this.xyChart)==null?void 0:l.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((g=this.xyChart)==null?void 0:g.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((d=this.xyChart)==null?void 0:d.plotColorPalette)||"#CDE498,#FF6B6B,#A0D2DB,#D7BDE2,#F0F0F0,#FFC3A0,#7FD8BE,#FF9A8B,#FAF3E0,#FFF176"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=this.git0||this.primaryColor,this.git1=this.git1||this.secondaryColor,this.git2=this.git2||this.tertiaryColor,this.git3=this.git3||u(this.primaryColor,{h:-30}),this.git4=this.git4||u(this.primaryColor,{h:-60}),this.git5=this.git5||u(this.primaryColor,{h:-90}),this.git6=this.git6||u(this.primaryColor,{h:60}),this.git7=this.git7||u(this.primaryColor,{h:120}),this.darkMode?(this.git0=B(this.git0,25),this.git1=B(this.git1,25),this.git2=B(this.git2,25),this.git3=B(this.git3,25),this.git4=B(this.git4,25),this.git5=B(this.git5,25),this.git6=B(this.git6,25),this.git7=B(this.git7,25)):(this.git0=A(this.git0,25),this.git1=A(this.git1,25),this.git2=A(this.git2,25),this.git3=A(this.git3,25),this.git4=A(this.git4,25),this.git5=A(this.git5,25),this.git6=A(this.git6,25),this.git7=A(this.git7,25)),this.gitInv0=this.gitInv0||y(this.git0),this.gitInv1=this.gitInv1||y(this.git1),this.gitInv2=this.gitInv2||y(this.git2),this.gitInv3=this.gitInv3||y(this.git3),this.gitInv4=this.gitInv4||y(this.git4),this.gitInv5=this.gitInv5||y(this.git5),this.gitInv6=this.gitInv6||y(this.git6),this.gitInv7=this.gitInv7||y(this.git7),this.gitBranchLabel0=this.gitBranchLabel0||y(this.labelTextColor),this.gitBranchLabel1=this.gitBranchLabel1||this.labelTextColor,this.gitBranchLabel2=this.gitBranchLabel2||this.labelTextColor,this.gitBranchLabel3=this.gitBranchLabel3||y(this.labelTextColor),this.gitBranchLabel4=this.gitBranchLabel4||this.labelTextColor,this.gitBranchLabel5=this.gitBranchLabel5||this.labelTextColor,this.gitBranchLabel6=this.gitBranchLabel6||this.labelTextColor,this.gitBranchLabel7=this.gitBranchLabel7||this.labelTextColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ye,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ge}calculate(e){if(typeof e!="object"){this.updateColors();return}const i=Object.keys(e);i.forEach(r=>{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}};const qs=t=>{const e=new Rs;return e.calculate(t),e};class Ps{constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=B(this.contrast,55),this.background="#ffffff",this.tertiaryColor=u(this.primaryColor,{h:-160}),this.primaryBorderColor=nt(this.primaryColor,this.darkMode),this.secondaryBorderColor=nt(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=nt(this.tertiaryColor,this.darkMode),this.primaryTextColor=y(this.primaryColor),this.secondaryTextColor=y(this.secondaryColor),this.tertiaryTextColor=y(this.tertiaryColor),this.lineColor=y(this.background),this.textColor=y(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){var e,i,r,o,n,a,s,l,g,p,d;this.secondBkg=B(this.contrast,55),this.border2=this.contrast,this.actorBorder=B(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 h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleInv"+h]=this["cScaleInv"+h]||y(this["cScale"+h]);for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this.darkMode?this["cScalePeer"+h]=this["cScalePeer"+h]||B(this["cScale"+h],10):this["cScalePeer"+h]=this["cScalePeer"+h]||A(this["cScale"+h],10);this.scaleLabelColor=this.scaleLabelColor||(this.darkMode?"black":this.labelTextColor),this.cScaleLabel0=this.cScaleLabel0||this.cScale1,this.cScaleLabel2=this.cScaleLabel2||this.cScale1;for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["cScaleLabel"+h]=this["cScaleLabel"+h]||this.scaleLabelColor;for(let h=0;h<5;h++)this["surface"+h]=this["surface"+h]||u(this.mainBkg,{l:-(5+h*5)}),this["surfacePeer"+h]=this["surfacePeer"+h]||u(this.mainBkg,{l:-(8+h*5)});this.nodeBkg=this.mainBkg,this.nodeBorder=this.border1,this.clusterBkg=this.secondBkg,this.clusterBorder=this.border2,this.defaultLinkColor=this.lineColor,this.titleColor=this.text,this.sectionBkgColor=B(this.contrast,30),this.sectionBkgColor2=B(this.contrast,30),this.taskBorderColor=A(this.contrast,10),this.taskBkgColor=this.contrast,this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor=this.text,this.taskTextOutsideColor=this.taskTextDarkColor,this.activeTaskBorderColor=this.taskBorderColor,this.activeTaskBkgColor=this.mainBkg,this.gridColor=B(this.border1,30),this.doneTaskBkgColor=this.done,this.doneTaskBorderColor=this.lineColor,this.critBkgColor=this.critical,this.critBorderColor=A(this.critBkgColor,10),this.todayLineColor=this.critBkgColor,this.transitionColor=this.transitionColor||"#000",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||"#f4f4f4",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.stateBorder=this.stateBorder||"#000",this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#222",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.classText=this.primaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=u(this.primaryColor,{h:64}),this.fillType3=u(this.secondaryColor,{h:64}),this.fillType4=u(this.primaryColor,{h:-64}),this.fillType5=u(this.secondaryColor,{h:-64}),this.fillType6=u(this.primaryColor,{h:128}),this.fillType7=u(this.secondaryColor,{h:128});for(let h=0;h<this.THEME_COLOR_LIMIT;h++)this["pie"+h]=this["cScale"+h];this.pie12=this.pie0,this.pieTitleTextSize=this.pieTitleTextSize||"25px",this.pieTitleTextColor=this.pieTitleTextColor||this.taskTextDarkColor,this.pieSectionTextSize=this.pieSectionTextSize||"17px",this.pieSectionTextColor=this.pieSectionTextColor||this.textColor,this.pieLegendTextSize=this.pieLegendTextSize||"17px",this.pieLegendTextColor=this.pieLegendTextColor||this.taskTextDarkColor,this.pieStrokeColor=this.pieStrokeColor||"black",this.pieStrokeWidth=this.pieStrokeWidth||"2px",this.pieOuterStrokeWidth=this.pieOuterStrokeWidth||"2px",this.pieOuterStrokeColor=this.pieOuterStrokeColor||"black",this.pieOpacity=this.pieOpacity||"0.7",this.quadrant1Fill=this.quadrant1Fill||this.primaryColor,this.quadrant2Fill=this.quadrant2Fill||u(this.primaryColor,{r:5,g:5,b:5}),this.quadrant3Fill=this.quadrant3Fill||u(this.primaryColor,{r:10,g:10,b:10}),this.quadrant4Fill=this.quadrant4Fill||u(this.primaryColor,{r:15,g:15,b:15}),this.quadrant1TextFill=this.quadrant1TextFill||this.primaryTextColor,this.quadrant2TextFill=this.quadrant2TextFill||u(this.primaryTextColor,{r:-5,g:-5,b:-5}),this.quadrant3TextFill=this.quadrant3TextFill||u(this.primaryTextColor,{r:-10,g:-10,b:-10}),this.quadrant4TextFill=this.quadrant4TextFill||u(this.primaryTextColor,{r:-15,g:-15,b:-15}),this.quadrantPointFill=this.quadrantPointFill||_e(this.quadrant1Fill)?B(this.quadrant1Fill):A(this.quadrant1Fill),this.quadrantPointTextFill=this.quadrantPointTextFill||this.primaryTextColor,this.quadrantXAxisTextFill=this.quadrantXAxisTextFill||this.primaryTextColor,this.quadrantYAxisTextFill=this.quadrantYAxisTextFill||this.primaryTextColor,this.quadrantInternalBorderStrokeFill=this.quadrantInternalBorderStrokeFill||this.primaryBorderColor,this.quadrantExternalBorderStrokeFill=this.quadrantExternalBorderStrokeFill||this.primaryBorderColor,this.quadrantTitleFill=this.quadrantTitleFill||this.primaryTextColor,this.xyChart={backgroundColor:((e=this.xyChart)==null?void 0:e.backgroundColor)||this.background,titleColor:((i=this.xyChart)==null?void 0:i.titleColor)||this.primaryTextColor,xAxisTitleColor:((r=this.xyChart)==null?void 0:r.xAxisTitleColor)||this.primaryTextColor,xAxisLabelColor:((o=this.xyChart)==null?void 0:o.xAxisLabelColor)||this.primaryTextColor,xAxisTickColor:((n=this.xyChart)==null?void 0:n.xAxisTickColor)||this.primaryTextColor,xAxisLineColor:((a=this.xyChart)==null?void 0:a.xAxisLineColor)||this.primaryTextColor,yAxisTitleColor:((s=this.xyChart)==null?void 0:s.yAxisTitleColor)||this.primaryTextColor,yAxisLabelColor:((l=this.xyChart)==null?void 0:l.yAxisLabelColor)||this.primaryTextColor,yAxisTickColor:((g=this.xyChart)==null?void 0:g.yAxisTickColor)||this.primaryTextColor,yAxisLineColor:((p=this.xyChart)==null?void 0:p.yAxisLineColor)||this.primaryTextColor,plotColorPalette:((d=this.xyChart)==null?void 0:d.plotColorPalette)||"#EEE,#6BB8E4,#8ACB88,#C7ACD6,#E8DCC2,#FFB2A8,#FFF380,#7E8D91,#FFD8B1,#FAF3E0"},this.requirementBackground=this.requirementBackground||this.primaryColor,this.requirementBorderColor=this.requirementBorderColor||this.primaryBorderColor,this.requirementBorderSize=this.requirementBorderSize||"1",this.requirementTextColor=this.requirementTextColor||this.primaryTextColor,this.relationColor=this.relationColor||this.lineColor,this.relationLabelBackground=this.relationLabelBackground||this.edgeLabelBackground,this.relationLabelColor=this.relationLabelColor||this.actorTextColor,this.git0=A(this.pie1,25)||this.primaryColor,this.git1=this.pie2||this.secondaryColor,this.git2=this.pie3||this.tertiaryColor,this.git3=this.pie4||u(this.primaryColor,{h:-30}),this.git4=this.pie5||u(this.primaryColor,{h:-60}),this.git5=this.pie6||u(this.primaryColor,{h:-90}),this.git6=this.pie7||u(this.primaryColor,{h:60}),this.git7=this.pie8||u(this.primaryColor,{h:120}),this.gitInv0=this.gitInv0||y(this.git0),this.gitInv1=this.gitInv1||y(this.git1),this.gitInv2=this.gitInv2||y(this.git2),this.gitInv3=this.gitInv3||y(this.git3),this.gitInv4=this.gitInv4||y(this.git4),this.gitInv5=this.gitInv5||y(this.git5),this.gitInv6=this.gitInv6||y(this.git6),this.gitInv7=this.gitInv7||y(this.git7),this.branchLabelColor=this.branchLabelColor||this.labelTextColor,this.gitBranchLabel0=this.branchLabelColor,this.gitBranchLabel1="white",this.gitBranchLabel2=this.branchLabelColor,this.gitBranchLabel3="white",this.gitBranchLabel4=this.branchLabelColor,this.gitBranchLabel5=this.branchLabelColor,this.gitBranchLabel6=this.branchLabelColor,this.gitBranchLabel7=this.branchLabelColor,this.tagLabelColor=this.tagLabelColor||this.primaryTextColor,this.tagLabelBackground=this.tagLabelBackground||this.primaryColor,this.tagLabelBorder=this.tagBorder||this.primaryBorderColor,this.tagLabelFontSize=this.tagLabelFontSize||"10px",this.commitLabelColor=this.commitLabelColor||this.secondaryTextColor,this.commitLabelBackground=this.commitLabelBackground||this.secondaryColor,this.commitLabelFontSize=this.commitLabelFontSize||"10px",this.attributeBackgroundColorOdd=this.attributeBackgroundColorOdd||Ye,this.attributeBackgroundColorEven=this.attributeBackgroundColorEven||Ge}calculate(e){if(typeof e!="object"){this.updateColors();return}const i=Object.keys(e);i.forEach(r=>{this[r]=e[r]}),this.updateColors(),i.forEach(r=>{this[r]=e[r]})}}const zs=t=>{const e=new Ps;return e.calculate(t),e},Ot={base:{getThemeVariables:Os},dark:{getThemeVariables:Is},default:{getThemeVariables:$s},forest:{getThemeVariables:qs},neutral:{getThemeVariables:zs}},Et={flowchart:{useMaxWidth:!0,titleTopMargin:25,subGraphTitleMargin:{top:0,bottom:0},diagramPadding:8,htmlLabels:!0,nodeSpacing:50,rankSpacing:50,curve:"basis",padding:15,defaultRenderer:"dagre-wrapper",wrappingWidth:200},sequence:{useMaxWidth:!0,hideUnusedParticipants:!1,activationWidth:10,diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",mirrorActors:!0,forceMenus:!1,bottomMarginAdj:1,rightAngles:!1,showSequenceNumbers:!1,actorFontSize:14,actorFontFamily:'"Open Sans", sans-serif',actorFontWeight:400,noteFontSize:14,noteFontFamily:'"trebuchet ms", verdana, arial, sans-serif',noteFontWeight:400,noteAlign:"center",messageFontSize:16,messageFontFamily:'"trebuchet ms", verdana, arial, sans-serif',messageFontWeight:400,wrap:!1,wrapPadding:10,labelBoxWidth:50,labelBoxHeight:20},gantt:{useMaxWidth:!0,titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,rightPadding:75,leftPadding:75,gridLineStartPadding:35,fontSize:11,sectionFontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d",topAxis:!1,displayMode:"",weekday:"sunday"},journey:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"]},class:{useMaxWidth:!0,titleTopMargin:25,arrowMarkerAbsolute:!1,dividerMargin:10,padding:5,textHeight:10,defaultRenderer:"dagre-wrapper",htmlLabels:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,stroke:"gray",fill:"honeydew",fontSize:12},pie:{useMaxWidth:!0,textPosition:.75},quadrantChart:{useMaxWidth:!0,chartWidth:500,chartHeight:500,titleFontSize:20,titlePadding:10,quadrantPadding:5,xAxisLabelPadding:5,yAxisLabelPadding:5,xAxisLabelFontSize:16,yAxisLabelFontSize:16,quadrantLabelFontSize:16,quadrantTextTopPadding:5,pointTextPadding:5,pointLabelFontSize:12,pointRadius:5,xAxisPosition:"top",yAxisPosition:"left",quadrantInternalBorderStrokeWidth:1,quadrantExternalBorderStrokeWidth:2},xyChart:{useMaxWidth:!0,width:700,height:500,titleFontSize:20,titlePadding:10,showTitle:!0,xAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},yAxis:{$ref:"#/$defs/XYChartAxisConfig",showLabel:!0,labelFontSize:14,labelPadding:5,showTitle:!0,titleFontSize:16,titlePadding:5,showTick:!0,tickLength:5,tickWidth:2,showAxisLine:!0,axisLineWidth:2},chartOrientation:"vertical",plotReservedSpacePercent:50},requirement:{useMaxWidth:!0,rect_fill:"#f9f9f9",text_color:"#333",rect_border_size:"0.5px",rect_border_color:"#bbb",rect_min_width:200,rect_min_height:200,fontSize:14,rect_padding:10,line_height:20},mindmap:{useMaxWidth:!0,padding:10,maxNodeWidth:200},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},theme:"default",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","maxEdges"],deterministicIds:!1,fontSize:16},so={...Et,deterministicIDSeed:void 0,themeCSS:void 0,themeVariables:Ot.default.getThemeVariables(),sequence:{...Et.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:{...Et.gantt,tickInterval:void 0,useWidth:void 0},c4:{...Et.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:{...Et.pie,useWidth:984},xyChart:{...Et.xyChart,useWidth:void 0},requirement:{...Et.requirement,useWidth:void 0},gitGraph:{...Et.gitGraph,useMaxWidth:!1},sankey:{...Et.sankey,useMaxWidth:!1}},lo=(t,e="")=>Object.keys(t).reduce((i,r)=>Array.isArray(t[r])?i:typeof t[r]=="object"&&t[r]!==null?[...i,e+r,...lo(t[r],"")]:[...i,e+r],[]),Ns=new Set(lo(so,"")),Ws=so,Ie=t=>{if(F.debug("sanitizeDirective called with",t),!(typeof t!="object"||t==null)){if(Array.isArray(t)){t.forEach(e=>Ie(e));return}for(const e of Object.keys(t)){if(F.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!Ns.has(e)||t[e]==null){F.debug("sanitize deleting key: ",e),delete t[e];continue}if(typeof t[e]=="object"){F.debug("sanitizing object",e),Ie(t[e]);continue}const i=["themeCSS","fontFamily","altFontFamily"];for(const r of i)e.includes(r)&&(F.debug("sanitizing css option",e),t[e]=Hs(t[e]))}if(t.themeVariables)for(const e of Object.keys(t.themeVariables)){const i=t.themeVariables[e];i!=null&&i.match&&!i.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}F.debug("After sanitization",t)}},Hs=t=>{let e=0,i=0;for(const r of t){if(e<i)return"{ /* ERROR: Unbalanced CSS */ }";r==="{"?e++:r==="}"&&i++}return e!==i?"{ /* ERROR: Unbalanced CSS */ }":t},ho=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,Ce=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,js=/\s*%%.*\n/gm;class co extends Error{constructor(e){super(e),this.name="UnknownDiagramError"}}const oe={},Ve=function(t,e){t=t.replace(ho,"").replace(Ce,"").replace(js,`
`);for(const[i,{detector:r}]of Object.entries(oe))if(r(t,e))return i;throw new co(`No diagram type detected matching given configuration for text: ${t}`)},uo=(...t)=>{for(const{id:e,detector:i,loader:r}of t)fo(e,i,r)},fo=(t,e,i)=>{oe[t]?F.error(`Detector with key ${t} already exists`):oe[t]={detector:e,loader:i},F.debug(`Detector with key ${t} added${i?" with loader":""}`)},Us=t=>oe[t].loader,xi=(t,e,{depth:i=2,clobber:r=!1}={})=>{const o={depth:i,clobber:r};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach(n=>xi(t,n,o)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(n=>{t.includes(n)||t.push(n)}),t):t===void 0||i<=0?t!=null&&typeof t=="object"&&typeof e=="object"?Object.assign(t,e):e:(e!==void 0&&typeof t=="object"&&typeof e=="object"&&Object.keys(e).forEach(n=>{typeof e[n]=="object"&&(t[n]===void 0||typeof t[n]=="object")?(t[n]===void 0&&(t[n]=Array.isArray(e[n])?[]:{}),t[n]=xi(t[n],e[n],{depth:i-1,clobber:r})):(r||typeof t[n]!="object"&&typeof e[n]!="object")&&(t[n]=e[n])}),t)},it=xi,Ys="​",Gs={curveBasis:Pn,curveBasisClosed:zn,curveBasisOpen:Nn,curveBumpX:Pa,curveBumpY:za,curveBundle:Wn,curveCardinalClosed:Hn,curveCardinalOpen:jn,curveCardinal:Un,curveCatmullRomClosed:Yn,curveCatmullRomOpen:Gn,curveCatmullRom:Vn,curveLinear:Xn,curveLinearClosed:Kn,curveMonotoneX:Zn,curveMonotoneY:Jn,curveNatural:Qn,curveStep:ta,curveStepAfter:ea,curveStepBefore:ia},Vs=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Xs=function(t,e){const i=go(t,/(?:init\b)|(?:initialize\b)/);let r={};if(Array.isArray(i)){const a=i.map(s=>s.args);Ie(a),r=it(r,[...a])}else r=i.args;if(!r)return;let o=Ve(t,e);const n="config";return r[n]!==void 0&&(o==="flowchart-v2"&&(o="flowchart"),r[o]=r[n],delete r[n]),r},go=function(t,e=null){try{const i=new RegExp(`[%]{2}(?![{]${Vs.source})(?=[}][%]{2}).*
`,"ig");t=t.trim().replace(i,"").replace(/'/gm,'"'),F.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let r;const o=[];for(;(r=Ce.exec(t))!==null;)if(r.index===Ce.lastIndex&&Ce.lastIndex++,r&&!e||e&&r[1]&&r[1].match(e)||e&&r[2]&&r[2].match(e)){const n=r[1]?r[1]:r[2],a=r[3]?r[3].trim():r[4]?JSON.parse(r[4].trim()):null;o.push({type:n,args:a})}return o.length===0?{type:t,args:null}:o.length===1?o[0]:o}catch(i){return F.error(`ERROR: ${i.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},Ks=function(t){return t.replace(Ce,"")},Zs=function(t,e){for(const[i,r]of e.entries())if(r.match(t))return i;return-1};function Js(t,e){if(!t)return e;const i=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return Gs[i]??e}function Qs(t,e){const i=t.trim();if(i)return e.securityLevel!=="loose"?Kr.sanitizeUrl(i):i}const tl=(t,...e)=>{const i=t.split("."),r=i.length-1,o=i[r];let n=window;for(let a=0;a<r;a++)if(n=n[i[a]],!n){F.error(`Function name: ${t} not found in window`);return}n[o](...e)};function po(t,e){return!t||!e?0:Math.sqrt(Math.pow(e.x-t.x,2)+Math.pow(e.y-t.y,2))}function el(t){let e,i=0;t.forEach(o=>{i+=po(o,e),e=o});const r=i/2;return Ai(t,r)}function il(t){return t.length===1?t[0]:el(t)}const kr=(t,e=2)=>{const i=Math.pow(10,e);return Math.round(t*i)/i},Ai=(t,e)=>{let i,r=e;for(const o of t){if(i){const n=po(o,i);if(n<r)r-=n;else{const a=r/n;if(a<=0)return i;if(a>=1)return{x:o.x,y:o.y};if(a>0&&a<1)return{x:kr((1-a)*i.x+a*o.x,5),y:kr((1-a)*i.y+a*o.y,5)}}}i=o}throw new Error("Could not find a suitable point for the given distance")},rl=(t,e,i)=>{F.info(`our points ${JSON.stringify(e)}`),e[0]!==i&&(e=e.reverse());const o=Ai(e,25),n=t?10:5,a=Math.atan2(e[0].y-o.y,e[0].x-o.x),s={x:0,y:0};return s.x=Math.sin(a)*n+(e[0].x+o.x)/2,s.y=-Math.cos(a)*n+(e[0].y+o.y)/2,s};function ol(t,e,i){const r=structuredClone(i);F.info("our points",r),e!=="start_left"&&e!=="start_right"&&r.reverse();const o=25+t,n=Ai(r,o),a=10+t*.5,s=Math.atan2(r[0].y-n.y,r[0].x-n.x),l={x:0,y:0};return e==="start_left"?(l.x=Math.sin(s+Math.PI)*a+(r[0].x+n.x)/2,l.y=-Math.cos(s+Math.PI)*a+(r[0].y+n.y)/2):e==="end_right"?(l.x=Math.sin(s-Math.PI)*a+(r[0].x+n.x)/2-5,l.y=-Math.cos(s-Math.PI)*a+(r[0].y+n.y)/2-5):e==="end_left"?(l.x=Math.sin(s)*a+(r[0].x+n.x)/2-5,l.y=-Math.cos(s)*a+(r[0].y+n.y)/2-5):(l.x=Math.sin(s)*a+(r[0].x+n.x)/2,l.y=-Math.cos(s)*a+(r[0].y+n.y)/2),l}function nl(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 Sr=0;const al=()=>(Sr++,"id-"+Math.random().toString(36).substr(2,12)+"-"+Sr);function sl(t){let e="";const i="0123456789abcdef",r=i.length;for(let o=0;o<t;o++)e+=i.charAt(Math.floor(Math.random()*r));return e}const ll=t=>sl(t.length),hl=function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},cl=function(t,e){const i=e.text.replace(Fi.lineBreakRegex," "),[,r]=wi(e.fontSize),o=t.append("text");o.attr("x",e.x),o.attr("y",e.y),o.style("text-anchor",e.anchor),o.style("font-family",e.fontFamily),o.style("font-size",r),o.style("font-weight",e.fontWeight),o.attr("fill",e.fill),e.class!==void 0&&o.attr("class",e.class);const n=o.append("tspan");return n.attr("x",e.x+e.textMargin*2),n.attr("fill",e.fill),n.text(i),o},ul=Si((t,e,i)=>{if(!t||(i=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"<br/>"},i),Fi.lineBreakRegex.test(t)))return t;const r=t.split(" "),o=[];let n="";return r.forEach((a,s)=>{const l=De(`${a} `,i),g=De(n,i);if(l>e){const{hyphenatedStrings:h,remainingWord:f}=dl(a,e,"-",i);o.push(n,...h),n=f}else g+l>=e?(o.push(n),n=a):n=[n,a].filter(Boolean).join(" ");s+1===r.length&&o.push(n)}),o.filter(a=>a!=="").join(i.joinWith)},(t,e,i)=>`${t}${e}${i.fontSize}${i.fontWeight}${i.fontFamily}${i.joinWith}`),dl=Si((t,e,i="-",r)=>{r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},r);const o=[...t],n=[];let a="";return o.forEach((s,l)=>{const g=`${a}${s}`;if(De(g,r)>=e){const d=l+1,h=o.length===d,f=`${g}${i}`;n.push(h?g:f),a=""}else a=g}),{hyphenatedStrings:n,remainingWord:a}},(t,e,i="-",r)=>`${t}${e}${i}${r.fontSize}${r.fontWeight}${r.fontFamily}`);function fl(t,e){return Ei(t,e).height}function De(t,e){return Ei(t,e).width}const Ei=Si((t,e)=>{const{fontSize:i=12,fontFamily:r="Arial",fontWeight:o=400}=e;if(!t)return{width:0,height:0};const[,n]=wi(i),a=["sans-serif",r],s=t.split(Fi.lineBreakRegex),l=[],g=gt("body");if(!g.remove)return{width:0,height:0,lineHeight:0};const p=g.append("svg");for(const h of a){let f=0;const L={width:0,height:0,lineHeight:0};for(const R of s){const O=hl();O.text=R||Ys;const N=cl(p,O).style("font-size",n).style("font-weight",o).style("font-family",h),M=(N._groups||N)[0][0].getBBox();if(M.width===0&&M.height===0)throw new Error("svg element not in render tree");L.width=Math.round(Math.max(L.width,M.width)),f=Math.round(M.height),L.height+=f,L.lineHeight=Math.round(Math.max(L.lineHeight,f))}l.push(L)}p.remove();const d=isNaN(l[1].height)||isNaN(l[1].width)||isNaN(l[1].lineHeight)||l[0].height>l[1].height&&l[0].width>l[1].width&&l[0].lineHeight>l[1].lineHeight?0:1;return l[d]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`);class gl{constructor(e=!1,i){this.count=0,this.count=i?i.length:0,this.next=e?()=>this.count++:()=>Date.now()}}let Ee;const pl=function(t){return Ee=Ee||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),Ee.innerHTML=t,unescape(Ee.textContent)};function mo(t){return"str"in t}const ml=(t,e,i,r)=>{var o;if(!r)return;const n=(o=t.node())==null?void 0:o.getBBox();n&&t.append("text").text(r).attr("x",n.x+n.width/2).attr("y",-i).attr("class",e)},wi=t=>{if(typeof t=="number")return[t,t+"px"];const e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]};function Co(t,e){return qa({},t,e)}const ye={assignWithDepth:it,wrapLabel:ul,calculateTextHeight:fl,calculateTextWidth:De,calculateTextDimensions:Ei,cleanAndMerge:Co,detectInit:Xs,detectDirective:go,isSubstringInArray:Zs,interpolateToCurve:Js,calcLabelPosition:il,calcCardinalityPosition:rl,calcTerminalLabelPosition:ol,formatUrl:Qs,getStylesFromArray:nl,generateId:al,random:ll,runFunc:tl,entityDecode:pl,insertTitle:ml,parseFontSize:wi,InitIDGenerator:gl},Cl=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)?"ﬂ°°"+r+"¶ß":"ﬂ°"+r+"¶ß"}),e},yl=function(t){return t.replace(/ﬂ°°/g,"&#").replace(/ﬂ°/g,"&").replace(/¶ß/g,";")},Br="10.8.0",ne=Object.freeze(Ws);let ht=it({},ne),yo,ae=[],be=it({},ne);const Xe=(t,e)=>{let i=it({},t),r={};for(const o of e)To(o),r=it(r,o);if(i=it(i,r),r.theme&&r.theme in Ot){const o=it({},yo),n=it(o.themeVariables||{},r.themeVariables);i.theme&&i.theme in Ot&&(i.themeVariables=Ot[i.theme].getThemeVariables(n))}return be=i,_o(be),be},bl=t=>(ht=it({},ne),ht=it(ht,t),t.theme&&Ot[t.theme]&&(ht.themeVariables=Ot[t.theme].getThemeVariables(t.themeVariables)),Xe(ht,ae),ht),xl=t=>{yo=it({},t)},Tl=t=>(ht=it(ht,t),Xe(ht,ae),ht),bo=()=>it({},ht),xo=t=>(_o(t),it(be,t),St()),St=()=>it({},be),To=t=>{t&&(["secure",...ht.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(F.debug(`Denied attempt to modify a secure key ${e}`,t[e]),delete t[e])}),Object.keys(t).forEach(e=>{e.startsWith("__")&&delete t[e]}),Object.keys(t).forEach(e=>{typeof t[e]=="string"&&(t[e].includes("<")||t[e].includes(">")||t[e].includes("url(data:"))&&delete t[e],typeof t[e]=="object"&&To(t[e])}))},_l=t=>{Ie(t),t.fontFamily&&(!t.themeVariables||!t.themeVariables.fontFamily)&&(t.themeVariables={fontFamily:t.fontFamily}),ae.push(t),Xe(ht,ae)},$e=(t=ht)=>{ae=[],Xe(t,ae)},kl={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},vr={},Sl=t=>{vr[t]||(F.warn(kl[t]),vr[t]=!0)},_o=t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&Sl("LAZY_LOAD_DEPRECATED")},ko="c4",Bl=t=>/^\s*C4Context|C4Container|C4Component|C4Dynamic|C4Deployment/.test(t),vl=async()=>{const{diagram:t}=await Y(()=>import("./c4Diagram-b947cdbb-D_dFMgJl.js"),__vite__mapDeps([0,1,2,3]),import.meta.url);return{id:ko,diagram:t}},Ll={id:ko,detector:Bl,loader:vl},Fl=Ll,So="flowchart",Al=(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)},El=async()=>{const{diagram:t}=await Y(()=>import("./flowDiagram-d949d7c1-CpCOJ_ws.js"),__vite__mapDeps([4,5,1,2,6,7,8,9,10,11,12,13]),import.meta.url);return{id:So,diagram:t}},wl={id:So,detector:Al,loader:El},Ol=wl,Bo="flowchart-v2",Ml=(t,e)=>{var i,r,o;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)&&((o=e==null?void 0:e.flowchart)==null?void 0:o.defaultRenderer)==="dagre-wrapper"?!0:/^\s*flowchart/.test(t)},Il=async()=>{const{diagram:t}=await Y(()=>import("./flowDiagram-v2-49332944-ReNEJkVq.js"),__vite__mapDeps([14,5,1,2,8,6,9,7,10,11,12,13]),import.meta.url);return{id:Bo,diagram:t}},Dl={id:Bo,detector:Ml,loader:Il},$l=Dl,vo="er",Rl=t=>/^\s*erDiagram/.test(t),ql=async()=>{const{diagram:t}=await Y(()=>import("./erDiagram-0ea73325-OlIck4_b.js"),__vite__mapDeps([15,6,1,2,7]),import.meta.url);return{id:vo,diagram:t}},Pl={id:vo,detector:Rl,loader:ql},zl=Pl,Lo="gitGraph",Nl=t=>/^\s*gitGraph/.test(t),Wl=async()=>{const{diagram:t}=await Y(()=>import("./gitGraphDiagram-b9d81de9-DgdIAVAK.js"),__vite__mapDeps([16,1,2]),import.meta.url);return{id:Lo,diagram:t}},Hl={id:Lo,detector:Nl,loader:Wl},jl=Hl,Fo="gantt",Ul=t=>/^\s*gantt/.test(t),Yl=async()=>{const{diagram:t}=await Y(()=>import("./ganttDiagram-5c869e3b-BbmKbJhj.js"),__vite__mapDeps([17,1,2]),import.meta.url);return{id:Fo,diagram:t}},Gl={id:Fo,detector:Ul,loader:Yl},Vl=Gl,Ao="info",Xl=t=>/^\s*info/.test(t),Kl=async()=>{const{diagram:t}=await Y(()=>import("./infoDiagram-db7b18fc-Bcku8sL_.js"),__vite__mapDeps([18,1,2]),import.meta.url);return{id:Ao,diagram:t}},Zl={id:Ao,detector:Xl,loader:Kl},Eo="pie",Jl=t=>/^\s*pie/.test(t),Ql=async()=>{const{diagram:t}=await Y(()=>import("./pieDiagram-b0208e96-B4JAG5bu.js"),__vite__mapDeps([19,1,2]),import.meta.url);return{id:Eo,diagram:t}},th={id:Eo,detector:Jl,loader:Ql},wo="quadrantChart",eh=t=>/^\s*quadrantChart/.test(t),ih=async()=>{const{diagram:t}=await Y(()=>import("./quadrantDiagram-0332be45-CUt6OQ2s.js"),__vite__mapDeps([20,1,2]),import.meta.url);return{id:wo,diagram:t}},rh={id:wo,detector:eh,loader:ih},oh=rh,Oo="xychart",nh=t=>/^\s*xychart-beta/.test(t),ah=async()=>{const{diagram:t}=await Y(()=>import("./xychartDiagram-e50adddc-XDQqkwi5.js"),__vite__mapDeps([21,12,1,2]),import.meta.url);return{id:Oo,diagram:t}},sh={id:Oo,detector:nh,loader:ah},lh=sh,Mo="requirement",hh=t=>/^\s*requirement(Diagram)?/.test(t),ch=async()=>{const{diagram:t}=await Y(()=>import("./requirementDiagram-bf7890df-BJKKwdtl.js"),__vite__mapDeps([22,1,2,6,7]),import.meta.url);return{id:Mo,diagram:t}},uh={id:Mo,detector:hh,loader:ch},dh=uh,Io="sequence",fh=t=>/^\s*sequenceDiagram/.test(t),gh=async()=>{const{diagram:t}=await Y(()=>import("./sequenceDiagram-c18d009d-C5ESA_ph.js"),__vite__mapDeps([23,1,2,3]),import.meta.url);return{id:Io,diagram:t}},ph={id:Io,detector:fh,loader:gh},mh=ph,Do="class",Ch=(t,e)=>{var i;return((i=e==null?void 0:e.class)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*classDiagram/.test(t)},yh=async()=>{const{diagram:t}=await Y(()=>import("./classDiagram-35230388-Hss2RVoj.js"),__vite__mapDeps([24,25,1,2,6,7]),import.meta.url);return{id:Do,diagram:t}},bh={id:Do,detector:Ch,loader:yh},xh=bh,$o="classDiagram",Th=(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)},_h=async()=>{const{diagram:t}=await Y(()=>import("./classDiagram-v2-412acd34-C1qrd5aU.js"),__vite__mapDeps([26,25,1,2,6,9,7,10,11,12]),import.meta.url);return{id:$o,diagram:t}},kh={id:$o,detector:Th,loader:_h},Sh=kh,Ro="state",Bh=(t,e)=>{var i;return((i=e==null?void 0:e.state)==null?void 0:i.defaultRenderer)==="dagre-wrapper"?!1:/^\s*stateDiagram/.test(t)},vh=async()=>{const{diagram:t}=await Y(()=>import("./stateDiagram-43596fc0-CoVmyqxt.js"),__vite__mapDeps([27,28,1,2,6,7]),import.meta.url);return{id:Ro,diagram:t}},Lh={id:Ro,detector:Bh,loader:vh},Fh=Lh,qo="stateDiagram",Ah=(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")},Eh=async()=>{const{diagram:t}=await Y(()=>import("./stateDiagram-v2-2ead4f9c-yh7lRxiw.js"),__vite__mapDeps([29,28,6,1,2,9,7,10,11,12]),import.meta.url);return{id:qo,diagram:t}},wh={id:qo,detector:Ah,loader:Eh},Oh=wh,Po="journey",Mh=t=>/^\s*journey/.test(t),Ih=async()=>{const{diagram:t}=await Y(()=>import("./journeyDiagram-d5636530-CtaWqvtb.js"),__vite__mapDeps([30,1,2,3]),import.meta.url);return{id:Po,diagram:t}},Dh={id:Po,detector:Mh,loader:Ih},$h=Dh,Rh=function(t,e){for(let i of e)t.attr(i[0],i[1])},qh=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},zo=function(t,e,i,r){const o=qh(e,i,r);Rh(t,o)},Ph=function(t,e,i,r){const o=e.node().getBBox(),n=o.width,a=o.height;F.info(`SVG bounds: ${n}x${a}`,o);let s=0,l=0;F.info(`Graph bounds: ${s}x${l}`,t),s=n+i*2,l=a+i*2,F.info(`Calculated bounds: ${s}x${l}`),zo(e,l,s,r);const g=`${o.x-i} ${o.y-i} ${o.width+2*i} ${o.height+2*i}`;e.attr("viewBox",g)},Me={},zh=(t,e,i)=>{let r="";return t in Me&&Me[t]?r=Me[t](i):F.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}
`},Nh=(t,e)=>{e!==void 0&&(Me[t]=e)},Wh=zh;let Oi="",Mi="",Ii="";const Di=t=>xe(t,St()),Hh=()=>{Oi="",Ii="",Mi=""},jh=t=>{Oi=Di(t).replace(/^\s+/g,"")},Uh=()=>Oi,Yh=t=>{Ii=Di(t).replace(/\n\s+/g,`
`)},Gh=()=>Ii,Vh=t=>{Mi=Di(t)},Xh=()=>Mi,Kh=Object.freeze(Object.defineProperty({__proto__:null,clear:Hh,getAccDescription:Gh,getAccTitle:Uh,getDiagramTitle:Xh,setAccDescription:Yh,setAccTitle:jh,setDiagramTitle:Vh},Symbol.toStringTag,{value:"Module"})),Zh=F,Jh=Li,$i=St,gf=xo,pf=ne,Qh=t=>xe(t,$i()),tc=Ph,ec=()=>Kh,Re={},qe=(t,e,i)=>{var r;if(Re[t])throw new Error(`Diagram ${t} already registered.`);Re[t]=e,i&&fo(t,i),Nh(t,e.styles),(r=e.injectUtils)==null||r.call(e,Zh,Jh,$i,Qh,tc,ec(),()=>{})},Ri=t=>{if(t in Re)return Re[t];throw new ic(t)};class ic extends Error{constructor(e){super(`Diagram ${e} not found.`)}}const rc=t=>{var e;const{securityLevel:i}=$i();let r=gt("body");if(i==="sandbox"){const a=((e=gt(`#i${t}`).node())==null?void 0:e.contentDocument)??document;r=gt(a.body)}return r.select(`#${t}`)},oc=(t,e,i)=>{F.debug(`rendering svg for syntax error
`);const r=rc(e);r.attr("viewBox","0 0 2412 512"),zo(r,100,512,!0);const o=r.append("g");o.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"),o.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"),o.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"),o.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"),o.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"),o.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"),o.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"),o.append("text").attr("class","error-text").attr("x",1250).attr("y",400).attr("font-size","100px").style("text-anchor","middle").text(`mermaid version ${i}`)},No={draw:oc},nc=No,ac={db:{},renderer:No,parser:{parser:{yy:{}},parse:()=>{}}},sc=ac,Wo="flowchart-elk",lc=(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")},hc=async()=>{const{diagram:t}=await Y(()=>import("./flowchart-elk-definition-27cc417a-D3n0yIVA.js"),__vite__mapDeps([31,5,1,2,11,12]),import.meta.url);return{id:Wo,diagram:t}},cc={id:Wo,detector:lc,loader:hc},uc=cc,Ho="timeline",dc=t=>/^\s*timeline/.test(t),fc=async()=>{const{diagram:t}=await Y(()=>import("./timeline-definition-d977decf-DbaNuXC4.js"),__vite__mapDeps([32,1,2]),import.meta.url);return{id:Ho,diagram:t}},gc={id:Ho,detector:dc,loader:fc},pc=gc,jo="mindmap",mc=t=>/^\s*mindmap/.test(t),Cc=async()=>{const{diagram:t}=await Y(()=>import("./mindmap-definition-377f8f1f-acoaSzZy.js"),__vite__mapDeps([33,1,2,12]),import.meta.url);return{id:jo,diagram:t}},yc={id:jo,detector:mc,loader:Cc},bc=yc,Uo="sankey",xc=t=>/^\s*sankey-beta/.test(t),Tc=async()=>{const{diagram:t}=await Y(()=>import("./sankeyDiagram-0acdec17-SNYbWGRM.js"),__vite__mapDeps([34,1,2,35]),import.meta.url);return{id:Uo,diagram:t}},_c={id:Uo,detector:xc,loader:Tc},kc=_c,Yo="block",Sc=t=>/^\s*block-beta/.test(t),Bc=async()=>{const{diagram:t}=await Y(()=>import("./blockDiagram-6b2b5046-CuDrjI8z.js"),__vite__mapDeps([36,10,6,1,2,11,12,13,35]),import.meta.url);return{id:Yo,diagram:t}},vc={id:Yo,detector:Sc,loader:Bc},Lc=vc;let Lr=!1;const qi=()=>{Lr||(Lr=!0,qe("error",sc,t=>t.toLowerCase().trim()==="error"),qe("---",{db:{clear:()=>{}},styles:{},renderer:{draw:()=>{}},parser:{parser:{yy:{}},parse:()=>{throw new Error("Diagrams beginning with --- are not valid. If you were trying to use a YAML front-matter, please ensure that you've correctly opened and closed the YAML front-matter with un-indented `---` blocks")}},init:()=>null},t=>t.toLowerCase().trimStart().startsWith("---")),uo(Fl,Sh,xh,zl,Vl,Zl,th,dh,mh,uc,$l,Ol,bc,pc,jl,Oh,Fh,$h,oh,kc,lh,Lc))};class Go{constructor(e,i={}){this.text=e,this.metadata=i,this.type="graph",this.text=Cl(e),this.text+=`
`;const r=St();try{this.type=Ve(e,r)}catch(n){this.type="error",this.detectError=n}const o=Ri(this.type);F.debug("Type "+this.type),this.db=o.db,this.renderer=o.renderer,this.parser=o.parser,this.parser.parser.yy=this.db,this.init=o.init,this.parse()}parse(){var e,i,r,o,n;if(this.detectError)throw this.detectError;(i=(e=this.db).clear)==null||i.call(e);const a=St();(r=this.init)==null||r.call(this,a),this.metadata.title&&((n=(o=this.db).setDiagramTitle)==null||n.call(o,this.metadata.title)),this.parser.parse(this.text)}async render(e,i){await this.renderer.draw(this.text,e,i,this)}getParser(){return this.parser}getType(){return this.type}}const Fc=async(t,e={})=>{const i=Ve(t,St());try{Ri(i)}catch{const o=Us(i);if(!o)throw new co(`Diagram ${i} not found.`);const{id:n,diagram:a}=await o();qe(n,a)}return new Go(t,e)};let Fr=[];const Ac=()=>{Fr.forEach(t=>{t()}),Fr=[]},Ec="graphics-document document";function wc(t,e){t.attr("role",Ec),e!==""&&t.attr("aria-roledescription",e)}function Oc(t,e,i,r){if(t.insert!==void 0){if(i){const o=`chart-desc-${r}`;t.attr("aria-describedby",o),t.insert("desc",":first-child").attr("id",o).text(i)}if(e){const o=`chart-title-${r}`;t.attr("aria-labelledby",o),t.insert("title",":first-child").attr("id",o).text(e)}}}const Mc=t=>t.replace(/^\s*%%(?!{)[^\n]+\n?/gm,"").trimStart();/*! js-yaml 4.1.0 https://github.com/nodeca/js-yaml @license MIT */function Vo(t){return typeof t>"u"||t===null}function Ic(t){return typeof t=="object"&&t!==null}function Dc(t){return Array.isArray(t)?t:Vo(t)?[]:[t]}function $c(t,e){var i,r,o,n;if(e)for(n=Object.keys(e),i=0,r=n.length;i<r;i+=1)o=n[i],t[o]=e[o];return t}function Rc(t,e){var i="",r;for(r=0;r<e;r+=1)i+=t;return i}function qc(t){return t===0&&Number.NEGATIVE_INFINITY===1/t}var Pc=Vo,zc=Ic,Nc=Dc,Wc=Rc,Hc=qc,jc=$c,ot={isNothing:Pc,isObject:zc,toArray:Nc,repeat:Wc,isNegativeZero:Hc,extend:jc};function Xo(t,e){var i="",r=t.reason||"(unknown reason)";return t.mark?(t.mark.name&&(i+='in "'+t.mark.name+'" '),i+="("+(t.mark.line+1)+":"+(t.mark.column+1)+")",!e&&t.mark.snippet&&(i+=`

`+t.mark.snippet),r+" "+i):r}function Te(t,e){Error.call(this),this.name="YAMLException",this.reason=t,this.mark=e,this.message=Xo(this,!1),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack||""}Te.prototype=Object.create(Error.prototype);Te.prototype.constructor=Te;Te.prototype.toString=function(e){return this.name+": "+Xo(this,e)};var wt=Te;function hi(t,e,i,r,o){var n="",a="",s=Math.floor(o/2)-1;return r-e>s&&(n=" ... ",e=r-s+n.length),i-r>s&&(a=" ...",i=r+s-a.length),{str:n+t.slice(e,i).replace(/\t/g,"→")+a,pos:r-e+n.length}}function ci(t,e){return ot.repeat(" ",e-t.length)+t}function Uc(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],o=[],n,a=-1;n=i.exec(t.buffer);)o.push(n.index),r.push(n.index+n[0].length),t.position<=n.index&&a<0&&(a=r.length-2);a<0&&(a=r.length-1);var s="",l,g,p=Math.min(t.line+e.linesAfter,o.length).toString().length,d=e.maxLength-(e.indent+p+3);for(l=1;l<=e.linesBefore&&!(a-l<0);l++)g=hi(t.buffer,r[a-l],o[a-l],t.position-(r[a]-r[a-l]),d),s=ot.repeat(" ",e.indent)+ci((t.line-l+1).toString(),p)+" | "+g.str+`
`+s;for(g=hi(t.buffer,r[a],o[a],t.position,d),s+=ot.repeat(" ",e.indent)+ci((t.line+1).toString(),p)+" | "+g.str+`
`,s+=ot.repeat("-",e.indent+p+3+g.pos)+`^
`,l=1;l<=e.linesAfter&&!(a+l>=o.length);l++)g=hi(t.buffer,r[a+l],o[a+l],t.position-(r[a]-r[a+l]),d),s+=ot.repeat(" ",e.indent)+ci((t.line+l+1).toString(),p)+" | "+g.str+`
`;return s.replace(/\n$/,"")}var Yc=Uc,Gc=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],Vc=["scalar","sequence","mapping"];function Xc(t){var e={};return t!==null&&Object.keys(t).forEach(function(i){t[i].forEach(function(r){e[String(r)]=i})}),e}function Kc(t,e){if(e=e||{},Object.keys(e).forEach(function(i){if(Gc.indexOf(i)===-1)throw new wt('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=Xc(e.styleAliases||null),Vc.indexOf(this.kind)===-1)throw new wt('Unknown kind "'+this.kind+'" is specified for "'+t+'" YAML type.')}var rt=Kc;function Ar(t,e){var i=[];return t[e].forEach(function(r){var o=i.length;i.forEach(function(n,a){n.tag===r.tag&&n.kind===r.kind&&n.multi===r.multi&&(o=a)}),i[o]=r}),i}function Zc(){var t={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},e,i;function r(o){o.multi?(t.multi[o.kind].push(o),t.multi.fallback.push(o)):t[o.kind][o.tag]=t.fallback[o.tag]=o}for(e=0,i=arguments.length;e<i;e+=1)arguments[e].forEach(r);return t}function Ti(t){return this.extend(t)}Ti.prototype.extend=function(e){var i=[],r=[];if(e instanceof rt)r.push(e);else if(Array.isArray(e))r=r.concat(e);else if(e&&(Array.isArray(e.implicit)||Array.isArray(e.explicit)))e.implicit&&(i=i.concat(e.implicit)),e.explicit&&(r=r.concat(e.explicit));else throw new wt("Schema.extend argument should be a Type, [ Type ], or a schema definition ({ implicit: [...], explicit: [...] })");i.forEach(function(n){if(!(n instanceof rt))throw new wt("Specified list of YAML types (or a single Type object) contains a non-Type object.");if(n.loadKind&&n.loadKind!=="scalar")throw new wt("There is a non-scalar type in the implicit list of a schema. Implicit resolving of such types is not supported.");if(n.multi)throw new wt("There is a multi type in the implicit list of a schema. Multi tags can only be listed as explicit.")}),r.forEach(function(n){if(!(n instanceof rt))throw new wt("Specified list of YAML types (or a single Type object) contains a non-Type object.")});var o=Object.create(Ti.prototype);return o.implicit=(this.implicit||[]).concat(i),o.explicit=(this.explicit||[]).concat(r),o.compiledImplicit=Ar(o,"implicit"),o.compiledExplicit=Ar(o,"explicit"),o.compiledTypeMap=Zc(o.compiledImplicit,o.compiledExplicit),o};var Jc=Ti,Qc=new rt("tag:yaml.org,2002:str",{kind:"scalar",construct:function(t){return t!==null?t:""}}),tu=new rt("tag:yaml.org,2002:seq",{kind:"sequence",construct:function(t){return t!==null?t:[]}}),eu=new rt("tag:yaml.org,2002:map",{kind:"mapping",construct:function(t){return t!==null?t:{}}}),iu=new Jc({explicit:[Qc,tu,eu]});function ru(t){if(t===null)return!0;var e=t.length;return e===1&&t==="~"||e===4&&(t==="null"||t==="Null"||t==="NULL")}function ou(){return null}function nu(t){return t===null}var au=new rt("tag:yaml.org,2002:null",{kind:"scalar",resolve:ru,construct:ou,predicate:nu,represent:{canonical:function(){return"~"},lowercase:function(){return"null"},uppercase:function(){return"NULL"},camelcase:function(){return"Null"},empty:function(){return""}},defaultStyle:"lowercase"});function su(t){if(t===null)return!1;var e=t.length;return e===4&&(t==="true"||t==="True"||t==="TRUE")||e===5&&(t==="false"||t==="False"||t==="FALSE")}function lu(t){return t==="true"||t==="True"||t==="TRUE"}function hu(t){return Object.prototype.toString.call(t)==="[object Boolean]"}var cu=new rt("tag:yaml.org,2002:bool",{kind:"scalar",resolve:su,construct:lu,predicate:hu,represent:{lowercase:function(t){return t?"true":"false"},uppercase:function(t){return t?"TRUE":"FALSE"},camelcase:function(t){return t?"True":"False"}},defaultStyle:"lowercase"});function uu(t){return 48<=t&&t<=57||65<=t&&t<=70||97<=t&&t<=102}function du(t){return 48<=t&&t<=55}function fu(t){return 48<=t&&t<=57}function gu(t){if(t===null)return!1;var e=t.length,i=0,r=!1,o;if(!e)return!1;if(o=t[i],(o==="-"||o==="+")&&(o=t[++i]),o==="0"){if(i+1===e)return!0;if(o=t[++i],o==="b"){for(i++;i<e;i++)if(o=t[i],o!=="_"){if(o!=="0"&&o!=="1")return!1;r=!0}return r&&o!=="_"}if(o==="x"){for(i++;i<e;i++)if(o=t[i],o!=="_"){if(!uu(t.charCodeAt(i)))return!1;r=!0}return r&&o!=="_"}if(o==="o"){for(i++;i<e;i++)if(o=t[i],o!=="_"){if(!du(t.charCodeAt(i)))return!1;r=!0}return r&&o!=="_"}}if(o==="_")return!1;for(;i<e;i++)if(o=t[i],o!=="_"){if(!fu(t.charCodeAt(i)))return!1;r=!0}return!(!r||o==="_")}function pu(t){var e=t,i=1,r;if(e.indexOf("_")!==-1&&(e=e.replace(/_/g,"")),r=e[0],(r==="-"||r==="+")&&(r==="-"&&(i=-1),e=e.slice(1),r=e[0]),e==="0")return 0;if(r==="0"){if(e[1]==="b")return i*parseInt(e.slice(2),2);if(e[1]==="x")return i*parseInt(e.slice(2),16);if(e[1]==="o")return i*parseInt(e.slice(2),8)}return i*parseInt(e,10)}function mu(t){return Object.prototype.toString.call(t)==="[object Number]"&&t%1===0&&!ot.isNegativeZero(t)}var Cu=new rt("tag:yaml.org,2002:int",{kind:"scalar",resolve:gu,construct:pu,predicate:mu,represent:{binary:function(t){return t>=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"]}}),yu=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function bu(t){return!(t===null||!yu.test(t)||t[t.length-1]==="_")}function xu(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 Tu=/^[-+]?[0-9]+e/;function _u(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(ot.isNegativeZero(t))return"-0.0";return i=t.toString(10),Tu.test(i)?i.replace("e",".e"):i}function ku(t){return Object.prototype.toString.call(t)==="[object Number]"&&(t%1!==0||ot.isNegativeZero(t))}var Su=new rt("tag:yaml.org,2002:float",{kind:"scalar",resolve:bu,construct:xu,predicate:ku,represent:_u,defaultStyle:"lowercase"}),Ko=iu.extend({implicit:[au,cu,Cu,Su]}),Bu=Ko,Zo=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Jo=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 vu(t){return t===null?!1:Zo.exec(t)!==null||Jo.exec(t)!==null}function Lu(t){var e,i,r,o,n,a,s,l=0,g=null,p,d,h;if(e=Zo.exec(t),e===null&&(e=Jo.exec(t)),e===null)throw new Error("Date resolve error");if(i=+e[1],r=+e[2]-1,o=+e[3],!e[4])return new Date(Date.UTC(i,r,o));if(n=+e[4],a=+e[5],s=+e[6],e[7]){for(l=e[7].slice(0,3);l.length<3;)l+="0";l=+l}return e[9]&&(p=+e[10],d=+(e[11]||0),g=(p*60+d)*6e4,e[9]==="-"&&(g=-g)),h=new Date(Date.UTC(i,r,o,n,a,s,l)),g&&h.setTime(h.getTime()-g),h}function Fu(t){return t.toISOString()}var Au=new rt("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:vu,construct:Lu,instanceOf:Date,represent:Fu});function Eu(t){return t==="<<"||t===null}var wu=new rt("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Eu}),Pi=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=
\r`;function Ou(t){if(t===null)return!1;var e,i,r=0,o=t.length,n=Pi;for(i=0;i<o;i++)if(e=n.indexOf(t.charAt(i)),!(e>64)){if(e<0)return!1;r+=6}return r%8===0}function Mu(t){var e,i,r=t.replace(/[\r\n=]/g,""),o=r.length,n=Pi,a=0,s=[];for(e=0;e<o;e++)e%4===0&&e&&(s.push(a>>16&255),s.push(a>>8&255),s.push(a&255)),a=a<<6|n.indexOf(r.charAt(e));return i=o%4*6,i===0?(s.push(a>>16&255),s.push(a>>8&255),s.push(a&255)):i===18?(s.push(a>>10&255),s.push(a>>2&255)):i===12&&s.push(a>>4&255),new Uint8Array(s)}function Iu(t){var e="",i=0,r,o,n=t.length,a=Pi;for(r=0;r<n;r++)r%3===0&&r&&(e+=a[i>>18&63],e+=a[i>>12&63],e+=a[i>>6&63],e+=a[i&63]),i=(i<<8)+t[r];return o=n%3,o===0?(e+=a[i>>18&63],e+=a[i>>12&63],e+=a[i>>6&63],e+=a[i&63]):o===2?(e+=a[i>>10&63],e+=a[i>>4&63],e+=a[i<<2&63],e+=a[64]):o===1&&(e+=a[i>>2&63],e+=a[i<<4&63],e+=a[64],e+=a[64]),e}function Du(t){return Object.prototype.toString.call(t)==="[object Uint8Array]"}var $u=new rt("tag:yaml.org,2002:binary",{kind:"scalar",resolve:Ou,construct:Mu,predicate:Du,represent:Iu}),Ru=Object.prototype.hasOwnProperty,qu=Object.prototype.toString;function Pu(t){if(t===null)return!0;var e=[],i,r,o,n,a,s=t;for(i=0,r=s.length;i<r;i+=1){if(o=s[i],a=!1,qu.call(o)!=="[object Object]")return!1;for(n in o)if(Ru.call(o,n))if(!a)a=!0;else return!1;if(!a)return!1;if(e.indexOf(n)===-1)e.push(n);else return!1}return!0}function zu(t){return t!==null?t:[]}var Nu=new rt("tag:yaml.org,2002:omap",{kind:"sequence",resolve:Pu,construct:zu}),Wu=Object.prototype.toString;function Hu(t){if(t===null)return!0;var e,i,r,o,n,a=t;for(n=new Array(a.length),e=0,i=a.length;e<i;e+=1){if(r=a[e],Wu.call(r)!=="[object Object]"||(o=Object.keys(r),o.length!==1))return!1;n[e]=[o[0],r[o[0]]]}return!0}function ju(t){if(t===null)return[];var e,i,r,o,n,a=t;for(n=new Array(a.length),e=0,i=a.length;e<i;e+=1)r=a[e],o=Object.keys(r),n[e]=[o[0],r[o[0]]];return n}var Uu=new rt("tag:yaml.org,2002:pairs",{kind:"sequence",resolve:Hu,construct:ju}),Yu=Object.prototype.hasOwnProperty;function Gu(t){if(t===null)return!0;var e,i=t;for(e in i)if(Yu.call(i,e)&&i[e]!==null)return!1;return!0}function Vu(t){return t!==null?t:{}}var Xu=new rt("tag:yaml.org,2002:set",{kind:"mapping",resolve:Gu,construct:Vu}),Ku=Bu.extend({implicit:[Au,wu],explicit:[$u,Nu,Uu,Xu]}),zt=Object.prototype.hasOwnProperty,Pe=1,Qo=2,tn=3,ze=4,ui=1,Zu=2,Er=3,Ju=/[\x00-\x08\x0B\x0C\x0E-\x1F\x7F-\x84\x86-\x9F\uFFFE\uFFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,Qu=/[\x85\u2028\u2029]/,td=/[,\[\]\{\}]/,en=/^(?:!|!!|![a-z\-]+!)$/i,rn=/^(?:!|[^,\[\]\{\}])(?:%[0-9a-f]{2}|[0-9a-z\-#;\/\?:@&=\+\$,_\.!~\*'\(\)\[\]])*$/i;function wr(t){return Object.prototype.toString.call(t)}function _t(t){return t===10||t===13}function Yt(t){return t===9||t===32}function ct(t){return t===9||t===32||t===10||t===13}function te(t){return t===44||t===91||t===93||t===123||t===125}function ed(t){var e;return 48<=t&&t<=57?t-48:(e=t|32,97<=e&&e<=102?e-97+10:-1)}function id(t){return t===120?2:t===117?4:t===85?8:0}function rd(t){return 48<=t&&t<=57?t-48:-1}function Or(t){return t===48?"\0":t===97?"\x07":t===98?"\b":t===116||t===9?"	":t===110?`
`:t===118?"\v":t===102?"\f":t===114?"\r":t===101?"\x1B":t===32?" ":t===34?'"':t===47?"/":t===92?"\\":t===78?"":t===95?" ":t===76?"\u2028":t===80?"\u2029":""}function od(t){return t<=65535?String.fromCharCode(t):String.fromCharCode((t-65536>>10)+55296,(t-65536&1023)+56320)}var on=new Array(256),nn=new Array(256);for(var Qt=0;Qt<256;Qt++)on[Qt]=Or(Qt)?1:0,nn[Qt]=Or(Qt);function nd(t,e){this.input=t,this.filename=e.filename||null,this.schema=e.schema||Ku,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 an(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=Yc(i),new wt(e,i)}function v(t,e){throw an(t,e)}function Ne(t,e){t.onWarning&&t.onWarning.call(null,an(t,e))}var Mr={YAML:function(e,i,r){var o,n,a;e.version!==null&&v(e,"duplication of %YAML directive"),r.length!==1&&v(e,"YAML directive accepts exactly one argument"),o=/^([0-9]+)\.([0-9]+)$/.exec(r[0]),o===null&&v(e,"ill-formed argument of the YAML directive"),n=parseInt(o[1],10),a=parseInt(o[2],10),n!==1&&v(e,"unacceptable YAML version of the document"),e.version=r[0],e.checkLineBreaks=a<2,a!==1&&a!==2&&Ne(e,"unsupported YAML version of the document")},TAG:function(e,i,r){var o,n;r.length!==2&&v(e,"TAG directive accepts exactly two arguments"),o=r[0],n=r[1],en.test(o)||v(e,"ill-formed tag handle (first argument) of the TAG directive"),zt.call(e.tagMap,o)&&v(e,'there is a previously declared suffix for "'+o+'" tag handle'),rn.test(n)||v(e,"ill-formed tag prefix (second argument) of the TAG directive");try{n=decodeURIComponent(n)}catch{v(e,"tag prefix is malformed: "+n)}e.tagMap[o]=n}};function Pt(t,e,i,r){var o,n,a,s;if(e<i){if(s=t.input.slice(e,i),r)for(o=0,n=s.length;o<n;o+=1)a=s.charCodeAt(o),a===9||32<=a&&a<=1114111||v(t,"expected valid JSON character");else Ju.test(s)&&v(t,"the stream contains non-printable characters");t.result+=s}}function Ir(t,e,i,r){var o,n,a,s;for(ot.isObject(i)||v(t,"cannot merge mappings; the provided source object is unacceptable"),o=Object.keys(i),a=0,s=o.length;a<s;a+=1)n=o[a],zt.call(e,n)||(e[n]=i[n],r[n]=!0)}function ee(t,e,i,r,o,n,a,s,l){var g,p;if(Array.isArray(o))for(o=Array.prototype.slice.call(o),g=0,p=o.length;g<p;g+=1)Array.isArray(o[g])&&v(t,"nested arrays are not supported inside keys"),typeof o=="object"&&wr(o[g])==="[object Object]"&&(o[g]="[object Object]");if(typeof o=="object"&&wr(o)==="[object Object]"&&(o="[object Object]"),o=String(o),e===null&&(e={}),r==="tag:yaml.org,2002:merge")if(Array.isArray(n))for(g=0,p=n.length;g<p;g+=1)Ir(t,e,n[g],i);else Ir(t,e,n,i);else!t.json&&!zt.call(i,o)&&zt.call(e,o)&&(t.line=a||t.line,t.lineStart=s||t.lineStart,t.position=l||t.position,v(t,"duplicated mapping key")),o==="__proto__"?Object.defineProperty(e,o,{configurable:!0,enumerable:!0,writable:!0,value:n}):e[o]=n,delete i[o];return e}function zi(t){var e;e=t.input.charCodeAt(t.position),e===10?t.position++:e===13?(t.position++,t.input.charCodeAt(t.position)===10&&t.position++):v(t,"a line break is expected"),t.line+=1,t.lineStart=t.position,t.firstTabInLine=-1}function X(t,e,i){for(var r=0,o=t.input.charCodeAt(t.position);o!==0;){for(;Yt(o);)o===9&&t.firstTabInLine===-1&&(t.firstTabInLine=t.position),o=t.input.charCodeAt(++t.position);if(e&&o===35)do o=t.input.charCodeAt(++t.position);while(o!==10&&o!==13&&o!==0);if(_t(o))for(zi(t),o=t.input.charCodeAt(t.position),r++,t.lineIndent=0;o===32;)t.lineIndent++,o=t.input.charCodeAt(++t.position);else break}return i!==-1&&r!==0&&t.lineIndent<i&&Ne(t,"deficient indentation"),r}function Ke(t){var e=t.position,i;return i=t.input.charCodeAt(e),!!((i===45||i===46)&&i===t.input.charCodeAt(e+1)&&i===t.input.charCodeAt(e+2)&&(e+=3,i=t.input.charCodeAt(e),i===0||ct(i)))}function Ni(t,e){e===1?t.result+=" ":e>1&&(t.result+=ot.repeat(`
`,e-1))}function ad(t,e,i){var r,o,n,a,s,l,g,p,d=t.kind,h=t.result,f;if(f=t.input.charCodeAt(t.position),ct(f)||te(f)||f===35||f===38||f===42||f===33||f===124||f===62||f===39||f===34||f===37||f===64||f===96||(f===63||f===45)&&(o=t.input.charCodeAt(t.position+1),ct(o)||i&&te(o)))return!1;for(t.kind="scalar",t.result="",n=a=t.position,s=!1;f!==0;){if(f===58){if(o=t.input.charCodeAt(t.position+1),ct(o)||i&&te(o))break}else if(f===35){if(r=t.input.charCodeAt(t.position-1),ct(r))break}else{if(t.position===t.lineStart&&Ke(t)||i&&te(f))break;if(_t(f))if(l=t.line,g=t.lineStart,p=t.lineIndent,X(t,!1,-1),t.lineIndent>=e){s=!0,f=t.input.charCodeAt(t.position);continue}else{t.position=a,t.line=l,t.lineStart=g,t.lineIndent=p;break}}s&&(Pt(t,n,a,!1),Ni(t,t.line-l),n=a=t.position,s=!1),Yt(f)||(a=t.position+1),f=t.input.charCodeAt(++t.position)}return Pt(t,n,a,!1),t.result?!0:(t.kind=d,t.result=h,!1)}function sd(t,e){var i,r,o;if(i=t.input.charCodeAt(t.position),i!==39)return!1;for(t.kind="scalar",t.result="",t.position++,r=o=t.position;(i=t.input.charCodeAt(t.position))!==0;)if(i===39)if(Pt(t,r,t.position,!0),i=t.input.charCodeAt(++t.position),i===39)r=t.position,t.position++,o=t.position;else return!0;else _t(i)?(Pt(t,r,o,!0),Ni(t,X(t,!1,e)),r=o=t.position):t.position===t.lineStart&&Ke(t)?v(t,"unexpected end of the document within a single quoted scalar"):(t.position++,o=t.position);v(t,"unexpected end of the stream within a single quoted scalar")}function ld(t,e){var i,r,o,n,a,s;if(s=t.input.charCodeAt(t.position),s!==34)return!1;for(t.kind="scalar",t.result="",t.position++,i=r=t.position;(s=t.input.charCodeAt(t.position))!==0;){if(s===34)return Pt(t,i,t.position,!0),t.position++,!0;if(s===92){if(Pt(t,i,t.position,!0),s=t.input.charCodeAt(++t.position),_t(s))X(t,!1,e);else if(s<256&&on[s])t.result+=nn[s],t.position++;else if((a=id(s))>0){for(o=a,n=0;o>0;o--)s=t.input.charCodeAt(++t.position),(a=ed(s))>=0?n=(n<<4)+a:v(t,"expected hexadecimal character");t.result+=od(n),t.position++}else v(t,"unknown escape sequence");i=r=t.position}else _t(s)?(Pt(t,i,r,!0),Ni(t,X(t,!1,e)),i=r=t.position):t.position===t.lineStart&&Ke(t)?v(t,"unexpected end of the document within a double quoted scalar"):(t.position++,r=t.position)}v(t,"unexpected end of the stream within a double quoted scalar")}function hd(t,e){var i=!0,r,o,n,a=t.tag,s,l=t.anchor,g,p,d,h,f,L=Object.create(null),R,O,N,M;if(M=t.input.charCodeAt(t.position),M===91)p=93,f=!1,s=[];else if(M===123)p=125,f=!0,s={};else return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=s),M=t.input.charCodeAt(++t.position);M!==0;){if(X(t,!0,e),M=t.input.charCodeAt(t.position),M===p)return t.position++,t.tag=a,t.anchor=l,t.kind=f?"mapping":"sequence",t.result=s,!0;i?M===44&&v(t,"expected the node content, but found ','"):v(t,"missed comma between flow collection entries"),O=R=N=null,d=h=!1,M===63&&(g=t.input.charCodeAt(t.position+1),ct(g)&&(d=h=!0,t.position++,X(t,!0,e))),r=t.line,o=t.lineStart,n=t.position,se(t,e,Pe,!1,!0),O=t.tag,R=t.result,X(t,!0,e),M=t.input.charCodeAt(t.position),(h||t.line===r)&&M===58&&(d=!0,M=t.input.charCodeAt(++t.position),X(t,!0,e),se(t,e,Pe,!1,!0),N=t.result),f?ee(t,s,L,O,R,N,r,o,n):d?s.push(ee(t,null,L,O,R,N,r,o,n)):s.push(R),X(t,!0,e),M=t.input.charCodeAt(t.position),M===44?(i=!0,M=t.input.charCodeAt(++t.position)):i=!1}v(t,"unexpected end of the stream within a flow collection")}function cd(t,e){var i,r,o=ui,n=!1,a=!1,s=e,l=0,g=!1,p,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)ui===o?o=d===43?Er:Zu:v(t,"repeat of a chomping mode identifier");else if((p=rd(d))>=0)p===0?v(t,"bad explicit indentation width of a block scalar; it cannot be less than one"):a?v(t,"repeat of an indentation width identifier"):(s=e+p-1,a=!0);else break;if(Yt(d)){do d=t.input.charCodeAt(++t.position);while(Yt(d));if(d===35)do d=t.input.charCodeAt(++t.position);while(!_t(d)&&d!==0)}for(;d!==0;){for(zi(t),t.lineIndent=0,d=t.input.charCodeAt(t.position);(!a||t.lineIndent<s)&&d===32;)t.lineIndent++,d=t.input.charCodeAt(++t.position);if(!a&&t.lineIndent>s&&(s=t.lineIndent),_t(d)){l++;continue}if(t.lineIndent<s){o===Er?t.result+=ot.repeat(`
`,n?1+l:l):o===ui&&n&&(t.result+=`
`);break}for(r?Yt(d)?(g=!0,t.result+=ot.repeat(`
`,n?1+l:l)):g?(g=!1,t.result+=ot.repeat(`
`,l+1)):l===0?n&&(t.result+=" "):t.result+=ot.repeat(`
`,l):t.result+=ot.repeat(`
`,n?1+l:l),n=!0,a=!0,l=0,i=t.position;!_t(d)&&d!==0;)d=t.input.charCodeAt(++t.position);Pt(t,i,t.position,!1)}return!0}function Dr(t,e){var i,r=t.tag,o=t.anchor,n=[],a,s=!1,l;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=n),l=t.input.charCodeAt(t.position);l!==0&&(t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,v(t,"tab characters must not be used in indentation")),!(l!==45||(a=t.input.charCodeAt(t.position+1),!ct(a))));){if(s=!0,t.position++,X(t,!0,-1)&&t.lineIndent<=e){n.push(null),l=t.input.charCodeAt(t.position);continue}if(i=t.line,se(t,e,tn,!1,!0),n.push(t.result),X(t,!0,-1),l=t.input.charCodeAt(t.position),(t.line===i||t.lineIndent>e)&&l!==0)v(t,"bad indentation of a sequence entry");else if(t.lineIndent<e)break}return s?(t.tag=r,t.anchor=o,t.kind="sequence",t.result=n,!0):!1}function ud(t,e,i){var r,o,n,a,s,l,g=t.tag,p=t.anchor,d={},h=Object.create(null),f=null,L=null,R=null,O=!1,N=!1,M;if(t.firstTabInLine!==-1)return!1;for(t.anchor!==null&&(t.anchorMap[t.anchor]=d),M=t.input.charCodeAt(t.position);M!==0;){if(!O&&t.firstTabInLine!==-1&&(t.position=t.firstTabInLine,v(t,"tab characters must not be used in indentation")),r=t.input.charCodeAt(t.position+1),n=t.line,(M===63||M===58)&&ct(r))M===63?(O&&(ee(t,d,h,f,L,null,a,s,l),f=L=R=null),N=!0,O=!0,o=!0):O?(O=!1,o=!0):v(t,"incomplete explicit mapping pair; a key node is missed; or followed by a non-tabulated empty line"),t.position+=1,M=r;else{if(a=t.line,s=t.lineStart,l=t.position,!se(t,i,Qo,!1,!0))break;if(t.line===n){for(M=t.input.charCodeAt(t.position);Yt(M);)M=t.input.charCodeAt(++t.position);if(M===58)M=t.input.charCodeAt(++t.position),ct(M)||v(t,"a whitespace character is expected after the key-value separator within a block mapping"),O&&(ee(t,d,h,f,L,null,a,s,l),f=L=R=null),N=!0,O=!1,o=!1,f=t.tag,L=t.result;else if(N)v(t,"can not read an implicit mapping pair; a colon is missed");else return t.tag=g,t.anchor=p,!0}else if(N)v(t,"can not read a block mapping entry; a multiline key may not be an implicit key");else return t.tag=g,t.anchor=p,!0}if((t.line===n||t.lineIndent>e)&&(O&&(a=t.line,s=t.lineStart,l=t.position),se(t,e,ze,!0,o)&&(O?L=t.result:R=t.result),O||(ee(t,d,h,f,L,R,a,s,l),f=L=R=null),X(t,!0,-1),M=t.input.charCodeAt(t.position)),(t.line===n||t.lineIndent>e)&&M!==0)v(t,"bad indentation of a mapping entry");else if(t.lineIndent<e)break}return O&&ee(t,d,h,f,L,null,a,s,l),N&&(t.tag=g,t.anchor=p,t.kind="mapping",t.result=d),N}function dd(t){var e,i=!1,r=!1,o,n,a;if(a=t.input.charCodeAt(t.position),a!==33)return!1;if(t.tag!==null&&v(t,"duplication of a tag property"),a=t.input.charCodeAt(++t.position),a===60?(i=!0,a=t.input.charCodeAt(++t.position)):a===33?(r=!0,o="!!",a=t.input.charCodeAt(++t.position)):o="!",e=t.position,i){do a=t.input.charCodeAt(++t.position);while(a!==0&&a!==62);t.position<t.length?(n=t.input.slice(e,t.position),a=t.input.charCodeAt(++t.position)):v(t,"unexpected end of the stream within a verbatim tag")}else{for(;a!==0&&!ct(a);)a===33&&(r?v(t,"tag suffix cannot contain exclamation marks"):(o=t.input.slice(e-1,t.position+1),en.test(o)||v(t,"named tag handle cannot contain such characters"),r=!0,e=t.position+1)),a=t.input.charCodeAt(++t.position);n=t.input.slice(e,t.position),td.test(n)&&v(t,"tag suffix cannot contain flow indicator characters")}n&&!rn.test(n)&&v(t,"tag name cannot contain such characters: "+n);try{n=decodeURIComponent(n)}catch{v(t,"tag name is malformed: "+n)}return i?t.tag=n:zt.call(t.tagMap,o)?t.tag=t.tagMap[o]+n:o==="!"?t.tag="!"+n:o==="!!"?t.tag="tag:yaml.org,2002:"+n:v(t,'undeclared tag handle "'+o+'"'),!0}function fd(t){var e,i;if(i=t.input.charCodeAt(t.position),i!==38)return!1;for(t.anchor!==null&&v(t,"duplication of an anchor property"),i=t.input.charCodeAt(++t.position),e=t.position;i!==0&&!ct(i)&&!te(i);)i=t.input.charCodeAt(++t.position);return t.position===e&&v(t,"name of an anchor node must contain at least one character"),t.anchor=t.input.slice(e,t.position),!0}function gd(t){var e,i,r;if(r=t.input.charCodeAt(t.position),r!==42)return!1;for(r=t.input.charCodeAt(++t.position),e=t.position;r!==0&&!ct(r)&&!te(r);)r=t.input.charCodeAt(++t.position);return t.position===e&&v(t,"name of an alias node must contain at least one character"),i=t.input.slice(e,t.position),zt.call(t.anchorMap,i)||v(t,'unidentified alias "'+i+'"'),t.result=t.anchorMap[i],X(t,!0,-1),!0}function se(t,e,i,r,o){var n,a,s,l=1,g=!1,p=!1,d,h,f,L,R,O;if(t.listener!==null&&t.listener("open",t),t.tag=null,t.anchor=null,t.kind=null,t.result=null,n=a=s=ze===i||tn===i,r&&X(t,!0,-1)&&(g=!0,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)),l===1)for(;dd(t)||fd(t);)X(t,!0,-1)?(g=!0,s=n,t.lineIndent>e?l=1:t.lineIndent===e?l=0:t.lineIndent<e&&(l=-1)):s=!1;if(s&&(s=g||o),(l===1||ze===i)&&(Pe===i||Qo===i?R=e:R=e+1,O=t.position-t.lineStart,l===1?s&&(Dr(t,O)||ud(t,O,R))||hd(t,R)?p=!0:(a&&cd(t,R)||sd(t,R)||ld(t,R)?p=!0:gd(t)?(p=!0,(t.tag!==null||t.anchor!==null)&&v(t,"alias node should not have any properties")):ad(t,R,Pe===i)&&(p=!0,t.tag===null&&(t.tag="?")),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):l===0&&(p=s&&Dr(t,O))),t.tag===null)t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);else if(t.tag==="?"){for(t.result!==null&&t.kind!=="scalar"&&v(t,'unacceptable node kind for !<?> tag; it should be "scalar", not "'+t.kind+'"'),d=0,h=t.implicitTypes.length;d<h;d+=1)if(L=t.implicitTypes[d],L.resolve(t.result)){t.result=L.construct(t.result),t.tag=L.tag,t.anchor!==null&&(t.anchorMap[t.anchor]=t.result);break}}else if(t.tag!=="!"){if(zt.call(t.typeMap[t.kind||"fallback"],t.tag))L=t.typeMap[t.kind||"fallback"][t.tag];else for(L=null,f=t.typeMap.multi[t.kind||"fallback"],d=0,h=f.length;d<h;d+=1)if(t.tag.slice(0,f[d].tag.length)===f[d].tag){L=f[d];break}L||v(t,"unknown tag !<"+t.tag+">"),t.result!==null&&L.kind!==t.kind&&v(t,"unacceptable node kind for !<"+t.tag+'> tag; it should be "'+L.kind+'", not "'+t.kind+'"'),L.resolve(t.result,t.tag)?(t.result=L.construct(t.result,t.tag),t.anchor!==null&&(t.anchorMap[t.anchor]=t.result)):v(t,"cannot resolve a node with !<"+t.tag+"> explicit tag")}return t.listener!==null&&t.listener("close",t),t.tag!==null||t.anchor!==null||p}function pd(t){var e=t.position,i,r,o,n=!1,a;for(t.version=null,t.checkLineBreaks=t.legacy,t.tagMap=Object.create(null),t.anchorMap=Object.create(null);(a=t.input.charCodeAt(t.position))!==0&&(X(t,!0,-1),a=t.input.charCodeAt(t.position),!(t.lineIndent>0||a!==37));){for(n=!0,a=t.input.charCodeAt(++t.position),i=t.position;a!==0&&!ct(a);)a=t.input.charCodeAt(++t.position);for(r=t.input.slice(i,t.position),o=[],r.length<1&&v(t,"directive name must not be less than one character in length");a!==0;){for(;Yt(a);)a=t.input.charCodeAt(++t.position);if(a===35){do a=t.input.charCodeAt(++t.position);while(a!==0&&!_t(a));break}if(_t(a))break;for(i=t.position;a!==0&&!ct(a);)a=t.input.charCodeAt(++t.position);o.push(t.input.slice(i,t.position))}a!==0&&zi(t),zt.call(Mr,r)?Mr[r](t,r,o):Ne(t,'unknown document directive "'+r+'"')}if(X(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,X(t,!0,-1)):n&&v(t,"directives end mark is expected"),se(t,t.lineIndent-1,ze,!1,!0),X(t,!0,-1),t.checkLineBreaks&&Qu.test(t.input.slice(e,t.position))&&Ne(t,"non-ASCII line breaks are interpreted as content"),t.documents.push(t.result),t.position===t.lineStart&&Ke(t)){t.input.charCodeAt(t.position)===46&&(t.position+=3,X(t,!0,-1));return}if(t.position<t.length-1)v(t,"end of the stream or a document separator is expected");else return}function sn(t,e){t=String(t),e=e||{},t.length!==0&&(t.charCodeAt(t.length-1)!==10&&t.charCodeAt(t.length-1)!==13&&(t+=`
`),t.charCodeAt(0)===65279&&(t=t.slice(1)));var i=new nd(t,e),r=t.indexOf("\0");for(r!==-1&&(i.position=r,v(i,"null byte is not allowed in input")),i.input+="\0";i.input.charCodeAt(i.position)===32;)i.lineIndent+=1,i.position+=1;for(;i.position<i.length-1;)pd(i);return i.documents}function md(t,e,i){e!==null&&typeof e=="object"&&typeof i>"u"&&(i=e,e=null);var r=sn(t,i);if(typeof e!="function")return r;for(var o=0,n=r.length;o<n;o+=1)e(r[o])}function Cd(t,e){var i=sn(t,e);if(i.length!==0){if(i.length===1)return i[0];throw new wt("expected a single document in the stream, but found more")}}var yd=md,bd=Cd,xd={loadAll:yd,load:bd},Td=Ko,_d=xd.load;function kd(t){const e=t.match(ho);if(!e)return{text:t,metadata:{}};let i=_d(e[1],{schema:Td})??{};i=typeof i=="object"&&!Array.isArray(i)?i:{};const r={};return i.displayMode&&(r.displayMode=i.displayMode.toString()),i.title&&(r.title=i.title.toString()),i.config&&(r.config=i.config),{text:t.slice(e[0].length),metadata:r}}const Sd=t=>t.replace(/\r\n?/g,`
`).replace(/<(\w+)([^>]*)>/g,(e,i,r)=>"<"+i+r.replace(/="([^"]*)"/g,"='$1'")+">"),Bd=t=>{const{text:e,metadata:i}=kd(t),{displayMode:r,title:o,config:n={}}=i;return r&&(n.gantt||(n.gantt={}),n.gantt.displayMode=r),{title:o,config:n,text:e}},vd=t=>{const e=ye.detectInit(t)??{},i=ye.detectDirective(t,"wrap");return Array.isArray(i)?e.wrap=i.some(({type:r})=>{}):(i==null?void 0:i.type)==="wrap"&&(e.wrap=!0),{text:Ks(t),directive:e}};function ln(t){const e=Sd(t),i=Bd(e),r=vd(i.text),o=Co(i.config,r.directive);return t=Mc(r.text),{code:t,title:i.title,config:o}}const Ld=5e4,Fd="graph TB;a[Maximum text size in diagram exceeded];style a fill:#faa",Ad="sandbox",Ed="loose",wd="http://www.w3.org/2000/svg",Od="http://www.w3.org/1999/xlink",Md="http://www.w3.org/1999/xhtml",Id="100%",Dd="100%",$d="border:0;margin:0;",Rd="margin:0",qd="allow-top-navigation-by-user-activation allow-popups",Pd='The "iframe" tag is not supported by your browser.',zd=["foreignobject"],Nd=["dominant-baseline"];function hn(t){const e=ln(t);return $e(),_l(e.config??{}),e}async function Wd(t,e){qi(),t=hn(t).code;try{await Wi(t)}catch(i){if(e!=null&&e.suppressErrors)return!1;throw i}return!0}const $r=(t,e,i=[])=>`
.${t} ${e} { ${i.join(" !important; ")} !important; }`,Hd=(t,e={})=>{var i;let r="";if(t.themeCSS!==void 0&&(r+=`
${t.themeCSS}`),t.fontFamily!==void 0&&(r+=`
:root { --mermaid-font-family: ${t.fontFamily}}`),t.altFontFamily!==void 0&&(r+=`
:root { --mermaid-alt-font-family: ${t.altFontFamily}}`),!ri(e)){const s=t.htmlLabels||((i=t.flowchart)==null?void 0:i.htmlLabels)?["> *","span"]:["rect","polygon","ellipse","circle","path"];for(const l in e){const g=e[l];ri(g.styles)||s.forEach(p=>{r+=$r(g.id,p,g.styles)}),ri(g.textStyles)||(r+=$r(g.id,"tspan",g.textStyles))}}return r},jd=(t,e,i,r)=>{const o=Hd(t,i),n=Wh(e,o,t.themeVariables);return Rn(qn(`${r}{${n}}`),ra)},Ud=(t="",e,i)=>{let r=t;return!i&&!e&&(r=r.replace(/marker-end="url\([\d+./:=?A-Za-z-]*?#/g,'marker-end="url(#')),r=yl(r),r=r.replace(/<br>/g,"<br/>"),r},Yd=(t="",e)=>{var i,r;const o=(r=(i=e==null?void 0:e.viewBox)==null?void 0:i.baseVal)!=null&&r.height?e.viewBox.baseVal.height+"px":Dd,n=btoa('<body style="'+Rd+'">'+t+"</body>");return`<iframe style="width:${Id};height:${o};${$d}" src="data:text/html;base64,${n}" sandbox="${qd}">
  ${Pd}
</iframe>`},Rr=(t,e,i,r,o)=>{const n=t.append("div");n.attr("id",i),r&&n.attr("style",r);const a=n.append("svg").attr("id",e).attr("width","100%").attr("xmlns",wd);return o&&a.attr("xmlns:xlink",o),a.append("g"),t};function qr(t,e){return t.append("iframe").attr("id",e).attr("style","width: 100%; height: 100%;").attr("sandbox","")}const Gd=(t,e,i,r)=>{var o,n,a;(o=t.getElementById(e))==null||o.remove(),(n=t.getElementById(i))==null||n.remove(),(a=t.getElementById(r))==null||a.remove()},Vd=async function(t,e,i){var r,o,n,a,s,l;qi();const g=hn(e);e=g.code;const p=St();F.debug(p),e.length>((p==null?void 0:p.maxTextSize)??Ld)&&(e=Fd);const d="#"+t,h="i"+t,f="#"+h,L="d"+t,R="#"+L;let O=gt("body");const N=p.securityLevel===Ad,M=p.securityLevel===Ed,j=p.fontFamily;if(i!==void 0){if(i&&(i.innerHTML=""),N){const x=qr(gt(i),h);O=gt(x.nodes()[0].contentDocument.body),O.node().style.margin=0}else O=gt(i);Rr(O,t,L,`font-family: ${j}`,Od)}else{if(Gd(document,t,L,h),N){const x=qr(gt("body"),h);O=gt(x.nodes()[0].contentDocument.body),O.node().style.margin=0}else O=gt("body");Rr(O,t,L)}let V,ut;try{V=await Wi(e,{title:g.title})}catch(x){V=new Go("error"),ut=x}const Ct=O.select(R).node(),Nt=V.type,Mt=Ct.firstChild,It=Mt.firstChild,z=(o=(r=V.renderer).getClasses)==null?void 0:o.call(r,e,V),P=jd(p,Nt,z,d),yt=document.createElement("style");yt.innerHTML=P,Mt.insertBefore(yt,It);try{await V.renderer.draw(e,t,Br,V)}catch(x){throw nc.draw(e,t,Br),x}const Dt=O.select(`${R} svg`),E=(a=(n=V.db).getAccTitle)==null?void 0:a.call(n),T=(l=(s=V.db).getAccDescription)==null?void 0:l.call(s);Kd(Nt,Dt,E,T),O.select(`[id="${t}"]`).selectAll("foreignobject > *").attr("xmlns",Md);let C=O.select(R).node().innerHTML;if(F.debug("config.arrowMarkerAbsolute",p.arrowMarkerAbsolute),C=Ud(C,N,ao(p.arrowMarkerAbsolute)),N){const x=O.select(R+" svg").node();C=Yd(C,x)}else M||(C=re.sanitize(C,{ADD_TAGS:zd,ADD_ATTR:Nd}));if(Ac(),ut)throw ut;const b=gt(N?f:R).node();return b&&"remove"in b&&b.remove(),{svg:C,bindFunctions:V.db.bindFunctions}};function Xd(t={}){var e;t!=null&&t.fontFamily&&!((e=t.themeVariables)!=null&&e.fontFamily)&&(t.themeVariables||(t.themeVariables={}),t.themeVariables.fontFamily=t.fontFamily),xl(t),t!=null&&t.theme&&t.theme in Ot?t.themeVariables=Ot[t.theme].getThemeVariables(t.themeVariables):t&&(t.themeVariables=Ot.default.getThemeVariables(t.themeVariables));const i=typeof t=="object"?bl(t):bo();Li(i.logLevel),qi()}const Wi=(t,e={})=>{const{code:i}=ln(t);return Fc(i,e)};function Kd(t,e,i,r){wc(e,t),Oc(e,i,r,e.attr("id"))}const Gt=Object.freeze({render:Vd,parse:Wd,getDiagramFromText:Wi,initialize:Xd,getConfig:St,setConfig:xo,getSiteConfig:bo,updateSiteConfig:Tl,reset:()=>{$e()},globalReset:()=>{$e(ne)},defaultConfig:ne});Li(St().logLevel);$e(St());const Zd=async()=>{F.debug("Loading registered diagrams");const e=(await Promise.allSettled(Object.entries(oe).map(async([i,{detector:r,loader:o}])=>{if(o)try{Ri(i)}catch{try{const{diagram:a,id:s}=await o();qe(s,a,r)}catch(a){throw F.error(`Failed to load external diagram with key ${i}. Removing from detectors.`),delete oe[i],a}}}))).filter(i=>i.status==="rejected");if(e.length>0){F.error(`Failed to load ${e.length} external diagrams`);for(const i of e)F.error(i);throw new Error(`Failed to load ${e.length} external diagrams`)}},Jd=(t,e,i)=>{F.warn(t),mo(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}))},cn=async function(t={querySelector:".mermaid"}){try{await Qd(t)}catch(e){if(mo(e)&&F.error(e.str),mt.parseError&&mt.parseError(e),!t.suppressErrors)throw F.error("Use the suppressErrors option to suppress these errors"),e}},Qd=async function({postRenderCallback:t,querySelector:e,nodes:i}={querySelector:".mermaid"}){const r=Gt.getConfig();F.debug(`${t?"":"No "}Callback function found`);let o;if(i)o=i;else if(e)o=document.querySelectorAll(e);else throw new Error("Nodes and querySelector are both undefined");F.debug(`Found ${o.length} diagrams`),(r==null?void 0:r.startOnLoad)!==void 0&&(F.debug("Start On Load: "+(r==null?void 0:r.startOnLoad)),Gt.updateSiteConfig({startOnLoad:r==null?void 0:r.startOnLoad}));const n=new ye.InitIDGenerator(r.deterministicIds,r.deterministicIDSeed);let a;const s=[];for(const l of Array.from(o)){F.info("Rendering diagram: "+l.id);/*! Check if previously processed */if(l.getAttribute("data-processed"))continue;l.setAttribute("data-processed","true");const g=`mermaid-${n.next()}`;a=l.innerHTML,a=Na(ye.entityDecode(a)).trim().replace(/<br\s*\/?>/gi,"<br/>");const p=ye.detectInit(a);p&&F.debug("Detected early reinit: ",p);try{const{svg:d,bindFunctions:h}=await gn(g,a,l);l.innerHTML=d,t&&await t(g),h&&h(l)}catch(d){Jd(d,s,mt.parseError)}}if(s.length>0)throw s[0]},un=function(t){Gt.initialize(t)},tf=async function(t,e,i){F.warn("mermaid.init is deprecated. Please use run instead."),t&&un(t);const r={postRenderCallback:i,querySelector:".mermaid"};typeof e=="string"?r.querySelector=e:e&&(e instanceof HTMLElement?r.nodes=[e]:r.nodes=e),await cn(r)},ef=async(t,{lazyLoad:e=!0}={})=>{uo(...t),e===!1&&await Zd()},dn=function(){if(mt.startOnLoad){const{startOnLoad:t}=Gt.getConfig();t&&mt.run().catch(e=>F.error("Mermaid failed to initialize",e))}};if(typeof document<"u"){/*!
 * Wait for document loaded before starting the execution
 */window.addEventListener("load",dn,!1)}const rf=function(t){mt.parseError=t},We=[];let di=!1;const fn=async()=>{if(!di){for(di=!0;We.length>0;){const t=We.shift();if(t)try{await t()}catch(e){F.error("Error executing queue",e)}}di=!1}},of=async(t,e)=>new Promise((i,r)=>{const o=()=>new Promise((n,a)=>{Gt.parse(t,e).then(s=>{n(s),i(s)},s=>{var l;F.error("Error parsing",s),(l=mt.parseError)==null||l.call(mt,s),a(s),r(s)})});We.push(o),fn().catch(r)}),gn=(t,e,i)=>new Promise((r,o)=>{const n=()=>new Promise((a,s)=>{Gt.render(t,e,i).then(l=>{a(l),r(l)},l=>{var g;F.error("Error parsing",l),(g=mt.parseError)==null||g.call(mt,l),s(l),o(l)})});We.push(n),fn().catch(o)}),mt={startOnLoad:!0,mermaidAPI:Gt,parse:of,render:gn,init:tf,run:cn,registerExternalDiagrams:ef,initialize:un,parseError:void 0,contentLoaded:dn,setParseErrorHandler:rf,detectType:Ve},nf={startOnLoad:!0,theme:"forest",logLevel:"fatal",securityLevel:"strict",fontFamily:"var(--text-font)",arrowMarkerAbsolute:!1,flowchart:{htmlLabels:!0,curve:"linear"},sequence:{diagramMarginX:50,diagramMarginY:10,actorMargin:50,width:150,height:65,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,mirrorActors:!0,bottomMarginAdj:1,useMaxWidth:!0,rightAngles:!1,showSequenceNumbers:!1},gantt:{titleTopMargin:25,barHeight:20,barGap:4,topPadding:50,leftPadding:75,gridLineStartPadding:35,fontSize:11,numberSectionStyles:4,axisFormat:"%Y-%m-%d"}};function af(){const t="abcdefghijklmnopqrstuvwxyz";return Array.from({length:6},()=>t[Math.floor(Math.random()*t.length)]).join("")}const sf=({diagram:t})=>{const[e]=oa.useState(()=>af()),i=na().theme==="dark";mt.initialize({...nf,theme:i?"dark":"forest",darkMode:i});const{data:r}=aa(async()=>(await mt.render(e,t,void 0).catch(n=>{var a;throw(a=document.getElementById(e))==null||a.remove(),sa.warn("Failed to render mermaid diagram",n),n})).svg,[t,e]);return r?la.jsx("div",{dangerouslySetInnerHTML:{__html:r}}):null},mf=Object.freeze(Object.defineProperty({__proto__:null,default:sf},Symbol.toStringTag,{value:"Module"}));export{St as $,jr as A,Fa as B,Aa as C,ca as D,La as E,Ea as F,fa as G,wa as H,ri as I,Ba as J,me as K,Bi as L,qa as M,kt as N,yl as O,Na as P,gf as Q,hf as R,tc as S,ll as T,w as U,Ha as V,rc as W,Ws as X,Co as Y,wi as Z,$s as _,Gh as a,Ys as a0,al as a1,Kh as a2,_e as a3,B as a4,A as a5,mf as a6,Yh as b,$i as c,xe as d,it as e,De as f,Uh as g,zo as h,Fi as i,fl as j,Kr as k,F as l,Ue as m,nl as n,ao as o,Js as p,Ph as q,pf as r,jh as s,Vh as t,Xh as u,ye as v,ul as w,Hh as x,ga as y,Hr as z};
