From 47fc02a8c71af4926148beb5d5cc0fc221aa5429 Mon Sep 17 00:00:00 2001 From: Alexander Neonxp Kiryukhin Date: Sun, 15 Dec 2024 14:37:33 +0300 Subject: Auto-commit 2024-12-15 --- .../js/chunks/mermaid.esm.min/chunk-3YFHLAX3.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-54VS5GG6.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-5ZJXQJOJ.mjs | 14 ++ .../js/chunks/mermaid.esm.min/chunk-6BY5RJGC.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-6CAUGOKZ.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-7LIB5WBN.mjs | 37 +++++ .../js/chunks/mermaid.esm.min/chunk-AFC6EC46.mjs | 66 +++++++++ .../js/chunks/mermaid.esm.min/chunk-D4BOYBYT.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-E7A2AWYO.mjs | 15 ++ .../js/chunks/mermaid.esm.min/chunk-FASC7IG4.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-GTKDMUJJ.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-LM6QDVU5.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-OR2G2HG5.mjs | 64 +++++++++ .../js/chunks/mermaid.esm.min/chunk-P7KHIEPL.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-S67DUUA5.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-TI4EEUUG.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-UENA7NWE.mjs | 2 + .../js/chunks/mermaid.esm.min/chunk-YPUTD6PB.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-ZN7TASNU.mjs | 1 + .../js/chunks/mermaid.esm.min/chunk-ZUCAP7FR.mjs | 4 + .../js/chunks/mermaid.esm.min/dagre-RF25WEIW.mjs | 4 + .../mermaid.esm.min/flowDiagram-7QVFXBRT.mjs | 160 +++++++++++++++++++++ 22 files changed, 379 insertions(+) create mode 100644 static/js/chunks/mermaid.esm.min/chunk-3YFHLAX3.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-54VS5GG6.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-5ZJXQJOJ.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-6BY5RJGC.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-6CAUGOKZ.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-7LIB5WBN.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-AFC6EC46.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-D4BOYBYT.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-E7A2AWYO.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-FASC7IG4.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-GTKDMUJJ.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-LM6QDVU5.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-OR2G2HG5.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-P7KHIEPL.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-S67DUUA5.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-TI4EEUUG.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-UENA7NWE.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-YPUTD6PB.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-ZN7TASNU.mjs create mode 100644 static/js/chunks/mermaid.esm.min/chunk-ZUCAP7FR.mjs create mode 100644 static/js/chunks/mermaid.esm.min/dagre-RF25WEIW.mjs create mode 100644 static/js/chunks/mermaid.esm.min/flowDiagram-7QVFXBRT.mjs (limited to 'static/js/chunks') diff --git a/static/js/chunks/mermaid.esm.min/chunk-3YFHLAX3.mjs b/static/js/chunks/mermaid.esm.min/chunk-3YFHLAX3.mjs new file mode 100644 index 0000000..875d098 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-3YFHLAX3.mjs @@ -0,0 +1 @@ +import{X as s,ga as e}from"./chunk-OR2G2HG5.mjs";import{a as n}from"./chunk-GTKDMUJJ.mjs";var d=n(t=>{let{securityLevel:m}=s(),o=e("body");if(m==="sandbox"){let c=e(`#i${t}`).node()?.contentDocument??document;o=e(c.body)}return o.select(`#${t}`)},"selectSvgElement");export{d as a}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-54VS5GG6.mjs b/static/js/chunks/mermaid.esm.min/chunk-54VS5GG6.mjs new file mode 100644 index 0000000..432ba1e --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-54VS5GG6.mjs @@ -0,0 +1 @@ +import{b as g,c as y,d,e as f}from"./chunk-ZUCAP7FR.mjs";import{a as p,f as l,h as u}from"./chunk-E7A2AWYO.mjs";import{c as m}from"./chunk-UENA7NWE.mjs";import{A as a,L as s,b as i}from"./chunk-OR2G2HG5.mjs";import{a as o}from"./chunk-GTKDMUJJ.mjs";var L={common:s,getConfig:a,insertCluster:l,insertEdge:d,insertEdgeLabel:g,insertMarkers:f,insertNode:u,interpolateToCurve:m,labelHelper:p,log:i,positionEdgeLabel:y};var t={},h=o(r=>{for(let e of r)t[e.name]=e},"registerLayoutLoaders"),c=o(()=>{h([{name:"dagre",loader:o(async()=>await import("./dagre-RF25WEIW.mjs"),"loader")}])},"registerDefaultLayoutLoaders");c();var S=o(async(r,e)=>{if(!(r.layoutAlgorithm in t))throw new Error(`Unknown layout algorithm: ${r.layoutAlgorithm}`);let n=t[r.layoutAlgorithm];return(await n.loader()).render(r,e,L,{algorithm:n.algorithm})},"render"),V=o((r="",{fallback:e="dagre"}={})=>{if(r in t)return r;if(e in t)return i.warn(`Layout algorithm ${r} is not registered. Using ${e} as fallback.`),e;throw new Error(`Both layout algorithms ${r} and ${e} are not registered.`)},"getRegisteredLayoutAlgorithm");export{h as a,S as b,V as c}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-5ZJXQJOJ.mjs b/static/js/chunks/mermaid.esm.min/chunk-5ZJXQJOJ.mjs new file mode 100644 index 0000000..59bdf03 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-5ZJXQJOJ.mjs @@ -0,0 +1,14 @@ +import{a as hr,b as yr,c as C}from"./chunk-YPUTD6PB.mjs";import{A as st,B as I,C as nr,D as ir,E as _,F as G,G as lt,H as q,I as F,J as br,K as dt,L as B,M as L,N as xt,P as gt,Q as K,R as M,S as ct,a as et,b as P,c as Y,d as R,h as lr,j as ot,k as ft,l as W,m as dr,n as xr,o as at,p as Yr,q as gr,r as nt,s as it,u as mt,v as pt,w as ut,x as T,y as cr,z as s}from"./chunk-6BY5RJGC.mjs";import{a as e}from"./chunk-GTKDMUJJ.mjs";function io(r){return I(r)?dt(r):hr(r)}e(io,"keys");var h=io;function mo(r,t){for(var o=-1,f=r==null?0:r.length;++o2?t[2]:void 0;for(a&&M(t[0],t[1],a)&&(f=1);++om))return!1;var u=n.get(r),l=n.get(t);if(u&&l)return u==t&&l==r;var d=-1,x=!0,E=o&Qf?new k:void 0;for(n.set(r,t),n.set(t,r);++dt}e(gn,"baseGt");var le=gn;function cn(r){return r&&r.length?er(r,L,le):void 0}e(cn,"max");var bn=cn;function hn(r,t,o,f){if(!R(r))return r;t=j(t,r);for(var a=-1,n=t.length,i=n-1,m=r;m!=null&&++a0&&o(m)?t>1?be(m,t-1,o,f,a):J(a,m):f||(a[a.length]=m)}return a}e(be,"baseFlatten");var U=be;function In(r){var t=r==null?0:r.length;return t?U(r,1):[]}e(In,"flatten");var Qr=In;function vn(r){return gt(xt(r,void 0,Qr),r+"")}e(vn,"flatRest");var he=vn;var Sn=he(function(r,t){return r==null?{}:xe(r,t)}),Tn=Sn;function wn(r,t,o,f){var a=-1,n=r==null?0:r.length;for(f&&n&&(o=r[++a]);++a-1}e(Fn,"arrayIncludes");var Kr=Fn;function Bn(r,t,o){for(var f=-1,a=r==null?0:r.length;++f=Gn){var u=t?null:ve(r);if(u)return rr(u);i=!1,a=V,p=new k}else p=t?[]:m;r:for(;++fa?0:a+t),o=o>a?a:o,o<0&&(o+=a),a=t>o?0:o-t>>>0,t>>>=0;for(var n=Array(a);++f=wi&&(n=V,i=!1,t=new k(t));r:for(;++a-1?a[n?t[i]:i]:void 0}}e(Di,"createFind");var Ne=Di;var Gi=Math.max;function Wi(r,t,o){var f=r==null?0:r.length;if(!f)return-1;var a=o==null?0:D(o);return a<0&&(a=Gi(f+a,0)),qr(r,g(t,3),a)}e(Wi,"findIndex");var Ue=Wi;var qi=Ne(Ue),Ki=qi;function ji(r){return r&&r.length?r[0]:void 0}e(ji,"head");var De=ji;function Hi(r,t){return U(Jr(r,t),1)}e(Hi,"flatMap");var zi=Hi;function Yi(r,t){return r==null?r:xr(r,Q(t),B)}e(Yi,"forIn");var Zi=Yi;function $i(r,t){return r&&X(r,Q(t))}e($i,"forOwn");var Ji=$i;var Xi=Object.prototype,Qi=Xi.hasOwnProperty,ki=Ce(function(r,t,o){Qi.call(r,o)?r[o].push(t):dr(r,o,[t])}),Vi=ki;var rm=Object.prototype,tm=rm.hasOwnProperty;function em(r,t){return r!=null&&tm.call(r,t)}e(em,"baseHas");var Ge=em;function om(r,t){return r!=null&&Nr(r,t,Ge)}e(om,"has");var fm=om;var am="[object String]";function nm(r){return typeof r=="string"||!s(r)&&T(r)&&Y(r)==am}e(nm,"isString");var pr=nm;var im=Math.max;function mm(r,t,o,f){r=I(r)?r:Xr(r),o=o&&!f?D(o):0;var a=r.length;return o<0&&(o=im(a+o,0)),pr(r)?o<=a&&r.indexOf(t,o)>-1:!!a&&or(r,t,o)>-1}e(mm,"includes");var pm=mm;var um=Math.max;function sm(r,t,o){var f=r==null?0:r.length;if(!f)return-1;var a=o==null?0:D(o);return a<0&&(a=um(f+a,0)),or(r,t,a)}e(sm,"indexOf");var lm=sm;var dm="[object RegExp]";function xm(r){return T(r)&&Y(r)==dm}e(xm,"baseIsRegExp");var We=xm;var qe=G&&G.isRegExp,gm=qe?_(qe):We,cm=gm;function bm(r,t){return rt||n&&i&&p&&!m&&!u||f&&i&&p||!o&&p||!a)return 1;if(!f&&!n&&!u&&r=m)return p;var u=o[f];return p*(u=="desc"?-1:1)}}return r.index-t.index}e(Pm,"compareMultiple");var ze=Pm;function Rm(r,t,o){t.length?t=S(t,function(n){return s(n)?function(i){return H(i,n.length===1?n[0]:n)}:n}):t=[L];var f=-1;t=S(t,_(g));var a=Gr(r,function(n,i,m){var p=S(t,function(u){return u(n)});return{criteria:p,index:++f,value:n}});return je(a,function(n,i){return ze(n,i,o)})}e(Rm,"baseOrderBy");var Ye=Rm;var Lm=Dr("length"),Ze=Lm;var Je="\\ud800-\\udfff",Mm="\\u0300-\\u036f",Cm="\\ufe20-\\ufe2f",_m="\\u20d0-\\u20ff",Fm=Mm+Cm+_m,Bm="\\ufe0e\\ufe0f",Nm="["+Je+"]",Vr="["+Fm+"]",rt="\\ud83c[\\udffb-\\udfff]",Um="(?:"+Vr+"|"+rt+")",Xe="[^"+Je+"]",Qe="(?:\\ud83c[\\udde6-\\uddff]){2}",ke="[\\ud800-\\udbff][\\udc00-\\udfff]",Dm="\\u200d",Ve=Um+"?",ro="["+Bm+"]?",Gm="(?:"+Dm+"(?:"+[Xe,Qe,ke].join("|")+")"+ro+Ve+")*",Wm=ro+Ve+Gm,qm="(?:"+[Xe+Vr+"?",Vr,Qe,ke,Nm].join("|")+")",$e=RegExp(rt+"(?="+rt+")|"+qm+Wm,"g");function Km(r){for(var t=$e.lastIndex=0;$e.test(r);)++t;return t}e(Km,"unicodeSize");var to=Km;function jm(r){return Re(r)?to(r):Ze(r)}e(jm,"stringSize");var eo=jm;var Hm=Math.ceil,zm=Math.max;function Ym(r,t,o,f){for(var a=-1,n=zm(Hm((t-r)/(o||1)),0),i=Array(n);n--;)i[f?n:++a]=r,r+=o;return i}e(Ym,"baseRange");var oo=Ym;function Zm(r){return function(t,o,f){return f&&typeof f!="number"&&M(t,o,f)&&(o=f=void 0),t=ar(t),o===void 0?(o=t,t=0):o=ar(o),f=f===void 0?t1&&M(r,t[0],t[1])?t=[]:o>2&&M(t[0],t[1],t[2])&&(t=[t[0]]),Ye(r,U(t,1),[])}),np=ap;function ip(r){return r&&r.length?fr(r):[]}e(ip,"uniq");var mp=ip;function pp(r,t){return r&&r.length?fr(r,g(t,2)):[]}e(pp,"uniqBy");var s0=pp;var up=0;function sp(r){var t=++up;return Br(r)+t}e(sp,"uniqueId");var lp=sp;function dp(r,t,o){for(var f=-1,a=r.length,n=t.length,i={};++f + * Build: `lodash modularize exports="es" -o ./` + * Copyright OpenJS Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + *) +*/ diff --git a/static/js/chunks/mermaid.esm.min/chunk-6BY5RJGC.mjs b/static/js/chunks/mermaid.esm.min/chunk-6BY5RJGC.mjs new file mode 100644 index 0000000..43752b0 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-6BY5RJGC.mjs @@ -0,0 +1 @@ +import{a as e}from"./chunk-GTKDMUJJ.mjs";var Sr=typeof global=="object"&&global&&global.Object===Object&&global,R=Sr;var Ir=typeof self=="object"&&self&&self.Object===Object&&self,Mr=R||Ir||Function("return this")(),d=Mr;var Er=d.Symbol,O=Er;var it=Object.prototype,Fr=it.hasOwnProperty,Lr=it.toString,F=O?O.toStringTag:void 0;function Dr(t){var r=Fr.call(t,F),o=t[F];try{t[F]=void 0;var a=!0}catch{}var n=Lr.call(t);return a&&(r?t[F]=o:delete t[F]),n}e(Dr,"getRawTag");var ft=Dr;var Gr=Object.prototype,Nr=Gr.toString;function zr(t){return Nr.call(t)}e(zr,"objectToString");var pt=zr;var Ur="[object Null]",Rr="[object Undefined]",ut=O?O.toStringTag:void 0;function Hr(t){return t==null?t===void 0?Rr:Ur:ut&&ut in Object(t)?ft(t):pt(t)}e(Hr,"baseGetTag");var y=Hr;function Br(t){var r=typeof t;return t!=null&&(r=="object"||r=="function")}e(Br,"isObject");var m=Br;var Vr="[object AsyncFunction]",Kr="[object Function]",qr="[object GeneratorFunction]",$r="[object Proxy]";function Xr(t){if(!m(t))return!1;var r=y(t);return r==Kr||r==qr||r==Vr||r==$r}e(Xr,"isFunction");var T=Xr;var Jr=d["__core-js_shared__"],H=Jr;var st=function(){var t=/[^.]+$/.exec(H&&H.keys&&H.keys.IE_PROTO||"");return t?"Symbol(src)_1."+t:""}();function Wr(t){return!!st&&st in t}e(Wr,"isMasked");var mt=Wr;var Yr=Function.prototype,Zr=Yr.toString;function Qr(t){if(t!=null){try{return Zr.call(t)}catch{}try{return t+""}catch{}}return""}e(Qr,"toSource");var lt=Qr;var kr=/[\\^$.*+?()[\]{}|]/g,te=/^\[object .+?Constructor\]$/,re=Function.prototype,ee=Object.prototype,oe=re.toString,ae=ee.hasOwnProperty,ne=RegExp("^"+oe.call(ae).replace(kr,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function ie(t){if(!m(t)||mt(t))return!1;var r=T(t)?ne:te;return r.test(lt(t))}e(ie,"baseIsNative");var ct=ie;function fe(t,r){return t?.[r]}e(fe,"getValue");var dt=fe;function pe(t,r){var o=dt(t,r);return ct(o)?o:void 0}e(pe,"getNative");var j=pe;var ue=j(Object,"create"),g=ue;function se(){this.__data__=g?g(null):{},this.size=0}e(se,"hashClear");var ht=se;function me(t){var r=this.has(t)&&delete this.__data__[t];return this.size-=r?1:0,r}e(me,"hashDelete");var gt=me;var le="__lodash_hash_undefined__",ce=Object.prototype,de=ce.hasOwnProperty;function he(t){var r=this.__data__;if(g){var o=r[t];return o===le?void 0:o}return de.call(r,t)?r[t]:void 0}e(he,"hashGet");var yt=he;var ge=Object.prototype,ye=ge.hasOwnProperty;function be(t){var r=this.__data__;return g?r[t]!==void 0:ye.call(r,t)}e(be,"hashHas");var bt=be;var xe="__lodash_hash_undefined__";function ve(t,r){var o=this.__data__;return this.size+=this.has(t)?0:1,o[t]=g&&r===void 0?xe:r,this}e(ve,"hashSet");var xt=ve;function A(t){var r=-1,o=t==null?0:t.length;for(this.clear();++r-1}e(Pe,"listCacheHas");var Tt=Pe;function Se(t,r){var o=this.__data__,a=x(o,t);return a<0?(++this.size,o.push([t,r])):o[a][1]=r,this}e(Se,"listCacheSet");var jt=Se;function C(t){var r=-1,o=t==null?0:t.length;for(this.clear();++r-1&&t%1==0&&t<=yo}e(bo,"isLength");var q=bo;function xo(t){return t!=null&&q(t.length)&&!T(t)}e(xo,"isArrayLike");var M=xo;function vo(t){return h(t)&&M(t)}e(vo,"isArrayLikeObject");var kt=vo;function _o(){return!1}e(_o,"stubFalse");var tr=_o;var or=typeof exports=="object"&&exports&&!exports.nodeType&&exports,rr=or&&typeof module=="object"&&module&&!module.nodeType&&module,Oo=rr&&rr.exports===or,er=Oo?d.Buffer:void 0,To=er?er.isBuffer:void 0,jo=To||tr,$=jo;var Ao="[object Object]",Co=Function.prototype,wo=Object.prototype,ar=Co.toString,Po=wo.hasOwnProperty,So=ar.call(Object);function Io(t){if(!h(t)||y(t)!=Ao)return!1;var r=V(t);if(r===null)return!0;var o=Po.call(r,"constructor")&&r.constructor;return typeof o=="function"&&o instanceof o&&ar.call(o)==So}e(Io,"isPlainObject");var nr=Io;var Mo="[object Arguments]",Eo="[object Array]",Fo="[object Boolean]",Lo="[object Date]",Do="[object Error]",Go="[object Function]",No="[object Map]",zo="[object Number]",Uo="[object Object]",Ro="[object RegExp]",Ho="[object Set]",Bo="[object String]",Vo="[object WeakMap]",Ko="[object ArrayBuffer]",qo="[object DataView]",$o="[object Float32Array]",Xo="[object Float64Array]",Jo="[object Int8Array]",Wo="[object Int16Array]",Yo="[object Int32Array]",Zo="[object Uint8Array]",Qo="[object Uint8ClampedArray]",ko="[object Uint16Array]",ta="[object Uint32Array]",u={};u[$o]=u[Xo]=u[Jo]=u[Wo]=u[Yo]=u[Zo]=u[Qo]=u[ko]=u[ta]=!0;u[Mo]=u[Eo]=u[Ko]=u[Fo]=u[qo]=u[Lo]=u[Do]=u[Go]=u[No]=u[zo]=u[Uo]=u[Ro]=u[Ho]=u[Bo]=u[Vo]=!1;function ra(t){return h(t)&&q(t.length)&&!!u[y(t)]}e(ra,"baseIsTypedArray");var ir=ra;function ea(t){return function(r){return t(r)}}e(ea,"baseUnary");var fr=ea;var pr=typeof exports=="object"&&exports&&!exports.nodeType&&exports,z=pr&&typeof module=="object"&&module&&!module.nodeType&&module,oa=z&&z.exports===pr,ot=oa&&R.process,aa=function(){try{var t=z&&z.require&&z.require("util").types;return t||ot&&ot.binding&&ot.binding("util")}catch{}}(),at=aa;var ur=at&&at.isTypedArray,na=ur?fr(ur):ir,X=na;function ia(t,r){if(!(r==="constructor"&&typeof t[r]=="function")&&r!="__proto__")return t[r]}e(ia,"safeGet");var U=ia;var fa=Object.prototype,pa=fa.hasOwnProperty;function ua(t,r,o){var a=t[r];(!(pa.call(t,r)&&b(a,o))||o===void 0&&!(r in t))&&I(t,r,o)}e(ua,"assignValue");var sr=ua;function sa(t,r,o,a){var n=!o;o||(o={});for(var f=-1,p=r.length;++f-1&&t%1==0&&t0){if(++r>=Sa)return arguments[0]}else r=0;return t.apply(void 0,arguments)}}e(Ea,"shortOut");var jr=Ea;var Fa=jr(Tr),Ar=Fa;function La(t,r){return Ar(Or(t,r,Y),t+"")}e(La,"baseRest");var Cr=La;function Da(t,r,o){if(!m(o))return!1;var a=typeof r;return(a=="number"?M(o)&&J(r,o.length):a=="string"&&r in o)?b(o[r],t):!1}e(Da,"isIterateeCall");var wr=Da;function Ga(t){return Cr(function(r,o){var a=-1,n=o.length,f=n>1?o[n-1]:void 0,p=n>2?o[2]:void 0;for(f=t.length>3&&typeof f=="function"?(n--,f):void 0,p&&wr(o[0],o[1],p)&&(f=n<3?void 0:f,n=1),r=Object(r);++a"u"||e===null}c(_e,"isNothing");function Qe(e){return typeof e=="object"&&e!==null}c(Qe,"isObject");function Ve(e){return Array.isArray(e)?e:_e(e)?[]:[e]}c(Ve,"toArray");function Xe(e,n){var i,l,r,u;if(n)for(u=Object.keys(n),i=0,l=u.length;if&&(u=" ... ",n=l-f+u.length),i-l>f&&(o=" ...",i=l+f-o.length),{str:u+e.slice(n,i).replace(/\t/g,"\u2192")+o,pos:l-n+u.length}}c(Q,"getLine");function V(e,n){return C.repeat(" ",n-e.length)+e}c(V,"padStart");function un(e,n){if(n=Object.create(n||null),!e.buffer)return null;n.maxLength||(n.maxLength=79),typeof n.indent!="number"&&(n.indent=1),typeof n.linesBefore!="number"&&(n.linesBefore=3),typeof n.linesAfter!="number"&&(n.linesAfter=2);for(var i=/\r?\n|\r|\0/g,l=[0],r=[],u,o=-1;u=i.exec(e.buffer);)r.push(u.index),l.push(u.index+u[0].length),e.position<=u.index&&o<0&&(o=l.length-2);o<0&&(o=l.length-1);var f="",a,p,h=Math.min(e.line+n.linesAfter,r.length).toString().length,t=n.maxLength-(n.indent+h+3);for(a=1;a<=n.linesBefore&&!(o-a<0);a++)p=Q(e.buffer,l[o-a],r[o-a],e.position-(l[o]-l[o-a]),t),f=C.repeat(" ",n.indent)+V((e.line-a+1).toString(),h)+" | "+p.str+` +`+f;for(p=Q(e.buffer,l[o],r[o],e.position,t),f+=C.repeat(" ",n.indent)+V((e.line+1).toString(),h)+" | "+p.str+` +`,f+=C.repeat("-",n.indent+h+3+p.pos)+`^ +`,a=1;a<=n.linesAfter&&!(o+a>=r.length);a++)p=Q(e.buffer,l[o+a],r[o+a],e.position-(l[o]-l[o+a]),t),f+=C.repeat(" ",n.indent)+V((e.line+a+1).toString(),h)+" | "+p.str+` +`;return f.replace(/\n$/,"")}c(un,"makeSnippet");var fn=un,cn=["kind","multi","resolve","construct","instanceOf","predicate","represent","representName","defaultStyle","styleAliases"],an=["scalar","sequence","mapping"];function pn(e){var n={};return e!==null&&Object.keys(e).forEach(function(i){e[i].forEach(function(l){n[String(l)]=i})}),n}c(pn,"compileStyleAliases");function tn(e,n){if(n=n||{},Object.keys(n).forEach(function(i){if(cn.indexOf(i)===-1)throw new E('Unknown option "'+i+'" is met in definition of "'+e+'" YAML type.')}),this.options=n,this.tag=e,this.kind=n.kind||null,this.resolve=n.resolve||function(){return!0},this.construct=n.construct||function(i){return i},this.instanceOf=n.instanceOf||null,this.predicate=n.predicate||null,this.represent=n.represent||null,this.representName=n.representName||null,this.defaultStyle=n.defaultStyle||null,this.multi=n.multi||!1,this.styleAliases=pn(n.styleAliases||null),an.indexOf(this.kind)===-1)throw new E('Unknown kind "'+this.kind+'" is specified for "'+e+'" YAML type.')}c(tn,"Type$1");var _=tn;function fe(e,n){var i=[];return e[n].forEach(function(l){var r=i.length;i.forEach(function(u,o){u.tag===l.tag&&u.kind===l.kind&&u.multi===l.multi&&(r=o)}),i[r]=l}),i}c(fe,"compileList");function hn(){var e={scalar:{},sequence:{},mapping:{},fallback:{},multi:{scalar:[],sequence:[],mapping:[],fallback:[]}},n,i;function l(r){r.multi?(e.multi[r.kind].push(r),e.multi.fallback.push(r)):e[r.kind][r.tag]=e.fallback[r.tag]=r}for(c(l,"collectType"),n=0,i=arguments.length;n=0?"0b"+e.toString(2):"-0b"+e.toString(2).slice(1)},"binary"),octal:c(function(e){return e>=0?"0o"+e.toString(8):"-0o"+e.toString(8).slice(1)},"octal"),decimal:c(function(e){return e.toString(10)},"decimal"),hexadecimal:c(function(e){return e>=0?"0x"+e.toString(16).toUpperCase():"-0x"+e.toString(16).toUpperCase().slice(1)},"hexadecimal")},defaultStyle:"decimal",styleAliases:{binary:[2,"bin"],octal:[8,"oct"],decimal:[10,"dec"],hexadecimal:[16,"hex"]}}),Nn=new RegExp("^(?:[-+]?(?:[0-9][0-9_]*)(?:\\.[0-9_]*)?(?:[eE][-+]?[0-9]+)?|\\.[0-9_]+(?:[eE][-+]?[0-9]+)?|[-+]?\\.(?:inf|Inf|INF)|\\.(?:nan|NaN|NAN))$");function Rn(e){return!(e===null||!Nn.test(e)||e[e.length-1]==="_")}c(Rn,"resolveYamlFloat");function Dn(e){var n,i;return n=e.replace(/_/g,"").toLowerCase(),i=n[0]==="-"?-1:1,"+-".indexOf(n[0])>=0&&(n=n.slice(1)),n===".inf"?i===1?Number.POSITIVE_INFINITY:Number.NEGATIVE_INFINITY:n===".nan"?NaN:i*parseFloat(n,10)}c(Dn,"constructYamlFloat");var Mn=/^[-+]?[0-9]+e/;function Yn(e,n){var i;if(isNaN(e))switch(n){case"lowercase":return".nan";case"uppercase":return".NAN";case"camelcase":return".NaN"}else if(Number.POSITIVE_INFINITY===e)switch(n){case"lowercase":return".inf";case"uppercase":return".INF";case"camelcase":return".Inf"}else if(Number.NEGATIVE_INFINITY===e)switch(n){case"lowercase":return"-.inf";case"uppercase":return"-.INF";case"camelcase":return"-.Inf"}else if(C.isNegativeZero(e))return"-0.0";return i=e.toString(10),Mn.test(i)?i.replace("e",".e"):i}c(Yn,"representYamlFloat");function Bn(e){return Object.prototype.toString.call(e)==="[object Number]"&&(e%1!==0||C.isNegativeZero(e))}c(Bn,"isFloat");var Pn=new _("tag:yaml.org,2002:float",{kind:"scalar",resolve:Rn,construct:Dn,predicate:Bn,represent:Yn,defaultStyle:"lowercase"}),Ee=gn.extend({implicit:[Cn,Sn,kn,Pn]}),Hn=Ee,Se=new RegExp("^([0-9][0-9][0-9][0-9])-([0-9][0-9])-([0-9][0-9])$"),Fe=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 jn(e){return e===null?!1:Se.exec(e)!==null||Fe.exec(e)!==null}c(jn,"resolveYamlTimestamp");function Un(e){var n,i,l,r,u,o,f,a=0,p=null,h,t,s;if(n=Se.exec(e),n===null&&(n=Fe.exec(e)),n===null)throw new Error("Date resolve error");if(i=+n[1],l=+n[2]-1,r=+n[3],!n[4])return new Date(Date.UTC(i,l,r));if(u=+n[4],o=+n[5],f=+n[6],n[7]){for(a=n[7].slice(0,3);a.length<3;)a+="0";a=+a}return n[9]&&(h=+n[10],t=+(n[11]||0),p=(h*60+t)*6e4,n[9]==="-"&&(p=-p)),s=new Date(Date.UTC(i,l,r,u,o,f,a)),p&&s.setTime(s.getTime()-p),s}c(Un,"constructYamlTimestamp");function Kn(e){return e.toISOString()}c(Kn,"representYamlTimestamp");var qn=new _("tag:yaml.org,2002:timestamp",{kind:"scalar",resolve:jn,construct:Un,instanceOf:Date,represent:Kn});function Gn(e){return e==="<<"||e===null}c(Gn,"resolveYamlMerge");var Wn=new _("tag:yaml.org,2002:merge",{kind:"scalar",resolve:Gn}),ie=`ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/= +\r`;function $n(e){if(e===null)return!1;var n,i,l=0,r=e.length,u=ie;for(i=0;i64)){if(n<0)return!1;l+=6}return l%8===0}c($n,"resolveYamlBinary");function Qn(e){var n,i,l=e.replace(/[\r\n=]/g,""),r=l.length,u=ie,o=0,f=[];for(n=0;n>16&255),f.push(o>>8&255),f.push(o&255)),o=o<<6|u.indexOf(l.charAt(n));return i=r%4*6,i===0?(f.push(o>>16&255),f.push(o>>8&255),f.push(o&255)):i===18?(f.push(o>>10&255),f.push(o>>2&255)):i===12&&f.push(o>>4&255),new Uint8Array(f)}c(Qn,"constructYamlBinary");function Vn(e){var n="",i=0,l,r,u=e.length,o=ie;for(l=0;l>18&63],n+=o[i>>12&63],n+=o[i>>6&63],n+=o[i&63]),i=(i<<8)+e[l];return r=u%3,r===0?(n+=o[i>>18&63],n+=o[i>>12&63],n+=o[i>>6&63],n+=o[i&63]):r===2?(n+=o[i>>10&63],n+=o[i>>4&63],n+=o[i<<2&63],n+=o[64]):r===1&&(n+=o[i>>2&63],n+=o[i<<4&63],n+=o[64],n+=o[64]),n}c(Vn,"representYamlBinary");function Xn(e){return Object.prototype.toString.call(e)==="[object Uint8Array]"}c(Xn,"isBinary");var Zn=new _("tag:yaml.org,2002:binary",{kind:"scalar",resolve:$n,construct:Qn,predicate:Xn,represent:Vn}),zn=Object.prototype.hasOwnProperty,Jn=Object.prototype.toString;function ei(e){if(e===null)return!0;var n=[],i,l,r,u,o,f=e;for(i=0,l=f.length;i>10)+55296,(e-65536&1023)+56320)}c(Ai,"charFromCodepoint");var ke=new Array(256),Ne=new Array(256);for(L=0;L<256;L++)ke[L]=pe(L)?1:0,Ne[L]=pe(L);var L;function vi(e,n){this.input=e,this.filename=n.filename||null,this.schema=n.schema||be,this.onWarning=n.onWarning||null,this.legacy=n.legacy||!1,this.json=n.json||!1,this.listener=n.listener||null,this.implicitTypes=this.schema.compiledImplicit,this.typeMap=this.schema.compiledTypeMap,this.length=e.length,this.position=0,this.line=0,this.lineStart=0,this.lineIndent=0,this.firstTabInLine=-1,this.documents=[]}c(vi,"State$1");function Re(e,n){var i={name:e.filename,buffer:e.input.slice(0,-1),position:e.position,line:e.line,column:e.position-e.lineStart};return i.snippet=fn(i),new E(n,i)}c(Re,"generateError");function d(e,n){throw Re(e,n)}c(d,"throwError");function q(e,n){e.onWarning&&e.onWarning.call(null,Re(e,n))}c(q,"throwWarning");var te={YAML:c(function(n,i,l){var r,u,o;n.version!==null&&d(n,"duplication of %YAML directive"),l.length!==1&&d(n,"YAML directive accepts exactly one argument"),r=/^([0-9]+)\.([0-9]+)$/.exec(l[0]),r===null&&d(n,"ill-formed argument of the YAML directive"),u=parseInt(r[1],10),o=parseInt(r[2],10),u!==1&&d(n,"unacceptable YAML version of the document"),n.version=l[0],n.checkLineBreaks=o<2,o!==1&&o!==2&&q(n,"unsupported YAML version of the document")},"handleYamlDirective"),TAG:c(function(n,i,l){var r,u;l.length!==2&&d(n,"TAG directive accepts exactly two arguments"),r=l[0],u=l[1],Ie.test(r)||d(n,"ill-formed tag handle (first argument) of the TAG directive"),I.call(n.tagMap,r)&&d(n,'there is a previously declared suffix for "'+r+'" tag handle'),Le.test(u)||d(n,"ill-formed tag prefix (second argument) of the TAG directive");try{u=decodeURIComponent(u)}catch{d(n,"tag prefix is malformed: "+u)}n.tagMap[r]=u},"handleTagDirective")};function O(e,n,i,l){var r,u,o,f;if(n1&&(e.result+=C.repeat(` +`,n-1))}c(le,"writeFoldedLines");function yi(e,n,i){var l,r,u,o,f,a,p,h,t=e.kind,s=e.result,x;if(x=e.input.charCodeAt(e.position),S(x)||R(x)||x===35||x===38||x===42||x===33||x===124||x===62||x===39||x===34||x===37||x===64||x===96||(x===63||x===45)&&(r=e.input.charCodeAt(e.position+1),S(r)||i&&R(r)))return!1;for(e.kind="scalar",e.result="",u=o=e.position,f=!1;x!==0;){if(x===58){if(r=e.input.charCodeAt(e.position+1),S(r)||i&&R(r))break}else if(x===35){if(l=e.input.charCodeAt(e.position-1),S(l))break}else{if(e.position===e.lineStart&&$(e)||i&&R(x))break;if(b(x))if(a=e.line,p=e.lineStart,h=e.lineIndent,y(e,!1,-1),e.lineIndent>=n){f=!0,x=e.input.charCodeAt(e.position);continue}else{e.position=o,e.line=a,e.lineStart=p,e.lineIndent=h;break}}f&&(O(e,u,o,!1),le(e,e.line-a),u=o=e.position,f=!1),k(x)||(o=e.position+1),x=e.input.charCodeAt(++e.position)}return O(e,u,o,!1),e.result?!0:(e.kind=t,e.result=s,!1)}c(yi,"readPlainScalar");function Ci(e,n){var i,l,r;if(i=e.input.charCodeAt(e.position),i!==39)return!1;for(e.kind="scalar",e.result="",e.position++,l=r=e.position;(i=e.input.charCodeAt(e.position))!==0;)if(i===39)if(O(e,l,e.position,!0),i=e.input.charCodeAt(++e.position),i===39)l=e.position,e.position++,r=e.position;else return!0;else b(i)?(O(e,l,r,!0),le(e,y(e,!1,n)),l=r=e.position):e.position===e.lineStart&&$(e)?d(e,"unexpected end of the document within a single quoted scalar"):(e.position++,r=e.position);d(e,"unexpected end of the stream within a single quoted scalar")}c(Ci,"readSingleQuotedScalar");function _i(e,n){var i,l,r,u,o,f;if(f=e.input.charCodeAt(e.position),f!==34)return!1;for(e.kind="scalar",e.result="",e.position++,i=l=e.position;(f=e.input.charCodeAt(e.position))!==0;){if(f===34)return O(e,i,e.position,!0),e.position++,!0;if(f===92){if(O(e,i,e.position,!0),f=e.input.charCodeAt(++e.position),b(f))y(e,!1,n);else if(f<256&&ke[f])e.result+=Ne[f],e.position++;else if((o=mi(f))>0){for(r=o,u=0;r>0;r--)f=e.input.charCodeAt(++e.position),(o=xi(f))>=0?u=(u<<4)+o:d(e,"expected hexadecimal character");e.result+=Ai(u),e.position++}else d(e,"unknown escape sequence");i=l=e.position}else b(f)?(O(e,i,l,!0),le(e,y(e,!1,n)),i=l=e.position):e.position===e.lineStart&&$(e)?d(e,"unexpected end of the document within a double quoted scalar"):(e.position++,l=e.position)}d(e,"unexpected end of the stream within a double quoted scalar")}c(_i,"readDoubleQuotedScalar");function wi(e,n){var i=!0,l,r,u,o=e.tag,f,a=e.anchor,p,h,t,s,x,m=Object.create(null),A,v,F,g;if(g=e.input.charCodeAt(e.position),g===91)h=93,x=!1,f=[];else if(g===123)h=125,x=!0,f={};else return!1;for(e.anchor!==null&&(e.anchorMap[e.anchor]=f),g=e.input.charCodeAt(++e.position);g!==0;){if(y(e,!0,n),g=e.input.charCodeAt(e.position),g===h)return e.position++,e.tag=o,e.anchor=a,e.kind=x?"mapping":"sequence",e.result=f,!0;i?g===44&&d(e,"expected the node content, but found ','"):d(e,"missed comma between flow collection entries"),v=A=F=null,t=s=!1,g===63&&(p=e.input.charCodeAt(e.position+1),S(p)&&(t=s=!0,e.position++,y(e,!0,n))),l=e.line,r=e.lineStart,u=e.position,M(e,n,U,!1,!0),v=e.tag,A=e.result,y(e,!0,n),g=e.input.charCodeAt(e.position),(s||e.line===l)&&g===58&&(t=!0,g=e.input.charCodeAt(++e.position),y(e,!0,n),M(e,n,U,!1,!0),F=e.result),x?D(e,f,m,v,A,F,l,r,u):t?f.push(D(e,null,m,v,A,F,l,r,u)):f.push(A),y(e,!0,n),g=e.input.charCodeAt(e.position),g===44?(i=!0,g=e.input.charCodeAt(++e.position)):i=!1}d(e,"unexpected end of the stream within a flow collection")}c(wi,"readFlowCollection");function Ei(e,n){var i,l,r=X,u=!1,o=!1,f=n,a=0,p=!1,h,t;if(t=e.input.charCodeAt(e.position),t===124)l=!1;else if(t===62)l=!0;else return!1;for(e.kind="scalar",e.result="";t!==0;)if(t=e.input.charCodeAt(++e.position),t===43||t===45)X===r?r=t===43?ce:ti:d(e,"repeat of a chomping mode identifier");else if((h=gi(t))>=0)h===0?d(e,"bad explicit indentation width of a block scalar; it cannot be less than one"):o?d(e,"repeat of an indentation width identifier"):(f=n+h-1,o=!0);else break;if(k(t)){do t=e.input.charCodeAt(++e.position);while(k(t));if(t===35)do t=e.input.charCodeAt(++e.position);while(!b(t)&&t!==0)}for(;t!==0;){for(re(e),e.lineIndent=0,t=e.input.charCodeAt(e.position);(!o||e.lineIndentf&&(f=e.lineIndent),b(t)){a++;continue}if(e.lineIndentn)&&a!==0)d(e,"bad indentation of a sequence entry");else if(e.lineIndentn)&&(v&&(o=e.line,f=e.lineStart,a=e.position),M(e,n,K,!0,r)&&(v?m=e.result:A=e.result),v||(D(e,t,s,x,m,A,o,f,a),x=m=A=null),y(e,!0,-1),g=e.input.charCodeAt(e.position)),(e.line===u||e.lineIndent>n)&&g!==0)d(e,"bad indentation of a mapping entry");else if(e.lineIndentn?a=1:e.lineIndent===n?a=0:e.lineIndentn?a=1:e.lineIndent===n?a=0:e.lineIndent tag; it should be "scalar", not "'+e.kind+'"'),t=0,s=e.implicitTypes.length;t"),e.result!==null&&m.kind!==e.kind&&d(e,"unacceptable node kind for !<"+e.tag+'> tag; it should be "'+m.kind+'", not "'+e.kind+'"'),m.resolve(e.result,e.tag)?(e.result=m.construct(e.result,e.tag),e.anchor!==null&&(e.anchorMap[e.anchor]=e.result)):d(e,"cannot resolve a node with !<"+e.tag+"> explicit tag")}return e.listener!==null&&e.listener("close",e),e.tag!==null||e.anchor!==null||h}c(M,"composeNode");function Oi(e){var n=e.position,i,l,r,u=!1,o;for(e.version=null,e.checkLineBreaks=e.legacy,e.tagMap=Object.create(null),e.anchorMap=Object.create(null);(o=e.input.charCodeAt(e.position))!==0&&(y(e,!0,-1),o=e.input.charCodeAt(e.position),!(e.lineIndent>0||o!==37));){for(u=!0,o=e.input.charCodeAt(++e.position),i=e.position;o!==0&&!S(o);)o=e.input.charCodeAt(++e.position);for(l=e.input.slice(i,e.position),r=[],l.length<1&&d(e,"directive name must not be less than one character in length");o!==0;){for(;k(o);)o=e.input.charCodeAt(++e.position);if(o===35){do o=e.input.charCodeAt(++e.position);while(o!==0&&!b(o));break}if(b(o))break;for(i=e.position;o!==0&&!S(o);)o=e.input.charCodeAt(++e.position);r.push(e.input.slice(i,e.position))}o!==0&&re(e),I.call(te,l)?te[l](e,l,r):q(e,'unknown document directive "'+l+'"')}if(y(e,!0,-1),e.lineIndent===0&&e.input.charCodeAt(e.position)===45&&e.input.charCodeAt(e.position+1)===45&&e.input.charCodeAt(e.position+2)===45?(e.position+=3,y(e,!0,-1)):u&&d(e,"directives end mark is expected"),M(e,e.lineIndent-1,K,!1,!0),y(e,!0,-1),e.checkLineBreaks&&di.test(e.input.slice(n,e.position))&&q(e,"non-ASCII line breaks are interpreted as content"),e.documents.push(e.result),e.position===e.lineStart&&$(e)){e.input.charCodeAt(e.position)===46&&(e.position+=3,y(e,!0,-1));return}if(e.position"u"&&(i=n,n=null);var l=De(e,i);if(typeof n!="function")return l;for(var r=0,u=l.length;r=55296&&i<=56319&&n+1=56320&&l<=57343)?(i-55296)*1024+l-56320+65536:i}c(Y,"codePointAt");function qe(e){var n=/^\n* /;return n.test(e)}c(qe,"needIndentIndicator");var Ge=1,ee=2,We=3,$e=4,N=5;function or(e,n,i,l,r,u,o,f){var a,p=0,h=null,t=!1,s=!1,x=l!==-1,m=-1,A=rr(Y(e,0))&&lr(Y(e,e.length-1));if(n||o)for(a=0;a=65536?a+=2:a++){if(p=Y(e,a),!j(p))return N;A=A&&me(p,h,f),h=p}else{for(a=0;a=65536?a+=2:a++){if(p=Y(e,a),p===P)t=!0,x&&(s=s||a-m-1>l&&e[m+1]!==" ",m=a);else if(!j(p))return N;A=A&&me(p,h,f),h=p}s=s||x&&a-m-1>l&&e[m+1]!==" "}return!t&&!s?A&&!o&&!r(e)?Ge:u===H?N:ee:i>9&&qe(e)?N:o?u===H?N:ee:s?$e:We}c(or,"chooseScalarStyle");function ur(e,n,i,l,r){e.dump=function(){if(n.length===0)return e.quotingType===H?'""':"''";if(!e.noCompatMode&&(Xi.indexOf(n)!==-1||Zi.test(n)))return e.quotingType===H?'"'+n+'"':"'"+n+"'";var u=e.indent*Math.max(1,i),o=e.lineWidth===-1?-1:Math.max(Math.min(e.lineWidth,40),e.lineWidth-u),f=l||e.flowLevel>-1&&i>=e.flowLevel;function a(p){return ir(e,p)}switch(c(a,"testAmbiguity"),or(n,f,e.indent,o,a,e.quotingType,e.forceQuotes&&!l,r)){case Ge:return n;case ee:return"'"+n.replace(/'/g,"''")+"'";case We:return"|"+ge(n,e.indent)+Ae(se(n,u));case $e:return">"+ge(n,e.indent)+Ae(se(fr(n,o),u));case N:return'"'+cr(n)+'"';default:throw new E("impossible error: invalid scalar style")}}()}c(ur,"writeScalar");function ge(e,n){var i=qe(e)?String(n):"",l=e[e.length-1]===` +`,r=l&&(e[e.length-2]===` +`||e===` +`),u=r?"+":l?"":"-";return i+u+` +`}c(ge,"blockHeader");function Ae(e){return e[e.length-1]===` +`?e.slice(0,-1):e}c(Ae,"dropEndingNewline");function fr(e,n){for(var i=/(\n+)([^\n]*)/g,l=function(){var p=e.indexOf(` +`);return p=p!==-1?p:e.length,i.lastIndex=p,ve(e.slice(0,p),n)}(),r=e[0]===` +`||e[0]===" ",u,o;o=i.exec(e);){var f=o[1],a=o[2];u=a[0]===" ",l+=f+(!r&&!u&&a!==""?` +`:"")+ve(a,n),r=u}return l}c(fr,"foldString");function ve(e,n){if(e===""||e[0]===" ")return e;for(var i=/ [^ ]/g,l,r=0,u,o=0,f=0,a="";l=i.exec(e);)f=l.index,f-r>n&&(u=o>r?o:f,a+=` +`+e.slice(r,u),r=u+1),o=f;return a+=` +`,e.length-r>n&&o>r?a+=e.slice(r,o)+` +`+e.slice(o+1):a+=e.slice(r),a.slice(1)}c(ve,"foldLine");function cr(e){for(var n="",i=0,l,r=0;r=65536?r+=2:r++)i=Y(e,r),l=w[i],!l&&j(i)?(n+=e[r],i>=65536&&(n+=e[r+1])):n+=l||Ji(i);return n}c(cr,"escapeString");function ar(e,n,i){var l="",r=e.tag,u,o,f;for(u=0,o=i.length;u"u"&&T(e,n,null,!1,!1))&&(l!==""&&(l+=","+(e.condenseFlow?"":" ")),l+=e.dump);e.tag=r,e.dump="["+l+"]"}c(ar,"writeFlowSequence");function ye(e,n,i,l){var r="",u=e.tag,o,f,a;for(o=0,f=i.length;o"u"&&T(e,n+1,null,!0,!0,!1,!0))&&((!l||r!=="")&&(r+=J(e,n)),e.dump&&P===e.dump.charCodeAt(0)?r+="-":r+="- ",r+=e.dump);e.tag=u,e.dump=r||"[]"}c(ye,"writeBlockSequence");function pr(e,n,i){var l="",r=e.tag,u=Object.keys(i),o,f,a,p,h;for(o=0,f=u.length;o1024&&(h+="? "),h+=e.dump+(e.condenseFlow?'"':"")+":"+(e.condenseFlow?"":" "),T(e,n,p,!1,!1)&&(h+=e.dump,l+=h));e.tag=r,e.dump="{"+l+"}"}c(pr,"writeFlowMapping");function tr(e,n,i,l){var r="",u=e.tag,o=Object.keys(i),f,a,p,h,t,s;if(e.sortKeys===!0)o.sort();else if(typeof e.sortKeys=="function")o.sort(e.sortKeys);else if(e.sortKeys)throw new E("sortKeys must be a boolean or a function");for(f=0,a=o.length;f1024,t&&(e.dump&&P===e.dump.charCodeAt(0)?s+="?":s+="? "),s+=e.dump,t&&(s+=J(e,n)),T(e,n+1,h,!0,t)&&(e.dump&&P===e.dump.charCodeAt(0)?s+=":":s+=": ",s+=e.dump,r+=s));e.tag=u,e.dump=r||"{}"}c(tr,"writeBlockMapping");function Ce(e,n,i){var l,r,u,o,f,a;for(r=i?e.explicitTypes:e.implicitTypes,u=0,o=r.length;u tag resolver accepts not "'+a+'" style');e.dump=l}return!0}return!1}c(Ce,"detectType");function T(e,n,i,l,r,u,o){e.tag=null,e.dump=i,Ce(e,i,!1)||Ce(e,i,!0);var f=Ye.call(e.dump),a=l,p;l&&(l=e.flowLevel<0||e.flowLevel>n);var h=f==="[object Object]"||f==="[object Array]",t,s;if(h&&(t=e.duplicates.indexOf(i),s=t!==-1),(e.tag!==null&&e.tag!=="?"||s||e.indent!==2&&n>0)&&(r=!1),s&&e.usedDuplicates[t])e.dump="*ref_"+t;else{if(h&&s&&!e.usedDuplicates[t]&&(e.usedDuplicates[t]=!0),f==="[object Object]")l&&Object.keys(e.dump).length!==0?(tr(e,n,e.dump,r),s&&(e.dump="&ref_"+t+e.dump)):(pr(e,n,e.dump),s&&(e.dump="&ref_"+t+" "+e.dump));else if(f==="[object Array]")l&&e.dump.length!==0?(e.noArrayIndent&&!o&&n>0?ye(e,n-1,e.dump,r):ye(e,n,e.dump,r),s&&(e.dump="&ref_"+t+e.dump)):(ar(e,n,e.dump),s&&(e.dump="&ref_"+t+" "+e.dump));else if(f==="[object String]")e.tag!=="?"&&ur(e,e.dump,n,u,a);else{if(f==="[object Undefined]")return!1;if(e.skipInvalid)return!1;throw new E("unacceptable kind of an object to dump "+f)}e.tag!==null&&e.tag!=="?"&&(p=encodeURI(e.tag[0]==="!"?e.tag.slice(1):e.tag).replace(/!/g,"%21"),e.tag[0]==="!"?p="!"+p:p.slice(0,18)==="tag:yaml.org,2002:"?p="!!"+p.slice(18):p="!<"+p+">",e.dump=p+" "+e.dump)}return!0}c(T,"writeNode");function hr(e,n){var i=[],l=[],r,u;for(ne(e,i,l),r=0,u=l.length;r"']/,Le=new RegExp(fe.source,"g"),ge=/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,Me=new RegExp(ge.source,"g"),Ie={"&":"&","<":"<",">":">",'"':""","'":"'"},oe=f(a=>Ie[a],"getEscapeReplacement");function m(a,e){if(e){if(fe.test(a))return a.replace(Le,oe)}else if(ge.test(a))return a.replace(Me,oe);return a}f(m,"escape$1");var _e=/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig;function Ee(a){return a.replace(_e,(e,t)=>(t=t.toLowerCase(),t==="colon"?":":t.charAt(0)==="#"?t.charAt(1)==="x"?String.fromCharCode(parseInt(t.substring(2),16)):String.fromCharCode(+t.substring(1)):""))}f(Ee,"unescape");var Ae=/(^|[^\[])\^/g;function x(a,e){let t=typeof a=="string"?a:a.source;e=e||"";let s={replace:f((n,r)=>{let i=typeof r=="string"?r:r.source;return i=i.replace(Ae,"$1"),t=t.replace(n,i),s},"replace"),getRegex:f(()=>new RegExp(t,e),"getRegex")};return s}f(x,"edit");function ae(a){try{a=encodeURI(a).replace(/%25/g,"%")}catch{return null}return a}f(ae,"cleanUrl");var _={exec:f(()=>null,"exec")};function ce(a,e){let t=a.replace(/\|/g,(r,i,l)=>{let o=!1,p=i;for(;--p>=0&&l[p]==="\\";)o=!o;return o?"|":" |"}),s=t.split(/ \|/),n=0;if(s[0].trim()||s.shift(),s.length>0&&!s[s.length-1].trim()&&s.pop(),e)if(s.length>e)s.splice(e);else for(;s.length{let r=n.match(/^\s+/);if(r===null)return n;let[i]=r;return i.length>=s.length?n.slice(s.length):n}).join(` +`)}f(ve,"indentCodeCompensation");var S=class{static{f(this,"_Tokenizer")}options;rules;lexer;constructor(e){this.options=e||R}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let s=t[0].replace(/^ {1,4}/gm,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?s:M(s,` +`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let s=t[0],n=ve(s,t[3]||"");return{type:"code",raw:s,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:n}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let s=t[2].trim();if(/#$/.test(s)){let n=M(s,"#");(this.options.pedantic||!n||/ $/.test(n))&&(s=n.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:s,tokens:this.lexer.inline(s)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:M(t[0],` +`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let s=M(t[0],` +`).split(` +`),n="",r="",i=[];for(;s.length>0;){let l=!1,o=[],p;for(p=0;p/.test(s[p]))o.push(s[p]),l=!0;else if(!l)o.push(s[p]);else break;s=s.slice(p);let c=o.join(` +`),h=c.replace(/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,` + $1`).replace(/^ {0,3}>[ \t]?/gm,"");n=n?`${n} +${c}`:c,r=r?`${r} +${h}`:h;let u=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTokens(h,i,!0),this.lexer.state.top=u,s.length===0)break;let g=i[i.length-1];if(g?.type==="code")break;if(g?.type==="blockquote"){let d=g,b=d.raw+` +`+s.join(` +`),w=this.blockquote(b);i[i.length-1]=w,n=n.substring(0,n.length-d.raw.length)+w.raw,r=r.substring(0,r.length-d.text.length)+w.text;break}else if(g?.type==="list"){let d=g,b=d.raw+` +`+s.join(` +`),w=this.list(b);i[i.length-1]=w,n=n.substring(0,n.length-g.raw.length)+w.raw,r=r.substring(0,r.length-d.raw.length)+w.raw,s=b.substring(i[i.length-1].raw.length).split(` +`);continue}}return{type:"blockquote",raw:n,tokens:i,text:r}}}list(e){let t=this.rules.block.list.exec(e);if(t){let s=t[1].trim(),n=s.length>1,r={type:"list",raw:"",ordered:n,start:n?+s.slice(0,-1):"",loose:!1,items:[]};s=n?`\\d{1,9}\\${s.slice(-1)}`:`\\${s}`,this.options.pedantic&&(s=n?s:"[*+-]");let i=new RegExp(`^( {0,3}${s})((?:[ ][^\\n]*)?(?:\\n|$))`),l=!1;for(;e;){let o=!1,p="",c="";if(!(t=i.exec(e))||this.rules.block.hr.test(e))break;p=t[0],e=e.substring(p.length);let h=t[2].split(` +`,1)[0].replace(/^\t+/,q=>" ".repeat(3*q.length)),u=e.split(` +`,1)[0],g=!h.trim(),d=0;if(this.options.pedantic?(d=2,c=h.trimStart()):g?d=t[1].length+1:(d=t[2].search(/[^ ]/),d=d>4?1:d,c=h.slice(d),d+=t[1].length),g&&/^ *$/.test(u)&&(p+=u+` +`,e=e.substring(u.length+1),o=!0),!o){let q=new RegExp(`^ {0,${Math.min(3,d-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),Y=new RegExp(`^ {0,${Math.min(3,d-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),J=new RegExp(`^ {0,${Math.min(3,d-1)}}(?:\`\`\`|~~~)`),ee=new RegExp(`^ {0,${Math.min(3,d-1)}}#`);for(;e;){let Z=e.split(` +`,1)[0];if(u=Z,this.options.pedantic&&(u=u.replace(/^ {1,4}(?=( {4})*[^ ])/g," ")),J.test(u)||ee.test(u)||q.test(u)||Y.test(e))break;if(u.search(/[^ ]/)>=d||!u.trim())c+=` +`+u.slice(d);else{if(g||h.search(/[^ ]/)>=4||J.test(h)||ee.test(h)||Y.test(h))break;c+=` +`+u}!g&&!u.trim()&&(g=!0),p+=Z+` +`,e=e.substring(Z.length+1),h=u.slice(d)}}r.loose||(l?r.loose=!0:/\n *\n *$/.test(p)&&(l=!0));let b=null,w;this.options.gfm&&(b=/^\[[ xX]\] /.exec(c),b&&(w=b[0]!=="[ ] ",c=c.replace(/^\[[ xX]\] +/,""))),r.items.push({type:"list_item",raw:p,task:!!b,checked:w,loose:!1,text:c,tokens:[]}),r.raw+=p}r.items[r.items.length-1].raw=r.items[r.items.length-1].raw.trimEnd(),r.items[r.items.length-1].text=r.items[r.items.length-1].text.trimEnd(),r.raw=r.raw.trimEnd();for(let o=0;oh.type==="space"),c=p.length>0&&p.some(h=>/\n.*\n/.test(h.raw));r.loose=c}if(r.loose)for(let o=0;o$/,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",r=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:s,raw:t[0],href:n,title:r}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!/[:|]/.test(t[2]))return;let s=ce(t[1]),n=t[2].replace(/^\||\| *$/g,"").split("|"),r=t[3]&&t[3].trim()?t[3].replace(/\n[ \t]*$/,"").split(` +`):[],i={type:"table",raw:t[0],header:[],align:[],rows:[]};if(s.length===n.length){for(let l of n)/^ *-+: *$/.test(l)?i.align.push("right"):/^ *:-+: *$/.test(l)?i.align.push("center"):/^ *:-+ *$/.test(l)?i.align.push("left"):i.align.push(null);for(let l=0;l({text:o,tokens:this.lexer.inline(o),header:!1,align:i.align[p]})));return i}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let s=t[1].charAt(t[1].length-1)===` +`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:s,tokens:this.lexer.inline(s)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:m(t[1])}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&/^/i.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&/^<(pre|code|kbd|script)(\s|>)/i.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&/^<\/(pre|code|kbd|script)(\s|>)/i.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let s=t[2].trim();if(!this.options.pedantic&&/^$/.test(s))return;let i=M(s.slice(0,-1),"\\");if((s.length-i.length)%2===0)return}else{let i=Ce(t[2],"()");if(i>-1){let o=(t[0].indexOf("!")===0?5:4)+t[1].length+i;t[2]=t[2].substring(0,i),t[0]=t[0].substring(0,o).trim(),t[3]=""}}let n=t[2],r="";if(this.options.pedantic){let i=/^([^'"]*[^\s])\s+(['"])(.*)\2/.exec(n);i&&(n=i[1],r=i[3])}else r=t[3]?t[3].slice(1,-1):"";return n=n.trim(),/^$/.test(s)?n=n.slice(1):n=n.slice(1,-1)),pe(t,{href:n&&n.replace(this.rules.inline.anyPunctuation,"$1"),title:r&&r.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer)}}reflink(e,t){let s;if((s=this.rules.inline.reflink.exec(e))||(s=this.rules.inline.nolink.exec(e))){let n=(s[2]||s[1]).replace(/\s+/g," "),r=t[n.toLowerCase()];if(!r){let i=s[0].charAt(0);return{type:"text",raw:i,text:i}}return pe(s,r,s[0],this.lexer)}}emStrong(e,t,s=""){let n=this.rules.inline.emStrongLDelim.exec(e);if(!n||n[3]&&s.match(/[\p{L}\p{N}]/u))return;if(!(n[1]||n[2]||"")||!s||this.rules.inline.punctuation.exec(s)){let i=[...n[0]].length-1,l,o,p=i,c=0,h=n[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(h.lastIndex=0,t=t.slice(-1*e.length+i);(n=h.exec(t))!=null;){if(l=n[1]||n[2]||n[3]||n[4]||n[5]||n[6],!l)continue;if(o=[...l].length,n[3]||n[4]){p+=o;continue}else if((n[5]||n[6])&&i%3&&!((i+o)%3)){c+=o;continue}if(p-=o,p>0)continue;o=Math.min(o,o+p+c);let u=[...n[0]][0].length,g=e.slice(0,i+n.index+u+o);if(Math.min(i,o)%2){let b=g.slice(1,-1);return{type:"em",raw:g,text:b,tokens:this.lexer.inlineTokens(b)}}let d=g.slice(2,-2);return{type:"strong",raw:g,text:d,tokens:this.lexer.inlineTokens(d)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let s=t[2].replace(/\n/g," "),n=/[^ ]/.test(s),r=/^ /.test(s)&&/ $/.test(s);return n&&r&&(s=s.substring(1,s.length-1)),s=m(s,!0),{type:"codespan",raw:t[0],text:s}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e){let t=this.rules.inline.del.exec(e);if(t)return{type:"del",raw:t[0],text:t[2],tokens:this.lexer.inlineTokens(t[2])}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let s,n;return t[2]==="@"?(s=m(t[1]),n="mailto:"+s):(s=m(t[1]),n=s),{type:"link",raw:t[0],text:s,href:n,tokens:[{type:"text",raw:s,text:s}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let s,n;if(t[2]==="@")s=m(t[0]),n="mailto:"+s;else{let r;do r=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??"";while(r!==t[0]);s=m(t[0]),t[1]==="www."?n="http://"+t[0]:n=t[0]}return{type:"link",raw:t[0],text:s,href:n,tokens:[{type:"text",raw:s,text:s}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let s;return this.lexer.state.inRawBlock?s=t[0]:s=m(t[0]),{type:"text",raw:t[0],text:s}}}},je=/^(?: *(?:\n|$))+/,Be=/^( {4}[^\n]+(?:\n(?: *(?:\n|$))*)?)+/,We=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,A=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,qe=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,de=/(?:[*+-]|\d{1,9}[.)])/,ke=x(/^(?!bull |blockCode|fences|blockquote|heading|html)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html))+?)\n {0,3}(=+|-+) *(?:\n+|$)/).replace(/bull/g,de).replace(/blockCode/g,/ {4}/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).getRegex(),Q=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Ze=/^[^\n]+/,H=/(?!\s*\])(?:\\.|[^\[\]\\])+/,Pe=x(/^ {0,3}\[(label)\]: *(?:\n *)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n *)?| *\n *)(title))? *(?:\n+|$)/).replace("label",H).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),De=x(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,de).getRegex(),W="address|article|aside|base|basefont|blockquote|body|caption|center|col|colgroup|dd|details|dialog|dir|div|dl|dt|fieldset|figcaption|figure|footer|form|frame|frameset|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",N=/|$))/,Fe=x("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|\\n*|$)|\\n*|$)|)[\\s\\S]*?(?:(?:\\n *)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$)|(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n *)+\\n|$))","i").replace("comment",N).replace("tag",W).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),xe=x(Q).replace("hr",A).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",W).getRegex(),Oe=x(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",xe).getRegex(),G={blockquote:Oe,code:Be,def:Pe,fences:We,heading:qe,hr:A,html:Fe,lheading:ke,list:De,newline:je,paragraph:xe,table:_,text:Ze},he=x("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",A).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code"," {4}[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",W).getRegex(),Qe={...G,table:he,paragraph:x(Q).replace("hr",A).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",he).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html",")|<(?:script|pre|style|textarea|!--)").replace("tag",W).getRegex()},He={...G,html:x(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+? *(?:\\n{2,}|\\s*$)|\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",N).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:_,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:x(Q).replace("hr",A).replace("heading",` *#{1,6} *[^ +]`).replace("lheading",ke).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},me=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,Ne=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,be=/^( {2,}|\\)\n(?!\s*$)/,Ge=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\]*?>/g,Ke=x(/^(?:\*+(?:((?!\*)[punct])|[^\s*]))|^_+(?:((?!_)[punct])|([^\s_]))/,"u").replace(/punct/g,C).getRegex(),Ve=x("^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)[punct](\\*+)(?=[\\s]|$)|[^punct\\s](\\*+)(?!\\*)(?=[punct\\s]|$)|(?!\\*)[punct\\s](\\*+)(?=[^punct\\s])|[\\s](\\*+)(?!\\*)(?=[punct])|(?!\\*)[punct](\\*+)(?!\\*)(?=[punct])|[^punct\\s](\\*+)(?=[^punct\\s])","gu").replace(/punct/g,C).getRegex(),Ye=x("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)[punct](_+)(?=[\\s]|$)|[^punct\\s](_+)(?!_)(?=[punct\\s]|$)|(?!_)[punct\\s](_+)(?=[^punct\\s])|[\\s](_+)(?!_)(?=[punct])|(?!_)[punct](_+)(?!_)(?=[punct])","gu").replace(/punct/g,C).getRegex(),Je=x(/\\([punct])/,"gu").replace(/punct/g,C).getRegex(),et=x(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+(@)[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)+(?![-_])/).getRegex(),tt=x(N).replace("(?:-->|$)","-->").getRegex(),nt=x("^comment|^|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^|^").replace("comment",tt).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),B=/(?:\[(?:\\.|[^\[\]\\])*\]|\\.|`[^`]*`|[^\[\]\\`])*?/,st=x(/^!?\[(label)\]\(\s*(href)(?:\s+(title))?\s*\)/).replace("label",B).replace("href",/<(?:\\.|[^\n<>\\])+>|[^\s\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),we=x(/^!?\[(label)\]\[(ref)\]/).replace("label",B).replace("ref",H).getRegex(),ye=x(/^!?\[(ref)\](?:\[\])?/).replace("ref",H).getRegex(),rt=x("reflink|nolink(?!\\()","g").replace("reflink",we).replace("nolink",ye).getRegex(),U={_backpedal:_,anyPunctuation:Je,autolink:et,blockSkip:Xe,br:be,code:Ne,del:_,emStrongLDelim:Ke,emStrongRDelimAst:Ve,emStrongRDelimUnd:Ye,escape:me,link:st,nolink:ye,punctuation:Ue,reflink:we,reflinkSearch:rt,tag:nt,text:Ge,url:_},it={...U,link:x(/^!?\[(label)\]\((.*?)\)/).replace("label",B).getRegex(),reflink:x(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",B).getRegex()},D={...U,escape:x(me).replace("])","~|])").getRegex(),url:x(/^((?:ftp|https?):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/,"i").replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])([\s\S]*?[^\s~])\1(?=[^~]|$)/,text:/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\o+" ".repeat(p.length));let n,r,i;for(;e;)if(!(this.options.extensions&&this.options.extensions.block&&this.options.extensions.block.some(l=>(n=l.call({lexer:this},e,t))?(e=e.substring(n.raw.length),t.push(n),!0):!1))){if(n=this.tokenizer.space(e)){e=e.substring(n.raw.length),n.raw.length===1&&t.length>0?t[t.length-1].raw+=` +`:t.push(n);continue}if(n=this.tokenizer.code(e)){e=e.substring(n.raw.length),r=t[t.length-1],r&&(r.type==="paragraph"||r.type==="text")?(r.raw+=` +`+n.raw,r.text+=` +`+n.text,this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n);continue}if(n=this.tokenizer.fences(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.heading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.hr(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.blockquote(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.list(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.html(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.def(e)){e=e.substring(n.raw.length),r=t[t.length-1],r&&(r.type==="paragraph"||r.type==="text")?(r.raw+=` +`+n.raw,r.text+=` +`+n.raw,this.inlineQueue[this.inlineQueue.length-1].src=r.text):this.tokens.links[n.tag]||(this.tokens.links[n.tag]={href:n.href,title:n.title});continue}if(n=this.tokenizer.table(e)){e=e.substring(n.raw.length),t.push(n);continue}if(n=this.tokenizer.lheading(e)){e=e.substring(n.raw.length),t.push(n);continue}if(i=e,this.options.extensions&&this.options.extensions.startBlock){let l=1/0,o=e.slice(1),p;this.options.extensions.startBlock.forEach(c=>{p=c.call({lexer:this},o),typeof p=="number"&&p>=0&&(l=Math.min(l,p))}),l<1/0&&l>=0&&(i=e.substring(0,l+1))}if(this.state.top&&(n=this.tokenizer.paragraph(i))){r=t[t.length-1],s&&r?.type==="paragraph"?(r.raw+=` +`+n.raw,r.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n),s=i.length!==e.length,e=e.substring(n.raw.length);continue}if(n=this.tokenizer.text(e)){e=e.substring(n.raw.length),r=t[t.length-1],r&&r.type==="text"?(r.raw+=` +`+n.raw,r.text+=` +`+n.text,this.inlineQueue.pop(),this.inlineQueue[this.inlineQueue.length-1].src=r.text):t.push(n);continue}if(e){let l="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(l);break}else throw new Error(l)}}return this.state.top=!0,t}inline(e,t=[]){return this.inlineQueue.push({src:e,tokens:t}),t}inlineTokens(e,t=[]){let s,n,r,i=e,l,o,p;if(this.tokens.links){let c=Object.keys(this.tokens.links);if(c.length>0)for(;(l=this.tokenizer.rules.inline.reflinkSearch.exec(i))!=null;)c.includes(l[0].slice(l[0].lastIndexOf("[")+1,-1))&&(i=i.slice(0,l.index)+"["+"a".repeat(l[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(l=this.tokenizer.rules.inline.blockSkip.exec(i))!=null;)i=i.slice(0,l.index)+"["+"a".repeat(l[0].length-2)+"]"+i.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);for(;(l=this.tokenizer.rules.inline.anyPunctuation.exec(i))!=null;)i=i.slice(0,l.index)+"++"+i.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);for(;e;)if(o||(p=""),o=!1,!(this.options.extensions&&this.options.extensions.inline&&this.options.extensions.inline.some(c=>(s=c.call({lexer:this},e,t))?(e=e.substring(s.raw.length),t.push(s),!0):!1))){if(s=this.tokenizer.escape(e)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.tag(e)){e=e.substring(s.raw.length),n=t[t.length-1],n&&s.type==="text"&&n.type==="text"?(n.raw+=s.raw,n.text+=s.text):t.push(s);continue}if(s=this.tokenizer.link(e)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.reflink(e,this.tokens.links)){e=e.substring(s.raw.length),n=t[t.length-1],n&&s.type==="text"&&n.type==="text"?(n.raw+=s.raw,n.text+=s.text):t.push(s);continue}if(s=this.tokenizer.emStrong(e,i,p)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.codespan(e)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.br(e)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.del(e)){e=e.substring(s.raw.length),t.push(s);continue}if(s=this.tokenizer.autolink(e)){e=e.substring(s.raw.length),t.push(s);continue}if(!this.state.inLink&&(s=this.tokenizer.url(e))){e=e.substring(s.raw.length),t.push(s);continue}if(r=e,this.options.extensions&&this.options.extensions.startInline){let c=1/0,h=e.slice(1),u;this.options.extensions.startInline.forEach(g=>{u=g.call({lexer:this},h),typeof u=="number"&&u>=0&&(c=Math.min(c,u))}),c<1/0&&c>=0&&(r=e.substring(0,c+1))}if(s=this.tokenizer.inlineText(r)){e=e.substring(s.raw.length),s.raw.slice(-1)!=="_"&&(p=s.raw.slice(-1)),o=!0,n=t[t.length-1],n&&n.type==="text"?(n.raw+=s.raw,n.text+=s.text):t.push(s);continue}if(e){let c="Infinite loop on byte: "+e.charCodeAt(0);if(this.options.silent){console.error(c);break}else throw new Error(c)}}return t}},L=class{static{f(this,"_Renderer")}options;parser;constructor(e){this.options=e||R}space(e){return""}code({text:e,lang:t,escaped:s}){let n=(t||"").match(/^\S*/)?.[0],r=e.replace(/\n$/,"")+` +`;return n?'
'+(s?r:m(r,!0))+`
+`:"
"+(s?r:m(r,!0))+`
+`}blockquote({tokens:e}){return`
+${this.parser.parse(e)}
+`}html({text:e}){return e}heading({tokens:e,depth:t}){return`${this.parser.parseInline(e)} +`}hr(e){return`
+`}list(e){let t=e.ordered,s=e.start,n="";for(let l=0;l +`+n+" +`}listitem(e){let t="";if(e.task){let s=this.checkbox({checked:!!e.checked});e.loose?e.tokens.length>0&&e.tokens[0].type==="paragraph"?(e.tokens[0].text=s+" "+e.tokens[0].text,e.tokens[0].tokens&&e.tokens[0].tokens.length>0&&e.tokens[0].tokens[0].type==="text"&&(e.tokens[0].tokens[0].text=s+" "+e.tokens[0].tokens[0].text)):e.tokens.unshift({type:"text",raw:s+" ",text:s+" "}):t+=s+" "}return t+=this.parser.parse(e.tokens,!!e.loose),`
  • ${t}
  • +`}checkbox({checked:e}){return"'}paragraph({tokens:e}){return`

    ${this.parser.parseInline(e)}

    +`}table(e){let t="",s="";for(let r=0;r${n}`),` + +`+t+` +`+n+`
    +`}tablerow({text:e}){return` +${e} +`}tablecell(e){let t=this.parser.parseInline(e.tokens),s=e.header?"th":"td";return(e.align?`<${s} align="${e.align}">`:`<${s}>`)+t+` +`}strong({tokens:e}){return`${this.parser.parseInline(e)}`}em({tokens:e}){return`${this.parser.parseInline(e)}`}codespan({text:e}){return`${e}`}br(e){return"
    "}del({tokens:e}){return`${this.parser.parseInline(e)}`}link({href:e,title:t,tokens:s}){let n=this.parser.parseInline(s),r=ae(e);if(r===null)return n;e=r;let i='
    ",i}image({href:e,title:t,text:s}){let n=ae(e);if(n===null)return s;e=n;let r=`${s}{let l=r[i].flat(1/0);s=s.concat(this.walkTokens(l,t))}):r.tokens&&(s=s.concat(this.walkTokens(r.tokens,t)))}}return s}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(s=>{let n={...s};if(n.async=this.defaults.async||n.async||!1,s.extensions&&(s.extensions.forEach(r=>{if(!r.name)throw new Error("extension name required");if("renderer"in r){let i=t.renderers[r.name];i?t.renderers[r.name]=function(...l){let o=r.renderer.apply(this,l);return o===!1&&(o=i.apply(this,l)),o}:t.renderers[r.name]=r.renderer}if("tokenizer"in r){if(!r.level||r.level!=="block"&&r.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let i=t[r.level];i?i.unshift(r.tokenizer):t[r.level]=[r.tokenizer],r.start&&(r.level==="block"?t.startBlock?t.startBlock.push(r.start):t.startBlock=[r.start]:r.level==="inline"&&(t.startInline?t.startInline.push(r.start):t.startInline=[r.start]))}"childTokens"in r&&r.childTokens&&(t.childTokens[r.name]=r.childTokens)}),n.extensions=t),s.renderer){let r=this.defaults.renderer||new L(this.defaults);for(let i in s.renderer){if(!(i in r))throw new Error(`renderer '${i}' does not exist`);if(["options","parser"].includes(i))continue;let l=i,o=s.renderer[l];s.useNewRenderer||(o=this.#t(o,l,r));let p=r[l];r[l]=(...c)=>{let h=o.apply(r,c);return h===!1&&(h=p.apply(r,c)),h||""}}n.renderer=r}if(s.tokenizer){let r=this.defaults.tokenizer||new S(this.defaults);for(let i in s.tokenizer){if(!(i in r))throw new Error(`tokenizer '${i}' does not exist`);if(["options","rules","lexer"].includes(i))continue;let l=i,o=s.tokenizer[l],p=r[l];r[l]=(...c)=>{let h=o.apply(r,c);return h===!1&&(h=p.apply(r,c)),h}}n.tokenizer=r}if(s.hooks){let r=this.defaults.hooks||new z;for(let i in s.hooks){if(!(i in r))throw new Error(`hook '${i}' does not exist`);if(i==="options")continue;let l=i,o=s.hooks[l],p=r[l];z.passThroughHooks.has(i)?r[l]=c=>{if(this.defaults.async)return Promise.resolve(o.call(r,c)).then(u=>p.call(r,u));let h=o.call(r,c);return p.call(r,h)}:r[l]=(...c)=>{let h=o.apply(r,c);return h===!1&&(h=p.apply(r,c)),h}}n.hooks=r}if(s.walkTokens){let r=this.defaults.walkTokens,i=s.walkTokens;n.walkTokens=function(l){let o=[];return o.push(i.call(this,l)),r&&(o=o.concat(r.call(this,l))),o}}this.defaults={...this.defaults,...n}}),this}#t(e,t,s){switch(t){case"heading":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,s.parser.parseInline(n.tokens),n.depth,Ee(s.parser.parseInline(n.tokens,s.parser.textRenderer)))};case"code":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.text,n.lang,!!n.escaped)};case"table":return function(n){if(!n.type||n.type!==t)return e.apply(this,arguments);let r="",i="";for(let o=0;o0&&c.tokens[0].type==="paragraph"?(c.tokens[0].text=d+" "+c.tokens[0].text,c.tokens[0].tokens&&c.tokens[0].tokens.length>0&&c.tokens[0].tokens[0].type==="text"&&(c.tokens[0].tokens[0].text=d+" "+c.tokens[0].tokens[0].text)):c.tokens.unshift({type:"text",text:d+" "}):g+=d+" "}g+=this.parser.parse(c.tokens,l),o+=this.listitem({type:"list_item",raw:g,text:g,task:u,checked:!!h,loose:l,tokens:c.tokens})}return e.call(this,o,r,i)};case"html":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.text,n.block)};case"paragraph":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,this.parser.parseInline(n.tokens))};case"escape":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.text)};case"link":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.href,n.title,this.parser.parseInline(n.tokens))};case"image":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.href,n.title,n.text)};case"strong":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,this.parser.parseInline(n.tokens))};case"em":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,this.parser.parseInline(n.tokens))};case"codespan":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.text)};case"del":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,this.parser.parseInline(n.tokens))};case"text":return function(n){return!n.type||n.type!==t?e.apply(this,arguments):e.call(this,n.text)}}return e}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return y.lex(e,t??this.defaults)}parser(e,t){return T.parse(e,t??this.defaults)}#e(e,t){return(s,n)=>{let r={...n},i={...this.defaults,...r};this.defaults.async===!0&&r.async===!1&&(i.silent||console.warn("marked(): The async option was set to true by an extension. The async: false option sent to parse will be ignored."),i.async=!0);let l=this.#n(!!i.silent,!!i.async);if(typeof s>"u"||s===null)return l(new Error("marked(): input parameter is undefined or null"));if(typeof s!="string")return l(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(s)+", string expected"));if(i.hooks&&(i.hooks.options=i),i.async)return Promise.resolve(i.hooks?i.hooks.preprocess(s):s).then(o=>e(o,i)).then(o=>i.hooks?i.hooks.processAllTokens(o):o).then(o=>i.walkTokens?Promise.all(this.walkTokens(o,i.walkTokens)).then(()=>o):o).then(o=>t(o,i)).then(o=>i.hooks?i.hooks.postprocess(o):o).catch(l);try{i.hooks&&(s=i.hooks.preprocess(s));let o=e(s,i);i.hooks&&(o=i.hooks.processAllTokens(o)),i.walkTokens&&this.walkTokens(o,i.walkTokens);let p=t(o,i);return i.hooks&&(p=i.hooks.postprocess(p)),p}catch(o){return l(o)}}}#n(e,t){return s=>{if(s.message+=` +Please report this to https://github.com/markedjs/marked.`,e){let n="

    An error occurred:

    "+m(s.message+"",!0)+"
    ";return t?Promise.resolve(n):n}if(t)return Promise.reject(s);throw s}}},$=new F;function k(a,e){return $.parse(a,e)}f(k,"marked");k.options=k.setOptions=function(a){return $.setOptions(a),k.defaults=$.defaults,ue(k.defaults),k};k.getDefaults=O;k.defaults=R;k.use=function(...a){return $.use(...a),k.defaults=$.defaults,ue(k.defaults),k};k.walkTokens=function(a,e){return $.walkTokens(a,e)};k.parseInline=$.parseInline;k.Parser=T;k.parser=T.parse;k.Renderer=L;k.TextRenderer=E;k.Lexer=y;k.lexer=y.lex;k.Tokenizer=S;k.Hooks=z;k.parse=k;var kt=k.options,xt=k.setOptions,mt=k.use,bt=k.walkTokens,wt=k.parseInline;var yt=T.parse,Tt=y.lex;function ot(a,{markdownAutoWrap:e}){let s=a.replace(//g,` +`).replace(/\n{2,}/g,` +`),n=le(s);return e===!1?n.replace(/ /g," "):n}f(ot,"preprocessMarkdown");function Te(a,e={}){let t=ot(a,e),s=k.lexer(t),n=[[]],r=0;function i(l,o="normal"){l.type==="text"?l.text.split(` +`).forEach((c,h)=>{h!==0&&(r++,n.push([])),c.split(" ").forEach(u=>{u=u.replace(/'/g,"'"),u&&n[r].push({content:u,type:o})})}):l.type==="strong"||l.type==="em"?l.tokens.forEach(p=>{i(p,l.type)}):l.type==="html"&&n[r].push({content:l.text,type:"normal"})}return f(i,"processNode"),s.forEach(l=>{l.type==="paragraph"?l.tokens?.forEach(o=>{i(o)}):l.type==="html"&&n[r].push({content:l.text,type:"normal"})}),n}f(Te,"markdownToLines");function $e(a,{markdownAutoWrap:e}={}){let t=k.lexer(a);function s(n){return n.type==="text"?e===!1?n.text.replace(/\n */g,"
    ").replace(/ /g," "):n.text.replace(/\n */g,"
    "):n.type==="strong"?`${n.tokens?.map(s).join("")}`:n.type==="em"?`${n.tokens?.map(s).join("")}`:n.type==="paragraph"?`

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

    `:n.type==="space"?"":n.type==="html"?`${n.text}`:n.type==="escape"?n.text:`Unsupported markdown: ${n.type}`}return f(s,"output"),t.map(s).join("")}f($e,"markdownToHTML");function at(a){return Intl.Segmenter?[...new Intl.Segmenter().segment(a)].map(e=>e.segment):[...a]}f(at,"splitTextToChars");function ct(a,e){let t=at(e.content);return Re(a,[],t,e.type)}f(ct,"splitWordToFitWidth");function Re(a,e,t,s){if(t.length===0)return[{content:e.join(""),type:s},{content:"",type:s}];let[n,...r]=t,i=[...e,n];return a([{content:i.join(""),type:s}])?Re(a,i,r,s):(e.length===0&&n&&(e.push(n),t.shift()),[{content:e.join(""),type:s},{content:t.join(""),type:s}])}f(Re,"splitWordToFitWidthRecursion");function ze(a,e){if(a.some(({content:t})=>t.includes(` +`)))throw new Error("splitLineToFitWidth does not support newlines in the line");return X(a,e)}f(ze,"splitLineToFitWidth");function X(a,e,t=[],s=[]){if(a.length===0)return s.length>0&&t.push(s),t.length>0?t:[];let n="";a[0].content===" "&&(n=" ",a.shift());let r=a.shift()??{content:" ",type:"normal"},i=[...s];if(n!==""&&i.push({content:n,type:"normal"}),i.push(r),e(i))return X(a,e,t,i);if(s.length>0)t.push(s),a.unshift(r);else if(r.content){let[l,o]=ct(e,r);t.push([l]),o.content&&a.unshift(o)}return X(a,e,t)}f(X,"splitLineToFitWidthRecursion");function Se(a,e){e&&a.attr("style",e)}f(Se,"applyStyle");async function pt(a,e,t,s,n=!1){let r=a.append("foreignObject");r.attr("width",`${10*t}px`),r.attr("height",`${10*t}px`);let i=r.append("xhtml:div"),l=e.label;e.label&&P(e.label)&&(l=await ne(e.label.replace(se.lineBreakRegex,` +`),re()));let o=e.isNode?"nodeLabel":"edgeLabel",p=i.append("span");p.html(l),Se(p,e.labelStyle),p.attr("class",`${o} ${s}`),Se(i,e.labelStyle),i.style("display","table-cell"),i.style("white-space","nowrap"),i.style("line-height","1.5"),i.style("max-width",t+"px"),i.style("text-align","center"),i.attr("xmlns","http://www.w3.org/1999/xhtml"),n&&i.attr("class","labelBkg");let c=i.node().getBoundingClientRect();return c.width===t&&(i.style("display","table"),i.style("white-space","break-spaces"),i.style("width",t+"px"),c=i.node().getBoundingClientRect()),r.node()}f(pt,"addHtmlSpan");function K(a,e,t){return a.append("tspan").attr("class","text-outer-tspan").attr("x",0).attr("y",e*t-.1+"em").attr("dy",t+"em")}f(K,"createTspan");function ht(a,e,t){let s=a.append("text"),n=K(s,1,e);V(n,t);let r=n.node().getComputedTextLength();return s.remove(),r}f(ht,"computeWidthOfText");function qt(a,e,t){let s=a.append("text"),n=K(s,1,e);V(n,[{content:t,type:"normal"}]);let r=n.node()?.getBoundingClientRect();return r&&s.remove(),r}f(qt,"computeDimensionOfText");function ut(a,e,t,s=!1){let r=e.append("g"),i=r.insert("rect").attr("class","background").attr("style","stroke: none"),l=r.append("text").attr("y","-10.1"),o=0;for(let p of t){let c=f(u=>ht(r,1.1,u)<=a,"checkWidth"),h=c(p)?[p]:ze(p,c);for(let u of h){let g=K(l,o,1.1);V(g,u),o++}}if(s){let p=l.node().getBBox(),c=2;return i.attr("x",p.x-c).attr("y",p.y-c).attr("width",p.width+2*c).attr("height",p.height+2*c),r.node()}else return l.node()}f(ut,"createFormattedText");function V(a,e){a.text(""),e.forEach((t,s)=>{let n=a.append("tspan").attr("font-style",t.type==="em"?"italic":"normal").attr("class","text-inner-tspan").attr("font-weight",t.type==="strong"?"bold":"normal");s===0?n.text(t.content):n.text(" "+t.content)})}f(V,"updateTextContentAndStyles");function ft(a){return a.replace(/fa[bklrs]?:fa-[\w-]+/g,e=>``)}f(ft,"replaceIconSubstring");var Zt=f(async(a,e="",{style:t="",isTitle:s=!1,classes:n="",useHtmlLabels:r=!0,isNode:i=!0,width:l=200,addSvgBackground:o=!1}={},p)=>{if(te.debug("XYZ createText",e,t,s,n,r,i,"addSvgBackground: ",o),r){let c=$e(e,p),h=ft(ie(c)),u=e.replace(/\\\\/g,"\\"),g={isNode:i,label:P(e)?u:h,labelStyle:t.replace("fill:","color:")};return await pt(a,g,l,n,o)}else{let c=e.replace(//g,"
    "),h=Te(c.replace("
    ","
    "),p),u=ut(l,a,h,e?o:!1);if(i){/stroke:/.exec(t)&&(t=t.replace("stroke:","lineColor:"));let g=t.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");v(u).attr("style",g)}else{let g=t.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/background:/g,"fill:");v(u).select("rect").attr("style",g.replace(/background:/g,"fill:"));let d=t.replace(/stroke:[^;]+;?/g,"").replace(/stroke-width:[^;]+;?/g,"").replace(/fill:[^;]+;?/g,"").replace(/color:/g,"fill:");v(u).select("text").attr("style",d)}return u}},"createText");export{le as a,qt as b,ft as c,Zt as d}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-D4BOYBYT.mjs b/static/js/chunks/mermaid.esm.min/chunk-D4BOYBYT.mjs new file mode 100644 index 0000000..b15e4c8 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-D4BOYBYT.mjs @@ -0,0 +1 @@ +import{b as j}from"./chunk-OR2G2HG5.mjs";import{a as i,b as P,e as ie}from"./chunk-GTKDMUJJ.mjs";var X=P((at,Q)=>{"use strict";var b=1e3,v=b*60,E=v*60,y=E*24,he=y*7,Ce=y*365.25;Q.exports=function(e,o){o=o||{};var t=typeof e;if(t==="string"&&e.length>0)return xe(e);if(t==="number"&&isFinite(e))return o.long?we(e):Ie(e);throw new Error("val is not a non-empty string or a valid number. val="+JSON.stringify(e))};function xe(e){if(e=String(e),!(e.length>100)){var o=/^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(e);if(o){var t=parseFloat(o[1]),n=(o[2]||"ms").toLowerCase();switch(n){case"years":case"year":case"yrs":case"yr":case"y":return t*Ce;case"weeks":case"week":case"w":return t*he;case"days":case"day":case"d":return t*y;case"hours":case"hour":case"hrs":case"hr":case"h":return t*E;case"minutes":case"minute":case"mins":case"min":case"m":return t*v;case"seconds":case"second":case"secs":case"sec":case"s":return t*b;case"milliseconds":case"millisecond":case"msecs":case"msec":case"ms":return t;default:return}}}}i(xe,"parse");function Ie(e){var o=Math.abs(e);return o>=y?Math.round(e/y)+"d":o>=E?Math.round(e/E)+"h":o>=v?Math.round(e/v)+"m":o>=b?Math.round(e/b)+"s":e+"ms"}i(Ie,"fmtShort");function we(e){var o=Math.abs(e);return o>=y?D(e,o,y,"day"):o>=E?D(e,o,E,"hour"):o>=v?D(e,o,v,"minute"):o>=b?D(e,o,b,"second"):e+" ms"}i(we,"fmtLong");function D(e,o,t,n){var r=o>=t*1.5;return Math.round(e/t)+" "+n+(r?"s":"")}i(D,"plural")});var ee=P((lt,Y)=>{"use strict";function Fe(e){t.debug=t,t.default=t,t.coerce=h,t.disable=c,t.enable=r,t.enabled=f,t.humanize=X(),t.destroy=C,Object.keys(e).forEach(s=>{t[s]=e[s]}),t.names=[],t.skips=[],t.formatters={};function o(s){let a=0;for(let p=0;p{if(M==="%%")return"%";d++;let H=t.formatters[re];if(typeof H=="function"){let ne=u[d];M=H.call(I,ne),u.splice(d,1),d--}return M}),t.formatArgs.call(I,u),(I.log||t.log).apply(I,u)}return i(m,"debug"),m.namespace=s,m.useColors=t.useColors(),m.color=t.selectColor(s),m.extend=n,m.destroy=t.destroy,Object.defineProperty(m,"enabled",{enumerable:!0,configurable:!1,get:i(()=>p!==null?p:(w!==t.namespaces&&(w=t.namespaces,T=t.enabled(s)),T),"get"),set:i(u=>{p=u},"set")}),typeof t.init=="function"&&t.init(m),m}i(t,"createDebug");function n(s,a){let p=t(this.namespace+(typeof a>"u"?":":a)+s);return p.log=this.log,p}i(n,"extend");function r(s){t.save(s),t.namespaces=s,t.names=[],t.skips=[];let a,p=(typeof s=="string"?s:"").split(/[\s,]+/),w=p.length;for(a=0;a"-"+a)].join(",");return t.enable(""),s}i(c,"disable");function f(s){if(s[s.length-1]==="*")return!0;let a,p;for(a=0,p=t.skips.length;a{"use strict";g.formatArgs=Se;g.save=be;g.load=ve;g.useColors=ye;g.storage=Ee();g.destroy=(()=>{let e=!1;return()=>{e||(e=!0,console.warn("Instance method `debug.destroy()` is deprecated and no longer does anything. It will be removed in the next major version of `debug`."))}})();g.colors=["#0000CC","#0000FF","#0033CC","#0033FF","#0066CC","#0066FF","#0099CC","#0099FF","#00CC00","#00CC33","#00CC66","#00CC99","#00CCCC","#00CCFF","#3300CC","#3300FF","#3333CC","#3333FF","#3366CC","#3366FF","#3399CC","#3399FF","#33CC00","#33CC33","#33CC66","#33CC99","#33CCCC","#33CCFF","#6600CC","#6600FF","#6633CC","#6633FF","#66CC00","#66CC33","#9900CC","#9900FF","#9933CC","#9933FF","#99CC00","#99CC33","#CC0000","#CC0033","#CC0066","#CC0099","#CC00CC","#CC00FF","#CC3300","#CC3333","#CC3366","#CC3399","#CC33CC","#CC33FF","#CC6600","#CC6633","#CC9900","#CC9933","#CCCC00","#CCCC33","#FF0000","#FF0033","#FF0066","#FF0099","#FF00CC","#FF00FF","#FF3300","#FF3333","#FF3366","#FF3399","#FF33CC","#FF33FF","#FF6600","#FF6633","#FF9900","#FF9933","#FFCC00","#FFCC33"];function ye(){if(typeof window<"u"&&window.process&&(window.process.type==="renderer"||window.process.__nwjs))return!0;if(typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/(edge|trident)\/(\d+)/))return!1;let e;return typeof document<"u"&&document.documentElement&&document.documentElement.style&&document.documentElement.style.WebkitAppearance||typeof window<"u"&&window.console&&(window.console.firebug||window.console.exception&&window.console.table)||typeof navigator<"u"&&navigator.userAgent&&(e=navigator.userAgent.toLowerCase().match(/firefox\/(\d+)/))&&parseInt(e[1],10)>=31||typeof navigator<"u"&&navigator.userAgent&&navigator.userAgent.toLowerCase().match(/applewebkit\/(\d+)/)}i(ye,"useColors");function Se(e){if(e[0]=(this.useColors?"%c":"")+this.namespace+(this.useColors?" %c":" ")+e[0]+(this.useColors?"%c ":" ")+"+"+A.exports.humanize(this.diff),!this.useColors)return;let o="color: "+this.color;e.splice(1,0,o,"color: inherit");let t=0,n=0;e[0].replace(/%[a-zA-Z%]/g,r=>{r!=="%%"&&(t++,r==="%c"&&(n=t))}),e.splice(n,0,o)}i(Se,"formatArgs");g.log=console.debug||console.log||(()=>{});function be(e){try{e?g.storage.setItem("debug",e):g.storage.removeItem("debug")}catch{}}i(be,"save");function ve(){let e;try{e=g.storage.getItem("debug")}catch{}return!e&&typeof process<"u"&&"env"in process&&(e=process.env.DEBUG),e}i(ve,"load");function Ee(){try{return localStorage}catch{}}i(Ee,"localstorage");A.exports=ee()(g);var{formatters:Te}=A.exports;Te.j=function(e){try{return JSON.stringify(e)}catch(o){return"[UnexpectedJSONParseError]: "+o.message}}});var se=Object.freeze({left:0,top:0,width:16,height:16}),S=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),L=Object.freeze({...se,...S}),J=Object.freeze({...L,body:"",hidden:!1});var ce=Object.freeze({width:null,height:null}),B=Object.freeze({...ce,...S});var O=/^[a-z0-9]+(-[a-z0-9]+)*$/,V=i((e,o,t,n="")=>{let r=e.split(":");if(e.slice(0,1)==="@"){if(r.length<2||r.length>3)return null;n=r.shift().slice(1)}if(r.length>3||!r.length)return null;if(r.length>1){let l=r.pop(),h=r.pop(),C={provider:r.length>0?r[0]:n,prefix:h,name:l};return o&&!k(C)?null:C}let c=r[0],f=c.split("-");if(f.length>1){let l={provider:n,prefix:f.shift(),name:f.join("-")};return o&&!k(l)?null:l}if(t&&n===""){let l={provider:n,prefix:"",name:c};return o&&!k(l,t)?null:l}return null},"stringToIcon"),k=i((e,o)=>e?!!((e.provider===""||e.provider.match(O))&&(o&&e.prefix===""||e.prefix.match(O))&&e.name.match(O)):!1,"validateIconName");function K(e,o){let t={};!e.hFlip!=!o.hFlip&&(t.hFlip=!0),!e.vFlip!=!o.vFlip&&(t.vFlip=!0);let n=((e.rotate||0)+(o.rotate||0))%4;return n&&(t.rotate=n),t}i(K,"mergeIconTransformations");function G(e,o){let t=K(e,o);for(let n in J)n in S?n in e&&!(n in t)&&(t[n]=S[n]):n in o?t[n]=o[n]:n in e&&(t[n]=e[n]);return t}i(G,"mergeIconData");function W(e,o){let t=e.icons,n=e.aliases||Object.create(null),r=Object.create(null);function c(f){if(t[f])return r[f]=[];if(!(f in r)){r[f]=null;let l=n[f]&&n[f].parent,h=l&&c(l);h&&(r[f]=[l].concat(h))}return r[f]}return i(c,"resolve"),(o||Object.keys(t).concat(Object.keys(n))).forEach(c),r}i(W,"getIconsTree");function Z(e,o,t){let n=e.icons,r=e.aliases||Object.create(null),c={};function f(l){c=G(n[l]||r[l],c)}return i(f,"parse"),f(o),t.forEach(f),G(e,c)}i(Z,"internalGetIconData");function z(e,o){if(e.icons[o])return Z(e,o,[]);let t=W(e,[o])[o];return t?Z(e,o,t):null}i(z,"getIconData");var ae=/(-?[0-9.]*[0-9]+[0-9.]*)/g,fe=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function N(e,o,t){if(o===1)return e;if(t=t||100,typeof e=="number")return Math.ceil(e*o*t)/t;if(typeof e!="string")return e;let n=e.split(ae);if(n===null||!n.length)return e;let r=[],c=n.shift(),f=fe.test(c);for(;;){if(f){let l=parseFloat(c);isNaN(l)?r.push(c):r.push(Math.ceil(l*o*t)/t)}else r.push(c);if(c=n.shift(),c===void 0)return r.join("");f=!f}}i(N,"calculateSize");function le(e,o="defs"){let t="",n=e.indexOf("<"+o);for(;n>=0;){let r=e.indexOf(">",n),c=e.indexOf("",c);if(f===-1)break;t+=e.slice(r+1,c).trim(),e=e.slice(0,n).trim()+e.slice(f+1)}return{defs:t,content:e}}i(le,"splitSVGDefs");function ue(e,o){return e?""+e+""+o:o}i(ue,"mergeDefsAndContent");function _(e,o,t){let n=le(e);return ue(n.defs,o+n.content+t)}i(_,"wrapSVGContent");var pe=i(e=>e==="unset"||e==="undefined"||e==="none","isUnsetKeyword");function $(e,o){let t={...L,...e},n={...B,...o},r={left:t.left,top:t.top,width:t.width,height:t.height},c=t.body;[t,n].forEach(m=>{let u=[],I=m.hFlip,F=m.vFlip,x=m.rotate;I?F?x+=2:(u.push("translate("+(r.width+r.left).toString()+" "+(0-r.top).toString()+")"),u.push("scale(-1 1)"),r.top=r.left=0):F&&(u.push("translate("+(0-r.left).toString()+" "+(r.height+r.top).toString()+")"),u.push("scale(1 -1)"),r.top=r.left=0);let d;switch(x<0&&(x-=Math.floor(x/4)*4),x=x%4,x){case 1:d=r.height/2+r.top,u.unshift("rotate(90 "+d.toString()+" "+d.toString()+")");break;case 2:u.unshift("rotate(180 "+(r.width/2+r.left).toString()+" "+(r.height/2+r.top).toString()+")");break;case 3:d=r.width/2+r.left,u.unshift("rotate(-90 "+d.toString()+" "+d.toString()+")");break}x%2===1&&(r.left!==r.top&&(d=r.left,r.left=r.top,r.top=d),r.width!==r.height&&(d=r.width,r.width=r.height,r.height=d)),u.length&&(c=_(c,'',""))});let f=n.width,l=n.height,h=r.width,C=r.height,s,a;f===null?(a=l===null?"1em":l==="auto"?C:l,s=N(a,h/C)):(s=f==="auto"?h:f,a=l===null?N(s,C/h):l==="auto"?C:l);let p={},w=i((m,u)=>{pe(u)||(p[m]=u.toString())},"setAttr");w("width",s),w("height",a);let T=[r.left,r.top,h,C];return p.viewBox=T.join(" "),{attributes:p,viewBox:T,body:c}}i($,"iconToSVG");var me=/\sid="(\S+)"/g,de="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16),ge=0;function U(e,o=de){let t=[],n;for(;n=me.exec(e);)t.push(n[1]);if(!t.length)return e;let r="suffix"+(Math.random()*16777216|Date.now()).toString(16);return t.forEach(c=>{let f=typeof o=="function"?o(c):o+(ge++).toString(),l=c.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+l+')([")]|\\.[a-z])',"g"),"$1"+f+r+"$3")}),e=e.replace(new RegExp(r,"g"),""),e}i(U,"replaceIDs");function q(e,o){let t=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(let n in o)t+=" "+n+'="'+o[n]+'"';return'"+e+""}i(q,"iconToHTML");var mt=ie(te(),1);var je={body:'?',height:80,width:80},R=new Map,oe=new Map,yt=i(e=>{for(let o of e){if(!o.name)throw new Error('Invalid icon loader. Must have a "name" property with non-empty string value.');if(j.debug("Registering icon pack:",o.name),"loader"in o)oe.set(o.name,o.loader);else if("icons"in o)R.set(o.name,o.icons);else throw j.error("Invalid icon loader:",o),new Error('Invalid icon loader. Must have either "icons" or "loader" property.')}},"registerIconPacks"),Oe=i(async(e,o)=>{let t=V(e,!0,o!==void 0);if(!t)throw new Error(`Invalid icon name: ${e}`);let n=t.prefix||o;if(!n)throw new Error(`Icon name must contain a prefix: ${e}`);let r=R.get(n);if(!r){let f=oe.get(n);if(!f)throw new Error(`Icon set not found: ${t.prefix}`);try{r={...await f(),prefix:n},R.set(n,r)}catch(l){throw j.error(l),new Error(`Failed to load icon set: ${t.prefix}`)}}let c=z(r,t.name);if(!c)throw new Error(`Icon not found: ${e}`);return c},"getRegisteredIconData");var St=i(async(e,o)=>{let t;try{t=await Oe(e,o?.fallbackPrefix)}catch(c){j.error(c),t=je}let n=$(t,o);return q(U(n.body),n.attributes)},"getIconSVG");export{je as a,yt as b,St as c}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-E7A2AWYO.mjs b/static/js/chunks/mermaid.esm.min/chunk-E7A2AWYO.mjs new file mode 100644 index 0000000..3136979 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-E7A2AWYO.mjs @@ -0,0 +1,15 @@ +import{a as Lt}from"./chunk-LM6QDVU5.mjs";import{c as at}from"./chunk-D4BOYBYT.mjs";import{d as it}from"./chunk-AFC6EC46.mjs";import{i as ne,k as le,o as pt,q as X}from"./chunk-UENA7NWE.mjs";import{A as wt,F as Ot,G as Y,I as Nt,K as oe,L as ae,X as q,_ as ie,b as z,ga as Z,s as re}from"./chunk-OR2G2HG5.mjs";import{a as u}from"./chunk-GTKDMUJJ.mjs";var T=u(async(n,t,o)=>{let r,s=t.useHtmlLabels||Y(q()?.htmlLabels);o?r=o:r="node default";let a=n.insert("g").attr("class",r).attr("id",t.domId||t.id),c=a.insert("g").attr("class","label").attr("style",X(t.labelStyle)),e;t.label===void 0?e="":e=typeof t.label=="string"?t.label:t.label[0];let h=await it(c,Ot(pt(e),q()),{useHtmlLabels:s,width:t.width||q().flowchart?.wrappingWidth,cssClasses:"markdown-node-label",style:t.labelStyle,addSvgBackground:!!t.icon||!!t.img}),i=h.getBBox(),l=(t?.padding??0)/2;if(s){let p=h.children[0],f=Z(h),m=p.getElementsByTagName("img");if(m){let g=e.replace(/]*>/g,"").trim()==="";await Promise.all([...m].map(d=>new Promise(x=>{function y(){if(d.style.display="flex",d.style.flexDirection="column",g){let b=q().fontSize?q().fontSize:window.getComputedStyle(document.body).fontSize,S=5,[$=re.fontSize]=le(b),w=$*S+"px";d.style.minWidth=w,d.style.maxWidth=w}else d.style.width="100%";x(d)}u(y,"setupImage"),setTimeout(()=>{d.complete&&y()}),d.addEventListener("error",y),d.addEventListener("load",y)})))}i=p.getBoundingClientRect(),f.attr("width",i.width),f.attr("height",i.height)}return s?c.attr("transform","translate("+-i.width/2+", "+-i.height/2+")"):c.attr("transform","translate(0, "+-i.height/2+")"),t.centerLabel&&c.attr("transform","translate("+-i.width/2+", "+-i.height/2+")"),c.insert("rect",":first-child"),{shapeSvg:a,bbox:i,halfPadding:l,label:c}},"labelHelper"),Dt=u(async(n,t,o)=>{let r=o.useHtmlLabels||Y(q()?.flowchart?.htmlLabels),s=n.insert("g").attr("class","label").attr("style",o.labelStyle||""),a=await it(s,Ot(pt(t),q()),{useHtmlLabels:r,width:o.width||q()?.flowchart?.wrappingWidth,style:o.labelStyle,addSvgBackground:!!o.icon||!!o.img}),c=a.getBBox(),e=o.padding/2;if(Y(q()?.flowchart?.htmlLabels)){let h=a.children[0],i=Z(a);c=h.getBoundingClientRect(),i.attr("width",c.width),i.attr("height",c.height)}return r?s.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"):s.attr("transform","translate(0, "+-c.height/2+")"),o.centerLabel&&s.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),s.insert("rect",":first-child"),{shapeSvg:n,bbox:c,halfPadding:e,label:s}},"insertLabel"),v=u((n,t)=>{let o=t.node().getBBox();n.width=o.width,n.height=o.height},"updateNodeBounds");var P=u((n,t)=>(n.look==="handDrawn"?"rough-node":"node")+" "+n.cssClasses+" "+(t||""),"getNodeClasses");function H(n){let t=n.map((o,r)=>`${r===0?"M":"L"}${o.x},${o.y}`);return t.push("Z"),t.join(" ")}u(H,"createPathFromPoints");function st(n,t,o,r,s,a){let c=[],h=o-n,i=r-t,l=h/a,p=2*Math.PI/l,f=t+i/2;for(let m=0;m<=50;m++){let g=m/50,d=n+g*h,x=f+s*Math.sin(p*(d-n));c.push({x:d,y:x})}return c}u(st,"generateFullSineWavePoints");function Mt(n,t,o,r,s,a){let c=[],e=s*Math.PI/180,l=(a*Math.PI/180-e)/(r-1);for(let p=0;p2&&f.push(S)}let m=[];l=Math.max(l,.1);let g=[];for(let b of f)for(let S=0;Sb.yminS.ymin?1:b.xS.x?1:b.ymax===S.ymax?0:(b.ymax-S.ymax)/Math.abs(b.ymax-S.ymax)),!g.length)return m;let d=[],x=g[0].ymin,y=0;for(;d.length||g.length;){if(g.length){let b=-1;for(let S=0;Sx);S++)b=S;g.splice(0,b+1).forEach(S=>{d.push({s:x,edge:S})})}if(d=d.filter(b=>!(b.edge.ymax<=x)),d.sort((b,S)=>b.edge.x===S.edge.x?0:(b.edge.x-S.edge.x)/Math.abs(b.edge.x-S.edge.x)),(p!==1||y%l==0)&&d.length>1)for(let b=0;b=d.length)break;let $=d[b].edge,w=d[S].edge;m.push([[Math.round($.x),x],[Math.round(w.x),x]])}x+=p,d.forEach(b=>{b.edge.x=b.edge.x+p*b.edge.islope}),y++}return m}(c,a,r);if(s){for(let i of c)Ht(i,e,-s);(function(i,l,p){let f=[];i.forEach(m=>f.push(...m)),Ht(f,l,p)})(h,e,-s)}return h}u(Ls,"s");function bt(n,t){var o;let r=t.hachureAngle+90,s=t.hachureGap;s<0&&(s=4*t.strokeWidth),s=Math.round(Math.max(s,.1));let a=1;return t.roughness>=1&&(((o=t.randomizer)===null||o===void 0?void 0:o.next())||Math.random())>.7&&(a=s),Ls(n,s,r,a||1)}u(bt,"n");var xt=class{static{u(this,"o")}constructor(t){this.helper=t}fillPolygons(t,o){return this._fillPolygons(t,o)}_fillPolygons(t,o){let r=bt(t,o);return{type:"fillSketch",ops:this.renderLines(r,o)}}renderLines(t,o){let r=[];for(let s of t)r.push(...this.helper.doubleLineOps(s[0][0],s[0][1],s[1][0],s[1][1],o));return r}};function Gt(n){let t=n[0],o=n[1];return Math.sqrt(Math.pow(t[0]-o[0],2)+Math.pow(t[1]-o[1],2))}u(Gt,"a");var _t=class extends xt{static{u(this,"h")}fillPolygons(t,o){let r=o.hachureGap;r<0&&(r=4*o.strokeWidth),r=Math.max(r,.1);let s=bt(t,Object.assign({},o,{hachureGap:r})),a=Math.PI/180*o.hachureAngle,c=[],e=.5*r*Math.cos(a),h=.5*r*Math.sin(a);for(let[i,l]of s)Gt([i,l])&&c.push([[i[0]-e,i[1]+h],[...l]],[[i[0]+e,i[1]-h],[...l]]);return{type:"fillSketch",ops:this.renderLines(c,o)}}},zt=class extends xt{static{u(this,"r")}fillPolygons(t,o){let r=this._fillPolygons(t,o),s=Object.assign({},o,{hachureAngle:o.hachureAngle+90}),a=this._fillPolygons(t,s);return r.ops=r.ops.concat(a.ops),r}},qt=class{static{u(this,"i")}constructor(t){this.helper=t}fillPolygons(t,o){let r=bt(t,o=Object.assign({},o,{hachureAngle:0}));return this.dotsOnLines(r,o)}dotsOnLines(t,o){let r=[],s=o.hachureGap;s<0&&(s=4*o.strokeWidth),s=Math.max(s,.1);let a=o.fillWeight;a<0&&(a=o.strokeWidth/2);let c=s/4;for(let e of t){let h=Gt(e),i=h/s,l=Math.ceil(i)-1,p=h-l*s,f=(e[0][0]+e[1][0])/2-s/4,m=Math.min(e[0][1],e[1][1]);for(let g=0;g{let e=Gt(c),h=Math.floor(e/(r+s)),i=(e+s-h*(r+s))/2,l=c[0],p=c[1];l[0]>p[0]&&(l=c[1],p=c[0]);let f=Math.atan((p[1]-l[1])/(p[0]-l[0]));for(let m=0;m{let c=Gt(a),e=Math.round(c/(2*o)),h=a[0],i=a[1];h[0]>i[0]&&(h=a[1],i=a[0]);let l=Math.atan((i[1]-h[1])/(i[0]-h[0]));for(let p=0;pl%2?i+o:i+t);a.push({key:"C",data:h}),t=h[4],o=h[5];break}case"Q":a.push({key:"Q",data:[...e]}),t=e[2],o=e[3];break;case"q":{let h=e.map((i,l)=>l%2?i+o:i+t);a.push({key:"Q",data:h}),t=h[2],o=h[3];break}case"A":a.push({key:"A",data:[...e]}),t=e[5],o=e[6];break;case"a":t+=e[5],o+=e[6],a.push({key:"A",data:[e[0],e[1],e[2],e[3],e[4],t,o]});break;case"H":a.push({key:"H",data:[...e]}),t=e[0];break;case"h":t+=e[0],a.push({key:"H",data:[t]});break;case"V":a.push({key:"V",data:[...e]}),o=e[0];break;case"v":o+=e[0],a.push({key:"V",data:[o]});break;case"S":a.push({key:"S",data:[...e]}),t=e[2],o=e[3];break;case"s":{let h=e.map((i,l)=>l%2?i+o:i+t);a.push({key:"S",data:h}),t=h[2],o=h[3];break}case"T":a.push({key:"T",data:[...e]}),t=e[0],o=e[1];break;case"t":t+=e[0],o+=e[1],a.push({key:"T",data:[t,o]});break;case"Z":case"z":a.push({key:"Z",data:[]}),t=r,o=s}return a}u(ye,"y");function xe(n){let t=[],o="",r=0,s=0,a=0,c=0,e=0,h=0;for(let{key:i,data:l}of n){switch(i){case"M":t.push({key:"M",data:[...l]}),[r,s]=l,[a,c]=l;break;case"C":t.push({key:"C",data:[...l]}),r=l[4],s=l[5],e=l[2],h=l[3];break;case"L":t.push({key:"L",data:[...l]}),[r,s]=l;break;case"H":r=l[0],t.push({key:"L",data:[r,s]});break;case"V":s=l[0],t.push({key:"L",data:[r,s]});break;case"S":{let p=0,f=0;o==="C"||o==="S"?(p=r+(r-e),f=s+(s-h)):(p=r,f=s),t.push({key:"C",data:[p,f,...l]}),e=l[0],h=l[1],r=l[2],s=l[3];break}case"T":{let[p,f]=l,m=0,g=0;o==="Q"||o==="T"?(m=r+(r-e),g=s+(s-h)):(m=r,g=s);let d=r+2*(m-r)/3,x=s+2*(g-s)/3,y=p+2*(m-p)/3,b=f+2*(g-f)/3;t.push({key:"C",data:[d,x,y,b,p,f]}),e=m,h=g,r=p,s=f;break}case"Q":{let[p,f,m,g]=l,d=r+2*(p-r)/3,x=s+2*(f-s)/3,y=m+2*(p-m)/3,b=g+2*(f-g)/3;t.push({key:"C",data:[d,x,y,b,m,g]}),e=p,h=f,r=m,s=g;break}case"A":{let p=Math.abs(l[0]),f=Math.abs(l[1]),m=l[2],g=l[3],d=l[4],x=l[5],y=l[6];p===0||f===0?(t.push({key:"C",data:[r,s,x,y,x,y]}),r=x,s=y):(r!==x||s!==y)&&(be(r,s,x,y,p,f,m,g,d).forEach(function(b){t.push({key:"C",data:b})}),r=x,s=y);break}case"Z":t.push({key:"Z",data:[]}),r=a,s=c}o=i}return t}u(xe,"m");function ut(n,t,o){return[n*Math.cos(o)-t*Math.sin(o),n*Math.sin(o)+t*Math.cos(o)]}u(ut,"w");function be(n,t,o,r,s,a,c,e,h,i){let l=(p=c,Math.PI*p/180);var p;let f=[],m=0,g=0,d=0,x=0;if(i)[m,g,d,x]=i;else{[n,t]=ut(n,t,-l),[o,r]=ut(o,r,-l);let G=(n-o)/2,L=(t-r)/2,V=G*G/(s*s)+L*L/(a*a);V>1&&(V=Math.sqrt(V),s*=V,a*=V);let E=s*s,I=a*a,_=E*I-E*L*L-I*G*G,U=E*L*L+I*G*G,rt=(e===h?-1:1)*Math.sqrt(Math.abs(_/U));d=rt*s*L/a+(n+o)/2,x=rt*-a*G/s+(t+r)/2,m=Math.asin(parseFloat(((t-x)/a).toFixed(9))),g=Math.asin(parseFloat(((r-x)/a).toFixed(9))),ng&&(m-=2*Math.PI),!h&&g>m&&(g-=2*Math.PI)}let y=g-m;if(Math.abs(y)>120*Math.PI/180){let G=g,L=o,V=r;g=h&&g>m?m+120*Math.PI/180*1:m+120*Math.PI/180*-1,f=be(o=d+s*Math.cos(g),r=x+a*Math.sin(g),L,V,s,a,c,0,h,[g,G,d,x])}y=g-m;let b=Math.cos(m),S=Math.sin(m),$=Math.cos(g),w=Math.sin(g),C=Math.tan(y/4),B=4/3*s*C,R=4/3*a*C,j=[n,t],A=[n+B*S,t-R*b],O=[o+B*w,r-R*$],W=[o,r];if(A[0]=2*j[0]-A[0],A[1]=2*j[1]-A[1],i)return[A,O,W].concat(f);{f=[A,O,W].concat(f);let G=[];for(let L=0;L2){let s=[];for(let a=0;a2*Math.PI&&(m=0,g=2*Math.PI);let d=2*Math.PI/h.curveStepCount,x=Math.min(d/2,(g-m)/2),y=de(x,i,l,p,f,m,g,1,h);if(!h.disableMultiStroke){let b=de(x,i,l,p,f,m,g,1.5,h);y.push(...b)}return c&&(e?y.push(...nt(i,l,i+p*Math.cos(m),l+f*Math.sin(m),h),...nt(i,l,i+p*Math.cos(g),l+f*Math.sin(g),h)):y.push({op:"lineTo",data:[i,l]},{op:"lineTo",data:[i+p*Math.cos(m),l+f*Math.sin(m)]})),{type:"path",ops:y}}u(pe,"A");function me(n,t){let o=xe(ye(ee(n))),r=[],s=[0,0],a=[0,0];for(let{key:c,data:e}of o)switch(c){case"M":a=[e[0],e[1]],s=[e[0],e[1]];break;case"L":r.push(...nt(a[0],a[1],e[0],e[1],t)),a=[e[0],e[1]];break;case"C":{let[h,i,l,p,f,m]=e;r.push(...Is(h,i,l,p,f,m,a,t)),a=[f,m];break}case"Z":r.push(...nt(a[0],a[1],s[0],s[1],t)),a=[s[0],s[1]]}return{type:"path",ops:r}}u(me,"_");function It(n,t){let o=[];for(let r of n)if(r.length){let s=t.maxRandomnessOffset||0,a=r.length;if(a>2){o.push({op:"move",data:[r[0][0]+F(s,t),r[0][1]+F(s,t)]});for(let c=1;c500?.4:-.0016668*h+1.233334;let l=s.maxRandomnessOffset||0;l*l*100>e&&(l=h/10);let p=l/2,f=.2+.2*Ne(s),m=s.bowing*s.maxRandomnessOffset*(r-t)/200,g=s.bowing*s.maxRandomnessOffset*(n-o)/200;m=F(m,s,i),g=F(g,s,i);let d=[],x=u(()=>F(p,s,i),"M"),y=u(()=>F(l,s,i),"k"),b=s.preserveVertices;return a&&(c?d.push({op:"move",data:[n+(b?0:x()),t+(b?0:x())]}):d.push({op:"move",data:[n+(b?0:F(l,s,i)),t+(b?0:F(l,s,i))]})),c?d.push({op:"bcurveTo",data:[m+n+(o-n)*f+x(),g+t+(r-t)*f+x(),m+n+2*(o-n)*f+x(),g+t+2*(r-t)*f+x(),o+(b?0:x()),r+(b?0:x())]}):d.push({op:"bcurveTo",data:[m+n+(o-n)*f+y(),g+t+(r-t)*f+y(),m+n+2*(o-n)*f+y(),g+t+2*(r-t)*f+y(),o+(b?0:y()),r+(b?0:y())]}),d}u(Qt,"R");function kt(n,t,o){if(!n.length)return[];let r=[];r.push([n[0][0]+F(t,o),n[0][1]+F(t,o)]),r.push([n[0][0]+F(t,o),n[0][1]+F(t,o)]);for(let s=1;s3){let a=[],c=1-o.curveTightness;s.push({op:"move",data:[n[1][0],n[1][1]]});for(let e=1;e+21&&s.push(e)):s.push(e),s.push(n[t+3])}else{let h=n[t+0],i=n[t+1],l=n[t+2],p=n[t+3],f=mt(h,i,.5),m=mt(i,l,.5),g=mt(l,p,.5),d=mt(f,m,.5),x=mt(m,g,.5),y=mt(d,x,.5);Jt([h,f,d,y],0,o,s),Jt([y,x,g,p],0,o,s)}var a,c;return s}u(Jt,"K");function _s(n,t){return Rt(n,0,n.length,t)}u(_s,"U");function Rt(n,t,o,r,s){let a=s||[],c=n[t],e=n[o-1],h=0,i=1;for(let l=t+1;lh&&(h=p,i=l)}return Math.sqrt(h)>r?(Rt(n,t,i+1,r,a),Rt(n,i,o,r,a)):(a.length||a.push(c),a.push(e)),a}u(Rt,"X");function Ft(n,t=.15,o){let r=[],s=(n.length-1)/3;for(let a=0;a0?Rt(r,0,r.length,o):r}u(Ft,"Y");var et="none",dt=class{static{u(this,"et")}constructor(t){this.defaultOptions={maxRandomnessOffset:2,roughness:1,bowing:1,stroke:"#000",strokeWidth:1,curveTightness:0,curveFitting:.95,curveStepCount:9,fillStyle:"hachure",fillWeight:-1,hachureAngle:-41,hachureGap:-1,dashOffset:-1,dashGap:-1,zigzagOffset:-1,seed:0,disableMultiStroke:!1,disableMultiStrokeFill:!1,preserveVertices:!1,fillShapeRoughnessGain:.8},this.config=t||{},this.config.options&&(this.defaultOptions=this._o(this.config.options))}static newSeed(){return Math.floor(Math.random()*2**31)}_o(t){return t?Object.assign({},this.defaultOptions,t):this.defaultOptions}_d(t,o,r){return{shape:t,sets:o||[],options:r||this.defaultOptions}}line(t,o,r,s,a){let c=this._o(a);return this._d("line",[Se(t,o,r,s,c)],c)}rectangle(t,o,r,s,a){let c=this._o(a),e=[],h=Ws(t,o,r,s,c);if(c.fill){let i=[[t,o],[t+r,o],[t+r,o+s],[t,o+s]];c.fillStyle==="solid"?e.push(It([i],c)):e.push(gt([i],c))}return c.stroke!==et&&e.push(h),this._d("rectangle",e,c)}ellipse(t,o,r,s,a){let c=this._o(a),e=[],h=we(r,s,c),i=Ut(t,o,c,h);if(c.fill)if(c.fillStyle==="solid"){let l=Ut(t,o,c,h).opset;l.type="fillPath",e.push(l)}else e.push(gt([i.estimatedPoints],c));return c.stroke!==et&&e.push(i.opset),this._d("ellipse",e,c)}circle(t,o,r,s){let a=this.ellipse(t,o,r,r,s);return a.shape="circle",a}linearPath(t,o){let r=this._o(o);return this._d("linearPath",[Pt(t,!1,r)],r)}arc(t,o,r,s,a,c,e=!1,h){let i=this._o(h),l=[],p=pe(t,o,r,s,a,c,e,!0,i);if(e&&i.fill)if(i.fillStyle==="solid"){let f=Object.assign({},i);f.disableMultiStroke=!0;let m=pe(t,o,r,s,a,c,!0,!1,f);m.type="fillPath",l.push(m)}else l.push(function(f,m,g,d,x,y,b){let S=f,$=m,w=Math.abs(g/2),C=Math.abs(d/2);w+=F(.01*w,b),C+=F(.01*C,b);let B=x,R=y;for(;B<0;)B+=2*Math.PI,R+=2*Math.PI;R-B>2*Math.PI&&(B=0,R=2*Math.PI);let j=(R-B)/b.curveStepCount,A=[];for(let O=B;O<=R;O+=j)A.push([S+w*Math.cos(O),$+C*Math.sin(O)]);return A.push([S+w*Math.cos(R),$+C*Math.sin(R)]),A.push([S,$]),gt([A],b)}(t,o,r,s,a,c,i));return i.stroke!==et&&l.push(p),this._d("arc",l,i)}curve(t,o){let r=this._o(o),s=[],a=he(t,r);if(r.fill&&r.fill!==et)if(r.fillStyle==="solid"){let c=he(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));s.push({type:"fillPath",ops:this._mergedShape(c.ops)})}else{let c=[],e=t;if(e.length){let h=typeof e[0][0]=="number"?[e]:e;for(let i of h)i.length<3?c.push(...i):i.length===3?c.push(...Ft(ue([i[0],i[0],i[1],i[2]]),10,(1+r.roughness)/2)):c.push(...Ft(ue(i),10,(1+r.roughness)/2))}c.length&&s.push(gt([c],r))}return r.stroke!==et&&s.push(a),this._d("curve",s,r)}polygon(t,o){let r=this._o(o),s=[],a=Pt(t,!0,r);return r.fill&&(r.fillStyle==="solid"?s.push(It([t],r)):s.push(gt([t],r))),r.stroke!==et&&s.push(a),this._d("polygon",s,r)}path(t,o){let r=this._o(o),s=[];if(!t)return this._d("path",s,r);t=(t||"").replace(/\n/g," ").replace(/(-\s)/g,"-").replace("/(ss)/g"," ");let a=r.fill&&r.fill!=="transparent"&&r.fill!==et,c=r.stroke!==et,e=!!(r.simplification&&r.simplification<1),h=function(l,p,f){let m=xe(ye(ee(l))),g=[],d=[],x=[0,0],y=[],b=u(()=>{y.length>=4&&d.push(...Ft(y,p)),y=[]},"i"),S=u(()=>{b(),d.length&&(g.push(d),d=[])},"c");for(let{key:w,data:C}of m)switch(w){case"M":S(),x=[C[0],C[1]],d.push(x);break;case"L":b(),d.push([C[0],C[1]]);break;case"C":if(!y.length){let B=d.length?d[d.length-1]:x;y.push([B[0],B[1]])}y.push([C[0],C[1]]),y.push([C[2],C[3]]),y.push([C[4],C[5]]);break;case"Z":b(),d.push([x[0],x[1]])}if(S(),!f)return g;let $=[];for(let w of g){let C=_s(w,f);C.length&&$.push(C)}return $}(t,1,e?4-4*(r.simplification||1):(1+r.roughness)/2),i=me(t,r);if(a)if(r.fillStyle==="solid")if(h.length===1){let l=me(t,Object.assign(Object.assign({},r),{disableMultiStroke:!0,roughness:r.roughness?r.roughness+r.fillShapeRoughnessGain:0}));s.push({type:"fillPath",ops:this._mergedShape(l.ops)})}else s.push(It(h,r));else s.push(gt(h,r));return c&&(e?h.forEach(l=>{s.push(Pt(l,!1,r))}):s.push(i)),this._d("path",s,r)}opsToPath(t,o){let r="";for(let s of t.ops){let a=typeof o=="number"&&o>=0?s.data.map(c=>+c.toFixed(o)):s.data;switch(s.op){case"move":r+=`M${a[0]} ${a[1]} `;break;case"bcurveTo":r+=`C${a[0]} ${a[1]}, ${a[2]} ${a[3]}, ${a[4]} ${a[5]} `;break;case"lineTo":r+=`L${a[0]} ${a[1]} `}}return r.trim()}toPaths(t){let o=t.sets||[],r=t.options||this.defaultOptions,s=[];for(let a of o){let c=null;switch(a.type){case"path":c={d:this.opsToPath(a),stroke:r.stroke,strokeWidth:r.strokeWidth,fill:et};break;case"fillPath":c={d:this.opsToPath(a),stroke:et,strokeWidth:0,fill:r.fill||et};break;case"fillSketch":c=this.fillSketch(a,r)}c&&s.push(c)}return s}fillSketch(t,o){let r=o.fillWeight;return r<0&&(r=o.strokeWidth/2),{d:this.opsToPath(t),stroke:o.fill||et,strokeWidth:r,fill:et}}_mergedShape(t){return t.filter((o,r)=>r===0||o.op!=="move")}},Kt=class{static{u(this,"st")}constructor(t,o){this.canvas=t,this.ctx=this.canvas.getContext("2d"),this.gen=new dt(o)}draw(t){let o=t.sets||[],r=t.options||this.getDefaultOptions(),s=this.ctx,a=t.options.fixedDecimalPlaceDigits;for(let c of o)switch(c.type){case"path":s.save(),s.strokeStyle=r.stroke==="none"?"transparent":r.stroke,s.lineWidth=r.strokeWidth,r.strokeLineDash&&s.setLineDash(r.strokeLineDash),r.strokeLineDashOffset&&(s.lineDashOffset=r.strokeLineDashOffset),this._drawToContext(s,c,a),s.restore();break;case"fillPath":{s.save(),s.fillStyle=r.fill||"";let e=t.shape==="curve"||t.shape==="polygon"||t.shape==="path"?"evenodd":"nonzero";this._drawToContext(s,c,a,e),s.restore();break}case"fillSketch":this.fillSketch(s,c,r)}}fillSketch(t,o,r){let s=r.fillWeight;s<0&&(s=r.strokeWidth/2),t.save(),r.fillLineDash&&t.setLineDash(r.fillLineDash),r.fillLineDashOffset&&(t.lineDashOffset=r.fillLineDashOffset),t.strokeStyle=r.fill||"",t.lineWidth=s,this._drawToContext(t,o,r.fixedDecimalPlaceDigits),t.restore()}_drawToContext(t,o,r,s="nonzero"){t.beginPath();for(let a of o.ops){let c=typeof r=="number"&&r>=0?a.data.map(e=>+e.toFixed(r)):a.data;switch(a.op){case"move":t.moveTo(c[0],c[1]);break;case"bcurveTo":t.bezierCurveTo(c[0],c[1],c[2],c[3],c[4],c[5]);break;case"lineTo":t.lineTo(c[0],c[1])}}o.type==="fillPath"?t.fill(s):t.stroke()}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}line(t,o,r,s,a){let c=this.gen.line(t,o,r,s,a);return this.draw(c),c}rectangle(t,o,r,s,a){let c=this.gen.rectangle(t,o,r,s,a);return this.draw(c),c}ellipse(t,o,r,s,a){let c=this.gen.ellipse(t,o,r,s,a);return this.draw(c),c}circle(t,o,r,s){let a=this.gen.circle(t,o,r,s);return this.draw(a),a}linearPath(t,o){let r=this.gen.linearPath(t,o);return this.draw(r),r}polygon(t,o){let r=this.gen.polygon(t,o);return this.draw(r),r}arc(t,o,r,s,a,c,e=!1,h){let i=this.gen.arc(t,o,r,s,a,c,e,h);return this.draw(i),i}curve(t,o){let r=this.gen.curve(t,o);return this.draw(r),r}path(t,o){let r=this.gen.path(t,o);return this.draw(r),r}},$t="http://www.w3.org/2000/svg",te=class{static{u(this,"ot")}constructor(t,o){this.svg=t,this.gen=new dt(o)}draw(t){let o=t.sets||[],r=t.options||this.getDefaultOptions(),s=this.svg.ownerDocument||window.document,a=s.createElementNS($t,"g"),c=t.options.fixedDecimalPlaceDigits;for(let e of o){let h=null;switch(e.type){case"path":h=s.createElementNS($t,"path"),h.setAttribute("d",this.opsToPath(e,c)),h.setAttribute("stroke",r.stroke),h.setAttribute("stroke-width",r.strokeWidth+""),h.setAttribute("fill","none"),r.strokeLineDash&&h.setAttribute("stroke-dasharray",r.strokeLineDash.join(" ").trim()),r.strokeLineDashOffset&&h.setAttribute("stroke-dashoffset",`${r.strokeLineDashOffset}`);break;case"fillPath":h=s.createElementNS($t,"path"),h.setAttribute("d",this.opsToPath(e,c)),h.setAttribute("stroke","none"),h.setAttribute("stroke-width","0"),h.setAttribute("fill",r.fill||""),t.shape!=="curve"&&t.shape!=="polygon"||h.setAttribute("fill-rule","evenodd");break;case"fillSketch":h=this.fillSketch(s,e,r)}h&&a.appendChild(h)}return a}fillSketch(t,o,r){let s=r.fillWeight;s<0&&(s=r.strokeWidth/2);let a=t.createElementNS($t,"path");return a.setAttribute("d",this.opsToPath(o,r.fixedDecimalPlaceDigits)),a.setAttribute("stroke",r.fill||""),a.setAttribute("stroke-width",s+""),a.setAttribute("fill","none"),r.fillLineDash&&a.setAttribute("stroke-dasharray",r.fillLineDash.join(" ").trim()),r.fillLineDashOffset&&a.setAttribute("stroke-dashoffset",`${r.fillLineDashOffset}`),a}get generator(){return this.gen}getDefaultOptions(){return this.gen.defaultOptions}opsToPath(t,o){return this.gen.opsToPath(t,o)}line(t,o,r,s,a){let c=this.gen.line(t,o,r,s,a);return this.draw(c)}rectangle(t,o,r,s,a){let c=this.gen.rectangle(t,o,r,s,a);return this.draw(c)}ellipse(t,o,r,s,a){let c=this.gen.ellipse(t,o,r,s,a);return this.draw(c)}circle(t,o,r,s){let a=this.gen.circle(t,o,r,s);return this.draw(a)}linearPath(t,o){let r=this.gen.linearPath(t,o);return this.draw(r)}polygon(t,o){let r=this.gen.polygon(t,o);return this.draw(r)}arc(t,o,r,s,a,c,e=!1,h){let i=this.gen.arc(t,o,r,s,a,c,e,h);return this.draw(i)}curve(t,o){let r=this.gen.curve(t,o);return this.draw(r)}path(t,o){let r=this.gen.path(t,o);return this.draw(r)}},D={canvas:u((n,t)=>new Kt(n,t),"canvas"),svg:u((n,t)=>new te(n,t),"svg"),generator:u(n=>new dt(n),"generator"),newSeed:u(()=>dt.newSeed(),"newSeed")};var zs=u((n,t)=>{var o=n.x,r=n.y,s=t.x-o,a=t.y-r,c=n.width/2,e=n.height/2,h,i;return Math.abs(a)*c>Math.abs(s)*e?(a<0&&(e=-e),h=a===0?0:e*s/a,i=e):(s<0&&(c=-c),h=c,i=s===0?0:c*a/s),{x:o+h,y:r+i}},"intersectRect"),lt=zs;function qs(n,t){t&&n.attr("style",t)}u(qs,"applyStyle");async function Xs(n){let t=Z(document.createElementNS("http://www.w3.org/2000/svg","foreignObject")),o=t.append("xhtml:div"),r=n.label;n.label&&Nt(n.label)&&(r=await oe(n.label.replace(ae.lineBreakRegex,` +`),q()));let s=n.isNode?"nodeLabel":"edgeLabel";return o.html('"+r+""),qs(o,n.labelStyle),o.style("display","inline-block"),o.style("padding-right","1px"),o.style("white-space","nowrap"),o.attr("xmlns","http://www.w3.org/1999/xhtml"),t.node()}u(Xs,"addHtmlLabel");var Ys=u(async(n,t,o,r)=>{let s=n||"";if(typeof s=="object"&&(s=s[0]),Y(q().flowchart.htmlLabels)){s=s.replace(/\\n|\n/g,"
    "),z.info("vertexText"+s);let a={isNode:r,label:pt(s).replace(/fa[blrs]?:fa-[\w-]+/g,e=>``),labelStyle:t&&t.replace("fill:","color:")};return await Xs(a)}else{let a=document.createElementNS("http://www.w3.org/2000/svg","text");a.setAttribute("style",t.replace("color:","fill:"));let c=[];typeof s=="string"?c=s.split(/\\n|\n|/gi):Array.isArray(s)?c=s:c=[];for(let e of c){let h=document.createElementNS("http://www.w3.org/2000/svg","tspan");h.setAttributeNS("http://www.w3.org/XML/1998/namespace","xml:space","preserve"),h.setAttribute("dy","1em"),h.setAttribute("x","0"),o?h.setAttribute("class","title-row"):h.setAttribute("class","row"),h.textContent=e.trim(),a.appendChild(h)}return a}},"createLabel"),St=Ys;var Q=u((n,t,o,r,s)=>["M",n+s,t,"H",n+o-s,"A",s,s,0,0,1,n+o,t+s,"V",t+r-s,"A",s,s,0,0,1,n+o-s,t+r,"H",n+s,"A",s,s,0,0,1,n,t+r-s,"V",t+s,"A",s,s,0,0,1,n+s,t,"Z"].join(" "),"createRoundedRectPathD");var De=u(n=>{let{handDrawnSeed:t}=q();return{fill:n,hachureAngle:120,hachureGap:4,fillWeight:2,roughness:.7,stroke:n,seed:t}},"solidStateFill"),ot=u(n=>{let t=Zs([...n.cssCompiledStyles||[],...n.cssStyles||[]]);return{stylesMap:t,stylesArray:[...t]}},"compileStyles"),Zs=u(n=>{let t=new Map;return n.forEach(o=>{let[r,s]=o.split(":");t.set(r.trim(),s?.trim())}),t},"styles2Map"),k=u(n=>{let{stylesArray:t}=ot(n),o=[],r=[],s=[],a=[];return t.forEach(c=>{let e=c[0];e==="color"||e==="font-size"||e==="font-family"||e==="font-weight"||e==="font-style"||e==="text-decoration"||e==="text-align"||e==="text-transform"||e==="line-height"||e==="letter-spacing"||e==="word-spacing"||e==="text-shadow"||e==="text-overflow"||e==="white-space"||e==="word-wrap"||e==="word-break"||e==="overflow-wrap"||e==="hyphens"?o.push(c.join(":")+" !important"):(r.push(c.join(":")+" !important"),e.includes("stroke")&&s.push(c.join(":")+" !important"),e==="fill"&&a.push(c.join(":")+" !important"))}),{labelStyles:o.join(";"),nodeStyles:r.join(";"),stylesArray:t,borderStyles:s,backgroundStyles:a}},"styles2String"),M=u((n,t)=>{let{themeVariables:o,handDrawnSeed:r}=q(),{nodeBorder:s,mainBkg:a}=o,{stylesMap:c}=ot(n);return Object.assign({roughness:.7,fill:c.get("fill")||a,fillStyle:"hachure",fillWeight:4,hachureGap:5.2,stroke:c.get("stroke")||s,seed:r,strokeWidth:c.get("stroke-width")?.replace("px","")||1.3,fillLineDash:[0,0]},t)},"userNodeOverrides");var Me=u(async(n,t)=>{z.info("Creating subgraph rect for ",t.id,t);let o=q(),{themeVariables:r,handDrawnSeed:s}=o,{clusterBkg:a,clusterBorder:c}=r,{labelStyles:e,nodeStyles:h,borderStyles:i,backgroundStyles:l}=k(t),p=n.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),f=Y(o.flowchart.htmlLabels),m=p.insert("g").attr("class","cluster-label "),g=await it(m,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0}),d=g.getBBox();if(Y(o.flowchart.htmlLabels)){let B=g.children[0],R=Z(g);d=B.getBoundingClientRect(),R.attr("width",d.width),R.attr("height",d.height)}let x=t.width<=d.width+t.padding?d.width+t.padding:t.width;t.width<=d.width+t.padding?t.diff=(x-t.width)/2-t.padding:t.diff=-t.padding;let y=t.height,b=t.x-x/2,S=t.y-y/2;z.trace("Data ",t,JSON.stringify(t));let $;if(t.look==="handDrawn"){let B=D.svg(p),R=M(t,{roughness:.7,fill:a,stroke:c,fillWeight:3,seed:s}),j=B.path(Q(b,S,x,y,0),R);$=p.insert(()=>(z.debug("Rough node insert CXC",j),j),":first-child"),$.select("path:nth-child(2)").attr("style",i.join(";")),$.select("path").attr("style",l.join(";").replace("fill","stroke"))}else $=p.insert("rect",":first-child"),$.attr("style",h).attr("rx",t.rx).attr("ry",t.ry).attr("x",b).attr("y",S).attr("width",x).attr("height",y);let{subGraphTitleTopMargin:w}=Lt(o);if(m.attr("transform",`translate(${t.x-d.width/2}, ${t.y-t.height/2+w})`),e){let B=m.select("span");B&&B.attr("style",e)}let C=$.node().getBBox();return t.offsetX=0,t.width=C.width,t.height=C.height,t.offsetY=d.height-t.padding/2,t.intersect=function(B){return lt(t,B)},{cluster:p,labelBBox:d}},"rect"),Us=u((n,t)=>{let o=n.insert("g").attr("class","note-cluster").attr("id",t.id),r=o.insert("rect",":first-child"),s=0*t.padding,a=s/2;r.attr("rx",t.rx).attr("ry",t.ry).attr("x",t.x-t.width/2-a).attr("y",t.y-t.height/2-a).attr("width",t.width+s).attr("height",t.height+s).attr("fill","none");let c=r.node().getBBox();return t.width=c.width,t.height=c.height,t.intersect=function(e){return lt(t,e)},{cluster:o,labelBBox:{width:0,height:0}}},"noteGroup"),Qs=u(async(n,t)=>{let o=q(),{themeVariables:r,handDrawnSeed:s}=o,{altBackground:a,compositeBackground:c,compositeTitleBackground:e,nodeBorder:h}=r,i=n.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-id",t.id).attr("data-look",t.look),l=i.insert("g",":first-child"),p=i.insert("g").attr("class","cluster-label"),f=i.append("rect"),m=p.node().appendChild(await St(t.label,t.labelStyle,void 0,!0)),g=m.getBBox();if(Y(o.flowchart.htmlLabels)){let j=m.children[0],A=Z(m);g=j.getBoundingClientRect(),A.attr("width",g.width),A.attr("height",g.height)}let d=0*t.padding,x=d/2,y=(t.width<=g.width+t.padding?g.width+t.padding:t.width)+d;t.width<=g.width+t.padding?t.diff=(y-t.width)/2-t.padding:t.diff=-t.padding;let b=t.height+d,S=t.height+d-g.height-6,$=t.x-y/2,w=t.y-b/2;t.width=y;let C=t.y-t.height/2-x+g.height+2,B;if(t.look==="handDrawn"){let j=t.cssClasses.includes("statediagram-cluster-alt"),A=D.svg(i),O=t.rx||t.ry?A.path(Q($,w,y,b,10),{roughness:.7,fill:e,fillStyle:"solid",stroke:h,seed:s}):A.rectangle($,w,y,b,{seed:s});B=i.insert(()=>O,":first-child");let W=A.rectangle($,C,y,S,{fill:j?a:c,fillStyle:j?"hachure":"solid",stroke:h,seed:s});B=i.insert(()=>O,":first-child"),f=i.insert(()=>W)}else B=l.insert("rect",":first-child"),B.attr("class","outer").attr("x",$).attr("y",w).attr("width",y).attr("height",b).attr("data-look",t.look),f.attr("class","inner").attr("x",$).attr("y",C).attr("width",y).attr("height",S);p.attr("transform",`translate(${t.x-g.width/2}, ${w+1-(Y(o.flowchart.htmlLabels)?0:3)})`);let R=B.node().getBBox();return t.height=R.height,t.offsetX=0,t.offsetY=g.height-t.padding/2,t.labelBBox=g,t.intersect=function(j){return lt(t,j)},{cluster:i,labelBBox:g}},"roundedWithTitle"),Js=u(async(n,t)=>{z.info("Creating subgraph rect for ",t.id,t);let o=q(),{themeVariables:r,handDrawnSeed:s}=o,{clusterBkg:a,clusterBorder:c}=r,{labelStyles:e,nodeStyles:h,borderStyles:i,backgroundStyles:l}=k(t),p=n.insert("g").attr("class","cluster "+t.cssClasses).attr("id",t.id).attr("data-look",t.look),f=Y(o.flowchart.htmlLabels),m=p.insert("g").attr("class","cluster-label "),g=await it(m,t.label,{style:t.labelStyle,useHtmlLabels:f,isNode:!0,width:t.width}),d=g.getBBox();if(Y(o.flowchart.htmlLabels)){let B=g.children[0],R=Z(g);d=B.getBoundingClientRect(),R.attr("width",d.width),R.attr("height",d.height)}let x=t.width<=d.width+t.padding?d.width+t.padding:t.width;t.width<=d.width+t.padding?t.diff=(x-t.width)/2-t.padding:t.diff=-t.padding;let y=t.height,b=t.x-x/2,S=t.y-y/2;z.trace("Data ",t,JSON.stringify(t));let $;if(t.look==="handDrawn"){let B=D.svg(p),R=M(t,{roughness:.7,fill:a,stroke:c,fillWeight:4,seed:s}),j=B.path(Q(b,S,x,y,t.rx),R);$=p.insert(()=>(z.debug("Rough node insert CXC",j),j),":first-child"),$.select("path:nth-child(2)").attr("style",i.join(";")),$.select("path").attr("style",l.join(";").replace("fill","stroke"))}else $=p.insert("rect",":first-child"),$.attr("style",h).attr("rx",t.rx).attr("ry",t.ry).attr("x",b).attr("y",S).attr("width",x).attr("height",y);let{subGraphTitleTopMargin:w}=Lt(o);if(m.attr("transform",`translate(${t.x-d.width/2}, ${t.y-t.height/2+w})`),e){let B=m.select("span");B&&B.attr("style",e)}let C=$.node().getBBox();return t.offsetX=0,t.width=C.width,t.height=C.height,t.offsetY=d.height-t.padding/2,t.intersect=function(B){return lt(t,B)},{cluster:p,labelBBox:d}},"kanbanSection"),Ks=u((n,t)=>{let o=q(),{themeVariables:r,handDrawnSeed:s}=o,{nodeBorder:a}=r,c=n.insert("g").attr("class",t.cssClasses).attr("id",t.id).attr("data-look",t.look),e=c.insert("g",":first-child"),h=0*t.padding,i=t.width+h;t.diff=-t.padding;let l=t.height+h,p=t.x-i/2,f=t.y-l/2;t.width=i;let m;if(t.look==="handDrawn"){let x=D.svg(c).rectangle(p,f,i,l,{fill:"lightgrey",roughness:.5,strokeLineDash:[5],stroke:a,seed:s});m=c.insert(()=>x,":first-child")}else m=e.insert("rect",":first-child"),m.attr("class","divider").attr("x",p).attr("y",f).attr("width",i).attr("height",l).attr("data-look",t.look);let g=m.node().getBBox();return t.height=g.height,t.offsetX=0,t.offsetY=0,t.intersect=function(d){return lt(t,d)},{cluster:c,labelBBox:{}}},"divider"),tr=Me,er={rect:Me,squareRect:tr,roundedWithTitle:Qs,noteGroup:Us,divider:Ks,kanbanSection:Js},ve=new Map,ro=u(async(n,t)=>{let o=t.shape||"rect",r=await er[o](n,t);return ve.set(t.id,r),r},"insertCluster");var oo=u(()=>{ve=new Map},"clear");function sr(n,t){return n.intersect(t)}u(sr,"intersectNode");var ke=sr;function rr(n,t,o,r){var s=n.x,a=n.y,c=s-r.x,e=a-r.y,h=Math.sqrt(t*t*e*e+o*o*c*c),i=Math.abs(t*o*c/h);r.x0}u(Pe,"sameSign");var Te=ar;function ir(n,t,o){let r=n.x,s=n.y,a=[],c=Number.POSITIVE_INFINITY,e=Number.POSITIVE_INFINITY;typeof t.forEach=="function"?t.forEach(function(l){c=Math.min(c,l.x),e=Math.min(e,l.y)}):(c=Math.min(c,t.x),e=Math.min(e,t.y));let h=r-n.width/2-c,i=s-n.height/2-e;for(let l=0;l1&&a.sort(function(l,p){let f=l.x-o.x,m=l.y-o.y,g=Math.sqrt(f*f+m*m),d=p.x-o.x,x=p.y-o.y,y=Math.sqrt(d*d+x*x);return gl,":first-child");return p.attr("class","anchor").attr("style",X(e)),v(t,p),t.intersect=function(f){return z.info("Circle intersect",t,c,f),N.circle(t,c,f)},a}u(Be,"anchor");function Re(n,t,o,r,s,a,c){let h=(n+o)/2,i=(t+r)/2,l=Math.atan2(r-t,o-n),p=(o-n)/2,f=(r-t)/2,m=p/s,g=f/a,d=Math.sqrt(m**2+g**2);if(d>1)throw new Error("The given radii are too small to create an arc between the points.");let x=Math.sqrt(1-d**2),y=h+x*a*Math.sin(l)*(c?-1:1),b=i-x*s*Math.cos(l)*(c?-1:1),S=Math.atan2((t-b)/a,(n-y)/s),w=Math.atan2((r-b)/a,(o-y)/s)-S;c&&w<0&&(w+=2*Math.PI),!c&&w>0&&(w-=2*Math.PI);let C=[];for(let B=0;B<20;B++){let R=B/19,j=S+R*w,A=y+s*Math.cos(j),O=b+a*Math.sin(j);C.push({x:A,y:O})}return C}u(Re,"generateArcPoints");async function Ge(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=a.width+t.padding+20,e=a.height+t.padding,h=e/2,i=h/(2.5+e/50),{cssStyles:l}=t,p=[{x:c/2,y:-e/2},{x:-c/2,y:-e/2},...Re(-c/2,-e/2,-c/2,e/2,i,h,!1),{x:c/2,y:e/2},...Re(c/2,e/2,c/2,-e/2,i,h,!0)],f=D.svg(s),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=H(p),d=f.path(g,m),x=s.insert(()=>d,":first-child");return x.attr("class","basic label-container"),l&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",l),r&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",r),x.attr("transform",`translate(${i/2}, 0)`),v(t,x),t.intersect=function(y){return N.polygon(t,p,y)},s}u(Ge,"bowTieRect");function J(n,t,o,r){return n.insert("polygon",":first-child").attr("points",r.map(function(s){return s.x+","+s.y}).join(" ")).attr("class","label-container").attr("transform","translate("+-t/2+","+o/2+")")}u(J,"insertPolygonShape");async function je(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=a.height+t.padding,e=12,h=a.width+t.padding+e,i=0,l=h,p=-c,f=0,m=[{x:i+e,y:p},{x:l,y:p},{x:l,y:f},{x:i,y:f},{x:i,y:p+e},{x:i+e,y:p}],g,{cssStyles:d}=t;if(t.look==="handDrawn"){let x=D.svg(s),y=M(t,{}),b=H(m),S=x.path(b,y);g=s.insert(()=>S,":first-child").attr("transform",`translate(${-h/2}, ${c/2})`),d&&g.attr("style",d)}else g=J(s,h,c,m);return r&&g.attr("style",r),v(t,g),t.intersect=function(x){return N.polygon(t,m,x)},s}u(je,"card");function Ee(n,t){let{nodeStyles:o}=k(t);t.label="";let r=n.insert("g").attr("class",P(t)).attr("id",t.domId??t.id),{cssStyles:s}=t,a=Math.max(28,t.width??0),c=[{x:0,y:a/2},{x:a/2,y:0},{x:0,y:-a/2},{x:-a/2,y:0}],e=D.svg(r),h=M(t,{});t.look!=="handDrawn"&&(h.roughness=0,h.fillStyle="solid");let i=H(c),l=e.path(i,h),p=r.insert(()=>l,":first-child");return s&&t.look!=="handDrawn"&&p.selectAll("path").attr("style",s),o&&t.look!=="handDrawn"&&p.selectAll("path").attr("style",o),t.width=28,t.height=28,t.intersect=function(f){return N.polygon(t,c,f)},r}u(Ee,"choice");async function Ae(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,halfPadding:c}=await T(n,t,P(t)),e=a.width/2+c,h,{cssStyles:i}=t;if(t.look==="handDrawn"){let l=D.svg(s),p=M(t,{}),f=l.circle(0,0,e*2,p);h=s.insert(()=>f,":first-child"),h.attr("class","basic label-container").attr("style",X(i))}else h=s.insert("circle",":first-child").attr("class","basic label-container").attr("style",r).attr("r",e).attr("cx",0).attr("cy",0);return v(t,h),t.intersect=function(l){return z.info("Circle intersect",t,e,l),N.circle(t,e,l)},s}u(Ae,"circle");function nr(n){let t=Math.cos(Math.PI/4),o=Math.sin(Math.PI/4),r=n*2,s={x:r/2*t,y:r/2*o},a={x:-(r/2)*t,y:r/2*o},c={x:-(r/2)*t,y:-(r/2)*o},e={x:r/2*t,y:-(r/2)*o};return`M ${a.x},${a.y} L ${e.x},${e.y} + M ${s.x},${s.y} L ${c.x},${c.y}`}u(nr,"createLine");function Oe(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o,t.label="";let s=n.insert("g").attr("class",P(t)).attr("id",t.domId??t.id),a=Math.max(30,t?.width??0),{cssStyles:c}=t,e=D.svg(s),h=M(t,{});t.look!=="handDrawn"&&(h.roughness=0,h.fillStyle="solid");let i=e.circle(0,0,a*2,h),l=nr(a),p=e.path(l,h),f=s.insert(()=>i,":first-child");return f.insert(()=>p),c&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",c),r&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",r),v(t,f),t.intersect=function(m){return z.info("crossedCircle intersect",t,{radius:a,point:m}),N.circle(t,a,m)},s}u(Oe,"crossedCircle");function ct(n,t,o,r=100,s=0,a=180){let c=[],e=s*Math.PI/180,l=(a*Math.PI/180-e)/(r-1);for(let p=0;pS,":first-child").attr("stroke-opacity",0),$.insert(()=>y,":first-child"),$.attr("class","text"),l&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",l),r&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",r),$.attr("transform",`translate(${i}, 0)`),c.attr("transform",`translate(${-e/2+i-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),v(t,$),t.intersect=function(w){return N.polygon(t,f,w)},s}u(Le,"curlyBraceLeft");function ht(n,t,o,r=100,s=0,a=180){let c=[],e=s*Math.PI/180,l=(a*Math.PI/180-e)/(r-1);for(let p=0;pS,":first-child").attr("stroke-opacity",0),$.insert(()=>y,":first-child"),$.attr("class","text"),l&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",l),r&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",r),$.attr("transform",`translate(${-i}, 0)`),c.attr("transform",`translate(${-e/2+(t.padding??0)/2-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),v(t,$),t.intersect=function(w){return N.polygon(t,f,w)},s}u(He,"curlyBraceRight");function K(n,t,o,r=100,s=0,a=180){let c=[],e=s*Math.PI/180,l=(a*Math.PI/180-e)/(r-1);for(let p=0;pB,":first-child").attr("stroke-opacity",0),R.insert(()=>b,":first-child"),R.insert(()=>w,":first-child"),R.attr("class","text"),l&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",l),r&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",r),R.attr("transform",`translate(${i-i/4}, 0)`),c.attr("transform",`translate(${-e/2+(t.padding??0)/2-(a.x-(a.left??0))},${-h/2+(t.padding??0)/2-(a.y-(a.top??0))})`),v(t,R),t.intersect=function(j){return N.polygon(t,m,j)},s}u(Ve,"curlyBraces");async function We(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=80,e=20,h=Math.max(c,(a.width+(t.padding??0)*2)*1.25,t?.width??0),i=Math.max(e,a.height+(t.padding??0)*2,t?.height??0),l=i/2,{cssStyles:p}=t,f=D.svg(s),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=h,d=i,x=g-l,y=d/4,b=[{x,y:0},{x:y,y:0},{x:0,y:d/2},{x:y,y:d},{x,y:d},...Mt(-x,-d/2,l,50,270,90)],S=H(b),$=f.path(S,m),w=s.insert(()=>$,":first-child");return w.attr("class","basic label-container"),p&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",p),r&&t.look!=="handDrawn"&&w.selectChildren("path").attr("style",r),w.attr("transform",`translate(${-h/2}, ${-i/2})`),v(t,w),t.intersect=function(C){return N.polygon(t,b,C)},s}u(We,"curvedTrapezoid");var lr=u((n,t,o,r,s,a)=>[`M${n},${t+a}`,`a${s},${a} 0,0,0 ${o},0`,`a${s},${a} 0,0,0 ${-o},0`,`l0,${r}`,`a${s},${a} 0,0,0 ${o},0`,`l0,${-r}`].join(" "),"createCylinderPathD"),cr=u((n,t,o,r,s,a)=>[`M${n},${t+a}`,`M${n+o},${t+a}`,`a${s},${a} 0,0,0 ${-o},0`,`l0,${r}`,`a${s},${a} 0,0,0 ${o},0`,`l0,${-r}`].join(" "),"createOuterCylinderPathD"),hr=u((n,t,o,r,s,a)=>[`M${n-o/2},${-r/2}`,`a${s},${a} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD");async function Ie(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+t.padding,t.width??0),h=e/2,i=h/(2.5+e/50),l=Math.max(a.height+i+t.padding,t.height??0),p,{cssStyles:f}=t;if(t.look==="handDrawn"){let m=D.svg(s),g=cr(0,0,e,l,h,i),d=hr(0,i,e,l,h,i),x=m.path(g,M(t,{})),y=m.path(d,M(t,{fill:"none"}));p=s.insert(()=>y,":first-child"),p=s.insert(()=>x,":first-child"),p.attr("class","basic label-container"),f&&p.attr("style",f)}else{let m=lr(0,0,e,l,h,i);p=s.insert("path",":first-child").attr("d",m).attr("class","basic label-container").attr("style",X(f)).attr("style",r)}return p.attr("label-offset-y",i),p.attr("transform",`translate(${-e/2}, ${-(l/2+i)})`),v(t,p),c.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)+(t.padding??0)/1.5-(a.y-(a.top??0))})`),t.intersect=function(m){let g=N.rect(t,m),d=g.x-(t.x??0);if(h!=0&&(Math.abs(d)<(t.width??0)/2||Math.abs(d)==(t.width??0)/2&&Math.abs(g.y-(t.y??0))>(t.height??0)/2-i)){let x=i*i*(1-d*d/(h*h));x>0&&(x=Math.sqrt(x)),x=i-x,m.y-(t.y??0)>0&&(x=-x),g.y+=x}return g},s}u(Ie,"cylinder");async function Fe(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=a.width+t.padding,h=a.height+t.padding,i=h*.2,l=-e/2,p=-h/2-i/2,{cssStyles:f}=t,m=D.svg(s),g=M(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let d=[{x:l,y:p+i},{x:-l,y:p+i},{x:-l,y:-p},{x:l,y:-p},{x:l,y:p},{x:-l,y:p},{x:-l,y:p+i}],x=m.polygon(d.map(b=>[b.x,b.y]),g),y=s.insert(()=>x,":first-child");return y.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",f),r&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",r),c.attr("transform",`translate(${l+(t.padding??0)/2-(a.x-(a.left??0))}, ${p+i+(t.padding??0)/2-(a.y-(a.top??0))})`),v(t,y),t.intersect=function(b){return N.rect(t,b)},s}u(Fe,"dividedRectangle");async function _e(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,halfPadding:c}=await T(n,t,P(t)),h=a.width/2+c+5,i=a.width/2+c,l,{cssStyles:p}=t;if(t.look==="handDrawn"){let f=D.svg(s),m=M(t,{roughness:.2,strokeWidth:2.5}),g=M(t,{roughness:.2,strokeWidth:1.5}),d=f.circle(0,0,h*2,m),x=f.circle(0,0,i*2,g);l=s.insert("g",":first-child"),l.attr("class",X(t.cssClasses)).attr("style",X(p)),l.node()?.appendChild(d),l.node()?.appendChild(x)}else{l=s.insert("g",":first-child");let f=l.insert("circle",":first-child"),m=l.insert("circle");l.attr("class","basic label-container").attr("style",r),f.attr("class","outer-circle").attr("style",r).attr("r",h).attr("cx",0).attr("cy",0),m.attr("class","inner-circle").attr("style",r).attr("r",i).attr("cx",0).attr("cy",0)}return v(t,l),t.intersect=function(f){return z.info("DoubleCircle intersect",t,h,f),N.circle(t,h,f)},s}u(_e,"doublecircle");function ze(n,t,{config:{themeVariables:o}}){let{labelStyles:r,nodeStyles:s}=k(t);t.label="",t.labelStyle=r;let a=n.insert("g").attr("class",P(t)).attr("id",t.domId??t.id),c=7,{cssStyles:e}=t,h=D.svg(a),{nodeBorder:i}=o,l=M(t,{fillStyle:"solid"});t.look!=="handDrawn"&&(l.roughness=0);let p=h.circle(0,0,c*2,l),f=a.insert(()=>p,":first-child");return f.selectAll("path").attr("style",`fill: ${i} !important;`),e&&e.length>0&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",e),s&&t.look!=="handDrawn"&&f.selectAll("path").attr("style",s),v(t,f),t.intersect=function(m){return z.info("filledCircle intersect",t,{radius:c,point:m}),N.circle(t,c,m)},a}u(ze,"filledCircle");async function qe(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=a.width+(t.padding??0),h=e+a.height,i=e+a.height,l=[{x:0,y:-h},{x:i,y:-h},{x:i/2,y:0}],{cssStyles:p}=t,f=D.svg(s),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=H(l),d=f.path(g,m),x=s.insert(()=>d,":first-child").attr("transform",`translate(${-h/2}, ${h/2})`);return p&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",p),r&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",r),t.width=e,t.height=h,v(t,x),c.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${-h/2+(t.padding??0)/2+(a.y-(a.top??0))})`),t.intersect=function(y){return z.info("Triangle intersect",t,l,y),N.polygon(t,l,y)},s}u(qe,"flippedTriangle");function Xe(n,t,{dir:o,config:{state:r,themeVariables:s}}){let{nodeStyles:a}=k(t);t.label="";let c=n.insert("g").attr("class",P(t)).attr("id",t.domId??t.id),{cssStyles:e}=t,h=Math.max(70,t?.width??0),i=Math.max(10,t?.height??0);o==="LR"&&(h=Math.max(10,t?.width??0),i=Math.max(70,t?.height??0));let l=-1*h/2,p=-1*i/2,f=D.svg(c),m=M(t,{stroke:s.lineColor,fill:s.lineColor});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=f.rectangle(l,p,h,i,m),d=c.insert(()=>g,":first-child");e&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",e),a&&t.look!=="handDrawn"&&d.selectAll("path").attr("style",a),v(t,d);let x=r?.padding??0;return t.width&&t.height&&(t.width+=x/2||0,t.height+=x/2||0),t.intersect=function(y){return N.rect(t,y)},c}u(Xe,"forkJoin");async function Ye(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let s=80,a=50,{shapeSvg:c,bbox:e}=await T(n,t,P(t)),h=Math.max(s,e.width+(t.padding??0)*2,t?.width??0),i=Math.max(a,e.height+(t.padding??0)*2,t?.height??0),l=i/2,{cssStyles:p}=t,f=D.svg(c),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=[{x:-h/2,y:-i/2},{x:h/2-l,y:-i/2},...Mt(-h/2+l,0,l,50,90,270),{x:h/2-l,y:i/2},{x:-h/2,y:i/2}],d=H(g),x=f.path(d,m),y=c.insert(()=>x,":first-child");return y.attr("class","basic label-container"),p&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",p),r&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",r),v(t,y),t.intersect=function(b){return z.info("Pill intersect",t,{radius:l,point:b}),N.polygon(t,g,b)},c}u(Ye,"halfRoundedRectangle");var pr=u((n,t,o,r,s)=>[`M${n+s},${t}`,`L${n+o-s},${t}`,`L${n+o},${t-r/2}`,`L${n+o-s},${t-r}`,`L${n+s},${t-r}`,`L${n},${t-r/2}`,"Z"].join(" "),"createHexagonPathD");async function Ze(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=4,e=a.height+t.padding,h=e/c,i=a.width+2*h+t.padding,l=[{x:h,y:0},{x:i-h,y:0},{x:i,y:-e/2},{x:i-h,y:-e},{x:h,y:-e},{x:0,y:-e/2}],p,{cssStyles:f}=t;if(t.look==="handDrawn"){let m=D.svg(s),g=M(t,{}),d=pr(0,0,i,e,h),x=m.path(d,g);p=s.insert(()=>x,":first-child").attr("transform",`translate(${-i/2}, ${e/2})`),f&&p.attr("style",f)}else p=J(s,i,e,l);return r&&p.attr("style",r),t.width=i,t.height=e,v(t,p),t.intersect=function(m){return N.polygon(t,l,m)},s}u(Ze,"hexagon");async function Ue(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.label="",t.labelStyle=o;let{shapeSvg:s}=await T(n,t,P(t)),a=Math.max(30,t?.width??0),c=Math.max(30,t?.height??0),{cssStyles:e}=t,h=D.svg(s),i=M(t,{});t.look!=="handDrawn"&&(i.roughness=0,i.fillStyle="solid");let l=[{x:0,y:0},{x:a,y:0},{x:0,y:c},{x:a,y:c}],p=H(l),f=h.path(p,i),m=s.insert(()=>f,":first-child");return m.attr("class","basic label-container"),e&&t.look!=="handDrawn"&&m.selectChildren("path").attr("style",e),r&&t.look!=="handDrawn"&&m.selectChildren("path").attr("style",r),m.attr("transform",`translate(${-a/2}, ${-c/2})`),v(t,m),t.intersect=function(g){return z.info("Pill intersect",t,{points:l}),N.polygon(t,l,g)},s}u(Ue,"hourglass");async function Qe(n,t,{config:{themeVariables:o,flowchart:r}}){let{labelStyles:s}=k(t);t.labelStyle=s;let a=t.assetHeight??48,c=t.assetWidth??48,e=Math.max(a,c),h=r?.wrappingWidth;t.width=Math.max(e,h??0);let{shapeSvg:i,bbox:l,label:p}=await T(n,t,"icon-shape default"),f=t.pos==="t",m=e,g=e,{nodeBorder:d}=o,{stylesMap:x}=ot(t),y=-g/2,b=-m/2,S=t.label?8:0,$=D.svg(i),w=M(t,{stroke:"none",fill:"none"});t.look!=="handDrawn"&&(w.roughness=0,w.fillStyle="solid");let C=$.rectangle(y,b,g,m,w),B=Math.max(g,l.width),R=m+l.height+S,j=$.rectangle(-B/2,-R/2,B,R,{...w,fill:"transparent",stroke:"none"}),A=i.insert(()=>C,":first-child"),O=i.insert(()=>j);if(t.icon){let W=i.append("g");W.html(`${await at(t.icon,{height:e,width:e,fallbackPrefix:""})}`);let G=W.node().getBBox(),L=G.width,V=G.height,E=G.x,I=G.y;W.attr("transform",`translate(${-L/2-E},${f?l.height/2+S/2-V/2-I:-l.height/2-S/2-V/2-I})`),W.attr("style",`color: ${x.get("stroke")??d};`)}return p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))},${f?-R/2:R/2-l.height})`),A.attr("transform",`translate(0,${f?l.height/2+S/2:-l.height/2-S/2})`),v(t,O),t.intersect=function(W){if(z.info("iconSquare intersect",t,W),!t.label)return N.rect(t,W);let G=t.x??0,L=t.y??0,V=t.height??0,E=[];return f?E=[{x:G-l.width/2,y:L-V/2},{x:G+l.width/2,y:L-V/2},{x:G+l.width/2,y:L-V/2+l.height+S},{x:G+g/2,y:L-V/2+l.height+S},{x:G+g/2,y:L+V/2},{x:G-g/2,y:L+V/2},{x:G-g/2,y:L-V/2+l.height+S},{x:G-l.width/2,y:L-V/2+l.height+S}]:E=[{x:G-g/2,y:L-V/2},{x:G+g/2,y:L-V/2},{x:G+g/2,y:L-V/2+m},{x:G+l.width/2,y:L-V/2+m},{x:G+l.width/2/2,y:L+V/2},{x:G-l.width/2,y:L+V/2},{x:G-l.width/2,y:L-V/2+m},{x:G-g/2,y:L-V/2+m}],N.polygon(t,E,W)},i}u(Qe,"icon");async function Je(n,t,{config:{themeVariables:o,flowchart:r}}){let{labelStyles:s}=k(t);t.labelStyle=s;let a=t.assetHeight??48,c=t.assetWidth??48,e=Math.max(a,c),h=r?.wrappingWidth;t.width=Math.max(e,h??0);let{shapeSvg:i,bbox:l,label:p}=await T(n,t,"icon-shape default"),f=20,m=t.label?8:0,g=t.pos==="t",{nodeBorder:d,mainBkg:x}=o,{stylesMap:y}=ot(t),b=D.svg(i),S=M(t,{});t.look!=="handDrawn"&&(S.roughness=0,S.fillStyle="solid");let $=y.get("fill");S.stroke=$??x;let w=i.append("g");t.icon&&w.html(`${await at(t.icon,{height:e,width:e,fallbackPrefix:""})}`);let C=w.node().getBBox(),B=C.width,R=C.height,j=C.x,A=C.y,O=Math.max(B,R)*Math.SQRT2+f*2,W=b.circle(0,0,O,S),G=Math.max(O,l.width),L=O+l.height+m,V=b.rectangle(-G/2,-L/2,G,L,{...S,fill:"transparent",stroke:"none"}),E=i.insert(()=>W,":first-child"),I=i.insert(()=>V);return w.attr("transform",`translate(${-B/2-j},${g?l.height/2+m/2-R/2-A:-l.height/2-m/2-R/2-A})`),w.attr("style",`color: ${y.get("stroke")??d};`),p.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))},${g?-L/2:L/2-l.height})`),E.attr("transform",`translate(0,${g?l.height/2+m/2:-l.height/2-m/2})`),v(t,I),t.intersect=function(_){return z.info("iconSquare intersect",t,_),N.rect(t,_)},i}u(Je,"iconCircle");async function Ke(n,t,{config:{themeVariables:o,flowchart:r}}){let{labelStyles:s}=k(t);t.labelStyle=s;let a=t.assetHeight??48,c=t.assetWidth??48,e=Math.max(a,c),h=r?.wrappingWidth;t.width=Math.max(e,h??0);let{shapeSvg:i,bbox:l,halfPadding:p,label:f}=await T(n,t,"icon-shape default"),m=t.pos==="t",g=e+p*2,d=e+p*2,{nodeBorder:x,mainBkg:y}=o,{stylesMap:b}=ot(t),S=-d/2,$=-g/2,w=t.label?8:0,C=D.svg(i),B=M(t,{});t.look!=="handDrawn"&&(B.roughness=0,B.fillStyle="solid");let R=b.get("fill");B.stroke=R??y;let j=C.path(Q(S,$,d,g,5),B),A=Math.max(d,l.width),O=g+l.height+w,W=C.rectangle(-A/2,-O/2,A,O,{...B,fill:"transparent",stroke:"none"}),G=i.insert(()=>j,":first-child").attr("class","icon-shape2"),L=i.insert(()=>W);if(t.icon){let V=i.append("g");V.html(`${await at(t.icon,{height:e,width:e,fallbackPrefix:""})}`);let E=V.node().getBBox(),I=E.width,_=E.height,U=E.x,rt=E.y;V.attr("transform",`translate(${-I/2-U},${m?l.height/2+w/2-_/2-rt:-l.height/2-w/2-_/2-rt})`),V.attr("style",`color: ${b.get("stroke")??x};`)}return f.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))},${m?-O/2:O/2-l.height})`),G.attr("transform",`translate(0,${m?l.height/2+w/2:-l.height/2-w/2})`),v(t,L),t.intersect=function(V){if(z.info("iconSquare intersect",t,V),!t.label)return N.rect(t,V);let E=t.x??0,I=t.y??0,_=t.height??0,U=[];return m?U=[{x:E-l.width/2,y:I-_/2},{x:E+l.width/2,y:I-_/2},{x:E+l.width/2,y:I-_/2+l.height+w},{x:E+d/2,y:I-_/2+l.height+w},{x:E+d/2,y:I+_/2},{x:E-d/2,y:I+_/2},{x:E-d/2,y:I-_/2+l.height+w},{x:E-l.width/2,y:I-_/2+l.height+w}]:U=[{x:E-d/2,y:I-_/2},{x:E+d/2,y:I-_/2},{x:E+d/2,y:I-_/2+g},{x:E+l.width/2,y:I-_/2+g},{x:E+l.width/2/2,y:I+_/2},{x:E-l.width/2,y:I+_/2},{x:E-l.width/2,y:I-_/2+g},{x:E-d/2,y:I-_/2+g}],N.polygon(t,U,V)},i}u(Ke,"iconRounded");async function ts(n,t,{config:{themeVariables:o,flowchart:r}}){let{labelStyles:s}=k(t);t.labelStyle=s;let a=t.assetHeight??48,c=t.assetWidth??48,e=Math.max(a,c),h=r?.wrappingWidth;t.width=Math.max(e,h??0);let{shapeSvg:i,bbox:l,halfPadding:p,label:f}=await T(n,t,"icon-shape default"),m=t.pos==="t",g=e+p*2,d=e+p*2,{nodeBorder:x,mainBkg:y}=o,{stylesMap:b}=ot(t),S=-d/2,$=-g/2,w=t.label?8:0,C=D.svg(i),B=M(t,{});t.look!=="handDrawn"&&(B.roughness=0,B.fillStyle="solid");let R=b.get("fill");B.stroke=R??y;let j=C.path(Q(S,$,d,g,.1),B),A=Math.max(d,l.width),O=g+l.height+w,W=C.rectangle(-A/2,-O/2,A,O,{...B,fill:"transparent",stroke:"none"}),G=i.insert(()=>j,":first-child"),L=i.insert(()=>W);if(t.icon){let V=i.append("g");V.html(`${await at(t.icon,{height:e,width:e,fallbackPrefix:""})}`);let E=V.node().getBBox(),I=E.width,_=E.height,U=E.x,rt=E.y;V.attr("transform",`translate(${-I/2-U},${m?l.height/2+w/2-_/2-rt:-l.height/2-w/2-_/2-rt})`),V.attr("style",`color: ${b.get("stroke")??x};`)}return f.attr("transform",`translate(${-l.width/2-(l.x-(l.left??0))},${m?-O/2:O/2-l.height})`),G.attr("transform",`translate(0,${m?l.height/2+w/2:-l.height/2-w/2})`),v(t,L),t.intersect=function(V){if(z.info("iconSquare intersect",t,V),!t.label)return N.rect(t,V);let E=t.x??0,I=t.y??0,_=t.height??0,U=[];return m?U=[{x:E-l.width/2,y:I-_/2},{x:E+l.width/2,y:I-_/2},{x:E+l.width/2,y:I-_/2+l.height+w},{x:E+d/2,y:I-_/2+l.height+w},{x:E+d/2,y:I+_/2},{x:E-d/2,y:I+_/2},{x:E-d/2,y:I-_/2+l.height+w},{x:E-l.width/2,y:I-_/2+l.height+w}]:U=[{x:E-d/2,y:I-_/2},{x:E+d/2,y:I-_/2},{x:E+d/2,y:I-_/2+g},{x:E+l.width/2,y:I-_/2+g},{x:E+l.width/2/2,y:I+_/2},{x:E-l.width/2,y:I+_/2},{x:E-l.width/2,y:I-_/2+g},{x:E-d/2,y:I-_/2+g}],N.polygon(t,U,V)},i}u(ts,"iconSquare");async function es(n,t,{config:{flowchart:o}}){let r=new Image;r.src=t?.img??"",await r.decode();let s=Number(r.naturalWidth.toString().replace("px","")),a=Number(r.naturalHeight.toString().replace("px",""));t.imageAspectRatio=s/a;let{labelStyles:c}=k(t);t.labelStyle=c;let e=o?.wrappingWidth;t.defaultWidth=o?.wrappingWidth;let h=Math.max(t.label?e??0:0,t?.assetWidth??s),i=t.constraint==="on"&&t?.assetHeight?t.assetHeight*t.imageAspectRatio:h,l=t.constraint==="on"?i/t.imageAspectRatio:t?.assetHeight??a;t.width=Math.max(i,e??0);let{shapeSvg:p,bbox:f,label:m}=await T(n,t,"image-shape default"),g=t.pos==="t",d=-i/2,x=-l/2,y=t.label?8:0,b=D.svg(p),S=M(t,{});t.look!=="handDrawn"&&(S.roughness=0,S.fillStyle="solid");let $=b.rectangle(d,x,i,l,S),w=Math.max(i,f.width),C=l+f.height+y,B=b.rectangle(-w/2,-C/2,w,C,{...S,fill:"none",stroke:"none"}),R=p.insert(()=>$,":first-child"),j=p.insert(()=>B);if(t.img){let A=p.append("image");A.attr("href",t.img),A.attr("width",i),A.attr("height",l),A.attr("preserveAspectRatio","none"),A.attr("transform",`translate(${-i/2},${g?C/2-l:-C/2})`)}return m.attr("transform",`translate(${-f.width/2-(f.x-(f.left??0))},${g?-l/2-f.height/2-y/2:l/2-f.height/2+y/2})`),R.attr("transform",`translate(0,${g?f.height/2+y/2:-f.height/2-y/2})`),v(t,j),t.intersect=function(A){if(z.info("iconSquare intersect",t,A),!t.label)return N.rect(t,A);let O=t.x??0,W=t.y??0,G=t.height??0,L=[];return g?L=[{x:O-f.width/2,y:W-G/2},{x:O+f.width/2,y:W-G/2},{x:O+f.width/2,y:W-G/2+f.height+y},{x:O+i/2,y:W-G/2+f.height+y},{x:O+i/2,y:W+G/2},{x:O-i/2,y:W+G/2},{x:O-i/2,y:W-G/2+f.height+y},{x:O-f.width/2,y:W-G/2+f.height+y}]:L=[{x:O-i/2,y:W-G/2},{x:O+i/2,y:W-G/2},{x:O+i/2,y:W-G/2+l},{x:O+f.width/2,y:W-G/2+l},{x:O+f.width/2/2,y:W+G/2},{x:O-f.width/2,y:W+G/2},{x:O-f.width/2,y:W-G/2+l},{x:O-i/2,y:W-G/2+l}],N.polygon(t,L,A)},p}u(es,"imageSquare");async function ss(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=Math.max(a.width+(t.padding??0)*2,t?.width??0),e=Math.max(a.height+(t.padding??0)*2,t?.height??0),h=[{x:0,y:0},{x:c,y:0},{x:c+3*e/6,y:-e},{x:-3*e/6,y:-e}],i,{cssStyles:l}=t;if(t.look==="handDrawn"){let p=D.svg(s),f=M(t,{}),m=H(h),g=p.path(m,f);i=s.insert(()=>g,":first-child").attr("transform",`translate(${-c/2}, ${e/2})`),l&&i.attr("style",l)}else i=J(s,c,e,h);return r&&i.attr("style",r),t.width=c,t.height=e,v(t,i),t.intersect=function(p){return N.polygon(t,h,p)},s}u(ss,"inv_trapezoid");async function ft(n,t,o){let{labelStyles:r,nodeStyles:s}=k(t);t.labelStyle=r;let{shapeSvg:a,bbox:c}=await T(n,t,P(t)),e=Math.max(c.width+o.labelPaddingX*2,t?.width||0),h=Math.max(c.height+o.labelPaddingY*2,t?.height||0),i=-e/2,l=-h/2,p,{rx:f,ry:m}=t,{cssStyles:g}=t;if(o?.rx&&o.ry&&(f=o.rx,m=o.ry),t.look==="handDrawn"){let d=D.svg(a),x=M(t,{}),y=f||m?d.path(Q(i,l,e,h,f||0),x):d.rectangle(i,l,e,h,x);p=a.insert(()=>y,":first-child"),p.attr("class","basic label-container").attr("style",X(g))}else p=a.insert("rect",":first-child"),p.attr("class","basic label-container").attr("style",s).attr("rx",X(f)).attr("ry",X(m)).attr("x",i).attr("y",l).attr("width",e).attr("height",h);return v(t,p),t.intersect=function(d){return N.rect(t,d)},a}u(ft,"drawRect");async function rs(n,t){let{shapeSvg:o,bbox:r,label:s}=await T(n,t,"label"),a=o.insert("rect",":first-child");return a.attr("width",.1).attr("height",.1),o.attr("class","label edgeLabel"),s.attr("transform",`translate(${-(r.width/2)-(r.x-(r.left??0))}, ${-(r.height/2)-(r.y-(r.top??0))})`),v(t,a),t.intersect=function(h){return N.rect(t,h)},o}u(rs,"labelRect");async function os(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=Math.max(a.width+(t.padding??0),t?.width??0),e=Math.max(a.height+(t.padding??0),t?.height??0),h=[{x:0,y:0},{x:c+3*e/6,y:0},{x:c,y:-e},{x:-(3*e)/6,y:-e}],i,{cssStyles:l}=t;if(t.look==="handDrawn"){let p=D.svg(s),f=M(t,{}),m=H(h),g=p.path(m,f);i=s.insert(()=>g,":first-child").attr("transform",`translate(${-c/2}, ${e/2})`),l&&i.attr("style",l)}else i=J(s,c,e,h);return r&&i.attr("style",r),t.width=c,t.height=e,v(t,i),t.intersect=function(p){return N.polygon(t,h,p)},s}u(os,"lean_left");async function as(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=Math.max(a.width+(t.padding??0),t?.width??0),e=Math.max(a.height+(t.padding??0),t?.height??0),h=[{x:-3*e/6,y:0},{x:c,y:0},{x:c+3*e/6,y:-e},{x:0,y:-e}],i,{cssStyles:l}=t;if(t.look==="handDrawn"){let p=D.svg(s),f=M(t,{}),m=H(h),g=p.path(m,f);i=s.insert(()=>g,":first-child").attr("transform",`translate(${-c/2}, ${e/2})`),l&&i.attr("style",l)}else i=J(s,c,e,h);return r&&i.attr("style",r),t.width=c,t.height=e,v(t,i),t.intersect=function(p){return N.polygon(t,h,p)},s}u(as,"lean_right");function is(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.label="",t.labelStyle=o;let s=n.insert("g").attr("class",P(t)).attr("id",t.domId??t.id),{cssStyles:a}=t,c=Math.max(35,t?.width??0),e=Math.max(35,t?.height??0),h=7,i=[{x:c,y:0},{x:0,y:e+h/2},{x:c-2*h,y:e+h/2},{x:0,y:2*e},{x:c,y:e-h/2},{x:2*h,y:e-h/2}],l=D.svg(s),p=M(t,{});t.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let f=H(i),m=l.path(f,p),g=s.insert(()=>m,":first-child");return a&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",a),r&&t.look!=="handDrawn"&&g.selectAll("path").attr("style",r),g.attr("transform",`translate(-${c/2},${-e})`),v(t,g),t.intersect=function(d){return z.info("lightningBolt intersect",t,d),N.polygon(t,i,d)},s}u(is,"lightningBolt");var mr=u((n,t,o,r,s,a,c)=>[`M${n},${t+a}`,`a${s},${a} 0,0,0 ${o},0`,`a${s},${a} 0,0,0 ${-o},0`,`l0,${r}`,`a${s},${a} 0,0,0 ${o},0`,`l0,${-r}`,`M${n},${t+a+c}`,`a${s},${a} 0,0,0 ${o},0`].join(" "),"createCylinderPathD"),fr=u((n,t,o,r,s,a,c)=>[`M${n},${t+a}`,`M${n+o},${t+a}`,`a${s},${a} 0,0,0 ${-o},0`,`l0,${r}`,`a${s},${a} 0,0,0 ${o},0`,`l0,${-r}`,`M${n},${t+a+c}`,`a${s},${a} 0,0,0 ${o},0`].join(" "),"createOuterCylinderPathD"),gr=u((n,t,o,r,s,a)=>[`M${n-o/2},${-r/2}`,`a${s},${a} 0,0,0 ${o},0`].join(" "),"createInnerCylinderPathD");async function ns(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0),t.width??0),h=e/2,i=h/(2.5+e/50),l=Math.max(a.height+i+(t.padding??0),t.height??0),p=l*.1,f,{cssStyles:m}=t;if(t.look==="handDrawn"){let g=D.svg(s),d=fr(0,0,e,l,h,i,p),x=gr(0,i,e,l,h,i),y=M(t,{}),b=g.path(d,y),S=g.path(x,y);s.insert(()=>S,":first-child").attr("class","line"),f=s.insert(()=>b,":first-child"),f.attr("class","basic label-container"),m&&f.attr("style",m)}else{let g=mr(0,0,e,l,h,i,p);f=s.insert("path",":first-child").attr("d",g).attr("class","basic label-container").attr("style",X(m)).attr("style",r)}return f.attr("label-offset-y",i),f.attr("transform",`translate(${-e/2}, ${-(l/2+i)})`),v(t,f),c.attr("transform",`translate(${-(a.width/2)-(a.x-(a.left??0))}, ${-(a.height/2)+i-(a.y-(a.top??0))})`),t.intersect=function(g){let d=N.rect(t,g),x=d.x-(t.x??0);if(h!=0&&(Math.abs(x)<(t.width??0)/2||Math.abs(x)==(t.width??0)/2&&Math.abs(d.y-(t.y??0))>(t.height??0)/2-i)){let y=i*i*(1-x*x/(h*h));y>0&&(y=Math.sqrt(y)),y=i-y,g.y-(t.y??0)>0&&(y=-y),d.y+=y}return d},s}u(ns,"linedCylinder");async function ls(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=h/4,l=h+i,{cssStyles:p}=t,f=D.svg(s),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=[{x:-e/2-e/2*.1,y:-l/2},{x:-e/2-e/2*.1,y:l/2},...st(-e/2-e/2*.1,l/2,e/2+e/2*.1,l/2,i,.8),{x:e/2+e/2*.1,y:-l/2},{x:-e/2-e/2*.1,y:-l/2},{x:-e/2,y:-l/2},{x:-e/2,y:l/2*1.1},{x:-e/2,y:-l/2}],d=f.polygon(g.map(y=>[y.x,y.y]),m),x=s.insert(()=>d,":first-child");return x.attr("class","basic label-container"),p&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",p),r&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",r),x.attr("transform",`translate(0,${-i/2})`),c.attr("transform",`translate(${-e/2+(t.padding??0)+e/2*.1/2-(a.x-(a.left??0))},${-h/2+(t.padding??0)-i/2-(a.y-(a.top??0))})`),v(t,x),t.intersect=function(y){return N.polygon(t,g,y)},s}u(ls,"linedWaveEdgedRect");async function cs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=5,l=-e/2,p=-h/2,{cssStyles:f}=t,m=D.svg(s),g=M(t,{}),d=[{x:l-i,y:p+i},{x:l-i,y:p+h+i},{x:l+e-i,y:p+h+i},{x:l+e-i,y:p+h},{x:l+e,y:p+h},{x:l+e,y:p+h-i},{x:l+e+i,y:p+h-i},{x:l+e+i,y:p-i},{x:l+i,y:p-i},{x:l+i,y:p},{x:l,y:p},{x:l,y:p+i}],x=[{x:l,y:p+i},{x:l+e-i,y:p+i},{x:l+e-i,y:p+h},{x:l+e,y:p+h},{x:l+e,y:p},{x:l,y:p}];t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let y=H(d),b=m.path(y,g),S=H(x),$=m.path(S,{...g,fill:"none"}),w=s.insert(()=>$,":first-child");return w.insert(()=>b,":first-child"),w.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",f),r&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",r),c.attr("transform",`translate(${-(a.width/2)-i-(a.x-(a.left??0))}, ${-(a.height/2)+i-(a.y-(a.top??0))})`),v(t,w),t.intersect=function(C){return N.polygon(t,d,C)},s}u(cs,"multiRect");async function hs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=h/4,l=h+i,p=-e/2,f=-l/2,m=5,{cssStyles:g}=t,d=st(p-m,f+l+m,p+e-m,f+l+m,i,.8),x=d?.[d.length-1],y=[{x:p-m,y:f+m},{x:p-m,y:f+l+m},...d,{x:p+e-m,y:x.y-m},{x:p+e,y:x.y-m},{x:p+e,y:x.y-2*m},{x:p+e+m,y:x.y-2*m},{x:p+e+m,y:f-m},{x:p+m,y:f-m},{x:p+m,y:f},{x:p,y:f},{x:p,y:f+m}],b=[{x:p,y:f+m},{x:p+e-m,y:f+m},{x:p+e-m,y:x.y-m},{x:p+e,y:x.y-m},{x:p+e,y:f},{x:p,y:f}],S=D.svg(s),$=M(t,{});t.look!=="handDrawn"&&($.roughness=0,$.fillStyle="solid");let w=H(y),C=S.path(w,$),B=H(b),R=S.path(B,$),j=s.insert(()=>C,":first-child");return j.insert(()=>R),j.attr("class","basic label-container"),g&&t.look!=="handDrawn"&&j.selectAll("path").attr("style",g),r&&t.look!=="handDrawn"&&j.selectAll("path").attr("style",r),j.attr("transform",`translate(0,${-i/2})`),c.attr("transform",`translate(${-(a.width/2)-m-(a.x-(a.left??0))}, ${-(a.height/2)+m-i/2-(a.y-(a.top??0))})`),v(t,j),t.intersect=function(A){return N.polygon(t,y,A)},s}u(hs,"multiWaveEdgedRectangle");async function ps(n,t,{config:{themeVariables:o}}){let{labelStyles:r,nodeStyles:s}=k(t);t.labelStyle=r,t.useHtmlLabels||wt().flowchart?.htmlLabels!==!1||(t.centerLabel=!0);let{shapeSvg:c,bbox:e}=await T(n,t,P(t)),h=Math.max(e.width+(t.padding??0)*2,t?.width??0),i=Math.max(e.height+(t.padding??0)*2,t?.height??0),l=-h/2,p=-i/2,{cssStyles:f}=t,m=D.svg(c),g=M(t,{fill:o.noteBkgColor,stroke:o.noteBorderColor});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let d=m.rectangle(l,p,h,i,g),x=c.insert(()=>d,":first-child");return x.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",f),s&&t.look!=="handDrawn"&&x.selectAll("path").attr("style",s),v(t,x),t.intersect=function(y){return N.rect(t,y)},c}u(ps,"note");var dr=u((n,t,o)=>[`M${n+o/2},${t}`,`L${n+o},${t-o/2}`,`L${n+o/2},${t-o}`,`L${n},${t-o/2}`,"Z"].join(" "),"createDecisionBoxPathD");async function ms(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=a.width+t.padding,e=a.height+t.padding,h=c+e,i=[{x:h/2,y:0},{x:h,y:-h/2},{x:h/2,y:-h},{x:0,y:-h/2}],l,{cssStyles:p}=t;if(t.look==="handDrawn"){let f=D.svg(s),m=M(t,{}),g=dr(0,0,h),d=f.path(g,m);l=s.insert(()=>d,":first-child").attr("transform",`translate(${-h/2}, ${h/2})`),p&&l.attr("style",p)}else l=J(s,h,h,i);return r&&l.attr("style",r),v(t,l),t.intersect=function(f){return z.debug(`APA12 Intersect called SPLIT +point:`,f,` +node: +`,t,` +res:`,N.polygon(t,i,f)),N.polygon(t,i,f)},s}u(ms,"question");async function fs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0),t?.width??0),h=Math.max(a.height+(t.padding??0),t?.height??0),i=-e/2,l=-h/2,p=l/2,f=[{x:i+p,y:l},{x:i,y:0},{x:i+p,y:-l},{x:-i,y:-l},{x:-i,y:l}],{cssStyles:m}=t,g=D.svg(s),d=M(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");let x=H(f),y=g.path(x,d),b=s.insert(()=>y,":first-child");return b.attr("class","basic label-container"),m&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",m),r&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",r),b.attr("transform",`translate(${-p/2},0)`),c.attr("transform",`translate(${-p/2-a.width/2-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),v(t,b),t.intersect=function(S){return N.polygon(t,f,S)},s}u(fs,"rect_left_inv_arrow");async function gs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let s;t.cssClasses?s="node "+t.cssClasses:s="node default";let a=n.insert("g").attr("class",s).attr("id",t.domId||t.id),c=a.insert("g"),e=a.insert("g").attr("class","label").attr("style",r),h=t.description,i=t.label,l=e.node().appendChild(await St(i,t.labelStyle,!0,!0)),p={width:0,height:0};if(Y(q()?.flowchart?.htmlLabels)){let R=l.children[0],j=Z(l);p=R.getBoundingClientRect(),j.attr("width",p.width),j.attr("height",p.height)}z.info("Text 2",h);let f=h||[],m=l.getBBox(),g=e.node().appendChild(await St(f.join?f.join("
    "):f,t.labelStyle,!0,!0)),d=g.children[0],x=Z(g);p=d.getBoundingClientRect(),x.attr("width",p.width),x.attr("height",p.height);let y=(t.padding||0)/2;Z(g).attr("transform","translate( "+(p.width>m.width?0:(m.width-p.width)/2)+", "+(m.height+y+5)+")"),Z(l).attr("transform","translate( "+(p.width(z.debug("Rough node insert CXC",A),O),":first-child"),C=a.insert(()=>(z.debug("Rough node insert CXC",A),A),":first-child")}else C=c.insert("rect",":first-child"),B=c.insert("line"),C.attr("class","outer title-state").attr("style",r).attr("x",-p.width/2-y).attr("y",-p.height/2-y).attr("width",p.width+(t.padding||0)).attr("height",p.height+(t.padding||0)),B.attr("class","divider").attr("x1",-p.width/2-y).attr("x2",p.width/2+y).attr("y1",-p.height/2-y+m.height+y).attr("y2",-p.height/2-y+m.height+y);return v(t,C),t.intersect=function(R){return N.rect(t,R)},a}u(gs,"rectWithTitle");async function ds(n,t){let o={rx:5,ry:5,classes:"",labelPaddingX:(t?.padding||0)*1,labelPaddingY:(t?.padding||0)*1};return ft(n,t,o)}u(ds,"roundedRect");async function us(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=t?.padding??0,h=Math.max(a.width+(t.padding??0)*2,t?.width??0),i=Math.max(a.height+(t.padding??0)*2,t?.height??0),l=-a.width/2-e,p=-a.height/2-e,{cssStyles:f}=t,m=D.svg(s),g=M(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let d=[{x:l,y:p},{x:l+h+8,y:p},{x:l+h+8,y:p+i},{x:l-8,y:p+i},{x:l-8,y:p},{x:l,y:p},{x:l,y:p+i}],x=m.polygon(d.map(b=>[b.x,b.y]),g),y=s.insert(()=>x,":first-child");return y.attr("class","basic label-container").attr("style",X(f)),r&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",r),f&&t.look!=="handDrawn"&&y.selectAll("path").attr("style",r),c.attr("transform",`translate(${-h/2+4+(t.padding??0)-(a.x-(a.left??0))},${-i/2+(t.padding??0)-(a.y-(a.top??0))})`),v(t,y),t.intersect=function(b){return N.rect(t,b)},s}u(us,"shadedProcess");async function ys(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=-e/2,l=-h/2,{cssStyles:p}=t,f=D.svg(s),m=M(t,{});t.look!=="handDrawn"&&(m.roughness=0,m.fillStyle="solid");let g=[{x:i,y:l},{x:i,y:l+h},{x:i+e,y:l+h},{x:i+e,y:l-h/2}],d=H(g),x=f.path(d,m),y=s.insert(()=>x,":first-child");return y.attr("class","basic label-container"),p&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",p),r&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",r),y.attr("transform",`translate(0, ${h/4})`),c.attr("transform",`translate(${-e/2+(t.padding??0)-(a.x-(a.left??0))}, ${-h/4+(t.padding??0)-(a.y-(a.top??0))})`),v(t,y),t.intersect=function(b){return N.polygon(t,g,b)},s}u(ys,"slopedRect");async function xs(n,t){let o={rx:0,ry:0,classes:"",labelPaddingX:(t?.padding||0)*2,labelPaddingY:(t?.padding||0)*1};return ft(n,t,o)}u(xs,"squareRect");async function bs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=a.height+t.padding,e=a.width+c/4+t.padding,h,{cssStyles:i}=t;if(t.look==="handDrawn"){let l=D.svg(s),p=M(t,{}),f=Q(-e/2,-c/2,e,c,c/2),m=l.path(f,p);h=s.insert(()=>m,":first-child"),h.attr("class","basic label-container").attr("style",X(i))}else h=s.insert("rect",":first-child"),h.attr("class","basic label-container").attr("style",r).attr("rx",c/2).attr("ry",c/2).attr("x",-e/2).attr("y",-c/2).attr("width",e).attr("height",c);return v(t,h),t.intersect=function(l){return N.rect(t,l)},s}u(bs,"stadium");async function Ss(n,t){return ft(n,t,{rx:5,ry:5,classes:"flowchart-node"})}u(Ss,"state");function ws(n,t,{config:{themeVariables:o}}){let{labelStyles:r,nodeStyles:s}=k(t);t.labelStyle=r;let{cssStyles:a}=t,{lineColor:c,stateBorder:e,nodeBorder:h}=o,i=n.insert("g").attr("class","node default").attr("id",t.domId||t.id),l=D.svg(i),p=M(t,{});t.look!=="handDrawn"&&(p.roughness=0,p.fillStyle="solid");let f=l.circle(0,0,14,{...p,stroke:c,strokeWidth:2}),m=e??h,g=l.circle(0,0,5,{...p,fill:m,stroke:m,strokeWidth:2,fillStyle:"solid"}),d=i.insert(()=>f,":first-child");return d.insert(()=>g),a&&d.selectAll("path").attr("style",a),s&&d.selectAll("path").attr("style",s),v(t,d),t.intersect=function(x){return N.circle(t,7,x)},i}u(ws,"stateEnd");function Ns(n,t,{config:{themeVariables:o}}){let{lineColor:r}=o,s=n.insert("g").attr("class","node default").attr("id",t.domId||t.id),a;if(t.look==="handDrawn"){let e=D.svg(s).circle(0,0,14,De(r));a=s.insert(()=>e),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14)}else a=s.insert("circle",":first-child"),a.attr("class","state-start").attr("r",7).attr("width",14).attr("height",14);return v(t,a),t.intersect=function(c){return N.circle(t,7,c)},s}u(Ns,"stateStart");async function Ds(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=(t?.padding||0)/2,e=a.width+t.padding,h=a.height+t.padding,i=-a.width/2-c,l=-a.height/2-c,p=[{x:0,y:0},{x:e,y:0},{x:e,y:-h},{x:0,y:-h},{x:0,y:0},{x:-8,y:0},{x:e+8,y:0},{x:e+8,y:-h},{x:-8,y:-h},{x:-8,y:0}];if(t.look==="handDrawn"){let f=D.svg(s),m=M(t,{}),g=f.rectangle(i-8,l,e+16,h,m),d=f.line(i,l,i,l+h,m),x=f.line(i+e,l,i+e,l+h,m);s.insert(()=>d,":first-child"),s.insert(()=>x,":first-child");let y=s.insert(()=>g,":first-child"),{cssStyles:b}=t;y.attr("class","basic label-container").attr("style",X(b)),v(t,y)}else{let f=J(s,e,h,p);r&&f.attr("style",r),v(t,f)}return t.intersect=function(f){return N.polygon(t,p,f)},s}u(Ds,"subroutine");async function Ms(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=Math.max(a.width+(t.padding??0)*2,t?.width??0),e=Math.max(a.height+(t.padding??0)*2,t?.height??0),h=-c/2,i=-e/2,l=.2*e,p=.2*e,{cssStyles:f}=t,m=D.svg(s),g=M(t,{}),d=[{x:h-l/2,y:i},{x:h+c+l/2,y:i},{x:h+c+l/2,y:i+e},{x:h-l/2,y:i+e}],x=[{x:h+c-l/2,y:i+e},{x:h+c+l/2,y:i+e},{x:h+c+l/2,y:i+e-p}];t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let y=H(d),b=m.path(y,g),S=H(x),$=m.path(S,{...g,fillStyle:"solid"}),w=s.insert(()=>$,":first-child");return w.insert(()=>b,":first-child"),w.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",f),r&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",r),v(t,w),t.intersect=function(C){return N.polygon(t,d,C)},s}u(Ms,"taggedRect");async function vs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=h/4,l=.2*e,p=.2*h,f=h+i,{cssStyles:m}=t,g=D.svg(s),d=M(t,{});t.look!=="handDrawn"&&(d.roughness=0,d.fillStyle="solid");let x=[{x:-e/2-e/2*.1,y:f/2},...st(-e/2-e/2*.1,f/2,e/2+e/2*.1,f/2,i,.8),{x:e/2+e/2*.1,y:-f/2},{x:-e/2-e/2*.1,y:-f/2}],y=-e/2+e/2*.1,b=-f/2-p*.4,S=[{x:y+e-l,y:(b+h)*1.4},{x:y+e,y:b+h-p},{x:y+e,y:(b+h)*.9},...st(y+e,(b+h)*1.3,y+e-l,(b+h)*1.5,-h*.03,.5)],$=H(x),w=g.path($,d),C=H(S),B=g.path(C,{...d,fillStyle:"solid"}),R=s.insert(()=>B,":first-child");return R.insert(()=>w,":first-child"),R.attr("class","basic label-container"),m&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",m),r&&t.look!=="handDrawn"&&R.selectAll("path").attr("style",r),R.attr("transform",`translate(0,${-i/2})`),c.attr("transform",`translate(${-e/2+(t.padding??0)-(a.x-(a.left??0))},${-h/2+(t.padding??0)-i/2-(a.y-(a.top??0))})`),v(t,R),t.intersect=function(j){return N.polygon(t,x,j)},s}u(vs,"taggedWaveEdgedRectangle");async function ks(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=Math.max(a.width+t.padding,t?.width||0),e=Math.max(a.height+t.padding,t?.height||0),h=-c/2,i=-e/2,l=s.insert("rect",":first-child");return l.attr("class","text").attr("style",r).attr("rx",0).attr("ry",0).attr("x",h).attr("y",i).attr("width",c).attr("height",e),v(t,l),t.intersect=function(p){return N.rect(t,p)},s}u(ks,"text");var ur=u((n,t,o,r,s,a)=>`M${n},${t} + a${s},${a} 0,0,1 0,${-r} + l${o},0 + a${s},${a} 0,0,1 0,${r} + M${o},${-r} + a${s},${a} 0,0,0 0,${r} + l${-o},0`,"createCylinderPathD"),yr=u((n,t,o,r,s,a)=>[`M${n},${t}`,`M${n+o},${t}`,`a${s},${a} 0,0,0 0,${-r}`,`l${-o},0`,`a${s},${a} 0,0,0 0,${r}`,`l${o},0`].join(" "),"createOuterCylinderPathD"),xr=u((n,t,o,r,s,a)=>[`M${n+o/2},${-r/2}`,`a${s},${a} 0,0,0 0,${r}`].join(" "),"createInnerCylinderPathD");async function $s(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c,halfPadding:e}=await T(n,t,P(t)),h=t.look==="neo"?e*2:e,i=a.height+h,l=i/2,p=l/(2.5+i/50),f=a.width+p+h,{cssStyles:m}=t,g;if(t.look==="handDrawn"){let d=D.svg(s),x=yr(0,0,f,i,p,l),y=xr(0,0,f,i,p,l),b=d.path(x,M(t,{})),S=d.path(y,M(t,{fill:"none"}));g=s.insert(()=>S,":first-child"),g=s.insert(()=>b,":first-child"),g.attr("class","basic label-container"),m&&g.attr("style",m)}else{let d=ur(0,0,f,i,p,l);g=s.insert("path",":first-child").attr("d",d).attr("class","basic label-container").attr("style",X(m)).attr("style",r),g.attr("class","basic label-container"),m&&g.selectAll("path").attr("style",m),r&&g.selectAll("path").attr("style",r)}return g.attr("label-offset-x",p),g.attr("transform",`translate(${-f/2}, ${i/2} )`),c.attr("transform",`translate(${-(a.width/2)-p-(a.x-(a.left??0))}, ${-(a.height/2)-(a.y-(a.top??0))})`),v(t,g),t.intersect=function(d){let x=N.rect(t,d),y=x.y-(t.y??0);if(l!=0&&(Math.abs(y)<(t.height??0)/2||Math.abs(y)==(t.height??0)/2&&Math.abs(x.x-(t.x??0))>(t.width??0)/2-p)){let b=p*p*(1-y*y/(l*l));b!=0&&(b=Math.sqrt(Math.abs(b))),b=p-b,d.x-(t.x??0)>0&&(b=-b),x.x+=b}return x},s}u($s,"tiltedCylinder");async function Ps(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=a.width+t.padding,e=a.height+t.padding,h=[{x:-3*e/6,y:0},{x:c+3*e/6,y:0},{x:c,y:-e},{x:0,y:-e}],i,{cssStyles:l}=t;if(t.look==="handDrawn"){let p=D.svg(s),f=M(t,{}),m=H(h),g=p.path(m,f);i=s.insert(()=>g,":first-child").attr("transform",`translate(${-c/2}, ${e/2})`),l&&i.attr("style",l)}else i=J(s,c,e,h);return r&&i.attr("style",r),t.width=c,t.height=e,v(t,i),t.intersect=function(p){return N.polygon(t,h,p)},s}u(Ps,"trapezoid");async function Ts(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=60,e=20,h=Math.max(c,a.width+(t.padding??0)*2,t?.width??0),i=Math.max(e,a.height+(t.padding??0)*2,t?.height??0),{cssStyles:l}=t,p=D.svg(s),f=M(t,{});t.look!=="handDrawn"&&(f.roughness=0,f.fillStyle="solid");let m=[{x:-h/2*.8,y:-i/2},{x:h/2*.8,y:-i/2},{x:h/2,y:-i/2*.6},{x:h/2,y:i/2},{x:-h/2,y:i/2},{x:-h/2,y:-i/2*.6}],g=H(m),d=p.path(g,f),x=s.insert(()=>d,":first-child");return x.attr("class","basic label-container"),l&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",l),r&&t.look!=="handDrawn"&&x.selectChildren("path").attr("style",r),v(t,x),t.intersect=function(y){return N.polygon(t,m,y)},s}u(Ts,"trapezoidalPentagon");async function Cs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Y(q().flowchart?.htmlLabels),h=a.width+(t.padding??0),i=h+a.height,l=h+a.height,p=[{x:0,y:0},{x:l,y:0},{x:l/2,y:-i}],{cssStyles:f}=t,m=D.svg(s),g=M(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let d=H(p),x=m.path(d,g),y=s.insert(()=>x,":first-child").attr("transform",`translate(${-i/2}, ${i/2})`);return f&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",f),r&&t.look!=="handDrawn"&&y.selectChildren("path").attr("style",r),t.width=h,t.height=i,v(t,y),c.attr("transform",`translate(${-a.width/2-(a.x-(a.left??0))}, ${i/2-(a.height+(t.padding??0)/(e?2:1)-(a.y-(a.top??0)))})`),t.intersect=function(b){return z.info("Triangle intersect",t,p,b),N.polygon(t,p,b)},s}u(Cs,"triangle");async function Bs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=h/8,l=h+i,{cssStyles:p}=t,m=70-e,g=m>0?m/2:0,d=D.svg(s),x=M(t,{});t.look!=="handDrawn"&&(x.roughness=0,x.fillStyle="solid");let y=[{x:-e/2-g,y:l/2},...st(-e/2-g,l/2,e/2+g,l/2,i,.8),{x:e/2+g,y:-l/2},{x:-e/2-g,y:-l/2}],b=H(y),S=d.path(b,x),$=s.insert(()=>S,":first-child");return $.attr("class","basic label-container"),p&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",p),r&&t.look!=="handDrawn"&&$.selectAll("path").attr("style",r),$.attr("transform",`translate(0,${-i/2})`),c.attr("transform",`translate(${-e/2+(t.padding??0)-(a.x-(a.left??0))},${-h/2+(t.padding??0)-i-(a.y-(a.top??0))})`),v(t,$),t.intersect=function(w){return N.polygon(t,y,w)},s}u(Bs,"waveEdgedRectangle");async function Rs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a}=await T(n,t,P(t)),c=100,e=50,h=Math.max(a.width+(t.padding??0)*2,t?.width??0),i=Math.max(a.height+(t.padding??0)*2,t?.height??0),l=h/i,p=h,f=i;p>f*l?f=p/l:p=f*l,p=Math.max(p,c),f=Math.max(f,e);let m=Math.min(f*.2,f/4),g=f+m*2,{cssStyles:d}=t,x=D.svg(s),y=M(t,{});t.look!=="handDrawn"&&(y.roughness=0,y.fillStyle="solid");let b=[{x:-p/2,y:g/2},...st(-p/2,g/2,p/2,g/2,m,1),{x:p/2,y:-g/2},...st(p/2,-g/2,-p/2,-g/2,m,-1)],S=H(b),$=x.path(S,y),w=s.insert(()=>$,":first-child");return w.attr("class","basic label-container"),d&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",d),r&&t.look!=="handDrawn"&&w.selectAll("path").attr("style",r),v(t,w),t.intersect=function(C){return N.polygon(t,b,C)},s}u(Rs,"waveRectangle");async function Gs(n,t){let{labelStyles:o,nodeStyles:r}=k(t);t.labelStyle=o;let{shapeSvg:s,bbox:a,label:c}=await T(n,t,P(t)),e=Math.max(a.width+(t.padding??0)*2,t?.width??0),h=Math.max(a.height+(t.padding??0)*2,t?.height??0),i=5,l=-e/2,p=-h/2,{cssStyles:f}=t,m=D.svg(s),g=M(t,{}),d=[{x:l-i,y:p-i},{x:l-i,y:p+h},{x:l+e,y:p+h},{x:l+e,y:p-i}],x=`M${l-i},${p-i} L${l+e},${p-i} L${l+e},${p+h} L${l-i},${p+h} L${l-i},${p-i} + M${l-i},${p} L${l+e},${p} + M${l},${p-i} L${l},${p+h}`;t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let y=m.path(x,g),b=s.insert(()=>y,":first-child");return b.attr("transform",`translate(${i/2}, ${i/2})`),b.attr("class","basic label-container"),f&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",f),r&&t.look!=="handDrawn"&&b.selectAll("path").attr("style",r),c.attr("transform",`translate(${-(a.width/2)+i/2-(a.x-(a.left??0))}, ${-(a.height/2)+i/2-(a.y-(a.top??0))})`),v(t,b),t.intersect=function(S){return N.polygon(t,d,S)},s}u(Gs,"windowPane");async function js(n,t,o,r,s=o.class.padding??12){let a=r?0:3,c=n.insert("g").attr("class",P(t)).attr("id",t.domId||t.id),e=null,h=null,i=null,l=null,p=0,f=0,m=0;if(e=c.insert("g").attr("class","annotation-group text"),t.annotations.length>0){let b=t.annotations[0];await Et(e,{text:`\xAB${b}\xBB`},0),p=e.node().getBBox().height}h=c.insert("g").attr("class","label-group text"),await Et(h,t,0,["font-weight: bolder"]);let g=h.node().getBBox();f=g.height,i=c.insert("g").attr("class","members-group text");let d=0;for(let b of t.members){let S=await Et(i,b,d,[b.parseClassifier()]);d+=S+a}m=i.node().getBBox().height,m<=0&&(m=s/2),l=c.insert("g").attr("class","methods-group text");let x=0;for(let b of t.methods){let S=await Et(l,b,x,[b.parseClassifier()]);x+=S+a}let y=c.node().getBBox();if(e!==null){let b=e.node().getBBox();e.attr("transform",`translate(${-b.width/2})`)}return h.attr("transform",`translate(${-g.width/2}, ${p})`),y=c.node().getBBox(),i.attr("transform",`translate(0, ${p+f+s*2})`),y=c.node().getBBox(),l.attr("transform",`translate(0, ${p+f+(m?m+s*4:s*2)})`),y=c.node().getBBox(),{shapeSvg:c,bbox:y}}u(js,"textHelper");async function Et(n,t,o,r=[]){let s=n.insert("g").attr("class","label").attr("style",r.join("; ")),a=wt(),c="useHtmlLabels"in t?t.useHtmlLabels:Y(a.htmlLabels)??!0,e="";"text"in t?e=t.text:e=t.label,!c&&e.startsWith("\\")&&(e=e.substring(1)),Nt(e)&&(c=!0);let h=await it(s,ie(pt(e)),{width:ne(e,a)+50,classes:"markdown-node-label",useHtmlLabels:c},a),i,l=1;if(c){let p=h.children[0],f=Z(h);l=p.innerHTML.split("
    ").length,p.innerHTML.includes("")&&(l+=p.innerHTML.split("").length-1);let m=p.getElementsByTagName("img");if(m){let g=e.replace(/]*>/g,"").trim()==="";await Promise.all([...m].map(d=>new Promise(x=>{function y(){if(d.style.display="flex",d.style.flexDirection="column",g){let b=a.fontSize?.toString()??window.getComputedStyle(document.body).fontSize,$=parseInt(b,10)*5+"px";d.style.minWidth=$,d.style.maxWidth=$}else d.style.width="100%";x(d)}u(y,"setupImage"),setTimeout(()=>{d.complete&&y()}),d.addEventListener("error",y),d.addEventListener("load",y)})))}i=p.getBoundingClientRect(),f.attr("width",i.width),f.attr("height",i.height)}else{r.includes("font-weight: bolder")&&Z(h).selectAll("tspan").attr("font-weight",""),l=h.children.length;let p=h.children[0];(h.textContent===""||h.textContent.includes(">"))&&(p.textContent=e[0]+e.substring(1).replaceAll(">",">").replaceAll("<","<").trim(),e[1]===" "&&(p.textContent=p.textContent[0]+" "+p.textContent.substring(1))),p.textContent==="undefined"&&(p.textContent=""),i=h.getBBox()}return s.attr("transform","translate(0,"+(-i.height/(2*l)+o)+")"),i.height}u(Et,"addText");async function Es(n,t){let o=q(),r=o.class.padding??12,s=r,a=t.useHtmlLabels??Y(o.htmlLabels)??!0,c=t;c.annotations=c.annotations??[],c.members=c.members??[],c.methods=c.methods??[];let{shapeSvg:e,bbox:h}=await js(n,t,o,a,s),{labelStyles:i,nodeStyles:l}=k(t);t.labelStyle=i,t.cssStyles=c.styles||"";let p=c.styles?.join(";")||l||"";t.cssStyles||(t.cssStyles=p.replaceAll("!important","").split(";"));let f=c.members.length===0&&c.methods.length===0&&!o.class?.hideEmptyMembersBox,m=D.svg(e),g=M(t,{});t.look!=="handDrawn"&&(g.roughness=0,g.fillStyle="solid");let d=h.width,x=h.height;c.members.length===0&&c.methods.length===0?x+=s:c.members.length>0&&c.methods.length===0&&(x+=s*2);let y=-d/2,b=-x/2,S=m.rectangle(y-r,b-r-(f?r:c.members.length===0&&c.methods.length===0?-r/2:0),d+2*r,x+2*r+(f?r*2:c.members.length===0&&c.methods.length===0?-r:0),g),$=e.insert(()=>S,":first-child");$.attr("class","basic label-container");let w=$.node().getBBox();e.selectAll(".text").each((j,A,O)=>{let W=Z(O[A]),G=W.attr("transform"),L=0;if(G){let _=RegExp(/translate\(([^,]+),([^)]+)\)/).exec(G);_&&(L=parseFloat(_[2]))}let V=L+b+r-(f?r:c.members.length===0&&c.methods.length===0?-r/2:0);a||(V-=4);let E=y;(W.attr("class").includes("label-group")||W.attr("class").includes("annotation-group"))&&(E=-W.node()?.getBBox().width/2||0,e.selectAll("text").each(function(I,_,U){window.getComputedStyle(U[_]).textAnchor==="middle"&&(E=0)})),W.attr("transform",`translate(${E}, ${V})`)});let C=e.select(".annotation-group").node().getBBox().height-(f?r/2:0)||0,B=e.select(".label-group").node().getBBox().height-(f?r/2:0)||0,R=e.select(".members-group").node().getBBox().height-(f?r/2:0)||0;if(c.members.length>0||c.methods.length>0||f){let j=m.line(w.x,C+B+b+r,w.x+w.width,C+B+b+r,g);e.insert(()=>j).attr("class","divider").attr("style",p)}if(f||c.members.length>0||c.methods.length>0){let j=m.line(w.x,C+B+R+b+s*2+r,w.x+w.width,C+B+R+b+r+s*2,g);e.insert(()=>j).attr("class","divider").attr("style",p)}if(c.look!=="handDrawn"&&e.selectAll("path").attr("style",p),$.select(":nth-child(2)").attr("style",p),e.selectAll(".divider").select("path").attr("style",p),t.labelStyle?e.selectAll("span").attr("style",t.labelStyle):e.selectAll("span").attr("style",p),!a){let j=RegExp(/color\s*:\s*([^;]*)/),A=j.exec(p);if(A){let O=A[0].replace("color","fill");e.selectAll("tspan").attr("style",O)}else if(i){let O=j.exec(i);if(O){let W=O[0].replace("color","fill");e.selectAll("tspan").attr("style",W)}}}return v(t,$),t.intersect=function(j){return N.rect(t,j)},e}u(Es,"classBox");var br=u(n=>{switch(n){case"Very High":return"red";case"High":return"orange";case"Medium":return null;case"Low":return"blue";case"Very Low":return"lightblue"}},"colorFromPriority");async function As(n,t,{config:o}){let{labelStyles:r,nodeStyles:s}=k(t);t.labelStyle=r||"";let a=10,c=t.width;t.width=(t.width??200)-10;let{shapeSvg:e,bbox:h,label:i}=await T(n,t,P(t)),l=t.padding||10,p="",f;"ticket"in t&&t.ticket&&o?.kanban?.ticketBaseUrl&&(p=o?.kanban?.ticketBaseUrl.replace("#TICKET#",t.ticket),f=e.insert("svg:a",":first-child").attr("class","kanban-ticket-link").attr("xlink:href",p).attr("target","_blank"));let m={useHtmlLabels:t.useHtmlLabels,labelStyle:t.labelStyle||"",width:t.width,img:t.img,padding:t.padding||8,centerLabel:!1},g,d;f?{label:g,bbox:d}=await Dt(f,"ticket"in t&&t.ticket||"",m):{label:g,bbox:d}=await Dt(e,"ticket"in t&&t.ticket||"",m);let{label:x,bbox:y}=await Dt(e,"assigned"in t&&t.assigned||"",m);t.width=c;let b=10,S=t?.width||0,$=Math.max(d.height,y.height)/2,w=Math.max(h.height+b*2,t?.height||0)+$,C=-S/2,B=-w/2;i.attr("transform","translate("+(l-S/2)+", "+(-$-h.height/2)+")"),g.attr("transform","translate("+(l-S/2)+", "+(-$+h.height/2)+")"),x.attr("transform","translate("+(l+S/2-y.width-2*a)+", "+(-$+h.height/2)+")");let R,{rx:j,ry:A}=t,{cssStyles:O}=t;if(t.look==="handDrawn"){let W=D.svg(e),G=M(t,{}),L=j||A?W.path(Q(C,B,S,w,j||0),G):W.rectangle(C,B,S,w,G);R=e.insert(()=>L,":first-child"),R.attr("class","basic label-container").attr("style",O||null)}else{R=e.insert("rect",":first-child"),R.attr("class","basic label-container __APA__").attr("style",s).attr("rx",j??5).attr("ry",A??5).attr("x",C).attr("y",B).attr("width",S).attr("height",w);let W="priority"in t&&t.priority;if(W){let G=e.append("line"),L=C+2,V=B+Math.floor((j??0)/2),E=B+w-Math.floor((j??0)/2);G.attr("x1",L).attr("y1",V).attr("x2",L).attr("y2",E).attr("stroke-width","4").attr("stroke",br(W))}}return v(t,R),t.height=w,t.intersect=function(W){return N.rect(t,W)},e}u(As,"kanbanItem");var Sr=[{semanticName:"Process",name:"Rectangle",shortName:"rect",description:"Standard process shape",aliases:["proc","process","rectangle"],internalAliases:["squareRect"],handler:xs},{semanticName:"Event",name:"Rounded Rectangle",shortName:"rounded",description:"Represents an event",aliases:["event"],internalAliases:["roundedRect"],handler:ds},{semanticName:"Terminal Point",name:"Stadium",shortName:"stadium",description:"Terminal point",aliases:["terminal","pill"],handler:bs},{semanticName:"Subprocess",name:"Framed Rectangle",shortName:"fr-rect",description:"Subprocess",aliases:["subprocess","subproc","framed-rectangle","subroutine"],handler:Ds},{semanticName:"Database",name:"Cylinder",shortName:"cyl",description:"Database storage",aliases:["db","database","cylinder"],handler:Ie},{semanticName:"Start",name:"Circle",shortName:"circle",description:"Starting point",aliases:["circ"],handler:Ae},{semanticName:"Decision",name:"Diamond",shortName:"diam",description:"Decision-making step",aliases:["decision","diamond","question"],handler:ms},{semanticName:"Prepare Conditional",name:"Hexagon",shortName:"hex",description:"Preparation or condition step",aliases:["hexagon","prepare"],handler:Ze},{semanticName:"Data Input/Output",name:"Lean Right",shortName:"lean-r",description:"Represents input or output",aliases:["lean-right","in-out"],internalAliases:["lean_right"],handler:as},{semanticName:"Data Input/Output",name:"Lean Left",shortName:"lean-l",description:"Represents output or input",aliases:["lean-left","out-in"],internalAliases:["lean_left"],handler:os},{semanticName:"Priority Action",name:"Trapezoid Base Bottom",shortName:"trap-b",description:"Priority action",aliases:["priority","trapezoid-bottom","trapezoid"],handler:Ps},{semanticName:"Manual Operation",name:"Trapezoid Base Top",shortName:"trap-t",description:"Represents a manual task",aliases:["manual","trapezoid-top","inv-trapezoid"],internalAliases:["inv_trapezoid"],handler:ss},{semanticName:"Stop",name:"Double Circle",shortName:"dbl-circ",description:"Represents a stop point",aliases:["double-circle"],internalAliases:["doublecircle"],handler:_e},{semanticName:"Text Block",name:"Text Block",shortName:"text",description:"Text block",handler:ks},{semanticName:"Card",name:"Notched Rectangle",shortName:"notch-rect",description:"Represents a card",aliases:["card","notched-rectangle"],handler:je},{semanticName:"Lined/Shaded Process",name:"Lined Rectangle",shortName:"lin-rect",description:"Lined process shape",aliases:["lined-rectangle","lined-process","lin-proc","shaded-process"],handler:us},{semanticName:"Start",name:"Small Circle",shortName:"sm-circ",description:"Small starting point",aliases:["start","small-circle"],internalAliases:["stateStart"],handler:Ns},{semanticName:"Stop",name:"Framed Circle",shortName:"fr-circ",description:"Stop point",aliases:["stop","framed-circle"],internalAliases:["stateEnd"],handler:ws},{semanticName:"Fork/Join",name:"Filled Rectangle",shortName:"fork",description:"Fork or join in process flow",aliases:["join"],internalAliases:["forkJoin"],handler:Xe},{semanticName:"Collate",name:"Hourglass",shortName:"hourglass",description:"Represents a collate operation",aliases:["hourglass","collate"],handler:Ue},{semanticName:"Comment",name:"Curly Brace",shortName:"brace",description:"Adds a comment",aliases:["comment","brace-l"],handler:Le},{semanticName:"Comment Right",name:"Curly Brace",shortName:"brace-r",description:"Adds a comment",handler:He},{semanticName:"Comment with braces on both sides",name:"Curly Braces",shortName:"braces",description:"Adds a comment",handler:Ve},{semanticName:"Com Link",name:"Lightning Bolt",shortName:"bolt",description:"Communication link",aliases:["com-link","lightning-bolt"],handler:is},{semanticName:"Document",name:"Document",shortName:"doc",description:"Represents a document",aliases:["doc","document"],handler:Bs},{semanticName:"Delay",name:"Half-Rounded Rectangle",shortName:"delay",description:"Represents a delay",aliases:["half-rounded-rectangle"],handler:Ye},{semanticName:"Direct Access Storage",name:"Horizontal Cylinder",shortName:"h-cyl",description:"Direct access storage",aliases:["das","horizontal-cylinder"],handler:$s},{semanticName:"Disk Storage",name:"Lined Cylinder",shortName:"lin-cyl",description:"Disk storage",aliases:["disk","lined-cylinder"],handler:ns},{semanticName:"Display",name:"Curved Trapezoid",shortName:"curv-trap",description:"Represents a display",aliases:["curved-trapezoid","display"],handler:We},{semanticName:"Divided Process",name:"Divided Rectangle",shortName:"div-rect",description:"Divided process shape",aliases:["div-proc","divided-rectangle","divided-process"],handler:Fe},{semanticName:"Extract",name:"Triangle",shortName:"tri",description:"Extraction process",aliases:["extract","triangle"],handler:Cs},{semanticName:"Internal Storage",name:"Window Pane",shortName:"win-pane",description:"Internal storage",aliases:["internal-storage","window-pane"],handler:Gs},{semanticName:"Junction",name:"Filled Circle",shortName:"f-circ",description:"Junction point",aliases:["junction","filled-circle"],handler:ze},{semanticName:"Loop Limit",name:"Trapezoidal Pentagon",shortName:"notch-pent",description:"Loop limit step",aliases:["loop-limit","notched-pentagon"],handler:Ts},{semanticName:"Manual File",name:"Flipped Triangle",shortName:"flip-tri",description:"Manual file operation",aliases:["manual-file","flipped-triangle"],handler:qe},{semanticName:"Manual Input",name:"Sloped Rectangle",shortName:"sl-rect",description:"Manual input step",aliases:["manual-input","sloped-rectangle"],handler:ys},{semanticName:"Multi-Document",name:"Stacked Document",shortName:"docs",description:"Multiple documents",aliases:["documents","st-doc","stacked-document"],handler:hs},{semanticName:"Multi-Process",name:"Stacked Rectangle",shortName:"st-rect",description:"Multiple processes",aliases:["procs","processes","stacked-rectangle"],handler:cs},{semanticName:"Stored Data",name:"Bow Tie Rectangle",shortName:"bow-rect",description:"Stored data",aliases:["stored-data","bow-tie-rectangle"],handler:Ge},{semanticName:"Summary",name:"Crossed Circle",shortName:"cross-circ",description:"Summary",aliases:["summary","crossed-circle"],handler:Oe},{semanticName:"Tagged Document",name:"Tagged Document",shortName:"tag-doc",description:"Tagged document",aliases:["tag-doc","tagged-document"],handler:vs},{semanticName:"Tagged Process",name:"Tagged Rectangle",shortName:"tag-rect",description:"Tagged process",aliases:["tagged-rectangle","tag-proc","tagged-process"],handler:Ms},{semanticName:"Paper Tape",name:"Flag",shortName:"flag",description:"Paper tape",aliases:["paper-tape"],handler:Rs},{semanticName:"Odd",name:"Odd",shortName:"odd",description:"Odd shape",internalAliases:["rect_left_inv_arrow"],handler:fs},{semanticName:"Lined Document",name:"Lined Document",shortName:"lin-doc",description:"Lined document",aliases:["lined-document"],handler:ls}],wr=u(()=>{let t=[...Object.entries({state:Ss,choice:Ee,note:ps,rectWithTitle:gs,labelRect:rs,iconSquare:ts,iconCircle:Je,icon:Qe,iconRounded:Ke,imageSquare:es,anchor:Be,kanbanItem:As,classBox:Es}),...Sr.flatMap(o=>[o.shortName,..."aliases"in o?o.aliases:[],..."internalAliases"in o?o.internalAliases:[]].map(s=>[s,o.handler]))];return Object.fromEntries(t)},"generateShapeMap"),se=wr();function gf(n){return n in se}u(gf,"isValidShape");var At=new Map;async function bf(n,t,o){let r,s;t.shape==="rect"&&(t.rx&&t.ry?t.shape="roundedRect":t.shape="squareRect");let a=t.shape?se[t.shape]:void 0;if(!a)throw new Error(`No such shape: ${t.shape}. Please check your syntax.`);if(t.link){let c;o.config.securityLevel==="sandbox"?c="_top":t.linkTarget&&(c=t.linkTarget||"_blank"),r=n.insert("svg:a").attr("xlink:href",t.link).attr("target",c??null),s=await a(r,t,o)}else s=await a(n,t,o),r=s;return t.tooltip&&s.attr("title",t.tooltip),At.set(t.id,r),t.haveCallback&&r.attr("class",r.attr("class")+" clickable"),r}u(bf,"insertNode");var Sf=u((n,t)=>{At.set(t.id,n)},"setNodeElem"),wf=u(()=>{At.clear()},"clear"),Nf=u(n=>{let t=At.get(n.id);z.trace("Transforming node",n.diff,n,"translate("+(n.x-n.width/2-5)+", "+n.width/2+")");let o=8,r=n.diff||0;return n.clusterNode?t.attr("transform","translate("+(n.x+r-n.width/2)+", "+(n.y-n.height/2-o)+")"):t.attr("transform","translate("+n.x+", "+n.y+")"),r},"positionNode");export{T as a,v as b,D as c,St as d,gf as e,ro as f,oo as g,bf as h,Sf as i,wf as j,Nf as k}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-FASC7IG4.mjs b/static/js/chunks/mermaid.esm.min/chunk-FASC7IG4.mjs new file mode 100644 index 0000000..c4849de --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-FASC7IG4.mjs @@ -0,0 +1 @@ +import{a as E}from"./chunk-ZN7TASNU.mjs";import{D as y,E as G,F as x,G as P,H as V,J as B,K as k,L as S,N as yr,P as O,T as A,U as Z,d as N,f as _r,h as Q,i as wr,k as R,n as u,p as I,q as z,s as _,u as br,v as Er,x as q,z as L}from"./chunk-5ZJXQJOJ.mjs";import{O as F,T as Y,z as vr}from"./chunk-6BY5RJGC.mjs";import{a as s}from"./chunk-GTKDMUJJ.mjs";function g(r,e,n,t){var o;do o=A(t);while(r.hasNode(o));return n.dummy=e,r.setNode(o,n),o}s(g,"addDummyNode");function xr(r){var e=new E().setGraph(r.graph());return u(r.nodes(),function(n){e.setNode(n,r.node(n))}),u(r.edges(),function(n){var t=e.edge(n.v,n.w)||{weight:0,minlen:1},o=r.edge(n);e.setEdge(n.v,n.w,{weight:t.weight+o.weight,minlen:Math.max(t.minlen,o.minlen)})}),e}s(xr,"simplify");function X(r){var e=new E({multigraph:r.isMultigraph()}).setGraph(r.graph());return u(r.nodes(),function(n){r.children(n).length||e.setNode(n,r.node(n))}),u(r.edges(),function(n){e.setEdge(n,r.edge(n))}),e}s(X,"asNonCompoundGraph");function $(r,e){var n=r.x,t=r.y,o=e.x-n,a=e.y-t,i=r.width/2,f=r.height/2;if(!o&&!a)throw new Error("Not possible to find intersection inside of the rectangle");var d,c;return Math.abs(a)*i>Math.abs(o)*f?(a<0&&(f=-f),d=f*o/a,c=f):(o<0&&(i=-i),d=i,c=i*a/o),{x:n+d,y:t+c}}s($,"intersectRect");function C(r){var e=_(k(er(r)+1),function(){return[]});return u(r.nodes(),function(n){var t=r.node(n),o=t.rank;y(o)||(e[o][t.order]=n)}),e}s(C,"buildLayerMatrix");function kr(r){var e=P(_(r.nodes(),function(n){return r.node(n).rank}));u(r.nodes(),function(n){var t=r.node(n);q(t,"rank")&&(t.rank-=e)})}s(kr,"normalizeRanks");function gr(r){var e=P(_(r.nodes(),function(a){return r.node(a).rank})),n=[];u(r.nodes(),function(a){var i=r.node(a).rank-e;n[i]||(n[i]=[]),n[i].push(a)});var t=0,o=r.graph().nodeRankFactor;u(n,function(a,i){y(a)&&i%o!==0?--t:t&&u(a,function(f){r.node(f).rank+=t})})}s(gr,"removeEmptyRanks");function rr(r,e,n,t){var o={width:0,height:0};return arguments.length>=4&&(o.rank=n,o.order=t),g(r,"border",o,e)}s(rr,"addBorderNode");function er(r){return x(_(r.nodes(),function(e){var n=r.node(e).rank;if(!y(n))return n}))}s(er,"maxRank");function Nr(r,e){var n={lhs:[],rhs:[]};return u(r,function(t){e(t)?n.lhs.push(t):n.rhs.push(t)}),n}s(Nr,"partition");function Ir(r,e){var n=Q();try{return e()}finally{console.log(r+" time: "+(Q()-n)+"ms")}}s(Ir,"time");function Or(r,e){return e()}s(Or,"notime");function Pr(r){function e(n){var t=r.children(n),o=r.node(n);if(t.length&&u(t,e),Object.prototype.hasOwnProperty.call(o,"minRank")){o.borderLeft=[],o.borderRight=[];for(var a=o.minRank,i=o.maxRank+1;a0;--f)if(i=e[f].dequeue(),i){t=t.concat(or(r,e,n,i,!0));break}}}return t}s(be,"doGreedyFAS");function or(r,e,n,t,o){var a=o?[]:void 0;return u(r.inEdges(t.v),function(i){var f=r.edge(i),d=r.node(i.v);o&&a.push({v:i.v,w:i.w}),d.out-=f,ar(e,n,d)}),u(r.outEdges(t.v),function(i){var f=r.edge(i),d=i.w,c=r.node(d);c.in-=f,ar(e,n,c)}),r.removeNode(t.v),a}s(or,"removeNode");function Ee(r,e){var n=new E,t=0,o=0;u(r.nodes(),function(f){n.setNode(f,{v:f,in:0,out:0})}),u(r.edges(),function(f){var d=n.edge(f.v,f.w)||0,c=e(f),h=d+c;n.setEdge(f.v,f.w,h),o=Math.max(o,n.node(f.v).out+=c),t=Math.max(t,n.node(f.w).in+=c)});var a=k(o+t+3).map(function(){return new H}),i=t+1;return u(n.nodes(),function(f){ar(a,i,n.node(f))}),{graph:n,buckets:a,zeroIdx:i}}s(Ee,"buildState");function ar(r,e,n){n.out?n.in?r[n.out-n.in+e].enqueue(n):r[r.length-1].enqueue(n):r[0].enqueue(n)}s(ar,"assignBucket");function Fr(r){var e=r.graph().acyclicer==="greedy"?Mr(r,n(r)):ye(r);u(e,function(t){var o=r.edge(t);r.removeEdge(t),o.forwardName=t.name,o.reversed=!0,r.setEdge(t.w,t.v,o,A("rev"))});function n(t){return function(o){return t.edge(o).weight}}s(n,"weightFn")}s(Fr,"run");function ye(r){var e=[],n={},t={};function o(a){Object.prototype.hasOwnProperty.call(t,a)||(t[a]=!0,n[a]=!0,u(r.outEdges(a),function(i){Object.prototype.hasOwnProperty.call(n,i.w)?e.push(i):o(i.w)}),delete n[a])}return s(o,"dfs"),u(r.nodes(),o),e}s(ye,"dfsFAS");function Gr(r){u(r.edges(),function(e){var n=r.edge(e);if(n.reversed){r.removeEdge(e);var t=n.forwardName;delete n.reversed,delete n.forwardName,r.setEdge(e.w,e.v,n,t)}})}s(Gr,"undo");function Br(r){r.graph().dummyChains=[],u(r.edges(),function(e){xe(r,e)})}s(Br,"run");function xe(r,e){var n=e.v,t=r.node(n).rank,o=e.w,a=r.node(o).rank,i=e.name,f=r.edge(e),d=f.labelRank;if(a!==t+1){r.removeEdge(e);var c=void 0,h,l;for(l=0,++t;ti.lim&&(f=i,d=!0);var c=I(e.edges(),function(h){return d===zr(r,r.node(h.v),f)&&d!==zr(r,r.node(h.w),f)});return V(c,function(h){return M(e,h)})}s(Xr,"enterEdge");function Hr(r,e,n,t){var o=n.v,a=n.w;r.removeEdge(o,a),r.setEdge(t.v,t.w,{}),dr(r),ur(r,e),Te(r,e)}s(Hr,"exchangeEdges");function Te(r,e){var n=z(r.nodes(),function(o){return!e.node(o).parent}),t=fr(r,n);t=t.slice(1),u(t,function(o){var a=r.node(o).parent,i=e.edge(o,a),f=!1;i||(i=e.edge(a,o),f=!0),e.node(o).rank=e.node(a).rank+(f?i.minlen:-i.minlen)})}s(Te,"updateRanks");function je(r,e,n){return r.hasEdge(e,n)}s(je,"isTreeEdge");function zr(r,e,n){return n.low<=e.lim&&e.lim<=n.lim}s(zr,"isDescendant");function cr(r){switch(r.graph().ranker){case"network-simplex":Jr(r);break;case"tight-tree":Se(r);break;case"longest-path":Re(r);break;default:Jr(r)}}s(cr,"rank");var Re=U;function Se(r){U(r),J(r)}s(Se,"tightTreeRanker");function Jr(r){j(r)}s(Jr,"networkSimplexRanker");function Kr(r){var e=g(r,"root",{},"_root"),n=Me(r),t=x(L(n))-1,o=2*t+1;r.graph().nestingRoot=e,u(r.edges(),function(i){r.edge(i).minlen*=o});var a=Fe(r)+1;u(r.children(),function(i){Qr(r,e,o,a,t,n,i)}),r.graph().nodeRankFactor=o}s(Kr,"run");function Qr(r,e,n,t,o,a,i){var f=r.children(i);if(!f.length){i!==e&&r.setEdge(e,i,{weight:0,minlen:n});return}var d=rr(r,"_bt"),c=rr(r,"_bb"),h=r.node(i);r.setParent(d,i),h.borderTop=d,r.setParent(c,i),h.borderBottom=c,u(f,function(l){Qr(r,e,n,t,o,a,l);var p=r.node(l),m=p.borderTop?p.borderTop:l,v=p.borderBottom?p.borderBottom:l,b=p.borderTop?t:2*t,D=m!==v?1:o-a[i]+1;r.setEdge(d,m,{weight:b,minlen:D,nestingEdge:!0}),r.setEdge(v,c,{weight:b,minlen:D,nestingEdge:!0})}),r.parent(i)||r.setEdge(e,d,{weight:0,minlen:o+a[i]})}s(Qr,"dfs");function Me(r){var e={};function n(t,o){var a=r.children(t);a&&a.length&&u(a,function(i){n(i,o+1)}),e[t]=o}return s(n,"dfs"),u(r.children(),function(t){n(t,1)}),e}s(Me,"treeDepths");function Fe(r){return S(r.edges(),function(e,n){return e+r.edge(n).weight},0)}s(Fe,"sumWeights");function Zr(r){var e=r.graph();r.removeNode(e.nestingRoot),delete e.nestingRoot,u(r.edges(),function(n){var t=r.edge(n);t.nestingEdge&&r.removeEdge(n)})}s(Zr,"cleanup");function $r(r,e,n){var t={},o;u(n,function(a){for(var i=r.parent(a),f,d;i;){if(f=r.parent(i),f?(d=t[f],t[f]=i):(d=o,o=i),d&&d!==i){e.setEdge(d,i);return}i=f}})}s($r,"addSubgraphConstraints");function re(r,e,n){var t=Ve(r),o=new E({compound:!0}).setGraph({root:t}).setDefaultNodeLabel(function(a){return r.node(a)});return u(r.nodes(),function(a){var i=r.node(a),f=r.parent(a);(i.rank===e||i.minRank<=e&&e<=i.maxRank)&&(o.setNode(a),o.setParent(a,f||t),u(r[n](a),function(d){var c=d.v===a?d.w:d.v,h=o.edge(c,a),l=y(h)?0:h.weight;o.setEdge(c,a,{weight:r.edge(d).weight+l})}),Object.prototype.hasOwnProperty.call(i,"minRank")&&o.setNode(a,{borderLeft:i.borderLeft[e],borderRight:i.borderRight[e]}))}),o}s(re,"buildLayerGraph");function Ve(r){for(var e;r.hasNode(e=A("_root")););return e}s(Ve,"createRootNode");function ee(r,e){for(var n=0,t=1;t0;)h%2&&(l+=f[h+1]),h=h-1>>1,f[h]+=c.weight;d+=c.weight*l})),d}s(Be,"twoLayerCrossCount");function ne(r){var e={},n=I(r.nodes(),function(f){return!r.children(f).length}),t=x(_(n,function(f){return r.node(f).rank})),o=_(k(t+1),function(){return[]});function a(f){if(!q(e,f)){e[f]=!0;var d=r.node(f);o[d.rank].push(f),u(r.successors(f),a)}}s(a,"dfs");var i=O(n,function(f){return r.node(f).rank});return u(i,a),o}s(ne,"initOrder");function te(r,e){return _(e,function(n){var t=r.inEdges(n);if(t.length){var o=S(t,function(a,i){var f=r.edge(i),d=r.node(i.v);return{sum:a.sum+f.weight*d.order,weight:a.weight+f.weight}},{sum:0,weight:0});return{v:n,barycenter:o.sum/o.weight,weight:o.weight}}else return{v:n}})}s(te,"barycenter");function oe(r,e){var n={};u(r,function(o,a){var i=n[o.v]={indegree:0,in:[],out:[],vs:[o.v],i:a};y(o.barycenter)||(i.barycenter=o.barycenter,i.weight=o.weight)}),u(e.edges(),function(o){var a=n[o.v],i=n[o.w];!y(a)&&!y(i)&&(i.indegree++,a.out.push(n[o.w]))});var t=I(n,function(o){return!o.indegree});return Ae(t)}s(oe,"resolveConflicts");function Ae(r){var e=[];function n(a){return function(i){i.merged||(y(i.barycenter)||y(a.barycenter)||i.barycenter>=a.barycenter)&&De(a,i)}}s(n,"handleIn");function t(a){return function(i){i.in.push(a),--i.indegree===0&&r.push(i)}}for(s(t,"handleOut");r.length;){var o=r.pop();e.push(o),u(o.in.reverse(),n(o)),u(o.out,t(o))}return _(I(e,function(a){return!a.merged}),function(a){return B(a,["vs","i","barycenter","weight"])})}s(Ae,"doResolveConflicts");function De(r,e){var n=0,t=0;r.weight&&(n+=r.barycenter*r.weight,t+=r.weight),e.weight&&(n+=e.barycenter*e.weight,t+=e.weight),r.vs=e.vs.concat(r.vs),r.barycenter=n/t,r.weight=t,r.i=Math.min(e.i,r.i),e.merged=!0}s(De,"mergeEntries");function ie(r,e){var n=Nr(r,function(h){return Object.prototype.hasOwnProperty.call(h,"barycenter")}),t=n.lhs,o=O(n.rhs,function(h){return-h.i}),a=[],i=0,f=0,d=0;t.sort(Ye(!!e)),d=ae(a,o,d),u(t,function(h){d+=h.vs.length,a.push(h.vs),i+=h.barycenter*h.weight,f+=h.weight,d=ae(a,o,d)});var c={vs:N(a)};return f&&(c.barycenter=i/f,c.weight=f),c}s(ie,"sort");function ae(r,e,n){for(var t;e.length&&(t=R(e)).i<=n;)e.pop(),r.push(t.vs),n++;return n}s(ae,"consumeUnsortable");function Ye(r){return function(e,n){return e.barycentern.barycenter?1:r?n.i-e.i:e.i-n.i}}s(Ye,"compareWithBias");function hr(r,e,n,t){var o=r.children(e),a=r.node(e),i=a?a.borderLeft:void 0,f=a?a.borderRight:void 0,d={};i&&(o=I(o,function(v){return v!==i&&v!==f}));var c=te(r,o);u(c,function(v){if(r.children(v.v).length){var b=hr(r,v.v,n,t);d[v.v]=b,Object.prototype.hasOwnProperty.call(b,"barycenter")&&Ue(v,b)}});var h=oe(c,n);ze(h,d);var l=ie(h,t);if(i&&(l.vs=N([i,l.vs,f]),r.predecessors(i).length)){var p=r.node(r.predecessors(i)[0]),m=r.node(r.predecessors(f)[0]);Object.prototype.hasOwnProperty.call(l,"barycenter")||(l.barycenter=0,l.weight=0),l.barycenter=(l.barycenter*l.weight+p.order+m.order)/(l.weight+2),l.weight+=2}return l}s(hr,"sortSubgraph");function ze(r,e){u(r,function(n){n.vs=N(n.vs.map(function(t){return e[t]?e[t].vs:t}))})}s(ze,"expandSubgraphs");function Ue(r,e){y(r.barycenter)?(r.barycenter=e.barycenter,r.weight=e.weight):(r.barycenter=(r.barycenter*r.weight+e.barycenter*e.weight)/(r.weight+e.weight),r.weight+=e.weight)}s(Ue,"mergeBarycenters");function ue(r){var e=er(r),n=se(r,k(1,e+1),"inEdges"),t=se(r,k(e-1,-1,-1),"outEdges"),o=ne(r);fe(r,o);for(var a=Number.POSITIVE_INFINITY,i,f=0,d=0;d<4;++f,++d){We(f%2?n:t,f%4>=2),o=C(r);var c=ee(r,o);ci||f>e[d].lim));for(c=d,d=t;(d=r.parent(d))!==c;)a.push(d);return{path:o.concat(a.reverse()),lca:c}}s(qe,"findPath");function Xe(r){var e={},n=0;function t(o){var a=n;u(r.children(o),t),e[o]={low:a,lim:n++}}return s(t,"dfs"),u(r.children(),t),e}s(Xe,"postorder");function He(r,e){var n={};function t(o,a){var i=0,f=0,d=o.length,c=R(a);return u(a,function(h,l){var p=Ke(r,h),m=p?r.node(p).order:d;(p||h===c)&&(u(a.slice(f,l+1),function(v){u(r.predecessors(v),function(b){var D=r.node(b),mr=D.order;(mrc)&&ce(n,p,h)})})}s(t,"scan");function o(a,i){var f=-1,d,c=0;return u(i,function(h,l){if(r.node(h).dummy==="border"){var p=r.predecessors(h);p.length&&(d=r.node(p[0]).order,t(i,c,l,f,d),c=l,f=d)}t(i,c,i.length,d,a.length)}),i}return s(o,"visitLayer"),S(e,o),n}s(Je,"findType2Conflicts");function Ke(r,e){if(r.node(e).dummy)return z(r.predecessors(e),function(n){return r.node(n).dummy})}s(Ke,"findOtherInnerSegmentNode");function ce(r,e,n){if(e>n){var t=e;e=n,n=t}var o=r[e];o||(r[e]=o={}),o[n]=!0}s(ce,"addConflict");function Qe(r,e,n){if(e>n){var t=e;e=n,n=t}return!!r[e]&&Object.prototype.hasOwnProperty.call(r[e],n)}s(Qe,"hasConflict");function Ze(r,e,n,t){var o={},a={},i={};return u(e,function(f){u(f,function(d,c){o[d]=d,a[d]=d,i[d]=c})}),u(e,function(f){var d=-1;u(f,function(c){var h=t(c);if(h.length){h=O(h,function(b){return i[b]});for(var l=(h.length-1)/2,p=Math.floor(l),m=Math.ceil(l);p<=m;++p){var v=h[p];a[c]===c&&d{var t=n(" buildLayoutGraph",()=>bn(r));n(" runLayout",()=>un(t,n)),n(" updateInputGraph",()=>dn(r,t))})}s(fn,"layout");function un(r,e){e(" makeSpaceForEdgeLabels",()=>En(r)),e(" removeSelfEdges",()=>Pn(r)),e(" acyclic",()=>Fr(r)),e(" nestingGraph.run",()=>Kr(r)),e(" rank",()=>cr(X(r))),e(" injectEdgeLabelProxies",()=>yn(r)),e(" removeEmptyRanks",()=>gr(r)),e(" nestingGraph.cleanup",()=>Zr(r)),e(" normalizeRanks",()=>kr(r)),e(" assignRankMinMax",()=>xn(r)),e(" removeEdgeLabelProxies",()=>kn(r)),e(" normalize.run",()=>Br(r)),e(" parentDummyChains",()=>de(r)),e(" addBorderSegments",()=>Pr(r)),e(" order",()=>ue(r)),e(" insertSelfEdges",()=>Cn(r)),e(" adjustCoordinateSystem",()=>Tr(r)),e(" position",()=>le(r)),e(" positionSelfEdges",()=>Tn(r)),e(" removeBorderNodes",()=>Ln(r)),e(" normalize.undo",()=>Ar(r)),e(" fixupEdgeLabelCoords",()=>In(r)),e(" undoCoordinateSystem",()=>jr(r)),e(" translateGraph",()=>gn(r)),e(" assignNodeIntersects",()=>Nn(r)),e(" reversePoints",()=>On(r)),e(" acyclic.undo",()=>Gr(r))}s(un,"runLayout");function dn(r,e){u(r.nodes(),function(n){var t=r.node(n),o=e.node(n);t&&(t.x=o.x,t.y=o.y,e.children(n).length&&(t.width=o.width,t.height=o.height))}),u(r.edges(),function(n){var t=r.edge(n),o=e.edge(n);t.points=o.points,Object.prototype.hasOwnProperty.call(o,"x")&&(t.x=o.x,t.y=o.y)}),r.graph().width=e.graph().width,r.graph().height=e.graph().height}s(dn,"updateInputGraph");var cn=["nodesep","edgesep","ranksep","marginx","marginy"],hn={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},ln=["acyclicer","ranker","rankdir","align"],pn=["width","height"],mn={width:0,height:0},vn=["minlen","weight","width","height","labeloffset"],_n={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},wn=["labelpos"];function bn(r){var e=new E({multigraph:!0,compound:!0}),n=pr(r.graph());return e.setGraph(Y({},hn,lr(n,cn),B(n,ln))),u(r.nodes(),function(t){var o=pr(r.node(t));e.setNode(t,wr(lr(o,pn),mn)),e.setParent(t,r.parent(t))}),u(r.edges(),function(t){var o=pr(r.edge(t));e.setEdge(t,Y({},_n,lr(o,vn),B(o,wn)))}),e}s(bn,"buildLayoutGraph");function En(r){var e=r.graph();e.ranksep/=2,u(r.edges(),function(n){var t=r.edge(n);t.minlen*=2,t.labelpos.toLowerCase()!=="c"&&(e.rankdir==="TB"||e.rankdir==="BT"?t.width+=t.labeloffset:t.height+=t.labeloffset)})}s(En,"makeSpaceForEdgeLabels");function yn(r){u(r.edges(),function(e){var n=r.edge(e);if(n.width&&n.height){var t=r.node(e.v),o=r.node(e.w),a={rank:(o.rank-t.rank)/2+t.rank,e};g(r,"edge-proxy",a,"_ep")}})}s(yn,"injectEdgeLabelProxies");function xn(r){var e=0;u(r.nodes(),function(n){var t=r.node(n);t.borderTop&&(t.minRank=r.node(t.borderTop).rank,t.maxRank=r.node(t.borderBottom).rank,e=x(e,t.maxRank))}),r.graph().maxRank=e}s(xn,"assignRankMinMax");function kn(r){u(r.nodes(),function(e){var n=r.node(e);n.dummy==="edge-proxy"&&(r.edge(n.e).labelRank=n.rank,r.removeNode(e))})}s(kn,"removeEdgeLabelProxies");function gn(r){var e=Number.POSITIVE_INFINITY,n=0,t=Number.POSITIVE_INFINITY,o=0,a=r.graph(),i=a.marginx||0,f=a.marginy||0;function d(c){var h=c.x,l=c.y,p=c.width,m=c.height;e=Math.min(e,h-p/2),n=Math.max(n,h+p/2),t=Math.min(t,l-m/2),o=Math.max(o,l+m/2)}s(d,"getExtremes"),u(r.nodes(),function(c){d(r.node(c))}),u(r.edges(),function(c){var h=r.edge(c);Object.prototype.hasOwnProperty.call(h,"x")&&d(h)}),e-=i,t-=f,u(r.nodes(),function(c){var h=r.node(c);h.x-=e,h.y-=t}),u(r.edges(),function(c){var h=r.edge(c);u(h.points,function(l){l.x-=e,l.y-=t}),Object.prototype.hasOwnProperty.call(h,"x")&&(h.x-=e),Object.prototype.hasOwnProperty.call(h,"y")&&(h.y-=t)}),a.width=n-e+i,a.height=o-t+f}s(gn,"translateGraph");function Nn(r){u(r.edges(),function(e){var n=r.edge(e),t=r.node(e.v),o=r.node(e.w),a,i;n.points?(a=n.points[0],i=n.points[n.points.length-1]):(n.points=[],a=o,i=t),n.points.unshift($(t,a)),n.points.push($(o,i))})}s(Nn,"assignNodeIntersects");function In(r){u(r.edges(),function(e){var n=r.edge(e);if(Object.prototype.hasOwnProperty.call(n,"x"))switch((n.labelpos==="l"||n.labelpos==="r")&&(n.width-=n.labeloffset),n.labelpos){case"l":n.x-=n.width/2+n.labeloffset;break;case"r":n.x+=n.width/2+n.labeloffset;break}})}s(In,"fixupEdgeLabelCoords");function On(r){u(r.edges(),function(e){var n=r.edge(e);n.reversed&&n.points.reverse()})}s(On,"reversePointsForReversedEdges");function Ln(r){u(r.nodes(),function(e){if(r.children(e).length){var n=r.node(e),t=r.node(n.borderTop),o=r.node(n.borderBottom),a=r.node(R(n.borderLeft)),i=r.node(R(n.borderRight));n.width=Math.abs(i.x-a.x),n.height=Math.abs(o.y-t.y),n.x=a.x+n.width/2,n.y=t.y+n.height/2}}),u(r.nodes(),function(e){r.node(e).dummy==="border"&&r.removeNode(e)})}s(Ln,"removeBorderNodes");function Pn(r){u(r.edges(),function(e){if(e.v===e.w){var n=r.node(e.v);n.selfEdges||(n.selfEdges=[]),n.selfEdges.push({e,label:r.edge(e)}),r.removeEdge(e)}})}s(Pn,"removeSelfEdges");function Cn(r){var e=C(r);u(e,function(n){var t=0;u(n,function(o,a){var i=r.node(o);i.order=a+t,u(i.selfEdges,function(f){g(r,"selfedge",{width:f.label.width,height:f.label.height,rank:i.rank,order:a+ ++t,e:f.e,label:f.label},"_se")}),delete i.selfEdges})})}s(Cn,"insertSelfEdges");function Tn(r){u(r.nodes(),function(e){var n=r.node(e);if(n.dummy==="selfedge"){var t=r.node(n.e.v),o=t.x+t.width/2,a=t.y,i=n.x-o,f=t.height/2;r.setEdge(n.e,n.label),r.removeNode(e),n.label.points=[{x:o+2*i/3,y:a-f},{x:o+5*i/6,y:a-f},{x:o+i,y:a},{x:o+5*i/6,y:a+f},{x:o+2*i/3,y:a+f}],n.label.x=n.x,n.label.y=n.y}})}s(Tn,"positionSelfEdges");function lr(r,e){return G(B(r,e),Number)}s(lr,"selectNumberAttrs");function pr(r){var e={};return u(r,function(n,t){e[t.toLowerCase()]=n}),e}s(pr,"canonicalize");export{fn as a}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-GTKDMUJJ.mjs b/static/js/chunks/mermaid.esm.min/chunk-GTKDMUJJ.mjs new file mode 100644 index 0000000..5514357 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-GTKDMUJJ.mjs @@ -0,0 +1 @@ +var h=Object.create;var e=Object.defineProperty;var i=Object.getOwnPropertyDescriptor;var j=Object.getOwnPropertyNames;var k=Object.getPrototypeOf,l=Object.prototype.hasOwnProperty;var m=(b,a)=>e(b,"name",{value:a,configurable:!0});var n=(b,a)=>()=>(a||b((a={exports:{}}).exports,a),a.exports),o=(b,a)=>{for(var c in a)e(b,c,{get:a[c],enumerable:!0})},f=(b,a,c,g)=>{if(a&&typeof a=="object"||typeof a=="function")for(let d of j(a))!l.call(b,d)&&d!==c&&e(b,d,{get:()=>a[d],enumerable:!(g=i(a,d))||g.enumerable});return b},p=(b,a,c)=>(f(b,a,"default"),c&&f(c,a,"default")),q=(b,a,c)=>(c=b!=null?h(k(b)):{},f(a||!b||!b.__esModule?e(c,"default",{value:b,enumerable:!0}):c,b));export{m as a,n as b,o as c,p as d,q as e}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-LM6QDVU5.mjs b/static/js/chunks/mermaid.esm.min/chunk-LM6QDVU5.mjs new file mode 100644 index 0000000..120fdca --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-LM6QDVU5.mjs @@ -0,0 +1 @@ +import{a as i}from"./chunk-GTKDMUJJ.mjs";var n=i(({flowchart:r})=>{let t=r?.subGraphTitleMargin?.top??0,a=r?.subGraphTitleMargin?.bottom??0,o=t+a;return{subGraphTitleTopMargin:t,subGraphTitleBottomMargin:a,subGraphTitleTotalMargin:o}},"getSubGraphTitleMargins");export{n as a}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-OR2G2HG5.mjs b/static/js/chunks/mermaid.esm.min/chunk-OR2G2HG5.mjs new file mode 100644 index 0000000..1dae0c1 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-OR2G2HG5.mjs @@ -0,0 +1,64 @@ +import{a as i,b as fu,c as mu,e as pu}from"./chunk-GTKDMUJJ.mjs";var Ya=fu((qo,zo)=>{"use strict";(function(t,e){typeof qo=="object"&&typeof zo<"u"?zo.exports=e():typeof define=="function"&&define.amd?define(e):(t=typeof globalThis<"u"?globalThis:t||self).dayjs=e()})(qo,function(){"use strict";var t=1e3,e=6e4,r=36e5,o="millisecond",n="second",s="minute",a="hour",l="day",c="week",h="month",u="quarter",d="year",f="date",g="Invalid Date",T=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,L=/\[([^\]]+)]|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,$={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:i(function(k){var x=["th","st","nd","rd"],y=k%100;return"["+k+(x[(y-20)%10]||x[y]||x[0])+"]"},"ordinal")},z=i(function(k,x,y){var F=String(k);return!F||F.length>=x?k:""+Array(x+1-F.length).join(y)+k},"m"),G={s:z,z:i(function(k){var x=-k.utcOffset(),y=Math.abs(x),F=Math.floor(y/60),S=y%60;return(x<=0?"+":"-")+z(F,2,"0")+":"+z(S,2,"0")},"z"),m:i(function k(x,y){if(x.date()1)return k(O[0])}else{var U=x.name;B[U]=x,S=U}return!F&&S&&(E=S),S||!F&&E},"t"),j=i(function(k,x){if(w(k))return k.clone();var y=typeof x=="object"?x:{};return y.date=k,y.args=arguments,new it(y)},"O"),W=G;W.l=X,W.i=w,W.w=function(k,x){return j(k,{locale:x.$L,utc:x.$u,x:x.$x,$offset:x.$offset})};var it=function(){function k(y){this.$L=X(y.locale,null,!0),this.parse(y),this.$x=this.$x||y.x||{},this[P]=!0}i(k,"M");var x=k.prototype;return x.parse=function(y){this.$d=function(F){var S=F.date,N=F.utc;if(S===null)return new Date(NaN);if(W.u(S))return new Date;if(S instanceof Date)return new Date(S);if(typeof S=="string"&&!/Z$/i.test(S)){var O=S.match(T);if(O){var U=O[2]-1||0,rt=(O[7]||"0").substring(0,3);return N?new Date(Date.UTC(O[1],U,O[3]||1,O[4]||0,O[5]||0,O[6]||0,rt)):new Date(O[1],U,O[3]||1,O[4]||0,O[5]||0,O[6]||0,rt)}}return new Date(S)}(y),this.init()},x.init=function(){var y=this.$d;this.$y=y.getFullYear(),this.$M=y.getMonth(),this.$D=y.getDate(),this.$W=y.getDay(),this.$H=y.getHours(),this.$m=y.getMinutes(),this.$s=y.getSeconds(),this.$ms=y.getMilliseconds()},x.$utils=function(){return W},x.isValid=function(){return this.$d.toString()!==g},x.isSame=function(y,F){var S=j(y);return this.startOf(F)<=S&&S<=this.endOf(F)},x.isAfter=function(y,F){return j(y){},"trace"),debug:i((...t)=>{},"debug"),info:i((...t)=>{},"info"),warn:i((...t)=>{},"warn"),error:i((...t)=>{},"error"),fatal:i((...t)=>{},"fatal")},Va=i(function(t="fatal"){let e=oe.fatal;typeof t=="string"?t.toLowerCase()in oe&&(e=oe[t]):typeof t=="number"&&(e=t),tt.trace=()=>{},tt.debug=()=>{},tt.info=()=>{},tt.warn=()=>{},tt.error=()=>{},tt.fatal=()=>{},e<=oe.fatal&&(tt.fatal=console.error?console.error.bind(console,Pt("FATAL"),"color: orange"):console.log.bind(console,"\x1B[35m",Pt("FATAL"))),e<=oe.error&&(tt.error=console.error?console.error.bind(console,Pt("ERROR"),"color: orange"):console.log.bind(console,"\x1B[31m",Pt("ERROR"))),e<=oe.warn&&(tt.warn=console.warn?console.warn.bind(console,Pt("WARN"),"color: orange"):console.log.bind(console,"\x1B[33m",Pt("WARN"))),e<=oe.info&&(tt.info=console.info?console.info.bind(console,Pt("INFO"),"color: lightblue"):console.log.bind(console,"\x1B[34m",Pt("INFO"))),e<=oe.debug&&(tt.debug=console.debug?console.debug.bind(console,Pt("DEBUG"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Pt("DEBUG"))),e<=oe.trace&&(tt.trace=console.debug?console.debug.bind(console,Pt("TRACE"),"color: lightgreen"):console.log.bind(console,"\x1B[32m",Pt("TRACE")))},"setLogLevel"),Pt=i(t=>`%c${(0,Ga.default)().format("ss.SSS")} : ${t} : `,"format");var Xa=/^-{3}\s*[\n\r](.*?)[\n\r]-{3}\s*[\n\r]+/s,ja=/%{2}{\s*(?:(\w+)\s*:|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,Za=/\s*%%.*\n/gm;var bi=class extends Error{static{i(this,"UnknownDiagramError")}constructor(e){super(e),this.name="UnknownDiagramError"}};var Ti={},cx=i(function(t,e){t=t.replace(Xa,"").replace(ja,"").replace(Za,` +`);for(let[r,{detector:o}]of Object.entries(Ti))if(o(t,e))return r;throw new bi(`No diagram type detected matching given configuration for text: ${t}`)},"detectType"),ux=i((...t)=>{for(let{id:e,detector:r,loader:o}of t)Po(e,r,o)},"registerLazyLoadedDiagrams"),Po=i((t,e,r)=>{Ti[t]&&tt.warn(`Detector with key ${t} already exists. Overwriting.`),Ti[t]={detector:e,loader:r},tt.debug(`Detector with key ${t} added${r?" with loader":""}`)},"addDetector"),fx=i(t=>Ti[t].loader,"getDiagramLoader");var $o=i((t,e,{depth:r=2,clobber:o=!1}={})=>{let n={depth:r,clobber:o};return Array.isArray(e)&&!Array.isArray(t)?(e.forEach(s=>$o(t,s,n)),t):Array.isArray(e)&&Array.isArray(t)?(e.forEach(s=>{t.includes(s)||t.push(s)}),t):t===void 0||r<=0?t!=null&&typeof t=="object"&&typeof e=="object"?Object.assign(t,e):e:(e!==void 0&&typeof t=="object"&&typeof e=="object"&&Object.keys(e).forEach(s=>{typeof e[s]=="object"&&(t[s]===void 0||typeof t[s]=="object")?(t[s]===void 0&&(t[s]=Array.isArray(e[s])?[]:{}),t[s]=$o(t[s],e[s],{depth:r-1,clobber:o})):(o||typeof t[s]!="object"&&typeof e[s]!="object")&&(t[s]=e[s])}),t)},"assignWithDepth"),Lt=$o;var ki={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:i(t=>t>=255?255:t<0?0:t,"r"),g:i(t=>t>=255?255:t<0?0:t,"g"),b:i(t=>t>=255?255:t<0?0:t,"b"),h:i(t=>t%360,"h"),s:i(t=>t>=100?100:t<0?0:t,"s"),l:i(t=>t>=100?100:t<0?0:t,"l"),a:i(t=>t>=1?1:t<0?0:t,"a")},toLinear:i(t=>{let e=t/255;return t>.03928?Math.pow((e+.055)/1.055,2.4):e/12.92},"toLinear"),hue2rgb:i((t,e,r)=>(r<0&&(r+=1),r>1&&(r-=1),r<.16666666666666666?t+(e-t)*6*r:r<.5?e:r<.6666666666666666?t+(e-t)*(.6666666666666666-r)*6:t),"hue2rgb"),hsl2rgb:i(({h:t,s:e,l:r},o)=>{if(!e)return r*2.55;t/=360,e/=100,r/=100;let n=r<.5?r*(1+e):r+e-r*e,s=2*r-n;switch(o){case"r":return ki.hue2rgb(s,n,t+.3333333333333333)*255;case"g":return ki.hue2rgb(s,n,t)*255;case"b":return ki.hue2rgb(s,n,t-.3333333333333333)*255}},"hsl2rgb"),rgb2hsl:i(({r:t,g:e,b:r},o)=>{t/=255,e/=255,r/=255;let n=Math.max(t,e,r),s=Math.min(t,e,r),a=(n+s)/2;if(o==="l")return a*100;if(n===s)return 0;let l=n-s,c=a>.5?l/(2-n-s):l/(n+s);if(o==="s")return c*100;switch(n){case t:return((e-r)/l+(ee>r?Math.min(e,Math.max(r,t)):Math.min(r,Math.max(e,t)),"clamp"),round:i(t=>Math.round(t*1e10)/1e10,"round")},Qa=du;var gu={dec2hex:i(t=>{let e=Math.round(t).toString(16);return e.length>1?e:`0${e}`},"dec2hex")},Ja=gu;var xu={channel:Ka,lang:Qa,unit:Ja},q=xu;var ne={};for(let t=0;t<=255;t++)ne[t]=q.unit.dec2hex(t);var ut={ALL:0,RGB:1,HSL:2};var Wo=class{static{i(this,"Type")}constructor(){this.type=ut.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=ut.ALL}is(e){return this.type===e}},tl=Wo;var Ho=class{static{i(this,"Channels")}constructor(e,r){this.color=r,this.changed=!1,this.data=e,this.type=new tl}set(e,r){return this.color=r,this.changed=!1,this.data=e,this.type.type=ut.ALL,this}_ensureHSL(){let e=this.data,{h:r,s:o,l:n}=e;r===void 0&&(e.h=q.channel.rgb2hsl(e,"h")),o===void 0&&(e.s=q.channel.rgb2hsl(e,"s")),n===void 0&&(e.l=q.channel.rgb2hsl(e,"l"))}_ensureRGB(){let e=this.data,{r,g:o,b:n}=e;r===void 0&&(e.r=q.channel.hsl2rgb(e,"r")),o===void 0&&(e.g=q.channel.hsl2rgb(e,"g")),n===void 0&&(e.b=q.channel.hsl2rgb(e,"b"))}get r(){let e=this.data,r=e.r;return!this.type.is(ut.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"r"))}get g(){let e=this.data,r=e.g;return!this.type.is(ut.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"g"))}get b(){let e=this.data,r=e.b;return!this.type.is(ut.HSL)&&r!==void 0?r:(this._ensureHSL(),q.channel.hsl2rgb(e,"b"))}get h(){let e=this.data,r=e.h;return!this.type.is(ut.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"h"))}get s(){let e=this.data,r=e.s;return!this.type.is(ut.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"s"))}get l(){let e=this.data,r=e.l;return!this.type.is(ut.RGB)&&r!==void 0?r:(this._ensureRGB(),q.channel.rgb2hsl(e,"l"))}get a(){return this.data.a}set r(e){this.type.set(ut.RGB),this.changed=!0,this.data.r=e}set g(e){this.type.set(ut.RGB),this.changed=!0,this.data.g=e}set b(e){this.type.set(ut.RGB),this.changed=!0,this.data.b=e}set h(e){this.type.set(ut.HSL),this.changed=!0,this.data.h=e}set s(e){this.type.set(ut.HSL),this.changed=!0,this.data.s=e}set l(e){this.type.set(ut.HSL),this.changed=!0,this.data.l=e}set a(e){this.changed=!0,this.data.a=e}},el=Ho;var yu=new el({r:0,g:0,b:0,a:0},"transparent"),de=yu;var rl={re:/^#((?:[a-f0-9]{2}){2,4}|[a-f0-9]{3})$/i,parse:i(t=>{if(t.charCodeAt(0)!==35)return;let e=t.match(rl.re);if(!e)return;let r=e[1],o=parseInt(r,16),n=r.length,s=n%4===0,a=n>4,l=a?1:17,c=a?8:4,h=s?0:-1,u=a?255:15;return de.set({r:(o>>c*(h+3)&u)*l,g:(o>>c*(h+2)&u)*l,b:(o>>c*(h+1)&u)*l,a:s?(o&u)*l/255:1},t)},"parse"),stringify:i(t=>{let{r:e,g:r,b:o,a:n}=t;return n<1?`#${ne[Math.round(e)]}${ne[Math.round(r)]}${ne[Math.round(o)]}${ne[Math.round(n*255)]}`:`#${ne[Math.round(e)]}${ne[Math.round(r)]}${ne[Math.round(o)]}`},"stringify")},Ae=rl;var Si={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:i(t=>{let e=t.match(Si.hueRe);if(e){let[,r,o]=e;switch(o){case"grad":return q.channel.clamp.h(parseFloat(r)*.9);case"rad":return q.channel.clamp.h(parseFloat(r)*180/Math.PI);case"turn":return q.channel.clamp.h(parseFloat(r)*360)}}return q.channel.clamp.h(parseFloat(t))},"_hue2deg"),parse:i(t=>{let e=t.charCodeAt(0);if(e!==104&&e!==72)return;let r=t.match(Si.re);if(!r)return;let[,o,n,s,a,l]=r;return de.set({h:Si._hue2deg(o),s:q.channel.clamp.s(parseFloat(n)),l:q.channel.clamp.l(parseFloat(s)),a:a?q.channel.clamp.a(l?parseFloat(a)/100:parseFloat(a)):1},t)},"parse"),stringify:i(t=>{let{h:e,s:r,l:o,a:n}=t;return n<1?`hsla(${q.lang.round(e)}, ${q.lang.round(r)}%, ${q.lang.round(o)}%, ${n})`:`hsl(${q.lang.round(e)}, ${q.lang.round(r)}%, ${q.lang.round(o)}%)`},"stringify")},Fr=Si;var vi={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:i(t=>{t=t.toLowerCase();let e=vi.colors[t];if(e)return Ae.parse(e)},"parse"),stringify:i(t=>{let e=Ae.stringify(t);for(let r in vi.colors)if(vi.colors[r]===e)return r},"stringify")},Uo=vi;var il={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:i(t=>{let e=t.charCodeAt(0);if(e!==114&&e!==82)return;let r=t.match(il.re);if(!r)return;let[,o,n,s,a,l,c,h,u]=r;return de.set({r:q.channel.clamp.r(n?parseFloat(o)*2.55:parseFloat(o)),g:q.channel.clamp.g(a?parseFloat(s)*2.55:parseFloat(s)),b:q.channel.clamp.b(c?parseFloat(l)*2.55:parseFloat(l)),a:h?q.channel.clamp.a(u?parseFloat(h)/100:parseFloat(h)):1},t)},"parse"),stringify:i(t=>{let{r:e,g:r,b:o,a:n}=t;return n<1?`rgba(${q.lang.round(e)}, ${q.lang.round(r)}, ${q.lang.round(o)}, ${q.lang.round(n)})`:`rgb(${q.lang.round(e)}, ${q.lang.round(r)}, ${q.lang.round(o)})`},"stringify")},Mr=il;var Cu={format:{keyword:Uo,hex:Ae,rgb:Mr,rgba:Mr,hsl:Fr,hsla:Fr},parse:i(t=>{if(typeof t!="string")return t;let e=Ae.parse(t)||Mr.parse(t)||Fr.parse(t)||Uo.parse(t);if(e)return e;throw new Error(`Unsupported color format: "${t}"`)},"parse"),stringify:i(t=>!t.changed&&t.color?t.color:t.type.is(ut.HSL)||t.data.r===void 0?Fr.stringify(t):t.a<1||!Number.isInteger(t.r)||!Number.isInteger(t.g)||!Number.isInteger(t.b)?Mr.stringify(t):Ae.stringify(t),"stringify")},ft=Cu;var _u=i((t,e)=>{let r=ft.parse(t);for(let o in e)r[o]=q.channel.clamp[o](e[o]);return ft.stringify(r)},"change"),wi=_u;var bu=i((t,e,r=0,o=1)=>{if(typeof t!="number")return wi(t,{a:e});let n=de.set({r:q.channel.clamp.r(t),g:q.channel.clamp.g(e),b:q.channel.clamp.b(r),a:q.channel.clamp.a(o)});return ft.stringify(n)},"rgba"),se=bu;var Tu=i((t,e)=>q.lang.round(ft.parse(t)[e]),"channel"),ku=Tu;var Su=i(t=>{let{r:e,g:r,b:o}=ft.parse(t),n=.2126*q.channel.toLinear(e)+.7152*q.channel.toLinear(r)+.0722*q.channel.toLinear(o);return q.lang.round(n)},"luminance"),ol=Su;var vu=i(t=>ol(t)>=.5,"isLight"),nl=vu;var wu=i(t=>!nl(t),"isDark"),Wt=wu;var Bu=i((t,e,r)=>{let o=ft.parse(t),n=o[e],s=q.channel.clamp[e](n+r);return n!==s&&(o[e]=s),ft.stringify(o)},"adjustChannel"),Bi=Bu;var Fu=i((t,e)=>Bi(t,"l",e),"lighten"),A=Fu;var Mu=i((t,e)=>Bi(t,"l",-e),"darken"),R=Mu;var Lu=i((t,e)=>{let r=ft.parse(t),o={};for(let n in e)e[n]&&(o[n]=r[n]+e[n]);return wi(t,o)},"adjust"),p=Lu;var Au=i((t,e,r=50)=>{let{r:o,g:n,b:s,a}=ft.parse(t),{r:l,g:c,b:h,a:u}=ft.parse(e),d=r/100,f=d*2-1,g=a-u,L=((f*g===-1?f:(f+g)/(1+f*g))+1)/2,$=1-L,z=o*L+l*$,G=n*L+c*$,E=s*L+h*$,B=a*d+u*(1-d);return se(z,G,E,B)},"mix"),sl=Au;var Eu=i((t,e=100)=>{let r=ft.parse(t);return r.r=255-r.r,r.g=255-r.g,r.b=255-r.b,sl(r,t,e)},"invert"),b=Eu;var ge="#ffffff",xe="#f2f2f2";var ct=i((t,e)=>e?p(t,{s:-40,l:10}):p(t,{s:-40,l:-10}),"mkBorder");var Yo=class{static{i(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#fff4dd",this.noteBkgColor="#fff5ad",this.noteTextColor="#333",this.THEME_COLOR_LIMIT=12,this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px"}updateColors(){if(this.primaryTextColor=this.primaryTextColor||(this.darkMode?"#eee":"#333"),this.secondaryColor=this.secondaryColor||p(this.primaryColor,{h:-120}),this.tertiaryColor=this.tertiaryColor||p(this.primaryColor,{h:180,l:5}),this.primaryBorderColor=this.primaryBorderColor||ct(this.primaryColor,this.darkMode),this.secondaryBorderColor=this.secondaryBorderColor||ct(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=this.tertiaryBorderColor||ct(this.tertiaryColor,this.darkMode),this.noteBorderColor=this.noteBorderColor||ct(this.noteBkgColor,this.darkMode),this.noteBkgColor=this.noteBkgColor||"#fff5ad",this.noteTextColor=this.noteTextColor||"#333",this.secondaryTextColor=this.secondaryTextColor||b(this.secondaryColor),this.tertiaryTextColor=this.tertiaryTextColor||b(this.tertiaryColor),this.lineColor=this.lineColor||b(this.background),this.arrowheadColor=this.arrowheadColor||b(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?R(this.secondaryColor,30):this.secondaryColor),this.nodeTextColor=this.nodeTextColor||this.primaryTextColor,this.actorBorder=this.actorBorder||this.primaryBorderColor,this.actorBkg=this.actorBkg||this.mainBkg,this.actorTextColor=this.actorTextColor||this.primaryTextColor,this.actorLineColor=this.actorLineColor||this.actorBorder,this.labelBoxBkgColor=this.labelBoxBkgColor||this.actorBkg,this.signalColor=this.signalColor||this.textColor,this.signalTextColor=this.signalTextColor||this.textColor,this.labelBoxBorderColor=this.labelBoxBorderColor||this.actorBorder,this.labelTextColor=this.labelTextColor||this.actorTextColor,this.loopTextColor=this.loopTextColor||this.actorTextColor,this.activationBorderColor=this.activationBorderColor||R(this.secondaryColor,10),this.activationBkgColor=this.activationBkgColor||this.secondaryColor,this.sequenceNumberColor=this.sequenceNumberColor||b(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||A(this.primaryColor,23),this.gridColor=this.gridColor||"lightgrey",this.doneTaskBkgColor=this.doneTaskBkgColor||"lightgrey",this.doneTaskBorderColor=this.doneTaskBorderColor||"grey",this.critBorderColor=this.critBorderColor||"#ff8888",this.critBkgColor=this.critBkgColor||"red",this.todayLineColor=this.todayLineColor||"red",this.taskTextColor=this.taskTextColor||this.textColor,this.taskTextOutsideColor=this.taskTextOutsideColor||this.textColor,this.taskTextLightColor=this.taskTextLightColor||this.textColor,this.taskTextColor=this.taskTextColor||this.primaryTextColor,this.taskTextDarkColor=this.taskTextDarkColor||this.textColor,this.taskTextClickableColor=this.taskTextClickableColor||"#003163",this.personBorder=this.personBorder||this.primaryBorderColor,this.personBkg=this.personBkg||this.mainBkg,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||this.tertiaryColor,this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.nodeBorder,this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.transitionColor=this.transitionColor||this.lineColor,this.specialStateColor=this.lineColor,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210,l:150}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.darkMode)for(let r=0;r{this[o]=e[o]}),this.updateColors(),r.forEach(o=>{this[o]=e[o]})}},al=i(t=>{let e=new Yo;return e.calculate(t),e},"getThemeVariables");var Go=class{static{i(this,"Theme")}constructor(){this.background="#333",this.primaryColor="#1f2020",this.secondaryColor=A(this.primaryColor,16),this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=b(this.background),this.secondaryBorderColor=ct(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ct(this.tertiaryColor,this.darkMode),this.primaryTextColor=b(this.primaryColor),this.secondaryTextColor=b(this.secondaryColor),this.tertiaryTextColor=b(this.tertiaryColor),this.lineColor=b(this.background),this.textColor=b(this.background),this.mainBkg="#1f2020",this.secondBkg="calculated",this.mainContrastColor="lightgrey",this.darkTextColor=A(b("#323D47"),10),this.lineColor="calculated",this.border1="#ccc",this.border2=se(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=R("#EAE8D9",30),this.altSectionBkgColor="calculated",this.sectionBkgColor2="#EAE8D9",this.excludeBkgColor=R(this.sectionBkgColor,10),this.taskBorderColor=se(255,255,255,70),this.taskBkgColor="calculated",this.taskTextColor="calculated",this.taskTextLightColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor=se(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.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="calculated",this.errorBkgColor="#a44141",this.errorTextColor="#ddd"}updateColors(){this.secondBkg=A(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=A(this.labelBackground,25),this.actorBorder=this.border1,this.actorBkg=this.mainBkg,this.actorTextColor=this.mainContrastColor,this.actorLineColor=this.actorBorder,this.signalColor=this.mainContrastColor,this.signalTextColor=this.mainContrastColor,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.mainContrastColor,this.loopTextColor=this.mainContrastColor,this.noteBorderColor=this.secondaryBorderColor,this.noteBkgColor=this.secondBkg,this.noteTextColor=this.secondaryTextColor,this.activationBorderColor=this.border1,this.activationBkgColor=this.secondBkg,this.altSectionBkgColor=this.background,this.taskBkgColor=A(this.mainBkg,23),this.taskTextColor=this.darkTextColor,this.taskTextLightColor=this.mainContrastColor,this.taskTextOutsideColor=this.taskTextLightColor,this.gridColor=this.mainContrastColor,this.doneTaskBkgColor=this.mainContrastColor,this.taskTextDarkColor=this.darkTextColor,this.archEdgeColor=this.lineColor,this.archEdgeArrowColor=this.lineColor,this.transitionColor=this.transitionColor||this.lineColor,this.transitionLabelColor=this.transitionLabelColor||this.textColor,this.stateLabelColor=this.stateLabelColor||this.stateBkg||this.primaryTextColor,this.stateBkg=this.stateBkg||this.mainBkg,this.labelBackgroundColor=this.labelBackgroundColor||this.stateBkg,this.compositeBackground=this.compositeBackground||this.background||this.tertiaryColor,this.altBackground=this.altBackground||"#555",this.compositeTitleBackground=this.compositeTitleBackground||this.mainBkg,this.compositeBorder=this.compositeBorder||this.nodeBorder,this.innerEndBackground=this.primaryBorderColor,this.specialStateColor="#f4f4f4",this.errorBkgColor=this.errorBkgColor||this.tertiaryColor,this.errorTextColor=this.errorTextColor||this.tertiaryTextColor,this.fillType0=this.primaryColor,this.fillType1=this.secondaryColor,this.fillType2=p(this.primaryColor,{h:64}),this.fillType3=p(this.secondaryColor,{h:64}),this.fillType4=p(this.primaryColor,{h:-64}),this.fillType5=p(this.secondaryColor,{h:-64}),this.fillType6=p(this.primaryColor,{h:128}),this.fillType7=p(this.secondaryColor,{h:128}),this.cScale1=this.cScale1||"#0b0000",this.cScale2=this.cScale2||"#4d1037",this.cScale3=this.cScale3||"#3f5258",this.cScale4=this.cScale4||"#4f2f1b",this.cScale5=this.cScale5||"#6e0a0a",this.cScale6=this.cScale6||"#3b0048",this.cScale7=this.cScale7||"#995a01",this.cScale8=this.cScale8||"#154706",this.cScale9=this.cScale9||"#161722",this.cScale10=this.cScale10||"#00296f",this.cScale11=this.cScale11||"#01629c",this.cScale12=this.cScale12||"#010029",this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330});for(let e=0;e{this[o]=e[o]}),this.updateColors(),r.forEach(o=>{this[o]=e[o]})}},ll=i(t=>{let e=new Go;return e.calculate(t),e},"getThemeVariables");var Vo=class{static{i(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#ECECFF",this.secondaryColor=p(this.primaryColor,{h:120}),this.secondaryColor="#ffffde",this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=ct(this.primaryColor,this.darkMode),this.secondaryBorderColor=ct(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ct(this.tertiaryColor,this.darkMode),this.primaryTextColor=b(this.primaryColor),this.secondaryTextColor=b(this.secondaryColor),this.tertiaryTextColor=b(this.tertiaryColor),this.lineColor=b(this.background),this.textColor=b(this.background),this.background="white",this.mainBkg="#ECECFF",this.secondBkg="#ffffde",this.lineColor="#333333",this.border1="#9370DB",this.border2="#aaaa33",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.labelBackground="rgba(232,232,232, 0.8)",this.textColor="#333",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="calculated",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="calculated",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="calculated",this.taskTextColor=this.taskTextLightColor,this.taskTextDarkColor="calculated",this.taskTextOutsideColor=this.taskTextDarkColor,this.taskTextClickableColor="calculated",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBorderColor="calculated",this.critBkgColor="calculated",this.todayLineColor="calculated",this.sectionBkgColor=se(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.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222",this.updateColors()}updateColors(){this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||R(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||R(this.tertiaryColor,40);for(let e=0;e{this[o]=e[o]}),this.updateColors(),r.forEach(o=>{this[o]=e[o]})}},hl=i(t=>{let e=new Vo;return e.calculate(t),e},"getThemeVariables");var Xo=class{static{i(this,"Theme")}constructor(){this.background="#f4f4f4",this.primaryColor="#cde498",this.secondaryColor="#cdffb2",this.background="white",this.mainBkg="#cde498",this.secondBkg="#cdffb2",this.lineColor="green",this.border1="#13540c",this.border2="#6eaa49",this.arrowheadColor="green",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.tertiaryColor=A("#cde498",10),this.primaryBorderColor=ct(this.primaryColor,this.darkMode),this.secondaryBorderColor=ct(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ct(this.tertiaryColor,this.darkMode),this.primaryTextColor=b(this.primaryColor),this.secondaryTextColor=b(this.secondaryColor),this.tertiaryTextColor=b(this.primaryColor),this.lineColor=b(this.background),this.textColor=b(this.background),this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="#333",this.edgeLabelBackground="#e8e8e8",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="black",this.actorLineColor="calculated",this.signalColor="#333",this.signalTextColor="#333",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="#326932",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="#fff5ad",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="#6eaa49",this.altSectionBkgColor="white",this.sectionBkgColor2="#6eaa49",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="#487e3a",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="black",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="lightgrey",this.doneTaskBkgColor="lightgrey",this.doneTaskBorderColor="grey",this.critBorderColor="#ff8888",this.critBkgColor="red",this.todayLineColor="red",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.actorBorder=R(this.mainBkg,20),this.actorBkg=this.mainBkg,this.labelBoxBkgColor=this.actorBkg,this.labelTextColor=this.actorTextColor,this.loopTextColor=this.actorTextColor,this.noteBorderColor=this.border2,this.noteTextColor=this.actorTextColor,this.actorLineColor=this.actorBorder,this.cScale0=this.cScale0||this.primaryColor,this.cScale1=this.cScale1||this.secondaryColor,this.cScale2=this.cScale2||this.tertiaryColor,this.cScale3=this.cScale3||p(this.primaryColor,{h:30}),this.cScale4=this.cScale4||p(this.primaryColor,{h:60}),this.cScale5=this.cScale5||p(this.primaryColor,{h:90}),this.cScale6=this.cScale6||p(this.primaryColor,{h:120}),this.cScale7=this.cScale7||p(this.primaryColor,{h:150}),this.cScale8=this.cScale8||p(this.primaryColor,{h:210}),this.cScale9=this.cScale9||p(this.primaryColor,{h:270}),this.cScale10=this.cScale10||p(this.primaryColor,{h:300}),this.cScale11=this.cScale11||p(this.primaryColor,{h:330}),this.cScalePeer1=this.cScalePeer1||R(this.secondaryColor,45),this.cScalePeer2=this.cScalePeer2||R(this.tertiaryColor,40);for(let e=0;e{this[o]=e[o]}),this.updateColors(),r.forEach(o=>{this[o]=e[o]})}},cl=i(t=>{let e=new Xo;return e.calculate(t),e},"getThemeVariables");var jo=class{static{i(this,"Theme")}constructor(){this.primaryColor="#eee",this.contrast="#707070",this.secondaryColor=A(this.contrast,55),this.background="#ffffff",this.tertiaryColor=p(this.primaryColor,{h:-160}),this.primaryBorderColor=ct(this.primaryColor,this.darkMode),this.secondaryBorderColor=ct(this.secondaryColor,this.darkMode),this.tertiaryBorderColor=ct(this.tertiaryColor,this.darkMode),this.primaryTextColor=b(this.primaryColor),this.secondaryTextColor=b(this.secondaryColor),this.tertiaryTextColor=b(this.tertiaryColor),this.lineColor=b(this.background),this.textColor=b(this.background),this.mainBkg="#eee",this.secondBkg="calculated",this.lineColor="#666",this.border1="#999",this.border2="calculated",this.note="#ffa",this.text="#333",this.critical="#d42",this.done="#bbb",this.arrowheadColor="#333333",this.fontFamily='"trebuchet ms", verdana, arial, sans-serif',this.fontSize="16px",this.THEME_COLOR_LIMIT=12,this.nodeBkg="calculated",this.nodeBorder="calculated",this.clusterBkg="calculated",this.clusterBorder="calculated",this.defaultLinkColor="calculated",this.titleColor="calculated",this.edgeLabelBackground="white",this.actorBorder="calculated",this.actorBkg="calculated",this.actorTextColor="calculated",this.actorLineColor=this.actorBorder,this.signalColor="calculated",this.signalTextColor="calculated",this.labelBoxBkgColor="calculated",this.labelBoxBorderColor="calculated",this.labelTextColor="calculated",this.loopTextColor="calculated",this.noteBorderColor="calculated",this.noteBkgColor="calculated",this.noteTextColor="calculated",this.activationBorderColor="#666",this.activationBkgColor="#f4f4f4",this.sequenceNumberColor="white",this.sectionBkgColor="calculated",this.altSectionBkgColor="white",this.sectionBkgColor2="calculated",this.excludeBkgColor="#eeeeee",this.taskBorderColor="calculated",this.taskBkgColor="calculated",this.taskTextLightColor="white",this.taskTextColor="calculated",this.taskTextDarkColor="calculated",this.taskTextOutsideColor="calculated",this.taskTextClickableColor="#003163",this.activeTaskBorderColor="calculated",this.activeTaskBkgColor="calculated",this.gridColor="calculated",this.doneTaskBkgColor="calculated",this.doneTaskBorderColor="calculated",this.critBkgColor="calculated",this.critBorderColor="calculated",this.todayLineColor="calculated",this.personBorder=this.primaryBorderColor,this.personBkg=this.mainBkg,this.archEdgeColor="calculated",this.archEdgeArrowColor="calculated",this.archEdgeWidth="3",this.archGroupBorderColor=this.primaryBorderColor,this.archGroupBorderWidth="2px",this.labelColor="black",this.errorBkgColor="#552222",this.errorTextColor="#552222"}updateColors(){this.secondBkg=A(this.contrast,55),this.border2=this.contrast,this.actorBorder=A(this.border1,23),this.actorBkg=this.mainBkg,this.actorTextColor=this.text,this.actorLineColor=this.actorBorder,this.signalColor=this.text,this.signalTextColor=this.text,this.labelBoxBkgColor=this.actorBkg,this.labelBoxBorderColor=this.actorBorder,this.labelTextColor=this.text,this.loopTextColor=this.text,this.noteBorderColor="#999",this.noteBkgColor="#666",this.noteTextColor="#fff",this.cScale0=this.cScale0||"#555",this.cScale1=this.cScale1||"#F4F4F4",this.cScale2=this.cScale2||"#555",this.cScale3=this.cScale3||"#BBB",this.cScale4=this.cScale4||"#777",this.cScale5=this.cScale5||"#999",this.cScale6=this.cScale6||"#DDD",this.cScale7=this.cScale7||"#FFF",this.cScale8=this.cScale8||"#DDD",this.cScale9=this.cScale9||"#BBB",this.cScale10=this.cScale10||"#999",this.cScale11=this.cScale11||"#777";for(let e=0;e{this[o]=e[o]}),this.updateColors(),r.forEach(o=>{this[o]=e[o]})}},ul=i(t=>{let e=new jo;return e.calculate(t),e},"getThemeVariables");var ye={base:{getThemeVariables:al},dark:{getThemeVariables:ll},default:{getThemeVariables:hl},forest:{getThemeVariables:cl},neutral:{getThemeVariables:ul}};var ae={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,hideEmptyMembersBox:!1},state:{useMaxWidth:!0,titleTopMargin:25,dividerMargin:10,sizeUnit:5,padding:8,textHeight:10,titleShift:-15,noteMargin:10,forkWidth:70,forkHeight:7,miniPadding:2,fontSizeFactor:5.02,fontSize:24,labelHeight:16,edgeLengthFactor:"20",compositTitleSize:35,radius:5,defaultRenderer:"dagre-wrapper"},er:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:20,layoutDirection:"TB",minEntityWidth:100,minEntityHeight:75,entityPadding:15,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},kanban:{useMaxWidth:!0,padding:8,sectionWidth:200,ticketBaseUrl:""},timeline:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,leftMargin:150,width:150,height:50,boxMargin:10,boxTextMargin:5,noteMargin:10,messageMargin:35,messageAlign:"center",bottomMarginAdj:1,rightAngles:!1,taskFontSize:14,taskFontFamily:'"Open Sans", sans-serif',taskMargin:50,activationWidth:10,textPlacement:"fo",actorColours:["#8FBC8F","#7CFC00","#00FFFF","#20B2AA","#B0E0E6","#FFFFE0"],sectionFills:["#191970","#8B008B","#4B0082","#2F4F4F","#800000","#8B4513","#00008B"],sectionColours:["#fff"],disableMulticolor:!1},gitGraph:{useMaxWidth:!0,titleTopMargin:25,diagramPadding:8,nodeLabel:{width:75,height:100,x:-25,y:0},mainBranchName:"main",mainBranchOrder:0,showCommitLabel:!0,showBranches:!0,rotateCommitLabel:!0,parallelCommits:!1,arrowMarkerAbsolute:!1},c4:{useMaxWidth:!0,diagramMarginX:50,diagramMarginY:10,c4ShapeMargin:50,c4ShapePadding:20,width:216,height:60,boxMargin:10,c4ShapeInRow:4,nextLinePaddingX:0,c4BoundaryInRow:2,personFontSize:14,personFontFamily:'"Open Sans", sans-serif',personFontWeight:"normal",external_personFontSize:14,external_personFontFamily:'"Open Sans", sans-serif',external_personFontWeight:"normal",systemFontSize:14,systemFontFamily:'"Open Sans", sans-serif',systemFontWeight:"normal",external_systemFontSize:14,external_systemFontFamily:'"Open Sans", sans-serif',external_systemFontWeight:"normal",system_dbFontSize:14,system_dbFontFamily:'"Open Sans", sans-serif',system_dbFontWeight:"normal",external_system_dbFontSize:14,external_system_dbFontFamily:'"Open Sans", sans-serif',external_system_dbFontWeight:"normal",system_queueFontSize:14,system_queueFontFamily:'"Open Sans", sans-serif',system_queueFontWeight:"normal",external_system_queueFontSize:14,external_system_queueFontFamily:'"Open Sans", sans-serif',external_system_queueFontWeight:"normal",boundaryFontSize:14,boundaryFontFamily:'"Open Sans", sans-serif',boundaryFontWeight:"normal",messageFontSize:12,messageFontFamily:'"Open Sans", sans-serif',messageFontWeight:"normal",containerFontSize:14,containerFontFamily:'"Open Sans", sans-serif',containerFontWeight:"normal",external_containerFontSize:14,external_containerFontFamily:'"Open Sans", sans-serif',external_containerFontWeight:"normal",container_dbFontSize:14,container_dbFontFamily:'"Open Sans", sans-serif',container_dbFontWeight:"normal",external_container_dbFontSize:14,external_container_dbFontFamily:'"Open Sans", sans-serif',external_container_dbFontWeight:"normal",container_queueFontSize:14,container_queueFontFamily:'"Open Sans", sans-serif',container_queueFontWeight:"normal",external_container_queueFontSize:14,external_container_queueFontFamily:'"Open Sans", sans-serif',external_container_queueFontWeight:"normal",componentFontSize:14,componentFontFamily:'"Open Sans", sans-serif',componentFontWeight:"normal",external_componentFontSize:14,external_componentFontFamily:'"Open Sans", sans-serif',external_componentFontWeight:"normal",component_dbFontSize:14,component_dbFontFamily:'"Open Sans", sans-serif',component_dbFontWeight:"normal",external_component_dbFontSize:14,external_component_dbFontFamily:'"Open Sans", sans-serif',external_component_dbFontWeight:"normal",component_queueFontSize:14,component_queueFontFamily:'"Open Sans", sans-serif',component_queueFontWeight:"normal",external_component_queueFontSize:14,external_component_queueFontFamily:'"Open Sans", sans-serif',external_component_queueFontWeight:"normal",wrap:!0,wrapPadding:10,person_bg_color:"#08427B",person_border_color:"#073B6F",external_person_bg_color:"#686868",external_person_border_color:"#8A8A8A",system_bg_color:"#1168BD",system_border_color:"#3C7FC0",system_db_bg_color:"#1168BD",system_db_border_color:"#3C7FC0",system_queue_bg_color:"#1168BD",system_queue_border_color:"#3C7FC0",external_system_bg_color:"#999999",external_system_border_color:"#8A8A8A",external_system_db_bg_color:"#999999",external_system_db_border_color:"#8A8A8A",external_system_queue_bg_color:"#999999",external_system_queue_border_color:"#8A8A8A",container_bg_color:"#438DD5",container_border_color:"#3C7FC0",container_db_bg_color:"#438DD5",container_db_border_color:"#3C7FC0",container_queue_bg_color:"#438DD5",container_queue_border_color:"#3C7FC0",external_container_bg_color:"#B3B3B3",external_container_border_color:"#A6A6A6",external_container_db_bg_color:"#B3B3B3",external_container_db_border_color:"#A6A6A6",external_container_queue_bg_color:"#B3B3B3",external_container_queue_border_color:"#A6A6A6",component_bg_color:"#85BBF0",component_border_color:"#78A8D8",component_db_bg_color:"#85BBF0",component_db_border_color:"#78A8D8",component_queue_bg_color:"#85BBF0",component_queue_border_color:"#78A8D8",external_component_bg_color:"#CCCCCC",external_component_border_color:"#BFBFBF",external_component_db_bg_color:"#CCCCCC",external_component_db_border_color:"#BFBFBF",external_component_queue_bg_color:"#CCCCCC",external_component_queue_border_color:"#BFBFBF"},sankey:{useMaxWidth:!0,width:600,height:400,linkColor:"gradient",nodeAlignment:"justify",showValues:!0,prefix:"",suffix:""},block:{useMaxWidth:!0,padding:8},packet:{useMaxWidth:!0,rowHeight:32,bitWidth:32,bitsPerRow:32,showBits:!0,paddingX:5,paddingY:5},architecture:{useMaxWidth:!0,padding:40,iconSize:80,fontSize:16},theme:"default",look:"classic",handDrawnSeed:0,layout:"dagre",maxTextSize:5e4,maxEdges:500,darkMode:!1,fontFamily:'"trebuchet ms", verdana, arial, sans-serif;',logLevel:5,securityLevel:"strict",startOnLoad:!0,arrowMarkerAbsolute:!1,secure:["secure","securityLevel","startOnLoad","maxTextSize","suppressErrorRendering","maxEdges"],legacyMathML:!1,forceLegacyMathML:!1,deterministicIds:!1,fontSize:16,markdownAutoWrap:!0,suppressErrorRendering:!1};var fl={...ae,deterministicIDSeed:void 0,elk:{mergeEdges:!1,nodePlacementStrategy:"BRANDES_KOEPF"},themeCSS:void 0,themeVariables:ye.default.getThemeVariables(),sequence:{...ae.sequence,messageFont:i(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont"),noteFont:i(function(){return{fontFamily:this.noteFontFamily,fontSize:this.noteFontSize,fontWeight:this.noteFontWeight}},"noteFont"),actorFont:i(function(){return{fontFamily:this.actorFontFamily,fontSize:this.actorFontSize,fontWeight:this.actorFontWeight}},"actorFont")},class:{hideEmptyMembersBox:!1},gantt:{...ae.gantt,tickInterval:void 0,useWidth:void 0},c4:{...ae.c4,useWidth:void 0,personFont:i(function(){return{fontFamily:this.personFontFamily,fontSize:this.personFontSize,fontWeight:this.personFontWeight}},"personFont"),external_personFont:i(function(){return{fontFamily:this.external_personFontFamily,fontSize:this.external_personFontSize,fontWeight:this.external_personFontWeight}},"external_personFont"),systemFont:i(function(){return{fontFamily:this.systemFontFamily,fontSize:this.systemFontSize,fontWeight:this.systemFontWeight}},"systemFont"),external_systemFont:i(function(){return{fontFamily:this.external_systemFontFamily,fontSize:this.external_systemFontSize,fontWeight:this.external_systemFontWeight}},"external_systemFont"),system_dbFont:i(function(){return{fontFamily:this.system_dbFontFamily,fontSize:this.system_dbFontSize,fontWeight:this.system_dbFontWeight}},"system_dbFont"),external_system_dbFont:i(function(){return{fontFamily:this.external_system_dbFontFamily,fontSize:this.external_system_dbFontSize,fontWeight:this.external_system_dbFontWeight}},"external_system_dbFont"),system_queueFont:i(function(){return{fontFamily:this.system_queueFontFamily,fontSize:this.system_queueFontSize,fontWeight:this.system_queueFontWeight}},"system_queueFont"),external_system_queueFont:i(function(){return{fontFamily:this.external_system_queueFontFamily,fontSize:this.external_system_queueFontSize,fontWeight:this.external_system_queueFontWeight}},"external_system_queueFont"),containerFont:i(function(){return{fontFamily:this.containerFontFamily,fontSize:this.containerFontSize,fontWeight:this.containerFontWeight}},"containerFont"),external_containerFont:i(function(){return{fontFamily:this.external_containerFontFamily,fontSize:this.external_containerFontSize,fontWeight:this.external_containerFontWeight}},"external_containerFont"),container_dbFont:i(function(){return{fontFamily:this.container_dbFontFamily,fontSize:this.container_dbFontSize,fontWeight:this.container_dbFontWeight}},"container_dbFont"),external_container_dbFont:i(function(){return{fontFamily:this.external_container_dbFontFamily,fontSize:this.external_container_dbFontSize,fontWeight:this.external_container_dbFontWeight}},"external_container_dbFont"),container_queueFont:i(function(){return{fontFamily:this.container_queueFontFamily,fontSize:this.container_queueFontSize,fontWeight:this.container_queueFontWeight}},"container_queueFont"),external_container_queueFont:i(function(){return{fontFamily:this.external_container_queueFontFamily,fontSize:this.external_container_queueFontSize,fontWeight:this.external_container_queueFontWeight}},"external_container_queueFont"),componentFont:i(function(){return{fontFamily:this.componentFontFamily,fontSize:this.componentFontSize,fontWeight:this.componentFontWeight}},"componentFont"),external_componentFont:i(function(){return{fontFamily:this.external_componentFontFamily,fontSize:this.external_componentFontSize,fontWeight:this.external_componentFontWeight}},"external_componentFont"),component_dbFont:i(function(){return{fontFamily:this.component_dbFontFamily,fontSize:this.component_dbFontSize,fontWeight:this.component_dbFontWeight}},"component_dbFont"),external_component_dbFont:i(function(){return{fontFamily:this.external_component_dbFontFamily,fontSize:this.external_component_dbFontSize,fontWeight:this.external_component_dbFontWeight}},"external_component_dbFont"),component_queueFont:i(function(){return{fontFamily:this.component_queueFontFamily,fontSize:this.component_queueFontSize,fontWeight:this.component_queueFontWeight}},"component_queueFont"),external_component_queueFont:i(function(){return{fontFamily:this.external_component_queueFontFamily,fontSize:this.external_component_queueFontSize,fontWeight:this.external_component_queueFontWeight}},"external_component_queueFont"),boundaryFont:i(function(){return{fontFamily:this.boundaryFontFamily,fontSize:this.boundaryFontSize,fontWeight:this.boundaryFontWeight}},"boundaryFont"),messageFont:i(function(){return{fontFamily:this.messageFontFamily,fontSize:this.messageFontSize,fontWeight:this.messageFontWeight}},"messageFont")},pie:{...ae.pie,useWidth:984},xyChart:{...ae.xyChart,useWidth:void 0},requirement:{...ae.requirement,useWidth:void 0},packet:{...ae.packet}},ml=i((t,e="")=>Object.keys(t).reduce((r,o)=>Array.isArray(t[o])?r:typeof t[o]=="object"&&t[o]!==null?[...r,e+o,...ml(t[o],"")]:[...r,e+o],[]),"keyify"),pl=new Set(ml(fl,"")),dl=fl;var Fi=i(t=>{if(tt.debug("sanitizeDirective called with",t),!(typeof t!="object"||t==null)){if(Array.isArray(t)){t.forEach(e=>Fi(e));return}for(let e of Object.keys(t)){if(tt.debug("Checking key",e),e.startsWith("__")||e.includes("proto")||e.includes("constr")||!pl.has(e)||t[e]==null){tt.debug("sanitize deleting key: ",e),delete t[e];continue}if(typeof t[e]=="object"){tt.debug("sanitizing object",e),Fi(t[e]);continue}let r=["themeCSS","fontFamily","altFontFamily"];for(let o of r)e.includes(o)&&(tt.debug("sanitizing css option",e),t[e]=Du(t[e]))}if(t.themeVariables)for(let e of Object.keys(t.themeVariables)){let r=t.themeVariables[e];r?.match&&!r.match(/^[\d "#%(),.;A-Za-z]+$/)&&(t.themeVariables[e]="")}tt.debug("After sanitization",t)}},"sanitizeDirective"),Du=i(t=>{let e=0,r=0;for(let o of t){if(e{let r=Lt({},t),o={};for(let n of e)Cl(n),o=Lt(o,n);if(r=Lt(r,o),o.theme&&o.theme in ye){let n=Lt({},xl),s=Lt(n.themeVariables||{},o.themeVariables);r.theme&&r.theme in ye&&(r.themeVariables=ye[r.theme].getThemeVariables(s))}return Lr=r,_l(Lr),Lr},"updateCurrentConfig"),Ou=i(t=>(Rt=Lt({},Ar),Rt=Lt(Rt,t),t.theme&&ye[t.theme]&&(Rt.themeVariables=ye[t.theme].getThemeVariables(t.themeVariables)),Mi(Rt,tr),Rt),"setSiteConfig"),eC=i(t=>{xl=Lt({},t)},"saveConfigFromInitialize"),rC=i(t=>(Rt=Lt(Rt,t),Mi(Rt,tr),Rt),"updateSiteConfig"),iC=i(()=>Lt({},Rt),"getSiteConfig"),yl=i(t=>(_l(t),Lt(Lr,t),Er()),"setConfig"),Er=i(()=>Lt({},Lr),"getConfig"),Cl=i(t=>{t&&(["secure",...Rt.secure??[]].forEach(e=>{Object.hasOwn(t,e)&&(tt.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"&&Cl(t[e])}))},"sanitize"),oC=i(t=>{Fi(t),t.fontFamily&&!t.themeVariables?.fontFamily&&(t.themeVariables={...t.themeVariables,fontFamily:t.fontFamily}),tr.push(t),Mi(Rt,tr)},"addDirective"),nC=i((t=Rt)=>{tr=[],Mi(t,tr)},"reset"),Iu={LAZY_LOAD_DEPRECATED:"The configuration options lazyLoadedDiagrams and loadExternalDiagramsAtStartup are deprecated. Please use registerExternalDiagrams instead."},gl={},Ru=i(t=>{gl[t]||(tt.warn(Iu[t]),gl[t]=!0)},"issueWarning"),_l=i(t=>{t&&(t.lazyLoadedDiagrams||t.loadExternalDiagramsAtStartup)&&Ru("LAZY_LOAD_DEPRECATED")},"checkConfig");var{entries:Ml,setPrototypeOf:bl,isFrozen:Nu,getPrototypeOf:qu,getOwnPropertyDescriptor:zu}=Object,{freeze:Et,seal:$t,create:Ll}=Object,{apply:en,construct:rn}=typeof Reflect<"u"&&Reflect;Et||(Et=i(function(e){return e},"freeze"));$t||($t=i(function(e){return e},"seal"));en||(en=i(function(e,r,o){return e.apply(r,o)},"apply"));rn||(rn=i(function(e,r){return new e(...r)},"construct"));var Li=Nt(Array.prototype.forEach),Tl=Nt(Array.prototype.pop),Dr=Nt(Array.prototype.push),Ei=Nt(String.prototype.toLowerCase),Zo=Nt(String.prototype.toString),kl=Nt(String.prototype.match),Or=Nt(String.prototype.replace),Pu=Nt(String.prototype.indexOf),$u=Nt(String.prototype.trim),Ht=Nt(Object.prototype.hasOwnProperty),At=Nt(RegExp.prototype.test),Ir=Wu(TypeError);function Nt(t){return function(e){for(var r=arguments.length,o=new Array(r>1?r-1:0),n=1;n2&&arguments[2]!==void 0?arguments[2]:Ei;bl&&bl(t,null);let o=e.length;for(;o--;){let n=e[o];if(typeof n=="string"){let s=r(n);s!==n&&(Nu(e)||(e[o]=s),n=s)}t[n]=!0}return t}i(Q,"addToSet");function Hu(t){for(let e=0;e/gm),Xu=$t(/\${[\w\W]*}/gm),ju=$t(/^data-[\-\w.\u00B7-\uFFFF]/),Zu=$t(/^aria-[\-\w]+$/),Al=$t(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Ku=$t(/^(?:\w+script|data):/i),Qu=$t(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),El=$t(/^html$/i),Ju=$t(/^[a-z][.\w]*(-[.\w]+)+$/i),Fl=Object.freeze({__proto__:null,ARIA_ATTR:Zu,ATTR_WHITESPACE:Qu,CUSTOM_ELEMENT:Ju,DATA_ATTR:ju,DOCTYPE_NAME:El,ERB_EXPR:Vu,IS_ALLOWED_URI:Al,IS_SCRIPT_OR_DATA:Ku,MUSTACHE_EXPR:Gu,TMPLIT_EXPR:Xu}),Nr={element:1,attribute:2,text:3,cdataSection:4,entityReference:5,entityNode:6,progressingInstruction:7,comment:8,document:9,documentType:10,documentFragment:11,notation:12},tf=i(function(){return typeof window>"u"?null:window},"getGlobal"),ef=i(function(e,r){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let o=null,n="data-tt-policy-suffix";r&&r.hasAttribute(n)&&(o=r.getAttribute(n));let s="dompurify"+(o?"#"+o:"");try{return e.createPolicy(s,{createHTML(a){return a},createScriptURL(a){return a}})}catch{return console.warn("TrustedTypes policy "+s+" could not be created."),null}},"_createTrustedTypesPolicy");function Dl(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:tf(),e=i(I=>Dl(I),"DOMPurify");if(e.version="3.2.1",e.removed=[],!t||!t.document||t.document.nodeType!==Nr.document)return e.isSupported=!1,e;let{document:r}=t,o=r,n=o.currentScript,{DocumentFragment:s,HTMLTemplateElement:a,Node:l,Element:c,NodeFilter:h,NamedNodeMap:u=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:d,DOMParser:f,trustedTypes:g}=t,T=c.prototype,L=Rr(T,"cloneNode"),$=Rr(T,"remove"),z=Rr(T,"nextSibling"),G=Rr(T,"childNodes"),E=Rr(T,"parentNode");if(typeof a=="function"){let I=r.createElement("template");I.content&&I.content.ownerDocument&&(r=I.content.ownerDocument)}let B,P="",{implementation:w,createNodeIterator:X,createDocumentFragment:j,getElementsByTagName:W}=r,{importNode:it}=o,M={};e.isSupported=typeof Ml=="function"&&typeof E=="function"&&w&&w.createHTMLDocument!==void 0;let{MUSTACHE_EXPR:k,ERB_EXPR:x,TMPLIT_EXPR:y,DATA_ATTR:F,ARIA_ATTR:S,IS_SCRIPT_OR_DATA:N,ATTR_WHITESPACE:O,CUSTOM_ELEMENT:U}=Fl,{IS_ALLOWED_URI:rt}=Fl,Y=null,nt=Q({},[...Sl,...Ko,...Qo,...Jo,...vl]),K=null,Ft=Q({},[...wl,...tn,...Bl,...Ai]),Z=Object.seal(Ll(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}})),Ct=null,_t=null,lt=!0,v=!0,H=!1,V=!0,C=!1,pt=!0,J=!1,bt=!1,Tt=!1,Ot=!1,Le=!1,di=!1,wa=!0,Ba=!1,ou="user-content-",Do=!0,vr=!1,Ze={},Ke=null,Fa=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"]),Ma=null,La=Q({},["audio","video","img","source","image","track"]),Oo=null,Aa=Q({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),gi="http://www.w3.org/1998/Math/MathML",xi="http://www.w3.org/2000/svg",re="http://www.w3.org/1999/xhtml",Qe=re,Io=!1,Ro=null,nu=Q({},[gi,xi,re],Zo),yi=Q({},["mi","mo","mn","ms","mtext"]),Ci=Q({},["annotation-xml"]),su=Q({},["title","style","font","a","script"]),wr=null,au=["application/xhtml+xml","text/html"],lu="text/html",dt=null,Je=null,hu=r.createElement("form"),Ea=i(function(m){return m instanceof RegExp||m instanceof Function},"isRegexOrFunction"),No=i(function(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(Je&&Je===m)){if((!m||typeof m!="object")&&(m={}),m=Ee(m),wr=au.indexOf(m.PARSER_MEDIA_TYPE)===-1?lu:m.PARSER_MEDIA_TYPE,dt=wr==="application/xhtml+xml"?Zo:Ei,Y=Ht(m,"ALLOWED_TAGS")?Q({},m.ALLOWED_TAGS,dt):nt,K=Ht(m,"ALLOWED_ATTR")?Q({},m.ALLOWED_ATTR,dt):Ft,Ro=Ht(m,"ALLOWED_NAMESPACES")?Q({},m.ALLOWED_NAMESPACES,Zo):nu,Oo=Ht(m,"ADD_URI_SAFE_ATTR")?Q(Ee(Aa),m.ADD_URI_SAFE_ATTR,dt):Aa,Ma=Ht(m,"ADD_DATA_URI_TAGS")?Q(Ee(La),m.ADD_DATA_URI_TAGS,dt):La,Ke=Ht(m,"FORBID_CONTENTS")?Q({},m.FORBID_CONTENTS,dt):Fa,Ct=Ht(m,"FORBID_TAGS")?Q({},m.FORBID_TAGS,dt):{},_t=Ht(m,"FORBID_ATTR")?Q({},m.FORBID_ATTR,dt):{},Ze=Ht(m,"USE_PROFILES")?m.USE_PROFILES:!1,lt=m.ALLOW_ARIA_ATTR!==!1,v=m.ALLOW_DATA_ATTR!==!1,H=m.ALLOW_UNKNOWN_PROTOCOLS||!1,V=m.ALLOW_SELF_CLOSE_IN_ATTR!==!1,C=m.SAFE_FOR_TEMPLATES||!1,pt=m.SAFE_FOR_XML!==!1,J=m.WHOLE_DOCUMENT||!1,Ot=m.RETURN_DOM||!1,Le=m.RETURN_DOM_FRAGMENT||!1,di=m.RETURN_TRUSTED_TYPE||!1,Tt=m.FORCE_BODY||!1,wa=m.SANITIZE_DOM!==!1,Ba=m.SANITIZE_NAMED_PROPS||!1,Do=m.KEEP_CONTENT!==!1,vr=m.IN_PLACE||!1,rt=m.ALLOWED_URI_REGEXP||Al,Qe=m.NAMESPACE||re,yi=m.MATHML_TEXT_INTEGRATION_POINTS||yi,Ci=m.HTML_INTEGRATION_POINTS||Ci,Z=m.CUSTOM_ELEMENT_HANDLING||{},m.CUSTOM_ELEMENT_HANDLING&&Ea(m.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(Z.tagNameCheck=m.CUSTOM_ELEMENT_HANDLING.tagNameCheck),m.CUSTOM_ELEMENT_HANDLING&&Ea(m.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(Z.attributeNameCheck=m.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),m.CUSTOM_ELEMENT_HANDLING&&typeof m.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(Z.allowCustomizedBuiltInElements=m.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),C&&(v=!1),Le&&(Ot=!0),Ze&&(Y=Q({},vl),K=[],Ze.html===!0&&(Q(Y,Sl),Q(K,wl)),Ze.svg===!0&&(Q(Y,Ko),Q(K,tn),Q(K,Ai)),Ze.svgFilters===!0&&(Q(Y,Qo),Q(K,tn),Q(K,Ai)),Ze.mathMl===!0&&(Q(Y,Jo),Q(K,Bl),Q(K,Ai))),m.ADD_TAGS&&(Y===nt&&(Y=Ee(Y)),Q(Y,m.ADD_TAGS,dt)),m.ADD_ATTR&&(K===Ft&&(K=Ee(K)),Q(K,m.ADD_ATTR,dt)),m.ADD_URI_SAFE_ATTR&&Q(Oo,m.ADD_URI_SAFE_ATTR,dt),m.FORBID_CONTENTS&&(Ke===Fa&&(Ke=Ee(Ke)),Q(Ke,m.FORBID_CONTENTS,dt)),Do&&(Y["#text"]=!0),J&&Q(Y,["html","head","body"]),Y.table&&(Q(Y,["tbody"]),delete Ct.tbody),m.TRUSTED_TYPES_POLICY){if(typeof m.TRUSTED_TYPES_POLICY.createHTML!="function")throw Ir('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof m.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Ir('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');B=m.TRUSTED_TYPES_POLICY,P=B.createHTML("")}else B===void 0&&(B=ef(g,n)),B!==null&&typeof P=="string"&&(P=B.createHTML(""));Et&&Et(m),Je=m}},"_parseConfig"),Da=Q({},[...Ko,...Qo,...Uu]),Oa=Q({},[...Jo,...Yu]),cu=i(function(m){let _=E(m);(!_||!_.tagName)&&(_={namespaceURI:Qe,tagName:"template"});let D=Ei(m.tagName),at=Ei(_.tagName);return Ro[m.namespaceURI]?m.namespaceURI===xi?_.namespaceURI===re?D==="svg":_.namespaceURI===gi?D==="svg"&&(at==="annotation-xml"||yi[at]):!!Da[D]:m.namespaceURI===gi?_.namespaceURI===re?D==="math":_.namespaceURI===xi?D==="math"&&Ci[at]:!!Oa[D]:m.namespaceURI===re?_.namespaceURI===xi&&!Ci[at]||_.namespaceURI===gi&&!yi[at]?!1:!Oa[D]&&(su[D]||!Da[D]):!!(wr==="application/xhtml+xml"&&Ro[m.namespaceURI]):!1},"_checkValidNamespace"),jt=i(function(m){Dr(e.removed,{element:m});try{E(m).removeChild(m)}catch{$(m)}},"_forceRemove"),_i=i(function(m,_){try{Dr(e.removed,{attribute:_.getAttributeNode(m),from:_})}catch{Dr(e.removed,{attribute:null,from:_})}if(_.removeAttribute(m),m==="is"&&!K[m])if(Ot||Le)try{jt(_)}catch{}else try{_.setAttribute(m,"")}catch{}},"_removeAttribute"),Ia=i(function(m){let _=null,D=null;if(Tt)m=""+m;else{let kt=kl(m,/^[\r\n\t ]+/);D=kt&&kt[0]}wr==="application/xhtml+xml"&&Qe===re&&(m=''+m+"");let at=B?B.createHTML(m):m;if(Qe===re)try{_=new f().parseFromString(at,wr)}catch{}if(!_||!_.documentElement){_=w.createDocument(Qe,"template",null);try{_.documentElement.innerHTML=Io?P:at}catch{}}let Bt=_.body||_.documentElement;return m&&D&&Bt.insertBefore(r.createTextNode(D),Bt.childNodes[0]||null),Qe===re?W.call(_,J?"html":"body")[0]:J?_.documentElement:Bt},"_initDocument"),Ra=i(function(m){return X.call(m.ownerDocument||m,m,h.SHOW_ELEMENT|h.SHOW_COMMENT|h.SHOW_TEXT|h.SHOW_PROCESSING_INSTRUCTION|h.SHOW_CDATA_SECTION,null)},"_createNodeIterator"),Na=i(function(m){return m instanceof d&&(typeof m.nodeName!="string"||typeof m.textContent!="string"||typeof m.removeChild!="function"||!(m.attributes instanceof u)||typeof m.removeAttribute!="function"||typeof m.setAttribute!="function"||typeof m.namespaceURI!="string"||typeof m.insertBefore!="function"||typeof m.hasChildNodes!="function")},"_isClobbered"),qa=i(function(m){return typeof l=="function"&&m instanceof l},"_isNode");function ie(I,m,_){M[I]&&Li(M[I],D=>{D.call(e,m,_,Je)})}i(ie,"_executeHook");let za=i(function(m){let _=null;if(ie("beforeSanitizeElements",m,null),Na(m))return jt(m),!0;let D=dt(m.nodeName);if(ie("uponSanitizeElement",m,{tagName:D,allowedTags:Y}),m.hasChildNodes()&&!qa(m.firstElementChild)&&At(/<[/\w]/g,m.innerHTML)&&At(/<[/\w]/g,m.textContent)||m.nodeType===Nr.progressingInstruction||pt&&m.nodeType===Nr.comment&&At(/<[/\w]/g,m.data))return jt(m),!0;if(!Y[D]||Ct[D]){if(!Ct[D]&&$a(D)&&(Z.tagNameCheck instanceof RegExp&&At(Z.tagNameCheck,D)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(D)))return!1;if(Do&&!Ke[D]){let at=E(m)||m.parentNode,Bt=G(m)||m.childNodes;if(Bt&&at){let kt=Bt.length;for(let It=kt-1;It>=0;--It){let Zt=L(Bt[It],!0);Zt.__removalCount=(m.__removalCount||0)+1,at.insertBefore(Zt,z(m))}}}return jt(m),!0}return m instanceof c&&!cu(m)||(D==="noscript"||D==="noembed"||D==="noframes")&&At(/<\/no(script|embed|frames)/i,m.innerHTML)?(jt(m),!0):(C&&m.nodeType===Nr.text&&(_=m.textContent,Li([k,x,y],at=>{_=Or(_,at," ")}),m.textContent!==_&&(Dr(e.removed,{element:m.cloneNode()}),m.textContent=_)),ie("afterSanitizeElements",m,null),!1)},"_sanitizeElements"),Pa=i(function(m,_,D){if(wa&&(_==="id"||_==="name")&&(D in r||D in hu))return!1;if(!(v&&!_t[_]&&At(F,_))){if(!(lt&&At(S,_))){if(!K[_]||_t[_]){if(!($a(m)&&(Z.tagNameCheck instanceof RegExp&&At(Z.tagNameCheck,m)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(m))&&(Z.attributeNameCheck instanceof RegExp&&At(Z.attributeNameCheck,_)||Z.attributeNameCheck instanceof Function&&Z.attributeNameCheck(_))||_==="is"&&Z.allowCustomizedBuiltInElements&&(Z.tagNameCheck instanceof RegExp&&At(Z.tagNameCheck,D)||Z.tagNameCheck instanceof Function&&Z.tagNameCheck(D))))return!1}else if(!Oo[_]){if(!At(rt,Or(D,O,""))){if(!((_==="src"||_==="xlink:href"||_==="href")&&m!=="script"&&Pu(D,"data:")===0&&Ma[m])){if(!(H&&!At(N,Or(D,O,"")))){if(D)return!1}}}}}}return!0},"_isValidAttribute"),$a=i(function(m){return m!=="annotation-xml"&&kl(m,U)},"_isBasicCustomElement"),Wa=i(function(m){ie("beforeSanitizeAttributes",m,null);let{attributes:_}=m;if(!_)return;let D={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:K,forceKeepAttr:void 0},at=_.length;for(;at--;){let Bt=_[at],{name:kt,namespaceURI:It,value:Zt}=Bt,Br=dt(kt),Mt=kt==="value"?Zt:$u(Zt);if(D.attrName=Br,D.attrValue=Mt,D.keepAttr=!0,D.forceKeepAttr=void 0,ie("uponSanitizeAttribute",m,D),Mt=D.attrValue,Ba&&(Br==="id"||Br==="name")&&(_i(kt,m),Mt=ou+Mt),pt&&At(/((--!?|])>)|<\/(style|title)/i,Mt)){_i(kt,m);continue}if(D.forceKeepAttr||(_i(kt,m),!D.keepAttr))continue;if(!V&&At(/\/>/i,Mt)){_i(kt,m);continue}C&&Li([k,x,y],Ua=>{Mt=Or(Mt,Ua," ")});let Ha=dt(m.nodeName);if(Pa(Ha,Br,Mt)){if(B&&typeof g=="object"&&typeof g.getAttributeType=="function"&&!It)switch(g.getAttributeType(Ha,Br)){case"TrustedHTML":{Mt=B.createHTML(Mt);break}case"TrustedScriptURL":{Mt=B.createScriptURL(Mt);break}}try{It?m.setAttributeNS(It,kt,Mt):m.setAttribute(kt,Mt),Na(m)?jt(m):Tl(e.removed)}catch{}}}ie("afterSanitizeAttributes",m,null)},"_sanitizeAttributes"),uu=i(function I(m){let _=null,D=Ra(m);for(ie("beforeSanitizeShadowDOM",m,null);_=D.nextNode();)ie("uponSanitizeShadowNode",_,null),!za(_)&&(_.content instanceof s&&I(_.content),Wa(_));ie("afterSanitizeShadowDOM",m,null)},"_sanitizeShadowDOM");return e.sanitize=function(I){let m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},_=null,D=null,at=null,Bt=null;if(Io=!I,Io&&(I=""),typeof I!="string"&&!qa(I))if(typeof I.toString=="function"){if(I=I.toString(),typeof I!="string")throw Ir("dirty is not a string, aborting")}else throw Ir("toString is not a function");if(!e.isSupported)return I;if(bt||No(m),e.removed=[],typeof I=="string"&&(vr=!1),vr){if(I.nodeName){let Zt=dt(I.nodeName);if(!Y[Zt]||Ct[Zt])throw Ir("root node is forbidden and cannot be sanitized in-place")}}else if(I instanceof l)_=Ia(""),D=_.ownerDocument.importNode(I,!0),D.nodeType===Nr.element&&D.nodeName==="BODY"||D.nodeName==="HTML"?_=D:_.appendChild(D);else{if(!Ot&&!C&&!J&&I.indexOf("<")===-1)return B&&di?B.createHTML(I):I;if(_=Ia(I),!_)return Ot?null:di?P:""}_&&Tt&&jt(_.firstChild);let kt=Ra(vr?I:_);for(;at=kt.nextNode();)za(at)||(at.content instanceof s&&uu(at.content),Wa(at));if(vr)return I;if(Ot){if(Le)for(Bt=j.call(_.ownerDocument);_.firstChild;)Bt.appendChild(_.firstChild);else Bt=_;return(K.shadowroot||K.shadowrootmode)&&(Bt=it.call(o,Bt,!0)),Bt}let It=J?_.outerHTML:_.innerHTML;return J&&Y["!doctype"]&&_.ownerDocument&&_.ownerDocument.doctype&&_.ownerDocument.doctype.name&&At(El,_.ownerDocument.doctype.name)&&(It=" +`+It),C&&Li([k,x,y],Zt=>{It=Or(It,Zt," ")}),B&&di?B.createHTML(It):It},e.setConfig=function(){let I=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};No(I),bt=!0},e.clearConfig=function(){Je=null,bt=!1},e.isValidAttribute=function(I,m,_){Je||No({});let D=dt(I),at=dt(m);return Pa(D,at,_)},e.addHook=function(I,m){typeof m=="function"&&(M[I]=M[I]||[],Dr(M[I],m))},e.removeHook=function(I){if(M[I])return Tl(M[I])},e.removeHooks=function(I){M[I]&&(M[I]=[])},e.removeAllHooks=function(){M={}},e}i(Dl,"createDOMPurify");var er=Dl();var qr=//gi,rf=i(t=>t?ql(t).replace(/\\n/g,"#br#").split("#br#"):[""],"getRows"),of=(()=>{let t=!1;return()=>{t||(nf(),t=!0)}})();function nf(){let t="data-temp-href-target";er.addHook("beforeSanitizeAttributes",e=>{e instanceof Element&&e.tagName==="A"&&e.hasAttribute("target")&&e.setAttribute(t,e.getAttribute("target")??"")}),er.addHook("afterSanitizeAttributes",e=>{e instanceof Element&&e.tagName==="A"&&e.hasAttribute(t)&&(e.setAttribute("target",e.getAttribute(t)??""),e.removeAttribute(t),e.getAttribute("target")==="_blank"&&e.setAttribute("rel","noopener"))})}i(nf,"setupDompurifyHooks");var Nl=i(t=>(of(),er.sanitize(t)),"removeScript"),Ol=i((t,e)=>{if(e.flowchart?.htmlLabels!==!1){let r=e.securityLevel;r==="antiscript"||r==="strict"?t=Nl(t):r!=="loose"&&(t=ql(t),t=t.replace(//g,">"),t=t.replace(/=/g,"="),t=hf(t))}return t},"sanitizeMore"),De=i((t,e)=>t&&(e.dompurifyConfig?t=er.sanitize(Ol(t,e),e.dompurifyConfig).toString():t=er.sanitize(Ol(t,e),{FORBID_TAGS:["style"]}).toString(),t),"sanitizeText"),sf=i((t,e)=>typeof t=="string"?De(t,e):t.flat().map(r=>De(r,e)),"sanitizeTextOrArray"),af=i(t=>qr.test(t),"hasBreaks"),lf=i(t=>t.split(qr),"splitBreaks"),hf=i(t=>t.replace(/#br#/g,"
    "),"placeholderToBreak"),ql=i(t=>t.replace(qr,"#br#"),"breakToPlaceholder"),cf=i(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},"getUrl"),uf=i(t=>!(t===!1||["false","null","0"].includes(String(t).trim().toLowerCase())),"evaluate"),ff=i(function(...t){let e=t.filter(r=>!isNaN(r));return Math.max(...e)},"getMax"),mf=i(function(...t){let e=t.filter(r=>!isNaN(r));return Math.min(...e)},"getMin"),uC=i(function(t){let e=t.split(/(,)/),r=[];for(let o=0;o0&&o+1Math.max(0,t.split(e).length-1),"countOccurrence"),pf=i((t,e)=>{let r=on(t,"~"),o=on(e,"~");return r===1&&o===1},"shouldCombineSets"),df=i(t=>{let e=on(t,"~"),r=!1;if(e<=1)return t;e%2!==0&&t.startsWith("~")&&(t=t.substring(1),r=!0);let o=[...t],n=o.indexOf("~"),s=o.lastIndexOf("~");for(;n!==-1&&s!==-1&&n!==s;)o[n]="<",o[s]=">",n=o.indexOf("~"),s=o.lastIndexOf("~");return r&&o.unshift("~"),o.join("")},"processSet"),Il=i(()=>window.MathMLElement!==void 0,"isMathMLSupported"),nn=/\$\$(.*)\$\$/g,Rl=i(t=>(t.match(nn)?.length??0)>0,"hasKatex"),fC=i(async(t,e)=>{t=await gf(t,e);let r=document.createElement("div");r.innerHTML=t,r.id="katex-temp",r.style.visibility="hidden",r.style.position="absolute",r.style.top="0",document.querySelector("body")?.insertAdjacentElement("beforeend",r);let n={width:r.clientWidth,height:r.clientHeight};return r.remove(),n},"calculateMathMLDimensions"),gf=i(async(t,e)=>{if(!Rl(t))return t;if(!(Il()||e.legacyMathML||e.forceLegacyMathML))return t.replace(nn,"MathML is unsupported in this environment.");let{default:r}=await import("./katex-SWYD7GD6.mjs"),o=e.forceLegacyMathML||!Il()&&e.legacyMathML?"htmlAndMathml":"mathml";return t.split(qr).map(n=>Rl(n)?`
    ${n}
    `:`
    ${n}
    `).join("").replace(nn,(n,s)=>r.renderToString(s,{throwOnError:!0,displayMode:!0,output:o}).replace(/\n/g," ").replace(//g,""))},"renderKatex"),mC={getRows:rf,sanitizeText:De,sanitizeTextOrArray:sf,hasBreaks:af,splitBreaks:lf,lineBreakRegex:qr,removeScript:Nl,getUrl:cf,evaluate:uf,getMax:ff,getMin:mf};var xf=i(function(t,e){for(let r of e)t.attr(r[0],r[1])},"d3Attrs"),yf=i(function(t,e,r){let o=new Map;return r?(o.set("width","100%"),o.set("style",`max-width: ${e}px;`)):(o.set("height",t),o.set("width",e)),o},"calculateSvgSizeAttrs"),Cf=i(function(t,e,r,o){let n=yf(e,r,o);xf(t,n)},"configureSvgSize"),zl=i(function(t,e,r,o){let n=e.node().getBBox(),s=n.width,a=n.height;tt.info(`SVG bounds: ${s}x${a}`,n);let l=0,c=0;tt.info(`Graph bounds: ${l}x${c}`,t),l=s+r*2,c=a+r*2,tt.info(`Calculated bounds: ${l}x${c}`),Cf(e,c,l,o);let h=`${n.x-r} ${n.y-r} ${n.width+2*r} ${n.height+2*r}`;e.attr("viewBox",h)},"setupGraphViewbox");var Di={},_f=i((t,e,r)=>{let o="";return t in Di&&Di[t]?o=Di[t](r):tt.warn(`No theme found for ${t}`),` & { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + fill: ${r.textColor} + } + + /* Classes common for multiple diagrams */ + + & .error-icon { + fill: ${r.errorBkgColor}; + } + & .error-text { + fill: ${r.errorTextColor}; + stroke: ${r.errorTextColor}; + } + + & .edge-thickness-normal { + stroke-width: 1px; + } + & .edge-thickness-thick { + stroke-width: 3.5px + } + & .edge-pattern-solid { + stroke-dasharray: 0; + } + & .edge-thickness-invisible { + stroke-width: 0; + fill: none; + } + & .edge-pattern-dashed{ + stroke-dasharray: 3; + } + .edge-pattern-dotted { + stroke-dasharray: 2; + } + + & .marker { + fill: ${r.lineColor}; + stroke: ${r.lineColor}; + } + & .marker.cross { + stroke: ${r.lineColor}; + } + + & svg { + font-family: ${r.fontFamily}; + font-size: ${r.fontSize}; + } + & p { + margin: 0 + } + + ${o} + + ${e} +`},"getStyles"),Pl=i((t,e)=>{e!==void 0&&(Di[t]=e)},"addStylesForDiagram"),_C=_f;var cn={};mu(cn,{clear:()=>bf,getAccDescription:()=>vf,getAccTitle:()=>kf,getDiagramTitle:()=>Bf,setAccDescription:()=>Sf,setAccTitle:()=>Tf,setDiagramTitle:()=>wf});var sn="",an="",ln="",hn=i(t=>De(t,Er()),"sanitizeText"),bf=i(()=>{sn="",ln="",an=""},"clear"),Tf=i(t=>{sn=hn(t).replace(/^\s+/g,"")},"setAccTitle"),kf=i(()=>sn,"getAccTitle"),Sf=i(t=>{ln=hn(t).replace(/\n\s+/g,` +`)},"setAccDescription"),vf=i(()=>ln,"getAccDescription"),wf=i(t=>{an=hn(t)},"setDiagramTitle"),Bf=i(()=>an,"getDiagramTitle");var $l=tt,Ff=Va,Wl=Er,EC=yl,DC=Ar;var Mf=i(t=>De(t,Wl()),"sanitizeText"),Lf=zl,Af=i(()=>cn,"getCommonDb"),Oi={},OC=i((t,e,r)=>{Oi[t]&&$l.warn(`Diagram with id ${t} already registered. Overwriting.`),Oi[t]=e,r&&Po(t,r),Pl(t,e.styles),e.injectUtils?.($l,Ff,Wl,Mf,Lf,Af(),()=>{})},"registerDiagram"),IC=i(t=>{if(t in Oi)return Oi[t];throw new un(t)},"getDiagram"),un=class extends Error{static{i(this,"DiagramNotFoundError")}constructor(e){super(`Diagram ${e} not found.`)}};function Hl(t,e){let r;if(e===void 0)for(let o of t)o!=null&&(r=o)&&(r=o);else{let o=-1;for(let n of t)(n=e(n,++o,t))!=null&&(r=n)&&(r=n)}return r}i(Hl,"max");function Ul(t,e){let r;if(e===void 0)for(let o of t)o!=null&&(r>o||r===void 0&&o>=o)&&(r=o);else{let o=-1;for(let n of t)(n=e(n,++o,t))!=null&&(r>n||r===void 0&&n>=n)&&(r=n)}return r}i(Ul,"min");function Oe(t,e){return t==null||e==null?NaN:te?1:t>=e?0:NaN}i(Oe,"ascending");function fn(t,e){return t==null||e==null?NaN:et?1:e>=t?0:NaN}i(fn,"descending");function Ie(t){let e,r,o;t.length!==2?(e=Oe,r=i((l,c)=>Oe(t(l),c),"compare2"),o=i((l,c)=>t(l)-c,"delta")):(e=t===Oe||t===fn?t:Ef,r=t,o=t);function n(l,c,h=0,u=l.length){if(h>>1;r(l[d],c)<0?h=d+1:u=d}while(h>>1;r(l[d],c)<=0?h=d+1:u=d}while(hh&&o(l[d-1],c)>-o(l[d],c)?d-1:d}return i(a,"center"),{left:n,center:a,right:s}}i(Ie,"bisector");function Ef(){return 0}i(Ef,"zero");function mn(t){return t===null?NaN:+t}i(mn,"number");var Yl=Ie(Oe),Gl=Yl.right,Df=Yl.left,Of=Ie(mn).center,pn=Gl;var rr=class extends Map{static{i(this,"InternMap")}constructor(e,r=Nf){if(super(),Object.defineProperties(this,{_intern:{value:new Map},_key:{value:r}}),e!=null)for(let[o,n]of e)this.set(o,n)}get(e){return super.get(Vl(this,e))}has(e){return super.has(Vl(this,e))}set(e,r){return super.set(If(this,e),r)}delete(e){return super.delete(Rf(this,e))}};function Vl({_intern:t,_key:e},r){let o=e(r);return t.has(o)?t.get(o):r}i(Vl,"intern_get");function If({_intern:t,_key:e},r){let o=e(r);return t.has(o)?t.get(o):(t.set(o,r),r)}i(If,"intern_set");function Rf({_intern:t,_key:e},r){let o=e(r);return t.has(o)&&(r=t.get(o),t.delete(o)),r}i(Rf,"intern_delete");function Nf(t){return t!==null&&typeof t=="object"?t.valueOf():t}i(Nf,"keyof");var qf=Math.sqrt(50),zf=Math.sqrt(10),Pf=Math.sqrt(2);function Ii(t,e,r){let o=(e-t)/Math.max(0,r),n=Math.floor(Math.log10(o)),s=o/Math.pow(10,n),a=s>=qf?10:s>=zf?5:s>=Pf?2:1,l,c,h;return n<0?(h=Math.pow(10,-n)/a,l=Math.round(t*h),c=Math.round(e*h),l/he&&--c,h=-h):(h=Math.pow(10,n)*a,l=Math.round(t/h),c=Math.round(e/h),l*he&&--c),c0))return[];if(t===e)return[t];let o=e=n))return[];let l=s-n+1,c=new Array(l);if(o)if(a<0)for(let h=0;h+t(e)}i(Hf,"number");function Uf(t,e){return e=Math.max(0,t.bandwidth()-e*2)/2,t.round()&&(e=Math.round(e)),r=>+t(r)+e}i(Uf,"center");function Yf(){return!this.__axis}i(Yf,"entering");function jl(t,e){var r=[],o=null,n=null,s=6,a=6,l=3,c=typeof window<"u"&&window.devicePixelRatio>1?0:.5,h=t===zi||t===qi?-1:1,u=t===qi||t===gn?"x":"y",d=t===zi||t===xn?$f:Wf;function f(g){var T=o??(e.ticks?e.ticks.apply(e,r):e.domain()),L=n??(e.tickFormat?e.tickFormat.apply(e,r):dn),$=Math.max(s,0)+l,z=e.range(),G=+z[0]+c,E=+z[z.length-1]+c,B=(e.bandwidth?Uf:Hf)(e.copy(),c),P=g.selection?g.selection():g,w=P.selectAll(".domain").data([null]),X=P.selectAll(".tick").data(T,e).order(),j=X.exit(),W=X.enter().append("g").attr("class","tick"),it=X.select("line"),M=X.select("text");w=w.merge(w.enter().insert("path",".tick").attr("class","domain").attr("stroke","currentColor")),X=X.merge(W),it=it.merge(W.append("line").attr("stroke","currentColor").attr(u+"2",h*s)),M=M.merge(W.append("text").attr("fill","currentColor").attr(u,h*$).attr("dy",t===zi?"0em":t===xn?"0.71em":"0.32em")),g!==P&&(w=w.transition(g),X=X.transition(g),it=it.transition(g),M=M.transition(g),j=j.transition(g).attr("opacity",Xl).attr("transform",function(k){return isFinite(k=B(k))?d(k+c):this.getAttribute("transform")}),W.attr("opacity",Xl).attr("transform",function(k){var x=this.parentNode.__axis;return d((x&&isFinite(x=x(k))?x:B(k))+c)})),j.remove(),w.attr("d",t===qi||t===gn?a?"M"+h*a+","+G+"H"+c+"V"+E+"H"+h*a:"M"+c+","+G+"V"+E:a?"M"+G+","+h*a+"V"+c+"H"+E+"V"+h*a:"M"+G+","+c+"H"+E),X.attr("opacity",1).attr("transform",function(k){return d(B(k)+c)}),it.attr(u+"2",h*s),M.attr(u,h*$).text(L),P.filter(Yf).attr("fill","none").attr("font-size",10).attr("font-family","sans-serif").attr("text-anchor",t===gn?"start":t===qi?"end":"middle"),P.each(function(){this.__axis=B})}return i(f,"axis"),f.scale=function(g){return arguments.length?(e=g,f):e},f.ticks=function(){return r=Array.from(arguments),f},f.tickArguments=function(g){return arguments.length?(r=g==null?[]:Array.from(g),f):r.slice()},f.tickValues=function(g){return arguments.length?(o=g==null?null:Array.from(g),f):o&&o.slice()},f.tickFormat=function(g){return arguments.length?(n=g,f):n},f.tickSize=function(g){return arguments.length?(s=a=+g,f):s},f.tickSizeInner=function(g){return arguments.length?(s=+g,f):s},f.tickSizeOuter=function(g){return arguments.length?(a=+g,f):a},f.tickPadding=function(g){return arguments.length?(l=+g,f):l},f.offset=function(g){return arguments.length?(c=+g,f):c},f}i(jl,"axis");function Gf(t){return jl(zi,t)}i(Gf,"axisTop");function Vf(t){return jl(xn,t)}i(Vf,"axisBottom");function Xf(){}i(Xf,"none");function Ce(t){return t==null?Xf:function(){return this.querySelector(t)}}i(Ce,"default");function yn(t){typeof t!="function"&&(t=Ce(t));for(var e=this._groups,r=e.length,o=new Array(r),n=0;n=E&&(E=G+1);!(P=$[E])&&++E=0;)(a=o[n])&&(s&&a.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(a,s),s=a);return this}i(Ln,"default");function An(t){t||(t=am);function e(d,f){return d&&f?t(d.__data__,f.__data__):!d-!f}i(e,"compareNode");for(var r=this._groups,o=r.length,n=new Array(o),s=0;se?1:t>=e?0:NaN}i(am,"ascending");function En(){var t=arguments[0];return arguments[0]=this,t.apply(null,arguments),this}i(En,"default");function Dn(){return Array.from(this)}i(Dn,"default");function On(){for(var t=this._groups,e=0,r=t.length;e=0&&(e=t.slice(0,r))!=="xmlns"&&(t=t.slice(r+1)),qn.hasOwnProperty(e)?{space:qn[e],local:t}:t}i(Kt,"default");function lm(t){return function(){this.removeAttribute(t)}}i(lm,"attrRemove");function hm(t){return function(){this.removeAttributeNS(t.space,t.local)}}i(hm,"attrRemoveNS");function cm(t,e){return function(){this.setAttribute(t,e)}}i(cm,"attrConstant");function um(t,e){return function(){this.setAttributeNS(t.space,t.local,e)}}i(um,"attrConstantNS");function fm(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttribute(t):this.setAttribute(t,r)}}i(fm,"attrFunction");function mm(t,e){return function(){var r=e.apply(this,arguments);r==null?this.removeAttributeNS(t.space,t.local):this.setAttributeNS(t.space,t.local,r)}}i(mm,"attrFunctionNS");function zn(t,e){var r=Kt(t);if(arguments.length<2){var o=this.node();return r.local?o.getAttributeNS(r.space,r.local):o.getAttribute(r)}return this.each((e==null?r.local?hm:lm:typeof e=="function"?r.local?mm:fm:r.local?um:cm)(r,e))}i(zn,"default");function Wr(t){return t.ownerDocument&&t.ownerDocument.defaultView||t.document&&t||t.defaultView}i(Wr,"default");function pm(t){return function(){this.style.removeProperty(t)}}i(pm,"styleRemove");function dm(t,e,r){return function(){this.style.setProperty(t,e,r)}}i(dm,"styleConstant");function gm(t,e,r){return function(){var o=e.apply(this,arguments);o==null?this.style.removeProperty(t):this.style.setProperty(t,o,r)}}i(gm,"styleFunction");function Pn(t,e,r){return arguments.length>1?this.each((e==null?pm:typeof e=="function"?gm:dm)(t,e,r??"")):_e(this.node(),t)}i(Pn,"default");function _e(t,e){return t.style.getPropertyValue(e)||Wr(t).getComputedStyle(t,null).getPropertyValue(e)}i(_e,"styleValue");function xm(t){return function(){delete this[t]}}i(xm,"propertyRemove");function ym(t,e){return function(){this[t]=e}}i(ym,"propertyConstant");function Cm(t,e){return function(){var r=e.apply(this,arguments);r==null?delete this[t]:this[t]=r}}i(Cm,"propertyFunction");function $n(t,e){return arguments.length>1?this.each((e==null?xm:typeof e=="function"?Cm:ym)(t,e)):this.node()[t]}i($n,"default");function Zl(t){return t.trim().split(/^|\s+/)}i(Zl,"classArray");function Wn(t){return t.classList||new Kl(t)}i(Wn,"classList");function Kl(t){this._node=t,this._names=Zl(t.getAttribute("class")||"")}i(Kl,"ClassList");Kl.prototype={add:i(function(t){var e=this._names.indexOf(t);e<0&&(this._names.push(t),this._node.setAttribute("class",this._names.join(" ")))},"add"),remove:i(function(t){var e=this._names.indexOf(t);e>=0&&(this._names.splice(e,1),this._node.setAttribute("class",this._names.join(" ")))},"remove"),contains:i(function(t){return this._names.indexOf(t)>=0},"contains")};function Ql(t,e){for(var r=Wn(t),o=-1,n=e.length;++o=0&&(r=e.slice(o+1),e=e.slice(0,o)),{type:e,name:r}})}i(qm,"parseTypenames");function zm(t){return function(){var e=this.__on;if(e){for(var r=0,o=-1,n=e.length,s;r>8&15|e>>4&240,e>>4&15|e&240,(e&15)<<4|e&15,1):r===8?Wi(e>>24&255,e>>16&255,e>>8&255,(e&255)/255):r===4?Wi(e>>12&15|e>>8&240,e>>8&15|e>>4&240,e>>4&15|e&240,((e&15)<<4|e&15)/255):null):(e=Ym.exec(t))?new St(e[1],e[2],e[3],1):(e=Gm.exec(t))?new St(e[1]*255/100,e[2]*255/100,e[3]*255/100,1):(e=Vm.exec(t))?Wi(e[1],e[2],e[3],e[4]):(e=Xm.exec(t))?Wi(e[1]*255/100,e[2]*255/100,e[3]*255/100,e[4]):(e=jm.exec(t))?hh(e[1],e[2]/100,e[3]/100,1):(e=Zm.exec(t))?hh(e[1],e[2]/100,e[3]/100,e[4]):ih.hasOwnProperty(t)?sh(ih[t]):t==="transparent"?new St(NaN,NaN,NaN,0):null}i(Yt,"color");function sh(t){return new St(t>>16&255,t>>8&255,t&255,1)}i(sh,"rgbn");function Wi(t,e,r,o){return o<=0&&(t=e=r=NaN),new St(t,e,r,o)}i(Wi,"rgba");function os(t){return t instanceof Te||(t=Yt(t)),t?(t=t.rgb(),new St(t.r,t.g,t.b,t.opacity)):new St}i(os,"rgbConvert");function lr(t,e,r,o){return arguments.length===1?os(t):new St(t,e,r,o??1)}i(lr,"rgb");function St(t,e,r,o){this.r=+t,this.g=+e,this.b=+r,this.opacity=+o}i(St,"Rgb");be(St,lr,sr(Te,{brighter(t){return t=t==null?Ui:Math.pow(Ui,t),new St(this.r*t,this.g*t,this.b*t,this.opacity)},darker(t){return t=t==null?Ur:Math.pow(Ur,t),new St(this.r*t,this.g*t,this.b*t,this.opacity)},rgb(){return this},clamp(){return new St(Ne(this.r),Ne(this.g),Ne(this.b),Yi(this.opacity))},displayable(){return-.5<=this.r&&this.r<255.5&&-.5<=this.g&&this.g<255.5&&-.5<=this.b&&this.b<255.5&&0<=this.opacity&&this.opacity<=1},hex:ah,formatHex:ah,formatHex8:Jm,formatRgb:lh,toString:lh}));function ah(){return`#${Re(this.r)}${Re(this.g)}${Re(this.b)}`}i(ah,"rgb_formatHex");function Jm(){return`#${Re(this.r)}${Re(this.g)}${Re(this.b)}${Re((isNaN(this.opacity)?1:this.opacity)*255)}`}i(Jm,"rgb_formatHex8");function lh(){let t=Yi(this.opacity);return`${t===1?"rgb(":"rgba("}${Ne(this.r)}, ${Ne(this.g)}, ${Ne(this.b)}${t===1?")":`, ${t})`}`}i(lh,"rgb_formatRgb");function Yi(t){return isNaN(t)?1:Math.max(0,Math.min(1,t))}i(Yi,"clampa");function Ne(t){return Math.max(0,Math.min(255,Math.round(t)||0))}i(Ne,"clampi");function Re(t){return t=Ne(t),(t<16?"0":"")+t.toString(16)}i(Re,"hex");function hh(t,e,r,o){return o<=0?t=e=r=NaN:r<=0||r>=1?t=e=NaN:e<=0&&(t=NaN),new Ut(t,e,r,o)}i(hh,"hsla");function uh(t){if(t instanceof Ut)return new Ut(t.h,t.s,t.l,t.opacity);if(t instanceof Te||(t=Yt(t)),!t)return new Ut;if(t instanceof Ut)return t;t=t.rgb();var e=t.r/255,r=t.g/255,o=t.b/255,n=Math.min(e,r,o),s=Math.max(e,r,o),a=NaN,l=s-n,c=(s+n)/2;return l?(e===s?a=(r-o)/l+(r0&&c<1?0:a,new Ut(a,l,c,t.opacity)}i(uh,"hslConvert");function fh(t,e,r,o){return arguments.length===1?uh(t):new Ut(t,e,r,o??1)}i(fh,"hsl");function Ut(t,e,r,o){this.h=+t,this.s=+e,this.l=+r,this.opacity=+o}i(Ut,"Hsl");be(Ut,fh,sr(Te,{brighter(t){return t=t==null?Ui:Math.pow(Ui,t),new Ut(this.h,this.s,this.l*t,this.opacity)},darker(t){return t=t==null?Ur:Math.pow(Ur,t),new Ut(this.h,this.s,this.l*t,this.opacity)},rgb(){var t=this.h%360+(this.h<0)*360,e=isNaN(t)||isNaN(this.s)?0:this.s,r=this.l,o=r+(r<.5?r:1-r)*e,n=2*r-o;return new St(is(t>=240?t-240:t+120,n,o),is(t,n,o),is(t<120?t+240:t-120,n,o),this.opacity)},clamp(){return new Ut(ch(this.h),Hi(this.s),Hi(this.l),Yi(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){let t=Yi(this.opacity);return`${t===1?"hsl(":"hsla("}${ch(this.h)}, ${Hi(this.s)*100}%, ${Hi(this.l)*100}%${t===1?")":`, ${t})`}`}}));function ch(t){return t=(t||0)%360,t<0?t+360:t}i(ch,"clamph");function Hi(t){return Math.max(0,Math.min(1,t||0))}i(Hi,"clampt");function is(t,e,r){return(t<60?e+(r-e)*t/60:t<180?r:t<240?e+(r-e)*(240-t)/60:e)*255}i(is,"hsl2rgb");var mh=Math.PI/180,ph=180/Math.PI;var Gi=18,dh=.96422,gh=1,xh=.82521,yh=4/29,hr=6/29,Ch=3*hr*hr,tp=hr*hr*hr;function _h(t){if(t instanceof Jt)return new Jt(t.l,t.a,t.b,t.opacity);if(t instanceof he)return bh(t);t instanceof St||(t=os(t));var e=ls(t.r),r=ls(t.g),o=ls(t.b),n=ns((.2225045*e+.7168786*r+.0606169*o)/gh),s,a;return e===r&&r===o?s=a=n:(s=ns((.4360747*e+.3850649*r+.1430804*o)/dh),a=ns((.0139322*e+.0971045*r+.7141733*o)/xh)),new Jt(116*n-16,500*(s-n),200*(n-a),t.opacity)}i(_h,"labConvert");function hs(t,e,r,o){return arguments.length===1?_h(t):new Jt(t,e,r,o??1)}i(hs,"lab");function Jt(t,e,r,o){this.l=+t,this.a=+e,this.b=+r,this.opacity=+o}i(Jt,"Lab");be(Jt,hs,sr(Te,{brighter(t){return new Jt(this.l+Gi*(t??1),this.a,this.b,this.opacity)},darker(t){return new Jt(this.l-Gi*(t??1),this.a,this.b,this.opacity)},rgb(){var t=(this.l+16)/116,e=isNaN(this.a)?t:t+this.a/500,r=isNaN(this.b)?t:t-this.b/200;return e=dh*ss(e),t=gh*ss(t),r=xh*ss(r),new St(as(3.1338561*e-1.6168667*t-.4906146*r),as(-.9787684*e+1.9161415*t+.033454*r),as(.0719453*e-.2289914*t+1.4052427*r),this.opacity)}}));function ns(t){return t>tp?Math.pow(t,1/3):t/Ch+yh}i(ns,"xyz2lab");function ss(t){return t>hr?t*t*t:Ch*(t-yh)}i(ss,"lab2xyz");function as(t){return 255*(t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055)}i(as,"lrgb2rgb");function ls(t){return(t/=255)<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}i(ls,"rgb2lrgb");function ep(t){if(t instanceof he)return new he(t.h,t.c,t.l,t.opacity);if(t instanceof Jt||(t=_h(t)),t.a===0&&t.b===0)return new he(NaN,0()=>t,"default");function Th(t,e){return function(r){return t+r*e}}i(Th,"linear");function rp(t,e,r){return t=Math.pow(t,r),e=Math.pow(e,r)-t,r=1/r,function(o){return Math.pow(t+o*e,r)}}i(rp,"exponential");function kh(t,e){var r=e-t;return r?Th(t,r>180||r<-180?r-360*Math.round(r/360):r):cr(isNaN(t)?e:t)}i(kh,"hue");function Sh(t){return(t=+t)==1?ce:function(e,r){return r-e?rp(e,r,t):cr(isNaN(e)?r:e)}}i(Sh,"gamma");function ce(t,e){var r=e-t;return r?Th(t,r):cr(isNaN(t)?e:t)}i(ce,"nogamma");function vh(t){return function(e,r){var o=t((e=Gr(e)).h,(r=Gr(r)).h),n=ce(e.c,r.c),s=ce(e.l,r.l),a=ce(e.opacity,r.opacity);return function(l){return e.h=o(l),e.c=n(l),e.l=s(l),e.opacity=a(l),e+""}}}i(vh,"hcl");var ip=vh(kh),op=vh(ce);function cs(t,e,r,o,n){var s=t*t,a=s*t;return((1-3*t+3*s-a)*e+(4-6*s+3*a)*r+(1+3*t+3*s-3*a)*o+a*n)/6}i(cs,"basis");function us(t){var e=t.length-1;return function(r){var o=r<=0?r=0:r>=1?(r=1,e-1):Math.floor(r*e),n=t[o],s=t[o+1],a=o>0?t[o-1]:2*n-s,l=or&&(s=e.slice(r,s),l[a]?l[a]+=s:l[++a]=s),(o=o[0])===(n=n[0])?l[a]?l[a]+=n:l[++a]=n:(l[++a]=null,c.push({i:a,x:gt(o,n)})),r=gs.lastIndex;return r180?u+=360:u-h>180&&(h+=360),f.push({i:d.push(n(d)+"rotate(",null,o)-2,x:gt(h,u)})):u&&d.push(n(d)+"rotate("+u+o)}i(a,"rotate");function l(h,u,d,f){h!==u?f.push({i:d.push(n(d)+"skewX(",null,o)-2,x:gt(h,u)}):u&&d.push(n(d)+"skewX("+u+o)}i(l,"skewX");function c(h,u,d,f,g,T){if(h!==d||u!==f){var L=g.push(n(g)+"scale(",null,",",null,")");T.push({i:L-4,x:gt(h,d)},{i:L-2,x:gt(u,f)})}else(d!==1||f!==1)&&g.push(n(g)+"scale("+d+","+f+")")}return i(c,"scale"),function(h,u){var d=[],f=[];return h=t(h),u=t(u),s(h.translateX,h.translateY,u.translateX,u.translateY,d,f),a(h.rotate,u.rotate,d,f),l(h.skewX,u.skewX,d,f),c(h.scaleX,h.scaleY,u.scaleX,u.scaleY,d,f),h=u=null,function(g){for(var T=-1,L=f.length,$;++Te&&(r=t,t=e,e=r),function(o){return Math.max(t,Math.min(e,o))}}i(hp,"clamper");function cp(t,e,r){var o=t[0],n=t[1],s=e[0],a=e[1];return n2?up:cp,c=h=null,d}i(u,"rescale");function d(f){return f==null||isNaN(f=+f)?s:(c||(c=l(t.map(o),e,r)))(o(a(f)))}return i(d,"scale"),d.invert=function(f){return a(n((h||(h=l(e,t.map(o),gt)))(f)))},d.domain=function(f){return arguments.length?(t=Array.from(f,Ts),u()):t.slice()},d.range=function(f){return arguments.length?(e=Array.from(f),u()):e.slice()},d.rangeRound=function(f){return e=Array.from(f),r=Vi,u()},d.clamp=function(f){return arguments.length?(a=f?!0:fr,u()):a!==fr},d.interpolate=function(f){return arguments.length?(r=f,u()):r},d.unknown=function(f){return arguments.length?(s=f,d):s},function(f,g){return o=f,n=g,u()}}i(fp,"transformer");function Xr(){return fp()(fr,fr)}i(Xr,"continuous");function Ss(t){return Math.abs(t=Math.round(t))>=1e21?t.toLocaleString("en").replace(/,/g,""):t.toString(10)}i(Ss,"default");function ze(t,e){if((r=(t=e?t.toExponential(e-1):t.toExponential()).indexOf("e"))<0)return null;var r,o=t.slice(0,r);return[o.length>1?o[0]+o.slice(2):o,+t.slice(r+1)]}i(ze,"formatDecimalParts");function Gt(t){return t=ze(Math.abs(t)),t?t[1]:NaN}i(Gt,"default");function vs(t,e){return function(r,o){for(var n=r.length,s=[],a=0,l=t[0],c=0;n>0&&l>0&&(c+l+1>o&&(l=Math.max(1,o-c)),s.push(r.substring(n-=l,n+l)),!((c+=l+1)>o));)l=t[a=(a+1)%t.length];return s.reverse().join(e)}}i(vs,"default");function ws(t){return function(e){return e.replace(/[0-9]/g,function(r){return t[+r]})}}i(ws,"default");var mp=/^(?:(.)?([<>=^]))?([+\-( ])?([$#])?(0)?(\d+)?(,)?(\.\d+)?(~)?([a-z%])?$/i;function ve(t){if(!(e=mp.exec(t)))throw new Error("invalid format: "+t);var e;return new Qi({fill:e[1],align:e[2],sign:e[3],symbol:e[4],zero:e[5],width:e[6],comma:e[7],precision:e[8]&&e[8].slice(1),trim:e[9],type:e[10]})}i(ve,"formatSpecifier");ve.prototype=Qi.prototype;function Qi(t){this.fill=t.fill===void 0?" ":t.fill+"",this.align=t.align===void 0?">":t.align+"",this.sign=t.sign===void 0?"-":t.sign+"",this.symbol=t.symbol===void 0?"":t.symbol+"",this.zero=!!t.zero,this.width=t.width===void 0?void 0:+t.width,this.comma=!!t.comma,this.precision=t.precision===void 0?void 0:+t.precision,this.trim=!!t.trim,this.type=t.type===void 0?"":t.type+""}i(Qi,"FormatSpecifier");Qi.prototype.toString=function(){return this.fill+this.align+this.sign+this.symbol+(this.zero?"0":"")+(this.width===void 0?"":Math.max(1,this.width|0))+(this.comma?",":"")+(this.precision===void 0?"":"."+Math.max(0,this.precision|0))+(this.trim?"~":"")+this.type};function Bs(t){t:for(var e=t.length,r=1,o=-1,n;r0&&(o=0);break}return o>0?t.slice(0,o)+t.slice(n+1):t}i(Bs,"default");var Fs;function Ms(t,e){var r=ze(t,e);if(!r)return t+"";var o=r[0],n=r[1],s=n-(Fs=Math.max(-8,Math.min(8,Math.floor(n/3)))*3)+1,a=o.length;return s===a?o:s>a?o+new Array(s-a+1).join("0"):s>0?o.slice(0,s)+"."+o.slice(s):"0."+new Array(1-s).join("0")+ze(t,Math.max(0,e+s-1))[0]}i(Ms,"default");function Ji(t,e){var r=ze(t,e);if(!r)return t+"";var o=r[0],n=r[1];return n<0?"0."+new Array(-n).join("0")+o:o.length>n+1?o.slice(0,n+1)+"."+o.slice(n+1):o+new Array(n-o.length+2).join("0")}i(Ji,"default");var Ls={"%":i((t,e)=>(t*100).toFixed(e),"%"),b:i(t=>Math.round(t).toString(2),"b"),c:i(t=>t+"","c"),d:Ss,e:i((t,e)=>t.toExponential(e),"e"),f:i((t,e)=>t.toFixed(e),"f"),g:i((t,e)=>t.toPrecision(e),"g"),o:i(t=>Math.round(t).toString(8),"o"),p:i((t,e)=>Ji(t*100,e),"p"),r:Ji,s:Ms,X:i(t=>Math.round(t).toString(16).toUpperCase(),"X"),x:i(t=>Math.round(t).toString(16),"x")};function to(t){return t}i(to,"default");var Oh=Array.prototype.map,Ih=["y","z","a","f","p","n","\xB5","m","","k","M","G","T","P","E","Z","Y"];function As(t){var e=t.grouping===void 0||t.thousands===void 0?to:vs(Oh.call(t.grouping,Number),t.thousands+""),r=t.currency===void 0?"":t.currency[0]+"",o=t.currency===void 0?"":t.currency[1]+"",n=t.decimal===void 0?".":t.decimal+"",s=t.numerals===void 0?to:ws(Oh.call(t.numerals,String)),a=t.percent===void 0?"%":t.percent+"",l=t.minus===void 0?"\u2212":t.minus+"",c=t.nan===void 0?"NaN":t.nan+"";function h(d){d=ve(d);var f=d.fill,g=d.align,T=d.sign,L=d.symbol,$=d.zero,z=d.width,G=d.comma,E=d.precision,B=d.trim,P=d.type;P==="n"?(G=!0,P="g"):Ls[P]||(E===void 0&&(E=12),B=!0,P="g"),($||f==="0"&&g==="=")&&($=!0,f="0",g="=");var w=L==="$"?r:L==="#"&&/[boxX]/.test(P)?"0"+P.toLowerCase():"",X=L==="$"?o:/[%p]/.test(P)?a:"",j=Ls[P],W=/[defgprs%]/.test(P);E=E===void 0?6:/[gprs]/.test(P)?Math.max(1,Math.min(21,E)):Math.max(0,Math.min(20,E));function it(M){var k=w,x=X,y,F,S;if(P==="c")x=j(M)+x,M="";else{M=+M;var N=M<0||1/M<0;if(M=isNaN(M)?c:j(Math.abs(M),E),B&&(M=Bs(M)),N&&+M==0&&T!=="+"&&(N=!1),k=(N?T==="("?T:l:T==="-"||T==="("?"":T)+k,x=(P==="s"?Ih[8+Fs/3]:"")+x+(N&&T==="("?")":""),W){for(y=-1,F=M.length;++yS||S>57){x=(S===46?n+M.slice(y+1):M.slice(y))+x,M=M.slice(0,y);break}}}G&&!$&&(M=e(M,1/0));var O=k.length+M.length+x.length,U=O>1)+k+M+x+U.slice(O);break;default:M=U+k+M+x;break}return s(M)}return i(it,"format"),it.toString=function(){return d+""},it}i(h,"newFormat");function u(d,f){var g=h((d=ve(d),d.type="f",d)),T=Math.max(-8,Math.min(8,Math.floor(Gt(f)/3)))*3,L=Math.pow(10,-T),$=Ih[8+T/3];return function(z){return g(L*z)+$}}return i(u,"formatPrefix"),{format:h,formatPrefix:u}}i(As,"default");var eo,ro,io;Es({thousands:",",grouping:[3],currency:["$",""]});function Es(t){return eo=As(t),ro=eo.format,io=eo.formatPrefix,eo}i(Es,"defaultLocale");function oo(t){return Math.max(0,-Gt(Math.abs(t)))}i(oo,"default");function no(t,e){return Math.max(0,Math.max(-8,Math.min(8,Math.floor(Gt(e)/3)))*3-Gt(Math.abs(t)))}i(no,"default");function so(t,e){return t=Math.abs(t),e=Math.abs(e)-t,Math.max(0,Gt(e)-Gt(t))+1}i(so,"default");function Ds(t,e,r,o){var n=ir(t,e,r),s;switch(o=ve(o??",f"),o.type){case"s":{var a=Math.max(Math.abs(t),Math.abs(e));return o.precision==null&&!isNaN(s=no(n,a))&&(o.precision=s),io(o,a)}case"":case"e":case"g":case"p":case"r":{o.precision==null&&!isNaN(s=so(n,Math.max(Math.abs(t),Math.abs(e))))&&(o.precision=s-(o.type==="e"));break}case"f":case"%":{o.precision==null&&!isNaN(s=oo(n))&&(o.precision=s-(o.type==="%")*2);break}}return ro(o)}i(Ds,"tickFormat");function pp(t){var e=t.domain;return t.ticks=function(r){var o=e();return Ri(o[0],o[o.length-1],r??10)},t.tickFormat=function(r,o){var n=e();return Ds(n[0],n[n.length-1],r??10,o)},t.nice=function(r){r==null&&(r=10);var o=e(),n=0,s=o.length-1,a=o[n],l=o[s],c,h,u=10;for(l0;){if(h=zr(a,l,r),h===c)return o[n]=a,o[s]=l,e(o);if(h>0)a=Math.floor(a/h)*h,l=Math.ceil(l/h)*h;else if(h<0)a=Math.ceil(a*h)/h,l=Math.floor(l*h)/h;else break;c=h}return t},t}i(pp,"linearish");function Os(){var t=Xr();return t.copy=function(){return Ki(t,Os())},Se.apply(t,arguments),pp(t)}i(Os,"linear");var Is=new Date,Rs=new Date;function ot(t,e,r,o){function n(s){return t(s=arguments.length===0?new Date:new Date(+s)),s}return i(n,"interval"),n.floor=s=>(t(s=new Date(+s)),s),n.ceil=s=>(t(s=new Date(s-1)),e(s,1),t(s),s),n.round=s=>{let a=n(s),l=n.ceil(s);return s-a(e(s=new Date(+s),a==null?1:Math.floor(a)),s),n.range=(s,a,l)=>{let c=[];if(s=n.ceil(s),l=l==null?1:Math.floor(l),!(s0))return c;let h;do c.push(h=new Date(+s)),e(s,l),t(s);while(hot(a=>{if(a>=a)for(;t(a),!s(a);)a.setTime(a-1)},(a,l)=>{if(a>=a)if(l<0)for(;++l<=0;)for(;e(a,-1),!s(a););else for(;--l>=0;)for(;e(a,1),!s(a););}),r&&(n.count=(s,a)=>(Is.setTime(+s),Rs.setTime(+a),t(Is),t(Rs),Math.floor(r(Is,Rs))),n.every=s=>(s=Math.floor(s),!isFinite(s)||!(s>0)?null:s>1?n.filter(o?a=>o(a)%s===0:a=>n.count(0,a)%s===0):n)),n}i(ot,"timeInterval");var Pe=ot(()=>{},(t,e)=>{t.setTime(+t+e)},(t,e)=>e-t);Pe.every=t=>(t=Math.floor(t),!isFinite(t)||!(t>0)?null:t>1?ot(e=>{e.setTime(Math.floor(e/t)*t)},(e,r)=>{e.setTime(+e+r*t)},(e,r)=>(r-e)/t):Pe);var Rh=Pe.range;var te=ot(t=>{t.setTime(t-t.getMilliseconds())},(t,e)=>{t.setTime(+t+e*1e3)},(t,e)=>(e-t)/1e3,t=>t.getUTCSeconds()),Nh=te.range;var mr=ot(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getMinutes()),dp=mr.range,ao=ot(t=>{t.setUTCSeconds(0,0)},(t,e)=>{t.setTime(+t+e*6e4)},(t,e)=>(e-t)/6e4,t=>t.getUTCMinutes()),gp=ao.range;var pr=ot(t=>{t.setTime(t-t.getMilliseconds()-t.getSeconds()*1e3-t.getMinutes()*6e4)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getHours()),xp=pr.range,lo=ot(t=>{t.setUTCMinutes(0,0,0)},(t,e)=>{t.setTime(+t+e*36e5)},(t,e)=>(e-t)/36e5,t=>t.getUTCHours()),yp=lo.range;var ue=ot(t=>t.setHours(0,0,0,0),(t,e)=>t.setDate(t.getDate()+e),(t,e)=>(e-t-(e.getTimezoneOffset()-t.getTimezoneOffset())*6e4)/864e5,t=>t.getDate()-1),Cp=ue.range,Zr=ot(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>t.getUTCDate()-1),_p=Zr.range,ho=ot(t=>{t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCDate(t.getUTCDate()+e)},(t,e)=>(e-t)/864e5,t=>Math.floor(t/864e5)),bp=ho.range;function He(t){return ot(e=>{e.setDate(e.getDate()-(e.getDay()+7-t)%7),e.setHours(0,0,0,0)},(e,r)=>{e.setDate(e.getDate()+r*7)},(e,r)=>(r-e-(r.getTimezoneOffset()-e.getTimezoneOffset())*6e4)/6048e5)}i(He,"timeWeekday");var fe=He(0),dr=He(1),zh=He(2),Ph=He(3),we=He(4),$h=He(5),Wh=He(6),Hh=fe.range,Tp=dr.range,kp=zh.range,Sp=Ph.range,vp=we.range,wp=$h.range,Bp=Wh.range;function Ue(t){return ot(e=>{e.setUTCDate(e.getUTCDate()-(e.getUTCDay()+7-t)%7),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCDate(e.getUTCDate()+r*7)},(e,r)=>(r-e)/6048e5)}i(Ue,"utcWeekday");var Ye=Ue(0),gr=Ue(1),Uh=Ue(2),Yh=Ue(3),Be=Ue(4),Gh=Ue(5),Vh=Ue(6),Xh=Ye.range,Fp=gr.range,Mp=Uh.range,Lp=Yh.range,Ap=Be.range,Ep=Gh.range,Dp=Vh.range;var xr=ot(t=>{t.setDate(1),t.setHours(0,0,0,0)},(t,e)=>{t.setMonth(t.getMonth()+e)},(t,e)=>e.getMonth()-t.getMonth()+(e.getFullYear()-t.getFullYear())*12,t=>t.getMonth()),Op=xr.range,co=ot(t=>{t.setUTCDate(1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCMonth(t.getUTCMonth()+e)},(t,e)=>e.getUTCMonth()-t.getUTCMonth()+(e.getUTCFullYear()-t.getUTCFullYear())*12,t=>t.getUTCMonth()),Ip=co.range;var qt=ot(t=>{t.setMonth(0,1),t.setHours(0,0,0,0)},(t,e)=>{t.setFullYear(t.getFullYear()+e)},(t,e)=>e.getFullYear()-t.getFullYear(),t=>t.getFullYear());qt.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:ot(e=>{e.setFullYear(Math.floor(e.getFullYear()/t)*t),e.setMonth(0,1),e.setHours(0,0,0,0)},(e,r)=>{e.setFullYear(e.getFullYear()+r*t)});var Rp=qt.range,Vt=ot(t=>{t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0)},(t,e)=>{t.setUTCFullYear(t.getUTCFullYear()+e)},(t,e)=>e.getUTCFullYear()-t.getUTCFullYear(),t=>t.getUTCFullYear());Vt.every=t=>!isFinite(t=Math.floor(t))||!(t>0)?null:ot(e=>{e.setUTCFullYear(Math.floor(e.getUTCFullYear()/t)*t),e.setUTCMonth(0,1),e.setUTCHours(0,0,0,0)},(e,r)=>{e.setUTCFullYear(e.getUTCFullYear()+r*t)});var Np=Vt.range;function Zh(t,e,r,o,n,s){let a=[[te,1,1e3],[te,5,5*1e3],[te,15,15*1e3],[te,30,30*1e3],[s,1,6e4],[s,5,5*6e4],[s,15,15*6e4],[s,30,30*6e4],[n,1,36e5],[n,3,3*36e5],[n,6,6*36e5],[n,12,12*36e5],[o,1,864e5],[o,2,2*864e5],[r,1,6048e5],[e,1,2592e6],[e,3,3*2592e6],[t,1,31536e6]];function l(h,u,d){let f=u$).right(a,f);if(g===a.length)return t.every(ir(h/31536e6,u/31536e6,d));if(g===0)return Pe.every(Math.max(ir(h,u,d),1));let[T,L]=a[f/a[g-1][2]53)return null;"w"in C||(C.w=1),"Z"in C?(J=Ps(Kr(C.y,0,1)),bt=J.getUTCDay(),J=bt>4||bt===0?gr.ceil(J):gr(J),J=Zr.offset(J,(C.V-1)*7),C.y=J.getUTCFullYear(),C.m=J.getUTCMonth(),C.d=J.getUTCDate()+(C.w+6)%7):(J=zs(Kr(C.y,0,1)),bt=J.getDay(),J=bt>4||bt===0?dr.ceil(J):dr(J),J=ue.offset(J,(C.V-1)*7),C.y=J.getFullYear(),C.m=J.getMonth(),C.d=J.getDate()+(C.w+6)%7)}else("W"in C||"U"in C)&&("w"in C||(C.w="u"in C?C.u%7:"W"in C?1:0),bt="Z"in C?Ps(Kr(C.y,0,1)).getUTCDay():zs(Kr(C.y,0,1)).getDay(),C.m=0,C.d="W"in C?(C.w+6)%7+C.W*7-(bt+5)%7:C.w+C.U*7-(bt+6)%7);return"Z"in C?(C.H+=C.Z/100|0,C.M+=C.Z%100,Ps(C)):zs(C)}}i(X,"newParse");function j(v,H,V,C){for(var pt=0,J=H.length,bt=V.length,Tt,Ot;pt=bt)return-1;if(Tt=H.charCodeAt(pt++),Tt===37){if(Tt=H.charAt(pt++),Ot=P[Tt in Kh?H.charAt(pt++):Tt],!Ot||(C=Ot(v,V,C))<0)return-1}else if(Tt!=V.charCodeAt(C++))return-1}return C}i(j,"parseSpecifier");function W(v,H,V){var C=h.exec(H.slice(V));return C?(v.p=u.get(C[0].toLowerCase()),V+C[0].length):-1}i(W,"parsePeriod");function it(v,H,V){var C=g.exec(H.slice(V));return C?(v.w=T.get(C[0].toLowerCase()),V+C[0].length):-1}i(it,"parseShortWeekday");function M(v,H,V){var C=d.exec(H.slice(V));return C?(v.w=f.get(C[0].toLowerCase()),V+C[0].length):-1}i(M,"parseWeekday");function k(v,H,V){var C=z.exec(H.slice(V));return C?(v.m=G.get(C[0].toLowerCase()),V+C[0].length):-1}i(k,"parseShortMonth");function x(v,H,V){var C=L.exec(H.slice(V));return C?(v.m=$.get(C[0].toLowerCase()),V+C[0].length):-1}i(x,"parseMonth");function y(v,H,V){return j(v,e,H,V)}i(y,"parseLocaleDateTime");function F(v,H,V){return j(v,r,H,V)}i(F,"parseLocaleDate");function S(v,H,V){return j(v,o,H,V)}i(S,"parseLocaleTime");function N(v){return a[v.getDay()]}i(N,"formatShortWeekday");function O(v){return s[v.getDay()]}i(O,"formatWeekday");function U(v){return c[v.getMonth()]}i(U,"formatShortMonth");function rt(v){return l[v.getMonth()]}i(rt,"formatMonth");function Y(v){return n[+(v.getHours()>=12)]}i(Y,"formatPeriod");function nt(v){return 1+~~(v.getMonth()/3)}i(nt,"formatQuarter");function K(v){return a[v.getUTCDay()]}i(K,"formatUTCShortWeekday");function Ft(v){return s[v.getUTCDay()]}i(Ft,"formatUTCWeekday");function Z(v){return c[v.getUTCMonth()]}i(Z,"formatUTCShortMonth");function Ct(v){return l[v.getUTCMonth()]}i(Ct,"formatUTCMonth");function _t(v){return n[+(v.getUTCHours()>=12)]}i(_t,"formatUTCPeriod");function lt(v){return 1+~~(v.getUTCMonth()/3)}return i(lt,"formatUTCQuarter"),{format:i(function(v){var H=w(v+="",E);return H.toString=function(){return v},H},"format"),parse:i(function(v){var H=X(v+="",!1);return H.toString=function(){return v},H},"parse"),utcFormat:i(function(v){var H=w(v+="",B);return H.toString=function(){return v},H},"utcFormat"),utcParse:i(function(v){var H=X(v+="",!0);return H.toString=function(){return v},H},"utcParse")}}i($s,"formatLocale");var Kh={"-":"",_:" ",0:"0"},xt=/^\s*\d+/,$p=/^%/,Wp=/[\\^$*+?|[\]().{}]/g;function et(t,e,r){var o=t<0?"-":"",n=(o?-t:t)+"",s=n.length;return o+(s[e.toLowerCase(),r]))}i(Jr,"formatLookup");function Up(t,e,r){var o=xt.exec(e.slice(r,r+1));return o?(t.w=+o[0],r+o[0].length):-1}i(Up,"parseWeekdayNumberSunday");function Yp(t,e,r){var o=xt.exec(e.slice(r,r+1));return o?(t.u=+o[0],r+o[0].length):-1}i(Yp,"parseWeekdayNumberMonday");function Gp(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.U=+o[0],r+o[0].length):-1}i(Gp,"parseWeekNumberSunday");function Vp(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.V=+o[0],r+o[0].length):-1}i(Vp,"parseWeekNumberISO");function Xp(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.W=+o[0],r+o[0].length):-1}i(Xp,"parseWeekNumberMonday");function Qh(t,e,r){var o=xt.exec(e.slice(r,r+4));return o?(t.y=+o[0],r+o[0].length):-1}i(Qh,"parseFullYear");function Jh(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.y=+o[0]+(+o[0]>68?1900:2e3),r+o[0].length):-1}i(Jh,"parseYear");function jp(t,e,r){var o=/^(Z)|([+-]\d\d)(?::?(\d\d))?/.exec(e.slice(r,r+6));return o?(t.Z=o[1]?0:-(o[2]+(o[3]||"00")),r+o[0].length):-1}i(jp,"parseZone");function Zp(t,e,r){var o=xt.exec(e.slice(r,r+1));return o?(t.q=o[0]*3-3,r+o[0].length):-1}i(Zp,"parseQuarter");function Kp(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.m=o[0]-1,r+o[0].length):-1}i(Kp,"parseMonthNumber");function tc(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.d=+o[0],r+o[0].length):-1}i(tc,"parseDayOfMonth");function Qp(t,e,r){var o=xt.exec(e.slice(r,r+3));return o?(t.m=0,t.d=+o[0],r+o[0].length):-1}i(Qp,"parseDayOfYear");function ec(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.H=+o[0],r+o[0].length):-1}i(ec,"parseHour24");function Jp(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.M=+o[0],r+o[0].length):-1}i(Jp,"parseMinutes");function td(t,e,r){var o=xt.exec(e.slice(r,r+2));return o?(t.S=+o[0],r+o[0].length):-1}i(td,"parseSeconds");function ed(t,e,r){var o=xt.exec(e.slice(r,r+3));return o?(t.L=+o[0],r+o[0].length):-1}i(ed,"parseMilliseconds");function rd(t,e,r){var o=xt.exec(e.slice(r,r+6));return o?(t.L=Math.floor(o[0]/1e3),r+o[0].length):-1}i(rd,"parseMicroseconds");function id(t,e,r){var o=$p.exec(e.slice(r,r+1));return o?r+o[0].length:-1}i(id,"parseLiteralPercent");function od(t,e,r){var o=xt.exec(e.slice(r));return o?(t.Q=+o[0],r+o[0].length):-1}i(od,"parseUnixTimestamp");function nd(t,e,r){var o=xt.exec(e.slice(r));return o?(t.s=+o[0],r+o[0].length):-1}i(nd,"parseUnixTimestampSeconds");function rc(t,e){return et(t.getDate(),e,2)}i(rc,"formatDayOfMonth");function sd(t,e){return et(t.getHours(),e,2)}i(sd,"formatHour24");function ad(t,e){return et(t.getHours()%12||12,e,2)}i(ad,"formatHour12");function ld(t,e){return et(1+ue.count(qt(t),t),e,3)}i(ld,"formatDayOfYear");function ac(t,e){return et(t.getMilliseconds(),e,3)}i(ac,"formatMilliseconds");function hd(t,e){return ac(t,e)+"000"}i(hd,"formatMicroseconds");function cd(t,e){return et(t.getMonth()+1,e,2)}i(cd,"formatMonthNumber");function ud(t,e){return et(t.getMinutes(),e,2)}i(ud,"formatMinutes");function fd(t,e){return et(t.getSeconds(),e,2)}i(fd,"formatSeconds");function md(t){var e=t.getDay();return e===0?7:e}i(md,"formatWeekdayNumberMonday");function pd(t,e){return et(fe.count(qt(t)-1,t),e,2)}i(pd,"formatWeekNumberSunday");function lc(t){var e=t.getDay();return e>=4||e===0?we(t):we.ceil(t)}i(lc,"dISO");function dd(t,e){return t=lc(t),et(we.count(qt(t),t)+(qt(t).getDay()===4),e,2)}i(dd,"formatWeekNumberISO");function gd(t){return t.getDay()}i(gd,"formatWeekdayNumberSunday");function xd(t,e){return et(dr.count(qt(t)-1,t),e,2)}i(xd,"formatWeekNumberMonday");function yd(t,e){return et(t.getFullYear()%100,e,2)}i(yd,"formatYear");function Cd(t,e){return t=lc(t),et(t.getFullYear()%100,e,2)}i(Cd,"formatYearISO");function _d(t,e){return et(t.getFullYear()%1e4,e,4)}i(_d,"formatFullYear");function bd(t,e){var r=t.getDay();return t=r>=4||r===0?we(t):we.ceil(t),et(t.getFullYear()%1e4,e,4)}i(bd,"formatFullYearISO");function Td(t){var e=t.getTimezoneOffset();return(e>0?"-":(e*=-1,"+"))+et(e/60|0,"0",2)+et(e%60,"0",2)}i(Td,"formatZone");function ic(t,e){return et(t.getUTCDate(),e,2)}i(ic,"formatUTCDayOfMonth");function kd(t,e){return et(t.getUTCHours(),e,2)}i(kd,"formatUTCHour24");function Sd(t,e){return et(t.getUTCHours()%12||12,e,2)}i(Sd,"formatUTCHour12");function vd(t,e){return et(1+Zr.count(Vt(t),t),e,3)}i(vd,"formatUTCDayOfYear");function hc(t,e){return et(t.getUTCMilliseconds(),e,3)}i(hc,"formatUTCMilliseconds");function wd(t,e){return hc(t,e)+"000"}i(wd,"formatUTCMicroseconds");function Bd(t,e){return et(t.getUTCMonth()+1,e,2)}i(Bd,"formatUTCMonthNumber");function Fd(t,e){return et(t.getUTCMinutes(),e,2)}i(Fd,"formatUTCMinutes");function Md(t,e){return et(t.getUTCSeconds(),e,2)}i(Md,"formatUTCSeconds");function Ld(t){var e=t.getUTCDay();return e===0?7:e}i(Ld,"formatUTCWeekdayNumberMonday");function Ad(t,e){return et(Ye.count(Vt(t)-1,t),e,2)}i(Ad,"formatUTCWeekNumberSunday");function cc(t){var e=t.getUTCDay();return e>=4||e===0?Be(t):Be.ceil(t)}i(cc,"UTCdISO");function Ed(t,e){return t=cc(t),et(Be.count(Vt(t),t)+(Vt(t).getUTCDay()===4),e,2)}i(Ed,"formatUTCWeekNumberISO");function Dd(t){return t.getUTCDay()}i(Dd,"formatUTCWeekdayNumberSunday");function Od(t,e){return et(gr.count(Vt(t)-1,t),e,2)}i(Od,"formatUTCWeekNumberMonday");function Id(t,e){return et(t.getUTCFullYear()%100,e,2)}i(Id,"formatUTCYear");function Rd(t,e){return t=cc(t),et(t.getUTCFullYear()%100,e,2)}i(Rd,"formatUTCYearISO");function Nd(t,e){return et(t.getUTCFullYear()%1e4,e,4)}i(Nd,"formatUTCFullYear");function qd(t,e){var r=t.getUTCDay();return t=r>=4||r===0?Be(t):Be.ceil(t),et(t.getUTCFullYear()%1e4,e,4)}i(qd,"formatUTCFullYearISO");function zd(){return"+0000"}i(zd,"formatUTCZone");function oc(){return"%"}i(oc,"formatLiteralPercent");function nc(t){return+t}i(nc,"formatUnixTimestamp");function sc(t){return Math.floor(+t/1e3)}i(sc,"formatUnixTimestampSeconds");var yr,uo,uc,fc,mc;Ws({dateTime:"%x, %X",date:"%-m/%-d/%Y",time:"%-I:%M:%S %p",periods:["AM","PM"],days:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"],shortDays:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],months:["January","February","March","April","May","June","July","August","September","October","November","December"],shortMonths:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"]});function Ws(t){return yr=$s(t),uo=yr.format,uc=yr.parse,fc=yr.utcFormat,mc=yr.utcParse,yr}i(Ws,"defaultLocale");function Hs(t,e){t=t.slice();var r=0,o=t.length-1,n=t[r],s=t[o],a;return s1?0:t<-1?Cr:Math.acos(t)}i(xc,"acos");function Vs(t){return t>=1?ti:t<=-1?-ti:Math.asin(t)}i(Vs,"asin");var Xs=Math.PI,js=2*Xs,Ve=1e-6,Hd=js-Ve;function yc(t){this._+=t[0];for(let e=1,r=t.length;e=0))throw new Error(`invalid digits: ${t}`);if(e>15)return yc;let r=10**e;return function(o){this._+=o[0];for(let n=1,s=o.length;nVe)if(!(Math.abs(d*c-h*u)>Ve)||!s)this._append`L${this._x1=e},${this._y1=r}`;else{let g=o-a,T=n-l,L=c*c+h*h,$=g*g+T*T,z=Math.sqrt(L),G=Math.sqrt(f),E=s*Math.tan((Xs-Math.acos((L+f-$)/(2*z*G)))/2),B=E/G,P=E/z;Math.abs(B-1)>Ve&&this._append`L${e+B*u},${r+B*d}`,this._append`A${s},${s},0,0,${+(d*g>u*T)},${this._x1=e+P*c},${this._y1=r+P*h}`}}arc(e,r,o,n,s,a){if(e=+e,r=+r,o=+o,a=!!a,o<0)throw new Error(`negative radius: ${o}`);let l=o*Math.cos(n),c=o*Math.sin(n),h=e+l,u=r+c,d=1^a,f=a?n-s:s-n;this._x1===null?this._append`M${h},${u}`:(Math.abs(this._x1-h)>Ve||Math.abs(this._y1-u)>Ve)&&this._append`L${h},${u}`,o&&(f<0&&(f=f%js+js),f>Hd?this._append`A${o},${o},0,1,${d},${e-l},${r-c}A${o},${o},0,1,${d},${this._x1=h},${this._y1=u}`:f>Ve&&this._append`A${o},${o},0,${+(f>=Xs)},${d},${this._x1=e+o*Math.cos(s)},${this._y1=r+o*Math.sin(s)}`)}rect(e,r,o,n){this._append`M${this._x0=this._x1=+e},${this._y0=this._y1=+r}h${o=+o}v${+n}h${-o}Z`}toString(){return this._}};function Cc(){return new Xe}i(Cc,"path");Cc.prototype=Xe.prototype;function mo(t){let e=3;return t.digits=function(r){if(!arguments.length)return e;if(r==null)e=null;else{let o=Math.floor(r);if(!(o>=0))throw new RangeError(`invalid digits: ${r}`);e=o}return t},()=>new Xe(e)}i(mo,"withPath");function Yd(t){return t.innerRadius}i(Yd,"arcInnerRadius");function Gd(t){return t.outerRadius}i(Gd,"arcOuterRadius");function Vd(t){return t.startAngle}i(Vd,"arcStartAngle");function Xd(t){return t.endAngle}i(Xd,"arcEndAngle");function jd(t){return t&&t.padAngle}i(jd,"arcPadAngle");function Zd(t,e,r,o,n,s,a,l){var c=r-t,h=o-e,u=a-n,d=l-s,f=d*c-u*h;if(!(f*fy*y+F*F&&(j=it,W=M),{cx:j,cy:W,x01:-u,y01:-d,x11:j*(n/P-1),y11:W*(n/P-1)}}i(po,"cornerTangents");function _c(){var t=Yd,e=Gd,r=st(0),o=null,n=Vd,s=Xd,a=jd,l=null,c=mo(h);function h(){var u,d,f=+t.apply(this,arguments),g=+e.apply(this,arguments),T=n.apply(this,arguments)-ti,L=s.apply(this,arguments)-ti,$=Gs(L-T),z=L>T;if(l||(l=u=c()),gyt))l.moveTo(0,0);else if($>_r-yt)l.moveTo(g*Fe(T),g*Xt(T)),l.arc(0,0,g,T,L,!z),f>yt&&(l.moveTo(f*Fe(L),f*Xt(L)),l.arc(0,0,f,L,T,z));else{var G=T,E=L,B=T,P=L,w=$,X=$,j=a.apply(this,arguments)/2,W=j>yt&&(o?+o.apply(this,arguments):Ge(f*f+g*g)),it=fo(Gs(g-f)/2,+r.apply(this,arguments)),M=it,k=it,x,y;if(W>yt){var F=Vs(W/f*Xt(j)),S=Vs(W/g*Xt(j));(w-=F*2)>yt?(F*=z?1:-1,B+=F,P-=F):(w=0,B=P=(T+L)/2),(X-=S*2)>yt?(S*=z?1:-1,G+=S,E-=S):(X=0,G=E=(T+L)/2)}var N=g*Fe(G),O=g*Xt(G),U=f*Fe(P),rt=f*Xt(P);if(it>yt){var Y=g*Fe(E),nt=g*Xt(E),K=f*Fe(B),Ft=f*Xt(B),Z;if($yt?k>yt?(x=po(K,Ft,N,O,g,k,z),y=po(Y,nt,U,rt,g,k,z),l.moveTo(x.cx+x.x01,x.cy+x.y01),kyt)||!(w>yt)?l.lineTo(U,rt):M>yt?(x=po(U,rt,Y,nt,f,-M,z),y=po(N,O,K,Ft,f,-M,z),l.lineTo(x.cx+x.x01,x.cy+x.y01),Mt?1:e>=t?0:NaN}i(Zs,"default");function Ks(t){return t}i(Ks,"default");function vc(){var t=Ks,e=Zs,r=null,o=st(0),n=st(_r),s=st(0);function a(l){var c,h=(l=ei(l)).length,u,d,f=0,g=new Array(h),T=new Array(h),L=+o.apply(this,arguments),$=Math.min(_r,Math.max(-_r,n.apply(this,arguments)-L)),z,G=Math.min(Math.abs($)/h,s.apply(this,arguments)),E=G*($<0?-1:1),B;for(c=0;c0&&(f+=B);for(e!=null?g.sort(function(P,w){return e(T[P],T[w])}):r!=null&&g.sort(function(P,w){return r(l[P],l[w])}),c=0,d=f?($-h*E)/f:0;c0?B*d:0)+E,T[u]={data:l[u],index:c,value:B,startAngle:L,endAngle:z,padAngle:G};return T}return i(a,"pie"),a.value=function(l){return arguments.length?(t=typeof l=="function"?l:st(+l),a):t},a.sortValues=function(l){return arguments.length?(e=l,r=null,a):e},a.sort=function(l){return arguments.length?(r=l,e=null,a):r},a.startAngle=function(l){return arguments.length?(o=typeof l=="function"?l:st(+l),a):o},a.endAngle=function(l){return arguments.length?(n=typeof l=="function"?l:st(+l),a):n},a.padAngle=function(l){return arguments.length?(s=typeof l=="function"?l:st(+l),a):s},a}i(vc,"default");var xo=class{static{i(this,"Bump")}constructor(e,r){this._context=e,this._x=r}areaStart(){this._line=0}areaEnd(){this._line=NaN}lineStart(){this._point=0}lineEnd(){(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line}point(e,r){switch(e=+e,r=+r,this._point){case 0:{this._point=1,this._line?this._context.lineTo(e,r):this._context.moveTo(e,r);break}case 1:this._point=2;default:{this._x?this._context.bezierCurveTo(this._x0=(this._x0+e)/2,this._y0,this._x0,r,e,r):this._context.bezierCurveTo(this._x0,this._y0=(this._y0+r)/2,e,this._y0,e,r);break}}this._x0=e,this._y0=r}};function Kd(t){return new xo(t,!0)}i(Kd,"bumpX");function Qd(t){return new xo(t,!1)}i(Qd,"bumpY");function br(t,e,r){t._context.bezierCurveTo((2*t._x0+t._x1)/3,(2*t._y0+t._y1)/3,(t._x0+2*t._x1)/3,(t._y0+2*t._y1)/3,(t._x0+4*t._x1+e)/6,(t._y0+4*t._y1+r)/6)}i(br,"point");function ri(t){this._context=t}i(ri,"Basis");ri.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 3:br(this,this._x1,this._y1);case 2:this._context.lineTo(this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,this._context.lineTo((5*this._x0+this._x1)/6,(5*this._y0+this._y1)/6);default:br(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};function wc(t){return new ri(t)}i(wc,"default");function zt(){}i(zt,"default");function Bc(t){this._context=t}i(Bc,"BasisClosed");Bc.prototype={areaStart:zt,areaEnd:zt,lineStart:i(function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._y0=this._y1=this._y2=this._y3=this._y4=NaN,this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 1:{this._context.moveTo(this._x2,this._y2),this._context.closePath();break}case 2:{this._context.moveTo((this._x2+2*this._x3)/3,(this._y2+2*this._y3)/3),this._context.lineTo((this._x3+2*this._x2)/3,(this._y3+2*this._y2)/3),this._context.closePath();break}case 3:{this.point(this._x2,this._y2),this.point(this._x3,this._y3),this.point(this._x4,this._y4);break}}},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x2=t,this._y2=e;break;case 1:this._point=2,this._x3=t,this._y3=e;break;case 2:this._point=3,this._x4=t,this._y4=e,this._context.moveTo((this._x0+4*this._x1+t)/6,(this._y0+4*this._y1+e)/6);break;default:br(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};function Fc(t){return new Bc(t)}i(Fc,"default");function Mc(t){this._context=t}i(Mc,"BasisOpen");Mc.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._y0=this._y1=NaN,this._point=0},"lineStart"),lineEnd:i(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3;var r=(this._x0+4*this._x1+t)/6,o=(this._y0+4*this._y1+e)/6;this._line?this._context.lineTo(r,o):this._context.moveTo(r,o);break;case 3:this._point=4;default:br(this,t,e);break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e},"point")};function Lc(t){return new Mc(t)}i(Lc,"default");function Ac(t,e){this._basis=new ri(t),this._beta=e}i(Ac,"Bundle");Ac.prototype={lineStart:i(function(){this._x=[],this._y=[],this._basis.lineStart()},"lineStart"),lineEnd:i(function(){var t=this._x,e=this._y,r=t.length-1;if(r>0)for(var o=t[0],n=e[0],s=t[r]-o,a=e[r]-n,l=-1,c;++l<=r;)c=l/r,this._basis.point(this._beta*t[l]+(1-this._beta)*(o+c*s),this._beta*e[l]+(1-this._beta)*(n+c*a));this._x=this._y=null,this._basis.lineEnd()},"lineEnd"),point:i(function(t,e){this._x.push(+t),this._y.push(+e)},"point")};var Jd=i(function t(e){function r(o){return e===1?new ri(o):new Ac(o,e)}return i(r,"bundle"),r.beta=function(o){return t(+o)},r},"custom")(.85);function Tr(t,e,r){t._context.bezierCurveTo(t._x1+t._k*(t._x2-t._x0),t._y1+t._k*(t._y2-t._y0),t._x2+t._k*(t._x1-e),t._y2+t._k*(t._y1-r),t._x2,t._y2)}i(Tr,"point");function yo(t,e){this._context=t,this._k=(1-e)/6}i(yo,"Cardinal");yo.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:Tr(this,this._x1,this._y1);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2,this._x1=t,this._y1=e;break;case 2:this._point=3;default:Tr(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var tg=i(function t(e){function r(o){return new yo(o,e)}return i(r,"cardinal"),r.tension=function(o){return t(+o)},r},"custom")(0);function Co(t,e){this._context=t,this._k=(1-e)/6}i(Co,"CardinalClosed");Co.prototype={areaStart:zt,areaEnd:zt,lineStart:i(function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:Tr(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var eg=i(function t(e){function r(o){return new Co(o,e)}return i(r,"cardinal"),r.tension=function(o){return t(+o)},r},"custom")(0);function _o(t,e){this._context=t,this._k=(1-e)/6}i(_o,"CardinalOpen");_o.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._point=0},"lineStart"),lineEnd:i(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:Tr(this,t,e);break}this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var rg=i(function t(e){function r(o){return new _o(o,e)}return i(r,"cardinal"),r.tension=function(o){return t(+o)},r},"custom")(0);function ii(t,e,r){var o=t._x1,n=t._y1,s=t._x2,a=t._y2;if(t._l01_a>yt){var l=2*t._l01_2a+3*t._l01_a*t._l12_a+t._l12_2a,c=3*t._l01_a*(t._l01_a+t._l12_a);o=(o*l-t._x0*t._l12_2a+t._x2*t._l01_2a)/c,n=(n*l-t._y0*t._l12_2a+t._y2*t._l01_2a)/c}if(t._l23_a>yt){var h=2*t._l23_2a+3*t._l23_a*t._l12_a+t._l12_2a,u=3*t._l23_a*(t._l23_a+t._l12_a);s=(s*h+t._x1*t._l23_2a-e*t._l12_2a)/u,a=(a*h+t._y1*t._l23_2a-r*t._l12_2a)/u}t._context.bezierCurveTo(o,n,s,a,t._x2,t._y2)}i(ii,"point");function Ec(t,e){this._context=t,this._alpha=e}i(Ec,"CatmullRom");Ec.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 2:this._context.lineTo(this._x2,this._y2);break;case 3:this.point(this._x2,this._y2);break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,o=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+o*o,this._alpha))}switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3;default:ii(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var ig=i(function t(e){function r(o){return e?new Ec(o,e):new yo(o,0)}return i(r,"catmullRom"),r.alpha=function(o){return t(+o)},r},"custom")(.5);function Dc(t,e){this._context=t,this._alpha=e}i(Dc,"CatmullRomClosed");Dc.prototype={areaStart:zt,areaEnd:zt,lineStart:i(function(){this._x0=this._x1=this._x2=this._x3=this._x4=this._x5=this._y0=this._y1=this._y2=this._y3=this._y4=this._y5=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 1:{this._context.moveTo(this._x3,this._y3),this._context.closePath();break}case 2:{this._context.lineTo(this._x3,this._y3),this._context.closePath();break}case 3:{this.point(this._x3,this._y3),this.point(this._x4,this._y4),this.point(this._x5,this._y5);break}}},"lineEnd"),point:i(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,o=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+o*o,this._alpha))}switch(this._point){case 0:this._point=1,this._x3=t,this._y3=e;break;case 1:this._point=2,this._context.moveTo(this._x4=t,this._y4=e);break;case 2:this._point=3,this._x5=t,this._y5=e;break;default:ii(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var og=i(function t(e){function r(o){return e?new Dc(o,e):new Co(o,0)}return i(r,"catmullRom"),r.alpha=function(o){return t(+o)},r},"custom")(.5);function Oc(t,e){this._context=t,this._alpha=e}i(Oc,"CatmullRomOpen");Oc.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._x2=this._y0=this._y1=this._y2=NaN,this._l01_a=this._l12_a=this._l23_a=this._l01_2a=this._l12_2a=this._l23_2a=this._point=0},"lineStart"),lineEnd:i(function(){(this._line||this._line!==0&&this._point===3)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){if(t=+t,e=+e,this._point){var r=this._x2-t,o=this._y2-e;this._l23_a=Math.sqrt(this._l23_2a=Math.pow(r*r+o*o,this._alpha))}switch(this._point){case 0:this._point=1;break;case 1:this._point=2;break;case 2:this._point=3,this._line?this._context.lineTo(this._x2,this._y2):this._context.moveTo(this._x2,this._y2);break;case 3:this._point=4;default:ii(this,t,e);break}this._l01_a=this._l12_a,this._l12_a=this._l23_a,this._l01_2a=this._l12_2a,this._l12_2a=this._l23_2a,this._x0=this._x1,this._x1=this._x2,this._x2=t,this._y0=this._y1,this._y1=this._y2,this._y2=e},"point")};var ng=i(function t(e){function r(o){return e?new Oc(o,e):new _o(o,0)}return i(r,"catmullRom"),r.alpha=function(o){return t(+o)},r},"custom")(.5);function Ic(t){this._context=t}i(Ic,"LinearClosed");Ic.prototype={areaStart:zt,areaEnd:zt,lineStart:i(function(){this._point=0},"lineStart"),lineEnd:i(function(){this._point&&this._context.closePath()},"lineEnd"),point:i(function(t,e){t=+t,e=+e,this._point?this._context.lineTo(t,e):(this._point=1,this._context.moveTo(t,e))},"point")};function Rc(t){return new Ic(t)}i(Rc,"default");function Nc(t){return t<0?-1:1}i(Nc,"sign");function qc(t,e,r){var o=t._x1-t._x0,n=e-t._x1,s=(t._y1-t._y0)/(o||n<0&&-0),a=(r-t._y1)/(n||o<0&&-0),l=(s*n+a*o)/(o+n);return(Nc(s)+Nc(a))*Math.min(Math.abs(s),Math.abs(a),.5*Math.abs(l))||0}i(qc,"slope3");function zc(t,e){var r=t._x1-t._x0;return r?(3*(t._y1-t._y0)/r-e)/2:e}i(zc,"slope2");function Qs(t,e,r){var o=t._x0,n=t._y0,s=t._x1,a=t._y1,l=(s-o)/3;t._context.bezierCurveTo(o+l,n+l*e,s-l,a-l*r,s,a)}i(Qs,"point");function bo(t){this._context=t}i(bo,"MonotoneX");bo.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x0=this._x1=this._y0=this._y1=this._t0=NaN,this._point=0},"lineStart"),lineEnd:i(function(){switch(this._point){case 2:this._context.lineTo(this._x1,this._y1);break;case 3:Qs(this,this._t0,zc(this,this._t0));break}(this._line||this._line!==0&&this._point===1)&&this._context.closePath(),this._line=1-this._line},"lineEnd"),point:i(function(t,e){var r=NaN;if(t=+t,e=+e,!(t===this._x1&&e===this._y1)){switch(this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;break;case 2:this._point=3,Qs(this,zc(this,r=qc(this,t,e)),r);break;default:Qs(this,this._t0,r=qc(this,t,e));break}this._x0=this._x1,this._x1=t,this._y0=this._y1,this._y1=e,this._t0=r}},"point")};function Pc(t){this._context=new $c(t)}i(Pc,"MonotoneY");(Pc.prototype=Object.create(bo.prototype)).point=function(t,e){bo.prototype.point.call(this,e,t)};function $c(t){this._context=t}i($c,"ReflectContext");$c.prototype={moveTo:i(function(t,e){this._context.moveTo(e,t)},"moveTo"),closePath:i(function(){this._context.closePath()},"closePath"),lineTo:i(function(t,e){this._context.lineTo(e,t)},"lineTo"),bezierCurveTo:i(function(t,e,r,o,n,s){this._context.bezierCurveTo(e,t,o,r,s,n)},"bezierCurveTo")};function sg(t){return new bo(t)}i(sg,"monotoneX");function ag(t){return new Pc(t)}i(ag,"monotoneY");function Hc(t){this._context=t}i(Hc,"Natural");Hc.prototype={areaStart:i(function(){this._line=0},"areaStart"),areaEnd:i(function(){this._line=NaN},"areaEnd"),lineStart:i(function(){this._x=[],this._y=[]},"lineStart"),lineEnd:i(function(){var t=this._x,e=this._y,r=t.length;if(r)if(this._line?this._context.lineTo(t[0],e[0]):this._context.moveTo(t[0],e[0]),r===2)this._context.lineTo(t[1],e[1]);else for(var o=Wc(t),n=Wc(e),s=0,a=1;a=0;--e)n[e]=(a[e]-n[e+1])/s[e];for(s[r-1]=(t[r]+n[r-1])/2,e=0;e=0&&(this._t=1-this._t,this._line=1-this._line)},"lineEnd"),point:i(function(t,e){switch(t=+t,e=+e,this._point){case 0:this._point=1,this._line?this._context.lineTo(t,e):this._context.moveTo(t,e);break;case 1:this._point=2;default:{if(this._t<=0)this._context.lineTo(this._x,e),this._context.lineTo(t,e);else{var r=this._x*(1-this._t)+t*this._t;this._context.lineTo(r,this._y),this._context.lineTo(r,e)}break}}this._x=t,this._y=e},"point")};function Yc(t){return new To(t,.5)}i(Yc,"default");function lg(t){return new To(t,0)}i(lg,"stepBefore");function hg(t){return new To(t,1)}i(hg,"stepAfter");var cg={value:i(()=>{},"value")};function Vc(){for(var t=0,e=arguments.length,r={},o;t=0&&(o=r.slice(n+1),r=r.slice(0,n)),r&&!e.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:o}})}i(ug,"parseTypenames");ko.prototype=Vc.prototype={constructor:ko,on:i(function(t,e){var r=this._,o=ug(t+"",r),n,s=-1,a=o.length;if(arguments.length<2){for(;++s0)for(var r=new Array(n),o=0,n,s;o=0&&t._call.call(void 0,e),t=t._next;--kr}i(Kc,"timerFlush");function Xc(){je=(vo=ai.now())+wo,kr=ni=0;try{Kc()}finally{kr=0,dg(),je=0}}i(Xc,"wake");function pg(){var t=ai.now(),e=t-vo;e>jc&&(wo-=e,vo=t)}i(pg,"poke");function dg(){for(var t,e=So,r,o=1/0;e;)e._call?(o>e._time&&(o=e._time),t=e,e=e._next):(r=e._next,e._next=null,e=t?t._next=r:So=r);si=t,ta(o)}i(dg,"nap");function ta(t){if(!kr){ni&&(ni=clearTimeout(ni));var e=t-je;e>24?(t<1/0&&(ni=setTimeout(Xc,t-ai.now()-wo)),oi&&(oi=clearInterval(oi))):(oi||(vo=ai.now(),oi=setInterval(pg,jc)),kr=1,Zc(Xc))}}i(ta,"sleep");function ci(t,e,r){var o=new li;return e=e==null?0:+e,o.restart(n=>{o.stop(),t(n+e)},e,r),o}i(ci,"default");var gg=Js("start","end","cancel","interrupt"),xg=[],tu=0,Qc=1,Mo=2,Fo=3,Jc=4,Lo=5,ui=6;function me(t,e,r,o,n,s){var a=t.__transition;if(!a)t.__transition={};else if(r in a)return;yg(t,r,{name:e,index:o,group:n,on:gg,tween:xg,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:tu})}i(me,"default");function fi(t,e){var r=mt(t,e);if(r.state>tu)throw new Error("too late; already scheduled");return r}i(fi,"init");function wt(t,e){var r=mt(t,e);if(r.state>Fo)throw new Error("too late; already running");return r}i(wt,"set");function mt(t,e){var r=t.__transition;if(!r||!(r=r[e]))throw new Error("transition not found");return r}i(mt,"get");function yg(t,e,r){var o=t.__transition,n;o[e]=r,r.timer=Bo(s,0,r.time);function s(h){r.state=Qc,r.timer.restart(a,r.delay,r.time),r.delay<=h&&a(h-r.delay)}i(s,"schedule");function a(h){var u,d,f,g;if(r.state!==Qc)return c();for(u in o)if(g=o[u],g.name===r.name){if(g.state===Fo)return ci(a);g.state===Jc?(g.state=ui,g.timer.stop(),g.on.call("interrupt",t,t.__data__,g.index,g.group),delete o[u]):+uMo&&o.state=0&&(e=e.slice(0,r)),!e||e==="start"})}i(Ng,"start");function qg(t,e,r){var o,n,s=Ng(e)?fi:wt;return function(){var a=s(this,t),l=a.on;l!==o&&(n=(o=l).copy()).on(e,r),a.on=n}}i(qg,"onFunction");function ua(t,e){var r=this._id;return arguments.length<2?mt(this.node(),r).on.on(t):this.each(qg(r,t,e))}i(ua,"default");function zg(t){return function(){var e=this.parentNode;for(var r in this.__transition)if(+r!==t)return;e&&e.removeChild(this)}}i(zg,"removeFunction");function fa(){return this.on("end.remove",zg(this._id))}i(fa,"default");function ma(t){var e=this._name,r=this._id;typeof t!="function"&&(t=Ce(t));for(var o=this._groups,n=o.length,s=new Array(n),a=0;a{let e;return o==="sandbox"&&(e=s("#i"+t)),(o==="sandbox"?s(e.nodes()[0].contentDocument.body):s("body")).select(`[id="${t}"]`)},"getDiagramElement");var $=r((t,o,e,i)=>{t.attr("class",e);let{width:n,height:m,x:h,y:x}=a(t,o);b(t,m,n,i);let c=d(h,x,n,m,o);t.attr("viewBox",c),u.debug(`viewBox configured: ${c} with padding: ${o}`)},"setupViewPortForSVG"),a=r((t,o)=>{let e=t.node()?.getBBox()||{width:0,height:0,x:0,y:0};return{width:e.width+o*2,height:e.height+o*2,x:e.x,y:e.y}},"calculateDimensionsWithPadding"),d=r((t,o,e,i,n)=>`${t-n} ${o-n} ${e} ${i}`,"createViewBox");export{w as a,$ as b}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-S67DUUA5.mjs b/static/js/chunks/mermaid.esm.min/chunk-S67DUUA5.mjs new file mode 100644 index 0000000..e7db630 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-S67DUUA5.mjs @@ -0,0 +1 @@ +import{a as p}from"./chunk-GTKDMUJJ.mjs";var o={aggregation:18,extension:18,composition:18,dependency:6,lollipop:13.5,arrow_point:4};function b(n,a){if(n===void 0||a===void 0)return{angle:0,deltaX:0,deltaY:0};n=t(n),a=t(a);let[c,e]=[n.x,n.y],[l,f]=[a.x,a.y],s=l-c,m=f-e;return{angle:Math.atan(m/s),deltaX:s,deltaY:m}}p(b,"calculateDeltaAndAngle");var t=p(n=>Array.isArray(n)?{x:n[0],y:n[1]}:n,"pointTransformer"),d=p(n=>({x:p(function(a,c,e){let l=0,f=t(e[0]).x=0?1:-1)}else if(c===e.length-1&&Object.hasOwn(o,n.arrowTypeEnd)){let{angle:r,deltaX:h}=b(e[e.length-1],e[e.length-2]);l=o[n.arrowTypeEnd]*Math.cos(r)*(h>=0?1:-1)}let s=Math.abs(t(a).x-t(e[e.length-1]).x),m=Math.abs(t(a).y-t(e[e.length-1]).y),i=Math.abs(t(a).x-t(e[0]).x),x=Math.abs(t(a).y-t(e[0]).y),u=o[n.arrowTypeStart],y=o[n.arrowTypeEnd],g=1;if(s0&&m0&&x=0?1:-1)}else if(c===e.length-1&&Object.hasOwn(o,n.arrowTypeEnd)){let{angle:r,deltaY:h}=b(e[e.length-1],e[e.length-2]);l=o[n.arrowTypeEnd]*Math.abs(Math.sin(r))*(h>=0?1:-1)}let s=Math.abs(t(a).y-t(e[e.length-1]).y),m=Math.abs(t(a).x-t(e[e.length-1]).x),i=Math.abs(t(a).y-t(e[0]).y),x=Math.abs(t(a).x-t(e[0]).x),u=o[n.arrowTypeStart],y=o[n.arrowTypeEnd],g=1;if(s0&&m0&&x{"use strict";Object.defineProperty(e,"__esModule",{value:!0});e.BLANK_URL=e.relativeFirstCharacters=e.whitespaceEscapeCharsRegex=e.urlSchemeRegex=e.ctrlCharactersRegex=e.htmlCtrlEntityRegex=e.htmlEntitiesRegex=e.invalidProtocolRegex=void 0;e.invalidProtocolRegex=/^([^\w]*)(javascript|data|vbscript)/im;e.htmlEntitiesRegex=/&#(\w+)(^\w|;)?/g;e.htmlCtrlEntityRegex=/&(newline|tab);/gi;e.ctrlCharactersRegex=/[\u0000-\u001F\u007F-\u009F\u2000-\u200D\uFEFF]/gim;e.urlSchemeRegex=/^.+(:|:)/gim;e.whitespaceEscapeCharsRegex=/(\\|%5[cC])((%(6[eE]|72|74))|[nrt])/g;e.relativeFirstCharacters=[".","/"];e.BLANK_URL="about:blank"});var f=R(h=>{"use strict";Object.defineProperty(h,"__esModule",{value:!0});h.sanitizeUrl=void 0;var t=g();function v(r){return t.relativeFirstCharacters.indexOf(r[0])>-1}n(v,"isRelativeUrlWithoutProtocol");function x(r){var c=r.replace(t.ctrlCharactersRegex,"");return c.replace(t.htmlEntitiesRegex,function(a,i){return String.fromCharCode(i)})}n(x,"decodeHtmlCharacters");function C(r){return URL.canParse(r)}n(C,"isValidUrl");function d(r){try{return decodeURIComponent(r)}catch{return r}}n(d,"decodeURI");function p(r){if(!r)return t.BLANK_URL;var c,a=d(r.trim());do a=x(a).replace(t.htmlCtrlEntityRegex,"").replace(t.ctrlCharactersRegex,"").replace(t.whitespaceEscapeCharsRegex,"").trim(),a=d(a),c=a.match(t.ctrlCharactersRegex)||a.match(t.htmlEntitiesRegex)||a.match(t.htmlCtrlEntityRegex)||a.match(t.whitespaceEscapeCharsRegex);while(c&&c.length>0);var i=a;if(!i)return t.BLANK_URL;if(v(i))return i;var u=i.trimStart(),m=u.match(t.urlSchemeRegex);if(!m)return i;var l=m[0].toLowerCase().trim();if(t.invalidProtocolRegex.test(l))return t.BLANK_URL;var s=u.replace(/\\/g,"/");if(l==="mailto:"||l.includes("://"))return s;if(l==="http:"||l==="https:"){if(!C(s))return t.BLANK_URL;var o=new URL(s);return o.protocol=o.protocol.toLowerCase(),o.hostname=o.hostname.toLowerCase(),o.toString()}return s}n(p,"sanitizeUrl");h.sanitizeUrl=p});export{f as a}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-UENA7NWE.mjs b/static/js/chunks/mermaid.esm.min/chunk-UENA7NWE.mjs new file mode 100644 index 0000000..45903d2 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-UENA7NWE.mjs @@ -0,0 +1,2 @@ +import{a as ae}from"./chunk-TI4EEUUG.mjs";import{Ca as R,Fa as F,Ga as O,Ha as _,Ia as k,Ja as N,Ka as j,L as v,La as A,Ma as H,Na as z,Oa as I,Pa as U,Qa as X,Ra as Y,Sa as J,Ta as V,Ua as q,Va as G,Wa as Z,Xa as K,b as d,e as m,ga as D,h as B,k as w,t as L}from"./chunk-OR2G2HG5.mjs";import{T as Q,k as b}from"./chunk-6BY5RJGC.mjs";import{a,e as se}from"./chunk-GTKDMUJJ.mjs";var ne=se(ae(),1);var ce="\u200B",ue={curveBasis:_,curveBasisClosed:k,curveBasisOpen:N,curveBumpX:F,curveBumpY:O,curveBundle:j,curveCardinalClosed:H,curveCardinalOpen:z,curveCardinal:A,curveCatmullRomClosed:U,curveCatmullRomOpen:X,curveCatmullRom:I,curveLinear:R,curveLinearClosed:Y,curveMonotoneX:J,curveMonotoneY:V,curveNatural:q,curveStep:G,curveStepAfter:K,curveStepBefore:Z},le=/\s*(?:(\w+)(?=:):|(\w+))\s*(?:(\w+)|((?:(?!}%{2}).|\r?\n)*))?\s*(?:}%{2})?/gi,fe=a(function(t,e){let r=re(t,/(?:init\b)|(?:initialize\b)/),n={};if(Array.isArray(r)){let s=r.map(u=>u.args);L(s),n=w(n,[...s])}else n=r.args;if(!n)return;let i=B(t,e),o="config";return n[o]!==void 0&&(i==="flowchart-v2"&&(i="flowchart"),n[i]=n[o],delete n[o]),n},"detectInit"),re=a(function(t,e=null){try{let r=new RegExp(`[%]{2}(?![{]${le.source})(?=[}][%]{2}).* +`,"ig");t=t.trim().replace(r,"").replace(/'/gm,'"'),d.debug(`Detecting diagram directive${e!==null?" type:"+e:""} based on the text:${t}`);let n,i=[];for(;(n=m.exec(t))!==null;)if(n.index===m.lastIndex&&m.lastIndex++,n&&!e||e&&n[1]?.match(e)||e&&n[2]?.match(e)){let o=n[1]?n[1]:n[2],s=n[3]?n[3].trim():n[4]?JSON.parse(n[4].trim()):null;i.push({type:o,args:s})}return i.length===0?{type:t,args:null}:i.length===1?i[0]:i}catch(r){return d.error(`ERROR: ${r.message} - Unable to parse directive type: '${e}' based on the text: '${t}'`),{type:void 0,args:null}}},"detectDirective"),He=a(function(t){return t.replace(m,"")},"removeDirectives"),ge=a(function(t,e){for(let[r,n]of e.entries())if(n.match(t))return r;return-1},"isSubstringInArray");function de(t,e){if(!t)return e;let r=`curve${t.charAt(0).toUpperCase()+t.slice(1)}`;return ue[r]??e}a(de,"interpolateToCurve");function he(t,e){let r=t.trim();if(r)return e.securityLevel!=="loose"?(0,ne.sanitizeUrl)(r):r}a(he,"formatUrl");var me=a((t,...e)=>{let r=t.split("."),n=r.length-1,i=r[n],o=window;for(let s=0;s{r+=ie(i,e),e=i});let n=r/2;return T(t,n)}a(pe,"traverseEdge");function xe(t){return t.length===1?t[0]:pe(t)}a(xe,"calcLabelPosition");var ee=a((t,e=2)=>{let r=Math.pow(10,e);return Math.round(t*r)/r},"roundNumber"),T=a((t,e)=>{let r,n=e;for(let i of t){if(r){let o=ie(i,r);if(o=1)return{x:i.x,y:i.y};if(s>0&&s<1)return{x:ee((1-s)*r.x+s*i.x,5),y:ee((1-s)*r.y+s*i.y,5)}}}r=i}throw new Error("Could not find a suitable point for the given distance")},"calculatePoint"),ye=a((t,e,r)=>{d.info(`our points ${JSON.stringify(e)}`),e[0]!==r&&(e=e.reverse());let i=T(e,25),o=t?10:5,s=Math.atan2(e[0].y-i.y,e[0].x-i.x),u={x:0,y:0};return u.x=Math.sin(s)*o+(e[0].x+i.x)/2,u.y=-Math.cos(s)*o+(e[0].y+i.y)/2,u},"calcCardinalityPosition");function ve(t,e,r){let n=structuredClone(r);d.info("our points",n),e!=="start_left"&&e!=="start_right"&&n.reverse();let i=25+t,o=T(n,i),s=10+t*.5,u=Math.atan2(n[0].y-o.y,n[0].x-o.x),c={x:0,y:0};return e==="start_left"?(c.x=Math.sin(u+Math.PI)*s+(n[0].x+o.x)/2,c.y=-Math.cos(u+Math.PI)*s+(n[0].y+o.y)/2):e==="end_right"?(c.x=Math.sin(u-Math.PI)*s+(n[0].x+o.x)/2-5,c.y=-Math.cos(u-Math.PI)*s+(n[0].y+o.y)/2-5):e==="end_left"?(c.x=Math.sin(u)*s+(n[0].x+o.x)/2-5,c.y=-Math.cos(u)*s+(n[0].y+o.y)/2-5):(c.x=Math.sin(u)*s+(n[0].x+o.x)/2,c.y=-Math.cos(u)*s+(n[0].y+o.y)/2),c}a(ve,"calcTerminalLabelPosition");function be(t){let e="",r="";for(let n of t)n!==void 0&&(n.startsWith("color:")||n.startsWith("text-align:")?r=r+n+";":e=e+n+";");return{style:e,labelStyle:r}}a(be,"getStylesFromArray");var te=0,Ce=a(()=>(te++,"id-"+Math.random().toString(36).substr(2,12)+"-"+te),"generateId");function Me(t){let e="",r="0123456789abcdef",n=r.length;for(let i=0;iMe(t.length),"random"),Pe=a(function(){return{x:0,y:0,fill:void 0,anchor:"start",style:"#666",width:100,height:100,textMargin:0,rx:0,ry:0,valign:void 0,text:""}},"getTextObj"),Te=a(function(t,e){let r=e.text.replace(v.lineBreakRegex," "),[,n]=S(e.fontSize),i=t.append("text");i.attr("x",e.x),i.attr("y",e.y),i.style("text-anchor",e.anchor),i.style("font-family",e.fontFamily),i.style("font-size",n),i.style("font-weight",e.fontWeight),i.attr("fill",e.fill),e.class!==void 0&&i.attr("class",e.class);let o=i.append("tspan");return o.attr("x",e.x+e.textMargin*2),o.attr("fill",e.fill),o.text(r),i},"drawSimpleText"),$e=b((t,e,r)=>{if(!t||(r=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",joinWith:"
    "},r),v.lineBreakRegex.test(t)))return t;let n=t.split(" ").filter(Boolean),i=[],o="";return n.forEach((s,u)=>{let c=M(`${s} `,r),l=M(o,r);if(c>e){let{hyphenatedStrings:h,remainingWord:f}=Se(s,e,"-",r);i.push(o,...h),o=f}else l+c>=e?(i.push(o),o=s):o=[o,s].filter(Boolean).join(" ");u+1===n.length&&i.push(o)}),i.filter(s=>s!=="").join(r.joinWith)},(t,e,r)=>`${t}${e}${r.fontSize}${r.fontWeight}${r.fontFamily}${r.joinWith}`),Se=b((t,e,r="-",n)=>{n=Object.assign({fontSize:12,fontWeight:400,fontFamily:"Arial",margin:0},n);let i=[...t],o=[],s="";return i.forEach((u,c)=>{let l=`${s}${u}`;if(M(l,n)>=e){let x=c+1,h=i.length===x,f=`${l}${r}`;o.push(h?l:f),s=""}else s=l}),{hyphenatedStrings:o,remainingWord:s}},(t,e,r="-",n)=>`${t}${e}${r}${n.fontSize}${n.fontWeight}${n.fontFamily}`);function We(t,e){return $(t,e).height}a(We,"calculateTextHeight");function M(t,e){return $(t,e).width}a(M,"calculateTextWidth");var $=b((t,e)=>{let{fontSize:r=12,fontFamily:n="Arial",fontWeight:i=400}=e;if(!t)return{width:0,height:0};let[,o]=S(r),s=["sans-serif",n],u=t.split(v.lineBreakRegex),c=[],l=D("body");if(!l.remove)return{width:0,height:0,lineHeight:0};let p=l.append("svg");for(let h of s){let f=0,g={width:0,height:0,lineHeight:0};for(let oe of u){let W=Pe();W.text=oe||ce;let E=Te(p,W).style("font-size",o).style("font-weight",i).style("font-family",h),y=(E._groups||E)[0][0].getBBox();if(y.width===0&&y.height===0)throw new Error("svg element not in render tree");g.width=Math.round(Math.max(g.width,y.width)),f=Math.round(y.height),g.height+=f,g.lineHeight=Math.round(Math.max(g.lineHeight,f))}c.push(g)}p.remove();let x=isNaN(c[1].height)||isNaN(c[1].width)||isNaN(c[1].lineHeight)||c[0].height>c[1].height&&c[0].width>c[1].width&&c[0].lineHeight>c[1].lineHeight?0:1;return c[x]},(t,e)=>`${t}${e.fontSize}${e.fontWeight}${e.fontFamily}`),P=class{constructor(e=!1,r){this.count=0;this.count=r?r.length:0,this.next=e?()=>this.count++:()=>Date.now()}static{a(this,"InitIDGenerator")}},C,Ee=a(function(t){return C=C||document.createElement("div"),t=escape(t).replace(/%26/g,"&").replace(/%23/g,"#").replace(/%3B/g,";"),C.innerHTML=t,unescape(C.textContent)},"entityDecode");function ze(t){return"str"in t}a(ze,"isDetailedError");var Be=a((t,e,r,n)=>{if(!n)return;let i=t.node()?.getBBox();i&&t.append("text").text(n).attr("text-anchor","middle").attr("x",i.x+i.width/2).attr("y",-r).attr("class",e)},"insertTitle"),S=a(t=>{if(typeof t=="number")return[t,t+"px"];let e=parseInt(t??"",10);return Number.isNaN(e)?[void 0,void 0]:t===String(e)?[e,t+"px"]:[e,t]},"parseFontSize");function Le(t,e){return Q({},t,e)}a(Le,"cleanAndMerge");var Ie={assignWithDepth:w,wrapLabel:$e,calculateTextHeight:We,calculateTextWidth:M,calculateTextDimensions:$,cleanAndMerge:Le,detectInit:fe,detectDirective:re,isSubstringInArray:ge,interpolateToCurve:de,calcLabelPosition:xe,calcCardinalityPosition:ye,calcTerminalLabelPosition:ve,formatUrl:he,getStylesFromArray:be,generateId:Ce,random:we,runFunc:me,entityDecode:Ee,insertTitle:Be,parseFontSize:S,InitIDGenerator:P},Ue=a(function(t){let e=t;return e=e.replace(/style.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),e=e.replace(/classDef.*:\S*#.*;/g,function(r){return r.substring(0,r.length-1)}),e=e.replace(/#\w+;/g,function(r){let n=r.substring(1,r.length-1);return/^\+?\d+$/.test(n)?"\uFB02\xB0\xB0"+n+"\xB6\xDF":"\uFB02\xB0"+n+"\xB6\xDF"}),e},"encodeEntities"),Xe=a(function(t){return t.replace(/fl°°/g,"&#").replace(/fl°/g,"&").replace(/¶ß/g,";")},"decodeEntities");var Ye=a((t,e,{counter:r=0,prefix:n,suffix:i})=>`${n?`${n}_`:""}${t}_${e}_${r}${i?`_${i}`:""}`,"getEdgeId");function Je(t){return t??null}a(Je,"handleUndefinedAttr");export{ce as a,He as b,de as c,be as d,Ce as e,we as f,$e as g,We as h,M as i,ze as j,S as k,Le as l,Ie as m,Ue as n,Xe as o,Ye as p,Je as q}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-YPUTD6PB.mjs b/static/js/chunks/mermaid.esm.min/chunk-YPUTD6PB.mjs new file mode 100644 index 0000000..e342b42 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-YPUTD6PB.mjs @@ -0,0 +1 @@ +import{B as v,D as P,G as S,a as e,c as y,f as i,g as a,i as f,t as b,v as n,y as j,z as d}from"./chunk-6BY5RJGC.mjs";import{a as m}from"./chunk-GTKDMUJJ.mjs";var C=b(Object.keys,Object),T=C;var V=Object.prototype,D=V.hasOwnProperty;function K(r){if(!n(r))return T(r);var t=[];for(var o in Object(r))D.call(r,o)&&o!="constructor"&&t.push(o);return t}m(K,"baseKeys");var O=K;var N=a(e,"DataView"),s=N;var W=a(e,"Promise"),c=W;var B=a(e,"Set"),g=B;var z=a(e,"WeakMap"),u=z;var M="[object Map]",E="[object Object]",h="[object Promise]",x="[object Set]",k="[object WeakMap]",l="[object DataView]",G=i(s),L=i(f),q=i(c),F=i(g),H=i(u),p=y;(s&&p(new s(new ArrayBuffer(1)))!=l||f&&p(new f)!=M||c&&p(c.resolve())!=h||g&&p(new g)!=x||u&&p(new u)!=k)&&(p=m(function(r){var t=y(r),o=t==E?r.constructor:void 0,w=o?i(o):"";if(w)switch(w){case G:return l;case L:return M;case q:return h;case F:return x;case H:return k}return t},"getTag"));var A=p;var I="[object Map]",J="[object Set]",Q=Object.prototype,R=Q.hasOwnProperty;function U(r){if(r==null)return!0;if(v(r)&&(d(r)||typeof r=="string"||typeof r.splice=="function"||P(r)||S(r)||j(r)))return!r.length;var t=A(r);if(t==I||t==J)return!r.size;if(n(r))return!O(r).length;for(var o in r)if(R.call(r,o))return!1;return!0}m(U,"isEmpty");var Cr=U;export{O as a,g as b,A as c,Cr as d}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-ZN7TASNU.mjs b/static/js/chunks/mermaid.esm.min/chunk-ZN7TASNU.mjs new file mode 100644 index 0000000..6b69c29 --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-ZN7TASNU.mjs @@ -0,0 +1 @@ +import{D as _,L as C,Q as N,b as a,n as u,p as g,z as b}from"./chunk-5ZJXQJOJ.mjs";import{d as y}from"./chunk-YPUTD6PB.mjs";import{O as f,e as E}from"./chunk-6BY5RJGC.mjs";import{a as o}from"./chunk-GTKDMUJJ.mjs";var P="\0",l="\0",v="",m=class{static{o(this,"Graph")}constructor(e={}){this._isDirected=Object.prototype.hasOwnProperty.call(e,"directed")?e.directed:!0,this._isMultigraph=Object.prototype.hasOwnProperty.call(e,"multigraph")?e.multigraph:!1,this._isCompound=Object.prototype.hasOwnProperty.call(e,"compound")?e.compound:!1,this._label=void 0,this._defaultNodeLabelFn=f(void 0),this._defaultEdgeLabelFn=f(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[l]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}isDirected(){return this._isDirected}isMultigraph(){return this._isMultigraph}isCompound(){return this._isCompound}setGraph(e){return this._label=e,this}graph(){return this._label}setDefaultNodeLabel(e){return E(e)||(e=f(e)),this._defaultNodeLabelFn=e,this}nodeCount(){return this._nodeCount}nodes(){return a(this._nodes)}sources(){var e=this;return g(this.nodes(),function(t){return y(e._in[t])})}sinks(){var e=this;return g(this.nodes(),function(t){return y(e._out[t])})}setNodes(e,t){var s=arguments,i=this;return u(e,function(r){s.length>1?i.setNode(r,t):i.setNode(r)}),this}setNode(e,t){return Object.prototype.hasOwnProperty.call(this._nodes,e)?(arguments.length>1&&(this._nodes[e]=t),this):(this._nodes[e]=arguments.length>1?t:this._defaultNodeLabelFn(e),this._isCompound&&(this._parent[e]=l,this._children[e]={},this._children[l][e]=!0),this._in[e]={},this._preds[e]={},this._out[e]={},this._sucs[e]={},++this._nodeCount,this)}node(e){return this._nodes[e]}hasNode(e){return Object.prototype.hasOwnProperty.call(this._nodes,e)}removeNode(e){if(Object.prototype.hasOwnProperty.call(this._nodes,e)){var t=o(s=>this.removeEdge(this._edgeObjs[s]),"removeEdge");delete this._nodes[e],this._isCompound&&(this._removeFromParentsChildList(e),delete this._parent[e],u(this.children(e),s=>{this.setParent(s)}),delete this._children[e]),u(a(this._in[e]),t),delete this._in[e],delete this._preds[e],u(a(this._out[e]),t),delete this._out[e],delete this._sucs[e],--this._nodeCount}return this}setParent(e,t){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(_(t))t=l;else{t+="";for(var s=t;!_(s);s=this.parent(s))if(s===e)throw new Error("Setting "+t+" as parent of "+e+" would create a cycle");this.setNode(t)}return this.setNode(e),this._removeFromParentsChildList(e),this._parent[e]=t,this._children[t][e]=!0,this}_removeFromParentsChildList(e){delete this._children[this._parent[e]][e]}parent(e){if(this._isCompound){var t=this._parent[e];if(t!==l)return t}}children(e){if(_(e)&&(e=l),this._isCompound){var t=this._children[e];if(t)return a(t)}else{if(e===l)return this.nodes();if(this.hasNode(e))return[]}}predecessors(e){var t=this._preds[e];if(t)return a(t)}successors(e){var t=this._sucs[e];if(t)return a(t)}neighbors(e){var t=this.predecessors(e);if(t)return N(t,this.successors(e))}isLeaf(e){var t;return this.isDirected()?t=this.successors(e):t=this.neighbors(e),t.length===0}filterNodes(e){var t=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});t.setGraph(this.graph());var s=this;u(this._nodes,function(n,h){e(h)&&t.setNode(h,n)}),u(this._edgeObjs,function(n){t.hasNode(n.v)&&t.hasNode(n.w)&&t.setEdge(n,s.edge(n))});var i={};function r(n){var h=s.parent(n);return h===void 0||t.hasNode(h)?(i[n]=h,h):h in i?i[h]:r(h)}return o(r,"findParent"),this._isCompound&&u(t.nodes(),function(n){t.setParent(n,r(n))}),t}setDefaultEdgeLabel(e){return E(e)||(e=f(e)),this._defaultEdgeLabelFn=e,this}edgeCount(){return this._edgeCount}edges(){return b(this._edgeObjs)}setPath(e,t){var s=this,i=arguments;return C(e,function(r,n){return i.length>1?s.setEdge(r,n,t):s.setEdge(r,n),n}),this}setEdge(){var e,t,s,i,r=!1,n=arguments[0];typeof n=="object"&&n!==null&&"v"in n?(e=n.v,t=n.w,s=n.name,arguments.length===2&&(i=arguments[1],r=!0)):(e=n,t=arguments[1],s=arguments[3],arguments.length>2&&(i=arguments[2],r=!0)),e=""+e,t=""+t,_(s)||(s=""+s);var h=p(this._isDirected,e,t,s);if(Object.prototype.hasOwnProperty.call(this._edgeLabels,h))return r&&(this._edgeLabels[h]=i),this;if(!_(s)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(e),this.setNode(t),this._edgeLabels[h]=r?i:this._defaultEdgeLabelFn(e,t,s);var c=D(this._isDirected,e,t,s);return e=c.v,t=c.w,Object.freeze(c),this._edgeObjs[h]=c,L(this._preds[t],e),L(this._sucs[e],t),this._in[t][h]=c,this._out[e][h]=c,this._edgeCount++,this}edge(e,t,s){var i=arguments.length===1?O(this._isDirected,arguments[0]):p(this._isDirected,e,t,s);return this._edgeLabels[i]}hasEdge(e,t,s){var i=arguments.length===1?O(this._isDirected,arguments[0]):p(this._isDirected,e,t,s);return Object.prototype.hasOwnProperty.call(this._edgeLabels,i)}removeEdge(e,t,s){var i=arguments.length===1?O(this._isDirected,arguments[0]):p(this._isDirected,e,t,s),r=this._edgeObjs[i];return r&&(e=r.v,t=r.w,delete this._edgeLabels[i],delete this._edgeObjs[i],j(this._preds[t],e),j(this._sucs[e],t),delete this._in[t][i],delete this._out[e][i],this._edgeCount--),this}inEdges(e,t){var s=this._in[e];if(s){var i=b(s);return t?g(i,function(r){return r.v===t}):i}}outEdges(e,t){var s=this._out[e];if(s){var i=b(s);return t?g(i,function(r){return r.w===t}):i}}nodeEdges(e,t){var s=this.inEdges(e,t);if(s)return s.concat(this.outEdges(e,t))}};m.prototype._nodeCount=0;m.prototype._edgeCount=0;function L(d,e){d[e]?d[e]++:d[e]=1}o(L,"incrementOrInitEntry");function j(d,e){--d[e]||delete d[e]}o(j,"decrementOrRemoveEntry");function p(d,e,t,s){var i=""+e,r=""+t;if(!d&&i>r){var n=i;i=r,r=n}return i+v+r+v+(_(s)?P:s)}o(p,"edgeArgsToId");function D(d,e,t,s){var i=""+e,r=""+t;if(!d&&i>r){var n=i;i=r,r=n}var h={v:i,w:r};return s&&(h.name=s),h}o(D,"edgeArgsToObj");function O(d,e){return p(d,e.v,e.w,e.name)}o(O,"edgeObjToId");export{m as a}; diff --git a/static/js/chunks/mermaid.esm.min/chunk-ZUCAP7FR.mjs b/static/js/chunks/mermaid.esm.min/chunk-ZUCAP7FR.mjs new file mode 100644 index 0000000..1d78f8b --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/chunk-ZUCAP7FR.mjs @@ -0,0 +1,4 @@ +import{c as Y,d as L}from"./chunk-E7A2AWYO.mjs";import{a as O}from"./chunk-S67DUUA5.mjs";import{a as U}from"./chunk-LM6QDVU5.mjs";import{d as X}from"./chunk-AFC6EC46.mjs";import{m as w}from"./chunk-UENA7NWE.mjs";import{Da as W,G as H,Ha as R,X as b,b as d,ga as C}from"./chunk-OR2G2HG5.mjs";import{a as f}from"./chunk-GTKDMUJJ.mjs";var A=f((r,t,a,o,l)=>{t.arrowTypeStart&&Z(r,"start",t.arrowTypeStart,a,o,l),t.arrowTypeEnd&&Z(r,"end",t.arrowTypeEnd,a,o,l)},"addEdgeMarkers"),z={arrow_cross:"cross",arrow_point:"point",arrow_barb:"barb",arrow_circle:"circle",aggregation:"aggregation",extension:"extension",composition:"composition",dependency:"dependency",lollipop:"lollipop"},Z=f((r,t,a,o,l,i)=>{let s=z[a];if(!s){d.warn(`Unknown arrow type: ${a}`);return}let n=t==="start"?"Start":"End";r.attr(`marker-${t}`,`url(${o}#${l}_${i}-${s}${n})`)},"addEdgeMarker");var T=new Map,x=new Map,Et=f(()=>{T.clear(),x.clear()},"clear"),M=f(r=>r?r.reduce((a,o)=>a+";"+o,""):"","getLabelStyles"),$t=f(async(r,t)=>{let a=H(b().flowchart.htmlLabels),o=await X(r,t.label,{style:M(t.labelStyle),useHtmlLabels:a,addSvgBackground:!0,isNode:!1});d.info("abc82",t,t.labelType);let l=r.insert("g").attr("class","edgeLabel"),i=l.insert("g").attr("class","label");i.node().appendChild(o);let s=o.getBBox();if(a){let e=o.children[0],p=C(o);s=e.getBoundingClientRect(),p.attr("width",s.width),p.attr("height",s.height)}i.attr("transform","translate("+-s.width/2+", "+-s.height/2+")"),T.set(t.id,l),t.width=s.width,t.height=s.height;let n;if(t.startLabelLeft){let e=await L(t.startLabelLeft,M(t.labelStyle)),p=r.insert("g").attr("class","edgeTerminals"),h=p.insert("g").attr("class","inner");n=h.node().appendChild(e);let c=e.getBBox();h.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),x.get(t.id)||x.set(t.id,{}),x.get(t.id).startLeft=p,$(n,t.startLabelLeft)}if(t.startLabelRight){let e=await L(t.startLabelRight,M(t.labelStyle)),p=r.insert("g").attr("class","edgeTerminals"),h=p.insert("g").attr("class","inner");n=p.node().appendChild(e),h.node().appendChild(e);let c=e.getBBox();h.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),x.get(t.id)||x.set(t.id,{}),x.get(t.id).startRight=p,$(n,t.startLabelRight)}if(t.endLabelLeft){let e=await L(t.endLabelLeft,M(t.labelStyle)),p=r.insert("g").attr("class","edgeTerminals"),h=p.insert("g").attr("class","inner");n=h.node().appendChild(e);let c=e.getBBox();h.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),p.node().appendChild(e),x.get(t.id)||x.set(t.id,{}),x.get(t.id).endLeft=p,$(n,t.endLabelLeft)}if(t.endLabelRight){let e=await L(t.endLabelRight,M(t.labelStyle)),p=r.insert("g").attr("class","edgeTerminals"),h=p.insert("g").attr("class","inner");n=h.node().appendChild(e);let c=e.getBBox();h.attr("transform","translate("+-c.width/2+", "+-c.height/2+")"),p.node().appendChild(e),x.get(t.id)||x.set(t.id,{}),x.get(t.id).endRight=p,$(n,t.endLabelRight)}return o},"insertEdgeLabel");function $(r,t){b().flowchart.htmlLabels&&r&&(r.style.width=t.length*9+"px",r.style.height="12px")}f($,"setTerminalWidth");var Tt=f((r,t)=>{d.debug("Moving label abc88 ",r.id,r.label,T.get(r.id),t);let a=t.updatedPath?t.updatedPath:t.originalPath,o=b(),{subGraphTitleTotalMargin:l}=U(o);if(r.label){let i=T.get(r.id),s=r.x,n=r.y;if(a){let e=w.calcLabelPosition(a);d.debug("Moving label "+r.label+" from (",s,",",n,") to (",e.x,",",e.y,") abc88"),t.updatedPath&&(s=e.x,n=e.y)}i.attr("transform",`translate(${s}, ${n+l/2})`)}if(r.startLabelLeft){let i=x.get(r.id).startLeft,s=r.x,n=r.y;if(a){let e=w.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_left",a);s=e.x,n=e.y}i.attr("transform",`translate(${s}, ${n})`)}if(r.startLabelRight){let i=x.get(r.id).startRight,s=r.x,n=r.y;if(a){let e=w.calcTerminalLabelPosition(r.arrowTypeStart?10:0,"start_right",a);s=e.x,n=e.y}i.attr("transform",`translate(${s}, ${n})`)}if(r.endLabelLeft){let i=x.get(r.id).endLeft,s=r.x,n=r.y;if(a){let e=w.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_left",a);s=e.x,n=e.y}i.attr("transform",`translate(${s}, ${n})`)}if(r.endLabelRight){let i=x.get(r.id).endRight,s=r.x,n=r.y;if(a){let e=w.calcTerminalLabelPosition(r.arrowTypeEnd?10:0,"end_right",a);s=e.x,n=e.y}i.attr("transform",`translate(${s}, ${n})`)}},"positionEdgeLabel"),D=f((r,t)=>{let a=r.x,o=r.y,l=Math.abs(t.x-a),i=Math.abs(t.y-o),s=r.width/2,n=r.height/2;return l>=s||i>=n},"outsideNode"),F=f((r,t,a)=>{d.debug(`intersection calc abc89: + outsidePoint: ${JSON.stringify(t)} + insidePoint : ${JSON.stringify(a)} + node : x:${r.x} y:${r.y} w:${r.width} h:${r.height}`);let o=r.x,l=r.y,i=Math.abs(o-a.x),s=r.width/2,n=a.xMath.abs(o-t.x)*e){let c=a.y{d.warn("abc88 cutPathAtIntersect",r,t);let a=[],o=r[0],l=!1;return r.forEach(i=>{if(d.info("abc88 checking point",i,t),!D(t,i)&&!l){let s=F(t,o,i);d.debug("abc88 inside",i,o,s),d.debug("abc88 intersection",s,t);let n=!1;a.forEach(e=>{n=n||e.x===s.x&&e.y===s.y}),a.some(e=>e.x===s.x&&e.y===s.y)?d.warn("abc88 no intersect",s,a):a.push(s),l=!0}else d.warn("abc88 outside",i,o),o=i,l||a.push(i)}),d.debug("returning points",a),a},"cutPathAtIntersect");function K(r){let t=[],a=[];for(let o=1;o5&&Math.abs(i.y-l.y)>5||l.y===i.y&&i.x===s.x&&Math.abs(i.x-l.x)>5&&Math.abs(i.y-s.y)>5)&&(t.push(i),a.push(o))}return{cornerPoints:t,cornerPointPositions:a}}f(K,"extractCornerPoints");var N=f(function(r,t,a){let o=t.x-r.x,l=t.y-r.y,i=Math.sqrt(o*o+l*l),s=a/i;return{x:t.x-s*o,y:t.y-s*l}},"findAdjacentPoint"),P=f(function(r){let{cornerPointPositions:t}=K(r),a=[];for(let o=0;o10&&Math.abs(i.y-l.y)>=10){d.debug("Corner point fixing",Math.abs(i.x-l.x),Math.abs(i.y-l.y));let y=5;s.x===n.x?m={x:p<0?n.x-y+c:n.x+y-c,y:h<0?n.y-c:n.y+c}:m={x:p<0?n.x-c:n.x+c,y:h<0?n.y-y+c:n.y+y-c}}else d.debug("Corner point skipping fixing",Math.abs(i.x-l.x),Math.abs(i.y-l.y));a.push(m,e)}else a.push(r[o]);return a},"fixCorners"),vt=f(function(r,t,a,o,l,i,s){let{handDrawnSeed:n}=b(),e=t.points,p=!1,h=l;var c=i;c.intersect&&h.intersect&&(e=e.slice(1,t.points.length-1),e.unshift(h.intersect(e[0])),d.debug("Last point APA12",t.start,"-->",t.end,e[e.length-1],c,c.intersect(e[e.length-1])),e.push(c.intersect(e[e.length-1]))),t.toCluster&&(d.info("to cluster abc88",a.get(t.toCluster)),e=q(t.points,a.get(t.toCluster).node),p=!0),t.fromCluster&&(d.debug("from cluster abc88",a.get(t.fromCluster),JSON.stringify(e,null,2)),e=q(e.reverse(),a.get(t.fromCluster).node).reverse(),p=!0);let m=e.filter(u=>!Number.isNaN(u.y));m=P(m);let y=R;t.curve&&(y=t.curve);let{x:G,y:V}=O(t),j=W().x(G).y(V).curve(y),k;switch(t.thickness){case"normal":k="edge-thickness-normal";break;case"thick":k="edge-thickness-thick";break;case"invisible":k="edge-thickness-invisible";break;default:k="edge-thickness-normal"}switch(t.pattern){case"solid":k+=" edge-pattern-solid";break;case"dotted":k+=" edge-pattern-dotted";break;case"dashed":k+=" edge-pattern-dashed";break;default:k+=" edge-pattern-solid"}let g,B=j(m),S=Array.isArray(t.style)?t.style:[t.style];if(t.look==="handDrawn"){let u=Y.svg(r);Object.assign([],m);let _=u.path(B,{roughness:.3,seed:n});k+=" transition",g=C(_).select("path").attr("id",t.id).attr("class"," "+k+(t.classes?" "+t.classes:"")).attr("style",S?S.reduce((J,Q)=>J+";"+Q,""):"");let I=g.attr("d");g.attr("d",I),r.node().appendChild(g.node())}else g=r.append("path").attr("d",B).attr("id",t.id).attr("class"," "+k+(t.classes?" "+t.classes:"")).attr("style",S?S.reduce((u,_)=>u+";"+_,""):"");let E="";(b().flowchart.arrowMarkerAbsolute||b().state.arrowMarkerAbsolute)&&(E=window.location.protocol+"//"+window.location.host+window.location.pathname+window.location.search,E=E.replace(/\(/g,"\\(").replace(/\)/g,"\\)")),d.info("arrowTypeStart",t.arrowTypeStart),d.info("arrowTypeEnd",t.arrowTypeEnd),A(g,t,E,s,o);let v={};return p&&(v.updatedPath=e),v.originalPath=t.points,v},"insertEdge");var tt=f((r,t,a,o)=>{t.forEach(l=>{pt[l](r,a,o)})},"insertMarkers"),rt=f((r,t,a)=>{d.trace("Making markers for ",a),r.append("defs").append("marker").attr("id",a+"_"+t+"-extensionStart").attr("class","marker extension "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 1,7 L18,13 V 1 Z"),r.append("defs").append("marker").attr("id",a+"_"+t+"-extensionEnd").attr("class","marker extension "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 1,1 V 13 L18,7 Z")},"extension"),at=f((r,t,a)=>{r.append("defs").append("marker").attr("id",a+"_"+t+"-compositionStart").attr("class","marker composition "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",a+"_"+t+"-compositionEnd").attr("class","marker composition "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"composition"),et=f((r,t,a)=>{r.append("defs").append("marker").attr("id",a+"_"+t+"-aggregationStart").attr("class","marker aggregation "+t).attr("refX",18).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",a+"_"+t+"-aggregationEnd").attr("class","marker aggregation "+t).attr("refX",1).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L1,7 L9,1 Z")},"aggregation"),st=f((r,t,a)=>{r.append("defs").append("marker").attr("id",a+"_"+t+"-dependencyStart").attr("class","marker dependency "+t).attr("refX",6).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("path").attr("d","M 5,7 L9,13 L1,7 L9,1 Z"),r.append("defs").append("marker").attr("id",a+"_"+t+"-dependencyEnd").attr("class","marker dependency "+t).attr("refX",13).attr("refY",7).attr("markerWidth",20).attr("markerHeight",28).attr("orient","auto").append("path").attr("d","M 18,7 L9,13 L14,7 L9,1 Z")},"dependency"),nt=f((r,t,a)=>{r.append("defs").append("marker").attr("id",a+"_"+t+"-lollipopStart").attr("class","marker lollipop "+t).attr("refX",13).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6),r.append("defs").append("marker").attr("id",a+"_"+t+"-lollipopEnd").attr("class","marker lollipop "+t).attr("refX",1).attr("refY",7).attr("markerWidth",190).attr("markerHeight",240).attr("orient","auto").append("circle").attr("stroke","black").attr("fill","transparent").attr("cx",7).attr("cy",7).attr("r",6)},"lollipop"),ot=f((r,t,a)=>{r.append("marker").attr("id",a+"_"+t+"-pointEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 0 L 10 5 L 0 10 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",a+"_"+t+"-pointStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",4.5).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",8).attr("markerHeight",8).attr("orient","auto").append("path").attr("d","M 0 5 L 10 10 L 10 0 z").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"point"),it=f((r,t,a)=>{r.append("marker").attr("id",a+"_"+t+"-circleEnd").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",11).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0"),r.append("marker").attr("id",a+"_"+t+"-circleStart").attr("class","marker "+t).attr("viewBox","0 0 10 10").attr("refX",-1).attr("refY",5).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("circle").attr("cx","5").attr("cy","5").attr("r","5").attr("class","arrowMarkerPath").style("stroke-width",1).style("stroke-dasharray","1,0")},"circle"),lt=f((r,t,a)=>{r.append("marker").attr("id",a+"_"+t+"-crossEnd").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",12).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0"),r.append("marker").attr("id",a+"_"+t+"-crossStart").attr("class","marker cross "+t).attr("viewBox","0 0 11 11").attr("refX",-1).attr("refY",5.2).attr("markerUnits","userSpaceOnUse").attr("markerWidth",11).attr("markerHeight",11).attr("orient","auto").append("path").attr("d","M 1,1 l 9,9 M 10,1 l -9,9").attr("class","arrowMarkerPath").style("stroke-width",2).style("stroke-dasharray","1,0")},"cross"),ct=f((r,t,a)=>{r.append("defs").append("marker").attr("id",a+"_"+t+"-barbEnd").attr("refX",19).attr("refY",7).attr("markerWidth",20).attr("markerHeight",14).attr("markerUnits","userSpaceOnUse").attr("orient","auto").append("path").attr("d","M 19,7 L9,13 L14,7 L9,1 Z")},"barb"),pt={extension:rt,composition:at,aggregation:et,dependency:st,lollipop:nt,point:ot,circle:it,cross:lt,barb:ct},Ht=tt;export{Et as a,$t as b,Tt as c,vt as d,Ht as e}; diff --git a/static/js/chunks/mermaid.esm.min/dagre-RF25WEIW.mjs b/static/js/chunks/mermaid.esm.min/dagre-RF25WEIW.mjs new file mode 100644 index 0000000..785a7dd --- /dev/null +++ b/static/js/chunks/mermaid.esm.min/dagre-RF25WEIW.mjs @@ -0,0 +1,4 @@ +import{a as R,b as M,c as F,d as U,e as Y}from"./chunk-ZUCAP7FR.mjs";import{b as G,f as _,g as T,h as H,i as j,j as V,k as O}from"./chunk-E7A2AWYO.mjs";import"./chunk-S67DUUA5.mjs";import{a as A}from"./chunk-LM6QDVU5.mjs";import"./chunk-D4BOYBYT.mjs";import"./chunk-AFC6EC46.mjs";import{a as z}from"./chunk-FASC7IG4.mjs";import{a as C}from"./chunk-ZN7TASNU.mjs";import"./chunk-UENA7NWE.mjs";import"./chunk-TI4EEUUG.mjs";import{X as B,b as i}from"./chunk-OR2G2HG5.mjs";import{D as N,e as q,s as k}from"./chunk-5ZJXQJOJ.mjs";import"./chunk-YPUTD6PB.mjs";import"./chunk-6BY5RJGC.mjs";import{a as g}from"./chunk-GTKDMUJJ.mjs";function h(e){var t={options:{directed:e.isDirected(),multigraph:e.isMultigraph(),compound:e.isCompound()},nodes:re(e),edges:se(e)};return N(e.graph())||(t.value=q(e.graph())),t}g(h,"write");function re(e){return k(e.nodes(),function(t){var n=e.node(t),c=e.parent(t),s={v:t};return N(n)||(s.value=n),N(c)||(s.parent=c),s})}g(re,"writeNodes");function se(e){return k(e.edges(),function(t){var n=e.edge(t),c={v:t.v,w:t.w};return N(t.name)||(c.name=t.name),N(n)||(c.value=n),c})}g(se,"writeEdges");var a=new Map,v=new Map,W=new Map,Z=g(()=>{v.clear(),W.clear(),a.clear()},"clear"),J=g((e,t)=>{let n=v.get(t)||[];return i.trace("In isDescendant",t," ",e," = ",n.includes(e)),n.includes(e)},"isDescendant"),ce=g((e,t)=>{let n=v.get(t)||[];return i.info("Descendants of ",t," is ",n),i.info("Edge is ",e),e.v===t||e.w===t?!1:n?n.includes(e.v)||J(e.v,t)||J(e.w,t)||n.includes(e.w):(i.debug("Tilt, ",t,",not in descendants"),!1)},"edgeInCluster"),$=g((e,t,n,c)=>{i.warn("Copying children of ",e,"root",c,"data",t.node(e),c);let s=t.children(e)||[];e!==c&&s.push(e),i.warn("Copying (nodes) clusterId",e,"nodes",s),s.forEach(o=>{if(t.children(o).length>0)$(o,t,n,c);else{let l=t.node(o);i.info("cp ",o," to ",c," with parent ",e),n.setNode(o,l),c!==t.parent(o)&&(i.warn("Setting parent",o,t.parent(o)),n.setParent(o,t.parent(o))),e!==c&&o!==e?(i.debug("Setting parent",o,e),n.setParent(o,e)):(i.info("In copy ",e,"root",c,"data",t.node(e),c),i.debug("Not Setting parent for node=",o,"cluster!==rootId",e!==c,"node!==clusterId",o!==e));let u=t.edges(o);i.debug("Copying Edges",u),u.forEach(d=>{i.info("Edge",d);let m=t.edge(d.v,d.w,d.name);i.info("Edge data",m,c);try{ce(d,c)?(i.info("Copying as ",d.v,d.w,m,d.name),n.setEdge(d.v,d.w,m,d.name),i.info("newGraph edges ",n.edges(),n.edge(n.edges()[0]))):i.info("Skipping copy of edge ",d.v,"-->",d.w," rootId: ",c," clusterId:",e)}catch(p){i.error(p)}})}i.debug("Removing node",o),t.removeNode(o)})},"copy"),L=g((e,t)=>{let n=t.children(e),c=[...n];for(let s of n)W.set(s,e),c=[...c,...L(s,t)];return c},"extractDescendants");var ae=g((e,t,n)=>{let c=e.edges().filter(d=>d.v===t||d.w===t),s=e.edges().filter(d=>d.v===n||d.w===n),o=c.map(d=>({v:d.v===t?n:d.v,w:d.w===t?t:d.w})),l=s.map(d=>({v:d.v,w:d.w}));return o.filter(d=>l.some(m=>d.v===m.v&&d.w===m.w))},"findCommonEdges"),y=g((e,t,n)=>{let c=t.children(e);if(i.trace("Searching children of id ",e,c),c.length<1)return e;let s;for(let o of c){let l=y(o,t,n),u=ae(t,n,l);if(l)if(u.length>0)s=l;else return l}return s},"findNonClusterChild"),Q=g(e=>!a.has(e)||!a.get(e).externalConnections?e:a.has(e)?a.get(e).id:e,"getAnchorId"),I=g((e,t)=>{if(!e||t>10){i.debug("Opting out, no graph ");return}else i.debug("Opting in, graph ");e.nodes().forEach(function(n){e.children(n).length>0&&(i.warn("Cluster identified",n," Replacement id in edges: ",y(n,e,n)),v.set(n,L(n,e)),a.set(n,{id:y(n,e,n),clusterData:e.node(n)}))}),e.nodes().forEach(function(n){let c=e.children(n),s=e.edges();c.length>0?(i.debug("Cluster identified",n,v),s.forEach(o=>{let l=J(o.v,n),u=J(o.w,n);l^u&&(i.warn("Edge: ",o," leaves cluster ",n),i.warn("Descendants of XXX ",n,": ",v.get(n)),a.get(n).externalConnections=!0)})):i.debug("Not a cluster ",n,v)});for(let n of a.keys()){let c=a.get(n).id,s=e.parent(c);s!==n&&a.has(s)&&!a.get(s).externalConnections&&(a.get(n).id=s)}e.edges().forEach(function(n){let c=e.edge(n);i.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(n)),i.warn("Edge "+n.v+" -> "+n.w+": "+JSON.stringify(e.edge(n)));let s=n.v,o=n.w;if(i.warn("Fix XXX",a,"ids:",n.v,n.w,"Translating: ",a.get(n.v)," --- ",a.get(n.w)),a.get(n.v)||a.get(n.w)){if(i.warn("Fixing and trying - removing XXX",n.v,n.w,n.name),s=Q(n.v),o=Q(n.w),e.removeEdge(n.v,n.w,n.name),s!==n.v){let l=e.parent(s);a.get(l).externalConnections=!0,c.fromCluster=n.v}if(o!==n.w){let l=e.parent(o);a.get(l).externalConnections=!0,c.toCluster=n.w}i.warn("Fix Replacing with XXX",s,o,n.name),e.setEdge(s,o,c,n.name)}}),i.warn("Adjusted Graph",h(e)),ee(e,0),i.trace(a)},"adjustClustersAndEdges"),ee=g((e,t)=>{if(i.warn("extractor - ",t,h(e),e.children("D")),t>10){i.error("Bailing out");return}let n=e.nodes(),c=!1;for(let s of n){let o=e.children(s);c=c||o.length>0}if(!c){i.debug("Done, no node has children",e.nodes());return}i.debug("Nodes = ",n,t);for(let s of n)if(i.debug("Extracting node",s,a,a.has(s)&&!a.get(s).externalConnections,!e.parent(s),e.node(s),e.children("D")," Depth ",t),!a.has(s))i.debug("Not a cluster",s,t);else if(!a.get(s).externalConnections&&e.children(s)&&e.children(s).length>0){i.warn("Cluster without external connections, without a parent and with children",s,t);let l=e.graph().rankdir==="TB"?"LR":"TB";a.get(s)?.clusterData?.dir&&(l=a.get(s).clusterData.dir,i.warn("Fixing dir",a.get(s).clusterData.dir,l));let u=new C({multigraph:!0,compound:!0}).setGraph({rankdir:l,nodesep:50,ranksep:50,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}});i.warn("Old graph before copy",h(e)),$(s,e,u,s),e.setNode(s,{clusterNode:!0,id:s,clusterData:a.get(s).clusterData,label:a.get(s).label,graph:u}),i.warn("New graph after copy node: (",s,")",h(u)),i.debug("Old graph after copy",h(e))}else i.warn("Cluster ** ",s," **not meeting the criteria !externalConnections:",!a.get(s).externalConnections," no parent: ",!e.parent(s)," children ",e.children(s)&&e.children(s).length>0,e.children("D"),t),i.debug(a);n=e.nodes(),i.warn("New list of nodes",n);for(let s of n){let o=e.node(s);i.warn(" Now next level",s,o),o?.clusterNode&&ee(o.graph,t+1)}},"extractor"),ne=g((e,t)=>{if(t.length===0)return[];let n=Object.assign([],t);return t.forEach(c=>{let s=e.children(c),o=ne(e,s);n=[...n,...o]}),n},"sorter"),te=g(e=>ne(e,e.children()),"sortNodesByHierarchy");var ie=g(async(e,t,n,c,s,o)=>{i.warn("Graph in recursive render:XAX",h(t),s);let l=t.graph().rankdir;i.trace("Dir in recursive render - dir:",l);let u=e.insert("g").attr("class","root");t.nodes()?i.info("Recursive render XXX",t.nodes()):i.info("No nodes found for",t),t.edges().length>0&&i.info("Recursive edges",t.edge(t.edges()[0]));let d=u.insert("g").attr("class","clusters"),m=u.insert("g").attr("class","edgePaths"),p=u.insert("g").attr("class","edgeLabels"),b=u.insert("g").attr("class","nodes");await Promise.all(t.nodes().map(async function(f){let r=t.node(f);if(s!==void 0){let w=JSON.parse(JSON.stringify(s.clusterData));i.trace(`Setting data for parent cluster XXX + Node.id = `,f,` + data=`,w.height,` +Parent cluster`,s.height),t.setNode(s.id,w),t.parent(f)||(i.trace("Setting parent",f,s.id),t.setParent(f,s.id,w))}if(i.info("(Insert) Node XXX"+f+": "+JSON.stringify(t.node(f))),r?.clusterNode){i.info("Cluster identified XBX",f,r.width,t.node(f));let{ranksep:w,nodesep:X}=t.graph();r.graph.setGraph({...r.graph.graph(),ranksep:w+25,nodesep:X});let E=await ie(b,r.graph,n,c,t.node(f),o),D=E.elem;G(r,D),r.diff=E.diff||0,i.info("New compound node after recursive render XAX",f,"width",r.width,"height",r.height),j(D,r)}else t.children(f).length>0?(i.trace("Cluster - the non recursive path XBX",f,r.id,r,r.width,"Graph:",t),i.trace(y(r.id,t)),a.set(r.id,{id:y(r.id,t),node:r})):(i.trace("Node - the non recursive path XAX",f,b,t.node(f),l),await H(b,t.node(f),{config:o,dir:l}))})),await g(async()=>{let f=t.edges().map(async function(r){let w=t.edge(r.v,r.w,r.name);i.info("Edge "+r.v+" -> "+r.w+": "+JSON.stringify(r)),i.info("Edge "+r.v+" -> "+r.w+": ",r," ",JSON.stringify(t.edge(r))),i.info("Fix",a,"ids:",r.v,r.w,"Translating: ",a.get(r.v),a.get(r.w)),await M(p,w)});await Promise.all(f)},"processEdges")(),i.info("Graph before layout:",JSON.stringify(h(t))),i.info("############################################# XXX"),i.info("### Layout ### XXX"),i.info("############################################# XXX"),z(t),i.info("Graph after layout:",JSON.stringify(h(t)));let P=0,{subGraphTitleTotalMargin:S}=A(o);return await Promise.all(te(t).map(async function(f){let r=t.node(f);if(i.info("Position XBX => "+f+": ("+r.x,","+r.y,") width: ",r.width," height: ",r.height),r?.clusterNode)r.y+=S,i.info("A tainted cluster node XBX1",f,r.id,r.width,r.height,r.x,r.y,t.parent(f)),a.get(r.id).node=r,O(r);else if(t.children(f).length>0){i.info("A pure cluster node XBX1",f,r.id,r.x,r.y,r.width,r.height,t.parent(f)),r.height+=S,t.node(r.parentId);let w=r?.padding/2||0,X=r?.labelBBox?.height||0,E=X-w||0;i.debug("OffsetY",E,"labelHeight",X,"halfPadding",w),await _(d,r),a.get(r.id).node=r}else{let w=t.node(r.parentId);r.y+=S/2,i.info("A regular node XBX1 - using the padding",r.id,"parent",r.parentId,r.width,r.height,r.x,r.y,"offsetY",r.offsetY,"parent",w,w?.offsetY,r),O(r)}})),t.edges().forEach(function(f){let r=t.edge(f);i.info("Edge "+f.v+" -> "+f.w+": "+JSON.stringify(r),r),r.points.forEach(D=>D.y+=S/2);let w=t.node(f.v);var X=t.node(f.w);let E=U(m,r,a,n,w,X,c);F(r,E)}),t.nodes().forEach(function(f){let r=t.node(f);i.info(f,r.type,r.diff),r.isGroup&&(P=r.diff)}),i.warn("Returning from recursive render XAX",u,P),{elem:u,diff:P}},"recursiveRender"),Se=g(async(e,t)=>{let n=new C({multigraph:!0,compound:!0}).setGraph({rankdir:e.direction,nodesep:e.config?.nodeSpacing||e.config?.flowchart?.nodeSpacing||e.nodeSpacing,ranksep:e.config?.rankSpacing||e.config?.flowchart?.rankSpacing||e.rankSpacing,marginx:8,marginy:8}).setDefaultEdgeLabel(function(){return{}}),c=t.select("g");Y(c,e.markers,e.type,e.diagramId),V(),R(),T(),Z(),e.nodes.forEach(o=>{n.setNode(o.id,{...o}),o.parentId&&n.setParent(o.id,o.parentId)}),i.debug("Edges:",e.edges),e.edges.forEach(o=>{if(o.start===o.end){let l=o.start,u=l+"---"+l+"---1",d=l+"---"+l+"---2",m=n.node(l);n.setNode(u,{domId:u,id:u,parentId:m.parentId,labelStyle:"",label:"",padding:0,shape:"labelRect",style:"",width:10,height:10}),n.setParent(u,m.parentId),n.setNode(d,{domId:d,id:d,parentId:m.parentId,labelStyle:"",padding:0,shape:"labelRect",label:"",style:"",width:10,height:10}),n.setParent(d,m.parentId);let p=structuredClone(o),b=structuredClone(o),x=structuredClone(o);p.label="",p.arrowTypeEnd="none",p.id=l+"-cyclic-special-1",b.arrowTypeEnd="none",b.id=l+"-cyclic-special-mid",x.label="",m.isGroup&&(p.fromCluster=l,x.toCluster=l),x.id=l+"-cyclic-special-2",n.setEdge(l,u,p,l+"-cyclic-special-0"),n.setEdge(u,d,b,l+"-cyclic-special-1"),n.setEdge(d,l,x,l+"-cycrt.sanitizeText(e,Ue),"sanitizeText"),n1=u(function(e){for(let r of Ae.values())if(r.id===e)return r.domId;return e},"lookUpDomId"),Mt=u(function(e,r,n,i,o,f,g={},S){if(!e||e.trim().length===0)return;let h,l=Ae.get(e);if(l===void 0&&(l={id:e,labelType:"text",domId:Ot+e+"-"+Et,styles:[],classes:[]},Ae.set(e,l)),Et++,r!==void 0?(Ue=ke(),h=r1(r.text.trim()),l.labelType=r.type,h.startsWith('"')&&h.endsWith('"')&&(h=h.substring(1,h.length-1)),l.text=h):l.text===void 0&&(l.text=e),n!==void 0&&(l.type=n),i?.forEach(function(T){l.styles.push(T)}),o?.forEach(function(T){l.classes.push(T)}),f!==void 0&&(l.dir=f),l.props===void 0?l.props=g:g!==void 0&&Object.assign(l.props,g),S!==void 0){let T;S.includes(` +`)?T=S+` +`:T=`{ +`+S+` +}`;let b=gt(T,{schema:pt});if(b.shape){if(b.shape!==b.shape.toLowerCase()||b.shape.includes("_"))throw new Error(`No such shape: ${b.shape}. Shape names should be lowercase.`);if(!ft(b.shape))throw new Error(`No such shape: ${b.shape}.`);l.type=b?.shape}b?.label&&(l.text=b?.label),b?.icon&&(l.icon=b?.icon,!b.label?.trim()&&l.text===e&&(l.text="")),b?.form&&(l.form=b?.form),b?.pos&&(l.pos=b?.pos),b?.img&&(l.img=b?.img,!b.label?.trim()&&l.text===e&&(l.text="")),b?.constraint&&(l.constraint=b.constraint),b.w&&(l.assetWidth=Number(b.w)),b.h&&(l.assetHeight=Number(b.h))}},"addVertex"),Gt=u(function(e,r,n){let f={start:e,end:r,type:void 0,text:"",labelType:"text"};J.info("abc78 Got edge...",f);let g=n.text;if(g!==void 0&&(f.text=r1(g.text.trim()),f.text.startsWith('"')&&f.text.endsWith('"')&&(f.text=f.text.substring(1,f.text.length-1)),f.labelType=g.type),n!==void 0&&(f.type=n.type,f.stroke=n.stroke,f.length=n.length>10?10:n.length),j.length<(Ue.maxEdges??500))J.info("Pushing edge..."),j.push(f);else throw new Error(`Edge limit exceeded. ${j.length} edges found, but the limit is ${Ue.maxEdges}. + +Initialize mermaid with maxEdges set to a higher number to allow more edges. +You cannot set this config via configuration inside the diagram as it is a secure config. +You have to call mermaid.initialize.`)},"addSingleLink"),Ut=u(function(e,r,n){J.info("addLink",e,r,n);for(let i of e)for(let o of r)Gt(i,o,n)},"addLink"),Wt=u(function(e,r){e.forEach(function(n){n==="default"?j.defaultInterpolate=r:j[n].interpolate=r})},"updateLinkInterpolate"),jt=u(function(e,r){e.forEach(function(n){if(typeof n=="number"&&n>=j.length)throw new Error(`The index ${n} for linkStyle is out of bounds. Valid indices for linkStyle are between 0 and ${j.length-1}. (Help: Ensure that the index is within the range of existing edges.)`);n==="default"?j.defaultStyle=r:(j[n].style=r,(j[n]?.style?.length??0)>0&&!j[n]?.style?.some(i=>i?.startsWith("fill"))&&j[n]?.style?.push("fill:none"))})},"updateLink"),Kt=u(function(e,r){e.split(",").forEach(function(n){let i=Ye.get(n);i===void 0&&(i={id:n,styles:[],textStyles:[]},Ye.set(n,i)),r?.forEach(function(o){if(/color/.exec(o)){let f=o.replace("fill","bgFill");i.textStyles.push(f)}i.styles.push(o)})})},"addClass"),Yt=u(function(e){Z=e,/.*/.exec(Z)&&(Z="LR"),/.*v/.exec(Z)&&(Z="TB"),Z==="TD"&&(Z="TB")},"setDirection"),m1=u(function(e,r){for(let n of e.split(",")){let i=Ae.get(n);i&&i.classes.push(r);let o=k1.get(n);o&&o.classes.push(r)}},"setClass"),zt=u(function(e,r){if(r!==void 0){r=r1(r);for(let n of e.split(","))A1.set(t1==="gen-1"?n1(n):n,r)}},"setTooltip"),Ht=u(function(e,r,n){let i=n1(e);if(ke().securityLevel!=="loose"||r===void 0)return;let o=[];if(typeof n=="string"){o=n.split(/,(?=(?:(?:[^"]*"){2})*[^"]*$)/);for(let g=0;g")),o.classed("hover",!0)}).on("mouseout",function(){r.transition().duration(500).style("opacity",0),de(this).classed("hover",!1)})},"setupToolTips");s1.push(Dt);var Zt=u(function(e="gen-1"){Ae=new Map,Ye=new Map,j=[],s1=[Dt],fe=[],k1=new Map,e1=0,A1=new Map,g1=!0,t1=e,Ue=ke(),nt()},"clear"),$t=u(e=>{t1=e||"gen-2"},"setGen"),es=u(function(){return"fill:#ffa;stroke: #f66; stroke-width: 3px; stroke-dasharray: 5, 5;fill:#ffa;stroke: #666;"},"defaultStyle"),ts=u(function(e,r,n){let i=e.text.trim(),o=n.text;e===n&&/\s/.exec(n.text)&&(i=void 0);function f(l){let T={boolean:{},number:{},string:{}},b=[],K;return{nodeList:l.filter(function(k){let y=typeof k;return k.stmt&&k.stmt==="dir"?(K=k.value,!1):k.trim()===""?!1:y in T?T[y].hasOwnProperty(k)?!1:T[y][k]=!0:b.includes(k)?!1:b.push(k)}),dir:K}}u(f,"uniq");let{nodeList:g,dir:S}=f(r.flat());if(t1==="gen-1")for(let l=0;l2e3)return{result:!1,count:0};if(Ct[Ke]=r,fe[r].id===e)return{result:!0,count:0};let i=0,o=1;for(;i=0){let g=Ft(e,f);if(g.result)return{result:!0,count:o+g.count};o=o+g.count}i=i+1}return{result:!1,count:o}},"indexNodes2"),rs=u(function(e){return Ct[e]},"getDepthFirstPos"),ns=u(function(){Ke=-1,fe.length>0&&Ft("none",fe.length-1)},"indexNodes"),Tt=u(function(){return fe},"getSubGraphs"),is=u(()=>g1?(g1=!1,!0):!1,"firstGraph"),as=u(e=>{let r=e.trim(),n="arrow_open";switch(r[0]){case"<":n="arrow_point",r=r.slice(1);break;case"x":n="arrow_cross",r=r.slice(1);break;case"o":n="arrow_circle",r=r.slice(1);break}let i="normal";return r.includes("=")&&(i="thick"),r.includes(".")&&(i="dotted"),{type:n,stroke:i}},"destructStartLink"),us=u((e,r)=>{let n=r.length,i=0;for(let o=0;o{let r=e.trim(),n=r.slice(0,-1),i="arrow_open";switch(r.slice(-1)){case"x":i="arrow_cross",r.startsWith("x")&&(i="double_"+i,n=n.slice(1));break;case">":i="arrow_point",r.startsWith("<")&&(i="double_"+i,n=n.slice(1));break;case"o":i="arrow_circle",r.startsWith("o")&&(i="double_"+i,n=n.slice(1));break}let o="normal",f=n.length-1;n.startsWith("=")&&(o="thick"),n.startsWith("~")&&(o="invisible");let g=us(".",n);return g&&(o="dotted",f=g),{type:i,stroke:o,length:f}},"destructEndLink"),ls=u((e,r)=>{let n=os(e),i;if(r){if(i=as(r),i.stroke!==n.stroke)return{type:"INVALID",stroke:"INVALID"};if(i.type==="arrow_open")i.type=n.type;else{if(i.type!==n.type)return{type:"INVALID",stroke:"INVALID"};i.type="double_"+i.type}return i.type==="double_arrow"&&(i.type="double_arrow_point"),i.length=n.length,i}return n},"destructLink"),Bt=u((e,r)=>{for(let n of e)if(n.nodes.includes(r))return!0;return!1},"exists"),_t=u((e,r)=>{let n=[];return e.nodes.forEach((i,o)=>{Bt(r,i)||n.push(e.nodes[o])}),{nodes:n}},"makeUniq"),cs={firstGraph:is},hs=u(e=>{if(e.img)return"imageSquare";if(e.icon)return e.form==="circle"?"iconCircle":e.form==="square"?"iconSquare":e.form==="rounded"?"iconRounded":"icon";switch(e.type){case"square":case void 0:return"squareRect";case"round":return"roundedRect";case"ellipse":return"ellipse";default:return e.type}},"getTypeFromVertex"),ds=u((e,r)=>e.find(n=>n.id===r),"findNode"),fs=u(e=>{let r="none",n="arrow_point";switch(e){case"arrow_point":case"arrow_circle":case"arrow_cross":n=e;break;case"double_arrow_point":case"double_arrow_circle":case"double_arrow_cross":r=e.replace("double_",""),n=r;break}return{arrowTypeStart:r,arrowTypeEnd:n}},"destructEdgeType"),ps=u((e,r,n,i,o,f)=>{let g=n.get(e.id),S=i.get(e.id)??!1,h=ds(r,e.id);if(h)h.cssStyles=e.styles,h.cssCompiledStyles=b1(e.classes),h.cssClasses=e.classes.join(" ");else{let l={id:e.id,label:e.text,labelStyle:"",parentId:g,padding:o.flowchart?.padding||8,cssStyles:e.styles,cssCompiledStyles:b1(["default","node",...e.classes]),cssClasses:"default "+e.classes.join(" "),dir:e.dir,domId:e.domId,look:f,link:e.link,linkTarget:e.linkTarget,tooltip:xt(e.id),icon:e.icon,pos:e.pos,img:e.img,assetWidth:e.assetWidth,assetHeight:e.assetHeight,constraint:e.constraint};S?r.push({...l,isGroup:!0,shape:"rect"}):r.push({...l,isGroup:!1,shape:hs(e)})}},"addNodeFromVertex");function b1(e){let r=[];for(let n of e){let i=Ye.get(n);i?.styles&&(r=[...r,...i.styles??[]].map(o=>o.trim())),i?.textStyles&&(r=[...r,...i.textStyles??[]].map(o=>o.trim()))}return r}u(b1,"getCompiledStyles");var gs=u(()=>{let e=ke(),r=[],n=[],i=Tt(),o=new Map,f=new Map;for(let h=i.length-1;h>=0;h--){let l=i[h];l.nodes.length>0&&f.set(l.id,!0);for(let T of l.nodes)o.set(T,l.id)}for(let h=i.length-1;h>=0;h--){let l=i[h];r.push({id:l.id,label:l.title,labelStyle:"",parentId:o.get(l.id),padding:8,cssCompiledStyles:b1(l.classes),cssClasses:l.classes.join(" "),shape:"rect",dir:l.dir,isGroup:!0,look:e.look})}yt().forEach(h=>{ps(h,r,o,f,e,e.look||"classic")});let S=St();return S.forEach((h,l)=>{let{arrowTypeStart:T,arrowTypeEnd:b}=fs(h.type),K=[...S.defaultStyle??[]];h.style&&K.push(...h.style);let Y={id:dt(h.start,h.end,{counter:l,prefix:"L"}),start:h.start,end:h.end,type:h.type??"normal",label:h.text,labelpos:"c",thickness:h.stroke,minlen:h.length,classes:h?.stroke==="invisible"?"":"edge-thickness-normal edge-pattern-solid flowchart-link",arrowTypeStart:h?.stroke==="invisible"?"none":T,arrowTypeEnd:h?.stroke==="invisible"?"none":b,arrowheadStyle:"fill: #333",labelStyle:K,style:K,pattern:h.stroke,look:e.look};n.push(Y)}),{nodes:r,edges:n,other:{},config:e}},"getData"),i1={defaultConfig:u(()=>ht.flowchart,"defaultConfig"),setAccTitle:it,getAccTitle:at,getAccDescription:ot,getData:gs,setAccDescription:ut,addVertex:Mt,lookUpDomId:n1,addLink:Ut,updateLinkInterpolate:Wt,updateLink:jt,addClass:Kt,setDirection:Yt,setClass:m1,setTooltip:zt,getTooltip:xt,setClickEvent:qt,setLink:Xt,bindFunctions:Qt,getDirection:E1,getVertices:yt,getEdges:St,getClasses:Jt,clear:Zt,setGen:$t,defaultStyle:es,addSubGraph:ts,getDepthFirstPos:rs,indexNodes:ns,getSubGraphs:Tt,destructLink:ls,lex:cs,exists:Bt,makeUniq:_t,setDiagramTitle:lt,getDiagramTitle:ct};var bs=u(function(e,r){return r.db.getClasses()},"getClasses"),ks=u(async function(e,r,n,i){J.info("REF0:"),J.info("Drawing state diagram (v2)",r);let{securityLevel:o,flowchart:f,layout:g}=ke(),S;o==="sandbox"&&(S=de("#i"+r));let h=o==="sandbox"?S.nodes()[0].contentDocument:document;J.debug("Before getData: ");let l=i.db.getData();J.debug("Data: ",l);let T=bt(r,o),b=E1();l.type=i.type,l.layoutAlgorithm=At(g),l.layoutAlgorithm==="dagre"&&g==="elk"&&J.warn("flowchart-elk was moved to an external package in Mermaid v11. Please refer [release notes](https://github.com/mermaid-js/mermaid/releases/tag/v11.0.0) for more details. This diagram will be rendered using `dagre` layout as a fallback."),l.direction=b,l.nodeSpacing=f?.nodeSpacing||50,l.rankSpacing=f?.rankSpacing||50,l.markers=["point","circle","cross"],l.diagramId=r,J.debug("REF1:",l),await kt(l,T);let K=l.config.flowchart?.diagramPadding??8;je.insertTitle(T,"flowchartTitleText",f?.titleTopMargin||0,i.db.getDiagramTitle()),mt(T,K,"flowchart",f?.useMaxWidth||!1);for(let Y of l.nodes){let k=de(`#${r} [id="${Y.id}"]`);if(!k||!Y.link)continue;let y=h.createElementNS("http://www.w3.org/2000/svg","a");y.setAttributeNS("http://www.w3.org/2000/svg","class",Y.cssClasses),y.setAttributeNS("http://www.w3.org/2000/svg","rel","noopener"),o==="sandbox"?y.setAttributeNS("http://www.w3.org/2000/svg","target","_top"):Y.linkTarget&&y.setAttributeNS("http://www.w3.org/2000/svg","target",Y.linkTarget);let me=k.insert(function(){return y},":first-child"),Ee=k.select(".label-container");Ee&&me.append(function(){return Ee.node()});let xe=k.select(".label");xe&&me.append(function(){return xe.node()})}},"draw"),wt={getClasses:bs,draw:ks};var x1=function(){var e=u(function(be,c,d,p){for(d=d||{},p=be.length;p--;d[be[p]]=c);return d},"o"),r=[1,4],n=[1,3],i=[1,5],o=[1,8,9,10,11,27,34,36,38,44,60,83,84,85,86,87,88,101,104,105,108,110,113,114,115,120,121,122,123],f=[2,2],g=[1,13],S=[1,14],h=[1,15],l=[1,16],T=[1,23],b=[1,25],K=[1,26],Y=[1,27],k=[1,49],y=[1,48],me=[1,29],Ee=[1,30],xe=[1,31],ze=[1,32],He=[1,33],_=[1,44],w=[1,46],V=[1,42],L=[1,47],I=[1,43],v=[1,50],R=[1,45],N=[1,51],P=[1,52],Xe=[1,34],qe=[1,35],Qe=[1,36],Je=[1,37],pe=[1,57],D=[1,8,9,10,11,27,32,34,36,38,44,60,83,84,85,86,87,88,101,104,105,108,110,113,114,115,120,121,122,123],ee=[1,61],te=[1,60],se=[1,62],Fe=[8,9,11,75,77],y1=[1,77],Te=[1,90],Be=[1,95],_e=[1,94],we=[1,91],Ve=[1,87],Le=[1,93],Ie=[1,89],ve=[1,96],Re=[1,92],Ne=[1,97],Pe=[1,88],ye=[8,9,10,11,40,75,77],M=[8,9,10,11,40,46,75,77],z=[8,9,10,11,29,40,44,46,48,50,52,54,56,58,60,63,65,67,68,70,75,77,88,101,104,105,108,110,113,114,115],S1=[8,9,11,44,60,75,77,88,101,104,105,108,110,113,114,115],We=[44,60,88,101,104,105,108,110,113,114,115],D1=[1,123],C1=[1,122],F1=[1,130],T1=[1,144],B1=[1,145],_1=[1,146],w1=[1,147],V1=[1,132],L1=[1,134],I1=[1,138],v1=[1,139],R1=[1,140],N1=[1,141],P1=[1,142],O1=[1,143],M1=[1,148],G1=[1,149],U1=[1,128],W1=[1,129],j1=[1,136],K1=[1,131],Y1=[1,135],z1=[1,133],a1=[8,9,10,11,27,32,34,36,38,44,60,83,84,85,86,87,88,101,104,105,108,110,113,114,115,120,121,122,123],H1=[1,151],X1=[1,153],B=[8,9,11],H=[8,9,10,11,14,44,60,88,104,105,108,110,113,114,115],A=[1,173],G=[1,169],U=[1,170],m=[1,174],E=[1,171],x=[1,172],Oe=[77,115,118],C=[8,9,10,11,12,14,27,29,32,44,60,75,83,84,85,86,87,88,89,104,108,110,113,114,115],q1=[10,105],ge=[31,49,51,53,55,57,62,64,66,67,69,71,115,116,117],re=[1,242],ne=[1,240],ie=[1,244],ae=[1,238],ue=[1,239],oe=[1,241],le=[1,243],ce=[1,245],Me=[1,263],Q1=[8,9,11,105],$=[8,9,10,11,60,83,104,105,108,109,110,111],u1={trace:u(function(){},"trace"),yy:{},symbols_:{error:2,start:3,graphConfig:4,document:5,line:6,statement:7,SEMI:8,NEWLINE:9,SPACE:10,EOF:11,GRAPH:12,NODIR:13,DIR:14,FirstStmtSeparator:15,ending:16,endToken:17,spaceList:18,spaceListNewline:19,vertexStatement:20,separator:21,styleStatement:22,linkStyleStatement:23,classDefStatement:24,classStatement:25,clickStatement:26,subgraph:27,textNoTags:28,SQS:29,text:30,SQE:31,end:32,direction:33,acc_title:34,acc_title_value:35,acc_descr:36,acc_descr_value:37,acc_descr_multiline_value:38,shapeData:39,SHAPE_DATA:40,link:41,node:42,styledVertex:43,AMP:44,vertex:45,STYLE_SEPARATOR:46,idString:47,DOUBLECIRCLESTART:48,DOUBLECIRCLEEND:49,PS:50,PE:51,"(-":52,"-)":53,STADIUMSTART:54,STADIUMEND:55,SUBROUTINESTART:56,SUBROUTINEEND:57,VERTEX_WITH_PROPS_START:58,"NODE_STRING[field]":59,COLON:60,"NODE_STRING[value]":61,PIPE:62,CYLINDERSTART:63,CYLINDEREND:64,DIAMOND_START:65,DIAMOND_STOP:66,TAGEND:67,TRAPSTART:68,TRAPEND:69,INVTRAPSTART:70,INVTRAPEND:71,linkStatement:72,arrowText:73,TESTSTR:74,START_LINK:75,edgeText:76,LINK:77,edgeTextToken:78,STR:79,MD_STR:80,textToken:81,keywords:82,STYLE:83,LINKSTYLE:84,CLASSDEF:85,CLASS:86,CLICK:87,DOWN:88,UP:89,textNoTagsToken:90,stylesOpt:91,"idString[vertex]":92,"idString[class]":93,CALLBACKNAME:94,CALLBACKARGS:95,HREF:96,LINK_TARGET:97,"STR[link]":98,"STR[tooltip]":99,alphaNum:100,DEFAULT:101,numList:102,INTERPOLATE:103,NUM:104,COMMA:105,style:106,styleComponent:107,NODE_STRING:108,UNIT:109,BRKT:110,PCT:111,idStringToken:112,MINUS:113,MULT:114,UNICODE_TEXT:115,TEXT:116,TAGSTART:117,EDGE_TEXT:118,alphaNumToken:119,direction_tb:120,direction_bt:121,direction_rl:122,direction_lr:123,$accept:0,$end:1},terminals_:{2:"error",8:"SEMI",9:"NEWLINE",10:"SPACE",11:"EOF",12:"GRAPH",13:"NODIR",14:"DIR",27:"subgraph",29:"SQS",31:"SQE",32:"end",34:"acc_title",35:"acc_title_value",36:"acc_descr",37:"acc_descr_value",38:"acc_descr_multiline_value",40:"SHAPE_DATA",44:"AMP",46:"STYLE_SEPARATOR",48:"DOUBLECIRCLESTART",49:"DOUBLECIRCLEEND",50:"PS",51:"PE",52:"(-",53:"-)",54:"STADIUMSTART",55:"STADIUMEND",56:"SUBROUTINESTART",57:"SUBROUTINEEND",58:"VERTEX_WITH_PROPS_START",59:"NODE_STRING[field]",60:"COLON",61:"NODE_STRING[value]",62:"PIPE",63:"CYLINDERSTART",64:"CYLINDEREND",65:"DIAMOND_START",66:"DIAMOND_STOP",67:"TAGEND",68:"TRAPSTART",69:"TRAPEND",70:"INVTRAPSTART",71:"INVTRAPEND",74:"TESTSTR",75:"START_LINK",77:"LINK",79:"STR",80:"MD_STR",83:"STYLE",84:"LINKSTYLE",85:"CLASSDEF",86:"CLASS",87:"CLICK",88:"DOWN",89:"UP",92:"idString[vertex]",93:"idString[class]",94:"CALLBACKNAME",95:"CALLBACKARGS",96:"HREF",97:"LINK_TARGET",98:"STR[link]",99:"STR[tooltip]",101:"DEFAULT",103:"INTERPOLATE",104:"NUM",105:"COMMA",108:"NODE_STRING",109:"UNIT",110:"BRKT",111:"PCT",113:"MINUS",114:"MULT",115:"UNICODE_TEXT",116:"TEXT",117:"TAGSTART",118:"EDGE_TEXT",120:"direction_tb",121:"direction_bt",122:"direction_rl",123:"direction_lr"},productions_:[0,[3,2],[5,0],[5,2],[6,1],[6,1],[6,1],[6,1],[6,1],[4,2],[4,2],[4,2],[4,3],[16,2],[16,1],[17,1],[17,1],[17,1],[15,1],[15,1],[15,2],[19,2],[19,2],[19,1],[19,1],[18,2],[18,1],[7,2],[7,2],[7,2],[7,2],[7,2],[7,2],[7,9],[7,6],[7,4],[7,1],[7,2],[7,2],[7,1],[21,1],[21,1],[21,1],[39,2],[39,1],[20,4],[20,3],[20,4],[20,2],[20,2],[20,1],[42,1],[42,6],[42,5],[43,1],[43,3],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,8],[45,4],[45,4],[45,4],[45,6],[45,4],[45,4],[45,4],[45,4],[45,4],[45,1],[41,2],[41,3],[41,3],[41,1],[41,3],[76,1],[76,2],[76,1],[76,1],[72,1],[73,3],[30,1],[30,2],[30,1],[30,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[82,1],[28,1],[28,2],[28,1],[28,1],[24,5],[25,5],[26,2],[26,4],[26,3],[26,5],[26,3],[26,5],[26,5],[26,7],[26,2],[26,4],[26,2],[26,4],[26,4],[26,6],[22,5],[23,5],[23,5],[23,9],[23,9],[23,7],[23,7],[102,1],[102,3],[91,1],[91,3],[106,1],[106,2],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[107,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[112,1],[81,1],[81,1],[81,1],[81,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[90,1],[78,1],[78,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[119,1],[47,1],[47,2],[100,1],[100,2],[33,1],[33,1],[33,1],[33,1]],performAction:u(function(c,d,p,a,F,t,Se){var s=t.length-1;switch(F){case 2:this.$=[];break;case 3:(!Array.isArray(t[s])||t[s].length>0)&&t[s-1].push(t[s]),this.$=t[s-1];break;case 4:case 181:this.$=t[s];break;case 11:a.setDirection("TB"),this.$="TB";break;case 12:a.setDirection(t[s-1]),this.$=t[s-1];break;case 27:this.$=t[s-1].nodes;break;case 28:case 29:case 30:case 31:case 32:this.$=[];break;case 33:this.$=a.addSubGraph(t[s-6],t[s-1],t[s-4]);break;case 34:this.$=a.addSubGraph(t[s-3],t[s-1],t[s-3]);break;case 35:this.$=a.addSubGraph(void 0,t[s-1],void 0);break;case 37:this.$=t[s].trim(),a.setAccTitle(this.$);break;case 38:case 39:this.$=t[s].trim(),a.setAccDescription(this.$);break;case 43:this.$=t[s-1]+t[s];break;case 44:this.$=t[s];break;case 45:a.addVertex(t[s-1][0],void 0,void 0,void 0,void 0,void 0,void 0,t[s]),a.addLink(t[s-3].stmt,t[s-1],t[s-2]),this.$={stmt:t[s-1],nodes:t[s-1].concat(t[s-3].nodes)};break;case 46:a.addLink(t[s-2].stmt,t[s],t[s-1]),this.$={stmt:t[s],nodes:t[s].concat(t[s-2].nodes)};break;case 47:a.addLink(t[s-3].stmt,t[s-1],t[s-2]),this.$={stmt:t[s-1],nodes:t[s-1].concat(t[s-3].nodes)};break;case 48:this.$={stmt:t[s-1],nodes:t[s-1]};break;case 49:a.addVertex(t[s-1][0],void 0,void 0,void 0,void 0,void 0,void 0,t[s]),this.$={stmt:t[s-1],nodes:t[s-1],shapeData:t[s]};break;case 50:this.$={stmt:t[s],nodes:t[s]};break;case 51:this.$=[t[s]];break;case 52:a.addVertex(t[s-5][0],void 0,void 0,void 0,void 0,void 0,void 0,t[s-4]),this.$=t[s-5].concat(t[s]);break;case 53:this.$=t[s-4].concat(t[s]);break;case 54:this.$=t[s];break;case 55:this.$=t[s-2],a.setClass(t[s-2],t[s]);break;case 56:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"square");break;case 57:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"doublecircle");break;case 58:this.$=t[s-5],a.addVertex(t[s-5],t[s-2],"circle");break;case 59:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"ellipse");break;case 60:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"stadium");break;case 61:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"subroutine");break;case 62:this.$=t[s-7],a.addVertex(t[s-7],t[s-1],"rect",void 0,void 0,void 0,Object.fromEntries([[t[s-5],t[s-3]]]));break;case 63:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"cylinder");break;case 64:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"round");break;case 65:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"diamond");break;case 66:this.$=t[s-5],a.addVertex(t[s-5],t[s-2],"hexagon");break;case 67:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"odd");break;case 68:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"trapezoid");break;case 69:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"inv_trapezoid");break;case 70:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"lean_right");break;case 71:this.$=t[s-3],a.addVertex(t[s-3],t[s-1],"lean_left");break;case 72:this.$=t[s],a.addVertex(t[s]);break;case 73:t[s-1].text=t[s],this.$=t[s-1];break;case 74:case 75:t[s-2].text=t[s-1],this.$=t[s-2];break;case 76:this.$=t[s];break;case 77:var q=a.destructLink(t[s],t[s-2]);this.$={type:q.type,stroke:q.stroke,length:q.length,text:t[s-1]};break;case 78:this.$={text:t[s],type:"text"};break;case 79:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 80:this.$={text:t[s],type:"string"};break;case 81:this.$={text:t[s],type:"markdown"};break;case 82:var q=a.destructLink(t[s]);this.$={type:q.type,stroke:q.stroke,length:q.length};break;case 83:this.$=t[s-1];break;case 84:this.$={text:t[s],type:"text"};break;case 85:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 86:this.$={text:t[s],type:"string"};break;case 87:case 102:this.$={text:t[s],type:"markdown"};break;case 99:this.$={text:t[s],type:"text"};break;case 100:this.$={text:t[s-1].text+""+t[s],type:t[s-1].type};break;case 101:this.$={text:t[s],type:"text"};break;case 103:this.$=t[s-4],a.addClass(t[s-2],t[s]);break;case 104:this.$=t[s-4],a.setClass(t[s-2],t[s]);break;case 105:case 113:this.$=t[s-1],a.setClickEvent(t[s-1],t[s]);break;case 106:case 114:this.$=t[s-3],a.setClickEvent(t[s-3],t[s-2]),a.setTooltip(t[s-3],t[s]);break;case 107:this.$=t[s-2],a.setClickEvent(t[s-2],t[s-1],t[s]);break;case 108:this.$=t[s-4],a.setClickEvent(t[s-4],t[s-3],t[s-2]),a.setTooltip(t[s-4],t[s]);break;case 109:this.$=t[s-2],a.setLink(t[s-2],t[s]);break;case 110:this.$=t[s-4],a.setLink(t[s-4],t[s-2]),a.setTooltip(t[s-4],t[s]);break;case 111:this.$=t[s-4],a.setLink(t[s-4],t[s-2],t[s]);break;case 112:this.$=t[s-6],a.setLink(t[s-6],t[s-4],t[s]),a.setTooltip(t[s-6],t[s-2]);break;case 115:this.$=t[s-1],a.setLink(t[s-1],t[s]);break;case 116:this.$=t[s-3],a.setLink(t[s-3],t[s-2]),a.setTooltip(t[s-3],t[s]);break;case 117:this.$=t[s-3],a.setLink(t[s-3],t[s-2],t[s]);break;case 118:this.$=t[s-5],a.setLink(t[s-5],t[s-4],t[s]),a.setTooltip(t[s-5],t[s-2]);break;case 119:this.$=t[s-4],a.addVertex(t[s-2],void 0,void 0,t[s]);break;case 120:this.$=t[s-4],a.updateLink([t[s-2]],t[s]);break;case 121:this.$=t[s-4],a.updateLink(t[s-2],t[s]);break;case 122:this.$=t[s-8],a.updateLinkInterpolate([t[s-6]],t[s-2]),a.updateLink([t[s-6]],t[s]);break;case 123:this.$=t[s-8],a.updateLinkInterpolate(t[s-6],t[s-2]),a.updateLink(t[s-6],t[s]);break;case 124:this.$=t[s-6],a.updateLinkInterpolate([t[s-4]],t[s]);break;case 125:this.$=t[s-6],a.updateLinkInterpolate(t[s-4],t[s]);break;case 126:case 128:this.$=[t[s]];break;case 127:case 129:t[s-2].push(t[s]),this.$=t[s-2];break;case 131:this.$=t[s-1]+t[s];break;case 179:this.$=t[s];break;case 180:this.$=t[s-1]+""+t[s];break;case 182:this.$=t[s-1]+""+t[s];break;case 183:this.$={stmt:"dir",value:"TB"};break;case 184:this.$={stmt:"dir",value:"BT"};break;case 185:this.$={stmt:"dir",value:"RL"};break;case 186:this.$={stmt:"dir",value:"LR"};break}},"anonymous"),table:[{3:1,4:2,9:r,10:n,12:i},{1:[3]},e(o,f,{5:6}),{4:7,9:r,10:n,12:i},{4:8,9:r,10:n,12:i},{13:[1,9],14:[1,10]},{1:[2,1],6:11,7:12,8:g,9:S,10:h,11:l,20:17,22:18,23:19,24:20,25:21,26:22,27:T,33:24,34:b,36:K,38:Y,42:28,43:38,44:k,45:39,47:40,60:y,83:me,84:Ee,85:xe,86:ze,87:He,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P,120:Xe,121:qe,122:Qe,123:Je},e(o,[2,9]),e(o,[2,10]),e(o,[2,11]),{8:[1,54],9:[1,55],10:pe,15:53,18:56},e(D,[2,3]),e(D,[2,4]),e(D,[2,5]),e(D,[2,6]),e(D,[2,7]),e(D,[2,8]),{8:ee,9:te,11:se,21:58,41:59,72:63,75:[1,64],77:[1,65]},{8:ee,9:te,11:se,21:66},{8:ee,9:te,11:se,21:67},{8:ee,9:te,11:se,21:68},{8:ee,9:te,11:se,21:69},{8:ee,9:te,11:se,21:70},{8:ee,9:te,10:[1,71],11:se,21:72},e(D,[2,36]),{35:[1,73]},{37:[1,74]},e(D,[2,39]),e(Fe,[2,50],{18:75,39:76,10:pe,40:y1}),{10:[1,78]},{10:[1,79]},{10:[1,80]},{10:[1,81]},{14:Te,44:Be,60:_e,79:[1,85],88:we,94:[1,82],96:[1,83],100:84,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe,119:86},e(D,[2,183]),e(D,[2,184]),e(D,[2,185]),e(D,[2,186]),e(ye,[2,51]),e(ye,[2,54],{46:[1,98]}),e(M,[2,72],{112:111,29:[1,99],44:k,48:[1,100],50:[1,101],52:[1,102],54:[1,103],56:[1,104],58:[1,105],60:y,63:[1,106],65:[1,107],67:[1,108],68:[1,109],70:[1,110],88:_,101:w,104:V,105:L,108:I,110:v,113:R,114:N,115:P}),e(z,[2,179]),e(z,[2,140]),e(z,[2,141]),e(z,[2,142]),e(z,[2,143]),e(z,[2,144]),e(z,[2,145]),e(z,[2,146]),e(z,[2,147]),e(z,[2,148]),e(z,[2,149]),e(z,[2,150]),e(o,[2,12]),e(o,[2,18]),e(o,[2,19]),{9:[1,112]},e(S1,[2,26],{18:113,10:pe}),e(D,[2,27]),{42:114,43:38,44:k,45:39,47:40,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},e(D,[2,40]),e(D,[2,41]),e(D,[2,42]),e(We,[2,76],{73:115,62:[1,117],74:[1,116]}),{76:118,78:119,79:[1,120],80:[1,121],115:D1,118:C1},e([44,60,62,74,88,101,104,105,108,110,113,114,115],[2,82]),e(D,[2,28]),e(D,[2,29]),e(D,[2,30]),e(D,[2,31]),e(D,[2,32]),{10:F1,12:T1,14:B1,27:_1,28:124,32:w1,44:V1,60:L1,75:I1,79:[1,126],80:[1,127],82:137,83:v1,84:R1,85:N1,86:P1,87:O1,88:M1,89:G1,90:125,104:U1,108:W1,110:j1,113:K1,114:Y1,115:z1},e(a1,f,{5:150}),e(D,[2,37]),e(D,[2,38]),e(Fe,[2,48],{44:H1}),e(Fe,[2,49],{18:152,10:pe,40:X1}),e(ye,[2,44]),{44:k,47:154,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},{101:[1,155],102:156,104:[1,157]},{44:k,47:158,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},{44:k,47:159,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},e(B,[2,105],{10:[1,160],95:[1,161]}),{79:[1,162]},e(B,[2,113],{119:164,10:[1,163],14:Te,44:Be,60:_e,88:we,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe}),e(B,[2,115],{10:[1,165]}),e(H,[2,181]),e(H,[2,168]),e(H,[2,169]),e(H,[2,170]),e(H,[2,171]),e(H,[2,172]),e(H,[2,173]),e(H,[2,174]),e(H,[2,175]),e(H,[2,176]),e(H,[2,177]),e(H,[2,178]),{44:k,47:166,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},{30:167,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:175,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:177,50:[1,176],67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:178,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:179,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:180,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{108:[1,181]},{30:182,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:183,65:[1,184],67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:185,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:186,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{30:187,67:A,79:G,80:U,81:168,115:m,116:E,117:x},e(z,[2,180]),e(o,[2,20]),e(S1,[2,25]),e(Fe,[2,46],{39:188,18:189,10:pe,40:y1}),e(We,[2,73],{10:[1,190]}),{10:[1,191]},{30:192,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{77:[1,193],78:194,115:D1,118:C1},e(Oe,[2,78]),e(Oe,[2,80]),e(Oe,[2,81]),e(Oe,[2,166]),e(Oe,[2,167]),{8:ee,9:te,10:F1,11:se,12:T1,14:B1,21:196,27:_1,29:[1,195],32:w1,44:V1,60:L1,75:I1,82:137,83:v1,84:R1,85:N1,86:P1,87:O1,88:M1,89:G1,90:197,104:U1,108:W1,110:j1,113:K1,114:Y1,115:z1},e(C,[2,99]),e(C,[2,101]),e(C,[2,102]),e(C,[2,155]),e(C,[2,156]),e(C,[2,157]),e(C,[2,158]),e(C,[2,159]),e(C,[2,160]),e(C,[2,161]),e(C,[2,162]),e(C,[2,163]),e(C,[2,164]),e(C,[2,165]),e(C,[2,88]),e(C,[2,89]),e(C,[2,90]),e(C,[2,91]),e(C,[2,92]),e(C,[2,93]),e(C,[2,94]),e(C,[2,95]),e(C,[2,96]),e(C,[2,97]),e(C,[2,98]),{6:11,7:12,8:g,9:S,10:h,11:l,20:17,22:18,23:19,24:20,25:21,26:22,27:T,32:[1,198],33:24,34:b,36:K,38:Y,42:28,43:38,44:k,45:39,47:40,60:y,83:me,84:Ee,85:xe,86:ze,87:He,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P,120:Xe,121:qe,122:Qe,123:Je},{10:pe,18:199},{44:[1,200]},e(ye,[2,43]),{10:[1,201],44:k,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:111,113:R,114:N,115:P},{10:[1,202]},{10:[1,203],105:[1,204]},e(q1,[2,126]),{10:[1,205],44:k,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:111,113:R,114:N,115:P},{10:[1,206],44:k,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:111,113:R,114:N,115:P},{79:[1,207]},e(B,[2,107],{10:[1,208]}),e(B,[2,109],{10:[1,209]}),{79:[1,210]},e(H,[2,182]),{79:[1,211],97:[1,212]},e(ye,[2,55],{112:111,44:k,60:y,88:_,101:w,104:V,105:L,108:I,110:v,113:R,114:N,115:P}),{31:[1,213],67:A,81:214,115:m,116:E,117:x},e(ge,[2,84]),e(ge,[2,86]),e(ge,[2,87]),e(ge,[2,151]),e(ge,[2,152]),e(ge,[2,153]),e(ge,[2,154]),{49:[1,215],67:A,81:214,115:m,116:E,117:x},{30:216,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{51:[1,217],67:A,81:214,115:m,116:E,117:x},{53:[1,218],67:A,81:214,115:m,116:E,117:x},{55:[1,219],67:A,81:214,115:m,116:E,117:x},{57:[1,220],67:A,81:214,115:m,116:E,117:x},{60:[1,221]},{64:[1,222],67:A,81:214,115:m,116:E,117:x},{66:[1,223],67:A,81:214,115:m,116:E,117:x},{30:224,67:A,79:G,80:U,81:168,115:m,116:E,117:x},{31:[1,225],67:A,81:214,115:m,116:E,117:x},{67:A,69:[1,226],71:[1,227],81:214,115:m,116:E,117:x},{67:A,69:[1,229],71:[1,228],81:214,115:m,116:E,117:x},e(Fe,[2,45],{18:152,10:pe,40:X1}),e(Fe,[2,47],{44:H1}),e(We,[2,75]),e(We,[2,74]),{62:[1,230],67:A,81:214,115:m,116:E,117:x},e(We,[2,77]),e(Oe,[2,79]),{30:231,67:A,79:G,80:U,81:168,115:m,116:E,117:x},e(a1,f,{5:232}),e(C,[2,100]),e(D,[2,35]),{43:233,44:k,45:39,47:40,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},{10:pe,18:234},{10:re,60:ne,83:ie,91:235,104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},{10:re,60:ne,83:ie,91:246,103:[1,247],104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},{10:re,60:ne,83:ie,91:248,103:[1,249],104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},{104:[1,250]},{10:re,60:ne,83:ie,91:251,104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},{44:k,47:252,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},e(B,[2,106]),{79:[1,253]},{79:[1,254],97:[1,255]},e(B,[2,114]),e(B,[2,116],{10:[1,256]}),e(B,[2,117]),e(M,[2,56]),e(ge,[2,85]),e(M,[2,57]),{51:[1,257],67:A,81:214,115:m,116:E,117:x},e(M,[2,64]),e(M,[2,59]),e(M,[2,60]),e(M,[2,61]),{108:[1,258]},e(M,[2,63]),e(M,[2,65]),{66:[1,259],67:A,81:214,115:m,116:E,117:x},e(M,[2,67]),e(M,[2,68]),e(M,[2,70]),e(M,[2,69]),e(M,[2,71]),e([10,44,60,88,101,104,105,108,110,113,114,115],[2,83]),{31:[1,260],67:A,81:214,115:m,116:E,117:x},{6:11,7:12,8:g,9:S,10:h,11:l,20:17,22:18,23:19,24:20,25:21,26:22,27:T,32:[1,261],33:24,34:b,36:K,38:Y,42:28,43:38,44:k,45:39,47:40,60:y,83:me,84:Ee,85:xe,86:ze,87:He,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P,120:Xe,121:qe,122:Qe,123:Je},e(ye,[2,53]),{43:262,44:k,45:39,47:40,60:y,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P},e(B,[2,119],{105:Me}),e(Q1,[2,128],{107:264,10:re,60:ne,83:ie,104:ae,108:ue,109:oe,110:le,111:ce}),e($,[2,130]),e($,[2,132]),e($,[2,133]),e($,[2,134]),e($,[2,135]),e($,[2,136]),e($,[2,137]),e($,[2,138]),e($,[2,139]),e(B,[2,120],{105:Me}),{10:[1,265]},e(B,[2,121],{105:Me}),{10:[1,266]},e(q1,[2,127]),e(B,[2,103],{105:Me}),e(B,[2,104],{112:111,44:k,60:y,88:_,101:w,104:V,105:L,108:I,110:v,113:R,114:N,115:P}),e(B,[2,108]),e(B,[2,110],{10:[1,267]}),e(B,[2,111]),{97:[1,268]},{51:[1,269]},{62:[1,270]},{66:[1,271]},{8:ee,9:te,11:se,21:272},e(D,[2,34]),e(ye,[2,52]),{10:re,60:ne,83:ie,104:ae,106:273,107:237,108:ue,109:oe,110:le,111:ce},e($,[2,131]),{14:Te,44:Be,60:_e,88:we,100:274,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe,119:86},{14:Te,44:Be,60:_e,88:we,100:275,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe,119:86},{97:[1,276]},e(B,[2,118]),e(M,[2,58]),{30:277,67:A,79:G,80:U,81:168,115:m,116:E,117:x},e(M,[2,66]),e(a1,f,{5:278}),e(Q1,[2,129],{107:264,10:re,60:ne,83:ie,104:ae,108:ue,109:oe,110:le,111:ce}),e(B,[2,124],{119:164,10:[1,279],14:Te,44:Be,60:_e,88:we,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe}),e(B,[2,125],{119:164,10:[1,280],14:Te,44:Be,60:_e,88:we,104:Ve,105:Le,108:Ie,110:ve,113:Re,114:Ne,115:Pe}),e(B,[2,112]),{31:[1,281],67:A,81:214,115:m,116:E,117:x},{6:11,7:12,8:g,9:S,10:h,11:l,20:17,22:18,23:19,24:20,25:21,26:22,27:T,32:[1,282],33:24,34:b,36:K,38:Y,42:28,43:38,44:k,45:39,47:40,60:y,83:me,84:Ee,85:xe,86:ze,87:He,88:_,101:w,104:V,105:L,108:I,110:v,112:41,113:R,114:N,115:P,120:Xe,121:qe,122:Qe,123:Je},{10:re,60:ne,83:ie,91:283,104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},{10:re,60:ne,83:ie,91:284,104:ae,106:236,107:237,108:ue,109:oe,110:le,111:ce},e(M,[2,62]),e(D,[2,33]),e(B,[2,122],{105:Me}),e(B,[2,123],{105:Me})],defaultActions:{},parseError:u(function(c,d){if(d.recoverable)this.trace(c);else{var p=new Error(c);throw p.hash=d,p}},"parseError"),parse:u(function(c){var d=this,p=[0],a=[],F=[null],t=[],Se=this.table,s="",q=0,J1=0,Z1=0,vt=2,$1=1,Rt=t.slice.call(arguments,1),O=Object.create(this.lexer),De={yy:{}};for(var l1 in this.yy)Object.prototype.hasOwnProperty.call(this.yy,l1)&&(De.yy[l1]=this.yy[l1]);O.setInput(c,De.yy),De.yy.lexer=O,De.yy.parser=this,typeof O.yylloc>"u"&&(O.yylloc={});var c1=O.yylloc;t.push(c1);var Nt=O.options&&O.options.ranges;typeof De.yy.parseError=="function"?this.parseError=De.yy.parseError:this.parseError=Object.getPrototypeOf(this).parseError;function Es(X){p.length=p.length-2*X,F.length=F.length-X,t.length=t.length-X}u(Es,"popStack");function Pt(){var X;return X=a.pop()||O.lex()||$1,typeof X!="number"&&(X instanceof Array&&(a=X,X=a.pop()),X=d.symbols_[X]||X),X}u(Pt,"lex");for(var W,h1,Ce,Q,xs,d1,Ge={},Ze,he,et,$e;;){if(Ce=p[p.length-1],this.defaultActions[Ce]?Q=this.defaultActions[Ce]:((W===null||typeof W>"u")&&(W=Pt()),Q=Se[Ce]&&Se[Ce][W]),typeof Q>"u"||!Q.length||!Q[0]){var f1="";$e=[];for(Ze in Se[Ce])this.terminals_[Ze]&&Ze>vt&&$e.push("'"+this.terminals_[Ze]+"'");O.showPosition?f1="Parse error on line "+(q+1)+`: +`+O.showPosition()+` +Expecting `+$e.join(", ")+", got '"+(this.terminals_[W]||W)+"'":f1="Parse error on line "+(q+1)+": Unexpected "+(W==$1?"end of input":"'"+(this.terminals_[W]||W)+"'"),this.parseError(f1,{text:O.match,token:this.terminals_[W]||W,line:O.yylineno,loc:c1,expected:$e})}if(Q[0]instanceof Array&&Q.length>1)throw new Error("Parse Error: multiple actions possible at state: "+Ce+", token: "+W);switch(Q[0]){case 1:p.push(W),F.push(O.yytext),t.push(O.yylloc),p.push(Q[1]),W=null,h1?(W=h1,h1=null):(J1=O.yyleng,s=O.yytext,q=O.yylineno,c1=O.yylloc,Z1>0&&Z1--);break;case 2:if(he=this.productions_[Q[1]][1],Ge.$=F[F.length-he],Ge._$={first_line:t[t.length-(he||1)].first_line,last_line:t[t.length-1].last_line,first_column:t[t.length-(he||1)].first_column,last_column:t[t.length-1].last_column},Nt&&(Ge._$.range=[t[t.length-(he||1)].range[0],t[t.length-1].range[1]]),d1=this.performAction.apply(Ge,[s,J1,q,De.yy,Q[1],F,t].concat(Rt)),typeof d1<"u")return d1;he&&(p=p.slice(0,-1*he*2),F=F.slice(0,-1*he),t=t.slice(0,-1*he)),p.push(this.productions_[Q[1]][0]),F.push(Ge.$),t.push(Ge._$),et=Se[p[p.length-2]][p[p.length-1]],p.push(et);break;case 3:return!0}}return!0},"parse")},It=function(){var be={EOF:1,parseError:u(function(d,p){if(this.yy.parser)this.yy.parser.parseError(d,p);else throw new Error(d)},"parseError"),setInput:u(function(c,d){return this.yy=d||this.yy||{},this._input=c,this._more=this._backtrack=this.done=!1,this.yylineno=this.yyleng=0,this.yytext=this.matched=this.match="",this.conditionStack=["INITIAL"],this.yylloc={first_line:1,first_column:0,last_line:1,last_column:0},this.options.ranges&&(this.yylloc.range=[0,0]),this.offset=0,this},"setInput"),input:u(function(){var c=this._input[0];this.yytext+=c,this.yyleng++,this.offset++,this.match+=c,this.matched+=c;var d=c.match(/(?:\r\n?|\n).*/g);return d?(this.yylineno++,this.yylloc.last_line++):this.yylloc.last_column++,this.options.ranges&&this.yylloc.range[1]++,this._input=this._input.slice(1),c},"input"),unput:u(function(c){var d=c.length,p=c.split(/(?:\r\n?|\n)/g);this._input=c+this._input,this.yytext=this.yytext.substr(0,this.yytext.length-d),this.offset-=d;var a=this.match.split(/(?:\r\n?|\n)/g);this.match=this.match.substr(0,this.match.length-1),this.matched=this.matched.substr(0,this.matched.length-1),p.length-1&&(this.yylineno-=p.length-1);var F=this.yylloc.range;return this.yylloc={first_line:this.yylloc.first_line,last_line:this.yylineno+1,first_column:this.yylloc.first_column,last_column:p?(p.length===a.length?this.yylloc.first_column:0)+a[a.length-p.length].length-p[0].length:this.yylloc.first_column-d},this.options.ranges&&(this.yylloc.range=[F[0],F[0]+this.yyleng-d]),this.yyleng=this.yytext.length,this},"unput"),more:u(function(){return this._more=!0,this},"more"),reject:u(function(){if(this.options.backtrack_lexer)this._backtrack=!0;else return this.parseError("Lexical error on line "+(this.yylineno+1)+`. You can only invoke reject() in the lexer when the lexer is of the backtracking persuasion (options.backtrack_lexer = true). +`+this.showPosition(),{text:"",token:null,line:this.yylineno});return this},"reject"),less:u(function(c){this.unput(this.match.slice(c))},"less"),pastInput:u(function(){var c=this.matched.substr(0,this.matched.length-this.match.length);return(c.length>20?"...":"")+c.substr(-20).replace(/\n/g,"")},"pastInput"),upcomingInput:u(function(){var c=this.match;return c.length<20&&(c+=this._input.substr(0,20-c.length)),(c.substr(0,20)+(c.length>20?"...":"")).replace(/\n/g,"")},"upcomingInput"),showPosition:u(function(){var c=this.pastInput(),d=new Array(c.length+1).join("-");return c+this.upcomingInput()+` +`+d+"^"},"showPosition"),test_match:u(function(c,d){var p,a,F;if(this.options.backtrack_lexer&&(F={yylineno:this.yylineno,yylloc:{first_line:this.yylloc.first_line,last_line:this.last_line,first_column:this.yylloc.first_column,last_column:this.yylloc.last_column},yytext:this.yytext,match:this.match,matches:this.matches,matched:this.matched,yyleng:this.yyleng,offset:this.offset,_more:this._more,_input:this._input,yy:this.yy,conditionStack:this.conditionStack.slice(0),done:this.done},this.options.ranges&&(F.yylloc.range=this.yylloc.range.slice(0))),a=c[0].match(/(?:\r\n?|\n).*/g),a&&(this.yylineno+=a.length),this.yylloc={first_line:this.yylloc.last_line,last_line:this.yylineno+1,first_column:this.yylloc.last_column,last_column:a?a[a.length-1].length-a[a.length-1].match(/\r?\n?/)[0].length:this.yylloc.last_column+c[0].length},this.yytext+=c[0],this.match+=c[0],this.matches=c,this.yyleng=this.yytext.length,this.options.ranges&&(this.yylloc.range=[this.offset,this.offset+=this.yyleng]),this._more=!1,this._backtrack=!1,this._input=this._input.slice(c[0].length),this.matched+=c[0],p=this.performAction.call(this,this.yy,this,d,this.conditionStack[this.conditionStack.length-1]),this.done&&this._input&&(this.done=!1),p)return p;if(this._backtrack){for(var t in F)this[t]=F[t];return!1}return!1},"test_match"),next:u(function(){if(this.done)return this.EOF;this._input||(this.done=!0);var c,d,p,a;this._more||(this.yytext="",this.match="");for(var F=this._currentRules(),t=0;td[0].length)){if(d=p,a=t,this.options.backtrack_lexer){if(c=this.test_match(p,F[t]),c!==!1)return c;if(this._backtrack){d=!1;continue}else return!1}else if(!this.options.flex)break}return d?(c=this.test_match(d,F[a]),c!==!1?c:!1):this._input===""?this.EOF:this.parseError("Lexical error on line "+(this.yylineno+1)+`. Unrecognized text. +`+this.showPosition(),{text:"",token:null,line:this.yylineno})},"next"),lex:u(function(){var d=this.next();return d||this.lex()},"lex"),begin:u(function(d){this.conditionStack.push(d)},"begin"),popState:u(function(){var d=this.conditionStack.length-1;return d>0?this.conditionStack.pop():this.conditionStack[0]},"popState"),_currentRules:u(function(){return this.conditionStack.length&&this.conditionStack[this.conditionStack.length-1]?this.conditions[this.conditionStack[this.conditionStack.length-1]].rules:this.conditions.INITIAL.rules},"_currentRules"),topState:u(function(d){return d=this.conditionStack.length-1-Math.abs(d||0),d>=0?this.conditionStack[d]:"INITIAL"},"topState"),pushState:u(function(d){this.begin(d)},"pushState"),stateStackSize:u(function(){return this.conditionStack.length},"stateStackSize"),options:{},performAction:u(function(d,p,a,F){var t=F;switch(a){case 0:return this.begin("acc_title"),34;break;case 1:return this.popState(),"acc_title_value";break;case 2:return this.begin("acc_descr"),36;break;case 3:return this.popState(),"acc_descr_value";break;case 4:this.begin("acc_descr_multiline");break;case 5:this.popState();break;case 6:return"acc_descr_multiline_value";case 7:return this.pushState("shapeData"),p.yytext="",40;break;case 8:return this.pushState("shapeDataStr"),40;break;case 9:return this.popState(),40;break;case 10:let Se=/\n\s*/g;return p.yytext=p.yytext.replace(Se,"
    "),40;break;case 11:return 40;case 12:this.popState();break;case 13:this.begin("callbackname");break;case 14:this.popState();break;case 15:this.popState(),this.begin("callbackargs");break;case 16:return 94;case 17:this.popState();break;case 18:return 95;case 19:return"MD_STR";case 20:this.popState();break;case 21:this.begin("md_string");break;case 22:return"STR";case 23:this.popState();break;case 24:this.pushState("string");break;case 25:return 83;case 26:return 101;case 27:return 84;case 28:return 103;case 29:return 85;case 30:return 86;case 31:return 96;case 32:this.begin("click");break;case 33:this.popState();break;case 34:return 87;case 35:return d.lex.firstGraph()&&this.begin("dir"),12;break;case 36:return d.lex.firstGraph()&&this.begin("dir"),12;break;case 37:return d.lex.firstGraph()&&this.begin("dir"),12;break;case 38:return 27;case 39:return 32;case 40:return 97;case 41:return 97;case 42:return 97;case 43:return 97;case 44:return this.popState(),13;break;case 45:return this.popState(),14;break;case 46:return this.popState(),14;break;case 47:return this.popState(),14;break;case 48:return this.popState(),14;break;case 49:return this.popState(),14;break;case 50:return this.popState(),14;break;case 51:return this.popState(),14;break;case 52:return this.popState(),14;break;case 53:return this.popState(),14;break;case 54:return this.popState(),14;break;case 55:return 120;case 56:return 121;case 57:return 122;case 58:return 123;case 59:return 104;case 60:return 110;case 61:return 46;case 62:return 60;case 63:return 44;case 64:return 8;case 65:return 105;case 66:return 114;case 67:return this.popState(),77;break;case 68:return this.pushState("edgeText"),75;break;case 69:return 118;case 70:return this.popState(),77;break;case 71:return this.pushState("thickEdgeText"),75;break;case 72:return 118;case 73:return this.popState(),77;break;case 74:return this.pushState("dottedEdgeText"),75;break;case 75:return 118;case 76:return 77;case 77:return this.popState(),53;break;case 78:return"TEXT";case 79:return this.pushState("ellipseText"),52;break;case 80:return this.popState(),55;break;case 81:return this.pushState("text"),54;break;case 82:return this.popState(),57;break;case 83:return this.pushState("text"),56;break;case 84:return 58;case 85:return this.pushState("text"),67;break;case 86:return this.popState(),64;break;case 87:return this.pushState("text"),63;break;case 88:return this.popState(),49;break;case 89:return this.pushState("text"),48;break;case 90:return this.popState(),69;break;case 91:return this.popState(),71;break;case 92:return 116;case 93:return this.pushState("trapText"),68;break;case 94:return this.pushState("trapText"),70;break;case 95:return 117;case 96:return 67;case 97:return 89;case 98:return"SEP";case 99:return 88;case 100:return 114;case 101:return 110;case 102:return 44;case 103:return 108;case 104:return 113;case 105:return 115;case 106:return this.popState(),62;break;case 107:return this.pushState("text"),62;break;case 108:return this.popState(),51;break;case 109:return this.pushState("text"),50;break;case 110:return this.popState(),31;break;case 111:return this.pushState("text"),29;break;case 112:return this.popState(),66;break;case 113:return this.pushState("text"),65;break;case 114:return"TEXT";case 115:return"QUOTE";case 116:return 9;case 117:return 10;case 118:return 11}},"anonymous"),rules:[/^(?:accTitle\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*:\s*)/,/^(?:(?!\n||)*[^\n]*)/,/^(?:accDescr\s*\{\s*)/,/^(?:[\}])/,/^(?:[^\}]*)/,/^(?:@\{)/,/^(?:["])/,/^(?:["])/,/^(?:[^\"]+)/,/^(?:[^}^"]+)/,/^(?:\})/,/^(?:call[\s]+)/,/^(?:\([\s]*\))/,/^(?:\()/,/^(?:[^(]*)/,/^(?:\))/,/^(?:[^)]*)/,/^(?:[^`"]+)/,/^(?:[`]["])/,/^(?:["][`])/,/^(?:[^"]+)/,/^(?:["])/,/^(?:["])/,/^(?:style\b)/,/^(?:default\b)/,/^(?:linkStyle\b)/,/^(?:interpolate\b)/,/^(?:classDef\b)/,/^(?:class\b)/,/^(?:href[\s])/,/^(?:click[\s]+)/,/^(?:[\s\n])/,/^(?:[^\s\n]*)/,/^(?:flowchart-elk\b)/,/^(?:graph\b)/,/^(?:flowchart\b)/,/^(?:subgraph\b)/,/^(?:end\b\s*)/,/^(?:_self\b)/,/^(?:_blank\b)/,/^(?:_parent\b)/,/^(?:_top\b)/,/^(?:(\r?\n)*\s*\n)/,/^(?:\s*LR\b)/,/^(?:\s*RL\b)/,/^(?:\s*TB\b)/,/^(?:\s*BT\b)/,/^(?:\s*TD\b)/,/^(?:\s*BR\b)/,/^(?:\s*<)/,/^(?:\s*>)/,/^(?:\s*\^)/,/^(?:\s*v\b)/,/^(?:.*direction\s+TB[^\n]*)/,/^(?:.*direction\s+BT[^\n]*)/,/^(?:.*direction\s+RL[^\n]*)/,/^(?:.*direction\s+LR[^\n]*)/,/^(?:[0-9]+)/,/^(?:#)/,/^(?::::)/,/^(?::)/,/^(?:&)/,/^(?:;)/,/^(?:,)/,/^(?:\*)/,/^(?:\s*[xo<]?--+[-xo>]\s*)/,/^(?:\s*[xo<]?--\s*)/,/^(?:[^-]|-(?!-)+)/,/^(?:\s*[xo<]?==+[=xo>]\s*)/,/^(?:\s*[xo<]?==\s*)/,/^(?:[^=]|=(?!))/,/^(?:\s*[xo<]?-?\.+-[xo>]?\s*)/,/^(?:\s*[xo<]?-\.\s*)/,/^(?:[^\.]|\.(?!))/,/^(?:\s*~~[\~]+\s*)/,/^(?:[-/\)][\)])/,/^(?:[^\(\)\[\]\{\}]|!\)+)/,/^(?:\(-)/,/^(?:\]\))/,/^(?:\(\[)/,/^(?:\]\])/,/^(?:\[\[)/,/^(?:\[\|)/,/^(?:>)/,/^(?:\)\])/,/^(?:\[\()/,/^(?:\)\)\))/,/^(?:\(\(\()/,/^(?:[\\(?=\])][\]])/,/^(?:\/(?=\])\])/,/^(?:\/(?!\])|\\(?!\])|[^\\\[\]\(\)\{\}\/]+)/,/^(?:\[\/)/,/^(?:\[\\)/,/^(?:<)/,/^(?:>)/,/^(?:\^)/,/^(?:\\\|)/,/^(?:v\b)/,/^(?:\*)/,/^(?:#)/,/^(?:&)/,/^(?:([A-Za-z0-9!"\#$%&'*+\.`?\\_\/]|-(?=[^\>\-\.])|(?!))+)/,/^(?:-)/,/^(?:[\u00AA\u00B5\u00BA\u00C0-\u00D6\u00D8-\u00F6]|[\u00F8-\u02C1\u02C6-\u02D1\u02E0-\u02E4\u02EC\u02EE\u0370-\u0374\u0376\u0377]|[\u037A-\u037D\u0386\u0388-\u038A\u038C\u038E-\u03A1\u03A3-\u03F5]|[\u03F7-\u0481\u048A-\u0527\u0531-\u0556\u0559\u0561-\u0587\u05D0-\u05EA]|[\u05F0-\u05F2\u0620-\u064A\u066E\u066F\u0671-\u06D3\u06D5\u06E5\u06E6\u06EE]|[\u06EF\u06FA-\u06FC\u06FF\u0710\u0712-\u072F\u074D-\u07A5\u07B1\u07CA-\u07EA]|[\u07F4\u07F5\u07FA\u0800-\u0815\u081A\u0824\u0828\u0840-\u0858\u08A0]|[\u08A2-\u08AC\u0904-\u0939\u093D\u0950\u0958-\u0961\u0971-\u0977]|[\u0979-\u097F\u0985-\u098C\u098F\u0990\u0993-\u09A8\u09AA-\u09B0\u09B2]|[\u09B6-\u09B9\u09BD\u09CE\u09DC\u09DD\u09DF-\u09E1\u09F0\u09F1\u0A05-\u0A0A]|[\u0A0F\u0A10\u0A13-\u0A28\u0A2A-\u0A30\u0A32\u0A33\u0A35\u0A36\u0A38\u0A39]|[\u0A59-\u0A5C\u0A5E\u0A72-\u0A74\u0A85-\u0A8D\u0A8F-\u0A91\u0A93-\u0AA8]|[\u0AAA-\u0AB0\u0AB2\u0AB3\u0AB5-\u0AB9\u0ABD\u0AD0\u0AE0\u0AE1\u0B05-\u0B0C]|[\u0B0F\u0B10\u0B13-\u0B28\u0B2A-\u0B30\u0B32\u0B33\u0B35-\u0B39\u0B3D\u0B5C]|[\u0B5D\u0B5F-\u0B61\u0B71\u0B83\u0B85-\u0B8A\u0B8E-\u0B90\u0B92-\u0B95\u0B99]|[\u0B9A\u0B9C\u0B9E\u0B9F\u0BA3\u0BA4\u0BA8-\u0BAA\u0BAE-\u0BB9\u0BD0]|[\u0C05-\u0C0C\u0C0E-\u0C10\u0C12-\u0C28\u0C2A-\u0C33\u0C35-\u0C39\u0C3D]|[\u0C58\u0C59\u0C60\u0C61\u0C85-\u0C8C\u0C8E-\u0C90\u0C92-\u0CA8\u0CAA-\u0CB3]|[\u0CB5-\u0CB9\u0CBD\u0CDE\u0CE0\u0CE1\u0CF1\u0CF2\u0D05-\u0D0C\u0D0E-\u0D10]|[\u0D12-\u0D3A\u0D3D\u0D4E\u0D60\u0D61\u0D7A-\u0D7F\u0D85-\u0D96\u0D9A-\u0DB1]|[\u0DB3-\u0DBB\u0DBD\u0DC0-\u0DC6\u0E01-\u0E30\u0E32\u0E33\u0E40-\u0E46\u0E81]|[\u0E82\u0E84\u0E87\u0E88\u0E8A\u0E8D\u0E94-\u0E97\u0E99-\u0E9F\u0EA1-\u0EA3]|[\u0EA5\u0EA7\u0EAA\u0EAB\u0EAD-\u0EB0\u0EB2\u0EB3\u0EBD\u0EC0-\u0EC4\u0EC6]|[\u0EDC-\u0EDF\u0F00\u0F40-\u0F47\u0F49-\u0F6C\u0F88-\u0F8C\u1000-\u102A]|[\u103F\u1050-\u1055\u105A-\u105D\u1061\u1065\u1066\u106E-\u1070\u1075-\u1081]|[\u108E\u10A0-\u10C5\u10C7\u10CD\u10D0-\u10FA\u10FC-\u1248\u124A-\u124D]|[\u1250-\u1256\u1258\u125A-\u125D\u1260-\u1288\u128A-\u128D\u1290-\u12B0]|[\u12B2-\u12B5\u12B8-\u12BE\u12C0\u12C2-\u12C5\u12C8-\u12D6\u12D8-\u1310]|[\u1312-\u1315\u1318-\u135A\u1380-\u138F\u13A0-\u13F4\u1401-\u166C]|[\u166F-\u167F\u1681-\u169A\u16A0-\u16EA\u1700-\u170C\u170E-\u1711]|[\u1720-\u1731\u1740-\u1751\u1760-\u176C\u176E-\u1770\u1780-\u17B3\u17D7]|[\u17DC\u1820-\u1877\u1880-\u18A8\u18AA\u18B0-\u18F5\u1900-\u191C]|[\u1950-\u196D\u1970-\u1974\u1980-\u19AB\u19C1-\u19C7\u1A00-\u1A16]|[\u1A20-\u1A54\u1AA7\u1B05-\u1B33\u1B45-\u1B4B\u1B83-\u1BA0\u1BAE\u1BAF]|[\u1BBA-\u1BE5\u1C00-\u1C23\u1C4D-\u1C4F\u1C5A-\u1C7D\u1CE9-\u1CEC]|[\u1CEE-\u1CF1\u1CF5\u1CF6\u1D00-\u1DBF\u1E00-\u1F15\u1F18-\u1F1D]|[\u1F20-\u1F45\u1F48-\u1F4D\u1F50-\u1F57\u1F59\u1F5B\u1F5D\u1F5F-\u1F7D]|[\u1F80-\u1FB4\u1FB6-\u1FBC\u1FBE\u1FC2-\u1FC4\u1FC6-\u1FCC\u1FD0-\u1FD3]|[\u1FD6-\u1FDB\u1FE0-\u1FEC\u1FF2-\u1FF4\u1FF6-\u1FFC\u2071\u207F]|[\u2090-\u209C\u2102\u2107\u210A-\u2113\u2115\u2119-\u211D\u2124\u2126\u2128]|[\u212A-\u212D\u212F-\u2139\u213C-\u213F\u2145-\u2149\u214E\u2183\u2184]|[\u2C00-\u2C2E\u2C30-\u2C5E\u2C60-\u2CE4\u2CEB-\u2CEE\u2CF2\u2CF3]|[\u2D00-\u2D25\u2D27\u2D2D\u2D30-\u2D67\u2D6F\u2D80-\u2D96\u2DA0-\u2DA6]|[\u2DA8-\u2DAE\u2DB0-\u2DB6\u2DB8-\u2DBE\u2DC0-\u2DC6\u2DC8-\u2DCE]|[\u2DD0-\u2DD6\u2DD8-\u2DDE\u2E2F\u3005\u3006\u3031-\u3035\u303B\u303C]|[\u3041-\u3096\u309D-\u309F\u30A1-\u30FA\u30FC-\u30FF\u3105-\u312D]|[\u3131-\u318E\u31A0-\u31BA\u31F0-\u31FF\u3400-\u4DB5\u4E00-\u9FCC]|[\uA000-\uA48C\uA4D0-\uA4FD\uA500-\uA60C\uA610-\uA61F\uA62A\uA62B]|[\uA640-\uA66E\uA67F-\uA697\uA6A0-\uA6E5\uA717-\uA71F\uA722-\uA788]|[\uA78B-\uA78E\uA790-\uA793\uA7A0-\uA7AA\uA7F8-\uA801\uA803-\uA805]|[\uA807-\uA80A\uA80C-\uA822\uA840-\uA873\uA882-\uA8B3\uA8F2-\uA8F7\uA8FB]|[\uA90A-\uA925\uA930-\uA946\uA960-\uA97C\uA984-\uA9B2\uA9CF\uAA00-\uAA28]|[\uAA40-\uAA42\uAA44-\uAA4B\uAA60-\uAA76\uAA7A\uAA80-\uAAAF\uAAB1\uAAB5]|[\uAAB6\uAAB9-\uAABD\uAAC0\uAAC2\uAADB-\uAADD\uAAE0-\uAAEA\uAAF2-\uAAF4]|[\uAB01-\uAB06\uAB09-\uAB0E\uAB11-\uAB16\uAB20-\uAB26\uAB28-\uAB2E]|[\uABC0-\uABE2\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D]|[\uFA70-\uFAD9\uFB00-\uFB06\uFB13-\uFB17\uFB1D\uFB1F-\uFB28\uFB2A-\uFB36]|[\uFB38-\uFB3C\uFB3E\uFB40\uFB41\uFB43\uFB44\uFB46-\uFBB1\uFBD3-\uFD3D]|[\uFD50-\uFD8F\uFD92-\uFDC7\uFDF0-\uFDFB\uFE70-\uFE74\uFE76-\uFEFC]|[\uFF21-\uFF3A\uFF41-\uFF5A\uFF66-\uFFBE\uFFC2-\uFFC7\uFFCA-\uFFCF]|[\uFFD2-\uFFD7\uFFDA-\uFFDC])/,/^(?:\|)/,/^(?:\|)/,/^(?:\))/,/^(?:\()/,/^(?:\])/,/^(?:\[)/,/^(?:(\}))/,/^(?:\{)/,/^(?:[^\[\]\(\)\{\}\|\"]+)/,/^(?:")/,/^(?:(\r?\n)+)/,/^(?:\s)/,/^(?:$)/],conditions:{shapeDataEndBracket:{rules:[21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},shapeDataStr:{rules:[9,10,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},shapeData:{rules:[8,11,12,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},callbackargs:{rules:[17,18,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},callbackname:{rules:[14,15,16,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},href:{rules:[21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},click:{rules:[21,24,33,34,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},dottedEdgeText:{rules:[21,24,73,75,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},thickEdgeText:{rules:[21,24,70,72,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},edgeText:{rules:[21,24,67,69,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},trapText:{rules:[21,24,76,79,81,83,87,89,90,91,92,93,94,107,109,111,113],inclusive:!1},ellipseText:{rules:[21,24,76,77,78,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},text:{rules:[21,24,76,79,80,81,82,83,86,87,88,89,93,94,106,107,108,109,110,111,112,113,114],inclusive:!1},vertex:{rules:[21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},dir:{rules:[21,24,44,45,46,47,48,49,50,51,52,53,54,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},acc_descr_multiline:{rules:[5,6,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},acc_descr:{rules:[3,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},acc_title:{rules:[1,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},md_string:{rules:[19,20,21,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},string:{rules:[21,22,23,24,76,79,81,83,87,89,93,94,107,109,111,113],inclusive:!1},INITIAL:{rules:[0,2,4,7,13,21,24,25,26,27,28,29,30,31,32,35,36,37,38,39,40,41,42,43,55,56,57,58,59,60,61,62,63,64,65,66,67,68,70,71,73,74,76,79,81,83,84,85,87,89,93,94,95,96,97,98,99,100,101,102,103,104,105,107,109,111,113,115,116,117,118],inclusive:!0}}};return be}();u1.lexer=It;function o1(){this.yy={}}return u(o1,"Parser"),o1.prototype=u1,u1.Parser=o1,new o1}();x1.parser=x1;var Vt=x1;var As=u((e,r)=>{let n=st,i=n(e,"r"),o=n(e,"g"),f=n(e,"b");return tt(i,o,f,r)},"fade"),ms=u(e=>`.label { + font-family: ${e.fontFamily}; + color: ${e.nodeTextColor||e.textColor}; + } + .cluster-label text { + fill: ${e.titleColor}; + } + .cluster-label span { + color: ${e.titleColor}; + } + .cluster-label span p { + background-color: transparent; + } + + .label text,span { + fill: ${e.nodeTextColor||e.textColor}; + color: ${e.nodeTextColor||e.textColor}; + } + + .node rect, + .node circle, + .node ellipse, + .node polygon, + .node path { + fill: ${e.mainBkg}; + stroke: ${e.nodeBorder}; + stroke-width: 1px; + } + .rough-node .label text , .node .label text, .image-shape .label, .icon-shape .label { + text-anchor: middle; + } + // .flowchart-label .text-outer-tspan { + // text-anchor: middle; + // } + // .flowchart-label .text-inner-tspan { + // text-anchor: start; + // } + + .node .katex path { + fill: #000; + stroke: #000; + stroke-width: 1px; + } + + .rough-node .label,.node .label, .image-shape .label, .icon-shape .label { + text-align: center; + } + .node.clickable { + cursor: pointer; + } + + + .root .anchor path { + fill: ${e.lineColor} !important; + stroke-width: 0; + stroke: ${e.lineColor}; + } + + .arrowheadPath { + fill: ${e.arrowheadColor}; + } + + .edgePath .path { + stroke: ${e.lineColor}; + stroke-width: 2.0px; + } + + .flowchart-link { + stroke: ${e.lineColor}; + fill: none; + } + + .edgeLabel { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } + + /* For html labels only */ + .labelBkg { + background-color: ${As(e.edgeLabelBackground,.5)}; + // background-color: + } + + .cluster rect { + fill: ${e.clusterBkg}; + stroke: ${e.clusterBorder}; + stroke-width: 1px; + } + + .cluster text { + fill: ${e.titleColor}; + } + + .cluster span { + color: ${e.titleColor}; + } + /* .cluster div { + color: ${e.titleColor}; + } */ + + div.mermaidTooltip { + position: absolute; + text-align: center; + max-width: 200px; + padding: 2px; + font-family: ${e.fontFamily}; + font-size: 12px; + background: ${e.tertiaryColor}; + border: 1px solid ${e.border2}; + border-radius: 2px; + pointer-events: none; + z-index: 100; + } + + .flowchartTitleText { + text-anchor: middle; + font-size: 18px; + fill: ${e.textColor}; + } + + rect.text { + fill: none; + stroke-width: 0; + } + + .icon-shape, .image-shape { + background-color: ${e.edgeLabelBackground}; + p { + background-color: ${e.edgeLabelBackground}; + padding: 2px; + } + rect { + opacity: 0.5; + background-color: ${e.edgeLabelBackground}; + fill: ${e.edgeLabelBackground}; + } + text-align: center; + } +`,"getStyles"),Lt=ms;var Zs={parser:Vt,db:i1,renderer:wt,styles:Lt,init:u(e=>{e.flowchart||(e.flowchart={}),e.layout&&p1({layout:e.layout}),e.flowchart.arrowMarkerAbsolute=e.arrowMarkerAbsolute,p1({flowchart:{arrowMarkerAbsolute:e.arrowMarkerAbsolute}}),i1.clear(),i1.setGen("gen-2")},"init")};export{Zs as diagram}; -- cgit v1.2.3