hise-flow-graphs 1.1.21 → 1.1.22
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/components/Certificates/CertificateGraph/helpers.d.ts +1 -1
- package/dist/components/Certificates/WalkingGraph/helpers.d.ts +2 -2
- package/dist/components/Certificates/WorkspaceCertificate/WorkspaceFileNode/helpers.d.ts +1 -1
- package/dist/components/Certificates/WorkspaceCertificate/WorkspaceIDENode/helpers.d.ts +2 -2
- package/dist/components/Certificates/WorkspaceCertificate/WorkspacePipelineNode/helpers.d.ts +2 -2
- package/dist/components/Certificates/WorkspaceCertificate/helpers.d.ts +1 -1
- package/dist/context/HiseConfigContext.d.ts +33 -0
- package/dist/index.d.ts +4 -2
- package/dist/index.es.js +19789 -17842
- package/dist/index.umd.js +154 -47
- package/package.json +2 -2
package/dist/index.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(ht,$){typeof exports=="object"&&typeof module<"u"?$(exports,require("react/jsx-runtime"),require("react"),require("react-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom"],$):(ht=typeof globalThis<"u"?globalThis:ht||self,$(ht["hise-flow-graphs"]={},ht.jsxRuntime,ht.React,ht.ReactDOM))})(this,(function(ht,$,se,SS){"use strict";const hv=e=>e&&typeof e=="object"&&"default"in e?e:{default:e},nt=hv(se),pv=hv(SS);var ii=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function ts(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function ns(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var rs,vv;function kS(){if(vv)return rs;vv=1;function e(){this.__data__=[],this.size=0}return rs=e,rs}var os,gv;function vr(){if(gv)return os;gv=1;function e(t,n){return t===n||t!==t&&n!==n}return os=e,os}var is,yv;function ai(){if(yv)return is;yv=1;var e=vr();function t(n,r){for(var o=n.length;o--;)if(e(n[o][0],r))return o;return-1}return is=t,is}var as,mv;function NS(){if(mv)return as;mv=1;var e=ai(),t=Array.prototype,n=t.splice;function r(o){var s=this.__data__,l=e(s,o);if(l<0)return!1;var c=s.length-1;return l==c?s.pop():n.call(s,l,1),--this.size,!0}return as=r,as}var ss,bv;function TS(){if(bv)return ss;bv=1;var e=ai();function t(n){var r=this.__data__,o=e(r,n);return o<0?void 0:r[o][1]}return ss=t,ss}var ls,_v;function CS(){if(_v)return ls;_v=1;var e=ai();function t(n){return e(this.__data__,n)>-1}return ls=t,ls}var us,wv;function AS(){if(wv)return us;wv=1;var e=ai();function t(n,r){var o=this.__data__,s=e(o,n);return s<0?(++this.size,o.push([n,r])):o[s][1]=r,this}return us=t,us}var cs,Ov;function si(){if(Ov)return cs;Ov=1;var e=kS(),t=NS(),n=TS(),r=CS(),o=AS();function s(l){var c=-1,f=l==null?0:l.length;for(this.clear();++c<f;){var h=l[c];this.set(h[0],h[1])}}return s.prototype.clear=e,s.prototype.delete=t,s.prototype.get=n,s.prototype.has=r,s.prototype.set=o,cs=s,cs}var fs,Ev;function PS(){if(Ev)return fs;Ev=1;var e=si();function t(){this.__data__=new e,this.size=0}return fs=t,fs}var ds,xv;function IS(){if(xv)return ds;xv=1;function e(t){var n=this.__data__,r=n.delete(t);return this.size=n.size,r}return ds=e,ds}var hs,Sv;function MS(){if(Sv)return hs;Sv=1;function e(t){return this.__data__.get(t)}return hs=e,hs}var ps,kv;function qS(){if(kv)return ps;kv=1;function e(t){return this.__data__.has(t)}return ps=e,ps}var vs,Nv;function Tv(){if(Nv)return vs;Nv=1;var e=typeof ii=="object"&&ii&&ii.Object===Object&ⅈreturn vs=e,vs}var gs,Cv;function rn(){if(Cv)return gs;Cv=1;var e=Tv(),t=typeof self=="object"&&self&&self.Object===Object&&self,n=e||t||Function("return this")();return gs=n,gs}var ys,Av;function gr(){if(Av)return ys;Av=1;var e=rn(),t=e.Symbol;return ys=t,ys}var ms,Pv;function LS(){if(Pv)return ms;Pv=1;var e=gr(),t=Object.prototype,n=t.hasOwnProperty,r=t.toString,o=e?e.toStringTag:void 0;function s(l){var c=n.call(l,o),f=l[o];try{l[o]=void 0;var h=!0}catch{}var a=r.call(l);return h&&(c?l[o]=f:delete l[o]),a}return ms=s,ms}var bs,Iv;function RS(){if(Iv)return bs;Iv=1;var e=Object.prototype,t=e.toString;function n(r){return t.call(r)}return bs=n,bs}var _s,Mv;function Wn(){if(Mv)return _s;Mv=1;var e=gr(),t=LS(),n=RS(),r="[object Null]",o="[object Undefined]",s=e?e.toStringTag:void 0;function l(c){return c==null?c===void 0?o:r:s&&s in Object(c)?t(c):n(c)}return _s=l,_s}var ws,qv;function Wt(){if(qv)return ws;qv=1;function e(t){var n=typeof t;return t!=null&&(n=="object"||n=="function")}return ws=e,ws}var Os,Lv;function to(){if(Lv)return Os;Lv=1;var e=Wn(),t=Wt(),n="[object AsyncFunction]",r="[object Function]",o="[object GeneratorFunction]",s="[object Proxy]";function l(c){if(!t(c))return!1;var f=e(c);return f==r||f==o||f==n||f==s}return Os=l,Os}var Es,Rv;function DS(){if(Rv)return Es;Rv=1;var e=rn(),t=e["__core-js_shared__"];return Es=t,Es}var xs,Dv;function jS(){if(Dv)return xs;Dv=1;var e=DS(),t=(function(){var r=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return r?"Symbol(src)_1."+r:""})();function n(r){return!!t&&t in r}return xs=n,xs}var Ss,jv;function Fv(){if(jv)return Ss;jv=1;var e=Function.prototype,t=e.toString;function n(r){if(r!=null){try{return t.call(r)}catch{}try{return r+""}catch{}}return""}return Ss=n,Ss}var ks,Bv;function FS(){if(Bv)return ks;Bv=1;var e=to(),t=jS(),n=Wt(),r=Fv(),o=/[\\^$.*+?()[\]{}|]/g,s=/^\[object .+?Constructor\]$/,l=Function.prototype,c=Object.prototype,f=l.toString,h=c.hasOwnProperty,a=RegExp("^"+f.call(h).replace(o,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function u(d){if(!n(d)||t(d))return!1;var p=e(d)?a:s;return p.test(r(d))}return ks=u,ks}var Ns,zv;function BS(){if(zv)return Ns;zv=1;function e(t,n){return t?.[n]}return Ns=e,Ns}var Ts,$v;function Yn(){if($v)return Ts;$v=1;var e=FS(),t=BS();function n(r,o){var s=t(r,o);return e(s)?s:void 0}return Ts=n,Ts}var Cs,Hv;function As(){if(Hv)return Cs;Hv=1;var e=Yn(),t=rn(),n=e(t,"Map");return Cs=n,Cs}var Ps,Vv;function li(){if(Vv)return Ps;Vv=1;var e=Yn(),t=e(Object,"create");return Ps=t,Ps}var Is,Uv;function zS(){if(Uv)return Is;Uv=1;var e=li();function t(){this.__data__=e?e(null):{},this.size=0}return Is=t,Is}var Ms,Gv;function $S(){if(Gv)return Ms;Gv=1;function e(t){var n=this.has(t)&&delete this.__data__[t];return this.size-=n?1:0,n}return Ms=e,Ms}var qs,Kv;function HS(){if(Kv)return qs;Kv=1;var e=li(),t="__lodash_hash_undefined__",n=Object.prototype,r=n.hasOwnProperty;function o(s){var l=this.__data__;if(e){var c=l[s];return c===t?void 0:c}return r.call(l,s)?l[s]:void 0}return qs=o,qs}var Ls,Wv;function VS(){if(Wv)return Ls;Wv=1;var e=li(),t=Object.prototype,n=t.hasOwnProperty;function r(o){var s=this.__data__;return e?s[o]!==void 0:n.call(s,o)}return Ls=r,Ls}var Rs,Yv;function US(){if(Yv)return Rs;Yv=1;var e=li(),t="__lodash_hash_undefined__";function n(r,o){var s=this.__data__;return this.size+=this.has(r)?0:1,s[r]=e&&o===void 0?t:o,this}return Rs=n,Rs}var Ds,Zv;function GS(){if(Zv)return Ds;Zv=1;var e=zS(),t=$S(),n=HS(),r=VS(),o=US();function s(l){var c=-1,f=l==null?0:l.length;for(this.clear();++c<f;){var h=l[c];this.set(h[0],h[1])}}return s.prototype.clear=e,s.prototype.delete=t,s.prototype.get=n,s.prototype.has=r,s.prototype.set=o,Ds=s,Ds}var js,Xv;function KS(){if(Xv)return js;Xv=1;var e=GS(),t=si(),n=As();function r(){this.size=0,this.__data__={hash:new e,map:new(n||t),string:new e}}return js=r,js}var Fs,Qv;function WS(){if(Qv)return Fs;Qv=1;function e(t){var n=typeof t;return n=="string"||n=="number"||n=="symbol"||n=="boolean"?t!=="__proto__":t===null}return Fs=e,Fs}var Bs,Jv;function ui(){if(Jv)return Bs;Jv=1;var e=WS();function t(n,r){var o=n.__data__;return e(r)?o[typeof r=="string"?"string":"hash"]:o.map}return Bs=t,Bs}var zs,eg;function YS(){if(eg)return zs;eg=1;var e=ui();function t(n){var r=e(this,n).delete(n);return this.size-=r?1:0,r}return zs=t,zs}var $s,tg;function ZS(){if(tg)return $s;tg=1;var e=ui();function t(n){return e(this,n).get(n)}return $s=t,$s}var Hs,ng;function XS(){if(ng)return Hs;ng=1;var e=ui();function t(n){return e(this,n).has(n)}return Hs=t,Hs}var Vs,rg;function QS(){if(rg)return Vs;rg=1;var e=ui();function t(n,r){var o=e(this,n),s=o.size;return o.set(n,r),this.size+=o.size==s?0:1,this}return Vs=t,Vs}var Us,og;function Gs(){if(og)return Us;og=1;var e=KS(),t=YS(),n=ZS(),r=XS(),o=QS();function s(l){var c=-1,f=l==null?0:l.length;for(this.clear();++c<f;){var h=l[c];this.set(h[0],h[1])}}return s.prototype.clear=e,s.prototype.delete=t,s.prototype.get=n,s.prototype.has=r,s.prototype.set=o,Us=s,Us}var Ks,ig;function JS(){if(ig)return Ks;ig=1;var e=si(),t=As(),n=Gs(),r=200;function o(s,l){var c=this.__data__;if(c instanceof e){var f=c.__data__;if(!t||f.length<r-1)return f.push([s,l]),this.size=++c.size,this;c=this.__data__=new n(f)}return c.set(s,l),this.size=c.size,this}return Ks=o,Ks}var Ws,ag;function ci(){if(ag)return Ws;ag=1;var e=si(),t=PS(),n=IS(),r=MS(),o=qS(),s=JS();function l(c){var f=this.__data__=new e(c);this.size=f.size}return l.prototype.clear=t,l.prototype.delete=n,l.prototype.get=r,l.prototype.has=o,l.prototype.set=s,Ws=l,Ws}var Ys,sg;function Zs(){if(sg)return Ys;sg=1;function e(t,n){for(var r=-1,o=t==null?0:t.length;++r<o&&n(t[r],r,t)!==!1;);return t}return Ys=e,Ys}var Xs,lg;function ug(){if(lg)return Xs;lg=1;var e=Yn(),t=(function(){try{var n=e(Object,"defineProperty");return n({},"",{}),n}catch{}})();return Xs=t,Xs}var Qs,cg;function fi(){if(cg)return Qs;cg=1;var e=ug();function t(n,r,o){r=="__proto__"&&e?e(n,r,{configurable:!0,enumerable:!0,value:o,writable:!0}):n[r]=o}return Qs=t,Qs}var Js,fg;function di(){if(fg)return Js;fg=1;var e=fi(),t=vr(),n=Object.prototype,r=n.hasOwnProperty;function o(s,l,c){var f=s[l];(!(r.call(s,l)&&t(f,c))||c===void 0&&!(l in s))&&e(s,l,c)}return Js=o,Js}var el,dg;function no(){if(dg)return el;dg=1;var e=di(),t=fi();function n(r,o,s,l){var c=!s;s||(s={});for(var f=-1,h=o.length;++f<h;){var a=o[f],u=l?l(s[a],r[a],a,s,r):void 0;u===void 0&&(u=r[a]),c?t(s,a,u):e(s,a,u)}return s}return el=n,el}var tl,hg;function ek(){if(hg)return tl;hg=1;function e(t,n){for(var r=-1,o=Array(t);++r<t;)o[r]=n(r);return o}return tl=e,tl}var nl,pg;function fn(){if(pg)return nl;pg=1;function e(t){return t!=null&&typeof t=="object"}return nl=e,nl}var rl,vg;function tk(){if(vg)return rl;vg=1;var e=Wn(),t=fn(),n="[object Arguments]";function r(o){return t(o)&&e(o)==n}return rl=r,rl}var ol,gg;function ro(){if(gg)return ol;gg=1;var e=tk(),t=fn(),n=Object.prototype,r=n.hasOwnProperty,o=n.propertyIsEnumerable,s=e((function(){return arguments})())?e:function(l){return t(l)&&r.call(l,"callee")&&!o.call(l,"callee")};return ol=s,ol}var il,yg;function yt(){if(yg)return il;yg=1;var e=Array.isArray;return il=e,il}var oo={exports:{}},al,mg;function nk(){if(mg)return al;mg=1;function e(){return!1}return al=e,al}oo.exports;var bg;function yr(){return bg||(bg=1,(function(e,t){var n=rn(),r=nk(),o=t&&!t.nodeType&&t,s=o&&!0&&e&&!e.nodeType&&e,l=s&&s.exports===o,c=l?n.Buffer:void 0,f=c?c.isBuffer:void 0,h=f||r;e.exports=h})(oo,oo.exports)),oo.exports}var sl,_g;function hi(){if(_g)return sl;_g=1;var e=9007199254740991,t=/^(?:0|[1-9]\d*)$/;function n(r,o){var s=typeof r;return o=o??e,!!o&&(s=="number"||s!="symbol"&&t.test(r))&&r>-1&&r%1==0&&r<o}return sl=n,sl}var ll,wg;function ul(){if(wg)return ll;wg=1;var e=9007199254740991;function t(n){return typeof n=="number"&&n>-1&&n%1==0&&n<=e}return ll=t,ll}var cl,Og;function rk(){if(Og)return cl;Og=1;var e=Wn(),t=ul(),n=fn(),r="[object Arguments]",o="[object Array]",s="[object Boolean]",l="[object Date]",c="[object Error]",f="[object Function]",h="[object Map]",a="[object Number]",u="[object Object]",d="[object RegExp]",p="[object Set]",O="[object String]",g="[object WeakMap]",_="[object ArrayBuffer]",y="[object DataView]",w="[object Float32Array]",E="[object Float64Array]",m="[object Int8Array]",S="[object Int16Array]",C="[object Int32Array]",N="[object Uint8Array]",M="[object Uint8ClampedArray]",j="[object Uint16Array]",I="[object Uint32Array]",A={};A[w]=A[E]=A[m]=A[S]=A[C]=A[N]=A[M]=A[j]=A[I]=!0,A[r]=A[o]=A[_]=A[s]=A[y]=A[l]=A[c]=A[f]=A[h]=A[a]=A[u]=A[d]=A[p]=A[O]=A[g]=!1;function q(R){return n(R)&&t(R.length)&&!!A[e(R)]}return cl=q,cl}var fl,Eg;function pi(){if(Eg)return fl;Eg=1;function e(t){return function(n){return t(n)}}return fl=e,fl}var io={exports:{}};io.exports;var xg;function dl(){return xg||(xg=1,(function(e,t){var n=Tv(),r=t&&!t.nodeType&&t,o=r&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===r,l=s&&n.process,c=(function(){try{var f=o&&o.require&&o.require("util").types;return f||l&&l.binding&&l.binding("util")}catch{}})();e.exports=c})(io,io.exports)),io.exports}var hl,Sg;function ao(){if(Sg)return hl;Sg=1;var e=rk(),t=pi(),n=dl(),r=n&&n.isTypedArray,o=r?t(r):e;return hl=o,hl}var pl,kg;function Ng(){if(kg)return pl;kg=1;var e=ek(),t=ro(),n=yt(),r=yr(),o=hi(),s=ao(),l=Object.prototype,c=l.hasOwnProperty;function f(h,a){var u=n(h),d=!u&&t(h),p=!u&&!d&&r(h),O=!u&&!d&&!p&&s(h),g=u||d||p||O,_=g?e(h.length,String):[],y=_.length;for(var w in h)(a||c.call(h,w))&&!(g&&(w=="length"||p&&(w=="offset"||w=="parent")||O&&(w=="buffer"||w=="byteLength"||w=="byteOffset")||o(w,y)))&&_.push(w);return _}return pl=f,pl}var vl,Tg;function vi(){if(Tg)return vl;Tg=1;var e=Object.prototype;function t(n){var r=n&&n.constructor,o=typeof r=="function"&&r.prototype||e;return n===o}return vl=t,vl}var gl,Cg;function Ag(){if(Cg)return gl;Cg=1;function e(t,n){return function(r){return t(n(r))}}return gl=e,gl}var yl,Pg;function ok(){if(Pg)return yl;Pg=1;var e=Ag(),t=e(Object.keys,Object);return yl=t,yl}var ml,Ig;function bl(){if(Ig)return ml;Ig=1;var e=vi(),t=ok(),n=Object.prototype,r=n.hasOwnProperty;function o(s){if(!e(s))return t(s);var l=[];for(var c in Object(s))r.call(s,c)&&c!="constructor"&&l.push(c);return l}return ml=o,ml}var _l,Mg;function On(){if(Mg)return _l;Mg=1;var e=to(),t=ul();function n(r){return r!=null&&t(r.length)&&!e(r)}return _l=n,_l}var wl,qg;function Ln(){if(qg)return wl;qg=1;var e=Ng(),t=bl(),n=On();function r(o){return n(o)?e(o):t(o)}return wl=r,wl}var Ol,Lg;function ik(){if(Lg)return Ol;Lg=1;var e=no(),t=Ln();function n(r,o){return r&&e(o,t(o),r)}return Ol=n,Ol}var El,Rg;function ak(){if(Rg)return El;Rg=1;function e(t){var n=[];if(t!=null)for(var r in Object(t))n.push(r);return n}return El=e,El}var xl,Dg;function sk(){if(Dg)return xl;Dg=1;var e=Wt(),t=vi(),n=ak(),r=Object.prototype,o=r.hasOwnProperty;function s(l){if(!e(l))return n(l);var c=t(l),f=[];for(var h in l)h=="constructor"&&(c||!o.call(l,h))||f.push(h);return f}return xl=s,xl}var Sl,jg;function Zn(){if(jg)return Sl;jg=1;var e=Ng(),t=sk(),n=On();function r(o){return n(o)?e(o,!0):t(o)}return Sl=r,Sl}var kl,Fg;function lk(){if(Fg)return kl;Fg=1;var e=no(),t=Zn();function n(r,o){return r&&e(o,t(o),r)}return kl=n,kl}var so={exports:{}};so.exports;var Bg;function zg(){return Bg||(Bg=1,(function(e,t){var n=rn(),r=t&&!t.nodeType&&t,o=r&&!0&&e&&!e.nodeType&&e,s=o&&o.exports===r,l=s?n.Buffer:void 0,c=l?l.allocUnsafe:void 0;function f(h,a){if(a)return h.slice();var u=h.length,d=c?c(u):new h.constructor(u);return h.copy(d),d}e.exports=f})(so,so.exports)),so.exports}var Nl,$g;function Hg(){if($g)return Nl;$g=1;function e(t,n){var r=-1,o=t.length;for(n||(n=Array(o));++r<o;)n[r]=t[r];return n}return Nl=e,Nl}var Tl,Vg;function Ug(){if(Vg)return Tl;Vg=1;function e(t,n){for(var r=-1,o=t==null?0:t.length,s=0,l=[];++r<o;){var c=t[r];n(c,r,t)&&(l[s++]=c)}return l}return Tl=e,Tl}var Cl,Gg;function Kg(){if(Gg)return Cl;Gg=1;function e(){return[]}return Cl=e,Cl}var Al,Wg;function Pl(){if(Wg)return Al;Wg=1;var e=Ug(),t=Kg(),n=Object.prototype,r=n.propertyIsEnumerable,o=Object.getOwnPropertySymbols,s=o?function(l){return l==null?[]:(l=Object(l),e(o(l),function(c){return r.call(l,c)}))}:t;return Al=s,Al}var Il,Yg;function uk(){if(Yg)return Il;Yg=1;var e=no(),t=Pl();function n(r,o){return e(r,t(r),o)}return Il=n,Il}var Ml,Zg;function ql(){if(Zg)return Ml;Zg=1;function e(t,n){for(var r=-1,o=n.length,s=t.length;++r<o;)t[s+r]=n[r];return t}return Ml=e,Ml}var Ll,Xg;function gi(){if(Xg)return Ll;Xg=1;var e=Ag(),t=e(Object.getPrototypeOf,Object);return Ll=t,Ll}var Rl,Qg;function Jg(){if(Qg)return Rl;Qg=1;var e=ql(),t=gi(),n=Pl(),r=Kg(),o=Object.getOwnPropertySymbols,s=o?function(l){for(var c=[];l;)e(c,n(l)),l=t(l);return c}:r;return Rl=s,Rl}var Dl,ey;function ck(){if(ey)return Dl;ey=1;var e=no(),t=Jg();function n(r,o){return e(r,t(r),o)}return Dl=n,Dl}var jl,ty;function ny(){if(ty)return jl;ty=1;var e=ql(),t=yt();function n(r,o,s){var l=o(r);return t(r)?l:e(l,s(r))}return jl=n,jl}var Fl,ry;function oy(){if(ry)return Fl;ry=1;var e=ny(),t=Pl(),n=Ln();function r(o){return e(o,n,t)}return Fl=r,Fl}var Bl,iy;function fk(){if(iy)return Bl;iy=1;var e=ny(),t=Jg(),n=Zn();function r(o){return e(o,n,t)}return Bl=r,Bl}var zl,ay;function dk(){if(ay)return zl;ay=1;var e=Yn(),t=rn(),n=e(t,"DataView");return zl=n,zl}var $l,sy;function hk(){if(sy)return $l;sy=1;var e=Yn(),t=rn(),n=e(t,"Promise");return $l=n,$l}var Hl,ly;function uy(){if(ly)return Hl;ly=1;var e=Yn(),t=rn(),n=e(t,"Set");return Hl=n,Hl}var Vl,cy;function pk(){if(cy)return Vl;cy=1;var e=Yn(),t=rn(),n=e(t,"WeakMap");return Vl=n,Vl}var Ul,fy;function mr(){if(fy)return Ul;fy=1;var e=dk(),t=As(),n=hk(),r=uy(),o=pk(),s=Wn(),l=Fv(),c="[object Map]",f="[object Object]",h="[object Promise]",a="[object Set]",u="[object WeakMap]",d="[object DataView]",p=l(e),O=l(t),g=l(n),_=l(r),y=l(o),w=s;return(e&&w(new e(new ArrayBuffer(1)))!=d||t&&w(new t)!=c||n&&w(n.resolve())!=h||r&&w(new r)!=a||o&&w(new o)!=u)&&(w=function(E){var m=s(E),S=m==f?E.constructor:void 0,C=S?l(S):"";if(C)switch(C){case p:return d;case O:return c;case g:return h;case _:return a;case y:return u}return m}),Ul=w,Ul}var Gl,dy;function vk(){if(dy)return Gl;dy=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r){var o=r.length,s=new r.constructor(o);return o&&typeof r[0]=="string"&&t.call(r,"index")&&(s.index=r.index,s.input=r.input),s}return Gl=n,Gl}var Kl,hy;function py(){if(hy)return Kl;hy=1;var e=rn(),t=e.Uint8Array;return Kl=t,Kl}var Wl,vy;function Yl(){if(vy)return Wl;vy=1;var e=py();function t(n){var r=new n.constructor(n.byteLength);return new e(r).set(new e(n)),r}return Wl=t,Wl}var Zl,gy;function gk(){if(gy)return Zl;gy=1;var e=Yl();function t(n,r){var o=r?e(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.byteLength)}return Zl=t,Zl}var Xl,yy;function yk(){if(yy)return Xl;yy=1;var e=/\w*$/;function t(n){var r=new n.constructor(n.source,e.exec(n));return r.lastIndex=n.lastIndex,r}return Xl=t,Xl}var Ql,my;function mk(){if(my)return Ql;my=1;var e=gr(),t=e?e.prototype:void 0,n=t?t.valueOf:void 0;function r(o){return n?Object(n.call(o)):{}}return Ql=r,Ql}var Jl,by;function _y(){if(by)return Jl;by=1;var e=Yl();function t(n,r){var o=r?e(n.buffer):n.buffer;return new n.constructor(o,n.byteOffset,n.length)}return Jl=t,Jl}var eu,wy;function bk(){if(wy)return eu;wy=1;var e=Yl(),t=gk(),n=yk(),r=mk(),o=_y(),s="[object Boolean]",l="[object Date]",c="[object Map]",f="[object Number]",h="[object RegExp]",a="[object Set]",u="[object String]",d="[object Symbol]",p="[object ArrayBuffer]",O="[object DataView]",g="[object Float32Array]",_="[object Float64Array]",y="[object Int8Array]",w="[object Int16Array]",E="[object Int32Array]",m="[object Uint8Array]",S="[object Uint8ClampedArray]",C="[object Uint16Array]",N="[object Uint32Array]";function M(j,I,A){var q=j.constructor;switch(I){case p:return e(j);case s:case l:return new q(+j);case O:return t(j,A);case g:case _:case y:case w:case E:case m:case S:case C:case N:return o(j,A);case c:return new q;case f:case u:return new q(j);case h:return n(j);case a:return new q;case d:return r(j)}}return eu=M,eu}var tu,Oy;function Ey(){if(Oy)return tu;Oy=1;var e=Wt(),t=Object.create,n=(function(){function r(){}return function(o){if(!e(o))return{};if(t)return t(o);r.prototype=o;var s=new r;return r.prototype=void 0,s}})();return tu=n,tu}var nu,xy;function Sy(){if(xy)return nu;xy=1;var e=Ey(),t=gi(),n=vi();function r(o){return typeof o.constructor=="function"&&!n(o)?e(t(o)):{}}return nu=r,nu}var ru,ky;function _k(){if(ky)return ru;ky=1;var e=mr(),t=fn(),n="[object Map]";function r(o){return t(o)&&e(o)==n}return ru=r,ru}var ou,Ny;function wk(){if(Ny)return ou;Ny=1;var e=_k(),t=pi(),n=dl(),r=n&&n.isMap,o=r?t(r):e;return ou=o,ou}var iu,Ty;function Ok(){if(Ty)return iu;Ty=1;var e=mr(),t=fn(),n="[object Set]";function r(o){return t(o)&&e(o)==n}return iu=r,iu}var au,Cy;function Ek(){if(Cy)return au;Cy=1;var e=Ok(),t=pi(),n=dl(),r=n&&n.isSet,o=r?t(r):e;return au=o,au}var su,Ay;function Py(){if(Ay)return su;Ay=1;var e=ci(),t=Zs(),n=di(),r=ik(),o=lk(),s=zg(),l=Hg(),c=uk(),f=ck(),h=oy(),a=fk(),u=mr(),d=vk(),p=bk(),O=Sy(),g=yt(),_=yr(),y=wk(),w=Wt(),E=Ek(),m=Ln(),S=Zn(),C=1,N=2,M=4,j="[object Arguments]",I="[object Array]",A="[object Boolean]",q="[object Date]",R="[object Error]",k="[object Function]",F="[object GeneratorFunction]",U="[object Map]",ne="[object Number]",ue="[object Object]",K="[object RegExp]",W="[object Set]",z="[object String]",Q="[object Symbol]",re="[object WeakMap]",Z="[object ArrayBuffer]",X="[object DataView]",H="[object Float32Array]",ee="[object Float64Array]",le="[object Int8Array]",de="[object Int16Array]",pe="[object Int32Array]",Ee="[object Uint8Array]",Ie="[object Uint8ClampedArray]",Pe="[object Uint16Array]",Ae="[object Uint32Array]",Se={};Se[j]=Se[I]=Se[Z]=Se[X]=Se[A]=Se[q]=Se[H]=Se[ee]=Se[le]=Se[de]=Se[pe]=Se[U]=Se[ne]=Se[ue]=Se[K]=Se[W]=Se[z]=Se[Q]=Se[Ee]=Se[Ie]=Se[Pe]=Se[Ae]=!0,Se[R]=Se[k]=Se[re]=!1;function Ge(Oe,ge,me,ke,Ne,we){var qe,je=ge&C,ze=ge&N,lt=ge&M;if(me&&(qe=Ne?me(Oe,ke,Ne,we):me(Oe)),qe!==void 0)return qe;if(!w(Oe))return Oe;var pt=g(Oe);if(pt){if(qe=d(Oe),!je)return l(Oe,qe)}else{var Ze=u(Oe),It=Ze==k||Ze==F;if(_(Oe))return s(Oe,je);if(Ze==ue||Ze==j||It&&!Ne){if(qe=ze||It?{}:O(Oe),!je)return ze?f(Oe,o(qe,Oe)):c(Oe,r(qe,Oe))}else{if(!Se[Ze])return Ne?Oe:{};qe=p(Oe,Ze,je)}}we||(we=new e);var We=we.get(Oe);if(We)return We;we.set(Oe,qe),E(Oe)?Oe.forEach(function(kt){qe.add(Ge(kt,ge,me,kt,Oe,we))}):y(Oe)&&Oe.forEach(function(kt,Nt){qe.set(Nt,Ge(kt,ge,me,Nt,Oe,we))});var it=lt?ze?a:h:ze?S:m,Ot=pt?void 0:it(Oe);return t(Ot||Oe,function(kt,Nt){Ot&&(Nt=kt,kt=Oe[Nt]),n(qe,Nt,Ge(kt,ge,me,Nt,Oe,we))}),qe}return su=Ge,su}var lu,Iy;function xk(){if(Iy)return lu;Iy=1;var e=Py(),t=4;function n(r){return e(r,t)}return lu=n,lu}var uu,My;function cu(){if(My)return uu;My=1;function e(t){return function(){return t}}return uu=e,uu}var fu,qy;function Sk(){if(qy)return fu;qy=1;function e(t){return function(n,r,o){for(var s=-1,l=Object(n),c=o(n),f=c.length;f--;){var h=c[t?f:++s];if(r(l[h],h,l)===!1)break}return n}}return fu=e,fu}var du,Ly;function hu(){if(Ly)return du;Ly=1;var e=Sk(),t=e();return du=t,du}var pu,Ry;function vu(){if(Ry)return pu;Ry=1;var e=hu(),t=Ln();function n(r,o){return r&&e(r,o,t)}return pu=n,pu}var gu,Dy;function kk(){if(Dy)return gu;Dy=1;var e=On();function t(n,r){return function(o,s){if(o==null)return o;if(!e(o))return n(o,s);for(var l=o.length,c=r?l:-1,f=Object(o);(r?c--:++c<l)&&s(f[c],c,f)!==!1;);return o}}return gu=t,gu}var yu,jy;function yi(){if(jy)return yu;jy=1;var e=vu(),t=kk(),n=t(e);return yu=n,yu}var mu,Fy;function Xn(){if(Fy)return mu;Fy=1;function e(t){return t}return mu=e,mu}var bu,By;function zy(){if(By)return bu;By=1;var e=Xn();function t(n){return typeof n=="function"?n:e}return bu=t,bu}var _u,$y;function Hy(){if($y)return _u;$y=1;var e=Zs(),t=yi(),n=zy(),r=yt();function o(s,l){var c=r(s)?e:t;return c(s,n(l))}return _u=o,_u}var wu,Vy;function Uy(){return Vy||(Vy=1,wu=Hy()),wu}var Ou,Gy;function Nk(){if(Gy)return Ou;Gy=1;var e=yi();function t(n,r){var o=[];return e(n,function(s,l,c){r(s,l,c)&&o.push(s)}),o}return Ou=t,Ou}var Eu,Ky;function Tk(){if(Ky)return Eu;Ky=1;var e="__lodash_hash_undefined__";function t(n){return this.__data__.set(n,e),this}return Eu=t,Eu}var xu,Wy;function Ck(){if(Wy)return xu;Wy=1;function e(t){return this.__data__.has(t)}return xu=e,xu}var Su,Yy;function Zy(){if(Yy)return Su;Yy=1;var e=Gs(),t=Tk(),n=Ck();function r(o){var s=-1,l=o==null?0:o.length;for(this.__data__=new e;++s<l;)this.add(o[s])}return r.prototype.add=r.prototype.push=t,r.prototype.has=n,Su=r,Su}var ku,Xy;function Ak(){if(Xy)return ku;Xy=1;function e(t,n){for(var r=-1,o=t==null?0:t.length;++r<o;)if(n(t[r],r,t))return!0;return!1}return ku=e,ku}var Nu,Qy;function Jy(){if(Qy)return Nu;Qy=1;function e(t,n){return t.has(n)}return Nu=e,Nu}var Tu,em;function tm(){if(em)return Tu;em=1;var e=Zy(),t=Ak(),n=Jy(),r=1,o=2;function s(l,c,f,h,a,u){var d=f&r,p=l.length,O=c.length;if(p!=O&&!(d&&O>p))return!1;var g=u.get(l),_=u.get(c);if(g&&_)return g==c&&_==l;var y=-1,w=!0,E=f&o?new e:void 0;for(u.set(l,c),u.set(c,l);++y<p;){var m=l[y],S=c[y];if(h)var C=d?h(S,m,y,c,l,u):h(m,S,y,l,c,u);if(C!==void 0){if(C)continue;w=!1;break}if(E){if(!t(c,function(N,M){if(!n(E,M)&&(m===N||a(m,N,f,h,u)))return E.push(M)})){w=!1;break}}else if(!(m===S||a(m,S,f,h,u))){w=!1;break}}return u.delete(l),u.delete(c),w}return Tu=s,Tu}var Cu,nm;function Pk(){if(nm)return Cu;nm=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(o,s){r[++n]=[s,o]}),r}return Cu=e,Cu}var Au,rm;function Pu(){if(rm)return Au;rm=1;function e(t){var n=-1,r=Array(t.size);return t.forEach(function(o){r[++n]=o}),r}return Au=e,Au}var Iu,om;function Ik(){if(om)return Iu;om=1;var e=gr(),t=py(),n=vr(),r=tm(),o=Pk(),s=Pu(),l=1,c=2,f="[object Boolean]",h="[object Date]",a="[object Error]",u="[object Map]",d="[object Number]",p="[object RegExp]",O="[object Set]",g="[object String]",_="[object Symbol]",y="[object ArrayBuffer]",w="[object DataView]",E=e?e.prototype:void 0,m=E?E.valueOf:void 0;function S(C,N,M,j,I,A,q){switch(M){case w:if(C.byteLength!=N.byteLength||C.byteOffset!=N.byteOffset)return!1;C=C.buffer,N=N.buffer;case y:return!(C.byteLength!=N.byteLength||!A(new t(C),new t(N)));case f:case h:case d:return n(+C,+N);case a:return C.name==N.name&&C.message==N.message;case p:case g:return C==N+"";case u:var R=o;case O:var k=j&l;if(R||(R=s),C.size!=N.size&&!k)return!1;var F=q.get(C);if(F)return F==N;j|=c,q.set(C,N);var U=r(R(C),R(N),j,I,A,q);return q.delete(C),U;case _:if(m)return m.call(C)==m.call(N)}return!1}return Iu=S,Iu}var Mu,im;function Mk(){if(im)return Mu;im=1;var e=oy(),t=1,n=Object.prototype,r=n.hasOwnProperty;function o(s,l,c,f,h,a){var u=c&t,d=e(s),p=d.length,O=e(l),g=O.length;if(p!=g&&!u)return!1;for(var _=p;_--;){var y=d[_];if(!(u?y in l:r.call(l,y)))return!1}var w=a.get(s),E=a.get(l);if(w&&E)return w==l&&E==s;var m=!0;a.set(s,l),a.set(l,s);for(var S=u;++_<p;){y=d[_];var C=s[y],N=l[y];if(f)var M=u?f(N,C,y,l,s,a):f(C,N,y,s,l,a);if(!(M===void 0?C===N||h(C,N,c,f,a):M)){m=!1;break}S||(S=y=="constructor")}if(m&&!S){var j=s.constructor,I=l.constructor;j!=I&&"constructor"in s&&"constructor"in l&&!(typeof j=="function"&&j instanceof j&&typeof I=="function"&&I instanceof I)&&(m=!1)}return a.delete(s),a.delete(l),m}return Mu=o,Mu}var qu,am;function qk(){if(am)return qu;am=1;var e=ci(),t=tm(),n=Ik(),r=Mk(),o=mr(),s=yt(),l=yr(),c=ao(),f=1,h="[object Arguments]",a="[object Array]",u="[object Object]",d=Object.prototype,p=d.hasOwnProperty;function O(g,_,y,w,E,m){var S=s(g),C=s(_),N=S?a:o(g),M=C?a:o(_);N=N==h?u:N,M=M==h?u:M;var j=N==u,I=M==u,A=N==M;if(A&&l(g)){if(!l(_))return!1;S=!0,j=!1}if(A&&!j)return m||(m=new e),S||c(g)?t(g,_,y,w,E,m):n(g,_,N,y,w,E,m);if(!(y&f)){var q=j&&p.call(g,"__wrapped__"),R=I&&p.call(_,"__wrapped__");if(q||R){var k=q?g.value():g,F=R?_.value():_;return m||(m=new e),E(k,F,y,w,m)}}return A?(m||(m=new e),r(g,_,y,w,E,m)):!1}return qu=O,qu}var Lu,sm;function Ru(){if(sm)return Lu;sm=1;var e=qk(),t=fn();function n(r,o,s,l,c){return r===o?!0:r==null||o==null||!t(r)&&!t(o)?r!==r&&o!==o:e(r,o,s,l,n,c)}return Lu=n,Lu}var Du,lm;function Lk(){if(lm)return Du;lm=1;var e=ci(),t=Ru(),n=1,r=2;function o(s,l,c,f){var h=c.length,a=h,u=!f;if(s==null)return!a;for(s=Object(s);h--;){var d=c[h];if(u&&d[2]?d[1]!==s[d[0]]:!(d[0]in s))return!1}for(;++h<a;){d=c[h];var p=d[0],O=s[p],g=d[1];if(u&&d[2]){if(O===void 0&&!(p in s))return!1}else{var _=new e;if(f)var y=f(O,g,p,s,l,_);if(!(y===void 0?t(g,O,n|r,f,_):y))return!1}}return!0}return Du=o,Du}var ju,um;function cm(){if(um)return ju;um=1;var e=Wt();function t(n){return n===n&&!e(n)}return ju=t,ju}var Fu,fm;function Rk(){if(fm)return Fu;fm=1;var e=cm(),t=Ln();function n(r){for(var o=t(r),s=o.length;s--;){var l=o[s],c=r[l];o[s]=[l,c,e(c)]}return o}return Fu=n,Fu}var Bu,dm;function hm(){if(dm)return Bu;dm=1;function e(t,n){return function(r){return r==null?!1:r[t]===n&&(n!==void 0||t in Object(r))}}return Bu=e,Bu}var zu,pm;function Dk(){if(pm)return zu;pm=1;var e=Lk(),t=Rk(),n=hm();function r(o){var s=t(o);return s.length==1&&s[0][2]?n(s[0][0],s[0][1]):function(l){return l===o||e(l,o,s)}}return zu=r,zu}var $u,vm;function br(){if(vm)return $u;vm=1;var e=Wn(),t=fn(),n="[object Symbol]";function r(o){return typeof o=="symbol"||t(o)&&e(o)==n}return $u=r,$u}var Hu,gm;function Vu(){if(gm)return Hu;gm=1;var e=yt(),t=br(),n=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,r=/^\w*$/;function o(s,l){if(e(s))return!1;var c=typeof s;return c=="number"||c=="symbol"||c=="boolean"||s==null||t(s)?!0:r.test(s)||!n.test(s)||l!=null&&s in Object(l)}return Hu=o,Hu}var Uu,ym;function jk(){if(ym)return Uu;ym=1;var e=Gs(),t="Expected a function";function n(r,o){if(typeof r!="function"||o!=null&&typeof o!="function")throw new TypeError(t);var s=function(){var l=arguments,c=o?o.apply(this,l):l[0],f=s.cache;if(f.has(c))return f.get(c);var h=r.apply(this,l);return s.cache=f.set(c,h)||f,h};return s.cache=new(n.Cache||e),s}return n.Cache=e,Uu=n,Uu}var Gu,mm;function Fk(){if(mm)return Gu;mm=1;var e=jk(),t=500;function n(r){var o=e(r,function(l){return s.size===t&&s.clear(),l}),s=o.cache;return o}return Gu=n,Gu}var Ku,bm;function Bk(){if(bm)return Ku;bm=1;var e=Fk(),t=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,n=/\\(\\)?/g,r=e(function(o){var s=[];return o.charCodeAt(0)===46&&s.push(""),o.replace(t,function(l,c,f,h){s.push(f?h.replace(n,"$1"):c||l)}),s});return Ku=r,Ku}var Wu,_m;function mi(){if(_m)return Wu;_m=1;function e(t,n){for(var r=-1,o=t==null?0:t.length,s=Array(o);++r<o;)s[r]=n(t[r],r,t);return s}return Wu=e,Wu}var Yu,wm;function zk(){if(wm)return Yu;wm=1;var e=gr(),t=mi(),n=yt(),r=br(),o=e?e.prototype:void 0,s=o?o.toString:void 0;function l(c){if(typeof c=="string")return c;if(n(c))return t(c,l)+"";if(r(c))return s?s.call(c):"";var f=c+"";return f=="0"&&1/c==-1/0?"-0":f}return Yu=l,Yu}var Zu,Om;function Em(){if(Om)return Zu;Om=1;var e=zk();function t(n){return n==null?"":e(n)}return Zu=t,Zu}var Xu,xm;function bi(){if(xm)return Xu;xm=1;var e=yt(),t=Vu(),n=Bk(),r=Em();function o(s,l){return e(s)?s:t(s,l)?[s]:n(r(s))}return Xu=o,Xu}var Qu,Sm;function lo(){if(Sm)return Qu;Sm=1;var e=br();function t(n){if(typeof n=="string"||e(n))return n;var r=n+"";return r=="0"&&1/n==-1/0?"-0":r}return Qu=t,Qu}var Ju,km;function _i(){if(km)return Ju;km=1;var e=bi(),t=lo();function n(r,o){o=e(o,r);for(var s=0,l=o.length;r!=null&&s<l;)r=r[t(o[s++])];return s&&s==l?r:void 0}return Ju=n,Ju}var ec,Nm;function $k(){if(Nm)return ec;Nm=1;var e=_i();function t(n,r,o){var s=n==null?void 0:e(n,r);return s===void 0?o:s}return ec=t,ec}var tc,Tm;function Hk(){if(Tm)return tc;Tm=1;function e(t,n){return t!=null&&n in Object(t)}return tc=e,tc}var nc,Cm;function Am(){if(Cm)return nc;Cm=1;var e=bi(),t=ro(),n=yt(),r=hi(),o=ul(),s=lo();function l(c,f,h){f=e(f,c);for(var a=-1,u=f.length,d=!1;++a<u;){var p=s(f[a]);if(!(d=c!=null&&h(c,p)))break;c=c[p]}return d||++a!=u?d:(u=c==null?0:c.length,!!u&&o(u)&&r(p,u)&&(n(c)||t(c)))}return nc=l,nc}var rc,Pm;function Im(){if(Pm)return rc;Pm=1;var e=Hk(),t=Am();function n(r,o){return r!=null&&t(r,o,e)}return rc=n,rc}var oc,Mm;function Vk(){if(Mm)return oc;Mm=1;var e=Ru(),t=$k(),n=Im(),r=Vu(),o=cm(),s=hm(),l=lo(),c=1,f=2;function h(a,u){return r(a)&&o(u)?s(l(a),u):function(d){var p=t(d,a);return p===void 0&&p===u?n(d,a):e(u,p,c|f)}}return oc=h,oc}var ic,qm;function Lm(){if(qm)return ic;qm=1;function e(t){return function(n){return n?.[t]}}return ic=e,ic}var ac,Rm;function Uk(){if(Rm)return ac;Rm=1;var e=_i();function t(n){return function(r){return e(r,n)}}return ac=t,ac}var sc,Dm;function Gk(){if(Dm)return sc;Dm=1;var e=Lm(),t=Uk(),n=Vu(),r=lo();function o(s){return n(s)?e(r(s)):t(s)}return sc=o,sc}var lc,jm;function En(){if(jm)return lc;jm=1;var e=Dk(),t=Vk(),n=Xn(),r=yt(),o=Gk();function s(l){return typeof l=="function"?l:l==null?n:typeof l=="object"?r(l)?t(l[0],l[1]):e(l):o(l)}return lc=s,lc}var uc,Fm;function Bm(){if(Fm)return uc;Fm=1;var e=Ug(),t=Nk(),n=En(),r=yt();function o(s,l){var c=r(s)?e:t;return c(s,n(l,3))}return uc=o,uc}var cc,zm;function Kk(){if(zm)return cc;zm=1;var e=Object.prototype,t=e.hasOwnProperty;function n(r,o){return r!=null&&t.call(r,o)}return cc=n,cc}var fc,$m;function Hm(){if($m)return fc;$m=1;var e=Kk(),t=Am();function n(r,o){return r!=null&&t(r,o,e)}return fc=n,fc}var dc,Vm;function Wk(){if(Vm)return dc;Vm=1;var e=bl(),t=mr(),n=ro(),r=yt(),o=On(),s=yr(),l=vi(),c=ao(),f="[object Map]",h="[object Set]",a=Object.prototype,u=a.hasOwnProperty;function d(p){if(p==null)return!0;if(o(p)&&(r(p)||typeof p=="string"||typeof p.splice=="function"||s(p)||c(p)||n(p)))return!p.length;var O=t(p);if(O==f||O==h)return!p.size;if(l(p))return!e(p).length;for(var g in p)if(u.call(p,g))return!1;return!0}return dc=d,dc}var hc,Um;function Gm(){if(Um)return hc;Um=1;function e(t){return t===void 0}return hc=e,hc}var pc,Km;function Wm(){if(Km)return pc;Km=1;var e=yi(),t=On();function n(r,o){var s=-1,l=t(r)?Array(r.length):[];return e(r,function(c,f,h){l[++s]=o(c,f,h)}),l}return pc=n,pc}var vc,Ym;function Zm(){if(Ym)return vc;Ym=1;var e=mi(),t=En(),n=Wm(),r=yt();function o(s,l){var c=r(s)?e:n;return c(s,t(l,3))}return vc=o,vc}var gc,Xm;function Yk(){if(Xm)return gc;Xm=1;function e(t,n,r,o){var s=-1,l=t==null?0:t.length;for(o&&l&&(r=t[++s]);++s<l;)r=n(r,t[s],s,t);return r}return gc=e,gc}var yc,Qm;function Zk(){if(Qm)return yc;Qm=1;function e(t,n,r,o,s){return s(t,function(l,c,f){r=o?(o=!1,l):n(r,l,c,f)}),r}return yc=e,yc}var mc,Jm;function eb(){if(Jm)return mc;Jm=1;var e=Yk(),t=yi(),n=En(),r=Zk(),o=yt();function s(l,c,f){var h=o(l)?e:r,a=arguments.length<3;return h(l,n(c,4),f,a,t)}return mc=s,mc}var bc,tb;function Xk(){if(tb)return bc;tb=1;var e=Wn(),t=yt(),n=fn(),r="[object String]";function o(s){return typeof s=="string"||!t(s)&&n(s)&&e(s)==r}return bc=o,bc}var _c,nb;function Qk(){if(nb)return _c;nb=1;var e=Lm(),t=e("length");return _c=t,_c}var wc,rb;function Jk(){if(rb)return wc;rb=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=t+n+r,s="\\ufe0e\\ufe0f",l="\\u200d",c=RegExp("["+l+e+o+s+"]");function f(h){return c.test(h)}return wc=f,wc}var Oc,ob;function eN(){if(ob)return Oc;ob=1;var e="\\ud800-\\udfff",t="\\u0300-\\u036f",n="\\ufe20-\\ufe2f",r="\\u20d0-\\u20ff",o=t+n+r,s="\\ufe0e\\ufe0f",l="["+e+"]",c="["+o+"]",f="\\ud83c[\\udffb-\\udfff]",h="(?:"+c+"|"+f+")",a="[^"+e+"]",u="(?:\\ud83c[\\udde6-\\uddff]){2}",d="[\\ud800-\\udbff][\\udc00-\\udfff]",p="\\u200d",O=h+"?",g="["+s+"]?",_="(?:"+p+"(?:"+[a,u,d].join("|")+")"+g+O+")*",y=g+O+_,w="(?:"+[a+c+"?",c,u,d,l].join("|")+")",E=RegExp(f+"(?="+f+")|"+w+y,"g");function m(S){for(var C=E.lastIndex=0;E.test(S);)++C;return C}return Oc=m,Oc}var Ec,ib;function tN(){if(ib)return Ec;ib=1;var e=Qk(),t=Jk(),n=eN();function r(o){return t(o)?n(o):e(o)}return Ec=r,Ec}var xc,ab;function nN(){if(ab)return xc;ab=1;var e=bl(),t=mr(),n=On(),r=Xk(),o=tN(),s="[object Map]",l="[object Set]";function c(f){if(f==null)return 0;if(n(f))return r(f)?o(f):f.length;var h=t(f);return h==s||h==l?f.size:e(f).length}return xc=c,xc}var Sc,sb;function rN(){if(sb)return Sc;sb=1;var e=Zs(),t=Ey(),n=vu(),r=En(),o=gi(),s=yt(),l=yr(),c=to(),f=Wt(),h=ao();function a(u,d,p){var O=s(u),g=O||l(u)||h(u);if(d=r(d,4),p==null){var _=u&&u.constructor;g?p=O?new _:[]:f(u)?p=c(_)?t(o(u)):{}:p={}}return(g?e:n)(u,function(y,w,E){return d(p,y,w,E)}),p}return Sc=a,Sc}var kc,lb;function oN(){if(lb)return kc;lb=1;var e=gr(),t=ro(),n=yt(),r=e?e.isConcatSpreadable:void 0;function o(s){return n(s)||t(s)||!!(r&&s&&s[r])}return kc=o,kc}var Nc,ub;function Tc(){if(ub)return Nc;ub=1;var e=ql(),t=oN();function n(r,o,s,l,c){var f=-1,h=r.length;for(s||(s=t),c||(c=[]);++f<h;){var a=r[f];o>0&&s(a)?o>1?n(a,o-1,s,l,c):e(c,a):l||(c[c.length]=a)}return c}return Nc=n,Nc}var Cc,cb;function iN(){if(cb)return Cc;cb=1;function e(t,n,r){switch(r.length){case 0:return t.call(n);case 1:return t.call(n,r[0]);case 2:return t.call(n,r[0],r[1]);case 3:return t.call(n,r[0],r[1],r[2])}return t.apply(n,r)}return Cc=e,Cc}var Ac,fb;function db(){if(fb)return Ac;fb=1;var e=iN(),t=Math.max;function n(r,o,s){return o=t(o===void 0?r.length-1:o,0),function(){for(var l=arguments,c=-1,f=t(l.length-o,0),h=Array(f);++c<f;)h[c]=l[o+c];c=-1;for(var a=Array(o+1);++c<o;)a[c]=l[c];return a[o]=s(h),e(r,this,a)}}return Ac=n,Ac}var Pc,hb;function aN(){if(hb)return Pc;hb=1;var e=cu(),t=ug(),n=Xn(),r=t?function(o,s){return t(o,"toString",{configurable:!0,enumerable:!1,value:e(s),writable:!0})}:n;return Pc=r,Pc}var Ic,pb;function sN(){if(pb)return Ic;pb=1;var e=800,t=16,n=Date.now;function r(o){var s=0,l=0;return function(){var c=n(),f=t-(c-l);if(l=c,f>0){if(++s>=e)return arguments[0]}else s=0;return o.apply(void 0,arguments)}}return Ic=r,Ic}var Mc,vb;function gb(){if(vb)return Mc;vb=1;var e=aN(),t=sN(),n=t(e);return Mc=n,Mc}var qc,yb;function wi(){if(yb)return qc;yb=1;var e=Xn(),t=db(),n=gb();function r(o,s){return n(t(o,s,e),o+"")}return qc=r,qc}var Lc,mb;function bb(){if(mb)return Lc;mb=1;function e(t,n,r,o){for(var s=t.length,l=r+(o?1:-1);o?l--:++l<s;)if(n(t[l],l,t))return l;return-1}return Lc=e,Lc}var Rc,_b;function lN(){if(_b)return Rc;_b=1;function e(t){return t!==t}return Rc=e,Rc}var Dc,wb;function uN(){if(wb)return Dc;wb=1;function e(t,n,r){for(var o=r-1,s=t.length;++o<s;)if(t[o]===n)return o;return-1}return Dc=e,Dc}var jc,Ob;function cN(){if(Ob)return jc;Ob=1;var e=bb(),t=lN(),n=uN();function r(o,s,l){return s===s?n(o,s,l):e(o,t,l)}return jc=r,jc}var Fc,Eb;function fN(){if(Eb)return Fc;Eb=1;var e=cN();function t(n,r){var o=n==null?0:n.length;return!!o&&e(n,r,0)>-1}return Fc=t,Fc}var Bc,xb;function dN(){if(xb)return Bc;xb=1;function e(t,n,r){for(var o=-1,s=t==null?0:t.length;++o<s;)if(r(n,t[o]))return!0;return!1}return Bc=e,Bc}var zc,Sb;function hN(){if(Sb)return zc;Sb=1;function e(){}return zc=e,zc}var $c,kb;function pN(){if(kb)return $c;kb=1;var e=uy(),t=hN(),n=Pu(),r=1/0,o=e&&1/n(new e([,-0]))[1]==r?function(s){return new e(s)}:t;return $c=o,$c}var Hc,Nb;function vN(){if(Nb)return Hc;Nb=1;var e=Zy(),t=fN(),n=dN(),r=Jy(),o=pN(),s=Pu(),l=200;function c(f,h,a){var u=-1,d=t,p=f.length,O=!0,g=[],_=g;if(a)O=!1,d=n;else if(p>=l){var y=h?null:o(f);if(y)return s(y);O=!1,d=r,_=new e}else _=h?[]:g;e:for(;++u<p;){var w=f[u],E=h?h(w):w;if(w=a||w!==0?w:0,O&&E===E){for(var m=_.length;m--;)if(_[m]===E)continue e;h&&_.push(E),g.push(w)}else d(_,E,a)||(_!==g&&_.push(E),g.push(w))}return g}return Hc=c,Hc}var Vc,Tb;function Cb(){if(Tb)return Vc;Tb=1;var e=On(),t=fn();function n(r){return t(r)&&e(r)}return Vc=n,Vc}var Uc,Ab;function gN(){if(Ab)return Uc;Ab=1;var e=Tc(),t=wi(),n=vN(),r=Cb(),o=t(function(s){return n(e(s,1,r,!0))});return Uc=o,Uc}var Gc,Pb;function yN(){if(Pb)return Gc;Pb=1;var e=mi();function t(n,r){return e(r,function(o){return n[o]})}return Gc=t,Gc}var Kc,Ib;function Mb(){if(Ib)return Kc;Ib=1;var e=yN(),t=Ln();function n(r){return r==null?[]:e(r,t(r))}return Kc=n,Kc}var Wc,qb;function Yt(){if(qb)return Wc;qb=1;var e;if(typeof ns=="function")try{e={clone:xk(),constant:cu(),each:Uy(),filter:Bm(),has:Hm(),isArray:yt(),isEmpty:Wk(),isFunction:to(),isUndefined:Gm(),keys:Ln(),map:Zm(),reduce:eb(),size:nN(),transform:rN(),union:gN(),values:Mb()}}catch{}return e||(e=window._),Wc=e,Wc}var Yc,Lb;function Zc(){if(Lb)return Yc;Lb=1;var e=Yt();Yc=o;var t="\0",n="\0",r="";function o(a){this._isDirected=e.has(a,"directed")?a.directed:!0,this._isMultigraph=e.has(a,"multigraph")?a.multigraph:!1,this._isCompound=e.has(a,"compound")?a.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[n]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}o.prototype._nodeCount=0,o.prototype._edgeCount=0,o.prototype.isDirected=function(){return this._isDirected},o.prototype.isMultigraph=function(){return this._isMultigraph},o.prototype.isCompound=function(){return this._isCompound},o.prototype.setGraph=function(a){return this._label=a,this},o.prototype.graph=function(){return this._label},o.prototype.setDefaultNodeLabel=function(a){return e.isFunction(a)||(a=e.constant(a)),this._defaultNodeLabelFn=a,this},o.prototype.nodeCount=function(){return this._nodeCount},o.prototype.nodes=function(){return e.keys(this._nodes)},o.prototype.sources=function(){var a=this;return e.filter(this.nodes(),function(u){return e.isEmpty(a._in[u])})},o.prototype.sinks=function(){var a=this;return e.filter(this.nodes(),function(u){return e.isEmpty(a._out[u])})},o.prototype.setNodes=function(a,u){var d=arguments,p=this;return e.each(a,function(O){d.length>1?p.setNode(O,u):p.setNode(O)}),this},o.prototype.setNode=function(a,u){return e.has(this._nodes,a)?(arguments.length>1&&(this._nodes[a]=u),this):(this._nodes[a]=arguments.length>1?u:this._defaultNodeLabelFn(a),this._isCompound&&(this._parent[a]=n,this._children[a]={},this._children[n][a]=!0),this._in[a]={},this._preds[a]={},this._out[a]={},this._sucs[a]={},++this._nodeCount,this)},o.prototype.node=function(a){return this._nodes[a]},o.prototype.hasNode=function(a){return e.has(this._nodes,a)},o.prototype.removeNode=function(a){var u=this;if(e.has(this._nodes,a)){var d=function(p){u.removeEdge(u._edgeObjs[p])};delete this._nodes[a],this._isCompound&&(this._removeFromParentsChildList(a),delete this._parent[a],e.each(this.children(a),function(p){u.setParent(p)}),delete this._children[a]),e.each(e.keys(this._in[a]),d),delete this._in[a],delete this._preds[a],e.each(e.keys(this._out[a]),d),delete this._out[a],delete this._sucs[a],--this._nodeCount}return this},o.prototype.setParent=function(a,u){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(u))u=n;else{u+="";for(var d=u;!e.isUndefined(d);d=this.parent(d))if(d===a)throw new Error("Setting "+u+" as parent of "+a+" would create a cycle");this.setNode(u)}return this.setNode(a),this._removeFromParentsChildList(a),this._parent[a]=u,this._children[u][a]=!0,this},o.prototype._removeFromParentsChildList=function(a){delete this._children[this._parent[a]][a]},o.prototype.parent=function(a){if(this._isCompound){var u=this._parent[a];if(u!==n)return u}},o.prototype.children=function(a){if(e.isUndefined(a)&&(a=n),this._isCompound){var u=this._children[a];if(u)return e.keys(u)}else{if(a===n)return this.nodes();if(this.hasNode(a))return[]}},o.prototype.predecessors=function(a){var u=this._preds[a];if(u)return e.keys(u)},o.prototype.successors=function(a){var u=this._sucs[a];if(u)return e.keys(u)},o.prototype.neighbors=function(a){var u=this.predecessors(a);if(u)return e.union(u,this.successors(a))},o.prototype.isLeaf=function(a){var u;return this.isDirected()?u=this.successors(a):u=this.neighbors(a),u.length===0},o.prototype.filterNodes=function(a){var u=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});u.setGraph(this.graph());var d=this;e.each(this._nodes,function(g,_){a(_)&&u.setNode(_,g)}),e.each(this._edgeObjs,function(g){u.hasNode(g.v)&&u.hasNode(g.w)&&u.setEdge(g,d.edge(g))});var p={};function O(g){var _=d.parent(g);return _===void 0||u.hasNode(_)?(p[g]=_,_):_ in p?p[_]:O(_)}return this._isCompound&&e.each(u.nodes(),function(g){u.setParent(g,O(g))}),u},o.prototype.setDefaultEdgeLabel=function(a){return e.isFunction(a)||(a=e.constant(a)),this._defaultEdgeLabelFn=a,this},o.prototype.edgeCount=function(){return this._edgeCount},o.prototype.edges=function(){return e.values(this._edgeObjs)},o.prototype.setPath=function(a,u){var d=this,p=arguments;return e.reduce(a,function(O,g){return p.length>1?d.setEdge(O,g,u):d.setEdge(O,g),g}),this},o.prototype.setEdge=function(){var a,u,d,p,O=!1,g=arguments[0];typeof g=="object"&&g!==null&&"v"in g?(a=g.v,u=g.w,d=g.name,arguments.length===2&&(p=arguments[1],O=!0)):(a=g,u=arguments[1],d=arguments[3],arguments.length>2&&(p=arguments[2],O=!0)),a=""+a,u=""+u,e.isUndefined(d)||(d=""+d);var _=c(this._isDirected,a,u,d);if(e.has(this._edgeLabels,_))return O&&(this._edgeLabels[_]=p),this;if(!e.isUndefined(d)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(a),this.setNode(u),this._edgeLabels[_]=O?p:this._defaultEdgeLabelFn(a,u,d);var y=f(this._isDirected,a,u,d);return a=y.v,u=y.w,Object.freeze(y),this._edgeObjs[_]=y,s(this._preds[u],a),s(this._sucs[a],u),this._in[u][_]=y,this._out[a][_]=y,this._edgeCount++,this},o.prototype.edge=function(a,u,d){var p=arguments.length===1?h(this._isDirected,arguments[0]):c(this._isDirected,a,u,d);return this._edgeLabels[p]},o.prototype.hasEdge=function(a,u,d){var p=arguments.length===1?h(this._isDirected,arguments[0]):c(this._isDirected,a,u,d);return e.has(this._edgeLabels,p)},o.prototype.removeEdge=function(a,u,d){var p=arguments.length===1?h(this._isDirected,arguments[0]):c(this._isDirected,a,u,d),O=this._edgeObjs[p];return O&&(a=O.v,u=O.w,delete this._edgeLabels[p],delete this._edgeObjs[p],l(this._preds[u],a),l(this._sucs[a],u),delete this._in[u][p],delete this._out[a][p],this._edgeCount--),this},o.prototype.inEdges=function(a,u){var d=this._in[a];if(d){var p=e.values(d);return u?e.filter(p,function(O){return O.v===u}):p}},o.prototype.outEdges=function(a,u){var d=this._out[a];if(d){var p=e.values(d);return u?e.filter(p,function(O){return O.w===u}):p}},o.prototype.nodeEdges=function(a,u){var d=this.inEdges(a,u);if(d)return d.concat(this.outEdges(a,u))};function s(a,u){a[u]?a[u]++:a[u]=1}function l(a,u){--a[u]||delete a[u]}function c(a,u,d,p){var O=""+u,g=""+d;if(!a&&O>g){var _=O;O=g,g=_}return O+r+g+r+(e.isUndefined(p)?t:p)}function f(a,u,d,p){var O=""+u,g=""+d;if(!a&&O>g){var _=O;O=g,g=_}var y={v:O,w:g};return p&&(y.name=p),y}function h(a,u){return c(a,u.v,u.w,u.name)}return Yc}var Xc,Rb;function mN(){return Rb||(Rb=1,Xc="2.1.8"),Xc}var Qc,Db;function bN(){return Db||(Db=1,Qc={Graph:Zc(),version:mN()}),Qc}var Jc,jb;function _N(){if(jb)return Jc;jb=1;var e=Yt(),t=Zc();Jc={write:n,read:s};function n(l){var c={options:{directed:l.isDirected(),multigraph:l.isMultigraph(),compound:l.isCompound()},nodes:r(l),edges:o(l)};return e.isUndefined(l.graph())||(c.value=e.clone(l.graph())),c}function r(l){return e.map(l.nodes(),function(c){var f=l.node(c),h=l.parent(c),a={v:c};return e.isUndefined(f)||(a.value=f),e.isUndefined(h)||(a.parent=h),a})}function o(l){return e.map(l.edges(),function(c){var f=l.edge(c),h={v:c.v,w:c.w};return e.isUndefined(c.name)||(h.name=c.name),e.isUndefined(f)||(h.value=f),h})}function s(l){var c=new t(l.options).setGraph(l.value);return e.each(l.nodes,function(f){c.setNode(f.v,f.value),f.parent&&c.setParent(f.v,f.parent)}),e.each(l.edges,function(f){c.setEdge({v:f.v,w:f.w,name:f.name},f.value)}),c}return Jc}var ef,Fb;function wN(){if(Fb)return ef;Fb=1;var e=Yt();ef=t;function t(n){var r={},o=[],s;function l(c){e.has(r,c)||(r[c]=!0,s.push(c),e.each(n.successors(c),l),e.each(n.predecessors(c),l))}return e.each(n.nodes(),function(c){s=[],l(c),s.length&&o.push(s)}),o}return ef}var tf,Bb;function zb(){if(Bb)return tf;Bb=1;var e=Yt();tf=t;function t(){this._arr=[],this._keyIndices={}}return t.prototype.size=function(){return this._arr.length},t.prototype.keys=function(){return this._arr.map(function(n){return n.key})},t.prototype.has=function(n){return e.has(this._keyIndices,n)},t.prototype.priority=function(n){var r=this._keyIndices[n];if(r!==void 0)return this._arr[r].priority},t.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},t.prototype.add=function(n,r){var o=this._keyIndices;if(n=String(n),!e.has(o,n)){var s=this._arr,l=s.length;return o[n]=l,s.push({key:n,priority:r}),this._decrease(l),!0}return!1},t.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var n=this._arr.pop();return delete this._keyIndices[n.key],this._heapify(0),n.key},t.prototype.decrease=function(n,r){var o=this._keyIndices[n];if(r>this._arr[o].priority)throw new Error("New priority is greater than current priority. Key: "+n+" Old: "+this._arr[o].priority+" New: "+r);this._arr[o].priority=r,this._decrease(o)},t.prototype._heapify=function(n){var r=this._arr,o=2*n,s=o+1,l=n;o<r.length&&(l=r[o].priority<r[l].priority?o:l,s<r.length&&(l=r[s].priority<r[l].priority?s:l),l!==n&&(this._swap(n,l),this._heapify(l)))},t.prototype._decrease=function(n){for(var r=this._arr,o=r[n].priority,s;n!==0&&(s=n>>1,!(r[s].priority<o));)this._swap(n,s),n=s},t.prototype._swap=function(n,r){var o=this._arr,s=this._keyIndices,l=o[n],c=o[r];o[n]=c,o[r]=l,s[c.key]=n,s[l.key]=r},tf}var nf,$b;function Hb(){if($b)return nf;$b=1;var e=Yt(),t=zb();nf=r;var n=e.constant(1);function r(s,l,c,f){return o(s,String(l),c||n,f||function(h){return s.outEdges(h)})}function o(s,l,c,f){var h={},a=new t,u,d,p=function(O){var g=O.v!==u?O.v:O.w,_=h[g],y=c(O),w=d.distance+y;if(y<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+O+" Weight: "+y);w<_.distance&&(_.distance=w,_.predecessor=u,a.decrease(g,w))};for(s.nodes().forEach(function(O){var g=O===l?0:Number.POSITIVE_INFINITY;h[O]={distance:g},a.add(O,g)});a.size()>0&&(u=a.removeMin(),d=h[u],d.distance!==Number.POSITIVE_INFINITY);)f(u).forEach(p);return h}return nf}var rf,Vb;function ON(){if(Vb)return rf;Vb=1;var e=Hb(),t=Yt();rf=n;function n(r,o,s){return t.transform(r.nodes(),function(l,c){l[c]=e(r,c,o,s)},{})}return rf}var of,Ub;function Gb(){if(Ub)return of;Ub=1;var e=Yt();of=t;function t(n){var r=0,o=[],s={},l=[];function c(f){var h=s[f]={onStack:!0,lowlink:r,index:r++};if(o.push(f),n.successors(f).forEach(function(d){e.has(s,d)?s[d].onStack&&(h.lowlink=Math.min(h.lowlink,s[d].index)):(c(d),h.lowlink=Math.min(h.lowlink,s[d].lowlink))}),h.lowlink===h.index){var a=[],u;do u=o.pop(),s[u].onStack=!1,a.push(u);while(f!==u);l.push(a)}}return n.nodes().forEach(function(f){e.has(s,f)||c(f)}),l}return of}var af,Kb;function EN(){if(Kb)return af;Kb=1;var e=Yt(),t=Gb();af=n;function n(r){return e.filter(t(r),function(o){return o.length>1||o.length===1&&r.hasEdge(o[0],o[0])})}return af}var sf,Wb;function xN(){if(Wb)return sf;Wb=1;var e=Yt();sf=n;var t=e.constant(1);function n(o,s,l){return r(o,s||t,l||function(c){return o.outEdges(c)})}function r(o,s,l){var c={},f=o.nodes();return f.forEach(function(h){c[h]={},c[h][h]={distance:0},f.forEach(function(a){h!==a&&(c[h][a]={distance:Number.POSITIVE_INFINITY})}),l(h).forEach(function(a){var u=a.v===h?a.w:a.v,d=s(a);c[h][u]={distance:d,predecessor:h}})}),f.forEach(function(h){var a=c[h];f.forEach(function(u){var d=c[u];f.forEach(function(p){var O=d[h],g=a[p],_=d[p],y=O.distance+g.distance;y<_.distance&&(_.distance=y,_.predecessor=g.predecessor)})})}),c}return sf}var lf,Yb;function Zb(){if(Yb)return lf;Yb=1;var e=Yt();lf=t,t.CycleException=n;function t(r){var o={},s={},l=[];function c(f){if(e.has(s,f))throw new n;e.has(o,f)||(s[f]=!0,o[f]=!0,e.each(r.predecessors(f),c),delete s[f],l.push(f))}if(e.each(r.sinks(),c),e.size(o)!==r.nodeCount())throw new n;return l}function n(){}return n.prototype=new Error,lf}var uf,Xb;function SN(){if(Xb)return uf;Xb=1;var e=Zb();uf=t;function t(n){try{e(n)}catch(r){if(r instanceof e.CycleException)return!1;throw r}return!0}return uf}var cf,Qb;function Jb(){if(Qb)return cf;Qb=1;var e=Yt();cf=t;function t(r,o,s){e.isArray(o)||(o=[o]);var l=(r.isDirected()?r.successors:r.neighbors).bind(r),c=[],f={};return e.each(o,function(h){if(!r.hasNode(h))throw new Error("Graph does not have node: "+h);n(r,h,s==="post",f,l,c)}),c}function n(r,o,s,l,c,f){e.has(l,o)||(l[o]=!0,s||f.push(o),e.each(c(o),function(h){n(r,h,s,l,c,f)}),s&&f.push(o))}return cf}var ff,e0;function kN(){if(e0)return ff;e0=1;var e=Jb();ff=t;function t(n,r){return e(n,r,"post")}return ff}var df,t0;function NN(){if(t0)return df;t0=1;var e=Jb();df=t;function t(n,r){return e(n,r,"pre")}return df}var hf,n0;function TN(){if(n0)return hf;n0=1;var e=Yt(),t=Zc(),n=zb();hf=r;function r(o,s){var l=new t,c={},f=new n,h;function a(d){var p=d.v===h?d.w:d.v,O=f.priority(p);if(O!==void 0){var g=s(d);g<O&&(c[p]=h,f.decrease(p,g))}}if(o.nodeCount()===0)return l;e.each(o.nodes(),function(d){f.add(d,Number.POSITIVE_INFINITY),l.setNode(d)}),f.decrease(o.nodes()[0],0);for(var u=!1;f.size()>0;){if(h=f.removeMin(),e.has(c,h))l.setEdge(h,c[h]);else{if(u)throw new Error("Input graph is not connected: "+o);u=!0}o.nodeEdges(h).forEach(a)}return l}return hf}var pf,r0;function CN(){return r0||(r0=1,pf={components:wN(),dijkstra:Hb(),dijkstraAll:ON(),findCycles:EN(),floydWarshall:xN(),isAcyclic:SN(),postorder:kN(),preorder:NN(),prim:TN(),tarjan:Gb(),topsort:Zb()}),pf}var vf,o0;function AN(){if(o0)return vf;o0=1;var e=bN();return vf={Graph:e.Graph,json:_N(),alg:CN(),version:e.version},vf}var gf,i0;function on(){if(i0)return gf;i0=1;var e;if(typeof ns=="function")try{e=AN()}catch{}return e||(e=window.graphlib),gf=e,gf}var yf,a0;function PN(){if(a0)return yf;a0=1;var e=Py(),t=1,n=4;function r(o){return e(o,t|n)}return yf=r,yf}var mf,s0;function Oi(){if(s0)return mf;s0=1;var e=vr(),t=On(),n=hi(),r=Wt();function o(s,l,c){if(!r(c))return!1;var f=typeof l;return(f=="number"?t(c)&&n(l,c.length):f=="string"&&l in c)?e(c[l],s):!1}return mf=o,mf}var bf,l0;function IN(){if(l0)return bf;l0=1;var e=wi(),t=vr(),n=Oi(),r=Zn(),o=Object.prototype,s=o.hasOwnProperty,l=e(function(c,f){c=Object(c);var h=-1,a=f.length,u=a>2?f[2]:void 0;for(u&&n(f[0],f[1],u)&&(a=1);++h<a;)for(var d=f[h],p=r(d),O=-1,g=p.length;++O<g;){var _=p[O],y=c[_];(y===void 0||t(y,o[_])&&!s.call(c,_))&&(c[_]=d[_])}return c});return bf=l,bf}var _f,u0;function MN(){if(u0)return _f;u0=1;var e=En(),t=On(),n=Ln();function r(o){return function(s,l,c){var f=Object(s);if(!t(s)){var h=e(l,3);s=n(s),l=function(u){return h(f[u],u,f)}}var a=o(s,l,c);return a>-1?f[h?s[a]:a]:void 0}}return _f=r,_f}var wf,c0;function qN(){if(c0)return wf;c0=1;var e=/\s/;function t(n){for(var r=n.length;r--&&e.test(n.charAt(r)););return r}return wf=t,wf}var Of,f0;function LN(){if(f0)return Of;f0=1;var e=qN(),t=/^\s+/;function n(r){return r&&r.slice(0,e(r)+1).replace(t,"")}return Of=n,Of}var Ef,d0;function RN(){if(d0)return Ef;d0=1;var e=LN(),t=Wt(),n=br(),r=NaN,o=/^[-+]0x[0-9a-f]+$/i,s=/^0b[01]+$/i,l=/^0o[0-7]+$/i,c=parseInt;function f(h){if(typeof h=="number")return h;if(n(h))return r;if(t(h)){var a=typeof h.valueOf=="function"?h.valueOf():h;h=t(a)?a+"":a}if(typeof h!="string")return h===0?h:+h;h=e(h);var u=s.test(h);return u||l.test(h)?c(h.slice(2),u?2:8):o.test(h)?r:+h}return Ef=f,Ef}var xf,h0;function p0(){if(h0)return xf;h0=1;var e=RN(),t=1/0,n=17976931348623157e292;function r(o){if(!o)return o===0?o:0;if(o=e(o),o===t||o===-t){var s=o<0?-1:1;return s*n}return o===o?o:0}return xf=r,xf}var Sf,v0;function DN(){if(v0)return Sf;v0=1;var e=p0();function t(n){var r=e(n),o=r%1;return r===r?o?r-o:r:0}return Sf=t,Sf}var kf,g0;function jN(){if(g0)return kf;g0=1;var e=bb(),t=En(),n=DN(),r=Math.max;function o(s,l,c){var f=s==null?0:s.length;if(!f)return-1;var h=c==null?0:n(c);return h<0&&(h=r(f+h,0)),e(s,t(l,3),h)}return kf=o,kf}var Nf,y0;function FN(){if(y0)return Nf;y0=1;var e=MN(),t=jN(),n=e(t);return Nf=n,Nf}var Tf,m0;function b0(){if(m0)return Tf;m0=1;var e=Tc();function t(n){var r=n==null?0:n.length;return r?e(n,1):[]}return Tf=t,Tf}var Cf,_0;function BN(){if(_0)return Cf;_0=1;var e=hu(),t=zy(),n=Zn();function r(o,s){return o==null?o:e(o,t(s),n)}return Cf=r,Cf}var Af,w0;function zN(){if(w0)return Af;w0=1;function e(t){var n=t==null?0:t.length;return n?t[n-1]:void 0}return Af=e,Af}var Pf,O0;function $N(){if(O0)return Pf;O0=1;var e=fi(),t=vu(),n=En();function r(o,s){var l={};return s=n(s,3),t(o,function(c,f,h){e(l,f,s(c,f,h))}),l}return Pf=r,Pf}var If,E0;function Mf(){if(E0)return If;E0=1;var e=br();function t(n,r,o){for(var s=-1,l=n.length;++s<l;){var c=n[s],f=r(c);if(f!=null&&(h===void 0?f===f&&!e(f):o(f,h)))var h=f,a=c}return a}return If=t,If}var qf,x0;function HN(){if(x0)return qf;x0=1;function e(t,n){return t>n}return qf=e,qf}var Lf,S0;function VN(){if(S0)return Lf;S0=1;var e=Mf(),t=HN(),n=Xn();function r(o){return o&&o.length?e(o,n,t):void 0}return Lf=r,Lf}var Rf,k0;function N0(){if(k0)return Rf;k0=1;var e=fi(),t=vr();function n(r,o,s){(s!==void 0&&!t(r[o],s)||s===void 0&&!(o in r))&&e(r,o,s)}return Rf=n,Rf}var Df,T0;function UN(){if(T0)return Df;T0=1;var e=Wn(),t=gi(),n=fn(),r="[object Object]",o=Function.prototype,s=Object.prototype,l=o.toString,c=s.hasOwnProperty,f=l.call(Object);function h(a){if(!n(a)||e(a)!=r)return!1;var u=t(a);if(u===null)return!0;var d=c.call(u,"constructor")&&u.constructor;return typeof d=="function"&&d instanceof d&&l.call(d)==f}return Df=h,Df}var jf,C0;function A0(){if(C0)return jf;C0=1;function e(t,n){if(!(n==="constructor"&&typeof t[n]=="function")&&n!="__proto__")return t[n]}return jf=e,jf}var Ff,P0;function GN(){if(P0)return Ff;P0=1;var e=no(),t=Zn();function n(r){return e(r,t(r))}return Ff=n,Ff}var Bf,I0;function KN(){if(I0)return Bf;I0=1;var e=N0(),t=zg(),n=_y(),r=Hg(),o=Sy(),s=ro(),l=yt(),c=Cb(),f=yr(),h=to(),a=Wt(),u=UN(),d=ao(),p=A0(),O=GN();function g(_,y,w,E,m,S,C){var N=p(_,w),M=p(y,w),j=C.get(M);if(j){e(_,w,j);return}var I=S?S(N,M,w+"",_,y,C):void 0,A=I===void 0;if(A){var q=l(M),R=!q&&f(M),k=!q&&!R&&d(M);I=M,q||R||k?l(N)?I=N:c(N)?I=r(N):R?(A=!1,I=t(M,!0)):k?(A=!1,I=n(M,!0)):I=[]:u(M)||s(M)?(I=N,s(N)?I=O(N):(!a(N)||h(N))&&(I=o(M))):A=!1}A&&(C.set(M,I),m(I,M,E,S,C),C.delete(M)),e(_,w,I)}return Bf=g,Bf}var zf,M0;function WN(){if(M0)return zf;M0=1;var e=ci(),t=N0(),n=hu(),r=KN(),o=Wt(),s=Zn(),l=A0();function c(f,h,a,u,d){f!==h&&n(h,function(p,O){if(d||(d=new e),o(p))r(f,h,O,a,c,u,d);else{var g=u?u(l(f,O),p,O+"",f,h,d):void 0;g===void 0&&(g=p),t(f,O,g)}},s)}return zf=c,zf}var $f,q0;function YN(){if(q0)return $f;q0=1;var e=wi(),t=Oi();function n(r){return e(function(o,s){var l=-1,c=s.length,f=c>1?s[c-1]:void 0,h=c>2?s[2]:void 0;for(f=r.length>3&&typeof f=="function"?(c--,f):void 0,h&&t(s[0],s[1],h)&&(f=c<3?void 0:f,c=1),o=Object(o);++l<c;){var a=s[l];a&&r(o,a,l,f)}return o})}return $f=n,$f}var Hf,L0;function ZN(){if(L0)return Hf;L0=1;var e=WN(),t=YN(),n=t(function(r,o,s){e(r,o,s)});return Hf=n,Hf}var Vf,R0;function D0(){if(R0)return Vf;R0=1;function e(t,n){return t<n}return Vf=e,Vf}var Uf,j0;function XN(){if(j0)return Uf;j0=1;var e=Mf(),t=D0(),n=Xn();function r(o){return o&&o.length?e(o,n,t):void 0}return Uf=r,Uf}var Gf,F0;function QN(){if(F0)return Gf;F0=1;var e=Mf(),t=En(),n=D0();function r(o,s){return o&&o.length?e(o,t(s,2),n):void 0}return Gf=r,Gf}var Kf,B0;function JN(){if(B0)return Kf;B0=1;var e=rn(),t=function(){return e.Date.now()};return Kf=t,Kf}var Wf,z0;function e2(){if(z0)return Wf;z0=1;var e=di(),t=bi(),n=hi(),r=Wt(),o=lo();function s(l,c,f,h){if(!r(l))return l;c=t(c,l);for(var a=-1,u=c.length,d=u-1,p=l;p!=null&&++a<u;){var O=o(c[a]),g=f;if(O==="__proto__"||O==="constructor"||O==="prototype")return l;if(a!=d){var _=p[O];g=h?h(_,O,p):void 0,g===void 0&&(g=r(_)?_:n(c[a+1])?[]:{})}e(p,O,g),p=p[O]}return l}return Wf=s,Wf}var Yf,$0;function t2(){if($0)return Yf;$0=1;var e=_i(),t=e2(),n=bi();function r(o,s,l){for(var c=-1,f=s.length,h={};++c<f;){var a=s[c],u=e(o,a);l(u,a)&&t(h,n(a,o),u)}return h}return Yf=r,Yf}var Zf,H0;function n2(){if(H0)return Zf;H0=1;var e=t2(),t=Im();function n(r,o){return e(r,o,function(s,l){return t(r,l)})}return Zf=n,Zf}var Xf,V0;function r2(){if(V0)return Xf;V0=1;var e=b0(),t=db(),n=gb();function r(o){return n(t(o,void 0,e),o+"")}return Xf=r,Xf}var Qf,U0;function o2(){if(U0)return Qf;U0=1;var e=n2(),t=r2(),n=t(function(r,o){return r==null?{}:e(r,o)});return Qf=n,Qf}var Jf,G0;function i2(){if(G0)return Jf;G0=1;var e=Math.ceil,t=Math.max;function n(r,o,s,l){for(var c=-1,f=t(e((o-r)/(s||1)),0),h=Array(f);f--;)h[l?f:++c]=r,r+=s;return h}return Jf=n,Jf}var ed,K0;function a2(){if(K0)return ed;K0=1;var e=i2(),t=Oi(),n=p0();function r(o){return function(s,l,c){return c&&typeof c!="number"&&t(s,l,c)&&(l=c=void 0),s=n(s),l===void 0?(l=s,s=0):l=n(l),c=c===void 0?s<l?1:-1:n(c),e(s,l,c,o)}}return ed=r,ed}var td,W0;function s2(){if(W0)return td;W0=1;var e=a2(),t=e();return td=t,td}var nd,Y0;function l2(){if(Y0)return nd;Y0=1;function e(t,n){var r=t.length;for(t.sort(n);r--;)t[r]=t[r].value;return t}return nd=e,nd}var rd,Z0;function u2(){if(Z0)return rd;Z0=1;var e=br();function t(n,r){if(n!==r){var o=n!==void 0,s=n===null,l=n===n,c=e(n),f=r!==void 0,h=r===null,a=r===r,u=e(r);if(!h&&!u&&!c&&n>r||c&&f&&a&&!h&&!u||s&&f&&a||!o&&a||!l)return 1;if(!s&&!c&&!u&&n<r||u&&o&&l&&!s&&!c||h&&o&&l||!f&&l||!a)return-1}return 0}return rd=t,rd}var od,X0;function c2(){if(X0)return od;X0=1;var e=u2();function t(n,r,o){for(var s=-1,l=n.criteria,c=r.criteria,f=l.length,h=o.length;++s<f;){var a=e(l[s],c[s]);if(a){if(s>=h)return a;var u=o[s];return a*(u=="desc"?-1:1)}}return n.index-r.index}return od=t,od}var id,Q0;function f2(){if(Q0)return id;Q0=1;var e=mi(),t=_i(),n=En(),r=Wm(),o=l2(),s=pi(),l=c2(),c=Xn(),f=yt();function h(a,u,d){u.length?u=e(u,function(g){return f(g)?function(_){return t(_,g.length===1?g[0]:g)}:g}):u=[c];var p=-1;u=e(u,s(n));var O=r(a,function(g,_,y){var w=e(u,function(E){return E(g)});return{criteria:w,index:++p,value:g}});return o(O,function(g,_){return l(g,_,d)})}return id=h,id}var ad,J0;function d2(){if(J0)return ad;J0=1;var e=Tc(),t=f2(),n=wi(),r=Oi(),o=n(function(s,l){if(s==null)return[];var c=l.length;return c>1&&r(s,l[0],l[1])?l=[]:c>2&&r(l[0],l[1],l[2])&&(l=[l[0]]),t(s,e(l,1),[])});return ad=o,ad}var sd,e1;function h2(){if(e1)return sd;e1=1;var e=Em(),t=0;function n(r){var o=++t;return e(r)+o}return sd=n,sd}var ld,t1;function p2(){if(t1)return ld;t1=1;function e(t,n,r){for(var o=-1,s=t.length,l=n.length,c={};++o<s;){var f=o<l?n[o]:void 0;r(c,t[o],f)}return c}return ld=e,ld}var ud,n1;function v2(){if(n1)return ud;n1=1;var e=di(),t=p2();function n(r,o){return t(r||[],o||[],e)}return ud=n,ud}var cd,r1;function ft(){if(r1)return cd;r1=1;var e;if(typeof ns=="function")try{e={cloneDeep:PN(),constant:cu(),defaults:IN(),each:Uy(),filter:Bm(),find:FN(),flatten:b0(),forEach:Hy(),forIn:BN(),has:Hm(),isUndefined:Gm(),last:zN(),map:Zm(),mapValues:$N(),max:VN(),merge:ZN(),min:XN(),minBy:QN(),now:JN(),pick:o2(),range:s2(),reduce:eb(),sortBy:d2(),uniqueId:h2(),values:Mb(),zipObject:v2()}}catch{}return e||(e=window._),cd=e,cd}var fd,o1;function g2(){if(o1)return fd;o1=1,fd=e;function e(){var r={};r._next=r._prev=r,this._sentinel=r}e.prototype.dequeue=function(){var r=this._sentinel,o=r._prev;if(o!==r)return t(o),o},e.prototype.enqueue=function(r){var o=this._sentinel;r._prev&&r._next&&t(r),r._next=o._next,o._next._prev=r,o._next=r,r._prev=o},e.prototype.toString=function(){for(var r=[],o=this._sentinel,s=o._prev;s!==o;)r.push(JSON.stringify(s,n)),s=s._prev;return"["+r.join(", ")+"]"};function t(r){r._prev._next=r._next,r._next._prev=r._prev,delete r._next,delete r._prev}function n(r,o){if(r!=="_next"&&r!=="_prev")return o}return fd}var dd,i1;function y2(){if(i1)return dd;i1=1;var e=ft(),t=on().Graph,n=g2();dd=o;var r=e.constant(1);function o(h,a){if(h.nodeCount()<=1)return[];var u=c(h,a||r),d=s(u.graph,u.buckets,u.zeroIdx);return e.flatten(e.map(d,function(p){return h.outEdges(p.v,p.w)}),!0)}function s(h,a,u){for(var d=[],p=a[a.length-1],O=a[0],g;h.nodeCount();){for(;g=O.dequeue();)l(h,a,u,g);for(;g=p.dequeue();)l(h,a,u,g);if(h.nodeCount()){for(var _=a.length-2;_>0;--_)if(g=a[_].dequeue(),g){d=d.concat(l(h,a,u,g,!0));break}}}return d}function l(h,a,u,d,p){var O=p?[]:void 0;return e.forEach(h.inEdges(d.v),function(g){var _=h.edge(g),y=h.node(g.v);p&&O.push({v:g.v,w:g.w}),y.out-=_,f(a,u,y)}),e.forEach(h.outEdges(d.v),function(g){var _=h.edge(g),y=g.w,w=h.node(y);w.in-=_,f(a,u,w)}),h.removeNode(d.v),O}function c(h,a){var u=new t,d=0,p=0;e.forEach(h.nodes(),function(_){u.setNode(_,{v:_,in:0,out:0})}),e.forEach(h.edges(),function(_){var y=u.edge(_.v,_.w)||0,w=a(_),E=y+w;u.setEdge(_.v,_.w,E),p=Math.max(p,u.node(_.v).out+=w),d=Math.max(d,u.node(_.w).in+=w)});var O=e.range(p+d+3).map(function(){return new n}),g=d+1;return e.forEach(u.nodes(),function(_){f(O,g,u.node(_))}),{graph:u,buckets:O,zeroIdx:g}}function f(h,a,u){u.out?u.in?h[u.out-u.in+a].enqueue(u):h[h.length-1].enqueue(u):h[0].enqueue(u)}return dd}var hd,a1;function m2(){if(a1)return hd;a1=1;var e=ft(),t=y2();hd={run:n,undo:o};function n(s){var l=s.graph().acyclicer==="greedy"?t(s,c(s)):r(s);e.forEach(l,function(f){var h=s.edge(f);s.removeEdge(f),h.forwardName=f.name,h.reversed=!0,s.setEdge(f.w,f.v,h,e.uniqueId("rev"))});function c(f){return function(h){return f.edge(h).weight}}}function r(s){var l=[],c={},f={};function h(a){e.has(f,a)||(f[a]=!0,c[a]=!0,e.forEach(s.outEdges(a),function(u){e.has(c,u.w)?l.push(u):h(u.w)}),delete c[a])}return e.forEach(s.nodes(),h),l}function o(s){e.forEach(s.edges(),function(l){var c=s.edge(l);if(c.reversed){s.removeEdge(l);var f=c.forwardName;delete c.reversed,delete c.forwardName,s.setEdge(l.w,l.v,c,f)}})}return hd}var pd,s1;function Rt(){if(s1)return pd;s1=1;var e=ft(),t=on().Graph;pd={addDummyNode:n,simplify:r,asNonCompoundGraph:o,successorWeights:s,predecessorWeights:l,intersectRect:c,buildLayerMatrix:f,normalizeRanks:h,removeEmptyRanks:a,addBorderNode:u,maxRank:d,partition:p,time:O,notime:g};function n(_,y,w,E){var m;do m=e.uniqueId(E);while(_.hasNode(m));return w.dummy=y,_.setNode(m,w),m}function r(_){var y=new t().setGraph(_.graph());return e.forEach(_.nodes(),function(w){y.setNode(w,_.node(w))}),e.forEach(_.edges(),function(w){var E=y.edge(w.v,w.w)||{weight:0,minlen:1},m=_.edge(w);y.setEdge(w.v,w.w,{weight:E.weight+m.weight,minlen:Math.max(E.minlen,m.minlen)})}),y}function o(_){var y=new t({multigraph:_.isMultigraph()}).setGraph(_.graph());return e.forEach(_.nodes(),function(w){_.children(w).length||y.setNode(w,_.node(w))}),e.forEach(_.edges(),function(w){y.setEdge(w,_.edge(w))}),y}function s(_){var y=e.map(_.nodes(),function(w){var E={};return e.forEach(_.outEdges(w),function(m){E[m.w]=(E[m.w]||0)+_.edge(m).weight}),E});return e.zipObject(_.nodes(),y)}function l(_){var y=e.map(_.nodes(),function(w){var E={};return e.forEach(_.inEdges(w),function(m){E[m.v]=(E[m.v]||0)+_.edge(m).weight}),E});return e.zipObject(_.nodes(),y)}function c(_,y){var w=_.x,E=_.y,m=y.x-w,S=y.y-E,C=_.width/2,N=_.height/2;if(!m&&!S)throw new Error("Not possible to find intersection inside of the rectangle");var M,j;return Math.abs(S)*C>Math.abs(m)*N?(S<0&&(N=-N),M=N*m/S,j=N):(m<0&&(C=-C),M=C,j=C*S/m),{x:w+M,y:E+j}}function f(_){var y=e.map(e.range(d(_)+1),function(){return[]});return e.forEach(_.nodes(),function(w){var E=_.node(w),m=E.rank;e.isUndefined(m)||(y[m][E.order]=w)}),y}function h(_){var y=e.min(e.map(_.nodes(),function(w){return _.node(w).rank}));e.forEach(_.nodes(),function(w){var E=_.node(w);e.has(E,"rank")&&(E.rank-=y)})}function a(_){var y=e.min(e.map(_.nodes(),function(S){return _.node(S).rank})),w=[];e.forEach(_.nodes(),function(S){var C=_.node(S).rank-y;w[C]||(w[C]=[]),w[C].push(S)});var E=0,m=_.graph().nodeRankFactor;e.forEach(w,function(S,C){e.isUndefined(S)&&C%m!==0?--E:E&&e.forEach(S,function(N){_.node(N).rank+=E})})}function u(_,y,w,E){var m={width:0,height:0};return arguments.length>=4&&(m.rank=w,m.order=E),n(_,"border",m,y)}function d(_){return e.max(e.map(_.nodes(),function(y){var w=_.node(y).rank;if(!e.isUndefined(w))return w}))}function p(_,y){var w={lhs:[],rhs:[]};return e.forEach(_,function(E){y(E)?w.lhs.push(E):w.rhs.push(E)}),w}function O(_,y){var w=e.now();try{return y()}finally{console.log(_+" time: "+(e.now()-w)+"ms")}}function g(_,y){return y()}return pd}var vd,l1;function b2(){if(l1)return vd;l1=1;var e=ft(),t=Rt();vd={run:n,undo:o};function n(s){s.graph().dummyChains=[],e.forEach(s.edges(),function(l){r(s,l)})}function r(s,l){var c=l.v,f=s.node(c).rank,h=l.w,a=s.node(h).rank,u=l.name,d=s.edge(l),p=d.labelRank;if(a!==f+1){s.removeEdge(l);var O,g,_;for(_=0,++f;f<a;++_,++f)d.points=[],g={width:0,height:0,edgeLabel:d,edgeObj:l,rank:f},O=t.addDummyNode(s,"edge",g,"_d"),f===p&&(g.width=d.width,g.height=d.height,g.dummy="edge-label",g.labelpos=d.labelpos),s.setEdge(c,O,{weight:d.weight},u),_===0&&s.graph().dummyChains.push(O),c=O;s.setEdge(c,h,{weight:d.weight},u)}}function o(s){e.forEach(s.graph().dummyChains,function(l){var c=s.node(l),f=c.edgeLabel,h;for(s.setEdge(c.edgeObj,f);c.dummy;)h=s.successors(l)[0],s.removeNode(l),f.points.push({x:c.x,y:c.y}),c.dummy==="edge-label"&&(f.x=c.x,f.y=c.y,f.width=c.width,f.height=c.height),l=h,c=s.node(l)})}return vd}var gd,u1;function Ei(){if(u1)return gd;u1=1;var e=ft();gd={longestPath:t,slack:n};function t(r){var o={};function s(l){var c=r.node(l);if(e.has(o,l))return c.rank;o[l]=!0;var f=e.min(e.map(r.outEdges(l),function(h){return s(h.w)-r.edge(h).minlen}));return(f===Number.POSITIVE_INFINITY||f===void 0||f===null)&&(f=0),c.rank=f}e.forEach(r.sources(),s)}function n(r,o){return r.node(o.w).rank-r.node(o.v).rank-r.edge(o).minlen}return gd}var yd,c1;function f1(){if(c1)return yd;c1=1;var e=ft(),t=on().Graph,n=Ei().slack;yd=r;function r(c){var f=new t({directed:!1}),h=c.nodes()[0],a=c.nodeCount();f.setNode(h,{});for(var u,d;o(f,c)<a;)u=s(f,c),d=f.hasNode(u.v)?n(c,u):-n(c,u),l(f,c,d);return f}function o(c,f){function h(a){e.forEach(f.nodeEdges(a),function(u){var d=u.v,p=a===d?u.w:d;!c.hasNode(p)&&!n(f,u)&&(c.setNode(p,{}),c.setEdge(a,p,{}),h(p))})}return e.forEach(c.nodes(),h),c.nodeCount()}function s(c,f){return e.minBy(f.edges(),function(h){if(c.hasNode(h.v)!==c.hasNode(h.w))return n(f,h)})}function l(c,f,h){e.forEach(c.nodes(),function(a){f.node(a).rank+=h})}return yd}var md,d1;function _2(){if(d1)return md;d1=1;var e=ft(),t=f1(),n=Ei().slack,r=Ei().longestPath,o=on().alg.preorder,s=on().alg.postorder,l=Rt().simplify;md=c,c.initLowLimValues=u,c.initCutValues=f,c.calcCutValue=a,c.leaveEdge=p,c.enterEdge=O,c.exchangeEdges=g;function c(E){E=l(E),r(E);var m=t(E);u(m),f(m,E);for(var S,C;S=p(m);)C=O(m,E,S),g(m,E,S,C)}function f(E,m){var S=s(E,E.nodes());S=S.slice(0,S.length-1),e.forEach(S,function(C){h(E,m,C)})}function h(E,m,S){var C=E.node(S),N=C.parent;E.edge(S,N).cutvalue=a(E,m,S)}function a(E,m,S){var C=E.node(S),N=C.parent,M=!0,j=m.edge(S,N),I=0;return j||(M=!1,j=m.edge(N,S)),I=j.weight,e.forEach(m.nodeEdges(S),function(A){var q=A.v===S,R=q?A.w:A.v;if(R!==N){var k=q===M,F=m.edge(A).weight;if(I+=k?F:-F,y(E,S,R)){var U=E.edge(S,R).cutvalue;I+=k?-U:U}}}),I}function u(E,m){arguments.length<2&&(m=E.nodes()[0]),d(E,{},1,m)}function d(E,m,S,C,N){var M=S,j=E.node(C);return m[C]=!0,e.forEach(E.neighbors(C),function(I){e.has(m,I)||(S=d(E,m,S,I,C))}),j.low=M,j.lim=S++,N?j.parent=N:delete j.parent,S}function p(E){return e.find(E.edges(),function(m){return E.edge(m).cutvalue<0})}function O(E,m,S){var C=S.v,N=S.w;m.hasEdge(C,N)||(C=S.w,N=S.v);var M=E.node(C),j=E.node(N),I=M,A=!1;M.lim>j.lim&&(I=j,A=!0);var q=e.filter(m.edges(),function(R){return A===w(E,E.node(R.v),I)&&A!==w(E,E.node(R.w),I)});return e.minBy(q,function(R){return n(m,R)})}function g(E,m,S,C){var N=S.v,M=S.w;E.removeEdge(N,M),E.setEdge(C.v,C.w,{}),u(E),f(E,m),_(E,m)}function _(E,m){var S=e.find(E.nodes(),function(N){return!m.node(N).parent}),C=o(E,S);C=C.slice(1),e.forEach(C,function(N){var M=E.node(N).parent,j=m.edge(N,M),I=!1;j||(j=m.edge(M,N),I=!0),m.node(N).rank=m.node(M).rank+(I?j.minlen:-j.minlen)})}function y(E,m,S){return E.hasEdge(m,S)}function w(E,m,S){return S.low<=m.lim&&m.lim<=S.lim}return md}var bd,h1;function w2(){if(h1)return bd;h1=1;var e=Ei(),t=e.longestPath,n=f1(),r=_2();bd=o;function o(f){switch(f.graph().ranker){case"network-simplex":c(f);break;case"tight-tree":l(f);break;case"longest-path":s(f);break;default:c(f)}}var s=t;function l(f){t(f),n(f)}function c(f){r(f)}return bd}var _d,p1;function O2(){if(p1)return _d;p1=1;var e=ft();_d=t;function t(o){var s=r(o);e.forEach(o.graph().dummyChains,function(l){for(var c=o.node(l),f=c.edgeObj,h=n(o,s,f.v,f.w),a=h.path,u=h.lca,d=0,p=a[d],O=!0;l!==f.w;){if(c=o.node(l),O){for(;(p=a[d])!==u&&o.node(p).maxRank<c.rank;)d++;p===u&&(O=!1)}if(!O){for(;d<a.length-1&&o.node(p=a[d+1]).minRank<=c.rank;)d++;p=a[d]}o.setParent(l,p),l=o.successors(l)[0]}})}function n(o,s,l,c){var f=[],h=[],a=Math.min(s[l].low,s[c].low),u=Math.max(s[l].lim,s[c].lim),d,p;d=l;do d=o.parent(d),f.push(d);while(d&&(s[d].low>a||u>s[d].lim));for(p=d,d=c;(d=o.parent(d))!==p;)h.push(d);return{path:f.concat(h.reverse()),lca:p}}function r(o){var s={},l=0;function c(f){var h=l;e.forEach(o.children(f),c),s[f]={low:h,lim:l++}}return e.forEach(o.children(),c),s}return _d}var wd,v1;function E2(){if(v1)return wd;v1=1;var e=ft(),t=Rt();wd={run:n,cleanup:l};function n(c){var f=t.addDummyNode(c,"root",{},"_root"),h=o(c),a=e.max(e.values(h))-1,u=2*a+1;c.graph().nestingRoot=f,e.forEach(c.edges(),function(p){c.edge(p).minlen*=u});var d=s(c)+1;e.forEach(c.children(),function(p){r(c,f,u,d,a,h,p)}),c.graph().nodeRankFactor=u}function r(c,f,h,a,u,d,p){var O=c.children(p);if(!O.length){p!==f&&c.setEdge(f,p,{weight:0,minlen:h});return}var g=t.addBorderNode(c,"_bt"),_=t.addBorderNode(c,"_bb"),y=c.node(p);c.setParent(g,p),y.borderTop=g,c.setParent(_,p),y.borderBottom=_,e.forEach(O,function(w){r(c,f,h,a,u,d,w);var E=c.node(w),m=E.borderTop?E.borderTop:w,S=E.borderBottom?E.borderBottom:w,C=E.borderTop?a:2*a,N=m!==S?1:u-d[p]+1;c.setEdge(g,m,{weight:C,minlen:N,nestingEdge:!0}),c.setEdge(S,_,{weight:C,minlen:N,nestingEdge:!0})}),c.parent(p)||c.setEdge(f,g,{weight:0,minlen:u+d[p]})}function o(c){var f={};function h(a,u){var d=c.children(a);d&&d.length&&e.forEach(d,function(p){h(p,u+1)}),f[a]=u}return e.forEach(c.children(),function(a){h(a,1)}),f}function s(c){return e.reduce(c.edges(),function(f,h){return f+c.edge(h).weight},0)}function l(c){var f=c.graph();c.removeNode(f.nestingRoot),delete f.nestingRoot,e.forEach(c.edges(),function(h){var a=c.edge(h);a.nestingEdge&&c.removeEdge(h)})}return wd}var Od,g1;function x2(){if(g1)return Od;g1=1;var e=ft(),t=Rt();Od=n;function n(o){function s(l){var c=o.children(l),f=o.node(l);if(c.length&&e.forEach(c,s),e.has(f,"minRank")){f.borderLeft=[],f.borderRight=[];for(var h=f.minRank,a=f.maxRank+1;h<a;++h)r(o,"borderLeft","_bl",l,f,h),r(o,"borderRight","_br",l,f,h)}}e.forEach(o.children(),s)}function r(o,s,l,c,f,h){var a={width:0,height:0,rank:h,borderType:s},u=f[s][h-1],d=t.addDummyNode(o,"border",a,l);f[s][h]=d,o.setParent(d,c),u&&o.setEdge(u,d,{weight:1})}return Od}var Ed,y1;function S2(){if(y1)return Ed;y1=1;var e=ft();Ed={adjust:t,undo:n};function t(h){var a=h.graph().rankdir.toLowerCase();(a==="lr"||a==="rl")&&r(h)}function n(h){var a=h.graph().rankdir.toLowerCase();(a==="bt"||a==="rl")&&s(h),(a==="lr"||a==="rl")&&(c(h),r(h))}function r(h){e.forEach(h.nodes(),function(a){o(h.node(a))}),e.forEach(h.edges(),function(a){o(h.edge(a))})}function o(h){var a=h.width;h.width=h.height,h.height=a}function s(h){e.forEach(h.nodes(),function(a){l(h.node(a))}),e.forEach(h.edges(),function(a){var u=h.edge(a);e.forEach(u.points,l),e.has(u,"y")&&l(u)})}function l(h){h.y=-h.y}function c(h){e.forEach(h.nodes(),function(a){f(h.node(a))}),e.forEach(h.edges(),function(a){var u=h.edge(a);e.forEach(u.points,f),e.has(u,"x")&&f(u)})}function f(h){var a=h.x;h.x=h.y,h.y=a}return Ed}var xd,m1;function k2(){if(m1)return xd;m1=1;var e=ft();xd=t;function t(n){var r={},o=e.filter(n.nodes(),function(h){return!n.children(h).length}),s=e.max(e.map(o,function(h){return n.node(h).rank})),l=e.map(e.range(s+1),function(){return[]});function c(h){if(!e.has(r,h)){r[h]=!0;var a=n.node(h);l[a.rank].push(h),e.forEach(n.successors(h),c)}}var f=e.sortBy(o,function(h){return n.node(h).rank});return e.forEach(f,c),l}return xd}var Sd,b1;function N2(){if(b1)return Sd;b1=1;var e=ft();Sd=t;function t(r,o){for(var s=0,l=1;l<o.length;++l)s+=n(r,o[l-1],o[l]);return s}function n(r,o,s){for(var l=e.zipObject(s,e.map(s,function(d,p){return p})),c=e.flatten(e.map(o,function(d){return e.sortBy(e.map(r.outEdges(d),function(p){return{pos:l[p.w],weight:r.edge(p).weight}}),"pos")}),!0),f=1;f<s.length;)f<<=1;var h=2*f-1;f-=1;var a=e.map(new Array(h),function(){return 0}),u=0;return e.forEach(c.forEach(function(d){var p=d.pos+f;a[p]+=d.weight;for(var O=0;p>0;)p%2&&(O+=a[p+1]),p=p-1>>1,a[p]+=d.weight;u+=d.weight*O})),u}return Sd}var kd,_1;function T2(){if(_1)return kd;_1=1;var e=ft();kd=t;function t(n,r){return e.map(r,function(o){var s=n.inEdges(o);if(s.length){var l=e.reduce(s,function(c,f){var h=n.edge(f),a=n.node(f.v);return{sum:c.sum+h.weight*a.order,weight:c.weight+h.weight}},{sum:0,weight:0});return{v:o,barycenter:l.sum/l.weight,weight:l.weight}}else return{v:o}})}return kd}var Nd,w1;function C2(){if(w1)return Nd;w1=1;var e=ft();Nd=t;function t(o,s){var l={};e.forEach(o,function(f,h){var a=l[f.v]={indegree:0,in:[],out:[],vs:[f.v],i:h};e.isUndefined(f.barycenter)||(a.barycenter=f.barycenter,a.weight=f.weight)}),e.forEach(s.edges(),function(f){var h=l[f.v],a=l[f.w];!e.isUndefined(h)&&!e.isUndefined(a)&&(a.indegree++,h.out.push(l[f.w]))});var c=e.filter(l,function(f){return!f.indegree});return n(c)}function n(o){var s=[];function l(h){return function(a){a.merged||(e.isUndefined(a.barycenter)||e.isUndefined(h.barycenter)||a.barycenter>=h.barycenter)&&r(h,a)}}function c(h){return function(a){a.in.push(h),--a.indegree===0&&o.push(a)}}for(;o.length;){var f=o.pop();s.push(f),e.forEach(f.in.reverse(),l(f)),e.forEach(f.out,c(f))}return e.map(e.filter(s,function(h){return!h.merged}),function(h){return e.pick(h,["vs","i","barycenter","weight"])})}function r(o,s){var l=0,c=0;o.weight&&(l+=o.barycenter*o.weight,c+=o.weight),s.weight&&(l+=s.barycenter*s.weight,c+=s.weight),o.vs=s.vs.concat(o.vs),o.barycenter=l/c,o.weight=c,o.i=Math.min(s.i,o.i),s.merged=!0}return Nd}var Td,O1;function A2(){if(O1)return Td;O1=1;var e=ft(),t=Rt();Td=n;function n(s,l){var c=t.partition(s,function(g){return e.has(g,"barycenter")}),f=c.lhs,h=e.sortBy(c.rhs,function(g){return-g.i}),a=[],u=0,d=0,p=0;f.sort(o(!!l)),p=r(a,h,p),e.forEach(f,function(g){p+=g.vs.length,a.push(g.vs),u+=g.barycenter*g.weight,d+=g.weight,p=r(a,h,p)});var O={vs:e.flatten(a,!0)};return d&&(O.barycenter=u/d,O.weight=d),O}function r(s,l,c){for(var f;l.length&&(f=e.last(l)).i<=c;)l.pop(),s.push(f.vs),c++;return c}function o(s){return function(l,c){return l.barycenter<c.barycenter?-1:l.barycenter>c.barycenter?1:s?c.i-l.i:l.i-c.i}}return Td}var Cd,E1;function P2(){if(E1)return Cd;E1=1;var e=ft(),t=T2(),n=C2(),r=A2();Cd=o;function o(c,f,h,a){var u=c.children(f),d=c.node(f),p=d?d.borderLeft:void 0,O=d?d.borderRight:void 0,g={};p&&(u=e.filter(u,function(S){return S!==p&&S!==O}));var _=t(c,u);e.forEach(_,function(S){if(c.children(S.v).length){var C=o(c,S.v,h,a);g[S.v]=C,e.has(C,"barycenter")&&l(S,C)}});var y=n(_,h);s(y,g);var w=r(y,a);if(p&&(w.vs=e.flatten([p,w.vs,O],!0),c.predecessors(p).length)){var E=c.node(c.predecessors(p)[0]),m=c.node(c.predecessors(O)[0]);e.has(w,"barycenter")||(w.barycenter=0,w.weight=0),w.barycenter=(w.barycenter*w.weight+E.order+m.order)/(w.weight+2),w.weight+=2}return w}function s(c,f){e.forEach(c,function(h){h.vs=e.flatten(h.vs.map(function(a){return f[a]?f[a].vs:a}),!0)})}function l(c,f){e.isUndefined(c.barycenter)?(c.barycenter=f.barycenter,c.weight=f.weight):(c.barycenter=(c.barycenter*c.weight+f.barycenter*f.weight)/(c.weight+f.weight),c.weight+=f.weight)}return Cd}var Ad,x1;function I2(){if(x1)return Ad;x1=1;var e=ft(),t=on().Graph;Ad=n;function n(o,s,l){var c=r(o),f=new t({compound:!0}).setGraph({root:c}).setDefaultNodeLabel(function(h){return o.node(h)});return e.forEach(o.nodes(),function(h){var a=o.node(h),u=o.parent(h);(a.rank===s||a.minRank<=s&&s<=a.maxRank)&&(f.setNode(h),f.setParent(h,u||c),e.forEach(o[l](h),function(d){var p=d.v===h?d.w:d.v,O=f.edge(p,h),g=e.isUndefined(O)?0:O.weight;f.setEdge(p,h,{weight:o.edge(d).weight+g})}),e.has(a,"minRank")&&f.setNode(h,{borderLeft:a.borderLeft[s],borderRight:a.borderRight[s]}))}),f}function r(o){for(var s;o.hasNode(s=e.uniqueId("_root")););return s}return Ad}var Pd,S1;function M2(){if(S1)return Pd;S1=1;var e=ft();Pd=t;function t(n,r,o){var s={},l;e.forEach(o,function(c){for(var f=n.parent(c),h,a;f;){if(h=n.parent(f),h?(a=s[h],s[h]=f):(a=l,l=f),a&&a!==f){r.setEdge(a,f);return}f=h}})}return Pd}var Id,k1;function q2(){if(k1)return Id;k1=1;var e=ft(),t=k2(),n=N2(),r=P2(),o=I2(),s=M2(),l=on().Graph,c=Rt();Id=f;function f(d){var p=c.maxRank(d),O=h(d,e.range(1,p+1),"inEdges"),g=h(d,e.range(p-1,-1,-1),"outEdges"),_=t(d);u(d,_);for(var y=Number.POSITIVE_INFINITY,w,E=0,m=0;m<4;++E,++m){a(E%2?O:g,E%4>=2),_=c.buildLayerMatrix(d);var S=n(d,_);S<y&&(m=0,w=e.cloneDeep(_),y=S)}u(d,w)}function h(d,p,O){return e.map(p,function(g){return o(d,g,O)})}function a(d,p){var O=new l;e.forEach(d,function(g){var _=g.graph().root,y=r(g,_,O,p);e.forEach(y.vs,function(w,E){g.node(w).order=E}),s(g,O,y.vs)})}function u(d,p){e.forEach(p,function(O){e.forEach(O,function(g,_){d.node(g).order=_})})}return Id}var Md,N1;function L2(){if(N1)return Md;N1=1;var e=ft(),t=on().Graph,n=Rt();Md={positionX:O,findType1Conflicts:r,findType2Conflicts:o,addConflict:l,hasConflict:c,verticalAlignment:f,horizontalCompaction:h,alignCoordinates:d,findSmallestWidthAlignment:u,balance:p};function r(y,w){var E={};function m(S,C){var N=0,M=0,j=S.length,I=e.last(C);return e.forEach(C,function(A,q){var R=s(y,A),k=R?y.node(R).order:j;(R||A===I)&&(e.forEach(C.slice(M,q+1),function(F){e.forEach(y.predecessors(F),function(U){var ne=y.node(U),ue=ne.order;(ue<N||k<ue)&&!(ne.dummy&&y.node(F).dummy)&&l(E,U,F)})}),M=q+1,N=k)}),C}return e.reduce(w,m),E}function o(y,w){var E={};function m(C,N,M,j,I){var A;e.forEach(e.range(N,M),function(q){A=C[q],y.node(A).dummy&&e.forEach(y.predecessors(A),function(R){var k=y.node(R);k.dummy&&(k.order<j||k.order>I)&&l(E,R,A)})})}function S(C,N){var M=-1,j,I=0;return e.forEach(N,function(A,q){if(y.node(A).dummy==="border"){var R=y.predecessors(A);R.length&&(j=y.node(R[0]).order,m(N,I,q,M,j),I=q,M=j)}m(N,I,N.length,j,C.length)}),N}return e.reduce(w,S),E}function s(y,w){if(y.node(w).dummy)return e.find(y.predecessors(w),function(E){return y.node(E).dummy})}function l(y,w,E){if(w>E){var m=w;w=E,E=m}var S=y[w];S||(y[w]=S={}),S[E]=!0}function c(y,w,E){if(w>E){var m=w;w=E,E=m}return e.has(y[w],E)}function f(y,w,E,m){var S={},C={},N={};return e.forEach(w,function(M){e.forEach(M,function(j,I){S[j]=j,C[j]=j,N[j]=I})}),e.forEach(w,function(M){var j=-1;e.forEach(M,function(I){var A=m(I);if(A.length){A=e.sortBy(A,function(U){return N[U]});for(var q=(A.length-1)/2,R=Math.floor(q),k=Math.ceil(q);R<=k;++R){var F=A[R];C[I]===I&&j<N[F]&&!c(E,I,F)&&(C[F]=I,C[I]=S[I]=S[F],j=N[F])}}})}),{root:S,align:C}}function h(y,w,E,m,S){var C={},N=a(y,w,E,S),M=S?"borderLeft":"borderRight";function j(q,R){for(var k=N.nodes(),F=k.pop(),U={};F;)U[F]?q(F):(U[F]=!0,k.push(F),k=k.concat(R(F))),F=k.pop()}function I(q){C[q]=N.inEdges(q).reduce(function(R,k){return Math.max(R,C[k.v]+N.edge(k))},0)}function A(q){var R=N.outEdges(q).reduce(function(F,U){return Math.min(F,C[U.w]-N.edge(U))},Number.POSITIVE_INFINITY),k=y.node(q);R!==Number.POSITIVE_INFINITY&&k.borderType!==M&&(C[q]=Math.max(C[q],R))}return j(I,N.predecessors.bind(N)),j(A,N.successors.bind(N)),e.forEach(m,function(q){C[q]=C[E[q]]}),C}function a(y,w,E,m){var S=new t,C=y.graph(),N=g(C.nodesep,C.edgesep,m);return e.forEach(w,function(M){var j;e.forEach(M,function(I){var A=E[I];if(S.setNode(A),j){var q=E[j],R=S.edge(q,A);S.setEdge(q,A,Math.max(N(y,I,j),R||0))}j=I})}),S}function u(y,w){return e.minBy(e.values(w),function(E){var m=Number.NEGATIVE_INFINITY,S=Number.POSITIVE_INFINITY;return e.forIn(E,function(C,N){var M=_(y,N)/2;m=Math.max(C+M,m),S=Math.min(C-M,S)}),m-S})}function d(y,w){var E=e.values(w),m=e.min(E),S=e.max(E);e.forEach(["u","d"],function(C){e.forEach(["l","r"],function(N){var M=C+N,j=y[M],I;if(j!==w){var A=e.values(j);I=N==="l"?m-e.min(A):S-e.max(A),I&&(y[M]=e.mapValues(j,function(q){return q+I}))}})})}function p(y,w){return e.mapValues(y.ul,function(E,m){if(w)return y[w.toLowerCase()][m];var S=e.sortBy(e.map(y,m));return(S[1]+S[2])/2})}function O(y){var w=n.buildLayerMatrix(y),E=e.merge(r(y,w),o(y,w)),m={},S;e.forEach(["u","d"],function(N){S=N==="u"?w:e.values(w).reverse(),e.forEach(["l","r"],function(M){M==="r"&&(S=e.map(S,function(q){return e.values(q).reverse()}));var j=(N==="u"?y.predecessors:y.successors).bind(y),I=f(y,S,E,j),A=h(y,S,I.root,I.align,M==="r");M==="r"&&(A=e.mapValues(A,function(q){return-q})),m[N+M]=A})});var C=u(y,m);return d(m,C),p(m,y.graph().align)}function g(y,w,E){return function(m,S,C){var N=m.node(S),M=m.node(C),j=0,I;if(j+=N.width/2,e.has(N,"labelpos"))switch(N.labelpos.toLowerCase()){case"l":I=-N.width/2;break;case"r":I=N.width/2;break}if(I&&(j+=E?I:-I),I=0,j+=(N.dummy?w:y)/2,j+=(M.dummy?w:y)/2,j+=M.width/2,e.has(M,"labelpos"))switch(M.labelpos.toLowerCase()){case"l":I=M.width/2;break;case"r":I=-M.width/2;break}return I&&(j+=E?I:-I),I=0,j}}function _(y,w){return y.node(w).width}return Md}var qd,T1;function R2(){if(T1)return qd;T1=1;var e=ft(),t=Rt(),n=L2().positionX;qd=r;function r(s){s=t.asNonCompoundGraph(s),o(s),e.forEach(n(s),function(l,c){s.node(c).x=l})}function o(s){var l=t.buildLayerMatrix(s),c=s.graph().ranksep,f=0;e.forEach(l,function(h){var a=e.max(e.map(h,function(u){return s.node(u).height}));e.forEach(h,function(u){s.node(u).y=f+a/2}),f+=a+c})}return qd}var Ld,C1;function D2(){if(C1)return Ld;C1=1;var e=ft(),t=m2(),n=b2(),r=w2(),o=Rt().normalizeRanks,s=O2(),l=Rt().removeEmptyRanks,c=E2(),f=x2(),h=S2(),a=q2(),u=R2(),d=Rt(),p=on().Graph;Ld=O;function O(Z,X){var H=X&&X.debugTiming?d.time:d.notime;H("layout",function(){var ee=H(" buildLayoutGraph",function(){return j(Z)});H(" runLayout",function(){g(ee,H)}),H(" updateInputGraph",function(){_(Z,ee)})})}function g(Z,X){X(" makeSpaceForEdgeLabels",function(){I(Z)}),X(" removeSelfEdges",function(){K(Z)}),X(" acyclic",function(){t.run(Z)}),X(" nestingGraph.run",function(){c.run(Z)}),X(" rank",function(){r(d.asNonCompoundGraph(Z))}),X(" injectEdgeLabelProxies",function(){A(Z)}),X(" removeEmptyRanks",function(){l(Z)}),X(" nestingGraph.cleanup",function(){c.cleanup(Z)}),X(" normalizeRanks",function(){o(Z)}),X(" assignRankMinMax",function(){q(Z)}),X(" removeEdgeLabelProxies",function(){R(Z)}),X(" normalize.run",function(){n.run(Z)}),X(" parentDummyChains",function(){s(Z)}),X(" addBorderSegments",function(){f(Z)}),X(" order",function(){a(Z)}),X(" insertSelfEdges",function(){W(Z)}),X(" adjustCoordinateSystem",function(){h.adjust(Z)}),X(" position",function(){u(Z)}),X(" positionSelfEdges",function(){z(Z)}),X(" removeBorderNodes",function(){ue(Z)}),X(" normalize.undo",function(){n.undo(Z)}),X(" fixupEdgeLabelCoords",function(){U(Z)}),X(" undoCoordinateSystem",function(){h.undo(Z)}),X(" translateGraph",function(){k(Z)}),X(" assignNodeIntersects",function(){F(Z)}),X(" reversePoints",function(){ne(Z)}),X(" acyclic.undo",function(){t.undo(Z)})}function _(Z,X){e.forEach(Z.nodes(),function(H){var ee=Z.node(H),le=X.node(H);ee&&(ee.x=le.x,ee.y=le.y,X.children(H).length&&(ee.width=le.width,ee.height=le.height))}),e.forEach(Z.edges(),function(H){var ee=Z.edge(H),le=X.edge(H);ee.points=le.points,e.has(le,"x")&&(ee.x=le.x,ee.y=le.y)}),Z.graph().width=X.graph().width,Z.graph().height=X.graph().height}var y=["nodesep","edgesep","ranksep","marginx","marginy"],w={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},E=["acyclicer","ranker","rankdir","align"],m=["width","height"],S={width:0,height:0},C=["minlen","weight","width","height","labeloffset"],N={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},M=["labelpos"];function j(Z){var X=new p({multigraph:!0,compound:!0}),H=re(Z.graph());return X.setGraph(e.merge({},w,Q(H,y),e.pick(H,E))),e.forEach(Z.nodes(),function(ee){var le=re(Z.node(ee));X.setNode(ee,e.defaults(Q(le,m),S)),X.setParent(ee,Z.parent(ee))}),e.forEach(Z.edges(),function(ee){var le=re(Z.edge(ee));X.setEdge(ee,e.merge({},N,Q(le,C),e.pick(le,M)))}),X}function I(Z){var X=Z.graph();X.ranksep/=2,e.forEach(Z.edges(),function(H){var ee=Z.edge(H);ee.minlen*=2,ee.labelpos.toLowerCase()!=="c"&&(X.rankdir==="TB"||X.rankdir==="BT"?ee.width+=ee.labeloffset:ee.height+=ee.labeloffset)})}function A(Z){e.forEach(Z.edges(),function(X){var H=Z.edge(X);if(H.width&&H.height){var ee=Z.node(X.v),le=Z.node(X.w),de={rank:(le.rank-ee.rank)/2+ee.rank,e:X};d.addDummyNode(Z,"edge-proxy",de,"_ep")}})}function q(Z){var X=0;e.forEach(Z.nodes(),function(H){var ee=Z.node(H);ee.borderTop&&(ee.minRank=Z.node(ee.borderTop).rank,ee.maxRank=Z.node(ee.borderBottom).rank,X=e.max(X,ee.maxRank))}),Z.graph().maxRank=X}function R(Z){e.forEach(Z.nodes(),function(X){var H=Z.node(X);H.dummy==="edge-proxy"&&(Z.edge(H.e).labelRank=H.rank,Z.removeNode(X))})}function k(Z){var X=Number.POSITIVE_INFINITY,H=0,ee=Number.POSITIVE_INFINITY,le=0,de=Z.graph(),pe=de.marginx||0,Ee=de.marginy||0;function Ie(Pe){var Ae=Pe.x,Se=Pe.y,Ge=Pe.width,Oe=Pe.height;X=Math.min(X,Ae-Ge/2),H=Math.max(H,Ae+Ge/2),ee=Math.min(ee,Se-Oe/2),le=Math.max(le,Se+Oe/2)}e.forEach(Z.nodes(),function(Pe){Ie(Z.node(Pe))}),e.forEach(Z.edges(),function(Pe){var Ae=Z.edge(Pe);e.has(Ae,"x")&&Ie(Ae)}),X-=pe,ee-=Ee,e.forEach(Z.nodes(),function(Pe){var Ae=Z.node(Pe);Ae.x-=X,Ae.y-=ee}),e.forEach(Z.edges(),function(Pe){var Ae=Z.edge(Pe);e.forEach(Ae.points,function(Se){Se.x-=X,Se.y-=ee}),e.has(Ae,"x")&&(Ae.x-=X),e.has(Ae,"y")&&(Ae.y-=ee)}),de.width=H-X+pe,de.height=le-ee+Ee}function F(Z){e.forEach(Z.edges(),function(X){var H=Z.edge(X),ee=Z.node(X.v),le=Z.node(X.w),de,pe;H.points?(de=H.points[0],pe=H.points[H.points.length-1]):(H.points=[],de=le,pe=ee),H.points.unshift(d.intersectRect(ee,de)),H.points.push(d.intersectRect(le,pe))})}function U(Z){e.forEach(Z.edges(),function(X){var H=Z.edge(X);if(e.has(H,"x"))switch((H.labelpos==="l"||H.labelpos==="r")&&(H.width-=H.labeloffset),H.labelpos){case"l":H.x-=H.width/2+H.labeloffset;break;case"r":H.x+=H.width/2+H.labeloffset;break}})}function ne(Z){e.forEach(Z.edges(),function(X){var H=Z.edge(X);H.reversed&&H.points.reverse()})}function ue(Z){e.forEach(Z.nodes(),function(X){if(Z.children(X).length){var H=Z.node(X),ee=Z.node(H.borderTop),le=Z.node(H.borderBottom),de=Z.node(e.last(H.borderLeft)),pe=Z.node(e.last(H.borderRight));H.width=Math.abs(pe.x-de.x),H.height=Math.abs(le.y-ee.y),H.x=de.x+H.width/2,H.y=ee.y+H.height/2}}),e.forEach(Z.nodes(),function(X){Z.node(X).dummy==="border"&&Z.removeNode(X)})}function K(Z){e.forEach(Z.edges(),function(X){if(X.v===X.w){var H=Z.node(X.v);H.selfEdges||(H.selfEdges=[]),H.selfEdges.push({e:X,label:Z.edge(X)}),Z.removeEdge(X)}})}function W(Z){var X=d.buildLayerMatrix(Z);e.forEach(X,function(H){var ee=0;e.forEach(H,function(le,de){var pe=Z.node(le);pe.order=de+ee,e.forEach(pe.selfEdges,function(Ee){d.addDummyNode(Z,"selfedge",{width:Ee.label.width,height:Ee.label.height,rank:pe.rank,order:de+ ++ee,e:Ee.e,label:Ee.label},"_se")}),delete pe.selfEdges})})}function z(Z){e.forEach(Z.nodes(),function(X){var H=Z.node(X);if(H.dummy==="selfedge"){var ee=Z.node(H.e.v),le=ee.x+ee.width/2,de=ee.y,pe=H.x-le,Ee=ee.height/2;Z.setEdge(H.e,H.label),Z.removeNode(X),H.label.points=[{x:le+2*pe/3,y:de-Ee},{x:le+5*pe/6,y:de-Ee},{x:le+pe,y:de},{x:le+5*pe/6,y:de+Ee},{x:le+2*pe/3,y:de+Ee}],H.label.x=H.x,H.label.y=H.y}})}function Q(Z,X){return e.mapValues(e.pick(Z,X),Number)}function re(Z){var X={};return e.forEach(Z,function(H,ee){X[ee.toLowerCase()]=H}),X}return Ld}var Rd,A1;function j2(){if(A1)return Rd;A1=1;var e=ft(),t=Rt(),n=on().Graph;Rd={debugOrdering:r};function r(o){var s=t.buildLayerMatrix(o),l=new n({compound:!0,multigraph:!0}).setGraph({});return e.forEach(o.nodes(),function(c){l.setNode(c,{label:c}),l.setParent(c,"layer"+o.node(c).rank)}),e.forEach(o.edges(),function(c){l.setEdge(c.v,c.w,{},c.name)}),e.forEach(s,function(c,f){var h="layer"+f;l.setNode(h,{rank:"same"}),e.reduce(c,function(a,u){return l.setEdge(a,u,{style:"invis"}),u})}),l}return Rd}var Dd,P1;function F2(){return P1||(P1=1,Dd="0.8.5"),Dd}var jd,I1;function B2(){return I1||(I1=1,jd={graphlib:on(),layout:D2(),debug:j2(),util:{time:Rt().time,notime:Rt().notime},version:F2()}),jd}var z2=B2();const uo=ts(z2);function _r(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function xn(e){return function t(n){return arguments.length===0||_r(n)?t:e.apply(this,arguments)}}function M1(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return _r(n)?t:xn(function(o){return e(n,o)});default:return _r(n)&&_r(r)?t:_r(n)?xn(function(o){return e(o,r)}):_r(r)?xn(function(o){return e(n,o)}):e(n,r)}}}const $2=Array.isArray||function(t){return t!=null&&t.length>=0&&Object.prototype.toString.call(t)==="[object Array]"};function H2(e){return Object.prototype.toString.call(e)==="[object String]"}function xi(e,t){return Object.prototype.hasOwnProperty.call(t,e)}var q1=Object.prototype.toString,L1=(function(){return q1.call(arguments)==="[object Arguments]"?function(t){return q1.call(t)==="[object Arguments]"}:function(t){return xi("callee",t)}})(),V2=!{toString:null}.propertyIsEnumerable("toString"),R1=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],D1=(function(){return arguments.propertyIsEnumerable("length")})(),U2=function(t,n){for(var r=0;r<t.length;){if(t[r]===n)return!0;r+=1}return!1},j1=xn(typeof Object.keys=="function"&&!D1?function(t){return Object(t)!==t?[]:Object.keys(t)}:function(t){if(Object(t)!==t)return[];var n,r,o=[],s=D1&&L1(t);for(n in t)xi(n,t)&&(!s||n!=="length")&&(o[o.length]=n);if(V2)for(r=R1.length-1;r>=0;)n=R1[r],xi(n,t)&&!U2(o,n)&&(o[o.length]=n),r-=1;return o}),dn=xn(function(t){return t==null}),F1=xn(function(t){return t===null?"Null":t===void 0?"Undefined":Object.prototype.toString.call(t).slice(8,-1)});function B1(e){for(var t=[],n;!(n=e.next()).done;)t.push(n.value);return t}function z1(e,t,n){for(var r=0,o=n.length;r<o;){if(e(t,n[r]))return!0;r+=1}return!1}function G2(e){var t=String(e).match(/^function (\w*)/);return t==null?"":t[1]}function K2(e,t){return e===t?e!==0||1/e===1/t:e!==e&&t!==t}const Fd=typeof Object.is=="function"?Object.is:K2;function $1(e,t,n,r){var o=B1(e),s=B1(t);function l(c,f){return Bd(c,f,n.slice(),r.slice())}return!z1(function(c,f){return!z1(l,f,c)},s,o)}function Bd(e,t,n,r){if(Fd(e,t))return!0;var o=F1(e);if(o!==F1(t)||e==null||t==null)return!1;if(typeof e["fantasy-land/equals"]=="function"||typeof t["fantasy-land/equals"]=="function")return typeof e["fantasy-land/equals"]=="function"&&e["fantasy-land/equals"](t)&&typeof t["fantasy-land/equals"]=="function"&&t["fantasy-land/equals"](e);if(typeof e.equals=="function"||typeof t.equals=="function")return typeof e.equals=="function"&&e.equals(t)&&typeof t.equals=="function"&&t.equals(e);switch(o){case"Arguments":case"Array":case"Object":if(typeof e.constructor=="function"&&G2(e.constructor)==="Promise")return e===t;break;case"Boolean":case"Number":case"String":if(!(typeof e==typeof t&&Fd(e.valueOf(),t.valueOf())))return!1;break;case"Date":if(!Fd(e.valueOf(),t.valueOf()))return!1;break;case"Error":return e.name===t.name&&e.message===t.message;case"RegExp":if(!(e.source===t.source&&e.global===t.global&&e.ignoreCase===t.ignoreCase&&e.multiline===t.multiline&&e.sticky===t.sticky&&e.unicode===t.unicode))return!1;break}for(var s=n.length-1;s>=0;){if(n[s]===e)return r[s]===t;s-=1}switch(o){case"Map":return e.size!==t.size?!1:$1(e.entries(),t.entries(),n.concat([e]),r.concat([t]));case"Set":return e.size!==t.size?!1:$1(e.values(),t.values(),n.concat([e]),r.concat([t]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var l=j1(e);if(l.length!==j1(t).length)return!1;var c=n.concat([e]),f=r.concat([t]);for(s=l.length-1;s>=0;){var h=l[s];if(!(xi(h,t)&&Bd(t[h],e[h],c,f)))return!1;s-=1}return!0}var W2=M1(function(t,n){return Bd(t,n,[],[])});function Y2(e){return Object.prototype.toString.call(e)==="[object Object]"}var Z2=xn(function(t){return t!=null&&typeof t["fantasy-land/empty"]=="function"?t["fantasy-land/empty"]():t!=null&&t.constructor!=null&&typeof t.constructor["fantasy-land/empty"]=="function"?t.constructor["fantasy-land/empty"]():t!=null&&typeof t.empty=="function"?t.empty():t!=null&&t.constructor!=null&&typeof t.constructor.empty=="function"?t.constructor.empty():$2(t)?[]:H2(t)?"":Y2(t)?{}:L1(t)?(function(){return arguments})():void 0}),bt=xn(function(t){return t!=null&&W2(t,Z2(t))}),H1=M1(function(t,n){for(var r={},o={},s=0,l=t.length;s<l;)o[t[s]]=1,s+=1;for(var c in n)o.hasOwnProperty(c)||(r[c]=n[c]);return r});function Tt(e){if(typeof e=="string"||typeof e=="number")return""+e;let t="";if(Array.isArray(e))for(let n=0,r;n<e.length;n++)(r=Tt(e[n]))!==""&&(t+=(t&&" ")+r);else for(let n in e)e[n]&&(t+=(t&&" ")+n);return t}var zd={exports:{}},$d={},Hd={exports:{}},Vd={};/**
|
|
1
|
+
(function(It,K){typeof exports=="object"&&typeof module<"u"?K(exports,require("react/jsx-runtime"),require("react"),require("react-dom"),require("react-router-dom")):typeof define=="function"&&define.amd?define(["exports","react/jsx-runtime","react","react-dom","react-router-dom"],K):(It=typeof globalThis<"u"?globalThis:It||self,K(It["hise-flow-graphs"]={},It.require$$2,It.React,It.ReactDOM,It.require$$1))})(this,(function(It,K,he,ZN,QN){"use strict";const rs=e=>e&&typeof e=="object"&&"default"in e?e:{default:e},JN=rs(K),wt=rs(he),uy=rs(ZN),$N=rs(QN);var os=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Iu(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Mu(e){throw new Error('Could not dynamically require "'+e+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var ju,cy;function eT(){if(cy)return ju;cy=1;function e(){this.__data__=[],this.size=0}return ju=e,ju}var Lu,fy;function Do(){if(fy)return Lu;fy=1;function e(n,r){return n===r||n!==n&&r!==r}return Lu=e,Lu}var Du,dy;function is(){if(dy)return Du;dy=1;var e=Do();function n(r,o){for(var i=r.length;i--;)if(e(r[i][0],o))return i;return-1}return Du=n,Du}var Bu,hy;function tT(){if(hy)return Bu;hy=1;var e=is(),n=Array.prototype,r=n.splice;function o(i){var l=this.__data__,c=e(l,i);if(c<0)return!1;var f=l.length-1;return c==f?l.pop():r.call(l,c,1),--this.size,!0}return Bu=o,Bu}var Fu,py;function nT(){if(py)return Fu;py=1;var e=is();function n(r){var o=this.__data__,i=e(o,r);return i<0?void 0:o[i][1]}return Fu=n,Fu}var qu,my;function rT(){if(my)return qu;my=1;var e=is();function n(r){return e(this.__data__,r)>-1}return qu=n,qu}var zu,gy;function oT(){if(gy)return zu;gy=1;var e=is();function n(r,o){var i=this.__data__,l=e(i,r);return l<0?(++this.size,i.push([r,o])):i[l][1]=o,this}return zu=n,zu}var Hu,vy;function as(){if(vy)return Hu;vy=1;var e=eT(),n=tT(),r=nT(),o=rT(),i=oT();function l(c){var f=-1,m=c==null?0:c.length;for(this.clear();++f<m;){var g=c[f];this.set(g[0],g[1])}}return l.prototype.clear=e,l.prototype.delete=n,l.prototype.get=r,l.prototype.has=o,l.prototype.set=i,Hu=l,Hu}var Vu,yy;function iT(){if(yy)return Vu;yy=1;var e=as();function n(){this.__data__=new e,this.size=0}return Vu=n,Vu}var Uu,by;function aT(){if(by)return Uu;by=1;function e(n){var r=this.__data__,o=r.delete(n);return this.size=r.size,o}return Uu=e,Uu}var Wu,wy;function sT(){if(wy)return Wu;wy=1;function e(n){return this.__data__.get(n)}return Wu=e,Wu}var Gu,xy;function lT(){if(xy)return Gu;xy=1;function e(n){return this.__data__.has(n)}return Gu=e,Gu}var Ku,_y;function Sy(){if(_y)return Ku;_y=1;var e=typeof os=="object"&&os&&os.Object===Object&&os;return Ku=e,Ku}var Yu,Ey;function Qn(){if(Ey)return Yu;Ey=1;var e=Sy(),n=typeof self=="object"&&self&&self.Object===Object&&self,r=e||n||Function("return this")();return Yu=r,Yu}var Xu,Oy;function Bo(){if(Oy)return Xu;Oy=1;var e=Qn(),n=e.Symbol;return Xu=n,Xu}var Zu,ky;function uT(){if(ky)return Zu;ky=1;var e=Bo(),n=Object.prototype,r=n.hasOwnProperty,o=n.toString,i=e?e.toStringTag:void 0;function l(c){var f=r.call(c,i),m=c[i];try{c[i]=void 0;var g=!0}catch{}var d=o.call(c);return g&&(f?c[i]=m:delete c[i]),d}return Zu=l,Zu}var Qu,Cy;function cT(){if(Cy)return Qu;Cy=1;var e=Object.prototype,n=e.toString;function r(o){return n.call(o)}return Qu=r,Qu}var Ju,Ay;function uo(){if(Ay)return Ju;Ay=1;var e=Bo(),n=uT(),r=cT(),o="[object Null]",i="[object Undefined]",l=e?e.toStringTag:void 0;function c(f){return f==null?f===void 0?i:o:l&&l in Object(f)?n(f):r(f)}return Ju=c,Ju}var $u,Ny;function In(){if(Ny)return $u;Ny=1;function e(n){var r=typeof n;return n!=null&&(r=="object"||r=="function")}return $u=e,$u}var ec,Ty;function Di(){if(Ty)return ec;Ty=1;var e=uo(),n=In(),r="[object AsyncFunction]",o="[object Function]",i="[object GeneratorFunction]",l="[object Proxy]";function c(f){if(!n(f))return!1;var m=e(f);return m==o||m==i||m==r||m==l}return ec=c,ec}var tc,Ry;function fT(){if(Ry)return tc;Ry=1;var e=Qn(),n=e["__core-js_shared__"];return tc=n,tc}var nc,Py;function dT(){if(Py)return nc;Py=1;var e=fT(),n=(function(){var o=/[^.]+$/.exec(e&&e.keys&&e.keys.IE_PROTO||"");return o?"Symbol(src)_1."+o:""})();function r(o){return!!n&&n in o}return nc=r,nc}var rc,Iy;function My(){if(Iy)return rc;Iy=1;var e=Function.prototype,n=e.toString;function r(o){if(o!=null){try{return n.call(o)}catch{}try{return o+""}catch{}}return""}return rc=r,rc}var oc,jy;function hT(){if(jy)return oc;jy=1;var e=Di(),n=dT(),r=In(),o=My(),i=/[\\^$.*+?()[\]{}|]/g,l=/^\[object .+?Constructor\]$/,c=Function.prototype,f=Object.prototype,m=c.toString,g=f.hasOwnProperty,d=RegExp("^"+m.call(g).replace(i,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function p(h){if(!r(h)||n(h))return!1;var s=e(h)?d:l;return s.test(o(h))}return oc=p,oc}var ic,Ly;function pT(){if(Ly)return ic;Ly=1;function e(n,r){return n?.[r]}return ic=e,ic}var ac,Dy;function co(){if(Dy)return ac;Dy=1;var e=hT(),n=pT();function r(o,i){var l=n(o,i);return e(l)?l:void 0}return ac=r,ac}var sc,By;function lc(){if(By)return sc;By=1;var e=co(),n=Qn(),r=e(n,"Map");return sc=r,sc}var uc,Fy;function ss(){if(Fy)return uc;Fy=1;var e=co(),n=e(Object,"create");return uc=n,uc}var cc,qy;function mT(){if(qy)return cc;qy=1;var e=ss();function n(){this.__data__=e?e(null):{},this.size=0}return cc=n,cc}var fc,zy;function gT(){if(zy)return fc;zy=1;function e(n){var r=this.has(n)&&delete this.__data__[n];return this.size-=r?1:0,r}return fc=e,fc}var dc,Hy;function vT(){if(Hy)return dc;Hy=1;var e=ss(),n="__lodash_hash_undefined__",r=Object.prototype,o=r.hasOwnProperty;function i(l){var c=this.__data__;if(e){var f=c[l];return f===n?void 0:f}return o.call(c,l)?c[l]:void 0}return dc=i,dc}var hc,Vy;function yT(){if(Vy)return hc;Vy=1;var e=ss(),n=Object.prototype,r=n.hasOwnProperty;function o(i){var l=this.__data__;return e?l[i]!==void 0:r.call(l,i)}return hc=o,hc}var pc,Uy;function bT(){if(Uy)return pc;Uy=1;var e=ss(),n="__lodash_hash_undefined__";function r(o,i){var l=this.__data__;return this.size+=this.has(o)?0:1,l[o]=e&&i===void 0?n:i,this}return pc=r,pc}var mc,Wy;function wT(){if(Wy)return mc;Wy=1;var e=mT(),n=gT(),r=vT(),o=yT(),i=bT();function l(c){var f=-1,m=c==null?0:c.length;for(this.clear();++f<m;){var g=c[f];this.set(g[0],g[1])}}return l.prototype.clear=e,l.prototype.delete=n,l.prototype.get=r,l.prototype.has=o,l.prototype.set=i,mc=l,mc}var gc,Gy;function xT(){if(Gy)return gc;Gy=1;var e=wT(),n=as(),r=lc();function o(){this.size=0,this.__data__={hash:new e,map:new(r||n),string:new e}}return gc=o,gc}var vc,Ky;function _T(){if(Ky)return vc;Ky=1;function e(n){var r=typeof n;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?n!=="__proto__":n===null}return vc=e,vc}var yc,Yy;function ls(){if(Yy)return yc;Yy=1;var e=_T();function n(r,o){var i=r.__data__;return e(o)?i[typeof o=="string"?"string":"hash"]:i.map}return yc=n,yc}var bc,Xy;function ST(){if(Xy)return bc;Xy=1;var e=ls();function n(r){var o=e(this,r).delete(r);return this.size-=o?1:0,o}return bc=n,bc}var wc,Zy;function ET(){if(Zy)return wc;Zy=1;var e=ls();function n(r){return e(this,r).get(r)}return wc=n,wc}var xc,Qy;function OT(){if(Qy)return xc;Qy=1;var e=ls();function n(r){return e(this,r).has(r)}return xc=n,xc}var _c,Jy;function kT(){if(Jy)return _c;Jy=1;var e=ls();function n(r,o){var i=e(this,r),l=i.size;return i.set(r,o),this.size+=i.size==l?0:1,this}return _c=n,_c}var Sc,$y;function Ec(){if($y)return Sc;$y=1;var e=xT(),n=ST(),r=ET(),o=OT(),i=kT();function l(c){var f=-1,m=c==null?0:c.length;for(this.clear();++f<m;){var g=c[f];this.set(g[0],g[1])}}return l.prototype.clear=e,l.prototype.delete=n,l.prototype.get=r,l.prototype.has=o,l.prototype.set=i,Sc=l,Sc}var Oc,eb;function CT(){if(eb)return Oc;eb=1;var e=as(),n=lc(),r=Ec(),o=200;function i(l,c){var f=this.__data__;if(f instanceof e){var m=f.__data__;if(!n||m.length<o-1)return m.push([l,c]),this.size=++f.size,this;f=this.__data__=new r(m)}return f.set(l,c),this.size=f.size,this}return Oc=i,Oc}var kc,tb;function us(){if(tb)return kc;tb=1;var e=as(),n=iT(),r=aT(),o=sT(),i=lT(),l=CT();function c(f){var m=this.__data__=new e(f);this.size=m.size}return c.prototype.clear=n,c.prototype.delete=r,c.prototype.get=o,c.prototype.has=i,c.prototype.set=l,kc=c,kc}var Cc,nb;function Ac(){if(nb)return Cc;nb=1;function e(n,r){for(var o=-1,i=n==null?0:n.length;++o<i&&r(n[o],o,n)!==!1;);return n}return Cc=e,Cc}var Nc,rb;function ob(){if(rb)return Nc;rb=1;var e=co(),n=(function(){try{var r=e(Object,"defineProperty");return r({},"",{}),r}catch{}})();return Nc=n,Nc}var Tc,ib;function cs(){if(ib)return Tc;ib=1;var e=ob();function n(r,o,i){o=="__proto__"&&e?e(r,o,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[o]=i}return Tc=n,Tc}var Rc,ab;function fs(){if(ab)return Rc;ab=1;var e=cs(),n=Do(),r=Object.prototype,o=r.hasOwnProperty;function i(l,c,f){var m=l[c];(!(o.call(l,c)&&n(m,f))||f===void 0&&!(c in l))&&e(l,c,f)}return Rc=i,Rc}var Pc,sb;function Bi(){if(sb)return Pc;sb=1;var e=fs(),n=cs();function r(o,i,l,c){var f=!l;l||(l={});for(var m=-1,g=i.length;++m<g;){var d=i[m],p=c?c(l[d],o[d],d,l,o):void 0;p===void 0&&(p=o[d]),f?n(l,d,p):e(l,d,p)}return l}return Pc=r,Pc}var Ic,lb;function AT(){if(lb)return Ic;lb=1;function e(n,r){for(var o=-1,i=Array(n);++o<n;)i[o]=r(o);return i}return Ic=e,Ic}var Mc,ub;function ur(){if(ub)return Mc;ub=1;function e(n){return n!=null&&typeof n=="object"}return Mc=e,Mc}var jc,cb;function NT(){if(cb)return jc;cb=1;var e=uo(),n=ur(),r="[object Arguments]";function o(i){return n(i)&&e(i)==r}return jc=o,jc}var Lc,fb;function Fi(){if(fb)return Lc;fb=1;var e=NT(),n=ur(),r=Object.prototype,o=r.hasOwnProperty,i=r.propertyIsEnumerable,l=e((function(){return arguments})())?e:function(c){return n(c)&&o.call(c,"callee")&&!i.call(c,"callee")};return Lc=l,Lc}var Dc,db;function Kt(){if(db)return Dc;db=1;var e=Array.isArray;return Dc=e,Dc}var qi={exports:{}},Bc,hb;function TT(){if(hb)return Bc;hb=1;function e(){return!1}return Bc=e,Bc}qi.exports;var pb;function Fo(){return pb||(pb=1,(function(e,n){var r=Qn(),o=TT(),i=n&&!n.nodeType&&n,l=i&&!0&&e&&!e.nodeType&&e,c=l&&l.exports===i,f=c?r.Buffer:void 0,m=f?f.isBuffer:void 0,g=m||o;e.exports=g})(qi,qi.exports)),qi.exports}var Fc,mb;function ds(){if(mb)return Fc;mb=1;var e=9007199254740991,n=/^(?:0|[1-9]\d*)$/;function r(o,i){var l=typeof o;return i=i??e,!!i&&(l=="number"||l!="symbol"&&n.test(o))&&o>-1&&o%1==0&&o<i}return Fc=r,Fc}var qc,gb;function zc(){if(gb)return qc;gb=1;var e=9007199254740991;function n(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=e}return qc=n,qc}var Hc,vb;function RT(){if(vb)return Hc;vb=1;var e=uo(),n=zc(),r=ur(),o="[object Arguments]",i="[object Array]",l="[object Boolean]",c="[object Date]",f="[object Error]",m="[object Function]",g="[object Map]",d="[object Number]",p="[object Object]",h="[object RegExp]",s="[object Set]",S="[object String]",b="[object WeakMap]",_="[object ArrayBuffer]",w="[object DataView]",y="[object Float32Array]",E="[object Float64Array]",x="[object Int8Array]",k="[object Int16Array]",P="[object Int32Array]",R="[object Uint8Array]",j="[object Uint8ClampedArray]",z="[object Uint16Array]",L="[object Uint32Array]",M={};M[y]=M[E]=M[x]=M[k]=M[P]=M[R]=M[j]=M[z]=M[L]=!0,M[o]=M[i]=M[_]=M[l]=M[w]=M[c]=M[f]=M[m]=M[g]=M[d]=M[p]=M[h]=M[s]=M[S]=M[b]=!1;function D(F){return r(F)&&n(F.length)&&!!M[e(F)]}return Hc=D,Hc}var Vc,yb;function hs(){if(yb)return Vc;yb=1;function e(n){return function(r){return n(r)}}return Vc=e,Vc}var zi={exports:{}};zi.exports;var bb;function Uc(){return bb||(bb=1,(function(e,n){var r=Sy(),o=n&&!n.nodeType&&n,i=o&&!0&&e&&!e.nodeType&&e,l=i&&i.exports===o,c=l&&r.process,f=(function(){try{var m=i&&i.require&&i.require("util").types;return m||c&&c.binding&&c.binding("util")}catch{}})();e.exports=f})(zi,zi.exports)),zi.exports}var Wc,wb;function Hi(){if(wb)return Wc;wb=1;var e=RT(),n=hs(),r=Uc(),o=r&&r.isTypedArray,i=o?n(o):e;return Wc=i,Wc}var Gc,xb;function _b(){if(xb)return Gc;xb=1;var e=AT(),n=Fi(),r=Kt(),o=Fo(),i=ds(),l=Hi(),c=Object.prototype,f=c.hasOwnProperty;function m(g,d){var p=r(g),h=!p&&n(g),s=!p&&!h&&o(g),S=!p&&!h&&!s&&l(g),b=p||h||s||S,_=b?e(g.length,String):[],w=_.length;for(var y in g)(d||f.call(g,y))&&!(b&&(y=="length"||s&&(y=="offset"||y=="parent")||S&&(y=="buffer"||y=="byteLength"||y=="byteOffset")||i(y,w)))&&_.push(y);return _}return Gc=m,Gc}var Kc,Sb;function ps(){if(Sb)return Kc;Sb=1;var e=Object.prototype;function n(r){var o=r&&r.constructor,i=typeof o=="function"&&o.prototype||e;return r===i}return Kc=n,Kc}var Yc,Eb;function Ob(){if(Eb)return Yc;Eb=1;function e(n,r){return function(o){return n(r(o))}}return Yc=e,Yc}var Xc,kb;function PT(){if(kb)return Xc;kb=1;var e=Ob(),n=e(Object.keys,Object);return Xc=n,Xc}var Zc,Cb;function Qc(){if(Cb)return Zc;Cb=1;var e=ps(),n=PT(),r=Object.prototype,o=r.hasOwnProperty;function i(l){if(!e(l))return n(l);var c=[];for(var f in Object(l))o.call(l,f)&&f!="constructor"&&c.push(f);return c}return Zc=i,Zc}var Jc,Ab;function Sr(){if(Ab)return Jc;Ab=1;var e=Di(),n=zc();function r(o){return o!=null&&n(o.length)&&!e(o)}return Jc=r,Jc}var $c,Nb;function Gr(){if(Nb)return $c;Nb=1;var e=_b(),n=Qc(),r=Sr();function o(i){return r(i)?e(i):n(i)}return $c=o,$c}var ef,Tb;function IT(){if(Tb)return ef;Tb=1;var e=Bi(),n=Gr();function r(o,i){return o&&e(i,n(i),o)}return ef=r,ef}var tf,Rb;function MT(){if(Rb)return tf;Rb=1;function e(n){var r=[];if(n!=null)for(var o in Object(n))r.push(o);return r}return tf=e,tf}var nf,Pb;function jT(){if(Pb)return nf;Pb=1;var e=In(),n=ps(),r=MT(),o=Object.prototype,i=o.hasOwnProperty;function l(c){if(!e(c))return r(c);var f=n(c),m=[];for(var g in c)g=="constructor"&&(f||!i.call(c,g))||m.push(g);return m}return nf=l,nf}var rf,Ib;function fo(){if(Ib)return rf;Ib=1;var e=_b(),n=jT(),r=Sr();function o(i){return r(i)?e(i,!0):n(i)}return rf=o,rf}var of,Mb;function LT(){if(Mb)return of;Mb=1;var e=Bi(),n=fo();function r(o,i){return o&&e(i,n(i),o)}return of=r,of}var Vi={exports:{}};Vi.exports;var jb;function Lb(){return jb||(jb=1,(function(e,n){var r=Qn(),o=n&&!n.nodeType&&n,i=o&&!0&&e&&!e.nodeType&&e,l=i&&i.exports===o,c=l?r.Buffer:void 0,f=c?c.allocUnsafe:void 0;function m(g,d){if(d)return g.slice();var p=g.length,h=f?f(p):new g.constructor(p);return g.copy(h),h}e.exports=m})(Vi,Vi.exports)),Vi.exports}var af,Db;function Bb(){if(Db)return af;Db=1;function e(n,r){var o=-1,i=n.length;for(r||(r=Array(i));++o<i;)r[o]=n[o];return r}return af=e,af}var sf,Fb;function qb(){if(Fb)return sf;Fb=1;function e(n,r){for(var o=-1,i=n==null?0:n.length,l=0,c=[];++o<i;){var f=n[o];r(f,o,n)&&(c[l++]=f)}return c}return sf=e,sf}var lf,zb;function Hb(){if(zb)return lf;zb=1;function e(){return[]}return lf=e,lf}var uf,Vb;function cf(){if(Vb)return uf;Vb=1;var e=qb(),n=Hb(),r=Object.prototype,o=r.propertyIsEnumerable,i=Object.getOwnPropertySymbols,l=i?function(c){return c==null?[]:(c=Object(c),e(i(c),function(f){return o.call(c,f)}))}:n;return uf=l,uf}var ff,Ub;function DT(){if(Ub)return ff;Ub=1;var e=Bi(),n=cf();function r(o,i){return e(o,n(o),i)}return ff=r,ff}var df,Wb;function hf(){if(Wb)return df;Wb=1;function e(n,r){for(var o=-1,i=r.length,l=n.length;++o<i;)n[l+o]=r[o];return n}return df=e,df}var pf,Gb;function ms(){if(Gb)return pf;Gb=1;var e=Ob(),n=e(Object.getPrototypeOf,Object);return pf=n,pf}var mf,Kb;function Yb(){if(Kb)return mf;Kb=1;var e=hf(),n=ms(),r=cf(),o=Hb(),i=Object.getOwnPropertySymbols,l=i?function(c){for(var f=[];c;)e(f,r(c)),c=n(c);return f}:o;return mf=l,mf}var gf,Xb;function BT(){if(Xb)return gf;Xb=1;var e=Bi(),n=Yb();function r(o,i){return e(o,n(o),i)}return gf=r,gf}var vf,Zb;function Qb(){if(Zb)return vf;Zb=1;var e=hf(),n=Kt();function r(o,i,l){var c=i(o);return n(o)?c:e(c,l(o))}return vf=r,vf}var yf,Jb;function $b(){if(Jb)return yf;Jb=1;var e=Qb(),n=cf(),r=Gr();function o(i){return e(i,r,n)}return yf=o,yf}var bf,e0;function FT(){if(e0)return bf;e0=1;var e=Qb(),n=Yb(),r=fo();function o(i){return e(i,r,n)}return bf=o,bf}var wf,t0;function qT(){if(t0)return wf;t0=1;var e=co(),n=Qn(),r=e(n,"DataView");return wf=r,wf}var xf,n0;function zT(){if(n0)return xf;n0=1;var e=co(),n=Qn(),r=e(n,"Promise");return xf=r,xf}var _f,r0;function o0(){if(r0)return _f;r0=1;var e=co(),n=Qn(),r=e(n,"Set");return _f=r,_f}var Sf,i0;function HT(){if(i0)return Sf;i0=1;var e=co(),n=Qn(),r=e(n,"WeakMap");return Sf=r,Sf}var Ef,a0;function qo(){if(a0)return Ef;a0=1;var e=qT(),n=lc(),r=zT(),o=o0(),i=HT(),l=uo(),c=My(),f="[object Map]",m="[object Object]",g="[object Promise]",d="[object Set]",p="[object WeakMap]",h="[object DataView]",s=c(e),S=c(n),b=c(r),_=c(o),w=c(i),y=l;return(e&&y(new e(new ArrayBuffer(1)))!=h||n&&y(new n)!=f||r&&y(r.resolve())!=g||o&&y(new o)!=d||i&&y(new i)!=p)&&(y=function(E){var x=l(E),k=x==m?E.constructor:void 0,P=k?c(k):"";if(P)switch(P){case s:return h;case S:return f;case b:return g;case _:return d;case w:return p}return x}),Ef=y,Ef}var Of,s0;function VT(){if(s0)return Of;s0=1;var e=Object.prototype,n=e.hasOwnProperty;function r(o){var i=o.length,l=new o.constructor(i);return i&&typeof o[0]=="string"&&n.call(o,"index")&&(l.index=o.index,l.input=o.input),l}return Of=r,Of}var kf,l0;function u0(){if(l0)return kf;l0=1;var e=Qn(),n=e.Uint8Array;return kf=n,kf}var Cf,c0;function Af(){if(c0)return Cf;c0=1;var e=u0();function n(r){var o=new r.constructor(r.byteLength);return new e(o).set(new e(r)),o}return Cf=n,Cf}var Nf,f0;function UT(){if(f0)return Nf;f0=1;var e=Af();function n(r,o){var i=o?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.byteLength)}return Nf=n,Nf}var Tf,d0;function WT(){if(d0)return Tf;d0=1;var e=/\w*$/;function n(r){var o=new r.constructor(r.source,e.exec(r));return o.lastIndex=r.lastIndex,o}return Tf=n,Tf}var Rf,h0;function GT(){if(h0)return Rf;h0=1;var e=Bo(),n=e?e.prototype:void 0,r=n?n.valueOf:void 0;function o(i){return r?Object(r.call(i)):{}}return Rf=o,Rf}var Pf,p0;function m0(){if(p0)return Pf;p0=1;var e=Af();function n(r,o){var i=o?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.length)}return Pf=n,Pf}var If,g0;function KT(){if(g0)return If;g0=1;var e=Af(),n=UT(),r=WT(),o=GT(),i=m0(),l="[object Boolean]",c="[object Date]",f="[object Map]",m="[object Number]",g="[object RegExp]",d="[object Set]",p="[object String]",h="[object Symbol]",s="[object ArrayBuffer]",S="[object DataView]",b="[object Float32Array]",_="[object Float64Array]",w="[object Int8Array]",y="[object Int16Array]",E="[object Int32Array]",x="[object Uint8Array]",k="[object Uint8ClampedArray]",P="[object Uint16Array]",R="[object Uint32Array]";function j(z,L,M){var D=z.constructor;switch(L){case s:return e(z);case l:case c:return new D(+z);case S:return n(z,M);case b:case _:case w:case y:case E:case x:case k:case P:case R:return i(z,M);case f:return new D;case m:case p:return new D(z);case g:return r(z);case d:return new D;case h:return o(z)}}return If=j,If}var Mf,v0;function y0(){if(v0)return Mf;v0=1;var e=In(),n=Object.create,r=(function(){function o(){}return function(i){if(!e(i))return{};if(n)return n(i);o.prototype=i;var l=new o;return o.prototype=void 0,l}})();return Mf=r,Mf}var jf,b0;function w0(){if(b0)return jf;b0=1;var e=y0(),n=ms(),r=ps();function o(i){return typeof i.constructor=="function"&&!r(i)?e(n(i)):{}}return jf=o,jf}var Lf,x0;function YT(){if(x0)return Lf;x0=1;var e=qo(),n=ur(),r="[object Map]";function o(i){return n(i)&&e(i)==r}return Lf=o,Lf}var Df,_0;function XT(){if(_0)return Df;_0=1;var e=YT(),n=hs(),r=Uc(),o=r&&r.isMap,i=o?n(o):e;return Df=i,Df}var Bf,S0;function ZT(){if(S0)return Bf;S0=1;var e=qo(),n=ur(),r="[object Set]";function o(i){return n(i)&&e(i)==r}return Bf=o,Bf}var Ff,E0;function QT(){if(E0)return Ff;E0=1;var e=ZT(),n=hs(),r=Uc(),o=r&&r.isSet,i=o?n(o):e;return Ff=i,Ff}var qf,O0;function k0(){if(O0)return qf;O0=1;var e=us(),n=Ac(),r=fs(),o=IT(),i=LT(),l=Lb(),c=Bb(),f=DT(),m=BT(),g=$b(),d=FT(),p=qo(),h=VT(),s=KT(),S=w0(),b=Kt(),_=Fo(),w=XT(),y=In(),E=QT(),x=Gr(),k=fo(),P=1,R=2,j=4,z="[object Arguments]",L="[object Array]",M="[object Boolean]",D="[object Date]",F="[object Error]",B="[object Function]",U="[object GeneratorFunction]",J="[object Map]",oe="[object Number]",de="[object Object]",Y="[object RegExp]",ee="[object Set]",W="[object String]",ne="[object Symbol]",ae="[object WeakMap]",te="[object ArrayBuffer]",re="[object DataView]",Z="[object Float32Array]",se="[object Float64Array]",pe="[object Int8Array]",ge="[object Int16Array]",be="[object Int32Array]",Ae="[object Uint8Array]",Ue="[object Uint8ClampedArray]",Ve="[object Uint16Array]",Fe="[object Uint32Array]",Pe={};Pe[z]=Pe[L]=Pe[te]=Pe[re]=Pe[M]=Pe[D]=Pe[Z]=Pe[se]=Pe[pe]=Pe[ge]=Pe[be]=Pe[J]=Pe[oe]=Pe[de]=Pe[Y]=Pe[ee]=Pe[W]=Pe[ne]=Pe[Ae]=Pe[Ue]=Pe[Ve]=Pe[Fe]=!0,Pe[F]=Pe[B]=Pe[ae]=!1;function ut(Ce,we,xe,Re,De,Ee){var We,Qe=we&P,ot=we&R,Mt=we&j;if(xe&&(We=De?xe(Ce,Re,De,Ee):xe(Ce)),We!==void 0)return We;if(!y(Ce))return Ce;var jt=b(Ce);if(jt){if(We=h(Ce),!Qe)return c(Ce,We)}else{var pt=p(Ce),vn=pt==B||pt==U;if(_(Ce))return l(Ce,Qe);if(pt==de||pt==z||vn&&!De){if(We=ot||vn?{}:S(Ce),!Qe)return ot?m(Ce,i(We,Ce)):f(Ce,o(We,Ce))}else{if(!Pe[pt])return De?Ce:{};We=s(Ce,pt,Qe)}}Ee||(Ee=new e);var ft=Ee.get(Ce);if(ft)return ft;Ee.set(Ce,We),E(Ce)?Ce.forEach(function(Yt){We.add(ut(Yt,we,xe,Yt,Ce,Ee))}):w(Ce)&&Ce.forEach(function(Yt,cn){We.set(cn,ut(Yt,we,xe,cn,Ce,Ee))});var Rt=Mt?ot?d:g:ot?k:x,Cn=jt?void 0:Rt(Ce);return n(Cn||Ce,function(Yt,cn){Cn&&(cn=Yt,Yt=Ce[cn]),r(We,cn,ut(Yt,we,xe,cn,Ce,Ee))}),We}return qf=ut,qf}var zf,C0;function JT(){if(C0)return zf;C0=1;var e=k0(),n=4;function r(o){return e(o,n)}return zf=r,zf}var Hf,A0;function Vf(){if(A0)return Hf;A0=1;function e(n){return function(){return n}}return Hf=e,Hf}var Uf,N0;function $T(){if(N0)return Uf;N0=1;function e(n){return function(r,o,i){for(var l=-1,c=Object(r),f=i(r),m=f.length;m--;){var g=f[n?m:++l];if(o(c[g],g,c)===!1)break}return r}}return Uf=e,Uf}var Wf,T0;function Gf(){if(T0)return Wf;T0=1;var e=$T(),n=e();return Wf=n,Wf}var Kf,R0;function Yf(){if(R0)return Kf;R0=1;var e=Gf(),n=Gr();function r(o,i){return o&&e(o,i,n)}return Kf=r,Kf}var Xf,P0;function eR(){if(P0)return Xf;P0=1;var e=Sr();function n(r,o){return function(i,l){if(i==null)return i;if(!e(i))return r(i,l);for(var c=i.length,f=o?c:-1,m=Object(i);(o?f--:++f<c)&&l(m[f],f,m)!==!1;);return i}}return Xf=n,Xf}var Zf,I0;function gs(){if(I0)return Zf;I0=1;var e=Yf(),n=eR(),r=n(e);return Zf=r,Zf}var Qf,M0;function ho(){if(M0)return Qf;M0=1;function e(n){return n}return Qf=e,Qf}var Jf,j0;function L0(){if(j0)return Jf;j0=1;var e=ho();function n(r){return typeof r=="function"?r:e}return Jf=n,Jf}var $f,D0;function B0(){if(D0)return $f;D0=1;var e=Ac(),n=gs(),r=L0(),o=Kt();function i(l,c){var f=o(l)?e:n;return f(l,r(c))}return $f=i,$f}var ed,F0;function q0(){return F0||(F0=1,ed=B0()),ed}var td,z0;function tR(){if(z0)return td;z0=1;var e=gs();function n(r,o){var i=[];return e(r,function(l,c,f){o(l,c,f)&&i.push(l)}),i}return td=n,td}var nd,H0;function nR(){if(H0)return nd;H0=1;var e="__lodash_hash_undefined__";function n(r){return this.__data__.set(r,e),this}return nd=n,nd}var rd,V0;function rR(){if(V0)return rd;V0=1;function e(n){return this.__data__.has(n)}return rd=e,rd}var od,U0;function W0(){if(U0)return od;U0=1;var e=Ec(),n=nR(),r=rR();function o(i){var l=-1,c=i==null?0:i.length;for(this.__data__=new e;++l<c;)this.add(i[l])}return o.prototype.add=o.prototype.push=n,o.prototype.has=r,od=o,od}var id,G0;function oR(){if(G0)return id;G0=1;function e(n,r){for(var o=-1,i=n==null?0:n.length;++o<i;)if(r(n[o],o,n))return!0;return!1}return id=e,id}var ad,K0;function Y0(){if(K0)return ad;K0=1;function e(n,r){return n.has(r)}return ad=e,ad}var sd,X0;function Z0(){if(X0)return sd;X0=1;var e=W0(),n=oR(),r=Y0(),o=1,i=2;function l(c,f,m,g,d,p){var h=m&o,s=c.length,S=f.length;if(s!=S&&!(h&&S>s))return!1;var b=p.get(c),_=p.get(f);if(b&&_)return b==f&&_==c;var w=-1,y=!0,E=m&i?new e:void 0;for(p.set(c,f),p.set(f,c);++w<s;){var x=c[w],k=f[w];if(g)var P=h?g(k,x,w,f,c,p):g(x,k,w,c,f,p);if(P!==void 0){if(P)continue;y=!1;break}if(E){if(!n(f,function(R,j){if(!r(E,j)&&(x===R||d(x,R,m,g,p)))return E.push(j)})){y=!1;break}}else if(!(x===k||d(x,k,m,g,p))){y=!1;break}}return p.delete(c),p.delete(f),y}return sd=l,sd}var ld,Q0;function iR(){if(Q0)return ld;Q0=1;function e(n){var r=-1,o=Array(n.size);return n.forEach(function(i,l){o[++r]=[l,i]}),o}return ld=e,ld}var ud,J0;function cd(){if(J0)return ud;J0=1;function e(n){var r=-1,o=Array(n.size);return n.forEach(function(i){o[++r]=i}),o}return ud=e,ud}var fd,$0;function aR(){if($0)return fd;$0=1;var e=Bo(),n=u0(),r=Do(),o=Z0(),i=iR(),l=cd(),c=1,f=2,m="[object Boolean]",g="[object Date]",d="[object Error]",p="[object Map]",h="[object Number]",s="[object RegExp]",S="[object Set]",b="[object String]",_="[object Symbol]",w="[object ArrayBuffer]",y="[object DataView]",E=e?e.prototype:void 0,x=E?E.valueOf:void 0;function k(P,R,j,z,L,M,D){switch(j){case y:if(P.byteLength!=R.byteLength||P.byteOffset!=R.byteOffset)return!1;P=P.buffer,R=R.buffer;case w:return!(P.byteLength!=R.byteLength||!M(new n(P),new n(R)));case m:case g:case h:return r(+P,+R);case d:return P.name==R.name&&P.message==R.message;case s:case b:return P==R+"";case p:var F=i;case S:var B=z&c;if(F||(F=l),P.size!=R.size&&!B)return!1;var U=D.get(P);if(U)return U==R;z|=f,D.set(P,R);var J=o(F(P),F(R),z,L,M,D);return D.delete(P),J;case _:if(x)return x.call(P)==x.call(R)}return!1}return fd=k,fd}var dd,e1;function sR(){if(e1)return dd;e1=1;var e=$b(),n=1,r=Object.prototype,o=r.hasOwnProperty;function i(l,c,f,m,g,d){var p=f&n,h=e(l),s=h.length,S=e(c),b=S.length;if(s!=b&&!p)return!1;for(var _=s;_--;){var w=h[_];if(!(p?w in c:o.call(c,w)))return!1}var y=d.get(l),E=d.get(c);if(y&&E)return y==c&&E==l;var x=!0;d.set(l,c),d.set(c,l);for(var k=p;++_<s;){w=h[_];var P=l[w],R=c[w];if(m)var j=p?m(R,P,w,c,l,d):m(P,R,w,l,c,d);if(!(j===void 0?P===R||g(P,R,f,m,d):j)){x=!1;break}k||(k=w=="constructor")}if(x&&!k){var z=l.constructor,L=c.constructor;z!=L&&"constructor"in l&&"constructor"in c&&!(typeof z=="function"&&z instanceof z&&typeof L=="function"&&L instanceof L)&&(x=!1)}return d.delete(l),d.delete(c),x}return dd=i,dd}var hd,t1;function lR(){if(t1)return hd;t1=1;var e=us(),n=Z0(),r=aR(),o=sR(),i=qo(),l=Kt(),c=Fo(),f=Hi(),m=1,g="[object Arguments]",d="[object Array]",p="[object Object]",h=Object.prototype,s=h.hasOwnProperty;function S(b,_,w,y,E,x){var k=l(b),P=l(_),R=k?d:i(b),j=P?d:i(_);R=R==g?p:R,j=j==g?p:j;var z=R==p,L=j==p,M=R==j;if(M&&c(b)){if(!c(_))return!1;k=!0,z=!1}if(M&&!z)return x||(x=new e),k||f(b)?n(b,_,w,y,E,x):r(b,_,R,w,y,E,x);if(!(w&m)){var D=z&&s.call(b,"__wrapped__"),F=L&&s.call(_,"__wrapped__");if(D||F){var B=D?b.value():b,U=F?_.value():_;return x||(x=new e),E(B,U,w,y,x)}}return M?(x||(x=new e),o(b,_,w,y,E,x)):!1}return hd=S,hd}var pd,n1;function md(){if(n1)return pd;n1=1;var e=lR(),n=ur();function r(o,i,l,c,f){return o===i?!0:o==null||i==null||!n(o)&&!n(i)?o!==o&&i!==i:e(o,i,l,c,r,f)}return pd=r,pd}var gd,r1;function uR(){if(r1)return gd;r1=1;var e=us(),n=md(),r=1,o=2;function i(l,c,f,m){var g=f.length,d=g,p=!m;if(l==null)return!d;for(l=Object(l);g--;){var h=f[g];if(p&&h[2]?h[1]!==l[h[0]]:!(h[0]in l))return!1}for(;++g<d;){h=f[g];var s=h[0],S=l[s],b=h[1];if(p&&h[2]){if(S===void 0&&!(s in l))return!1}else{var _=new e;if(m)var w=m(S,b,s,l,c,_);if(!(w===void 0?n(b,S,r|o,m,_):w))return!1}}return!0}return gd=i,gd}var vd,o1;function i1(){if(o1)return vd;o1=1;var e=In();function n(r){return r===r&&!e(r)}return vd=n,vd}var yd,a1;function cR(){if(a1)return yd;a1=1;var e=i1(),n=Gr();function r(o){for(var i=n(o),l=i.length;l--;){var c=i[l],f=o[c];i[l]=[c,f,e(f)]}return i}return yd=r,yd}var bd,s1;function l1(){if(s1)return bd;s1=1;function e(n,r){return function(o){return o==null?!1:o[n]===r&&(r!==void 0||n in Object(o))}}return bd=e,bd}var wd,u1;function fR(){if(u1)return wd;u1=1;var e=uR(),n=cR(),r=l1();function o(i){var l=n(i);return l.length==1&&l[0][2]?r(l[0][0],l[0][1]):function(c){return c===i||e(c,i,l)}}return wd=o,wd}var xd,c1;function zo(){if(c1)return xd;c1=1;var e=uo(),n=ur(),r="[object Symbol]";function o(i){return typeof i=="symbol"||n(i)&&e(i)==r}return xd=o,xd}var _d,f1;function Sd(){if(f1)return _d;f1=1;var e=Kt(),n=zo(),r=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,o=/^\w*$/;function i(l,c){if(e(l))return!1;var f=typeof l;return f=="number"||f=="symbol"||f=="boolean"||l==null||n(l)?!0:o.test(l)||!r.test(l)||c!=null&&l in Object(c)}return _d=i,_d}var Ed,d1;function dR(){if(d1)return Ed;d1=1;var e=Ec(),n="Expected a function";function r(o,i){if(typeof o!="function"||i!=null&&typeof i!="function")throw new TypeError(n);var l=function(){var c=arguments,f=i?i.apply(this,c):c[0],m=l.cache;if(m.has(f))return m.get(f);var g=o.apply(this,c);return l.cache=m.set(f,g)||m,g};return l.cache=new(r.Cache||e),l}return r.Cache=e,Ed=r,Ed}var Od,h1;function hR(){if(h1)return Od;h1=1;var e=dR(),n=500;function r(o){var i=e(o,function(c){return l.size===n&&l.clear(),c}),l=i.cache;return i}return Od=r,Od}var kd,p1;function pR(){if(p1)return kd;p1=1;var e=hR(),n=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,r=/\\(\\)?/g,o=e(function(i){var l=[];return i.charCodeAt(0)===46&&l.push(""),i.replace(n,function(c,f,m,g){l.push(m?g.replace(r,"$1"):f||c)}),l});return kd=o,kd}var Cd,m1;function vs(){if(m1)return Cd;m1=1;function e(n,r){for(var o=-1,i=n==null?0:n.length,l=Array(i);++o<i;)l[o]=r(n[o],o,n);return l}return Cd=e,Cd}var Ad,g1;function mR(){if(g1)return Ad;g1=1;var e=Bo(),n=vs(),r=Kt(),o=zo(),i=e?e.prototype:void 0,l=i?i.toString:void 0;function c(f){if(typeof f=="string")return f;if(r(f))return n(f,c)+"";if(o(f))return l?l.call(f):"";var m=f+"";return m=="0"&&1/f==-1/0?"-0":m}return Ad=c,Ad}var Nd,v1;function y1(){if(v1)return Nd;v1=1;var e=mR();function n(r){return r==null?"":e(r)}return Nd=n,Nd}var Td,b1;function ys(){if(b1)return Td;b1=1;var e=Kt(),n=Sd(),r=pR(),o=y1();function i(l,c){return e(l)?l:n(l,c)?[l]:r(o(l))}return Td=i,Td}var Rd,w1;function Ui(){if(w1)return Rd;w1=1;var e=zo();function n(r){if(typeof r=="string"||e(r))return r;var o=r+"";return o=="0"&&1/r==-1/0?"-0":o}return Rd=n,Rd}var Pd,x1;function bs(){if(x1)return Pd;x1=1;var e=ys(),n=Ui();function r(o,i){i=e(i,o);for(var l=0,c=i.length;o!=null&&l<c;)o=o[n(i[l++])];return l&&l==c?o:void 0}return Pd=r,Pd}var Id,_1;function gR(){if(_1)return Id;_1=1;var e=bs();function n(r,o,i){var l=r==null?void 0:e(r,o);return l===void 0?i:l}return Id=n,Id}var Md,S1;function vR(){if(S1)return Md;S1=1;function e(n,r){return n!=null&&r in Object(n)}return Md=e,Md}var jd,E1;function O1(){if(E1)return jd;E1=1;var e=ys(),n=Fi(),r=Kt(),o=ds(),i=zc(),l=Ui();function c(f,m,g){m=e(m,f);for(var d=-1,p=m.length,h=!1;++d<p;){var s=l(m[d]);if(!(h=f!=null&&g(f,s)))break;f=f[s]}return h||++d!=p?h:(p=f==null?0:f.length,!!p&&i(p)&&o(s,p)&&(r(f)||n(f)))}return jd=c,jd}var Ld,k1;function C1(){if(k1)return Ld;k1=1;var e=vR(),n=O1();function r(o,i){return o!=null&&n(o,i,e)}return Ld=r,Ld}var Dd,A1;function yR(){if(A1)return Dd;A1=1;var e=md(),n=gR(),r=C1(),o=Sd(),i=i1(),l=l1(),c=Ui(),f=1,m=2;function g(d,p){return o(d)&&i(p)?l(c(d),p):function(h){var s=n(h,d);return s===void 0&&s===p?r(h,d):e(p,s,f|m)}}return Dd=g,Dd}var Bd,N1;function T1(){if(N1)return Bd;N1=1;function e(n){return function(r){return r?.[n]}}return Bd=e,Bd}var Fd,R1;function bR(){if(R1)return Fd;R1=1;var e=bs();function n(r){return function(o){return e(o,r)}}return Fd=n,Fd}var qd,P1;function wR(){if(P1)return qd;P1=1;var e=T1(),n=bR(),r=Sd(),o=Ui();function i(l){return r(l)?e(o(l)):n(l)}return qd=i,qd}var zd,I1;function Er(){if(I1)return zd;I1=1;var e=fR(),n=yR(),r=ho(),o=Kt(),i=wR();function l(c){return typeof c=="function"?c:c==null?r:typeof c=="object"?o(c)?n(c[0],c[1]):e(c):i(c)}return zd=l,zd}var Hd,M1;function j1(){if(M1)return Hd;M1=1;var e=qb(),n=tR(),r=Er(),o=Kt();function i(l,c){var f=o(l)?e:n;return f(l,r(c,3))}return Hd=i,Hd}var Vd,L1;function xR(){if(L1)return Vd;L1=1;var e=Object.prototype,n=e.hasOwnProperty;function r(o,i){return o!=null&&n.call(o,i)}return Vd=r,Vd}var Ud,D1;function B1(){if(D1)return Ud;D1=1;var e=xR(),n=O1();function r(o,i){return o!=null&&n(o,i,e)}return Ud=r,Ud}var Wd,F1;function _R(){if(F1)return Wd;F1=1;var e=Qc(),n=qo(),r=Fi(),o=Kt(),i=Sr(),l=Fo(),c=ps(),f=Hi(),m="[object Map]",g="[object Set]",d=Object.prototype,p=d.hasOwnProperty;function h(s){if(s==null)return!0;if(i(s)&&(o(s)||typeof s=="string"||typeof s.splice=="function"||l(s)||f(s)||r(s)))return!s.length;var S=n(s);if(S==m||S==g)return!s.size;if(c(s))return!e(s).length;for(var b in s)if(p.call(s,b))return!1;return!0}return Wd=h,Wd}var Gd,q1;function z1(){if(q1)return Gd;q1=1;function e(n){return n===void 0}return Gd=e,Gd}var Kd,H1;function V1(){if(H1)return Kd;H1=1;var e=gs(),n=Sr();function r(o,i){var l=-1,c=n(o)?Array(o.length):[];return e(o,function(f,m,g){c[++l]=i(f,m,g)}),c}return Kd=r,Kd}var Yd,U1;function W1(){if(U1)return Yd;U1=1;var e=vs(),n=Er(),r=V1(),o=Kt();function i(l,c){var f=o(l)?e:r;return f(l,n(c,3))}return Yd=i,Yd}var Xd,G1;function SR(){if(G1)return Xd;G1=1;function e(n,r,o,i){var l=-1,c=n==null?0:n.length;for(i&&c&&(o=n[++l]);++l<c;)o=r(o,n[l],l,n);return o}return Xd=e,Xd}var Zd,K1;function ER(){if(K1)return Zd;K1=1;function e(n,r,o,i,l){return l(n,function(c,f,m){o=i?(i=!1,c):r(o,c,f,m)}),o}return Zd=e,Zd}var Qd,Y1;function X1(){if(Y1)return Qd;Y1=1;var e=SR(),n=gs(),r=Er(),o=ER(),i=Kt();function l(c,f,m){var g=i(c)?e:o,d=arguments.length<3;return g(c,r(f,4),m,d,n)}return Qd=l,Qd}var Jd,Z1;function OR(){if(Z1)return Jd;Z1=1;var e=uo(),n=Kt(),r=ur(),o="[object String]";function i(l){return typeof l=="string"||!n(l)&&r(l)&&e(l)==o}return Jd=i,Jd}var $d,Q1;function kR(){if(Q1)return $d;Q1=1;var e=T1(),n=e("length");return $d=n,$d}var eh,J1;function CR(){if(J1)return eh;J1=1;var e="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",o="\\u20d0-\\u20ff",i=n+r+o,l="\\ufe0e\\ufe0f",c="\\u200d",f=RegExp("["+c+e+i+l+"]");function m(g){return f.test(g)}return eh=m,eh}var th,$1;function AR(){if($1)return th;$1=1;var e="\\ud800-\\udfff",n="\\u0300-\\u036f",r="\\ufe20-\\ufe2f",o="\\u20d0-\\u20ff",i=n+r+o,l="\\ufe0e\\ufe0f",c="["+e+"]",f="["+i+"]",m="\\ud83c[\\udffb-\\udfff]",g="(?:"+f+"|"+m+")",d="[^"+e+"]",p="(?:\\ud83c[\\udde6-\\uddff]){2}",h="[\\ud800-\\udbff][\\udc00-\\udfff]",s="\\u200d",S=g+"?",b="["+l+"]?",_="(?:"+s+"(?:"+[d,p,h].join("|")+")"+b+S+")*",w=b+S+_,y="(?:"+[d+f+"?",f,p,h,c].join("|")+")",E=RegExp(m+"(?="+m+")|"+y+w,"g");function x(k){for(var P=E.lastIndex=0;E.test(k);)++P;return P}return th=x,th}var nh,ew;function NR(){if(ew)return nh;ew=1;var e=kR(),n=CR(),r=AR();function o(i){return n(i)?r(i):e(i)}return nh=o,nh}var rh,tw;function TR(){if(tw)return rh;tw=1;var e=Qc(),n=qo(),r=Sr(),o=OR(),i=NR(),l="[object Map]",c="[object Set]";function f(m){if(m==null)return 0;if(r(m))return o(m)?i(m):m.length;var g=n(m);return g==l||g==c?m.size:e(m).length}return rh=f,rh}var oh,nw;function RR(){if(nw)return oh;nw=1;var e=Ac(),n=y0(),r=Yf(),o=Er(),i=ms(),l=Kt(),c=Fo(),f=Di(),m=In(),g=Hi();function d(p,h,s){var S=l(p),b=S||c(p)||g(p);if(h=o(h,4),s==null){var _=p&&p.constructor;b?s=S?new _:[]:m(p)?s=f(_)?n(i(p)):{}:s={}}return(b?e:r)(p,function(w,y,E){return h(s,w,y,E)}),s}return oh=d,oh}var ih,rw;function PR(){if(rw)return ih;rw=1;var e=Bo(),n=Fi(),r=Kt(),o=e?e.isConcatSpreadable:void 0;function i(l){return r(l)||n(l)||!!(o&&l&&l[o])}return ih=i,ih}var ah,ow;function sh(){if(ow)return ah;ow=1;var e=hf(),n=PR();function r(o,i,l,c,f){var m=-1,g=o.length;for(l||(l=n),f||(f=[]);++m<g;){var d=o[m];i>0&&l(d)?i>1?r(d,i-1,l,c,f):e(f,d):c||(f[f.length]=d)}return f}return ah=r,ah}var lh,iw;function IR(){if(iw)return lh;iw=1;function e(n,r,o){switch(o.length){case 0:return n.call(r);case 1:return n.call(r,o[0]);case 2:return n.call(r,o[0],o[1]);case 3:return n.call(r,o[0],o[1],o[2])}return n.apply(r,o)}return lh=e,lh}var uh,aw;function sw(){if(aw)return uh;aw=1;var e=IR(),n=Math.max;function r(o,i,l){return i=n(i===void 0?o.length-1:i,0),function(){for(var c=arguments,f=-1,m=n(c.length-i,0),g=Array(m);++f<m;)g[f]=c[i+f];f=-1;for(var d=Array(i+1);++f<i;)d[f]=c[f];return d[i]=l(g),e(o,this,d)}}return uh=r,uh}var ch,lw;function MR(){if(lw)return ch;lw=1;var e=Vf(),n=ob(),r=ho(),o=n?function(i,l){return n(i,"toString",{configurable:!0,enumerable:!1,value:e(l),writable:!0})}:r;return ch=o,ch}var fh,uw;function jR(){if(uw)return fh;uw=1;var e=800,n=16,r=Date.now;function o(i){var l=0,c=0;return function(){var f=r(),m=n-(f-c);if(c=f,m>0){if(++l>=e)return arguments[0]}else l=0;return i.apply(void 0,arguments)}}return fh=o,fh}var dh,cw;function fw(){if(cw)return dh;cw=1;var e=MR(),n=jR(),r=n(e);return dh=r,dh}var hh,dw;function ws(){if(dw)return hh;dw=1;var e=ho(),n=sw(),r=fw();function o(i,l){return r(n(i,l,e),i+"")}return hh=o,hh}var ph,hw;function pw(){if(hw)return ph;hw=1;function e(n,r,o,i){for(var l=n.length,c=o+(i?1:-1);i?c--:++c<l;)if(r(n[c],c,n))return c;return-1}return ph=e,ph}var mh,mw;function LR(){if(mw)return mh;mw=1;function e(n){return n!==n}return mh=e,mh}var gh,gw;function DR(){if(gw)return gh;gw=1;function e(n,r,o){for(var i=o-1,l=n.length;++i<l;)if(n[i]===r)return i;return-1}return gh=e,gh}var vh,vw;function BR(){if(vw)return vh;vw=1;var e=pw(),n=LR(),r=DR();function o(i,l,c){return l===l?r(i,l,c):e(i,n,c)}return vh=o,vh}var yh,yw;function FR(){if(yw)return yh;yw=1;var e=BR();function n(r,o){var i=r==null?0:r.length;return!!i&&e(r,o,0)>-1}return yh=n,yh}var bh,bw;function qR(){if(bw)return bh;bw=1;function e(n,r,o){for(var i=-1,l=n==null?0:n.length;++i<l;)if(o(r,n[i]))return!0;return!1}return bh=e,bh}var wh,ww;function zR(){if(ww)return wh;ww=1;function e(){}return wh=e,wh}var xh,xw;function HR(){if(xw)return xh;xw=1;var e=o0(),n=zR(),r=cd(),o=1/0,i=e&&1/r(new e([,-0]))[1]==o?function(l){return new e(l)}:n;return xh=i,xh}var _h,_w;function VR(){if(_w)return _h;_w=1;var e=W0(),n=FR(),r=qR(),o=Y0(),i=HR(),l=cd(),c=200;function f(m,g,d){var p=-1,h=n,s=m.length,S=!0,b=[],_=b;if(d)S=!1,h=r;else if(s>=c){var w=g?null:i(m);if(w)return l(w);S=!1,h=o,_=new e}else _=g?[]:b;e:for(;++p<s;){var y=m[p],E=g?g(y):y;if(y=d||y!==0?y:0,S&&E===E){for(var x=_.length;x--;)if(_[x]===E)continue e;g&&_.push(E),b.push(y)}else h(_,E,d)||(_!==b&&_.push(E),b.push(y))}return b}return _h=f,_h}var Sh,Sw;function Ew(){if(Sw)return Sh;Sw=1;var e=Sr(),n=ur();function r(o){return n(o)&&e(o)}return Sh=r,Sh}var Eh,Ow;function UR(){if(Ow)return Eh;Ow=1;var e=sh(),n=ws(),r=VR(),o=Ew(),i=n(function(l){return r(e(l,1,o,!0))});return Eh=i,Eh}var Oh,kw;function WR(){if(kw)return Oh;kw=1;var e=vs();function n(r,o){return e(o,function(i){return r[i]})}return Oh=n,Oh}var kh,Cw;function Aw(){if(Cw)return kh;Cw=1;var e=WR(),n=Gr();function r(o){return o==null?[]:e(o,n(o))}return kh=r,kh}var Ch,Nw;function Mn(){if(Nw)return Ch;Nw=1;var e;if(typeof Mu=="function")try{e={clone:JT(),constant:Vf(),each:q0(),filter:j1(),has:B1(),isArray:Kt(),isEmpty:_R(),isFunction:Di(),isUndefined:z1(),keys:Gr(),map:W1(),reduce:X1(),size:TR(),transform:RR(),union:UR(),values:Aw()}}catch{}return e||(e=window._),Ch=e,Ch}var Ah,Tw;function Nh(){if(Tw)return Ah;Tw=1;var e=Mn();Ah=i;var n="\0",r="\0",o="";function i(d){this._isDirected=e.has(d,"directed")?d.directed:!0,this._isMultigraph=e.has(d,"multigraph")?d.multigraph:!1,this._isCompound=e.has(d,"compound")?d.compound:!1,this._label=void 0,this._defaultNodeLabelFn=e.constant(void 0),this._defaultEdgeLabelFn=e.constant(void 0),this._nodes={},this._isCompound&&(this._parent={},this._children={},this._children[r]={}),this._in={},this._preds={},this._out={},this._sucs={},this._edgeObjs={},this._edgeLabels={}}i.prototype._nodeCount=0,i.prototype._edgeCount=0,i.prototype.isDirected=function(){return this._isDirected},i.prototype.isMultigraph=function(){return this._isMultigraph},i.prototype.isCompound=function(){return this._isCompound},i.prototype.setGraph=function(d){return this._label=d,this},i.prototype.graph=function(){return this._label},i.prototype.setDefaultNodeLabel=function(d){return e.isFunction(d)||(d=e.constant(d)),this._defaultNodeLabelFn=d,this},i.prototype.nodeCount=function(){return this._nodeCount},i.prototype.nodes=function(){return e.keys(this._nodes)},i.prototype.sources=function(){var d=this;return e.filter(this.nodes(),function(p){return e.isEmpty(d._in[p])})},i.prototype.sinks=function(){var d=this;return e.filter(this.nodes(),function(p){return e.isEmpty(d._out[p])})},i.prototype.setNodes=function(d,p){var h=arguments,s=this;return e.each(d,function(S){h.length>1?s.setNode(S,p):s.setNode(S)}),this},i.prototype.setNode=function(d,p){return e.has(this._nodes,d)?(arguments.length>1&&(this._nodes[d]=p),this):(this._nodes[d]=arguments.length>1?p:this._defaultNodeLabelFn(d),this._isCompound&&(this._parent[d]=r,this._children[d]={},this._children[r][d]=!0),this._in[d]={},this._preds[d]={},this._out[d]={},this._sucs[d]={},++this._nodeCount,this)},i.prototype.node=function(d){return this._nodes[d]},i.prototype.hasNode=function(d){return e.has(this._nodes,d)},i.prototype.removeNode=function(d){var p=this;if(e.has(this._nodes,d)){var h=function(s){p.removeEdge(p._edgeObjs[s])};delete this._nodes[d],this._isCompound&&(this._removeFromParentsChildList(d),delete this._parent[d],e.each(this.children(d),function(s){p.setParent(s)}),delete this._children[d]),e.each(e.keys(this._in[d]),h),delete this._in[d],delete this._preds[d],e.each(e.keys(this._out[d]),h),delete this._out[d],delete this._sucs[d],--this._nodeCount}return this},i.prototype.setParent=function(d,p){if(!this._isCompound)throw new Error("Cannot set parent in a non-compound graph");if(e.isUndefined(p))p=r;else{p+="";for(var h=p;!e.isUndefined(h);h=this.parent(h))if(h===d)throw new Error("Setting "+p+" as parent of "+d+" would create a cycle");this.setNode(p)}return this.setNode(d),this._removeFromParentsChildList(d),this._parent[d]=p,this._children[p][d]=!0,this},i.prototype._removeFromParentsChildList=function(d){delete this._children[this._parent[d]][d]},i.prototype.parent=function(d){if(this._isCompound){var p=this._parent[d];if(p!==r)return p}},i.prototype.children=function(d){if(e.isUndefined(d)&&(d=r),this._isCompound){var p=this._children[d];if(p)return e.keys(p)}else{if(d===r)return this.nodes();if(this.hasNode(d))return[]}},i.prototype.predecessors=function(d){var p=this._preds[d];if(p)return e.keys(p)},i.prototype.successors=function(d){var p=this._sucs[d];if(p)return e.keys(p)},i.prototype.neighbors=function(d){var p=this.predecessors(d);if(p)return e.union(p,this.successors(d))},i.prototype.isLeaf=function(d){var p;return this.isDirected()?p=this.successors(d):p=this.neighbors(d),p.length===0},i.prototype.filterNodes=function(d){var p=new this.constructor({directed:this._isDirected,multigraph:this._isMultigraph,compound:this._isCompound});p.setGraph(this.graph());var h=this;e.each(this._nodes,function(b,_){d(_)&&p.setNode(_,b)}),e.each(this._edgeObjs,function(b){p.hasNode(b.v)&&p.hasNode(b.w)&&p.setEdge(b,h.edge(b))});var s={};function S(b){var _=h.parent(b);return _===void 0||p.hasNode(_)?(s[b]=_,_):_ in s?s[_]:S(_)}return this._isCompound&&e.each(p.nodes(),function(b){p.setParent(b,S(b))}),p},i.prototype.setDefaultEdgeLabel=function(d){return e.isFunction(d)||(d=e.constant(d)),this._defaultEdgeLabelFn=d,this},i.prototype.edgeCount=function(){return this._edgeCount},i.prototype.edges=function(){return e.values(this._edgeObjs)},i.prototype.setPath=function(d,p){var h=this,s=arguments;return e.reduce(d,function(S,b){return s.length>1?h.setEdge(S,b,p):h.setEdge(S,b),b}),this},i.prototype.setEdge=function(){var d,p,h,s,S=!1,b=arguments[0];typeof b=="object"&&b!==null&&"v"in b?(d=b.v,p=b.w,h=b.name,arguments.length===2&&(s=arguments[1],S=!0)):(d=b,p=arguments[1],h=arguments[3],arguments.length>2&&(s=arguments[2],S=!0)),d=""+d,p=""+p,e.isUndefined(h)||(h=""+h);var _=f(this._isDirected,d,p,h);if(e.has(this._edgeLabels,_))return S&&(this._edgeLabels[_]=s),this;if(!e.isUndefined(h)&&!this._isMultigraph)throw new Error("Cannot set a named edge when isMultigraph = false");this.setNode(d),this.setNode(p),this._edgeLabels[_]=S?s:this._defaultEdgeLabelFn(d,p,h);var w=m(this._isDirected,d,p,h);return d=w.v,p=w.w,Object.freeze(w),this._edgeObjs[_]=w,l(this._preds[p],d),l(this._sucs[d],p),this._in[p][_]=w,this._out[d][_]=w,this._edgeCount++,this},i.prototype.edge=function(d,p,h){var s=arguments.length===1?g(this._isDirected,arguments[0]):f(this._isDirected,d,p,h);return this._edgeLabels[s]},i.prototype.hasEdge=function(d,p,h){var s=arguments.length===1?g(this._isDirected,arguments[0]):f(this._isDirected,d,p,h);return e.has(this._edgeLabels,s)},i.prototype.removeEdge=function(d,p,h){var s=arguments.length===1?g(this._isDirected,arguments[0]):f(this._isDirected,d,p,h),S=this._edgeObjs[s];return S&&(d=S.v,p=S.w,delete this._edgeLabels[s],delete this._edgeObjs[s],c(this._preds[p],d),c(this._sucs[d],p),delete this._in[p][s],delete this._out[d][s],this._edgeCount--),this},i.prototype.inEdges=function(d,p){var h=this._in[d];if(h){var s=e.values(h);return p?e.filter(s,function(S){return S.v===p}):s}},i.prototype.outEdges=function(d,p){var h=this._out[d];if(h){var s=e.values(h);return p?e.filter(s,function(S){return S.w===p}):s}},i.prototype.nodeEdges=function(d,p){var h=this.inEdges(d,p);if(h)return h.concat(this.outEdges(d,p))};function l(d,p){d[p]?d[p]++:d[p]=1}function c(d,p){--d[p]||delete d[p]}function f(d,p,h,s){var S=""+p,b=""+h;if(!d&&S>b){var _=S;S=b,b=_}return S+o+b+o+(e.isUndefined(s)?n:s)}function m(d,p,h,s){var S=""+p,b=""+h;if(!d&&S>b){var _=S;S=b,b=_}var w={v:S,w:b};return s&&(w.name=s),w}function g(d,p){return f(d,p.v,p.w,p.name)}return Ah}var Th,Rw;function GR(){return Rw||(Rw=1,Th="2.1.8"),Th}var Rh,Pw;function KR(){return Pw||(Pw=1,Rh={Graph:Nh(),version:GR()}),Rh}var Ph,Iw;function YR(){if(Iw)return Ph;Iw=1;var e=Mn(),n=Nh();Ph={write:r,read:l};function r(c){var f={options:{directed:c.isDirected(),multigraph:c.isMultigraph(),compound:c.isCompound()},nodes:o(c),edges:i(c)};return e.isUndefined(c.graph())||(f.value=e.clone(c.graph())),f}function o(c){return e.map(c.nodes(),function(f){var m=c.node(f),g=c.parent(f),d={v:f};return e.isUndefined(m)||(d.value=m),e.isUndefined(g)||(d.parent=g),d})}function i(c){return e.map(c.edges(),function(f){var m=c.edge(f),g={v:f.v,w:f.w};return e.isUndefined(f.name)||(g.name=f.name),e.isUndefined(m)||(g.value=m),g})}function l(c){var f=new n(c.options).setGraph(c.value);return e.each(c.nodes,function(m){f.setNode(m.v,m.value),m.parent&&f.setParent(m.v,m.parent)}),e.each(c.edges,function(m){f.setEdge({v:m.v,w:m.w,name:m.name},m.value)}),f}return Ph}var Ih,Mw;function XR(){if(Mw)return Ih;Mw=1;var e=Mn();Ih=n;function n(r){var o={},i=[],l;function c(f){e.has(o,f)||(o[f]=!0,l.push(f),e.each(r.successors(f),c),e.each(r.predecessors(f),c))}return e.each(r.nodes(),function(f){l=[],c(f),l.length&&i.push(l)}),i}return Ih}var Mh,jw;function Lw(){if(jw)return Mh;jw=1;var e=Mn();Mh=n;function n(){this._arr=[],this._keyIndices={}}return n.prototype.size=function(){return this._arr.length},n.prototype.keys=function(){return this._arr.map(function(r){return r.key})},n.prototype.has=function(r){return e.has(this._keyIndices,r)},n.prototype.priority=function(r){var o=this._keyIndices[r];if(o!==void 0)return this._arr[o].priority},n.prototype.min=function(){if(this.size()===0)throw new Error("Queue underflow");return this._arr[0].key},n.prototype.add=function(r,o){var i=this._keyIndices;if(r=String(r),!e.has(i,r)){var l=this._arr,c=l.length;return i[r]=c,l.push({key:r,priority:o}),this._decrease(c),!0}return!1},n.prototype.removeMin=function(){this._swap(0,this._arr.length-1);var r=this._arr.pop();return delete this._keyIndices[r.key],this._heapify(0),r.key},n.prototype.decrease=function(r,o){var i=this._keyIndices[r];if(o>this._arr[i].priority)throw new Error("New priority is greater than current priority. Key: "+r+" Old: "+this._arr[i].priority+" New: "+o);this._arr[i].priority=o,this._decrease(i)},n.prototype._heapify=function(r){var o=this._arr,i=2*r,l=i+1,c=r;i<o.length&&(c=o[i].priority<o[c].priority?i:c,l<o.length&&(c=o[l].priority<o[c].priority?l:c),c!==r&&(this._swap(r,c),this._heapify(c)))},n.prototype._decrease=function(r){for(var o=this._arr,i=o[r].priority,l;r!==0&&(l=r>>1,!(o[l].priority<i));)this._swap(r,l),r=l},n.prototype._swap=function(r,o){var i=this._arr,l=this._keyIndices,c=i[r],f=i[o];i[r]=f,i[o]=c,l[f.key]=r,l[c.key]=o},Mh}var jh,Dw;function Bw(){if(Dw)return jh;Dw=1;var e=Mn(),n=Lw();jh=o;var r=e.constant(1);function o(l,c,f,m){return i(l,String(c),f||r,m||function(g){return l.outEdges(g)})}function i(l,c,f,m){var g={},d=new n,p,h,s=function(S){var b=S.v!==p?S.v:S.w,_=g[b],w=f(S),y=h.distance+w;if(w<0)throw new Error("dijkstra does not allow negative edge weights. Bad edge: "+S+" Weight: "+w);y<_.distance&&(_.distance=y,_.predecessor=p,d.decrease(b,y))};for(l.nodes().forEach(function(S){var b=S===c?0:Number.POSITIVE_INFINITY;g[S]={distance:b},d.add(S,b)});d.size()>0&&(p=d.removeMin(),h=g[p],h.distance!==Number.POSITIVE_INFINITY);)m(p).forEach(s);return g}return jh}var Lh,Fw;function ZR(){if(Fw)return Lh;Fw=1;var e=Bw(),n=Mn();Lh=r;function r(o,i,l){return n.transform(o.nodes(),function(c,f){c[f]=e(o,f,i,l)},{})}return Lh}var Dh,qw;function zw(){if(qw)return Dh;qw=1;var e=Mn();Dh=n;function n(r){var o=0,i=[],l={},c=[];function f(m){var g=l[m]={onStack:!0,lowlink:o,index:o++};if(i.push(m),r.successors(m).forEach(function(h){e.has(l,h)?l[h].onStack&&(g.lowlink=Math.min(g.lowlink,l[h].index)):(f(h),g.lowlink=Math.min(g.lowlink,l[h].lowlink))}),g.lowlink===g.index){var d=[],p;do p=i.pop(),l[p].onStack=!1,d.push(p);while(m!==p);c.push(d)}}return r.nodes().forEach(function(m){e.has(l,m)||f(m)}),c}return Dh}var Bh,Hw;function QR(){if(Hw)return Bh;Hw=1;var e=Mn(),n=zw();Bh=r;function r(o){return e.filter(n(o),function(i){return i.length>1||i.length===1&&o.hasEdge(i[0],i[0])})}return Bh}var Fh,Vw;function JR(){if(Vw)return Fh;Vw=1;var e=Mn();Fh=r;var n=e.constant(1);function r(i,l,c){return o(i,l||n,c||function(f){return i.outEdges(f)})}function o(i,l,c){var f={},m=i.nodes();return m.forEach(function(g){f[g]={},f[g][g]={distance:0},m.forEach(function(d){g!==d&&(f[g][d]={distance:Number.POSITIVE_INFINITY})}),c(g).forEach(function(d){var p=d.v===g?d.w:d.v,h=l(d);f[g][p]={distance:h,predecessor:g}})}),m.forEach(function(g){var d=f[g];m.forEach(function(p){var h=f[p];m.forEach(function(s){var S=h[g],b=d[s],_=h[s],w=S.distance+b.distance;w<_.distance&&(_.distance=w,_.predecessor=b.predecessor)})})}),f}return Fh}var qh,Uw;function Ww(){if(Uw)return qh;Uw=1;var e=Mn();qh=n,n.CycleException=r;function n(o){var i={},l={},c=[];function f(m){if(e.has(l,m))throw new r;e.has(i,m)||(l[m]=!0,i[m]=!0,e.each(o.predecessors(m),f),delete l[m],c.push(m))}if(e.each(o.sinks(),f),e.size(i)!==o.nodeCount())throw new r;return c}function r(){}return r.prototype=new Error,qh}var zh,Gw;function $R(){if(Gw)return zh;Gw=1;var e=Ww();zh=n;function n(r){try{e(r)}catch(o){if(o instanceof e.CycleException)return!1;throw o}return!0}return zh}var Hh,Kw;function Yw(){if(Kw)return Hh;Kw=1;var e=Mn();Hh=n;function n(o,i,l){e.isArray(i)||(i=[i]);var c=(o.isDirected()?o.successors:o.neighbors).bind(o),f=[],m={};return e.each(i,function(g){if(!o.hasNode(g))throw new Error("Graph does not have node: "+g);r(o,g,l==="post",m,c,f)}),f}function r(o,i,l,c,f,m){e.has(c,i)||(c[i]=!0,l||m.push(i),e.each(f(i),function(g){r(o,g,l,c,f,m)}),l&&m.push(i))}return Hh}var Vh,Xw;function e2(){if(Xw)return Vh;Xw=1;var e=Yw();Vh=n;function n(r,o){return e(r,o,"post")}return Vh}var Uh,Zw;function t2(){if(Zw)return Uh;Zw=1;var e=Yw();Uh=n;function n(r,o){return e(r,o,"pre")}return Uh}var Wh,Qw;function n2(){if(Qw)return Wh;Qw=1;var e=Mn(),n=Nh(),r=Lw();Wh=o;function o(i,l){var c=new n,f={},m=new r,g;function d(h){var s=h.v===g?h.w:h.v,S=m.priority(s);if(S!==void 0){var b=l(h);b<S&&(f[s]=g,m.decrease(s,b))}}if(i.nodeCount()===0)return c;e.each(i.nodes(),function(h){m.add(h,Number.POSITIVE_INFINITY),c.setNode(h)}),m.decrease(i.nodes()[0],0);for(var p=!1;m.size()>0;){if(g=m.removeMin(),e.has(f,g))c.setEdge(g,f[g]);else{if(p)throw new Error("Input graph is not connected: "+i);p=!0}i.nodeEdges(g).forEach(d)}return c}return Wh}var Gh,Jw;function r2(){return Jw||(Jw=1,Gh={components:XR(),dijkstra:Bw(),dijkstraAll:ZR(),findCycles:QR(),floydWarshall:JR(),isAcyclic:$R(),postorder:e2(),preorder:t2(),prim:n2(),tarjan:zw(),topsort:Ww()}),Gh}var Kh,$w;function o2(){if($w)return Kh;$w=1;var e=KR();return Kh={Graph:e.Graph,json:YR(),alg:r2(),version:e.version},Kh}var Yh,ex;function Jn(){if(ex)return Yh;ex=1;var e;if(typeof Mu=="function")try{e=o2()}catch{}return e||(e=window.graphlib),Yh=e,Yh}var Xh,tx;function i2(){if(tx)return Xh;tx=1;var e=k0(),n=1,r=4;function o(i){return e(i,n|r)}return Xh=o,Xh}var Zh,nx;function xs(){if(nx)return Zh;nx=1;var e=Do(),n=Sr(),r=ds(),o=In();function i(l,c,f){if(!o(f))return!1;var m=typeof c;return(m=="number"?n(f)&&r(c,f.length):m=="string"&&c in f)?e(f[c],l):!1}return Zh=i,Zh}var Qh,rx;function a2(){if(rx)return Qh;rx=1;var e=ws(),n=Do(),r=xs(),o=fo(),i=Object.prototype,l=i.hasOwnProperty,c=e(function(f,m){f=Object(f);var g=-1,d=m.length,p=d>2?m[2]:void 0;for(p&&r(m[0],m[1],p)&&(d=1);++g<d;)for(var h=m[g],s=o(h),S=-1,b=s.length;++S<b;){var _=s[S],w=f[_];(w===void 0||n(w,i[_])&&!l.call(f,_))&&(f[_]=h[_])}return f});return Qh=c,Qh}var Jh,ox;function s2(){if(ox)return Jh;ox=1;var e=Er(),n=Sr(),r=Gr();function o(i){return function(l,c,f){var m=Object(l);if(!n(l)){var g=e(c,3);l=r(l),c=function(p){return g(m[p],p,m)}}var d=i(l,c,f);return d>-1?m[g?l[d]:d]:void 0}}return Jh=o,Jh}var $h,ix;function l2(){if(ix)return $h;ix=1;var e=/\s/;function n(r){for(var o=r.length;o--&&e.test(r.charAt(o)););return o}return $h=n,$h}var ep,ax;function u2(){if(ax)return ep;ax=1;var e=l2(),n=/^\s+/;function r(o){return o&&o.slice(0,e(o)+1).replace(n,"")}return ep=r,ep}var tp,sx;function c2(){if(sx)return tp;sx=1;var e=u2(),n=In(),r=zo(),o=NaN,i=/^[-+]0x[0-9a-f]+$/i,l=/^0b[01]+$/i,c=/^0o[0-7]+$/i,f=parseInt;function m(g){if(typeof g=="number")return g;if(r(g))return o;if(n(g)){var d=typeof g.valueOf=="function"?g.valueOf():g;g=n(d)?d+"":d}if(typeof g!="string")return g===0?g:+g;g=e(g);var p=l.test(g);return p||c.test(g)?f(g.slice(2),p?2:8):i.test(g)?o:+g}return tp=m,tp}var np,lx;function ux(){if(lx)return np;lx=1;var e=c2(),n=1/0,r=17976931348623157e292;function o(i){if(!i)return i===0?i:0;if(i=e(i),i===n||i===-n){var l=i<0?-1:1;return l*r}return i===i?i:0}return np=o,np}var rp,cx;function f2(){if(cx)return rp;cx=1;var e=ux();function n(r){var o=e(r),i=o%1;return o===o?i?o-i:o:0}return rp=n,rp}var op,fx;function d2(){if(fx)return op;fx=1;var e=pw(),n=Er(),r=f2(),o=Math.max;function i(l,c,f){var m=l==null?0:l.length;if(!m)return-1;var g=f==null?0:r(f);return g<0&&(g=o(m+g,0)),e(l,n(c,3),g)}return op=i,op}var ip,dx;function h2(){if(dx)return ip;dx=1;var e=s2(),n=d2(),r=e(n);return ip=r,ip}var ap,hx;function px(){if(hx)return ap;hx=1;var e=sh();function n(r){var o=r==null?0:r.length;return o?e(r,1):[]}return ap=n,ap}var sp,mx;function p2(){if(mx)return sp;mx=1;var e=Gf(),n=L0(),r=fo();function o(i,l){return i==null?i:e(i,n(l),r)}return sp=o,sp}var lp,gx;function m2(){if(gx)return lp;gx=1;function e(n){var r=n==null?0:n.length;return r?n[r-1]:void 0}return lp=e,lp}var up,vx;function g2(){if(vx)return up;vx=1;var e=cs(),n=Yf(),r=Er();function o(i,l){var c={};return l=r(l,3),n(i,function(f,m,g){e(c,m,l(f,m,g))}),c}return up=o,up}var cp,yx;function fp(){if(yx)return cp;yx=1;var e=zo();function n(r,o,i){for(var l=-1,c=r.length;++l<c;){var f=r[l],m=o(f);if(m!=null&&(g===void 0?m===m&&!e(m):i(m,g)))var g=m,d=f}return d}return cp=n,cp}var dp,bx;function v2(){if(bx)return dp;bx=1;function e(n,r){return n>r}return dp=e,dp}var hp,wx;function y2(){if(wx)return hp;wx=1;var e=fp(),n=v2(),r=ho();function o(i){return i&&i.length?e(i,r,n):void 0}return hp=o,hp}var pp,xx;function _x(){if(xx)return pp;xx=1;var e=cs(),n=Do();function r(o,i,l){(l!==void 0&&!n(o[i],l)||l===void 0&&!(i in o))&&e(o,i,l)}return pp=r,pp}var mp,Sx;function b2(){if(Sx)return mp;Sx=1;var e=uo(),n=ms(),r=ur(),o="[object Object]",i=Function.prototype,l=Object.prototype,c=i.toString,f=l.hasOwnProperty,m=c.call(Object);function g(d){if(!r(d)||e(d)!=o)return!1;var p=n(d);if(p===null)return!0;var h=f.call(p,"constructor")&&p.constructor;return typeof h=="function"&&h instanceof h&&c.call(h)==m}return mp=g,mp}var gp,Ex;function Ox(){if(Ex)return gp;Ex=1;function e(n,r){if(!(r==="constructor"&&typeof n[r]=="function")&&r!="__proto__")return n[r]}return gp=e,gp}var vp,kx;function w2(){if(kx)return vp;kx=1;var e=Bi(),n=fo();function r(o){return e(o,n(o))}return vp=r,vp}var yp,Cx;function x2(){if(Cx)return yp;Cx=1;var e=_x(),n=Lb(),r=m0(),o=Bb(),i=w0(),l=Fi(),c=Kt(),f=Ew(),m=Fo(),g=Di(),d=In(),p=b2(),h=Hi(),s=Ox(),S=w2();function b(_,w,y,E,x,k,P){var R=s(_,y),j=s(w,y),z=P.get(j);if(z){e(_,y,z);return}var L=k?k(R,j,y+"",_,w,P):void 0,M=L===void 0;if(M){var D=c(j),F=!D&&m(j),B=!D&&!F&&h(j);L=j,D||F||B?c(R)?L=R:f(R)?L=o(R):F?(M=!1,L=n(j,!0)):B?(M=!1,L=r(j,!0)):L=[]:p(j)||l(j)?(L=R,l(R)?L=S(R):(!d(R)||g(R))&&(L=i(j))):M=!1}M&&(P.set(j,L),x(L,j,E,k,P),P.delete(j)),e(_,y,L)}return yp=b,yp}var bp,Ax;function _2(){if(Ax)return bp;Ax=1;var e=us(),n=_x(),r=Gf(),o=x2(),i=In(),l=fo(),c=Ox();function f(m,g,d,p,h){m!==g&&r(g,function(s,S){if(h||(h=new e),i(s))o(m,g,S,d,f,p,h);else{var b=p?p(c(m,S),s,S+"",m,g,h):void 0;b===void 0&&(b=s),n(m,S,b)}},l)}return bp=f,bp}var wp,Nx;function S2(){if(Nx)return wp;Nx=1;var e=ws(),n=xs();function r(o){return e(function(i,l){var c=-1,f=l.length,m=f>1?l[f-1]:void 0,g=f>2?l[2]:void 0;for(m=o.length>3&&typeof m=="function"?(f--,m):void 0,g&&n(l[0],l[1],g)&&(m=f<3?void 0:m,f=1),i=Object(i);++c<f;){var d=l[c];d&&o(i,d,c,m)}return i})}return wp=r,wp}var xp,Tx;function E2(){if(Tx)return xp;Tx=1;var e=_2(),n=S2(),r=n(function(o,i,l){e(o,i,l)});return xp=r,xp}var _p,Rx;function Px(){if(Rx)return _p;Rx=1;function e(n,r){return n<r}return _p=e,_p}var Sp,Ix;function O2(){if(Ix)return Sp;Ix=1;var e=fp(),n=Px(),r=ho();function o(i){return i&&i.length?e(i,r,n):void 0}return Sp=o,Sp}var Ep,Mx;function k2(){if(Mx)return Ep;Mx=1;var e=fp(),n=Er(),r=Px();function o(i,l){return i&&i.length?e(i,n(l,2),r):void 0}return Ep=o,Ep}var Op,jx;function C2(){if(jx)return Op;jx=1;var e=Qn(),n=function(){return e.Date.now()};return Op=n,Op}var kp,Lx;function A2(){if(Lx)return kp;Lx=1;var e=fs(),n=ys(),r=ds(),o=In(),i=Ui();function l(c,f,m,g){if(!o(c))return c;f=n(f,c);for(var d=-1,p=f.length,h=p-1,s=c;s!=null&&++d<p;){var S=i(f[d]),b=m;if(S==="__proto__"||S==="constructor"||S==="prototype")return c;if(d!=h){var _=s[S];b=g?g(_,S,s):void 0,b===void 0&&(b=o(_)?_:r(f[d+1])?[]:{})}e(s,S,b),s=s[S]}return c}return kp=l,kp}var Cp,Dx;function N2(){if(Dx)return Cp;Dx=1;var e=bs(),n=A2(),r=ys();function o(i,l,c){for(var f=-1,m=l.length,g={};++f<m;){var d=l[f],p=e(i,d);c(p,d)&&n(g,r(d,i),p)}return g}return Cp=o,Cp}var Ap,Bx;function T2(){if(Bx)return Ap;Bx=1;var e=N2(),n=C1();function r(o,i){return e(o,i,function(l,c){return n(o,c)})}return Ap=r,Ap}var Np,Fx;function R2(){if(Fx)return Np;Fx=1;var e=px(),n=sw(),r=fw();function o(i){return r(n(i,void 0,e),i+"")}return Np=o,Np}var Tp,qx;function P2(){if(qx)return Tp;qx=1;var e=T2(),n=R2(),r=n(function(o,i){return o==null?{}:e(o,i)});return Tp=r,Tp}var Rp,zx;function I2(){if(zx)return Rp;zx=1;var e=Math.ceil,n=Math.max;function r(o,i,l,c){for(var f=-1,m=n(e((i-o)/(l||1)),0),g=Array(m);m--;)g[c?m:++f]=o,o+=l;return g}return Rp=r,Rp}var Pp,Hx;function M2(){if(Hx)return Pp;Hx=1;var e=I2(),n=xs(),r=ux();function o(i){return function(l,c,f){return f&&typeof f!="number"&&n(l,c,f)&&(c=f=void 0),l=r(l),c===void 0?(c=l,l=0):c=r(c),f=f===void 0?l<c?1:-1:r(f),e(l,c,f,i)}}return Pp=o,Pp}var Ip,Vx;function j2(){if(Vx)return Ip;Vx=1;var e=M2(),n=e();return Ip=n,Ip}var Mp,Ux;function L2(){if(Ux)return Mp;Ux=1;function e(n,r){var o=n.length;for(n.sort(r);o--;)n[o]=n[o].value;return n}return Mp=e,Mp}var jp,Wx;function D2(){if(Wx)return jp;Wx=1;var e=zo();function n(r,o){if(r!==o){var i=r!==void 0,l=r===null,c=r===r,f=e(r),m=o!==void 0,g=o===null,d=o===o,p=e(o);if(!g&&!p&&!f&&r>o||f&&m&&d&&!g&&!p||l&&m&&d||!i&&d||!c)return 1;if(!l&&!f&&!p&&r<o||p&&i&&c&&!l&&!f||g&&i&&c||!m&&c||!d)return-1}return 0}return jp=n,jp}var Lp,Gx;function B2(){if(Gx)return Lp;Gx=1;var e=D2();function n(r,o,i){for(var l=-1,c=r.criteria,f=o.criteria,m=c.length,g=i.length;++l<m;){var d=e(c[l],f[l]);if(d){if(l>=g)return d;var p=i[l];return d*(p=="desc"?-1:1)}}return r.index-o.index}return Lp=n,Lp}var Dp,Kx;function F2(){if(Kx)return Dp;Kx=1;var e=vs(),n=bs(),r=Er(),o=V1(),i=L2(),l=hs(),c=B2(),f=ho(),m=Kt();function g(d,p,h){p.length?p=e(p,function(b){return m(b)?function(_){return n(_,b.length===1?b[0]:b)}:b}):p=[f];var s=-1;p=e(p,l(r));var S=o(d,function(b,_,w){var y=e(p,function(E){return E(b)});return{criteria:y,index:++s,value:b}});return i(S,function(b,_){return c(b,_,h)})}return Dp=g,Dp}var Bp,Yx;function q2(){if(Yx)return Bp;Yx=1;var e=sh(),n=F2(),r=ws(),o=xs(),i=r(function(l,c){if(l==null)return[];var f=c.length;return f>1&&o(l,c[0],c[1])?c=[]:f>2&&o(c[0],c[1],c[2])&&(c=[c[0]]),n(l,e(c,1),[])});return Bp=i,Bp}var Fp,Xx;function z2(){if(Xx)return Fp;Xx=1;var e=y1(),n=0;function r(o){var i=++n;return e(o)+i}return Fp=r,Fp}var qp,Zx;function H2(){if(Zx)return qp;Zx=1;function e(n,r,o){for(var i=-1,l=n.length,c=r.length,f={};++i<l;){var m=i<c?r[i]:void 0;o(f,n[i],m)}return f}return qp=e,qp}var zp,Qx;function V2(){if(Qx)return zp;Qx=1;var e=fs(),n=H2();function r(o,i){return n(o||[],i||[],e)}return zp=r,zp}var Hp,Jx;function Dt(){if(Jx)return Hp;Jx=1;var e;if(typeof Mu=="function")try{e={cloneDeep:i2(),constant:Vf(),defaults:a2(),each:q0(),filter:j1(),find:h2(),flatten:px(),forEach:B0(),forIn:p2(),has:B1(),isUndefined:z1(),last:m2(),map:W1(),mapValues:g2(),max:y2(),merge:E2(),min:O2(),minBy:k2(),now:C2(),pick:P2(),range:j2(),reduce:X1(),sortBy:q2(),uniqueId:z2(),values:Aw(),zipObject:V2()}}catch{}return e||(e=window._),Hp=e,Hp}var Vp,$x;function U2(){if($x)return Vp;$x=1,Vp=e;function e(){var o={};o._next=o._prev=o,this._sentinel=o}e.prototype.dequeue=function(){var o=this._sentinel,i=o._prev;if(i!==o)return n(i),i},e.prototype.enqueue=function(o){var i=this._sentinel;o._prev&&o._next&&n(o),o._next=i._next,i._next._prev=o,i._next=o,o._prev=i},e.prototype.toString=function(){for(var o=[],i=this._sentinel,l=i._prev;l!==i;)o.push(JSON.stringify(l,r)),l=l._prev;return"["+o.join(", ")+"]"};function n(o){o._prev._next=o._next,o._next._prev=o._prev,delete o._next,delete o._prev}function r(o,i){if(o!=="_next"&&o!=="_prev")return i}return Vp}var Up,e_;function W2(){if(e_)return Up;e_=1;var e=Dt(),n=Jn().Graph,r=U2();Up=i;var o=e.constant(1);function i(g,d){if(g.nodeCount()<=1)return[];var p=f(g,d||o),h=l(p.graph,p.buckets,p.zeroIdx);return e.flatten(e.map(h,function(s){return g.outEdges(s.v,s.w)}),!0)}function l(g,d,p){for(var h=[],s=d[d.length-1],S=d[0],b;g.nodeCount();){for(;b=S.dequeue();)c(g,d,p,b);for(;b=s.dequeue();)c(g,d,p,b);if(g.nodeCount()){for(var _=d.length-2;_>0;--_)if(b=d[_].dequeue(),b){h=h.concat(c(g,d,p,b,!0));break}}}return h}function c(g,d,p,h,s){var S=s?[]:void 0;return e.forEach(g.inEdges(h.v),function(b){var _=g.edge(b),w=g.node(b.v);s&&S.push({v:b.v,w:b.w}),w.out-=_,m(d,p,w)}),e.forEach(g.outEdges(h.v),function(b){var _=g.edge(b),w=b.w,y=g.node(w);y.in-=_,m(d,p,y)}),g.removeNode(h.v),S}function f(g,d){var p=new n,h=0,s=0;e.forEach(g.nodes(),function(_){p.setNode(_,{v:_,in:0,out:0})}),e.forEach(g.edges(),function(_){var w=p.edge(_.v,_.w)||0,y=d(_),E=w+y;p.setEdge(_.v,_.w,E),s=Math.max(s,p.node(_.v).out+=y),h=Math.max(h,p.node(_.w).in+=y)});var S=e.range(s+h+3).map(function(){return new r}),b=h+1;return e.forEach(p.nodes(),function(_){m(S,b,p.node(_))}),{graph:p,buckets:S,zeroIdx:b}}function m(g,d,p){p.out?p.in?g[p.out-p.in+d].enqueue(p):g[g.length-1].enqueue(p):g[0].enqueue(p)}return Up}var Wp,t_;function G2(){if(t_)return Wp;t_=1;var e=Dt(),n=W2();Wp={run:r,undo:i};function r(l){var c=l.graph().acyclicer==="greedy"?n(l,f(l)):o(l);e.forEach(c,function(m){var g=l.edge(m);l.removeEdge(m),g.forwardName=m.name,g.reversed=!0,l.setEdge(m.w,m.v,g,e.uniqueId("rev"))});function f(m){return function(g){return m.edge(g).weight}}}function o(l){var c=[],f={},m={};function g(d){e.has(m,d)||(m[d]=!0,f[d]=!0,e.forEach(l.outEdges(d),function(p){e.has(f,p.w)?c.push(p):g(p.w)}),delete f[d])}return e.forEach(l.nodes(),g),c}function i(l){e.forEach(l.edges(),function(c){var f=l.edge(c);if(f.reversed){l.removeEdge(c);var m=f.forwardName;delete f.reversed,delete f.forwardName,l.setEdge(c.w,c.v,f,m)}})}return Wp}var Gp,n_;function wn(){if(n_)return Gp;n_=1;var e=Dt(),n=Jn().Graph;Gp={addDummyNode:r,simplify:o,asNonCompoundGraph:i,successorWeights:l,predecessorWeights:c,intersectRect:f,buildLayerMatrix:m,normalizeRanks:g,removeEmptyRanks:d,addBorderNode:p,maxRank:h,partition:s,time:S,notime:b};function r(_,w,y,E){var x;do x=e.uniqueId(E);while(_.hasNode(x));return y.dummy=w,_.setNode(x,y),x}function o(_){var w=new n().setGraph(_.graph());return e.forEach(_.nodes(),function(y){w.setNode(y,_.node(y))}),e.forEach(_.edges(),function(y){var E=w.edge(y.v,y.w)||{weight:0,minlen:1},x=_.edge(y);w.setEdge(y.v,y.w,{weight:E.weight+x.weight,minlen:Math.max(E.minlen,x.minlen)})}),w}function i(_){var w=new n({multigraph:_.isMultigraph()}).setGraph(_.graph());return e.forEach(_.nodes(),function(y){_.children(y).length||w.setNode(y,_.node(y))}),e.forEach(_.edges(),function(y){w.setEdge(y,_.edge(y))}),w}function l(_){var w=e.map(_.nodes(),function(y){var E={};return e.forEach(_.outEdges(y),function(x){E[x.w]=(E[x.w]||0)+_.edge(x).weight}),E});return e.zipObject(_.nodes(),w)}function c(_){var w=e.map(_.nodes(),function(y){var E={};return e.forEach(_.inEdges(y),function(x){E[x.v]=(E[x.v]||0)+_.edge(x).weight}),E});return e.zipObject(_.nodes(),w)}function f(_,w){var y=_.x,E=_.y,x=w.x-y,k=w.y-E,P=_.width/2,R=_.height/2;if(!x&&!k)throw new Error("Not possible to find intersection inside of the rectangle");var j,z;return Math.abs(k)*P>Math.abs(x)*R?(k<0&&(R=-R),j=R*x/k,z=R):(x<0&&(P=-P),j=P,z=P*k/x),{x:y+j,y:E+z}}function m(_){var w=e.map(e.range(h(_)+1),function(){return[]});return e.forEach(_.nodes(),function(y){var E=_.node(y),x=E.rank;e.isUndefined(x)||(w[x][E.order]=y)}),w}function g(_){var w=e.min(e.map(_.nodes(),function(y){return _.node(y).rank}));e.forEach(_.nodes(),function(y){var E=_.node(y);e.has(E,"rank")&&(E.rank-=w)})}function d(_){var w=e.min(e.map(_.nodes(),function(k){return _.node(k).rank})),y=[];e.forEach(_.nodes(),function(k){var P=_.node(k).rank-w;y[P]||(y[P]=[]),y[P].push(k)});var E=0,x=_.graph().nodeRankFactor;e.forEach(y,function(k,P){e.isUndefined(k)&&P%x!==0?--E:E&&e.forEach(k,function(R){_.node(R).rank+=E})})}function p(_,w,y,E){var x={width:0,height:0};return arguments.length>=4&&(x.rank=y,x.order=E),r(_,"border",x,w)}function h(_){return e.max(e.map(_.nodes(),function(w){var y=_.node(w).rank;if(!e.isUndefined(y))return y}))}function s(_,w){var y={lhs:[],rhs:[]};return e.forEach(_,function(E){w(E)?y.lhs.push(E):y.rhs.push(E)}),y}function S(_,w){var y=e.now();try{return w()}finally{console.log(_+" time: "+(e.now()-y)+"ms")}}function b(_,w){return w()}return Gp}var Kp,r_;function K2(){if(r_)return Kp;r_=1;var e=Dt(),n=wn();Kp={run:r,undo:i};function r(l){l.graph().dummyChains=[],e.forEach(l.edges(),function(c){o(l,c)})}function o(l,c){var f=c.v,m=l.node(f).rank,g=c.w,d=l.node(g).rank,p=c.name,h=l.edge(c),s=h.labelRank;if(d!==m+1){l.removeEdge(c);var S,b,_;for(_=0,++m;m<d;++_,++m)h.points=[],b={width:0,height:0,edgeLabel:h,edgeObj:c,rank:m},S=n.addDummyNode(l,"edge",b,"_d"),m===s&&(b.width=h.width,b.height=h.height,b.dummy="edge-label",b.labelpos=h.labelpos),l.setEdge(f,S,{weight:h.weight},p),_===0&&l.graph().dummyChains.push(S),f=S;l.setEdge(f,g,{weight:h.weight},p)}}function i(l){e.forEach(l.graph().dummyChains,function(c){var f=l.node(c),m=f.edgeLabel,g;for(l.setEdge(f.edgeObj,m);f.dummy;)g=l.successors(c)[0],l.removeNode(c),m.points.push({x:f.x,y:f.y}),f.dummy==="edge-label"&&(m.x=f.x,m.y=f.y,m.width=f.width,m.height=f.height),c=g,f=l.node(c)})}return Kp}var Yp,o_;function _s(){if(o_)return Yp;o_=1;var e=Dt();Yp={longestPath:n,slack:r};function n(o){var i={};function l(c){var f=o.node(c);if(e.has(i,c))return f.rank;i[c]=!0;var m=e.min(e.map(o.outEdges(c),function(g){return l(g.w)-o.edge(g).minlen}));return(m===Number.POSITIVE_INFINITY||m===void 0||m===null)&&(m=0),f.rank=m}e.forEach(o.sources(),l)}function r(o,i){return o.node(i.w).rank-o.node(i.v).rank-o.edge(i).minlen}return Yp}var Xp,i_;function a_(){if(i_)return Xp;i_=1;var e=Dt(),n=Jn().Graph,r=_s().slack;Xp=o;function o(f){var m=new n({directed:!1}),g=f.nodes()[0],d=f.nodeCount();m.setNode(g,{});for(var p,h;i(m,f)<d;)p=l(m,f),h=m.hasNode(p.v)?r(f,p):-r(f,p),c(m,f,h);return m}function i(f,m){function g(d){e.forEach(m.nodeEdges(d),function(p){var h=p.v,s=d===h?p.w:h;!f.hasNode(s)&&!r(m,p)&&(f.setNode(s,{}),f.setEdge(d,s,{}),g(s))})}return e.forEach(f.nodes(),g),f.nodeCount()}function l(f,m){return e.minBy(m.edges(),function(g){if(f.hasNode(g.v)!==f.hasNode(g.w))return r(m,g)})}function c(f,m,g){e.forEach(f.nodes(),function(d){m.node(d).rank+=g})}return Xp}var Zp,s_;function Y2(){if(s_)return Zp;s_=1;var e=Dt(),n=a_(),r=_s().slack,o=_s().longestPath,i=Jn().alg.preorder,l=Jn().alg.postorder,c=wn().simplify;Zp=f,f.initLowLimValues=p,f.initCutValues=m,f.calcCutValue=d,f.leaveEdge=s,f.enterEdge=S,f.exchangeEdges=b;function f(E){E=c(E),o(E);var x=n(E);p(x),m(x,E);for(var k,P;k=s(x);)P=S(x,E,k),b(x,E,k,P)}function m(E,x){var k=l(E,E.nodes());k=k.slice(0,k.length-1),e.forEach(k,function(P){g(E,x,P)})}function g(E,x,k){var P=E.node(k),R=P.parent;E.edge(k,R).cutvalue=d(E,x,k)}function d(E,x,k){var P=E.node(k),R=P.parent,j=!0,z=x.edge(k,R),L=0;return z||(j=!1,z=x.edge(R,k)),L=z.weight,e.forEach(x.nodeEdges(k),function(M){var D=M.v===k,F=D?M.w:M.v;if(F!==R){var B=D===j,U=x.edge(M).weight;if(L+=B?U:-U,w(E,k,F)){var J=E.edge(k,F).cutvalue;L+=B?-J:J}}}),L}function p(E,x){arguments.length<2&&(x=E.nodes()[0]),h(E,{},1,x)}function h(E,x,k,P,R){var j=k,z=E.node(P);return x[P]=!0,e.forEach(E.neighbors(P),function(L){e.has(x,L)||(k=h(E,x,k,L,P))}),z.low=j,z.lim=k++,R?z.parent=R:delete z.parent,k}function s(E){return e.find(E.edges(),function(x){return E.edge(x).cutvalue<0})}function S(E,x,k){var P=k.v,R=k.w;x.hasEdge(P,R)||(P=k.w,R=k.v);var j=E.node(P),z=E.node(R),L=j,M=!1;j.lim>z.lim&&(L=z,M=!0);var D=e.filter(x.edges(),function(F){return M===y(E,E.node(F.v),L)&&M!==y(E,E.node(F.w),L)});return e.minBy(D,function(F){return r(x,F)})}function b(E,x,k,P){var R=k.v,j=k.w;E.removeEdge(R,j),E.setEdge(P.v,P.w,{}),p(E),m(E,x),_(E,x)}function _(E,x){var k=e.find(E.nodes(),function(R){return!x.node(R).parent}),P=i(E,k);P=P.slice(1),e.forEach(P,function(R){var j=E.node(R).parent,z=x.edge(R,j),L=!1;z||(z=x.edge(j,R),L=!0),x.node(R).rank=x.node(j).rank+(L?z.minlen:-z.minlen)})}function w(E,x,k){return E.hasEdge(x,k)}function y(E,x,k){return k.low<=x.lim&&x.lim<=k.lim}return Zp}var Qp,l_;function X2(){if(l_)return Qp;l_=1;var e=_s(),n=e.longestPath,r=a_(),o=Y2();Qp=i;function i(m){switch(m.graph().ranker){case"network-simplex":f(m);break;case"tight-tree":c(m);break;case"longest-path":l(m);break;default:f(m)}}var l=n;function c(m){n(m),r(m)}function f(m){o(m)}return Qp}var Jp,u_;function Z2(){if(u_)return Jp;u_=1;var e=Dt();Jp=n;function n(i){var l=o(i);e.forEach(i.graph().dummyChains,function(c){for(var f=i.node(c),m=f.edgeObj,g=r(i,l,m.v,m.w),d=g.path,p=g.lca,h=0,s=d[h],S=!0;c!==m.w;){if(f=i.node(c),S){for(;(s=d[h])!==p&&i.node(s).maxRank<f.rank;)h++;s===p&&(S=!1)}if(!S){for(;h<d.length-1&&i.node(s=d[h+1]).minRank<=f.rank;)h++;s=d[h]}i.setParent(c,s),c=i.successors(c)[0]}})}function r(i,l,c,f){var m=[],g=[],d=Math.min(l[c].low,l[f].low),p=Math.max(l[c].lim,l[f].lim),h,s;h=c;do h=i.parent(h),m.push(h);while(h&&(l[h].low>d||p>l[h].lim));for(s=h,h=f;(h=i.parent(h))!==s;)g.push(h);return{path:m.concat(g.reverse()),lca:s}}function o(i){var l={},c=0;function f(m){var g=c;e.forEach(i.children(m),f),l[m]={low:g,lim:c++}}return e.forEach(i.children(),f),l}return Jp}var $p,c_;function Q2(){if(c_)return $p;c_=1;var e=Dt(),n=wn();$p={run:r,cleanup:c};function r(f){var m=n.addDummyNode(f,"root",{},"_root"),g=i(f),d=e.max(e.values(g))-1,p=2*d+1;f.graph().nestingRoot=m,e.forEach(f.edges(),function(s){f.edge(s).minlen*=p});var h=l(f)+1;e.forEach(f.children(),function(s){o(f,m,p,h,d,g,s)}),f.graph().nodeRankFactor=p}function o(f,m,g,d,p,h,s){var S=f.children(s);if(!S.length){s!==m&&f.setEdge(m,s,{weight:0,minlen:g});return}var b=n.addBorderNode(f,"_bt"),_=n.addBorderNode(f,"_bb"),w=f.node(s);f.setParent(b,s),w.borderTop=b,f.setParent(_,s),w.borderBottom=_,e.forEach(S,function(y){o(f,m,g,d,p,h,y);var E=f.node(y),x=E.borderTop?E.borderTop:y,k=E.borderBottom?E.borderBottom:y,P=E.borderTop?d:2*d,R=x!==k?1:p-h[s]+1;f.setEdge(b,x,{weight:P,minlen:R,nestingEdge:!0}),f.setEdge(k,_,{weight:P,minlen:R,nestingEdge:!0})}),f.parent(s)||f.setEdge(m,b,{weight:0,minlen:p+h[s]})}function i(f){var m={};function g(d,p){var h=f.children(d);h&&h.length&&e.forEach(h,function(s){g(s,p+1)}),m[d]=p}return e.forEach(f.children(),function(d){g(d,1)}),m}function l(f){return e.reduce(f.edges(),function(m,g){return m+f.edge(g).weight},0)}function c(f){var m=f.graph();f.removeNode(m.nestingRoot),delete m.nestingRoot,e.forEach(f.edges(),function(g){var d=f.edge(g);d.nestingEdge&&f.removeEdge(g)})}return $p}var em,f_;function J2(){if(f_)return em;f_=1;var e=Dt(),n=wn();em=r;function r(i){function l(c){var f=i.children(c),m=i.node(c);if(f.length&&e.forEach(f,l),e.has(m,"minRank")){m.borderLeft=[],m.borderRight=[];for(var g=m.minRank,d=m.maxRank+1;g<d;++g)o(i,"borderLeft","_bl",c,m,g),o(i,"borderRight","_br",c,m,g)}}e.forEach(i.children(),l)}function o(i,l,c,f,m,g){var d={width:0,height:0,rank:g,borderType:l},p=m[l][g-1],h=n.addDummyNode(i,"border",d,c);m[l][g]=h,i.setParent(h,f),p&&i.setEdge(p,h,{weight:1})}return em}var tm,d_;function $2(){if(d_)return tm;d_=1;var e=Dt();tm={adjust:n,undo:r};function n(g){var d=g.graph().rankdir.toLowerCase();(d==="lr"||d==="rl")&&o(g)}function r(g){var d=g.graph().rankdir.toLowerCase();(d==="bt"||d==="rl")&&l(g),(d==="lr"||d==="rl")&&(f(g),o(g))}function o(g){e.forEach(g.nodes(),function(d){i(g.node(d))}),e.forEach(g.edges(),function(d){i(g.edge(d))})}function i(g){var d=g.width;g.width=g.height,g.height=d}function l(g){e.forEach(g.nodes(),function(d){c(g.node(d))}),e.forEach(g.edges(),function(d){var p=g.edge(d);e.forEach(p.points,c),e.has(p,"y")&&c(p)})}function c(g){g.y=-g.y}function f(g){e.forEach(g.nodes(),function(d){m(g.node(d))}),e.forEach(g.edges(),function(d){var p=g.edge(d);e.forEach(p.points,m),e.has(p,"x")&&m(p)})}function m(g){var d=g.x;g.x=g.y,g.y=d}return tm}var nm,h_;function eP(){if(h_)return nm;h_=1;var e=Dt();nm=n;function n(r){var o={},i=e.filter(r.nodes(),function(g){return!r.children(g).length}),l=e.max(e.map(i,function(g){return r.node(g).rank})),c=e.map(e.range(l+1),function(){return[]});function f(g){if(!e.has(o,g)){o[g]=!0;var d=r.node(g);c[d.rank].push(g),e.forEach(r.successors(g),f)}}var m=e.sortBy(i,function(g){return r.node(g).rank});return e.forEach(m,f),c}return nm}var rm,p_;function tP(){if(p_)return rm;p_=1;var e=Dt();rm=n;function n(o,i){for(var l=0,c=1;c<i.length;++c)l+=r(o,i[c-1],i[c]);return l}function r(o,i,l){for(var c=e.zipObject(l,e.map(l,function(h,s){return s})),f=e.flatten(e.map(i,function(h){return e.sortBy(e.map(o.outEdges(h),function(s){return{pos:c[s.w],weight:o.edge(s).weight}}),"pos")}),!0),m=1;m<l.length;)m<<=1;var g=2*m-1;m-=1;var d=e.map(new Array(g),function(){return 0}),p=0;return e.forEach(f.forEach(function(h){var s=h.pos+m;d[s]+=h.weight;for(var S=0;s>0;)s%2&&(S+=d[s+1]),s=s-1>>1,d[s]+=h.weight;p+=h.weight*S})),p}return rm}var om,m_;function nP(){if(m_)return om;m_=1;var e=Dt();om=n;function n(r,o){return e.map(o,function(i){var l=r.inEdges(i);if(l.length){var c=e.reduce(l,function(f,m){var g=r.edge(m),d=r.node(m.v);return{sum:f.sum+g.weight*d.order,weight:f.weight+g.weight}},{sum:0,weight:0});return{v:i,barycenter:c.sum/c.weight,weight:c.weight}}else return{v:i}})}return om}var im,g_;function rP(){if(g_)return im;g_=1;var e=Dt();im=n;function n(i,l){var c={};e.forEach(i,function(m,g){var d=c[m.v]={indegree:0,in:[],out:[],vs:[m.v],i:g};e.isUndefined(m.barycenter)||(d.barycenter=m.barycenter,d.weight=m.weight)}),e.forEach(l.edges(),function(m){var g=c[m.v],d=c[m.w];!e.isUndefined(g)&&!e.isUndefined(d)&&(d.indegree++,g.out.push(c[m.w]))});var f=e.filter(c,function(m){return!m.indegree});return r(f)}function r(i){var l=[];function c(g){return function(d){d.merged||(e.isUndefined(d.barycenter)||e.isUndefined(g.barycenter)||d.barycenter>=g.barycenter)&&o(g,d)}}function f(g){return function(d){d.in.push(g),--d.indegree===0&&i.push(d)}}for(;i.length;){var m=i.pop();l.push(m),e.forEach(m.in.reverse(),c(m)),e.forEach(m.out,f(m))}return e.map(e.filter(l,function(g){return!g.merged}),function(g){return e.pick(g,["vs","i","barycenter","weight"])})}function o(i,l){var c=0,f=0;i.weight&&(c+=i.barycenter*i.weight,f+=i.weight),l.weight&&(c+=l.barycenter*l.weight,f+=l.weight),i.vs=l.vs.concat(i.vs),i.barycenter=c/f,i.weight=f,i.i=Math.min(l.i,i.i),l.merged=!0}return im}var am,v_;function oP(){if(v_)return am;v_=1;var e=Dt(),n=wn();am=r;function r(l,c){var f=n.partition(l,function(b){return e.has(b,"barycenter")}),m=f.lhs,g=e.sortBy(f.rhs,function(b){return-b.i}),d=[],p=0,h=0,s=0;m.sort(i(!!c)),s=o(d,g,s),e.forEach(m,function(b){s+=b.vs.length,d.push(b.vs),p+=b.barycenter*b.weight,h+=b.weight,s=o(d,g,s)});var S={vs:e.flatten(d,!0)};return h&&(S.barycenter=p/h,S.weight=h),S}function o(l,c,f){for(var m;c.length&&(m=e.last(c)).i<=f;)c.pop(),l.push(m.vs),f++;return f}function i(l){return function(c,f){return c.barycenter<f.barycenter?-1:c.barycenter>f.barycenter?1:l?f.i-c.i:c.i-f.i}}return am}var sm,y_;function iP(){if(y_)return sm;y_=1;var e=Dt(),n=nP(),r=rP(),o=oP();sm=i;function i(f,m,g,d){var p=f.children(m),h=f.node(m),s=h?h.borderLeft:void 0,S=h?h.borderRight:void 0,b={};s&&(p=e.filter(p,function(k){return k!==s&&k!==S}));var _=n(f,p);e.forEach(_,function(k){if(f.children(k.v).length){var P=i(f,k.v,g,d);b[k.v]=P,e.has(P,"barycenter")&&c(k,P)}});var w=r(_,g);l(w,b);var y=o(w,d);if(s&&(y.vs=e.flatten([s,y.vs,S],!0),f.predecessors(s).length)){var E=f.node(f.predecessors(s)[0]),x=f.node(f.predecessors(S)[0]);e.has(y,"barycenter")||(y.barycenter=0,y.weight=0),y.barycenter=(y.barycenter*y.weight+E.order+x.order)/(y.weight+2),y.weight+=2}return y}function l(f,m){e.forEach(f,function(g){g.vs=e.flatten(g.vs.map(function(d){return m[d]?m[d].vs:d}),!0)})}function c(f,m){e.isUndefined(f.barycenter)?(f.barycenter=m.barycenter,f.weight=m.weight):(f.barycenter=(f.barycenter*f.weight+m.barycenter*m.weight)/(f.weight+m.weight),f.weight+=m.weight)}return sm}var lm,b_;function aP(){if(b_)return lm;b_=1;var e=Dt(),n=Jn().Graph;lm=r;function r(i,l,c){var f=o(i),m=new n({compound:!0}).setGraph({root:f}).setDefaultNodeLabel(function(g){return i.node(g)});return e.forEach(i.nodes(),function(g){var d=i.node(g),p=i.parent(g);(d.rank===l||d.minRank<=l&&l<=d.maxRank)&&(m.setNode(g),m.setParent(g,p||f),e.forEach(i[c](g),function(h){var s=h.v===g?h.w:h.v,S=m.edge(s,g),b=e.isUndefined(S)?0:S.weight;m.setEdge(s,g,{weight:i.edge(h).weight+b})}),e.has(d,"minRank")&&m.setNode(g,{borderLeft:d.borderLeft[l],borderRight:d.borderRight[l]}))}),m}function o(i){for(var l;i.hasNode(l=e.uniqueId("_root")););return l}return lm}var um,w_;function sP(){if(w_)return um;w_=1;var e=Dt();um=n;function n(r,o,i){var l={},c;e.forEach(i,function(f){for(var m=r.parent(f),g,d;m;){if(g=r.parent(m),g?(d=l[g],l[g]=m):(d=c,c=m),d&&d!==m){o.setEdge(d,m);return}m=g}})}return um}var cm,x_;function lP(){if(x_)return cm;x_=1;var e=Dt(),n=eP(),r=tP(),o=iP(),i=aP(),l=sP(),c=Jn().Graph,f=wn();cm=m;function m(h){var s=f.maxRank(h),S=g(h,e.range(1,s+1),"inEdges"),b=g(h,e.range(s-1,-1,-1),"outEdges"),_=n(h);p(h,_);for(var w=Number.POSITIVE_INFINITY,y,E=0,x=0;x<4;++E,++x){d(E%2?S:b,E%4>=2),_=f.buildLayerMatrix(h);var k=r(h,_);k<w&&(x=0,y=e.cloneDeep(_),w=k)}p(h,y)}function g(h,s,S){return e.map(s,function(b){return i(h,b,S)})}function d(h,s){var S=new c;e.forEach(h,function(b){var _=b.graph().root,w=o(b,_,S,s);e.forEach(w.vs,function(y,E){b.node(y).order=E}),l(b,S,w.vs)})}function p(h,s){e.forEach(s,function(S){e.forEach(S,function(b,_){h.node(b).order=_})})}return cm}var fm,__;function uP(){if(__)return fm;__=1;var e=Dt(),n=Jn().Graph,r=wn();fm={positionX:S,findType1Conflicts:o,findType2Conflicts:i,addConflict:c,hasConflict:f,verticalAlignment:m,horizontalCompaction:g,alignCoordinates:h,findSmallestWidthAlignment:p,balance:s};function o(w,y){var E={};function x(k,P){var R=0,j=0,z=k.length,L=e.last(P);return e.forEach(P,function(M,D){var F=l(w,M),B=F?w.node(F).order:z;(F||M===L)&&(e.forEach(P.slice(j,D+1),function(U){e.forEach(w.predecessors(U),function(J){var oe=w.node(J),de=oe.order;(de<R||B<de)&&!(oe.dummy&&w.node(U).dummy)&&c(E,J,U)})}),j=D+1,R=B)}),P}return e.reduce(y,x),E}function i(w,y){var E={};function x(P,R,j,z,L){var M;e.forEach(e.range(R,j),function(D){M=P[D],w.node(M).dummy&&e.forEach(w.predecessors(M),function(F){var B=w.node(F);B.dummy&&(B.order<z||B.order>L)&&c(E,F,M)})})}function k(P,R){var j=-1,z,L=0;return e.forEach(R,function(M,D){if(w.node(M).dummy==="border"){var F=w.predecessors(M);F.length&&(z=w.node(F[0]).order,x(R,L,D,j,z),L=D,j=z)}x(R,L,R.length,z,P.length)}),R}return e.reduce(y,k),E}function l(w,y){if(w.node(y).dummy)return e.find(w.predecessors(y),function(E){return w.node(E).dummy})}function c(w,y,E){if(y>E){var x=y;y=E,E=x}var k=w[y];k||(w[y]=k={}),k[E]=!0}function f(w,y,E){if(y>E){var x=y;y=E,E=x}return e.has(w[y],E)}function m(w,y,E,x){var k={},P={},R={};return e.forEach(y,function(j){e.forEach(j,function(z,L){k[z]=z,P[z]=z,R[z]=L})}),e.forEach(y,function(j){var z=-1;e.forEach(j,function(L){var M=x(L);if(M.length){M=e.sortBy(M,function(J){return R[J]});for(var D=(M.length-1)/2,F=Math.floor(D),B=Math.ceil(D);F<=B;++F){var U=M[F];P[L]===L&&z<R[U]&&!f(E,L,U)&&(P[U]=L,P[L]=k[L]=k[U],z=R[U])}}})}),{root:k,align:P}}function g(w,y,E,x,k){var P={},R=d(w,y,E,k),j=k?"borderLeft":"borderRight";function z(D,F){for(var B=R.nodes(),U=B.pop(),J={};U;)J[U]?D(U):(J[U]=!0,B.push(U),B=B.concat(F(U))),U=B.pop()}function L(D){P[D]=R.inEdges(D).reduce(function(F,B){return Math.max(F,P[B.v]+R.edge(B))},0)}function M(D){var F=R.outEdges(D).reduce(function(U,J){return Math.min(U,P[J.w]-R.edge(J))},Number.POSITIVE_INFINITY),B=w.node(D);F!==Number.POSITIVE_INFINITY&&B.borderType!==j&&(P[D]=Math.max(P[D],F))}return z(L,R.predecessors.bind(R)),z(M,R.successors.bind(R)),e.forEach(x,function(D){P[D]=P[E[D]]}),P}function d(w,y,E,x){var k=new n,P=w.graph(),R=b(P.nodesep,P.edgesep,x);return e.forEach(y,function(j){var z;e.forEach(j,function(L){var M=E[L];if(k.setNode(M),z){var D=E[z],F=k.edge(D,M);k.setEdge(D,M,Math.max(R(w,L,z),F||0))}z=L})}),k}function p(w,y){return e.minBy(e.values(y),function(E){var x=Number.NEGATIVE_INFINITY,k=Number.POSITIVE_INFINITY;return e.forIn(E,function(P,R){var j=_(w,R)/2;x=Math.max(P+j,x),k=Math.min(P-j,k)}),x-k})}function h(w,y){var E=e.values(y),x=e.min(E),k=e.max(E);e.forEach(["u","d"],function(P){e.forEach(["l","r"],function(R){var j=P+R,z=w[j],L;if(z!==y){var M=e.values(z);L=R==="l"?x-e.min(M):k-e.max(M),L&&(w[j]=e.mapValues(z,function(D){return D+L}))}})})}function s(w,y){return e.mapValues(w.ul,function(E,x){if(y)return w[y.toLowerCase()][x];var k=e.sortBy(e.map(w,x));return(k[1]+k[2])/2})}function S(w){var y=r.buildLayerMatrix(w),E=e.merge(o(w,y),i(w,y)),x={},k;e.forEach(["u","d"],function(R){k=R==="u"?y:e.values(y).reverse(),e.forEach(["l","r"],function(j){j==="r"&&(k=e.map(k,function(D){return e.values(D).reverse()}));var z=(R==="u"?w.predecessors:w.successors).bind(w),L=m(w,k,E,z),M=g(w,k,L.root,L.align,j==="r");j==="r"&&(M=e.mapValues(M,function(D){return-D})),x[R+j]=M})});var P=p(w,x);return h(x,P),s(x,w.graph().align)}function b(w,y,E){return function(x,k,P){var R=x.node(k),j=x.node(P),z=0,L;if(z+=R.width/2,e.has(R,"labelpos"))switch(R.labelpos.toLowerCase()){case"l":L=-R.width/2;break;case"r":L=R.width/2;break}if(L&&(z+=E?L:-L),L=0,z+=(R.dummy?y:w)/2,z+=(j.dummy?y:w)/2,z+=j.width/2,e.has(j,"labelpos"))switch(j.labelpos.toLowerCase()){case"l":L=j.width/2;break;case"r":L=-j.width/2;break}return L&&(z+=E?L:-L),L=0,z}}function _(w,y){return w.node(y).width}return fm}var dm,S_;function cP(){if(S_)return dm;S_=1;var e=Dt(),n=wn(),r=uP().positionX;dm=o;function o(l){l=n.asNonCompoundGraph(l),i(l),e.forEach(r(l),function(c,f){l.node(f).x=c})}function i(l){var c=n.buildLayerMatrix(l),f=l.graph().ranksep,m=0;e.forEach(c,function(g){var d=e.max(e.map(g,function(p){return l.node(p).height}));e.forEach(g,function(p){l.node(p).y=m+d/2}),m+=d+f})}return dm}var hm,E_;function fP(){if(E_)return hm;E_=1;var e=Dt(),n=G2(),r=K2(),o=X2(),i=wn().normalizeRanks,l=Z2(),c=wn().removeEmptyRanks,f=Q2(),m=J2(),g=$2(),d=lP(),p=cP(),h=wn(),s=Jn().Graph;hm=S;function S(te,re){var Z=re&&re.debugTiming?h.time:h.notime;Z("layout",function(){var se=Z(" buildLayoutGraph",function(){return z(te)});Z(" runLayout",function(){b(se,Z)}),Z(" updateInputGraph",function(){_(te,se)})})}function b(te,re){re(" makeSpaceForEdgeLabels",function(){L(te)}),re(" removeSelfEdges",function(){Y(te)}),re(" acyclic",function(){n.run(te)}),re(" nestingGraph.run",function(){f.run(te)}),re(" rank",function(){o(h.asNonCompoundGraph(te))}),re(" injectEdgeLabelProxies",function(){M(te)}),re(" removeEmptyRanks",function(){c(te)}),re(" nestingGraph.cleanup",function(){f.cleanup(te)}),re(" normalizeRanks",function(){i(te)}),re(" assignRankMinMax",function(){D(te)}),re(" removeEdgeLabelProxies",function(){F(te)}),re(" normalize.run",function(){r.run(te)}),re(" parentDummyChains",function(){l(te)}),re(" addBorderSegments",function(){m(te)}),re(" order",function(){d(te)}),re(" insertSelfEdges",function(){ee(te)}),re(" adjustCoordinateSystem",function(){g.adjust(te)}),re(" position",function(){p(te)}),re(" positionSelfEdges",function(){W(te)}),re(" removeBorderNodes",function(){de(te)}),re(" normalize.undo",function(){r.undo(te)}),re(" fixupEdgeLabelCoords",function(){J(te)}),re(" undoCoordinateSystem",function(){g.undo(te)}),re(" translateGraph",function(){B(te)}),re(" assignNodeIntersects",function(){U(te)}),re(" reversePoints",function(){oe(te)}),re(" acyclic.undo",function(){n.undo(te)})}function _(te,re){e.forEach(te.nodes(),function(Z){var se=te.node(Z),pe=re.node(Z);se&&(se.x=pe.x,se.y=pe.y,re.children(Z).length&&(se.width=pe.width,se.height=pe.height))}),e.forEach(te.edges(),function(Z){var se=te.edge(Z),pe=re.edge(Z);se.points=pe.points,e.has(pe,"x")&&(se.x=pe.x,se.y=pe.y)}),te.graph().width=re.graph().width,te.graph().height=re.graph().height}var w=["nodesep","edgesep","ranksep","marginx","marginy"],y={ranksep:50,edgesep:20,nodesep:50,rankdir:"tb"},E=["acyclicer","ranker","rankdir","align"],x=["width","height"],k={width:0,height:0},P=["minlen","weight","width","height","labeloffset"],R={minlen:1,weight:1,width:0,height:0,labeloffset:10,labelpos:"r"},j=["labelpos"];function z(te){var re=new s({multigraph:!0,compound:!0}),Z=ae(te.graph());return re.setGraph(e.merge({},y,ne(Z,w),e.pick(Z,E))),e.forEach(te.nodes(),function(se){var pe=ae(te.node(se));re.setNode(se,e.defaults(ne(pe,x),k)),re.setParent(se,te.parent(se))}),e.forEach(te.edges(),function(se){var pe=ae(te.edge(se));re.setEdge(se,e.merge({},R,ne(pe,P),e.pick(pe,j)))}),re}function L(te){var re=te.graph();re.ranksep/=2,e.forEach(te.edges(),function(Z){var se=te.edge(Z);se.minlen*=2,se.labelpos.toLowerCase()!=="c"&&(re.rankdir==="TB"||re.rankdir==="BT"?se.width+=se.labeloffset:se.height+=se.labeloffset)})}function M(te){e.forEach(te.edges(),function(re){var Z=te.edge(re);if(Z.width&&Z.height){var se=te.node(re.v),pe=te.node(re.w),ge={rank:(pe.rank-se.rank)/2+se.rank,e:re};h.addDummyNode(te,"edge-proxy",ge,"_ep")}})}function D(te){var re=0;e.forEach(te.nodes(),function(Z){var se=te.node(Z);se.borderTop&&(se.minRank=te.node(se.borderTop).rank,se.maxRank=te.node(se.borderBottom).rank,re=e.max(re,se.maxRank))}),te.graph().maxRank=re}function F(te){e.forEach(te.nodes(),function(re){var Z=te.node(re);Z.dummy==="edge-proxy"&&(te.edge(Z.e).labelRank=Z.rank,te.removeNode(re))})}function B(te){var re=Number.POSITIVE_INFINITY,Z=0,se=Number.POSITIVE_INFINITY,pe=0,ge=te.graph(),be=ge.marginx||0,Ae=ge.marginy||0;function Ue(Ve){var Fe=Ve.x,Pe=Ve.y,ut=Ve.width,Ce=Ve.height;re=Math.min(re,Fe-ut/2),Z=Math.max(Z,Fe+ut/2),se=Math.min(se,Pe-Ce/2),pe=Math.max(pe,Pe+Ce/2)}e.forEach(te.nodes(),function(Ve){Ue(te.node(Ve))}),e.forEach(te.edges(),function(Ve){var Fe=te.edge(Ve);e.has(Fe,"x")&&Ue(Fe)}),re-=be,se-=Ae,e.forEach(te.nodes(),function(Ve){var Fe=te.node(Ve);Fe.x-=re,Fe.y-=se}),e.forEach(te.edges(),function(Ve){var Fe=te.edge(Ve);e.forEach(Fe.points,function(Pe){Pe.x-=re,Pe.y-=se}),e.has(Fe,"x")&&(Fe.x-=re),e.has(Fe,"y")&&(Fe.y-=se)}),ge.width=Z-re+be,ge.height=pe-se+Ae}function U(te){e.forEach(te.edges(),function(re){var Z=te.edge(re),se=te.node(re.v),pe=te.node(re.w),ge,be;Z.points?(ge=Z.points[0],be=Z.points[Z.points.length-1]):(Z.points=[],ge=pe,be=se),Z.points.unshift(h.intersectRect(se,ge)),Z.points.push(h.intersectRect(pe,be))})}function J(te){e.forEach(te.edges(),function(re){var Z=te.edge(re);if(e.has(Z,"x"))switch((Z.labelpos==="l"||Z.labelpos==="r")&&(Z.width-=Z.labeloffset),Z.labelpos){case"l":Z.x-=Z.width/2+Z.labeloffset;break;case"r":Z.x+=Z.width/2+Z.labeloffset;break}})}function oe(te){e.forEach(te.edges(),function(re){var Z=te.edge(re);Z.reversed&&Z.points.reverse()})}function de(te){e.forEach(te.nodes(),function(re){if(te.children(re).length){var Z=te.node(re),se=te.node(Z.borderTop),pe=te.node(Z.borderBottom),ge=te.node(e.last(Z.borderLeft)),be=te.node(e.last(Z.borderRight));Z.width=Math.abs(be.x-ge.x),Z.height=Math.abs(pe.y-se.y),Z.x=ge.x+Z.width/2,Z.y=se.y+Z.height/2}}),e.forEach(te.nodes(),function(re){te.node(re).dummy==="border"&&te.removeNode(re)})}function Y(te){e.forEach(te.edges(),function(re){if(re.v===re.w){var Z=te.node(re.v);Z.selfEdges||(Z.selfEdges=[]),Z.selfEdges.push({e:re,label:te.edge(re)}),te.removeEdge(re)}})}function ee(te){var re=h.buildLayerMatrix(te);e.forEach(re,function(Z){var se=0;e.forEach(Z,function(pe,ge){var be=te.node(pe);be.order=ge+se,e.forEach(be.selfEdges,function(Ae){h.addDummyNode(te,"selfedge",{width:Ae.label.width,height:Ae.label.height,rank:be.rank,order:ge+ ++se,e:Ae.e,label:Ae.label},"_se")}),delete be.selfEdges})})}function W(te){e.forEach(te.nodes(),function(re){var Z=te.node(re);if(Z.dummy==="selfedge"){var se=te.node(Z.e.v),pe=se.x+se.width/2,ge=se.y,be=Z.x-pe,Ae=se.height/2;te.setEdge(Z.e,Z.label),te.removeNode(re),Z.label.points=[{x:pe+2*be/3,y:ge-Ae},{x:pe+5*be/6,y:ge-Ae},{x:pe+be,y:ge},{x:pe+5*be/6,y:ge+Ae},{x:pe+2*be/3,y:ge+Ae}],Z.label.x=Z.x,Z.label.y=Z.y}})}function ne(te,re){return e.mapValues(e.pick(te,re),Number)}function ae(te){var re={};return e.forEach(te,function(Z,se){re[se.toLowerCase()]=Z}),re}return hm}var pm,O_;function dP(){if(O_)return pm;O_=1;var e=Dt(),n=wn(),r=Jn().Graph;pm={debugOrdering:o};function o(i){var l=n.buildLayerMatrix(i),c=new r({compound:!0,multigraph:!0}).setGraph({});return e.forEach(i.nodes(),function(f){c.setNode(f,{label:f}),c.setParent(f,"layer"+i.node(f).rank)}),e.forEach(i.edges(),function(f){c.setEdge(f.v,f.w,{},f.name)}),e.forEach(l,function(f,m){var g="layer"+m;c.setNode(g,{rank:"same"}),e.reduce(f,function(d,p){return c.setEdge(d,p,{style:"invis"}),p})}),c}return pm}var mm,k_;function hP(){return k_||(k_=1,mm="0.8.5"),mm}var gm,C_;function pP(){return C_||(C_=1,gm={graphlib:Jn(),layout:fP(),debug:dP(),util:{time:wn().time,notime:wn().notime},version:hP()}),gm}var mP=pP();const Wi=Iu(mP);function Ho(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function Or(e){return function n(r){return arguments.length===0||Ho(r)?n:e.apply(this,arguments)}}function A_(e){return function n(r,o){switch(arguments.length){case 0:return n;case 1:return Ho(r)?n:Or(function(i){return e(r,i)});default:return Ho(r)&&Ho(o)?n:Ho(r)?Or(function(i){return e(i,o)}):Ho(o)?Or(function(i){return e(r,i)}):e(r,o)}}}const gP=Array.isArray||function(n){return n!=null&&n.length>=0&&Object.prototype.toString.call(n)==="[object Array]"};function vP(e){return Object.prototype.toString.call(e)==="[object String]"}function Ss(e,n){return Object.prototype.hasOwnProperty.call(n,e)}var N_=Object.prototype.toString,T_=(function(){return N_.call(arguments)==="[object Arguments]"?function(n){return N_.call(n)==="[object Arguments]"}:function(n){return Ss("callee",n)}})(),yP=!{toString:null}.propertyIsEnumerable("toString"),R_=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],P_=(function(){return arguments.propertyIsEnumerable("length")})(),bP=function(n,r){for(var o=0;o<n.length;){if(n[o]===r)return!0;o+=1}return!1},I_=Or(typeof Object.keys=="function"&&!P_?function(n){return Object(n)!==n?[]:Object.keys(n)}:function(n){if(Object(n)!==n)return[];var r,o,i=[],l=P_&&T_(n);for(r in n)Ss(r,n)&&(!l||r!=="length")&&(i[i.length]=r);if(yP)for(o=R_.length-1;o>=0;)r=R_[o],Ss(r,n)&&!bP(i,r)&&(i[i.length]=r),o-=1;return i}),cr=Or(function(n){return n==null}),M_=Or(function(n){return n===null?"Null":n===void 0?"Undefined":Object.prototype.toString.call(n).slice(8,-1)});function j_(e){for(var n=[],r;!(r=e.next()).done;)n.push(r.value);return n}function L_(e,n,r){for(var o=0,i=r.length;o<i;){if(e(n,r[o]))return!0;o+=1}return!1}function wP(e){var n=String(e).match(/^function (\w*)/);return n==null?"":n[1]}function xP(e,n){return e===n?e!==0||1/e===1/n:e!==e&&n!==n}const vm=typeof Object.is=="function"?Object.is:xP;function D_(e,n,r,o){var i=j_(e),l=j_(n);function c(f,m){return ym(f,m,r.slice(),o.slice())}return!L_(function(f,m){return!L_(c,m,f)},l,i)}function ym(e,n,r,o){if(vm(e,n))return!0;var i=M_(e);if(i!==M_(n)||e==null||n==null)return!1;if(typeof e["fantasy-land/equals"]=="function"||typeof n["fantasy-land/equals"]=="function")return typeof e["fantasy-land/equals"]=="function"&&e["fantasy-land/equals"](n)&&typeof n["fantasy-land/equals"]=="function"&&n["fantasy-land/equals"](e);if(typeof e.equals=="function"||typeof n.equals=="function")return typeof e.equals=="function"&&e.equals(n)&&typeof n.equals=="function"&&n.equals(e);switch(i){case"Arguments":case"Array":case"Object":if(typeof e.constructor=="function"&&wP(e.constructor)==="Promise")return e===n;break;case"Boolean":case"Number":case"String":if(!(typeof e==typeof n&&vm(e.valueOf(),n.valueOf())))return!1;break;case"Date":if(!vm(e.valueOf(),n.valueOf()))return!1;break;case"Error":return e.name===n.name&&e.message===n.message;case"RegExp":if(!(e.source===n.source&&e.global===n.global&&e.ignoreCase===n.ignoreCase&&e.multiline===n.multiline&&e.sticky===n.sticky&&e.unicode===n.unicode))return!1;break}for(var l=r.length-1;l>=0;){if(r[l]===e)return o[l]===n;l-=1}switch(i){case"Map":return e.size!==n.size?!1:D_(e.entries(),n.entries(),r.concat([e]),o.concat([n]));case"Set":return e.size!==n.size?!1:D_(e.values(),n.values(),r.concat([e]),o.concat([n]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var c=I_(e);if(c.length!==I_(n).length)return!1;var f=r.concat([e]),m=o.concat([n]);for(l=c.length-1;l>=0;){var g=c[l];if(!(Ss(g,n)&&ym(n[g],e[g],f,m)))return!1;l-=1}return!0}var _P=A_(function(n,r){return ym(n,r,[],[])});function SP(e){return Object.prototype.toString.call(e)==="[object Object]"}var EP=Or(function(n){return n!=null&&typeof n["fantasy-land/empty"]=="function"?n["fantasy-land/empty"]():n!=null&&n.constructor!=null&&typeof n.constructor["fantasy-land/empty"]=="function"?n.constructor["fantasy-land/empty"]():n!=null&&typeof n.empty=="function"?n.empty():n!=null&&n.constructor!=null&&typeof n.constructor.empty=="function"?n.constructor.empty():gP(n)?[]:vP(n)?"":SP(n)?{}:T_(n)?(function(){return arguments})():void 0}),$t=Or(function(n){return n!=null&&_P(n,EP(n))}),B_=A_(function(n,r){for(var o={},i={},l=0,c=n.length;l<c;)i[n[l]]=1,l+=1;for(var f in r)i.hasOwnProperty(f)||(o[f]=r[f]);return o});function un(e){if(typeof e=="string"||typeof e=="number")return""+e;let n="";if(Array.isArray(e))for(let r=0,o;r<e.length;r++)(o=un(e[r]))!==""&&(n+=(n&&" ")+o);else for(let r in e)e[r]&&(n+=(n&&" ")+r);return n}var bm={exports:{}},wm={},xm={exports:{}},_m={};/**
|
|
2
2
|
* @license React
|
|
3
3
|
* use-sync-external-store-shim.production.min.js
|
|
4
4
|
*
|
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
*
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
|
-
*/var
|
|
9
|
+
*/var F_;function OP(){if(F_)return _m;F_=1;var e=wt.default;function n(p,h){return p===h&&(p!==0||1/p===1/h)||p!==p&&h!==h}var r=typeof Object.is=="function"?Object.is:n,o=e.useState,i=e.useEffect,l=e.useLayoutEffect,c=e.useDebugValue;function f(p,h){var s=h(),S=o({inst:{value:s,getSnapshot:h}}),b=S[0].inst,_=S[1];return l(function(){b.value=s,b.getSnapshot=h,m(b)&&_({inst:b})},[p,s,h]),i(function(){return m(b)&&_({inst:b}),p(function(){m(b)&&_({inst:b})})},[p]),c(s),s}function m(p){var h=p.getSnapshot;p=p.value;try{var s=h();return!r(p,s)}catch{return!0}}function g(p,h){return h()}var d=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?g:f;return _m.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,_m}var q_;function kP(){return q_||(q_=1,xm.exports=OP()),xm.exports}/**
|
|
10
10
|
* @license React
|
|
11
11
|
* use-sync-external-store-shim/with-selector.production.min.js
|
|
12
12
|
*
|
|
@@ -14,56 +14,163 @@
|
|
|
14
14
|
*
|
|
15
15
|
* This source code is licensed under the MIT license found in the
|
|
16
16
|
* LICENSE file in the root directory of this source tree.
|
|
17
|
-
*/var G1;function J2(){if(G1)return $d;G1=1;var e=nt.default,t=Q2();function n(h,a){return h===a&&(h!==0||1/h===1/a)||h!==h&&a!==a}var r=typeof Object.is=="function"?Object.is:n,o=t.useSyncExternalStore,s=e.useRef,l=e.useEffect,c=e.useMemo,f=e.useDebugValue;return $d.useSyncExternalStoreWithSelector=function(h,a,u,d,p){var O=s(null);if(O.current===null){var g={hasValue:!1,value:null};O.current=g}else g=O.current;O=c(function(){function y(C){if(!w){if(w=!0,E=C,C=d(C),p!==void 0&&g.hasValue){var N=g.value;if(p(N,C))return m=N}return m=C}if(N=m,r(E,C))return N;var M=d(C);return p!==void 0&&p(N,M)?N:(E=C,m=M)}var w=!1,E,m,S=u===void 0?null:u;return[function(){return y(a())},S===null?void 0:function(){return y(S())}]},[a,u,d,p]);var _=o(h,O[0],O[1]);return l(function(){g.hasValue=!0,g.value=_},[_]),f(_),_},$d}var K1;function eT(){return K1||(K1=1,zd.exports=J2()),zd.exports}var tT=eT();const nT=ts(tT),rT={},W1=e=>{let t;const n=new Set,r=(f,h)=>{const a=typeof f=="function"?f(t):f;if(!Object.is(a,t)){const u=t;t=h??typeof a!="object"?a:Object.assign({},t,a),n.forEach(d=>d(t,u))}},o=()=>t,c={setState:r,getState:o,subscribe:f=>(n.add(f),()=>n.delete(f)),destroy:()=>{(rT?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),n.clear()}};return t=e(r,o,c),c},oT=e=>e?W1(e):W1,{useSyncExternalStoreWithSelector:iT}=nT;function Y1(e,t=e.getState,n){const r=iT(e.subscribe,e.getState,e.getServerState||e.getState,t,n);return se.useDebugValue(r),r}const Z1=(e,t)=>{const n=oT(e),r=(o,s=t)=>Y1(n,o,s);return Object.assign(r,n),r},aT=(e,t)=>e?Z1(e,t):Z1;function St(e,t){if(Object.is(e,t))return!0;if(typeof e!="object"||e===null||typeof t!="object"||t===null)return!1;if(e instanceof Map&&t instanceof Map){if(e.size!==t.size)return!1;for(const[r,o]of e)if(!Object.is(o,t.get(r)))return!1;return!0}if(e instanceof Set&&t instanceof Set){if(e.size!==t.size)return!1;for(const r of e)if(!t.has(r))return!1;return!0}const n=Object.keys(e);if(n.length!==Object.keys(t).length)return!1;for(let r=0;r<n.length;r++)if(!Object.prototype.hasOwnProperty.call(t,n[r])||!Object.is(e[n[r]],t[n[r]]))return!1;return!0}var sT={value:()=>{}};function Si(){for(var e=0,t=arguments.length,n={},r;e<t;++e){if(!(r=arguments[e]+"")||r in n||/[\s.]/.test(r))throw new Error("illegal type: "+r);n[r]=[]}return new ki(n)}function ki(e){this._=e}function lT(e,t){return e.trim().split(/^|\s+/).map(function(n){var r="",o=n.indexOf(".");if(o>=0&&(r=n.slice(o+1),n=n.slice(0,o)),n&&!t.hasOwnProperty(n))throw new Error("unknown type: "+n);return{type:n,name:r}})}ki.prototype=Si.prototype={constructor:ki,on:function(e,t){var n=this._,r=lT(e+"",n),o,s=-1,l=r.length;if(arguments.length<2){for(;++s<l;)if((o=(e=r[s]).type)&&(o=uT(n[o],e.name)))return o;return}if(t!=null&&typeof t!="function")throw new Error("invalid callback: "+t);for(;++s<l;)if(o=(e=r[s]).type)n[o]=X1(n[o],e.name,t);else if(t==null)for(o in n)n[o]=X1(n[o],e.name,null);return this},copy:function(){var e={},t=this._;for(var n in t)e[n]=t[n].slice();return new ki(e)},call:function(e,t){if((o=arguments.length-2)>0)for(var n=new Array(o),r=0,o,s;r<o;++r)n[r]=arguments[r+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(s=this._[e],r=0,o=s.length;r<o;++r)s[r].value.apply(t,n)},apply:function(e,t,n){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var r=this._[e],o=0,s=r.length;o<s;++o)r[o].value.apply(t,n)}};function uT(e,t){for(var n=0,r=e.length,o;n<r;++n)if((o=e[n]).name===t)return o.value}function X1(e,t,n){for(var r=0,o=e.length;r<o;++r)if(e[r].name===t){e[r]=sT,e=e.slice(0,r).concat(e.slice(r+1));break}return n!=null&&e.push({name:t,value:n}),e}var Ud="http://www.w3.org/1999/xhtml";const Q1={svg:"http://www.w3.org/2000/svg",xhtml:Ud,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Ni(e){var t=e+="",n=t.indexOf(":");return n>=0&&(t=e.slice(0,n))!=="xmlns"&&(e=e.slice(n+1)),Q1.hasOwnProperty(t)?{space:Q1[t],local:e}:e}function cT(e){return function(){var t=this.ownerDocument,n=this.namespaceURI;return n===Ud&&t.documentElement.namespaceURI===Ud?t.createElement(e):t.createElementNS(n,e)}}function fT(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function J1(e){var t=Ni(e);return(t.local?fT:cT)(t)}function dT(){}function Gd(e){return e==null?dT:function(){return this.querySelector(e)}}function hT(e){typeof e!="function"&&(e=Gd(e));for(var t=this._groups,n=t.length,r=new Array(n),o=0;o<n;++o)for(var s=t[o],l=s.length,c=r[o]=new Array(l),f,h,a=0;a<l;++a)(f=s[a])&&(h=e.call(f,f.__data__,a,s))&&("__data__"in f&&(h.__data__=f.__data__),c[a]=h);return new $t(r,this._parents)}function pT(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function vT(){return[]}function e_(e){return e==null?vT:function(){return this.querySelectorAll(e)}}function gT(e){return function(){return pT(e.apply(this,arguments))}}function yT(e){typeof e=="function"?e=gT(e):e=e_(e);for(var t=this._groups,n=t.length,r=[],o=[],s=0;s<n;++s)for(var l=t[s],c=l.length,f,h=0;h<c;++h)(f=l[h])&&(r.push(e.call(f,f.__data__,h,l)),o.push(f));return new $t(r,o)}function t_(e){return function(){return this.matches(e)}}function n_(e){return function(t){return t.matches(e)}}var mT=Array.prototype.find;function bT(e){return function(){return mT.call(this.children,e)}}function _T(){return this.firstElementChild}function wT(e){return this.select(e==null?_T:bT(typeof e=="function"?e:n_(e)))}var OT=Array.prototype.filter;function ET(){return Array.from(this.children)}function xT(e){return function(){return OT.call(this.children,e)}}function ST(e){return this.selectAll(e==null?ET:xT(typeof e=="function"?e:n_(e)))}function kT(e){typeof e!="function"&&(e=t_(e));for(var t=this._groups,n=t.length,r=new Array(n),o=0;o<n;++o)for(var s=t[o],l=s.length,c=r[o]=[],f,h=0;h<l;++h)(f=s[h])&&e.call(f,f.__data__,h,s)&&c.push(f);return new $t(r,this._parents)}function r_(e){return new Array(e.length)}function NT(){return new $t(this._enter||this._groups.map(r_),this._parents)}function Ti(e,t){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=t}Ti.prototype={constructor:Ti,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,t){return this._parent.insertBefore(e,t)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function TT(e){return function(){return e}}function CT(e,t,n,r,o,s){for(var l=0,c,f=t.length,h=s.length;l<h;++l)(c=t[l])?(c.__data__=s[l],r[l]=c):n[l]=new Ti(e,s[l]);for(;l<f;++l)(c=t[l])&&(o[l]=c)}function AT(e,t,n,r,o,s,l){var c,f,h=new Map,a=t.length,u=s.length,d=new Array(a),p;for(c=0;c<a;++c)(f=t[c])&&(d[c]=p=l.call(f,f.__data__,c,t)+"",h.has(p)?o[c]=f:h.set(p,f));for(c=0;c<u;++c)p=l.call(e,s[c],c,s)+"",(f=h.get(p))?(r[c]=f,f.__data__=s[c],h.delete(p)):n[c]=new Ti(e,s[c]);for(c=0;c<a;++c)(f=t[c])&&h.get(d[c])===f&&(o[c]=f)}function PT(e){return e.__data__}function IT(e,t){if(!arguments.length)return Array.from(this,PT);var n=t?AT:CT,r=this._parents,o=this._groups;typeof e!="function"&&(e=TT(e));for(var s=o.length,l=new Array(s),c=new Array(s),f=new Array(s),h=0;h<s;++h){var a=r[h],u=o[h],d=u.length,p=MT(e.call(a,a&&a.__data__,h,r)),O=p.length,g=c[h]=new Array(O),_=l[h]=new Array(O),y=f[h]=new Array(d);n(a,u,g,_,y,p,t);for(var w=0,E=0,m,S;w<O;++w)if(m=g[w]){for(w>=E&&(E=w+1);!(S=_[E])&&++E<O;);m._next=S||null}}return l=new $t(l,r),l._enter=c,l._exit=f,l}function MT(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function qT(){return new $t(this._exit||this._groups.map(r_),this._parents)}function LT(e,t,n){var r=this.enter(),o=this,s=this.exit();return typeof e=="function"?(r=e(r),r&&(r=r.selection())):r=r.append(e+""),t!=null&&(o=t(o),o&&(o=o.selection())),n==null?s.remove():n(s),r&&o?r.merge(o).order():o}function RT(e){for(var t=e.selection?e.selection():e,n=this._groups,r=t._groups,o=n.length,s=r.length,l=Math.min(o,s),c=new Array(o),f=0;f<l;++f)for(var h=n[f],a=r[f],u=h.length,d=c[f]=new Array(u),p,O=0;O<u;++O)(p=h[O]||a[O])&&(d[O]=p);for(;f<o;++f)c[f]=n[f];return new $t(c,this._parents)}function DT(){for(var e=this._groups,t=-1,n=e.length;++t<n;)for(var r=e[t],o=r.length-1,s=r[o],l;--o>=0;)(l=r[o])&&(s&&l.compareDocumentPosition(s)^4&&s.parentNode.insertBefore(l,s),s=l);return this}function jT(e){e||(e=FT);function t(u,d){return u&&d?e(u.__data__,d.__data__):!u-!d}for(var n=this._groups,r=n.length,o=new Array(r),s=0;s<r;++s){for(var l=n[s],c=l.length,f=o[s]=new Array(c),h,a=0;a<c;++a)(h=l[a])&&(f[a]=h);f.sort(t)}return new $t(o,this._parents).order()}function FT(e,t){return e<t?-1:e>t?1:e>=t?0:NaN}function BT(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function zT(){return Array.from(this)}function $T(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],o=0,s=r.length;o<s;++o){var l=r[o];if(l)return l}return null}function HT(){let e=0;for(const t of this)++e;return e}function VT(){return!this.node()}function UT(e){for(var t=this._groups,n=0,r=t.length;n<r;++n)for(var o=t[n],s=0,l=o.length,c;s<l;++s)(c=o[s])&&e.call(c,c.__data__,s,o);return this}function GT(e){return function(){this.removeAttribute(e)}}function KT(e){return function(){this.removeAttributeNS(e.space,e.local)}}function WT(e,t){return function(){this.setAttribute(e,t)}}function YT(e,t){return function(){this.setAttributeNS(e.space,e.local,t)}}function ZT(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttribute(e):this.setAttribute(e,n)}}function XT(e,t){return function(){var n=t.apply(this,arguments);n==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,n)}}function QT(e,t){var n=Ni(e);if(arguments.length<2){var r=this.node();return n.local?r.getAttributeNS(n.space,n.local):r.getAttribute(n)}return this.each((t==null?n.local?KT:GT:typeof t=="function"?n.local?XT:ZT:n.local?YT:WT)(n,t))}function o_(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function JT(e){return function(){this.style.removeProperty(e)}}function eC(e,t,n){return function(){this.style.setProperty(e,t,n)}}function tC(e,t,n){return function(){var r=t.apply(this,arguments);r==null?this.style.removeProperty(e):this.style.setProperty(e,r,n)}}function nC(e,t,n){return arguments.length>1?this.each((t==null?JT:typeof t=="function"?tC:eC)(e,t,n??"")):wr(this.node(),e)}function wr(e,t){return e.style.getPropertyValue(t)||o_(e).getComputedStyle(e,null).getPropertyValue(t)}function rC(e){return function(){delete this[e]}}function oC(e,t){return function(){this[e]=t}}function iC(e,t){return function(){var n=t.apply(this,arguments);n==null?delete this[e]:this[e]=n}}function aC(e,t){return arguments.length>1?this.each((t==null?rC:typeof t=="function"?iC:oC)(e,t)):this.node()[e]}function i_(e){return e.trim().split(/^|\s+/)}function Kd(e){return e.classList||new a_(e)}function a_(e){this._node=e,this._names=i_(e.getAttribute("class")||"")}a_.prototype={add:function(e){var t=this._names.indexOf(e);t<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var t=this._names.indexOf(e);t>=0&&(this._names.splice(t,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function s_(e,t){for(var n=Kd(e),r=-1,o=t.length;++r<o;)n.add(t[r])}function l_(e,t){for(var n=Kd(e),r=-1,o=t.length;++r<o;)n.remove(t[r])}function sC(e){return function(){s_(this,e)}}function lC(e){return function(){l_(this,e)}}function uC(e,t){return function(){(t.apply(this,arguments)?s_:l_)(this,e)}}function cC(e,t){var n=i_(e+"");if(arguments.length<2){for(var r=Kd(this.node()),o=-1,s=n.length;++o<s;)if(!r.contains(n[o]))return!1;return!0}return this.each((typeof t=="function"?uC:t?sC:lC)(n,t))}function fC(){this.textContent=""}function dC(e){return function(){this.textContent=e}}function hC(e){return function(){var t=e.apply(this,arguments);this.textContent=t??""}}function pC(e){return arguments.length?this.each(e==null?fC:(typeof e=="function"?hC:dC)(e)):this.node().textContent}function vC(){this.innerHTML=""}function gC(e){return function(){this.innerHTML=e}}function yC(e){return function(){var t=e.apply(this,arguments);this.innerHTML=t??""}}function mC(e){return arguments.length?this.each(e==null?vC:(typeof e=="function"?yC:gC)(e)):this.node().innerHTML}function bC(){this.nextSibling&&this.parentNode.appendChild(this)}function _C(){return this.each(bC)}function wC(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function OC(){return this.each(wC)}function EC(e){var t=typeof e=="function"?e:J1(e);return this.select(function(){return this.appendChild(t.apply(this,arguments))})}function xC(){return null}function SC(e,t){var n=typeof e=="function"?e:J1(e),r=t==null?xC:typeof t=="function"?t:Gd(t);return this.select(function(){return this.insertBefore(n.apply(this,arguments),r.apply(this,arguments)||null)})}function kC(){var e=this.parentNode;e&&e.removeChild(this)}function NC(){return this.each(kC)}function TC(){var e=this.cloneNode(!1),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function CC(){var e=this.cloneNode(!0),t=this.parentNode;return t?t.insertBefore(e,this.nextSibling):e}function AC(e){return this.select(e?CC:TC)}function PC(e){return arguments.length?this.property("__data__",e):this.node().__data__}function IC(e){return function(t){e.call(this,t,this.__data__)}}function MC(e){return e.trim().split(/^|\s+/).map(function(t){var n="",r=t.indexOf(".");return r>=0&&(n=t.slice(r+1),t=t.slice(0,r)),{type:t,name:n}})}function qC(e){return function(){var t=this.__on;if(t){for(var n=0,r=-1,o=t.length,s;n<o;++n)s=t[n],(!e.type||s.type===e.type)&&s.name===e.name?this.removeEventListener(s.type,s.listener,s.options):t[++r]=s;++r?t.length=r:delete this.__on}}}function LC(e,t,n){return function(){var r=this.__on,o,s=IC(t);if(r){for(var l=0,c=r.length;l<c;++l)if((o=r[l]).type===e.type&&o.name===e.name){this.removeEventListener(o.type,o.listener,o.options),this.addEventListener(o.type,o.listener=s,o.options=n),o.value=t;return}}this.addEventListener(e.type,s,n),o={type:e.type,name:e.name,value:t,listener:s,options:n},r?r.push(o):this.__on=[o]}}function RC(e,t,n){var r=MC(e+""),o,s=r.length,l;if(arguments.length<2){var c=this.node().__on;if(c){for(var f=0,h=c.length,a;f<h;++f)for(o=0,a=c[f];o<s;++o)if((l=r[o]).type===a.type&&l.name===a.name)return a.value}return}for(c=t?LC:qC,o=0;o<s;++o)this.each(c(r[o],t,n));return this}function u_(e,t,n){var r=o_(e),o=r.CustomEvent;typeof o=="function"?o=new o(t,n):(o=r.document.createEvent("Event"),n?(o.initEvent(t,n.bubbles,n.cancelable),o.detail=n.detail):o.initEvent(t,!1,!1)),e.dispatchEvent(o)}function DC(e,t){return function(){return u_(this,e,t)}}function jC(e,t){return function(){return u_(this,e,t.apply(this,arguments))}}function FC(e,t){return this.each((typeof t=="function"?jC:DC)(e,t))}function*BC(){for(var e=this._groups,t=0,n=e.length;t<n;++t)for(var r=e[t],o=0,s=r.length,l;o<s;++o)(l=r[o])&&(yield l)}var c_=[null];function $t(e,t){this._groups=e,this._parents=t}function co(){return new $t([[document.documentElement]],c_)}function zC(){return this}$t.prototype=co.prototype={constructor:$t,select:hT,selectAll:yT,selectChild:wT,selectChildren:ST,filter:kT,data:IT,enter:NT,exit:qT,join:LT,merge:RT,selection:zC,order:DT,sort:jT,call:BT,nodes:zT,node:$T,size:HT,empty:VT,each:UT,attr:QT,style:nC,property:aC,classed:cC,text:pC,html:mC,raise:_C,lower:OC,append:EC,insert:SC,remove:NC,clone:AC,datum:PC,on:RC,dispatch:FC,[Symbol.iterator]:BC};function Zt(e){return typeof e=="string"?new $t([[document.querySelector(e)]],[document.documentElement]):new $t([[e]],c_)}function $C(e){let t;for(;t=e.sourceEvent;)e=t;return e}function an(e,t){if(e=$C(e),t===void 0&&(t=e.currentTarget),t){var n=t.ownerSVGElement||t;if(n.createSVGPoint){var r=n.createSVGPoint();return r.x=e.clientX,r.y=e.clientY,r=r.matrixTransform(t.getScreenCTM().inverse()),[r.x,r.y]}if(t.getBoundingClientRect){var o=t.getBoundingClientRect();return[e.clientX-o.left-t.clientLeft,e.clientY-o.top-t.clientTop]}}return[e.pageX,e.pageY]}const HC={passive:!1},fo={capture:!0,passive:!1};function Wd(e){e.stopImmediatePropagation()}function Or(e){e.preventDefault(),e.stopImmediatePropagation()}function f_(e){var t=e.document.documentElement,n=Zt(e).on("dragstart.drag",Or,fo);"onselectstart"in t?n.on("selectstart.drag",Or,fo):(t.__noselect=t.style.MozUserSelect,t.style.MozUserSelect="none")}function d_(e,t){var n=e.document.documentElement,r=Zt(e).on("dragstart.drag",null);t&&(r.on("click.drag",Or,fo),setTimeout(function(){r.on("click.drag",null)},0)),"onselectstart"in n?r.on("selectstart.drag",null):(n.style.MozUserSelect=n.__noselect,delete n.__noselect)}const Ci=e=>()=>e;function Yd(e,{sourceEvent:t,subject:n,target:r,identifier:o,active:s,x:l,y:c,dx:f,dy:h,dispatch:a}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},subject:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},identifier:{value:o,enumerable:!0,configurable:!0},active:{value:s,enumerable:!0,configurable:!0},x:{value:l,enumerable:!0,configurable:!0},y:{value:c,enumerable:!0,configurable:!0},dx:{value:f,enumerable:!0,configurable:!0},dy:{value:h,enumerable:!0,configurable:!0},_:{value:a}})}Yd.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function VC(e){return!e.ctrlKey&&!e.button}function UC(){return this.parentNode}function GC(e,t){return t??{x:e.x,y:e.y}}function KC(){return navigator.maxTouchPoints||"ontouchstart"in this}function WC(){var e=VC,t=UC,n=GC,r=KC,o={},s=Si("start","drag","end"),l=0,c,f,h,a,u=0;function d(m){m.on("mousedown.drag",p).filter(r).on("touchstart.drag",_).on("touchmove.drag",y,HC).on("touchend.drag touchcancel.drag",w).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function p(m,S){if(!(a||!e.call(this,m,S))){var C=E(this,t.call(this,m,S),m,S,"mouse");C&&(Zt(m.view).on("mousemove.drag",O,fo).on("mouseup.drag",g,fo),f_(m.view),Wd(m),h=!1,c=m.clientX,f=m.clientY,C("start",m))}}function O(m){if(Or(m),!h){var S=m.clientX-c,C=m.clientY-f;h=S*S+C*C>u}o.mouse("drag",m)}function g(m){Zt(m.view).on("mousemove.drag mouseup.drag",null),d_(m.view,h),Or(m),o.mouse("end",m)}function _(m,S){if(e.call(this,m,S)){var C=m.changedTouches,N=t.call(this,m,S),M=C.length,j,I;for(j=0;j<M;++j)(I=E(this,N,m,S,C[j].identifier,C[j]))&&(Wd(m),I("start",m,C[j]))}}function y(m){var S=m.changedTouches,C=S.length,N,M;for(N=0;N<C;++N)(M=o[S[N].identifier])&&(Or(m),M("drag",m,S[N]))}function w(m){var S=m.changedTouches,C=S.length,N,M;for(a&&clearTimeout(a),a=setTimeout(function(){a=null},500),N=0;N<C;++N)(M=o[S[N].identifier])&&(Wd(m),M("end",m,S[N]))}function E(m,S,C,N,M,j){var I=s.copy(),A=an(j||C,S),q,R,k;if((k=n.call(m,new Yd("beforestart",{sourceEvent:C,target:d,identifier:M,active:l,x:A[0],y:A[1],dx:0,dy:0,dispatch:I}),N))!=null)return q=k.x-A[0]||0,R=k.y-A[1]||0,function F(U,ne,ue){var K=A,W;switch(U){case"start":o[M]=F,W=l++;break;case"end":delete o[M],--l;case"drag":A=an(ue||ne,S),W=l;break}I.call(U,m,new Yd(U,{sourceEvent:ne,subject:k,target:d,identifier:M,active:W,x:A[0]+q,y:A[1]+R,dx:A[0]-K[0],dy:A[1]-K[1],dispatch:I}),N)}}return d.filter=function(m){return arguments.length?(e=typeof m=="function"?m:Ci(!!m),d):e},d.container=function(m){return arguments.length?(t=typeof m=="function"?m:Ci(m),d):t},d.subject=function(m){return arguments.length?(n=typeof m=="function"?m:Ci(m),d):n},d.touchable=function(m){return arguments.length?(r=typeof m=="function"?m:Ci(!!m),d):r},d.on=function(){var m=s.on.apply(s,arguments);return m===s?d:m},d.clickDistance=function(m){return arguments.length?(u=(m=+m)*m,d):Math.sqrt(u)},d}function Zd(e,t,n){e.prototype=t.prototype=n,n.constructor=e}function h_(e,t){var n=Object.create(e.prototype);for(var r in t)n[r]=t[r];return n}function ho(){}var po=.7,Ai=1/po,Er="\\s*([+-]?\\d+)\\s*",vo="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",hn="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",YC=/^#([0-9a-f]{3,8})$/,ZC=new RegExp(`^rgb\\(${Er},${Er},${Er}\\)$`),XC=new RegExp(`^rgb\\(${hn},${hn},${hn}\\)$`),QC=new RegExp(`^rgba\\(${Er},${Er},${Er},${vo}\\)$`),JC=new RegExp(`^rgba\\(${hn},${hn},${hn},${vo}\\)$`),eA=new RegExp(`^hsl\\(${vo},${hn},${hn}\\)$`),tA=new RegExp(`^hsla\\(${vo},${hn},${hn},${vo}\\)$`),p_={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Zd(ho,go,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:v_,formatHex:v_,formatHex8:nA,formatHsl:rA,formatRgb:g_,toString:g_});function v_(){return this.rgb().formatHex()}function nA(){return this.rgb().formatHex8()}function rA(){return w_(this).formatHsl()}function g_(){return this.rgb().formatRgb()}function go(e){var t,n;return e=(e+"").trim().toLowerCase(),(t=YC.exec(e))?(n=t[1].length,t=parseInt(t[1],16),n===6?y_(t):n===3?new Dt(t>>8&15|t>>4&240,t>>4&15|t&240,(t&15)<<4|t&15,1):n===8?Pi(t>>24&255,t>>16&255,t>>8&255,(t&255)/255):n===4?Pi(t>>12&15|t>>8&240,t>>8&15|t>>4&240,t>>4&15|t&240,((t&15)<<4|t&15)/255):null):(t=ZC.exec(e))?new Dt(t[1],t[2],t[3],1):(t=XC.exec(e))?new Dt(t[1]*255/100,t[2]*255/100,t[3]*255/100,1):(t=QC.exec(e))?Pi(t[1],t[2],t[3],t[4]):(t=JC.exec(e))?Pi(t[1]*255/100,t[2]*255/100,t[3]*255/100,t[4]):(t=eA.exec(e))?__(t[1],t[2]/100,t[3]/100,1):(t=tA.exec(e))?__(t[1],t[2]/100,t[3]/100,t[4]):p_.hasOwnProperty(e)?y_(p_[e]):e==="transparent"?new Dt(NaN,NaN,NaN,0):null}function y_(e){return new Dt(e>>16&255,e>>8&255,e&255,1)}function Pi(e,t,n,r){return r<=0&&(e=t=n=NaN),new Dt(e,t,n,r)}function oA(e){return e instanceof ho||(e=go(e)),e?(e=e.rgb(),new Dt(e.r,e.g,e.b,e.opacity)):new Dt}function Xd(e,t,n,r){return arguments.length===1?oA(e):new Dt(e,t,n,r??1)}function Dt(e,t,n,r){this.r=+e,this.g=+t,this.b=+n,this.opacity=+r}Zd(Dt,Xd,h_(ho,{brighter(e){return e=e==null?Ai:Math.pow(Ai,e),new Dt(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?po:Math.pow(po,e),new Dt(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new Dt(Qn(this.r),Qn(this.g),Qn(this.b),Ii(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:m_,formatHex:m_,formatHex8:iA,formatRgb:b_,toString:b_}));function m_(){return`#${Jn(this.r)}${Jn(this.g)}${Jn(this.b)}`}function iA(){return`#${Jn(this.r)}${Jn(this.g)}${Jn(this.b)}${Jn((isNaN(this.opacity)?1:this.opacity)*255)}`}function b_(){const e=Ii(this.opacity);return`${e===1?"rgb(":"rgba("}${Qn(this.r)}, ${Qn(this.g)}, ${Qn(this.b)}${e===1?")":`, ${e})`}`}function Ii(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function Qn(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function Jn(e){return e=Qn(e),(e<16?"0":"")+e.toString(16)}function __(e,t,n,r){return r<=0?e=t=n=NaN:n<=0||n>=1?e=t=NaN:t<=0&&(e=NaN),new sn(e,t,n,r)}function w_(e){if(e instanceof sn)return new sn(e.h,e.s,e.l,e.opacity);if(e instanceof ho||(e=go(e)),!e)return new sn;if(e instanceof sn)return e;e=e.rgb();var t=e.r/255,n=e.g/255,r=e.b/255,o=Math.min(t,n,r),s=Math.max(t,n,r),l=NaN,c=s-o,f=(s+o)/2;return c?(t===s?l=(n-r)/c+(n<r)*6:n===s?l=(r-t)/c+2:l=(t-n)/c+4,c/=f<.5?s+o:2-s-o,l*=60):c=f>0&&f<1?0:l,new sn(l,c,f,e.opacity)}function aA(e,t,n,r){return arguments.length===1?w_(e):new sn(e,t,n,r??1)}function sn(e,t,n,r){this.h=+e,this.s=+t,this.l=+n,this.opacity=+r}Zd(sn,aA,h_(ho,{brighter(e){return e=e==null?Ai:Math.pow(Ai,e),new sn(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?po:Math.pow(po,e),new sn(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,t=isNaN(e)||isNaN(this.s)?0:this.s,n=this.l,r=n+(n<.5?n:1-n)*t,o=2*n-r;return new Dt(Qd(e>=240?e-240:e+120,o,r),Qd(e,o,r),Qd(e<120?e+240:e-120,o,r),this.opacity)},clamp(){return new sn(O_(this.h),Mi(this.s),Mi(this.l),Ii(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Ii(this.opacity);return`${e===1?"hsl(":"hsla("}${O_(this.h)}, ${Mi(this.s)*100}%, ${Mi(this.l)*100}%${e===1?")":`, ${e})`}`}}));function O_(e){return e=(e||0)%360,e<0?e+360:e}function Mi(e){return Math.max(0,Math.min(1,e||0))}function Qd(e,t,n){return(e<60?t+(n-t)*e/60:e<180?n:e<240?t+(n-t)*(240-e)/60:t)*255}const E_=e=>()=>e;function sA(e,t){return function(n){return e+n*t}}function lA(e,t,n){return e=Math.pow(e,n),t=Math.pow(t,n)-e,n=1/n,function(r){return Math.pow(e+r*t,n)}}function uA(e){return(e=+e)==1?x_:function(t,n){return n-t?lA(t,n,e):E_(isNaN(t)?n:t)}}function x_(e,t){var n=t-e;return n?sA(e,n):E_(isNaN(e)?t:e)}const S_=(function e(t){var n=uA(t);function r(o,s){var l=n((o=Xd(o)).r,(s=Xd(s)).r),c=n(o.g,s.g),f=n(o.b,s.b),h=x_(o.opacity,s.opacity);return function(a){return o.r=l(a),o.g=c(a),o.b=f(a),o.opacity=h(a),o+""}}return r.gamma=e,r})(1);function Rn(e,t){return e=+e,t=+t,function(n){return e*(1-n)+t*n}}var Jd=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,eh=new RegExp(Jd.source,"g");function cA(e){return function(){return e}}function fA(e){return function(t){return e(t)+""}}function dA(e,t){var n=Jd.lastIndex=eh.lastIndex=0,r,o,s,l=-1,c=[],f=[];for(e=e+"",t=t+"";(r=Jd.exec(e))&&(o=eh.exec(t));)(s=o.index)>n&&(s=t.slice(n,s),c[l]?c[l]+=s:c[++l]=s),(r=r[0])===(o=o[0])?c[l]?c[l]+=o:c[++l]=o:(c[++l]=null,f.push({i:l,x:Rn(r,o)})),n=eh.lastIndex;return n<t.length&&(s=t.slice(n),c[l]?c[l]+=s:c[++l]=s),c.length<2?f[0]?fA(f[0].x):cA(t):(t=f.length,function(h){for(var a=0,u;a<t;++a)c[(u=f[a]).i]=u.x(h);return c.join("")})}var k_=180/Math.PI,th={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function N_(e,t,n,r,o,s){var l,c,f;return(l=Math.sqrt(e*e+t*t))&&(e/=l,t/=l),(f=e*n+t*r)&&(n-=e*f,r-=t*f),(c=Math.sqrt(n*n+r*r))&&(n/=c,r/=c,f/=c),e*r<t*n&&(e=-e,t=-t,f=-f,l=-l),{translateX:o,translateY:s,rotate:Math.atan2(t,e)*k_,skewX:Math.atan(f)*k_,scaleX:l,scaleY:c}}var qi;function hA(e){const t=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return t.isIdentity?th:N_(t.a,t.b,t.c,t.d,t.e,t.f)}function pA(e){return e==null||(qi||(qi=document.createElementNS("http://www.w3.org/2000/svg","g")),qi.setAttribute("transform",e),!(e=qi.transform.baseVal.consolidate()))?th:(e=e.matrix,N_(e.a,e.b,e.c,e.d,e.e,e.f))}function T_(e,t,n,r){function o(h){return h.length?h.pop()+" ":""}function s(h,a,u,d,p,O){if(h!==u||a!==d){var g=p.push("translate(",null,t,null,n);O.push({i:g-4,x:Rn(h,u)},{i:g-2,x:Rn(a,d)})}else(u||d)&&p.push("translate("+u+t+d+n)}function l(h,a,u,d){h!==a?(h-a>180?a+=360:a-h>180&&(h+=360),d.push({i:u.push(o(u)+"rotate(",null,r)-2,x:Rn(h,a)})):a&&u.push(o(u)+"rotate("+a+r)}function c(h,a,u,d){h!==a?d.push({i:u.push(o(u)+"skewX(",null,r)-2,x:Rn(h,a)}):a&&u.push(o(u)+"skewX("+a+r)}function f(h,a,u,d,p,O){if(h!==u||a!==d){var g=p.push(o(p)+"scale(",null,",",null,")");O.push({i:g-4,x:Rn(h,u)},{i:g-2,x:Rn(a,d)})}else(u!==1||d!==1)&&p.push(o(p)+"scale("+u+","+d+")")}return function(h,a){var u=[],d=[];return h=e(h),a=e(a),s(h.translateX,h.translateY,a.translateX,a.translateY,u,d),l(h.rotate,a.rotate,u,d),c(h.skewX,a.skewX,u,d),f(h.scaleX,h.scaleY,a.scaleX,a.scaleY,u,d),h=a=null,function(p){for(var O=-1,g=d.length,_;++O<g;)u[(_=d[O]).i]=_.x(p);return u.join("")}}}var vA=T_(hA,"px, ","px)","deg)"),gA=T_(pA,", ",")",")"),yA=1e-12;function C_(e){return((e=Math.exp(e))+1/e)/2}function mA(e){return((e=Math.exp(e))-1/e)/2}function bA(e){return((e=Math.exp(2*e))-1)/(e+1)}const _A=(function e(t,n,r){function o(s,l){var c=s[0],f=s[1],h=s[2],a=l[0],u=l[1],d=l[2],p=a-c,O=u-f,g=p*p+O*O,_,y;if(g<yA)y=Math.log(d/h)/t,_=function(N){return[c+N*p,f+N*O,h*Math.exp(t*N*y)]};else{var w=Math.sqrt(g),E=(d*d-h*h+r*g)/(2*h*n*w),m=(d*d-h*h-r*g)/(2*d*n*w),S=Math.log(Math.sqrt(E*E+1)-E),C=Math.log(Math.sqrt(m*m+1)-m);y=(C-S)/t,_=function(N){var M=N*y,j=C_(S),I=h/(n*w)*(j*bA(t*M+S)-mA(S));return[c+I*p,f+I*O,h*j/C_(t*M+S)]}}return _.duration=y*1e3*t/Math.SQRT2,_}return o.rho=function(s){var l=Math.max(.001,+s),c=l*l,f=c*c;return e(l,c,f)},o})(Math.SQRT2,2,4);var xr=0,yo=0,mo=0,A_=1e3,Li,bo,Ri=0,er=0,Di=0,_o=typeof performance=="object"&&performance.now?performance:Date,P_=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function nh(){return er||(P_(wA),er=_o.now()+Di)}function wA(){er=0}function ji(){this._call=this._time=this._next=null}ji.prototype=I_.prototype={constructor:ji,restart:function(e,t,n){if(typeof e!="function")throw new TypeError("callback is not a function");n=(n==null?nh():+n)+(t==null?0:+t),!this._next&&bo!==this&&(bo?bo._next=this:Li=this,bo=this),this._call=e,this._time=n,rh()},stop:function(){this._call&&(this._call=null,this._time=1/0,rh())}};function I_(e,t,n){var r=new ji;return r.restart(e,t,n),r}function OA(){nh(),++xr;for(var e=Li,t;e;)(t=er-e._time)>=0&&e._call.call(void 0,t),e=e._next;--xr}function M_(){er=(Ri=_o.now())+Di,xr=yo=0;try{OA()}finally{xr=0,xA(),er=0}}function EA(){var e=_o.now(),t=e-Ri;t>A_&&(Di-=t,Ri=e)}function xA(){for(var e,t=Li,n,r=1/0;t;)t._call?(r>t._time&&(r=t._time),e=t,t=t._next):(n=t._next,t._next=null,t=e?e._next=n:Li=n);bo=e,rh(r)}function rh(e){if(!xr){yo&&(yo=clearTimeout(yo));var t=e-er;t>24?(e<1/0&&(yo=setTimeout(M_,e-_o.now()-Di)),mo&&(mo=clearInterval(mo))):(mo||(Ri=_o.now(),mo=setInterval(EA,A_)),xr=1,P_(M_))}}function q_(e,t,n){var r=new ji;return t=t==null?0:+t,r.restart(o=>{r.stop(),e(o+t)},t,n),r}var SA=Si("start","end","cancel","interrupt"),kA=[],L_=0,R_=1,oh=2,Fi=3,D_=4,ih=5,Bi=6;function zi(e,t,n,r,o,s){var l=e.__transition;if(!l)e.__transition={};else if(n in l)return;NA(e,n,{name:t,index:r,group:o,on:SA,tween:kA,time:s.time,delay:s.delay,duration:s.duration,ease:s.ease,timer:null,state:L_})}function ah(e,t){var n=ln(e,t);if(n.state>L_)throw new Error("too late; already scheduled");return n}function pn(e,t){var n=ln(e,t);if(n.state>Fi)throw new Error("too late; already running");return n}function ln(e,t){var n=e.__transition;if(!n||!(n=n[t]))throw new Error("transition not found");return n}function NA(e,t,n){var r=e.__transition,o;r[t]=n,n.timer=I_(s,0,n.time);function s(h){n.state=R_,n.timer.restart(l,n.delay,n.time),n.delay<=h&&l(h-n.delay)}function l(h){var a,u,d,p;if(n.state!==R_)return f();for(a in r)if(p=r[a],p.name===n.name){if(p.state===Fi)return q_(l);p.state===D_?(p.state=Bi,p.timer.stop(),p.on.call("interrupt",e,e.__data__,p.index,p.group),delete r[a]):+a<t&&(p.state=Bi,p.timer.stop(),p.on.call("cancel",e,e.__data__,p.index,p.group),delete r[a])}if(q_(function(){n.state===Fi&&(n.state=D_,n.timer.restart(c,n.delay,n.time),c(h))}),n.state=oh,n.on.call("start",e,e.__data__,n.index,n.group),n.state===oh){for(n.state=Fi,o=new Array(d=n.tween.length),a=0,u=-1;a<d;++a)(p=n.tween[a].value.call(e,e.__data__,n.index,n.group))&&(o[++u]=p);o.length=u+1}}function c(h){for(var a=h<n.duration?n.ease.call(null,h/n.duration):(n.timer.restart(f),n.state=ih,1),u=-1,d=o.length;++u<d;)o[u].call(e,a);n.state===ih&&(n.on.call("end",e,e.__data__,n.index,n.group),f())}function f(){n.state=Bi,n.timer.stop(),delete r[t];for(var h in r)return;delete e.__transition}}function $i(e,t){var n=e.__transition,r,o,s=!0,l;if(n){t=t==null?null:t+"";for(l in n){if((r=n[l]).name!==t){s=!1;continue}o=r.state>oh&&r.state<ih,r.state=Bi,r.timer.stop(),r.on.call(o?"interrupt":"cancel",e,e.__data__,r.index,r.group),delete n[l]}s&&delete e.__transition}}function TA(e){return this.each(function(){$i(this,e)})}function CA(e,t){var n,r;return function(){var o=pn(this,e),s=o.tween;if(s!==n){r=n=s;for(var l=0,c=r.length;l<c;++l)if(r[l].name===t){r=r.slice(),r.splice(l,1);break}}o.tween=r}}function AA(e,t,n){var r,o;if(typeof n!="function")throw new Error;return function(){var s=pn(this,e),l=s.tween;if(l!==r){o=(r=l).slice();for(var c={name:t,value:n},f=0,h=o.length;f<h;++f)if(o[f].name===t){o[f]=c;break}f===h&&o.push(c)}s.tween=o}}function PA(e,t){var n=this._id;if(e+="",arguments.length<2){for(var r=ln(this.node(),n).tween,o=0,s=r.length,l;o<s;++o)if((l=r[o]).name===e)return l.value;return null}return this.each((t==null?CA:AA)(n,e,t))}function sh(e,t,n){var r=e._id;return e.each(function(){var o=pn(this,r);(o.value||(o.value={}))[t]=n.apply(this,arguments)}),function(o){return ln(o,r).value[t]}}function j_(e,t){var n;return(typeof t=="number"?Rn:t instanceof go?S_:(n=go(t))?(t=n,S_):dA)(e,t)}function IA(e){return function(){this.removeAttribute(e)}}function MA(e){return function(){this.removeAttributeNS(e.space,e.local)}}function qA(e,t,n){var r,o=n+"",s;return function(){var l=this.getAttribute(e);return l===o?null:l===r?s:s=t(r=l,n)}}function LA(e,t,n){var r,o=n+"",s;return function(){var l=this.getAttributeNS(e.space,e.local);return l===o?null:l===r?s:s=t(r=l,n)}}function RA(e,t,n){var r,o,s;return function(){var l,c=n(this),f;return c==null?void this.removeAttribute(e):(l=this.getAttribute(e),f=c+"",l===f?null:l===r&&f===o?s:(o=f,s=t(r=l,c)))}}function DA(e,t,n){var r,o,s;return function(){var l,c=n(this),f;return c==null?void this.removeAttributeNS(e.space,e.local):(l=this.getAttributeNS(e.space,e.local),f=c+"",l===f?null:l===r&&f===o?s:(o=f,s=t(r=l,c)))}}function jA(e,t){var n=Ni(e),r=n==="transform"?gA:j_;return this.attrTween(e,typeof t=="function"?(n.local?DA:RA)(n,r,sh(this,"attr."+e,t)):t==null?(n.local?MA:IA)(n):(n.local?LA:qA)(n,r,t))}function FA(e,t){return function(n){this.setAttribute(e,t.call(this,n))}}function BA(e,t){return function(n){this.setAttributeNS(e.space,e.local,t.call(this,n))}}function zA(e,t){var n,r;function o(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&BA(e,s)),n}return o._value=t,o}function $A(e,t){var n,r;function o(){var s=t.apply(this,arguments);return s!==r&&(n=(r=s)&&FA(e,s)),n}return o._value=t,o}function HA(e,t){var n="attr."+e;if(arguments.length<2)return(n=this.tween(n))&&n._value;if(t==null)return this.tween(n,null);if(typeof t!="function")throw new Error;var r=Ni(e);return this.tween(n,(r.local?zA:$A)(r,t))}function VA(e,t){return function(){ah(this,e).delay=+t.apply(this,arguments)}}function UA(e,t){return t=+t,function(){ah(this,e).delay=t}}function GA(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?VA:UA)(t,e)):ln(this.node(),t).delay}function KA(e,t){return function(){pn(this,e).duration=+t.apply(this,arguments)}}function WA(e,t){return t=+t,function(){pn(this,e).duration=t}}function YA(e){var t=this._id;return arguments.length?this.each((typeof e=="function"?KA:WA)(t,e)):ln(this.node(),t).duration}function ZA(e,t){if(typeof t!="function")throw new Error;return function(){pn(this,e).ease=t}}function XA(e){var t=this._id;return arguments.length?this.each(ZA(t,e)):ln(this.node(),t).ease}function QA(e,t){return function(){var n=t.apply(this,arguments);if(typeof n!="function")throw new Error;pn(this,e).ease=n}}function JA(e){if(typeof e!="function")throw new Error;return this.each(QA(this._id,e))}function eP(e){typeof e!="function"&&(e=t_(e));for(var t=this._groups,n=t.length,r=new Array(n),o=0;o<n;++o)for(var s=t[o],l=s.length,c=r[o]=[],f,h=0;h<l;++h)(f=s[h])&&e.call(f,f.__data__,h,s)&&c.push(f);return new Sn(r,this._parents,this._name,this._id)}function tP(e){if(e._id!==this._id)throw new Error;for(var t=this._groups,n=e._groups,r=t.length,o=n.length,s=Math.min(r,o),l=new Array(r),c=0;c<s;++c)for(var f=t[c],h=n[c],a=f.length,u=l[c]=new Array(a),d,p=0;p<a;++p)(d=f[p]||h[p])&&(u[p]=d);for(;c<r;++c)l[c]=t[c];return new Sn(l,this._parents,this._name,this._id)}function nP(e){return(e+"").trim().split(/^|\s+/).every(function(t){var n=t.indexOf(".");return n>=0&&(t=t.slice(0,n)),!t||t==="start"})}function rP(e,t,n){var r,o,s=nP(t)?ah:pn;return function(){var l=s(this,e),c=l.on;c!==r&&(o=(r=c).copy()).on(t,n),l.on=o}}function oP(e,t){var n=this._id;return arguments.length<2?ln(this.node(),n).on.on(e):this.each(rP(n,e,t))}function iP(e){return function(){var t=this.parentNode;for(var n in this.__transition)if(+n!==e)return;t&&t.removeChild(this)}}function aP(){return this.on("end.remove",iP(this._id))}function sP(e){var t=this._name,n=this._id;typeof e!="function"&&(e=Gd(e));for(var r=this._groups,o=r.length,s=new Array(o),l=0;l<o;++l)for(var c=r[l],f=c.length,h=s[l]=new Array(f),a,u,d=0;d<f;++d)(a=c[d])&&(u=e.call(a,a.__data__,d,c))&&("__data__"in a&&(u.__data__=a.__data__),h[d]=u,zi(h[d],t,n,d,h,ln(a,n)));return new Sn(s,this._parents,t,n)}function lP(e){var t=this._name,n=this._id;typeof e!="function"&&(e=e_(e));for(var r=this._groups,o=r.length,s=[],l=[],c=0;c<o;++c)for(var f=r[c],h=f.length,a,u=0;u<h;++u)if(a=f[u]){for(var d=e.call(a,a.__data__,u,f),p,O=ln(a,n),g=0,_=d.length;g<_;++g)(p=d[g])&&zi(p,t,n,g,d,O);s.push(d),l.push(a)}return new Sn(s,l,t,n)}var uP=co.prototype.constructor;function cP(){return new uP(this._groups,this._parents)}function fP(e,t){var n,r,o;return function(){var s=wr(this,e),l=(this.style.removeProperty(e),wr(this,e));return s===l?null:s===n&&l===r?o:o=t(n=s,r=l)}}function F_(e){return function(){this.style.removeProperty(e)}}function dP(e,t,n){var r,o=n+"",s;return function(){var l=wr(this,e);return l===o?null:l===r?s:s=t(r=l,n)}}function hP(e,t,n){var r,o,s;return function(){var l=wr(this,e),c=n(this),f=c+"";return c==null&&(f=c=(this.style.removeProperty(e),wr(this,e))),l===f?null:l===r&&f===o?s:(o=f,s=t(r=l,c))}}function pP(e,t){var n,r,o,s="style."+t,l="end."+s,c;return function(){var f=pn(this,e),h=f.on,a=f.value[s]==null?c||(c=F_(t)):void 0;(h!==n||o!==a)&&(r=(n=h).copy()).on(l,o=a),f.on=r}}function vP(e,t,n){var r=(e+="")=="transform"?vA:j_;return t==null?this.styleTween(e,fP(e,r)).on("end.style."+e,F_(e)):typeof t=="function"?this.styleTween(e,hP(e,r,sh(this,"style."+e,t))).each(pP(this._id,e)):this.styleTween(e,dP(e,r,t),n).on("end.style."+e,null)}function gP(e,t,n){return function(r){this.style.setProperty(e,t.call(this,r),n)}}function yP(e,t,n){var r,o;function s(){var l=t.apply(this,arguments);return l!==o&&(r=(o=l)&&gP(e,l,n)),r}return s._value=t,s}function mP(e,t,n){var r="style."+(e+="");if(arguments.length<2)return(r=this.tween(r))&&r._value;if(t==null)return this.tween(r,null);if(typeof t!="function")throw new Error;return this.tween(r,yP(e,t,n??""))}function bP(e){return function(){this.textContent=e}}function _P(e){return function(){var t=e(this);this.textContent=t??""}}function wP(e){return this.tween("text",typeof e=="function"?_P(sh(this,"text",e)):bP(e==null?"":e+""))}function OP(e){return function(t){this.textContent=e.call(this,t)}}function EP(e){var t,n;function r(){var o=e.apply(this,arguments);return o!==n&&(t=(n=o)&&OP(o)),t}return r._value=e,r}function xP(e){var t="text";if(arguments.length<1)return(t=this.tween(t))&&t._value;if(e==null)return this.tween(t,null);if(typeof e!="function")throw new Error;return this.tween(t,EP(e))}function SP(){for(var e=this._name,t=this._id,n=B_(),r=this._groups,o=r.length,s=0;s<o;++s)for(var l=r[s],c=l.length,f,h=0;h<c;++h)if(f=l[h]){var a=ln(f,t);zi(f,e,n,h,l,{time:a.time+a.delay+a.duration,delay:0,duration:a.duration,ease:a.ease})}return new Sn(r,this._parents,e,n)}function kP(){var e,t,n=this,r=n._id,o=n.size();return new Promise(function(s,l){var c={value:l},f={value:function(){--o===0&&s()}};n.each(function(){var h=pn(this,r),a=h.on;a!==e&&(t=(e=a).copy(),t._.cancel.push(c),t._.interrupt.push(c),t._.end.push(f)),h.on=t}),o===0&&s()})}var NP=0;function Sn(e,t,n,r){this._groups=e,this._parents=t,this._name=n,this._id=r}function B_(){return++NP}var kn=co.prototype;Sn.prototype={constructor:Sn,select:sP,selectAll:lP,selectChild:kn.selectChild,selectChildren:kn.selectChildren,filter:eP,merge:tP,selection:cP,transition:SP,call:kn.call,nodes:kn.nodes,node:kn.node,size:kn.size,empty:kn.empty,each:kn.each,on:oP,attr:jA,attrTween:HA,style:vP,styleTween:mP,text:wP,textTween:xP,remove:aP,tween:PA,delay:GA,duration:YA,ease:XA,easeVarying:JA,end:kP,[Symbol.iterator]:kn[Symbol.iterator]};function TP(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var CP={time:null,delay:0,duration:250,ease:TP};function AP(e,t){for(var n;!(n=e.__transition)||!(n=n[t]);)if(!(e=e.parentNode))throw new Error(`transition ${t} not found`);return n}function PP(e){var t,n;e instanceof Sn?(t=e._id,e=e._name):(t=B_(),(n=CP).time=nh(),e=e==null?null:e+"");for(var r=this._groups,o=r.length,s=0;s<o;++s)for(var l=r[s],c=l.length,f,h=0;h<c;++h)(f=l[h])&&zi(f,e,t,h,l,n||AP(f,t));return new Sn(r,this._parents,e,t)}co.prototype.interrupt=TA,co.prototype.transition=PP;const Hi=e=>()=>e;function IP(e,{sourceEvent:t,target:n,transform:r,dispatch:o}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:t,enumerable:!0,configurable:!0},target:{value:n,enumerable:!0,configurable:!0},transform:{value:r,enumerable:!0,configurable:!0},_:{value:o}})}function Nn(e,t,n){this.k=e,this.x=t,this.y=n}Nn.prototype={constructor:Nn,scale:function(e){return e===1?this:new Nn(this.k*e,this.x,this.y)},translate:function(e,t){return e===0&t===0?this:new Nn(this.k,this.x+this.k*e,this.y+this.k*t)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Tn=new Nn(1,0,0);Nn.prototype;function lh(e){e.stopImmediatePropagation()}function wo(e){e.preventDefault(),e.stopImmediatePropagation()}function MP(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function qP(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function z_(){return this.__zoom||Tn}function LP(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function RP(){return navigator.maxTouchPoints||"ontouchstart"in this}function DP(e,t,n){var r=e.invertX(t[0][0])-n[0][0],o=e.invertX(t[1][0])-n[1][0],s=e.invertY(t[0][1])-n[0][1],l=e.invertY(t[1][1])-n[1][1];return e.translate(o>r?(r+o)/2:Math.min(0,r)||Math.max(0,o),l>s?(s+l)/2:Math.min(0,s)||Math.max(0,l))}function $_(){var e=MP,t=qP,n=DP,r=LP,o=RP,s=[0,1/0],l=[[-1/0,-1/0],[1/0,1/0]],c=250,f=_A,h=Si("start","zoom","end"),a,u,d,p=500,O=150,g=0,_=10;function y(k){k.property("__zoom",z_).on("wheel.zoom",M,{passive:!1}).on("mousedown.zoom",j).on("dblclick.zoom",I).filter(o).on("touchstart.zoom",A).on("touchmove.zoom",q).on("touchend.zoom touchcancel.zoom",R).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}y.transform=function(k,F,U,ne){var ue=k.selection?k.selection():k;ue.property("__zoom",z_),k!==ue?S(k,F,U,ne):ue.interrupt().each(function(){C(this,arguments).event(ne).start().zoom(null,typeof F=="function"?F.apply(this,arguments):F).end()})},y.scaleBy=function(k,F,U,ne){y.scaleTo(k,function(){var ue=this.__zoom.k,K=typeof F=="function"?F.apply(this,arguments):F;return ue*K},U,ne)},y.scaleTo=function(k,F,U,ne){y.transform(k,function(){var ue=t.apply(this,arguments),K=this.__zoom,W=U==null?m(ue):typeof U=="function"?U.apply(this,arguments):U,z=K.invert(W),Q=typeof F=="function"?F.apply(this,arguments):F;return n(E(w(K,Q),W,z),ue,l)},U,ne)},y.translateBy=function(k,F,U,ne){y.transform(k,function(){return n(this.__zoom.translate(typeof F=="function"?F.apply(this,arguments):F,typeof U=="function"?U.apply(this,arguments):U),t.apply(this,arguments),l)},null,ne)},y.translateTo=function(k,F,U,ne,ue){y.transform(k,function(){var K=t.apply(this,arguments),W=this.__zoom,z=ne==null?m(K):typeof ne=="function"?ne.apply(this,arguments):ne;return n(Tn.translate(z[0],z[1]).scale(W.k).translate(typeof F=="function"?-F.apply(this,arguments):-F,typeof U=="function"?-U.apply(this,arguments):-U),K,l)},ne,ue)};function w(k,F){return F=Math.max(s[0],Math.min(s[1],F)),F===k.k?k:new Nn(F,k.x,k.y)}function E(k,F,U){var ne=F[0]-U[0]*k.k,ue=F[1]-U[1]*k.k;return ne===k.x&&ue===k.y?k:new Nn(k.k,ne,ue)}function m(k){return[(+k[0][0]+ +k[1][0])/2,(+k[0][1]+ +k[1][1])/2]}function S(k,F,U,ne){k.on("start.zoom",function(){C(this,arguments).event(ne).start()}).on("interrupt.zoom end.zoom",function(){C(this,arguments).event(ne).end()}).tween("zoom",function(){var ue=this,K=arguments,W=C(ue,K).event(ne),z=t.apply(ue,K),Q=U==null?m(z):typeof U=="function"?U.apply(ue,K):U,re=Math.max(z[1][0]-z[0][0],z[1][1]-z[0][1]),Z=ue.__zoom,X=typeof F=="function"?F.apply(ue,K):F,H=f(Z.invert(Q).concat(re/Z.k),X.invert(Q).concat(re/X.k));return function(ee){if(ee===1)ee=X;else{var le=H(ee),de=re/le[2];ee=new Nn(de,Q[0]-le[0]*de,Q[1]-le[1]*de)}W.zoom(null,ee)}})}function C(k,F,U){return!U&&k.__zooming||new N(k,F)}function N(k,F){this.that=k,this.args=F,this.active=0,this.sourceEvent=null,this.extent=t.apply(k,F),this.taps=0}N.prototype={event:function(k){return k&&(this.sourceEvent=k),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(k,F){return this.mouse&&k!=="mouse"&&(this.mouse[1]=F.invert(this.mouse[0])),this.touch0&&k!=="touch"&&(this.touch0[1]=F.invert(this.touch0[0])),this.touch1&&k!=="touch"&&(this.touch1[1]=F.invert(this.touch1[0])),this.that.__zoom=F,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(k){var F=Zt(this.that).datum();h.call(k,this.that,new IP(k,{sourceEvent:this.sourceEvent,target:y,transform:this.that.__zoom,dispatch:h}),F)}};function M(k,...F){if(!e.apply(this,arguments))return;var U=C(this,F).event(k),ne=this.__zoom,ue=Math.max(s[0],Math.min(s[1],ne.k*Math.pow(2,r.apply(this,arguments)))),K=an(k);if(U.wheel)(U.mouse[0][0]!==K[0]||U.mouse[0][1]!==K[1])&&(U.mouse[1]=ne.invert(U.mouse[0]=K)),clearTimeout(U.wheel);else{if(ne.k===ue)return;U.mouse=[K,ne.invert(K)],$i(this),U.start()}wo(k),U.wheel=setTimeout(W,O),U.zoom("mouse",n(E(w(ne,ue),U.mouse[0],U.mouse[1]),U.extent,l));function W(){U.wheel=null,U.end()}}function j(k,...F){if(d||!e.apply(this,arguments))return;var U=k.currentTarget,ne=C(this,F,!0).event(k),ue=Zt(k.view).on("mousemove.zoom",Q,!0).on("mouseup.zoom",re,!0),K=an(k,U),W=k.clientX,z=k.clientY;f_(k.view),lh(k),ne.mouse=[K,this.__zoom.invert(K)],$i(this),ne.start();function Q(Z){if(wo(Z),!ne.moved){var X=Z.clientX-W,H=Z.clientY-z;ne.moved=X*X+H*H>g}ne.event(Z).zoom("mouse",n(E(ne.that.__zoom,ne.mouse[0]=an(Z,U),ne.mouse[1]),ne.extent,l))}function re(Z){ue.on("mousemove.zoom mouseup.zoom",null),d_(Z.view,ne.moved),wo(Z),ne.event(Z).end()}}function I(k,...F){if(e.apply(this,arguments)){var U=this.__zoom,ne=an(k.changedTouches?k.changedTouches[0]:k,this),ue=U.invert(ne),K=U.k*(k.shiftKey?.5:2),W=n(E(w(U,K),ne,ue),t.apply(this,F),l);wo(k),c>0?Zt(this).transition().duration(c).call(S,W,ne,k):Zt(this).call(y.transform,W,ne,k)}}function A(k,...F){if(e.apply(this,arguments)){var U=k.touches,ne=U.length,ue=C(this,F,k.changedTouches.length===ne).event(k),K,W,z,Q;for(lh(k),W=0;W<ne;++W)z=U[W],Q=an(z,this),Q=[Q,this.__zoom.invert(Q),z.identifier],ue.touch0?!ue.touch1&&ue.touch0[2]!==Q[2]&&(ue.touch1=Q,ue.taps=0):(ue.touch0=Q,K=!0,ue.taps=1+!!a);a&&(a=clearTimeout(a)),K&&(ue.taps<2&&(u=Q[0],a=setTimeout(function(){a=null},p)),$i(this),ue.start())}}function q(k,...F){if(this.__zooming){var U=C(this,F).event(k),ne=k.changedTouches,ue=ne.length,K,W,z,Q;for(wo(k),K=0;K<ue;++K)W=ne[K],z=an(W,this),U.touch0&&U.touch0[2]===W.identifier?U.touch0[0]=z:U.touch1&&U.touch1[2]===W.identifier&&(U.touch1[0]=z);if(W=U.that.__zoom,U.touch1){var re=U.touch0[0],Z=U.touch0[1],X=U.touch1[0],H=U.touch1[1],ee=(ee=X[0]-re[0])*ee+(ee=X[1]-re[1])*ee,le=(le=H[0]-Z[0])*le+(le=H[1]-Z[1])*le;W=w(W,Math.sqrt(ee/le)),z=[(re[0]+X[0])/2,(re[1]+X[1])/2],Q=[(Z[0]+H[0])/2,(Z[1]+H[1])/2]}else if(U.touch0)z=U.touch0[0],Q=U.touch0[1];else return;U.zoom("touch",n(E(W,z,Q),U.extent,l))}}function R(k,...F){if(this.__zooming){var U=C(this,F).event(k),ne=k.changedTouches,ue=ne.length,K,W;for(lh(k),d&&clearTimeout(d),d=setTimeout(function(){d=null},p),K=0;K<ue;++K)W=ne[K],U.touch0&&U.touch0[2]===W.identifier?delete U.touch0:U.touch1&&U.touch1[2]===W.identifier&&delete U.touch1;if(U.touch1&&!U.touch0&&(U.touch0=U.touch1,delete U.touch1),U.touch0)U.touch0[1]=this.__zoom.invert(U.touch0[0]);else if(U.end(),U.taps===2&&(W=an(W,this),Math.hypot(u[0]-W[0],u[1]-W[1])<_)){var z=Zt(this).on("dblclick.zoom");z&&z.apply(this,arguments)}}}return y.wheelDelta=function(k){return arguments.length?(r=typeof k=="function"?k:Hi(+k),y):r},y.filter=function(k){return arguments.length?(e=typeof k=="function"?k:Hi(!!k),y):e},y.touchable=function(k){return arguments.length?(o=typeof k=="function"?k:Hi(!!k),y):o},y.extent=function(k){return arguments.length?(t=typeof k=="function"?k:Hi([[+k[0][0],+k[0][1]],[+k[1][0],+k[1][1]]]),y):t},y.scaleExtent=function(k){return arguments.length?(s[0]=+k[0],s[1]=+k[1],y):[s[0],s[1]]},y.translateExtent=function(k){return arguments.length?(l[0][0]=+k[0][0],l[1][0]=+k[1][0],l[0][1]=+k[0][1],l[1][1]=+k[1][1],y):[[l[0][0],l[0][1]],[l[1][0],l[1][1]]]},y.constrain=function(k){return arguments.length?(n=k,y):n},y.duration=function(k){return arguments.length?(c=+k,y):c},y.interpolate=function(k){return arguments.length?(f=k,y):f},y.on=function(){var k=h.on.apply(h,arguments);return k===h?y:k},y.clickDistance=function(k){return arguments.length?(g=(k=+k)*k,y):Math.sqrt(g)},y.tapDistance=function(k){return arguments.length?(_=+k,y):_},y}const Vi=se.createContext(null),jP=Vi.Provider,Cn={error001:()=>"[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001",error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The React Flow parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,t)=>`Couldn't create edge for ${e?"target":"source"} handle id: "${e?t.targetHandle:t.sourceHandle}", edge id: ${t.id}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`},H_=Cn.error001();function st(e,t){const n=se.useContext(Vi);if(n===null)throw new Error(H_);return Y1(n,e,t)}const _t=()=>{const e=se.useContext(Vi);if(e===null)throw new Error(H_);return se.useMemo(()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe,destroy:e.destroy}),[e])},FP=e=>e.userSelectionActive?"none":"all";function uh({position:e,children:t,className:n,style:r,...o}){const s=st(FP),l=`${e}`.split("-");return $.jsx("div",{className:Tt(["react-flow__panel",n,...l]),style:{...r,pointerEvents:s},...o,children:t})}function BP({proOptions:e,position:t="bottom-right"}){return e?.hideAttribution?null:$.jsx(uh,{position:t,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev",children:$.jsx("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}const zP=({x:e,y:t,label:n,labelStyle:r={},labelShowBg:o=!0,labelBgStyle:s={},labelBgPadding:l=[2,4],labelBgBorderRadius:c=2,children:f,className:h,...a})=>{const u=se.useRef(null),[d,p]=se.useState({x:0,y:0,width:0,height:0}),O=Tt(["react-flow__edge-textwrapper",h]);return se.useEffect(()=>{if(u.current){const g=u.current.getBBox();p({x:g.x,y:g.y,width:g.width,height:g.height})}},[n]),typeof n>"u"||!n?null:$.jsxs("g",{transform:`translate(${e-d.width/2} ${t-d.height/2})`,className:O,visibility:d.width?"visible":"hidden",...a,children:[o&&$.jsx("rect",{width:d.width+2*l[0],x:-l[0],y:-l[1],height:d.height+2*l[1],className:"react-flow__edge-textbg",style:s,rx:c,ry:c}),$.jsx("text",{className:"react-flow__edge-text",y:d.height/2,dy:"0.3em",ref:u,style:r,children:n}),f]})};var $P=se.memo(zP);const ch=e=>({width:e.offsetWidth,height:e.offsetHeight}),Sr=(e,t=0,n=1)=>Math.min(Math.max(e,t),n),fh=(e={x:0,y:0},t)=>({x:Sr(e.x,t[0][0],t[1][0]),y:Sr(e.y,t[0][1],t[1][1])}),V_=(e,t,n)=>e<t?Sr(Math.abs(e-t),1,50)/50:e>n?-Sr(Math.abs(e-n),1,50)/50:0,U_=(e,t)=>{const n=V_(e.x,35,t.width-35)*20,r=V_(e.y,35,t.height-35)*20;return[n,r]},G_=e=>e.getRootNode?.()||window?.document,K_=(e,t)=>({x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x2,t.x2),y2:Math.max(e.y2,t.y2)}),Oo=({x:e,y:t,width:n,height:r})=>({x:e,y:t,x2:e+n,y2:t+r}),W_=({x:e,y:t,x2:n,y2:r})=>({x:e,y:t,width:n-e,height:r-t}),Y_=e=>({...e.positionAbsolute||{x:0,y:0},width:e.width||0,height:e.height||0}),HP=(e,t)=>W_(K_(Oo(e),Oo(t))),dh=(e,t)=>{const n=Math.max(0,Math.min(e.x+e.width,t.x+t.width)-Math.max(e.x,t.x)),r=Math.max(0,Math.min(e.y+e.height,t.y+t.height)-Math.max(e.y,t.y));return Math.ceil(n*r)},VP=e=>Xt(e.width)&&Xt(e.height)&&Xt(e.x)&&Xt(e.y),Xt=e=>!isNaN(e)&&isFinite(e),wt=Symbol.for("internals"),Z_=["Enter"," ","Escape"],UP=(e,t)=>{},GP=e=>"nativeEvent"in e;function hh(e){const n=(GP(e)?e.nativeEvent:e).composedPath?.()?.[0]||e.target;return["INPUT","SELECT","TEXTAREA"].includes(n?.nodeName)||n?.hasAttribute("contenteditable")||!!n?.closest(".nokey")}const X_=e=>"clientX"in e,Dn=(e,t)=>{const n=X_(e),r=n?e.clientX:e.touches?.[0].clientX,o=n?e.clientY:e.touches?.[0].clientY;return{x:r-(t?.left??0),y:o-(t?.top??0)}},Ui=()=>typeof navigator<"u"&&navigator?.userAgent?.indexOf("Mac")>=0,Eo=({id:e,path:t,labelX:n,labelY:r,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h,style:a,markerEnd:u,markerStart:d,interactionWidth:p=20})=>$.jsxs($.Fragment,{children:[$.jsx("path",{id:e,style:a,d:t,fill:"none",className:"react-flow__edge-path",markerEnd:u,markerStart:d}),p&&$.jsx("path",{d:t,fill:"none",strokeOpacity:0,strokeWidth:p,className:"react-flow__edge-interaction"}),o&&Xt(n)&&Xt(r)?$.jsx($P,{x:n,y:r,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h}):null]});Eo.displayName="BaseEdge";function xo(e,t,n){return n===void 0?n:r=>{const o=t().edges.find(s=>s.id===e);o&&n(r,{...o})}}function Q_({sourceX:e,sourceY:t,targetX:n,targetY:r}){const o=Math.abs(n-e)/2,s=n<e?n+o:n-o,l=Math.abs(r-t)/2,c=r<t?r+l:r-l;return[s,c,o,l]}function J_({sourceX:e,sourceY:t,targetX:n,targetY:r,sourceControlX:o,sourceControlY:s,targetControlX:l,targetControlY:c}){const f=e*.125+o*.375+l*.375+n*.125,h=t*.125+s*.375+c*.375+r*.125,a=Math.abs(f-e),u=Math.abs(h-t);return[f,h,a,u]}var tr;(function(e){e.Strict="strict",e.Loose="loose"})(tr||(tr={}));var nr;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(nr||(nr={}));var So;(function(e){e.Partial="partial",e.Full="full"})(So||(So={}));var vn;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(vn||(vn={}));var Gi;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(Gi||(Gi={}));var Ce;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Ce||(Ce={}));function ew({pos:e,x1:t,y1:n,x2:r,y2:o}){return e===Ce.Left||e===Ce.Right?[.5*(t+r),n]:[t,.5*(n+o)]}function tw({sourceX:e,sourceY:t,sourcePosition:n=Ce.Bottom,targetX:r,targetY:o,targetPosition:s=Ce.Top}){const[l,c]=ew({pos:n,x1:e,y1:t,x2:r,y2:o}),[f,h]=ew({pos:s,x1:r,y1:o,x2:e,y2:t}),[a,u,d,p]=J_({sourceX:e,sourceY:t,targetX:r,targetY:o,sourceControlX:l,sourceControlY:c,targetControlX:f,targetControlY:h});return[`M${e},${t} C${l},${c} ${f},${h} ${r},${o}`,a,u,d,p]}const ph=se.memo(({sourceX:e,sourceY:t,targetX:n,targetY:r,sourcePosition:o=Ce.Bottom,targetPosition:s=Ce.Top,label:l,labelStyle:c,labelShowBg:f,labelBgStyle:h,labelBgPadding:a,labelBgBorderRadius:u,style:d,markerEnd:p,markerStart:O,interactionWidth:g})=>{const[_,y,w]=tw({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:s});return $.jsx(Eo,{path:_,labelX:y,labelY:w,label:l,labelStyle:c,labelShowBg:f,labelBgStyle:h,labelBgPadding:a,labelBgBorderRadius:u,style:d,markerEnd:p,markerStart:O,interactionWidth:g})});ph.displayName="SimpleBezierEdge";const nw={[Ce.Left]:{x:-1,y:0},[Ce.Right]:{x:1,y:0},[Ce.Top]:{x:0,y:-1},[Ce.Bottom]:{x:0,y:1}},KP=({source:e,sourcePosition:t=Ce.Bottom,target:n})=>t===Ce.Left||t===Ce.Right?e.x<n.x?{x:1,y:0}:{x:-1,y:0}:e.y<n.y?{x:0,y:1}:{x:0,y:-1},rw=(e,t)=>Math.sqrt(Math.pow(t.x-e.x,2)+Math.pow(t.y-e.y,2));function WP({source:e,sourcePosition:t=Ce.Bottom,target:n,targetPosition:r=Ce.Top,center:o,offset:s}){const l=nw[t],c=nw[r],f={x:e.x+l.x*s,y:e.y+l.y*s},h={x:n.x+c.x*s,y:n.y+c.y*s},a=KP({source:f,sourcePosition:t,target:h}),u=a.x!==0?"x":"y",d=a[u];let p=[],O,g;const _={x:0,y:0},y={x:0,y:0},[w,E,m,S]=Q_({sourceX:e.x,sourceY:e.y,targetX:n.x,targetY:n.y});if(l[u]*c[u]===-1){O=o.x||w,g=o.y||E;const N=[{x:O,y:f.y},{x:O,y:h.y}],M=[{x:f.x,y:g},{x:h.x,y:g}];l[u]===d?p=u==="x"?N:M:p=u==="x"?M:N}else{const N=[{x:f.x,y:h.y}],M=[{x:h.x,y:f.y}];if(u==="x"?p=l.x===d?M:N:p=l.y===d?N:M,t===r){const R=Math.abs(e[u]-n[u]);if(R<=s){const k=Math.min(s-1,s-R);l[u]===d?_[u]=k:y[u]=k}}if(t!==r){const R=u==="x"?"y":"x",k=l[u]===c[R],F=f[R]>h[R],U=f[R]<h[R];(l[u]===1&&(!k&&F||k&&U)||l[u]!==1&&(!k&&U||k&&F))&&(p=u==="x"?N:M)}const j={x:f.x-_.x,y:f.y-_.y},I={x:h.x-y.x,y:h.y-y.y},A=Math.max(Math.abs(j.x-p[0].x),Math.abs(I.x-p[0].x)),q=Math.max(Math.abs(j.y-p[0].y),Math.abs(I.y-p[0].y));A>=q?(O=(j.x+I.x)/2,g=p[0].y):(O=p[0].x,g=(j.y+I.y)/2)}return[[e,{x:f.x-_.x,y:f.y-_.y},...p,{x:h.x-y.x,y:h.y-y.y},n],O,g,m,S]}function YP(e,t,n,r){const o=Math.min(rw(e,t)/2,rw(t,n)/2,r),{x:s,y:l}=t;if(e.x===s&&s===n.x||e.y===l&&l===n.y)return`L${s} ${l}`;if(e.y===l){const h=e.x<n.x?-1:1,a=e.y<n.y?1:-1;return`L ${s+o*h},${l}Q ${s},${l} ${s},${l+o*a}`}const c=e.x<n.x?1:-1,f=e.y<n.y?-1:1;return`L ${s},${l+o*f}Q ${s},${l} ${s+o*c},${l}`}function vh({sourceX:e,sourceY:t,sourcePosition:n=Ce.Bottom,targetX:r,targetY:o,targetPosition:s=Ce.Top,borderRadius:l=5,centerX:c,centerY:f,offset:h=20}){const[a,u,d,p,O]=WP({source:{x:e,y:t},sourcePosition:n,target:{x:r,y:o},targetPosition:s,center:{x:c,y:f},offset:h});return[a.reduce((_,y,w)=>{let E="";return w>0&&w<a.length-1?E=YP(a[w-1],y,a[w+1],l):E=`${w===0?"M":"L"}${y.x} ${y.y}`,_+=E,_},""),u,d,p,O]}const Ki=se.memo(({sourceX:e,sourceY:t,targetX:n,targetY:r,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h,style:a,sourcePosition:u=Ce.Bottom,targetPosition:d=Ce.Top,markerEnd:p,markerStart:O,pathOptions:g,interactionWidth:_})=>{const[y,w,E]=vh({sourceX:e,sourceY:t,sourcePosition:u,targetX:n,targetY:r,targetPosition:d,borderRadius:g?.borderRadius,offset:g?.offset});return $.jsx(Eo,{path:y,labelX:w,labelY:E,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h,style:a,markerEnd:p,markerStart:O,interactionWidth:_})});Ki.displayName="SmoothStepEdge";const gh=se.memo(e=>$.jsx(Ki,{...e,pathOptions:se.useMemo(()=>({borderRadius:0,offset:e.pathOptions?.offset}),[e.pathOptions?.offset])}));gh.displayName="StepEdge";function ZP({sourceX:e,sourceY:t,targetX:n,targetY:r}){const[o,s,l,c]=Q_({sourceX:e,sourceY:t,targetX:n,targetY:r});return[`M ${e},${t}L ${n},${r}`,o,s,l,c]}const yh=se.memo(({sourceX:e,sourceY:t,targetX:n,targetY:r,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h,style:a,markerEnd:u,markerStart:d,interactionWidth:p})=>{const[O,g,_]=ZP({sourceX:e,sourceY:t,targetX:n,targetY:r});return $.jsx(Eo,{path:O,labelX:g,labelY:_,label:o,labelStyle:s,labelShowBg:l,labelBgStyle:c,labelBgPadding:f,labelBgBorderRadius:h,style:a,markerEnd:u,markerStart:d,interactionWidth:p})});yh.displayName="StraightEdge";function Wi(e,t){return e>=0?.5*e:t*25*Math.sqrt(-e)}function ow({pos:e,x1:t,y1:n,x2:r,y2:o,c:s}){switch(e){case Ce.Left:return[t-Wi(t-r,s),n];case Ce.Right:return[t+Wi(r-t,s),n];case Ce.Top:return[t,n-Wi(n-o,s)];case Ce.Bottom:return[t,n+Wi(o-n,s)]}}function iw({sourceX:e,sourceY:t,sourcePosition:n=Ce.Bottom,targetX:r,targetY:o,targetPosition:s=Ce.Top,curvature:l=.25}){const[c,f]=ow({pos:n,x1:e,y1:t,x2:r,y2:o,c:l}),[h,a]=ow({pos:s,x1:r,y1:o,x2:e,y2:t,c:l}),[u,d,p,O]=J_({sourceX:e,sourceY:t,targetX:r,targetY:o,sourceControlX:c,sourceControlY:f,targetControlX:h,targetControlY:a});return[`M${e},${t} C${c},${f} ${h},${a} ${r},${o}`,u,d,p,O]}const Yi=se.memo(({sourceX:e,sourceY:t,targetX:n,targetY:r,sourcePosition:o=Ce.Bottom,targetPosition:s=Ce.Top,label:l,labelStyle:c,labelShowBg:f,labelBgStyle:h,labelBgPadding:a,labelBgBorderRadius:u,style:d,markerEnd:p,markerStart:O,pathOptions:g,interactionWidth:_})=>{const[y,w,E]=iw({sourceX:e,sourceY:t,sourcePosition:o,targetX:n,targetY:r,targetPosition:s,curvature:g?.curvature});return $.jsx(Eo,{path:y,labelX:w,labelY:E,label:l,labelStyle:c,labelShowBg:f,labelBgStyle:h,labelBgPadding:a,labelBgBorderRadius:u,style:d,markerEnd:p,markerStart:O,interactionWidth:_})});Yi.displayName="BezierEdge";const mh=se.createContext(null),XP=mh.Provider;mh.Consumer;const QP=()=>se.useContext(mh),JP=e=>"id"in e&&"source"in e&&"target"in e,eI=({source:e,sourceHandle:t,target:n,targetHandle:r})=>`reactflow__edge-${e}${t||""}-${n}${r||""}`,bh=(e,t)=>typeof e>"u"?"":typeof e=="string"?e:`${t?`${t}__`:""}${Object.keys(e).sort().map(r=>`${r}=${e[r]}`).join("&")}`,tI=(e,t)=>t.some(n=>n.source===e.source&&n.target===e.target&&(n.sourceHandle===e.sourceHandle||!n.sourceHandle&&!e.sourceHandle)&&(n.targetHandle===e.targetHandle||!n.targetHandle&&!e.targetHandle)),nI=(e,t)=>{if(!e.source||!e.target)return t;let n;return JP(e)?n={...e}:n={...e,id:eI(e)},tI(n,t)?t:t.concat(n)},aw=({x:e,y:t},[n,r,o],s,[l,c])=>{const f={x:(e-n)/o,y:(t-r)/o};return s?{x:l*Math.round(f.x/l),y:c*Math.round(f.y/c)}:f},rI=({x:e,y:t},[n,r,o])=>({x:e*o+n,y:t*o+r}),rr=(e,t=[0,0])=>{if(!e)return{x:0,y:0,positionAbsolute:{x:0,y:0}};const n=(e.width??0)*t[0],r=(e.height??0)*t[1],o={x:e.position.x-n,y:e.position.y-r};return{...o,positionAbsolute:e.positionAbsolute?{x:e.positionAbsolute.x-n,y:e.positionAbsolute.y-r}:o}},Zi=(e,t=[0,0])=>{if(e.length===0)return{x:0,y:0,width:0,height:0};const n=e.reduce((r,o)=>{const{x:s,y:l}=rr(o,t).positionAbsolute;return K_(r,Oo({x:s,y:l,width:o.width||0,height:o.height||0}))},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return W_(n)},sw=(e,t,[n,r,o]=[0,0,1],s=!1,l=!1,c=[0,0])=>{const f={x:(t.x-n)/o,y:(t.y-r)/o,width:t.width/o,height:t.height/o},h=[];return e.forEach(a=>{const{width:u,height:d,selectable:p=!0,hidden:O=!1}=a;if(l&&!p||O)return!1;const{positionAbsolute:g}=rr(a,c),_={x:g.x,y:g.y,width:u||0,height:d||0},y=dh(f,_),w=typeof u>"u"||typeof d>"u"||u===null||d===null,E=s&&y>0,m=(u||0)*(d||0);(w||E||y>=m||a.dragging)&&h.push(a)}),h},lw=(e,t)=>{const n=e.map(r=>r.id);return t.filter(r=>n.includes(r.source)||n.includes(r.target))},uw=(e,t,n,r,o,s=.1)=>{const l=t/(e.width*(1+s)),c=n/(e.height*(1+s)),f=Math.min(l,c),h=Sr(f,r,o),a=e.x+e.width/2,u=e.y+e.height/2,d=t/2-a*h,p=n/2-u*h;return[d,p,h]},or=(e,t=0)=>e.transition().duration(t);function cw(e,t,n,r){return(t[n]||[]).reduce((o,s)=>(`${e.id}-${s.id}-${n}`!==r&&o.push({id:s.id||null,type:n,nodeId:e.id,x:(e.positionAbsolute?.x??0)+s.x+s.width/2,y:(e.positionAbsolute?.y??0)+s.y+s.height/2}),o),[])}function oI(e,t,n,r,o,s){const{x:l,y:c}=Dn(e),h=t.elementsFromPoint(l,c).find(O=>O.classList.contains("react-flow__handle"));if(h){const O=h.getAttribute("data-nodeid");if(O){const g=_h(void 0,h),_=h.getAttribute("data-handleid"),y=s({nodeId:O,id:_,type:g});if(y)return{handle:{id:_,type:g,nodeId:O,x:n.x,y:n.y},validHandleResult:y}}}let a=[],u=1/0;if(o.forEach(O=>{const g=Math.sqrt((O.x-n.x)**2+(O.y-n.y)**2);if(g<=r){const _=s(O);g<=u&&(g<u?a=[{handle:O,validHandleResult:_}]:g===u&&a.push({handle:O,validHandleResult:_}),u=g)}}),!a.length)return{handle:null,validHandleResult:fw()};if(a.length===1)return a[0];const d=a.some(({validHandleResult:O})=>O.isValid),p=a.some(({handle:O})=>O.type==="target");return a.find(({handle:O,validHandleResult:g})=>p?O.type==="target":d?g.isValid:!0)||a[0]}const iI={source:null,target:null,sourceHandle:null,targetHandle:null},fw=()=>({handleDomNode:null,isValid:!1,connection:iI,endHandle:null});function dw(e,t,n,r,o,s,l){const c=o==="target",f=l.querySelector(`.react-flow__handle[data-id="${e?.nodeId}-${e?.id}-${e?.type}"]`),h={...fw(),handleDomNode:f};if(f){const a=_h(void 0,f),u=f.getAttribute("data-nodeid"),d=f.getAttribute("data-handleid"),p=f.classList.contains("connectable"),O=f.classList.contains("connectableend"),g={source:c?u:n,sourceHandle:c?d:r,target:c?n:u,targetHandle:c?r:d};h.connection=g,p&&O&&(t===tr.Strict?c&&a==="source"||!c&&a==="target":u!==n||d!==r)&&(h.endHandle={nodeId:u,handleId:d,type:a},h.isValid=s(g))}return h}function aI({nodes:e,nodeId:t,handleId:n,handleType:r}){return e.reduce((o,s)=>{if(s[wt]){const{handleBounds:l}=s[wt];let c=[],f=[];l&&(c=cw(s,l,"source",`${t}-${n}-${r}`),f=cw(s,l,"target",`${t}-${n}-${r}`)),o.push(...c,...f)}return o},[])}function _h(e,t){return e||(t?.classList.contains("target")?"target":t?.classList.contains("source")?"source":null)}function wh(e){e?.classList.remove("valid","connecting","react-flow__handle-valid","react-flow__handle-connecting")}function sI(e,t){let n=null;return t?n="valid":e&&!t&&(n="invalid"),n}function hw({event:e,handleId:t,nodeId:n,onConnect:r,isTarget:o,getState:s,setState:l,isValidConnection:c,edgeUpdaterType:f,onEdgeUpdateEnd:h}){const a=G_(e.target),{connectionMode:u,domNode:d,autoPanOnConnect:p,connectionRadius:O,onConnectStart:g,panBy:_,getNodes:y,cancelConnection:w}=s();let E=0,m;const{x:S,y:C}=Dn(e),N=a?.elementFromPoint(S,C),M=_h(f,N),j=d?.getBoundingClientRect();if(!j||!M)return;let I,A=Dn(e,j),q=!1,R=null,k=!1,F=null;const U=aI({nodes:y(),nodeId:n,handleId:t,handleType:M}),ne=()=>{if(!p)return;const[W,z]=U_(A,j);_({x:W,y:z}),E=requestAnimationFrame(ne)};l({connectionPosition:A,connectionStatus:null,connectionNodeId:n,connectionHandleId:t,connectionHandleType:M,connectionStartHandle:{nodeId:n,handleId:t,type:M},connectionEndHandle:null}),g?.(e,{nodeId:n,handleId:t,handleType:M});function ue(W){const{transform:z}=s();A=Dn(W,j);const{handle:Q,validHandleResult:re}=oI(W,a,aw(A,z,!1,[1,1]),O,U,Z=>dw(Z,u,n,t,o?"target":"source",c,a));if(m=Q,q||(ne(),q=!0),F=re.handleDomNode,R=re.connection,k=re.isValid,l({connectionPosition:m&&k?rI({x:m.x,y:m.y},z):A,connectionStatus:sI(!!m,k),connectionEndHandle:re.endHandle}),!m&&!k&&!F)return wh(I);R.source!==R.target&&F&&(wh(I),I=F,F.classList.add("connecting","react-flow__handle-connecting"),F.classList.toggle("valid",k),F.classList.toggle("react-flow__handle-valid",k))}function K(W){(m||F)&&R&&k&&r?.(R),s().onConnectEnd?.(W),f&&h?.(W),wh(I),w(),cancelAnimationFrame(E),q=!1,k=!1,R=null,F=null,a.removeEventListener("mousemove",ue),a.removeEventListener("mouseup",K),a.removeEventListener("touchmove",ue),a.removeEventListener("touchend",K)}a.addEventListener("mousemove",ue),a.addEventListener("mouseup",K),a.addEventListener("touchmove",ue),a.addEventListener("touchend",K)}const pw=()=>!0,lI=e=>({connectionStartHandle:e.connectionStartHandle,connectOnClick:e.connectOnClick,noPanClassName:e.noPanClassName}),uI=(e,t,n)=>r=>{const{connectionStartHandle:o,connectionEndHandle:s,connectionClickStartHandle:l}=r;return{connecting:o?.nodeId===e&&o?.handleId===t&&o?.type===n||s?.nodeId===e&&s?.handleId===t&&s?.type===n,clickConnecting:l?.nodeId===e&&l?.handleId===t&&l?.type===n}},vw=se.forwardRef(({type:e="source",position:t=Ce.Top,isValidConnection:n,isConnectable:r=!0,isConnectableStart:o=!0,isConnectableEnd:s=!0,id:l,onConnect:c,children:f,className:h,onMouseDown:a,onTouchStart:u,...d},p)=>{const O=l||null,g=e==="target",_=_t(),y=QP(),{connectOnClick:w,noPanClassName:E}=st(lI,St),{connecting:m,clickConnecting:S}=st(uI(y,O,e),St);y||_.getState().onError?.("010",Cn.error010());const C=j=>{const{defaultEdgeOptions:I,onConnect:A,hasDefaultEdges:q}=_.getState(),R={...I,...j};if(q){const{edges:k,setEdges:F}=_.getState();F(nI(R,k))}A?.(R),c?.(R)},N=j=>{if(!y)return;const I=X_(j);o&&(I&&j.button===0||!I)&&hw({event:j,handleId:O,nodeId:y,onConnect:C,isTarget:g,getState:_.getState,setState:_.setState,isValidConnection:n||_.getState().isValidConnection||pw}),I?a?.(j):u?.(j)},M=j=>{const{onClickConnectStart:I,onClickConnectEnd:A,connectionClickStartHandle:q,connectionMode:R,isValidConnection:k}=_.getState();if(!y||!q&&!o)return;if(!q){I?.(j,{nodeId:y,handleId:O,handleType:e}),_.setState({connectionClickStartHandle:{nodeId:y,type:e,handleId:O}});return}const F=G_(j.target),U=n||k||pw,{connection:ne,isValid:ue}=dw({nodeId:y,id:O,type:e},R,q.nodeId,q.handleId||null,q.type,U,F);ue&&C(ne),A?.(j),_.setState({connectionClickStartHandle:null})};return $.jsx("div",{"data-handleid":O,"data-nodeid":y,"data-handlepos":t,"data-id":`${y}-${O}-${e}`,className:Tt(["react-flow__handle",`react-flow__handle-${t}`,"nodrag",E,h,{source:!g,target:g,connectable:r,connectablestart:o,connectableend:s,connecting:S,connectionindicator:r&&(o&&!m||s&&m)}]),onMouseDown:N,onTouchStart:N,onClick:w?M:void 0,ref:p,...d,children:f})});vw.displayName="Handle";var vt=se.memo(vw);const gw=({data:e,isConnectable:t,targetPosition:n=Ce.Top,sourcePosition:r=Ce.Bottom})=>$.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:n,isConnectable:t}),e?.label,$.jsx(vt,{type:"source",position:r,isConnectable:t})]});gw.displayName="DefaultNode";var Oh=se.memo(gw);const yw=({data:e,isConnectable:t,sourcePosition:n=Ce.Bottom})=>$.jsxs($.Fragment,{children:[e?.label,$.jsx(vt,{type:"source",position:n,isConnectable:t})]});yw.displayName="InputNode";var mw=se.memo(yw);const bw=({data:e,isConnectable:t,targetPosition:n=Ce.Top})=>$.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:n,isConnectable:t}),e?.label]});bw.displayName="OutputNode";var _w=se.memo(bw);const Eh=()=>null;Eh.displayName="GroupNode";const cI=e=>({selectedNodes:e.getNodes().filter(t=>t.selected),selectedEdges:e.edges.filter(t=>t.selected)}),Xi=e=>e.id;function fI(e,t){return St(e.selectedNodes.map(Xi),t.selectedNodes.map(Xi))&&St(e.selectedEdges.map(Xi),t.selectedEdges.map(Xi))}const ww=se.memo(({onSelectionChange:e})=>{const t=_t(),{selectedNodes:n,selectedEdges:r}=st(cI,fI);return se.useEffect(()=>{const o={nodes:n,edges:r};e?.(o),t.getState().onSelectionChange?.(o)},[n,r,e]),null});ww.displayName="SelectionListener";const dI=e=>!!e.onSelectionChange;function hI({onSelectionChange:e}){const t=st(dI);return e||t?$.jsx(ww,{onSelectionChange:e}):null}const pI=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset});function kr(e,t){se.useEffect(()=>{typeof e<"u"&&t(e)},[e])}function Xe(e,t,n){se.useEffect(()=>{typeof t<"u"&&n({[e]:t})},[t])}const vI=({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:o,onConnectStart:s,onConnectEnd:l,onClickConnectStart:c,onClickConnectEnd:f,nodesDraggable:h,nodesConnectable:a,nodesFocusable:u,edgesFocusable:d,edgesUpdatable:p,elevateNodesOnSelect:O,minZoom:g,maxZoom:_,nodeExtent:y,onNodesChange:w,onEdgesChange:E,elementsSelectable:m,connectionMode:S,snapGrid:C,snapToGrid:N,translateExtent:M,connectOnClick:j,defaultEdgeOptions:I,fitView:A,fitViewOptions:q,onNodesDelete:R,onEdgesDelete:k,onNodeDrag:F,onNodeDragStart:U,onNodeDragStop:ne,onSelectionDrag:ue,onSelectionDragStart:K,onSelectionDragStop:W,noPanClassName:z,nodeOrigin:Q,rfId:re,autoPanOnConnect:Z,autoPanOnNodeDrag:X,onError:H,connectionRadius:ee,isValidConnection:le})=>{const{setNodes:de,setEdges:pe,setDefaultNodesAndEdges:Ee,setMinZoom:Ie,setMaxZoom:Pe,setTranslateExtent:Ae,setNodeExtent:Se,reset:Ge}=st(pI,St),Oe=_t();return se.useEffect(()=>{const ge=r?.map(me=>({...me,...I}));return Ee(n,ge),()=>{Ge()}},[]),Xe("defaultEdgeOptions",I,Oe.setState),Xe("connectionMode",S,Oe.setState),Xe("onConnect",o,Oe.setState),Xe("onConnectStart",s,Oe.setState),Xe("onConnectEnd",l,Oe.setState),Xe("onClickConnectStart",c,Oe.setState),Xe("onClickConnectEnd",f,Oe.setState),Xe("nodesDraggable",h,Oe.setState),Xe("nodesConnectable",a,Oe.setState),Xe("nodesFocusable",u,Oe.setState),Xe("edgesFocusable",d,Oe.setState),Xe("edgesUpdatable",p,Oe.setState),Xe("elementsSelectable",m,Oe.setState),Xe("elevateNodesOnSelect",O,Oe.setState),Xe("snapToGrid",N,Oe.setState),Xe("snapGrid",C,Oe.setState),Xe("onNodesChange",w,Oe.setState),Xe("onEdgesChange",E,Oe.setState),Xe("connectOnClick",j,Oe.setState),Xe("fitViewOnInit",A,Oe.setState),Xe("fitViewOnInitOptions",q,Oe.setState),Xe("onNodesDelete",R,Oe.setState),Xe("onEdgesDelete",k,Oe.setState),Xe("onNodeDrag",F,Oe.setState),Xe("onNodeDragStart",U,Oe.setState),Xe("onNodeDragStop",ne,Oe.setState),Xe("onSelectionDrag",ue,Oe.setState),Xe("onSelectionDragStart",K,Oe.setState),Xe("onSelectionDragStop",W,Oe.setState),Xe("noPanClassName",z,Oe.setState),Xe("nodeOrigin",Q,Oe.setState),Xe("rfId",re,Oe.setState),Xe("autoPanOnConnect",Z,Oe.setState),Xe("autoPanOnNodeDrag",X,Oe.setState),Xe("onError",H,Oe.setState),Xe("connectionRadius",ee,Oe.setState),Xe("isValidConnection",le,Oe.setState),kr(e,de),kr(t,pe),kr(g,Ie),kr(_,Pe),kr(M,Ae),kr(y,Se),null},Ow={display:"none"},gI={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},Ew="react-flow__node-desc",xw="react-flow__edge-desc",yI="react-flow__aria-live",mI=e=>e.ariaLiveMessage;function bI({rfId:e}){const t=st(mI);return $.jsx("div",{id:`${yI}-${e}`,"aria-live":"assertive","aria-atomic":"true",style:gI,children:t})}function _I({rfId:e,disableKeyboardA11y:t}){return $.jsxs($.Fragment,{children:[$.jsxs("div",{id:`${Ew}-${e}`,style:Ow,children:["Press enter or space to select a node.",!t&&"You can then use the arrow keys to move the node around."," Press delete to remove it and escape to cancel."," "]}),$.jsx("div",{id:`${xw}-${e}`,style:Ow,children:"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel."}),!t&&$.jsx(bI,{rfId:e})]})}const wI=typeof document<"u"?document:null;var ko=(e=null,t={target:wI})=>{const[n,r]=se.useState(!1),o=se.useRef(!1),s=se.useRef(new Set([])),[l,c]=se.useMemo(()=>{if(e!==null){const h=(Array.isArray(e)?e:[e]).filter(u=>typeof u=="string").map(u=>u.split("+")),a=h.reduce((u,d)=>u.concat(...d),[]);return[h,a]}return[[],[]]},[e]);return se.useEffect(()=>{if(e!==null){const f=u=>{if(o.current=u.ctrlKey||u.metaKey||u.shiftKey,!o.current&&hh(u))return!1;const d=kw(u.code,c);s.current.add(u[d]),Sw(l,s.current,!1)&&(u.preventDefault(),r(!0))},h=u=>{if(!o.current&&hh(u))return!1;const d=kw(u.code,c);Sw(l,s.current,!0)?(r(!1),s.current.clear()):s.current.delete(u[d]),u.key==="Meta"&&s.current.clear(),o.current=!1},a=()=>{s.current.clear(),r(!1)};return t?.target?.addEventListener("keydown",f),t?.target?.addEventListener("keyup",h),window.addEventListener("blur",a),()=>{t?.target?.removeEventListener("keydown",f),t?.target?.removeEventListener("keyup",h),window.removeEventListener("blur",a)}}},[e,r]),n};function Sw(e,t,n){return e.filter(r=>n||r.length===t.size).some(r=>r.every(o=>t.has(o)))}function kw(e,t){return t.includes(e)?"code":"key"}function Nw(e,t,n,r){if(!e.parentNode)return n;const o=t.get(e.parentNode),s=rr(o,r);return Nw(o,t,{x:(n.x??0)+s.x,y:(n.y??0)+s.y,z:(o[wt]?.z??0)>(n.z??0)?o[wt]?.z??0:n.z??0},r)}function Tw(e,t,n){e.forEach(r=>{if(r.parentNode&&!e.has(r.parentNode))throw new Error(`Parent node ${r.parentNode} not found`);if(r.parentNode||n?.[r.id]){const{x:o,y:s,z:l}=Nw(r,e,{...r.position,z:r[wt]?.z??0},t);r.positionAbsolute={x:o,y:s},r[wt].z=l,n?.[r.id]&&(r[wt].isParent=!0)}})}function xh(e,t,n,r){const o=new Map,s={},l=r?1e3:0;return e.forEach(c=>{const f=(Xt(c.zIndex)?c.zIndex:0)+(c.selected?l:0),h=t.get(c.id),a={width:h?.width,height:h?.height,...c,positionAbsolute:{x:c.position.x,y:c.position.y}};c.parentNode&&(a.parentNode=c.parentNode,s[c.parentNode]=!0),Object.defineProperty(a,wt,{enumerable:!1,value:{handleBounds:h?.[wt]?.handleBounds,z:f}}),o.set(c.id,a)}),Tw(o,n,s),o}function Cw(e,t={}){const{getNodes:n,width:r,height:o,minZoom:s,maxZoom:l,d3Zoom:c,d3Selection:f,fitViewOnInitDone:h,fitViewOnInit:a,nodeOrigin:u}=e(),d=t.initial&&!h&&a;if(c&&f&&(d||!t.initial)){const O=n().filter(_=>{const y=t.includeHiddenNodes?_.width&&_.height:!_.hidden;return t.nodes?.length?y&&t.nodes.some(w=>w.id===_.id):y}),g=O.every(_=>_.width&&_.height);if(O.length>0&&g){const _=Zi(O,u),[y,w,E]=uw(_,r,o,t.minZoom??s,t.maxZoom??l,t.padding??.1),m=Tn.translate(y,w).scale(E);return typeof t.duration=="number"&&t.duration>0?c.transform(or(f,t.duration),m):c.transform(f,m),!0}}return!1}function OI(e,t){return e.forEach(n=>{const r=t.get(n.id);r&&t.set(r.id,{...r,[wt]:r[wt],selected:n.selected})}),new Map(t)}function EI(e,t){return t.map(n=>{const r=e.find(o=>o.id===n.id);return r&&(n.selected=r.selected),n})}function Qi({changedNodes:e,changedEdges:t,get:n,set:r}){const{nodeInternals:o,edges:s,onNodesChange:l,onEdgesChange:c,hasDefaultNodes:f,hasDefaultEdges:h}=n();e?.length&&(f&&r({nodeInternals:OI(e,o)}),l?.(e)),t?.length&&(h&&r({edges:EI(t,s)}),c?.(t))}const Nr=()=>{},xI={zoomIn:Nr,zoomOut:Nr,zoomTo:Nr,getZoom:()=>1,setViewport:Nr,getViewport:()=>({x:0,y:0,zoom:1}),fitView:()=>!1,setCenter:Nr,fitBounds:Nr,project:e=>e,viewportInitialized:!1},SI=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection}),kI=()=>{const e=_t(),{d3Zoom:t,d3Selection:n}=st(SI,St);return se.useMemo(()=>n&&t?{zoomIn:o=>t.scaleBy(or(n,o?.duration),1.2),zoomOut:o=>t.scaleBy(or(n,o?.duration),1/1.2),zoomTo:(o,s)=>t.scaleTo(or(n,s?.duration),o),getZoom:()=>e.getState().transform[2],setViewport:(o,s)=>{const[l,c,f]=e.getState().transform,h=Tn.translate(o.x??l,o.y??c).scale(o.zoom??f);t.transform(or(n,s?.duration),h)},getViewport:()=>{const[o,s,l]=e.getState().transform;return{x:o,y:s,zoom:l}},fitView:o=>Cw(e.getState,o),setCenter:(o,s,l)=>{const{width:c,height:f,maxZoom:h}=e.getState(),a=typeof l?.zoom<"u"?l.zoom:h,u=c/2-o*a,d=f/2-s*a,p=Tn.translate(u,d).scale(a);t.transform(or(n,l?.duration),p)},fitBounds:(o,s)=>{const{width:l,height:c,minZoom:f,maxZoom:h}=e.getState(),[a,u,d]=uw(o,l,c,f,h,s?.padding??.1),p=Tn.translate(a,u).scale(d);t.transform(or(n,s?.duration),p)},project:o=>{const{transform:s,snapToGrid:l,snapGrid:c}=e.getState();return aw(o,s,l,c)},viewportInitialized:!0}:xI,[t,n])};function Ji(){const e=kI(),t=_t(),n=se.useCallback(()=>t.getState().getNodes().map(g=>({...g})),[]),r=se.useCallback(g=>t.getState().nodeInternals.get(g),[]),o=se.useCallback(()=>{const{edges:g=[]}=t.getState();return g.map(_=>({..._}))},[]),s=se.useCallback(g=>{const{edges:_=[]}=t.getState();return _.find(y=>y.id===g)},[]),l=se.useCallback(g=>{const{getNodes:_,setNodes:y,hasDefaultNodes:w,onNodesChange:E}=t.getState(),m=_(),S=typeof g=="function"?g(m):g;if(w)y(S);else if(E){const C=S.length===0?m.map(N=>({type:"remove",id:N.id})):S.map(N=>({item:N,type:"reset"}));E(C)}},[]),c=se.useCallback(g=>{const{edges:_=[],setEdges:y,hasDefaultEdges:w,onEdgesChange:E}=t.getState(),m=typeof g=="function"?g(_):g;if(w)y(m);else if(E){const S=m.length===0?_.map(C=>({type:"remove",id:C.id})):m.map(C=>({item:C,type:"reset"}));E(S)}},[]),f=se.useCallback(g=>{const _=Array.isArray(g)?g:[g],{getNodes:y,setNodes:w,hasDefaultNodes:E,onNodesChange:m}=t.getState();if(E){const C=[...y(),..._];w(C)}else if(m){const S=_.map(C=>({item:C,type:"add"}));m(S)}},[]),h=se.useCallback(g=>{const _=Array.isArray(g)?g:[g],{edges:y=[],setEdges:w,hasDefaultEdges:E,onEdgesChange:m}=t.getState();if(E)w([...y,..._]);else if(m){const S=_.map(C=>({item:C,type:"add"}));m(S)}},[]),a=se.useCallback(()=>{const{getNodes:g,edges:_=[],transform:y}=t.getState(),[w,E,m]=y;return{nodes:g().map(S=>({...S})),edges:_.map(S=>({...S})),viewport:{x:w,y:E,zoom:m}}},[]),u=se.useCallback(({nodes:g,edges:_})=>{const{nodeInternals:y,getNodes:w,edges:E,hasDefaultNodes:m,hasDefaultEdges:S,onNodesDelete:C,onEdgesDelete:N,onNodesChange:M,onEdgesChange:j}=t.getState(),I=(g||[]).map(F=>F.id),A=(_||[]).map(F=>F.id),q=w().reduce((F,U)=>{const ne=!I.includes(U.id)&&U.parentNode&&F.find(K=>K.id===U.parentNode);return(typeof U.deletable=="boolean"?U.deletable:!0)&&(I.includes(U.id)||ne)&&F.push(U),F},[]),R=E.filter(F=>typeof F.deletable=="boolean"?F.deletable:!0),k=R.filter(F=>A.includes(F.id));if(q||k){const F=lw(q,R),U=[...k,...F],ne=U.reduce((ue,K)=>(ue.includes(K.id)||ue.push(K.id),ue),[]);if((S||m)&&(S&&t.setState({edges:E.filter(ue=>!ne.includes(ue.id))}),m&&(q.forEach(ue=>{y.delete(ue.id)}),t.setState({nodeInternals:new Map(y)}))),ne.length>0&&(N?.(U),j&&j(ne.map(ue=>({id:ue,type:"remove"})))),q.length>0&&(C?.(q),M)){const ue=q.map(K=>({id:K.id,type:"remove"}));M(ue)}}},[]),d=se.useCallback(g=>{const _=VP(g),y=_?null:t.getState().nodeInternals.get(g.id);return[_?g:Y_(y),y,_]},[]),p=se.useCallback((g,_=!0,y)=>{const[w,E,m]=d(g);return w?(y||t.getState().getNodes()).filter(S=>{if(!m&&(S.id===E.id||!S.positionAbsolute))return!1;const C=Y_(S),N=dh(C,w);return _&&N>0||N>=g.width*g.height}):[]},[]),O=se.useCallback((g,_,y=!0)=>{const[w]=d(g);if(!w)return!1;const E=dh(w,_);return y&&E>0||E>=g.width*g.height},[]);return se.useMemo(()=>({...e,getNodes:n,getNode:r,getEdges:o,getEdge:s,setNodes:l,setEdges:c,addNodes:f,addEdges:h,toObject:a,deleteElements:u,getIntersectingNodes:p,isNodeIntersecting:O}),[e,n,r,o,s,l,c,f,h,a,u,p,O])}var NI=({deleteKeyCode:e,multiSelectionKeyCode:t})=>{const n=_t(),{deleteElements:r}=Ji(),o=ko(e),s=ko(t);se.useEffect(()=>{if(o){const{edges:l,getNodes:c}=n.getState(),f=c().filter(a=>a.selected),h=l.filter(a=>a.selected);r({nodes:f,edges:h}),n.setState({nodesSelectionActive:!1})}},[o]),se.useEffect(()=>{n.setState({multiSelectionActive:s})},[s])};function TI(e){const t=_t();se.useEffect(()=>{let n;const r=()=>{if(!e.current)return;const o=ch(e.current);(o.height===0||o.width===0)&&t.getState().onError?.("004",Cn.error004()),t.setState({width:o.width||500,height:o.height||500})};return r(),window.addEventListener("resize",r),e.current&&(n=new ResizeObserver(()=>r()),n.observe(e.current)),()=>{window.removeEventListener("resize",r),n&&e.current&&n.unobserve(e.current)}},[])}const Sh={position:"absolute",width:"100%",height:"100%",top:0,left:0},CI=(e,t)=>e.x!==t.x||e.y!==t.y||e.zoom!==t.k,ea=e=>({x:e.x,y:e.y,zoom:e.k}),Tr=(e,t)=>e.target.closest(`.${t}`),Aw=(e,t)=>t===2&&Array.isArray(e)&&e.includes(2),Pw=e=>{const t=e.ctrlKey&&Ui()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*t},AI=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection,d3ZoomHandler:e.d3ZoomHandler,userSelectionActive:e.userSelectionActive}),PI=({onMove:e,onMoveStart:t,onMoveEnd:n,onPaneContextMenu:r,zoomOnScroll:o=!0,zoomOnPinch:s=!0,panOnScroll:l=!1,panOnScrollSpeed:c=.5,panOnScrollMode:f=nr.Free,zoomOnDoubleClick:h=!0,elementsSelectable:a,panOnDrag:u=!0,defaultViewport:d,translateExtent:p,minZoom:O,maxZoom:g,zoomActivationKeyCode:_,preventScrolling:y=!0,children:w,noWheelClassName:E,noPanClassName:m})=>{const S=se.useRef(),C=_t(),N=se.useRef(!1),M=se.useRef(!1),j=se.useRef(null),I=se.useRef({x:0,y:0,zoom:0}),{d3Zoom:A,d3Selection:q,d3ZoomHandler:R,userSelectionActive:k}=st(AI,St),F=ko(_),U=se.useRef(0),ne=se.useRef(!1),ue=se.useRef();return TI(j),se.useEffect(()=>{if(j.current){const K=j.current.getBoundingClientRect(),W=$_().scaleExtent([O,g]).translateExtent(p),z=Zt(j.current).call(W),Q=Tn.translate(d.x,d.y).scale(Sr(d.zoom,O,g)),re=[[0,0],[K.width,K.height]],Z=W.constrain()(Q,re,p);W.transform(z,Z),W.wheelDelta(Pw),C.setState({d3Zoom:W,d3Selection:z,d3ZoomHandler:z.on("wheel.zoom"),transform:[Z.x,Z.y,Z.k],domNode:j.current.closest(".react-flow")})}},[]),se.useEffect(()=>{q&&A&&(l&&!F&&!k?q.on("wheel.zoom",K=>{if(Tr(K,E))return!1;K.preventDefault(),K.stopImmediatePropagation();const W=q.property("__zoom").k||1,z=Ui();if(K.ctrlKey&&s&&z){const de=an(K),pe=Pw(K),Ee=W*Math.pow(2,pe);A.scaleTo(q,Ee,de,K);return}const Q=K.deltaMode===1?20:1;let re=f===nr.Vertical?0:K.deltaX*Q,Z=f===nr.Horizontal?0:K.deltaY*Q;!z&&K.shiftKey&&f!==nr.Vertical&&(re=K.deltaY*Q,Z=0),A.translateBy(q,-(re/W)*c,-(Z/W)*c,{internal:!0});const X=ea(q.property("__zoom")),{onViewportChangeStart:H,onViewportChange:ee,onViewportChangeEnd:le}=C.getState();clearTimeout(ue.current),ne.current||(ne.current=!0,t?.(K,X),H?.(X)),ne.current&&(e?.(K,X),ee?.(X),ue.current=setTimeout(()=>{n?.(K,X),le?.(X),ne.current=!1},150))},{passive:!1}):typeof R<"u"&&q.on("wheel.zoom",function(K,W){if(!y||Tr(K,E))return null;K.preventDefault(),R.call(this,K,W)},{passive:!1}))},[k,l,f,q,A,R,F,s,y,E,t,e,n]),se.useEffect(()=>{A&&A.on("start",K=>{if(!K.sourceEvent||K.sourceEvent.internal)return null;U.current=K.sourceEvent?.button;const{onViewportChangeStart:W}=C.getState(),z=ea(K.transform);N.current=!0,I.current=z,K.sourceEvent?.type==="mousedown"&&C.setState({paneDragging:!0}),W?.(z),t?.(K.sourceEvent,z)})},[A,t]),se.useEffect(()=>{A&&(k&&!N.current?A.on("zoom",null):k||A.on("zoom",K=>{const{onViewportChange:W}=C.getState();if(C.setState({transform:[K.transform.x,K.transform.y,K.transform.k]}),M.current=!!(r&&Aw(u,U.current??0)),(e||W)&&!K.sourceEvent?.internal){const z=ea(K.transform);W?.(z),e?.(K.sourceEvent,z)}}))},[k,A,e,u,r]),se.useEffect(()=>{A&&A.on("end",K=>{if(!K.sourceEvent||K.sourceEvent.internal)return null;const{onViewportChangeEnd:W}=C.getState();if(N.current=!1,C.setState({paneDragging:!1}),r&&Aw(u,U.current??0)&&!M.current&&r(K.sourceEvent),M.current=!1,(n||W)&&CI(I.current,K.transform)){const z=ea(K.transform);I.current=z,clearTimeout(S.current),S.current=setTimeout(()=>{W?.(z),n?.(K.sourceEvent,z)},l?150:0)}})},[A,l,u,n,r]),se.useEffect(()=>{A&&A.filter(K=>{const W=F||o,z=s&&K.ctrlKey;if(K.button===1&&K.type==="mousedown"&&(Tr(K,"react-flow__node")||Tr(K,"react-flow__edge")))return!0;if(!u&&!W&&!l&&!h&&!s||k||!h&&K.type==="dblclick"||Tr(K,E)&&K.type==="wheel"||Tr(K,m)&&K.type!=="wheel"||!s&&K.ctrlKey&&K.type==="wheel"||!W&&!l&&!z&&K.type==="wheel"||!u&&(K.type==="mousedown"||K.type==="touchstart")||Array.isArray(u)&&!u.includes(K.button)&&(K.type==="mousedown"||K.type==="touchstart"))return!1;const Q=Array.isArray(u)&&u.includes(K.button)||!K.button||K.button<=1;return(!K.ctrlKey||K.type==="wheel")&&Q})},[k,A,o,s,l,h,u,a,F]),$.jsx("div",{className:"react-flow__renderer",ref:j,style:Sh,children:w})},II=e=>({userSelectionActive:e.userSelectionActive,userSelectionRect:e.userSelectionRect});function MI(){const{userSelectionActive:e,userSelectionRect:t}=st(II,St);return e&&t?$.jsx("div",{className:"react-flow__selection react-flow__container",style:{width:t.width,height:t.height,transform:`translate(${t.x}px, ${t.y}px)`}}):null}function Iw(e,t){const n=e.find(r=>r.id===t.parentNode);if(n){const r=t.position.x+t.width-n.width,o=t.position.y+t.height-n.height;if(r>0||o>0||t.position.x<0||t.position.y<0){if(n.style={...n.style},n.style.width=n.style.width??n.width,n.style.height=n.style.height??n.height,r>0&&(n.style.width+=r),o>0&&(n.style.height+=o),t.position.x<0){const s=Math.abs(t.position.x);n.position.x=n.position.x-s,n.style.width+=s,t.position.x=0}if(t.position.y<0){const s=Math.abs(t.position.y);n.position.y=n.position.y-s,n.style.height+=s,t.position.y=0}n.width=n.style.width,n.height=n.style.height}}}function Mw(e,t){if(e.some(r=>r.type==="reset"))return e.filter(r=>r.type==="reset").map(r=>r.item);const n=e.filter(r=>r.type==="add").map(r=>r.item);return t.reduce((r,o)=>{const s=e.filter(c=>c.id===o.id);if(s.length===0)return r.push(o),r;const l={...o};for(const c of s)if(c)switch(c.type){case"select":{l.selected=c.selected;break}case"position":{typeof c.position<"u"&&(l.position=c.position),typeof c.positionAbsolute<"u"&&(l.positionAbsolute=c.positionAbsolute),typeof c.dragging<"u"&&(l.dragging=c.dragging),l.expandParent&&Iw(r,l);break}case"dimensions":{typeof c.dimensions<"u"&&(l.width=c.dimensions.width,l.height=c.dimensions.height),typeof c.updateStyle<"u"&&(l.style={...l.style||{},...c.dimensions}),typeof c.resizing=="boolean"&&(l.resizing=c.resizing),l.expandParent&&Iw(r,l);break}case"remove":return r}return r.push(l),r},n)}function qw(e,t){return Mw(e,t)}function qI(e,t){return Mw(e,t)}const jn=(e,t)=>({id:e,type:"select",selected:t});function Cr(e,t){return e.reduce((n,r)=>{const o=t.includes(r.id);return!r.selected&&o?(r.selected=!0,n.push(jn(r.id,!0))):r.selected&&!o&&(r.selected=!1,n.push(jn(r.id,!1))),n},[])}const kh=(e,t)=>n=>{n.target===t.current&&e?.(n)},LI=e=>({userSelectionActive:e.userSelectionActive,elementsSelectable:e.elementsSelectable,dragging:e.paneDragging}),Lw=se.memo(({isSelecting:e,selectionMode:t=So.Full,panOnDrag:n,onSelectionStart:r,onSelectionEnd:o,onPaneClick:s,onPaneContextMenu:l,onPaneScroll:c,onPaneMouseEnter:f,onPaneMouseMove:h,onPaneMouseLeave:a,children:u})=>{const d=se.useRef(null),p=_t(),O=se.useRef(0),g=se.useRef(0),_=se.useRef(),{userSelectionActive:y,elementsSelectable:w,dragging:E}=st(LI,St),m=()=>{p.setState({userSelectionActive:!1,userSelectionRect:null}),O.current=0,g.current=0},S=R=>{s?.(R),p.getState().resetSelectedElements(),p.setState({nodesSelectionActive:!1})},C=R=>{if(Array.isArray(n)&&n?.includes(2)){R.preventDefault();return}l?.(R)},N=c?R=>c(R):void 0,M=R=>{const{resetSelectedElements:k,domNode:F}=p.getState();if(_.current=F?.getBoundingClientRect(),!w||!e||R.button!==0||R.target!==d.current||!_.current)return;const{x:U,y:ne}=Dn(R,_.current);k(),p.setState({userSelectionRect:{width:0,height:0,startX:U,startY:ne,x:U,y:ne}}),r?.(R)},j=R=>{const{userSelectionRect:k,nodeInternals:F,edges:U,transform:ne,onNodesChange:ue,onEdgesChange:K,nodeOrigin:W,getNodes:z}=p.getState();if(!e||!_.current||!k)return;p.setState({userSelectionActive:!0,nodesSelectionActive:!1});const Q=Dn(R,_.current),re=k.startX??0,Z=k.startY??0,X={...k,x:Q.x<re?Q.x:re,y:Q.y<Z?Q.y:Z,width:Math.abs(Q.x-re),height:Math.abs(Q.y-Z)},H=z(),ee=sw(F,X,ne,t===So.Partial,!0,W),le=lw(ee,U).map(pe=>pe.id),de=ee.map(pe=>pe.id);if(O.current!==de.length){O.current=de.length;const pe=Cr(H,de);pe.length&&ue?.(pe)}if(g.current!==le.length){g.current=le.length;const pe=Cr(U,le);pe.length&&K?.(pe)}p.setState({userSelectionRect:X})},I=R=>{if(R.button!==0)return;const{userSelectionRect:k}=p.getState();!y&&k&&R.target===d.current&&S?.(R),p.setState({nodesSelectionActive:O.current>0}),m(),o?.(R)},A=R=>{y&&(p.setState({nodesSelectionActive:O.current>0}),o?.(R)),m()},q=w&&(e||y);return $.jsxs("div",{className:Tt(["react-flow__pane",{dragging:E,selection:e}]),onClick:q?void 0:kh(S,d),onContextMenu:kh(C,d),onWheel:kh(N,d),onMouseEnter:q?void 0:f,onMouseDown:q?M:void 0,onMouseMove:q?j:h,onMouseUp:q?I:void 0,onMouseLeave:q?A:a,ref:d,style:Sh,children:[u,$.jsx(MI,{})]})});Lw.displayName="Pane";function Rw(e,t){if(!e.parentNode)return!1;const n=t.get(e.parentNode);return n?n.selected?!0:Rw(n,t):!1}function Dw(e,t,n){let r=e;do{if(r?.matches(t))return!0;if(r===n.current)return!1;r=r.parentElement}while(r);return!1}function RI(e,t,n,r){return Array.from(e.values()).filter(o=>(o.selected||o.id===r)&&(!o.parentNode||!Rw(o,e))&&(o.draggable||t&&typeof o.draggable>"u")).map(o=>({id:o.id,position:o.position||{x:0,y:0},positionAbsolute:o.positionAbsolute||{x:0,y:0},distance:{x:n.x-(o.positionAbsolute?.x??0),y:n.y-(o.positionAbsolute?.y??0)},delta:{x:0,y:0},extent:o.extent,parentNode:o.parentNode,width:o.width,height:o.height}))}function DI(e,t){return!t||t==="parent"?t:[t[0],[t[1][0]-(e.width||0),t[1][1]-(e.height||0)]]}function jw(e,t,n,r,o=[0,0],s){const l=DI(e,e.extent||r);let c=l;if(e.extent==="parent")if(e.parentNode&&e.width&&e.height){const a=n.get(e.parentNode),{x:u,y:d}=rr(a,o).positionAbsolute;c=a&&Xt(u)&&Xt(d)&&Xt(a.width)&&Xt(a.height)?[[u+e.width*o[0],d+e.height*o[1]],[u+a.width-e.width+e.width*o[0],d+a.height-e.height+e.height*o[1]]]:c}else s?.("005",Cn.error005()),c=l;else if(e.extent&&e.parentNode){const a=n.get(e.parentNode),{x:u,y:d}=rr(a,o).positionAbsolute;c=[[e.extent[0][0]+u,e.extent[0][1]+d],[e.extent[1][0]+u,e.extent[1][1]+d]]}let f={x:0,y:0};if(e.parentNode){const a=n.get(e.parentNode);f=rr(a,o).positionAbsolute}const h=c&&c!=="parent"?fh(t,c):t;return{position:{x:h.x-f.x,y:h.y-f.y},positionAbsolute:h}}function Nh({nodeId:e,dragItems:t,nodeInternals:n}){const r=t.map(o=>({...n.get(o.id),position:o.position,positionAbsolute:o.positionAbsolute}));return[e?r.find(o=>o.id===e):r[0],r]}const Fw=(e,t,n,r)=>{const o=t.querySelectorAll(e);if(!o||!o.length)return null;const s=Array.from(o),l=t.getBoundingClientRect(),c={x:l.width*r[0],y:l.height*r[1]};return s.map(f=>{const h=f.getBoundingClientRect();return{id:f.getAttribute("data-handleid"),position:f.getAttribute("data-handlepos"),x:(h.left-l.left-c.x)/n,y:(h.top-l.top-c.y)/n,...ch(f)}})};function No(e,t,n){return n===void 0?n:r=>{const o=t().nodeInternals.get(e);o&&n(r,{...o})}}function Th({id:e,store:t,unselect:n=!1,nodeRef:r}){const{addSelectedNodes:o,unselectNodesAndEdges:s,multiSelectionActive:l,nodeInternals:c,onError:f}=t.getState(),h=c.get(e);if(!h){f?.("012",Cn.error012(e));return}t.setState({nodesSelectionActive:!1}),h.selected?(n||h.selected&&l)&&(s({nodes:[h]}),requestAnimationFrame(()=>r?.current?.blur())):o([e])}function jI(){const e=_t();return se.useCallback(({sourceEvent:n})=>{const{transform:r,snapGrid:o,snapToGrid:s}=e.getState(),l=n.touches?n.touches[0].clientX:n.clientX,c=n.touches?n.touches[0].clientY:n.clientY,f={x:(l-r[0])/r[2],y:(c-r[1])/r[2]};return{xSnapped:s?o[0]*Math.round(f.x/o[0]):f.x,ySnapped:s?o[1]*Math.round(f.y/o[1]):f.y,...f}},[])}function Ch(e){return(t,n,r)=>e?.(t,r)}function Bw({nodeRef:e,disabled:t=!1,noDragClassName:n,handleSelector:r,nodeId:o,isSelectable:s,selectNodesOnDrag:l}){const c=_t(),[f,h]=se.useState(!1),a=se.useRef([]),u=se.useRef({x:null,y:null}),d=se.useRef(0),p=se.useRef(null),O=se.useRef({x:0,y:0}),g=se.useRef(null),_=se.useRef(!1),y=jI();return se.useEffect(()=>{if(e?.current){const w=Zt(e.current),E=({x:S,y:C})=>{const{nodeInternals:N,onNodeDrag:M,onSelectionDrag:j,updateNodePositions:I,nodeExtent:A,snapGrid:q,snapToGrid:R,nodeOrigin:k,onError:F}=c.getState();u.current={x:S,y:C};let U=!1,ne={x:0,y:0,x2:0,y2:0};if(a.current.length>1&&A){const K=Zi(a.current,k);ne=Oo(K)}if(a.current=a.current.map(K=>{const W={x:S-K.distance.x,y:C-K.distance.y};R&&(W.x=q[0]*Math.round(W.x/q[0]),W.y=q[1]*Math.round(W.y/q[1]));const z=[[A[0][0],A[0][1]],[A[1][0],A[1][1]]];a.current.length>1&&A&&!K.extent&&(z[0][0]=K.positionAbsolute.x-ne.x+A[0][0],z[1][0]=K.positionAbsolute.x+(K.width??0)-ne.x2+A[1][0],z[0][1]=K.positionAbsolute.y-ne.y+A[0][1],z[1][1]=K.positionAbsolute.y+(K.height??0)-ne.y2+A[1][1]);const Q=jw(K,W,N,z,k,F);return U=U||K.position.x!==Q.position.x||K.position.y!==Q.position.y,K.position=Q.position,K.positionAbsolute=Q.positionAbsolute,K}),!U)return;I(a.current,!0,!0),h(!0);const ue=o?M:Ch(j);if(ue&&g.current){const[K,W]=Nh({nodeId:o,dragItems:a.current,nodeInternals:N});ue(g.current,K,W)}},m=()=>{if(!p.current)return;const[S,C]=U_(O.current,p.current);if(S!==0||C!==0){const{transform:N,panBy:M}=c.getState();u.current.x=(u.current.x??0)-S/N[2],u.current.y=(u.current.y??0)-C/N[2],M({x:S,y:C})&&E(u.current)}d.current=requestAnimationFrame(m)};if(t)w.on(".drag",null);else{const S=WC().on("start",C=>{const{nodeInternals:N,multiSelectionActive:M,domNode:j,nodesDraggable:I,unselectNodesAndEdges:A,onNodeDragStart:q,onSelectionDragStart:R}=c.getState(),k=o?q:Ch(R);!l&&!M&&o&&(N.get(o)?.selected||A()),o&&s&&l&&Th({id:o,store:c,nodeRef:e});const F=y(C);if(u.current=F,a.current=RI(N,I,F,o),k&&a.current){const[U,ne]=Nh({nodeId:o,dragItems:a.current,nodeInternals:N});k(C.sourceEvent,U,ne)}p.current=j?.getBoundingClientRect()||null,O.current=Dn(C.sourceEvent,p.current)}).on("drag",C=>{const N=y(C),{autoPanOnNodeDrag:M}=c.getState();!_.current&&M&&(_.current=!0,m()),(u.current.x!==N.xSnapped||u.current.y!==N.ySnapped)&&a.current&&(g.current=C.sourceEvent,O.current=Dn(C.sourceEvent,p.current),E(N))}).on("end",C=>{if(h(!1),_.current=!1,cancelAnimationFrame(d.current),a.current){const{updateNodePositions:N,nodeInternals:M,onNodeDragStop:j,onSelectionDragStop:I}=c.getState(),A=o?j:Ch(I);if(N(a.current,!1,!1),A){const[q,R]=Nh({nodeId:o,dragItems:a.current,nodeInternals:M});A(C.sourceEvent,q,R)}}}).filter(C=>{const N=C.target;return!C.button&&(!n||!Dw(N,`.${n}`,e))&&(!r||Dw(N,r,e))});return w.call(S),()=>{w.on(".drag",null)}}}},[e,t,n,r,s,c,o,l,y]),f}function zw(){const e=_t();return se.useCallback(n=>{const{nodeInternals:r,nodeExtent:o,updateNodePositions:s,getNodes:l,snapToGrid:c,snapGrid:f,onError:h,nodesDraggable:a}=e.getState(),u=l().filter(w=>w.selected&&(w.draggable||a&&typeof w.draggable>"u")),d=c?f[0]:5,p=c?f[1]:5,O=n.isShiftPressed?4:1,g=n.x*d*O,_=n.y*p*O,y=u.map(w=>{if(w.positionAbsolute){const E={x:w.positionAbsolute.x+g,y:w.positionAbsolute.y+_};c&&(E.x=f[0]*Math.round(E.x/f[0]),E.y=f[1]*Math.round(E.y/f[1]));const{positionAbsolute:m,position:S}=jw(w,E,r,o,void 0,h);w.position=S,w.positionAbsolute=m}return w});s(y,!0,!1)},[])}const Ar={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}};var To=e=>{const t=({id:n,type:r,data:o,xPos:s,yPos:l,xPosOrigin:c,yPosOrigin:f,selected:h,onClick:a,onMouseEnter:u,onMouseMove:d,onMouseLeave:p,onContextMenu:O,onDoubleClick:g,style:_,className:y,isDraggable:w,isSelectable:E,isConnectable:m,isFocusable:S,selectNodesOnDrag:C,sourcePosition:N,targetPosition:M,hidden:j,resizeObserver:I,dragHandle:A,zIndex:q,isParent:R,noDragClassName:k,noPanClassName:F,initialized:U,disableKeyboardA11y:ne,ariaLabel:ue,rfId:K})=>{const W=_t(),z=se.useRef(null),Q=se.useRef(N),re=se.useRef(M),Z=se.useRef(r),X=E||w||a||u||d||p,H=zw(),ee=No(n,W.getState,u),le=No(n,W.getState,d),de=No(n,W.getState,p),pe=No(n,W.getState,O),Ee=No(n,W.getState,g),Ie=Se=>{if(E&&(!C||!w)&&Th({id:n,store:W,nodeRef:z}),a){const Ge=W.getState().nodeInternals.get(n);Ge&&a(Se,{...Ge})}},Pe=Se=>{if(!hh(Se))if(Z_.includes(Se.key)&&E){const Ge=Se.key==="Escape";Th({id:n,store:W,unselect:Ge,nodeRef:z})}else!ne&&w&&h&&Object.prototype.hasOwnProperty.call(Ar,Se.key)&&(W.setState({ariaLiveMessage:`Moved selected node ${Se.key.replace("Arrow","").toLowerCase()}. New position, x: ${~~s}, y: ${~~l}`}),H({x:Ar[Se.key].x,y:Ar[Se.key].y,isShiftPressed:Se.shiftKey}))};se.useEffect(()=>{if(z.current&&!j){const Se=z.current;return I?.observe(Se),()=>I?.unobserve(Se)}},[j]),se.useEffect(()=>{const Se=Z.current!==r,Ge=Q.current!==N,Oe=re.current!==M;z.current&&(Se||Ge||Oe)&&(Se&&(Z.current=r),Ge&&(Q.current=N),Oe&&(re.current=M),W.getState().updateNodeDimensions([{id:n,nodeElement:z.current,forceUpdate:!0}]))},[n,r,N,M]);const Ae=Bw({nodeRef:z,disabled:j||!w,noDragClassName:k,handleSelector:A,nodeId:n,isSelectable:E,selectNodesOnDrag:C});return j?null:$.jsx("div",{className:Tt(["react-flow__node",`react-flow__node-${r}`,{[F]:w},y,{selected:h,selectable:E,parent:R,dragging:Ae}]),ref:z,style:{zIndex:q,transform:`translate(${c}px,${f}px)`,pointerEvents:X?"all":"none",visibility:U?"visible":"hidden",..._},"data-id":n,"data-testid":`rf__node-${n}`,onMouseEnter:ee,onMouseMove:le,onMouseLeave:de,onContextMenu:pe,onClick:Ie,onDoubleClick:Ee,onKeyDown:S?Pe:void 0,tabIndex:S?0:void 0,role:S?"button":void 0,"aria-describedby":ne?void 0:`${Ew}-${K}`,"aria-label":ue,children:$.jsx(XP,{value:n,children:$.jsx(e,{id:n,data:o,type:r,xPos:s,yPos:l,selected:h,isConnectable:m,sourcePosition:N,targetPosition:M,dragging:Ae,dragHandle:A,zIndex:q})})})};return t.displayName="NodeWrapper",se.memo(t)};const FI=e=>{const t=e.getNodes().filter(n=>n.selected);return{...Zi(t,e.nodeOrigin),transformString:`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`,userSelectionActive:e.userSelectionActive}};function BI({onSelectionContextMenu:e,noPanClassName:t,disableKeyboardA11y:n}){const r=_t(),{width:o,height:s,x:l,y:c,transformString:f,userSelectionActive:h}=st(FI,St),a=zw(),u=se.useRef(null);if(se.useEffect(()=>{n||u.current?.focus({preventScroll:!0})},[n]),Bw({nodeRef:u}),h||!o||!s)return null;const d=e?O=>{const g=r.getState().getNodes().filter(_=>_.selected);e(O,g)}:void 0,p=O=>{Object.prototype.hasOwnProperty.call(Ar,O.key)&&a({x:Ar[O.key].x,y:Ar[O.key].y,isShiftPressed:O.shiftKey})};return $.jsx("div",{className:Tt(["react-flow__nodesselection","react-flow__container",t]),style:{transform:f},children:$.jsx("div",{ref:u,className:"react-flow__nodesselection-rect",onContextMenu:d,tabIndex:n?void 0:-1,onKeyDown:n?void 0:p,style:{width:o,height:s,top:c,left:l}})})}var zI=se.memo(BI);const $I=e=>e.nodesSelectionActive,$w=({children:e,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:s,onPaneScroll:l,deleteKeyCode:c,onMove:f,onMoveStart:h,onMoveEnd:a,selectionKeyCode:u,selectionOnDrag:d,selectionMode:p,onSelectionStart:O,onSelectionEnd:g,multiSelectionKeyCode:_,panActivationKeyCode:y,zoomActivationKeyCode:w,elementsSelectable:E,zoomOnScroll:m,zoomOnPinch:S,panOnScroll:C,panOnScrollSpeed:N,panOnScrollMode:M,zoomOnDoubleClick:j,panOnDrag:I,defaultViewport:A,translateExtent:q,minZoom:R,maxZoom:k,preventScrolling:F,onSelectionContextMenu:U,noWheelClassName:ne,noPanClassName:ue,disableKeyboardA11y:K})=>{const W=st($I),z=ko(u),re=ko(y)||I,Z=z||d&&re!==!0;return NI({deleteKeyCode:c,multiSelectionKeyCode:_}),$.jsx(PI,{onMove:f,onMoveStart:h,onMoveEnd:a,onPaneContextMenu:s,elementsSelectable:E,zoomOnScroll:m,zoomOnPinch:S,panOnScroll:C,panOnScrollSpeed:N,panOnScrollMode:M,zoomOnDoubleClick:j,panOnDrag:!z&&re,defaultViewport:A,translateExtent:q,minZoom:R,maxZoom:k,zoomActivationKeyCode:w,preventScrolling:F,noWheelClassName:ne,noPanClassName:ue,children:$.jsxs(Lw,{onSelectionStart:O,onSelectionEnd:g,onPaneClick:t,onPaneMouseEnter:n,onPaneMouseMove:r,onPaneMouseLeave:o,onPaneContextMenu:s,onPaneScroll:l,panOnDrag:re,isSelecting:!!Z,selectionMode:p,children:[e,W&&$.jsx(zI,{onSelectionContextMenu:U,noPanClassName:ue,disableKeyboardA11y:K})]})})};$w.displayName="FlowRenderer";var HI=se.memo($w);function VI(e){return st(se.useCallback(n=>e?sw(n.nodeInternals,{x:0,y:0,width:n.width,height:n.height},n.transform,!0):n.getNodes(),[e]))}function UI(e){const t={input:To(e.input||mw),default:To(e.default||Oh),output:To(e.output||_w),group:To(e.group||Eh)},n={},r=Object.keys(e).filter(o=>!["input","default","output","group"].includes(o)).reduce((o,s)=>(o[s]=To(e[s]||Oh),o),n);return{...t,...r}}const GI=({x:e,y:t,width:n,height:r,origin:o})=>!n||!r?{x:e,y:t}:o[0]<0||o[1]<0||o[0]>1||o[1]>1?{x:e,y:t}:{x:e-n*o[0],y:t-r*o[1]},KI=e=>({nodesDraggable:e.nodesDraggable,nodesConnectable:e.nodesConnectable,nodesFocusable:e.nodesFocusable,elementsSelectable:e.elementsSelectable,updateNodeDimensions:e.updateNodeDimensions,onError:e.onError}),Hw=e=>{const{nodesDraggable:t,nodesConnectable:n,nodesFocusable:r,elementsSelectable:o,updateNodeDimensions:s,onError:l}=st(KI,St),c=VI(e.onlyRenderVisibleElements),f=se.useRef(),h=se.useMemo(()=>{if(typeof ResizeObserver>"u")return null;const a=new ResizeObserver(u=>{const d=u.map(p=>({id:p.target.getAttribute("data-id"),nodeElement:p.target,forceUpdate:!0}));s(d)});return f.current=a,a},[]);return se.useEffect(()=>()=>{f?.current?.disconnect()},[]),$.jsx("div",{className:"react-flow__nodes",style:Sh,children:c.map(a=>{let u=a.type||"default";e.nodeTypes[u]||(l?.("003",Cn.error003(u)),u="default");const d=e.nodeTypes[u]||e.nodeTypes.default,p=!!(a.draggable||t&&typeof a.draggable>"u"),O=!!(a.selectable||o&&typeof a.selectable>"u"),g=!!(a.connectable||n&&typeof a.connectable>"u"),_=!!(a.focusable||r&&typeof a.focusable>"u"),y=e.nodeExtent?fh(a.positionAbsolute,e.nodeExtent):a.positionAbsolute,w=y?.x??0,E=y?.y??0,m=GI({x:w,y:E,width:a.width??0,height:a.height??0,origin:e.nodeOrigin});return $.jsx(d,{id:a.id,className:a.className,style:a.style,type:u,data:a.data,sourcePosition:a.sourcePosition||Ce.Bottom,targetPosition:a.targetPosition||Ce.Top,hidden:a.hidden,xPos:w,yPos:E,xPosOrigin:m.x,yPosOrigin:m.y,selectNodesOnDrag:e.selectNodesOnDrag,onClick:e.onNodeClick,onMouseEnter:e.onNodeMouseEnter,onMouseMove:e.onNodeMouseMove,onMouseLeave:e.onNodeMouseLeave,onContextMenu:e.onNodeContextMenu,onDoubleClick:e.onNodeDoubleClick,selected:!!a.selected,isDraggable:p,isSelectable:O,isConnectable:g,isFocusable:_,resizeObserver:h,dragHandle:a.dragHandle,zIndex:a[wt]?.z??0,isParent:!!a[wt]?.isParent,noDragClassName:e.noDragClassName,noPanClassName:e.noPanClassName,initialized:!!a.width&&!!a.height,rfId:e.rfId,disableKeyboardA11y:e.disableKeyboardA11y,ariaLabel:a.ariaLabel},a.id)})})};Hw.displayName="NodeRenderer";var WI=se.memo(Hw);const YI=(e,t,n)=>n===Ce.Left?e-t:n===Ce.Right?e+t:e,ZI=(e,t,n)=>n===Ce.Top?e-t:n===Ce.Bottom?e+t:e,Vw="react-flow__edgeupdater",Uw=({position:e,centerX:t,centerY:n,radius:r=10,onMouseDown:o,onMouseEnter:s,onMouseOut:l,type:c})=>$.jsx("circle",{onMouseDown:o,onMouseEnter:s,onMouseOut:l,className:Tt([Vw,`${Vw}-${c}`]),cx:YI(t,r,e),cy:ZI(n,r,e),r,stroke:"transparent",fill:"transparent"}),XI=()=>!0;var Pr=e=>{const t=({id:n,className:r,type:o,data:s,onClick:l,onEdgeDoubleClick:c,selected:f,animated:h,label:a,labelStyle:u,labelShowBg:d,labelBgStyle:p,labelBgPadding:O,labelBgBorderRadius:g,style:_,source:y,target:w,sourceX:E,sourceY:m,targetX:S,targetY:C,sourcePosition:N,targetPosition:M,elementsSelectable:j,hidden:I,sourceHandleId:A,targetHandleId:q,onContextMenu:R,onMouseEnter:k,onMouseMove:F,onMouseLeave:U,edgeUpdaterRadius:ne,onEdgeUpdate:ue,onEdgeUpdateStart:K,onEdgeUpdateEnd:W,markerEnd:z,markerStart:Q,rfId:re,ariaLabel:Z,isFocusable:X,isUpdatable:H,pathOptions:ee,interactionWidth:le})=>{const de=se.useRef(null),[pe,Ee]=se.useState(!1),[Ie,Pe]=se.useState(!1),Ae=_t(),Se=se.useMemo(()=>`url(#${bh(Q,re)})`,[Q,re]),Ge=se.useMemo(()=>`url(#${bh(z,re)})`,[z,re]);if(I)return null;const Oe=We=>{const{edges:it,addSelectedEdges:Ot}=Ae.getState();if(j&&(Ae.setState({nodesSelectionActive:!1}),Ot([n])),l){const kt=it.find(Nt=>Nt.id===n);l(We,kt)}},ge=xo(n,Ae.getState,c),me=xo(n,Ae.getState,R),ke=xo(n,Ae.getState,k),Ne=xo(n,Ae.getState,F),we=xo(n,Ae.getState,U),qe=(We,it)=>{if(We.button!==0)return;const{edges:Ot,isValidConnection:kt}=Ae.getState(),Nt=it?w:y,Ft=(it?q:A)||null,gn=it?"target":"source",qo=kt||XI,Lo=it,yn=Ot.find(Pn=>Pn.id===n);Pe(!0),K?.(We,yn,gn);const Ro=Pn=>{Pe(!1),W?.(Pn,yn,gn)};hw({event:We,handleId:Ft,nodeId:Nt,onConnect:Pn=>ue?.(yn,Pn),isTarget:Lo,getState:Ae.getState,setState:Ae.setState,isValidConnection:qo,edgeUpdaterType:gn,onEdgeUpdateEnd:Ro})},je=We=>qe(We,!0),ze=We=>qe(We,!1),lt=()=>Ee(!0),pt=()=>Ee(!1),Ze=!j&&!l,It=We=>{if(Z_.includes(We.key)&&j){const{unselectNodesAndEdges:it,addSelectedEdges:Ot,edges:kt}=Ae.getState();We.key==="Escape"?(de.current?.blur(),it({edges:[kt.find(Ft=>Ft.id===n)]})):Ot([n])}};return $.jsxs("g",{className:Tt(["react-flow__edge",`react-flow__edge-${o}`,r,{selected:f,animated:h,inactive:Ze,updating:pe}]),onClick:Oe,onDoubleClick:ge,onContextMenu:me,onMouseEnter:ke,onMouseMove:Ne,onMouseLeave:we,onKeyDown:X?It:void 0,tabIndex:X?0:void 0,role:X?"button":"img","data-testid":`rf__edge-${n}`,"aria-label":Z===null?void 0:Z||`Edge from ${y} to ${w}`,"aria-describedby":X?`${xw}-${re}`:void 0,ref:de,children:[!Ie&&$.jsx(e,{id:n,source:y,target:w,selected:f,animated:h,label:a,labelStyle:u,labelShowBg:d,labelBgStyle:p,labelBgPadding:O,labelBgBorderRadius:g,data:s,style:_,sourceX:E,sourceY:m,targetX:S,targetY:C,sourcePosition:N,targetPosition:M,sourceHandleId:A,targetHandleId:q,markerStart:Se,markerEnd:Ge,pathOptions:ee,interactionWidth:le}),H&&$.jsxs($.Fragment,{children:[(H==="source"||H===!0)&&$.jsx(Uw,{position:N,centerX:E,centerY:m,radius:ne,onMouseDown:je,onMouseEnter:lt,onMouseOut:pt,type:"source"}),(H==="target"||H===!0)&&$.jsx(Uw,{position:M,centerX:S,centerY:C,radius:ne,onMouseDown:ze,onMouseEnter:lt,onMouseOut:pt,type:"target"})]})]})};return t.displayName="EdgeWrapper",se.memo(t)};function QI(e){const t={default:Pr(e.default||Yi),straight:Pr(e.bezier||yh),step:Pr(e.step||gh),smoothstep:Pr(e.step||Ki),simplebezier:Pr(e.simplebezier||ph)},n={},r=Object.keys(e).filter(o=>!["default","bezier"].includes(o)).reduce((o,s)=>(o[s]=Pr(e[s]||Yi),o),n);return{...t,...r}}function Gw(e,t,n=null){const r=(n?.x||0)+t.x,o=(n?.y||0)+t.y,s=n?.width||t.width,l=n?.height||t.height;switch(e){case Ce.Top:return{x:r+s/2,y:o};case Ce.Right:return{x:r+s,y:o+l/2};case Ce.Bottom:return{x:r+s/2,y:o+l};case Ce.Left:return{x:r,y:o+l/2}}}function Kw(e,t){return e?e.length===1||!t?e[0]:t&&e.find(n=>n.id===t)||null:null}const JI=(e,t,n,r,o,s)=>{const l=Gw(n,e,t),c=Gw(s,r,o);return{sourceX:l.x,sourceY:l.y,targetX:c.x,targetY:c.y}};function eM({sourcePos:e,targetPos:t,sourceWidth:n,sourceHeight:r,targetWidth:o,targetHeight:s,width:l,height:c,transform:f}){const h={x:Math.min(e.x,t.x),y:Math.min(e.y,t.y),x2:Math.max(e.x+n,t.x+o),y2:Math.max(e.y+r,t.y+s)};h.x===h.x2&&(h.x2+=1),h.y===h.y2&&(h.y2+=1);const a=Oo({x:(0-f[0])/f[2],y:(0-f[1])/f[2],width:l/f[2],height:c/f[2]}),u=Math.max(0,Math.min(a.x2,h.x2)-Math.max(a.x,h.x)),d=Math.max(0,Math.min(a.y2,h.y2)-Math.max(a.y,h.y));return Math.ceil(u*d)>0}function Ww(e){const t=e?.[wt]?.handleBounds||null,n=t&&e?.width&&e?.height&&typeof e?.positionAbsolute?.x<"u"&&typeof e?.positionAbsolute?.y<"u";return[{x:e?.positionAbsolute?.x||0,y:e?.positionAbsolute?.y||0,width:e?.width||0,height:e?.height||0},t,!!n]}const tM=[{level:0,isMaxLevel:!0,edges:[]}];function nM(e,t,n=!1){let r=-1;const o=e.reduce((l,c)=>{const f=Xt(c.zIndex);let h=f?c.zIndex:0;if(n){const a=t.get(c.target),u=t.get(c.source),d=c.selected||a?.selected||u?.selected,p=Math.max(u?.[wt]?.z||0,a?.[wt]?.z||0,1e3);h=(f?c.zIndex:0)+(d?p:0)}return l[h]?l[h].push(c):l[h]=[c],r=h>r?h:r,l},{}),s=Object.entries(o).map(([l,c])=>{const f=+l;return{edges:c,level:f,isMaxLevel:f===r}});return s.length===0?tM:s}function rM(e,t,n){const r=st(se.useCallback(o=>e?o.edges.filter(s=>{const l=t.get(s.source),c=t.get(s.target);return l?.width&&l?.height&&c?.width&&c?.height&&eM({sourcePos:l.positionAbsolute||{x:0,y:0},targetPos:c.positionAbsolute||{x:0,y:0},sourceWidth:l.width,sourceHeight:l.height,targetWidth:c.width,targetHeight:c.height,width:o.width,height:o.height,transform:o.transform})}):o.edges,[e,t]));return nM(r,t,n)}const oM=({color:e="none",strokeWidth:t=1})=>$.jsx("polyline",{stroke:e,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:t,fill:"none",points:"-5,-4 0,0 -5,4"}),iM=({color:e="none",strokeWidth:t=1})=>$.jsx("polyline",{stroke:e,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:t,fill:e,points:"-5,-4 0,0 -5,4 -5,-4"}),Yw={[Gi.Arrow]:oM,[Gi.ArrowClosed]:iM};function aM(e){const t=_t();return se.useMemo(()=>Object.prototype.hasOwnProperty.call(Yw,e)?Yw[e]:(t.getState().onError?.("009",Cn.error009(e)),null),[e])}const sM=({id:e,type:t,color:n,width:r=12.5,height:o=12.5,markerUnits:s="strokeWidth",strokeWidth:l,orient:c="auto-start-reverse"})=>{const f=aM(t);return f?$.jsx("marker",{className:"react-flow__arrowhead",id:e,markerWidth:`${r}`,markerHeight:`${o}`,viewBox:"-10 -10 20 20",markerUnits:s,orient:c,refX:"0",refY:"0",children:$.jsx(f,{color:n,strokeWidth:l})}):null},lM=({defaultColor:e,rfId:t})=>n=>{const r=[];return n.edges.reduce((o,s)=>([s.markerStart,s.markerEnd].forEach(l=>{if(l&&typeof l=="object"){const c=bh(l,t);r.includes(c)||(o.push({id:c,color:l.color||e,...l}),r.push(c))}}),o),[]).sort((o,s)=>o.id.localeCompare(s.id))},Zw=({defaultColor:e,rfId:t})=>{const n=st(se.useCallback(lM({defaultColor:e,rfId:t}),[e,t]),(r,o)=>!(r.length!==o.length||r.some((s,l)=>s.id!==o[l].id)));return $.jsx("defs",{children:n.map(r=>$.jsx(sM,{id:r.id,type:r.type,color:r.color,width:r.width,height:r.height,markerUnits:r.markerUnits,strokeWidth:r.strokeWidth,orient:r.orient},r.id))})};Zw.displayName="MarkerDefinitions";var uM=se.memo(Zw);const cM=e=>({nodesConnectable:e.nodesConnectable,edgesFocusable:e.edgesFocusable,edgesUpdatable:e.edgesUpdatable,elementsSelectable:e.elementsSelectable,width:e.width,height:e.height,connectionMode:e.connectionMode,nodeInternals:e.nodeInternals,onError:e.onError}),Xw=({defaultMarkerColor:e,onlyRenderVisibleElements:t,elevateEdgesOnSelect:n,rfId:r,edgeTypes:o,noPanClassName:s,onEdgeUpdate:l,onEdgeContextMenu:c,onEdgeMouseEnter:f,onEdgeMouseMove:h,onEdgeMouseLeave:a,onEdgeClick:u,edgeUpdaterRadius:d,onEdgeDoubleClick:p,onEdgeUpdateStart:O,onEdgeUpdateEnd:g,children:_})=>{const{edgesFocusable:y,edgesUpdatable:w,elementsSelectable:E,width:m,height:S,connectionMode:C,nodeInternals:N,onError:M}=st(cM,St),j=rM(t,N,n);return m?$.jsxs($.Fragment,{children:[j.map(({level:I,edges:A,isMaxLevel:q})=>$.jsxs("svg",{style:{zIndex:I},width:m,height:S,className:"react-flow__edges react-flow__container",children:[q&&$.jsx(uM,{defaultColor:e,rfId:r}),$.jsx("g",{children:A.map(R=>{const[k,F,U]=Ww(N.get(R.source)),[ne,ue,K]=Ww(N.get(R.target));if(!U||!K)return null;let W=R.type||"default";o[W]||(M?.("011",Cn.error011(W)),W="default");const z=o[W]||o.default,Q=C===tr.Strict?ue.target:(ue.target??[]).concat(ue.source??[]),re=Kw(F.source,R.sourceHandle),Z=Kw(Q,R.targetHandle),X=re?.position||Ce.Bottom,H=Z?.position||Ce.Top,ee=!!(R.focusable||y&&typeof R.focusable>"u"),le=typeof l<"u"&&(R.updatable||w&&typeof R.updatable>"u");if(!re||!Z)return M?.("008",Cn.error008(re,R)),null;const{sourceX:de,sourceY:pe,targetX:Ee,targetY:Ie}=JI(k,re,X,ne,Z,H);return $.jsx(z,{id:R.id,className:Tt([R.className,s]),type:W,data:R.data,selected:!!R.selected,animated:!!R.animated,hidden:!!R.hidden,label:R.label,labelStyle:R.labelStyle,labelShowBg:R.labelShowBg,labelBgStyle:R.labelBgStyle,labelBgPadding:R.labelBgPadding,labelBgBorderRadius:R.labelBgBorderRadius,style:R.style,source:R.source,target:R.target,sourceHandleId:R.sourceHandle,targetHandleId:R.targetHandle,markerEnd:R.markerEnd,markerStart:R.markerStart,sourceX:de,sourceY:pe,targetX:Ee,targetY:Ie,sourcePosition:X,targetPosition:H,elementsSelectable:E,onEdgeUpdate:l,onContextMenu:c,onMouseEnter:f,onMouseMove:h,onMouseLeave:a,onClick:u,edgeUpdaterRadius:d,onEdgeDoubleClick:p,onEdgeUpdateStart:O,onEdgeUpdateEnd:g,rfId:r,ariaLabel:R.ariaLabel,isFocusable:ee,isUpdatable:le,pathOptions:"pathOptions"in R?R.pathOptions:void 0,interactionWidth:R.interactionWidth},R.id)})})]},I)),_]}):null};Xw.displayName="EdgeRenderer";var fM=se.memo(Xw);const dM=e=>`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`;function hM({children:e}){const t=st(dM);return $.jsx("div",{className:"react-flow__viewport react-flow__container",style:{transform:t},children:e})}function pM(e){const t=Ji(),n=se.useRef(!1);se.useEffect(()=>{!n.current&&t.viewportInitialized&&e&&(setTimeout(()=>e(t),1),n.current=!0)},[e,t.viewportInitialized])}const vM={[Ce.Left]:Ce.Right,[Ce.Right]:Ce.Left,[Ce.Top]:Ce.Bottom,[Ce.Bottom]:Ce.Top},Qw=({nodeId:e,handleType:t,style:n,type:r=vn.Bezier,CustomComponent:o,connectionStatus:s})=>{const{fromNode:l,handleId:c,toX:f,toY:h,connectionMode:a}=st(se.useCallback(C=>({fromNode:C.nodeInternals.get(e),handleId:C.connectionHandleId,toX:(C.connectionPosition.x-C.transform[0])/C.transform[2],toY:(C.connectionPosition.y-C.transform[1])/C.transform[2],connectionMode:C.connectionMode}),[e]),St),u=l?.[wt]?.handleBounds;let d=u?.[t];if(a===tr.Loose&&(d=d||u?.[t==="source"?"target":"source"]),!l||!d)return null;const p=c?d.find(C=>C.id===c):d[0],O=p?p.x+p.width/2:(l.width??0)/2,g=p?p.y+p.height/2:l.height??0,_=(l.positionAbsolute?.x??0)+O,y=(l.positionAbsolute?.y??0)+g,w=p?.position,E=w?vM[w]:null;if(!w||!E)return null;if(o)return $.jsx(o,{connectionLineType:r,connectionLineStyle:n,fromNode:l,fromHandle:p,fromX:_,fromY:y,toX:f,toY:h,fromPosition:w,toPosition:E,connectionStatus:s});let m="";const S={sourceX:_,sourceY:y,sourcePosition:w,targetX:f,targetY:h,targetPosition:E};return r===vn.Bezier?[m]=iw(S):r===vn.Step?[m]=vh({...S,borderRadius:0}):r===vn.SmoothStep?[m]=vh(S):r===vn.SimpleBezier?[m]=tw(S):m=`M${_},${y} ${f},${h}`,$.jsx("path",{d:m,fill:"none",className:"react-flow__connection-path",style:n})};Qw.displayName="ConnectionLine";const gM=e=>({nodeId:e.connectionNodeId,handleType:e.connectionHandleType,nodesConnectable:e.nodesConnectable,connectionStatus:e.connectionStatus,width:e.width,height:e.height});function yM({containerStyle:e,style:t,type:n,component:r}){const{nodeId:o,handleType:s,nodesConnectable:l,width:c,height:f,connectionStatus:h}=st(gM,St);return!(o&&s&&c&&l)?null:$.jsx("svg",{style:e,width:c,height:f,className:"react-flow__edges react-flow__connectionline react-flow__container",children:$.jsx("g",{className:Tt(["react-flow__connection",h]),children:$.jsx(Qw,{nodeId:o,handleType:s,style:t,type:n,CustomComponent:r,connectionStatus:h})})})}function Jw(e,t){return se.useRef(null),_t(),se.useMemo(()=>t(e),[e])}const eO=({nodeTypes:e,edgeTypes:t,onMove:n,onMoveStart:r,onMoveEnd:o,onInit:s,onNodeClick:l,onEdgeClick:c,onNodeDoubleClick:f,onEdgeDoubleClick:h,onNodeMouseEnter:a,onNodeMouseMove:u,onNodeMouseLeave:d,onNodeContextMenu:p,onSelectionContextMenu:O,onSelectionStart:g,onSelectionEnd:_,connectionLineType:y,connectionLineStyle:w,connectionLineComponent:E,connectionLineContainerStyle:m,selectionKeyCode:S,selectionOnDrag:C,selectionMode:N,multiSelectionKeyCode:M,panActivationKeyCode:j,zoomActivationKeyCode:I,deleteKeyCode:A,onlyRenderVisibleElements:q,elementsSelectable:R,selectNodesOnDrag:k,defaultViewport:F,translateExtent:U,minZoom:ne,maxZoom:ue,preventScrolling:K,defaultMarkerColor:W,zoomOnScroll:z,zoomOnPinch:Q,panOnScroll:re,panOnScrollSpeed:Z,panOnScrollMode:X,zoomOnDoubleClick:H,panOnDrag:ee,onPaneClick:le,onPaneMouseEnter:de,onPaneMouseMove:pe,onPaneMouseLeave:Ee,onPaneScroll:Ie,onPaneContextMenu:Pe,onEdgeUpdate:Ae,onEdgeContextMenu:Se,onEdgeMouseEnter:Ge,onEdgeMouseMove:Oe,onEdgeMouseLeave:ge,edgeUpdaterRadius:me,onEdgeUpdateStart:ke,onEdgeUpdateEnd:Ne,noDragClassName:we,noWheelClassName:qe,noPanClassName:je,elevateEdgesOnSelect:ze,disableKeyboardA11y:lt,nodeOrigin:pt,nodeExtent:Ze,rfId:It})=>{const We=Jw(e,UI),it=Jw(t,QI);return pM(s),$.jsx(HI,{onPaneClick:le,onPaneMouseEnter:de,onPaneMouseMove:pe,onPaneMouseLeave:Ee,onPaneContextMenu:Pe,onPaneScroll:Ie,deleteKeyCode:A,selectionKeyCode:S,selectionOnDrag:C,selectionMode:N,onSelectionStart:g,onSelectionEnd:_,multiSelectionKeyCode:M,panActivationKeyCode:j,zoomActivationKeyCode:I,elementsSelectable:R,onMove:n,onMoveStart:r,onMoveEnd:o,zoomOnScroll:z,zoomOnPinch:Q,zoomOnDoubleClick:H,panOnScroll:re,panOnScrollSpeed:Z,panOnScrollMode:X,panOnDrag:ee,defaultViewport:F,translateExtent:U,minZoom:ne,maxZoom:ue,onSelectionContextMenu:O,preventScrolling:K,noDragClassName:we,noWheelClassName:qe,noPanClassName:je,disableKeyboardA11y:lt,children:$.jsxs(hM,{children:[$.jsx(fM,{edgeTypes:it,onEdgeClick:c,onEdgeDoubleClick:h,onEdgeUpdate:Ae,onlyRenderVisibleElements:q,onEdgeContextMenu:Se,onEdgeMouseEnter:Ge,onEdgeMouseMove:Oe,onEdgeMouseLeave:ge,onEdgeUpdateStart:ke,onEdgeUpdateEnd:Ne,edgeUpdaterRadius:me,defaultMarkerColor:W,noPanClassName:je,elevateEdgesOnSelect:!!ze,disableKeyboardA11y:lt,rfId:It,children:$.jsx(yM,{style:w,type:y,component:E,containerStyle:m})}),$.jsx("div",{className:"react-flow__edgelabel-renderer"}),$.jsx(WI,{nodeTypes:We,onNodeClick:l,onNodeDoubleClick:f,onNodeMouseEnter:a,onNodeMouseMove:u,onNodeMouseLeave:d,onNodeContextMenu:p,selectNodesOnDrag:k,onlyRenderVisibleElements:q,noPanClassName:je,noDragClassName:we,disableKeyboardA11y:lt,nodeOrigin:pt,nodeExtent:Ze,rfId:It})]})})};eO.displayName="GraphView";var mM=se.memo(eO);const Ah=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],Fn={rfId:"1",width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:Ah,nodeExtent:Ah,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionStatus:null,connectionMode:tr.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:[0,0],snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesUpdatable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,multiSelectionActive:!1,connectionStartHandle:null,connectionEndHandle:null,connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,connectionRadius:20,onError:UP,isValidConnection:void 0},bM=()=>aT((e,t)=>({...Fn,setNodes:n=>{const{nodeInternals:r,nodeOrigin:o,elevateNodesOnSelect:s}=t();e({nodeInternals:xh(n,r,o,s)})},getNodes:()=>Array.from(t().nodeInternals.values()),setEdges:n=>{const{defaultEdgeOptions:r={}}=t();e({edges:n.map(o=>({...r,...o}))})},setDefaultNodesAndEdges:(n,r)=>{const o=typeof n<"u",s=typeof r<"u",l=o?xh(n,new Map,t().nodeOrigin,t().elevateNodesOnSelect):new Map;e({nodeInternals:l,edges:s?r:[],hasDefaultNodes:o,hasDefaultEdges:s})},updateNodeDimensions:n=>{const{onNodesChange:r,nodeInternals:o,fitViewOnInit:s,fitViewOnInitDone:l,fitViewOnInitOptions:c,domNode:f,nodeOrigin:h}=t(),a=f?.querySelector(".react-flow__viewport");if(!a)return;const u=window.getComputedStyle(a),{m22:d}=new window.DOMMatrixReadOnly(u.transform),p=n.reduce((g,_)=>{const y=o.get(_.id);if(y){const w=ch(_.nodeElement);!!(w.width&&w.height&&(y.width!==w.width||y.height!==w.height||_.forceUpdate))&&(o.set(y.id,{...y,[wt]:{...y[wt],handleBounds:{source:Fw(".source",_.nodeElement,d,h),target:Fw(".target",_.nodeElement,d,h)}},...w}),g.push({id:y.id,type:"dimensions",dimensions:w}))}return g},[]);Tw(o,h);const O=l||s&&!l&&Cw(t,{initial:!0,...c});e({nodeInternals:new Map(o),fitViewOnInitDone:O}),p?.length>0&&r?.(p)},updateNodePositions:(n,r=!0,o=!1)=>{const{triggerNodeChanges:s}=t(),l=n.map(c=>{const f={id:c.id,type:"position",dragging:o};return r&&(f.positionAbsolute=c.positionAbsolute,f.position=c.position),f});s(l)},triggerNodeChanges:n=>{const{onNodesChange:r,nodeInternals:o,hasDefaultNodes:s,nodeOrigin:l,getNodes:c,elevateNodesOnSelect:f}=t();if(n?.length){if(s){const h=qw(n,c()),a=xh(h,o,l,f);e({nodeInternals:a})}r?.(n)}},addSelectedNodes:n=>{const{multiSelectionActive:r,edges:o,getNodes:s}=t();let l,c=null;r?l=n.map(f=>jn(f,!0)):(l=Cr(s(),n),c=Cr(o,[])),Qi({changedNodes:l,changedEdges:c,get:t,set:e})},addSelectedEdges:n=>{const{multiSelectionActive:r,edges:o,getNodes:s}=t();let l,c=null;r?l=n.map(f=>jn(f,!0)):(l=Cr(o,n),c=Cr(s(),[])),Qi({changedNodes:c,changedEdges:l,get:t,set:e})},unselectNodesAndEdges:({nodes:n,edges:r}={})=>{const{edges:o,getNodes:s}=t(),l=n||s(),c=r||o,f=l.map(a=>(a.selected=!1,jn(a.id,!1))),h=c.map(a=>jn(a.id,!1));Qi({changedNodes:f,changedEdges:h,get:t,set:e})},setMinZoom:n=>{const{d3Zoom:r,maxZoom:o}=t();r?.scaleExtent([n,o]),e({minZoom:n})},setMaxZoom:n=>{const{d3Zoom:r,minZoom:o}=t();r?.scaleExtent([o,n]),e({maxZoom:n})},setTranslateExtent:n=>{t().d3Zoom?.translateExtent(n),e({translateExtent:n})},resetSelectedElements:()=>{const{edges:n,getNodes:r}=t(),s=r().filter(c=>c.selected).map(c=>jn(c.id,!1)),l=n.filter(c=>c.selected).map(c=>jn(c.id,!1));Qi({changedNodes:s,changedEdges:l,get:t,set:e})},setNodeExtent:n=>{const{nodeInternals:r}=t();r.forEach(o=>{o.positionAbsolute=fh(o.position,n)}),e({nodeExtent:n,nodeInternals:new Map(r)})},panBy:n=>{const{transform:r,width:o,height:s,d3Zoom:l,d3Selection:c,translateExtent:f}=t();if(!l||!c||!n.x&&!n.y)return!1;const h=Tn.translate(r[0]+n.x,r[1]+n.y).scale(r[2]),a=[[0,0],[o,s]],u=l?.constrain()(h,a,f);return l.transform(c,u),r[0]!==u.x||r[1]!==u.y||r[2]!==u.k},cancelConnection:()=>e({connectionNodeId:Fn.connectionNodeId,connectionHandleId:Fn.connectionHandleId,connectionHandleType:Fn.connectionHandleType,connectionStatus:Fn.connectionStatus,connectionStartHandle:Fn.connectionStartHandle,connectionEndHandle:Fn.connectionEndHandle}),reset:()=>e({...Fn})}),Object.is),tO=({children:e})=>{const t=se.useRef(null);return t.current||(t.current=bM()),$.jsx(jP,{value:t.current,children:e})};tO.displayName="ReactFlowProvider";const nO=({children:e})=>se.useContext(Vi)?$.jsx($.Fragment,{children:e}):$.jsx(tO,{children:e});nO.displayName="ReactFlowWrapper";const _M={input:mw,default:Oh,output:_w,group:Eh},wM={default:Yi,straight:yh,step:gh,smoothstep:Ki,simplebezier:ph},OM=[0,0],EM=[15,15],xM={x:0,y:0,zoom:1},SM={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0},Ph=se.forwardRef(({nodes:e,edges:t,defaultNodes:n,defaultEdges:r,className:o,nodeTypes:s=_M,edgeTypes:l=wM,onNodeClick:c,onEdgeClick:f,onInit:h,onMove:a,onMoveStart:u,onMoveEnd:d,onConnect:p,onConnectStart:O,onConnectEnd:g,onClickConnectStart:_,onClickConnectEnd:y,onNodeMouseEnter:w,onNodeMouseMove:E,onNodeMouseLeave:m,onNodeContextMenu:S,onNodeDoubleClick:C,onNodeDragStart:N,onNodeDrag:M,onNodeDragStop:j,onNodesDelete:I,onEdgesDelete:A,onSelectionChange:q,onSelectionDragStart:R,onSelectionDrag:k,onSelectionDragStop:F,onSelectionContextMenu:U,onSelectionStart:ne,onSelectionEnd:ue,connectionMode:K=tr.Strict,connectionLineType:W=vn.Bezier,connectionLineStyle:z,connectionLineComponent:Q,connectionLineContainerStyle:re,deleteKeyCode:Z="Backspace",selectionKeyCode:X="Shift",selectionOnDrag:H=!1,selectionMode:ee=So.Full,panActivationKeyCode:le="Space",multiSelectionKeyCode:de=Ui()?"Meta":"Control",zoomActivationKeyCode:pe=Ui()?"Meta":"Control",snapToGrid:Ee=!1,snapGrid:Ie=EM,onlyRenderVisibleElements:Pe=!1,selectNodesOnDrag:Ae=!0,nodesDraggable:Se,nodesConnectable:Ge,nodesFocusable:Oe,nodeOrigin:ge=OM,edgesFocusable:me,edgesUpdatable:ke,elementsSelectable:Ne,defaultViewport:we=xM,minZoom:qe=.5,maxZoom:je=2,translateExtent:ze=Ah,preventScrolling:lt=!0,nodeExtent:pt,defaultMarkerColor:Ze="#b1b1b7",zoomOnScroll:It=!0,zoomOnPinch:We=!0,panOnScroll:it=!1,panOnScrollSpeed:Ot=.5,panOnScrollMode:kt=nr.Free,zoomOnDoubleClick:Nt=!0,panOnDrag:Ft=!0,onPaneClick:gn,onPaneMouseEnter:qo,onPaneMouseMove:Lo,onPaneMouseLeave:yn,onPaneScroll:Ro,onPaneContextMenu:Ir,children:Pn,onEdgeUpdate:fa,onEdgeContextMenu:da,onEdgeDoubleClick:Do,onEdgeMouseEnter:ha,onEdgeMouseMove:Kh,onEdgeMouseLeave:jo,onEdgeUpdateStart:Wh,onEdgeUpdateEnd:Fo,edgeUpdaterRadius:pa=10,onNodesChange:Mr,onEdgesChange:Yh,noDragClassName:Zh="nodrag",noWheelClassName:qr="nowheel",noPanClassName:va="nopan",fitView:Lr=!1,fitViewOptions:Xh,connectOnClick:Rr=!0,attributionPosition:Qh,proOptions:Dr,defaultEdgeOptions:Jh,elevateNodesOnSelect:jr=!0,elevateEdgesOnSelect:ep=!1,disableKeyboardA11y:sr=!1,autoPanOnConnect:Fr=!0,autoPanOnNodeDrag:$n=!0,connectionRadius:tp=20,isValidConnection:ga,onError:lr,style:ya,id:Hn,...Bo},np)=>{const ur=Hn||"1";return $.jsx("div",{...Bo,style:{...ya,...SM},ref:np,className:Tt(["react-flow",o]),"data-testid":"rf__wrapper",id:Hn,children:$.jsxs(nO,{children:[$.jsx(mM,{onInit:h,onMove:a,onMoveStart:u,onMoveEnd:d,onNodeClick:c,onEdgeClick:f,onNodeMouseEnter:w,onNodeMouseMove:E,onNodeMouseLeave:m,onNodeContextMenu:S,onNodeDoubleClick:C,nodeTypes:s,edgeTypes:l,connectionLineType:W,connectionLineStyle:z,connectionLineComponent:Q,connectionLineContainerStyle:re,selectionKeyCode:X,selectionOnDrag:H,selectionMode:ee,deleteKeyCode:Z,multiSelectionKeyCode:de,panActivationKeyCode:le,zoomActivationKeyCode:pe,onlyRenderVisibleElements:Pe,selectNodesOnDrag:Ae,defaultViewport:we,translateExtent:ze,minZoom:qe,maxZoom:je,preventScrolling:lt,zoomOnScroll:It,zoomOnPinch:We,zoomOnDoubleClick:Nt,panOnScroll:it,panOnScrollSpeed:Ot,panOnScrollMode:kt,panOnDrag:Ft,onPaneClick:gn,onPaneMouseEnter:qo,onPaneMouseMove:Lo,onPaneMouseLeave:yn,onPaneScroll:Ro,onPaneContextMenu:Ir,onSelectionContextMenu:U,onSelectionStart:ne,onSelectionEnd:ue,onEdgeUpdate:fa,onEdgeContextMenu:da,onEdgeDoubleClick:Do,onEdgeMouseEnter:ha,onEdgeMouseMove:Kh,onEdgeMouseLeave:jo,onEdgeUpdateStart:Wh,onEdgeUpdateEnd:Fo,edgeUpdaterRadius:pa,defaultMarkerColor:Ze,noDragClassName:Zh,noWheelClassName:qr,noPanClassName:va,elevateEdgesOnSelect:ep,rfId:ur,disableKeyboardA11y:sr,nodeOrigin:ge,nodeExtent:pt}),$.jsx(vI,{nodes:e,edges:t,defaultNodes:n,defaultEdges:r,onConnect:p,onConnectStart:O,onConnectEnd:g,onClickConnectStart:_,onClickConnectEnd:y,nodesDraggable:Se,nodesConnectable:Ge,nodesFocusable:Oe,edgesFocusable:me,edgesUpdatable:ke,elementsSelectable:Ne,elevateNodesOnSelect:jr,minZoom:qe,maxZoom:je,nodeExtent:pt,onNodesChange:Mr,onEdgesChange:Yh,snapToGrid:Ee,snapGrid:Ie,connectionMode:K,translateExtent:ze,connectOnClick:Rr,defaultEdgeOptions:Jh,fitView:Lr,fitViewOptions:Xh,onNodesDelete:I,onEdgesDelete:A,onNodeDragStart:N,onNodeDrag:M,onNodeDragStop:j,onSelectionDrag:k,onSelectionDragStart:R,onSelectionDragStop:F,noPanClassName:va,nodeOrigin:ge,rfId:ur,autoPanOnConnect:Fr,autoPanOnNodeDrag:$n,onError:lr,connectionRadius:tp,isValidConnection:ga}),$.jsx(hI,{onSelectionChange:q}),Pn,$.jsx(BP,{proOptions:Dr,position:Qh}),$.jsx(_I,{rfId:ur,disableKeyboardA11y:sr})]})})});Ph.displayName="ReactFlow";function rO(e){return t=>{const[n,r]=se.useState(t),o=se.useCallback(s=>r(l=>e(s,l)),[]);return[n,r,o]}}const kM=rO(qw),NM=rO(qI),oO=({id:e,x:t,y:n,width:r,height:o,style:s,color:l,strokeColor:c,strokeWidth:f,className:h,borderRadius:a,shapeRendering:u,onClick:d,selected:p})=>{const{background:O,backgroundColor:g}=s||{},_=l||O||g;return $.jsx("rect",{className:Tt(["react-flow__minimap-node",{selected:p},h]),x:t,y:n,rx:a,ry:a,width:r,height:o,fill:_,stroke:c,strokeWidth:f,shapeRendering:u,onClick:d?y=>d(y,e):void 0})};oO.displayName="MiniMapNode";var TM=se.memo(oO);const CM=e=>e.nodeOrigin,AM=e=>e.getNodes().filter(t=>!t.hidden&&t.width&&t.height),Ih=e=>e instanceof Function?e:()=>e;function PM({nodeStrokeColor:e="transparent",nodeColor:t="#e2e2e2",nodeClassName:n="",nodeBorderRadius:r=5,nodeStrokeWidth:o=2,nodeComponent:s=TM,onClick:l}){const c=st(AM,St),f=st(CM),h=Ih(t),a=Ih(e),u=Ih(n),d=typeof window>"u"||window.chrome?"crispEdges":"geometricPrecision";return $.jsx($.Fragment,{children:c.map(p=>{const{x:O,y:g}=rr(p,f).positionAbsolute;return $.jsx(s,{x:O,y:g,width:p.width,height:p.height,style:p.style,selected:p.selected,className:u(p),color:h(p),borderRadius:r,strokeColor:a(p),strokeWidth:o,shapeRendering:d,onClick:l,id:p.id},p.id)})})}var IM=se.memo(PM);const MM=200,qM=150,LM=e=>{const t=e.getNodes(),n={x:-e.transform[0]/e.transform[2],y:-e.transform[1]/e.transform[2],width:e.width/e.transform[2],height:e.height/e.transform[2]};return{viewBB:n,boundingRect:t.length>0?HP(Zi(t,e.nodeOrigin),n):n,rfId:e.rfId}},RM="react-flow__minimap-desc";function iO({style:e,className:t,nodeStrokeColor:n="transparent",nodeColor:r="#e2e2e2",nodeClassName:o="",nodeBorderRadius:s=5,nodeStrokeWidth:l=2,nodeComponent:c,maskColor:f="rgb(240, 240, 240, 0.6)",maskStrokeColor:h="none",maskStrokeWidth:a=1,position:u="bottom-right",onClick:d,onNodeClick:p,pannable:O=!1,zoomable:g=!1,ariaLabel:_="React Flow mini map",inversePan:y=!1,zoomStep:w=10,offsetScale:E=5}){const m=_t(),S=se.useRef(null),{boundingRect:C,viewBB:N,rfId:M}=st(LM,St),j=e?.width??MM,I=e?.height??qM,A=C.width/j,q=C.height/I,R=Math.max(A,q),k=R*j,F=R*I,U=E*R,ne=C.x-(k-C.width)/2-U,ue=C.y-(F-C.height)/2-U,K=k+U*2,W=F+U*2,z=`${RM}-${M}`,Q=se.useRef(0);Q.current=R,se.useEffect(()=>{if(S.current){const X=Zt(S.current),H=de=>{const{transform:pe,d3Selection:Ee,d3Zoom:Ie}=m.getState();if(de.sourceEvent.type!=="wheel"||!Ee||!Ie)return;const Pe=-de.sourceEvent.deltaY*(de.sourceEvent.deltaMode===1?.05:de.sourceEvent.deltaMode?1:.002)*w,Ae=pe[2]*Math.pow(2,Pe);Ie.scaleTo(Ee,Ae)},ee=de=>{const{transform:pe,d3Selection:Ee,d3Zoom:Ie,translateExtent:Pe,width:Ae,height:Se}=m.getState();if(de.sourceEvent.type!=="mousemove"||!Ee||!Ie)return;const Ge=Q.current*Math.max(1,pe[2])*(y?-1:1),Oe={x:pe[0]-de.sourceEvent.movementX*Ge,y:pe[1]-de.sourceEvent.movementY*Ge},ge=[[0,0],[Ae,Se]],me=Tn.translate(Oe.x,Oe.y).scale(pe[2]),ke=Ie.constrain()(me,ge,Pe);Ie.transform(Ee,ke)},le=$_().on("zoom",O?ee:null).on("zoom.wheel",g?H:null);return X.call(le),()=>{X.on("zoom",null)}}},[O,g,y,w]);const re=d?X=>{const H=an(X);d(X,{x:H[0],y:H[1]})}:void 0,Z=p?(X,H)=>{const ee=m.getState().nodeInternals.get(H);p(X,ee)}:void 0;return $.jsx(uh,{position:u,style:e,className:Tt(["react-flow__minimap",t]),"data-testid":"rf__minimap",children:$.jsxs("svg",{width:j,height:I,viewBox:`${ne} ${ue} ${K} ${W}`,role:"img","aria-labelledby":z,ref:S,onClick:re,children:[_&&$.jsx("title",{id:z,children:_}),$.jsx(IM,{onClick:Z,nodeColor:r,nodeStrokeColor:n,nodeBorderRadius:s,nodeClassName:o,nodeStrokeWidth:l,nodeComponent:c}),$.jsx("path",{className:"react-flow__minimap-mask",d:`M${ne-U},${ue-U}h${K+U*2}v${W+U*2}h${-K-U*2}z
|
|
18
|
-
M${N.x},${N.y}h${N.width}v${N.height}h${-N.width}z`,fill:f,fillRule:"evenodd",stroke:h,strokeWidth:a,pointerEvents:"none"})]})})}iO.displayName="MiniMap";var aO=se.memo(iO);function DM(){return $.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:$.jsx("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"})})}function jM(){return $.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5",children:$.jsx("path",{d:"M0 0h32v4.2H0z"})})}function FM(){return $.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30",children:$.jsx("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"})})}function BM(){return $.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:$.jsx("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"})})}function zM(){return $.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:$.jsx("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"})})}const Co=({children:e,className:t,...n})=>$.jsx("button",{type:"button",className:Tt(["react-flow__controls-button",t]),...n,children:e});Co.displayName="ControlButton";const $M=e=>({isInteractive:e.nodesDraggable||e.nodesConnectable||e.elementsSelectable,minZoomReached:e.transform[2]<=e.minZoom,maxZoomReached:e.transform[2]>=e.maxZoom}),sO=({style:e,showZoom:t=!0,showFitView:n=!0,showInteractive:r=!0,fitViewOptions:o,onZoomIn:s,onZoomOut:l,onFitView:c,onInteractiveChange:f,className:h,children:a,position:u="bottom-left"})=>{const d=_t(),[p,O]=se.useState(!1),{isInteractive:g,minZoomReached:_,maxZoomReached:y}=st($M,St),{zoomIn:w,zoomOut:E,fitView:m}=Ji();if(se.useEffect(()=>{O(!0)},[]),!p)return null;const S=()=>{w(),s?.()},C=()=>{E(),l?.()},N=()=>{m(o),c?.()},M=()=>{d.setState({nodesDraggable:!g,nodesConnectable:!g,elementsSelectable:!g}),f?.(!g)};return $.jsxs(uh,{className:Tt(["react-flow__controls",h]),position:u,style:e,"data-testid":"rf__controls",children:[t&&$.jsxs($.Fragment,{children:[$.jsx(Co,{onClick:S,className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in",disabled:y,children:$.jsx(DM,{})}),$.jsx(Co,{onClick:C,className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out",disabled:_,children:$.jsx(jM,{})})]}),n&&$.jsx(Co,{className:"react-flow__controls-fitview",onClick:N,title:"fit view","aria-label":"fit view",children:$.jsx(FM,{})}),r&&$.jsx(Co,{className:"react-flow__controls-interactive",onClick:M,title:"toggle interactivity","aria-label":"toggle interactivity",children:g?$.jsx(zM,{}):$.jsx(BM,{})}),a]})};sO.displayName="Controls";var lO=se.memo(sO),un;(function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"})(un||(un={}));function HM({color:e,dimensions:t,lineWidth:n}){return $.jsx("path",{stroke:e,strokeWidth:n,d:`M${t[0]/2} 0 V${t[1]} M0 ${t[1]/2} H${t[0]}`})}function VM({color:e,radius:t}){return $.jsx("circle",{cx:t,cy:t,r:t,fill:e})}const UM={[un.Dots]:"#91919a",[un.Lines]:"#eee",[un.Cross]:"#e2e2e2"},GM={[un.Dots]:1,[un.Lines]:1,[un.Cross]:6},KM=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function uO({id:e,variant:t=un.Dots,gap:n=20,size:r,lineWidth:o=1,offset:s=2,color:l,style:c,className:f}){const h=se.useRef(null),{transform:a,patternId:u}=st(KM,St),d=l||UM[t],p=r||GM[t],O=t===un.Dots,g=t===un.Cross,_=Array.isArray(n)?n:[n,n],y=[_[0]*a[2]||1,_[1]*a[2]||1],w=p*a[2],E=g?[w,w]:y,m=O?[w/s,w/s]:[E[0]/s,E[1]/s];return $.jsxs("svg",{className:Tt(["react-flow__background",f]),style:{...c,position:"absolute",width:"100%",height:"100%",top:0,left:0},ref:h,"data-testid":"rf__background",children:[$.jsx("pattern",{id:u+e,x:a[0]%y[0],y:a[1]%y[1],width:y[0],height:y[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${m[0]},-${m[1]})`,children:O?$.jsx(VM,{color:d,radius:w/s}):$.jsx(HM,{dimensions:E,color:d,lineWidth:o})}),$.jsx("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${u+e})`})]})}uO.displayName="Background";var cO=se.memo(uO);function fO(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=fO(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Bn(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=fO(e))&&(r&&(r+=" "),r+=t);return r}const Ao=e=>typeof e=="number"&&!isNaN(e),ir=e=>typeof e=="string",jt=e=>typeof e=="function",ta=e=>ir(e)||jt(e)?e:null,Mh=e=>se.isValidElement(e)||ir(e)||jt(e)||Ao(e);function WM(e,t,n){n===void 0&&(n=300);const{scrollHeight:r,style:o}=e;requestAnimationFrame(()=>{o.minHeight="initial",o.height=r+"px",o.transition=`all ${n}ms`,requestAnimationFrame(()=>{o.height="0",o.padding="0",o.margin="0",setTimeout(t,n)})})}function na(e){let{enter:t,exit:n,appendPosition:r=!1,collapse:o=!0,collapseDuration:s=300}=e;return function(l){let{children:c,position:f,preventExitTransition:h,done:a,nodeRef:u,isIn:d}=l;const p=r?`${t}--${f}`:t,O=r?`${n}--${f}`:n,g=se.useRef(0);return se.useLayoutEffect(()=>{const _=u.current,y=p.split(" "),w=E=>{E.target===u.current&&(_.dispatchEvent(new Event("d")),_.removeEventListener("animationend",w),_.removeEventListener("animationcancel",w),g.current===0&&E.type!=="animationcancel"&&_.classList.remove(...y))};_.classList.add(...y),_.addEventListener("animationend",w),_.addEventListener("animationcancel",w)},[]),se.useEffect(()=>{const _=u.current,y=()=>{_.removeEventListener("animationend",y),o?WM(_,a,s):a()};d||(h?y():(g.current=1,_.className+=` ${O}`,_.addEventListener("animationend",y)))},[d]),nt.default.createElement(nt.default.Fragment,null,c)}}function dO(e,t){return e!=null?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:t}:{}}const Qt={list:new Map,emitQueue:new Map,on(e,t){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(t),this},off(e,t){if(t){const n=this.list.get(e).filter(r=>r!==t);return this.list.set(e,n),this}return this.list.delete(e),this},cancelEmit(e){const t=this.emitQueue.get(e);return t&&(t.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit(e){this.list.has(e)&&this.list.get(e).forEach(t=>{const n=setTimeout(()=>{t(...[].slice.call(arguments,1))},0);this.emitQueue.has(e)||this.emitQueue.set(e,[]),this.emitQueue.get(e).push(n)})}},ra=e=>{let{theme:t,type:n,...r}=e;return nt.default.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${n})`,...r})},qh={info:function(e){return nt.default.createElement(ra,{...e},nt.default.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return nt.default.createElement(ra,{...e},nt.default.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return nt.default.createElement(ra,{...e},nt.default.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return nt.default.createElement(ra,{...e},nt.default.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return nt.default.createElement("div",{className:"Toastify__spinner"})}};function YM(e){const[,t]=se.useReducer(p=>p+1,0),[n,r]=se.useState([]),o=se.useRef(null),s=se.useRef(new Map).current,l=p=>n.indexOf(p)!==-1,c=se.useRef({toastKey:1,displayedToast:0,count:0,queue:[],props:e,containerId:null,isToastActive:l,getToast:p=>s.get(p)}).current;function f(p){let{containerId:O}=p;const{limit:g}=c.props;!g||O&&c.containerId!==O||(c.count-=c.queue.length,c.queue=[])}function h(p){r(O=>p==null?[]:O.filter(g=>g!==p))}function a(){const{toastContent:p,toastProps:O,staleId:g}=c.queue.shift();d(p,O,g)}function u(p,O){let{delay:g,staleId:_,...y}=O;if(!Mh(p)||(function(q){return!o.current||c.props.enableMultiContainer&&q.containerId!==c.props.containerId||s.has(q.toastId)&&q.updateId==null})(y))return;const{toastId:w,updateId:E,data:m}=y,{props:S}=c,C=()=>h(w),N=E==null;N&&c.count++;const M={...S,style:S.toastStyle,key:c.toastKey++,...Object.fromEntries(Object.entries(y).filter(q=>{let[R,k]=q;return k!=null})),toastId:w,updateId:E,data:m,closeToast:C,isIn:!1,className:ta(y.className||S.toastClassName),bodyClassName:ta(y.bodyClassName||S.bodyClassName),progressClassName:ta(y.progressClassName||S.progressClassName),autoClose:!y.isLoading&&(j=y.autoClose,I=S.autoClose,j===!1||Ao(j)&&j>0?j:I),deleteToast(){const q=dO(s.get(w),"removed");s.delete(w),Qt.emit(4,q);const R=c.queue.length;if(c.count=w==null?c.count-c.displayedToast:c.count-1,c.count<0&&(c.count=0),R>0){const k=w==null?c.props.limit:1;if(R===1||k===1)c.displayedToast++,a();else{const F=k>R?R:k;c.displayedToast=F;for(let U=0;U<F;U++)a()}}else t()}};var j,I;M.iconOut=(function(q){let{theme:R,type:k,isLoading:F,icon:U}=q,ne=null;const ue={theme:R,type:k};return U===!1||(jt(U)?ne=U(ue):se.isValidElement(U)?ne=se.cloneElement(U,ue):ir(U)||Ao(U)?ne=U:F?ne=qh.spinner():(K=>K in qh)(k)&&(ne=qh[k](ue))),ne})(M),jt(y.onOpen)&&(M.onOpen=y.onOpen),jt(y.onClose)&&(M.onClose=y.onClose),M.closeButton=S.closeButton,y.closeButton===!1||Mh(y.closeButton)?M.closeButton=y.closeButton:y.closeButton===!0&&(M.closeButton=!Mh(S.closeButton)||S.closeButton);let A=p;se.isValidElement(p)&&!ir(p.type)?A=se.cloneElement(p,{closeToast:C,toastProps:M,data:m}):jt(p)&&(A=p({closeToast:C,toastProps:M,data:m})),S.limit&&S.limit>0&&c.count>S.limit&&N?c.queue.push({toastContent:A,toastProps:M,staleId:_}):Ao(g)?setTimeout(()=>{d(A,M,_)},g):d(A,M,_)}function d(p,O,g){const{toastId:_}=O;g&&s.delete(g);const y={content:p,props:O};s.set(_,y),r(w=>[...w,_].filter(E=>E!==g)),Qt.emit(4,dO(y,y.props.updateId==null?"added":"updated"))}return se.useEffect(()=>(c.containerId=e.containerId,Qt.cancelEmit(3).on(0,u).on(1,p=>o.current&&h(p)).on(5,f).emit(2,c),()=>{s.clear(),Qt.emit(3,c)}),[]),se.useEffect(()=>{c.props=e,c.isToastActive=l,c.displayedToast=n.length}),{getToastToRender:function(p){const O=new Map,g=Array.from(s.values());return e.newestOnTop&&g.reverse(),g.forEach(_=>{const{position:y}=_.props;O.has(y)||O.set(y,[]),O.get(y).push(_)}),Array.from(O,_=>p(_[0],_[1]))},containerRef:o,isToastActive:l}}function hO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function pO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function ZM(e){const[t,n]=se.useState(!1),[r,o]=se.useState(!1),s=se.useRef(null),l=se.useRef({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,c=se.useRef(e),{autoClose:f,pauseOnHover:h,closeToast:a,onClick:u,closeOnClick:d}=e;function p(m){if(e.draggable){m.nativeEvent.type==="touchstart"&&m.nativeEvent.preventDefault(),l.didMove=!1,document.addEventListener("mousemove",y),document.addEventListener("mouseup",w),document.addEventListener("touchmove",y),document.addEventListener("touchend",w);const S=s.current;l.canCloseOnClick=!0,l.canDrag=!0,l.boundingRect=S.getBoundingClientRect(),S.style.transition="",l.x=hO(m.nativeEvent),l.y=pO(m.nativeEvent),e.draggableDirection==="x"?(l.start=l.x,l.removalDistance=S.offsetWidth*(e.draggablePercent/100)):(l.start=l.y,l.removalDistance=S.offsetHeight*(e.draggablePercent===80?1.5*e.draggablePercent:e.draggablePercent/100))}}function O(m){if(l.boundingRect){const{top:S,bottom:C,left:N,right:M}=l.boundingRect;m.nativeEvent.type!=="touchend"&&e.pauseOnHover&&l.x>=N&&l.x<=M&&l.y>=S&&l.y<=C?_():g()}}function g(){n(!0)}function _(){n(!1)}function y(m){const S=s.current;l.canDrag&&S&&(l.didMove=!0,t&&_(),l.x=hO(m),l.y=pO(m),l.delta=e.draggableDirection==="x"?l.x-l.start:l.y-l.start,l.start!==l.x&&(l.canCloseOnClick=!1),S.style.transform=`translate${e.draggableDirection}(${l.delta}px)`,S.style.opacity=""+(1-Math.abs(l.delta/l.removalDistance)))}function w(){document.removeEventListener("mousemove",y),document.removeEventListener("mouseup",w),document.removeEventListener("touchmove",y),document.removeEventListener("touchend",w);const m=s.current;if(l.canDrag&&l.didMove&&m){if(l.canDrag=!1,Math.abs(l.delta)>l.removalDistance)return o(!0),void e.closeToast();m.style.transition="transform 0.2s, opacity 0.2s",m.style.transform=`translate${e.draggableDirection}(0)`,m.style.opacity="1"}}se.useEffect(()=>{c.current=e}),se.useEffect(()=>(s.current&&s.current.addEventListener("d",g,{once:!0}),jt(e.onOpen)&&e.onOpen(se.isValidElement(e.children)&&e.children.props),()=>{const m=c.current;jt(m.onClose)&&m.onClose(se.isValidElement(m.children)&&m.children.props)}),[]),se.useEffect(()=>(e.pauseOnFocusLoss&&(document.hasFocus()||_(),window.addEventListener("focus",g),window.addEventListener("blur",_)),()=>{e.pauseOnFocusLoss&&(window.removeEventListener("focus",g),window.removeEventListener("blur",_))}),[e.pauseOnFocusLoss]);const E={onMouseDown:p,onTouchStart:p,onMouseUp:O,onTouchEnd:O};return f&&h&&(E.onMouseEnter=_,E.onMouseLeave=g),d&&(E.onClick=m=>{u&&u(m),l.canCloseOnClick&&a()}),{playToast:g,pauseToast:_,isRunning:t,preventExitTransition:r,toastRef:s,eventHandlers:E}}function vO(e){let{closeToast:t,theme:n,ariaLabel:r="close"}=e;return nt.default.createElement("button",{className:`Toastify__close-button Toastify__close-button--${n}`,type:"button",onClick:o=>{o.stopPropagation(),t(o)},"aria-label":r},nt.default.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},nt.default.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function XM(e){let{delay:t,isRunning:n,closeToast:r,type:o="default",hide:s,className:l,style:c,controlledProgress:f,progress:h,rtl:a,isIn:u,theme:d}=e;const p=s||f&&h===0,O={...c,animationDuration:`${t}ms`,animationPlayState:n?"running":"paused",opacity:p?0:1};f&&(O.transform=`scaleX(${h})`);const g=Bn("Toastify__progress-bar",f?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${d}`,`Toastify__progress-bar--${o}`,{"Toastify__progress-bar--rtl":a}),_=jt(l)?l({rtl:a,type:o,defaultClassName:g}):Bn(g,l);return nt.default.createElement("div",{role:"progressbar","aria-hidden":p?"true":"false","aria-label":"notification timer",className:_,style:O,[f&&h>=1?"onTransitionEnd":"onAnimationEnd"]:f&&h<1?null:()=>{u&&r()}})}const QM=e=>{const{isRunning:t,preventExitTransition:n,toastRef:r,eventHandlers:o}=ZM(e),{closeButton:s,children:l,autoClose:c,onClick:f,type:h,hideProgressBar:a,closeToast:u,transition:d,position:p,className:O,style:g,bodyClassName:_,bodyStyle:y,progressClassName:w,progressStyle:E,updateId:m,role:S,progress:C,rtl:N,toastId:M,deleteToast:j,isIn:I,isLoading:A,iconOut:q,closeOnClick:R,theme:k}=e,F=Bn("Toastify__toast",`Toastify__toast-theme--${k}`,`Toastify__toast--${h}`,{"Toastify__toast--rtl":N},{"Toastify__toast--close-on-click":R}),U=jt(O)?O({rtl:N,position:p,type:h,defaultClassName:F}):Bn(F,O),ne=!!C||!c,ue={closeToast:u,type:h,theme:k};let K=null;return s===!1||(K=jt(s)?s(ue):se.isValidElement(s)?se.cloneElement(s,ue):vO(ue)),nt.default.createElement(d,{isIn:I,done:j,position:p,preventExitTransition:n,nodeRef:r},nt.default.createElement("div",{id:M,onClick:f,className:U,...o,style:g,ref:r},nt.default.createElement("div",{...I&&{role:S},className:jt(_)?_({type:h}):Bn("Toastify__toast-body",_),style:y},q!=null&&nt.default.createElement("div",{className:Bn("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!A})},q),nt.default.createElement("div",null,l)),K,nt.default.createElement(XM,{...m&&!ne?{key:`pb-${m}`}:{},rtl:N,theme:k,delay:c,isRunning:t,isIn:I,closeToast:u,hide:a,type:h,style:E,className:w,controlledProgress:ne,progress:C||0})))},oa=function(e,t){return t===void 0&&(t=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:t}},JM=na(oa("bounce",!0));na(oa("slide",!0)),na(oa("zoom")),na(oa("flip"));const Lh=se.forwardRef((e,t)=>{const{getToastToRender:n,containerRef:r,isToastActive:o}=YM(e),{className:s,style:l,rtl:c,containerId:f}=e;function h(a){const u=Bn("Toastify__toast-container",`Toastify__toast-container--${a}`,{"Toastify__toast-container--rtl":c});return jt(s)?s({position:a,rtl:c,defaultClassName:u}):Bn(u,ta(s))}return se.useEffect(()=>{t&&(t.current=r.current)},[]),nt.default.createElement("div",{ref:r,className:"Toastify",id:f},n((a,u)=>{const d=u.length?{...l}:{...l,pointerEvents:"none"};return nt.default.createElement("div",{className:h(a),style:d,key:`container-${a}`},u.map((p,O)=>{let{content:g,props:_}=p;return nt.default.createElement(QM,{..._,isIn:o(_.toastId),style:{..._.style,"--nth":O+1,"--len":u.length},key:`toast-${_.key}`},g)}))}))});Lh.displayName="ToastContainer",Lh.defaultProps={position:"top-right",transition:JM,autoClose:5e3,closeButton:vO,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let Rh,ar=new Map,Po=[],eq=1;function gO(){return""+eq++}function tq(e){return e&&(ir(e.toastId)||Ao(e.toastId))?e.toastId:gO()}function Io(e,t){return ar.size>0?Qt.emit(0,e,t):Po.push({content:e,options:t}),t.toastId}function ia(e,t){return{...t,type:t&&t.type||e,toastId:tq(t)}}function aa(e){return(t,n)=>Io(t,ia(e,n))}function Ke(e,t){return Io(e,ia("default",t))}Ke.loading=(e,t)=>Io(e,ia("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...t})),Ke.promise=function(e,t,n){let r,{pending:o,error:s,success:l}=t;o&&(r=ir(o)?Ke.loading(o,n):Ke.loading(o.render,{...n,...o}));const c={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},f=(a,u,d)=>{if(u==null)return void Ke.dismiss(r);const p={type:a,...c,...n,data:d},O=ir(u)?{render:u}:u;return r?Ke.update(r,{...p,...O}):Ke(O.render,{...p,...O}),d},h=jt(e)?e():e;return h.then(a=>f("success",l,a)).catch(a=>f("error",s,a)),h},Ke.success=aa("success"),Ke.info=aa("info"),Ke.error=aa("error"),Ke.warning=aa("warning"),Ke.warn=Ke.warning,Ke.dark=(e,t)=>Io(e,ia("default",{theme:"dark",...t})),Ke.dismiss=e=>{ar.size>0?Qt.emit(1,e):Po=Po.filter(t=>e!=null&&t.options.toastId!==e)},Ke.clearWaitingQueue=function(e){return e===void 0&&(e={}),Qt.emit(5,e)},Ke.isActive=e=>{let t=!1;return ar.forEach(n=>{n.isToastActive&&n.isToastActive(e)&&(t=!0)}),t},Ke.update=function(e,t){t===void 0&&(t={}),setTimeout(()=>{const n=(function(r,o){let{containerId:s}=o;const l=ar.get(s||Rh);return l&&l.getToast(r)})(e,t);if(n){const{props:r,content:o}=n,s={delay:100,...r,...t,toastId:t.toastId||e,updateId:gO()};s.toastId!==e&&(s.staleId=e);const l=s.render||o;delete s.render,Io(l,s)}},0)},Ke.done=e=>{Ke.update(e,{progress:1})},Ke.onChange=e=>(Qt.on(4,e),()=>{Qt.off(4,e)}),Ke.POSITION={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},Ke.TYPE={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},Qt.on(2,e=>{Rh=e.containerId||e,ar.set(Rh,e),Po.forEach(t=>{Qt.emit(0,t.content,t.options)}),Po=[]}).on(3,e=>{ar.delete(e.containerId||e),ar.size===0&&Qt.off(0).off(1).off(5)});const yO=se.createContext({certificate:{},node:{},setNode:()=>{},type:"readNode",replica:{},nodesState:[],edgesState:[],nodeLayers:{previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}},setNodeLayers:()=>{}}),mO=e=>{const[t,n]=se.useState({}),[r,o]=se.useState({previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}}),s=kM([]),l=NM([]),c=se.useMemo(()=>({node:t,setNode:n,type:e.type,certificate:e.certificate,replica:e.replica,nodeLayers:r,setNodeLayers:o,nodesState:s,edgesState:l}),[t,n,e.type,e.certificate,e.replica,r,o,s,l]);return $.jsx(yO.Provider,{value:c,children:e.children})},ot=()=>se.useContext(yO);var Dh={exports:{}};/*! For license information please see main.js.LICENSE.txt */var bO;function nq(){return bO||(bO=1,(function(e,t){(function(n,r){e.exports=r(nt.default,pv.default)})(self,((n,r)=>(()=>{var o={184:(f,h)=>{var a;(function(){var u={}.hasOwnProperty;function d(){for(var p=[],O=0;O<arguments.length;O++){var g=arguments[O];if(g){var _=typeof g;if(_==="string"||_==="number")p.push(g);else if(Array.isArray(g)){if(g.length){var y=d.apply(null,g);y&&p.push(y)}}else if(_==="object"){if(g.toString!==Object.prototype.toString&&!g.toString.toString().includes("[native code]")){p.push(g.toString());continue}for(var w in g)u.call(g,w)&&g[w]&&p.push(w)}}}return p.join(" ")}f.exports?(d.default=d,f.exports=d):(a=(function(){return d}).apply(h,[]))===void 0||(f.exports=a)})()},953:(f,h,a)=>{a.d(h,{Z:()=>g});var u=a(81),d=a.n(u),p=a(645),O=a.n(p)()(d());O.push([f.id,".button-component{font-weight:500;letter-spacing:.2px}.button-component.btn{border-radius:2px;white-space:nowrap}.button-component.btn-sm{font-weight:600}.button-component.btn-primary,.button-component.btn-primary:active,.button-component.btn-primary:not(:disabled):not(.disabled):active{background:#003057;border:1px solid #001424;transition:none}.button-component.btn-primary:hover{background:#004c8a}.button-component.btn-primary:disabled{background:#557e9e;border:1px solid #517490;color:#ccc}.button-component.btn-secondary,.button-component.btn-secondary:active,.button-component.btn-secondary:not(:disabled):not(.disabled):active{background:#fff;border:1px solid #ccc;transition:none;color:#000}.button-component.btn-secondary:hover{background:#eee;border:1px solid #ccc;color:#000}.button-component.btn-secondary:disabled{background:#eee;border:1px solid #ccc;color:#666}.button-component a,.button-component a:hover,.button-component a:focus{color:inherit;text-decoration:inherit}.button-component i{margin-right:.4rem}.button-component i.no-text{margin-right:0}.button-component>button{font-weight:500;letter-spacing:.2px}.button-component>button.btn{border-radius:2px;white-space:nowrap}.button-component>button.btn-sm{font-weight:600}.button-component>button.btn-primary,.button-component>button.btn-primary:active,.button-component>button.btn-primary:not(:disabled):not(.disabled):active{background:#003057;border:1px solid #001424;transition:none}.button-component>button.btn-primary:hover{background:#004c8a}.button-component>button.btn-primary:disabled{background:#557e9e;border:1px solid #517490;color:#ccc}.button-component>button.btn-secondary,.button-component>button.btn-secondary:active,.button-component>button.btn-secondary:not(:disabled):not(.disabled):active{background:#fff;border:1px solid #ccc;transition:none;color:#000}.button-component>button.btn-secondary:hover{background:#eee;border:1px solid #ccc;color:#000}.button-component>button.btn-secondary:disabled{background:#eee;border:1px solid #ccc;color:#666}.button-component>button a,.button-component>button a:hover,.button-component>button a:focus{color:inherit;text-decoration:inherit}.button-component>button i{margin-right:.4rem}.button-component>button i.no-text{margin-right:0}",""]);const g=O},525:(f,h,a)=>{a.d(h,{Z:()=>g});var u=a(81),d=a.n(u),p=a(645),O=a.n(p)()(d());O.push([f.id,".keyval__wrapper{display:flex;font-size:13px;margin-bottom:.5rem}.keyval__label{color:#71899c}.keyval__list{list-style:none;padding:0;margin:0;flex-grow:1}.keyval__item{display:block}",""]);const g=O},318:(f,h,a)=>{a.d(h,{Z:()=>g});var u=a(81),d=a.n(u),p=a(645),O=a.n(p)()(d());O.push([f.id,".message-stripe-component{margin:1rem;padding:.75rem}.message-stripe-component.alert{color:inherit;border:none;border-radius:0;box-shadow:0 1px 2px rgba(0,0,0,.25)}.message-stripe__remove-button{background:none;border:none}.message-stripe__remove-button svg{-webkit-appearance:none}",""]);const g=O},970:(f,h,a)=>{a.d(h,{Z:()=>g});var u=a(81),d=a.n(u),p=a(645),O=a.n(p)()(d());O.push([f.id,".hise-select__wrapper .hise-select__control{border:1px solid #aaa;border-radius:0}.hise-select__wrapper.invalid .hise-select__control{border:1px solid #dc3545}",""]);const g=O},645:f=>{f.exports=function(h){var a=[];return a.toString=function(){return this.map((function(u){var d="",p=u[5]!==void 0;return u[4]&&(d+="@supports (".concat(u[4],") {")),u[2]&&(d+="@media ".concat(u[2]," {")),p&&(d+="@layer".concat(u[5].length>0?" ".concat(u[5]):""," {")),d+=h(u),p&&(d+="}"),u[2]&&(d+="}"),u[4]&&(d+="}"),d})).join("")},a.i=function(u,d,p,O,g){typeof u=="string"&&(u=[[null,u,void 0]]);var _={};if(p)for(var y=0;y<this.length;y++){var w=this[y][0];w!=null&&(_[w]=!0)}for(var E=0;E<u.length;E++){var m=[].concat(u[E]);p&&_[m[0]]||(g!==void 0&&(m[5]===void 0||(m[1]="@layer".concat(m[5].length>0?" ".concat(m[5]):""," {").concat(m[1],"}")),m[5]=g),d&&(m[2]&&(m[1]="@media ".concat(m[2]," {").concat(m[1],"}")),m[2]=d),O&&(m[4]?(m[1]="@supports (".concat(m[4],") {").concat(m[1],"}"),m[4]=O):m[4]="".concat(O)),a.push(m))}},a}},81:f=>{f.exports=function(h){return h[1]}},679:(f,h,a)=>{var u=a(864),d={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},p={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},O={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},g={};function _(N){return u.isMemo(N)?O:g[N.$$typeof]||d}g[u.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},g[u.Memo]=O;var y=Object.defineProperty,w=Object.getOwnPropertyNames,E=Object.getOwnPropertySymbols,m=Object.getOwnPropertyDescriptor,S=Object.getPrototypeOf,C=Object.prototype;f.exports=function N(M,j,I){if(typeof j!="string"){if(C){var A=S(j);A&&A!==C&&N(M,A,I)}var q=w(j);E&&(q=q.concat(E(j)));for(var R=_(M),k=_(j),F=0;F<q.length;++F){var U=q[F];if(!(p[U]||I&&I[U]||k&&k[U]||R&&R[U])){var ne=m(j,U);try{y(M,U,ne)}catch{}}}}return M}},703:(f,h,a)=>{var u=a(414);function d(){}function p(){}p.resetWarningCache=d,f.exports=function(){function O(y,w,E,m,S,C){if(C!==u){var N=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw N.name="Invariant Violation",N}}function g(){return O}O.isRequired=O;var _={array:O,bigint:O,bool:O,func:O,number:O,object:O,string:O,symbol:O,any:O,arrayOf:g,element:O,elementType:O,instanceOf:g,node:O,objectOf:g,oneOf:g,oneOfType:g,shape:g,exact:g,checkPropTypes:p,resetWarningCache:d};return _.PropTypes=_,_}},697:(f,h,a)=>{f.exports=a(703)()},414:f=>{f.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(f,h)=>{var a=typeof Symbol=="function"&&Symbol.for,u=a?Symbol.for("react.element"):60103,d=a?Symbol.for("react.portal"):60106,p=a?Symbol.for("react.fragment"):60107,O=a?Symbol.for("react.strict_mode"):60108,g=a?Symbol.for("react.profiler"):60114,_=a?Symbol.for("react.provider"):60109,y=a?Symbol.for("react.context"):60110,w=a?Symbol.for("react.async_mode"):60111,E=a?Symbol.for("react.concurrent_mode"):60111,m=a?Symbol.for("react.forward_ref"):60112,S=a?Symbol.for("react.suspense"):60113,C=a?Symbol.for("react.suspense_list"):60120,N=a?Symbol.for("react.memo"):60115,M=a?Symbol.for("react.lazy"):60116,j=a?Symbol.for("react.block"):60121,I=a?Symbol.for("react.fundamental"):60117,A=a?Symbol.for("react.responder"):60118,q=a?Symbol.for("react.scope"):60119;function R(F){if(typeof F=="object"&&F!==null){var U=F.$$typeof;switch(U){case u:switch(F=F.type){case w:case E:case p:case g:case O:case S:return F;default:switch(F=F&&F.$$typeof){case y:case m:case M:case N:case _:return F;default:return U}}case d:return U}}}function k(F){return R(F)===E}h.AsyncMode=w,h.ConcurrentMode=E,h.ContextConsumer=y,h.ContextProvider=_,h.Element=u,h.ForwardRef=m,h.Fragment=p,h.Lazy=M,h.Memo=N,h.Portal=d,h.Profiler=g,h.StrictMode=O,h.Suspense=S,h.isAsyncMode=function(F){return k(F)||R(F)===w},h.isConcurrentMode=k,h.isContextConsumer=function(F){return R(F)===y},h.isContextProvider=function(F){return R(F)===_},h.isElement=function(F){return typeof F=="object"&&F!==null&&F.$$typeof===u},h.isForwardRef=function(F){return R(F)===m},h.isFragment=function(F){return R(F)===p},h.isLazy=function(F){return R(F)===M},h.isMemo=function(F){return R(F)===N},h.isPortal=function(F){return R(F)===d},h.isProfiler=function(F){return R(F)===g},h.isStrictMode=function(F){return R(F)===O},h.isSuspense=function(F){return R(F)===S},h.isValidElementType=function(F){return typeof F=="string"||typeof F=="function"||F===p||F===E||F===g||F===O||F===S||F===C||typeof F=="object"&&F!==null&&(F.$$typeof===M||F.$$typeof===N||F.$$typeof===_||F.$$typeof===y||F.$$typeof===m||F.$$typeof===I||F.$$typeof===A||F.$$typeof===q||F.$$typeof===j)},h.typeOf=R},864:(f,h,a)=>{f.exports=a(921)},379:f=>{var h=[];function a(p){for(var O=-1,g=0;g<h.length;g++)if(h[g].identifier===p){O=g;break}return O}function u(p,O){for(var g={},_=[],y=0;y<p.length;y++){var w=p[y],E=O.base?w[0]+O.base:w[0],m=g[E]||0,S="".concat(E," ").concat(m);g[E]=m+1;var C=a(S),N={css:w[1],media:w[2],sourceMap:w[3],supports:w[4],layer:w[5]};if(C!==-1)h[C].references++,h[C].updater(N);else{var M=d(N,O);O.byIndex=y,h.splice(y,0,{identifier:S,updater:M,references:1})}_.push(S)}return _}function d(p,O){var g=O.domAPI(O);return g.update(p),function(_){if(_){if(_.css===p.css&&_.media===p.media&&_.sourceMap===p.sourceMap&&_.supports===p.supports&&_.layer===p.layer)return;g.update(p=_)}else g.remove()}}f.exports=function(p,O){var g=u(p=p||[],O=O||{});return function(_){_=_||[];for(var y=0;y<g.length;y++){var w=a(g[y]);h[w].references--}for(var E=u(_,O),m=0;m<g.length;m++){var S=a(g[m]);h[S].references===0&&(h[S].updater(),h.splice(S,1))}g=E}}},569:f=>{var h={};f.exports=function(a,u){var d=(function(p){if(h[p]===void 0){var O=document.querySelector(p);if(window.HTMLIFrameElement&&O instanceof window.HTMLIFrameElement)try{O=O.contentDocument.head}catch{O=null}h[p]=O}return h[p]})(a);if(!d)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");d.appendChild(u)}},216:f=>{f.exports=function(h){var a=document.createElement("style");return h.setAttributes(a,h.attributes),h.insert(a,h.options),a}},565:(f,h,a)=>{f.exports=function(u){var d=a.nc;d&&u.setAttribute("nonce",d)}},795:f=>{f.exports=function(h){if(typeof document>"u")return{update:function(){},remove:function(){}};var a=h.insertStyleElement(h);return{update:function(u){(function(d,p,O){var g="";O.supports&&(g+="@supports (".concat(O.supports,") {")),O.media&&(g+="@media ".concat(O.media," {"));var _=O.layer!==void 0;_&&(g+="@layer".concat(O.layer.length>0?" ".concat(O.layer):""," {")),g+=O.css,_&&(g+="}"),O.media&&(g+="}"),O.supports&&(g+="}");var y=O.sourceMap;y&&typeof btoa<"u"&&(g+=`
|
|
19
|
-
/*# sourceMappingURL=data:application/json;base64,`.concat(btoa(unescape(encodeURIComponent(JSON.stringify(y))))," */")),p.styleTagTransform(g,d,p.options)})(a,h,u)},remove:function(){(function(u){if(u.parentNode===null)return!1;u.parentNode.removeChild(u)})(a)}}}},589:f=>{f.exports=function(h,a){if(a.styleSheet)a.styleSheet.cssText=h;else{for(;a.firstChild;)a.removeChild(a.firstChild);a.appendChild(document.createTextNode(h))}}},583:f=>{f.exports=n},732:f=>{f.exports=r}},s={};function l(f){var h=s[f];if(h!==void 0)return h.exports;var a=s[f]={id:f,exports:{}};return o[f](a,a.exports,l),a.exports}l.n=f=>{var h=f&&f.__esModule?()=>f.default:()=>f;return l.d(h,{a:h}),h},l.d=(f,h)=>{for(var a in h)l.o(h,a)&&!l.o(f,a)&&Object.defineProperty(f,a,{enumerable:!0,get:h[a]})},l.o=(f,h)=>Object.prototype.hasOwnProperty.call(f,h),l.r=f=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(f,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(f,"__esModule",{value:!0})},l.nc=void 0;var c={};return(()=>{l.r(c),l.d(c,{Button:()=>lr,ConfirmationModal:()=>zL,HISETabs:()=>tR,KeyValPair:()=>nR,MessageStripe:()=>Ur,ResourceEditor:()=>xS});var f,h,a=l(583),u=l.n(a);function d(i){var v=i.pathname,b=v===void 0?"/":v,x=i.search,D=x===void 0?"":x,B=i.hash,G=B===void 0?"":B;return D&&D!=="?"&&(b+=D.charAt(0)==="?"?D:"?"+D),G&&G!=="#"&&(b+=G.charAt(0)==="#"?G:"#"+G),b}function p(i){var v={};if(i){var b=i.indexOf("#");b>=0&&(v.hash=i.substr(b),i=i.substr(0,b));var x=i.indexOf("?");x>=0&&(v.search=i.substr(x),i=i.substr(0,x)),i&&(v.pathname=i)}return v}function O(i,v){throw new Error(v)}(h=f||(f={})).Pop="POP",h.Push="PUSH",h.Replace="REPLACE";const g=(0,a.createContext)(null),_=(0,a.createContext)(null),y=(0,a.createContext)({outlet:null,matches:[]});function w(){return(0,a.useContext)(_)!=null}function E(){return w()||O(),(0,a.useContext)(_).location}function m(i){let{matches:v}=(0,a.useContext)(y),{pathname:b}=E(),x=JSON.stringify(v.map((D=>D.pathnameBase)));return(0,a.useMemo)((()=>S(i,JSON.parse(x),b)),[i,x,b])}function S(i,v,b){let x,D=typeof i=="string"?p(i):i,B=i===""||D.pathname===""?"/":D.pathname;if(B==null)x=b;else{let L=v.length-1;if(B.startsWith("..")){let P=B.split("/");for(;P[0]==="..";)P.shift(),L-=1;D.pathname=P.join("/")}x=L>=0?v[L]:"/"}let G=(function(L,P){P===void 0&&(P="/");let{pathname:T,search:te="",hash:oe=""}=typeof L=="string"?p(L):L;return{pathname:T?T.startsWith("/")?T:(function(J,Y){let ie=Y.replace(/\/+$/,"").split("/");return J.split("/").forEach((ae=>{ae===".."?ie.length>1&&ie.pop():ae!=="."&&ie.push(ae)})),ie.length>1?ie.join("/"):"/"})(T,P):P,search:N(te),hash:M(oe)}})(D,x);return B&&B!=="/"&&B.endsWith("/")&&!G.pathname.endsWith("/")&&(G.pathname+="/"),G}const C=i=>i.join("/").replace(/\/\/+/g,"/"),N=i=>i&&i!=="?"?i.startsWith("?")?i:"?"+i:"",M=i=>i&&i!=="#"?i.startsWith("#")?i:"#"+i:"";function j(){return j=Object.assign||function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},j.apply(this,arguments)}const I=["onClick","reloadDocument","replace","state","target","to"],A=(0,a.forwardRef)((function(i,v){let{onClick:b,reloadDocument:x,replace:D=!1,state:B,target:G,to:L}=i,P=(function(oe,V){if(oe==null)return{};var J,Y,ie={},ae=Object.keys(oe);for(Y=0;Y<ae.length;Y++)J=ae[Y],V.indexOf(J)>=0||(ie[J]=oe[J]);return ie})(i,I),T=(function(oe){w()||O();let{basename:V,navigator:J}=(0,a.useContext)(g),{hash:Y,pathname:ie,search:ae}=m(oe),ce=ie;if(V!=="/"){let fe=(function(he){return he===""||he.pathname===""?"/":typeof he=="string"?p(he).pathname:he.pathname})(oe),ve=fe!=null&&fe.endsWith("/");ce=ie==="/"?V+(ve?"/":""):C([V,ie])}return J.createHref({pathname:ce,search:ae,hash:Y})})(L),te=(function(oe,V){let{target:J,replace:Y,state:ie}=V===void 0?{}:V,ae=(function(){w()||O();let{basename:ve,navigator:he}=(0,a.useContext)(g),{matches:ye}=(0,a.useContext)(y),{pathname:be}=E(),_e=JSON.stringify(ye.map((Te=>Te.pathnameBase))),xe=(0,a.useRef)(!1);return(0,a.useEffect)((()=>{xe.current=!0})),(0,a.useCallback)((function(Te,De){if(De===void 0&&(De={}),!xe.current)return;if(typeof Te=="number")return void he.go(Te);let Le=S(Te,JSON.parse(_e),be);ve!=="/"&&(Le.pathname=C([ve,Le.pathname])),(De.replace?he.replace:he.push)(Le,De.state)}),[ve,he,_e,be])})(),ce=E(),fe=m(oe);return(0,a.useCallback)((ve=>{if(!(ve.button!==0||J&&J!=="_self"||(function(he){return!!(he.metaKey||he.altKey||he.ctrlKey||he.shiftKey)})(ve))){ve.preventDefault();let he=!!Y||d(ce)===d(fe);ae(oe,{replace:he,state:ie})}}),[ce,ae,fe,Y,ie,J,oe])})(L,{replace:D,state:B,target:G});return(0,a.createElement)("a",j({},P,{href:T,onClick:function(oe){b&&b(oe),oe.defaultPrevented||x||te(oe)},ref:v,target:G}))}));var q,R=l(697),k=l.n(R),F=l(184),U=l.n(F);function ne(i){return ne=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},ne(i)}function ue(i){document.body.style.paddingRight=i>0?"".concat(i,"px"):null}function K(){var i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",v=arguments.length>1&&arguments[1]!==void 0?arguments[1]:q;return v?i.split(" ").map((function(b){return v[b]||b})).join(" "):i}function W(i,v){var b={};return Object.keys(i).forEach((function(x){v.indexOf(x)===-1&&(b[x]=i[x])})),b}var z={};function Q(i){z[i]||(typeof console<"u"&&console.error(i),z[i]=!0)}var re=(typeof window>"u"?"undefined":ne(window))==="object"&&window.Element||function(){},Z=k().oneOfType([k().string,k().func,function(i,v,b){if(!(i[v]instanceof re))return new Error("Invalid prop `"+v+"` supplied to `"+b+"`. Expected prop to be an instance of Element. Validation failed.")},k().shape({current:k().any})]),X=k().oneOfType([k().func,k().string,k().shape({$$typeof:k().symbol,render:k().func}),k().arrayOf(k().oneOfType([k().func,k().string,k().shape({$$typeof:k().symbol,render:k().func})]))]),H=["in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","onEnter","onEntering","onEntered","onExit","onExiting","onExited"],ee={esc:27,space:32,enter:13,tab:9,up:38,down:40,home:36,end:35,n:78,p:80},le=!(typeof window>"u"||!window.document||!window.document.createElement);function de(i){if((function(b){return!(!b||ne(b)!=="object")&&"current"in b})(i))return i.current;if((function(b){if(!(function(D){var B=ne(D);return D!=null&&(B==="object"||B==="function")})(b))return!1;var x=(function(D){return D==null?D===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(D)})(b);return x==="[object Function]"||x==="[object AsyncFunction]"||x==="[object GeneratorFunction]"||x==="[object Proxy]"})(i))return i();if(typeof i=="string"&&le){var v=document.querySelectorAll(i);if(v.length||(v=document.querySelectorAll("#".concat(i))),!v.length)throw new Error("The target '".concat(i,"' could not be identified in the dom, tip: check spelling"));return v}return i}function pe(i){return i!==null&&(Array.isArray(i)||le&&typeof i.length=="number")}var Ee=["a[href]","area[href]","input:not([disabled]):not([type=hidden])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","object","embed","[tabindex]:not(.modal):not(.offcanvas)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],Ie=["className","cssModule","variant","innerRef"];function Pe(){return Pe=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Pe.apply(this,arguments)}function Ae(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function Se(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}var Ge={active:k().bool,"aria-label":k().string,onClick:k().func,variant:k().oneOf(["white"]),className:k().string,cssModule:k().object,innerRef:k().oneOfType([k().object,k().string,k().func])};function Oe(i){var v=i.className,b=(i.cssModule,i.variant),x=i.innerRef,D=(function(G,L){if(G==null)return{};var P,T,te=(function(V,J){if(V==null)return{};var Y,ie,ae={},ce=Object.keys(V);for(ie=0;ie<ce.length;ie++)Y=ce[ie],J.indexOf(Y)>=0||(ae[Y]=V[Y]);return ae})(G,L);if(Object.getOwnPropertySymbols){var oe=Object.getOwnPropertySymbols(G);for(T=0;T<oe.length;T++)P=oe[T],L.indexOf(P)>=0||Object.prototype.propertyIsEnumerable.call(G,P)&&(te[P]=G[P])}return te})(i,Ie),B=K(U()(v,"btn-close",b&&"btn-close-".concat(b)));return u().createElement("button",Pe({ref:x,type:"button",className:B},(function(G){for(var L=1;L<arguments.length;L++){var P=arguments[L]!=null?arguments[L]:{};L%2?Ae(Object(P),!0).forEach((function(T){Se(G,T,P[T])})):Object.getOwnPropertyDescriptors?Object.defineProperties(G,Object.getOwnPropertyDescriptors(P)):Ae(Object(P)).forEach((function(T){Object.defineProperty(G,T,Object.getOwnPropertyDescriptor(P,T))}))}return G})({"aria-label":"close"},D)))}Oe.propTypes=Ge;const ge=Oe;var me=["active","aria-label","block","className","close","cssModule","color","outline","size","tag","innerRef"];function ke(){return ke=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},ke.apply(this,arguments)}var Ne={active:k().bool,"aria-label":k().string,block:k().bool,children:k().node,className:k().string,cssModule:k().object,close:k().bool,color:k().string,disabled:k().bool,innerRef:k().oneOfType([k().object,k().func,k().string]),onClick:k().func,outline:k().bool,size:k().string,tag:X};function we(i){var v=(0,a.useCallback)((function(fe){if(!i.disabled)return i.onClick?i.onClick(fe):void 0;fe.preventDefault()}),[i.onClick,i.disabled]),b=i.active,x=i["aria-label"],D=i.block,B=i.className,G=i.close,L=i.cssModule,P=i.color,T=P===void 0?"secondary":P,te=i.outline,oe=i.size,V=i.tag,J=V===void 0?"button":V,Y=i.innerRef,ie=(function(fe,ve){if(fe==null)return{};var he,ye,be=(function(xe,Me){if(xe==null)return{};var Te,De,Le={},Re=Object.keys(xe);for(De=0;De<Re.length;De++)Te=Re[De],Me.indexOf(Te)>=0||(Le[Te]=xe[Te]);return Le})(fe,ve);if(Object.getOwnPropertySymbols){var _e=Object.getOwnPropertySymbols(fe);for(ye=0;ye<_e.length;ye++)he=_e[ye],ve.indexOf(he)>=0||Object.prototype.propertyIsEnumerable.call(fe,he)&&(be[he]=fe[he])}return be})(i,me);if(G)return u().createElement(ge,ie);var ae="btn".concat(te?"-outline":"","-").concat(T),ce=K(U()(B,"btn",ae,!!oe&&"btn-".concat(oe),!!D&&"d-block w-100",{active:b,disabled:i.disabled}),L);return ie.href&&J==="button"&&(J="a"),u().createElement(J,ke({type:J==="button"&&ie.onClick?"button":void 0},ie,{className:ce,ref:Y,onClick:v,"aria-label":x}))}we.propTypes=Ne;const qe=we;var je=a.createContext(),ze=a.createContext();function lt(i){var v=i.children,b=a.useState(null),x=b[0],D=b[1],B=a.useRef(!1);a.useEffect((function(){return function(){B.current=!0}}),[]);var G=a.useCallback((function(L){B.current||D(L)}),[]);return a.createElement(je.Provider,{value:x},a.createElement(ze.Provider,{value:G},v))}var pt=u().createContext({}),Ze=u().createContext({});function It(i){return It=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},It(i)}var We=["className","cssModule","direction","isOpen","group","size","nav","setActiveFromChild","active","tag","menuRole"];function it(){return it=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},it.apply(this,arguments)}function Ot(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}function kt(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function Nt(i,v){return Nt=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},Nt(i,v)}function Ft(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function gn(i){return gn=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},gn(i)}var qo={a11y:k().bool,disabled:k().bool,direction:k().oneOf(["up","down","start","end","left","right"]),group:k().bool,isOpen:k().bool,nav:k().bool,active:k().bool,size:k().string,tag:X,toggle:k().func,children:k().node,className:k().string,cssModule:k().object,dropup:k().bool,inNavbar:k().bool,setActiveFromChild:k().bool,menuRole:k().oneOf(["listbox","menu"])},Lo=[ee.space,ee.enter,ee.up,ee.down,ee.end,ee.home],yn=(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&Nt(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=gn(x);if(D){var T=gn(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(It(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ft(te)})(this,L)});function G(L){var P;return(function(T,te){if(!(T instanceof te))throw new TypeError("Cannot call a class as a function")})(this,G),(P=B.call(this,L)).addEvents=P.addEvents.bind(Ft(P)),P.handleDocumentClick=P.handleDocumentClick.bind(Ft(P)),P.handleKeyDown=P.handleKeyDown.bind(Ft(P)),P.removeEvents=P.removeEvents.bind(Ft(P)),P.toggle=P.toggle.bind(Ft(P)),P.handleMenuRef=P.handleMenuRef.bind(Ft(P)),P.handleToggleRef=P.handleToggleRef.bind(Ft(P)),P.containerRef=u().createRef(),P.menuRef=u().createRef(),P.toggleRef=u().createRef(),P}return v=G,b=[{key:"componentDidMount",value:function(){this.handleProps()}},{key:"componentDidUpdate",value:function(L){this.props.isOpen!==L.isOpen&&this.handleProps()}},{key:"componentWillUnmount",value:function(){this.removeEvents()}},{key:"handleMenuRef",value:function(L){this.menuRef.current=L}},{key:"handleToggleRef",value:function(L){this.toggleRef.current=L}},{key:"handleDocumentClick",value:function(L){if(!L||L.which!==3&&(L.type!=="keyup"||L.which===ee.tab)){var P=this.getContainer(),T=this.getMenu(),te=this.getToggle().contains(L.target),oe=T&&T.contains(L.target)&&T!==L.target,V=!1;P&&(V=P.classList.contains("input-group")&&P.classList.contains("dropdown")&&L.target.tagName==="INPUT"),(!(te&&!V||oe)||L.type==="keyup"&&L.which!==ee.tab)&&this.toggle(L)}}},{key:"handleKeyDown",value:function(L){var P=this,T=L.target.getAttribute("role")==="menuitem"||L.target.getAttribute("role")==="option",te=this.getMenuCtrl()===L.target,oe=ee.tab===L.which;if(!(/input|textarea/i.test(L.target.tagName)||oe&&!this.props.a11y||oe&&!T&&!te||((Lo.indexOf(L.which)!==-1||L.which>=48&&L.which<=90)&&L.preventDefault(),this.props.disabled))){if(te)if([ee.space,ee.enter,ee.up,ee.down].indexOf(L.which)>-1)this.props.isOpen||this.toggle(L),setTimeout((function(){var ve;return(ve=P.getMenuItems()[0])===null||ve===void 0?void 0:ve.focus()}));else if(this.props.isOpen&&oe){var V;L.preventDefault(),(V=this.getMenuItems()[0])===null||V===void 0||V.focus()}else this.props.isOpen&&L.which===ee.esc&&this.toggle(L);if(this.props.isOpen&&T){if([ee.tab,ee.esc].indexOf(L.which)>-1)this.toggle(L),this.getMenuCtrl().focus();else if([ee.space,ee.enter].indexOf(L.which)>-1)L.target.click(),this.getMenuCtrl().focus();else if([ee.down,ee.up].indexOf(L.which)>-1||[ee.n,ee.p].indexOf(L.which)>-1&&L.ctrlKey){var J=this.getMenuItems(),Y=J.indexOf(L.target);ee.up===L.which||ee.p===L.which&&L.ctrlKey?Y=Y!==0?Y-1:J.length-1:(ee.down===L.which||ee.n===L.which&&L.ctrlKey)&&(Y=Y===J.length-1?0:Y+1),J[Y].focus()}else if(ee.end===L.which){var ie=this.getMenuItems();ie[ie.length-1].focus()}else if(ee.home===L.which)this.getMenuItems()[0].focus();else if(L.which>=48&&L.which<=90){for(var ae=this.getMenuItems(),ce=String.fromCharCode(L.which).toLowerCase(),fe=0;fe<ae.length;fe+=1)if((ae[fe].textContent&&ae[fe].textContent[0].toLowerCase())===ce){ae[fe].focus();break}}}}}},{key:"handleProps",value:function(){this.props.isOpen?this.addEvents():this.removeEvents()}},{key:"getContextValue",value:function(){return{toggle:this.toggle,isOpen:this.props.isOpen,direction:this.props.direction==="down"&&this.props.dropup?"up":this.props.direction,inNavbar:this.props.inNavbar,disabled:this.props.disabled,onMenuRef:this.handleMenuRef,onToggleRef:this.handleToggleRef,menuRole:this.props.menuRole}}},{key:"getContainer",value:function(){return this.containerRef.current}},{key:"getMenu",value:function(){return this.menuRef.current}},{key:"getToggle",value:function(){return this.toggleRef.current}},{key:"getMenuCtrl",value:function(){return this._$menuCtrl||(this._$menuCtrl=this.getToggle()),this._$menuCtrl}},{key:"getItemType",value:function(){return this.props.menuRole==="listbox"?"option":"menuitem"}},{key:"getMenuItems",value:function(){var L=this.getMenu()||this.getContainer();return[].slice.call(L.querySelectorAll('[role="'.concat(this.getItemType(),'"]')))}},{key:"addEvents",value:function(){var L=this;["click","touchstart","keyup"].forEach((function(P){return document.addEventListener(P,L.handleDocumentClick,!0)}))}},{key:"removeEvents",value:function(){var L=this;["click","touchstart","keyup"].forEach((function(P){return document.removeEventListener(P,L.handleDocumentClick,!0)}))}},{key:"toggle",value:function(L){return this.props.disabled?L&&L.preventDefault():this.props.toggle(L)}},{key:"render",value:function(){var L,P=this,T=W(this.props,["toggle","disabled","inNavbar","a11y"]),te=T.className,oe=T.cssModule,V=T.direction,J=T.isOpen,Y=T.group,ie=T.size,ae=T.nav,ce=T.setActiveFromChild,fe=T.active,ve=T.tag,he=(T.menuRole,(function(xe,Me){if(xe==null)return{};var Te,De,Le=(function(He,Ve){if(He==null)return{};var Ue,at,Qe={},ut=Object.keys(He);for(at=0;at<ut.length;at++)Ue=ut[at],Ve.indexOf(Ue)>=0||(Qe[Ue]=He[Ue]);return Qe})(xe,Me);if(Object.getOwnPropertySymbols){var Re=Object.getOwnPropertySymbols(xe);for(De=0;De<Re.length;De++)Te=Re[De],Me.indexOf(Te)>=0||Object.prototype.propertyIsEnumerable.call(xe,Te)&&(Le[Te]=xe[Te])}return Le})(T,We)),ye=ve||(ae?"li":"div"),be=!1;ce&&u().Children.map(this.props.children[1].props.children,(function(xe){xe&&xe.props.active&&(be=!0)}));var _e=K(U()(te,!(!ae||!fe)&&"active",!(!ce||!be)&&"active",(Ot(L={"btn-group":Y},"btn-group-".concat(ie),!!ie),Ot(L,"dropdown",!Y),Ot(L,"dropup",V==="up"),Ot(L,"dropstart",V==="start"||V==="left"),Ot(L,"dropend",V==="end"||V==="right"),Ot(L,"show",J),Ot(L,"nav-item",ae),L)),oe);return this.context.insideInputGroup?u().createElement(pt.Provider,{value:this.getContextValue()},u().createElement(lt,null,u().Children.map(this.props.children,(function(xe){return u().cloneElement(xe,{onKeyDown:P.handleKeyDown})})))):u().createElement(pt.Provider,{value:this.getContextValue()},u().createElement(lt,null,u().createElement(ye,it({},he,Ot({},typeof ye=="string"?"ref":"innerRef",this.containerRef),{onKeyDown:this.handleKeyDown,className:_e}))))}}],b&&kt(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(u().Component);yn.propTypes=qo,yn.defaultProps={a11y:!0,isOpen:!1,direction:"down",nav:!1,active:!1,inNavbar:!1,setActiveFromChild:!1},yn.contextType=Ze;const Ro=yn;function Ir(){return Ir=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Ir.apply(this,arguments)}var Pn={children:k().node};function fa(i){return u().createElement(Ro,Ir({group:!0},i))}fa.propTypes=Pn;const da=fa;function Do(i){return Do=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},Do(i)}function ha(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function Kh(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}function jo(){return jo=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},jo.apply(this,arguments)}function Wh(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function Fo(i,v){return Fo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},Fo(i,v)}function pa(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function Mr(i){return Mr=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},Mr(i)}var Yh=["defaultOpen"];(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&Fo(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=Mr(x);if(D){var T=Mr(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(Do(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return pa(te)})(this,L)});function G(L){var P;return(function(T,te){if(!(T instanceof te))throw new TypeError("Cannot call a class as a function")})(this,G),(P=B.call(this,L)).state={isOpen:L.defaultOpen||!1},P.toggle=P.toggle.bind(pa(P)),P}return v=G,(b=[{key:"toggle",value:function(){this.setState((function(L){return{isOpen:!L.isOpen}}))}},{key:"render",value:function(){return u().createElement(da,jo({isOpen:this.state.isOpen,toggle:this.toggle},W(this.props,Yh)))}}])&&Wh(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(a.Component).propTypes=(function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?ha(Object(b),!0).forEach((function(x){Kh(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):ha(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i})({defaultOpen:k().bool},da.propTypes);var Zh=l(379),qr=l.n(Zh),va=l(795),Lr=l.n(va),Xh=l(569),Rr=l.n(Xh),Qh=l(565),Dr=l.n(Qh),Jh=l(216),jr=l.n(Jh),ep=l(589),sr=l.n(ep),Fr=l(953),$n={};$n.styleTagTransform=sr(),$n.setAttributes=Dr(),$n.insert=Rr().bind(null,"head"),$n.domAPI=Lr(),$n.insertStyleElement=jr(),qr()(Fr.Z,$n),Fr.Z&&Fr.Z.locals&&Fr.Z.locals;var tp=["href","to","icon","pending","children","target","download","noText"],ga=function(i){var v=i.href,b=i.to,x=i.icon,D=i.pending,B=i.children,G=i.target,L=i.download,P=i.noText,T=(function(oe,V){if(oe==null)return{};var J,Y,ie=(function(ce,fe){if(ce==null)return{};var ve,he,ye={},be=Object.keys(ce);for(he=0;he<be.length;he++)ve=be[he],fe.indexOf(ve)>=0||(ye[ve]=ce[ve]);return ye})(oe,V);if(Object.getOwnPropertySymbols){var ae=Object.getOwnPropertySymbols(oe);for(Y=0;Y<ae.length;Y++)J=ae[Y],V.indexOf(J)>=0||Object.prototype.propertyIsEnumerable.call(oe,J)&&(ie[J]=oe[J])}return ie})(i,tp);T.className="".concat(i.className," button-component");var te=u().createElement(u().Fragment,null,D&&u().createElement("i",{className:"fas fa-spinner fa-spin"}),x&&!D&&u().createElement("i",{className:"fas ".concat(x," ").concat(P?"no-text":"")}),B);return T.disabled=T.disabled||D,b&&!T.disabled?u().createElement(A,{to:b,target:G},u().createElement(qe,T,te)):v?u().createElement("a",{href:v,target:G,download:L,rel:"noopener noreferrer"},u().createElement(qe,T,te)):u().createElement(qe,T,te)};ga.defaultProps={active:!1,"aria-label":"",block:!1,color:"secondary",disabled:!1,outline:!1,icon:"",pending:!1,className:"",to:"",href:"",target:"_self",download:!1,children:null};const lr=ga;var ya=l(732),Hn=l.n(ya);function Bo(i){return Bo=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},Bo(i)}function np(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function ur(i,v){return ur=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},ur(i,v)}function ma(i){return ma=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},ma(i)}var mL={children:k().node.isRequired,node:k().any},XO=(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&ur(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=ma(x);if(D){var T=ma(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(Bo(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(V){if(V===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return V})(te)})(this,L)});function G(){return(function(L,P){if(!(L instanceof P))throw new TypeError("Cannot call a class as a function")})(this,G),B.apply(this,arguments)}return v=G,(b=[{key:"componentWillUnmount",value:function(){this.defaultNode&&document.body.removeChild(this.defaultNode),this.defaultNode=null}},{key:"render",value:function(){return le?(this.props.node||this.defaultNode||(this.defaultNode=document.createElement("div"),document.body.appendChild(this.defaultNode)),Hn().createPortal(this.props.children,this.props.node||this.defaultNode)):null}}])&&np(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(u().Component);XO.propTypes=mL;const bL=XO;function QO(i,v){if(i==null)return{};var b,x,D={},B=Object.keys(i);for(x=0;x<B.length;x++)b=B[x],v.indexOf(b)>=0||(D[b]=i[b]);return D}function ba(i,v){return ba=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},ba(i,v)}function JO(i,v){i.prototype=Object.create(v.prototype),i.prototype.constructor=i,ba(i,v)}const eE=u().createContext(null);var zo="unmounted",cr="exited",fr="entering",Br="entered",rp="exiting",In=(function(i){function v(x,D){var B;B=i.call(this,x,D)||this;var G,L=D&&!D.isMounting?x.enter:x.appear;return B.appearStatus=null,x.in?L?(G=cr,B.appearStatus=fr):G=Br:G=x.unmountOnExit||x.mountOnEnter?zo:cr,B.state={status:G},B.nextCallback=null,B}JO(v,i),v.getDerivedStateFromProps=function(x,D){return x.in&&D.status===zo?{status:cr}:null};var b=v.prototype;return b.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},b.componentDidUpdate=function(x){var D=null;if(x!==this.props){var B=this.state.status;this.props.in?B!==fr&&B!==Br&&(D=fr):B!==fr&&B!==Br||(D=rp)}this.updateStatus(!1,D)},b.componentWillUnmount=function(){this.cancelNextCallback()},b.getTimeouts=function(){var x,D,B,G=this.props.timeout;return x=D=B=G,G!=null&&typeof G!="number"&&(x=G.exit,D=G.enter,B=G.appear!==void 0?G.appear:D),{exit:x,enter:D,appear:B}},b.updateStatus=function(x,D){if(x===void 0&&(x=!1),D!==null)if(this.cancelNextCallback(),D===fr){if(this.props.unmountOnExit||this.props.mountOnEnter){var B=this.props.nodeRef?this.props.nodeRef.current:Hn().findDOMNode(this);B&&(function(G){G.scrollTop})(B)}this.performEnter(x)}else this.performExit();else this.props.unmountOnExit&&this.state.status===cr&&this.setState({status:zo})},b.performEnter=function(x){var D=this,B=this.props.enter,G=this.context?this.context.isMounting:x,L=this.props.nodeRef?[G]:[Hn().findDOMNode(this),G],P=L[0],T=L[1],te=this.getTimeouts(),oe=G?te.appear:te.enter;x||B?(this.props.onEnter(P,T),this.safeSetState({status:fr},(function(){D.props.onEntering(P,T),D.onTransitionEnd(oe,(function(){D.safeSetState({status:Br},(function(){D.props.onEntered(P,T)}))}))}))):this.safeSetState({status:Br},(function(){D.props.onEntered(P)}))},b.performExit=function(){var x=this,D=this.props.exit,B=this.getTimeouts(),G=this.props.nodeRef?void 0:Hn().findDOMNode(this);D?(this.props.onExit(G),this.safeSetState({status:rp},(function(){x.props.onExiting(G),x.onTransitionEnd(B.exit,(function(){x.safeSetState({status:cr},(function(){x.props.onExited(G)}))}))}))):this.safeSetState({status:cr},(function(){x.props.onExited(G)}))},b.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},b.safeSetState=function(x,D){D=this.setNextCallback(D),this.setState(x,D)},b.setNextCallback=function(x){var D=this,B=!0;return this.nextCallback=function(G){B&&(B=!1,D.nextCallback=null,x(G))},this.nextCallback.cancel=function(){B=!1},this.nextCallback},b.onTransitionEnd=function(x,D){this.setNextCallback(D);var B=this.props.nodeRef?this.props.nodeRef.current:Hn().findDOMNode(this),G=x==null&&!this.props.addEndListener;if(B&&!G){if(this.props.addEndListener){var L=this.props.nodeRef?[this.nextCallback]:[B,this.nextCallback],P=L[0],T=L[1];this.props.addEndListener(P,T)}x!=null&&setTimeout(this.nextCallback,x)}else setTimeout(this.nextCallback,0)},b.render=function(){var x=this.state.status;if(x===zo)return null;var D=this.props,B=D.children,G=(D.in,D.mountOnEnter,D.unmountOnExit,D.appear,D.enter,D.exit,D.timeout,D.addEndListener,D.onEnter,D.onEntering,D.onEntered,D.onExit,D.onExiting,D.onExited,D.nodeRef,QO(D,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return u().createElement(eE.Provider,{value:null},typeof B=="function"?B(x,G):u().cloneElement(u().Children.only(B),G))},v})(u().Component);function zr(){}In.contextType=eE,In.propTypes={},In.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:zr,onEntering:zr,onEntered:zr,onExit:zr,onExiting:zr,onExited:zr},In.UNMOUNTED=zo,In.EXITED=cr,In.ENTERING=fr,In.ENTERED=Br,In.EXITING=rp;const op=In;var _L=["tag","baseClass","baseClassActive","className","cssModule","children","innerRef"];function _a(){return _a=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},_a.apply(this,arguments)}function tE(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function $o(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?tE(Object(b),!0).forEach((function(x){wL(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):tE(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i}function wL(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}var OL=$o($o({},op.propTypes),{},{children:k().oneOfType([k().arrayOf(k().node),k().node]),tag:X,baseClass:k().string,baseClassActive:k().string,className:k().string,cssModule:k().object,innerRef:k().oneOfType([k().object,k().string,k().func])}),nE=$o($o({},op.defaultProps),{},{timeout:150,appear:!0,enter:!0,exit:!0,in:!0});function ip(i){var v=(0,a.useRef)(null),b=i.tag,x=b===void 0?"div":b,D=i.baseClass,B=D===void 0?"fade":D,G=i.baseClassActive,L=G===void 0?"show":G,P=i.className,T=i.cssModule,te=i.children,oe=i.innerRef,V=oe===void 0?v:oe,J=(function(ae,ce){if(ae==null)return{};var fe,ve,he=(function(be,_e){if(be==null)return{};var xe,Me,Te={},De=Object.keys(be);for(Me=0;Me<De.length;Me++)xe=De[Me],_e.indexOf(xe)>=0||(Te[xe]=be[xe]);return Te})(ae,ce);if(Object.getOwnPropertySymbols){var ye=Object.getOwnPropertySymbols(ae);for(ve=0;ve<ye.length;ve++)fe=ye[ve],ce.indexOf(fe)>=0||Object.prototype.propertyIsEnumerable.call(ae,fe)&&(he[fe]=ae[fe])}return he})(i,_L),Y=(function(ae,ce){for(var fe,ve=Array.isArray(ce)?ce:[ce],he=ve.length,ye={};he>0;)ye[fe=ve[he-=1]]=ae[fe];return ye})($o({defaultProps:nE},J),H),ie=W(J,H);return u().createElement(op,_a({nodeRef:V},Y),(function(ae){var ce=ae==="entered",fe=K(U()(P,B,ce&&L),T);return u().createElement(x,_a({className:fe},ie,{ref:V}),te)}))}ip.propTypes=OL,ip.defaultProps=nE;const Mn=ip;function ap(i){return ap=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},ap(i)}function rE(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function $r(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?rE(Object(b),!0).forEach((function(x){Hr(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):rE(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i}function Ho(){return Ho=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Ho.apply(this,arguments)}function Hr(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}function EL(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function sp(i,v){return sp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},sp(i,v)}function Jt(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function wa(i){return wa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},wa(i)}function Oa(){}var oE=k().shape(Mn.propTypes),iE={autoFocus:k().bool,backdrop:k().oneOfType([k().bool,k().oneOf(["static"])]),backdropClassName:k().string,backdropTransition:oE,centered:k().bool,children:k().node,contentClassName:k().string,className:k().string,container:Z,cssModule:k().object,external:k().node,fade:k().bool,fullscreen:k().oneOfType([k().bool,k().oneOf(["sm","md","lg","xl"])]),innerRef:k().oneOfType([k().object,k().string,k().func]),isOpen:k().bool,keyboard:k().bool,labelledBy:k().string,modalClassName:k().string,modalTransition:oE,onClosed:k().func,onEnter:k().func,onExit:k().func,onOpened:k().func,returnFocusAfterClose:k().bool,role:k().string,scrollable:k().bool,size:k().string,toggle:k().func,trapFocus:k().bool,unmountOnClose:k().bool,wrapClassName:k().string,zIndex:k().oneOfType([k().number,k().string])},xL=Object.keys(iE),SL={isOpen:!1,autoFocus:!0,centered:!1,scrollable:!1,role:"dialog",backdrop:!0,keyboard:!0,zIndex:1050,fade:!0,onOpened:Oa,onClosed:Oa,modalTransition:{timeout:300},backdropTransition:{mountOnEnter:!0,timeout:150},unmountOnClose:!0,returnFocusAfterClose:!0,container:"body",trapFocus:!1},Vo=(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&sp(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=wa(x);if(D){var T=wa(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(ap(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Jt(te)})(this,L)});function G(L){var P;return(function(T,te){if(!(T instanceof te))throw new TypeError("Cannot call a class as a function")})(this,G),(P=B.call(this,L))._element=null,P._originalBodyPadding=null,P.getFocusableChildren=P.getFocusableChildren.bind(Jt(P)),P.handleBackdropClick=P.handleBackdropClick.bind(Jt(P)),P.handleBackdropMouseDown=P.handleBackdropMouseDown.bind(Jt(P)),P.handleEscape=P.handleEscape.bind(Jt(P)),P.handleStaticBackdropAnimation=P.handleStaticBackdropAnimation.bind(Jt(P)),P.handleTab=P.handleTab.bind(Jt(P)),P.onOpened=P.onOpened.bind(Jt(P)),P.onClosed=P.onClosed.bind(Jt(P)),P.manageFocusAfterClose=P.manageFocusAfterClose.bind(Jt(P)),P.clearBackdropAnimationTimeout=P.clearBackdropAnimationTimeout.bind(Jt(P)),P.trapFocus=P.trapFocus.bind(Jt(P)),P.state={isOpen:!1,showStaticBackdropAnimation:!1},P}return v=G,b=[{key:"componentDidMount",value:function(){var L=this.props,P=L.isOpen,T=L.autoFocus,te=L.onEnter;P&&(this.init(),this.setState({isOpen:!0}),T&&this.setFocus()),te&&te(),document.addEventListener("focus",this.trapFocus,!0),this._isMounted=!0}},{key:"componentDidUpdate",value:function(L,P){if(this.props.isOpen&&!L.isOpen)return this.init(),void this.setState({isOpen:!0});this.props.autoFocus&&this.state.isOpen&&!P.isOpen&&this.setFocus(),this._element&&L.zIndex!==this.props.zIndex&&(this._element.style.zIndex=this.props.zIndex)}},{key:"componentWillUnmount",value:function(){this.clearBackdropAnimationTimeout(),this.props.onExit&&this.props.onExit(),this._element&&(this.destroy(),(this.props.isOpen||this.state.isOpen)&&this.close()),document.removeEventListener("focus",this.trapFocus,!0),this._isMounted=!1}},{key:"handleBackdropClick",value:function(L){if(L.target===this._mouseDownElement){L.stopPropagation();var P=this._dialog?this._dialog.parentNode:null;if(P&&L.target===P&&this.props.backdrop==="static"&&this.handleStaticBackdropAnimation(),!this.props.isOpen||this.props.backdrop!==!0)return;P&&L.target===P&&this.props.toggle&&this.props.toggle(L)}}},{key:"handleTab",value:function(L){if(L.which===9&&!(this.modalIndex<G.openCount-1)){var P=this.getFocusableChildren(),T=P.length;if(T!==0){for(var te=this.getFocusedChild(),oe=0,V=0;V<T;V+=1)if(P[V]===te){oe=V;break}L.shiftKey&&oe===0?(L.preventDefault(),P[T-1].focus()):L.shiftKey||oe!==T-1||(L.preventDefault(),P[0].focus())}}}},{key:"handleBackdropMouseDown",value:function(L){this._mouseDownElement=L.target}},{key:"handleEscape",value:function(L){this.props.isOpen&&L.keyCode===ee.esc&&this.props.toggle&&(this.props.keyboard?(L.preventDefault(),L.stopPropagation(),this.props.toggle(L)):this.props.backdrop==="static"&&(L.preventDefault(),L.stopPropagation(),this.handleStaticBackdropAnimation()))}},{key:"handleStaticBackdropAnimation",value:function(){var L=this;this.clearBackdropAnimationTimeout(),this.setState({showStaticBackdropAnimation:!0}),this._backdropAnimationTimeout=setTimeout((function(){L.setState({showStaticBackdropAnimation:!1})}),100)}},{key:"onOpened",value:function(L,P){this.props.onOpened(),(this.props.modalTransition.onEntered||Oa)(L,P)}},{key:"onClosed",value:function(L){var P=this.props.unmountOnClose;this.props.onClosed(),(this.props.modalTransition.onExited||Oa)(L),P&&this.destroy(),this.close(),this._isMounted&&this.setState({isOpen:!1})}},{key:"setFocus",value:function(){this._dialog&&this._dialog.parentNode&&typeof this._dialog.parentNode.focus=="function"&&this._dialog.parentNode.focus()}},{key:"getFocusableChildren",value:function(){return this._element.querySelectorAll(Ee.join(", "))}},{key:"getFocusedChild",value:function(){var L,P=this.getFocusableChildren();try{L=document.activeElement}catch{L=P[0]}return L}},{key:"trapFocus",value:function(L){if(this.props.trapFocus&&this._element&&!(this._dialog&&this._dialog.parentNode===L.target||this.modalIndex<G.openCount-1)){for(var P=this.getFocusableChildren(),T=0;T<P.length;T+=1)if(P[T]===L.target)return;P.length>0&&(L.preventDefault(),L.stopPropagation(),P[0].focus())}}},{key:"init",value:function(){try{this._triggeringElement=document.activeElement}catch{this._triggeringElement=null}var L,P,T,te,oe;this._element||(this._element=document.createElement("div"),this._element.setAttribute("tabindex","-1"),this._element.style.position="relative",this._element.style.zIndex=this.props.zIndex,this._mountContainer=pe(L=de(this.props.container))?L[0]:L,this._mountContainer.appendChild(this._element)),this._originalBodyPadding=(P=window.getComputedStyle(document.body,null),parseInt(P&&P.getPropertyValue("padding-right")||0,10)),G.openCount<1&&(G.originalBodyOverflow=window.getComputedStyle(document.body).overflow),T=(function(){var V=document.createElement("div");V.style.position="absolute",V.style.top="-9999px",V.style.width="50px",V.style.height="50px",V.style.overflow="scroll",document.body.appendChild(V);var J=V.offsetWidth-V.clientWidth;return document.body.removeChild(V),J})(),te=document.querySelectorAll(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top")[0],oe=te?parseInt(te.style.paddingRight||0,10):0,document.body.clientWidth<window.innerWidth&&ue(oe+T),G.openCount===0&&(document.body.className=U()(document.body.className,K("modal-open",this.props.cssModule)),document.body.style.overflow="hidden"),this.modalIndex=G.openCount,G.openCount+=1}},{key:"destroy",value:function(){this._element&&(this._mountContainer.removeChild(this._element),this._element=null),this.manageFocusAfterClose()}},{key:"manageFocusAfterClose",value:function(){if(this._triggeringElement){var L=this.props.returnFocusAfterClose;this._triggeringElement.focus&&L&&this._triggeringElement.focus(),this._triggeringElement=null}}},{key:"close",value:function(){if(G.openCount<=1){var L=K("modal-open",this.props.cssModule),P=new RegExp("(^| )".concat(L,"( |$)"));document.body.className=document.body.className.replace(P," ").trim(),document.body.style.overflow=G.originalBodyOverflow}this.manageFocusAfterClose(),G.openCount=Math.max(0,G.openCount-1),ue(this._originalBodyPadding)}},{key:"clearBackdropAnimationTimeout",value:function(){this._backdropAnimationTimeout&&(clearTimeout(this._backdropAnimationTimeout),this._backdropAnimationTimeout=void 0)}},{key:"renderModalDialog",value:function(){var L,P=this,T=W(this.props,xL),te="modal-dialog";return u().createElement("div",Ho({},T,{className:K(U()(te,this.props.className,(L={},Hr(L,"modal-".concat(this.props.size),this.props.size),Hr(L,"".concat(te,"-centered"),this.props.centered),Hr(L,"".concat(te,"-scrollable"),this.props.scrollable),Hr(L,"modal-fullscreen",this.props.fullscreen===!0),Hr(L,"modal-fullscreen-".concat(this.props.fullscreen,"-down"),typeof this.props.fullscreen=="string"),L)),this.props.cssModule),role:"document",ref:function(oe){P._dialog=oe}}),u().createElement("div",{className:K(U()("modal-content",this.props.contentClassName),this.props.cssModule)},this.props.children))}},{key:"render",value:function(){var L=this.props.unmountOnClose;if(this._element&&(this.state.isOpen||!L)){var P=!!this._element&&!this.state.isOpen&&!L;this._element.style.display=P?"none":"block";var T=this.props,te=T.wrapClassName,oe=T.modalClassName,V=T.backdropClassName,J=T.cssModule,Y=T.isOpen,ie=T.backdrop,ae=T.role,ce=T.labelledBy,fe=T.external,ve=T.innerRef,he={onClick:this.handleBackdropClick,onMouseDown:this.handleBackdropMouseDown,onKeyUp:this.handleEscape,onKeyDown:this.handleTab,style:{display:"block"},"aria-labelledby":ce,"aria-modal":!0,role:ae,tabIndex:"-1"},ye=this.props.fade,be=$r($r($r({},Mn.defaultProps),this.props.modalTransition),{},{baseClass:ye?this.props.modalTransition.baseClass:"",timeout:ye?this.props.modalTransition.timeout:0}),_e=$r($r($r({},Mn.defaultProps),this.props.backdropTransition),{},{baseClass:ye?this.props.backdropTransition.baseClass:"",timeout:ye?this.props.backdropTransition.timeout:0}),xe=ie&&(ye?u().createElement(Mn,Ho({},_e,{in:Y&&!!ie,cssModule:J,className:K(U()("modal-backdrop",V),J)})):u().createElement("div",{className:K(U()("modal-backdrop","show",V),J)}));return u().createElement(bL,{node:this._element},u().createElement("div",{className:K(te)},u().createElement(Mn,Ho({},he,be,{in:Y,onEntered:this.onOpened,onExited:this.onClosed,cssModule:J,className:K(U()("modal",oe,this.state.showStaticBackdropAnimation&&"modal-static"),J),innerRef:ve}),fe,this.renderModalDialog()),xe))}return null}}],b&&EL(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(u().Component);Vo.propTypes=iE,Vo.defaultProps=SL,Vo.openCount=0,Vo.originalBodyOverflow=null;const kL=Vo;var NL=["className","cssModule","children","toggle","tag","wrapTag","closeAriaLabel","close"];function lp(){return lp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},lp.apply(this,arguments)}var TL={children:k().node,className:k().string,close:k().object,closeAriaLabel:k().string,cssModule:k().object,tag:X,toggle:k().func,wrapTag:X};function aE(i){var v,b=i.className,x=i.cssModule,D=i.children,B=i.toggle,G=i.tag,L=G===void 0?"h5":G,P=i.wrapTag,T=P===void 0?"div":P,te=i.closeAriaLabel,oe=te===void 0?"Close":te,V=i.close,J=(function(ie,ae){if(ie==null)return{};var ce,fe,ve=(function(ye,be){if(ye==null)return{};var _e,xe,Me={},Te=Object.keys(ye);for(xe=0;xe<Te.length;xe++)_e=Te[xe],be.indexOf(_e)>=0||(Me[_e]=ye[_e]);return Me})(ie,ae);if(Object.getOwnPropertySymbols){var he=Object.getOwnPropertySymbols(ie);for(fe=0;fe<he.length;fe++)ce=he[fe],ae.indexOf(ce)>=0||Object.prototype.propertyIsEnumerable.call(ie,ce)&&(ve[ce]=ie[ce])}return ve})(i,NL),Y=K(U()(b,"modal-header"),x);return!V&&B&&(v=u().createElement("button",{type:"button",onClick:B,className:K("btn-close",x),"aria-label":oe})),u().createElement(T,lp({},J,{className:Y}),u().createElement(L,{className:K("modal-title",x)},D),V||v)}aE.propTypes=TL;const CL=aE;var AL=["className","cssModule","tag"];function up(){return up=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},up.apply(this,arguments)}var PL={className:k().string,cssModule:k().object,tag:X};function sE(i){var v=i.className,b=i.cssModule,x=i.tag,D=x===void 0?"div":x,B=(function(L,P){if(L==null)return{};var T,te,oe=(function(J,Y){if(J==null)return{};var ie,ae,ce={},fe=Object.keys(J);for(ae=0;ae<fe.length;ae++)ie=fe[ae],Y.indexOf(ie)>=0||(ce[ie]=J[ie]);return ce})(L,P);if(Object.getOwnPropertySymbols){var V=Object.getOwnPropertySymbols(L);for(te=0;te<V.length;te++)T=V[te],P.indexOf(T)>=0||Object.prototype.propertyIsEnumerable.call(L,T)&&(oe[T]=L[T])}return oe})(i,AL),G=K(U()(v,"modal-body"),b);return u().createElement(D,up({},B,{className:G}))}sE.propTypes=PL;const IL=sE;var ML=["className","cssModule","tag"];function cp(){return cp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},cp.apply(this,arguments)}var qL={className:k().string,cssModule:k().object,tag:X};function lE(i){var v=i.className,b=i.cssModule,x=i.tag,D=x===void 0?"div":x,B=(function(L,P){if(L==null)return{};var T,te,oe=(function(J,Y){if(J==null)return{};var ie,ae,ce={},fe=Object.keys(J);for(ae=0;ae<fe.length;ae++)ie=fe[ae],Y.indexOf(ie)>=0||(ce[ie]=J[ie]);return ce})(L,P);if(Object.getOwnPropertySymbols){var V=Object.getOwnPropertySymbols(L);for(te=0;te<V.length;te++)T=V[te],P.indexOf(T)>=0||Object.prototype.propertyIsEnumerable.call(L,T)&&(oe[T]=L[T])}return oe})(i,ML),G=K(U()(v,"modal-footer"),b);return u().createElement(D,cp({},B,{className:G}))}lE.propTypes=qL;const LL=lE;var RL=["className","closeClassName","closeAriaLabel","cssModule","tag","color","isOpen","toggle","children","transition","fade","innerRef"];function fp(){return fp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},fp.apply(this,arguments)}function uE(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function Uo(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?uE(Object(b),!0).forEach((function(x){DL(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):uE(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i}function DL(i,v,b){return v in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}var jL={children:k().node,className:k().string,closeClassName:k().string,closeAriaLabel:k().string,color:k().string,cssModule:k().object,fade:k().bool,innerRef:k().oneOfType([k().object,k().string,k().func]),isOpen:k().bool,tag:X,toggle:k().func,transition:k().shape(Mn.propTypes)};function cE(i){var v=i.className,b=i.closeClassName,x=i.closeAriaLabel,D=x===void 0?"Close":x,B=i.cssModule,G=i.tag,L=G===void 0?"div":G,P=i.color,T=P===void 0?"success":P,te=i.isOpen,oe=te===void 0||te,V=i.toggle,J=i.children,Y=i.transition,ie=Y===void 0?Uo(Uo({},Mn.defaultProps),{},{unmountOnExit:!0}):Y,ae=i.fade,ce=ae===void 0||ae,fe=i.innerRef,ve=(function(_e,xe){if(_e==null)return{};var Me,Te,De=(function(Re,He){if(Re==null)return{};var Ve,Ue,at={},Qe=Object.keys(Re);for(Ue=0;Ue<Qe.length;Ue++)Ve=Qe[Ue],He.indexOf(Ve)>=0||(at[Ve]=Re[Ve]);return at})(_e,xe);if(Object.getOwnPropertySymbols){var Le=Object.getOwnPropertySymbols(_e);for(Te=0;Te<Le.length;Te++)Me=Le[Te],xe.indexOf(Me)>=0||Object.prototype.propertyIsEnumerable.call(_e,Me)&&(De[Me]=_e[Me])}return De})(i,RL),he=K(U()(v,"alert","alert-".concat(T),{"alert-dismissible":V}),B),ye=K(U()("btn-close",b),B),be=Uo(Uo(Uo({},Mn.defaultProps),ie),{},{baseClass:ce?ie.baseClass:"",timeout:ce?ie.timeout:0});return u().createElement(Mn,fp({},ve,be,{tag:L,className:he,in:oe,role:"alert",innerRef:fe}),V?u().createElement("button",{type:"button",className:ye,"aria-label":D,onClick:V}):null,J)}cE.propTypes=jL;const FL=cE;var Ea=l(318),Vr={};function fE(i,v){(v==null||v>i.length)&&(v=i.length);for(var b=0,x=new Array(v);b<v;b++)x[b]=i[b];return x}Vr.styleTagTransform=sr(),Vr.setAttributes=Dr(),Vr.insert=Rr().bind(null,"head"),Vr.domAPI=Lr(),Vr.insertStyleElement=jr(),qr()(Ea.Z,Vr),Ea.Z&&Ea.Z.locals&&Ea.Z.locals;var dE=function(i){var v=(function(D,B){return(function(G){if(Array.isArray(G))return G})(D)||(function(G,L){var P=G==null?null:typeof Symbol<"u"&&G[Symbol.iterator]||G["@@iterator"];if(P!=null){var T,te,oe,V,J=[],Y=!0,ie=!1;try{if(oe=(P=P.call(G)).next,L!==0)for(;!(Y=(T=oe.call(P)).done)&&(J.push(T.value),J.length!==L);Y=!0);}catch(ae){ie=!0,te=ae}finally{try{if(!Y&&P.return!=null&&(V=P.return(),Object(V)!==V))return}finally{if(ie)throw te}}return J}})(D,B)||(function(G,L){if(G){if(typeof G=="string")return fE(G,L);var P=Object.prototype.toString.call(G).slice(8,-1);return P==="Object"&&G.constructor&&(P=G.constructor.name),P==="Map"||P==="Set"?Array.from(G):P==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(P)?fE(G,L):void 0}})(D,B)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
20
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,a.useState)(!1),2),b=v[0],x=v[1];return b?null:u().createElement(FL,{id:i.id,className:"message-stripe-component ".concat(i.classes," m-0"),color:i.color,fade:!1},i.dismissible&&u().createElement("button",{type:"button",className:"fas fa-times message-stripe__remove-button",onClick:function(){x(!0),i.onDismiss&&i.onDismiss()}}),i.icon&&u().createElement("i",{className:"fas ".concat(i.icon)}),i.title&&u().createElement("span",{className:"message-stripe__message ml-2 h5"},i.title),u().createElement("span",{className:"message-stripe__message"},i.message))};dE.defaultProps={dismissible:!0,onDismiss:function(){},icon:"",classes:"",title:""};const Ur=dE;var hE=function(i,v,b){return b?"".concat(b,": (").concat(i,") ").concat(v):"(".concat(i,") ").concat(v)},pE=function(i,v){return i.status?hE(i.status,i.message,v):i.Status?hE(i.Status,i.Message,v):v?"".concat(v,": ").concat(i):i};function dp(i){return dp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},dp(i)}var BL=function(i){var v=i.error;return v?v.constructor===Array?v.map((function(b){return u().createElement(Ur,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:pE(b)})})):["object","string"].includes(dp(v))?u().createElement(Ur,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:pE(v)}):void 0:null},vE=function(i){return u().createElement(kL,{id:i.id,size:i.size,className:i.className,isOpen:i.isOpen,scrollable:i.scrollable,backdrop:!i.noCancel||"static",toggle:i.onClose,onClosed:function(){i.onClosed&&i.onClosed()},onOpened:function(){i.onOpen&&i.onOpen()}},i.headerContent&&u().createElement(CL,{toggle:i.onClose},i.headerContent),u().createElement(BL,{error:i.error}),i.warning&&(Array.isArray(i.warning)?i.warning.map((function(v){return u().createElement(Ur,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:v})})):u().createElement(Ur,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:i.warning})),(i.content||i.disableSubmitMessage)&&u().createElement(IL,{className:i.bodyClassName},i.content,i.disableSubmit&&i.disableSubmitMessage&&u().createElement(Ur,{id:"cm-disable-submit-message",message:i.disableSubmitMessage,color:"danger",dismissible:!1})),u().createElement(LL,null,i.customFooter?i.customFooter:u().createElement(u().Fragment,null,!i.noCancel&&u().createElement(lr,{key:"cancel-button",onClick:i.onClose},i.cancelButtonText),!i.noSubmit&&u().createElement(lr,{key:"submit-button",color:i.submitButtonColor,pending:i.pending,onClick:i.onSubmit,disabled:i.disableSubmit},i.submitButtonText))))};vE.defaultProps={scrollable:!1,pending:!1,disableSubmit:!1,noSubmit:!1,noCancel:!1,content:null,customFooter:null,bodyClassName:"",cancelButtonText:"Cancel",submitButtonText:"Submit",submitButtonColor:"primary",error:null,warning:null,className:"",disableSubmitMessage:""};const zL=vE;var $L=["className","cssModule","tabs","pills","vertical","horizontal","justified","fill","navbar","card","tag"];function hp(){return hp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},hp.apply(this,arguments)}var HL={card:k().bool,className:k().string,cssModule:k().object,fill:k().bool,horizontal:k().oneOf(["center","end"]),justified:k().bool,navbar:k().bool,pills:k().bool,tabs:k().bool,tag:X,vertical:k().oneOfType([k().bool,k().string])};function gE(i){var v=i.className,b=i.cssModule,x=i.tabs,D=i.pills,B=i.vertical,G=B!==void 0&&B,L=i.horizontal,P=i.justified,T=i.fill,te=i.navbar,oe=i.card,V=i.tag,J=V===void 0?"ul":V,Y=(function(ae,ce){if(ae==null)return{};var fe,ve,he=(function(be,_e){if(be==null)return{};var xe,Me,Te={},De=Object.keys(be);for(Me=0;Me<De.length;Me++)xe=De[Me],_e.indexOf(xe)>=0||(Te[xe]=be[xe]);return Te})(ae,ce);if(Object.getOwnPropertySymbols){var ye=Object.getOwnPropertySymbols(ae);for(ve=0;ve<ye.length;ve++)fe=ye[ve],ce.indexOf(fe)>=0||Object.prototype.propertyIsEnumerable.call(ae,fe)&&(he[fe]=ae[fe])}return he})(i,$L),ie=K(U()(v,te?"navbar-nav":"nav",!!L&&"justify-content-".concat(L),(function(ae){return ae!==!1&&(ae===!0||ae==="xs"?"flex-column":"flex-".concat(ae,"-column"))})(G),{"nav-tabs":x,"card-header-tabs":oe&&x,"nav-pills":D,"card-header-pills":oe&&D,"nav-justified":P,"nav-fill":T}),b);return u().createElement(J,hp({},Y,{className:ie}))}gE.propTypes=HL;const VL=gE;var UL=["className","cssModule","active","tag"];function pp(){return pp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},pp.apply(this,arguments)}var GL={active:k().bool,className:k().string,cssModule:k().object,tag:X};function yE(i){var v=i.className,b=i.cssModule,x=i.active,D=i.tag,B=D===void 0?"li":D,G=(function(P,T){if(P==null)return{};var te,oe,V=(function(Y,ie){if(Y==null)return{};var ae,ce,fe={},ve=Object.keys(Y);for(ce=0;ce<ve.length;ce++)ae=ve[ce],ie.indexOf(ae)>=0||(fe[ae]=Y[ae]);return fe})(P,T);if(Object.getOwnPropertySymbols){var J=Object.getOwnPropertySymbols(P);for(oe=0;oe<J.length;oe++)te=J[oe],T.indexOf(te)>=0||Object.prototype.propertyIsEnumerable.call(P,te)&&(V[te]=P[te])}return V})(i,UL),L=K(U()(v,"nav-item",!!x&&"active"),b);return u().createElement(B,pp({},G,{className:L}))}yE.propTypes=GL;const KL=yE;function vp(i){return vp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},vp(i)}var WL=["className","cssModule","active","tag","innerRef"];function gp(){return gp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},gp.apply(this,arguments)}function YL(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function yp(i,v){return yp=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},yp(i,v)}function mE(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function xa(i){return xa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},xa(i)}var ZL={active:k().bool,className:k().string,cssModule:k().object,disabled:k().bool,href:k().any,innerRef:k().oneOfType([k().object,k().func,k().string]),onClick:k().func,tag:X},bE=(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&yp(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=xa(x);if(D){var T=xa(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(vp(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return mE(te)})(this,L)});function G(L){var P;return(function(T,te){if(!(T instanceof te))throw new TypeError("Cannot call a class as a function")})(this,G),(P=B.call(this,L)).onClick=P.onClick.bind(mE(P)),P}return v=G,(b=[{key:"onClick",value:function(L){this.props.disabled?L.preventDefault():(this.props.href==="#"&&L.preventDefault(),this.props.onClick&&this.props.onClick(L))}},{key:"render",value:function(){var L=this.props,P=L.className,T=L.cssModule,te=L.active,oe=L.tag,V=oe===void 0?"a":oe,J=L.innerRef,Y=(function(ae,ce){if(ae==null)return{};var fe,ve,he=(function(be,_e){if(be==null)return{};var xe,Me,Te={},De=Object.keys(be);for(Me=0;Me<De.length;Me++)xe=De[Me],_e.indexOf(xe)>=0||(Te[xe]=be[xe]);return Te})(ae,ce);if(Object.getOwnPropertySymbols){var ye=Object.getOwnPropertySymbols(ae);for(ve=0;ve<ye.length;ve++)fe=ye[ve],ce.indexOf(fe)>=0||Object.prototype.propertyIsEnumerable.call(ae,fe)&&(he[fe]=ae[fe])}return he})(L,WL),ie=K(U()(P,"nav-link",{disabled:Y.disabled,active:te}),T);return u().createElement(V,gp({},Y,{ref:J,onClick:this.onClick,className:ie}))}}])&&YL(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(u().Component);bE.propTypes=ZL;const XL=bE;var _E=u().createContext({});function mp(i){return mp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},mp(i)}function bp(){return bp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},bp.apply(this,arguments)}function wE(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function _p(i,v){return _p=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},_p(i,v)}function Sa(i){return Sa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},Sa(i)}var OE={tag:X,activeTab:k().any,className:k().string,cssModule:k().object},EE=(function(i){(function(P,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");P.prototype=Object.create(T&&T.prototype,{constructor:{value:P,writable:!0,configurable:!0}}),Object.defineProperty(P,"prototype",{writable:!1}),T&&_p(P,T)})(L,i);var v,b,x,D,B,G=(D=L,B=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var P,T=Sa(D);if(B){var te=Sa(this).constructor;P=Reflect.construct(T,arguments,te)}else P=T.apply(this,arguments);return(function(oe,V){if(V&&(mp(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function(J){if(J===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return J})(oe)})(this,P)});function L(P){var T;return(function(te,oe){if(!(te instanceof oe))throw new TypeError("Cannot call a class as a function")})(this,L),(T=G.call(this,P)).state={activeTab:T.props.activeTab},T}return v=L,x=[{key:"getDerivedStateFromProps",value:function(P,T){return T.activeTab!==P.activeTab?{activeTab:P.activeTab}:null}}],(b=[{key:"render",value:function(){var P=this.props,T=P.className,te=P.cssModule,oe=P.tag,V=oe===void 0?"div":oe,J=W(this.props,Object.keys(OE)),Y=K(U()("tab-content",T),te);return u().createElement(_E.Provider,{value:{activeTabId:this.state.activeTab}},u().createElement(V,bp({},J,{className:Y})))}}])&&wE(v.prototype,b),x&&wE(v,x),Object.defineProperty(v,"prototype",{writable:!1}),L})(a.Component);const QL=EE;EE.propTypes=OE;var JL=["className","cssModule","tabId","tag"];function wp(){return wp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},wp.apply(this,arguments)}var eR={tag:X,className:k().string,cssModule:k().object,tabId:k().any};function xE(i){var v=i.className,b=i.cssModule,x=i.tabId,D=i.tag,B=D===void 0?"div":D,G=(function(P,T){if(P==null)return{};var te,oe,V=(function(Y,ie){if(Y==null)return{};var ae,ce,fe={},ve=Object.keys(Y);for(ce=0;ce<ve.length;ce++)ae=ve[ce],ie.indexOf(ae)>=0||(fe[ae]=Y[ae]);return fe})(P,T);if(Object.getOwnPropertySymbols){var J=Object.getOwnPropertySymbols(P);for(oe=0;oe<J.length;oe++)te=J[oe],T.indexOf(te)>=0||Object.prototype.propertyIsEnumerable.call(P,te)&&(V[te]=P[te])}return V})(i,JL),L=function(P){return K(U()("tab-pane",v,{active:x===P}),b)};return u().createElement(_E.Consumer,null,(function(P){var T=P.activeTabId;return u().createElement(B,wp({},G,{className:L(T)}))}))}function SE(i,v){(v==null||v>i.length)&&(v=i.length);for(var b=0,x=new Array(v);b<v;b++)x[b]=i[b];return x}xE.propTypes=eR;var kE=function(i){var v=(function(B,G){return(function(L){if(Array.isArray(L))return L})(B)||(function(L,P){var T=L==null?null:typeof Symbol<"u"&&L[Symbol.iterator]||L["@@iterator"];if(T!=null){var te,oe,V,J,Y=[],ie=!0,ae=!1;try{if(V=(T=T.call(L)).next,P!==0)for(;!(ie=(te=V.call(T)).done)&&(Y.push(te.value),Y.length!==P);ie=!0);}catch(ce){ae=!0,oe=ce}finally{try{if(!ie&&T.return!=null&&(J=T.return(),Object(J)!==J))return}finally{if(ae)throw oe}}return Y}})(B,G)||(function(L,P){if(L){if(typeof L=="string")return SE(L,P);var T=Object.prototype.toString.call(L).slice(8,-1);return T==="Object"&&L.constructor&&(T=L.constructor.name),T==="Map"||T==="Set"?Array.from(L):T==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(T)?SE(L,P):void 0}})(B,G)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
21
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,a.useState)(),2),b=v[0],x=v[1];(0,a.useEffect)((function(){x(i.activeTab)}),[i.activeTab]);var D=i.tabs.filter((function(B){return!B.hideTab}));return u().createElement("div",null,u().createElement("div",{className:"container-md"},u().createElement(VL,{tabs:!0},D.map((function(B){return u().createElement(KL,{key:B.key},u().createElement(XL,{className:b===B.key?"active":"",onClick:function(){i.onChange(B.key),(function(G){b!==G&&x(G)})(B.key)}},B.label,i.enableTabClose&&u().createElement(lr,{noText:!0,color:"icon",style:{marginRight:"-0.75rem"},icon:"fas fa-times",onClick:function(G){i.onClose(B.key),G.stopPropagation()}})))})))),u().createElement(QL,{activeTab:b,className:"border-top"},D.map((function(B){return u().createElement(xE,{tabId:B.key,key:B.key},b===B.key?B.content:null)}))))};kE.defaultProps={onChange:function(){},enableTabClose:!1,onClose:function(){}};const tR=kE;var ka=l(525),Gr={};Gr.styleTagTransform=sr(),Gr.setAttributes=Dr(),Gr.insert=Rr().bind(null,"head"),Gr.domAPI=Lr(),Gr.insertStyleElement=jr(),qr()(ka.Z,Gr),ka.Z&&ka.Z.locals&&ka.Z.locals;var NE=function(i){return u().createElement("section",{className:"keyval__wrapper"},u().createElement("span",{className:"keyval__label",style:{minWidth:i.labelWidth}},i.label),u().createElement("ul",{className:"keyval__list"},i.items.map((function(v){return u().createElement("li",{key:String(v),className:"keyval__item"},v)}))))};NE.defaultProps={labelWidth:100};const nR=NE,Na=Array.isArray||function(i){return i!=null&&i.length>=0&&Object.prototype.toString.call(i)==="[object Array]"};function TE(i,v,b){return function(){if(arguments.length===0)return b();var x=arguments[arguments.length-1];if(!Na(x)){for(var D=0;D<i.length;){if(typeof x[i[D]]=="function")return x[i[D]].apply(x,Array.prototype.slice.call(arguments,0,-1));D+=1}if((function(B){return B!=null&&typeof B["@@transducer/step"]=="function"})(x))return v.apply(null,Array.prototype.slice.call(arguments,0,-1))(x)}return b.apply(this,arguments)}}const CE=function(){return this.xf["@@transducer/init"]()};function ct(i){return i!=null&&typeof i=="object"&&i["@@functional/placeholder"]===!0}function Mt(i){return function v(b){return arguments.length===0||ct(b)?v:i.apply(this,arguments)}}function en(i){return function v(b,x){switch(arguments.length){case 0:return v;case 1:return ct(b)?v:Mt((function(D){return i(b,D)}));default:return ct(b)&&ct(x)?v:ct(b)?Mt((function(D){return i(D,x)})):ct(x)?Mt((function(D){return i(b,D)})):i(b,x)}}}function AE(i){for(var v,b=[];!(v=i.next()).done;)b.push(v.value);return b}function PE(i,v,b){for(var x=0,D=b.length;x<D;){if(i(v,b[x]))return!0;x+=1}return!1}function Kr(i,v){return Object.prototype.hasOwnProperty.call(v,i)}const Op=typeof Object.is=="function"?Object.is:function(i,v){return i===v?i!==0||1/i==1/v:i!=i&&v!=v};var IE=Object.prototype.toString;const ME=(function(){return IE.call(arguments)==="[object Arguments]"?function(i){return IE.call(i)==="[object Arguments]"}:function(i){return Kr("callee",i)}})();var rR=!{toString:null}.propertyIsEnumerable("toString"),qE=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],LE=(function(){return arguments.propertyIsEnumerable("length")})(),oR=function(i,v){for(var b=0;b<i.length;){if(i[b]===v)return!0;b+=1}return!1};const RE=Mt(typeof Object.keys!="function"||LE?(function(i){if(Object(i)!==i)return[];var v,b,x=[],D=LE&&ME(i);for(v in i)!Kr(v,i)||D&&v==="length"||(x[x.length]=v);if(rR)for(b=qE.length-1;b>=0;)Kr(v=qE[b],i)&&!oR(x,v)&&(x[x.length]=v),b-=1;return x}):(function(i){return Object(i)!==i?[]:Object.keys(i)})),Ep=Mt((function(i){return i===null?"Null":i===void 0?"Undefined":Object.prototype.toString.call(i).slice(8,-1)}));function DE(i,v,b,x){var D=AE(i);function B(G,L){return xp(G,L,b.slice(),x.slice())}return!PE((function(G,L){return!PE(B,L,G)}),AE(v),D)}function xp(i,v,b,x){if(Op(i,v))return!0;var D,B,G=Ep(i);if(G!==Ep(v))return!1;if(typeof i["fantasy-land/equals"]=="function"||typeof v["fantasy-land/equals"]=="function")return typeof i["fantasy-land/equals"]=="function"&&i["fantasy-land/equals"](v)&&typeof v["fantasy-land/equals"]=="function"&&v["fantasy-land/equals"](i);if(typeof i.equals=="function"||typeof v.equals=="function")return typeof i.equals=="function"&&i.equals(v)&&typeof v.equals=="function"&&v.equals(i);switch(G){case"Arguments":case"Array":case"Object":if(typeof i.constructor=="function"&&(D=i.constructor,((B=String(D).match(/^function (\w*)/))==null?"":B[1])==="Promise"))return i===v;break;case"Boolean":case"Number":case"String":if(typeof i!=typeof v||!Op(i.valueOf(),v.valueOf()))return!1;break;case"Date":if(!Op(i.valueOf(),v.valueOf()))return!1;break;case"Error":return i.name===v.name&&i.message===v.message;case"RegExp":if(i.source!==v.source||i.global!==v.global||i.ignoreCase!==v.ignoreCase||i.multiline!==v.multiline||i.sticky!==v.sticky||i.unicode!==v.unicode)return!1}for(var L=b.length-1;L>=0;){if(b[L]===i)return x[L]===v;L-=1}switch(G){case"Map":return i.size===v.size&&DE(i.entries(),v.entries(),b.concat([i]),x.concat([v]));case"Set":return i.size===v.size&&DE(i.values(),v.values(),b.concat([i]),x.concat([v]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var P=RE(i);if(P.length!==RE(v).length)return!1;var T=b.concat([i]),te=x.concat([v]);for(L=P.length-1;L>=0;){var oe=P[L];if(!Kr(oe,v)||!xp(v[oe],i[oe],T,te))return!1;L-=1}return!0}const jE=en((function(i,v){return xp(i,v,[],[])}));function FE(i,v){switch(i){case 0:return function(){return v.apply(this,arguments)};case 1:return function(b){return v.apply(this,arguments)};case 2:return function(b,x){return v.apply(this,arguments)};case 3:return function(b,x,D){return v.apply(this,arguments)};case 4:return function(b,x,D,B){return v.apply(this,arguments)};case 5:return function(b,x,D,B,G){return v.apply(this,arguments)};case 6:return function(b,x,D,B,G,L){return v.apply(this,arguments)};case 7:return function(b,x,D,B,G,L,P){return v.apply(this,arguments)};case 8:return function(b,x,D,B,G,L,P,T){return v.apply(this,arguments)};case 9:return function(b,x,D,B,G,L,P,T,te){return v.apply(this,arguments)};case 10:return function(b,x,D,B,G,L,P,T,te,oe){return v.apply(this,arguments)};default:throw new Error("First argument to _arity must be a non-negative integer no greater than ten")}}function BE(i,v,b){return function(){for(var x=[],D=0,B=i,G=0;G<v.length||D<arguments.length;){var L;G<v.length&&(!ct(v[G])||D>=arguments.length)?L=v[G]:(L=arguments[D],D+=1),x[G]=L,ct(L)||(B-=1),G+=1}return B<=0?b.apply(this,x):FE(B,BE(i,x,b))}}const iR=Number.isInteger||function(i){return i<<0===i};function Sp(i){return Object.prototype.toString.call(i)==="[object String]"}const aR=en((function(i,v){var b=i<0?v.length+i:i;return Sp(v)?v.charAt(b):v[b]})),sR=en((function(i,v){if(v!=null)return iR(i)?aR(i,v):v[i]}));function lR(i){return function v(b,x,D){switch(arguments.length){case 0:return v;case 1:return ct(b)?v:en((function(B,G){return i(b,B,G)}));case 2:return ct(b)&&ct(x)?v:ct(b)?en((function(B,G){return i(B,x,G)})):ct(x)?en((function(B,G){return i(b,B,G)})):Mt((function(B){return i(b,x,B)}));default:return ct(b)&&ct(x)&&ct(D)?v:ct(b)&&ct(x)?en((function(B,G){return i(B,G,D)})):ct(b)&&ct(D)?en((function(B,G){return i(B,x,G)})):ct(x)&&ct(D)?en((function(B,G){return i(b,B,G)})):ct(b)?Mt((function(B){return i(B,x,D)})):ct(x)?Mt((function(B){return i(b,B,D)})):ct(D)?Mt((function(B){return i(b,x,B)})):i(b,x,D)}}}const uR=Mt((function(i){return!!Na(i)||!!i&&typeof i=="object"&&!Sp(i)&&(i.length===0||i.length>0&&i.hasOwnProperty(0)&&i.hasOwnProperty(i.length-1))}));var zE=typeof Symbol<"u"?Symbol.iterator:"@@iterator";function cR(i,v,b){return function(x,D,B){if(uR(B))return i(x,D,B);if(B==null)return D;if(typeof B["fantasy-land/reduce"]=="function")return v(x,D,B,"fantasy-land/reduce");if(B[zE]!=null)return b(x,D,B[zE]());if(typeof B.next=="function")return b(x,D,B);if(typeof B.reduce=="function")return v(x,D,B,"reduce");throw new TypeError("reduce: list must be array or iterable")}}function fR(i,v,b){for(var x=0,D=b.length;x<D;){if((v=i["@@transducer/step"](v,b[x]))&&v["@@transducer/reduced"]){v=v["@@transducer/value"];break}x+=1}return i["@@transducer/result"](v)}const dR=en((function(i,v){return FE(i.length,(function(){return i.apply(v,arguments)}))}));function hR(i,v,b){for(var x=b.next();!x.done;){if((v=i["@@transducer/step"](v,x.value))&&v["@@transducer/reduced"]){v=v["@@transducer/value"];break}x=b.next()}return i["@@transducer/result"](v)}function pR(i,v,b,x){return i["@@transducer/result"](b[x](dR(i["@@transducer/step"],i),v))}const vR=cR(fR,pR,hR);var gR=(function(){function i(v){this.f=v}return i.prototype["@@transducer/init"]=function(){throw new Error("init not implemented on XWrap")},i.prototype["@@transducer/result"]=function(v){return v},i.prototype["@@transducer/step"]=function(v,b){return this.f(v,b)},i})();function Ta(i,v,b){if(b||(b=new yR),D=typeof(x=i),x==null||D!="object"&&D!="function")return i;var x,D,B,G=function(L){var P=b.get(i);if(P)return P;for(var T in b.set(i,L),i)Object.prototype.hasOwnProperty.call(i,T)&&(L[T]=v?Ta(i[T],!0,b):i[T]);return L};switch(Ep(i)){case"Object":return G(Object.create(Object.getPrototypeOf(i)));case"Array":return G([]);case"Date":return new Date(i.valueOf());case"RegExp":return B=i,new RegExp(B.source,B.flags?B.flags:(B.global?"g":"")+(B.ignoreCase?"i":"")+(B.multiline?"m":"")+(B.sticky?"y":"")+(B.unicode?"u":"")+(B.dotAll?"s":""));case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"BigInt64Array":case"BigUint64Array":return i.slice();default:return i}}var yR=(function(){function i(){this.map={},this.length=0}return i.prototype.set=function(v,b){const x=this.hash(v);let D=this.map[x];D||(this.map[x]=D=[]),D.push([v,b]),this.length+=1},i.prototype.hash=function(v){let b=[];for(var x in v)b.push(Object.prototype.toString.call(v[x]));return b.join()},i.prototype.get=function(v){if(this.length<=180){for(const D in this.map){const B=this.map[D];for(let G=0;G<B.length;G+=1){const L=B[G];if(L[0]===v)return L[1]}}return}const b=this.hash(v),x=this.map[b];if(x)for(let D=0;D<x.length;D+=1){const B=x[D];if(B[0]===v)return B[1]}},i})();const mR=Mt((function(i){return i!=null&&typeof i.clone=="function"?i.clone():Ta(i,!0)}));function bR(i,v){return function(){var b=arguments.length;if(b===0)return v();var x=arguments[b-1];return Na(x)||typeof x[i]!="function"?v.apply(this,arguments):x[i].apply(x,Array.prototype.slice.call(arguments,0,b-1))}}function $E(i){return i&&i["@@transducer/reduced"]?i:{"@@transducer/value":i,"@@transducer/reduced":!0}}var _R=(function(){function i(v,b,x,D){this.valueFn=v,this.valueAcc=b,this.keyFn=x,this.xf=D,this.inputs={}}return i.prototype["@@transducer/init"]=CE,i.prototype["@@transducer/result"]=function(v){var b;for(b in this.inputs)if(Kr(b,this.inputs)&&(v=this.xf["@@transducer/step"](v,this.inputs[b]))["@@transducer/reduced"]){v=v["@@transducer/value"];break}return this.inputs=null,this.xf["@@transducer/result"](v)},i.prototype["@@transducer/step"]=function(v,b){var x=this.keyFn(b);return this.inputs[x]=this.inputs[x]||[x,Ta(this.valueAcc,!1)],this.inputs[x][1]=this.valueFn(this.inputs[x][1],b),v},i})();function wR(i,v,b){return function(x){return new _R(i,v,b,x)}}const OR=BE(4,[],TE([],wR,(function(i,v,b,x){var D=new gR((function(B,G){var L=b(G),P=i(Kr(L,B)?B[L]:Ta(v,!1),G);return P&&P["@@transducer/reduced"]?$E(B):(B[L]=P,B)}));return vR(D,{},x)}))),ER=Mt((function(i){return i!=null&&typeof i["fantasy-land/empty"]=="function"?i["fantasy-land/empty"]():i!=null&&i.constructor!=null&&typeof i.constructor["fantasy-land/empty"]=="function"?i.constructor["fantasy-land/empty"]():i!=null&&typeof i.empty=="function"?i.empty():i!=null&&i.constructor!=null&&typeof i.constructor.empty=="function"?i.constructor.empty():Na(i)?[]:Sp(i)?"":(function(x){return Object.prototype.toString.call(x)==="[object Object]"})(i)?{}:ME(i)?(function(){return arguments})():(v=i,(b=Object.prototype.toString.call(v))==="[object Uint8ClampedArray]"||b==="[object Int8Array]"||b==="[object Uint8Array]"||b==="[object Int16Array]"||b==="[object Uint16Array]"||b==="[object Int32Array]"||b==="[object Uint32Array]"||b==="[object Float32Array]"||b==="[object Float64Array]"||b==="[object BigInt64Array]"||b==="[object BigUint64Array]"?i.constructor.from(""):void 0);var v,b}));var xR=(function(){function i(v,b){this.xf=b,this.f=v,this.found=!1}return i.prototype["@@transducer/init"]=CE,i.prototype["@@transducer/result"]=function(v){return this.found||(v=this.xf["@@transducer/step"](v,void 0)),this.xf["@@transducer/result"](v)},i.prototype["@@transducer/step"]=function(v,b){return this.f(b)&&(this.found=!0,v=$E(this.xf["@@transducer/step"](v,b))),v},i})();function SR(i){return function(v){return new xR(i,v)}}const Ca=en(TE(["find"],SR,(function(i,v){for(var b=0,x=v.length;b<x;){if(i(v[b]))return v[b];b+=1}}))),kR=en(bR("groupBy",OR((function(i,v){return i.push(v),i}),[]))),HE=Mt((function(i){return i!=null&&jE(i,ER(i))})),kp=Mt((function(i){return i==null})),Aa=lR((function(i,v,b){return jE(i,sR(v,b))}));var NR=["className","cssModule","color","innerRef","pill","tag"];function Np(){return Np=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Np.apply(this,arguments)}var TR={children:k().node,className:k().string,color:k().string,cssModule:k().object,innerRef:k().oneOfType([k().object,k().func,k().string]),pill:k().bool,tag:X};function VE(i){var v=i.className,b=i.cssModule,x=i.color,D=x===void 0?"secondary":x,B=i.innerRef,G=i.pill,L=G!==void 0&&G,P=i.tag,T=P===void 0?"span":P,te=(function(V,J){if(V==null)return{};var Y,ie,ae=(function(fe,ve){if(fe==null)return{};var he,ye,be={},_e=Object.keys(fe);for(ye=0;ye<_e.length;ye++)he=_e[ye],ve.indexOf(he)>=0||(be[he]=fe[he]);return be})(V,J);if(Object.getOwnPropertySymbols){var ce=Object.getOwnPropertySymbols(V);for(ie=0;ie<ce.length;ie++)Y=ce[ie],J.indexOf(Y)>=0||Object.prototype.propertyIsEnumerable.call(V,Y)&&(ae[Y]=V[Y])}return ae})(i,NR),oe=K(U()(v,"badge","bg-"+D,!!L&&"rounded-pill"),b);return te.href&&T==="span"&&(T="a"),u().createElement(T,Np({},te,{className:oe,ref:B}))}VE.propTypes=TR;const UE=VE;function Tp(i){return Tp=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},Tp(i)}var CR=["className","cssModule","type","bsSize","valid","invalid","tag","addon","plaintext","innerRef"];function Cp(){return Cp=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Cp.apply(this,arguments)}function AR(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,x.key,x)}}function Ap(i,v){return Ap=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(b,x){return b.__proto__=x,b},Ap(i,v)}function Pp(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function Pa(i){return Pa=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},Pa(i)}var PR={children:k().node,type:k().string,size:k().oneOfType([k().number,k().string]),bsSize:k().string,valid:k().bool,invalid:k().bool,tag:X,innerRef:k().oneOfType([k().object,k().func,k().string]),plaintext:k().bool,addon:k().bool,className:k().string,cssModule:k().object},GE=(function(i){(function(L,P){if(typeof P!="function"&&P!==null)throw new TypeError("Super expression must either be null or a function");L.prototype=Object.create(P&&P.prototype,{constructor:{value:L,writable:!0,configurable:!0}}),Object.defineProperty(L,"prototype",{writable:!1}),P&&Ap(L,P)})(G,i);var v,b,x,D,B=(x=G,D=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var L,P=Pa(x);if(D){var T=Pa(this).constructor;L=Reflect.construct(P,arguments,T)}else L=P.apply(this,arguments);return(function(te,oe){if(oe&&(Tp(oe)==="object"||typeof oe=="function"))return oe;if(oe!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Pp(te)})(this,L)});function G(L){var P;return(function(T,te){if(!(T instanceof te))throw new TypeError("Cannot call a class as a function")})(this,G),(P=B.call(this,L)).getRef=P.getRef.bind(Pp(P)),P.focus=P.focus.bind(Pp(P)),P}return v=G,b=[{key:"getRef",value:function(L){this.props.innerRef&&this.props.innerRef(L),this.ref=L}},{key:"focus",value:function(){this.ref&&this.ref.focus()}},{key:"render",value:function(){var L=this.props,P=L.className,T=L.cssModule,te=L.type,oe=te===void 0?"text":te,V=L.bsSize,J=L.valid,Y=L.invalid,ie=L.tag,ae=L.addon,ce=L.plaintext,fe=L.innerRef,ve=(function(Te,De){if(Te==null)return{};var Le,Re,He=(function(Ue,at){if(Ue==null)return{};var Qe,ut,tt={},dt=Object.keys(Ue);for(ut=0;ut<dt.length;ut++)Qe=dt[ut],at.indexOf(Qe)>=0||(tt[Qe]=Ue[Qe]);return tt})(Te,De);if(Object.getOwnPropertySymbols){var Ve=Object.getOwnPropertySymbols(Te);for(Re=0;Re<Ve.length;Re++)Le=Ve[Re],De.indexOf(Le)>=0||Object.prototype.propertyIsEnumerable.call(Te,Le)&&(He[Le]=Te[Le])}return He})(L,CR),he=["switch","radio","checkbox"].indexOf(oe)>-1,ye=oe==="select",be=oe==="range",_e=ie||(ye||oe==="textarea"?oe:"input"),xe="form-control";ce?(xe="".concat(xe,"-plaintext"),_e=ie||"input"):be?xe="form-range":ye?xe="form-select":he&&(xe=ae?null:"form-check-input"),ve.size&&/\D/g.test(ve.size)&&(Q(`Please use the prop "bsSize" instead of the "size" to bootstrap's input sizing.`),V=ve.size,delete ve.size);var Me=K(U()(P,Y&&"is-invalid",J&&"is-valid",!!V&&(ye?"form-select-".concat(V):"form-control-".concat(V)),xe),T);return(_e==="input"||ie&&typeof ie=="function")&&(ve.type=oe==="switch"?"checkbox":oe),ve.children&&!ce&&oe!=="select"&&typeof _e=="string"&&_e!=="select"&&(Q('Input with a type of "'.concat(oe,'" cannot have children. Please use "value"/"defaultValue" instead.')),delete ve.children),u().createElement(_e,Cp({},ve,{ref:fe,className:Me,"aria-invalid":Y}))}}],b&&AR(v.prototype,b),Object.defineProperty(v,"prototype",{writable:!1}),G})(u().Component);GE.propTypes=PR;const Wr=GE;var IR=["className","cssModule","valid","tooltip","tag"];function Ip(){return Ip=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Ip.apply(this,arguments)}var MR={children:k().node,tag:X,className:k().string,cssModule:k().object,valid:k().bool,tooltip:k().bool};function KE(i){var v=i.className,b=i.cssModule,x=i.valid,D=x===void 0?void 0:x,B=i.tooltip,G=i.tag,L=G===void 0?"div":G,P=(function(oe,V){if(oe==null)return{};var J,Y,ie=(function(ce,fe){if(ce==null)return{};var ve,he,ye={},be=Object.keys(ce);for(he=0;he<be.length;he++)ve=be[he],fe.indexOf(ve)>=0||(ye[ve]=ce[ve]);return ye})(oe,V);if(Object.getOwnPropertySymbols){var ae=Object.getOwnPropertySymbols(oe);for(Y=0;Y<ae.length;Y++)J=ae[Y],V.indexOf(J)>=0||Object.prototype.propertyIsEnumerable.call(oe,J)&&(ie[J]=oe[J])}return ie})(i,IR),T=B?"tooltip":"feedback",te=K(U()(v,D?"valid-".concat(T):"invalid-".concat(T)),b);return u().createElement(L,Ip({},P,{className:te}))}KE.propTypes=MR;const Go=KE;function Be(){return Be=Object.assign?Object.assign.bind():function(i){for(var v=1;v<arguments.length;v++){var b=arguments[v];for(var x in b)Object.prototype.hasOwnProperty.call(b,x)&&(i[x]=b[x])}return i},Be.apply(this,arguments)}function dr(i){return dr=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(v){return typeof v}:function(v){return v&&typeof Symbol=="function"&&v.constructor===Symbol&&v!==Symbol.prototype?"symbol":typeof v},dr(i)}function WE(i){var v=(function(b,x){if(dr(b)!=="object"||b===null)return b;var D=b[Symbol.toPrimitive];if(D!==void 0){var B=D.call(b,"string");if(dr(B)!=="object")return B;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(b)})(i);return dr(v)==="symbol"?v:String(v)}function Ko(i,v,b){return(v=WE(v))in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}function YE(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function Fe(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?YE(Object(b),!0).forEach((function(x){Ko(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):YE(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i}function ZE(i,v){for(var b=0;b<v.length;b++){var x=v[b];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(i,WE(x.key),x)}}function Ia(i){return Ia=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(v){return v.__proto__||Object.getPrototypeOf(v)},Ia(i)}function Mp(i){if(i===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return i}function qp(i,v){(v==null||v>i.length)&&(v=i.length);for(var b=0,x=new Array(v);b<v;b++)x[b]=i[b];return x}function XE(i,v){if(i){if(typeof i=="string")return qp(i,v);var b=Object.prototype.toString.call(i).slice(8,-1);return b==="Object"&&i.constructor&&(b=i.constructor.name),b==="Map"||b==="Set"?Array.from(i):b==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(b)?qp(i,v):void 0}}function Wo(i){return(function(v){if(Array.isArray(v))return qp(v)})(i)||(function(v){if(typeof Symbol<"u"&&v[Symbol.iterator]!=null||v["@@iterator"]!=null)return Array.from(v)})(i)||XE(i)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
22
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}var qR=(function(){function i(b){var x=this;this._insertTag=function(D){var B;B=x.tags.length===0?x.insertionPoint?x.insertionPoint.nextSibling:x.prepend?x.container.firstChild:x.before:x.tags[x.tags.length-1].nextSibling,x.container.insertBefore(D,B),x.tags.push(D)},this.isSpeedy=b.speedy===void 0||b.speedy,this.tags=[],this.ctr=0,this.nonce=b.nonce,this.key=b.key,this.container=b.container,this.prepend=b.prepend,this.insertionPoint=b.insertionPoint,this.before=null}var v=i.prototype;return v.hydrate=function(b){b.forEach(this._insertTag)},v.insert=function(b){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag((function(B){var G=document.createElement("style");return G.setAttribute("data-emotion",B.key),B.nonce!==void 0&&G.setAttribute("nonce",B.nonce),G.appendChild(document.createTextNode("")),G.setAttribute("data-s",""),G})(this));var x=this.tags[this.tags.length-1];if(this.isSpeedy){var D=(function(B){if(B.sheet)return B.sheet;for(var G=0;G<document.styleSheets.length;G++)if(document.styleSheets[G].ownerNode===B)return document.styleSheets[G]})(x);try{D.insertRule(b,D.cssRules.length)}catch{}}else x.appendChild(document.createTextNode(b));this.ctr++},v.flush=function(){this.tags.forEach((function(b){return b.parentNode&&b.parentNode.removeChild(b)})),this.tags=[],this.ctr=0},i})(),LR=Math.abs,Ma=String.fromCharCode,RR=Object.assign;function QE(i){return i.trim()}function Je(i,v,b){return i.replace(v,b)}function Lp(i,v){return i.indexOf(v)}function Ct(i,v){return 0|i.charCodeAt(v)}function Yo(i,v,b){return i.slice(v,b)}function mn(i){return i.length}function Rp(i){return i.length}function qa(i,v){return v.push(i),i}var La=1,Yr=1,JE=0,Bt=0,mt=0,Zr="";function Ra(i,v,b,x,D,B,G){return{value:i,root:v,parent:b,type:x,props:D,children:B,line:La,column:Yr,length:G,return:""}}function Zo(i,v){return RR(Ra("",null,null,"",null,null,0),i,{length:-i.length},v)}function DR(){return mt=Bt>0?Ct(Zr,--Bt):0,Yr--,mt===10&&(Yr=1,La--),mt}function Ht(){return mt=Bt<JE?Ct(Zr,Bt++):0,Yr++,mt===10&&(Yr=1,La++),mt}function bn(){return Ct(Zr,Bt)}function Da(){return Bt}function Xo(i,v){return Yo(Zr,i,v)}function Qo(i){switch(i){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ex(i){return La=Yr=1,JE=mn(Zr=i),Bt=0,[]}function tx(i){return Zr="",i}function ja(i){return QE(Xo(Bt-1,Dp(i===91?i+2:i===40?i+1:i)))}function jR(i){for(;(mt=bn())&&mt<33;)Ht();return Qo(i)>2||Qo(mt)>3?"":" "}function FR(i,v){for(;--v&&Ht()&&!(mt<48||mt>102||mt>57&&mt<65||mt>70&&mt<97););return Xo(i,Da()+(v<6&&bn()==32&&Ht()==32))}function Dp(i){for(;Ht();)switch(mt){case i:return Bt;case 34:case 39:i!==34&&i!==39&&Dp(mt);break;case 40:i===41&&Dp(i);break;case 92:Ht()}return Bt}function BR(i,v){for(;Ht()&&i+mt!==57&&(i+mt!==84||bn()!==47););return"/*"+Xo(v,Bt-1)+"*"+Ma(i===47?i:Ht())}function zR(i){for(;!Qo(bn());)Ht();return Xo(i,Bt)}var At="-ms-",nx="-moz-",et="-webkit-",rx="comm",jp="rule",Fp="decl",ox="@keyframes";function Xr(i,v){for(var b="",x=Rp(i),D=0;D<x;D++)b+=v(i[D],D,i,v)||"";return b}function $R(i,v,b,x){switch(i.type){case"@layer":if(i.children.length)break;case"@import":case Fp:return i.return=i.return||i.value;case rx:return"";case ox:return i.return=i.value+"{"+Xr(i.children,x)+"}";case jp:i.value=i.props.join(",")}return mn(b=Xr(i.children,x))?i.return=i.value+"{"+b+"}":""}function HR(i){return tx(Fa("",null,null,null,[""],i=ex(i),0,[0],i))}function Fa(i,v,b,x,D,B,G,L,P){for(var T=0,te=0,oe=G,V=0,J=0,Y=0,ie=1,ae=1,ce=1,fe=0,ve="",he=D,ye=B,be=x,_e=ve;ae;)switch(Y=fe,fe=Ht()){case 40:if(Y!=108&&Ct(_e,oe-1)==58){Lp(_e+=Je(ja(fe),"&","&\f"),"&\f")!=-1&&(ce=-1);break}case 34:case 39:case 91:_e+=ja(fe);break;case 9:case 10:case 13:case 32:_e+=jR(Y);break;case 92:_e+=FR(Da()-1,7);continue;case 47:switch(bn()){case 42:case 47:qa(VR(BR(Ht(),Da()),v,b),P);break;default:_e+="/"}break;case 123*ie:L[T++]=mn(_e)*ce;case 125*ie:case 59:case 0:switch(fe){case 0:case 125:ae=0;case 59+te:ce==-1&&(_e=Je(_e,/\f/g,"")),J>0&&mn(_e)-oe&&qa(J>32?ax(_e+";",x,b,oe-1):ax(Je(_e," ","")+";",x,b,oe-2),P);break;case 59:_e+=";";default:if(qa(be=ix(_e,v,b,T,te,D,L,ve,he=[],ye=[],oe),B),fe===123)if(te===0)Fa(_e,v,be,be,he,B,oe,L,ye);else switch(V===99&&Ct(_e,3)===110?100:V){case 100:case 108:case 109:case 115:Fa(i,be,be,x&&qa(ix(i,be,be,0,0,D,L,ve,D,he=[],oe),ye),D,ye,oe,L,x?he:ye);break;default:Fa(_e,be,be,be,[""],ye,0,L,ye)}}T=te=J=0,ie=ce=1,ve=_e="",oe=G;break;case 58:oe=1+mn(_e),J=Y;default:if(ie<1){if(fe==123)--ie;else if(fe==125&&ie++==0&&DR()==125)continue}switch(_e+=Ma(fe),fe*ie){case 38:ce=te>0?1:(_e+="\f",-1);break;case 44:L[T++]=(mn(_e)-1)*ce,ce=1;break;case 64:bn()===45&&(_e+=ja(Ht())),V=bn(),te=oe=mn(ve=_e+=zR(Da())),fe++;break;case 45:Y===45&&mn(_e)==2&&(ie=0)}}return B}function ix(i,v,b,x,D,B,G,L,P,T,te){for(var oe=D-1,V=D===0?B:[""],J=Rp(V),Y=0,ie=0,ae=0;Y<x;++Y)for(var ce=0,fe=Yo(i,oe+1,oe=LR(ie=G[Y])),ve=i;ce<J;++ce)(ve=QE(ie>0?V[ce]+" "+fe:Je(fe,/&\f/g,V[ce])))&&(P[ae++]=ve);return Ra(i,v,b,D===0?jp:L,P,T,te)}function VR(i,v,b){return Ra(i,v,b,rx,Ma(mt),Yo(i,2,-2),0)}function ax(i,v,b,x){return Ra(i,v,b,Fp,Yo(i,0,x),Yo(i,x+1,-1),x)}var UR=function(i,v,b){for(var x=0,D=0;x=D,D=bn(),x===38&&D===12&&(v[b]=1),!Qo(D);)Ht();return Xo(i,Bt)},sx=new WeakMap,GR=function(i){if(i.type==="rule"&&i.parent&&!(i.length<1)){for(var v=i.value,b=i.parent,x=i.column===b.column&&i.line===b.line;b.type!=="rule";)if(!(b=b.parent))return;if((i.props.length!==1||v.charCodeAt(0)===58||sx.get(b))&&!x){sx.set(i,!0);for(var D=[],B=(function(te,oe){return tx((function(V,J){var Y=-1,ie=44;do switch(Qo(ie)){case 0:ie===38&&bn()===12&&(J[Y]=1),V[Y]+=UR(Bt-1,J,Y);break;case 2:V[Y]+=ja(ie);break;case 4:if(ie===44){V[++Y]=bn()===58?"&\f":"",J[Y]=V[Y].length;break}default:V[Y]+=Ma(ie)}while(ie=Ht());return V})(ex(te),oe))})(v,D),G=b.props,L=0,P=0;L<B.length;L++)for(var T=0;T<G.length;T++,P++)i.props[P]=D[L]?B[L].replace(/&\f/g,G[T]):G[T]+" "+B[L]}}},KR=function(i){if(i.type==="decl"){var v=i.value;v.charCodeAt(0)===108&&v.charCodeAt(2)===98&&(i.return="",i.value="")}};function lx(i,v){switch((function(b,x){return 45^Ct(b,0)?(((x<<2^Ct(b,0))<<2^Ct(b,1))<<2^Ct(b,2))<<2^Ct(b,3):0})(i,v)){case 5103:return et+"print-"+i+i;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return et+i+i;case 5349:case 4246:case 4810:case 6968:case 2756:return et+i+nx+i+At+i+i;case 6828:case 4268:return et+i+At+i+i;case 6165:return et+i+At+"flex-"+i+i;case 5187:return et+i+Je(i,/(\w+).+(:[^]+)/,et+"box-$1$2"+At+"flex-$1$2")+i;case 5443:return et+i+At+"flex-item-"+Je(i,/flex-|-self/,"")+i;case 4675:return et+i+At+"flex-line-pack"+Je(i,/align-content|flex-|-self/,"")+i;case 5548:return et+i+At+Je(i,"shrink","negative")+i;case 5292:return et+i+At+Je(i,"basis","preferred-size")+i;case 6060:return et+"box-"+Je(i,"-grow","")+et+i+At+Je(i,"grow","positive")+i;case 4554:return et+Je(i,/([^-])(transform)/g,"$1"+et+"$2")+i;case 6187:return Je(Je(Je(i,/(zoom-|grab)/,et+"$1"),/(image-set)/,et+"$1"),i,"")+i;case 5495:case 3959:return Je(i,/(image-set\([^]*)/,et+"$1$`$1");case 4968:return Je(Je(i,/(.+:)(flex-)?(.*)/,et+"box-pack:$3"+At+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+et+i+i;case 4095:case 3583:case 4068:case 2532:return Je(i,/(.+)-inline(.+)/,et+"$1$2")+i;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(mn(i)-1-v>6)switch(Ct(i,v+1)){case 109:if(Ct(i,v+4)!==45)break;case 102:return Je(i,/(.+:)(.+)-([^]+)/,"$1"+et+"$2-$3$1"+nx+(Ct(i,v+3)==108?"$3":"$2-$3"))+i;case 115:return~Lp(i,"stretch")?lx(Je(i,"stretch","fill-available"),v)+i:i}break;case 4949:if(Ct(i,v+1)!==115)break;case 6444:switch(Ct(i,mn(i)-3-(~Lp(i,"!important")&&10))){case 107:return Je(i,":",":"+et)+i;case 101:return Je(i,/(.+:)([^;!]+)(;|!.+)?/,"$1"+et+(Ct(i,14)===45?"inline-":"")+"box$3$1"+et+"$2$3$1"+At+"$2box$3")+i}break;case 5936:switch(Ct(i,v+11)){case 114:return et+i+At+Je(i,/[svh]\w+-[tblr]{2}/,"tb")+i;case 108:return et+i+At+Je(i,/[svh]\w+-[tblr]{2}/,"tb-rl")+i;case 45:return et+i+At+Je(i,/[svh]\w+-[tblr]{2}/,"lr")+i}return et+i+At+i+i}return i}var WR=[function(i,v,b,x){if(i.length>-1&&!i.return)switch(i.type){case Fp:i.return=lx(i.value,i.length);break;case ox:return Xr([Zo(i,{value:Je(i.value,"@","@"+et)})],x);case jp:if(i.length)return(function(D,B){return D.map(B).join("")})(i.props,(function(D){switch((function(B,G){return(B=/(::plac\w+|:read-\w+)/.exec(B))?B[0]:B})(D)){case":read-only":case":read-write":return Xr([Zo(i,{props:[Je(D,/:(read-\w+)/,":-moz-$1")]})],x);case"::placeholder":return Xr([Zo(i,{props:[Je(D,/:(plac\w+)/,":"+et+"input-$1")]}),Zo(i,{props:[Je(D,/:(plac\w+)/,":-moz-$1")]}),Zo(i,{props:[Je(D,/:(plac\w+)/,At+"input-$1")]})],x)}return""}))}}],YR=function(i){var v=i.key;if(v==="css"){var b=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(b,(function(ie){ie.getAttribute("data-emotion").indexOf(" ")!==-1&&(document.head.appendChild(ie),ie.setAttribute("data-s",""))}))}var x,D,B=i.stylisPlugins||WR,G={},L=[];x=i.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+v+' "]'),(function(ie){for(var ae=ie.getAttribute("data-emotion").split(" "),ce=1;ce<ae.length;ce++)G[ae[ce]]=!0;L.push(ie)}));var P,T,te,oe,V=[$R,(T=function(ie){P.insert(ie)},function(ie){ie.root||(ie=ie.return)&&T(ie)})],J=(te=[GR,KR].concat(B,V),oe=Rp(te),function(ie,ae,ce,fe){for(var ve="",he=0;he<oe;he++)ve+=te[he](ie,ae,ce,fe)||"";return ve});D=function(ie,ae,ce,fe){P=ce,Xr(HR(ie?ie+"{"+ae.styles+"}":ae.styles),J),fe&&(Y.inserted[ae.name]=!0)};var Y={key:v,sheet:new qR({key:v,container:x,nonce:i.nonce,speedy:i.speedy,prepend:i.prepend,insertionPoint:i.insertionPoint}),nonce:i.nonce,inserted:G,registered:{},insert:D};return Y.sheet.hydrate(L),Y},ux=function(i,v,b){var x=i.key+"-"+v.name;b===!1&&i.registered[x]===void 0&&(i.registered[x]=v.styles)},ZR={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function XR(i){var v=Object.create(null);return function(b){return v[b]===void 0&&(v[b]=i(b)),v[b]}}var QR=/[A-Z]|^ms/g,JR=/_EMO_([^_]+?)_([^]*?)_EMO_/g,cx=function(i){return i.charCodeAt(1)===45},fx=function(i){return i!=null&&typeof i!="boolean"},Bp=XR((function(i){return cx(i)?i:i.replace(QR,"-$&").toLowerCase()})),dx=function(i,v){switch(i){case"animation":case"animationName":if(typeof v=="string")return v.replace(JR,(function(b,x,D){return _n={name:x,styles:D,next:_n},x}))}return ZR[i]===1||cx(i)||typeof v!="number"||v===0?v:v+"px"};function Jo(i,v,b){if(b==null)return"";if(b.__emotion_styles!==void 0)return b;switch(typeof b){case"boolean":return"";case"object":if(b.anim===1)return _n={name:b.name,styles:b.styles,next:_n},b.name;if(b.styles!==void 0){var x=b.next;if(x!==void 0)for(;x!==void 0;)_n={name:x.name,styles:x.styles,next:_n},x=x.next;return b.styles+";"}return(function(G,L,P){var T="";if(Array.isArray(P))for(var te=0;te<P.length;te++)T+=Jo(G,L,P[te])+";";else for(var oe in P){var V=P[oe];if(typeof V!="object")fx(V)&&(T+=Bp(oe)+":"+dx(oe,V)+";");else if(!Array.isArray(V)||typeof V[0]!="string"||L!=null){var J=Jo(G,L,V);switch(oe){case"animation":case"animationName":T+=Bp(oe)+":"+J+";";break;default:T+=oe+"{"+J+"}"}}else for(var Y=0;Y<V.length;Y++)fx(V[Y])&&(T+=Bp(oe)+":"+dx(oe,V[Y])+";")}return T})(i,v,b);case"function":if(i!==void 0){var D=_n,B=b(i);return _n=D,Jo(i,v,B)}}return b}var _n,hx=/label:\s*([^\s;\n{]+)\s*(;|$)/g,px=function(i,v,b){if(i.length===1&&typeof i[0]=="object"&&i[0]!==null&&i[0].styles!==void 0)return i[0];var x=!0,D="";_n=void 0;var B=i[0];B==null||B.raw===void 0?(x=!1,D+=Jo(b,v,B)):D+=B[0];for(var G=1;G<i.length;G++)D+=Jo(b,v,i[G]),x&&(D+=B[G]);hx.lastIndex=0;for(var L,P="";(L=hx.exec(D))!==null;)P+="-"+L[1];var T=(function(te){for(var oe,V=0,J=0,Y=te.length;Y>=4;++J,Y-=4)oe=1540483477*(65535&(oe=255&te.charCodeAt(J)|(255&te.charCodeAt(++J))<<8|(255&te.charCodeAt(++J))<<16|(255&te.charCodeAt(++J))<<24))+(59797*(oe>>>16)<<16),V=1540483477*(65535&(oe^=oe>>>24))+(59797*(oe>>>16)<<16)^1540483477*(65535&V)+(59797*(V>>>16)<<16);switch(Y){case 3:V^=(255&te.charCodeAt(J+2))<<16;case 2:V^=(255&te.charCodeAt(J+1))<<8;case 1:V=1540483477*(65535&(V^=255&te.charCodeAt(J)))+(59797*(V>>>16)<<16)}return(((V=1540483477*(65535&(V^=V>>>13))+(59797*(V>>>16)<<16))^V>>>15)>>>0).toString(36)})(D)+P;return{name:T,styles:D,next:_n}},vx=!!a.useInsertionEffect&&a.useInsertionEffect,e5=vx||function(i){return i()},zp=(vx||a.useLayoutEffect,{}.hasOwnProperty),gx=a.createContext(typeof HTMLElement<"u"?YR({key:"css"}):null);gx.Provider;var t5=function(i){return(0,a.forwardRef)((function(v,b){var x=(0,a.useContext)(gx);return i(v,x,b)}))},n5=a.createContext({}),$p="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",r5=function(i){var v=i.cache,b=i.serialized,x=i.isStringTag;return ux(v,b,x),e5((function(){return(function(D,B,G){ux(D,B,G);var L=D.key+"-"+B.name;if(D.inserted[B.name]===void 0){var P=B;do D.insert(B===P?"."+L:"",P,D.sheet,!0),P=P.next;while(P!==void 0)}})(v,b,x)})),null},o5=t5((function(i,v,b){var x=i.css;typeof x=="string"&&v.registered[x]!==void 0&&(x=v.registered[x]);var D=i[$p],B=[x],G="";typeof i.className=="string"?G=(function(te,oe,V){var J="";return V.split(" ").forEach((function(Y){te[Y]!==void 0?oe.push(te[Y]+";"):J+=Y+" "})),J})(v.registered,B,i.className):i.className!=null&&(G=i.className+" ");var L=px(B,void 0,a.useContext(n5));G+=v.key+"-"+L.name;var P={};for(var T in i)zp.call(i,T)&&T!=="css"&&T!==$p&&(P[T]=i[T]);return P.ref=b,P.className=G,a.createElement(a.Fragment,null,a.createElement(r5,{cache:v,serialized:L,isStringTag:typeof D=="string"}),a.createElement(D,P))})),i5=o5,$e=(l(679),function(i,v){var b=arguments;if(v==null||!zp.call(v,"css"))return a.createElement.apply(void 0,b);var x=b.length,D=new Array(x);D[0]=i5,D[1]=(function(G,L){var P={};for(var T in L)zp.call(L,T)&&(P[T]=L[T]);return P[$p]=G,P})(i,v);for(var B=2;B<x;B++)D[B]=b[B];return a.createElement.apply(null,D)});function Hp(){for(var i=arguments.length,v=new Array(i),b=0;b<i;b++)v[b]=arguments[b];return px(v)}function qn(i,v){return(function(b){if(Array.isArray(b))return b})(i)||(function(b,x){var D=b==null?null:typeof Symbol<"u"&&b[Symbol.iterator]||b["@@iterator"];if(D!=null){var B,G,L,P,T=[],te=!0,oe=!1;try{if(L=(D=D.call(b)).next,x===0){if(Object(D)!==D)return;te=!1}else for(;!(te=(B=L.call(D)).done)&&(T.push(B.value),T.length!==x);te=!0);}catch(V){oe=!0,G=V}finally{try{if(!te&&D.return!=null&&(P=D.return(),Object(P)!==P))return}finally{if(oe)throw G}}return T}})(i,v)||XE(i,v)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
23
|
-
|
|
17
|
+
*/var z_;function CP(){if(z_)return wm;z_=1;var e=wt.default,n=kP();function r(g,d){return g===d&&(g!==0||1/g===1/d)||g!==g&&d!==d}var o=typeof Object.is=="function"?Object.is:r,i=n.useSyncExternalStore,l=e.useRef,c=e.useEffect,f=e.useMemo,m=e.useDebugValue;return wm.useSyncExternalStoreWithSelector=function(g,d,p,h,s){var S=l(null);if(S.current===null){var b={hasValue:!1,value:null};S.current=b}else b=S.current;S=f(function(){function w(P){if(!y){if(y=!0,E=P,P=h(P),s!==void 0&&b.hasValue){var R=b.value;if(s(R,P))return x=R}return x=P}if(R=x,o(E,P))return R;var j=h(P);return s!==void 0&&s(R,j)?R:(E=P,x=j)}var y=!1,E,x,k=p===void 0?null:p;return[function(){return w(d())},k===null?void 0:function(){return w(k())}]},[d,p,h,s]);var _=i(g,S[0],S[1]);return c(function(){b.hasValue=!0,b.value=_},[_]),m(_),_},wm}var H_;function AP(){return H_||(H_=1,bm.exports=CP()),bm.exports}var NP=AP();const TP=Iu(NP),RP={},V_=e=>{let n;const r=new Set,o=(m,g)=>{const d=typeof m=="function"?m(n):m;if(!Object.is(d,n)){const p=n;n=g??typeof d!="object"?d:Object.assign({},n,d),r.forEach(h=>h(n,p))}},i=()=>n,f={setState:o,getState:i,subscribe:m=>(r.add(m),()=>r.delete(m)),destroy:()=>{(RP?"production":void 0)!=="production"&&console.warn("[DEPRECATED] The `destroy` method will be unsupported in a future version. Instead use unsubscribe function returned by subscribe. Everything will be garbage-collected if store is garbage-collected."),r.clear()}};return n=e(o,i,f),f},PP=e=>e?V_(e):V_,{useSyncExternalStoreWithSelector:IP}=TP;function U_(e,n=e.getState,r){const o=IP(e.subscribe,e.getState,e.getServerState||e.getState,n,r);return he.useDebugValue(o),o}const W_=(e,n)=>{const r=PP(e),o=(i,l=n)=>U_(r,i,l);return Object.assign(o,r),o},MP=(e,n)=>e?W_(e,n):W_;function ln(e,n){if(Object.is(e,n))return!0;if(typeof e!="object"||e===null||typeof n!="object"||n===null)return!1;if(e instanceof Map&&n instanceof Map){if(e.size!==n.size)return!1;for(const[o,i]of e)if(!Object.is(i,n.get(o)))return!1;return!0}if(e instanceof Set&&n instanceof Set){if(e.size!==n.size)return!1;for(const o of e)if(!n.has(o))return!1;return!0}const r=Object.keys(e);if(r.length!==Object.keys(n).length)return!1;for(let o=0;o<r.length;o++)if(!Object.prototype.hasOwnProperty.call(n,r[o])||!Object.is(e[r[o]],n[r[o]]))return!1;return!0}var jP={value:()=>{}};function Es(){for(var e=0,n=arguments.length,r={},o;e<n;++e){if(!(o=arguments[e]+"")||o in r||/[\s.]/.test(o))throw new Error("illegal type: "+o);r[o]=[]}return new Os(r)}function Os(e){this._=e}function LP(e,n){return e.trim().split(/^|\s+/).map(function(r){var o="",i=r.indexOf(".");if(i>=0&&(o=r.slice(i+1),r=r.slice(0,i)),r&&!n.hasOwnProperty(r))throw new Error("unknown type: "+r);return{type:r,name:o}})}Os.prototype=Es.prototype={constructor:Os,on:function(e,n){var r=this._,o=LP(e+"",r),i,l=-1,c=o.length;if(arguments.length<2){for(;++l<c;)if((i=(e=o[l]).type)&&(i=DP(r[i],e.name)))return i;return}if(n!=null&&typeof n!="function")throw new Error("invalid callback: "+n);for(;++l<c;)if(i=(e=o[l]).type)r[i]=G_(r[i],e.name,n);else if(n==null)for(i in r)r[i]=G_(r[i],e.name,null);return this},copy:function(){var e={},n=this._;for(var r in n)e[r]=n[r].slice();return new Os(e)},call:function(e,n){if((i=arguments.length-2)>0)for(var r=new Array(i),o=0,i,l;o<i;++o)r[o]=arguments[o+2];if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(l=this._[e],o=0,i=l.length;o<i;++o)l[o].value.apply(n,r)},apply:function(e,n,r){if(!this._.hasOwnProperty(e))throw new Error("unknown type: "+e);for(var o=this._[e],i=0,l=o.length;i<l;++i)o[i].value.apply(n,r)}};function DP(e,n){for(var r=0,o=e.length,i;r<o;++r)if((i=e[r]).name===n)return i.value}function G_(e,n,r){for(var o=0,i=e.length;o<i;++o)if(e[o].name===n){e[o]=jP,e=e.slice(0,o).concat(e.slice(o+1));break}return r!=null&&e.push({name:n,value:r}),e}var Sm="http://www.w3.org/1999/xhtml";const K_={svg:"http://www.w3.org/2000/svg",xhtml:Sm,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function ks(e){var n=e+="",r=n.indexOf(":");return r>=0&&(n=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),K_.hasOwnProperty(n)?{space:K_[n],local:e}:e}function BP(e){return function(){var n=this.ownerDocument,r=this.namespaceURI;return r===Sm&&n.documentElement.namespaceURI===Sm?n.createElement(e):n.createElementNS(r,e)}}function FP(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function Y_(e){var n=ks(e);return(n.local?FP:BP)(n)}function qP(){}function Em(e){return e==null?qP:function(){return this.querySelector(e)}}function zP(e){typeof e!="function"&&(e=Em(e));for(var n=this._groups,r=n.length,o=new Array(r),i=0;i<r;++i)for(var l=n[i],c=l.length,f=o[i]=new Array(c),m,g,d=0;d<c;++d)(m=l[d])&&(g=e.call(m,m.__data__,d,l))&&("__data__"in m&&(g.__data__=m.__data__),f[d]=g);return new kn(o,this._parents)}function HP(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function VP(){return[]}function X_(e){return e==null?VP:function(){return this.querySelectorAll(e)}}function UP(e){return function(){return HP(e.apply(this,arguments))}}function WP(e){typeof e=="function"?e=UP(e):e=X_(e);for(var n=this._groups,r=n.length,o=[],i=[],l=0;l<r;++l)for(var c=n[l],f=c.length,m,g=0;g<f;++g)(m=c[g])&&(o.push(e.call(m,m.__data__,g,c)),i.push(m));return new kn(o,i)}function Z_(e){return function(){return this.matches(e)}}function Q_(e){return function(n){return n.matches(e)}}var GP=Array.prototype.find;function KP(e){return function(){return GP.call(this.children,e)}}function YP(){return this.firstElementChild}function XP(e){return this.select(e==null?YP:KP(typeof e=="function"?e:Q_(e)))}var ZP=Array.prototype.filter;function QP(){return Array.from(this.children)}function JP(e){return function(){return ZP.call(this.children,e)}}function $P(e){return this.selectAll(e==null?QP:JP(typeof e=="function"?e:Q_(e)))}function eI(e){typeof e!="function"&&(e=Z_(e));for(var n=this._groups,r=n.length,o=new Array(r),i=0;i<r;++i)for(var l=n[i],c=l.length,f=o[i]=[],m,g=0;g<c;++g)(m=l[g])&&e.call(m,m.__data__,g,l)&&f.push(m);return new kn(o,this._parents)}function J_(e){return new Array(e.length)}function tI(){return new kn(this._enter||this._groups.map(J_),this._parents)}function Cs(e,n){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=n}Cs.prototype={constructor:Cs,appendChild:function(e){return this._parent.insertBefore(e,this._next)},insertBefore:function(e,n){return this._parent.insertBefore(e,n)},querySelector:function(e){return this._parent.querySelector(e)},querySelectorAll:function(e){return this._parent.querySelectorAll(e)}};function nI(e){return function(){return e}}function rI(e,n,r,o,i,l){for(var c=0,f,m=n.length,g=l.length;c<g;++c)(f=n[c])?(f.__data__=l[c],o[c]=f):r[c]=new Cs(e,l[c]);for(;c<m;++c)(f=n[c])&&(i[c]=f)}function oI(e,n,r,o,i,l,c){var f,m,g=new Map,d=n.length,p=l.length,h=new Array(d),s;for(f=0;f<d;++f)(m=n[f])&&(h[f]=s=c.call(m,m.__data__,f,n)+"",g.has(s)?i[f]=m:g.set(s,m));for(f=0;f<p;++f)s=c.call(e,l[f],f,l)+"",(m=g.get(s))?(o[f]=m,m.__data__=l[f],g.delete(s)):r[f]=new Cs(e,l[f]);for(f=0;f<d;++f)(m=n[f])&&g.get(h[f])===m&&(i[f]=m)}function iI(e){return e.__data__}function aI(e,n){if(!arguments.length)return Array.from(this,iI);var r=n?oI:rI,o=this._parents,i=this._groups;typeof e!="function"&&(e=nI(e));for(var l=i.length,c=new Array(l),f=new Array(l),m=new Array(l),g=0;g<l;++g){var d=o[g],p=i[g],h=p.length,s=sI(e.call(d,d&&d.__data__,g,o)),S=s.length,b=f[g]=new Array(S),_=c[g]=new Array(S),w=m[g]=new Array(h);r(d,p,b,_,w,s,n);for(var y=0,E=0,x,k;y<S;++y)if(x=b[y]){for(y>=E&&(E=y+1);!(k=_[E])&&++E<S;);x._next=k||null}}return c=new kn(c,o),c._enter=f,c._exit=m,c}function sI(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function lI(){return new kn(this._exit||this._groups.map(J_),this._parents)}function uI(e,n,r){var o=this.enter(),i=this,l=this.exit();return typeof e=="function"?(o=e(o),o&&(o=o.selection())):o=o.append(e+""),n!=null&&(i=n(i),i&&(i=i.selection())),r==null?l.remove():r(l),o&&i?o.merge(i).order():i}function cI(e){for(var n=e.selection?e.selection():e,r=this._groups,o=n._groups,i=r.length,l=o.length,c=Math.min(i,l),f=new Array(i),m=0;m<c;++m)for(var g=r[m],d=o[m],p=g.length,h=f[m]=new Array(p),s,S=0;S<p;++S)(s=g[S]||d[S])&&(h[S]=s);for(;m<i;++m)f[m]=r[m];return new kn(f,this._parents)}function fI(){for(var e=this._groups,n=-1,r=e.length;++n<r;)for(var o=e[n],i=o.length-1,l=o[i],c;--i>=0;)(c=o[i])&&(l&&c.compareDocumentPosition(l)^4&&l.parentNode.insertBefore(c,l),l=c);return this}function dI(e){e||(e=hI);function n(p,h){return p&&h?e(p.__data__,h.__data__):!p-!h}for(var r=this._groups,o=r.length,i=new Array(o),l=0;l<o;++l){for(var c=r[l],f=c.length,m=i[l]=new Array(f),g,d=0;d<f;++d)(g=c[d])&&(m[d]=g);m.sort(n)}return new kn(i,this._parents).order()}function hI(e,n){return e<n?-1:e>n?1:e>=n?0:NaN}function pI(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function mI(){return Array.from(this)}function gI(){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var o=e[n],i=0,l=o.length;i<l;++i){var c=o[i];if(c)return c}return null}function vI(){let e=0;for(const n of this)++e;return e}function yI(){return!this.node()}function bI(e){for(var n=this._groups,r=0,o=n.length;r<o;++r)for(var i=n[r],l=0,c=i.length,f;l<c;++l)(f=i[l])&&e.call(f,f.__data__,l,i);return this}function wI(e){return function(){this.removeAttribute(e)}}function xI(e){return function(){this.removeAttributeNS(e.space,e.local)}}function _I(e,n){return function(){this.setAttribute(e,n)}}function SI(e,n){return function(){this.setAttributeNS(e.space,e.local,n)}}function EI(e,n){return function(){var r=n.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function OI(e,n){return function(){var r=n.apply(this,arguments);r==null?this.removeAttributeNS(e.space,e.local):this.setAttributeNS(e.space,e.local,r)}}function kI(e,n){var r=ks(e);if(arguments.length<2){var o=this.node();return r.local?o.getAttributeNS(r.space,r.local):o.getAttribute(r)}return this.each((n==null?r.local?xI:wI:typeof n=="function"?r.local?OI:EI:r.local?SI:_I)(r,n))}function $_(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function CI(e){return function(){this.style.removeProperty(e)}}function AI(e,n,r){return function(){this.style.setProperty(e,n,r)}}function NI(e,n,r){return function(){var o=n.apply(this,arguments);o==null?this.style.removeProperty(e):this.style.setProperty(e,o,r)}}function TI(e,n,r){return arguments.length>1?this.each((n==null?CI:typeof n=="function"?NI:AI)(e,n,r??"")):Vo(this.node(),e)}function Vo(e,n){return e.style.getPropertyValue(n)||$_(e).getComputedStyle(e,null).getPropertyValue(n)}function RI(e){return function(){delete this[e]}}function PI(e,n){return function(){this[e]=n}}function II(e,n){return function(){var r=n.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function MI(e,n){return arguments.length>1?this.each((n==null?RI:typeof n=="function"?II:PI)(e,n)):this.node()[e]}function eS(e){return e.trim().split(/^|\s+/)}function Om(e){return e.classList||new tS(e)}function tS(e){this._node=e,this._names=eS(e.getAttribute("class")||"")}tS.prototype={add:function(e){var n=this._names.indexOf(e);n<0&&(this._names.push(e),this._node.setAttribute("class",this._names.join(" ")))},remove:function(e){var n=this._names.indexOf(e);n>=0&&(this._names.splice(n,1),this._node.setAttribute("class",this._names.join(" ")))},contains:function(e){return this._names.indexOf(e)>=0}};function nS(e,n){for(var r=Om(e),o=-1,i=n.length;++o<i;)r.add(n[o])}function rS(e,n){for(var r=Om(e),o=-1,i=n.length;++o<i;)r.remove(n[o])}function jI(e){return function(){nS(this,e)}}function LI(e){return function(){rS(this,e)}}function DI(e,n){return function(){(n.apply(this,arguments)?nS:rS)(this,e)}}function BI(e,n){var r=eS(e+"");if(arguments.length<2){for(var o=Om(this.node()),i=-1,l=r.length;++i<l;)if(!o.contains(r[i]))return!1;return!0}return this.each((typeof n=="function"?DI:n?jI:LI)(r,n))}function FI(){this.textContent=""}function qI(e){return function(){this.textContent=e}}function zI(e){return function(){var n=e.apply(this,arguments);this.textContent=n??""}}function HI(e){return arguments.length?this.each(e==null?FI:(typeof e=="function"?zI:qI)(e)):this.node().textContent}function VI(){this.innerHTML=""}function UI(e){return function(){this.innerHTML=e}}function WI(e){return function(){var n=e.apply(this,arguments);this.innerHTML=n??""}}function GI(e){return arguments.length?this.each(e==null?VI:(typeof e=="function"?WI:UI)(e)):this.node().innerHTML}function KI(){this.nextSibling&&this.parentNode.appendChild(this)}function YI(){return this.each(KI)}function XI(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function ZI(){return this.each(XI)}function QI(e){var n=typeof e=="function"?e:Y_(e);return this.select(function(){return this.appendChild(n.apply(this,arguments))})}function JI(){return null}function $I(e,n){var r=typeof e=="function"?e:Y_(e),o=n==null?JI:typeof n=="function"?n:Em(n);return this.select(function(){return this.insertBefore(r.apply(this,arguments),o.apply(this,arguments)||null)})}function eM(){var e=this.parentNode;e&&e.removeChild(this)}function tM(){return this.each(eM)}function nM(){var e=this.cloneNode(!1),n=this.parentNode;return n?n.insertBefore(e,this.nextSibling):e}function rM(){var e=this.cloneNode(!0),n=this.parentNode;return n?n.insertBefore(e,this.nextSibling):e}function oM(e){return this.select(e?rM:nM)}function iM(e){return arguments.length?this.property("__data__",e):this.node().__data__}function aM(e){return function(n){e.call(this,n,this.__data__)}}function sM(e){return e.trim().split(/^|\s+/).map(function(n){var r="",o=n.indexOf(".");return o>=0&&(r=n.slice(o+1),n=n.slice(0,o)),{type:n,name:r}})}function lM(e){return function(){var n=this.__on;if(n){for(var r=0,o=-1,i=n.length,l;r<i;++r)l=n[r],(!e.type||l.type===e.type)&&l.name===e.name?this.removeEventListener(l.type,l.listener,l.options):n[++o]=l;++o?n.length=o:delete this.__on}}}function uM(e,n,r){return function(){var o=this.__on,i,l=aM(n);if(o){for(var c=0,f=o.length;c<f;++c)if((i=o[c]).type===e.type&&i.name===e.name){this.removeEventListener(i.type,i.listener,i.options),this.addEventListener(i.type,i.listener=l,i.options=r),i.value=n;return}}this.addEventListener(e.type,l,r),i={type:e.type,name:e.name,value:n,listener:l,options:r},o?o.push(i):this.__on=[i]}}function cM(e,n,r){var o=sM(e+""),i,l=o.length,c;if(arguments.length<2){var f=this.node().__on;if(f){for(var m=0,g=f.length,d;m<g;++m)for(i=0,d=f[m];i<l;++i)if((c=o[i]).type===d.type&&c.name===d.name)return d.value}return}for(f=n?uM:lM,i=0;i<l;++i)this.each(f(o[i],n,r));return this}function oS(e,n,r){var o=$_(e),i=o.CustomEvent;typeof i=="function"?i=new i(n,r):(i=o.document.createEvent("Event"),r?(i.initEvent(n,r.bubbles,r.cancelable),i.detail=r.detail):i.initEvent(n,!1,!1)),e.dispatchEvent(i)}function fM(e,n){return function(){return oS(this,e,n)}}function dM(e,n){return function(){return oS(this,e,n.apply(this,arguments))}}function hM(e,n){return this.each((typeof n=="function"?dM:fM)(e,n))}function*pM(){for(var e=this._groups,n=0,r=e.length;n<r;++n)for(var o=e[n],i=0,l=o.length,c;i<l;++i)(c=o[i])&&(yield c)}var iS=[null];function kn(e,n){this._groups=e,this._parents=n}function Gi(){return new kn([[document.documentElement]],iS)}function mM(){return this}kn.prototype=Gi.prototype={constructor:kn,select:zP,selectAll:WP,selectChild:XP,selectChildren:$P,filter:eI,data:aI,enter:tI,exit:lI,join:uI,merge:cI,selection:mM,order:fI,sort:dI,call:pI,nodes:mI,node:gI,size:vI,empty:yI,each:bI,attr:kI,style:TI,property:MI,classed:BI,text:HI,html:GI,raise:YI,lower:ZI,append:QI,insert:$I,remove:tM,clone:oM,datum:iM,on:cM,dispatch:hM,[Symbol.iterator]:pM};function jn(e){return typeof e=="string"?new kn([[document.querySelector(e)]],[document.documentElement]):new kn([[e]],iS)}function gM(e){let n;for(;n=e.sourceEvent;)e=n;return e}function $n(e,n){if(e=gM(e),n===void 0&&(n=e.currentTarget),n){var r=n.ownerSVGElement||n;if(r.createSVGPoint){var o=r.createSVGPoint();return o.x=e.clientX,o.y=e.clientY,o=o.matrixTransform(n.getScreenCTM().inverse()),[o.x,o.y]}if(n.getBoundingClientRect){var i=n.getBoundingClientRect();return[e.clientX-i.left-n.clientLeft,e.clientY-i.top-n.clientTop]}}return[e.pageX,e.pageY]}const vM={passive:!1},Ki={capture:!0,passive:!1};function km(e){e.stopImmediatePropagation()}function Uo(e){e.preventDefault(),e.stopImmediatePropagation()}function aS(e){var n=e.document.documentElement,r=jn(e).on("dragstart.drag",Uo,Ki);"onselectstart"in n?r.on("selectstart.drag",Uo,Ki):(n.__noselect=n.style.MozUserSelect,n.style.MozUserSelect="none")}function sS(e,n){var r=e.document.documentElement,o=jn(e).on("dragstart.drag",null);n&&(o.on("click.drag",Uo,Ki),setTimeout(function(){o.on("click.drag",null)},0)),"onselectstart"in r?o.on("selectstart.drag",null):(r.style.MozUserSelect=r.__noselect,delete r.__noselect)}const As=e=>()=>e;function Cm(e,{sourceEvent:n,subject:r,target:o,identifier:i,active:l,x:c,y:f,dx:m,dy:g,dispatch:d}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:n,enumerable:!0,configurable:!0},subject:{value:r,enumerable:!0,configurable:!0},target:{value:o,enumerable:!0,configurable:!0},identifier:{value:i,enumerable:!0,configurable:!0},active:{value:l,enumerable:!0,configurable:!0},x:{value:c,enumerable:!0,configurable:!0},y:{value:f,enumerable:!0,configurable:!0},dx:{value:m,enumerable:!0,configurable:!0},dy:{value:g,enumerable:!0,configurable:!0},_:{value:d}})}Cm.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function yM(e){return!e.ctrlKey&&!e.button}function bM(){return this.parentNode}function wM(e,n){return n??{x:e.x,y:e.y}}function xM(){return navigator.maxTouchPoints||"ontouchstart"in this}function _M(){var e=yM,n=bM,r=wM,o=xM,i={},l=Es("start","drag","end"),c=0,f,m,g,d,p=0;function h(x){x.on("mousedown.drag",s).filter(o).on("touchstart.drag",_).on("touchmove.drag",w,vM).on("touchend.drag touchcancel.drag",y).style("touch-action","none").style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}function s(x,k){if(!(d||!e.call(this,x,k))){var P=E(this,n.call(this,x,k),x,k,"mouse");P&&(jn(x.view).on("mousemove.drag",S,Ki).on("mouseup.drag",b,Ki),aS(x.view),km(x),g=!1,f=x.clientX,m=x.clientY,P("start",x))}}function S(x){if(Uo(x),!g){var k=x.clientX-f,P=x.clientY-m;g=k*k+P*P>p}i.mouse("drag",x)}function b(x){jn(x.view).on("mousemove.drag mouseup.drag",null),sS(x.view,g),Uo(x),i.mouse("end",x)}function _(x,k){if(e.call(this,x,k)){var P=x.changedTouches,R=n.call(this,x,k),j=P.length,z,L;for(z=0;z<j;++z)(L=E(this,R,x,k,P[z].identifier,P[z]))&&(km(x),L("start",x,P[z]))}}function w(x){var k=x.changedTouches,P=k.length,R,j;for(R=0;R<P;++R)(j=i[k[R].identifier])&&(Uo(x),j("drag",x,k[R]))}function y(x){var k=x.changedTouches,P=k.length,R,j;for(d&&clearTimeout(d),d=setTimeout(function(){d=null},500),R=0;R<P;++R)(j=i[k[R].identifier])&&(km(x),j("end",x,k[R]))}function E(x,k,P,R,j,z){var L=l.copy(),M=$n(z||P,k),D,F,B;if((B=r.call(x,new Cm("beforestart",{sourceEvent:P,target:h,identifier:j,active:c,x:M[0],y:M[1],dx:0,dy:0,dispatch:L}),R))!=null)return D=B.x-M[0]||0,F=B.y-M[1]||0,function U(J,oe,de){var Y=M,ee;switch(J){case"start":i[j]=U,ee=c++;break;case"end":delete i[j],--c;case"drag":M=$n(de||oe,k),ee=c;break}L.call(J,x,new Cm(J,{sourceEvent:oe,subject:B,target:h,identifier:j,active:ee,x:M[0]+D,y:M[1]+F,dx:M[0]-Y[0],dy:M[1]-Y[1],dispatch:L}),R)}}return h.filter=function(x){return arguments.length?(e=typeof x=="function"?x:As(!!x),h):e},h.container=function(x){return arguments.length?(n=typeof x=="function"?x:As(x),h):n},h.subject=function(x){return arguments.length?(r=typeof x=="function"?x:As(x),h):r},h.touchable=function(x){return arguments.length?(o=typeof x=="function"?x:As(!!x),h):o},h.on=function(){var x=l.on.apply(l,arguments);return x===l?h:x},h.clickDistance=function(x){return arguments.length?(p=(x=+x)*x,h):Math.sqrt(p)},h}function Am(e,n,r){e.prototype=n.prototype=r,r.constructor=e}function lS(e,n){var r=Object.create(e.prototype);for(var o in n)r[o]=n[o];return r}function Yi(){}var Xi=.7,Ns=1/Xi,Wo="\\s*([+-]?\\d+)\\s*",Zi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",fr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",SM=/^#([0-9a-f]{3,8})$/,EM=new RegExp(`^rgb\\(${Wo},${Wo},${Wo}\\)$`),OM=new RegExp(`^rgb\\(${fr},${fr},${fr}\\)$`),kM=new RegExp(`^rgba\\(${Wo},${Wo},${Wo},${Zi}\\)$`),CM=new RegExp(`^rgba\\(${fr},${fr},${fr},${Zi}\\)$`),AM=new RegExp(`^hsl\\(${Zi},${fr},${fr}\\)$`),NM=new RegExp(`^hsla\\(${Zi},${fr},${fr},${Zi}\\)$`),uS={aliceblue:15792383,antiquewhite:16444375,aqua:65535,aquamarine:8388564,azure:15794175,beige:16119260,bisque:16770244,black:0,blanchedalmond:16772045,blue:255,blueviolet:9055202,brown:10824234,burlywood:14596231,cadetblue:6266528,chartreuse:8388352,chocolate:13789470,coral:16744272,cornflowerblue:6591981,cornsilk:16775388,crimson:14423100,cyan:65535,darkblue:139,darkcyan:35723,darkgoldenrod:12092939,darkgray:11119017,darkgreen:25600,darkgrey:11119017,darkkhaki:12433259,darkmagenta:9109643,darkolivegreen:5597999,darkorange:16747520,darkorchid:10040012,darkred:9109504,darksalmon:15308410,darkseagreen:9419919,darkslateblue:4734347,darkslategray:3100495,darkslategrey:3100495,darkturquoise:52945,darkviolet:9699539,deeppink:16716947,deepskyblue:49151,dimgray:6908265,dimgrey:6908265,dodgerblue:2003199,firebrick:11674146,floralwhite:16775920,forestgreen:2263842,fuchsia:16711935,gainsboro:14474460,ghostwhite:16316671,gold:16766720,goldenrod:14329120,gray:8421504,green:32768,greenyellow:11403055,grey:8421504,honeydew:15794160,hotpink:16738740,indianred:13458524,indigo:4915330,ivory:16777200,khaki:15787660,lavender:15132410,lavenderblush:16773365,lawngreen:8190976,lemonchiffon:16775885,lightblue:11393254,lightcoral:15761536,lightcyan:14745599,lightgoldenrodyellow:16448210,lightgray:13882323,lightgreen:9498256,lightgrey:13882323,lightpink:16758465,lightsalmon:16752762,lightseagreen:2142890,lightskyblue:8900346,lightslategray:7833753,lightslategrey:7833753,lightsteelblue:11584734,lightyellow:16777184,lime:65280,limegreen:3329330,linen:16445670,magenta:16711935,maroon:8388608,mediumaquamarine:6737322,mediumblue:205,mediumorchid:12211667,mediumpurple:9662683,mediumseagreen:3978097,mediumslateblue:8087790,mediumspringgreen:64154,mediumturquoise:4772300,mediumvioletred:13047173,midnightblue:1644912,mintcream:16121850,mistyrose:16770273,moccasin:16770229,navajowhite:16768685,navy:128,oldlace:16643558,olive:8421376,olivedrab:7048739,orange:16753920,orangered:16729344,orchid:14315734,palegoldenrod:15657130,palegreen:10025880,paleturquoise:11529966,palevioletred:14381203,papayawhip:16773077,peachpuff:16767673,peru:13468991,pink:16761035,plum:14524637,powderblue:11591910,purple:8388736,rebeccapurple:6697881,red:16711680,rosybrown:12357519,royalblue:4286945,saddlebrown:9127187,salmon:16416882,sandybrown:16032864,seagreen:3050327,seashell:16774638,sienna:10506797,silver:12632256,skyblue:8900331,slateblue:6970061,slategray:7372944,slategrey:7372944,snow:16775930,springgreen:65407,steelblue:4620980,tan:13808780,teal:32896,thistle:14204888,tomato:16737095,turquoise:4251856,violet:15631086,wheat:16113331,white:16777215,whitesmoke:16119285,yellow:16776960,yellowgreen:10145074};Am(Yi,Qi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:cS,formatHex:cS,formatHex8:TM,formatHsl:RM,formatRgb:fS,toString:fS});function cS(){return this.rgb().formatHex()}function TM(){return this.rgb().formatHex8()}function RM(){return gS(this).formatHsl()}function fS(){return this.rgb().formatRgb()}function Qi(e){var n,r;return e=(e+"").trim().toLowerCase(),(n=SM.exec(e))?(r=n[1].length,n=parseInt(n[1],16),r===6?dS(n):r===3?new xn(n>>8&15|n>>4&240,n>>4&15|n&240,(n&15)<<4|n&15,1):r===8?Ts(n>>24&255,n>>16&255,n>>8&255,(n&255)/255):r===4?Ts(n>>12&15|n>>8&240,n>>8&15|n>>4&240,n>>4&15|n&240,((n&15)<<4|n&15)/255):null):(n=EM.exec(e))?new xn(n[1],n[2],n[3],1):(n=OM.exec(e))?new xn(n[1]*255/100,n[2]*255/100,n[3]*255/100,1):(n=kM.exec(e))?Ts(n[1],n[2],n[3],n[4]):(n=CM.exec(e))?Ts(n[1]*255/100,n[2]*255/100,n[3]*255/100,n[4]):(n=AM.exec(e))?mS(n[1],n[2]/100,n[3]/100,1):(n=NM.exec(e))?mS(n[1],n[2]/100,n[3]/100,n[4]):uS.hasOwnProperty(e)?dS(uS[e]):e==="transparent"?new xn(NaN,NaN,NaN,0):null}function dS(e){return new xn(e>>16&255,e>>8&255,e&255,1)}function Ts(e,n,r,o){return o<=0&&(e=n=r=NaN),new xn(e,n,r,o)}function PM(e){return e instanceof Yi||(e=Qi(e)),e?(e=e.rgb(),new xn(e.r,e.g,e.b,e.opacity)):new xn}function Nm(e,n,r,o){return arguments.length===1?PM(e):new xn(e,n,r,o??1)}function xn(e,n,r,o){this.r=+e,this.g=+n,this.b=+r,this.opacity=+o}Am(xn,Nm,lS(Yi,{brighter(e){return e=e==null?Ns:Math.pow(Ns,e),new xn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Xi:Math.pow(Xi,e),new xn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new xn(po(this.r),po(this.g),po(this.b),Rs(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:hS,formatHex:hS,formatHex8:IM,formatRgb:pS,toString:pS}));function hS(){return`#${mo(this.r)}${mo(this.g)}${mo(this.b)}`}function IM(){return`#${mo(this.r)}${mo(this.g)}${mo(this.b)}${mo((isNaN(this.opacity)?1:this.opacity)*255)}`}function pS(){const e=Rs(this.opacity);return`${e===1?"rgb(":"rgba("}${po(this.r)}, ${po(this.g)}, ${po(this.b)}${e===1?")":`, ${e})`}`}function Rs(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function po(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function mo(e){return e=po(e),(e<16?"0":"")+e.toString(16)}function mS(e,n,r,o){return o<=0?e=n=r=NaN:r<=0||r>=1?e=n=NaN:n<=0&&(e=NaN),new er(e,n,r,o)}function gS(e){if(e instanceof er)return new er(e.h,e.s,e.l,e.opacity);if(e instanceof Yi||(e=Qi(e)),!e)return new er;if(e instanceof er)return e;e=e.rgb();var n=e.r/255,r=e.g/255,o=e.b/255,i=Math.min(n,r,o),l=Math.max(n,r,o),c=NaN,f=l-i,m=(l+i)/2;return f?(n===l?c=(r-o)/f+(r<o)*6:r===l?c=(o-n)/f+2:c=(n-r)/f+4,f/=m<.5?l+i:2-l-i,c*=60):f=m>0&&m<1?0:c,new er(c,f,m,e.opacity)}function MM(e,n,r,o){return arguments.length===1?gS(e):new er(e,n,r,o??1)}function er(e,n,r,o){this.h=+e,this.s=+n,this.l=+r,this.opacity=+o}Am(er,MM,lS(Yi,{brighter(e){return e=e==null?Ns:Math.pow(Ns,e),new er(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Xi:Math.pow(Xi,e),new er(this.h,this.s,this.l*e,this.opacity)},rgb(){var e=this.h%360+(this.h<0)*360,n=isNaN(e)||isNaN(this.s)?0:this.s,r=this.l,o=r+(r<.5?r:1-r)*n,i=2*r-o;return new xn(Tm(e>=240?e-240:e+120,i,o),Tm(e,i,o),Tm(e<120?e+240:e-120,i,o),this.opacity)},clamp(){return new er(vS(this.h),Ps(this.s),Ps(this.l),Rs(this.opacity))},displayable(){return(0<=this.s&&this.s<=1||isNaN(this.s))&&0<=this.l&&this.l<=1&&0<=this.opacity&&this.opacity<=1},formatHsl(){const e=Rs(this.opacity);return`${e===1?"hsl(":"hsla("}${vS(this.h)}, ${Ps(this.s)*100}%, ${Ps(this.l)*100}%${e===1?")":`, ${e})`}`}}));function vS(e){return e=(e||0)%360,e<0?e+360:e}function Ps(e){return Math.max(0,Math.min(1,e||0))}function Tm(e,n,r){return(e<60?n+(r-n)*e/60:e<180?r:e<240?n+(r-n)*(240-e)/60:n)*255}const yS=e=>()=>e;function jM(e,n){return function(r){return e+r*n}}function LM(e,n,r){return e=Math.pow(e,r),n=Math.pow(n,r)-e,r=1/r,function(o){return Math.pow(e+o*n,r)}}function DM(e){return(e=+e)==1?bS:function(n,r){return r-n?LM(n,r,e):yS(isNaN(n)?r:n)}}function bS(e,n){var r=n-e;return r?jM(e,r):yS(isNaN(e)?n:e)}const wS=(function e(n){var r=DM(n);function o(i,l){var c=r((i=Nm(i)).r,(l=Nm(l)).r),f=r(i.g,l.g),m=r(i.b,l.b),g=bS(i.opacity,l.opacity);return function(d){return i.r=c(d),i.g=f(d),i.b=m(d),i.opacity=g(d),i+""}}return o.gamma=e,o})(1);function Kr(e,n){return e=+e,n=+n,function(r){return e*(1-r)+n*r}}var Rm=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Pm=new RegExp(Rm.source,"g");function BM(e){return function(){return e}}function FM(e){return function(n){return e(n)+""}}function qM(e,n){var r=Rm.lastIndex=Pm.lastIndex=0,o,i,l,c=-1,f=[],m=[];for(e=e+"",n=n+"";(o=Rm.exec(e))&&(i=Pm.exec(n));)(l=i.index)>r&&(l=n.slice(r,l),f[c]?f[c]+=l:f[++c]=l),(o=o[0])===(i=i[0])?f[c]?f[c]+=i:f[++c]=i:(f[++c]=null,m.push({i:c,x:Kr(o,i)})),r=Pm.lastIndex;return r<n.length&&(l=n.slice(r),f[c]?f[c]+=l:f[++c]=l),f.length<2?m[0]?FM(m[0].x):BM(n):(n=m.length,function(g){for(var d=0,p;d<n;++d)f[(p=m[d]).i]=p.x(g);return f.join("")})}var xS=180/Math.PI,Im={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function _S(e,n,r,o,i,l){var c,f,m;return(c=Math.sqrt(e*e+n*n))&&(e/=c,n/=c),(m=e*r+n*o)&&(r-=e*m,o-=n*m),(f=Math.sqrt(r*r+o*o))&&(r/=f,o/=f,m/=f),e*o<n*r&&(e=-e,n=-n,m=-m,c=-c),{translateX:i,translateY:l,rotate:Math.atan2(n,e)*xS,skewX:Math.atan(m)*xS,scaleX:c,scaleY:f}}var Is;function zM(e){const n=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return n.isIdentity?Im:_S(n.a,n.b,n.c,n.d,n.e,n.f)}function HM(e){return e==null||(Is||(Is=document.createElementNS("http://www.w3.org/2000/svg","g")),Is.setAttribute("transform",e),!(e=Is.transform.baseVal.consolidate()))?Im:(e=e.matrix,_S(e.a,e.b,e.c,e.d,e.e,e.f))}function SS(e,n,r,o){function i(g){return g.length?g.pop()+" ":""}function l(g,d,p,h,s,S){if(g!==p||d!==h){var b=s.push("translate(",null,n,null,r);S.push({i:b-4,x:Kr(g,p)},{i:b-2,x:Kr(d,h)})}else(p||h)&&s.push("translate("+p+n+h+r)}function c(g,d,p,h){g!==d?(g-d>180?d+=360:d-g>180&&(g+=360),h.push({i:p.push(i(p)+"rotate(",null,o)-2,x:Kr(g,d)})):d&&p.push(i(p)+"rotate("+d+o)}function f(g,d,p,h){g!==d?h.push({i:p.push(i(p)+"skewX(",null,o)-2,x:Kr(g,d)}):d&&p.push(i(p)+"skewX("+d+o)}function m(g,d,p,h,s,S){if(g!==p||d!==h){var b=s.push(i(s)+"scale(",null,",",null,")");S.push({i:b-4,x:Kr(g,p)},{i:b-2,x:Kr(d,h)})}else(p!==1||h!==1)&&s.push(i(s)+"scale("+p+","+h+")")}return function(g,d){var p=[],h=[];return g=e(g),d=e(d),l(g.translateX,g.translateY,d.translateX,d.translateY,p,h),c(g.rotate,d.rotate,p,h),f(g.skewX,d.skewX,p,h),m(g.scaleX,g.scaleY,d.scaleX,d.scaleY,p,h),g=d=null,function(s){for(var S=-1,b=h.length,_;++S<b;)p[(_=h[S]).i]=_.x(s);return p.join("")}}}var VM=SS(zM,"px, ","px)","deg)"),UM=SS(HM,", ",")",")"),WM=1e-12;function ES(e){return((e=Math.exp(e))+1/e)/2}function GM(e){return((e=Math.exp(e))-1/e)/2}function KM(e){return((e=Math.exp(2*e))-1)/(e+1)}const YM=(function e(n,r,o){function i(l,c){var f=l[0],m=l[1],g=l[2],d=c[0],p=c[1],h=c[2],s=d-f,S=p-m,b=s*s+S*S,_,w;if(b<WM)w=Math.log(h/g)/n,_=function(R){return[f+R*s,m+R*S,g*Math.exp(n*R*w)]};else{var y=Math.sqrt(b),E=(h*h-g*g+o*b)/(2*g*r*y),x=(h*h-g*g-o*b)/(2*h*r*y),k=Math.log(Math.sqrt(E*E+1)-E),P=Math.log(Math.sqrt(x*x+1)-x);w=(P-k)/n,_=function(R){var j=R*w,z=ES(k),L=g/(r*y)*(z*KM(n*j+k)-GM(k));return[f+L*s,m+L*S,g*z/ES(n*j+k)]}}return _.duration=w*1e3*n/Math.SQRT2,_}return i.rho=function(l){var c=Math.max(.001,+l),f=c*c,m=f*f;return e(c,f,m)},i})(Math.SQRT2,2,4);var Go=0,Ji=0,$i=0,OS=1e3,Ms,ea,js=0,go=0,Ls=0,ta=typeof performance=="object"&&performance.now?performance:Date,kS=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Mm(){return go||(kS(XM),go=ta.now()+Ls)}function XM(){go=0}function Ds(){this._call=this._time=this._next=null}Ds.prototype=CS.prototype={constructor:Ds,restart:function(e,n,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?Mm():+r)+(n==null?0:+n),!this._next&&ea!==this&&(ea?ea._next=this:Ms=this,ea=this),this._call=e,this._time=r,jm()},stop:function(){this._call&&(this._call=null,this._time=1/0,jm())}};function CS(e,n,r){var o=new Ds;return o.restart(e,n,r),o}function ZM(){Mm(),++Go;for(var e=Ms,n;e;)(n=go-e._time)>=0&&e._call.call(void 0,n),e=e._next;--Go}function AS(){go=(js=ta.now())+Ls,Go=Ji=0;try{ZM()}finally{Go=0,JM(),go=0}}function QM(){var e=ta.now(),n=e-js;n>OS&&(Ls-=n,js=e)}function JM(){for(var e,n=Ms,r,o=1/0;n;)n._call?(o>n._time&&(o=n._time),e=n,n=n._next):(r=n._next,n._next=null,n=e?e._next=r:Ms=r);ea=e,jm(o)}function jm(e){if(!Go){Ji&&(Ji=clearTimeout(Ji));var n=e-go;n>24?(e<1/0&&(Ji=setTimeout(AS,e-ta.now()-Ls)),$i&&($i=clearInterval($i))):($i||(js=ta.now(),$i=setInterval(QM,OS)),Go=1,kS(AS))}}function NS(e,n,r){var o=new Ds;return n=n==null?0:+n,o.restart(i=>{o.stop(),e(i+n)},n,r),o}var $M=Es("start","end","cancel","interrupt"),ej=[],TS=0,RS=1,Lm=2,Bs=3,PS=4,Dm=5,Fs=6;function qs(e,n,r,o,i,l){var c=e.__transition;if(!c)e.__transition={};else if(r in c)return;tj(e,r,{name:n,index:o,group:i,on:$M,tween:ej,time:l.time,delay:l.delay,duration:l.duration,ease:l.ease,timer:null,state:TS})}function Bm(e,n){var r=tr(e,n);if(r.state>TS)throw new Error("too late; already scheduled");return r}function dr(e,n){var r=tr(e,n);if(r.state>Bs)throw new Error("too late; already running");return r}function tr(e,n){var r=e.__transition;if(!r||!(r=r[n]))throw new Error("transition not found");return r}function tj(e,n,r){var o=e.__transition,i;o[n]=r,r.timer=CS(l,0,r.time);function l(g){r.state=RS,r.timer.restart(c,r.delay,r.time),r.delay<=g&&c(g-r.delay)}function c(g){var d,p,h,s;if(r.state!==RS)return m();for(d in o)if(s=o[d],s.name===r.name){if(s.state===Bs)return NS(c);s.state===PS?(s.state=Fs,s.timer.stop(),s.on.call("interrupt",e,e.__data__,s.index,s.group),delete o[d]):+d<n&&(s.state=Fs,s.timer.stop(),s.on.call("cancel",e,e.__data__,s.index,s.group),delete o[d])}if(NS(function(){r.state===Bs&&(r.state=PS,r.timer.restart(f,r.delay,r.time),f(g))}),r.state=Lm,r.on.call("start",e,e.__data__,r.index,r.group),r.state===Lm){for(r.state=Bs,i=new Array(h=r.tween.length),d=0,p=-1;d<h;++d)(s=r.tween[d].value.call(e,e.__data__,r.index,r.group))&&(i[++p]=s);i.length=p+1}}function f(g){for(var d=g<r.duration?r.ease.call(null,g/r.duration):(r.timer.restart(m),r.state=Dm,1),p=-1,h=i.length;++p<h;)i[p].call(e,d);r.state===Dm&&(r.on.call("end",e,e.__data__,r.index,r.group),m())}function m(){r.state=Fs,r.timer.stop(),delete o[n];for(var g in o)return;delete e.__transition}}function zs(e,n){var r=e.__transition,o,i,l=!0,c;if(r){n=n==null?null:n+"";for(c in r){if((o=r[c]).name!==n){l=!1;continue}i=o.state>Lm&&o.state<Dm,o.state=Fs,o.timer.stop(),o.on.call(i?"interrupt":"cancel",e,e.__data__,o.index,o.group),delete r[c]}l&&delete e.__transition}}function nj(e){return this.each(function(){zs(this,e)})}function rj(e,n){var r,o;return function(){var i=dr(this,e),l=i.tween;if(l!==r){o=r=l;for(var c=0,f=o.length;c<f;++c)if(o[c].name===n){o=o.slice(),o.splice(c,1);break}}i.tween=o}}function oj(e,n,r){var o,i;if(typeof r!="function")throw new Error;return function(){var l=dr(this,e),c=l.tween;if(c!==o){i=(o=c).slice();for(var f={name:n,value:r},m=0,g=i.length;m<g;++m)if(i[m].name===n){i[m]=f;break}m===g&&i.push(f)}l.tween=i}}function ij(e,n){var r=this._id;if(e+="",arguments.length<2){for(var o=tr(this.node(),r).tween,i=0,l=o.length,c;i<l;++i)if((c=o[i]).name===e)return c.value;return null}return this.each((n==null?rj:oj)(r,e,n))}function Fm(e,n,r){var o=e._id;return e.each(function(){var i=dr(this,o);(i.value||(i.value={}))[n]=r.apply(this,arguments)}),function(i){return tr(i,o).value[n]}}function IS(e,n){var r;return(typeof n=="number"?Kr:n instanceof Qi?wS:(r=Qi(n))?(n=r,wS):qM)(e,n)}function aj(e){return function(){this.removeAttribute(e)}}function sj(e){return function(){this.removeAttributeNS(e.space,e.local)}}function lj(e,n,r){var o,i=r+"",l;return function(){var c=this.getAttribute(e);return c===i?null:c===o?l:l=n(o=c,r)}}function uj(e,n,r){var o,i=r+"",l;return function(){var c=this.getAttributeNS(e.space,e.local);return c===i?null:c===o?l:l=n(o=c,r)}}function cj(e,n,r){var o,i,l;return function(){var c,f=r(this),m;return f==null?void this.removeAttribute(e):(c=this.getAttribute(e),m=f+"",c===m?null:c===o&&m===i?l:(i=m,l=n(o=c,f)))}}function fj(e,n,r){var o,i,l;return function(){var c,f=r(this),m;return f==null?void this.removeAttributeNS(e.space,e.local):(c=this.getAttributeNS(e.space,e.local),m=f+"",c===m?null:c===o&&m===i?l:(i=m,l=n(o=c,f)))}}function dj(e,n){var r=ks(e),o=r==="transform"?UM:IS;return this.attrTween(e,typeof n=="function"?(r.local?fj:cj)(r,o,Fm(this,"attr."+e,n)):n==null?(r.local?sj:aj)(r):(r.local?uj:lj)(r,o,n))}function hj(e,n){return function(r){this.setAttribute(e,n.call(this,r))}}function pj(e,n){return function(r){this.setAttributeNS(e.space,e.local,n.call(this,r))}}function mj(e,n){var r,o;function i(){var l=n.apply(this,arguments);return l!==o&&(r=(o=l)&&pj(e,l)),r}return i._value=n,i}function gj(e,n){var r,o;function i(){var l=n.apply(this,arguments);return l!==o&&(r=(o=l)&&hj(e,l)),r}return i._value=n,i}function vj(e,n){var r="attr."+e;if(arguments.length<2)return(r=this.tween(r))&&r._value;if(n==null)return this.tween(r,null);if(typeof n!="function")throw new Error;var o=ks(e);return this.tween(r,(o.local?mj:gj)(o,n))}function yj(e,n){return function(){Bm(this,e).delay=+n.apply(this,arguments)}}function bj(e,n){return n=+n,function(){Bm(this,e).delay=n}}function wj(e){var n=this._id;return arguments.length?this.each((typeof e=="function"?yj:bj)(n,e)):tr(this.node(),n).delay}function xj(e,n){return function(){dr(this,e).duration=+n.apply(this,arguments)}}function _j(e,n){return n=+n,function(){dr(this,e).duration=n}}function Sj(e){var n=this._id;return arguments.length?this.each((typeof e=="function"?xj:_j)(n,e)):tr(this.node(),n).duration}function Ej(e,n){if(typeof n!="function")throw new Error;return function(){dr(this,e).ease=n}}function Oj(e){var n=this._id;return arguments.length?this.each(Ej(n,e)):tr(this.node(),n).ease}function kj(e,n){return function(){var r=n.apply(this,arguments);if(typeof r!="function")throw new Error;dr(this,e).ease=r}}function Cj(e){if(typeof e!="function")throw new Error;return this.each(kj(this._id,e))}function Aj(e){typeof e!="function"&&(e=Z_(e));for(var n=this._groups,r=n.length,o=new Array(r),i=0;i<r;++i)for(var l=n[i],c=l.length,f=o[i]=[],m,g=0;g<c;++g)(m=l[g])&&e.call(m,m.__data__,g,l)&&f.push(m);return new kr(o,this._parents,this._name,this._id)}function Nj(e){if(e._id!==this._id)throw new Error;for(var n=this._groups,r=e._groups,o=n.length,i=r.length,l=Math.min(o,i),c=new Array(o),f=0;f<l;++f)for(var m=n[f],g=r[f],d=m.length,p=c[f]=new Array(d),h,s=0;s<d;++s)(h=m[s]||g[s])&&(p[s]=h);for(;f<o;++f)c[f]=n[f];return new kr(c,this._parents,this._name,this._id)}function Tj(e){return(e+"").trim().split(/^|\s+/).every(function(n){var r=n.indexOf(".");return r>=0&&(n=n.slice(0,r)),!n||n==="start"})}function Rj(e,n,r){var o,i,l=Tj(n)?Bm:dr;return function(){var c=l(this,e),f=c.on;f!==o&&(i=(o=f).copy()).on(n,r),c.on=i}}function Pj(e,n){var r=this._id;return arguments.length<2?tr(this.node(),r).on.on(e):this.each(Rj(r,e,n))}function Ij(e){return function(){var n=this.parentNode;for(var r in this.__transition)if(+r!==e)return;n&&n.removeChild(this)}}function Mj(){return this.on("end.remove",Ij(this._id))}function jj(e){var n=this._name,r=this._id;typeof e!="function"&&(e=Em(e));for(var o=this._groups,i=o.length,l=new Array(i),c=0;c<i;++c)for(var f=o[c],m=f.length,g=l[c]=new Array(m),d,p,h=0;h<m;++h)(d=f[h])&&(p=e.call(d,d.__data__,h,f))&&("__data__"in d&&(p.__data__=d.__data__),g[h]=p,qs(g[h],n,r,h,g,tr(d,r)));return new kr(l,this._parents,n,r)}function Lj(e){var n=this._name,r=this._id;typeof e!="function"&&(e=X_(e));for(var o=this._groups,i=o.length,l=[],c=[],f=0;f<i;++f)for(var m=o[f],g=m.length,d,p=0;p<g;++p)if(d=m[p]){for(var h=e.call(d,d.__data__,p,m),s,S=tr(d,r),b=0,_=h.length;b<_;++b)(s=h[b])&&qs(s,n,r,b,h,S);l.push(h),c.push(d)}return new kr(l,c,n,r)}var Dj=Gi.prototype.constructor;function Bj(){return new Dj(this._groups,this._parents)}function Fj(e,n){var r,o,i;return function(){var l=Vo(this,e),c=(this.style.removeProperty(e),Vo(this,e));return l===c?null:l===r&&c===o?i:i=n(r=l,o=c)}}function MS(e){return function(){this.style.removeProperty(e)}}function qj(e,n,r){var o,i=r+"",l;return function(){var c=Vo(this,e);return c===i?null:c===o?l:l=n(o=c,r)}}function zj(e,n,r){var o,i,l;return function(){var c=Vo(this,e),f=r(this),m=f+"";return f==null&&(m=f=(this.style.removeProperty(e),Vo(this,e))),c===m?null:c===o&&m===i?l:(i=m,l=n(o=c,f))}}function Hj(e,n){var r,o,i,l="style."+n,c="end."+l,f;return function(){var m=dr(this,e),g=m.on,d=m.value[l]==null?f||(f=MS(n)):void 0;(g!==r||i!==d)&&(o=(r=g).copy()).on(c,i=d),m.on=o}}function Vj(e,n,r){var o=(e+="")=="transform"?VM:IS;return n==null?this.styleTween(e,Fj(e,o)).on("end.style."+e,MS(e)):typeof n=="function"?this.styleTween(e,zj(e,o,Fm(this,"style."+e,n))).each(Hj(this._id,e)):this.styleTween(e,qj(e,o,n),r).on("end.style."+e,null)}function Uj(e,n,r){return function(o){this.style.setProperty(e,n.call(this,o),r)}}function Wj(e,n,r){var o,i;function l(){var c=n.apply(this,arguments);return c!==i&&(o=(i=c)&&Uj(e,c,r)),o}return l._value=n,l}function Gj(e,n,r){var o="style."+(e+="");if(arguments.length<2)return(o=this.tween(o))&&o._value;if(n==null)return this.tween(o,null);if(typeof n!="function")throw new Error;return this.tween(o,Wj(e,n,r??""))}function Kj(e){return function(){this.textContent=e}}function Yj(e){return function(){var n=e(this);this.textContent=n??""}}function Xj(e){return this.tween("text",typeof e=="function"?Yj(Fm(this,"text",e)):Kj(e==null?"":e+""))}function Zj(e){return function(n){this.textContent=e.call(this,n)}}function Qj(e){var n,r;function o(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Zj(i)),n}return o._value=e,o}function Jj(e){var n="text";if(arguments.length<1)return(n=this.tween(n))&&n._value;if(e==null)return this.tween(n,null);if(typeof e!="function")throw new Error;return this.tween(n,Qj(e))}function $j(){for(var e=this._name,n=this._id,r=jS(),o=this._groups,i=o.length,l=0;l<i;++l)for(var c=o[l],f=c.length,m,g=0;g<f;++g)if(m=c[g]){var d=tr(m,n);qs(m,e,r,g,c,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new kr(o,this._parents,e,r)}function e5(){var e,n,r=this,o=r._id,i=r.size();return new Promise(function(l,c){var f={value:c},m={value:function(){--i===0&&l()}};r.each(function(){var g=dr(this,o),d=g.on;d!==e&&(n=(e=d).copy(),n._.cancel.push(f),n._.interrupt.push(f),n._.end.push(m)),g.on=n}),i===0&&l()})}var t5=0;function kr(e,n,r,o){this._groups=e,this._parents=n,this._name=r,this._id=o}function jS(){return++t5}var Cr=Gi.prototype;kr.prototype={constructor:kr,select:jj,selectAll:Lj,selectChild:Cr.selectChild,selectChildren:Cr.selectChildren,filter:Aj,merge:Nj,selection:Bj,transition:$j,call:Cr.call,nodes:Cr.nodes,node:Cr.node,size:Cr.size,empty:Cr.empty,each:Cr.each,on:Pj,attr:dj,attrTween:vj,style:Vj,styleTween:Gj,text:Xj,textTween:Jj,remove:Mj,tween:ij,delay:wj,duration:Sj,ease:Oj,easeVarying:Cj,end:e5,[Symbol.iterator]:Cr[Symbol.iterator]};function n5(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var r5={time:null,delay:0,duration:250,ease:n5};function o5(e,n){for(var r;!(r=e.__transition)||!(r=r[n]);)if(!(e=e.parentNode))throw new Error(`transition ${n} not found`);return r}function i5(e){var n,r;e instanceof kr?(n=e._id,e=e._name):(n=jS(),(r=r5).time=Mm(),e=e==null?null:e+"");for(var o=this._groups,i=o.length,l=0;l<i;++l)for(var c=o[l],f=c.length,m,g=0;g<f;++g)(m=c[g])&&qs(m,e,n,g,c,r||o5(m,n));return new kr(o,this._parents,e,n)}Gi.prototype.interrupt=nj,Gi.prototype.transition=i5;const Hs=e=>()=>e;function a5(e,{sourceEvent:n,target:r,transform:o,dispatch:i}){Object.defineProperties(this,{type:{value:e,enumerable:!0,configurable:!0},sourceEvent:{value:n,enumerable:!0,configurable:!0},target:{value:r,enumerable:!0,configurable:!0},transform:{value:o,enumerable:!0,configurable:!0},_:{value:i}})}function Ar(e,n,r){this.k=e,this.x=n,this.y=r}Ar.prototype={constructor:Ar,scale:function(e){return e===1?this:new Ar(this.k*e,this.x,this.y)},translate:function(e,n){return e===0&n===0?this:new Ar(this.k,this.x+this.k*e,this.y+this.k*n)},apply:function(e){return[e[0]*this.k+this.x,e[1]*this.k+this.y]},applyX:function(e){return e*this.k+this.x},applyY:function(e){return e*this.k+this.y},invert:function(e){return[(e[0]-this.x)/this.k,(e[1]-this.y)/this.k]},invertX:function(e){return(e-this.x)/this.k},invertY:function(e){return(e-this.y)/this.k},rescaleX:function(e){return e.copy().domain(e.range().map(this.invertX,this).map(e.invert,e))},rescaleY:function(e){return e.copy().domain(e.range().map(this.invertY,this).map(e.invert,e))},toString:function(){return"translate("+this.x+","+this.y+") scale("+this.k+")"}};var Nr=new Ar(1,0,0);Ar.prototype;function qm(e){e.stopImmediatePropagation()}function na(e){e.preventDefault(),e.stopImmediatePropagation()}function s5(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function l5(){var e=this;return e instanceof SVGElement?(e=e.ownerSVGElement||e,e.hasAttribute("viewBox")?(e=e.viewBox.baseVal,[[e.x,e.y],[e.x+e.width,e.y+e.height]]):[[0,0],[e.width.baseVal.value,e.height.baseVal.value]]):[[0,0],[e.clientWidth,e.clientHeight]]}function LS(){return this.__zoom||Nr}function u5(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function c5(){return navigator.maxTouchPoints||"ontouchstart"in this}function f5(e,n,r){var o=e.invertX(n[0][0])-r[0][0],i=e.invertX(n[1][0])-r[1][0],l=e.invertY(n[0][1])-r[0][1],c=e.invertY(n[1][1])-r[1][1];return e.translate(i>o?(o+i)/2:Math.min(0,o)||Math.max(0,i),c>l?(l+c)/2:Math.min(0,l)||Math.max(0,c))}function DS(){var e=s5,n=l5,r=f5,o=u5,i=c5,l=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],f=250,m=YM,g=Es("start","zoom","end"),d,p,h,s=500,S=150,b=0,_=10;function w(B){B.property("__zoom",LS).on("wheel.zoom",j,{passive:!1}).on("mousedown.zoom",z).on("dblclick.zoom",L).filter(i).on("touchstart.zoom",M).on("touchmove.zoom",D).on("touchend.zoom touchcancel.zoom",F).style("-webkit-tap-highlight-color","rgba(0,0,0,0)")}w.transform=function(B,U,J,oe){var de=B.selection?B.selection():B;de.property("__zoom",LS),B!==de?k(B,U,J,oe):de.interrupt().each(function(){P(this,arguments).event(oe).start().zoom(null,typeof U=="function"?U.apply(this,arguments):U).end()})},w.scaleBy=function(B,U,J,oe){w.scaleTo(B,function(){var de=this.__zoom.k,Y=typeof U=="function"?U.apply(this,arguments):U;return de*Y},J,oe)},w.scaleTo=function(B,U,J,oe){w.transform(B,function(){var de=n.apply(this,arguments),Y=this.__zoom,ee=J==null?x(de):typeof J=="function"?J.apply(this,arguments):J,W=Y.invert(ee),ne=typeof U=="function"?U.apply(this,arguments):U;return r(E(y(Y,ne),ee,W),de,c)},J,oe)},w.translateBy=function(B,U,J,oe){w.transform(B,function(){return r(this.__zoom.translate(typeof U=="function"?U.apply(this,arguments):U,typeof J=="function"?J.apply(this,arguments):J),n.apply(this,arguments),c)},null,oe)},w.translateTo=function(B,U,J,oe,de){w.transform(B,function(){var Y=n.apply(this,arguments),ee=this.__zoom,W=oe==null?x(Y):typeof oe=="function"?oe.apply(this,arguments):oe;return r(Nr.translate(W[0],W[1]).scale(ee.k).translate(typeof U=="function"?-U.apply(this,arguments):-U,typeof J=="function"?-J.apply(this,arguments):-J),Y,c)},oe,de)};function y(B,U){return U=Math.max(l[0],Math.min(l[1],U)),U===B.k?B:new Ar(U,B.x,B.y)}function E(B,U,J){var oe=U[0]-J[0]*B.k,de=U[1]-J[1]*B.k;return oe===B.x&&de===B.y?B:new Ar(B.k,oe,de)}function x(B){return[(+B[0][0]+ +B[1][0])/2,(+B[0][1]+ +B[1][1])/2]}function k(B,U,J,oe){B.on("start.zoom",function(){P(this,arguments).event(oe).start()}).on("interrupt.zoom end.zoom",function(){P(this,arguments).event(oe).end()}).tween("zoom",function(){var de=this,Y=arguments,ee=P(de,Y).event(oe),W=n.apply(de,Y),ne=J==null?x(W):typeof J=="function"?J.apply(de,Y):J,ae=Math.max(W[1][0]-W[0][0],W[1][1]-W[0][1]),te=de.__zoom,re=typeof U=="function"?U.apply(de,Y):U,Z=m(te.invert(ne).concat(ae/te.k),re.invert(ne).concat(ae/re.k));return function(se){if(se===1)se=re;else{var pe=Z(se),ge=ae/pe[2];se=new Ar(ge,ne[0]-pe[0]*ge,ne[1]-pe[1]*ge)}ee.zoom(null,se)}})}function P(B,U,J){return!J&&B.__zooming||new R(B,U)}function R(B,U){this.that=B,this.args=U,this.active=0,this.sourceEvent=null,this.extent=n.apply(B,U),this.taps=0}R.prototype={event:function(B){return B&&(this.sourceEvent=B),this},start:function(){return++this.active===1&&(this.that.__zooming=this,this.emit("start")),this},zoom:function(B,U){return this.mouse&&B!=="mouse"&&(this.mouse[1]=U.invert(this.mouse[0])),this.touch0&&B!=="touch"&&(this.touch0[1]=U.invert(this.touch0[0])),this.touch1&&B!=="touch"&&(this.touch1[1]=U.invert(this.touch1[0])),this.that.__zoom=U,this.emit("zoom"),this},end:function(){return--this.active===0&&(delete this.that.__zooming,this.emit("end")),this},emit:function(B){var U=jn(this.that).datum();g.call(B,this.that,new a5(B,{sourceEvent:this.sourceEvent,target:w,transform:this.that.__zoom,dispatch:g}),U)}};function j(B,...U){if(!e.apply(this,arguments))return;var J=P(this,U).event(B),oe=this.__zoom,de=Math.max(l[0],Math.min(l[1],oe.k*Math.pow(2,o.apply(this,arguments)))),Y=$n(B);if(J.wheel)(J.mouse[0][0]!==Y[0]||J.mouse[0][1]!==Y[1])&&(J.mouse[1]=oe.invert(J.mouse[0]=Y)),clearTimeout(J.wheel);else{if(oe.k===de)return;J.mouse=[Y,oe.invert(Y)],zs(this),J.start()}na(B),J.wheel=setTimeout(ee,S),J.zoom("mouse",r(E(y(oe,de),J.mouse[0],J.mouse[1]),J.extent,c));function ee(){J.wheel=null,J.end()}}function z(B,...U){if(h||!e.apply(this,arguments))return;var J=B.currentTarget,oe=P(this,U,!0).event(B),de=jn(B.view).on("mousemove.zoom",ne,!0).on("mouseup.zoom",ae,!0),Y=$n(B,J),ee=B.clientX,W=B.clientY;aS(B.view),qm(B),oe.mouse=[Y,this.__zoom.invert(Y)],zs(this),oe.start();function ne(te){if(na(te),!oe.moved){var re=te.clientX-ee,Z=te.clientY-W;oe.moved=re*re+Z*Z>b}oe.event(te).zoom("mouse",r(E(oe.that.__zoom,oe.mouse[0]=$n(te,J),oe.mouse[1]),oe.extent,c))}function ae(te){de.on("mousemove.zoom mouseup.zoom",null),sS(te.view,oe.moved),na(te),oe.event(te).end()}}function L(B,...U){if(e.apply(this,arguments)){var J=this.__zoom,oe=$n(B.changedTouches?B.changedTouches[0]:B,this),de=J.invert(oe),Y=J.k*(B.shiftKey?.5:2),ee=r(E(y(J,Y),oe,de),n.apply(this,U),c);na(B),f>0?jn(this).transition().duration(f).call(k,ee,oe,B):jn(this).call(w.transform,ee,oe,B)}}function M(B,...U){if(e.apply(this,arguments)){var J=B.touches,oe=J.length,de=P(this,U,B.changedTouches.length===oe).event(B),Y,ee,W,ne;for(qm(B),ee=0;ee<oe;++ee)W=J[ee],ne=$n(W,this),ne=[ne,this.__zoom.invert(ne),W.identifier],de.touch0?!de.touch1&&de.touch0[2]!==ne[2]&&(de.touch1=ne,de.taps=0):(de.touch0=ne,Y=!0,de.taps=1+!!d);d&&(d=clearTimeout(d)),Y&&(de.taps<2&&(p=ne[0],d=setTimeout(function(){d=null},s)),zs(this),de.start())}}function D(B,...U){if(this.__zooming){var J=P(this,U).event(B),oe=B.changedTouches,de=oe.length,Y,ee,W,ne;for(na(B),Y=0;Y<de;++Y)ee=oe[Y],W=$n(ee,this),J.touch0&&J.touch0[2]===ee.identifier?J.touch0[0]=W:J.touch1&&J.touch1[2]===ee.identifier&&(J.touch1[0]=W);if(ee=J.that.__zoom,J.touch1){var ae=J.touch0[0],te=J.touch0[1],re=J.touch1[0],Z=J.touch1[1],se=(se=re[0]-ae[0])*se+(se=re[1]-ae[1])*se,pe=(pe=Z[0]-te[0])*pe+(pe=Z[1]-te[1])*pe;ee=y(ee,Math.sqrt(se/pe)),W=[(ae[0]+re[0])/2,(ae[1]+re[1])/2],ne=[(te[0]+Z[0])/2,(te[1]+Z[1])/2]}else if(J.touch0)W=J.touch0[0],ne=J.touch0[1];else return;J.zoom("touch",r(E(ee,W,ne),J.extent,c))}}function F(B,...U){if(this.__zooming){var J=P(this,U).event(B),oe=B.changedTouches,de=oe.length,Y,ee;for(qm(B),h&&clearTimeout(h),h=setTimeout(function(){h=null},s),Y=0;Y<de;++Y)ee=oe[Y],J.touch0&&J.touch0[2]===ee.identifier?delete J.touch0:J.touch1&&J.touch1[2]===ee.identifier&&delete J.touch1;if(J.touch1&&!J.touch0&&(J.touch0=J.touch1,delete J.touch1),J.touch0)J.touch0[1]=this.__zoom.invert(J.touch0[0]);else if(J.end(),J.taps===2&&(ee=$n(ee,this),Math.hypot(p[0]-ee[0],p[1]-ee[1])<_)){var W=jn(this).on("dblclick.zoom");W&&W.apply(this,arguments)}}}return w.wheelDelta=function(B){return arguments.length?(o=typeof B=="function"?B:Hs(+B),w):o},w.filter=function(B){return arguments.length?(e=typeof B=="function"?B:Hs(!!B),w):e},w.touchable=function(B){return arguments.length?(i=typeof B=="function"?B:Hs(!!B),w):i},w.extent=function(B){return arguments.length?(n=typeof B=="function"?B:Hs([[+B[0][0],+B[0][1]],[+B[1][0],+B[1][1]]]),w):n},w.scaleExtent=function(B){return arguments.length?(l[0]=+B[0],l[1]=+B[1],w):[l[0],l[1]]},w.translateExtent=function(B){return arguments.length?(c[0][0]=+B[0][0],c[1][0]=+B[1][0],c[0][1]=+B[0][1],c[1][1]=+B[1][1],w):[[c[0][0],c[0][1]],[c[1][0],c[1][1]]]},w.constrain=function(B){return arguments.length?(r=B,w):r},w.duration=function(B){return arguments.length?(f=+B,w):f},w.interpolate=function(B){return arguments.length?(m=B,w):m},w.on=function(){var B=g.on.apply(g,arguments);return B===g?w:B},w.clickDistance=function(B){return arguments.length?(b=(B=+B)*B,w):Math.sqrt(b)},w.tapDistance=function(B){return arguments.length?(_=+B,w):_},w}const Vs=he.createContext(null),d5=Vs.Provider,Tr={error001:()=>"[React Flow]: Seems like you have not used zustand provider as an ancestor. Help: https://reactflow.dev/error#001",error002:()=>"It looks like you've created a new nodeTypes or edgeTypes object. If this wasn't on purpose please define the nodeTypes/edgeTypes outside of the component or memoize them.",error003:e=>`Node type "${e}" not found. Using fallback type "default".`,error004:()=>"The React Flow parent container needs a width and a height to render the graph.",error005:()=>"Only child nodes can use a parent extent.",error006:()=>"Can't create edge. An edge needs a source and a target.",error007:e=>`The old edge with id=${e} does not exist.`,error009:e=>`Marker type "${e}" doesn't exist.`,error008:(e,n)=>`Couldn't create edge for ${e?"target":"source"} handle id: "${e?n.targetHandle:n.sourceHandle}", edge id: ${n.id}.`,error010:()=>"Handle: No node id found. Make sure to only use a Handle inside a custom Node.",error011:e=>`Edge type "${e}" not found. Using fallback type "default".`,error012:e=>`Node with id "${e}" does not exist, it may have been removed. This can happen when a node is deleted before the "onNodeClick" handler is called.`},BS=Tr.error001();function Tt(e,n){const r=he.useContext(Vs);if(r===null)throw new Error(BS);return U_(r,e,n)}const en=()=>{const e=he.useContext(Vs);if(e===null)throw new Error(BS);return he.useMemo(()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe,destroy:e.destroy}),[e])},h5=e=>e.userSelectionActive?"none":"all";function zm({position:e,children:n,className:r,style:o,...i}){const l=Tt(h5),c=`${e}`.split("-");return K.jsx("div",{className:un(["react-flow__panel",r,...c]),style:{...o,pointerEvents:l},...i,children:n})}function p5({proOptions:e,position:n="bottom-right"}){return e?.hideAttribution?null:K.jsx(zm,{position:n,className:"react-flow__attribution","data-message":"Please only hide this attribution when you are subscribed to React Flow Pro: https://pro.reactflow.dev",children:K.jsx("a",{href:"https://reactflow.dev",target:"_blank",rel:"noopener noreferrer","aria-label":"React Flow attribution",children:"React Flow"})})}const m5=({x:e,y:n,label:r,labelStyle:o={},labelShowBg:i=!0,labelBgStyle:l={},labelBgPadding:c=[2,4],labelBgBorderRadius:f=2,children:m,className:g,...d})=>{const p=he.useRef(null),[h,s]=he.useState({x:0,y:0,width:0,height:0}),S=un(["react-flow__edge-textwrapper",g]);return he.useEffect(()=>{if(p.current){const b=p.current.getBBox();s({x:b.x,y:b.y,width:b.width,height:b.height})}},[r]),typeof r>"u"||!r?null:K.jsxs("g",{transform:`translate(${e-h.width/2} ${n-h.height/2})`,className:S,visibility:h.width?"visible":"hidden",...d,children:[i&&K.jsx("rect",{width:h.width+2*c[0],x:-c[0],y:-c[1],height:h.height+2*c[1],className:"react-flow__edge-textbg",style:l,rx:f,ry:f}),K.jsx("text",{className:"react-flow__edge-text",y:h.height/2,dy:"0.3em",ref:p,style:o,children:r}),m]})};var g5=he.memo(m5);const Hm=e=>({width:e.offsetWidth,height:e.offsetHeight}),Ko=(e,n=0,r=1)=>Math.min(Math.max(e,n),r),Vm=(e={x:0,y:0},n)=>({x:Ko(e.x,n[0][0],n[1][0]),y:Ko(e.y,n[0][1],n[1][1])}),FS=(e,n,r)=>e<n?Ko(Math.abs(e-n),1,50)/50:e>r?-Ko(Math.abs(e-r),1,50)/50:0,qS=(e,n)=>{const r=FS(e.x,35,n.width-35)*20,o=FS(e.y,35,n.height-35)*20;return[r,o]},zS=e=>e.getRootNode?.()||window?.document,HS=(e,n)=>({x:Math.min(e.x,n.x),y:Math.min(e.y,n.y),x2:Math.max(e.x2,n.x2),y2:Math.max(e.y2,n.y2)}),ra=({x:e,y:n,width:r,height:o})=>({x:e,y:n,x2:e+r,y2:n+o}),VS=({x:e,y:n,x2:r,y2:o})=>({x:e,y:n,width:r-e,height:o-n}),US=e=>({...e.positionAbsolute||{x:0,y:0},width:e.width||0,height:e.height||0}),v5=(e,n)=>VS(HS(ra(e),ra(n))),Um=(e,n)=>{const r=Math.max(0,Math.min(e.x+e.width,n.x+n.width)-Math.max(e.x,n.x)),o=Math.max(0,Math.min(e.y+e.height,n.y+n.height)-Math.max(e.y,n.y));return Math.ceil(r*o)},y5=e=>Ln(e.width)&&Ln(e.height)&&Ln(e.x)&&Ln(e.y),Ln=e=>!isNaN(e)&&isFinite(e),tn=Symbol.for("internals"),WS=["Enter"," ","Escape"],b5=(e,n)=>{},w5=e=>"nativeEvent"in e;function Wm(e){const r=(w5(e)?e.nativeEvent:e).composedPath?.()?.[0]||e.target;return["INPUT","SELECT","TEXTAREA"].includes(r?.nodeName)||r?.hasAttribute("contenteditable")||!!r?.closest(".nokey")}const GS=e=>"clientX"in e,Yr=(e,n)=>{const r=GS(e),o=r?e.clientX:e.touches?.[0].clientX,i=r?e.clientY:e.touches?.[0].clientY;return{x:o-(n?.left??0),y:i-(n?.top??0)}},Us=()=>typeof navigator<"u"&&navigator?.userAgent?.indexOf("Mac")>=0,oa=({id:e,path:n,labelX:r,labelY:o,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g,style:d,markerEnd:p,markerStart:h,interactionWidth:s=20})=>K.jsxs(K.Fragment,{children:[K.jsx("path",{id:e,style:d,d:n,fill:"none",className:"react-flow__edge-path",markerEnd:p,markerStart:h}),s&&K.jsx("path",{d:n,fill:"none",strokeOpacity:0,strokeWidth:s,className:"react-flow__edge-interaction"}),i&&Ln(r)&&Ln(o)?K.jsx(g5,{x:r,y:o,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g}):null]});oa.displayName="BaseEdge";function ia(e,n,r){return r===void 0?r:o=>{const i=n().edges.find(l=>l.id===e);i&&r(o,{...i})}}function KS({sourceX:e,sourceY:n,targetX:r,targetY:o}){const i=Math.abs(r-e)/2,l=r<e?r+i:r-i,c=Math.abs(o-n)/2,f=o<n?o+c:o-c;return[l,f,i,c]}function YS({sourceX:e,sourceY:n,targetX:r,targetY:o,sourceControlX:i,sourceControlY:l,targetControlX:c,targetControlY:f}){const m=e*.125+i*.375+c*.375+r*.125,g=n*.125+l*.375+f*.375+o*.125,d=Math.abs(m-e),p=Math.abs(g-n);return[m,g,d,p]}var vo;(function(e){e.Strict="strict",e.Loose="loose"})(vo||(vo={}));var yo;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(yo||(yo={}));var aa;(function(e){e.Partial="partial",e.Full="full"})(aa||(aa={}));var hr;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(hr||(hr={}));var Ws;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(Ws||(Ws={}));var Be;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Be||(Be={}));function XS({pos:e,x1:n,y1:r,x2:o,y2:i}){return e===Be.Left||e===Be.Right?[.5*(n+o),r]:[n,.5*(r+i)]}function ZS({sourceX:e,sourceY:n,sourcePosition:r=Be.Bottom,targetX:o,targetY:i,targetPosition:l=Be.Top}){const[c,f]=XS({pos:r,x1:e,y1:n,x2:o,y2:i}),[m,g]=XS({pos:l,x1:o,y1:i,x2:e,y2:n}),[d,p,h,s]=YS({sourceX:e,sourceY:n,targetX:o,targetY:i,sourceControlX:c,sourceControlY:f,targetControlX:m,targetControlY:g});return[`M${e},${n} C${c},${f} ${m},${g} ${o},${i}`,d,p,h,s]}const Gm=he.memo(({sourceX:e,sourceY:n,targetX:r,targetY:o,sourcePosition:i=Be.Bottom,targetPosition:l=Be.Top,label:c,labelStyle:f,labelShowBg:m,labelBgStyle:g,labelBgPadding:d,labelBgBorderRadius:p,style:h,markerEnd:s,markerStart:S,interactionWidth:b})=>{const[_,w,y]=ZS({sourceX:e,sourceY:n,sourcePosition:i,targetX:r,targetY:o,targetPosition:l});return K.jsx(oa,{path:_,labelX:w,labelY:y,label:c,labelStyle:f,labelShowBg:m,labelBgStyle:g,labelBgPadding:d,labelBgBorderRadius:p,style:h,markerEnd:s,markerStart:S,interactionWidth:b})});Gm.displayName="SimpleBezierEdge";const QS={[Be.Left]:{x:-1,y:0},[Be.Right]:{x:1,y:0},[Be.Top]:{x:0,y:-1},[Be.Bottom]:{x:0,y:1}},x5=({source:e,sourcePosition:n=Be.Bottom,target:r})=>n===Be.Left||n===Be.Right?e.x<r.x?{x:1,y:0}:{x:-1,y:0}:e.y<r.y?{x:0,y:1}:{x:0,y:-1},JS=(e,n)=>Math.sqrt(Math.pow(n.x-e.x,2)+Math.pow(n.y-e.y,2));function _5({source:e,sourcePosition:n=Be.Bottom,target:r,targetPosition:o=Be.Top,center:i,offset:l}){const c=QS[n],f=QS[o],m={x:e.x+c.x*l,y:e.y+c.y*l},g={x:r.x+f.x*l,y:r.y+f.y*l},d=x5({source:m,sourcePosition:n,target:g}),p=d.x!==0?"x":"y",h=d[p];let s=[],S,b;const _={x:0,y:0},w={x:0,y:0},[y,E,x,k]=KS({sourceX:e.x,sourceY:e.y,targetX:r.x,targetY:r.y});if(c[p]*f[p]===-1){S=i.x||y,b=i.y||E;const R=[{x:S,y:m.y},{x:S,y:g.y}],j=[{x:m.x,y:b},{x:g.x,y:b}];c[p]===h?s=p==="x"?R:j:s=p==="x"?j:R}else{const R=[{x:m.x,y:g.y}],j=[{x:g.x,y:m.y}];if(p==="x"?s=c.x===h?j:R:s=c.y===h?R:j,n===o){const F=Math.abs(e[p]-r[p]);if(F<=l){const B=Math.min(l-1,l-F);c[p]===h?_[p]=B:w[p]=B}}if(n!==o){const F=p==="x"?"y":"x",B=c[p]===f[F],U=m[F]>g[F],J=m[F]<g[F];(c[p]===1&&(!B&&U||B&&J)||c[p]!==1&&(!B&&J||B&&U))&&(s=p==="x"?R:j)}const z={x:m.x-_.x,y:m.y-_.y},L={x:g.x-w.x,y:g.y-w.y},M=Math.max(Math.abs(z.x-s[0].x),Math.abs(L.x-s[0].x)),D=Math.max(Math.abs(z.y-s[0].y),Math.abs(L.y-s[0].y));M>=D?(S=(z.x+L.x)/2,b=s[0].y):(S=s[0].x,b=(z.y+L.y)/2)}return[[e,{x:m.x-_.x,y:m.y-_.y},...s,{x:g.x-w.x,y:g.y-w.y},r],S,b,x,k]}function S5(e,n,r,o){const i=Math.min(JS(e,n)/2,JS(n,r)/2,o),{x:l,y:c}=n;if(e.x===l&&l===r.x||e.y===c&&c===r.y)return`L${l} ${c}`;if(e.y===c){const g=e.x<r.x?-1:1,d=e.y<r.y?1:-1;return`L ${l+i*g},${c}Q ${l},${c} ${l},${c+i*d}`}const f=e.x<r.x?1:-1,m=e.y<r.y?-1:1;return`L ${l},${c+i*m}Q ${l},${c} ${l+i*f},${c}`}function Km({sourceX:e,sourceY:n,sourcePosition:r=Be.Bottom,targetX:o,targetY:i,targetPosition:l=Be.Top,borderRadius:c=5,centerX:f,centerY:m,offset:g=20}){const[d,p,h,s,S]=_5({source:{x:e,y:n},sourcePosition:r,target:{x:o,y:i},targetPosition:l,center:{x:f,y:m},offset:g});return[d.reduce((_,w,y)=>{let E="";return y>0&&y<d.length-1?E=S5(d[y-1],w,d[y+1],c):E=`${y===0?"M":"L"}${w.x} ${w.y}`,_+=E,_},""),p,h,s,S]}const Gs=he.memo(({sourceX:e,sourceY:n,targetX:r,targetY:o,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g,style:d,sourcePosition:p=Be.Bottom,targetPosition:h=Be.Top,markerEnd:s,markerStart:S,pathOptions:b,interactionWidth:_})=>{const[w,y,E]=Km({sourceX:e,sourceY:n,sourcePosition:p,targetX:r,targetY:o,targetPosition:h,borderRadius:b?.borderRadius,offset:b?.offset});return K.jsx(oa,{path:w,labelX:y,labelY:E,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g,style:d,markerEnd:s,markerStart:S,interactionWidth:_})});Gs.displayName="SmoothStepEdge";const Ym=he.memo(e=>K.jsx(Gs,{...e,pathOptions:he.useMemo(()=>({borderRadius:0,offset:e.pathOptions?.offset}),[e.pathOptions?.offset])}));Ym.displayName="StepEdge";function E5({sourceX:e,sourceY:n,targetX:r,targetY:o}){const[i,l,c,f]=KS({sourceX:e,sourceY:n,targetX:r,targetY:o});return[`M ${e},${n}L ${r},${o}`,i,l,c,f]}const Xm=he.memo(({sourceX:e,sourceY:n,targetX:r,targetY:o,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g,style:d,markerEnd:p,markerStart:h,interactionWidth:s})=>{const[S,b,_]=E5({sourceX:e,sourceY:n,targetX:r,targetY:o});return K.jsx(oa,{path:S,labelX:b,labelY:_,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g,style:d,markerEnd:p,markerStart:h,interactionWidth:s})});Xm.displayName="StraightEdge";function Ks(e,n){return e>=0?.5*e:n*25*Math.sqrt(-e)}function $S({pos:e,x1:n,y1:r,x2:o,y2:i,c:l}){switch(e){case Be.Left:return[n-Ks(n-o,l),r];case Be.Right:return[n+Ks(o-n,l),r];case Be.Top:return[n,r-Ks(r-i,l)];case Be.Bottom:return[n,r+Ks(i-r,l)]}}function eE({sourceX:e,sourceY:n,sourcePosition:r=Be.Bottom,targetX:o,targetY:i,targetPosition:l=Be.Top,curvature:c=.25}){const[f,m]=$S({pos:r,x1:e,y1:n,x2:o,y2:i,c}),[g,d]=$S({pos:l,x1:o,y1:i,x2:e,y2:n,c}),[p,h,s,S]=YS({sourceX:e,sourceY:n,targetX:o,targetY:i,sourceControlX:f,sourceControlY:m,targetControlX:g,targetControlY:d});return[`M${e},${n} C${f},${m} ${g},${d} ${o},${i}`,p,h,s,S]}const Ys=he.memo(({sourceX:e,sourceY:n,targetX:r,targetY:o,sourcePosition:i=Be.Bottom,targetPosition:l=Be.Top,label:c,labelStyle:f,labelShowBg:m,labelBgStyle:g,labelBgPadding:d,labelBgBorderRadius:p,style:h,markerEnd:s,markerStart:S,pathOptions:b,interactionWidth:_})=>{const[w,y,E]=eE({sourceX:e,sourceY:n,sourcePosition:i,targetX:r,targetY:o,targetPosition:l,curvature:b?.curvature});return K.jsx(oa,{path:w,labelX:y,labelY:E,label:c,labelStyle:f,labelShowBg:m,labelBgStyle:g,labelBgPadding:d,labelBgBorderRadius:p,style:h,markerEnd:s,markerStart:S,interactionWidth:_})});Ys.displayName="BezierEdge";const Zm=he.createContext(null),O5=Zm.Provider;Zm.Consumer;const k5=()=>he.useContext(Zm),C5=e=>"id"in e&&"source"in e&&"target"in e,A5=({source:e,sourceHandle:n,target:r,targetHandle:o})=>`reactflow__edge-${e}${n||""}-${r}${o||""}`,Qm=(e,n)=>typeof e>"u"?"":typeof e=="string"?e:`${n?`${n}__`:""}${Object.keys(e).sort().map(o=>`${o}=${e[o]}`).join("&")}`,N5=(e,n)=>n.some(r=>r.source===e.source&&r.target===e.target&&(r.sourceHandle===e.sourceHandle||!r.sourceHandle&&!e.sourceHandle)&&(r.targetHandle===e.targetHandle||!r.targetHandle&&!e.targetHandle)),T5=(e,n)=>{if(!e.source||!e.target)return n;let r;return C5(e)?r={...e}:r={...e,id:A5(e)},N5(r,n)?n:n.concat(r)},tE=({x:e,y:n},[r,o,i],l,[c,f])=>{const m={x:(e-r)/i,y:(n-o)/i};return l?{x:c*Math.round(m.x/c),y:f*Math.round(m.y/f)}:m},R5=({x:e,y:n},[r,o,i])=>({x:e*i+r,y:n*i+o}),bo=(e,n=[0,0])=>{if(!e)return{x:0,y:0,positionAbsolute:{x:0,y:0}};const r=(e.width??0)*n[0],o=(e.height??0)*n[1],i={x:e.position.x-r,y:e.position.y-o};return{...i,positionAbsolute:e.positionAbsolute?{x:e.positionAbsolute.x-r,y:e.positionAbsolute.y-o}:i}},Xs=(e,n=[0,0])=>{if(e.length===0)return{x:0,y:0,width:0,height:0};const r=e.reduce((o,i)=>{const{x:l,y:c}=bo(i,n).positionAbsolute;return HS(o,ra({x:l,y:c,width:i.width||0,height:i.height||0}))},{x:1/0,y:1/0,x2:-1/0,y2:-1/0});return VS(r)},nE=(e,n,[r,o,i]=[0,0,1],l=!1,c=!1,f=[0,0])=>{const m={x:(n.x-r)/i,y:(n.y-o)/i,width:n.width/i,height:n.height/i},g=[];return e.forEach(d=>{const{width:p,height:h,selectable:s=!0,hidden:S=!1}=d;if(c&&!s||S)return!1;const{positionAbsolute:b}=bo(d,f),_={x:b.x,y:b.y,width:p||0,height:h||0},w=Um(m,_),y=typeof p>"u"||typeof h>"u"||p===null||h===null,E=l&&w>0,x=(p||0)*(h||0);(y||E||w>=x||d.dragging)&&g.push(d)}),g},rE=(e,n)=>{const r=e.map(o=>o.id);return n.filter(o=>r.includes(o.source)||r.includes(o.target))},oE=(e,n,r,o,i,l=.1)=>{const c=n/(e.width*(1+l)),f=r/(e.height*(1+l)),m=Math.min(c,f),g=Ko(m,o,i),d=e.x+e.width/2,p=e.y+e.height/2,h=n/2-d*g,s=r/2-p*g;return[h,s,g]},wo=(e,n=0)=>e.transition().duration(n);function iE(e,n,r,o){return(n[r]||[]).reduce((i,l)=>(`${e.id}-${l.id}-${r}`!==o&&i.push({id:l.id||null,type:r,nodeId:e.id,x:(e.positionAbsolute?.x??0)+l.x+l.width/2,y:(e.positionAbsolute?.y??0)+l.y+l.height/2}),i),[])}function P5(e,n,r,o,i,l){const{x:c,y:f}=Yr(e),g=n.elementsFromPoint(c,f).find(S=>S.classList.contains("react-flow__handle"));if(g){const S=g.getAttribute("data-nodeid");if(S){const b=Jm(void 0,g),_=g.getAttribute("data-handleid"),w=l({nodeId:S,id:_,type:b});if(w)return{handle:{id:_,type:b,nodeId:S,x:r.x,y:r.y},validHandleResult:w}}}let d=[],p=1/0;if(i.forEach(S=>{const b=Math.sqrt((S.x-r.x)**2+(S.y-r.y)**2);if(b<=o){const _=l(S);b<=p&&(b<p?d=[{handle:S,validHandleResult:_}]:b===p&&d.push({handle:S,validHandleResult:_}),p=b)}}),!d.length)return{handle:null,validHandleResult:aE()};if(d.length===1)return d[0];const h=d.some(({validHandleResult:S})=>S.isValid),s=d.some(({handle:S})=>S.type==="target");return d.find(({handle:S,validHandleResult:b})=>s?S.type==="target":h?b.isValid:!0)||d[0]}const I5={source:null,target:null,sourceHandle:null,targetHandle:null},aE=()=>({handleDomNode:null,isValid:!1,connection:I5,endHandle:null});function sE(e,n,r,o,i,l,c){const f=i==="target",m=c.querySelector(`.react-flow__handle[data-id="${e?.nodeId}-${e?.id}-${e?.type}"]`),g={...aE(),handleDomNode:m};if(m){const d=Jm(void 0,m),p=m.getAttribute("data-nodeid"),h=m.getAttribute("data-handleid"),s=m.classList.contains("connectable"),S=m.classList.contains("connectableend"),b={source:f?p:r,sourceHandle:f?h:o,target:f?r:p,targetHandle:f?o:h};g.connection=b,s&&S&&(n===vo.Strict?f&&d==="source"||!f&&d==="target":p!==r||h!==o)&&(g.endHandle={nodeId:p,handleId:h,type:d},g.isValid=l(b))}return g}function M5({nodes:e,nodeId:n,handleId:r,handleType:o}){return e.reduce((i,l)=>{if(l[tn]){const{handleBounds:c}=l[tn];let f=[],m=[];c&&(f=iE(l,c,"source",`${n}-${r}-${o}`),m=iE(l,c,"target",`${n}-${r}-${o}`)),i.push(...f,...m)}return i},[])}function Jm(e,n){return e||(n?.classList.contains("target")?"target":n?.classList.contains("source")?"source":null)}function $m(e){e?.classList.remove("valid","connecting","react-flow__handle-valid","react-flow__handle-connecting")}function j5(e,n){let r=null;return n?r="valid":e&&!n&&(r="invalid"),r}function lE({event:e,handleId:n,nodeId:r,onConnect:o,isTarget:i,getState:l,setState:c,isValidConnection:f,edgeUpdaterType:m,onEdgeUpdateEnd:g}){const d=zS(e.target),{connectionMode:p,domNode:h,autoPanOnConnect:s,connectionRadius:S,onConnectStart:b,panBy:_,getNodes:w,cancelConnection:y}=l();let E=0,x;const{x:k,y:P}=Yr(e),R=d?.elementFromPoint(k,P),j=Jm(m,R),z=h?.getBoundingClientRect();if(!z||!j)return;let L,M=Yr(e,z),D=!1,F=null,B=!1,U=null;const J=M5({nodes:w(),nodeId:r,handleId:n,handleType:j}),oe=()=>{if(!s)return;const[ee,W]=qS(M,z);_({x:ee,y:W}),E=requestAnimationFrame(oe)};c({connectionPosition:M,connectionStatus:null,connectionNodeId:r,connectionHandleId:n,connectionHandleType:j,connectionStartHandle:{nodeId:r,handleId:n,type:j},connectionEndHandle:null}),b?.(e,{nodeId:r,handleId:n,handleType:j});function de(ee){const{transform:W}=l();M=Yr(ee,z);const{handle:ne,validHandleResult:ae}=P5(ee,d,tE(M,W,!1,[1,1]),S,J,te=>sE(te,p,r,n,i?"target":"source",f,d));if(x=ne,D||(oe(),D=!0),U=ae.handleDomNode,F=ae.connection,B=ae.isValid,c({connectionPosition:x&&B?R5({x:x.x,y:x.y},W):M,connectionStatus:j5(!!x,B),connectionEndHandle:ae.endHandle}),!x&&!B&&!U)return $m(L);F.source!==F.target&&U&&($m(L),L=U,U.classList.add("connecting","react-flow__handle-connecting"),U.classList.toggle("valid",B),U.classList.toggle("react-flow__handle-valid",B))}function Y(ee){(x||U)&&F&&B&&o?.(F),l().onConnectEnd?.(ee),m&&g?.(ee),$m(L),y(),cancelAnimationFrame(E),D=!1,B=!1,F=null,U=null,d.removeEventListener("mousemove",de),d.removeEventListener("mouseup",Y),d.removeEventListener("touchmove",de),d.removeEventListener("touchend",Y)}d.addEventListener("mousemove",de),d.addEventListener("mouseup",Y),d.addEventListener("touchmove",de),d.addEventListener("touchend",Y)}const uE=()=>!0,L5=e=>({connectionStartHandle:e.connectionStartHandle,connectOnClick:e.connectOnClick,noPanClassName:e.noPanClassName}),D5=(e,n,r)=>o=>{const{connectionStartHandle:i,connectionEndHandle:l,connectionClickStartHandle:c}=o;return{connecting:i?.nodeId===e&&i?.handleId===n&&i?.type===r||l?.nodeId===e&&l?.handleId===n&&l?.type===r,clickConnecting:c?.nodeId===e&&c?.handleId===n&&c?.type===r}},cE=he.forwardRef(({type:e="source",position:n=Be.Top,isValidConnection:r,isConnectable:o=!0,isConnectableStart:i=!0,isConnectableEnd:l=!0,id:c,onConnect:f,children:m,className:g,onMouseDown:d,onTouchStart:p,...h},s)=>{const S=c||null,b=e==="target",_=en(),w=k5(),{connectOnClick:y,noPanClassName:E}=Tt(L5,ln),{connecting:x,clickConnecting:k}=Tt(D5(w,S,e),ln);w||_.getState().onError?.("010",Tr.error010());const P=z=>{const{defaultEdgeOptions:L,onConnect:M,hasDefaultEdges:D}=_.getState(),F={...L,...z};if(D){const{edges:B,setEdges:U}=_.getState();U(T5(F,B))}M?.(F),f?.(F)},R=z=>{if(!w)return;const L=GS(z);i&&(L&&z.button===0||!L)&&lE({event:z,handleId:S,nodeId:w,onConnect:P,isTarget:b,getState:_.getState,setState:_.setState,isValidConnection:r||_.getState().isValidConnection||uE}),L?d?.(z):p?.(z)},j=z=>{const{onClickConnectStart:L,onClickConnectEnd:M,connectionClickStartHandle:D,connectionMode:F,isValidConnection:B}=_.getState();if(!w||!D&&!i)return;if(!D){L?.(z,{nodeId:w,handleId:S,handleType:e}),_.setState({connectionClickStartHandle:{nodeId:w,type:e,handleId:S}});return}const U=zS(z.target),J=r||B||uE,{connection:oe,isValid:de}=sE({nodeId:w,id:S,type:e},F,D.nodeId,D.handleId||null,D.type,J,U);de&&P(oe),M?.(z),_.setState({connectionClickStartHandle:null})};return K.jsx("div",{"data-handleid":S,"data-nodeid":w,"data-handlepos":n,"data-id":`${w}-${S}-${e}`,className:un(["react-flow__handle",`react-flow__handle-${n}`,"nodrag",E,g,{source:!b,target:b,connectable:o,connectablestart:i,connectableend:l,connecting:k,connectionindicator:o&&(i&&!x||l&&x)}]),onMouseDown:R,onTouchStart:R,onClick:y?j:void 0,ref:s,...h,children:m})});cE.displayName="Handle";var qt=he.memo(cE);const fE=({data:e,isConnectable:n,targetPosition:r=Be.Top,sourcePosition:o=Be.Bottom})=>K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:r,isConnectable:n}),e?.label,K.jsx(qt,{type:"source",position:o,isConnectable:n})]});fE.displayName="DefaultNode";var eg=he.memo(fE);const dE=({data:e,isConnectable:n,sourcePosition:r=Be.Bottom})=>K.jsxs(K.Fragment,{children:[e?.label,K.jsx(qt,{type:"source",position:r,isConnectable:n})]});dE.displayName="InputNode";var hE=he.memo(dE);const pE=({data:e,isConnectable:n,targetPosition:r=Be.Top})=>K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:r,isConnectable:n}),e?.label]});pE.displayName="OutputNode";var mE=he.memo(pE);const tg=()=>null;tg.displayName="GroupNode";const B5=e=>({selectedNodes:e.getNodes().filter(n=>n.selected),selectedEdges:e.edges.filter(n=>n.selected)}),Zs=e=>e.id;function F5(e,n){return ln(e.selectedNodes.map(Zs),n.selectedNodes.map(Zs))&&ln(e.selectedEdges.map(Zs),n.selectedEdges.map(Zs))}const gE=he.memo(({onSelectionChange:e})=>{const n=en(),{selectedNodes:r,selectedEdges:o}=Tt(B5,F5);return he.useEffect(()=>{const i={nodes:r,edges:o};e?.(i),n.getState().onSelectionChange?.(i)},[r,o,e]),null});gE.displayName="SelectionListener";const q5=e=>!!e.onSelectionChange;function z5({onSelectionChange:e}){const n=Tt(q5);return e||n?K.jsx(gE,{onSelectionChange:e}):null}const H5=e=>({setNodes:e.setNodes,setEdges:e.setEdges,setDefaultNodesAndEdges:e.setDefaultNodesAndEdges,setMinZoom:e.setMinZoom,setMaxZoom:e.setMaxZoom,setTranslateExtent:e.setTranslateExtent,setNodeExtent:e.setNodeExtent,reset:e.reset});function Yo(e,n){he.useEffect(()=>{typeof e<"u"&&n(e)},[e])}function mt(e,n,r){he.useEffect(()=>{typeof n<"u"&&r({[e]:n})},[n])}const V5=({nodes:e,edges:n,defaultNodes:r,defaultEdges:o,onConnect:i,onConnectStart:l,onConnectEnd:c,onClickConnectStart:f,onClickConnectEnd:m,nodesDraggable:g,nodesConnectable:d,nodesFocusable:p,edgesFocusable:h,edgesUpdatable:s,elevateNodesOnSelect:S,minZoom:b,maxZoom:_,nodeExtent:w,onNodesChange:y,onEdgesChange:E,elementsSelectable:x,connectionMode:k,snapGrid:P,snapToGrid:R,translateExtent:j,connectOnClick:z,defaultEdgeOptions:L,fitView:M,fitViewOptions:D,onNodesDelete:F,onEdgesDelete:B,onNodeDrag:U,onNodeDragStart:J,onNodeDragStop:oe,onSelectionDrag:de,onSelectionDragStart:Y,onSelectionDragStop:ee,noPanClassName:W,nodeOrigin:ne,rfId:ae,autoPanOnConnect:te,autoPanOnNodeDrag:re,onError:Z,connectionRadius:se,isValidConnection:pe})=>{const{setNodes:ge,setEdges:be,setDefaultNodesAndEdges:Ae,setMinZoom:Ue,setMaxZoom:Ve,setTranslateExtent:Fe,setNodeExtent:Pe,reset:ut}=Tt(H5,ln),Ce=en();return he.useEffect(()=>{const we=o?.map(xe=>({...xe,...L}));return Ae(r,we),()=>{ut()}},[]),mt("defaultEdgeOptions",L,Ce.setState),mt("connectionMode",k,Ce.setState),mt("onConnect",i,Ce.setState),mt("onConnectStart",l,Ce.setState),mt("onConnectEnd",c,Ce.setState),mt("onClickConnectStart",f,Ce.setState),mt("onClickConnectEnd",m,Ce.setState),mt("nodesDraggable",g,Ce.setState),mt("nodesConnectable",d,Ce.setState),mt("nodesFocusable",p,Ce.setState),mt("edgesFocusable",h,Ce.setState),mt("edgesUpdatable",s,Ce.setState),mt("elementsSelectable",x,Ce.setState),mt("elevateNodesOnSelect",S,Ce.setState),mt("snapToGrid",R,Ce.setState),mt("snapGrid",P,Ce.setState),mt("onNodesChange",y,Ce.setState),mt("onEdgesChange",E,Ce.setState),mt("connectOnClick",z,Ce.setState),mt("fitViewOnInit",M,Ce.setState),mt("fitViewOnInitOptions",D,Ce.setState),mt("onNodesDelete",F,Ce.setState),mt("onEdgesDelete",B,Ce.setState),mt("onNodeDrag",U,Ce.setState),mt("onNodeDragStart",J,Ce.setState),mt("onNodeDragStop",oe,Ce.setState),mt("onSelectionDrag",de,Ce.setState),mt("onSelectionDragStart",Y,Ce.setState),mt("onSelectionDragStop",ee,Ce.setState),mt("noPanClassName",W,Ce.setState),mt("nodeOrigin",ne,Ce.setState),mt("rfId",ae,Ce.setState),mt("autoPanOnConnect",te,Ce.setState),mt("autoPanOnNodeDrag",re,Ce.setState),mt("onError",Z,Ce.setState),mt("connectionRadius",se,Ce.setState),mt("isValidConnection",pe,Ce.setState),Yo(e,ge),Yo(n,be),Yo(b,Ue),Yo(_,Ve),Yo(j,Fe),Yo(w,Pe),null},vE={display:"none"},U5={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},yE="react-flow__node-desc",bE="react-flow__edge-desc",W5="react-flow__aria-live",G5=e=>e.ariaLiveMessage;function K5({rfId:e}){const n=Tt(G5);return K.jsx("div",{id:`${W5}-${e}`,"aria-live":"assertive","aria-atomic":"true",style:U5,children:n})}function Y5({rfId:e,disableKeyboardA11y:n}){return K.jsxs(K.Fragment,{children:[K.jsxs("div",{id:`${yE}-${e}`,style:vE,children:["Press enter or space to select a node.",!n&&"You can then use the arrow keys to move the node around."," Press delete to remove it and escape to cancel."," "]}),K.jsx("div",{id:`${bE}-${e}`,style:vE,children:"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel."}),!n&&K.jsx(K5,{rfId:e})]})}const X5=typeof document<"u"?document:null;var sa=(e=null,n={target:X5})=>{const[r,o]=he.useState(!1),i=he.useRef(!1),l=he.useRef(new Set([])),[c,f]=he.useMemo(()=>{if(e!==null){const g=(Array.isArray(e)?e:[e]).filter(p=>typeof p=="string").map(p=>p.split("+")),d=g.reduce((p,h)=>p.concat(...h),[]);return[g,d]}return[[],[]]},[e]);return he.useEffect(()=>{if(e!==null){const m=p=>{if(i.current=p.ctrlKey||p.metaKey||p.shiftKey,!i.current&&Wm(p))return!1;const h=xE(p.code,f);l.current.add(p[h]),wE(c,l.current,!1)&&(p.preventDefault(),o(!0))},g=p=>{if(!i.current&&Wm(p))return!1;const h=xE(p.code,f);wE(c,l.current,!0)?(o(!1),l.current.clear()):l.current.delete(p[h]),p.key==="Meta"&&l.current.clear(),i.current=!1},d=()=>{l.current.clear(),o(!1)};return n?.target?.addEventListener("keydown",m),n?.target?.addEventListener("keyup",g),window.addEventListener("blur",d),()=>{n?.target?.removeEventListener("keydown",m),n?.target?.removeEventListener("keyup",g),window.removeEventListener("blur",d)}}},[e,o]),r};function wE(e,n,r){return e.filter(o=>r||o.length===n.size).some(o=>o.every(i=>n.has(i)))}function xE(e,n){return n.includes(e)?"code":"key"}function _E(e,n,r,o){if(!e.parentNode)return r;const i=n.get(e.parentNode),l=bo(i,o);return _E(i,n,{x:(r.x??0)+l.x,y:(r.y??0)+l.y,z:(i[tn]?.z??0)>(r.z??0)?i[tn]?.z??0:r.z??0},o)}function SE(e,n,r){e.forEach(o=>{if(o.parentNode&&!e.has(o.parentNode))throw new Error(`Parent node ${o.parentNode} not found`);if(o.parentNode||r?.[o.id]){const{x:i,y:l,z:c}=_E(o,e,{...o.position,z:o[tn]?.z??0},n);o.positionAbsolute={x:i,y:l},o[tn].z=c,r?.[o.id]&&(o[tn].isParent=!0)}})}function ng(e,n,r,o){const i=new Map,l={},c=o?1e3:0;return e.forEach(f=>{const m=(Ln(f.zIndex)?f.zIndex:0)+(f.selected?c:0),g=n.get(f.id),d={width:g?.width,height:g?.height,...f,positionAbsolute:{x:f.position.x,y:f.position.y}};f.parentNode&&(d.parentNode=f.parentNode,l[f.parentNode]=!0),Object.defineProperty(d,tn,{enumerable:!1,value:{handleBounds:g?.[tn]?.handleBounds,z:m}}),i.set(f.id,d)}),SE(i,r,l),i}function EE(e,n={}){const{getNodes:r,width:o,height:i,minZoom:l,maxZoom:c,d3Zoom:f,d3Selection:m,fitViewOnInitDone:g,fitViewOnInit:d,nodeOrigin:p}=e(),h=n.initial&&!g&&d;if(f&&m&&(h||!n.initial)){const S=r().filter(_=>{const w=n.includeHiddenNodes?_.width&&_.height:!_.hidden;return n.nodes?.length?w&&n.nodes.some(y=>y.id===_.id):w}),b=S.every(_=>_.width&&_.height);if(S.length>0&&b){const _=Xs(S,p),[w,y,E]=oE(_,o,i,n.minZoom??l,n.maxZoom??c,n.padding??.1),x=Nr.translate(w,y).scale(E);return typeof n.duration=="number"&&n.duration>0?f.transform(wo(m,n.duration),x):f.transform(m,x),!0}}return!1}function Z5(e,n){return e.forEach(r=>{const o=n.get(r.id);o&&n.set(o.id,{...o,[tn]:o[tn],selected:r.selected})}),new Map(n)}function Q5(e,n){return n.map(r=>{const o=e.find(i=>i.id===r.id);return o&&(r.selected=o.selected),r})}function Qs({changedNodes:e,changedEdges:n,get:r,set:o}){const{nodeInternals:i,edges:l,onNodesChange:c,onEdgesChange:f,hasDefaultNodes:m,hasDefaultEdges:g}=r();e?.length&&(m&&o({nodeInternals:Z5(e,i)}),c?.(e)),n?.length&&(g&&o({edges:Q5(n,l)}),f?.(n))}const Xo=()=>{},J5={zoomIn:Xo,zoomOut:Xo,zoomTo:Xo,getZoom:()=>1,setViewport:Xo,getViewport:()=>({x:0,y:0,zoom:1}),fitView:()=>!1,setCenter:Xo,fitBounds:Xo,project:e=>e,viewportInitialized:!1},$5=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection}),eL=()=>{const e=en(),{d3Zoom:n,d3Selection:r}=Tt($5,ln);return he.useMemo(()=>r&&n?{zoomIn:i=>n.scaleBy(wo(r,i?.duration),1.2),zoomOut:i=>n.scaleBy(wo(r,i?.duration),1/1.2),zoomTo:(i,l)=>n.scaleTo(wo(r,l?.duration),i),getZoom:()=>e.getState().transform[2],setViewport:(i,l)=>{const[c,f,m]=e.getState().transform,g=Nr.translate(i.x??c,i.y??f).scale(i.zoom??m);n.transform(wo(r,l?.duration),g)},getViewport:()=>{const[i,l,c]=e.getState().transform;return{x:i,y:l,zoom:c}},fitView:i=>EE(e.getState,i),setCenter:(i,l,c)=>{const{width:f,height:m,maxZoom:g}=e.getState(),d=typeof c?.zoom<"u"?c.zoom:g,p=f/2-i*d,h=m/2-l*d,s=Nr.translate(p,h).scale(d);n.transform(wo(r,c?.duration),s)},fitBounds:(i,l)=>{const{width:c,height:f,minZoom:m,maxZoom:g}=e.getState(),[d,p,h]=oE(i,c,f,m,g,l?.padding??.1),s=Nr.translate(d,p).scale(h);n.transform(wo(r,l?.duration),s)},project:i=>{const{transform:l,snapToGrid:c,snapGrid:f}=e.getState();return tE(i,l,c,f)},viewportInitialized:!0}:J5,[n,r])};function Js(){const e=eL(),n=en(),r=he.useCallback(()=>n.getState().getNodes().map(b=>({...b})),[]),o=he.useCallback(b=>n.getState().nodeInternals.get(b),[]),i=he.useCallback(()=>{const{edges:b=[]}=n.getState();return b.map(_=>({..._}))},[]),l=he.useCallback(b=>{const{edges:_=[]}=n.getState();return _.find(w=>w.id===b)},[]),c=he.useCallback(b=>{const{getNodes:_,setNodes:w,hasDefaultNodes:y,onNodesChange:E}=n.getState(),x=_(),k=typeof b=="function"?b(x):b;if(y)w(k);else if(E){const P=k.length===0?x.map(R=>({type:"remove",id:R.id})):k.map(R=>({item:R,type:"reset"}));E(P)}},[]),f=he.useCallback(b=>{const{edges:_=[],setEdges:w,hasDefaultEdges:y,onEdgesChange:E}=n.getState(),x=typeof b=="function"?b(_):b;if(y)w(x);else if(E){const k=x.length===0?_.map(P=>({type:"remove",id:P.id})):x.map(P=>({item:P,type:"reset"}));E(k)}},[]),m=he.useCallback(b=>{const _=Array.isArray(b)?b:[b],{getNodes:w,setNodes:y,hasDefaultNodes:E,onNodesChange:x}=n.getState();if(E){const P=[...w(),..._];y(P)}else if(x){const k=_.map(P=>({item:P,type:"add"}));x(k)}},[]),g=he.useCallback(b=>{const _=Array.isArray(b)?b:[b],{edges:w=[],setEdges:y,hasDefaultEdges:E,onEdgesChange:x}=n.getState();if(E)y([...w,..._]);else if(x){const k=_.map(P=>({item:P,type:"add"}));x(k)}},[]),d=he.useCallback(()=>{const{getNodes:b,edges:_=[],transform:w}=n.getState(),[y,E,x]=w;return{nodes:b().map(k=>({...k})),edges:_.map(k=>({...k})),viewport:{x:y,y:E,zoom:x}}},[]),p=he.useCallback(({nodes:b,edges:_})=>{const{nodeInternals:w,getNodes:y,edges:E,hasDefaultNodes:x,hasDefaultEdges:k,onNodesDelete:P,onEdgesDelete:R,onNodesChange:j,onEdgesChange:z}=n.getState(),L=(b||[]).map(U=>U.id),M=(_||[]).map(U=>U.id),D=y().reduce((U,J)=>{const oe=!L.includes(J.id)&&J.parentNode&&U.find(Y=>Y.id===J.parentNode);return(typeof J.deletable=="boolean"?J.deletable:!0)&&(L.includes(J.id)||oe)&&U.push(J),U},[]),F=E.filter(U=>typeof U.deletable=="boolean"?U.deletable:!0),B=F.filter(U=>M.includes(U.id));if(D||B){const U=rE(D,F),J=[...B,...U],oe=J.reduce((de,Y)=>(de.includes(Y.id)||de.push(Y.id),de),[]);if((k||x)&&(k&&n.setState({edges:E.filter(de=>!oe.includes(de.id))}),x&&(D.forEach(de=>{w.delete(de.id)}),n.setState({nodeInternals:new Map(w)}))),oe.length>0&&(R?.(J),z&&z(oe.map(de=>({id:de,type:"remove"})))),D.length>0&&(P?.(D),j)){const de=D.map(Y=>({id:Y.id,type:"remove"}));j(de)}}},[]),h=he.useCallback(b=>{const _=y5(b),w=_?null:n.getState().nodeInternals.get(b.id);return[_?b:US(w),w,_]},[]),s=he.useCallback((b,_=!0,w)=>{const[y,E,x]=h(b);return y?(w||n.getState().getNodes()).filter(k=>{if(!x&&(k.id===E.id||!k.positionAbsolute))return!1;const P=US(k),R=Um(P,y);return _&&R>0||R>=b.width*b.height}):[]},[]),S=he.useCallback((b,_,w=!0)=>{const[y]=h(b);if(!y)return!1;const E=Um(y,_);return w&&E>0||E>=b.width*b.height},[]);return he.useMemo(()=>({...e,getNodes:r,getNode:o,getEdges:i,getEdge:l,setNodes:c,setEdges:f,addNodes:m,addEdges:g,toObject:d,deleteElements:p,getIntersectingNodes:s,isNodeIntersecting:S}),[e,r,o,i,l,c,f,m,g,d,p,s,S])}var tL=({deleteKeyCode:e,multiSelectionKeyCode:n})=>{const r=en(),{deleteElements:o}=Js(),i=sa(e),l=sa(n);he.useEffect(()=>{if(i){const{edges:c,getNodes:f}=r.getState(),m=f().filter(d=>d.selected),g=c.filter(d=>d.selected);o({nodes:m,edges:g}),r.setState({nodesSelectionActive:!1})}},[i]),he.useEffect(()=>{r.setState({multiSelectionActive:l})},[l])};function nL(e){const n=en();he.useEffect(()=>{let r;const o=()=>{if(!e.current)return;const i=Hm(e.current);(i.height===0||i.width===0)&&n.getState().onError?.("004",Tr.error004()),n.setState({width:i.width||500,height:i.height||500})};return o(),window.addEventListener("resize",o),e.current&&(r=new ResizeObserver(()=>o()),r.observe(e.current)),()=>{window.removeEventListener("resize",o),r&&e.current&&r.unobserve(e.current)}},[])}const rg={position:"absolute",width:"100%",height:"100%",top:0,left:0},rL=(e,n)=>e.x!==n.x||e.y!==n.y||e.zoom!==n.k,$s=e=>({x:e.x,y:e.y,zoom:e.k}),Zo=(e,n)=>e.target.closest(`.${n}`),OE=(e,n)=>n===2&&Array.isArray(e)&&e.includes(2),kE=e=>{const n=e.ctrlKey&&Us()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*n},oL=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection,d3ZoomHandler:e.d3ZoomHandler,userSelectionActive:e.userSelectionActive}),iL=({onMove:e,onMoveStart:n,onMoveEnd:r,onPaneContextMenu:o,zoomOnScroll:i=!0,zoomOnPinch:l=!0,panOnScroll:c=!1,panOnScrollSpeed:f=.5,panOnScrollMode:m=yo.Free,zoomOnDoubleClick:g=!0,elementsSelectable:d,panOnDrag:p=!0,defaultViewport:h,translateExtent:s,minZoom:S,maxZoom:b,zoomActivationKeyCode:_,preventScrolling:w=!0,children:y,noWheelClassName:E,noPanClassName:x})=>{const k=he.useRef(),P=en(),R=he.useRef(!1),j=he.useRef(!1),z=he.useRef(null),L=he.useRef({x:0,y:0,zoom:0}),{d3Zoom:M,d3Selection:D,d3ZoomHandler:F,userSelectionActive:B}=Tt(oL,ln),U=sa(_),J=he.useRef(0),oe=he.useRef(!1),de=he.useRef();return nL(z),he.useEffect(()=>{if(z.current){const Y=z.current.getBoundingClientRect(),ee=DS().scaleExtent([S,b]).translateExtent(s),W=jn(z.current).call(ee),ne=Nr.translate(h.x,h.y).scale(Ko(h.zoom,S,b)),ae=[[0,0],[Y.width,Y.height]],te=ee.constrain()(ne,ae,s);ee.transform(W,te),ee.wheelDelta(kE),P.setState({d3Zoom:ee,d3Selection:W,d3ZoomHandler:W.on("wheel.zoom"),transform:[te.x,te.y,te.k],domNode:z.current.closest(".react-flow")})}},[]),he.useEffect(()=>{D&&M&&(c&&!U&&!B?D.on("wheel.zoom",Y=>{if(Zo(Y,E))return!1;Y.preventDefault(),Y.stopImmediatePropagation();const ee=D.property("__zoom").k||1,W=Us();if(Y.ctrlKey&&l&&W){const ge=$n(Y),be=kE(Y),Ae=ee*Math.pow(2,be);M.scaleTo(D,Ae,ge,Y);return}const ne=Y.deltaMode===1?20:1;let ae=m===yo.Vertical?0:Y.deltaX*ne,te=m===yo.Horizontal?0:Y.deltaY*ne;!W&&Y.shiftKey&&m!==yo.Vertical&&(ae=Y.deltaY*ne,te=0),M.translateBy(D,-(ae/ee)*f,-(te/ee)*f,{internal:!0});const re=$s(D.property("__zoom")),{onViewportChangeStart:Z,onViewportChange:se,onViewportChangeEnd:pe}=P.getState();clearTimeout(de.current),oe.current||(oe.current=!0,n?.(Y,re),Z?.(re)),oe.current&&(e?.(Y,re),se?.(re),de.current=setTimeout(()=>{r?.(Y,re),pe?.(re),oe.current=!1},150))},{passive:!1}):typeof F<"u"&&D.on("wheel.zoom",function(Y,ee){if(!w||Zo(Y,E))return null;Y.preventDefault(),F.call(this,Y,ee)},{passive:!1}))},[B,c,m,D,M,F,U,l,w,E,n,e,r]),he.useEffect(()=>{M&&M.on("start",Y=>{if(!Y.sourceEvent||Y.sourceEvent.internal)return null;J.current=Y.sourceEvent?.button;const{onViewportChangeStart:ee}=P.getState(),W=$s(Y.transform);R.current=!0,L.current=W,Y.sourceEvent?.type==="mousedown"&&P.setState({paneDragging:!0}),ee?.(W),n?.(Y.sourceEvent,W)})},[M,n]),he.useEffect(()=>{M&&(B&&!R.current?M.on("zoom",null):B||M.on("zoom",Y=>{const{onViewportChange:ee}=P.getState();if(P.setState({transform:[Y.transform.x,Y.transform.y,Y.transform.k]}),j.current=!!(o&&OE(p,J.current??0)),(e||ee)&&!Y.sourceEvent?.internal){const W=$s(Y.transform);ee?.(W),e?.(Y.sourceEvent,W)}}))},[B,M,e,p,o]),he.useEffect(()=>{M&&M.on("end",Y=>{if(!Y.sourceEvent||Y.sourceEvent.internal)return null;const{onViewportChangeEnd:ee}=P.getState();if(R.current=!1,P.setState({paneDragging:!1}),o&&OE(p,J.current??0)&&!j.current&&o(Y.sourceEvent),j.current=!1,(r||ee)&&rL(L.current,Y.transform)){const W=$s(Y.transform);L.current=W,clearTimeout(k.current),k.current=setTimeout(()=>{ee?.(W),r?.(Y.sourceEvent,W)},c?150:0)}})},[M,c,p,r,o]),he.useEffect(()=>{M&&M.filter(Y=>{const ee=U||i,W=l&&Y.ctrlKey;if(Y.button===1&&Y.type==="mousedown"&&(Zo(Y,"react-flow__node")||Zo(Y,"react-flow__edge")))return!0;if(!p&&!ee&&!c&&!g&&!l||B||!g&&Y.type==="dblclick"||Zo(Y,E)&&Y.type==="wheel"||Zo(Y,x)&&Y.type!=="wheel"||!l&&Y.ctrlKey&&Y.type==="wheel"||!ee&&!c&&!W&&Y.type==="wheel"||!p&&(Y.type==="mousedown"||Y.type==="touchstart")||Array.isArray(p)&&!p.includes(Y.button)&&(Y.type==="mousedown"||Y.type==="touchstart"))return!1;const ne=Array.isArray(p)&&p.includes(Y.button)||!Y.button||Y.button<=1;return(!Y.ctrlKey||Y.type==="wheel")&&ne})},[B,M,i,l,c,g,p,d,U]),K.jsx("div",{className:"react-flow__renderer",ref:z,style:rg,children:y})},aL=e=>({userSelectionActive:e.userSelectionActive,userSelectionRect:e.userSelectionRect});function sL(){const{userSelectionActive:e,userSelectionRect:n}=Tt(aL,ln);return e&&n?K.jsx("div",{className:"react-flow__selection react-flow__container",style:{width:n.width,height:n.height,transform:`translate(${n.x}px, ${n.y}px)`}}):null}function CE(e,n){const r=e.find(o=>o.id===n.parentNode);if(r){const o=n.position.x+n.width-r.width,i=n.position.y+n.height-r.height;if(o>0||i>0||n.position.x<0||n.position.y<0){if(r.style={...r.style},r.style.width=r.style.width??r.width,r.style.height=r.style.height??r.height,o>0&&(r.style.width+=o),i>0&&(r.style.height+=i),n.position.x<0){const l=Math.abs(n.position.x);r.position.x=r.position.x-l,r.style.width+=l,n.position.x=0}if(n.position.y<0){const l=Math.abs(n.position.y);r.position.y=r.position.y-l,r.style.height+=l,n.position.y=0}r.width=r.style.width,r.height=r.style.height}}}function AE(e,n){if(e.some(o=>o.type==="reset"))return e.filter(o=>o.type==="reset").map(o=>o.item);const r=e.filter(o=>o.type==="add").map(o=>o.item);return n.reduce((o,i)=>{const l=e.filter(f=>f.id===i.id);if(l.length===0)return o.push(i),o;const c={...i};for(const f of l)if(f)switch(f.type){case"select":{c.selected=f.selected;break}case"position":{typeof f.position<"u"&&(c.position=f.position),typeof f.positionAbsolute<"u"&&(c.positionAbsolute=f.positionAbsolute),typeof f.dragging<"u"&&(c.dragging=f.dragging),c.expandParent&&CE(o,c);break}case"dimensions":{typeof f.dimensions<"u"&&(c.width=f.dimensions.width,c.height=f.dimensions.height),typeof f.updateStyle<"u"&&(c.style={...c.style||{},...f.dimensions}),typeof f.resizing=="boolean"&&(c.resizing=f.resizing),c.expandParent&&CE(o,c);break}case"remove":return o}return o.push(c),o},r)}function NE(e,n){return AE(e,n)}function lL(e,n){return AE(e,n)}const Xr=(e,n)=>({id:e,type:"select",selected:n});function Qo(e,n){return e.reduce((r,o)=>{const i=n.includes(o.id);return!o.selected&&i?(o.selected=!0,r.push(Xr(o.id,!0))):o.selected&&!i&&(o.selected=!1,r.push(Xr(o.id,!1))),r},[])}const og=(e,n)=>r=>{r.target===n.current&&e?.(r)},uL=e=>({userSelectionActive:e.userSelectionActive,elementsSelectable:e.elementsSelectable,dragging:e.paneDragging}),TE=he.memo(({isSelecting:e,selectionMode:n=aa.Full,panOnDrag:r,onSelectionStart:o,onSelectionEnd:i,onPaneClick:l,onPaneContextMenu:c,onPaneScroll:f,onPaneMouseEnter:m,onPaneMouseMove:g,onPaneMouseLeave:d,children:p})=>{const h=he.useRef(null),s=en(),S=he.useRef(0),b=he.useRef(0),_=he.useRef(),{userSelectionActive:w,elementsSelectable:y,dragging:E}=Tt(uL,ln),x=()=>{s.setState({userSelectionActive:!1,userSelectionRect:null}),S.current=0,b.current=0},k=F=>{l?.(F),s.getState().resetSelectedElements(),s.setState({nodesSelectionActive:!1})},P=F=>{if(Array.isArray(r)&&r?.includes(2)){F.preventDefault();return}c?.(F)},R=f?F=>f(F):void 0,j=F=>{const{resetSelectedElements:B,domNode:U}=s.getState();if(_.current=U?.getBoundingClientRect(),!y||!e||F.button!==0||F.target!==h.current||!_.current)return;const{x:J,y:oe}=Yr(F,_.current);B(),s.setState({userSelectionRect:{width:0,height:0,startX:J,startY:oe,x:J,y:oe}}),o?.(F)},z=F=>{const{userSelectionRect:B,nodeInternals:U,edges:J,transform:oe,onNodesChange:de,onEdgesChange:Y,nodeOrigin:ee,getNodes:W}=s.getState();if(!e||!_.current||!B)return;s.setState({userSelectionActive:!0,nodesSelectionActive:!1});const ne=Yr(F,_.current),ae=B.startX??0,te=B.startY??0,re={...B,x:ne.x<ae?ne.x:ae,y:ne.y<te?ne.y:te,width:Math.abs(ne.x-ae),height:Math.abs(ne.y-te)},Z=W(),se=nE(U,re,oe,n===aa.Partial,!0,ee),pe=rE(se,J).map(be=>be.id),ge=se.map(be=>be.id);if(S.current!==ge.length){S.current=ge.length;const be=Qo(Z,ge);be.length&&de?.(be)}if(b.current!==pe.length){b.current=pe.length;const be=Qo(J,pe);be.length&&Y?.(be)}s.setState({userSelectionRect:re})},L=F=>{if(F.button!==0)return;const{userSelectionRect:B}=s.getState();!w&&B&&F.target===h.current&&k?.(F),s.setState({nodesSelectionActive:S.current>0}),x(),i?.(F)},M=F=>{w&&(s.setState({nodesSelectionActive:S.current>0}),i?.(F)),x()},D=y&&(e||w);return K.jsxs("div",{className:un(["react-flow__pane",{dragging:E,selection:e}]),onClick:D?void 0:og(k,h),onContextMenu:og(P,h),onWheel:og(R,h),onMouseEnter:D?void 0:m,onMouseDown:D?j:void 0,onMouseMove:D?z:g,onMouseUp:D?L:void 0,onMouseLeave:D?M:d,ref:h,style:rg,children:[p,K.jsx(sL,{})]})});TE.displayName="Pane";function RE(e,n){if(!e.parentNode)return!1;const r=n.get(e.parentNode);return r?r.selected?!0:RE(r,n):!1}function PE(e,n,r){let o=e;do{if(o?.matches(n))return!0;if(o===r.current)return!1;o=o.parentElement}while(o);return!1}function cL(e,n,r,o){return Array.from(e.values()).filter(i=>(i.selected||i.id===o)&&(!i.parentNode||!RE(i,e))&&(i.draggable||n&&typeof i.draggable>"u")).map(i=>({id:i.id,position:i.position||{x:0,y:0},positionAbsolute:i.positionAbsolute||{x:0,y:0},distance:{x:r.x-(i.positionAbsolute?.x??0),y:r.y-(i.positionAbsolute?.y??0)},delta:{x:0,y:0},extent:i.extent,parentNode:i.parentNode,width:i.width,height:i.height}))}function fL(e,n){return!n||n==="parent"?n:[n[0],[n[1][0]-(e.width||0),n[1][1]-(e.height||0)]]}function IE(e,n,r,o,i=[0,0],l){const c=fL(e,e.extent||o);let f=c;if(e.extent==="parent")if(e.parentNode&&e.width&&e.height){const d=r.get(e.parentNode),{x:p,y:h}=bo(d,i).positionAbsolute;f=d&&Ln(p)&&Ln(h)&&Ln(d.width)&&Ln(d.height)?[[p+e.width*i[0],h+e.height*i[1]],[p+d.width-e.width+e.width*i[0],h+d.height-e.height+e.height*i[1]]]:f}else l?.("005",Tr.error005()),f=c;else if(e.extent&&e.parentNode){const d=r.get(e.parentNode),{x:p,y:h}=bo(d,i).positionAbsolute;f=[[e.extent[0][0]+p,e.extent[0][1]+h],[e.extent[1][0]+p,e.extent[1][1]+h]]}let m={x:0,y:0};if(e.parentNode){const d=r.get(e.parentNode);m=bo(d,i).positionAbsolute}const g=f&&f!=="parent"?Vm(n,f):n;return{position:{x:g.x-m.x,y:g.y-m.y},positionAbsolute:g}}function ig({nodeId:e,dragItems:n,nodeInternals:r}){const o=n.map(i=>({...r.get(i.id),position:i.position,positionAbsolute:i.positionAbsolute}));return[e?o.find(i=>i.id===e):o[0],o]}const ME=(e,n,r,o)=>{const i=n.querySelectorAll(e);if(!i||!i.length)return null;const l=Array.from(i),c=n.getBoundingClientRect(),f={x:c.width*o[0],y:c.height*o[1]};return l.map(m=>{const g=m.getBoundingClientRect();return{id:m.getAttribute("data-handleid"),position:m.getAttribute("data-handlepos"),x:(g.left-c.left-f.x)/r,y:(g.top-c.top-f.y)/r,...Hm(m)}})};function la(e,n,r){return r===void 0?r:o=>{const i=n().nodeInternals.get(e);i&&r(o,{...i})}}function ag({id:e,store:n,unselect:r=!1,nodeRef:o}){const{addSelectedNodes:i,unselectNodesAndEdges:l,multiSelectionActive:c,nodeInternals:f,onError:m}=n.getState(),g=f.get(e);if(!g){m?.("012",Tr.error012(e));return}n.setState({nodesSelectionActive:!1}),g.selected?(r||g.selected&&c)&&(l({nodes:[g]}),requestAnimationFrame(()=>o?.current?.blur())):i([e])}function dL(){const e=en();return he.useCallback(({sourceEvent:r})=>{const{transform:o,snapGrid:i,snapToGrid:l}=e.getState(),c=r.touches?r.touches[0].clientX:r.clientX,f=r.touches?r.touches[0].clientY:r.clientY,m={x:(c-o[0])/o[2],y:(f-o[1])/o[2]};return{xSnapped:l?i[0]*Math.round(m.x/i[0]):m.x,ySnapped:l?i[1]*Math.round(m.y/i[1]):m.y,...m}},[])}function sg(e){return(n,r,o)=>e?.(n,o)}function jE({nodeRef:e,disabled:n=!1,noDragClassName:r,handleSelector:o,nodeId:i,isSelectable:l,selectNodesOnDrag:c}){const f=en(),[m,g]=he.useState(!1),d=he.useRef([]),p=he.useRef({x:null,y:null}),h=he.useRef(0),s=he.useRef(null),S=he.useRef({x:0,y:0}),b=he.useRef(null),_=he.useRef(!1),w=dL();return he.useEffect(()=>{if(e?.current){const y=jn(e.current),E=({x:k,y:P})=>{const{nodeInternals:R,onNodeDrag:j,onSelectionDrag:z,updateNodePositions:L,nodeExtent:M,snapGrid:D,snapToGrid:F,nodeOrigin:B,onError:U}=f.getState();p.current={x:k,y:P};let J=!1,oe={x:0,y:0,x2:0,y2:0};if(d.current.length>1&&M){const Y=Xs(d.current,B);oe=ra(Y)}if(d.current=d.current.map(Y=>{const ee={x:k-Y.distance.x,y:P-Y.distance.y};F&&(ee.x=D[0]*Math.round(ee.x/D[0]),ee.y=D[1]*Math.round(ee.y/D[1]));const W=[[M[0][0],M[0][1]],[M[1][0],M[1][1]]];d.current.length>1&&M&&!Y.extent&&(W[0][0]=Y.positionAbsolute.x-oe.x+M[0][0],W[1][0]=Y.positionAbsolute.x+(Y.width??0)-oe.x2+M[1][0],W[0][1]=Y.positionAbsolute.y-oe.y+M[0][1],W[1][1]=Y.positionAbsolute.y+(Y.height??0)-oe.y2+M[1][1]);const ne=IE(Y,ee,R,W,B,U);return J=J||Y.position.x!==ne.position.x||Y.position.y!==ne.position.y,Y.position=ne.position,Y.positionAbsolute=ne.positionAbsolute,Y}),!J)return;L(d.current,!0,!0),g(!0);const de=i?j:sg(z);if(de&&b.current){const[Y,ee]=ig({nodeId:i,dragItems:d.current,nodeInternals:R});de(b.current,Y,ee)}},x=()=>{if(!s.current)return;const[k,P]=qS(S.current,s.current);if(k!==0||P!==0){const{transform:R,panBy:j}=f.getState();p.current.x=(p.current.x??0)-k/R[2],p.current.y=(p.current.y??0)-P/R[2],j({x:k,y:P})&&E(p.current)}h.current=requestAnimationFrame(x)};if(n)y.on(".drag",null);else{const k=_M().on("start",P=>{const{nodeInternals:R,multiSelectionActive:j,domNode:z,nodesDraggable:L,unselectNodesAndEdges:M,onNodeDragStart:D,onSelectionDragStart:F}=f.getState(),B=i?D:sg(F);!c&&!j&&i&&(R.get(i)?.selected||M()),i&&l&&c&&ag({id:i,store:f,nodeRef:e});const U=w(P);if(p.current=U,d.current=cL(R,L,U,i),B&&d.current){const[J,oe]=ig({nodeId:i,dragItems:d.current,nodeInternals:R});B(P.sourceEvent,J,oe)}s.current=z?.getBoundingClientRect()||null,S.current=Yr(P.sourceEvent,s.current)}).on("drag",P=>{const R=w(P),{autoPanOnNodeDrag:j}=f.getState();!_.current&&j&&(_.current=!0,x()),(p.current.x!==R.xSnapped||p.current.y!==R.ySnapped)&&d.current&&(b.current=P.sourceEvent,S.current=Yr(P.sourceEvent,s.current),E(R))}).on("end",P=>{if(g(!1),_.current=!1,cancelAnimationFrame(h.current),d.current){const{updateNodePositions:R,nodeInternals:j,onNodeDragStop:z,onSelectionDragStop:L}=f.getState(),M=i?z:sg(L);if(R(d.current,!1,!1),M){const[D,F]=ig({nodeId:i,dragItems:d.current,nodeInternals:j});M(P.sourceEvent,D,F)}}}).filter(P=>{const R=P.target;return!P.button&&(!r||!PE(R,`.${r}`,e))&&(!o||PE(R,o,e))});return y.call(k),()=>{y.on(".drag",null)}}}},[e,n,r,o,l,f,i,c,w]),m}function LE(){const e=en();return he.useCallback(r=>{const{nodeInternals:o,nodeExtent:i,updateNodePositions:l,getNodes:c,snapToGrid:f,snapGrid:m,onError:g,nodesDraggable:d}=e.getState(),p=c().filter(y=>y.selected&&(y.draggable||d&&typeof y.draggable>"u")),h=f?m[0]:5,s=f?m[1]:5,S=r.isShiftPressed?4:1,b=r.x*h*S,_=r.y*s*S,w=p.map(y=>{if(y.positionAbsolute){const E={x:y.positionAbsolute.x+b,y:y.positionAbsolute.y+_};f&&(E.x=m[0]*Math.round(E.x/m[0]),E.y=m[1]*Math.round(E.y/m[1]));const{positionAbsolute:x,position:k}=IE(y,E,o,i,void 0,g);y.position=k,y.positionAbsolute=x}return y});l(w,!0,!1)},[])}const Jo={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}};var ua=e=>{const n=({id:r,type:o,data:i,xPos:l,yPos:c,xPosOrigin:f,yPosOrigin:m,selected:g,onClick:d,onMouseEnter:p,onMouseMove:h,onMouseLeave:s,onContextMenu:S,onDoubleClick:b,style:_,className:w,isDraggable:y,isSelectable:E,isConnectable:x,isFocusable:k,selectNodesOnDrag:P,sourcePosition:R,targetPosition:j,hidden:z,resizeObserver:L,dragHandle:M,zIndex:D,isParent:F,noDragClassName:B,noPanClassName:U,initialized:J,disableKeyboardA11y:oe,ariaLabel:de,rfId:Y})=>{const ee=en(),W=he.useRef(null),ne=he.useRef(R),ae=he.useRef(j),te=he.useRef(o),re=E||y||d||p||h||s,Z=LE(),se=la(r,ee.getState,p),pe=la(r,ee.getState,h),ge=la(r,ee.getState,s),be=la(r,ee.getState,S),Ae=la(r,ee.getState,b),Ue=Pe=>{if(E&&(!P||!y)&&ag({id:r,store:ee,nodeRef:W}),d){const ut=ee.getState().nodeInternals.get(r);ut&&d(Pe,{...ut})}},Ve=Pe=>{if(!Wm(Pe))if(WS.includes(Pe.key)&&E){const ut=Pe.key==="Escape";ag({id:r,store:ee,unselect:ut,nodeRef:W})}else!oe&&y&&g&&Object.prototype.hasOwnProperty.call(Jo,Pe.key)&&(ee.setState({ariaLiveMessage:`Moved selected node ${Pe.key.replace("Arrow","").toLowerCase()}. New position, x: ${~~l}, y: ${~~c}`}),Z({x:Jo[Pe.key].x,y:Jo[Pe.key].y,isShiftPressed:Pe.shiftKey}))};he.useEffect(()=>{if(W.current&&!z){const Pe=W.current;return L?.observe(Pe),()=>L?.unobserve(Pe)}},[z]),he.useEffect(()=>{const Pe=te.current!==o,ut=ne.current!==R,Ce=ae.current!==j;W.current&&(Pe||ut||Ce)&&(Pe&&(te.current=o),ut&&(ne.current=R),Ce&&(ae.current=j),ee.getState().updateNodeDimensions([{id:r,nodeElement:W.current,forceUpdate:!0}]))},[r,o,R,j]);const Fe=jE({nodeRef:W,disabled:z||!y,noDragClassName:B,handleSelector:M,nodeId:r,isSelectable:E,selectNodesOnDrag:P});return z?null:K.jsx("div",{className:un(["react-flow__node",`react-flow__node-${o}`,{[U]:y},w,{selected:g,selectable:E,parent:F,dragging:Fe}]),ref:W,style:{zIndex:D,transform:`translate(${f}px,${m}px)`,pointerEvents:re?"all":"none",visibility:J?"visible":"hidden",..._},"data-id":r,"data-testid":`rf__node-${r}`,onMouseEnter:se,onMouseMove:pe,onMouseLeave:ge,onContextMenu:be,onClick:Ue,onDoubleClick:Ae,onKeyDown:k?Ve:void 0,tabIndex:k?0:void 0,role:k?"button":void 0,"aria-describedby":oe?void 0:`${yE}-${Y}`,"aria-label":de,children:K.jsx(O5,{value:r,children:K.jsx(e,{id:r,data:i,type:o,xPos:l,yPos:c,selected:g,isConnectable:x,sourcePosition:R,targetPosition:j,dragging:Fe,dragHandle:M,zIndex:D})})})};return n.displayName="NodeWrapper",he.memo(n)};const hL=e=>{const n=e.getNodes().filter(r=>r.selected);return{...Xs(n,e.nodeOrigin),transformString:`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`,userSelectionActive:e.userSelectionActive}};function pL({onSelectionContextMenu:e,noPanClassName:n,disableKeyboardA11y:r}){const o=en(),{width:i,height:l,x:c,y:f,transformString:m,userSelectionActive:g}=Tt(hL,ln),d=LE(),p=he.useRef(null);if(he.useEffect(()=>{r||p.current?.focus({preventScroll:!0})},[r]),jE({nodeRef:p}),g||!i||!l)return null;const h=e?S=>{const b=o.getState().getNodes().filter(_=>_.selected);e(S,b)}:void 0,s=S=>{Object.prototype.hasOwnProperty.call(Jo,S.key)&&d({x:Jo[S.key].x,y:Jo[S.key].y,isShiftPressed:S.shiftKey})};return K.jsx("div",{className:un(["react-flow__nodesselection","react-flow__container",n]),style:{transform:m},children:K.jsx("div",{ref:p,className:"react-flow__nodesselection-rect",onContextMenu:h,tabIndex:r?void 0:-1,onKeyDown:r?void 0:s,style:{width:i,height:l,top:f,left:c}})})}var mL=he.memo(pL);const gL=e=>e.nodesSelectionActive,DE=({children:e,onPaneClick:n,onPaneMouseEnter:r,onPaneMouseMove:o,onPaneMouseLeave:i,onPaneContextMenu:l,onPaneScroll:c,deleteKeyCode:f,onMove:m,onMoveStart:g,onMoveEnd:d,selectionKeyCode:p,selectionOnDrag:h,selectionMode:s,onSelectionStart:S,onSelectionEnd:b,multiSelectionKeyCode:_,panActivationKeyCode:w,zoomActivationKeyCode:y,elementsSelectable:E,zoomOnScroll:x,zoomOnPinch:k,panOnScroll:P,panOnScrollSpeed:R,panOnScrollMode:j,zoomOnDoubleClick:z,panOnDrag:L,defaultViewport:M,translateExtent:D,minZoom:F,maxZoom:B,preventScrolling:U,onSelectionContextMenu:J,noWheelClassName:oe,noPanClassName:de,disableKeyboardA11y:Y})=>{const ee=Tt(gL),W=sa(p),ae=sa(w)||L,te=W||h&&ae!==!0;return tL({deleteKeyCode:f,multiSelectionKeyCode:_}),K.jsx(iL,{onMove:m,onMoveStart:g,onMoveEnd:d,onPaneContextMenu:l,elementsSelectable:E,zoomOnScroll:x,zoomOnPinch:k,panOnScroll:P,panOnScrollSpeed:R,panOnScrollMode:j,zoomOnDoubleClick:z,panOnDrag:!W&&ae,defaultViewport:M,translateExtent:D,minZoom:F,maxZoom:B,zoomActivationKeyCode:y,preventScrolling:U,noWheelClassName:oe,noPanClassName:de,children:K.jsxs(TE,{onSelectionStart:S,onSelectionEnd:b,onPaneClick:n,onPaneMouseEnter:r,onPaneMouseMove:o,onPaneMouseLeave:i,onPaneContextMenu:l,onPaneScroll:c,panOnDrag:ae,isSelecting:!!te,selectionMode:s,children:[e,ee&&K.jsx(mL,{onSelectionContextMenu:J,noPanClassName:de,disableKeyboardA11y:Y})]})})};DE.displayName="FlowRenderer";var vL=he.memo(DE);function yL(e){return Tt(he.useCallback(r=>e?nE(r.nodeInternals,{x:0,y:0,width:r.width,height:r.height},r.transform,!0):r.getNodes(),[e]))}function bL(e){const n={input:ua(e.input||hE),default:ua(e.default||eg),output:ua(e.output||mE),group:ua(e.group||tg)},r={},o=Object.keys(e).filter(i=>!["input","default","output","group"].includes(i)).reduce((i,l)=>(i[l]=ua(e[l]||eg),i),r);return{...n,...o}}const wL=({x:e,y:n,width:r,height:o,origin:i})=>!r||!o?{x:e,y:n}:i[0]<0||i[1]<0||i[0]>1||i[1]>1?{x:e,y:n}:{x:e-r*i[0],y:n-o*i[1]},xL=e=>({nodesDraggable:e.nodesDraggable,nodesConnectable:e.nodesConnectable,nodesFocusable:e.nodesFocusable,elementsSelectable:e.elementsSelectable,updateNodeDimensions:e.updateNodeDimensions,onError:e.onError}),BE=e=>{const{nodesDraggable:n,nodesConnectable:r,nodesFocusable:o,elementsSelectable:i,updateNodeDimensions:l,onError:c}=Tt(xL,ln),f=yL(e.onlyRenderVisibleElements),m=he.useRef(),g=he.useMemo(()=>{if(typeof ResizeObserver>"u")return null;const d=new ResizeObserver(p=>{const h=p.map(s=>({id:s.target.getAttribute("data-id"),nodeElement:s.target,forceUpdate:!0}));l(h)});return m.current=d,d},[]);return he.useEffect(()=>()=>{m?.current?.disconnect()},[]),K.jsx("div",{className:"react-flow__nodes",style:rg,children:f.map(d=>{let p=d.type||"default";e.nodeTypes[p]||(c?.("003",Tr.error003(p)),p="default");const h=e.nodeTypes[p]||e.nodeTypes.default,s=!!(d.draggable||n&&typeof d.draggable>"u"),S=!!(d.selectable||i&&typeof d.selectable>"u"),b=!!(d.connectable||r&&typeof d.connectable>"u"),_=!!(d.focusable||o&&typeof d.focusable>"u"),w=e.nodeExtent?Vm(d.positionAbsolute,e.nodeExtent):d.positionAbsolute,y=w?.x??0,E=w?.y??0,x=wL({x:y,y:E,width:d.width??0,height:d.height??0,origin:e.nodeOrigin});return K.jsx(h,{id:d.id,className:d.className,style:d.style,type:p,data:d.data,sourcePosition:d.sourcePosition||Be.Bottom,targetPosition:d.targetPosition||Be.Top,hidden:d.hidden,xPos:y,yPos:E,xPosOrigin:x.x,yPosOrigin:x.y,selectNodesOnDrag:e.selectNodesOnDrag,onClick:e.onNodeClick,onMouseEnter:e.onNodeMouseEnter,onMouseMove:e.onNodeMouseMove,onMouseLeave:e.onNodeMouseLeave,onContextMenu:e.onNodeContextMenu,onDoubleClick:e.onNodeDoubleClick,selected:!!d.selected,isDraggable:s,isSelectable:S,isConnectable:b,isFocusable:_,resizeObserver:g,dragHandle:d.dragHandle,zIndex:d[tn]?.z??0,isParent:!!d[tn]?.isParent,noDragClassName:e.noDragClassName,noPanClassName:e.noPanClassName,initialized:!!d.width&&!!d.height,rfId:e.rfId,disableKeyboardA11y:e.disableKeyboardA11y,ariaLabel:d.ariaLabel},d.id)})})};BE.displayName="NodeRenderer";var _L=he.memo(BE);const SL=(e,n,r)=>r===Be.Left?e-n:r===Be.Right?e+n:e,EL=(e,n,r)=>r===Be.Top?e-n:r===Be.Bottom?e+n:e,FE="react-flow__edgeupdater",qE=({position:e,centerX:n,centerY:r,radius:o=10,onMouseDown:i,onMouseEnter:l,onMouseOut:c,type:f})=>K.jsx("circle",{onMouseDown:i,onMouseEnter:l,onMouseOut:c,className:un([FE,`${FE}-${f}`]),cx:SL(n,o,e),cy:EL(r,o,e),r:o,stroke:"transparent",fill:"transparent"}),OL=()=>!0;var $o=e=>{const n=({id:r,className:o,type:i,data:l,onClick:c,onEdgeDoubleClick:f,selected:m,animated:g,label:d,labelStyle:p,labelShowBg:h,labelBgStyle:s,labelBgPadding:S,labelBgBorderRadius:b,style:_,source:w,target:y,sourceX:E,sourceY:x,targetX:k,targetY:P,sourcePosition:R,targetPosition:j,elementsSelectable:z,hidden:L,sourceHandleId:M,targetHandleId:D,onContextMenu:F,onMouseEnter:B,onMouseMove:U,onMouseLeave:J,edgeUpdaterRadius:oe,onEdgeUpdate:de,onEdgeUpdateStart:Y,onEdgeUpdateEnd:ee,markerEnd:W,markerStart:ne,rfId:ae,ariaLabel:te,isFocusable:re,isUpdatable:Z,pathOptions:se,interactionWidth:pe})=>{const ge=he.useRef(null),[be,Ae]=he.useState(!1),[Ue,Ve]=he.useState(!1),Fe=en(),Pe=he.useMemo(()=>`url(#${Qm(ne,ae)})`,[ne,ae]),ut=he.useMemo(()=>`url(#${Qm(W,ae)})`,[W,ae]);if(L)return null;const Ce=ft=>{const{edges:Rt,addSelectedEdges:Cn}=Fe.getState();if(z&&(Fe.setState({nodesSelectionActive:!1}),Cn([r])),c){const Yt=Rt.find(cn=>cn.id===r);c(ft,Yt)}},we=ia(r,Fe.getState,f),xe=ia(r,Fe.getState,F),Re=ia(r,Fe.getState,B),De=ia(r,Fe.getState,U),Ee=ia(r,Fe.getState,J),We=(ft,Rt)=>{if(ft.button!==0)return;const{edges:Cn,isValidConnection:Yt}=Fe.getState(),cn=Rt?y:w,So=(Rt?D:M)||null,Ir=Rt?"target":"source",ma=Yt||OL,Eo=Rt,$r=Cn.find(Mr=>Mr.id===r);Ve(!0),Y?.(ft,$r,Ir);const eo=Mr=>{Ve(!1),ee?.(Mr,$r,Ir)};lE({event:ft,handleId:So,nodeId:cn,onConnect:Mr=>de?.($r,Mr),isTarget:Eo,getState:Fe.getState,setState:Fe.setState,isValidConnection:ma,edgeUpdaterType:Ir,onEdgeUpdateEnd:eo})},Qe=ft=>We(ft,!0),ot=ft=>We(ft,!1),Mt=()=>Ae(!0),jt=()=>Ae(!1),pt=!z&&!c,vn=ft=>{if(WS.includes(ft.key)&&z){const{unselectNodesAndEdges:Rt,addSelectedEdges:Cn,edges:Yt}=Fe.getState();ft.key==="Escape"?(ge.current?.blur(),Rt({edges:[Yt.find(So=>So.id===r)]})):Cn([r])}};return K.jsxs("g",{className:un(["react-flow__edge",`react-flow__edge-${i}`,o,{selected:m,animated:g,inactive:pt,updating:be}]),onClick:Ce,onDoubleClick:we,onContextMenu:xe,onMouseEnter:Re,onMouseMove:De,onMouseLeave:Ee,onKeyDown:re?vn:void 0,tabIndex:re?0:void 0,role:re?"button":"img","data-testid":`rf__edge-${r}`,"aria-label":te===null?void 0:te||`Edge from ${w} to ${y}`,"aria-describedby":re?`${bE}-${ae}`:void 0,ref:ge,children:[!Ue&&K.jsx(e,{id:r,source:w,target:y,selected:m,animated:g,label:d,labelStyle:p,labelShowBg:h,labelBgStyle:s,labelBgPadding:S,labelBgBorderRadius:b,data:l,style:_,sourceX:E,sourceY:x,targetX:k,targetY:P,sourcePosition:R,targetPosition:j,sourceHandleId:M,targetHandleId:D,markerStart:Pe,markerEnd:ut,pathOptions:se,interactionWidth:pe}),Z&&K.jsxs(K.Fragment,{children:[(Z==="source"||Z===!0)&&K.jsx(qE,{position:R,centerX:E,centerY:x,radius:oe,onMouseDown:Qe,onMouseEnter:Mt,onMouseOut:jt,type:"source"}),(Z==="target"||Z===!0)&&K.jsx(qE,{position:j,centerX:k,centerY:P,radius:oe,onMouseDown:ot,onMouseEnter:Mt,onMouseOut:jt,type:"target"})]})]})};return n.displayName="EdgeWrapper",he.memo(n)};function kL(e){const n={default:$o(e.default||Ys),straight:$o(e.bezier||Xm),step:$o(e.step||Ym),smoothstep:$o(e.step||Gs),simplebezier:$o(e.simplebezier||Gm)},r={},o=Object.keys(e).filter(i=>!["default","bezier"].includes(i)).reduce((i,l)=>(i[l]=$o(e[l]||Ys),i),r);return{...n,...o}}function zE(e,n,r=null){const o=(r?.x||0)+n.x,i=(r?.y||0)+n.y,l=r?.width||n.width,c=r?.height||n.height;switch(e){case Be.Top:return{x:o+l/2,y:i};case Be.Right:return{x:o+l,y:i+c/2};case Be.Bottom:return{x:o+l/2,y:i+c};case Be.Left:return{x:o,y:i+c/2}}}function HE(e,n){return e?e.length===1||!n?e[0]:n&&e.find(r=>r.id===n)||null:null}const CL=(e,n,r,o,i,l)=>{const c=zE(r,e,n),f=zE(l,o,i);return{sourceX:c.x,sourceY:c.y,targetX:f.x,targetY:f.y}};function AL({sourcePos:e,targetPos:n,sourceWidth:r,sourceHeight:o,targetWidth:i,targetHeight:l,width:c,height:f,transform:m}){const g={x:Math.min(e.x,n.x),y:Math.min(e.y,n.y),x2:Math.max(e.x+r,n.x+i),y2:Math.max(e.y+o,n.y+l)};g.x===g.x2&&(g.x2+=1),g.y===g.y2&&(g.y2+=1);const d=ra({x:(0-m[0])/m[2],y:(0-m[1])/m[2],width:c/m[2],height:f/m[2]}),p=Math.max(0,Math.min(d.x2,g.x2)-Math.max(d.x,g.x)),h=Math.max(0,Math.min(d.y2,g.y2)-Math.max(d.y,g.y));return Math.ceil(p*h)>0}function VE(e){const n=e?.[tn]?.handleBounds||null,r=n&&e?.width&&e?.height&&typeof e?.positionAbsolute?.x<"u"&&typeof e?.positionAbsolute?.y<"u";return[{x:e?.positionAbsolute?.x||0,y:e?.positionAbsolute?.y||0,width:e?.width||0,height:e?.height||0},n,!!r]}const NL=[{level:0,isMaxLevel:!0,edges:[]}];function TL(e,n,r=!1){let o=-1;const i=e.reduce((c,f)=>{const m=Ln(f.zIndex);let g=m?f.zIndex:0;if(r){const d=n.get(f.target),p=n.get(f.source),h=f.selected||d?.selected||p?.selected,s=Math.max(p?.[tn]?.z||0,d?.[tn]?.z||0,1e3);g=(m?f.zIndex:0)+(h?s:0)}return c[g]?c[g].push(f):c[g]=[f],o=g>o?g:o,c},{}),l=Object.entries(i).map(([c,f])=>{const m=+c;return{edges:f,level:m,isMaxLevel:m===o}});return l.length===0?NL:l}function RL(e,n,r){const o=Tt(he.useCallback(i=>e?i.edges.filter(l=>{const c=n.get(l.source),f=n.get(l.target);return c?.width&&c?.height&&f?.width&&f?.height&&AL({sourcePos:c.positionAbsolute||{x:0,y:0},targetPos:f.positionAbsolute||{x:0,y:0},sourceWidth:c.width,sourceHeight:c.height,targetWidth:f.width,targetHeight:f.height,width:i.width,height:i.height,transform:i.transform})}):i.edges,[e,n]));return TL(o,n,r)}const PL=({color:e="none",strokeWidth:n=1})=>K.jsx("polyline",{stroke:e,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:n,fill:"none",points:"-5,-4 0,0 -5,4"}),IL=({color:e="none",strokeWidth:n=1})=>K.jsx("polyline",{stroke:e,strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:n,fill:e,points:"-5,-4 0,0 -5,4 -5,-4"}),UE={[Ws.Arrow]:PL,[Ws.ArrowClosed]:IL};function ML(e){const n=en();return he.useMemo(()=>Object.prototype.hasOwnProperty.call(UE,e)?UE[e]:(n.getState().onError?.("009",Tr.error009(e)),null),[e])}const jL=({id:e,type:n,color:r,width:o=12.5,height:i=12.5,markerUnits:l="strokeWidth",strokeWidth:c,orient:f="auto-start-reverse"})=>{const m=ML(n);return m?K.jsx("marker",{className:"react-flow__arrowhead",id:e,markerWidth:`${o}`,markerHeight:`${i}`,viewBox:"-10 -10 20 20",markerUnits:l,orient:f,refX:"0",refY:"0",children:K.jsx(m,{color:r,strokeWidth:c})}):null},LL=({defaultColor:e,rfId:n})=>r=>{const o=[];return r.edges.reduce((i,l)=>([l.markerStart,l.markerEnd].forEach(c=>{if(c&&typeof c=="object"){const f=Qm(c,n);o.includes(f)||(i.push({id:f,color:c.color||e,...c}),o.push(f))}}),i),[]).sort((i,l)=>i.id.localeCompare(l.id))},WE=({defaultColor:e,rfId:n})=>{const r=Tt(he.useCallback(LL({defaultColor:e,rfId:n}),[e,n]),(o,i)=>!(o.length!==i.length||o.some((l,c)=>l.id!==i[c].id)));return K.jsx("defs",{children:r.map(o=>K.jsx(jL,{id:o.id,type:o.type,color:o.color,width:o.width,height:o.height,markerUnits:o.markerUnits,strokeWidth:o.strokeWidth,orient:o.orient},o.id))})};WE.displayName="MarkerDefinitions";var DL=he.memo(WE);const BL=e=>({nodesConnectable:e.nodesConnectable,edgesFocusable:e.edgesFocusable,edgesUpdatable:e.edgesUpdatable,elementsSelectable:e.elementsSelectable,width:e.width,height:e.height,connectionMode:e.connectionMode,nodeInternals:e.nodeInternals,onError:e.onError}),GE=({defaultMarkerColor:e,onlyRenderVisibleElements:n,elevateEdgesOnSelect:r,rfId:o,edgeTypes:i,noPanClassName:l,onEdgeUpdate:c,onEdgeContextMenu:f,onEdgeMouseEnter:m,onEdgeMouseMove:g,onEdgeMouseLeave:d,onEdgeClick:p,edgeUpdaterRadius:h,onEdgeDoubleClick:s,onEdgeUpdateStart:S,onEdgeUpdateEnd:b,children:_})=>{const{edgesFocusable:w,edgesUpdatable:y,elementsSelectable:E,width:x,height:k,connectionMode:P,nodeInternals:R,onError:j}=Tt(BL,ln),z=RL(n,R,r);return x?K.jsxs(K.Fragment,{children:[z.map(({level:L,edges:M,isMaxLevel:D})=>K.jsxs("svg",{style:{zIndex:L},width:x,height:k,className:"react-flow__edges react-flow__container",children:[D&&K.jsx(DL,{defaultColor:e,rfId:o}),K.jsx("g",{children:M.map(F=>{const[B,U,J]=VE(R.get(F.source)),[oe,de,Y]=VE(R.get(F.target));if(!J||!Y)return null;let ee=F.type||"default";i[ee]||(j?.("011",Tr.error011(ee)),ee="default");const W=i[ee]||i.default,ne=P===vo.Strict?de.target:(de.target??[]).concat(de.source??[]),ae=HE(U.source,F.sourceHandle),te=HE(ne,F.targetHandle),re=ae?.position||Be.Bottom,Z=te?.position||Be.Top,se=!!(F.focusable||w&&typeof F.focusable>"u"),pe=typeof c<"u"&&(F.updatable||y&&typeof F.updatable>"u");if(!ae||!te)return j?.("008",Tr.error008(ae,F)),null;const{sourceX:ge,sourceY:be,targetX:Ae,targetY:Ue}=CL(B,ae,re,oe,te,Z);return K.jsx(W,{id:F.id,className:un([F.className,l]),type:ee,data:F.data,selected:!!F.selected,animated:!!F.animated,hidden:!!F.hidden,label:F.label,labelStyle:F.labelStyle,labelShowBg:F.labelShowBg,labelBgStyle:F.labelBgStyle,labelBgPadding:F.labelBgPadding,labelBgBorderRadius:F.labelBgBorderRadius,style:F.style,source:F.source,target:F.target,sourceHandleId:F.sourceHandle,targetHandleId:F.targetHandle,markerEnd:F.markerEnd,markerStart:F.markerStart,sourceX:ge,sourceY:be,targetX:Ae,targetY:Ue,sourcePosition:re,targetPosition:Z,elementsSelectable:E,onEdgeUpdate:c,onContextMenu:f,onMouseEnter:m,onMouseMove:g,onMouseLeave:d,onClick:p,edgeUpdaterRadius:h,onEdgeDoubleClick:s,onEdgeUpdateStart:S,onEdgeUpdateEnd:b,rfId:o,ariaLabel:F.ariaLabel,isFocusable:se,isUpdatable:pe,pathOptions:"pathOptions"in F?F.pathOptions:void 0,interactionWidth:F.interactionWidth},F.id)})})]},L)),_]}):null};GE.displayName="EdgeRenderer";var FL=he.memo(GE);const qL=e=>`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`;function zL({children:e}){const n=Tt(qL);return K.jsx("div",{className:"react-flow__viewport react-flow__container",style:{transform:n},children:e})}function HL(e){const n=Js(),r=he.useRef(!1);he.useEffect(()=>{!r.current&&n.viewportInitialized&&e&&(setTimeout(()=>e(n),1),r.current=!0)},[e,n.viewportInitialized])}const VL={[Be.Left]:Be.Right,[Be.Right]:Be.Left,[Be.Top]:Be.Bottom,[Be.Bottom]:Be.Top},KE=({nodeId:e,handleType:n,style:r,type:o=hr.Bezier,CustomComponent:i,connectionStatus:l})=>{const{fromNode:c,handleId:f,toX:m,toY:g,connectionMode:d}=Tt(he.useCallback(P=>({fromNode:P.nodeInternals.get(e),handleId:P.connectionHandleId,toX:(P.connectionPosition.x-P.transform[0])/P.transform[2],toY:(P.connectionPosition.y-P.transform[1])/P.transform[2],connectionMode:P.connectionMode}),[e]),ln),p=c?.[tn]?.handleBounds;let h=p?.[n];if(d===vo.Loose&&(h=h||p?.[n==="source"?"target":"source"]),!c||!h)return null;const s=f?h.find(P=>P.id===f):h[0],S=s?s.x+s.width/2:(c.width??0)/2,b=s?s.y+s.height/2:c.height??0,_=(c.positionAbsolute?.x??0)+S,w=(c.positionAbsolute?.y??0)+b,y=s?.position,E=y?VL[y]:null;if(!y||!E)return null;if(i)return K.jsx(i,{connectionLineType:o,connectionLineStyle:r,fromNode:c,fromHandle:s,fromX:_,fromY:w,toX:m,toY:g,fromPosition:y,toPosition:E,connectionStatus:l});let x="";const k={sourceX:_,sourceY:w,sourcePosition:y,targetX:m,targetY:g,targetPosition:E};return o===hr.Bezier?[x]=eE(k):o===hr.Step?[x]=Km({...k,borderRadius:0}):o===hr.SmoothStep?[x]=Km(k):o===hr.SimpleBezier?[x]=ZS(k):x=`M${_},${w} ${m},${g}`,K.jsx("path",{d:x,fill:"none",className:"react-flow__connection-path",style:r})};KE.displayName="ConnectionLine";const UL=e=>({nodeId:e.connectionNodeId,handleType:e.connectionHandleType,nodesConnectable:e.nodesConnectable,connectionStatus:e.connectionStatus,width:e.width,height:e.height});function WL({containerStyle:e,style:n,type:r,component:o}){const{nodeId:i,handleType:l,nodesConnectable:c,width:f,height:m,connectionStatus:g}=Tt(UL,ln);return!(i&&l&&f&&c)?null:K.jsx("svg",{style:e,width:f,height:m,className:"react-flow__edges react-flow__connectionline react-flow__container",children:K.jsx("g",{className:un(["react-flow__connection",g]),children:K.jsx(KE,{nodeId:i,handleType:l,style:n,type:r,CustomComponent:o,connectionStatus:g})})})}function YE(e,n){return he.useRef(null),en(),he.useMemo(()=>n(e),[e])}const XE=({nodeTypes:e,edgeTypes:n,onMove:r,onMoveStart:o,onMoveEnd:i,onInit:l,onNodeClick:c,onEdgeClick:f,onNodeDoubleClick:m,onEdgeDoubleClick:g,onNodeMouseEnter:d,onNodeMouseMove:p,onNodeMouseLeave:h,onNodeContextMenu:s,onSelectionContextMenu:S,onSelectionStart:b,onSelectionEnd:_,connectionLineType:w,connectionLineStyle:y,connectionLineComponent:E,connectionLineContainerStyle:x,selectionKeyCode:k,selectionOnDrag:P,selectionMode:R,multiSelectionKeyCode:j,panActivationKeyCode:z,zoomActivationKeyCode:L,deleteKeyCode:M,onlyRenderVisibleElements:D,elementsSelectable:F,selectNodesOnDrag:B,defaultViewport:U,translateExtent:J,minZoom:oe,maxZoom:de,preventScrolling:Y,defaultMarkerColor:ee,zoomOnScroll:W,zoomOnPinch:ne,panOnScroll:ae,panOnScrollSpeed:te,panOnScrollMode:re,zoomOnDoubleClick:Z,panOnDrag:se,onPaneClick:pe,onPaneMouseEnter:ge,onPaneMouseMove:be,onPaneMouseLeave:Ae,onPaneScroll:Ue,onPaneContextMenu:Ve,onEdgeUpdate:Fe,onEdgeContextMenu:Pe,onEdgeMouseEnter:ut,onEdgeMouseMove:Ce,onEdgeMouseLeave:we,edgeUpdaterRadius:xe,onEdgeUpdateStart:Re,onEdgeUpdateEnd:De,noDragClassName:Ee,noWheelClassName:We,noPanClassName:Qe,elevateEdgesOnSelect:ot,disableKeyboardA11y:Mt,nodeOrigin:jt,nodeExtent:pt,rfId:vn})=>{const ft=YE(e,bL),Rt=YE(n,kL);return HL(l),K.jsx(vL,{onPaneClick:pe,onPaneMouseEnter:ge,onPaneMouseMove:be,onPaneMouseLeave:Ae,onPaneContextMenu:Ve,onPaneScroll:Ue,deleteKeyCode:M,selectionKeyCode:k,selectionOnDrag:P,selectionMode:R,onSelectionStart:b,onSelectionEnd:_,multiSelectionKeyCode:j,panActivationKeyCode:z,zoomActivationKeyCode:L,elementsSelectable:F,onMove:r,onMoveStart:o,onMoveEnd:i,zoomOnScroll:W,zoomOnPinch:ne,zoomOnDoubleClick:Z,panOnScroll:ae,panOnScrollSpeed:te,panOnScrollMode:re,panOnDrag:se,defaultViewport:U,translateExtent:J,minZoom:oe,maxZoom:de,onSelectionContextMenu:S,preventScrolling:Y,noDragClassName:Ee,noWheelClassName:We,noPanClassName:Qe,disableKeyboardA11y:Mt,children:K.jsxs(zL,{children:[K.jsx(FL,{edgeTypes:Rt,onEdgeClick:f,onEdgeDoubleClick:g,onEdgeUpdate:Fe,onlyRenderVisibleElements:D,onEdgeContextMenu:Pe,onEdgeMouseEnter:ut,onEdgeMouseMove:Ce,onEdgeMouseLeave:we,onEdgeUpdateStart:Re,onEdgeUpdateEnd:De,edgeUpdaterRadius:xe,defaultMarkerColor:ee,noPanClassName:Qe,elevateEdgesOnSelect:!!ot,disableKeyboardA11y:Mt,rfId:vn,children:K.jsx(WL,{style:y,type:w,component:E,containerStyle:x})}),K.jsx("div",{className:"react-flow__edgelabel-renderer"}),K.jsx(_L,{nodeTypes:ft,onNodeClick:c,onNodeDoubleClick:m,onNodeMouseEnter:d,onNodeMouseMove:p,onNodeMouseLeave:h,onNodeContextMenu:s,selectNodesOnDrag:B,onlyRenderVisibleElements:D,noPanClassName:Qe,noDragClassName:Ee,disableKeyboardA11y:Mt,nodeOrigin:jt,nodeExtent:pt,rfId:vn})]})})};XE.displayName="GraphView";var GL=he.memo(XE);const lg=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],Zr={rfId:"1",width:0,height:0,transform:[0,0,1],nodeInternals:new Map,edges:[],onNodesChange:null,onEdgesChange:null,hasDefaultNodes:!1,hasDefaultEdges:!1,d3Zoom:null,d3Selection:null,d3ZoomHandler:void 0,minZoom:.5,maxZoom:2,translateExtent:lg,nodeExtent:lg,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionStatus:null,connectionMode:vo.Strict,domNode:null,paneDragging:!1,noPanClassName:"nopan",nodeOrigin:[0,0],snapGrid:[15,15],snapToGrid:!1,nodesDraggable:!0,nodesConnectable:!0,nodesFocusable:!0,edgesFocusable:!0,edgesUpdatable:!0,elementsSelectable:!0,elevateNodesOnSelect:!0,fitViewOnInit:!1,fitViewOnInitDone:!1,fitViewOnInitOptions:void 0,multiSelectionActive:!1,connectionStartHandle:null,connectionEndHandle:null,connectionClickStartHandle:null,connectOnClick:!0,ariaLiveMessage:"",autoPanOnConnect:!0,autoPanOnNodeDrag:!0,connectionRadius:20,onError:b5,isValidConnection:void 0},KL=()=>MP((e,n)=>({...Zr,setNodes:r=>{const{nodeInternals:o,nodeOrigin:i,elevateNodesOnSelect:l}=n();e({nodeInternals:ng(r,o,i,l)})},getNodes:()=>Array.from(n().nodeInternals.values()),setEdges:r=>{const{defaultEdgeOptions:o={}}=n();e({edges:r.map(i=>({...o,...i}))})},setDefaultNodesAndEdges:(r,o)=>{const i=typeof r<"u",l=typeof o<"u",c=i?ng(r,new Map,n().nodeOrigin,n().elevateNodesOnSelect):new Map;e({nodeInternals:c,edges:l?o:[],hasDefaultNodes:i,hasDefaultEdges:l})},updateNodeDimensions:r=>{const{onNodesChange:o,nodeInternals:i,fitViewOnInit:l,fitViewOnInitDone:c,fitViewOnInitOptions:f,domNode:m,nodeOrigin:g}=n(),d=m?.querySelector(".react-flow__viewport");if(!d)return;const p=window.getComputedStyle(d),{m22:h}=new window.DOMMatrixReadOnly(p.transform),s=r.reduce((b,_)=>{const w=i.get(_.id);if(w){const y=Hm(_.nodeElement);!!(y.width&&y.height&&(w.width!==y.width||w.height!==y.height||_.forceUpdate))&&(i.set(w.id,{...w,[tn]:{...w[tn],handleBounds:{source:ME(".source",_.nodeElement,h,g),target:ME(".target",_.nodeElement,h,g)}},...y}),b.push({id:w.id,type:"dimensions",dimensions:y}))}return b},[]);SE(i,g);const S=c||l&&!c&&EE(n,{initial:!0,...f});e({nodeInternals:new Map(i),fitViewOnInitDone:S}),s?.length>0&&o?.(s)},updateNodePositions:(r,o=!0,i=!1)=>{const{triggerNodeChanges:l}=n(),c=r.map(f=>{const m={id:f.id,type:"position",dragging:i};return o&&(m.positionAbsolute=f.positionAbsolute,m.position=f.position),m});l(c)},triggerNodeChanges:r=>{const{onNodesChange:o,nodeInternals:i,hasDefaultNodes:l,nodeOrigin:c,getNodes:f,elevateNodesOnSelect:m}=n();if(r?.length){if(l){const g=NE(r,f()),d=ng(g,i,c,m);e({nodeInternals:d})}o?.(r)}},addSelectedNodes:r=>{const{multiSelectionActive:o,edges:i,getNodes:l}=n();let c,f=null;o?c=r.map(m=>Xr(m,!0)):(c=Qo(l(),r),f=Qo(i,[])),Qs({changedNodes:c,changedEdges:f,get:n,set:e})},addSelectedEdges:r=>{const{multiSelectionActive:o,edges:i,getNodes:l}=n();let c,f=null;o?c=r.map(m=>Xr(m,!0)):(c=Qo(i,r),f=Qo(l(),[])),Qs({changedNodes:f,changedEdges:c,get:n,set:e})},unselectNodesAndEdges:({nodes:r,edges:o}={})=>{const{edges:i,getNodes:l}=n(),c=r||l(),f=o||i,m=c.map(d=>(d.selected=!1,Xr(d.id,!1))),g=f.map(d=>Xr(d.id,!1));Qs({changedNodes:m,changedEdges:g,get:n,set:e})},setMinZoom:r=>{const{d3Zoom:o,maxZoom:i}=n();o?.scaleExtent([r,i]),e({minZoom:r})},setMaxZoom:r=>{const{d3Zoom:o,minZoom:i}=n();o?.scaleExtent([i,r]),e({maxZoom:r})},setTranslateExtent:r=>{n().d3Zoom?.translateExtent(r),e({translateExtent:r})},resetSelectedElements:()=>{const{edges:r,getNodes:o}=n(),l=o().filter(f=>f.selected).map(f=>Xr(f.id,!1)),c=r.filter(f=>f.selected).map(f=>Xr(f.id,!1));Qs({changedNodes:l,changedEdges:c,get:n,set:e})},setNodeExtent:r=>{const{nodeInternals:o}=n();o.forEach(i=>{i.positionAbsolute=Vm(i.position,r)}),e({nodeExtent:r,nodeInternals:new Map(o)})},panBy:r=>{const{transform:o,width:i,height:l,d3Zoom:c,d3Selection:f,translateExtent:m}=n();if(!c||!f||!r.x&&!r.y)return!1;const g=Nr.translate(o[0]+r.x,o[1]+r.y).scale(o[2]),d=[[0,0],[i,l]],p=c?.constrain()(g,d,m);return c.transform(f,p),o[0]!==p.x||o[1]!==p.y||o[2]!==p.k},cancelConnection:()=>e({connectionNodeId:Zr.connectionNodeId,connectionHandleId:Zr.connectionHandleId,connectionHandleType:Zr.connectionHandleType,connectionStatus:Zr.connectionStatus,connectionStartHandle:Zr.connectionStartHandle,connectionEndHandle:Zr.connectionEndHandle}),reset:()=>e({...Zr})}),Object.is),ZE=({children:e})=>{const n=he.useRef(null);return n.current||(n.current=KL()),K.jsx(d5,{value:n.current,children:e})};ZE.displayName="ReactFlowProvider";const QE=({children:e})=>he.useContext(Vs)?K.jsx(K.Fragment,{children:e}):K.jsx(ZE,{children:e});QE.displayName="ReactFlowWrapper";const YL={input:hE,default:eg,output:mE,group:tg},XL={default:Ys,straight:Xm,step:Ym,smoothstep:Gs,simplebezier:Gm},ZL=[0,0],QL=[15,15],JL={x:0,y:0,zoom:1},$L={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0},ug=he.forwardRef(({nodes:e,edges:n,defaultNodes:r,defaultEdges:o,className:i,nodeTypes:l=YL,edgeTypes:c=XL,onNodeClick:f,onEdgeClick:m,onInit:g,onMove:d,onMoveStart:p,onMoveEnd:h,onConnect:s,onConnectStart:S,onConnectEnd:b,onClickConnectStart:_,onClickConnectEnd:w,onNodeMouseEnter:y,onNodeMouseMove:E,onNodeMouseLeave:x,onNodeContextMenu:k,onNodeDoubleClick:P,onNodeDragStart:R,onNodeDrag:j,onNodeDragStop:z,onNodesDelete:L,onEdgesDelete:M,onSelectionChange:D,onSelectionDragStart:F,onSelectionDrag:B,onSelectionDragStop:U,onSelectionContextMenu:J,onSelectionStart:oe,onSelectionEnd:de,connectionMode:Y=vo.Strict,connectionLineType:ee=hr.Bezier,connectionLineStyle:W,connectionLineComponent:ne,connectionLineContainerStyle:ae,deleteKeyCode:te="Backspace",selectionKeyCode:re="Shift",selectionOnDrag:Z=!1,selectionMode:se=aa.Full,panActivationKeyCode:pe="Space",multiSelectionKeyCode:ge=Us()?"Meta":"Control",zoomActivationKeyCode:be=Us()?"Meta":"Control",snapToGrid:Ae=!1,snapGrid:Ue=QL,onlyRenderVisibleElements:Ve=!1,selectNodesOnDrag:Fe=!0,nodesDraggable:Pe,nodesConnectable:ut,nodesFocusable:Ce,nodeOrigin:we=ZL,edgesFocusable:xe,edgesUpdatable:Re,elementsSelectable:De,defaultViewport:Ee=JL,minZoom:We=.5,maxZoom:Qe=2,translateExtent:ot=lg,preventScrolling:Mt=!0,nodeExtent:jt,defaultMarkerColor:pt="#b1b1b7",zoomOnScroll:vn=!0,zoomOnPinch:ft=!0,panOnScroll:Rt=!1,panOnScrollSpeed:Cn=.5,panOnScrollMode:Yt=yo.Free,zoomOnDoubleClick:cn=!0,panOnDrag:So=!0,onPaneClick:Ir,onPaneMouseEnter:ma,onPaneMouseMove:Eo,onPaneMouseLeave:$r,onPaneScroll:eo,onPaneContextMenu:cl,children:Mr,onEdgeUpdate:ga,onEdgeContextMenu:Og,onEdgeDoubleClick:va,onEdgeMouseEnter:kg,onEdgeMouseMove:ya,onEdgeMouseLeave:Cg,onEdgeUpdateStart:ba,onEdgeUpdateEnd:Ag,edgeUpdaterRadius:wa=10,onNodesChange:Ng,onEdgesChange:xa,noDragClassName:ei="nodrag",noWheelClassName:to="nowheel",noPanClassName:fl="nopan",fitView:dl=!1,fitViewOptions:ti,connectOnClick:hl=!0,attributionPosition:Oo,proOptions:_a,defaultEdgeOptions:Tg,elevateNodesOnSelect:Sa=!0,elevateEdgesOnSelect:ni=!1,disableKeyboardA11y:pl=!1,autoPanOnConnect:ml=!0,autoPanOnNodeDrag:Rg=!0,connectionRadius:Ea=20,isValidConnection:ri,onError:Oa,style:oi,id:no,...jr},Lr)=>{const pr=no||"1";return K.jsx("div",{...jr,style:{...oi,...$L},ref:Lr,className:un(["react-flow",i]),"data-testid":"rf__wrapper",id:no,children:K.jsxs(QE,{children:[K.jsx(GL,{onInit:g,onMove:d,onMoveStart:p,onMoveEnd:h,onNodeClick:f,onEdgeClick:m,onNodeMouseEnter:y,onNodeMouseMove:E,onNodeMouseLeave:x,onNodeContextMenu:k,onNodeDoubleClick:P,nodeTypes:l,edgeTypes:c,connectionLineType:ee,connectionLineStyle:W,connectionLineComponent:ne,connectionLineContainerStyle:ae,selectionKeyCode:re,selectionOnDrag:Z,selectionMode:se,deleteKeyCode:te,multiSelectionKeyCode:ge,panActivationKeyCode:pe,zoomActivationKeyCode:be,onlyRenderVisibleElements:Ve,selectNodesOnDrag:Fe,defaultViewport:Ee,translateExtent:ot,minZoom:We,maxZoom:Qe,preventScrolling:Mt,zoomOnScroll:vn,zoomOnPinch:ft,zoomOnDoubleClick:cn,panOnScroll:Rt,panOnScrollSpeed:Cn,panOnScrollMode:Yt,panOnDrag:So,onPaneClick:Ir,onPaneMouseEnter:ma,onPaneMouseMove:Eo,onPaneMouseLeave:$r,onPaneScroll:eo,onPaneContextMenu:cl,onSelectionContextMenu:J,onSelectionStart:oe,onSelectionEnd:de,onEdgeUpdate:ga,onEdgeContextMenu:Og,onEdgeDoubleClick:va,onEdgeMouseEnter:kg,onEdgeMouseMove:ya,onEdgeMouseLeave:Cg,onEdgeUpdateStart:ba,onEdgeUpdateEnd:Ag,edgeUpdaterRadius:wa,defaultMarkerColor:pt,noDragClassName:ei,noWheelClassName:to,noPanClassName:fl,elevateEdgesOnSelect:ni,rfId:pr,disableKeyboardA11y:pl,nodeOrigin:we,nodeExtent:jt}),K.jsx(V5,{nodes:e,edges:n,defaultNodes:r,defaultEdges:o,onConnect:s,onConnectStart:S,onConnectEnd:b,onClickConnectStart:_,onClickConnectEnd:w,nodesDraggable:Pe,nodesConnectable:ut,nodesFocusable:Ce,edgesFocusable:xe,edgesUpdatable:Re,elementsSelectable:De,elevateNodesOnSelect:Sa,minZoom:We,maxZoom:Qe,nodeExtent:jt,onNodesChange:Ng,onEdgesChange:xa,snapToGrid:Ae,snapGrid:Ue,connectionMode:Y,translateExtent:ot,connectOnClick:hl,defaultEdgeOptions:Tg,fitView:dl,fitViewOptions:ti,onNodesDelete:L,onEdgesDelete:M,onNodeDragStart:R,onNodeDrag:j,onNodeDragStop:z,onSelectionDrag:B,onSelectionDragStart:F,onSelectionDragStop:U,noPanClassName:fl,nodeOrigin:we,rfId:pr,autoPanOnConnect:ml,autoPanOnNodeDrag:Rg,onError:Oa,connectionRadius:Ea,isValidConnection:ri}),K.jsx(z5,{onSelectionChange:D}),Mr,K.jsx(p5,{proOptions:_a,position:Oo}),K.jsx(Y5,{rfId:pr,disableKeyboardA11y:pl})]})})});ug.displayName="ReactFlow";function JE(e){return n=>{const[r,o]=he.useState(n),i=he.useCallback(l=>o(c=>e(l,c)),[]);return[r,o,i]}}const e3=JE(NE),t3=JE(lL),$E=({id:e,x:n,y:r,width:o,height:i,style:l,color:c,strokeColor:f,strokeWidth:m,className:g,borderRadius:d,shapeRendering:p,onClick:h,selected:s})=>{const{background:S,backgroundColor:b}=l||{},_=c||S||b;return K.jsx("rect",{className:un(["react-flow__minimap-node",{selected:s},g]),x:n,y:r,rx:d,ry:d,width:o,height:i,fill:_,stroke:f,strokeWidth:m,shapeRendering:p,onClick:h?w=>h(w,e):void 0})};$E.displayName="MiniMapNode";var n3=he.memo($E);const r3=e=>e.nodeOrigin,o3=e=>e.getNodes().filter(n=>!n.hidden&&n.width&&n.height),cg=e=>e instanceof Function?e:()=>e;function i3({nodeStrokeColor:e="transparent",nodeColor:n="#e2e2e2",nodeClassName:r="",nodeBorderRadius:o=5,nodeStrokeWidth:i=2,nodeComponent:l=n3,onClick:c}){const f=Tt(o3,ln),m=Tt(r3),g=cg(n),d=cg(e),p=cg(r),h=typeof window>"u"||window.chrome?"crispEdges":"geometricPrecision";return K.jsx(K.Fragment,{children:f.map(s=>{const{x:S,y:b}=bo(s,m).positionAbsolute;return K.jsx(l,{x:S,y:b,width:s.width,height:s.height,style:s.style,selected:s.selected,className:p(s),color:g(s),borderRadius:o,strokeColor:d(s),strokeWidth:i,shapeRendering:h,onClick:c,id:s.id},s.id)})})}var a3=he.memo(i3);const s3=200,l3=150,u3=e=>{const n=e.getNodes(),r={x:-e.transform[0]/e.transform[2],y:-e.transform[1]/e.transform[2],width:e.width/e.transform[2],height:e.height/e.transform[2]};return{viewBB:r,boundingRect:n.length>0?v5(Xs(n,e.nodeOrigin),r):r,rfId:e.rfId}},c3="react-flow__minimap-desc";function eO({style:e,className:n,nodeStrokeColor:r="transparent",nodeColor:o="#e2e2e2",nodeClassName:i="",nodeBorderRadius:l=5,nodeStrokeWidth:c=2,nodeComponent:f,maskColor:m="rgb(240, 240, 240, 0.6)",maskStrokeColor:g="none",maskStrokeWidth:d=1,position:p="bottom-right",onClick:h,onNodeClick:s,pannable:S=!1,zoomable:b=!1,ariaLabel:_="React Flow mini map",inversePan:w=!1,zoomStep:y=10,offsetScale:E=5}){const x=en(),k=he.useRef(null),{boundingRect:P,viewBB:R,rfId:j}=Tt(u3,ln),z=e?.width??s3,L=e?.height??l3,M=P.width/z,D=P.height/L,F=Math.max(M,D),B=F*z,U=F*L,J=E*F,oe=P.x-(B-P.width)/2-J,de=P.y-(U-P.height)/2-J,Y=B+J*2,ee=U+J*2,W=`${c3}-${j}`,ne=he.useRef(0);ne.current=F,he.useEffect(()=>{if(k.current){const re=jn(k.current),Z=ge=>{const{transform:be,d3Selection:Ae,d3Zoom:Ue}=x.getState();if(ge.sourceEvent.type!=="wheel"||!Ae||!Ue)return;const Ve=-ge.sourceEvent.deltaY*(ge.sourceEvent.deltaMode===1?.05:ge.sourceEvent.deltaMode?1:.002)*y,Fe=be[2]*Math.pow(2,Ve);Ue.scaleTo(Ae,Fe)},se=ge=>{const{transform:be,d3Selection:Ae,d3Zoom:Ue,translateExtent:Ve,width:Fe,height:Pe}=x.getState();if(ge.sourceEvent.type!=="mousemove"||!Ae||!Ue)return;const ut=ne.current*Math.max(1,be[2])*(w?-1:1),Ce={x:be[0]-ge.sourceEvent.movementX*ut,y:be[1]-ge.sourceEvent.movementY*ut},we=[[0,0],[Fe,Pe]],xe=Nr.translate(Ce.x,Ce.y).scale(be[2]),Re=Ue.constrain()(xe,we,Ve);Ue.transform(Ae,Re)},pe=DS().on("zoom",S?se:null).on("zoom.wheel",b?Z:null);return re.call(pe),()=>{re.on("zoom",null)}}},[S,b,w,y]);const ae=h?re=>{const Z=$n(re);h(re,{x:Z[0],y:Z[1]})}:void 0,te=s?(re,Z)=>{const se=x.getState().nodeInternals.get(Z);s(re,se)}:void 0;return K.jsx(zm,{position:p,style:e,className:un(["react-flow__minimap",n]),"data-testid":"rf__minimap",children:K.jsxs("svg",{width:z,height:L,viewBox:`${oe} ${de} ${Y} ${ee}`,role:"img","aria-labelledby":W,ref:k,onClick:ae,children:[_&&K.jsx("title",{id:W,children:_}),K.jsx(a3,{onClick:te,nodeColor:o,nodeStrokeColor:r,nodeBorderRadius:l,nodeClassName:i,nodeStrokeWidth:c,nodeComponent:f}),K.jsx("path",{className:"react-flow__minimap-mask",d:`M${oe-J},${de-J}h${Y+J*2}v${ee+J*2}h${-Y-J*2}z
|
|
18
|
+
M${R.x},${R.y}h${R.width}v${R.height}h${-R.width}z`,fill:m,fillRule:"evenodd",stroke:g,strokeWidth:d,pointerEvents:"none"})]})})}eO.displayName="MiniMap";var tO=he.memo(eO);function f3(){return K.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",children:K.jsx("path",{d:"M32 18.133H18.133V32h-4.266V18.133H0v-4.266h13.867V0h4.266v13.867H32z"})})}function d3(){return K.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 5",children:K.jsx("path",{d:"M0 0h32v4.2H0z"})})}function h3(){return K.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 30",children:K.jsx("path",{d:"M3.692 4.63c0-.53.4-.938.939-.938h5.215V0H4.708C2.13 0 0 2.054 0 4.63v5.216h3.692V4.631zM27.354 0h-5.2v3.692h5.17c.53 0 .984.4.984.939v5.215H32V4.631A4.624 4.624 0 0027.354 0zm.954 24.83c0 .532-.4.94-.939.94h-5.215v3.768h5.215c2.577 0 4.631-2.13 4.631-4.707v-5.139h-3.692v5.139zm-23.677.94c-.531 0-.939-.4-.939-.94v-5.138H0v5.139c0 2.577 2.13 4.707 4.708 4.707h5.138V25.77H4.631z"})})}function p3(){return K.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:K.jsx("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0 8 0 4.571 3.429 4.571 7.619v3.048H3.048A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047zm4.724-13.866H7.467V7.619c0-2.59 2.133-4.724 4.723-4.724 2.591 0 4.724 2.133 4.724 4.724v3.048z"})})}function m3(){return K.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 25 32",children:K.jsx("path",{d:"M21.333 10.667H19.81V7.619C19.81 3.429 16.38 0 12.19 0c-4.114 1.828-1.37 2.133.305 2.438 1.676.305 4.42 2.59 4.42 5.181v3.048H3.047A3.056 3.056 0 000 13.714v15.238A3.056 3.056 0 003.048 32h18.285a3.056 3.056 0 003.048-3.048V13.714a3.056 3.056 0 00-3.048-3.047zM12.19 24.533a3.056 3.056 0 01-3.047-3.047 3.056 3.056 0 013.047-3.048 3.056 3.056 0 013.048 3.048 3.056 3.056 0 01-3.048 3.047z"})})}const ca=({children:e,className:n,...r})=>K.jsx("button",{type:"button",className:un(["react-flow__controls-button",n]),...r,children:e});ca.displayName="ControlButton";const g3=e=>({isInteractive:e.nodesDraggable||e.nodesConnectable||e.elementsSelectable,minZoomReached:e.transform[2]<=e.minZoom,maxZoomReached:e.transform[2]>=e.maxZoom}),nO=({style:e,showZoom:n=!0,showFitView:r=!0,showInteractive:o=!0,fitViewOptions:i,onZoomIn:l,onZoomOut:c,onFitView:f,onInteractiveChange:m,className:g,children:d,position:p="bottom-left"})=>{const h=en(),[s,S]=he.useState(!1),{isInteractive:b,minZoomReached:_,maxZoomReached:w}=Tt(g3,ln),{zoomIn:y,zoomOut:E,fitView:x}=Js();if(he.useEffect(()=>{S(!0)},[]),!s)return null;const k=()=>{y(),l?.()},P=()=>{E(),c?.()},R=()=>{x(i),f?.()},j=()=>{h.setState({nodesDraggable:!b,nodesConnectable:!b,elementsSelectable:!b}),m?.(!b)};return K.jsxs(zm,{className:un(["react-flow__controls",g]),position:p,style:e,"data-testid":"rf__controls",children:[n&&K.jsxs(K.Fragment,{children:[K.jsx(ca,{onClick:k,className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in",disabled:w,children:K.jsx(f3,{})}),K.jsx(ca,{onClick:P,className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out",disabled:_,children:K.jsx(d3,{})})]}),r&&K.jsx(ca,{className:"react-flow__controls-fitview",onClick:R,title:"fit view","aria-label":"fit view",children:K.jsx(h3,{})}),o&&K.jsx(ca,{className:"react-flow__controls-interactive",onClick:j,title:"toggle interactivity","aria-label":"toggle interactivity",children:b?K.jsx(m3,{}):K.jsx(p3,{})}),d]})};nO.displayName="Controls";var rO=he.memo(nO),nr;(function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"})(nr||(nr={}));function v3({color:e,dimensions:n,lineWidth:r}){return K.jsx("path",{stroke:e,strokeWidth:r,d:`M${n[0]/2} 0 V${n[1]} M0 ${n[1]/2} H${n[0]}`})}function y3({color:e,radius:n}){return K.jsx("circle",{cx:n,cy:n,r:n,fill:e})}const b3={[nr.Dots]:"#91919a",[nr.Lines]:"#eee",[nr.Cross]:"#e2e2e2"},w3={[nr.Dots]:1,[nr.Lines]:1,[nr.Cross]:6},x3=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function oO({id:e,variant:n=nr.Dots,gap:r=20,size:o,lineWidth:i=1,offset:l=2,color:c,style:f,className:m}){const g=he.useRef(null),{transform:d,patternId:p}=Tt(x3,ln),h=c||b3[n],s=o||w3[n],S=n===nr.Dots,b=n===nr.Cross,_=Array.isArray(r)?r:[r,r],w=[_[0]*d[2]||1,_[1]*d[2]||1],y=s*d[2],E=b?[y,y]:w,x=S?[y/l,y/l]:[E[0]/l,E[1]/l];return K.jsxs("svg",{className:un(["react-flow__background",m]),style:{...f,position:"absolute",width:"100%",height:"100%",top:0,left:0},ref:g,"data-testid":"rf__background",children:[K.jsx("pattern",{id:p+e,x:d[0]%w[0],y:d[1]%w[1],width:w[0],height:w[1],patternUnits:"userSpaceOnUse",patternTransform:`translate(-${x[0]},-${x[1]})`,children:S?K.jsx(y3,{color:h,radius:y/l}):K.jsx(v3,{dimensions:E,color:h,lineWidth:i})}),K.jsx("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${p+e})`})]})}oO.displayName="Background";var iO=he.memo(oO);function aO(e){var n,r,o="";if(typeof e=="string"||typeof e=="number")o+=e;else if(typeof e=="object")if(Array.isArray(e))for(n=0;n<e.length;n++)e[n]&&(r=aO(e[n]))&&(o&&(o+=" "),o+=r);else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function Qr(){for(var e,n,r=0,o="";r<arguments.length;)(e=arguments[r++])&&(n=aO(e))&&(o&&(o+=" "),o+=n);return o}const fa=e=>typeof e=="number"&&!isNaN(e),xo=e=>typeof e=="string",_n=e=>typeof e=="function",el=e=>xo(e)||_n(e)?e:null,fg=e=>he.isValidElement(e)||xo(e)||_n(e)||fa(e);function _3(e,n,r){r===void 0&&(r=300);const{scrollHeight:o,style:i}=e;requestAnimationFrame(()=>{i.minHeight="initial",i.height=o+"px",i.transition=`all ${r}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(n,r)})})}function tl(e){let{enter:n,exit:r,appendPosition:o=!1,collapse:i=!0,collapseDuration:l=300}=e;return function(c){let{children:f,position:m,preventExitTransition:g,done:d,nodeRef:p,isIn:h}=c;const s=o?`${n}--${m}`:n,S=o?`${r}--${m}`:r,b=he.useRef(0);return he.useLayoutEffect(()=>{const _=p.current,w=s.split(" "),y=E=>{E.target===p.current&&(_.dispatchEvent(new Event("d")),_.removeEventListener("animationend",y),_.removeEventListener("animationcancel",y),b.current===0&&E.type!=="animationcancel"&&_.classList.remove(...w))};_.classList.add(...w),_.addEventListener("animationend",y),_.addEventListener("animationcancel",y)},[]),he.useEffect(()=>{const _=p.current,w=()=>{_.removeEventListener("animationend",w),i?_3(_,d,l):d()};h||(g?w():(b.current=1,_.className+=` ${S}`,_.addEventListener("animationend",w)))},[h]),wt.default.createElement(wt.default.Fragment,null,f)}}function sO(e,n){return e!=null?{content:e.content,containerId:e.props.containerId,id:e.props.toastId,theme:e.props.theme,type:e.props.type,data:e.props.data||{},isLoading:e.props.isLoading,icon:e.props.icon,status:n}:{}}const Dn={list:new Map,emitQueue:new Map,on(e,n){return this.list.has(e)||this.list.set(e,[]),this.list.get(e).push(n),this},off(e,n){if(n){const r=this.list.get(e).filter(o=>o!==n);return this.list.set(e,r),this}return this.list.delete(e),this},cancelEmit(e){const n=this.emitQueue.get(e);return n&&(n.forEach(clearTimeout),this.emitQueue.delete(e)),this},emit(e){this.list.has(e)&&this.list.get(e).forEach(n=>{const r=setTimeout(()=>{n(...[].slice.call(arguments,1))},0);this.emitQueue.has(e)||this.emitQueue.set(e,[]),this.emitQueue.get(e).push(r)})}},nl=e=>{let{theme:n,type:r,...o}=e;return wt.default.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:n==="colored"?"currentColor":`var(--toastify-icon-color-${r})`,...o})},dg={info:function(e){return wt.default.createElement(nl,{...e},wt.default.createElement("path",{d:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}))},warning:function(e){return wt.default.createElement(nl,{...e},wt.default.createElement("path",{d:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}))},success:function(e){return wt.default.createElement(nl,{...e},wt.default.createElement("path",{d:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}))},error:function(e){return wt.default.createElement(nl,{...e},wt.default.createElement("path",{d:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}))},spinner:function(){return wt.default.createElement("div",{className:"Toastify__spinner"})}};function S3(e){const[,n]=he.useReducer(s=>s+1,0),[r,o]=he.useState([]),i=he.useRef(null),l=he.useRef(new Map).current,c=s=>r.indexOf(s)!==-1,f=he.useRef({toastKey:1,displayedToast:0,count:0,queue:[],props:e,containerId:null,isToastActive:c,getToast:s=>l.get(s)}).current;function m(s){let{containerId:S}=s;const{limit:b}=f.props;!b||S&&f.containerId!==S||(f.count-=f.queue.length,f.queue=[])}function g(s){o(S=>s==null?[]:S.filter(b=>b!==s))}function d(){const{toastContent:s,toastProps:S,staleId:b}=f.queue.shift();h(s,S,b)}function p(s,S){let{delay:b,staleId:_,...w}=S;if(!fg(s)||(function(D){return!i.current||f.props.enableMultiContainer&&D.containerId!==f.props.containerId||l.has(D.toastId)&&D.updateId==null})(w))return;const{toastId:y,updateId:E,data:x}=w,{props:k}=f,P=()=>g(y),R=E==null;R&&f.count++;const j={...k,style:k.toastStyle,key:f.toastKey++,...Object.fromEntries(Object.entries(w).filter(D=>{let[F,B]=D;return B!=null})),toastId:y,updateId:E,data:x,closeToast:P,isIn:!1,className:el(w.className||k.toastClassName),bodyClassName:el(w.bodyClassName||k.bodyClassName),progressClassName:el(w.progressClassName||k.progressClassName),autoClose:!w.isLoading&&(z=w.autoClose,L=k.autoClose,z===!1||fa(z)&&z>0?z:L),deleteToast(){const D=sO(l.get(y),"removed");l.delete(y),Dn.emit(4,D);const F=f.queue.length;if(f.count=y==null?f.count-f.displayedToast:f.count-1,f.count<0&&(f.count=0),F>0){const B=y==null?f.props.limit:1;if(F===1||B===1)f.displayedToast++,d();else{const U=B>F?F:B;f.displayedToast=U;for(let J=0;J<U;J++)d()}}else n()}};var z,L;j.iconOut=(function(D){let{theme:F,type:B,isLoading:U,icon:J}=D,oe=null;const de={theme:F,type:B};return J===!1||(_n(J)?oe=J(de):he.isValidElement(J)?oe=he.cloneElement(J,de):xo(J)||fa(J)?oe=J:U?oe=dg.spinner():(Y=>Y in dg)(B)&&(oe=dg[B](de))),oe})(j),_n(w.onOpen)&&(j.onOpen=w.onOpen),_n(w.onClose)&&(j.onClose=w.onClose),j.closeButton=k.closeButton,w.closeButton===!1||fg(w.closeButton)?j.closeButton=w.closeButton:w.closeButton===!0&&(j.closeButton=!fg(k.closeButton)||k.closeButton);let M=s;he.isValidElement(s)&&!xo(s.type)?M=he.cloneElement(s,{closeToast:P,toastProps:j,data:x}):_n(s)&&(M=s({closeToast:P,toastProps:j,data:x})),k.limit&&k.limit>0&&f.count>k.limit&&R?f.queue.push({toastContent:M,toastProps:j,staleId:_}):fa(b)?setTimeout(()=>{h(M,j,_)},b):h(M,j,_)}function h(s,S,b){const{toastId:_}=S;b&&l.delete(b);const w={content:s,props:S};l.set(_,w),o(y=>[...y,_].filter(E=>E!==b)),Dn.emit(4,sO(w,w.props.updateId==null?"added":"updated"))}return he.useEffect(()=>(f.containerId=e.containerId,Dn.cancelEmit(3).on(0,p).on(1,s=>i.current&&g(s)).on(5,m).emit(2,f),()=>{l.clear(),Dn.emit(3,f)}),[]),he.useEffect(()=>{f.props=e,f.isToastActive=c,f.displayedToast=r.length}),{getToastToRender:function(s){const S=new Map,b=Array.from(l.values());return e.newestOnTop&&b.reverse(),b.forEach(_=>{const{position:w}=_.props;S.has(w)||S.set(w,[]),S.get(w).push(_)}),Array.from(S,_=>s(_[0],_[1]))},containerRef:i,isToastActive:c}}function lO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function uO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function E3(e){const[n,r]=he.useState(!1),[o,i]=he.useState(!1),l=he.useRef(null),c=he.useRef({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,f=he.useRef(e),{autoClose:m,pauseOnHover:g,closeToast:d,onClick:p,closeOnClick:h}=e;function s(x){if(e.draggable){x.nativeEvent.type==="touchstart"&&x.nativeEvent.preventDefault(),c.didMove=!1,document.addEventListener("mousemove",w),document.addEventListener("mouseup",y),document.addEventListener("touchmove",w),document.addEventListener("touchend",y);const k=l.current;c.canCloseOnClick=!0,c.canDrag=!0,c.boundingRect=k.getBoundingClientRect(),k.style.transition="",c.x=lO(x.nativeEvent),c.y=uO(x.nativeEvent),e.draggableDirection==="x"?(c.start=c.x,c.removalDistance=k.offsetWidth*(e.draggablePercent/100)):(c.start=c.y,c.removalDistance=k.offsetHeight*(e.draggablePercent===80?1.5*e.draggablePercent:e.draggablePercent/100))}}function S(x){if(c.boundingRect){const{top:k,bottom:P,left:R,right:j}=c.boundingRect;x.nativeEvent.type!=="touchend"&&e.pauseOnHover&&c.x>=R&&c.x<=j&&c.y>=k&&c.y<=P?_():b()}}function b(){r(!0)}function _(){r(!1)}function w(x){const k=l.current;c.canDrag&&k&&(c.didMove=!0,n&&_(),c.x=lO(x),c.y=uO(x),c.delta=e.draggableDirection==="x"?c.x-c.start:c.y-c.start,c.start!==c.x&&(c.canCloseOnClick=!1),k.style.transform=`translate${e.draggableDirection}(${c.delta}px)`,k.style.opacity=""+(1-Math.abs(c.delta/c.removalDistance)))}function y(){document.removeEventListener("mousemove",w),document.removeEventListener("mouseup",y),document.removeEventListener("touchmove",w),document.removeEventListener("touchend",y);const x=l.current;if(c.canDrag&&c.didMove&&x){if(c.canDrag=!1,Math.abs(c.delta)>c.removalDistance)return i(!0),void e.closeToast();x.style.transition="transform 0.2s, opacity 0.2s",x.style.transform=`translate${e.draggableDirection}(0)`,x.style.opacity="1"}}he.useEffect(()=>{f.current=e}),he.useEffect(()=>(l.current&&l.current.addEventListener("d",b,{once:!0}),_n(e.onOpen)&&e.onOpen(he.isValidElement(e.children)&&e.children.props),()=>{const x=f.current;_n(x.onClose)&&x.onClose(he.isValidElement(x.children)&&x.children.props)}),[]),he.useEffect(()=>(e.pauseOnFocusLoss&&(document.hasFocus()||_(),window.addEventListener("focus",b),window.addEventListener("blur",_)),()=>{e.pauseOnFocusLoss&&(window.removeEventListener("focus",b),window.removeEventListener("blur",_))}),[e.pauseOnFocusLoss]);const E={onMouseDown:s,onTouchStart:s,onMouseUp:S,onTouchEnd:S};return m&&g&&(E.onMouseEnter=_,E.onMouseLeave=b),h&&(E.onClick=x=>{p&&p(x),c.canCloseOnClick&&d()}),{playToast:b,pauseToast:_,isRunning:n,preventExitTransition:o,toastRef:l,eventHandlers:E}}function cO(e){let{closeToast:n,theme:r,ariaLabel:o="close"}=e;return wt.default.createElement("button",{className:`Toastify__close-button Toastify__close-button--${r}`,type:"button",onClick:i=>{i.stopPropagation(),n(i)},"aria-label":o},wt.default.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},wt.default.createElement("path",{fillRule:"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"})))}function O3(e){let{delay:n,isRunning:r,closeToast:o,type:i="default",hide:l,className:c,style:f,controlledProgress:m,progress:g,rtl:d,isIn:p,theme:h}=e;const s=l||m&&g===0,S={...f,animationDuration:`${n}ms`,animationPlayState:r?"running":"paused",opacity:s?0:1};m&&(S.transform=`scaleX(${g})`);const b=Qr("Toastify__progress-bar",m?"Toastify__progress-bar--controlled":"Toastify__progress-bar--animated",`Toastify__progress-bar-theme--${h}`,`Toastify__progress-bar--${i}`,{"Toastify__progress-bar--rtl":d}),_=_n(c)?c({rtl:d,type:i,defaultClassName:b}):Qr(b,c);return wt.default.createElement("div",{role:"progressbar","aria-hidden":s?"true":"false","aria-label":"notification timer",className:_,style:S,[m&&g>=1?"onTransitionEnd":"onAnimationEnd"]:m&&g<1?null:()=>{p&&o()}})}const k3=e=>{const{isRunning:n,preventExitTransition:r,toastRef:o,eventHandlers:i}=E3(e),{closeButton:l,children:c,autoClose:f,onClick:m,type:g,hideProgressBar:d,closeToast:p,transition:h,position:s,className:S,style:b,bodyClassName:_,bodyStyle:w,progressClassName:y,progressStyle:E,updateId:x,role:k,progress:P,rtl:R,toastId:j,deleteToast:z,isIn:L,isLoading:M,iconOut:D,closeOnClick:F,theme:B}=e,U=Qr("Toastify__toast",`Toastify__toast-theme--${B}`,`Toastify__toast--${g}`,{"Toastify__toast--rtl":R},{"Toastify__toast--close-on-click":F}),J=_n(S)?S({rtl:R,position:s,type:g,defaultClassName:U}):Qr(U,S),oe=!!P||!f,de={closeToast:p,type:g,theme:B};let Y=null;return l===!1||(Y=_n(l)?l(de):he.isValidElement(l)?he.cloneElement(l,de):cO(de)),wt.default.createElement(h,{isIn:L,done:z,position:s,preventExitTransition:r,nodeRef:o},wt.default.createElement("div",{id:j,onClick:m,className:J,...i,style:b,ref:o},wt.default.createElement("div",{...L&&{role:k},className:_n(_)?_({type:g}):Qr("Toastify__toast-body",_),style:w},D!=null&&wt.default.createElement("div",{className:Qr("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!M})},D),wt.default.createElement("div",null,c)),Y,wt.default.createElement(O3,{...x&&!oe?{key:`pb-${x}`}:{},rtl:R,theme:B,delay:f,isRunning:n,isIn:L,closeToast:p,hide:d,type:g,style:E,className:y,controlledProgress:oe,progress:P||0})))},rl=function(e,n){return n===void 0&&(n=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:n}},C3=tl(rl("bounce",!0));tl(rl("slide",!0)),tl(rl("zoom")),tl(rl("flip"));const hg=he.forwardRef((e,n)=>{const{getToastToRender:r,containerRef:o,isToastActive:i}=S3(e),{className:l,style:c,rtl:f,containerId:m}=e;function g(d){const p=Qr("Toastify__toast-container",`Toastify__toast-container--${d}`,{"Toastify__toast-container--rtl":f});return _n(l)?l({position:d,rtl:f,defaultClassName:p}):Qr(p,el(l))}return he.useEffect(()=>{n&&(n.current=o.current)},[]),wt.default.createElement("div",{ref:o,className:"Toastify",id:m},r((d,p)=>{const h=p.length?{...c}:{...c,pointerEvents:"none"};return wt.default.createElement("div",{className:g(d),style:h,key:`container-${d}`},p.map((s,S)=>{let{content:b,props:_}=s;return wt.default.createElement(k3,{..._,isIn:i(_.toastId),style:{..._.style,"--nth":S+1,"--len":p.length},key:`toast-${_.key}`},b)}))}))});hg.displayName="ToastContainer",hg.defaultProps={position:"top-right",transition:C3,autoClose:5e3,closeButton:cO,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let pg,_o=new Map,da=[],A3=1;function fO(){return""+A3++}function N3(e){return e&&(xo(e.toastId)||fa(e.toastId))?e.toastId:fO()}function ha(e,n){return _o.size>0?Dn.emit(0,e,n):da.push({content:e,options:n}),n.toastId}function ol(e,n){return{...n,type:n&&n.type||e,toastId:N3(n)}}function il(e){return(n,r)=>ha(n,ol(e,r))}function ct(e,n){return ha(e,ol("default",n))}ct.loading=(e,n)=>ha(e,ol("default",{isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1,...n})),ct.promise=function(e,n,r){let o,{pending:i,error:l,success:c}=n;i&&(o=xo(i)?ct.loading(i,r):ct.loading(i.render,{...r,...i}));const f={isLoading:null,autoClose:null,closeOnClick:null,closeButton:null,draggable:null},m=(d,p,h)=>{if(p==null)return void ct.dismiss(o);const s={type:d,...f,...r,data:h},S=xo(p)?{render:p}:p;return o?ct.update(o,{...s,...S}):ct(S.render,{...s,...S}),h},g=_n(e)?e():e;return g.then(d=>m("success",c,d)).catch(d=>m("error",l,d)),g},ct.success=il("success"),ct.info=il("info"),ct.error=il("error"),ct.warning=il("warning"),ct.warn=ct.warning,ct.dark=(e,n)=>ha(e,ol("default",{theme:"dark",...n})),ct.dismiss=e=>{_o.size>0?Dn.emit(1,e):da=da.filter(n=>e!=null&&n.options.toastId!==e)},ct.clearWaitingQueue=function(e){return e===void 0&&(e={}),Dn.emit(5,e)},ct.isActive=e=>{let n=!1;return _o.forEach(r=>{r.isToastActive&&r.isToastActive(e)&&(n=!0)}),n},ct.update=function(e,n){n===void 0&&(n={}),setTimeout(()=>{const r=(function(o,i){let{containerId:l}=i;const c=_o.get(l||pg);return c&&c.getToast(o)})(e,n);if(r){const{props:o,content:i}=r,l={delay:100,...o,...n,toastId:n.toastId||e,updateId:fO()};l.toastId!==e&&(l.staleId=e);const c=l.render||i;delete l.render,ha(c,l)}},0)},ct.done=e=>{ct.update(e,{progress:1})},ct.onChange=e=>(Dn.on(4,e),()=>{Dn.off(4,e)}),ct.POSITION={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},ct.TYPE={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},Dn.on(2,e=>{pg=e.containerId||e,_o.set(pg,e),da.forEach(n=>{Dn.emit(0,n.content,n.options)}),da=[]}).on(3,e=>{_o.delete(e.containerId||e),_o.size===0&&Dn.off(0).off(1).off(5)});const dO=he.createContext({certificate:{},node:{},setNode:()=>{},type:"readNode",replica:{},nodesState:[],edgesState:[],nodeLayers:{previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}},setNodeLayers:()=>{}}),hO=e=>{const[n,r]=he.useState({}),[o,i]=he.useState({previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}}),l=e3([]),c=t3([]),f=he.useMemo(()=>({node:n,setNode:r,type:e.type,certificate:e.certificate,replica:e.replica,nodeLayers:o,setNodeLayers:i,nodesState:l,edgesState:c}),[n,r,e.type,e.certificate,e.replica,o,i,l,c]);return K.jsx(dO.Provider,{value:f,children:e.children})},Ot=()=>he.useContext(dO);var mg={exports:{}};/*! For license information please see main.js.LICENSE.txt */var pO;function T3(){return pO||(pO=1,(function(e,n){(function(r,o){e.exports=o(wt.default,$N.default,JN.default,uy.default)})(self,((r,o,i,l)=>(()=>{var c,f,m={55:(h,s)=>{var S=Symbol.for("react.fragment"),b=Symbol.for("react.strict_mode"),_=Symbol.for("react.profiler"),w=Symbol.for("react.consumer"),y=Symbol.for("react.context"),E=Symbol.for("react.forward_ref"),x=Symbol.for("react.suspense"),k=Symbol.for("react.suspense_list"),P=Symbol.for("react.memo"),R=Symbol.for("react.lazy"),j=Symbol.for("react.client.reference");s.iY=function(z){return typeof z=="string"||typeof z=="function"||z===S||z===_||z===b||z===x||z===k||typeof z=="object"&&z!==null&&(z.$$typeof===R||z.$$typeof===P||z.$$typeof===y||z.$$typeof===w||z.$$typeof===E||z.$$typeof===j||z.getModuleId!==void 0)}},184:(h,s)=>{var S;(function(){var b={}.hasOwnProperty;function _(){for(var w=[],y=0;y<arguments.length;y++){var E=arguments[y];if(E){var x=typeof E;if(x==="string"||x==="number")w.push(E);else if(Array.isArray(E)){if(E.length){var k=_.apply(null,E);k&&w.push(k)}}else if(x==="object"){if(E.toString!==Object.prototype.toString&&!E.toString.toString().includes("[native code]")){w.push(E.toString());continue}for(var P in E)b.call(E,P)&&E[P]&&w.push(P)}}}return w.join(" ")}h.exports?(_.default=_,h.exports=_):(S=(function(){return _}).apply(s,[]))===void 0||(h.exports=S)})()},953:(h,s,S)=>{S.d(s,{Z:()=>E});var b=S(81),_=S.n(b),w=S(645),y=S.n(w)()(_());y.push([h.id,".button-component{font-weight:500;letter-spacing:.2px}.button-component.btn{border-radius:2px;white-space:nowrap}.button-component.btn-sm{font-weight:600}.button-component.btn-primary,.button-component.btn-primary:active,.button-component.btn-primary:not(:disabled):not(.disabled):active{background:#003057;border:1px solid #001424;transition:none}.button-component.btn-primary:hover{background:#004c8a}.button-component.btn-primary:disabled{background:#557e9e;border:1px solid #517490;color:#ccc}.button-component.btn-secondary,.button-component.btn-secondary:active,.button-component.btn-secondary:not(:disabled):not(.disabled):active{background:#fff;border:1px solid #ccc;transition:none;color:#000}.button-component.btn-secondary:hover{background:#eee;border:1px solid #ccc;color:#000}.button-component.btn-secondary:disabled{background:#eee;border:1px solid #ccc;color:#666}.button-component a,.button-component a:hover,.button-component a:focus{color:inherit;text-decoration:inherit}.button-component i{margin-right:.4rem}.button-component i.no-text{margin-right:0}.button-component>button{font-weight:500;letter-spacing:.2px}.button-component>button.btn{border-radius:2px;white-space:nowrap}.button-component>button.btn-sm{font-weight:600}.button-component>button.btn-primary,.button-component>button.btn-primary:active,.button-component>button.btn-primary:not(:disabled):not(.disabled):active{background:#003057;border:1px solid #001424;transition:none}.button-component>button.btn-primary:hover{background:#004c8a}.button-component>button.btn-primary:disabled{background:#557e9e;border:1px solid #517490;color:#ccc}.button-component>button.btn-secondary,.button-component>button.btn-secondary:active,.button-component>button.btn-secondary:not(:disabled):not(.disabled):active{background:#fff;border:1px solid #ccc;transition:none;color:#000}.button-component>button.btn-secondary:hover{background:#eee;border:1px solid #ccc;color:#000}.button-component>button.btn-secondary:disabled{background:#eee;border:1px solid #ccc;color:#666}.button-component>button a,.button-component>button a:hover,.button-component>button a:focus{color:inherit;text-decoration:inherit}.button-component>button i{margin-right:.4rem}.button-component>button i.no-text{margin-right:0}",""]);const E=y},525:(h,s,S)=>{S.d(s,{Z:()=>E});var b=S(81),_=S.n(b),w=S(645),y=S.n(w)()(_());y.push([h.id,".keyval__wrapper{display:flex;font-size:13px;margin-bottom:.5rem}.keyval__label{color:#71899c}.keyval__list{list-style:none;padding:0;margin:0;flex-grow:1}.keyval__item{display:block}",""]);const E=y},970:(h,s,S)=>{S.d(s,{Z:()=>E});var b=S(81),_=S.n(b),w=S(645),y=S.n(w)()(_());y.push([h.id,".hise-select__wrapper .hise-select__control{border:1px solid #aaa;border-radius:0}.hise-select__wrapper.invalid .hise-select__control{border:1px solid #dc3545}",""]);const E=y},645:h=>{h.exports=function(s){var S=[];return S.toString=function(){return this.map((function(b){var _="",w=b[5]!==void 0;return b[4]&&(_+="@supports (".concat(b[4],") {")),b[2]&&(_+="@media ".concat(b[2]," {")),w&&(_+="@layer".concat(b[5].length>0?" ".concat(b[5]):""," {")),_+=s(b),w&&(_+="}"),b[2]&&(_+="}"),b[4]&&(_+="}"),_})).join("")},S.i=function(b,_,w,y,E){typeof b=="string"&&(b=[[null,b,void 0]]);var x={};if(w)for(var k=0;k<this.length;k++){var P=this[k][0];P!=null&&(x[P]=!0)}for(var R=0;R<b.length;R++){var j=[].concat(b[R]);w&&x[j[0]]||(E!==void 0&&(j[5]===void 0||(j[1]="@layer".concat(j[5].length>0?" ".concat(j[5]):""," {").concat(j[1],"}")),j[5]=E),_&&(j[2]&&(j[1]="@media ".concat(j[2]," {").concat(j[1],"}")),j[2]=_),y&&(j[4]?(j[1]="@supports (".concat(j[4],") {").concat(j[1],"}"),j[4]=y):j[4]="".concat(y)),S.push(j))}},S}},81:h=>{h.exports=function(s){return s[1]}},679:(h,s,S)=>{var b=S(864),_={childContextTypes:!0,contextType:!0,contextTypes:!0,defaultProps:!0,displayName:!0,getDefaultProps:!0,getDerivedStateFromError:!0,getDerivedStateFromProps:!0,mixins:!0,propTypes:!0,type:!0},w={name:!0,length:!0,prototype:!0,caller:!0,callee:!0,arguments:!0,arity:!0},y={$$typeof:!0,compare:!0,defaultProps:!0,displayName:!0,propTypes:!0,type:!0},E={};function x(M){return b.isMemo(M)?y:E[M.$$typeof]||_}E[b.ForwardRef]={$$typeof:!0,render:!0,defaultProps:!0,displayName:!0,propTypes:!0},E[b.Memo]=y;var k=Object.defineProperty,P=Object.getOwnPropertyNames,R=Object.getOwnPropertySymbols,j=Object.getOwnPropertyDescriptor,z=Object.getPrototypeOf,L=Object.prototype;h.exports=function M(D,F,B){if(typeof F!="string"){if(L){var U=z(F);U&&U!==L&&M(D,U,B)}var J=P(F);R&&(J=J.concat(R(F)));for(var oe=x(D),de=x(F),Y=0;Y<J.length;++Y){var ee=J[Y];if(!(w[ee]||B&&B[ee]||de&&de[ee]||oe&&oe[ee])){var W=j(F,ee);try{k(D,ee,W)}catch{}}}}return D}},703:(h,s,S)=>{var b=S(414);function _(){}function w(){}w.resetWarningCache=_,h.exports=function(){function y(k,P,R,j,z,L){if(L!==b){var M=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw M.name="Invariant Violation",M}}function E(){return y}y.isRequired=y;var x={array:y,bigint:y,bool:y,func:y,number:y,object:y,string:y,symbol:y,any:y,arrayOf:E,element:y,elementType:y,instanceOf:E,node:y,objectOf:E,oneOf:E,oneOfType:E,shape:E,exact:E,checkPropTypes:w,resetWarningCache:_};return x.PropTypes=x,x}},697:(h,s,S)=>{h.exports=S(703)()},414:h=>{h.exports="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"},921:(h,s)=>{var S=typeof Symbol=="function"&&Symbol.for,b=S?Symbol.for("react.element"):60103,_=S?Symbol.for("react.portal"):60106,w=S?Symbol.for("react.fragment"):60107,y=S?Symbol.for("react.strict_mode"):60108,E=S?Symbol.for("react.profiler"):60114,x=S?Symbol.for("react.provider"):60109,k=S?Symbol.for("react.context"):60110,P=S?Symbol.for("react.async_mode"):60111,R=S?Symbol.for("react.concurrent_mode"):60111,j=S?Symbol.for("react.forward_ref"):60112,z=S?Symbol.for("react.suspense"):60113,L=S?Symbol.for("react.suspense_list"):60120,M=S?Symbol.for("react.memo"):60115,D=S?Symbol.for("react.lazy"):60116,F=S?Symbol.for("react.block"):60121,B=S?Symbol.for("react.fundamental"):60117,U=S?Symbol.for("react.responder"):60118,J=S?Symbol.for("react.scope"):60119;function oe(Y){if(typeof Y=="object"&&Y!==null){var ee=Y.$$typeof;switch(ee){case b:switch(Y=Y.type){case P:case R:case w:case E:case y:case z:return Y;default:switch(Y=Y&&Y.$$typeof){case k:case j:case D:case M:case x:return Y;default:return ee}}case _:return ee}}}function de(Y){return oe(Y)===R}s.AsyncMode=P,s.ConcurrentMode=R,s.ContextConsumer=k,s.ContextProvider=x,s.Element=b,s.ForwardRef=j,s.Fragment=w,s.Lazy=D,s.Memo=M,s.Portal=_,s.Profiler=E,s.StrictMode=y,s.Suspense=z,s.isAsyncMode=function(Y){return de(Y)||oe(Y)===P},s.isConcurrentMode=de,s.isContextConsumer=function(Y){return oe(Y)===k},s.isContextProvider=function(Y){return oe(Y)===x},s.isElement=function(Y){return typeof Y=="object"&&Y!==null&&Y.$$typeof===b},s.isForwardRef=function(Y){return oe(Y)===j},s.isFragment=function(Y){return oe(Y)===w},s.isLazy=function(Y){return oe(Y)===D},s.isMemo=function(Y){return oe(Y)===M},s.isPortal=function(Y){return oe(Y)===_},s.isProfiler=function(Y){return oe(Y)===E},s.isStrictMode=function(Y){return oe(Y)===y},s.isSuspense=function(Y){return oe(Y)===z},s.isValidElementType=function(Y){return typeof Y=="string"||typeof Y=="function"||Y===w||Y===R||Y===E||Y===y||Y===z||Y===L||typeof Y=="object"&&Y!==null&&(Y.$$typeof===D||Y.$$typeof===M||Y.$$typeof===x||Y.$$typeof===k||Y.$$typeof===j||Y.$$typeof===B||Y.$$typeof===U||Y.$$typeof===J||Y.$$typeof===F)},s.typeOf=oe},864:(h,s,S)=>{h.exports=S(921)},379:h=>{var s=[];function S(w){for(var y=-1,E=0;E<s.length;E++)if(s[E].identifier===w){y=E;break}return y}function b(w,y){for(var E={},x=[],k=0;k<w.length;k++){var P=w[k],R=y.base?P[0]+y.base:P[0],j=E[R]||0,z="".concat(R," ").concat(j);E[R]=j+1;var L=S(z),M={css:P[1],media:P[2],sourceMap:P[3],supports:P[4],layer:P[5]};if(L!==-1)s[L].references++,s[L].updater(M);else{var D=_(M,y);y.byIndex=k,s.splice(k,0,{identifier:z,updater:D,references:1})}x.push(z)}return x}function _(w,y){var E=y.domAPI(y);return E.update(w),function(x){if(x){if(x.css===w.css&&x.media===w.media&&x.sourceMap===w.sourceMap&&x.supports===w.supports&&x.layer===w.layer)return;E.update(w=x)}else E.remove()}}h.exports=function(w,y){var E=b(w=w||[],y=y||{});return function(x){x=x||[];for(var k=0;k<E.length;k++){var P=S(E[k]);s[P].references--}for(var R=b(x,y),j=0;j<E.length;j++){var z=S(E[j]);s[z].references===0&&(s[z].updater(),s.splice(z,1))}E=R}}},569:h=>{var s={};h.exports=function(S,b){var _=(function(w){if(s[w]===void 0){var y=document.querySelector(w);if(window.HTMLIFrameElement&&y instanceof window.HTMLIFrameElement)try{y=y.contentDocument.head}catch{y=null}s[w]=y}return s[w]})(S);if(!_)throw new Error("Couldn't find a style target. This probably means that the value for the 'insert' parameter is invalid.");_.appendChild(b)}},216:h=>{h.exports=function(s){var S=document.createElement("style");return s.setAttributes(S,s.attributes),s.insert(S,s.options),S}},565:(h,s,S)=>{h.exports=function(b){var _=S.nc;_&&b.setAttribute("nonce",_)}},795:h=>{h.exports=function(s){if(typeof document>"u")return{update:function(){},remove:function(){}};var S=s.insertStyleElement(s);return{update:function(b){(function(_,w,y){var E="";y.supports&&(E+="@supports (".concat(y.supports,") {")),y.media&&(E+="@media ".concat(y.media," {"));var x=y.layer!==void 0;x&&(E+="@layer".concat(y.layer.length>0?" ".concat(y.layer):""," {")),E+=y.css,x&&(E+="}"),y.media&&(E+="}"),y.supports&&(E+="}");var k=y.sourceMap;k&&typeof btoa<"u"&&(E+=`
|
|
19
|
+
/*# sourceMappingURL=data:application/json;base64,`.concat(btoa(unescape(encodeURIComponent(JSON.stringify(k))))," */")),w.styleTagTransform(E,_,w.options)})(S,s,b)},remove:function(){(function(b){if(b.parentNode===null)return!1;b.parentNode.removeChild(b)})(S)}}}},589:h=>{h.exports=function(s,S){if(S.styleSheet)S.styleSheet.cssText=s;else{for(;S.firstChild;)S.removeChild(S.firstChild);S.appendChild(document.createTextNode(s))}}},583:h=>{h.exports=r},732:h=>{h.exports=l},774:h=>{h.exports=o},423:h=>{h.exports=i}},g={};function d(h){var s=g[h];if(s!==void 0)return s.exports;var S=g[h]={id:h,exports:{}};return m[h](S,S.exports,d),S.exports}d.n=h=>{var s=h&&h.__esModule?()=>h.default:()=>h;return d.d(s,{a:s}),s},f=Object.getPrototypeOf?h=>Object.getPrototypeOf(h):h=>h.__proto__,d.t=function(h,s){if(1&s&&(h=this(h)),8&s||typeof h=="object"&&h&&(4&s&&h.__esModule||16&s&&typeof h.then=="function"))return h;var S=Object.create(null);d.r(S);var b={};c=c||[null,f({}),f([]),f(f)];for(var _=2&s&&h;typeof _=="object"&&!~c.indexOf(_);_=f(_))Object.getOwnPropertyNames(_).forEach((w=>b[w]=()=>h[w]));return b.default=()=>h,d.d(S,b),S},d.d=(h,s)=>{for(var S in s)d.o(s,S)&&!d.o(h,S)&&Object.defineProperty(h,S,{enumerable:!0,get:s[S]})},d.o=(h,s)=>Object.prototype.hasOwnProperty.call(h,s),d.r=h=>{typeof Symbol<"u"&&Symbol.toStringTag&&Object.defineProperty(h,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(h,"__esModule",{value:!0})},d.nc=void 0;var p={};return(()=>{d.r(p),d.d(p,{Button:()=>ti,ConfirmationModal:()=>R6,HISETabs:()=>mF,KeyValPair:()=>gF,MessageStripe:()=>_i,ResourceEditor:()=>FN});var h,s=d(583),S=d.t(s,2),b=d.n(s),_=d(774),w=d(697),y=d.n(w),E=d(184),x=d.n(E);function k(t){return k=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},k(t)}function P(t){document.body.style.paddingRight=t>0?"".concat(t,"px"):null}function R(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",a=arguments.length>1&&arguments[1]!==void 0?arguments[1]:h;return a?t.split(" ").map((function(u){return a[u]||u})).join(" "):t}function j(t,a){var u={};return Object.keys(t).forEach((function(v){a.indexOf(v)===-1&&(u[v]=t[v])})),u}var z={};function L(t){z[t]||(typeof console<"u"&&console.error(t),z[t]=!0)}var M=(typeof window>"u"?"undefined":k(window))==="object"&&window.Element||function(){},D=y().oneOfType([y().string,y().func,function(t,a,u){if(!(t[a]instanceof M))return new Error("Invalid prop `"+a+"` supplied to `"+u+"`. Expected prop to be an instance of Element. Validation failed.")},y().shape({current:y().any})]),F=y().oneOfType([y().func,y().string,y().shape({$$typeof:y().symbol,render:y().func}),y().arrayOf(y().oneOfType([y().func,y().string,y().shape({$$typeof:y().symbol,render:y().func})]))]),B=["in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","onEnter","onEntering","onEntered","onExit","onExiting","onExited"],U={esc:27,space:32,enter:13,tab:9,up:38,down:40,home:36,end:35,n:78,p:80},J=!(typeof window>"u"||!window.document||!window.document.createElement);function oe(t){if((function(u){return!(!u||k(u)!=="object")&&"current"in u})(t))return t.current;if((function(u){if(!(function(O){var A=k(O);return O!=null&&(A==="object"||A==="function")})(u))return!1;var v=(function(O){return O==null?O===void 0?"[object Undefined]":"[object Null]":Object.prototype.toString.call(O)})(u);return v==="[object Function]"||v==="[object AsyncFunction]"||v==="[object GeneratorFunction]"||v==="[object Proxy]"})(t))return t();if(typeof t=="string"&&J){var a=document.querySelectorAll(t);if(a.length||(a=document.querySelectorAll("#".concat(t))),!a.length)throw new Error("The target '".concat(t,"' could not be identified in the dom, tip: check spelling"));return a}return t}function de(t){return t!==null&&(Array.isArray(t)||J&&typeof t.length=="number")}var Y=["a[href]","area[href]","input:not([disabled]):not([type=hidden])","select:not([disabled])","textarea:not([disabled])","button:not([disabled])","object","embed","[tabindex]:not(.modal):not(.offcanvas)","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])'],ee=["className","cssModule","variant","innerRef"];function W(){return W=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},W.apply(this,arguments)}function ne(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function ae(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}var te={active:y().bool,"aria-label":y().string,onClick:y().func,variant:y().oneOf(["white"]),className:y().string,cssModule:y().object,innerRef:y().oneOfType([y().object,y().string,y().func])};function re(t){var a=t.className,u=(t.cssModule,t.variant),v=t.innerRef,O=(function(I,N){if(I==null)return{};var T,C,X=(function($,q){if($==null)return{};var H,G,Q={},ie=Object.keys($);for(G=0;G<ie.length;G++)H=ie[G],q.indexOf(H)>=0||(Q[H]=$[H]);return Q})(I,N);if(Object.getOwnPropertySymbols){var V=Object.getOwnPropertySymbols(I);for(C=0;C<V.length;C++)T=V[C],N.indexOf(T)>=0||Object.prototype.propertyIsEnumerable.call(I,T)&&(X[T]=I[T])}return X})(t,ee),A=R(x()(a,"btn-close",u&&"btn-close-".concat(u)));return b().createElement("button",W({ref:v,type:"button",className:A},(function(I){for(var N=1;N<arguments.length;N++){var T=arguments[N]!=null?arguments[N]:{};N%2?ne(Object(T),!0).forEach((function(C){ae(I,C,T[C])})):Object.getOwnPropertyDescriptors?Object.defineProperties(I,Object.getOwnPropertyDescriptors(T)):ne(Object(T)).forEach((function(C){Object.defineProperty(I,C,Object.getOwnPropertyDescriptor(T,C))}))}return I})({"aria-label":"close"},O)))}re.propTypes=te;const Z=re;var se=["active","aria-label","block","className","close","cssModule","color","outline","size","tag","innerRef"];function pe(){return pe=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},pe.apply(this,arguments)}var ge={active:y().bool,"aria-label":y().string,block:y().bool,children:y().node,className:y().string,cssModule:y().object,close:y().bool,color:y().string,disabled:y().bool,innerRef:y().oneOfType([y().object,y().func,y().string]),onClick:y().func,outline:y().bool,size:y().string,tag:F};function be(t){var a=(0,s.useCallback)((function(ue){if(!t.disabled)return t.onClick?t.onClick(ue):void 0;ue.preventDefault()}),[t.onClick,t.disabled]),u=t.active,v=t["aria-label"],O=t.block,A=t.className,I=t.close,N=t.cssModule,T=t.color,C=T===void 0?"secondary":T,X=t.outline,V=t.size,$=t.tag,q=$===void 0?"button":$,H=t.innerRef,G=(function(ue,fe){if(ue==null)return{};var me,ve,ye=(function(Oe,Me){if(Oe==null)return{};var _e,je,Ne={},Te=Object.keys(Oe);for(je=0;je<Te.length;je++)_e=Te[je],Me.indexOf(_e)>=0||(Ne[_e]=Oe[_e]);return Ne})(ue,fe);if(Object.getOwnPropertySymbols){var ce=Object.getOwnPropertySymbols(ue);for(ve=0;ve<ce.length;ve++)me=ce[ve],fe.indexOf(me)>=0||Object.prototype.propertyIsEnumerable.call(ue,me)&&(ye[me]=ue[me])}return ye})(t,se);if(I)return b().createElement(Z,G);var Q="btn".concat(X?"-outline":"","-").concat(C),ie=R(x()(A,"btn",Q,!!V&&"btn-".concat(V),!!O&&"d-block w-100",{active:u,disabled:t.disabled}),N);return G.href&&q==="button"&&(q="a"),b().createElement(q,pe({type:q==="button"&&G.onClick?"button":void 0},G,{className:ie,ref:H,onClick:a,"aria-label":v}))}be.propTypes=ge;const Ae=be;var Ue=s.createContext(),Ve=s.createContext();function Fe(t){var a=t.children,u=s.useState(null),v=u[0],O=u[1],A=s.useRef(!1);s.useEffect((function(){return function(){A.current=!0}}),[]);var I=s.useCallback((function(N){A.current||O(N)}),[]);return s.createElement(Ue.Provider,{value:v},s.createElement(Ve.Provider,{value:I},a))}var Pe=b().createContext({}),ut=b().createContext({});function Ce(t){return Ce=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Ce(t)}var we=["className","cssModule","direction","isOpen","group","size","nav","setActiveFromChild","active","tag","menuRole"];function xe(){return xe=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},xe.apply(this,arguments)}function Re(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function De(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,v.key,v)}}function Ee(t,a){return Ee=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Ee(t,a)}function We(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function Qe(t){return Qe=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},Qe(t)}var ot={a11y:y().bool,disabled:y().bool,direction:y().oneOf(["up","down","start","end","left","right"]),group:y().bool,isOpen:y().bool,nav:y().bool,active:y().bool,size:y().string,tag:F,toggle:y().func,children:y().node,className:y().string,cssModule:y().object,dropup:y().bool,inNavbar:y().bool,setActiveFromChild:y().bool,menuRole:y().oneOf(["listbox","menu"])},Mt=[U.space,U.enter,U.up,U.down,U.end,U.home],jt=(function(t){(function(N,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(T&&T.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),T&&Ee(N,T)})(I,t);var a,u,v,O,A=(v=I,O=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var N,T=Qe(v);if(O){var C=Qe(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Ce(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return We(X)})(this,N)});function I(N){var T;return(function(C,X){if(!(C instanceof X))throw new TypeError("Cannot call a class as a function")})(this,I),(T=A.call(this,N)).addEvents=T.addEvents.bind(We(T)),T.handleDocumentClick=T.handleDocumentClick.bind(We(T)),T.handleKeyDown=T.handleKeyDown.bind(We(T)),T.removeEvents=T.removeEvents.bind(We(T)),T.toggle=T.toggle.bind(We(T)),T.handleMenuRef=T.handleMenuRef.bind(We(T)),T.handleToggleRef=T.handleToggleRef.bind(We(T)),T.containerRef=b().createRef(),T.menuRef=b().createRef(),T.toggleRef=b().createRef(),T}return a=I,u=[{key:"componentDidMount",value:function(){this.handleProps()}},{key:"componentDidUpdate",value:function(N){this.props.isOpen!==N.isOpen&&this.handleProps()}},{key:"componentWillUnmount",value:function(){this.removeEvents()}},{key:"handleMenuRef",value:function(N){this.menuRef.current=N}},{key:"handleToggleRef",value:function(N){this.toggleRef.current=N}},{key:"handleDocumentClick",value:function(N){if(!N||N.which!==3&&(N.type!=="keyup"||N.which===U.tab)){var T=this.getContainer(),C=this.getMenu(),X=this.getToggle().contains(N.target),V=C&&C.contains(N.target)&&C!==N.target,$=!1;T&&($=T.classList.contains("input-group")&&T.classList.contains("dropdown")&&N.target.tagName==="INPUT"),(!(X&&!$||V)||N.type==="keyup"&&N.which!==U.tab)&&this.toggle(N)}}},{key:"handleKeyDown",value:function(N){var T=this,C=N.target.getAttribute("role")==="menuitem"||N.target.getAttribute("role")==="option",X=this.getMenuCtrl()===N.target,V=U.tab===N.which;if(!(/input|textarea/i.test(N.target.tagName)||V&&!this.props.a11y||V&&!C&&!X||((Mt.indexOf(N.which)!==-1||N.which>=48&&N.which<=90)&&N.preventDefault(),this.props.disabled))){if(X)if([U.space,U.enter,U.up,U.down].indexOf(N.which)>-1)this.props.isOpen||this.toggle(N),setTimeout((function(){var fe;return(fe=T.getMenuItems()[0])===null||fe===void 0?void 0:fe.focus()}));else if(this.props.isOpen&&V){var $;N.preventDefault(),($=this.getMenuItems()[0])===null||$===void 0||$.focus()}else this.props.isOpen&&N.which===U.esc&&this.toggle(N);if(this.props.isOpen&&C){if([U.tab,U.esc].indexOf(N.which)>-1)this.toggle(N),this.getMenuCtrl().focus();else if([U.space,U.enter].indexOf(N.which)>-1)N.target.click(),this.getMenuCtrl().focus();else if([U.down,U.up].indexOf(N.which)>-1||[U.n,U.p].indexOf(N.which)>-1&&N.ctrlKey){var q=this.getMenuItems(),H=q.indexOf(N.target);U.up===N.which||U.p===N.which&&N.ctrlKey?H=H!==0?H-1:q.length-1:(U.down===N.which||U.n===N.which&&N.ctrlKey)&&(H=H===q.length-1?0:H+1),q[H].focus()}else if(U.end===N.which){var G=this.getMenuItems();G[G.length-1].focus()}else if(U.home===N.which)this.getMenuItems()[0].focus();else if(N.which>=48&&N.which<=90){for(var Q=this.getMenuItems(),ie=String.fromCharCode(N.which).toLowerCase(),ue=0;ue<Q.length;ue+=1)if((Q[ue].textContent&&Q[ue].textContent[0].toLowerCase())===ie){Q[ue].focus();break}}}}}},{key:"handleProps",value:function(){this.props.isOpen?this.addEvents():this.removeEvents()}},{key:"getContextValue",value:function(){return{toggle:this.toggle,isOpen:this.props.isOpen,direction:this.props.direction==="down"&&this.props.dropup?"up":this.props.direction,inNavbar:this.props.inNavbar,disabled:this.props.disabled,onMenuRef:this.handleMenuRef,onToggleRef:this.handleToggleRef,menuRole:this.props.menuRole}}},{key:"getContainer",value:function(){return this.containerRef.current}},{key:"getMenu",value:function(){return this.menuRef.current}},{key:"getToggle",value:function(){return this.toggleRef.current}},{key:"getMenuCtrl",value:function(){return this._$menuCtrl||(this._$menuCtrl=this.getToggle()),this._$menuCtrl}},{key:"getItemType",value:function(){return this.props.menuRole==="listbox"?"option":"menuitem"}},{key:"getMenuItems",value:function(){var N=this.getMenu()||this.getContainer();return[].slice.call(N.querySelectorAll('[role="'.concat(this.getItemType(),'"]')))}},{key:"addEvents",value:function(){var N=this;["click","touchstart","keyup"].forEach((function(T){return document.addEventListener(T,N.handleDocumentClick,!0)}))}},{key:"removeEvents",value:function(){var N=this;["click","touchstart","keyup"].forEach((function(T){return document.removeEventListener(T,N.handleDocumentClick,!0)}))}},{key:"toggle",value:function(N){return this.props.disabled?N&&N.preventDefault():this.props.toggle(N)}},{key:"render",value:function(){var N,T=this,C=j(this.props,["toggle","disabled","inNavbar","a11y"]),X=C.className,V=C.cssModule,$=C.direction,q=C.isOpen,H=C.group,G=C.size,Q=C.nav,ie=C.setActiveFromChild,ue=C.active,fe=C.tag,me=(C.menuRole,(function(Oe,Me){if(Oe==null)return{};var _e,je,Ne=(function(ze,Le){if(ze==null)return{};var ke,Ke,$e={},dt=Object.keys(ze);for(Ke=0;Ke<dt.length;Ke++)ke=dt[Ke],Le.indexOf(ke)>=0||($e[ke]=ze[ke]);return $e})(Oe,Me);if(Object.getOwnPropertySymbols){var Te=Object.getOwnPropertySymbols(Oe);for(je=0;je<Te.length;je++)_e=Te[je],Me.indexOf(_e)>=0||Object.prototype.propertyIsEnumerable.call(Oe,_e)&&(Ne[_e]=Oe[_e])}return Ne})(C,we)),ve=fe||(Q?"li":"div"),ye=!1;ie&&b().Children.map(this.props.children[1].props.children,(function(Oe){Oe&&Oe.props.active&&(ye=!0)}));var ce=R(x()(X,!(!Q||!ue)&&"active",!(!ie||!ye)&&"active",(Re(N={"btn-group":H},"btn-group-".concat(G),!!G),Re(N,"dropdown",!H),Re(N,"dropup",$==="up"),Re(N,"dropstart",$==="start"||$==="left"),Re(N,"dropend",$==="end"||$==="right"),Re(N,"show",q),Re(N,"nav-item",Q),N)),V);return this.context.insideInputGroup?b().createElement(Pe.Provider,{value:this.getContextValue()},b().createElement(Fe,null,b().Children.map(this.props.children,(function(Oe){return b().cloneElement(Oe,{onKeyDown:T.handleKeyDown})})))):b().createElement(Pe.Provider,{value:this.getContextValue()},b().createElement(Fe,null,b().createElement(ve,xe({},me,Re({},typeof ve=="string"?"ref":"innerRef",this.containerRef),{onKeyDown:this.handleKeyDown,className:ce}))))}}],u&&De(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);jt.propTypes=ot,jt.defaultProps={a11y:!0,isOpen:!1,direction:"down",nav:!1,active:!1,inNavbar:!1,setActiveFromChild:!1},jt.contextType=ut;const pt=jt;function vn(){return vn=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},vn.apply(this,arguments)}var ft={children:y().node};function Rt(t){return b().createElement(pt,vn({group:!0},t))}Rt.propTypes=ft;const Cn=Rt;function Yt(t){return Yt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Yt(t)}function cn(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function So(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function Ir(){return Ir=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Ir.apply(this,arguments)}function ma(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,v.key,v)}}function Eo(t,a){return Eo=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Eo(t,a)}function $r(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function eo(t){return eo=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},eo(t)}var cl=["defaultOpen"];(function(t){(function(N,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(T&&T.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),T&&Eo(N,T)})(I,t);var a,u,v,O,A=(v=I,O=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var N,T=eo(v);if(O){var C=eo(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Yt(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return $r(X)})(this,N)});function I(N){var T;return(function(C,X){if(!(C instanceof X))throw new TypeError("Cannot call a class as a function")})(this,I),(T=A.call(this,N)).state={isOpen:N.defaultOpen||!1},T.toggle=T.toggle.bind($r(T)),T}return a=I,(u=[{key:"toggle",value:function(){this.setState((function(N){return{isOpen:!N.isOpen}}))}},{key:"render",value:function(){return b().createElement(Cn,Ir({isOpen:this.state.isOpen,toggle:this.toggle},j(this.props,cl)))}}])&&ma(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(s.Component).propTypes=(function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?cn(Object(u),!0).forEach((function(v){So(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):cn(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t})({defaultOpen:y().bool},Cn.propTypes);var Mr=d(379),ga=d.n(Mr),Og=d(795),va=d.n(Og),kg=d(569),ya=d.n(kg),Cg=d(565),ba=d.n(Cg),Ag=d(216),wa=d.n(Ag),Ng=d(589),xa=d.n(Ng),ei=d(953),to={};to.styleTagTransform=xa(),to.setAttributes=ba(),to.insert=ya().bind(null,"head"),to.domAPI=va(),to.insertStyleElement=wa(),ga()(ei.Z,to),ei.Z&&ei.Z.locals&&ei.Z.locals;var fl=["href","to","icon","pending","children","target","download","noText"],dl=function(t){var a=t.href,u=t.to,v=t.icon,O=t.pending,A=t.children,I=t.target,N=t.download,T=t.noText,C=(function(V,$){if(V==null)return{};var q,H,G=(function(ie,ue){if(ie==null)return{};var fe,me,ve={},ye=Object.keys(ie);for(me=0;me<ye.length;me++)fe=ye[me],ue.indexOf(fe)>=0||(ve[fe]=ie[fe]);return ve})(V,$);if(Object.getOwnPropertySymbols){var Q=Object.getOwnPropertySymbols(V);for(H=0;H<Q.length;H++)q=Q[H],$.indexOf(q)>=0||Object.prototype.propertyIsEnumerable.call(V,q)&&(G[q]=V[q])}return G})(t,fl);C.className="".concat(t.className," button-component");var X=b().createElement(b().Fragment,null,O&&b().createElement("i",{className:"fas fa-spinner fa-spin"}),v&&!O&&b().createElement("i",{className:"fas ".concat(v," ").concat(T?"no-text":"")}),A);return C.disabled=C.disabled||O,u&&!C.disabled?b().createElement(_.Link,{to:u,target:I},b().createElement(Ae,C,X)):a?b().createElement("a",{href:a,target:I,download:N,rel:"noopener noreferrer"},b().createElement(Ae,C,X)):b().createElement(Ae,C,X)};dl.defaultProps={active:!1,"aria-label":"",block:!1,color:"secondary",disabled:!1,outline:!1,icon:"",pending:!1,className:"",to:"",href:"",target:"_self",download:!1,children:null};const ti=dl;var hl=d(732),Oo=d.n(hl);function _a(t){return _a=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},_a(t)}function Tg(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,v.key,v)}}function Sa(t,a){return Sa=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Sa(t,a)}function ni(t){return ni=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},ni(t)}var pl={children:y().node.isRequired,node:y().any},ml=(function(t){(function(N,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(T&&T.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),T&&Sa(N,T)})(I,t);var a,u,v,O,A=(v=I,O=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var N,T=ni(v);if(O){var C=ni(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(_a(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return(function($){if($===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return $})(X)})(this,N)});function I(){return(function(N,T){if(!(N instanceof T))throw new TypeError("Cannot call a class as a function")})(this,I),A.apply(this,arguments)}return a=I,(u=[{key:"componentWillUnmount",value:function(){this.defaultNode&&document.body.removeChild(this.defaultNode),this.defaultNode=null}},{key:"render",value:function(){return J?(this.props.node||this.defaultNode||(this.defaultNode=document.createElement("div"),document.body.appendChild(this.defaultNode)),Oo().createPortal(this.props.children,this.props.node||this.defaultNode)):null}}])&&Tg(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);ml.propTypes=pl;const Rg=ml;function Ea(t,a){if(t==null)return{};var u,v,O={},A=Object.keys(t);for(v=0;v<A.length;v++)u=A[v],a.indexOf(u)>=0||(O[u]=t[u]);return O}function ri(t,a){return ri=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},ri(t,a)}function Oa(t,a){t.prototype=Object.create(a.prototype),t.prototype.constructor=t,ri(t,a)}const oi=b().createContext(null);var no="unmounted",jr="exited",Lr="entering",pr="entered",Pg="exiting",Dr=(function(t){function a(v,O){var A;A=t.call(this,v,O)||this;var I,N=O&&!O.isMounting?v.enter:v.appear;return A.appearStatus=null,v.in?N?(I=jr,A.appearStatus=Lr):I=pr:I=v.unmountOnExit||v.mountOnEnter?no:jr,A.state={status:I},A.nextCallback=null,A}Oa(a,t),a.getDerivedStateFromProps=function(v,O){return v.in&&O.status===no?{status:jr}:null};var u=a.prototype;return u.componentDidMount=function(){this.updateStatus(!0,this.appearStatus)},u.componentDidUpdate=function(v){var O=null;if(v!==this.props){var A=this.state.status;this.props.in?A!==Lr&&A!==pr&&(O=Lr):A!==Lr&&A!==pr||(O=Pg)}this.updateStatus(!1,O)},u.componentWillUnmount=function(){this.cancelNextCallback()},u.getTimeouts=function(){var v,O,A,I=this.props.timeout;return v=O=A=I,I!=null&&typeof I!="number"&&(v=I.exit,O=I.enter,A=I.appear!==void 0?I.appear:O),{exit:v,enter:O,appear:A}},u.updateStatus=function(v,O){if(v===void 0&&(v=!1),O!==null)if(this.cancelNextCallback(),O===Lr){if(this.props.unmountOnExit||this.props.mountOnEnter){var A=this.props.nodeRef?this.props.nodeRef.current:Oo().findDOMNode(this);A&&(function(I){I.scrollTop})(A)}this.performEnter(v)}else this.performExit();else this.props.unmountOnExit&&this.state.status===jr&&this.setState({status:no})},u.performEnter=function(v){var O=this,A=this.props.enter,I=this.context?this.context.isMounting:v,N=this.props.nodeRef?[I]:[Oo().findDOMNode(this),I],T=N[0],C=N[1],X=this.getTimeouts(),V=I?X.appear:X.enter;v||A?(this.props.onEnter(T,C),this.safeSetState({status:Lr},(function(){O.props.onEntering(T,C),O.onTransitionEnd(V,(function(){O.safeSetState({status:pr},(function(){O.props.onEntered(T,C)}))}))}))):this.safeSetState({status:pr},(function(){O.props.onEntered(T)}))},u.performExit=function(){var v=this,O=this.props.exit,A=this.getTimeouts(),I=this.props.nodeRef?void 0:Oo().findDOMNode(this);O?(this.props.onExit(I),this.safeSetState({status:Pg},(function(){v.props.onExiting(I),v.onTransitionEnd(A.exit,(function(){v.safeSetState({status:jr},(function(){v.props.onExited(I)}))}))}))):this.safeSetState({status:jr},(function(){v.props.onExited(I)}))},u.cancelNextCallback=function(){this.nextCallback!==null&&(this.nextCallback.cancel(),this.nextCallback=null)},u.safeSetState=function(v,O){O=this.setNextCallback(O),this.setState(v,O)},u.setNextCallback=function(v){var O=this,A=!0;return this.nextCallback=function(I){A&&(A=!1,O.nextCallback=null,v(I))},this.nextCallback.cancel=function(){A=!1},this.nextCallback},u.onTransitionEnd=function(v,O){this.setNextCallback(O);var A=this.props.nodeRef?this.props.nodeRef.current:Oo().findDOMNode(this),I=v==null&&!this.props.addEndListener;if(A&&!I){if(this.props.addEndListener){var N=this.props.nodeRef?[this.nextCallback]:[A,this.nextCallback],T=N[0],C=N[1];this.props.addEndListener(T,C)}v!=null&&setTimeout(this.nextCallback,v)}else setTimeout(this.nextCallback,0)},u.render=function(){var v=this.state.status;if(v===no)return null;var O=this.props,A=O.children,I=(O.in,O.mountOnEnter,O.unmountOnExit,O.appear,O.enter,O.exit,O.timeout,O.addEndListener,O.onEnter,O.onEntering,O.onEntered,O.onExit,O.onExiting,O.onExited,O.nodeRef,Ea(O,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return b().createElement(oi.Provider,{value:null},typeof A=="function"?A(v,I):b().cloneElement(b().Children.only(A),I))},a})(b().Component);function ii(){}Dr.contextType=oi,Dr.propTypes={},Dr.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:ii,onEntering:ii,onEntered:ii,onExit:ii,onExiting:ii,onExited:ii},Dr.UNMOUNTED=no,Dr.EXITED=jr,Dr.ENTERING=Lr,Dr.ENTERED=pr,Dr.EXITING=Pg;const Ig=Dr;var G4=["tag","baseClass","baseClassActive","className","cssModule","children","innerRef"];function gl(){return gl=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},gl.apply(this,arguments)}function KO(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function ka(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?KO(Object(u),!0).forEach((function(v){K4(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):KO(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function K4(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}var Y4=ka(ka({},Ig.propTypes),{},{children:y().oneOfType([y().arrayOf(y().node),y().node]),tag:F,baseClass:y().string,baseClassActive:y().string,className:y().string,cssModule:y().object,innerRef:y().oneOfType([y().object,y().string,y().func])}),YO=ka(ka({},Ig.defaultProps),{},{timeout:150,appear:!0,enter:!0,exit:!0,in:!0});function Mg(t){var a=(0,s.useRef)(null),u=t.tag,v=u===void 0?"div":u,O=t.baseClass,A=O===void 0?"fade":O,I=t.baseClassActive,N=I===void 0?"show":I,T=t.className,C=t.cssModule,X=t.children,V=t.innerRef,$=V===void 0?a:V,q=(function(Q,ie){if(Q==null)return{};var ue,fe,me=(function(ye,ce){if(ye==null)return{};var Oe,Me,_e={},je=Object.keys(ye);for(Me=0;Me<je.length;Me++)Oe=je[Me],ce.indexOf(Oe)>=0||(_e[Oe]=ye[Oe]);return _e})(Q,ie);if(Object.getOwnPropertySymbols){var ve=Object.getOwnPropertySymbols(Q);for(fe=0;fe<ve.length;fe++)ue=ve[fe],ie.indexOf(ue)>=0||Object.prototype.propertyIsEnumerable.call(Q,ue)&&(me[ue]=Q[ue])}return me})(t,G4),H=(function(Q,ie){for(var ue,fe=Array.isArray(ie)?ie:[ie],me=fe.length,ve={};me>0;)ve[ue=fe[me-=1]]=Q[ue];return ve})(ka({defaultProps:YO},q),B),G=j(q,B);return b().createElement(Ig,gl({nodeRef:$},H),(function(Q){var ie=Q==="entered",ue=R(x()(T,A,ie&&N),C);return b().createElement(v,gl({className:ue},G,{ref:$}),X)}))}Mg.propTypes=Y4,Mg.defaultProps=YO;const Ca=Mg;function jg(t){return jg=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},jg(t)}function XO(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function ai(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?XO(Object(u),!0).forEach((function(v){si(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):XO(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function Aa(){return Aa=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Aa.apply(this,arguments)}function si(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function X4(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,v.key,v)}}function Lg(t,a){return Lg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Lg(t,a)}function Bn(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function vl(t){return vl=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},vl(t)}function yl(){}var ZO=y().shape(Ca.propTypes),QO={autoFocus:y().bool,backdrop:y().oneOfType([y().bool,y().oneOf(["static"])]),backdropClassName:y().string,backdropTransition:ZO,centered:y().bool,children:y().node,contentClassName:y().string,className:y().string,container:D,cssModule:y().object,external:y().node,fade:y().bool,fullscreen:y().oneOfType([y().bool,y().oneOf(["sm","md","lg","xl"])]),innerRef:y().oneOfType([y().object,y().string,y().func]),isOpen:y().bool,keyboard:y().bool,labelledBy:y().string,modalClassName:y().string,modalTransition:ZO,onClosed:y().func,onEnter:y().func,onExit:y().func,onOpened:y().func,returnFocusAfterClose:y().bool,role:y().string,scrollable:y().bool,size:y().string,toggle:y().func,trapFocus:y().bool,unmountOnClose:y().bool,wrapClassName:y().string,zIndex:y().oneOfType([y().number,y().string])},Z4=Object.keys(QO),Q4={isOpen:!1,autoFocus:!0,centered:!1,scrollable:!1,role:"dialog",backdrop:!0,keyboard:!0,zIndex:1050,fade:!0,onOpened:yl,onClosed:yl,modalTransition:{timeout:300},backdropTransition:{mountOnEnter:!0,timeout:150},unmountOnClose:!0,returnFocusAfterClose:!0,container:"body",trapFocus:!1},Na=(function(t){(function(N,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(T&&T.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),T&&Lg(N,T)})(I,t);var a,u,v,O,A=(v=I,O=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var N,T=vl(v);if(O){var C=vl(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(jg(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Bn(X)})(this,N)});function I(N){var T;return(function(C,X){if(!(C instanceof X))throw new TypeError("Cannot call a class as a function")})(this,I),(T=A.call(this,N))._element=null,T._originalBodyPadding=null,T.getFocusableChildren=T.getFocusableChildren.bind(Bn(T)),T.handleBackdropClick=T.handleBackdropClick.bind(Bn(T)),T.handleBackdropMouseDown=T.handleBackdropMouseDown.bind(Bn(T)),T.handleEscape=T.handleEscape.bind(Bn(T)),T.handleStaticBackdropAnimation=T.handleStaticBackdropAnimation.bind(Bn(T)),T.handleTab=T.handleTab.bind(Bn(T)),T.onOpened=T.onOpened.bind(Bn(T)),T.onClosed=T.onClosed.bind(Bn(T)),T.manageFocusAfterClose=T.manageFocusAfterClose.bind(Bn(T)),T.clearBackdropAnimationTimeout=T.clearBackdropAnimationTimeout.bind(Bn(T)),T.trapFocus=T.trapFocus.bind(Bn(T)),T.state={isOpen:!1,showStaticBackdropAnimation:!1},T}return a=I,u=[{key:"componentDidMount",value:function(){var N=this.props,T=N.isOpen,C=N.autoFocus,X=N.onEnter;T&&(this.init(),this.setState({isOpen:!0}),C&&this.setFocus()),X&&X(),document.addEventListener("focus",this.trapFocus,!0),this._isMounted=!0}},{key:"componentDidUpdate",value:function(N,T){if(this.props.isOpen&&!N.isOpen)return this.init(),void this.setState({isOpen:!0});this.props.autoFocus&&this.state.isOpen&&!T.isOpen&&this.setFocus(),this._element&&N.zIndex!==this.props.zIndex&&(this._element.style.zIndex=this.props.zIndex)}},{key:"componentWillUnmount",value:function(){this.clearBackdropAnimationTimeout(),this.props.onExit&&this.props.onExit(),this._element&&(this.destroy(),(this.props.isOpen||this.state.isOpen)&&this.close()),document.removeEventListener("focus",this.trapFocus,!0),this._isMounted=!1}},{key:"handleBackdropClick",value:function(N){if(N.target===this._mouseDownElement){N.stopPropagation();var T=this._dialog?this._dialog.parentNode:null;if(T&&N.target===T&&this.props.backdrop==="static"&&this.handleStaticBackdropAnimation(),!this.props.isOpen||this.props.backdrop!==!0)return;T&&N.target===T&&this.props.toggle&&this.props.toggle(N)}}},{key:"handleTab",value:function(N){if(N.which===9&&!(this.modalIndex<I.openCount-1)){var T=this.getFocusableChildren(),C=T.length;if(C!==0){for(var X=this.getFocusedChild(),V=0,$=0;$<C;$+=1)if(T[$]===X){V=$;break}N.shiftKey&&V===0?(N.preventDefault(),T[C-1].focus()):N.shiftKey||V!==C-1||(N.preventDefault(),T[0].focus())}}}},{key:"handleBackdropMouseDown",value:function(N){this._mouseDownElement=N.target}},{key:"handleEscape",value:function(N){this.props.isOpen&&N.keyCode===U.esc&&this.props.toggle&&(this.props.keyboard?(N.preventDefault(),N.stopPropagation(),this.props.toggle(N)):this.props.backdrop==="static"&&(N.preventDefault(),N.stopPropagation(),this.handleStaticBackdropAnimation()))}},{key:"handleStaticBackdropAnimation",value:function(){var N=this;this.clearBackdropAnimationTimeout(),this.setState({showStaticBackdropAnimation:!0}),this._backdropAnimationTimeout=setTimeout((function(){N.setState({showStaticBackdropAnimation:!1})}),100)}},{key:"onOpened",value:function(N,T){this.props.onOpened(),(this.props.modalTransition.onEntered||yl)(N,T)}},{key:"onClosed",value:function(N){var T=this.props.unmountOnClose;this.props.onClosed(),(this.props.modalTransition.onExited||yl)(N),T&&this.destroy(),this.close(),this._isMounted&&this.setState({isOpen:!1})}},{key:"setFocus",value:function(){this._dialog&&this._dialog.parentNode&&typeof this._dialog.parentNode.focus=="function"&&this._dialog.parentNode.focus()}},{key:"getFocusableChildren",value:function(){return this._element.querySelectorAll(Y.join(", "))}},{key:"getFocusedChild",value:function(){var N,T=this.getFocusableChildren();try{N=document.activeElement}catch{N=T[0]}return N}},{key:"trapFocus",value:function(N){if(this.props.trapFocus&&this._element&&!(this._dialog&&this._dialog.parentNode===N.target||this.modalIndex<I.openCount-1)){for(var T=this.getFocusableChildren(),C=0;C<T.length;C+=1)if(T[C]===N.target)return;T.length>0&&(N.preventDefault(),N.stopPropagation(),T[0].focus())}}},{key:"init",value:function(){try{this._triggeringElement=document.activeElement}catch{this._triggeringElement=null}var N,T,C,X;this._element||(this._element=document.createElement("div"),this._element.setAttribute("tabindex","-1"),this._element.style.position="relative",this._element.style.zIndex=this.props.zIndex,this._mountContainer=de(N=oe(this.props.container))?N[0]:N,this._mountContainer.appendChild(this._element)),this._originalBodyPadding=(function(){var V=window.getComputedStyle(document.body,null);return parseInt(V&&V.getPropertyValue("padding-right")||0,10)})(),I.openCount<1&&(I.originalBodyOverflow=window.getComputedStyle(document.body).overflow),T=(function(){var V=document.createElement("div");V.style.position="absolute",V.style.top="-9999px",V.style.width="50px",V.style.height="50px",V.style.overflow="scroll",document.body.appendChild(V);var $=V.offsetWidth-V.clientWidth;return document.body.removeChild(V),$})(),C=document.querySelectorAll(".fixed-top, .fixed-bottom, .is-fixed, .sticky-top")[0],X=C?parseInt(C.style.paddingRight||0,10):0,document.body.clientWidth<window.innerWidth&&P(X+T),I.openCount===0&&(document.body.className=x()(document.body.className,R("modal-open",this.props.cssModule)),document.body.style.overflow="hidden"),this.modalIndex=I.openCount,I.openCount+=1}},{key:"destroy",value:function(){this._element&&(this._mountContainer.removeChild(this._element),this._element=null),this.manageFocusAfterClose()}},{key:"manageFocusAfterClose",value:function(){if(this._triggeringElement){var N=this.props.returnFocusAfterClose;this._triggeringElement.focus&&N&&this._triggeringElement.focus(),this._triggeringElement=null}}},{key:"close",value:function(){if(I.openCount<=1){var N=R("modal-open",this.props.cssModule),T=new RegExp("(^| )".concat(N,"( |$)"));document.body.className=document.body.className.replace(T," ").trim(),document.body.style.overflow=I.originalBodyOverflow}this.manageFocusAfterClose(),I.openCount=Math.max(0,I.openCount-1),P(this._originalBodyPadding)}},{key:"clearBackdropAnimationTimeout",value:function(){this._backdropAnimationTimeout&&(clearTimeout(this._backdropAnimationTimeout),this._backdropAnimationTimeout=void 0)}},{key:"renderModalDialog",value:function(){var N,T=this,C=j(this.props,Z4),X="modal-dialog";return b().createElement("div",Aa({},C,{className:R(x()(X,this.props.className,(N={},si(N,"modal-".concat(this.props.size),this.props.size),si(N,"".concat(X,"-centered"),this.props.centered),si(N,"".concat(X,"-scrollable"),this.props.scrollable),si(N,"modal-fullscreen",this.props.fullscreen===!0),si(N,"modal-fullscreen-".concat(this.props.fullscreen,"-down"),typeof this.props.fullscreen=="string"),N)),this.props.cssModule),role:"document",ref:function(V){T._dialog=V}}),b().createElement("div",{className:R(x()("modal-content",this.props.contentClassName),this.props.cssModule)},this.props.children))}},{key:"render",value:function(){var N=this.props.unmountOnClose;if(this._element&&(this.state.isOpen||!N)){var T=!!this._element&&!this.state.isOpen&&!N;this._element.style.display=T?"none":"block";var C=this.props,X=C.wrapClassName,V=C.modalClassName,$=C.backdropClassName,q=C.cssModule,H=C.isOpen,G=C.backdrop,Q=C.role,ie=C.labelledBy,ue=C.external,fe=C.innerRef,me={onClick:this.handleBackdropClick,onMouseDown:this.handleBackdropMouseDown,onKeyUp:this.handleEscape,onKeyDown:this.handleTab,style:{display:"block"},"aria-labelledby":ie,"aria-modal":!0,role:Q,tabIndex:"-1"},ve=this.props.fade,ye=ai(ai(ai({},Ca.defaultProps),this.props.modalTransition),{},{baseClass:ve?this.props.modalTransition.baseClass:"",timeout:ve?this.props.modalTransition.timeout:0}),ce=ai(ai(ai({},Ca.defaultProps),this.props.backdropTransition),{},{baseClass:ve?this.props.backdropTransition.baseClass:"",timeout:ve?this.props.backdropTransition.timeout:0}),Oe=G&&(ve?b().createElement(Ca,Aa({},ce,{in:H&&!!G,cssModule:q,className:R(x()("modal-backdrop",$),q)})):b().createElement("div",{className:R(x()("modal-backdrop","show",$),q)}));return b().createElement(Rg,{node:this._element},b().createElement("div",{className:R(X)},b().createElement(Ca,Aa({},me,ye,{in:H,onEntered:this.onOpened,onExited:this.onClosed,cssModule:q,className:R(x()("modal",V,this.state.showStaticBackdropAnimation&&"modal-static"),q),innerRef:fe}),ue,this.renderModalDialog()),Oe))}return null}}],u&&X4(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);Na.propTypes=QO,Na.defaultProps=Q4,Na.openCount=0,Na.originalBodyOverflow=null;const J4=Na;var $4=["className","cssModule","children","toggle","tag","wrapTag","closeAriaLabel","close"];function Dg(){return Dg=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Dg.apply(this,arguments)}var eD={children:y().node,className:y().string,close:y().object,closeAriaLabel:y().string,cssModule:y().object,tag:F,toggle:y().func,wrapTag:F};function JO(t){var a,u=t.className,v=t.cssModule,O=t.children,A=t.toggle,I=t.tag,N=I===void 0?"h5":I,T=t.wrapTag,C=T===void 0?"div":T,X=t.closeAriaLabel,V=X===void 0?"Close":X,$=t.close,q=(function(G,Q){if(G==null)return{};var ie,ue,fe=(function(ve,ye){if(ve==null)return{};var ce,Oe,Me={},_e=Object.keys(ve);for(Oe=0;Oe<_e.length;Oe++)ce=_e[Oe],ye.indexOf(ce)>=0||(Me[ce]=ve[ce]);return Me})(G,Q);if(Object.getOwnPropertySymbols){var me=Object.getOwnPropertySymbols(G);for(ue=0;ue<me.length;ue++)ie=me[ue],Q.indexOf(ie)>=0||Object.prototype.propertyIsEnumerable.call(G,ie)&&(fe[ie]=G[ie])}return fe})(t,$4),H=R(x()(u,"modal-header"),v);return!$&&A&&(a=b().createElement("button",{type:"button",onClick:A,className:R("btn-close",v),"aria-label":V})),b().createElement(C,Dg({},q,{className:H}),b().createElement(N,{className:R("modal-title",v)},O),$||a)}JO.propTypes=eD;const tD=JO;var nD=["className","cssModule","tag"];function Bg(){return Bg=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Bg.apply(this,arguments)}var rD={className:y().string,cssModule:y().object,tag:F};function $O(t){var a=t.className,u=t.cssModule,v=t.tag,O=v===void 0?"div":v,A=(function(N,T){if(N==null)return{};var C,X,V=(function(q,H){if(q==null)return{};var G,Q,ie={},ue=Object.keys(q);for(Q=0;Q<ue.length;Q++)G=ue[Q],H.indexOf(G)>=0||(ie[G]=q[G]);return ie})(N,T);if(Object.getOwnPropertySymbols){var $=Object.getOwnPropertySymbols(N);for(X=0;X<$.length;X++)C=$[X],T.indexOf(C)>=0||Object.prototype.propertyIsEnumerable.call(N,C)&&(V[C]=N[C])}return V})(t,nD),I=R(x()(a,"modal-body"),u);return b().createElement(O,Bg({},A,{className:I}))}$O.propTypes=rD;const oD=$O;var iD=["className","cssModule","tag"];function Fg(){return Fg=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Fg.apply(this,arguments)}var aD={className:y().string,cssModule:y().object,tag:F};function ek(t){var a=t.className,u=t.cssModule,v=t.tag,O=v===void 0?"div":v,A=(function(N,T){if(N==null)return{};var C,X,V=(function(q,H){if(q==null)return{};var G,Q,ie={},ue=Object.keys(q);for(Q=0;Q<ue.length;Q++)G=ue[Q],H.indexOf(G)>=0||(ie[G]=q[G]);return ie})(N,T);if(Object.getOwnPropertySymbols){var $=Object.getOwnPropertySymbols(N);for(X=0;X<$.length;X++)C=$[X],T.indexOf(C)>=0||Object.prototype.propertyIsEnumerable.call(N,C)&&(V[C]=N[C])}return V})(t,iD),I=R(x()(a,"modal-footer"),u);return b().createElement(O,Fg({},A,{className:I}))}ek.propTypes=aD;const sD=ek;function tk(t){var a,u,v="";if(typeof t=="string"||typeof t=="number")v+=t;else if(typeof t=="object")if(Array.isArray(t)){var O=t.length;for(a=0;a<O;a++)t[a]&&(u=tk(t[a]))&&(v&&(v+=" "),v+=u)}else for(u in t)t[u]&&(v&&(v+=" "),v+=u);return v}const Pt=function(){for(var t,a,u=0,v="",O=arguments.length;u<O;u++)(t=arguments[u])&&(a=tk(t))&&(v&&(v+=" "),v+=a);return v};function or(t,a,u=void 0){const v={};for(const O in t){const A=t[O];let I="",N=!0;for(let T=0;T<A.length;T+=1){const C=A[T];C&&(I+=(N===!0?"":" ")+a(C),N=!1,u&&u[C]&&(I+=" "+u[C]))}v[O]=I}return v}function et(){return et=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},et.apply(this,arguments)}var lD=(function(){function t(u){var v=this;this._insertTag=function(O){var A;A=v.tags.length===0?v.insertionPoint?v.insertionPoint.nextSibling:v.prepend?v.container.firstChild:v.before:v.tags[v.tags.length-1].nextSibling,v.container.insertBefore(O,A),v.tags.push(O)},this.isSpeedy=u.speedy===void 0||u.speedy,this.tags=[],this.ctr=0,this.nonce=u.nonce,this.key=u.key,this.container=u.container,this.prepend=u.prepend,this.insertionPoint=u.insertionPoint,this.before=null}var a=t.prototype;return a.hydrate=function(u){u.forEach(this._insertTag)},a.insert=function(u){this.ctr%(this.isSpeedy?65e3:1)==0&&this._insertTag((function(A){var I=document.createElement("style");return I.setAttribute("data-emotion",A.key),A.nonce!==void 0&&I.setAttribute("nonce",A.nonce),I.appendChild(document.createTextNode("")),I.setAttribute("data-s",""),I})(this));var v=this.tags[this.tags.length-1];if(this.isSpeedy){var O=(function(A){if(A.sheet)return A.sheet;for(var I=0;I<document.styleSheets.length;I++)if(document.styleSheets[I].ownerNode===A)return document.styleSheets[I]})(v);try{O.insertRule(u,O.cssRules.length)}catch{}}else v.appendChild(document.createTextNode(u));this.ctr++},a.flush=function(){this.tags.forEach((function(u){return u.parentNode&&u.parentNode.removeChild(u)})),this.tags=[],this.ctr=0},t})(),uD=Math.abs,bl=String.fromCharCode,cD=Object.assign;function nk(t){return t.trim()}function vt(t,a,u){return t.replace(a,u)}function qg(t,a){return t.indexOf(a)}function fn(t,a){return 0|t.charCodeAt(a)}function Ta(t,a,u){return t.slice(a,u)}function mr(t){return t.length}function zg(t){return t.length}function wl(t,a){return a.push(t),t}var xl=1,li=1,rk=0,Sn=0,Xt=0,ui="";function _l(t,a,u,v,O,A,I){return{value:t,root:a,parent:u,type:v,props:O,children:A,line:xl,column:li,length:I,return:""}}function Ra(t,a){return cD(_l("",null,null,"",null,null,0),t,{length:-t.length},a)}function fD(){return Xt=Sn>0?fn(ui,--Sn):0,li--,Xt===10&&(li=1,xl--),Xt}function An(){return Xt=Sn<rk?fn(ui,Sn++):0,li++,Xt===10&&(li=1,xl++),Xt}function gr(){return fn(ui,Sn)}function Sl(){return Sn}function Pa(t,a){return Ta(ui,t,a)}function Ia(t){switch(t){case 0:case 9:case 10:case 13:case 32:return 5;case 33:case 43:case 44:case 47:case 62:case 64:case 126:case 59:case 123:case 125:return 4;case 58:return 3;case 34:case 39:case 40:case 91:return 2;case 41:case 93:return 1}return 0}function ok(t){return xl=li=1,rk=mr(ui=t),Sn=0,[]}function ik(t){return ui="",t}function El(t){return nk(Pa(Sn-1,Hg(t===91?t+2:t===40?t+1:t)))}function dD(t){for(;(Xt=gr())&&Xt<33;)An();return Ia(t)>2||Ia(Xt)>3?"":" "}function hD(t,a){for(;--a&&An()&&!(Xt<48||Xt>102||Xt>57&&Xt<65||Xt>70&&Xt<97););return Pa(t,Sl()+(a<6&&gr()==32&&An()==32))}function Hg(t){for(;An();)switch(Xt){case t:return Sn;case 34:case 39:t!==34&&t!==39&&Hg(Xt);break;case 40:t===41&&Hg(t);break;case 92:An()}return Sn}function pD(t,a){for(;An()&&t+Xt!==57&&(t+Xt!==84||gr()!==47););return"/*"+Pa(a,Sn-1)+"*"+bl(t===47?t:An())}function mD(t){for(;!Ia(gr());)An();return Pa(t,Sn)}var pn="-ms-",ak="-moz-",yt="-webkit-",sk="comm",Vg="rule",Ug="decl",lk="@keyframes";function ci(t,a){for(var u="",v=zg(t),O=0;O<v;O++)u+=a(t[O],O,t,a)||"";return u}function gD(t,a,u,v){switch(t.type){case"@layer":if(t.children.length)break;case"@import":case Ug:return t.return=t.return||t.value;case sk:return"";case lk:return t.return=t.value+"{"+ci(t.children,v)+"}";case Vg:t.value=t.props.join(",")}return mr(u=ci(t.children,v))?t.return=t.value+"{"+u+"}":""}function vD(t){return ik(Ol("",null,null,null,[""],t=ok(t),0,[0],t))}function Ol(t,a,u,v,O,A,I,N,T){for(var C=0,X=0,V=I,$=0,q=0,H=0,G=1,Q=1,ie=1,ue=0,fe="",me=O,ve=A,ye=v,ce=fe;Q;)switch(H=ue,ue=An()){case 40:if(H!=108&&fn(ce,V-1)==58){qg(ce+=vt(El(ue),"&","&\f"),"&\f")!=-1&&(ie=-1);break}case 34:case 39:case 91:ce+=El(ue);break;case 9:case 10:case 13:case 32:ce+=dD(H);break;case 92:ce+=hD(Sl()-1,7);continue;case 47:switch(gr()){case 42:case 47:wl(yD(pD(An(),Sl()),a,u),T);break;default:ce+="/"}break;case 123*G:N[C++]=mr(ce)*ie;case 125*G:case 59:case 0:switch(ue){case 0:case 125:Q=0;case 59+X:ie==-1&&(ce=vt(ce,/\f/g,"")),q>0&&mr(ce)-V&&wl(q>32?ck(ce+";",v,u,V-1):ck(vt(ce," ","")+";",v,u,V-2),T);break;case 59:ce+=";";default:if(wl(ye=uk(ce,a,u,C,X,O,N,fe,me=[],ve=[],V),A),ue===123)if(X===0)Ol(ce,a,ye,ye,me,A,V,N,ve);else switch($===99&&fn(ce,3)===110?100:$){case 100:case 108:case 109:case 115:Ol(t,ye,ye,v&&wl(uk(t,ye,ye,0,0,O,N,fe,O,me=[],V),ve),O,ve,V,N,v?me:ve);break;default:Ol(ce,ye,ye,ye,[""],ve,0,N,ve)}}C=X=q=0,G=ie=1,fe=ce="",V=I;break;case 58:V=1+mr(ce),q=H;default:if(G<1){if(ue==123)--G;else if(ue==125&&G++==0&&fD()==125)continue}switch(ce+=bl(ue),ue*G){case 38:ie=X>0?1:(ce+="\f",-1);break;case 44:N[C++]=(mr(ce)-1)*ie,ie=1;break;case 64:gr()===45&&(ce+=El(An())),$=gr(),X=V=mr(fe=ce+=mD(Sl())),ue++;break;case 45:H===45&&mr(ce)==2&&(G=0)}}return A}function uk(t,a,u,v,O,A,I,N,T,C,X){for(var V=O-1,$=O===0?A:[""],q=zg($),H=0,G=0,Q=0;H<v;++H)for(var ie=0,ue=Ta(t,V+1,V=uD(G=I[H])),fe=t;ie<q;++ie)(fe=nk(G>0?$[ie]+" "+ue:vt(ue,/&\f/g,$[ie])))&&(T[Q++]=fe);return _l(t,a,u,O===0?Vg:N,T,C,X)}function yD(t,a,u){return _l(t,a,u,sk,bl(Xt),Ta(t,2,-2),0)}function ck(t,a,u,v){return _l(t,a,u,Ug,Ta(t,0,v),Ta(t,v+1,-1),v)}var bD=function(t,a,u){for(var v=0,O=0;v=O,O=gr(),v===38&&O===12&&(a[u]=1),!Ia(O);)An();return Pa(t,Sn)},fk=new WeakMap,wD=function(t){if(t.type==="rule"&&t.parent&&!(t.length<1)){for(var a=t.value,u=t.parent,v=t.column===u.column&&t.line===u.line;u.type!=="rule";)if(!(u=u.parent))return;if((t.props.length!==1||a.charCodeAt(0)===58||fk.get(u))&&!v){fk.set(t,!0);for(var O=[],A=(function(X,V){return ik((function($,q){var H=-1,G=44;do switch(Ia(G)){case 0:G===38&&gr()===12&&(q[H]=1),$[H]+=bD(Sn-1,q,H);break;case 2:$[H]+=El(G);break;case 4:if(G===44){$[++H]=gr()===58?"&\f":"",q[H]=$[H].length;break}default:$[H]+=bl(G)}while(G=An());return $})(ok(X),V))})(a,O),I=u.props,N=0,T=0;N<A.length;N++)for(var C=0;C<I.length;C++,T++)t.props[T]=O[N]?A[N].replace(/&\f/g,I[C]):I[C]+" "+A[N]}}},xD=function(t){if(t.type==="decl"){var a=t.value;a.charCodeAt(0)===108&&a.charCodeAt(2)===98&&(t.return="",t.value="")}};function dk(t,a){switch((function(u,v){return 45^fn(u,0)?(((v<<2^fn(u,0))<<2^fn(u,1))<<2^fn(u,2))<<2^fn(u,3):0})(t,a)){case 5103:return yt+"print-"+t+t;case 5737:case 4201:case 3177:case 3433:case 1641:case 4457:case 2921:case 5572:case 6356:case 5844:case 3191:case 6645:case 3005:case 6391:case 5879:case 5623:case 6135:case 4599:case 4855:case 4215:case 6389:case 5109:case 5365:case 5621:case 3829:return yt+t+t;case 5349:case 4246:case 4810:case 6968:case 2756:return yt+t+ak+t+pn+t+t;case 6828:case 4268:return yt+t+pn+t+t;case 6165:return yt+t+pn+"flex-"+t+t;case 5187:return yt+t+vt(t,/(\w+).+(:[^]+)/,yt+"box-$1$2"+pn+"flex-$1$2")+t;case 5443:return yt+t+pn+"flex-item-"+vt(t,/flex-|-self/,"")+t;case 4675:return yt+t+pn+"flex-line-pack"+vt(t,/align-content|flex-|-self/,"")+t;case 5548:return yt+t+pn+vt(t,"shrink","negative")+t;case 5292:return yt+t+pn+vt(t,"basis","preferred-size")+t;case 6060:return yt+"box-"+vt(t,"-grow","")+yt+t+pn+vt(t,"grow","positive")+t;case 4554:return yt+vt(t,/([^-])(transform)/g,"$1"+yt+"$2")+t;case 6187:return vt(vt(vt(t,/(zoom-|grab)/,yt+"$1"),/(image-set)/,yt+"$1"),t,"")+t;case 5495:case 3959:return vt(t,/(image-set\([^]*)/,yt+"$1$`$1");case 4968:return vt(vt(t,/(.+:)(flex-)?(.*)/,yt+"box-pack:$3"+pn+"flex-pack:$3"),/s.+-b[^;]+/,"justify")+yt+t+t;case 4095:case 3583:case 4068:case 2532:return vt(t,/(.+)-inline(.+)/,yt+"$1$2")+t;case 8116:case 7059:case 5753:case 5535:case 5445:case 5701:case 4933:case 4677:case 5533:case 5789:case 5021:case 4765:if(mr(t)-1-a>6)switch(fn(t,a+1)){case 109:if(fn(t,a+4)!==45)break;case 102:return vt(t,/(.+:)(.+)-([^]+)/,"$1"+yt+"$2-$3$1"+ak+(fn(t,a+3)==108?"$3":"$2-$3"))+t;case 115:return~qg(t,"stretch")?dk(vt(t,"stretch","fill-available"),a)+t:t}break;case 4949:if(fn(t,a+1)!==115)break;case 6444:switch(fn(t,mr(t)-3-(~qg(t,"!important")&&10))){case 107:return vt(t,":",":"+yt)+t;case 101:return vt(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+yt+(fn(t,14)===45?"inline-":"")+"box$3$1"+yt+"$2$3$1"+pn+"$2box$3")+t}break;case 5936:switch(fn(t,a+11)){case 114:return yt+t+pn+vt(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return yt+t+pn+vt(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return yt+t+pn+vt(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return yt+t+pn+t+t}return t}var _D=[function(t,a,u,v){if(t.length>-1&&!t.return)switch(t.type){case Ug:t.return=dk(t.value,t.length);break;case lk:return ci([Ra(t,{value:vt(t.value,"@","@"+yt)})],v);case Vg:if(t.length)return(function(O,A){return O.map(A).join("")})(t.props,(function(O){switch((function(A,I){return(A=/(::plac\w+|:read-\w+)/.exec(A))?A[0]:A})(O)){case":read-only":case":read-write":return ci([Ra(t,{props:[vt(O,/:(read-\w+)/,":-moz-$1")]})],v);case"::placeholder":return ci([Ra(t,{props:[vt(O,/:(plac\w+)/,":"+yt+"input-$1")]}),Ra(t,{props:[vt(O,/:(plac\w+)/,":-moz-$1")]}),Ra(t,{props:[vt(O,/:(plac\w+)/,pn+"input-$1")]})],v)}return""}))}}],SD=function(t){var a=t.key;if(a==="css"){var u=document.querySelectorAll("style[data-emotion]:not([data-s])");Array.prototype.forEach.call(u,(function(G){G.getAttribute("data-emotion").indexOf(" ")!==-1&&(document.head.appendChild(G),G.setAttribute("data-s",""))}))}var v,O,A=t.stylisPlugins||_D,I={},N=[];v=t.container||document.head,Array.prototype.forEach.call(document.querySelectorAll('style[data-emotion^="'+a+' "]'),(function(G){for(var Q=G.getAttribute("data-emotion").split(" "),ie=1;ie<Q.length;ie++)I[Q[ie]]=!0;N.push(G)}));var T,C,X,V,$=[gD,(C=function(G){T.insert(G)},function(G){G.root||(G=G.return)&&C(G)})],q=(X=[wD,xD].concat(A,$),V=zg(X),function(G,Q,ie,ue){for(var fe="",me=0;me<V;me++)fe+=X[me](G,Q,ie,ue)||"";return fe});O=function(G,Q,ie,ue){T=ie,(function(fe){ci(vD(fe),q)})(G?G+"{"+Q.styles+"}":Q.styles),ue&&(H.inserted[Q.name]=!0)};var H={key:a,sheet:new lD({key:a,container:v,nonce:t.nonce,speedy:t.speedy,prepend:t.prepend,insertionPoint:t.insertionPoint}),nonce:t.nonce,inserted:I,registered:{},insert:O};return H.sheet.hydrate(N),H},hk=function(t,a,u){var v=t.key+"-"+a.name;u===!1&&t.registered[v]===void 0&&(t.registered[v]=a.styles)},ED={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function OD(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var kD=/[A-Z]|^ms/g,CD=/_EMO_([^_]+?)_([^]*?)_EMO_/g,pk=function(t){return t.charCodeAt(1)===45},mk=function(t){return t!=null&&typeof t!="boolean"},Wg=OD((function(t){return pk(t)?t:t.replace(kD,"-$&").toLowerCase()})),gk=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(CD,(function(u,v,O){return vr={name:v,styles:O,next:vr},v}))}return ED[t]===1||pk(t)||typeof a!="number"||a===0?a:a+"px"};function Ma(t,a,u){if(u==null)return"";if(u.__emotion_styles!==void 0)return u;switch(typeof u){case"boolean":return"";case"object":if(u.anim===1)return vr={name:u.name,styles:u.styles,next:vr},u.name;if(u.styles!==void 0){var v=u.next;if(v!==void 0)for(;v!==void 0;)vr={name:v.name,styles:v.styles,next:vr},v=v.next;return u.styles+";"}return(function(I,N,T){var C="";if(Array.isArray(T))for(var X=0;X<T.length;X++)C+=Ma(I,N,T[X])+";";else for(var V in T){var $=T[V];if(typeof $!="object")mk($)&&(C+=Wg(V)+":"+gk(V,$)+";");else if(!Array.isArray($)||typeof $[0]!="string"||N!=null){var q=Ma(I,N,$);switch(V){case"animation":case"animationName":C+=Wg(V)+":"+q+";";break;default:C+=V+"{"+q+"}"}}else for(var H=0;H<$.length;H++)mk($[H])&&(C+=Wg(V)+":"+gk(V,$[H])+";")}return C})(t,a,u);case"function":if(t!==void 0){var O=vr,A=u(t);return vr=O,Ma(t,a,A)}}return u}var vr,vk=/label:\s*([^\s;\n{]+)\s*(;|$)/g,yk=function(t,a,u){if(t.length===1&&typeof t[0]=="object"&&t[0]!==null&&t[0].styles!==void 0)return t[0];var v=!0,O="";vr=void 0;var A=t[0];A==null||A.raw===void 0?(v=!1,O+=Ma(u,a,A)):O+=A[0];for(var I=1;I<t.length;I++)O+=Ma(u,a,t[I]),v&&(O+=A[I]);vk.lastIndex=0;for(var N,T="";(N=vk.exec(O))!==null;)T+="-"+N[1];var C=(function(X){for(var V,$=0,q=0,H=X.length;H>=4;++q,H-=4)V=1540483477*(65535&(V=255&X.charCodeAt(q)|(255&X.charCodeAt(++q))<<8|(255&X.charCodeAt(++q))<<16|(255&X.charCodeAt(++q))<<24))+(59797*(V>>>16)<<16),$=1540483477*(65535&(V^=V>>>24))+(59797*(V>>>16)<<16)^1540483477*(65535&$)+(59797*($>>>16)<<16);switch(H){case 3:$^=(255&X.charCodeAt(q+2))<<16;case 2:$^=(255&X.charCodeAt(q+1))<<8;case 1:$=1540483477*(65535&($^=255&X.charCodeAt(q)))+(59797*($>>>16)<<16)}return((($=1540483477*(65535&($^=$>>>13))+(59797*($>>>16)<<16))^$>>>15)>>>0).toString(36)})(O)+T;return{name:C,styles:O,next:vr}},bk=!!s.useInsertionEffect&&s.useInsertionEffect,AD=bk||function(t){return t()},Gg=(bk||s.useLayoutEffect,{}.hasOwnProperty),wk=s.createContext(typeof HTMLElement<"u"?SD({key:"css"}):null);wk.Provider;var xk=function(t){return(0,s.forwardRef)((function(a,u){var v=(0,s.useContext)(wk);return t(a,v,u)}))},Kg=s.createContext({}),Yg="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",ND=function(t){var a=t.cache,u=t.serialized,v=t.isStringTag;return hk(a,u,v),AD((function(){return(function(O,A,I){hk(O,A,I);var N=O.key+"-"+A.name;if(O.inserted[A.name]===void 0){var T=A;do O.insert(A===T?"."+N:"",T,O.sheet,!0),T=T.next;while(T!==void 0)}})(a,u,v)})),null},TD=xk((function(t,a,u){var v=t.css;typeof v=="string"&&a.registered[v]!==void 0&&(v=a.registered[v]);var O=t[Yg],A=[v],I="";typeof t.className=="string"?I=(function(X,V,$){var q="";return $.split(" ").forEach((function(H){X[H]!==void 0?V.push(X[H]+";"):q+=H+" "})),q})(a.registered,A,t.className):t.className!=null&&(I=t.className+" ");var N=yk(A,void 0,s.useContext(Kg));I+=a.key+"-"+N.name;var T={};for(var C in t)Gg.call(t,C)&&C!=="css"&&C!==Yg&&(T[C]=t[C]);return T.ref=u,T.className=I,s.createElement(s.Fragment,null,s.createElement(ND,{cache:a,serialized:N,isStringTag:typeof O=="string"}),s.createElement(O,T))})),RD=TD,PD={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function _k(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var ID=/[A-Z]|^ms/g,MD=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Sk=function(t){return t.charCodeAt(1)===45},Ek=function(t){return t!=null&&typeof t!="boolean"},Xg=_k((function(t){return Sk(t)?t:t.replace(ID,"-$&").toLowerCase()})),Ok=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(MD,(function(u,v,O){return yr={name:v,styles:O,next:yr},v}))}return PD[t]===1||Sk(t)||typeof a!="number"||a===0?a:a+"px"};function ja(t,a,u){if(u==null)return"";var v=u;if(v.__emotion_styles!==void 0)return v;switch(typeof u){case"boolean":return"";case"object":var O=u;if(O.anim===1)return yr={name:O.name,styles:O.styles,next:yr},O.name;var A=u;if(A.styles!==void 0){var I=A.next;if(I!==void 0)for(;I!==void 0;)yr={name:I.name,styles:I.styles,next:yr},I=I.next;return A.styles+";"}return(function(V,$,q){var H="";if(Array.isArray(q))for(var G=0;G<q.length;G++)H+=ja(V,$,q[G])+";";else for(var Q in q){var ie=q[Q];if(typeof ie!="object"){var ue=ie;$!=null&&$[ue]!==void 0?H+=Q+"{"+$[ue]+"}":Ek(ue)&&(H+=Xg(Q)+":"+Ok(Q,ue)+";")}else if(!Array.isArray(ie)||typeof ie[0]!="string"||$!=null&&$[ie[0]]!==void 0){var fe=ja(V,$,ie);switch(Q){case"animation":case"animationName":H+=Xg(Q)+":"+fe+";";break;default:H+=Q+"{"+fe+"}"}}else for(var me=0;me<ie.length;me++)Ek(ie[me])&&(H+=Xg(Q)+":"+Ok(Q,ie[me])+";")}return H})(t,a,u);case"function":if(t!==void 0){var N=yr,T=u(t);return yr=N,ja(t,a,T)}}var C=u;if(a==null)return C;var X=a[C];return X!==void 0?X:C}var yr,kk=/label:\s*([^\s;{]+)\s*(;|$)/g,Ck=!!s.useInsertionEffect&&s.useInsertionEffect,jD=Ck||function(t){return t()};Ck||s.useLayoutEffect;var Ak=function(t,a,u){var v=t.key+"-"+a.name;u===!1&&t.registered[v]===void 0&&(t.registered[v]=a.styles)},LD=/^((children|dangerouslySetInnerHTML|key|ref|autoFocus|defaultValue|defaultChecked|innerHTML|suppressContentEditableWarning|suppressHydrationWarning|valueLink|abbr|accept|acceptCharset|accessKey|action|allow|allowUserMedia|allowPaymentRequest|allowFullScreen|allowTransparency|alt|async|autoComplete|autoPlay|capture|cellPadding|cellSpacing|challenge|charSet|checked|cite|classID|className|cols|colSpan|content|contentEditable|contextMenu|controls|controlsList|coords|crossOrigin|data|dateTime|decoding|default|defer|dir|disabled|disablePictureInPicture|disableRemotePlayback|download|draggable|encType|enterKeyHint|fetchpriority|fetchPriority|form|formAction|formEncType|formMethod|formNoValidate|formTarget|frameBorder|headers|height|hidden|high|href|hrefLang|htmlFor|httpEquiv|id|inputMode|integrity|is|keyParams|keyType|kind|label|lang|list|loading|loop|low|marginHeight|marginWidth|max|maxLength|media|mediaGroup|method|min|minLength|multiple|muted|name|nonce|noValidate|open|optimum|pattern|placeholder|playsInline|popover|popoverTarget|popoverTargetAction|poster|preload|profile|radioGroup|readOnly|referrerPolicy|rel|required|reversed|role|rows|rowSpan|sandbox|scope|scoped|scrolling|seamless|selected|shape|size|sizes|slot|span|spellCheck|src|srcDoc|srcLang|srcSet|start|step|style|summary|tabIndex|target|title|translate|type|useMap|value|width|wmode|wrap|about|datatype|inlist|prefix|property|resource|typeof|vocab|autoCapitalize|autoCorrect|autoSave|color|incremental|fallback|inert|itemProp|itemScope|itemType|itemID|itemRef|on|option|results|security|unselectable|accentHeight|accumulate|additive|alignmentBaseline|allowReorder|alphabetic|amplitude|arabicForm|ascent|attributeName|attributeType|autoReverse|azimuth|baseFrequency|baselineShift|baseProfile|bbox|begin|bias|by|calcMode|capHeight|clip|clipPathUnits|clipPath|clipRule|colorInterpolation|colorInterpolationFilters|colorProfile|colorRendering|contentScriptType|contentStyleType|cursor|cx|cy|d|decelerate|descent|diffuseConstant|direction|display|divisor|dominantBaseline|dur|dx|dy|edgeMode|elevation|enableBackground|end|exponent|externalResourcesRequired|fill|fillOpacity|fillRule|filter|filterRes|filterUnits|floodColor|floodOpacity|focusable|fontFamily|fontSize|fontSizeAdjust|fontStretch|fontStyle|fontVariant|fontWeight|format|from|fr|fx|fy|g1|g2|glyphName|glyphOrientationHorizontal|glyphOrientationVertical|glyphRef|gradientTransform|gradientUnits|hanging|horizAdvX|horizOriginX|ideographic|imageRendering|in|in2|intercept|k|k1|k2|k3|k4|kernelMatrix|kernelUnitLength|kerning|keyPoints|keySplines|keyTimes|lengthAdjust|letterSpacing|lightingColor|limitingConeAngle|local|markerEnd|markerMid|markerStart|markerHeight|markerUnits|markerWidth|mask|maskContentUnits|maskUnits|mathematical|mode|numOctaves|offset|opacity|operator|order|orient|orientation|origin|overflow|overlinePosition|overlineThickness|panose1|paintOrder|pathLength|patternContentUnits|patternTransform|patternUnits|pointerEvents|points|pointsAtX|pointsAtY|pointsAtZ|preserveAlpha|preserveAspectRatio|primitiveUnits|r|radius|refX|refY|renderingIntent|repeatCount|repeatDur|requiredExtensions|requiredFeatures|restart|result|rotate|rx|ry|scale|seed|shapeRendering|slope|spacing|specularConstant|specularExponent|speed|spreadMethod|startOffset|stdDeviation|stemh|stemv|stitchTiles|stopColor|stopOpacity|strikethroughPosition|strikethroughThickness|string|stroke|strokeDasharray|strokeDashoffset|strokeLinecap|strokeLinejoin|strokeMiterlimit|strokeOpacity|strokeWidth|surfaceScale|systemLanguage|tableValues|targetX|targetY|textAnchor|textDecoration|textRendering|textLength|to|transform|u1|u2|underlinePosition|underlineThickness|unicode|unicodeBidi|unicodeRange|unitsPerEm|vAlphabetic|vHanging|vIdeographic|vMathematical|values|vectorEffect|version|vertAdvY|vertOriginX|vertOriginY|viewBox|viewTarget|visibility|widths|wordSpacing|writingMode|x|xHeight|x1|x2|xChannelSelector|xlinkActuate|xlinkArcrole|xlinkHref|xlinkRole|xlinkShow|xlinkTitle|xlinkType|xmlBase|xmlns|xmlnsXlink|xmlLang|xmlSpace|y|y1|y2|yChannelSelector|z|zoomAndPan|for|class|autofocus)|(([Dd][Aa][Tt][Aa]|[Aa][Rr][Ii][Aa]|x)-.*))$/,DD=_k((function(t){return LD.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91})),BD=function(t){return t!=="theme"},Nk=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?DD:BD},Tk=function(t,a,u){var v;if(a){var O=a.shouldForwardProp;v=t.__emotion_forwardProp&&O?function(A){return t.__emotion_forwardProp(A)&&O(A)}:O}return typeof v!="function"&&u&&(v=t.__emotion_forwardProp),v},FD=function(t){var a=t.cache,u=t.serialized,v=t.isStringTag;return Ak(a,u,v),jD((function(){return(function(O,A,I){Ak(O,A,I);var N=O.key+"-"+A.name;if(O.inserted[A.name]===void 0){var T=A;do O.insert(A===T?"."+N:"",T,O.sheet,!0),T=T.next;while(T!==void 0)}})(a,u,v)})),null},Zg=(function t(a,u){var v,O,A=a.__emotion_real===a,I=A&&a.__emotion_base||a;u!==void 0&&(v=u.label,O=u.target);var N=Tk(a,u,A),T=N||Nk(I),C=!T("as");return function(){var X=arguments,V=A&&a.__emotion_styles!==void 0?a.__emotion_styles.slice(0):[];if(v!==void 0&&V.push("label:"+v+";"),X[0]==null||X[0].raw===void 0)V.push.apply(V,X);else{var $=X[0];V.push($[0]);for(var q=X.length,H=1;H<q;H++)V.push(X[H],$[H])}var G=xk((function(Q,ie,ue){var fe=C&&Q.as||I,me="",ve=[],ye=Q;if(Q.theme==null){for(var ce in ye={},Q)ye[ce]=Q[ce];ye.theme=s.useContext(Kg)}typeof Q.className=="string"?me=(function(Ne,Te,ze){var Le="";return ze.split(" ").forEach((function(ke){Ne[ke]!==void 0?Te.push(Ne[ke]+";"):ke&&(Le+=ke+" ")})),Le})(ie.registered,ve,Q.className):Q.className!=null&&(me=Q.className+" ");var Oe=(function(Ne,Te,ze){if(Ne.length===1&&typeof Ne[0]=="object"&&Ne[0]!==null&&Ne[0].styles!==void 0)return Ne[0];var Le=!0,ke="";yr=void 0;var Ke=Ne[0];Ke==null||Ke.raw===void 0?(Le=!1,ke+=ja(ze,Te,Ke)):ke+=Ke[0];for(var $e=1;$e<Ne.length;$e++)ke+=ja(ze,Te,Ne[$e]),Le&&(ke+=Ke[$e]);kk.lastIndex=0;for(var dt,lt="";(dt=kk.exec(ke))!==null;)lt+="-"+dt[1];var gt=(function(Xe){for(var le,qe=0,Ie=0,Ye=Xe.length;Ye>=4;++Ie,Ye-=4)le=1540483477*(65535&(le=255&Xe.charCodeAt(Ie)|(255&Xe.charCodeAt(++Ie))<<8|(255&Xe.charCodeAt(++Ie))<<16|(255&Xe.charCodeAt(++Ie))<<24))+(59797*(le>>>16)<<16),qe=1540483477*(65535&(le^=le>>>24))+(59797*(le>>>16)<<16)^1540483477*(65535&qe)+(59797*(qe>>>16)<<16);switch(Ye){case 3:qe^=(255&Xe.charCodeAt(Ie+2))<<16;case 2:qe^=(255&Xe.charCodeAt(Ie+1))<<8;case 1:qe=1540483477*(65535&(qe^=255&Xe.charCodeAt(Ie)))+(59797*(qe>>>16)<<16)}return(((qe=1540483477*(65535&(qe^=qe>>>13))+(59797*(qe>>>16)<<16))^qe>>>15)>>>0).toString(36)})(ke)+lt;return{name:gt,styles:ke,next:yr}})(V.concat(ve),ie.registered,ye);me+=ie.key+"-"+Oe.name,O!==void 0&&(me+=" "+O);var Me=C&&N===void 0?Nk(fe):T,_e={};for(var je in Q)C&&je==="as"||Me(je)&&(_e[je]=Q[je]);return _e.className=me,ue&&(_e.ref=ue),s.createElement(s.Fragment,null,s.createElement(FD,{cache:ie,serialized:Oe,isStringTag:typeof fe=="string"}),s.createElement(fe,_e))}));return G.displayName=v!==void 0?v:"Styled("+(typeof I=="string"?I:I.displayName||I.name||"Component")+")",G.defaultProps=a.defaultProps,G.__emotion_real=G,G.__emotion_base=I,G.__emotion_styles=V,G.__emotion_forwardProp=N,Object.defineProperty(G,"toString",{value:function(){return"."+O}}),G.withComponent=function(Q,ie){return t(Q,et({},u,ie,{shouldForwardProp:Tk(G,ie,!0)})).apply(void 0,V)},G}}).bind(null);["a","abbr","address","area","article","aside","audio","b","base","bdi","bdo","big","blockquote","body","br","button","canvas","caption","cite","code","col","colgroup","data","datalist","dd","del","details","dfn","dialog","div","dl","dt","em","embed","fieldset","figcaption","figure","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","iframe","img","input","ins","kbd","keygen","label","legend","li","link","main","map","mark","marquee","menu","menuitem","meta","meter","nav","noscript","object","ol","optgroup","option","output","p","param","picture","pre","progress","q","rp","rt","ruby","s","samp","script","section","select","small","source","span","strong","style","sub","summary","sup","table","tbody","td","textarea","tfoot","th","thead","time","title","tr","track","u","ul","var","video","wbr","circle","clipPath","defs","ellipse","foreignObject","g","image","line","linearGradient","mask","path","pattern","polygon","polyline","radialGradient","rect","stop","svg","text","tspan"].forEach((function(t){Zg[t]=Zg(t)}));var qD={animationIterationCount:1,aspectRatio:1,borderImageOutset:1,borderImageSlice:1,borderImageWidth:1,boxFlex:1,boxFlexGroup:1,boxOrdinalGroup:1,columnCount:1,columns:1,flex:1,flexGrow:1,flexPositive:1,flexShrink:1,flexNegative:1,flexOrder:1,gridRow:1,gridRowEnd:1,gridRowSpan:1,gridRowStart:1,gridColumn:1,gridColumnEnd:1,gridColumnSpan:1,gridColumnStart:1,msGridRow:1,msGridRowSpan:1,msGridColumn:1,msGridColumnSpan:1,fontWeight:1,lineHeight:1,opacity:1,order:1,orphans:1,scale:1,tabSize:1,widows:1,zIndex:1,zoom:1,WebkitLineClamp:1,fillOpacity:1,floodOpacity:1,stopOpacity:1,strokeDasharray:1,strokeDashoffset:1,strokeMiterlimit:1,strokeOpacity:1,strokeWidth:1};function zD(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var HD=/[A-Z]|^ms/g,VD=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Rk=function(t){return t.charCodeAt(1)===45},Pk=function(t){return t!=null&&typeof t!="boolean"},Qg=zD((function(t){return Rk(t)?t:t.replace(HD,"-$&").toLowerCase()})),Ik=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(VD,(function(u,v,O){return ro={name:v,styles:O,next:ro},v}))}return qD[t]===1||Rk(t)||typeof a!="number"||a===0?a:a+"px"};function kl(t,a,u){if(u==null)return"";var v=u;if(v.__emotion_styles!==void 0)return v;switch(typeof u){case"boolean":return"";case"object":var O=u;if(O.anim===1)return ro={name:O.name,styles:O.styles,next:ro},O.name;var A=u;if(A.styles!==void 0){var I=A.next;if(I!==void 0)for(;I!==void 0;)ro={name:I.name,styles:I.styles,next:ro},I=I.next;return A.styles+";"}return(function(T,C,X){var V="";if(Array.isArray(X))for(var $=0;$<X.length;$++)V+=kl(T,C,X[$])+";";else for(var q in X){var H=X[q];if(typeof H!="object"){var G=H;Pk(G)&&(V+=Qg(q)+":"+Ik(q,G)+";")}else if(!Array.isArray(H)||typeof H[0]!="string"||C!=null){var Q=kl(T,C,H);switch(q){case"animation":case"animationName":V+=Qg(q)+":"+Q+";";break;default:V+=q+"{"+Q+"}"}}else for(var ie=0;ie<H.length;ie++)Pk(H[ie])&&(V+=Qg(q)+":"+Ik(q,H[ie])+";")}return V})(t,a,u)}var N=u;return N}var ro,Mk=/label:\s*([^\s;{]+)\s*(;|$)/g;function jk(t,a){return Zg(t,a)}const Lk=[];function ko(t){return Lk[0]=t,(function(a,u,v){if(a.length===1&&typeof a[0]=="object"&&a[0]!==null&&a[0].styles!==void 0)return a[0];var O=!0,A="";ro=void 0;var I=a[0];I==null||I.raw===void 0?(O=!1,A+=kl(v,u,I)):A+=I[0];for(var N=1;N<a.length;N++)A+=kl(v,u,a[N]),O&&(A+=I[N]);Mk.lastIndex=0;for(var T,C="";(T=Mk.exec(A))!==null;)C+="-"+T[1];var X=(function(V){for(var $,q=0,H=0,G=V.length;G>=4;++H,G-=4)$=1540483477*(65535&($=255&V.charCodeAt(H)|(255&V.charCodeAt(++H))<<8|(255&V.charCodeAt(++H))<<16|(255&V.charCodeAt(++H))<<24))+(59797*($>>>16)<<16),q=1540483477*(65535&($^=$>>>24))+(59797*($>>>16)<<16)^1540483477*(65535&q)+(59797*(q>>>16)<<16);switch(G){case 3:q^=(255&V.charCodeAt(H+2))<<16;case 2:q^=(255&V.charCodeAt(H+1))<<8;case 1:q=1540483477*(65535&(q^=255&V.charCodeAt(H)))+(59797*(q>>>16)<<16)}return(((q=1540483477*(65535&(q^=q>>>13))+(59797*(q>>>16)<<16))^q>>>15)>>>0).toString(36)})(A)+C;return{name:X,styles:A,next:ro}})(Lk)}function Dk(t){if(t==null)return!0;for(const a in t)return!1;return!0}var Bk=d(55);function Br(t){if(typeof t!="object"||t===null)return!1;const a=Object.getPrototypeOf(t);return!(a!==null&&a!==Object.prototype&&Object.getPrototypeOf(a)!==null||Symbol.toStringTag in t||Symbol.iterator in t)}function Fk(t){if(s.isValidElement(t)||(0,Bk.iY)(t)||!Br(t))return t;const a={};return Object.keys(t).forEach((u=>{a[u]=Fk(t[u])})),a}function Fn(t,a,u={clone:!0}){const v=u.clone?{...t}:t;return Br(t)&&Br(a)&&Object.keys(a).forEach((O=>{s.isValidElement(a[O])||(0,Bk.iY)(a[O])?v[O]=a[O]:Br(a[O])&&Object.prototype.hasOwnProperty.call(t,O)&&Br(t[O])?v[O]=Fn(t[O],a[O],u):u.clone?v[O]=Br(a[O])?Fk(a[O]):a[O]:v[O]=a[O]})),v}function qk(t){const{values:a={xs:0,sm:600,md:900,lg:1200,xl:1536},unit:u="px",step:v=5,...O}=t,A=(V=>{const $=Object.keys(V).map((q=>({key:q,val:V[q]})))||[];return $.sort(((q,H)=>q.val-H.val)),$.reduce(((q,H)=>({...q,[H.key]:H.val})),{})})(a),I=Object.keys(A);function N(V){return`@media (min-width:${typeof a[V]=="number"?a[V]:V}${u})`}function T(V){return`@media (max-width:${(typeof a[V]=="number"?a[V]:V)-v/100}${u})`}function C(V,$){const q=I.indexOf($);return`@media (min-width:${typeof a[V]=="number"?a[V]:V}${u}) and (max-width:${(q!==-1&&typeof a[I[q]]=="number"?a[I[q]]:$)-v/100}${u})`}const X=[];for(let V=0;V<I.length;V+=1)X.push(N(I[V]));return{keys:I,values:A,up:N,down:T,between:C,only:function(V){return I.indexOf(V)+1<I.length?C(V,I[I.indexOf(V)+1]):N(V)},not:function(V){const $=I.indexOf(V);return $===0?N(I[1]):$===I.length-1?T(I[$]):C(V,I[I.indexOf(V)+1]).replace("@media","@media not all and")},unit:u,internal_mediaKeys:X,...O}}const zk=/min-width:\s*([0-9.]+)/;function Hk(t,a){if(!t.containerQueries||!(function(O){for(const A in O)if(A.startsWith("@container"))return!0;return!1})(a))return a;const u=[];for(const O in a)O.startsWith("@container")&&u.push(O);u.sort(((O,A)=>+(O.match(zk)?.[1]||0)-+(A.match(zk)?.[1]||0)));const v=a;for(let O=0;O<u.length;O+=1){const A=u[O],I=v[A];delete v[A],v[A]=I}return v}function Vk(t,a){return a==="@"||a.startsWith("@")&&(t.some((u=>a.startsWith(`@${u}`)))||!!a.match(/^@\d/))}function UD(t,a){const u=a.match(/^@([^/]+)?\/?(.+)?$/);if(!u)return null;const[,v,O]=u,A=Number.isNaN(+v)?v||0:+v;return t.containerQueries(O).up(A)}const WD={borderRadius:4};function La(t,a){const u=Array.isArray(a),v=Array.isArray(t);return typeof(O=a)!="object"||O===null?a:(function(A){return typeof A!="object"||A===null||A instanceof RegExp||A instanceof Date})(t)?fi(a):u&&v?(function(A,I){const N=A.length;for(let T=0;T<I.length;T+=1)A[N+T]=fi(I[T]);return A})(t,a):u!==v?fi(a):(function(A,I){for(const N in I)A[N]=N in A?La(A[N],I[N]):fi(I[N]);return A})(t,a);var O}function fi(t){return typeof(a=t)!="object"||a===null||a instanceof RegExp||a instanceof Date?t:Array.isArray(t)?(function(u){let v=0;const O=u.length,A=new Array(O);for(v=0;v<O;v+=1)A[v]=fi(u[v]);return A})(t):(function(u){const v={};for(const O in u)v[O]=fi(u[O]);return v})(t);var a}const GD={},Cl={xs:0,sm:600,md:900,lg:1200,xl:1536},Al=qk({values:Cl}),KD={containerQueries:t=>({up:a=>{let u=typeof a=="number"?a:Cl[a]||a;return typeof u=="number"&&(u=`${u}px`),t?`@container ${t} (min-width:${u})`:`@container (min-width:${u})`}})};function di(t,a,u){const v={};return Nl(v,t.theme,a,((O,A,I)=>{const N=u(A,I);O?v[O]=N:La(v,N)}))}function Nl(t,a,u,v){if(a??=GD,Array.isArray(u)){const O=a.breakpoints??Al;for(let A=0;A<u.length;A+=1)Jg(t,O.up(O.keys[A]),u[A],void 0,v);return t}if(typeof u=="object"){const O=a.breakpoints??Al,A=O.values??Cl;for(const I in u)if(Vk(O.keys,I)){const N=UD(a.containerQueries?a:KD,I);N&&Jg(t,N,u[I],I,v)}else if(I in A)Jg(t,O.up(I),u[I],I,v);else{const N=I;t[N]=u[N]}return t}return v(void 0,u),t}function Jg(t,a,u,v,O){t[a]??={},O(a,u,v)}function Uk(t,a){const u=t.internal_mediaKeys;for(let v=0;v<u.length;v+=1){const O=u[v];Dk(a[O])&&delete a[O]}return a}function YD(t,a){if(Array.isArray(a))return!0;if(typeof a=="object"&&a!==null){for(let v=0;v<t.keys.length;v+=1)if(t.keys[v]in a)return!0;const u=Object.keys(a);for(let v=0;v<u.length;v+=1)if(Vk(t.keys,u[v]))return!0}return!1}function Co(t,...a){const u=new URL(`https://mui.com/production-error/?code=${t}`);return a.forEach((v=>u.searchParams.append("args[]",v))),`Minified MUI error #${t}; visit ${u} for the full message.`}function Tl(t){if(typeof t!="string")throw new Error(Co(7));return t.charAt(0).toUpperCase()+t.slice(1)}function Wk(t,a,u,v){let O;return O=typeof t=="function"?t(u):Array.isArray(t)?t[u]||u:typeof u=="string"&&Rl(t,u,!0,v)||u,a&&(O=a(O,u,t)),O}function Rl(t,a,u=!0,v=void 0){if(!t||!a)return null;const O=a.split(".");if(t.vars&&u){const A=Gk(t.vars,O,v);if(A!=null)return A}return Gk(t,O,v)}function Gk(t,a,u=void 0){let v,O=t,A=0;for(;A<a.length;){if(O==null)return O;v=O,O=O[a[A]],A+=1}if(u&&O===void 0){const I=a[a.length-1],N=`${u}${I==="default"?"":Tl(I)}`;return v?.[N]}return O}function Wt(t){const{prop:a,cssProperty:u=t.prop,themeKey:v,transform:O}=t,A=I=>{if(I[a]==null)return null;const N=I[a],T=Rl(I.theme,v)||{};return di(I,N,(C=>{const X=Wk(T,O,C,a);return u===!1?X:{[u]:X}}))};return A.propTypes={},A.filterProps=[a],A}const XD={internal_cache:{}},Pl={m:"margin",p:"padding"},Kk={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Yk={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},Da={};for(const t in Pl)Da[t]=[Pl[t]];for(const t in Pl)for(const a in Kk){const u=Pl[t],v=Kk[a],O=Array.isArray(v)?v.map((A=>u+A)):[u+v];Da[t+a]=O}for(const t in Yk)Da[t]=Da[Yk[t]];const $g=new Set(["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"]),ev=new Set(["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"]);[...$g,...ev];function Ba(t,a,u,v){const O=Rl(t,a,!0)??u;return typeof O=="number"||typeof O=="string"?A=>typeof A=="string"?A:typeof O=="string"?O.startsWith("var(")&&A===0?0:O.startsWith("var(")&&A===1?O:`calc(${A} * ${O})`:O*A:Array.isArray(O)?A=>{if(typeof A=="string")return A;const I=Math.abs(A),N=O[I];return A>=0?N:typeof N=="number"?-N:typeof N=="string"&&N.startsWith("var(")?`calc(-1 * ${N})`:`-${N}`}:typeof O=="function"?O:()=>{}}function tv(t){return Ba(t,"spacing",8)}function Fa(t,a){return typeof a=="string"||a==null?a:t(a)}const Xk=[""];function Zk(t,a){const u=t.theme??XD,v=u?.internal_cache?.unarySpacing??tv(u),O={};for(const A in t){if(!a.has(A))continue;const I=Da[A]??(Xk[0]=A,Xk),N=t[A];Nl(O,t.theme,N,((T,C)=>{const X=T?O[T]:O;for(let V=0;V<I.length;V+=1)X[I[V]]=Fa(v,C)}))}return O}function zt(t){return Zk(t,$g)}function Ht(t){return Zk(t,ev)}function Qk(t=8,a=tv({spacing:t})){if(t.mui)return t;const u=(...v)=>(v.length===0?[1]:v).map((O=>{const A=a(O);return typeof A=="number"?`${A}px`:A})).join(" ");return u.mui=!0,u}zt.propTypes={},zt.filterProps=$g,Ht.propTypes={},Ht.filterProps=ev;const Il=function(...t){const a=t.reduce(((v,O)=>(O.filterProps.forEach((A=>{v[A]=O})),v)),{}),u=v=>{const O={};for(const A in v)a[A]&&La(O,a[A](v));return O};return u.propTypes={},u.filterProps=t.reduce(((v,O)=>v.concat(O.filterProps)),[]),u};function qn(t){return typeof t!="number"?t:`${t}px solid`}function zn(t,a){return Wt({prop:t,themeKey:"borders",transform:a})}const ZD=zn("border",qn),QD=zn("borderTop",qn),JD=zn("borderRight",qn),$D=zn("borderBottom",qn),eB=zn("borderLeft",qn),tB=zn("borderColor"),nB=zn("borderTopColor"),rB=zn("borderRightColor"),oB=zn("borderBottomColor"),iB=zn("borderLeftColor"),aB=zn("outline",qn),sB=zn("outlineColor"),Ml=t=>{if(t.borderRadius!==void 0&&t.borderRadius!==null){const a=Ba(t.theme,"shape.borderRadius",4),u=v=>({borderRadius:Fa(a,v)});return di(t,t.borderRadius,u)}return null};Ml.propTypes={},Ml.filterProps=["borderRadius"],Il(ZD,QD,JD,$D,eB,tB,nB,rB,oB,iB,Ml,aB,sB);const jl=t=>{if(t.gap!==void 0&&t.gap!==null){const a=Ba(t.theme,"spacing",8),u=v=>({gap:Fa(a,v)});return di(t,t.gap,u)}return null};jl.propTypes={},jl.filterProps=["gap"];const Ll=t=>{if(t.columnGap!==void 0&&t.columnGap!==null){const a=Ba(t.theme,"spacing",8),u=v=>({columnGap:Fa(a,v)});return di(t,t.columnGap,u)}return null};Ll.propTypes={},Ll.filterProps=["columnGap"];const Dl=t=>{if(t.rowGap!==void 0&&t.rowGap!==null){const a=Ba(t.theme,"spacing",8),u=v=>({rowGap:Fa(a,v)});return di(t,t.rowGap,u)}return null};function hi(t,a){return a==="grey"?a:t}function Nn(t){return t<=1&&t!==0?100*t+"%":t}Dl.propTypes={},Dl.filterProps=["rowGap"],Il(jl,Ll,Dl,Wt({prop:"gridColumn"}),Wt({prop:"gridRow"}),Wt({prop:"gridAutoFlow"}),Wt({prop:"gridAutoColumns"}),Wt({prop:"gridAutoRows"}),Wt({prop:"gridTemplateColumns"}),Wt({prop:"gridTemplateRows"}),Wt({prop:"gridTemplateAreas"}),Wt({prop:"gridArea"})),Il(Wt({prop:"color",themeKey:"palette",transform:hi}),Wt({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:hi}),Wt({prop:"backgroundColor",themeKey:"palette",transform:hi}));const lB=Wt({prop:"width",transform:Nn}),nv=t=>{if(t.maxWidth!==void 0&&t.maxWidth!==null){const a=u=>{const v=t.theme?.breakpoints?.values?.[u]||Cl[u];return v?t.theme?.breakpoints?.unit!=="px"?{maxWidth:`${v}${t.theme.breakpoints.unit}`}:{maxWidth:v}:{maxWidth:Nn(u)}};return di(t,t.maxWidth,a)}return null};nv.filterProps=["maxWidth"];const uB=Wt({prop:"minWidth",transform:Nn}),cB=Wt({prop:"height",transform:Nn}),fB=Wt({prop:"maxHeight",transform:Nn}),dB=Wt({prop:"minHeight",transform:Nn}),Bl=(Wt({prop:"size",cssProperty:"width",transform:Nn}),Wt({prop:"size",cssProperty:"height",transform:Nn}),Il(lB,nv,uB,cB,fB,dB,Wt({prop:"boxSizing"})),{border:{themeKey:"borders",transform:qn},borderTop:{themeKey:"borders",transform:qn},borderRight:{themeKey:"borders",transform:qn},borderBottom:{themeKey:"borders",transform:qn},borderLeft:{themeKey:"borders",transform:qn},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:qn},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Ml},color:{themeKey:"palette",transform:hi},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:hi},backgroundColor:{themeKey:"palette",transform:hi},p:{style:Ht},pt:{style:Ht},pr:{style:Ht},pb:{style:Ht},pl:{style:Ht},px:{style:Ht},py:{style:Ht},padding:{style:Ht},paddingTop:{style:Ht},paddingRight:{style:Ht},paddingBottom:{style:Ht},paddingLeft:{style:Ht},paddingX:{style:Ht},paddingY:{style:Ht},paddingInline:{style:Ht},paddingInlineStart:{style:Ht},paddingInlineEnd:{style:Ht},paddingBlock:{style:Ht},paddingBlockStart:{style:Ht},paddingBlockEnd:{style:Ht},m:{style:zt},mt:{style:zt},mr:{style:zt},mb:{style:zt},ml:{style:zt},mx:{style:zt},my:{style:zt},margin:{style:zt},marginTop:{style:zt},marginRight:{style:zt},marginBottom:{style:zt},marginLeft:{style:zt},marginX:{style:zt},marginY:{style:zt},marginInline:{style:zt},marginInlineStart:{style:zt},marginInlineEnd:{style:zt},marginBlock:{style:zt},marginBlockStart:{style:zt},marginBlockEnd:{style:zt},displayPrint:{cssProperty:!1,transform:t=>({"@media print":{display:t}})},display:{},overflow:{},textOverflow:{},visibility:{},whiteSpace:{},flexBasis:{},flexDirection:{},flexWrap:{},justifyContent:{},alignItems:{},alignContent:{},order:{},flex:{},flexGrow:{},flexShrink:{},alignSelf:{},justifyItems:{},justifySelf:{},gap:{style:jl},rowGap:{style:Dl},columnGap:{style:Ll},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:Nn},maxWidth:{style:nv},minWidth:{transform:Nn},height:{transform:Nn},maxHeight:{transform:Nn},minHeight:{transform:Nn},boxSizing:{},font:{themeKey:"font"},fontFamily:{themeKey:"typography"},fontSize:{themeKey:"typography"},fontStyle:{themeKey:"typography"},fontWeight:{themeKey:"typography"},letterSpacing:{},textTransform:{},lineHeight:{},textAlign:{},typography:{cssProperty:!1,themeKey:"typography"}}),hB={},pi=(function(){function t(a){if(!a.sx)return null;const{sx:u,theme:v=hB,nested:O}=a,A=v.unstable_sxConfig??Bl,I={sx:null,theme:v,nested:!0};function N(T){let C=T;if(typeof T=="function")C=T(v);else if(typeof T!="object")return T;if(!C)return null;const X=v.breakpoints??Al,V=(function($=Al){const{internal_mediaKeys:q}=$,H={};for(let G=0;G<q.length;G+=1)H[q[G]]={};return H})(X);for(const $ in C){const q=pB(C[$],v);q!=null&&(typeof q=="object"?A[$]?Jk(V,$,q,v,A):YD(X,q)?Nl(V,a.theme,q,((H,G)=>{V[H][$]=G})):(I.sx=q,V[$]=t(I)):Jk(V,$,q,v,A))}return!O&&v.modularCssLayers?{"@layer sx":Hk(v,Uk(X,V))}:Hk(v,Uk(X,V))}return Array.isArray(u)?u.map(N):N(u)}return t.filterProps=["sx"],t})();function Jk(t,a,u,v,O){const A=O[a];if(!A)return void(t[a]=u);if(u==null)return;const{themeKey:I}=A;if(I==="typography"&&u==="inherit")return void(t[a]=u);const{style:N}=A;if(N)return void La(t,N({[a]:u,theme:v}));const{cssProperty:T=a,transform:C}=A,X=Rl(v,I);Nl(t,v,u,((V,$)=>{const q=Wk(X,C,$,a);T===!1?La(V?t[V]:t,q):V?t[V][T]=q:t[T]=q}))}function pB(t,a){return typeof t=="function"?t(a):t}function mB(t,a){const u=this;if(u.vars){if(!u.colorSchemes?.[t]||typeof u.getColorSchemeSelector!="function")return{};let v=u.getColorSchemeSelector(t);return v==="&"?a:((v.includes("data-")||v.includes("."))&&(v=`*:where(${v.replace(/\s*&$/,"")}) &`),{[v]:a})}return u.palette.mode===t?a:{}}const Fl=function(t={},...a){const{breakpoints:u={},palette:v={},spacing:O,shape:A={},...I}=t;let N=Fn({breakpoints:qk(u),direction:"ltr",components:{},palette:{mode:"light",...v},spacing:Qk(O),shape:{...WD,...A}},I);return N=(function(T){const C=(q,H)=>q.replace("@media",H?`@container ${H}`:"@container");function X(q,H){q.up=(...G)=>C(T.breakpoints.up(...G),H),q.down=(...G)=>C(T.breakpoints.down(...G),H),q.between=(...G)=>C(T.breakpoints.between(...G),H),q.only=(...G)=>C(T.breakpoints.only(...G),H),q.not=(...G)=>{const Q=C(T.breakpoints.not(...G),H);return Q.includes("not all and")?Q.replace("not all and ","").replace("min-width:","width<").replace("max-width:","width>").replace("and","or"):Q}}const V={},$=q=>(X(V,q),V);return X($),{...T,containerQueries:$}})(N),N.applyStyles=mB,N=a.reduce(((T,C)=>Fn(T,C)),N),N.unstable_sxConfig={...Bl,...I?.unstable_sxConfig},N.unstable_sx=function(T){return pi({sx:T,theme:this})},N.internal_cache={},N};function $k(t){const{variants:a,...u}=t,v={variants:a,style:ko(u),isProcessed:!0};return v.style===u||a&&a.forEach((O=>{typeof O.style!="function"&&(O.style=ko(O.style))})),v}const gB=Fl();function rv(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function Ao(t,a){return a&&t&&typeof t=="object"&&t.styles&&!t.styles.startsWith("@layer")&&(t.styles=`@layer ${a}{${String(t.styles)}}`),t}function vB(t){return t?(a,u)=>u[t]:null}function ql(t,a,u){const v=typeof a=="function"?a(t):a;if(Array.isArray(v))return v.flatMap((O=>ql(t,O,u)));if(Array.isArray(v?.variants)){let O;if(v.isProcessed)O=u?Ao(v.style,u):v.style;else{const{variants:A,...I}=v;O=u?Ao(ko(I),u):I}return eC(t,v.variants,[O],u)}return v?.isProcessed?u?Ao(ko(v.style),u):v.style:u?Ao(ko(v),u):v}function eC(t,a,u=[],v=void 0){let O;e:for(let A=0;A<a.length;A+=1){const I=a[A];if(typeof I.props=="function"){if(O??={...t,...t.ownerState,ownerState:t.ownerState},!I.props(O))continue}else for(const N in I.props)if(t[N]!==I.props[N]&&t.ownerState?.[N]!==I.props[N])continue e;typeof I.style=="function"?(O??={...t,...t.ownerState,ownerState:t.ownerState},u.push(v?Ao(ko(I.style(O)),v):I.style(O))):u.push(v?Ao(ko(I.style),v):I.style)}return u}function tC(t={}){const{themeId:a,defaultTheme:u=gB,rootShouldForwardProp:v=rv,slotShouldForwardProp:O=rv}=t;function A(I){(function(N,T,C){N.theme=Dk(N.theme)?C:N.theme[T]||N.theme})(I,a,u)}return(I,N={})=>{(function(ve,ye){Array.isArray(ve.__emotion_styles)&&(ve.__emotion_styles=(ce=>ce.filter((Oe=>Oe!==pi)))(ve.__emotion_styles))})(I);const{name:T,slot:C,skipVariantsResolver:X,skipSx:V,overridesResolver:$=vB(yB(C)),...q}=N,H=T&&T.startsWith("Mui")||C?"components":"custom",G=X!==void 0?X:C&&C!=="Root"&&C!=="root"||!1,Q=V||!1;let ie=rv;C==="Root"||C==="root"?ie=v:C?ie=O:(function(ve){return typeof ve=="string"&&ve.charCodeAt(0)>96})(I)&&(ie=void 0);const ue=jk(I,{shouldForwardProp:ie,label:void 0,...q}),fe=ve=>{if(ve.__emotion_real===ve)return ve;if(typeof ve=="function")return function(ye){return ql(ye,ve,ye.theme.modularCssLayers?H:void 0)};if(Br(ve)){const ye=$k(ve);return function(ce){return ye.variants?ql(ce,ye,ce.theme.modularCssLayers?H:void 0):ce.theme.modularCssLayers?Ao(ye.style,H):ye.style}}return ve},me=(...ve)=>{const ye=[],ce=ve.map(fe),Oe=[];if(ye.push(A),T&&$&&Oe.push((function(je){const Ne=je.theme,Te=Ne.components?.[T]?.styleOverrides;if(!Te)return null;const ze={};for(const Le in Te)ze[Le]=ql(je,Te[Le],je.theme.modularCssLayers?"theme":void 0);return $(je,ze)})),T&&!G&&Oe.push((function(je){const Ne=je.theme,Te=Ne?.components?.[T]?.variants;return Te?eC(je,Te,[],je.theme.modularCssLayers?"theme":void 0):null})),Q||Oe.push(pi),Array.isArray(ce[0])){const je=ce.shift(),Ne=new Array(ye.length).fill(""),Te=new Array(Oe.length).fill("");let ze;ze=[...Ne,...je,...Te],ze.raw=[...Ne,...je.raw,...Te],ye.unshift(ze)}const Me=[...ye,...ce,...Oe],_e=ue(...Me);return I.muiName&&(_e.muiName=I.muiName),_e};return ue.withConfig&&(me.withConfig=ue.withConfig),me}}function yB(t){return t&&t.charAt(0).toLowerCase()+t.slice(1)}const bB=function(t,a=Number.MIN_SAFE_INTEGER,u=Number.MAX_SAFE_INTEGER){return Math.max(a,Math.min(t,u))};function ov(t,a=0,u=1){return bB(t,a,u)}function oo(t){if(t.type)return t;if(t.charAt(0)==="#")return oo((function(A){A=A.slice(1);const I=new RegExp(`.{1,${A.length>=6?2:1}}`,"g");let N=A.match(I);return N&&N[0].length===1&&(N=N.map((T=>T+T))),N?`rgb${N.length===4?"a":""}(${N.map(((T,C)=>C<3?parseInt(T,16):Math.round(parseInt(T,16)/255*1e3)/1e3)).join(", ")})`:""})(t));const a=t.indexOf("("),u=t.substring(0,a);if(!["rgb","rgba","hsl","hsla","color"].includes(u))throw new Error(Co(9,t));let v,O=t.substring(a+1,t.length-1);if(u==="color"){if(O=O.split(" "),v=O.shift(),O.length===4&&O[3].charAt(0)==="/"&&(O[3]=O[3].slice(1)),!["srgb","display-p3","a98-rgb","prophoto-rgb","rec-2020"].includes(v))throw new Error(Co(10,v))}else O=O.split(",");return O=O.map((A=>parseFloat(A))),{type:u,values:O,colorSpace:v}}const qa=(t,a)=>{try{return(u=>{const v=oo(u);return v.values.slice(0,3).map(((O,A)=>v.type.includes("hsl")&&A!==0?`${O}%`:O)).join(" ")})(t)}catch{return t}};function zl(t){const{type:a,colorSpace:u}=t;let{values:v}=t;return a.includes("rgb")?v=v.map(((O,A)=>A<3?parseInt(O,10):O)):a.includes("hsl")&&(v[1]=`${v[1]}%`,v[2]=`${v[2]}%`),v=a.includes("color")?`${u} ${v.join(" ")}`:`${v.join(", ")}`,`${a}(${v})`}function nC(t){t=oo(t);const{values:a}=t,u=a[0],v=a[1]/100,O=a[2]/100,A=v*Math.min(O,1-O),I=(C,X=(C+u/30)%12)=>O-A*Math.max(Math.min(X-3,9-X,1),-1);let N="rgb";const T=[Math.round(255*I(0)),Math.round(255*I(8)),Math.round(255*I(4))];return t.type==="hsla"&&(N+="a",T.push(a[3])),zl({type:N,values:T})}function iv(t){let a=(t=oo(t)).type==="hsl"||t.type==="hsla"?oo(nC(t)).values:t.values;return a=a.map((u=>(t.type!=="color"&&(u/=255),u<=.03928?u/12.92:((u+.055)/1.055)**2.4))),Number((.2126*a[0]+.7152*a[1]+.0722*a[2]).toFixed(3))}function Hl(t,a){return t=oo(t),a=ov(a),t.type!=="rgb"&&t.type!=="hsl"||(t.type+="a"),t.type==="color"?t.values[3]=`/${a}`:t.values[3]=a,zl(t)}function No(t,a,u){try{return Hl(t,a)}catch{return t}}function Vl(t,a){if(t=oo(t),a=ov(a),t.type.includes("hsl"))t.values[2]*=1-a;else if(t.type.includes("rgb")||t.type.includes("color"))for(let u=0;u<3;u+=1)t.values[u]*=1-a;return zl(t)}function xt(t,a,u){try{return Vl(t,a)}catch{return t}}function Ul(t,a){if(t=oo(t),a=ov(a),t.type.includes("hsl"))t.values[2]+=(100-t.values[2])*a;else if(t.type.includes("rgb"))for(let u=0;u<3;u+=1)t.values[u]+=(255-t.values[u])*a;else if(t.type.includes("color"))for(let u=0;u<3;u+=1)t.values[u]+=(1-t.values[u])*a;return zl(t)}function _t(t,a,u){try{return Ul(t,a)}catch{return t}}function Wl(t,a,u){try{return(function(v,O=.15){return iv(v)>.5?Vl(v,O):Ul(v,O)})(t,a)}catch{return t}}const za={black:"#000",white:"#fff"},wB={50:"#fafafa",100:"#f5f5f5",200:"#eeeeee",300:"#e0e0e0",400:"#bdbdbd",500:"#9e9e9e",600:"#757575",700:"#616161",800:"#424242",900:"#212121",A100:"#f5f5f5",A200:"#eeeeee",A400:"#bdbdbd",A700:"#616161"},mi={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},gi={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},Ha={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},vi={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},yi={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},bi={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function rC(){return{text:{primary:"rgba(0, 0, 0, 0.87)",secondary:"rgba(0, 0, 0, 0.6)",disabled:"rgba(0, 0, 0, 0.38)"},divider:"rgba(0, 0, 0, 0.12)",background:{paper:za.white,default:za.white},action:{active:"rgba(0, 0, 0, 0.54)",hover:"rgba(0, 0, 0, 0.04)",hoverOpacity:.04,selected:"rgba(0, 0, 0, 0.08)",selectedOpacity:.08,disabled:"rgba(0, 0, 0, 0.26)",disabledBackground:"rgba(0, 0, 0, 0.12)",disabledOpacity:.38,focus:"rgba(0, 0, 0, 0.12)",focusOpacity:.12,activatedOpacity:.12}}}const oC=rC();function iC(){return{text:{primary:za.white,secondary:"rgba(255, 255, 255, 0.7)",disabled:"rgba(255, 255, 255, 0.5)",icon:"rgba(255, 255, 255, 0.5)"},divider:"rgba(255, 255, 255, 0.12)",background:{paper:"#121212",default:"#121212"},action:{active:za.white,hover:"rgba(255, 255, 255, 0.08)",hoverOpacity:.08,selected:"rgba(255, 255, 255, 0.16)",selectedOpacity:.16,disabled:"rgba(255, 255, 255, 0.3)",disabledBackground:"rgba(255, 255, 255, 0.12)",disabledOpacity:.38,focus:"rgba(255, 255, 255, 0.12)",focusOpacity:.12,activatedOpacity:.24}}}const av=iC();function aC(t,a,u,v){const O=v.light||v,A=v.dark||1.5*v;t[a]||(t.hasOwnProperty(u)?t[a]=t[u]:a==="light"?t.light=Ul(t.main,O):a==="dark"&&(t.dark=Vl(t.main,A)))}function sC(t,a,u,v,O){const A=O.light||O,I=O.dark||1.5*O;a[u]||(a.hasOwnProperty(v)?a[u]=a[v]:u==="light"?a.light=`color-mix(in ${t}, ${a.main}, #fff ${(100*A).toFixed(0)}%)`:u==="dark"&&(a.dark=`color-mix(in ${t}, ${a.main}, #000 ${(100*I).toFixed(0)}%)`))}function sv(t){const{mode:a="light",contrastThreshold:u=3,tonalOffset:v=.2,colorSpace:O,...A}=t,I=t.primary||(function(G="light"){return G==="dark"?{main:vi[200],light:vi[50],dark:vi[400]}:{main:vi[700],light:vi[400],dark:vi[800]}})(a),N=t.secondary||(function(G="light"){return G==="dark"?{main:mi[200],light:mi[50],dark:mi[400]}:{main:mi[500],light:mi[300],dark:mi[700]}})(a),T=t.error||(function(G="light"){return G==="dark"?{main:gi[500],light:gi[300],dark:gi[700]}:{main:gi[700],light:gi[400],dark:gi[800]}})(a),C=t.info||(function(G="light"){return G==="dark"?{main:yi[400],light:yi[300],dark:yi[700]}:{main:yi[700],light:yi[500],dark:yi[900]}})(a),X=t.success||(function(G="light"){return G==="dark"?{main:bi[400],light:bi[300],dark:bi[700]}:{main:bi[800],light:bi[500],dark:bi[900]}})(a),V=t.warning||(function(G="light"){return G==="dark"?{main:Ha[400],light:Ha[300],dark:Ha[700]}:{main:"#ed6c02",light:Ha[500],dark:Ha[900]}})(a);function $(G){return O?(function(ie){return`oklch(from ${ie} var(--__l) 0 h / var(--__a))`})(G):(function(ie,ue){const fe=iv(ie),me=iv(ue);return(Math.max(fe,me)+.05)/(Math.min(fe,me)+.05)})(G,av.text.primary)>=u?av.text.primary:oC.text.primary}const q=({color:G,name:Q,mainShade:ie=500,lightShade:ue=300,darkShade:fe=700})=>{if(!(G={...G}).main&&G[ie]&&(G.main=G[ie]),!G.hasOwnProperty("main"))throw new Error(Co(11,Q?` (${Q})`:"",ie));if(typeof G.main!="string")throw new Error(Co(12,Q?` (${Q})`:"",JSON.stringify(G.main)));return O?(sC(O,G,"light",ue,v),sC(O,G,"dark",fe,v)):(aC(G,"light",ue,v),aC(G,"dark",fe,v)),G.contrastText||(G.contrastText=$(G.main)),G};let H;return a==="light"?H=rC():a==="dark"&&(H=iC()),Fn({common:{...za},mode:a,primary:q({color:I,name:"primary"}),secondary:q({color:N,name:"secondary",mainShade:"A400",lightShade:"A200",darkShade:"A700"}),error:q({color:T,name:"error"}),warning:q({color:V,name:"warning"}),info:q({color:C,name:"info"}),success:q({color:X,name:"success"}),grey:wB,contrastThreshold:u,getContrastText:$,augmentColor:q,tonalOffset:v,...H},A)}function xB(t=""){function a(...u){if(!u.length)return"";const v=u[0];return typeof v!="string"||v.match(/(#|\(|\)|(-?(\d*\.)?\d+)(px|em|%|ex|ch|rem|vw|vh|vmin|vmax|cm|mm|in|pt|pc))|^(-?(\d*\.)?\d+)$|(\d+ \d+ \d+)/)?`, ${v}`:`, var(--${t?`${t}-`:""}${v}${a(...u.slice(1))})`}return(u,...v)=>`var(--${t?`${t}-`:""}${u}${a(...v)})`}function _B(t){const a={};return Object.entries(t).forEach((u=>{const[v,O]=u;typeof O=="object"&&(a[v]=`${O.fontStyle?`${O.fontStyle} `:""}${O.fontVariant?`${O.fontVariant} `:""}${O.fontWeight?`${O.fontWeight} `:""}${O.fontStretch?`${O.fontStretch} `:""}${O.fontSize||""}${O.lineHeight?`/${O.lineHeight} `:""}${O.fontFamily||""}`)})),a}const lC=(t,a,u,v=[])=>{let O=t;a.forEach(((A,I)=>{I===a.length-1?Array.isArray(O)?O[Number(A)]=u:O&&typeof O=="object"&&(O[A]=u):O&&typeof O=="object"&&(O[A]||(O[A]=v.includes(A)?[]:{}),O=O[A])}))};function lv(t,a){const{prefix:u,shouldSkipGeneratingVar:v}=a||{},O={},A={},I={};return N=(C,X,V)=>{if(!(typeof X!="string"&&typeof X!="number"||v&&v(C,X))){const $=`--${u?`${u}-`:""}${C.join("-")}`,q=((H,G)=>typeof G=="number"?["lineHeight","fontWeight","opacity","zIndex"].some((Q=>H.includes(Q)))||H[H.length-1].toLowerCase().includes("opacity")?G:`${G}px`:G)(C,X);Object.assign(O,{[$]:q}),lC(A,C,`var(${$})`,V),lC(I,C,`var(${$}, ${q})`,V)}},T=C=>C[0]==="vars",(function C(X,V=[],$=[]){Object.entries(X).forEach((([q,H])=>{(!T||T&&!T([...V,q]))&&H!=null&&(typeof H=="object"&&Object.keys(H).length>0?C(H,[...V,q],Array.isArray(H)?[...$,q]:$):N([...V,q],H,$))}))})(t),{css:O,vars:A,varsWithDefaults:I};var N,T}const uC={textTransform:"uppercase"},cC='"Roboto", "Helvetica", "Arial", sans-serif';function SB(t,a){const{fontFamily:u=cC,fontSize:v=14,fontWeightLight:O=300,fontWeightRegular:A=400,fontWeightMedium:I=500,fontWeightBold:N=700,htmlFontSize:T=16,allVariants:C,pxToRem:X,...V}=typeof a=="function"?a(t):a,$=v/14,q=X||(Q=>Q/T*$+"rem"),H=(Q,ie,ue,fe,me)=>{return{fontFamily:u,fontWeight:Q,fontSize:q(ie),lineHeight:ue,...u===cC?{letterSpacing:(ve=fe/ie,Math.round(1e5*ve)/1e5+"em")}:{},...me,...C};var ve},G={h1:H(O,96,1.167,-1.5),h2:H(O,60,1.2,-.5),h3:H(A,48,1.167,0),h4:H(A,34,1.235,.25),h5:H(A,24,1.334,0),h6:H(I,20,1.6,.15),subtitle1:H(A,16,1.75,.15),subtitle2:H(I,14,1.57,.1),body1:H(A,16,1.5,.15),body2:H(A,14,1.43,.15),button:H(I,14,1.75,.4,uC),caption:H(A,12,1.66,.4),overline:H(A,12,2.66,1,uC),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Fn({htmlFontSize:T,pxToRem:q,fontFamily:u,fontSize:v,fontWeightLight:O,fontWeightRegular:A,fontWeightMedium:I,fontWeightBold:N,...G},V,{clone:!1})}function Bt(...t){return[`${t[0]}px ${t[1]}px ${t[2]}px ${t[3]}px rgba(0,0,0,0.2)`,`${t[4]}px ${t[5]}px ${t[6]}px ${t[7]}px rgba(0,0,0,0.14)`,`${t[8]}px ${t[9]}px ${t[10]}px ${t[11]}px rgba(0,0,0,0.12)`].join(",")}const EB=["none",Bt(0,2,1,-1,0,1,1,0,0,1,3,0),Bt(0,3,1,-2,0,2,2,0,0,1,5,0),Bt(0,3,3,-2,0,3,4,0,0,1,8,0),Bt(0,2,4,-1,0,4,5,0,0,1,10,0),Bt(0,3,5,-1,0,5,8,0,0,1,14,0),Bt(0,3,5,-1,0,6,10,0,0,1,18,0),Bt(0,4,5,-2,0,7,10,1,0,2,16,1),Bt(0,5,5,-3,0,8,10,1,0,3,14,2),Bt(0,5,6,-3,0,9,12,1,0,3,16,2),Bt(0,6,6,-3,0,10,14,1,0,4,18,3),Bt(0,6,7,-4,0,11,15,1,0,4,20,3),Bt(0,7,8,-4,0,12,17,2,0,5,22,4),Bt(0,7,8,-4,0,13,19,2,0,5,24,4),Bt(0,7,9,-4,0,14,21,2,0,5,26,4),Bt(0,8,9,-5,0,15,22,2,0,6,28,5),Bt(0,8,10,-5,0,16,24,2,0,6,30,5),Bt(0,8,11,-5,0,17,26,2,0,6,32,5),Bt(0,9,11,-5,0,18,28,2,0,7,34,6),Bt(0,9,12,-6,0,19,29,2,0,7,36,6),Bt(0,10,13,-6,0,20,31,3,0,8,38,7),Bt(0,10,13,-6,0,21,33,3,0,8,40,7),Bt(0,10,14,-6,0,22,35,3,0,8,42,7),Bt(0,11,14,-7,0,23,36,3,0,9,44,8),Bt(0,11,15,-7,0,24,38,3,0,9,46,8)],OB={easeInOut:"cubic-bezier(0.4, 0, 0.2, 1)",easeOut:"cubic-bezier(0.0, 0, 0.2, 1)",easeIn:"cubic-bezier(0.4, 0, 1, 1)",sharp:"cubic-bezier(0.4, 0, 0.6, 1)"},kB={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function fC(t){return`${Math.round(t)}ms`}function CB(t){if(!t)return 0;const a=t/36;return Math.min(Math.round(10*(4+15*a**.25+a/5)),3e3)}function AB(t){const a={...OB,...t.easing},u={...kB,...t.duration};return{getAutoHeightDuration:CB,create:(v=["all"],O={})=>{const{duration:A=u.standard,easing:I=a.easeInOut,delay:N=0,...T}=O;return(Array.isArray(v)?v:[v]).map((C=>`${C} ${typeof A=="string"?A:fC(A)} ${I} ${typeof N=="string"?N:fC(N)}`)).join(",")},...t,easing:a,duration:u}}const NB={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function dC(t={}){const a={...t};return(function u(v){const O=Object.entries(v);for(let I=0;I<O.length;I++){const[N,T]=O[I];!Br(A=T)&&A!==void 0&&typeof A!="string"&&typeof A!="boolean"&&typeof A!="number"&&!Array.isArray(A)||N.startsWith("unstable_")||N.startsWith("internal_")?delete v[N]:Br(T)&&(v[N]={...T},u(v[N]))}var A})(a),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
20
|
+
|
|
21
|
+
const theme = ${JSON.stringify(a,null,2)};
|
|
22
|
+
|
|
23
|
+
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
24
|
+
theme.transitions = createTransitions(theme.transitions || {});
|
|
25
|
+
|
|
26
|
+
export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFixed(0)}%`:`calc((${t}) * 100%)`}const uv=function(t={},...a){const{breakpoints:u,mixins:v={},spacing:O,palette:A={},transitions:I={},typography:N={},shape:T,colorSpace:C,...X}=t;if(t.vars&&t.generateThemeVars===void 0)throw new Error(Co(22));const V=sv({...A,colorSpace:C}),$=Fl(t);let q=Fn($,{mixins:(H=$.breakpoints,G=v,{toolbar:{minHeight:56,[H.up("xs")]:{"@media (orientation: landscape)":{minHeight:48}},[H.up("sm")]:{minHeight:64}},...G}),palette:V,shadows:EB.slice(),typography:SB(V,N),transitions:AB(I),zIndex:{...NB}});var H,G,Q;return q=Fn(q,X),q=a.reduce(((ie,ue)=>Fn(ie,ue)),q),q.unstable_sxConfig={...Bl,...X?.unstable_sxConfig},q.unstable_sx=function(ie){return pi({sx:ie,theme:this})},q.toRuntimeSource=dC,Q=q,Object.assign(Q,{alpha(ie,ue){const fe=this||Q;return fe.colorSpace?`oklch(from ${ie} l c h / ${typeof ue=="string"?`calc(${ue})`:ue})`:fe.vars?`rgba(${ie.replace(/var\(--([^,\s)]+)(?:,[^)]+)?\)+/g,"var(--$1Channel)")} / ${typeof ue=="string"?`calc(${ue})`:ue})`:Hl(ie,(me=>{if(!Number.isNaN(+me))return+me;const ve=me.match(/\d*\.?\d+/g);if(!ve)return 0;let ye=0;for(let ce=0;ce<ve.length;ce+=1)ye+=+ve[ce];return ye})(ue))},lighten(ie,ue){const fe=this||Q;return fe.colorSpace?`color-mix(in ${fe.colorSpace}, ${ie}, #fff ${hC(ue)})`:Ul(ie,ue)},darken(ie,ue){const fe=this||Q;return fe.colorSpace?`color-mix(in ${fe.colorSpace}, ${ie}, #000 ${hC(ue)})`:Vl(ie,ue)}}),q};function cv(t){let a;return a=t<1?5.11916*t**2:4.5*Math.log(t+1)+2,Math.round(10*a)/1e3}const TB=[...Array(25)].map(((t,a)=>{if(a===0)return"none";const u=cv(a);return`linear-gradient(rgba(255 255 255 / ${u}), rgba(255 255 255 / ${u}))`}));function pC(t){return{inputPlaceholder:t==="dark"?.5:.42,inputUnderline:t==="dark"?.7:.42,switchTrackDisabled:t==="dark"?.2:.12,switchTrack:t==="dark"?.3:.38}}function mC(t){return t==="dark"?TB:[]}function RB(t){return!!t[0].match(/(cssVarPrefix|colorSchemeSelector|modularCssLayers|rootSelector|typography|mixins|breakpoints|direction|transitions)/)||!!t[0].match(/sxConfig$/)||t[0]==="palette"&&!!t[1]?.match(/(mode|contrastThreshold|tonalOffset)/)}const PB=t=>(a,u)=>{const v=t.rootSelector||":root",O=t.colorSchemeSelector;let A=O;if(O==="class"&&(A=".%s"),O==="data"&&(A="[data-%s]"),O?.startsWith("data-")&&!O.includes("%s")&&(A=`[${O}="%s"]`),t.defaultColorScheme===a){if(a==="dark"){const N={};return(I=t.cssVarPrefix,[...[...Array(25)].map(((T,C)=>`--${I?`${I}-`:""}overlays-${C}`)),`--${I?`${I}-`:""}palette-AppBar-darkBg`,`--${I?`${I}-`:""}palette-AppBar-darkColor`]).forEach((T=>{N[T]=u[T],delete u[T]})),A==="media"?{[v]:u,"@media (prefers-color-scheme: dark)":{[v]:N}}:A?{[A.replace("%s",a)]:N,[`${v}, ${A.replace("%s",a)}`]:u}:{[v]:{...u,...N}}}if(A&&A!=="media")return`${v}, ${A.replace("%s",String(a))}`}else if(a){if(A==="media")return{[`@media (prefers-color-scheme: ${String(a)})`]:{[v]:u}};if(A)return A.replace("%s",String(a))}var I;return v};function Se(t,a,u){!t[a]&&u&&(t[a]=u)}function Va(t){return typeof t=="string"&&t.startsWith("hsl")?nC(t):t}function Fr(t,a){`${a}Channel`in t||(t[`${a}Channel`]=qa(Va(t[a])))}const br=t=>{try{return t()}catch{}};function fv(t,a,u,v,O){if(!u)return;u=u===!0?{}:u;const A=O==="dark"?"dark":"light";if(!v)return void(a[O]=(function(T){const{palette:C={mode:"light"},opacity:X,overlays:V,colorSpace:$,...q}=T,H=sv({...C,colorSpace:$});return{palette:H,opacity:{...pC(H.mode),...X},overlays:V||mC(H.mode),...q}})({...u,palette:{mode:A,...u?.palette},colorSpace:t}));const{palette:I,...N}=uv({...v,palette:{mode:A,...u?.palette},colorSpace:t});return a[O]={...u,palette:I,opacity:{...pC(A),...u?.opacity},overlays:u?.overlays||mC(A)},N}function gC(t,a,u){t.colorSchemes&&u&&(t.colorSchemes[a]={...u!==!0&&u,palette:sv({...u===!0?{}:u.palette,mode:a})})}function vC(t={},...a){const{palette:u,cssVariables:v=!1,colorSchemes:O=u?void 0:{light:!0},defaultColorScheme:A=u?.mode,...I}=t,N=A||"light",T=O?.[N],C={...O,...u?{[N]:{...typeof T!="boolean"&&T,palette:u}}:void 0};if(v===!1){if(!("colorSchemes"in t))return uv(t,...a);let X=u;"palette"in t||C[N]&&(C[N]!==!0?X=C[N].palette:N==="dark"&&(X={mode:"dark"}));const V=uv({...t,palette:X},...a);return V.defaultColorScheme=N,V.colorSchemes=C,V.palette.mode==="light"&&(V.colorSchemes.light={...C.light!==!0&&C.light,palette:V.palette},gC(V,"dark",C.dark)),V.palette.mode==="dark"&&(V.colorSchemes.dark={...C.dark!==!0&&C.dark,palette:V.palette},gC(V,"light",C.light)),V}return u||"light"in C||N!=="light"||(C.light=!0),(function(X={},...V){const{colorSchemes:$={light:!0},defaultColorScheme:q,disableCssColorScheme:H=!1,cssVarPrefix:G="mui",nativeColor:Q=!1,shouldSkipGeneratingVar:ie=RB,colorSchemeSelector:ue=$.light&&$.dark?"media":void 0,rootSelector:fe=":root",...me}=X,ve=Object.keys($)[0],ye=q||($.light&&ve!=="light"?"light":ve),ce=((Xe="mui")=>xB(Xe))(G),{[ye]:Oe,light:Me,dark:_e,...je}=$,Ne={...je};let Te,ze=Oe;if((ye==="dark"&&!("dark"in $)||ye==="light"&&!("light"in $))&&(ze=!0),!ze)throw new Error(Co(21,ye));Q&&(Te="oklch");const Le=fv(Te,Ne,ze,me,ye);Me&&!Ne.light&&fv(Te,Ne,Me,void 0,"light"),_e&&!Ne.dark&&fv(Te,Ne,_e,void 0,"dark");let ke={defaultColorScheme:ye,...Le,cssVarPrefix:G,colorSchemeSelector:ue,rootSelector:fe,getCssVar:ce,colorSchemes:Ne,font:{..._B(Le.typography),...Le.font},spacing:(Ke=me.spacing,typeof Ke=="number"?`${Ke}px`:typeof Ke=="string"||typeof Ke=="function"||Array.isArray(Ke)?Ke:"8px")};var Ke;Object.keys(ke.colorSchemes).forEach((Xe=>{const le=ke.colorSchemes[Xe].palette,qe=it=>{const at=it.split("-"),bt=at[1],kt=at[2];return ce(it,le[bt][kt])};function Ie(it,at,bt){if(Te){let kt;return it===No&&(kt=`transparent ${(100*(1-bt)).toFixed(0)}%`),it===xt&&(kt=`#000 ${(100*bt).toFixed(0)}%`),it===_t&&(kt=`#fff ${(100*bt).toFixed(0)}%`),`color-mix(in ${Te}, ${at}, ${kt})`}return it(at,bt)}if(le.mode==="light"&&(Se(le.common,"background","#fff"),Se(le.common,"onBackground","#000")),le.mode==="dark"&&(Se(le.common,"background","#000"),Se(le.common,"onBackground","#fff")),Ye=le,["Alert","AppBar","Avatar","Button","Chip","FilledInput","LinearProgress","Skeleton","Slider","SnackbarContent","SpeedDialAction","StepConnector","StepContent","Switch","TableCell","Tooltip"].forEach((it=>{Ye[it]||(Ye[it]={})})),le.mode==="light"){Se(le.Alert,"errorColor",Ie(xt,Q?ce("palette-error-light"):le.error.light,.6)),Se(le.Alert,"infoColor",Ie(xt,Q?ce("palette-info-light"):le.info.light,.6)),Se(le.Alert,"successColor",Ie(xt,Q?ce("palette-success-light"):le.success.light,.6)),Se(le.Alert,"warningColor",Ie(xt,Q?ce("palette-warning-light"):le.warning.light,.6)),Se(le.Alert,"errorFilledBg",qe("palette-error-main")),Se(le.Alert,"infoFilledBg",qe("palette-info-main")),Se(le.Alert,"successFilledBg",qe("palette-success-main")),Se(le.Alert,"warningFilledBg",qe("palette-warning-main")),Se(le.Alert,"errorFilledColor",br((()=>le.getContrastText(le.error.main)))),Se(le.Alert,"infoFilledColor",br((()=>le.getContrastText(le.info.main)))),Se(le.Alert,"successFilledColor",br((()=>le.getContrastText(le.success.main)))),Se(le.Alert,"warningFilledColor",br((()=>le.getContrastText(le.warning.main)))),Se(le.Alert,"errorStandardBg",Ie(_t,Q?ce("palette-error-light"):le.error.light,.9)),Se(le.Alert,"infoStandardBg",Ie(_t,Q?ce("palette-info-light"):le.info.light,.9)),Se(le.Alert,"successStandardBg",Ie(_t,Q?ce("palette-success-light"):le.success.light,.9)),Se(le.Alert,"warningStandardBg",Ie(_t,Q?ce("palette-warning-light"):le.warning.light,.9)),Se(le.Alert,"errorIconColor",qe("palette-error-main")),Se(le.Alert,"infoIconColor",qe("palette-info-main")),Se(le.Alert,"successIconColor",qe("palette-success-main")),Se(le.Alert,"warningIconColor",qe("palette-warning-main")),Se(le.AppBar,"defaultBg",qe("palette-grey-100")),Se(le.Avatar,"defaultBg",qe("palette-grey-400")),Se(le.Button,"inheritContainedBg",qe("palette-grey-300")),Se(le.Button,"inheritContainedHoverBg",qe("palette-grey-A100")),Se(le.Chip,"defaultBorder",qe("palette-grey-400")),Se(le.Chip,"defaultAvatarColor",qe("palette-grey-700")),Se(le.Chip,"defaultIconColor",qe("palette-grey-700")),Se(le.FilledInput,"bg","rgba(0, 0, 0, 0.06)"),Se(le.FilledInput,"hoverBg","rgba(0, 0, 0, 0.09)"),Se(le.FilledInput,"disabledBg","rgba(0, 0, 0, 0.12)"),Se(le.LinearProgress,"primaryBg",Ie(_t,Q?ce("palette-primary-main"):le.primary.main,.62)),Se(le.LinearProgress,"secondaryBg",Ie(_t,Q?ce("palette-secondary-main"):le.secondary.main,.62)),Se(le.LinearProgress,"errorBg",Ie(_t,Q?ce("palette-error-main"):le.error.main,.62)),Se(le.LinearProgress,"infoBg",Ie(_t,Q?ce("palette-info-main"):le.info.main,.62)),Se(le.LinearProgress,"successBg",Ie(_t,Q?ce("palette-success-main"):le.success.main,.62)),Se(le.LinearProgress,"warningBg",Ie(_t,Q?ce("palette-warning-light"):le.warning.main,.62)),Se(le.Skeleton,"bg",Te?Ie(No,Q?ce("palette-text-primary"):le.text.primary,.11):`rgba(${qe("palette-text-primaryChannel")} / 0.11)`),Se(le.Slider,"primaryTrack",Ie(_t,Q?ce("palette-primary-main"):le.primary.main,.62)),Se(le.Slider,"secondaryTrack",Ie(_t,Q?ce("palette-secondary-main"):le.secondary.main,.62)),Se(le.Slider,"errorTrack",Ie(_t,Q?ce("palette-error-main"):le.error.main,.62)),Se(le.Slider,"infoTrack",Ie(_t,Q?ce("palette-info-main"):le.info.main,.62)),Se(le.Slider,"successTrack",Ie(_t,Q?ce("palette-success-main"):le.success.main,.62)),Se(le.Slider,"warningTrack",Ie(_t,Q?ce("palette-warning-main"):le.warning.main,.62));const it=Te?Ie(xt,Q?ce("palette-background-default"):le.background.default,.6825):Wl(le.background.default,.8);Se(le.SnackbarContent,"bg",it),Se(le.SnackbarContent,"color",br((()=>Te?av.text.primary:le.getContrastText(it)))),Se(le.SpeedDialAction,"fabHoverBg",Wl(le.background.paper,.15)),Se(le.StepConnector,"border",qe("palette-grey-400")),Se(le.StepContent,"border",qe("palette-grey-400")),Se(le.Switch,"defaultColor",qe("palette-common-white")),Se(le.Switch,"defaultDisabledColor",qe("palette-grey-100")),Se(le.Switch,"primaryDisabledColor",Ie(_t,Q?ce("palette-primary-main"):le.primary.main,.62)),Se(le.Switch,"secondaryDisabledColor",Ie(_t,Q?ce("palette-secondary-main"):le.secondary.main,.62)),Se(le.Switch,"errorDisabledColor",Ie(_t,Q?ce("palette-error-main"):le.error.main,.62)),Se(le.Switch,"infoDisabledColor",Ie(_t,Q?ce("palette-info-main"):le.info.main,.62)),Se(le.Switch,"successDisabledColor",Ie(_t,Q?ce("palette-success-main"):le.success.main,.62)),Se(le.Switch,"warningDisabledColor",Ie(_t,Q?ce("palette-warning-main"):le.warning.main,.62)),Se(le.TableCell,"border",Ie(_t,No(Q?ce("palette-divider"):le.divider,1),.88)),Se(le.Tooltip,"bg",Ie(No,Q?ce("palette-grey-700"):le.grey[700],.92))}var Ye;if(le.mode==="dark"){Se(le.Alert,"errorColor",Ie(_t,Q?ce("palette-error-light"):le.error.light,.6)),Se(le.Alert,"infoColor",Ie(_t,Q?ce("palette-info-light"):le.info.light,.6)),Se(le.Alert,"successColor",Ie(_t,Q?ce("palette-success-light"):le.success.light,.6)),Se(le.Alert,"warningColor",Ie(_t,Q?ce("palette-warning-light"):le.warning.light,.6)),Se(le.Alert,"errorFilledBg",qe("palette-error-dark")),Se(le.Alert,"infoFilledBg",qe("palette-info-dark")),Se(le.Alert,"successFilledBg",qe("palette-success-dark")),Se(le.Alert,"warningFilledBg",qe("palette-warning-dark")),Se(le.Alert,"errorFilledColor",br((()=>le.getContrastText(le.error.dark)))),Se(le.Alert,"infoFilledColor",br((()=>le.getContrastText(le.info.dark)))),Se(le.Alert,"successFilledColor",br((()=>le.getContrastText(le.success.dark)))),Se(le.Alert,"warningFilledColor",br((()=>le.getContrastText(le.warning.dark)))),Se(le.Alert,"errorStandardBg",Ie(xt,Q?ce("palette-error-light"):le.error.light,.9)),Se(le.Alert,"infoStandardBg",Ie(xt,Q?ce("palette-info-light"):le.info.light,.9)),Se(le.Alert,"successStandardBg",Ie(xt,Q?ce("palette-success-light"):le.success.light,.9)),Se(le.Alert,"warningStandardBg",Ie(xt,Q?ce("palette-warning-light"):le.warning.light,.9)),Se(le.Alert,"errorIconColor",qe("palette-error-main")),Se(le.Alert,"infoIconColor",qe("palette-info-main")),Se(le.Alert,"successIconColor",qe("palette-success-main")),Se(le.Alert,"warningIconColor",qe("palette-warning-main")),Se(le.AppBar,"defaultBg",qe("palette-grey-900")),Se(le.AppBar,"darkBg",qe("palette-background-paper")),Se(le.AppBar,"darkColor",qe("palette-text-primary")),Se(le.Avatar,"defaultBg",qe("palette-grey-600")),Se(le.Button,"inheritContainedBg",qe("palette-grey-800")),Se(le.Button,"inheritContainedHoverBg",qe("palette-grey-700")),Se(le.Chip,"defaultBorder",qe("palette-grey-700")),Se(le.Chip,"defaultAvatarColor",qe("palette-grey-300")),Se(le.Chip,"defaultIconColor",qe("palette-grey-300")),Se(le.FilledInput,"bg","rgba(255, 255, 255, 0.09)"),Se(le.FilledInput,"hoverBg","rgba(255, 255, 255, 0.13)"),Se(le.FilledInput,"disabledBg","rgba(255, 255, 255, 0.12)"),Se(le.LinearProgress,"primaryBg",Ie(xt,Q?ce("palette-primary-main"):le.primary.main,.5)),Se(le.LinearProgress,"secondaryBg",Ie(xt,Q?ce("palette-secondary-main"):le.secondary.main,.5)),Se(le.LinearProgress,"errorBg",Ie(xt,Q?ce("palette-error-main"):le.error.main,.5)),Se(le.LinearProgress,"infoBg",Ie(xt,Q?ce("palette-info-main"):le.info.main,.5)),Se(le.LinearProgress,"successBg",Ie(xt,Q?ce("palette-success-main"):le.success.main,.5)),Se(le.LinearProgress,"warningBg",Ie(xt,Q?ce("palette-warning-main"):le.warning.main,.5)),Se(le.Skeleton,"bg",Te?Ie(No,Q?ce("palette-text-primary"):le.text.primary,.13):`rgba(${qe("palette-text-primaryChannel")} / 0.13)`),Se(le.Slider,"primaryTrack",Ie(xt,Q?ce("palette-primary-main"):le.primary.main,.5)),Se(le.Slider,"secondaryTrack",Ie(xt,Q?ce("palette-secondary-main"):le.secondary.main,.5)),Se(le.Slider,"errorTrack",Ie(xt,Q?ce("palette-error-main"):le.error.main,.5)),Se(le.Slider,"infoTrack",Ie(xt,Q?ce("palette-info-main"):le.info.main,.5)),Se(le.Slider,"successTrack",Ie(xt,Q?ce("palette-success-main"):le.success.main,.5)),Se(le.Slider,"warningTrack",Ie(xt,Q?ce("palette-warning-light"):le.warning.main,.5));const it=Te?Ie(_t,Q?ce("palette-background-default"):le.background.default,.985):Wl(le.background.default,.98);Se(le.SnackbarContent,"bg",it),Se(le.SnackbarContent,"color",br((()=>Te?oC.text.primary:le.getContrastText(it)))),Se(le.SpeedDialAction,"fabHoverBg",Wl(le.background.paper,.15)),Se(le.StepConnector,"border",qe("palette-grey-600")),Se(le.StepContent,"border",qe("palette-grey-600")),Se(le.Switch,"defaultColor",qe("palette-grey-300")),Se(le.Switch,"defaultDisabledColor",qe("palette-grey-600")),Se(le.Switch,"primaryDisabledColor",Ie(xt,Q?ce("palette-primary-main"):le.primary.main,.55)),Se(le.Switch,"secondaryDisabledColor",Ie(xt,Q?ce("palette-secondary-main"):le.secondary.main,.55)),Se(le.Switch,"errorDisabledColor",Ie(xt,Q?ce("palette-error-main"):le.error.main,.55)),Se(le.Switch,"infoDisabledColor",Ie(xt,Q?ce("palette-info-main"):le.info.main,.55)),Se(le.Switch,"successDisabledColor",Ie(xt,Q?ce("palette-success-main"):le.success.main,.55)),Se(le.Switch,"warningDisabledColor",Ie(xt,Q?ce("palette-warning-light"):le.warning.main,.55)),Se(le.TableCell,"border",Ie(xt,No(Q?ce("palette-divider"):le.divider,1),.68)),Se(le.Tooltip,"bg",Ie(No,Q?ce("palette-grey-700"):le.grey[700],.92))}Q||(Fr(le.background,"default"),Fr(le.background,"paper"),Fr(le.common,"background"),Fr(le.common,"onBackground"),Fr(le,"divider")),Object.keys(le).forEach((it=>{const at=le[it];it!=="tonalOffset"&&!Q&&at&&typeof at=="object"&&(at.main&&Se(le[it],"mainChannel",qa(Va(at.main))),at.light&&Se(le[it],"lightChannel",qa(Va(at.light))),at.dark&&Se(le[it],"darkChannel",qa(Va(at.dark))),at.contrastText&&Se(le[it],"contrastTextChannel",qa(Va(at.contrastText))),it==="text"&&(Fr(le[it],"primary"),Fr(le[it],"secondary")),it==="action"&&(at.active&&Fr(le[it],"active"),at.selected&&Fr(le[it],"selected")))}))})),ke=V.reduce(((Xe,le)=>Fn(Xe,le)),ke);const $e={prefix:G,disableCssColorScheme:H,shouldSkipGeneratingVar:ie,getSelector:PB(ke),enableContrastVars:Q},{vars:dt,generateThemeVars:lt,generateStyleSheets:gt}=(function(Xe,le={}){const{getSelector:qe=ar,disableCssColorScheme:Ie,colorSchemeSelector:Ye,enableContrastVars:it}=le,{colorSchemes:at={},components:bt,defaultColorScheme:kt="light",...Zt}=Xe,{vars:Qt,css:rn,varsWithDefaults:En}=lv(Zt,le);let on=En;const St={},{[kt]:Gt,...On}=at;if(Object.entries(On||{}).forEach((([Ct,dn])=>{const{vars:Jt,css:Hr,varsWithDefaults:jo}=lv(dn,le);on=Fn(on,jo),St[Ct]={css:Hr,vars:Jt}})),Gt){const{css:Ct,vars:dn,varsWithDefaults:Jt}=lv(Gt,le);on=Fn(on,Jt),St[kt]={css:Ct,vars:dn}}function ar(Ct,dn){let Jt=Ye;if(Ye==="class"&&(Jt=".%s"),Ye==="data"&&(Jt="[data-%s]"),Ye?.startsWith("data-")&&!Ye.includes("%s")&&(Jt=`[${Ye}="%s"]`),Ct){if(Jt==="media")return Xe.defaultColorScheme===Ct?":root":{[`@media (prefers-color-scheme: ${at[Ct]?.palette?.mode||Ct})`]:{":root":dn}};if(Jt)return Xe.defaultColorScheme===Ct?`:root, ${Jt.replace("%s",String(Ct))}`:Jt.replace("%s",String(Ct))}return":root"}return{vars:on,generateThemeVars:()=>{let Ct={...Qt};return Object.entries(St).forEach((([,{vars:dn}])=>{Ct=Fn(Ct,dn)})),Ct},generateStyleSheets:()=>{const Ct=[],dn=Xe.defaultColorScheme||"light";function Jt(Rn,Xn){Object.keys(Xn).length&&Ct.push(typeof Rn=="string"?{[Rn]:{...Xn}}:Rn)}Jt(qe(void 0,{...rn}),rn);const{[dn]:Hr,...jo}=St;if(Hr){const{css:Rn}=Hr,Xn=at[dn]?.palette?.mode,xr=!Ie&&Xn?{colorScheme:Xn,...Rn}:{...Rn};Jt(qe(dn,{...xr}),xr)}return Object.entries(jo).forEach((([Rn,{css:Xn}])=>{const xr=at[Rn]?.palette?.mode,Ti=!Ie&&xr?{colorScheme:xr,...Xn}:{...Xn};Jt(qe(Rn,{...Ti}),Ti)})),it&&Ct.push({":root":{"--__l-threshold":"0.7","--__l":"clamp(0, (l / var(--__l-threshold) - 1) * -infinity, 1)","--__a":"clamp(0.87, (l / var(--__l-threshold) - 1) * -infinity, 1)"}}),Ct}}})(ke,$e);return ke.vars=dt,Object.entries(ke.colorSchemes[ke.defaultColorScheme]).forEach((([Xe,le])=>{ke[Xe]=le})),ke.generateThemeVars=lt,ke.generateStyleSheets=gt,ke.generateSpacing=function(){return Qk(me.spacing,tv(this))},ke.getColorSchemeSelector=(function(Xe){return function(le){return Xe==="media"?`@media (prefers-color-scheme: ${le})`:Xe?Xe.startsWith("data-")&&!Xe.includes("%s")?`[${Xe}="${le}"] &`:Xe==="class"?`.${le} &`:Xe==="data"?`[data-${le}] &`:`${Xe.replace("%s",le)} &`:"&"}})(ue),ke.spacing=ke.generateSpacing(),ke.shouldSkipGeneratingVar=ie,ke.unstable_sxConfig={...Bl,...me?.unstable_sxConfig},ke.unstable_sx=function(Xe){return pi({sx:Xe,theme:this})},ke.internal_cache={},ke.toRuntimeSource=dC,ke})({...I,colorSchemes:C,defaultColorScheme:N,...typeof v!="boolean"&&v},...a)}const yC=vC(),dv="$$material",Ft=tC({themeId:dv,defaultTheme:yC,rootShouldForwardProp:t=>(function(a){return a!=="ownerState"&&a!=="theme"&&a!=="sx"&&a!=="as"})(t)&&t!=="classes"}),bC={theme:void 0},Hn=function(t){let a,u;return function(v){let O=a;return O!==void 0&&v.theme===u||(bC.theme=v.theme,O=$k(t(bC)),a=O,u=v.theme),O}};function Gl(t,a,u=!1){const v={...a};for(const O in t)if(Object.prototype.hasOwnProperty.call(t,O)){const A=O;if(A==="components"||A==="slots")v[A]={...t[A],...v[A]};else if(A==="componentsProps"||A==="slotProps"){const I=t[A],N=a[A];if(N)if(I){v[A]={...N};for(const T in I)if(Object.prototype.hasOwnProperty.call(I,T)){const C=T;v[A][C]=Gl(I[C],N[C],u)}}else v[A]=N;else v[A]=I||{}}else A==="className"&&u&&a.className!==void 0?v.className=Pt(t?.className,a?.className):A==="style"&&u&&a.style?v.style={...t?.style,...a?.style}:v[A]===void 0&&(v[A]=t[A])}return v}var Je=d(423);const IB=s.createContext(void 0);function Vn(t){return(function({props:a,name:u}){return(function(v){const{theme:O,name:A,props:I}=v;if(!O||!O.components||!O.components[A])return I;const N=O.components[A];return N.defaultProps?Gl(N.defaultProps,I,O.components.mergeClassNameAndStyle):N.styleOverrides||N.variants?I:Gl(N,I,O.components.mergeClassNameAndStyle)})({props:a,name:u,theme:{components:s.useContext(IB)}})})(t)}function Kl(...t){const a=s.useRef(void 0),u=s.useCallback((v=>{const O=t.map((A=>{if(A==null)return null;if(typeof A=="function"){const I=A,N=I(v);return typeof N=="function"?N:()=>{I(null)}}return A.current=v,()=>{A.current=null}}));return()=>{O.forEach((A=>A?.()))}}),t);return s.useMemo((()=>t.every((v=>v==null))?null:v=>{a.current&&(a.current(),a.current=void 0),v!=null&&(a.current=u(v))}),t)}const wC=function(t,a,u){return t===void 0||typeof t=="string"?a:{...a,ownerState:{...a.ownerState,...u}}},xC=function(t,a,u){return typeof t=="function"?t(a,u):t};function MB(t,a){const u=t.charCodeAt(2);return t[0]==="o"&&t[1]==="n"&&u>=65&&u<=90&&typeof a=="function"}const _C=function(t){if(t===void 0)return{};const a={};return Object.keys(t).filter((u=>!(u.match(/^on[A-Z]/)&&typeof t[u]=="function"))).forEach((u=>{a[u]=t[u]})),a},SC=function(t){const{getSlotProps:a,additionalProps:u,externalSlotProps:v,externalForwardedProps:O,className:A}=t;if(!a){const q=Pt(u?.className,A,O?.className,v?.className),H={...u?.style,...O?.style,...v?.style},G={...u,...O,...v};return q.length>0&&(G.className=q),Object.keys(H).length>0&&(G.style=H),{props:G,internalRef:void 0}}const I=(function(q){if(q===void 0)return{};const H={};for(const G of Object.keys(q))MB(G,q[G])&&(H[G]=q[G]);return H})({...O,...v}),N=_C(v),T=_C(O),C=a(I),X=Pt(C?.className,u?.className,A,O?.className,v?.className),V={...C?.style,...u?.style,...O?.style,...v?.style},$={...C,...u,...T,...N};return X.length>0&&($.className=X),Object.keys(V).length>0&&($.style=V),{props:$,internalRef:C.ref}};function Un(t,a){const{className:u,elementType:v,ownerState:O,externalForwardedProps:A,internalForwardedProps:I,shouldForwardComponentProp:N=!1,...T}=a,{component:C,slots:X={[t]:void 0},slotProps:V={[t]:void 0},...$}=A,q=X[t]||v,H=xC(V[t],O),{props:{component:G,...Q},internalRef:ie}=SC({className:u,...T,externalForwardedProps:t==="root"?$:void 0,externalSlotProps:H}),ue=Kl(ie,H?.ref,a.ref),fe=t==="root"?G||C:G;return[q,wC(q,{...t==="root"&&!C&&!X[t]&&I,...t!=="root"&&!X[t]&&I,...Q,...fe&&!N&&{as:fe},...fe&&N&&{component:fe},ref:ue},O)]}const nn=Tl;function wi(t=[]){return([,a])=>a&&(function(u,v=[]){if(!(function(O){return typeof O.main=="string"})(u))return!1;for(const O of v)if(!u.hasOwnProperty(O)||typeof u[O]!="string")return!1;return!0})(a,t)}const jB=Fl(),hv=function(t=jB){return(function(a=null){const u=s.useContext(Kg);return u&&(v=u,Object.keys(v).length!==0)?u:a;var v})(t)};function EC(){const t=hv(yC);return t[dv]||t}const OC=t=>t,kC=(()=>{let t=OC;return{configure(a){t=a},generate:a=>t(a),reset(){t=OC}}})(),LB={active:"active",checked:"checked",completed:"completed",disabled:"disabled",error:"error",expanded:"expanded",focused:"focused",focusVisible:"focusVisible",open:"open",readOnly:"readOnly",required:"required",selected:"selected"};function Wn(t,a,u="Mui"){const v=LB[a];return v?`${u}-${v}`:`${kC.generate(t)}-${a}`}function Gn(t,a,u="Mui"){const v={};return a.forEach((O=>{v[O]=Wn(t,O,u)})),v}function DB(t){return Wn("MuiPaper",t)}Gn("MuiPaper",["root","rounded","outlined","elevation","elevation0","elevation1","elevation2","elevation3","elevation4","elevation5","elevation6","elevation7","elevation8","elevation9","elevation10","elevation11","elevation12","elevation13","elevation14","elevation15","elevation16","elevation17","elevation18","elevation19","elevation20","elevation21","elevation22","elevation23","elevation24"]);const BB=Ft("div",{name:"MuiPaper",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[u.variant],!u.square&&a.rounded,u.variant==="elevation"&&a[`elevation${u.elevation}`]]}})(Hn((({theme:t})=>({backgroundColor:(t.vars||t).palette.background.paper,color:(t.vars||t).palette.text.primary,transition:t.transitions.create("box-shadow"),variants:[{props:({ownerState:a})=>!a.square,style:{borderRadius:t.shape.borderRadius}},{props:{variant:"outlined"},style:{border:`1px solid ${(t.vars||t).palette.divider}`}},{props:{variant:"elevation"},style:{boxShadow:"var(--Paper-shadow)",backgroundImage:"var(--Paper-overlay)"}}]})))),FB=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiPaper"}),v=EC(),{className:O,component:A="div",elevation:I=1,square:N=!1,variant:T="elevation",...C}=u,X={...u,component:A,elevation:I,square:N,variant:T},V=($=>{const{square:q,elevation:H,variant:G,classes:Q}=$;return or({root:["root",G,!q&&"rounded",G==="elevation"&&`elevation${H}`]},DB,Q)})(X);return(0,Je.jsx)(BB,{as:A,ownerState:X,className:Pt(V.root,O),ref:a,...C,style:{...T==="elevation"&&{"--Paper-shadow":(v.vars||v).shadows[I],...v.vars&&{"--Paper-overlay":v.vars.overlays?.[I]},...!v.vars&&v.palette.mode==="dark"&&{"--Paper-overlay":`linear-gradient(${Hl("#fff",cv(I))}, ${Hl("#fff",cv(I))})`}},...C.style}})}));function qB(t){return Wn("MuiAlert",t)}const CC=Gn("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","outlined","standard"]);let AC=0;const NC={...S}.useId;function TC(t){try{return t.matches(":focus-visible")}catch{}return!1}const pv=Kl,Yl=typeof window<"u"?s.useLayoutEffect:s.useEffect,Xl=function(t){const a=s.useRef(t);return Yl((()=>{a.current=t})),s.useRef(((...u)=>(0,a.current)(...u))).current},To=Xl,zB={},RC={};function PC(t,a){const u=s.useRef(RC);return u.current===RC&&(u.current=t(a)),u}class Zl{static create(){return new Zl}static use(){const a=PC(Zl.create).current,[u,v]=s.useState(!1);return a.shouldMount=u,a.setShouldMount=v,s.useEffect(a.mountEffect,[u]),a}constructor(){this.ref={current:null},this.mounted=null,this.didMount=!1,this.shouldMount=!1,this.setShouldMount=null}mount(){return this.mounted||(this.mounted=(function(){let a,u;const v=new Promise(((O,A)=>{a=O,u=A}));return v.resolve=a,v.reject=u,v})(),this.shouldMount=!0,this.setShouldMount(this.shouldMount)),this.mounted}mountEffect=()=>{this.shouldMount&&!this.didMount&&this.ref.current!==null&&(this.didMount=!0,this.mounted.resolve())};start(...a){this.mount().then((()=>this.ref.current?.start(...a)))}stop(...a){this.mount().then((()=>this.ref.current?.stop(...a)))}pulsate(...a){this.mount().then((()=>this.ref.current?.pulsate(...a)))}}function Ql(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function mv(t,a){var u=Object.create(null);return t&&s.Children.map(t,(function(v){return v})).forEach((function(v){u[v.key]=(function(O){return a&&(0,s.isValidElement)(O)?a(O):O})(v)})),u}function Ro(t,a,u){return u[a]!=null?u[a]:t.props[a]}function HB(t,a,u){var v=mv(t.children),O=(function(A,I){function N(G){return G in I?I[G]:A[G]}A=A||{},I=I||{};var T,C=Object.create(null),X=[];for(var V in A)V in I?X.length&&(C[V]=X,X=[]):X.push(V);var $={};for(var q in I){if(C[q])for(T=0;T<C[q].length;T++){var H=C[q][T];$[C[q][T]]=N(H)}$[q]=N(q)}for(T=0;T<X.length;T++)$[X[T]]=N(X[T]);return $})(a,v);return Object.keys(O).forEach((function(A){var I=O[A];if((0,s.isValidElement)(I)){var N=A in a,T=A in v,C=a[A],X=(0,s.isValidElement)(C)&&!C.props.in;!T||N&&!X?T||!N||X?T&&N&&(0,s.isValidElement)(C)&&(O[A]=(0,s.cloneElement)(I,{onExited:u.bind(null,I),in:C.props.in,exit:Ro(I,"exit",t),enter:Ro(I,"enter",t)})):O[A]=(0,s.cloneElement)(I,{in:!1}):O[A]=(0,s.cloneElement)(I,{onExited:u.bind(null,I),in:!0,exit:Ro(I,"exit",t),enter:Ro(I,"enter",t)})}})),O}var VB=Object.values||function(t){return Object.keys(t).map((function(a){return t[a]}))},gv=(function(t){function a(v,O){var A,I=(A=t.call(this,v,O)||this).handleExited.bind(Ql(A));return A.state={contextValue:{isMounting:!0},handleExited:I,firstRender:!0},A}Oa(a,t);var u=a.prototype;return u.componentDidMount=function(){this.mounted=!0,this.setState({contextValue:{isMounting:!1}})},u.componentWillUnmount=function(){this.mounted=!1},a.getDerivedStateFromProps=function(v,O){var A,I,N=O.children,T=O.handleExited;return{children:O.firstRender?(A=v,I=T,mv(A.children,(function(C){return(0,s.cloneElement)(C,{onExited:I.bind(null,C),in:!0,appear:Ro(C,"appear",A),enter:Ro(C,"enter",A),exit:Ro(C,"exit",A)})}))):HB(v,N,T),firstRender:!1}},u.handleExited=function(v,O){var A=mv(this.props.children);v.key in A||(v.props.onExited&&v.props.onExited(O),this.mounted&&this.setState((function(I){var N=et({},I.children);return delete N[v.key],{children:N}})))},u.render=function(){var v=this.props,O=v.component,A=v.childFactory,I=Ea(v,["component","childFactory"]),N=this.state.contextValue,T=VB(this.state.children).map(A);return delete I.appear,delete I.enter,delete I.exit,O===null?b().createElement(oi.Provider,{value:N},T):b().createElement(oi.Provider,{value:N},b().createElement(O,I,T))},a})(b().Component);gv.propTypes={},gv.defaultProps={component:"div",childFactory:function(t){return t}};const UB=gv,WB=[];class vv{static create(){return new vv}currentId=null;start(a,u){this.clear(),this.currentId=setTimeout((()=>{this.currentId=null,u()}),a)}clear=()=>{this.currentId!==null&&(clearTimeout(this.currentId),this.currentId=null)};disposeEffect=()=>this.clear}d(679);var nt=function(t,a){var u=arguments;if(a==null||!Gg.call(a,"css"))return s.createElement.apply(void 0,u);var v=u.length,O=new Array(v);O[0]=RD,O[1]=(function(I,N){var T={};for(var C in N)Gg.call(N,C)&&(T[C]=N[C]);return T[Yg]=I,T})(t,a);for(var A=2;A<v;A++)O[A]=u[A];return s.createElement.apply(null,O)};function Ua(){for(var t=arguments.length,a=new Array(t),u=0;u<t;u++)a[u]=arguments[u];return yk(a)}var xi=function(){var t=Ua.apply(void 0,arguments),a="animation-"+t.name;return{name:a,styles:"@keyframes "+a+"{"+t.styles+"}",anim:1,toString:function(){return"_EMO_"+this.name+"_"+this.styles+"_EMO_"}}};const Kn=Gn("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),GB=xi`
|
|
27
|
+
0% {
|
|
28
|
+
transform: scale(0);
|
|
29
|
+
opacity: 0.1;
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
100% {
|
|
33
|
+
transform: scale(1);
|
|
34
|
+
opacity: 0.3;
|
|
35
|
+
}
|
|
36
|
+
`,KB=xi`
|
|
37
|
+
0% {
|
|
38
|
+
opacity: 1;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
100% {
|
|
42
|
+
opacity: 0;
|
|
43
|
+
}
|
|
44
|
+
`,YB=xi`
|
|
45
|
+
0% {
|
|
46
|
+
transform: scale(1);
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
50% {
|
|
50
|
+
transform: scale(0.92);
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
100% {
|
|
54
|
+
transform: scale(1);
|
|
55
|
+
}
|
|
56
|
+
`,XB=Ft("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),ZB=Ft((function(t){const{className:a,classes:u,pulsate:v=!1,rippleX:O,rippleY:A,rippleSize:I,in:N,onExited:T,timeout:C}=t,[X,V]=s.useState(!1),$=Pt(a,u.ripple,u.rippleVisible,v&&u.ripplePulsate),q={width:I,height:I,top:-I/2+A,left:-I/2+O},H=Pt(u.child,X&&u.childLeaving,v&&u.childPulsate);return N||X||V(!0),s.useEffect((()=>{if(!N&&T!=null){const G=setTimeout(T,C);return()=>{clearTimeout(G)}}}),[T,N,C]),(0,Je.jsx)("span",{className:$,style:q,children:(0,Je.jsx)("span",{className:H})})}),{name:"MuiTouchRipple",slot:"Ripple"})`
|
|
57
|
+
opacity: 0;
|
|
58
|
+
position: absolute;
|
|
59
|
+
|
|
60
|
+
&.${Kn.rippleVisible} {
|
|
61
|
+
opacity: 0.3;
|
|
62
|
+
transform: scale(1);
|
|
63
|
+
animation-name: ${GB};
|
|
64
|
+
animation-duration: ${550}ms;
|
|
65
|
+
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
&.${Kn.ripplePulsate} {
|
|
69
|
+
animation-duration: ${({theme:t})=>t.transitions.duration.shorter}ms;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
& .${Kn.child} {
|
|
73
|
+
opacity: 1;
|
|
74
|
+
display: block;
|
|
75
|
+
width: 100%;
|
|
76
|
+
height: 100%;
|
|
77
|
+
border-radius: 50%;
|
|
78
|
+
background-color: currentColor;
|
|
79
|
+
}
|
|
80
|
+
|
|
81
|
+
& .${Kn.childLeaving} {
|
|
82
|
+
opacity: 0;
|
|
83
|
+
animation-name: ${KB};
|
|
84
|
+
animation-duration: ${550}ms;
|
|
85
|
+
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
86
|
+
}
|
|
87
|
+
|
|
88
|
+
& .${Kn.childPulsate} {
|
|
89
|
+
position: absolute;
|
|
90
|
+
/* @noflip */
|
|
91
|
+
left: 0px;
|
|
92
|
+
top: 0;
|
|
93
|
+
animation-name: ${YB};
|
|
94
|
+
animation-duration: 2500ms;
|
|
95
|
+
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
96
|
+
animation-iteration-count: infinite;
|
|
97
|
+
animation-delay: 200ms;
|
|
98
|
+
}
|
|
99
|
+
`,QB=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiTouchRipple"}),{center:v=!1,classes:O={},className:A,...I}=u,[N,T]=s.useState([]),C=s.useRef(0),X=s.useRef(null);s.useEffect((()=>{X.current&&(X.current(),X.current=null)}),[N]);const V=s.useRef(!1),$=(function(){const fe=PC(vv.create).current;var me;return me=fe.disposeEffect,s.useEffect(me,WB),fe})(),q=s.useRef(null),H=s.useRef(null),G=s.useCallback((fe=>{const{pulsate:me,rippleX:ve,rippleY:ye,rippleSize:ce,cb:Oe}=fe;T((Me=>[...Me,(0,Je.jsx)(ZB,{classes:{ripple:Pt(O.ripple,Kn.ripple),rippleVisible:Pt(O.rippleVisible,Kn.rippleVisible),ripplePulsate:Pt(O.ripplePulsate,Kn.ripplePulsate),child:Pt(O.child,Kn.child),childLeaving:Pt(O.childLeaving,Kn.childLeaving),childPulsate:Pt(O.childPulsate,Kn.childPulsate)},timeout:550,pulsate:me,rippleX:ve,rippleY:ye,rippleSize:ce},C.current)])),C.current+=1,X.current=Oe}),[O]),Q=s.useCallback(((fe={},me={},ve=(()=>{}))=>{const{pulsate:ye=!1,center:ce=v||me.pulsate,fakeElement:Oe=!1}=me;if(fe?.type==="mousedown"&&V.current)return void(V.current=!1);fe?.type==="touchstart"&&(V.current=!0);const Me=Oe?null:H.current,_e=Me?Me.getBoundingClientRect():{width:0,height:0,left:0,top:0};let je,Ne,Te;if(ce||fe===void 0||fe.clientX===0&&fe.clientY===0||!fe.clientX&&!fe.touches)je=Math.round(_e.width/2),Ne=Math.round(_e.height/2);else{const{clientX:ze,clientY:Le}=fe.touches&&fe.touches.length>0?fe.touches[0]:fe;je=Math.round(ze-_e.left),Ne=Math.round(Le-_e.top)}if(ce)Te=Math.sqrt((2*_e.width**2+_e.height**2)/3),Te%2==0&&(Te+=1);else{const ze=2*Math.max(Math.abs((Me?Me.clientWidth:0)-je),je)+2,Le=2*Math.max(Math.abs((Me?Me.clientHeight:0)-Ne),Ne)+2;Te=Math.sqrt(ze**2+Le**2)}fe?.touches?q.current===null&&(q.current=()=>{G({pulsate:ye,rippleX:je,rippleY:Ne,rippleSize:Te,cb:ve})},$.start(80,(()=>{q.current&&(q.current(),q.current=null)}))):G({pulsate:ye,rippleX:je,rippleY:Ne,rippleSize:Te,cb:ve})}),[v,G,$]),ie=s.useCallback((()=>{Q({},{pulsate:!0})}),[Q]),ue=s.useCallback(((fe,me)=>{if($.clear(),fe?.type==="touchend"&&q.current)return q.current(),q.current=null,void $.start(0,(()=>{ue(fe,me)}));q.current=null,T((ve=>ve.length>0?ve.slice(1):ve)),X.current=me}),[$]);return s.useImperativeHandle(a,(()=>({pulsate:ie,start:Q,stop:ue})),[ie,Q,ue]),(0,Je.jsx)(XB,{className:Pt(Kn.root,O.root,A),ref:H,...I,children:(0,Je.jsx)(UB,{component:null,exit:!0,children:N})})})),JB=QB;function $B(t){return Wn("MuiButtonBase",t)}const e6=Gn("MuiButtonBase",["root","disabled","focusVisible"]),t6=Ft("button",{name:"MuiButtonBase",slot:"Root"})({display:"inline-flex",alignItems:"center",justifyContent:"center",position:"relative",boxSizing:"border-box",WebkitTapHighlightColor:"transparent",backgroundColor:"transparent",outline:0,border:0,margin:0,borderRadius:0,padding:0,cursor:"pointer",userSelect:"none",verticalAlign:"middle",MozAppearance:"none",WebkitAppearance:"none",textDecoration:"none",color:"inherit","&::-moz-focus-inner":{borderStyle:"none"},[`&.${e6.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}});function qr(t,a,u,v=!1){return To((O=>(u&&u(O),v||t[a](O),!0)))}const yv=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiButtonBase"}),{action:v,centerRipple:O=!1,children:A,className:I,component:N="button",disabled:T=!1,disableRipple:C=!1,disableTouchRipple:X=!1,focusRipple:V=!1,focusVisibleClassName:$,focusableWhenDisabled:q,suppressFocusVisible:H=!1,internalNativeButton:G,LinkComponent:Q="a",nativeButton:ie,onBlur:ue,onClick:fe,onContextMenu:me,onDragLeave:ve,onFocus:ye,onFocusVisible:ce,onKeyDown:Oe,onKeyUp:Me,onMouseDown:_e,onMouseLeave:je,onMouseUp:Ne,onTouchEnd:Te,onTouchMove:ze,onTouchStart:Le,tabIndex:ke=0,TouchRippleProps:Ke,touchRippleRef:$e,type:dt,...lt}=u,gt=!!(lt.href||lt.to),Xe=!!lt.formAction;let le=N;le==="button"&>&&(le=Q);const qe=typeof le=="string"?le==="button":G??!1,Ie=ie??qe,Ye=Zl.use(),it=pv(Ye.ref,$e),[at,bt]=s.useState(!1);(T||H)&&at&&bt(!1);const kt=To((Et=>{V&&!Et.repeat&&at&&Et.key===" "&&Ye.stop(Et,(()=>{Ye.start(Et)}))})),Zt=To((Et=>{V&&Et.key===" "&&at&&!Et.defaultPrevented&&Ye.stop(Et,(()=>{Ye.pulsate(Et)}))})),{getButtonProps:Qt,rootRef:rn}=(function(Et){const{nativeButton:Vr,disabled:bn,type:Ur,hasFormAction:so=!1,tabIndex:Wr=0,focusableWhenDisabled:Pi,stopEventPropagation:ku=!1,onBeforeKeyDown:Ii,onBeforeKeyUp:Cu}=Et,Au=s.useRef(null),_r=Pi===!0,Mi=(function(hn){const{focusableWhenDisabled:Ge,disabled:He,composite:rt=!1,tabIndex:st=0,isNativeButton:Ze}=hn,At=rt&&Ge!==!1,an=rt&&Ge===!1;return s.useMemo((()=>{const mn={onKeyDown(sr){He&&Ge&&sr.key!=="Tab"&&sr.preventDefault()}};return rt||(mn.tabIndex=st,!Ze&&He&&(mn.tabIndex=Ge?st:-1)),(Ze&&(Ge||At)||!Ze&&He)&&(mn["aria-disabled"]=He),!Ze||Ge&&!an||(mn.disabled=He),mn}),[rt,He,Ge,At,an,Ze,st])})({focusableWhenDisabled:_r,disabled:bn,isNativeButton:Vr,tabIndex:Wr}),es=s.useCallback((()=>{const hn=Au.current;return hn==null?Vr:hn.tagName==="BUTTON"||!!(hn.tagName==="A"&&hn.href)}),[Vr]),Nu=s.useMemo((()=>{const hn=_r?{}:{tabIndex:bn?-1:Wr};return Vr?(hn.type=Ur!==void 0||so?Ur:"button",_r||(hn.disabled=bn)):(hn.role="button",!_r&&bn&&(hn["aria-disabled"]=bn)),_r?{...hn,...Mi}:hn}),[bn,_r,Mi,so,Vr,Wr,Ur]);return{getButtonProps:s.useCallback(((hn=zB)=>{const{onClick:Ge,onKeyDown:He,onKeyUp:rt,...st}=hn;return{...Nu,...st,onClick:Ze=>{ku&&Ze.stopPropagation(),bn?Ze.preventDefault():Ge?.(Ze)},onKeyDown:Ze=>{_r&&Mi.onKeyDown(Ze),bn||(Ii?.(Ze),He?.(Ze),Ze.target!==Ze.currentTarget||es()||(Ze.key!==" "?Ze.key==="Enter"&&(Ze.preventDefault(),Ze.currentTarget.click()):Ze.preventDefault()))},onKeyUp:Ze=>{bn||(Cu?.(Ze),rt?.(Ze),Ze.target!==Ze.currentTarget||es()||Ze.key!==" "||Ze.defaultPrevented||Ze.currentTarget.click())}}}),[Nu,bn,_r,Mi,es,Ii,Cu,ku]),rootRef:Au}})({nativeButton:Ie,disabled:T,type:dt,hasFormAction:Xe,tabIndex:ke,onBeforeKeyDown:kt,onBeforeKeyUp:Zt}),{onClick:En,onKeyDown:on,onKeyUp:St,...Gt}=Qt({onClick:fe,onKeyDown:Oe,onKeyUp:Me});s.useImperativeHandle(v,(()=>({focusVisible:()=>{bt(!0),rn.current.focus()}})),[rn]);const On=Ye.shouldMount&&!C&&!T;s.useEffect((()=>{at&&V&&!C&&Ye.pulsate()}),[C,V,at,Ye]);const ar=qr(Ye,"start",_e,X),Ct=qr(Ye,"stop",me,X),dn=qr(Ye,"stop",ve,X),Jt=qr(Ye,"stop",Ne,X),Hr=qr(Ye,"stop",(Et=>{at&&Et.preventDefault(),je&&je(Et)}),X),jo=qr(Ye,"start",Le,X),Rn=qr(Ye,"stop",Te,X),Xn=qr(Ye,"stop",ze,X),xr=qr(Ye,"stop",(Et=>{TC(Et.target)||bt(!1),ue&&ue(Et)}),!1),Ti=To((Et=>{rn.current||(rn.current=Et.currentTarget),!H&&TC(Et.target)&&(bt(!0),ce&&ce(Et)),ye&&ye(Et)})),Ri={};gt&&(Ri.tabIndex=T?-1:ke,T&&(Ri["aria-disabled"]=T),Ri.type=dt);const Eu=pv(a,rn),$a={...u,centerRipple:O,component:N,disabled:T,disableRipple:C,disableTouchRipple:X,focusRipple:V,suppressFocusVisible:H,tabIndex:ke,focusVisible:at},Ou=(Et=>{const{disabled:Vr,focusVisible:bn,focusVisibleClassName:Ur,suppressFocusVisible:so,classes:Wr}=Et,Pi=or({root:["root",Vr&&"disabled",bn&&!so&&"focusVisible"]},$B,Wr);return bn&&!so&&Ur&&(Pi.root+=` ${Ur}`),Pi})($a);return(0,Je.jsxs)(t6,{as:le,className:Pt(Ou.root,I),ownerState:$a,onBlur:xr,onClick:En,onContextMenu:Ct,onFocus:Ti,onKeyDown:on,onKeyUp:St,onMouseDown:ar,onMouseLeave:Hr,onMouseUp:Jt,onDragLeave:dn,onTouchEnd:Rn,onTouchMove:Xn,onTouchStart:jo,ref:Eu,...gt?Ri:Gt,...lt,children:[A,On?(0,Je.jsx)(JB,{ref:it,center:O,...Ke}):null]})}));function n6(t){return Wn("MuiCircularProgress",t)}Gn("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","track","circle","circleDisableShrink"]);const Po=44,bv=xi`
|
|
100
|
+
0% {
|
|
101
|
+
transform: rotate(0deg);
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
100% {
|
|
105
|
+
transform: rotate(360deg);
|
|
106
|
+
}
|
|
107
|
+
`,wv=xi`
|
|
108
|
+
0% {
|
|
109
|
+
stroke-dasharray: 1px, 200px;
|
|
110
|
+
stroke-dashoffset: 0;
|
|
111
|
+
}
|
|
112
|
+
|
|
113
|
+
50% {
|
|
114
|
+
stroke-dasharray: 100px, 200px;
|
|
115
|
+
stroke-dashoffset: -15px;
|
|
116
|
+
}
|
|
117
|
+
|
|
118
|
+
100% {
|
|
119
|
+
stroke-dasharray: 1px, 200px;
|
|
120
|
+
stroke-dashoffset: -126px;
|
|
121
|
+
}
|
|
122
|
+
`,r6=typeof bv!="string"?Ua`
|
|
123
|
+
animation: ${bv} 1.4s linear infinite;
|
|
124
|
+
`:null,o6=typeof wv!="string"?Ua`
|
|
125
|
+
animation: ${wv} 1.4s ease-in-out infinite;
|
|
126
|
+
`:null,i6=Ft("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[u.variant],a[`color${nn(u.color)}`]]}})(Hn((({theme:t})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:t.transitions.create("transform")}},{props:{variant:"indeterminate"},style:r6||{animation:`${bv} 1.4s linear infinite`}},...Object.entries(t.palette).filter(wi()).map((([a])=>({props:{color:a},style:{color:(t.vars||t).palette[a].main}})))]})))),a6=Ft("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),s6=Ft("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.circle,u.disableShrink&&a.circleDisableShrink]}})(Hn((({theme:t})=>({stroke:"currentColor",variants:[{props:{variant:"determinate"},style:{transition:t.transitions.create("stroke-dashoffset")}},{props:{variant:"indeterminate"},style:{strokeDasharray:"80px, 200px",strokeDashoffset:0}},{props:({ownerState:a})=>a.variant==="indeterminate"&&!a.disableShrink,style:o6||{animation:`${wv} 1.4s ease-in-out infinite`}}]})))),l6=Ft("circle",{name:"MuiCircularProgress",slot:"Track"})(Hn((({theme:t})=>({stroke:"currentColor",opacity:(t.vars||t).palette.action.activatedOpacity})))),u6=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiCircularProgress"}),{className:v,color:O="primary",disableShrink:A=!1,enableTrackSlot:I=!1,min:N,max:T,size:C=40,style:X,thickness:V=3.6,value:$=u.min??0,variant:q="indeterminate",...H}=u,G=N??0,Q=T??100,ie={...u,color:O,disableShrink:A,size:C,thickness:V,value:$,variant:q,enableTrackSlot:I},ue=(ye=>{const{classes:ce,variant:Oe,color:Me,disableShrink:_e}=ye;return or({root:["root",Oe,`color${nn(Me)}`],svg:["svg"],track:["track"],circle:["circle",_e&&"circleDisableShrink"]},n6,ce)})(ie),fe={},me={},ve={};if(q==="determinate"){const ye=2*Math.PI*((Po-V)/2),ce=Q-G;fe.strokeDasharray=ye.toFixed(3),fe.strokeDashoffset=ce>0?`${((Q-$)/ce*ye).toFixed(3)}px`:`${ye.toFixed(3)}px`,me.transform="rotate(-90deg)",ve["aria-valuenow"]=$,ve["aria-valuemin"]=G,ve["aria-valuemax"]=Q}return(0,Je.jsx)(i6,{className:Pt(ue.root,v),style:{width:C,height:C,...me,...X},ownerState:ie,ref:a,role:"progressbar",...ve,...H,children:(0,Je.jsxs)(a6,{className:ue.svg,ownerState:ie,viewBox:"22 22 44 44",children:[I?(0,Je.jsx)(l6,{className:ue.track,ownerState:ie,cx:Po,cy:Po,r:(Po-V)/2,fill:"none",strokeWidth:V,"aria-hidden":"true"}):null,(0,Je.jsx)(s6,{className:ue.circle,style:fe,ownerState:ie,cx:Po,cy:Po,r:(Po-V)/2,fill:"none",strokeWidth:V})]})})})),c6=u6;function f6(t){return Wn("MuiIconButton",t)}const IC=Gn("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),d6=Ft(yv,{name:"MuiIconButton",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.loading&&a.loading,u.color!=="default"&&a[`color${nn(u.color)}`],u.edge&&a[`edge${nn(u.edge)}`],a[`size${nn(u.size)}`]]}})(Hn((({theme:t})=>({textAlign:"center",flex:"0 0 auto",fontSize:t.typography.pxToRem(24),padding:8,borderRadius:"50%",color:(t.vars||t).palette.action.active,transition:t.transitions.create("background-color",{duration:t.transitions.duration.shortest}),variants:[{props:a=>!a.disableRipple,style:{"--IconButton-hoverBg":t.alpha((t.vars||t).palette.action.active,(t.vars||t).palette.action.hoverOpacity),"&:hover":{backgroundColor:"var(--IconButton-hoverBg)","@media (hover: none)":{backgroundColor:"transparent"}}}},{props:{edge:"start"},style:{marginLeft:-12}},{props:{edge:"start",size:"small"},style:{marginLeft:-3}},{props:{edge:"end"},style:{marginRight:-12}},{props:{edge:"end",size:"small"},style:{marginRight:-3}}]}))),Hn((({theme:t})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(t.palette).filter(wi()).map((([a])=>({props:{color:a},style:{color:(t.vars||t).palette[a].main,"--IconButton-hoverBg":t.alpha((t.vars||t).palette[a].main,(t.vars||t).palette.action.hoverOpacity)}}))),{props:{size:"small"},style:{padding:5,fontSize:t.typography.pxToRem(18)}},{props:{size:"large"},style:{padding:12,fontSize:t.typography.pxToRem(28)}}],[`&.${IC.disabled}`]:{backgroundColor:"transparent",color:(t.vars||t).palette.action.disabled},[`&.${IC.loading}`]:{color:"transparent"}})))),h6=Ft("span",{name:"MuiIconButton",slot:"LoadingIndicator"})((({theme:t})=>({display:"none",position:"absolute",visibility:"visible",top:"50%",left:"50%",transform:"translate(-50%, -50%)",color:(t.vars||t).palette.action.disabled,variants:[{props:{loading:!0},style:{display:"flex"}}]}))),p6=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiIconButton"}),{edge:v=!1,children:O,className:A,color:I="default",disabled:N=!1,disableFocusRipple:T=!1,size:C="medium",id:X,loading:V=null,loadingIndicator:$,...q}=u,H=(function(ue){if(NC!==void 0){const fe=NC();return ue??fe}return(function(fe){const[me,ve]=s.useState(fe),ye=fe||me;return s.useEffect((()=>{me==null&&(AC+=1,ve(`mui-${AC}`))}),[me]),ye})(ue)})(X),G=$??(0,Je.jsx)(c6,{"aria-labelledby":H,color:"inherit",size:16}),Q={...u,edge:v,color:I,disabled:N,disableFocusRipple:T,loading:V,loadingIndicator:G,size:C},ie=(ue=>{const{classes:fe,disabled:me,color:ve,edge:ye,size:ce,loading:Oe}=ue;return or({root:["root",Oe&&"loading",me&&"disabled",ve!=="default"&&`color${nn(ve)}`,ye&&`edge${nn(ye)}`,`size${nn(ce)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},f6,fe)})(Q);return(0,Je.jsxs)(d6,{id:V?H:X,className:Pt(ie.root,A),centerRipple:!0,internalNativeButton:!0,focusRipple:!T,disabled:N||V,ref:a,...q,ownerState:Q,children:[typeof V=="boolean"&&(0,Je.jsx)("span",{className:ie.loadingWrapper,style:{display:"contents"},children:(0,Je.jsx)(h6,{className:ie.loadingIndicator,ownerState:Q,children:V&&G})}),O]})})),MC=p6;function m6(t){return Wn("MuiSvgIcon",t)}Gn("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const g6=Ft("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.color!=="inherit"&&a[`color${nn(u.color)}`],a[`fontSize${nn(u.fontSize)}`]]}})(Hn((({theme:t})=>({userSelect:"none",width:"1em",height:"1em",display:"inline-block",flexShrink:0,transition:t.transitions?.create?.("fill",{duration:(t.vars??t).transitions?.duration?.shorter}),variants:[{props:a=>!a.hasSvgAsChild,style:{fill:"currentColor"}},{props:{fontSize:"inherit"},style:{fontSize:"inherit"}},{props:{fontSize:"small"},style:{fontSize:t.typography?.pxToRem?.(20)||"1.25rem"}},{props:{fontSize:"medium"},style:{fontSize:t.typography?.pxToRem?.(24)||"1.5rem"}},{props:{fontSize:"large"},style:{fontSize:t.typography?.pxToRem?.(35)||"2.1875rem"}},...Object.entries((t.vars??t).palette).filter((([,a])=>a&&a.main)).map((([a])=>({props:{color:a},style:{color:(t.vars??t).palette?.[a]?.main}}))),{props:{color:"action"},style:{color:(t.vars??t).palette?.action?.active}},{props:{color:"disabled"},style:{color:(t.vars??t).palette?.action?.disabled}},{props:{color:"inherit"},style:{color:void 0}}]})))),jC=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiSvgIcon"}),{children:v,className:O,color:A="inherit",component:I="svg",fontSize:N="medium",htmlColor:T,inheritViewBox:C=!1,titleAccess:X,viewBox:V="0 0 24 24",...$}=u,q=s.isValidElement(v)&&v.type==="svg",H={...u,color:A,component:I,fontSize:N,instanceFontSize:t.fontSize,inheritViewBox:C,viewBox:V,hasSvgAsChild:q},G={};C||(G.viewBox=V);const Q=(ie=>{const{color:ue,fontSize:fe,classes:me}=ie;return or({root:["root",ue!=="inherit"&&`color${nn(ue)}`,`fontSize${nn(fe)}`]},m6,me)})(H);return(0,Je.jsxs)(g6,{as:I,className:Pt(Q.root,O),focusable:"false",color:T,"aria-hidden":!X||void 0,role:X?"img":void 0,ref:a,...G,...$,...q&&v.props,ownerState:H,children:[q?v.props.children:v,X?(0,Je.jsx)("title",{children:X}):null]})}));jC.muiName="SvgIcon";const LC=jC;function io(t,a){function u(v,O){return(0,Je.jsx)(LC,{"data-testid":void 0,ref:O,...v,children:t})}return u.muiName=LC.muiName,s.memo(s.forwardRef(u))}const v6=io((0,Je.jsx)("path",{d:"M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z"})),y6=io((0,Je.jsx)("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"})),b6=io((0,Je.jsx)("path",{d:"M11 15h2v2h-2zm0-8h2v6h-2zm.99-5C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zM12 20c-4.42 0-8-3.58-8-8s3.58-8 8-8 8 3.58 8 8-3.58 8-8 8z"})),w6=io((0,Je.jsx)("path",{d:"M11,9H13V7H11M12,20C7.59,20 4,16.41 4,12C4,7.59 7.59,4 12,4C16.41,4 20,7.59 20, 12C20,16.41 16.41,20 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10, 10 0 0,0 12,2M11,17H13V11H11V17Z"})),x6=io((0,Je.jsx)("path",{d:"M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"})),_6=Ft(FB,{name:"MuiAlert",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[u.variant]]}})(Hn((({theme:t})=>{const a=t.palette.mode==="light"?t.darken:t.lighten,u=t.palette.mode==="light"?t.lighten:t.darken;return{...t.typography.body2,backgroundColor:"transparent",display:"flex",padding:"6px 16px",variants:[...Object.entries(t.palette).filter(wi(["light"])).map((([v])=>({props:{colorSeverity:v,variant:"standard"},style:{color:t.vars?t.vars.palette.Alert[`${v}Color`]:a(t.palette[v].light,.6),backgroundColor:t.vars?t.vars.palette.Alert[`${v}StandardBg`]:u(t.palette[v].light,.9),[`& .${CC.icon}`]:t.vars?{color:t.vars.palette.Alert[`${v}IconColor`]}:{color:t.palette[v].main}}}))),...Object.entries(t.palette).filter(wi(["light"])).map((([v])=>({props:{colorSeverity:v,variant:"outlined"},style:{color:t.vars?t.vars.palette.Alert[`${v}Color`]:a(t.palette[v].light,.6),border:`1px solid ${(t.vars||t).palette[v].light}`,[`& .${CC.icon}`]:t.vars?{color:t.vars.palette.Alert[`${v}IconColor`]}:{color:t.palette[v].main}}}))),...Object.entries(t.palette).filter(wi(["dark"])).map((([v])=>({props:{colorSeverity:v,variant:"filled"},style:{fontWeight:t.typography.fontWeightMedium,...t.vars?{color:t.vars.palette.Alert[`${v}FilledColor`],backgroundColor:t.vars.palette.Alert[`${v}FilledBg`]}:{backgroundColor:t.palette.mode==="dark"?t.palette[v].dark:t.palette[v].main,color:t.palette.getContrastText(t.palette[v].main)}}})))]}}))),S6=Ft("div",{name:"MuiAlert",slot:"Icon"})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),E6=Ft("div",{name:"MuiAlert",slot:"Message"})({padding:"8px 0",minWidth:0,overflow:"auto"}),O6=Ft("div",{name:"MuiAlert",slot:"Action"})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),DC={success:(0,Je.jsx)(v6,{fontSize:"inherit"}),warning:(0,Je.jsx)(y6,{fontSize:"inherit"}),error:(0,Je.jsx)(b6,{fontSize:"inherit"}),info:(0,Je.jsx)(w6,{fontSize:"inherit"})},k6=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiAlert"}),{action:v,children:O,className:A,closeText:I="Close",color:N,icon:T,iconMapping:C=DC,onClose:X,role:V="alert",severity:$="success",slotProps:q={},slots:H={},variant:G="standard",...Q}=u,ie={...u,color:N,severity:$,variant:G,colorSeverity:N||$},ue=(ke=>{const{variant:Ke,color:$e,severity:dt,classes:lt}=ke;return or({root:["root",`color${nn($e||dt)}`,`${Ke}`],icon:["icon"],message:["message"],action:["action"]},qB,lt)})(ie),fe={slots:H,slotProps:q},[me,ve]=Un("root",{ref:a,shouldForwardComponentProp:!0,className:Pt(ue.root,A),elementType:_6,externalForwardedProps:{...fe,...Q},ownerState:ie,additionalProps:{role:V,elevation:0}}),[ye,ce]=Un("icon",{className:ue.icon,elementType:S6,externalForwardedProps:fe,ownerState:ie}),[Oe,Me]=Un("message",{className:ue.message,elementType:E6,externalForwardedProps:fe,ownerState:ie}),[_e,je]=Un("action",{className:ue.action,elementType:O6,externalForwardedProps:fe,ownerState:ie}),[Ne,Te]=Un("closeButton",{elementType:MC,externalForwardedProps:fe,ownerState:ie}),[ze,Le]=Un("closeIcon",{elementType:x6,externalForwardedProps:fe,ownerState:ie});return(0,Je.jsxs)(me,{...ve,children:[T!==!1?(0,Je.jsx)(ye,{...ce,children:T||C[$]||DC[$]}):null,(0,Je.jsx)(Oe,{...Me,children:O}),v!=null?(0,Je.jsx)(_e,{...je,children:v}):null,v==null&&X?(0,Je.jsx)(_e,{...je,children:(0,Je.jsx)(Ne,{size:"small","aria-label":I,title:I,color:"inherit",onClick:X,...Te,children:(0,Je.jsx)(ze,{fontSize:"small",...Le})})}):null]})}));function C6(t){return Wn("MuiTypography",t)}Gn("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom"]);const A6=Ft("span",{name:"MuiTypography",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.variant&&a[u.variant],u.align!=="inherit"&&a[`align${nn(u.align)}`],u.noWrap&&a.noWrap,u.gutterBottom&&a.gutterBottom]}})(Hn((({theme:t})=>({margin:0,variants:[{props:{variant:"inherit"},style:{font:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}},...Object.entries(t.typography).filter((([a,u])=>a!=="inherit"&&u&&typeof u=="object")).map((([a,u])=>({props:{variant:a},style:u}))),...Object.entries(t.palette).filter(wi()).map((([a])=>({props:{color:a},style:{color:(t.vars||t).palette[a].main}}))),...Object.entries(t.palette?.text||{}).filter((([,a])=>typeof a=="string")).map((([a])=>({props:{color:`text${nn(a)}`},style:{color:(t.vars||t).palette.text[a]}}))),{props:({ownerState:a})=>a.align!=="inherit",style:{textAlign:"var(--Typography-textAlign)"}},{props:({ownerState:a})=>a.noWrap,style:{overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"}},{props:({ownerState:a})=>a.gutterBottom,style:{marginBottom:"0.35em"}}]})))),BC={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},FC=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiTypography"}),{color:v,align:O="inherit",className:A,component:I,gutterBottom:N=!1,noWrap:T=!1,variant:C="body1",variantMapping:X=BC,...V}=u,$={...u,align:O,color:v,className:A,component:I,gutterBottom:N,noWrap:T,variant:C,variantMapping:X},q=I||X[C]||BC[C]||"span",H=(G=>{const{align:Q,gutterBottom:ie,noWrap:ue,variant:fe,classes:me}=G;return or({root:["root",fe,G.align!=="inherit"&&`align${nn(Q)}`,ie&&"gutterBottom",ue&&"noWrap"]},C6,me)})($);return(0,Je.jsx)(A6,{as:q,ref:a,className:Pt(H.root,A),...V,ownerState:$,style:{...O!=="inherit"&&{"--Typography-textAlign":O},...V.style}})}));function Wa(t){return Wa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Wa(t)}function qC(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function Vt(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?qC(Object(u),!0).forEach((function(v){N6(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):qC(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function N6(t,a,u){return a=(function(v){var O=(function(A,I){if(Wa(A)!=="object"||A===null)return A;var N=A[Symbol.toPrimitive];if(N!==void 0){var T=N.call(A,"string");if(Wa(T)!=="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(A)})(v);return Wa(O)==="symbol"?O:String(O)})(a),a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function zC(t,a){(a==null||a>t.length)&&(a=t.length);for(var u=0,v=new Array(a);u<a;u++)v[u]=t[u];return v}const _i=function(t){var a=(function(N,T){return(function(C){if(Array.isArray(C))return C})(N)||(function(C,X){var V=C==null?null:typeof Symbol<"u"&&C[Symbol.iterator]||C["@@iterator"];if(V!=null){var $,q,H,G,Q=[],ie=!0,ue=!1;try{if(H=(V=V.call(C)).next,X!==0)for(;!(ie=($=H.call(V)).done)&&(Q.push($.value),Q.length!==X);ie=!0);}catch(fe){ue=!0,q=fe}finally{try{if(!ie&&V.return!=null&&(G=V.return(),Object(G)!==G))return}finally{if(ue)throw q}}return Q}})(N,T)||(function(C,X){if(C){if(typeof C=="string")return zC(C,X);var V=Object.prototype.toString.call(C).slice(8,-1);return V==="Object"&&C.constructor&&(V=C.constructor.name),V==="Map"||V==="Set"?Array.from(C):V==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(V)?zC(C,X):void 0}})(N,T)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
127
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,s.useState)(!1),2),u=a[0],v=a[1],O=(0,s.useCallback)((function(){t.dismissible&&(v(!0),t.onDismiss&&t.onDismiss())}),[t.dismissible,t.onDismiss]),A=(0,s.useMemo)((function(){switch(t.color){case"warning":return"warning";case"secondary":case"primary":case"info":default:return"info";case"danger":return"error";case"success":return"success"}}),[t.color]),I=(0,s.useMemo)((function(){if(t.classes){var N=t.classes.split(" "),T={};return N.forEach((function(C){switch(C){case"mx-auto":T=Vt(Vt({},T),{},{mx:"auto"});break;case"mt-5":T=Vt(Vt({},T),{},{mt:"3 rem"});break;case"mt-4":T=Vt(Vt({},T),{},{mt:"2.25 rem"});break;case"mt-2":T=Vt(Vt({},T),{},{mt:"1 rem"});break;case"m-0":T=Vt(Vt({},T),{},{m:"0"});break;case"mx-3":T=Vt(Vt({},T),{},{mx:"1.75 rem"});break;case"my-2":T=Vt(Vt({},T),{},{my:"1 rem"});break;case"my-3":T=Vt(Vt({},T),{},{my:"1.75 rem"});break;case"mb-3":T=Vt(Vt({},T),{},{mb:"1.75 rem"});break;case"mb-2":T=Vt(Vt({},T),{},{mb:"1 rem"});break;case"w-75":T=Vt(Vt({},T),{},{width:"75%"})}})),T}}),[t.classes]);return u?null:b().createElement(k6,{id:t.id,onClose:t.dismissible?O:void 0,severity:A,sx:I},t.title&&b().createElement(FC,{variant:"h6"},t.title),b().createElement(FC,{variant:"body2"},t.message))};var HC=function(t,a,u){return u?"".concat(u,": (").concat(t,") ").concat(a):"(".concat(t,") ").concat(a)},VC=function(t,a){return t.status?HC(t.status,t.message,a):t.Status?HC(t.Status,t.Message,a):a?"".concat(a,": ").concat(t):t};function xv(t){return xv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},xv(t)}var T6=function(t){var a=t.error;return a?a.constructor===Array?a.map((function(u){return b().createElement(_i,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:VC(u)})})):["object","string"].includes(xv(a))?b().createElement(_i,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:VC(a)}):void 0:null},UC=function(t){return b().createElement(J4,{id:t.id,size:t.size,className:t.className,isOpen:t.isOpen,scrollable:t.scrollable,backdrop:!t.noCancel||"static",toggle:t.onClose,onClosed:function(){t.onClosed&&t.onClosed()},onOpened:function(){t.onOpen&&t.onOpen()}},t.headerContent&&b().createElement(tD,{toggle:t.onClose},t.headerContent),b().createElement(T6,{error:t.error}),t.warning&&(Array.isArray(t.warning)?t.warning.map((function(a){return b().createElement(_i,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:a})})):b().createElement(_i,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:t.warning})),(t.content||t.disableSubmitMessage)&&b().createElement(oD,{className:t.bodyClassName},t.content,t.disableSubmit&&t.disableSubmitMessage&&b().createElement(_i,{id:"cm-disable-submit-message",message:t.disableSubmitMessage,color:"danger",dismissible:!1})),b().createElement(sD,null,t.customFooter?t.customFooter:b().createElement(b().Fragment,null,!t.noCancel&&b().createElement(ti,{key:"cancel-button",onClick:t.onClose},t.cancelButtonText),!t.noSubmit&&b().createElement(ti,{key:"submit-button",color:t.submitButtonColor,pending:t.pending,onClick:t.onSubmit,disabled:t.disableSubmit},t.submitButtonText))))};UC.defaultProps={scrollable:!1,pending:!1,disableSubmit:!1,noSubmit:!1,noCancel:!1,content:null,customFooter:null,bodyClassName:"",cancelButtonText:"Cancel",submitButtonText:"Submit",submitButtonColor:"primary",error:null,warning:null,className:"",disableSubmitMessage:""};const R6=UC,P6=Gn("MuiBox",["root"]),I6=vC(),M6=(function(t={}){const{themeId:a,defaultTheme:u,defaultClassName:v="MuiBox-root",generateClassName:O}=t,A=jk("div",{shouldForwardProp:I=>I!=="theme"&&I!=="sx"&&I!=="as"})(pi);return s.forwardRef((function(I,N){const T=hv(u),{className:C,component:X="div",...V}=I;return(0,Je.jsx)(A,{as:X,ref:N,className:Pt(C,O?O(v):v),theme:a&&T[a]||T,...V})}))})({themeId:dv,defaultTheme:I6,defaultClassName:P6.root,generateClassName:kC.generate}),Jl=M6,j6=tC(),L6=Fl(),D6=j6("div",{name:"MuiContainer",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[`maxWidth${Tl(String(u.maxWidth))}`],u.fixed&&a.fixed,u.disableGutters&&a.disableGutters]}}),B6=t=>(function({props:a,name:u,defaultTheme:v,themeId:O}){let A=hv(v);return O&&(A=A[O]||A),(function(I){const{theme:N,name:T,props:C}=I;return N&&N.components&&N.components[T]&&N.components[T].defaultProps?Gl(N.components[T].defaultProps,C):C})({theme:A,name:u,props:a})})({props:t,name:"MuiContainer",defaultTheme:L6}),F6=(function(t={}){const{createStyledComponent:a=D6,useThemeProps:u=B6,componentName:v="MuiContainer"}=t,O=a((({theme:I,ownerState:N})=>({width:"100%",marginLeft:"auto",boxSizing:"border-box",marginRight:"auto",...!N.disableGutters&&{paddingLeft:I.spacing(2),paddingRight:I.spacing(2),[I.breakpoints.up("sm")]:{paddingLeft:I.spacing(3),paddingRight:I.spacing(3)}}})),(({theme:I,ownerState:N})=>N.fixed&&Object.keys(I.breakpoints.values).reduce(((T,C)=>{const X=C,V=I.breakpoints.values[X];return V!==0&&(T[I.breakpoints.up(X)]={maxWidth:`${V}${I.breakpoints.unit}`}),T}),{})),(({theme:I,ownerState:N})=>({...N.maxWidth==="xs"&&{[I.breakpoints.up("xs")]:{maxWidth:Math.max(I.breakpoints.values.xs,444)}},...N.maxWidth&&N.maxWidth!=="xs"&&{[I.breakpoints.up(N.maxWidth)]:{maxWidth:`${I.breakpoints.values[N.maxWidth]}${I.breakpoints.unit}`}}})));return s.forwardRef((function(I,N){const T=u(I),{className:C,component:X="div",disableGutters:V=!1,fixed:$=!1,maxWidth:q="lg",classes:H,...G}=T,Q={...T,component:X,disableGutters:V,fixed:$,maxWidth:q},ie=((ue,fe)=>{const{classes:me,fixed:ve,disableGutters:ye,maxWidth:ce}=ue;return or({root:["root",ce&&`maxWidth${Tl(String(ce))}`,ve&&"fixed",ye&&"disableGutters"]},(Oe=>Wn(fe,Oe)),me)})(Q,v);return(0,Je.jsx)(O,{as:X,ownerState:Q,className:Pt(ie.root,C),ref:N,...G})}))})({createStyledComponent:Ft("div",{name:"MuiContainer",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[`maxWidth${nn(String(u.maxWidth))}`],u.fixed&&a.fixed,u.disableGutters&&a.disableGutters]}}),useThemeProps:t=>Vn({props:t,name:"MuiContainer"})}),q6=F6,z6=s.createContext(),WC=()=>s.useContext(z6)??!1,$l=function(t){const{elementType:a,externalSlotProps:u,ownerState:v,skipResolvingSlotProps:O=!1,...A}=t,I=O?{}:xC(u,v),{props:N,internalRef:T}=SC({...A,externalSlotProps:I}),C=Kl(T,I?.ref,t.additionalProps?.ref);return wC(a,{...N,ref:C},v)},GC=function(t,a=166){let u;function v(...O){clearTimeout(u),u=setTimeout((()=>{t.apply(this,O)}),a)}return v.clear=()=>{clearTimeout(u)},v};function H6(t){return(1+Math.sin(Math.PI*t-Math.PI/2))/2}const V6=Yl;function eu(t){return t&&t.ownerDocument||document}const KC=function(t){return eu(t).defaultView||window},U6={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll",pointerEvents:"none"},W6=io((0,Je.jsx)("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"})),G6=io((0,Je.jsx)("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}));function K6(t){return Wn("MuiTabScrollButton",t)}const Y6=Gn("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),X6=Ft(yv,{name:"MuiTabScrollButton",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.orientation&&a[u.orientation]]}})({width:40,flexShrink:0,opacity:.8,[`&.${Y6.disabled}`]:{opacity:0},variants:[{props:{orientation:"vertical"},style:{width:"100%",height:40,"& svg":{transform:"var(--TabScrollButton-svgRotate)"}}}]}),Z6=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiTabScrollButton"}),{className:v,slots:O={},slotProps:A={},direction:I,orientation:N,disabled:T,...C}=u,{nativeButton:X,...V}=C,$=WC(),q={isRtl:$,...u},H=(fe=>{const{classes:me,orientation:ve,disabled:ye}=fe;return or({root:["root",ve,ye&&"disabled"]},K6,me)})(q),G=O.StartScrollButtonIcon??W6,Q=O.EndScrollButtonIcon??G6,ie=$l({elementType:G,externalSlotProps:A.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:q}),ue=$l({elementType:Q,externalSlotProps:A.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:q});return(0,Je.jsx)(X6,{component:"div",className:Pt(H.root,v),ref:a,role:null,ownerState:q,tabIndex:null,...V,style:{...V.style,...N==="vertical"&&{"--TabScrollButton-svgRotate":`rotate(${$?-90:90}deg)`}},children:I==="left"?(0,Je.jsx)(G,{...ie}):(0,Je.jsx)(Q,{...ue})})}));function Q6(t){return Wn("MuiTabs",t)}const _v=Gn("MuiTabs",["root","vertical","list","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]);function Sv(t){let a=t.activeElement;for(;a?.shadowRoot?.activeElement!=null;)a=a.shadowRoot.activeElement;return a}const J6=Sv,$6=eu,eF=Object.is,YC=s.createContext(void 0);function XC(){const t=s.useContext(YC);if(t===void 0)throw new Error("MUI: RovingTabIndexContext is missing. Roving tab index items must be placed within a roving tab index provider.");return t}const tF=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown","Home","End"];function ZC(t,a,u,v){return t!=null?(function(O,A,I){const N=tA(A,O);return N===-1?$C(A,I):I(A[N])?A[N].id:JC(A,N,"next",!1,I)?.id??null})(t,a,u):(function(O,A,I){const N=I?.(O);if(N!=null){const T=eA(O,N);if(T&&A(T))return T.id}return $C(O,A)})(a,u,v)}function QC(t,a,u){if(a){const v=nA(t,a);if(v!==-1)return v}return tA(t,u)}function JC(t,a,u,v,O){const A=t.length-1;if(A===-1)return null;let I=!1,N=rA(a,A,u,v);const T=N;for(;N!==-1;){if(N===T){if(I)return null;I=!0}const C=t[N];if(C&&O(C))return C;N=rA(N,A,u,v)}return null}function $C(t,a){return t.find((u=>a(u)))?.id??null}function eA(t,a){return a==null?null:t.find((u=>u.id===a))??null}function tA(t,a){return a==null?-1:t.findIndex((u=>u.id===a))}function nA(t,a){return a?t.findIndex((u=>u.element===a||u.element?.contains(a))):-1}function Ev(t){const a=Array.from(t.values());return a.every((v=>v.element==null))?a:[...a.filter(Ov).sort(((v,O)=>(function(A,I){if(A===I)return 0;const N=A.compareDocumentPosition(I);return N&Node.DOCUMENT_POSITION_FOLLOWING||N&Node.DOCUMENT_POSITION_CONTAINED_BY?-1:N&Node.DOCUMENT_POSITION_PRECEDING||N&Node.DOCUMENT_POSITION_CONTAINS?1:0})(v.element,O.element))),...a.filter((v=>!Ov(v)))]}function tu(t){return Ev(t).filter(Ov)}function rA(t,a,u,v=!0){return u==="next"?t===a?v?0:-1:t+1:t===0?v?a:-1:t-1}function nF(t){return!!t.element&&(!!t.focusableWhenDisabled||!t.disabled&&!t.element.hasAttribute("disabled")&&t.element.getAttribute("aria-disabled")!=="true"&&t.element.hasAttribute("tabindex"))}function Ov(t){return t.element!=null&&t.element.isConnected}function rF(...t){return a=>{t.forEach((u=>{(function(v,O){typeof v=="function"?v(O):v&&(v.current=O)})(u??null,a)}))}}const oF=Ft("div",{name:"MuiTabs",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[{[`& .${_v.scrollButtons}`]:a.scrollButtons},{[`& .${_v.scrollButtons}`]:u.scrollButtonsHideMobile&&a.scrollButtonsHideMobile},a.root,u.vertical&&a.vertical]}})(Hn((({theme:t})=>({overflow:"hidden",minHeight:48,WebkitOverflowScrolling:"touch",display:"flex",variants:[{props:({ownerState:a})=>a.vertical,style:{flexDirection:"column"}},{props:({ownerState:a})=>a.scrollButtonsHideMobile,style:{[`& .${_v.scrollButtons}`]:{[t.breakpoints.down("sm")]:{display:"none"}}}}]})))),iF=Ft("div",{name:"MuiTabs",slot:"Scroller",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.scroller,u.fixed&&a.fixed,u.hideScrollbar&&a.hideScrollbar,u.scrollableX&&a.scrollableX,u.scrollableY&&a.scrollableY]}})({position:"relative",display:"inline-block",flex:"1 1 auto",whiteSpace:"nowrap",variants:[{props:({ownerState:t})=>t.fixed,style:{overflowX:"hidden",width:"100%"}},{props:({ownerState:t})=>t.hideScrollbar,style:{scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}},{props:({ownerState:t})=>t.scrollableX,style:{overflowX:"auto",overflowY:"hidden"}},{props:({ownerState:t})=>t.scrollableY,style:{overflowY:"auto",overflowX:"hidden"}}]}),aF=Ft("div",{name:"MuiTabs",slot:"List",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.list,u.centered&&a.centered]}})({display:"flex",variants:[{props:({ownerState:t})=>t.vertical,style:{flexDirection:"column"}},{props:({ownerState:t})=>t.centered,style:{justifyContent:"center"}}]}),sF=Ft("span",{name:"MuiTabs",slot:"Indicator"})(Hn((({theme:t})=>({position:"absolute",height:2,bottom:0,width:"100%",transition:t.transitions.create(),variants:[{props:{indicatorColor:"primary"},style:{backgroundColor:(t.vars||t).palette.primary.main}},{props:{indicatorColor:"secondary"},style:{backgroundColor:(t.vars||t).palette.secondary.main}},{props:({ownerState:a})=>a.vertical,style:{height:"100%",width:2,right:0}}]})))),lF=Ft((function(t){const{onChange:a,...u}=t,v=s.useRef(),O=s.useRef(null),A=()=>{v.current=O.current.offsetHeight-O.current.clientHeight};return V6((()=>{const I=GC((()=>{const T=v.current;A(),T!==v.current&&a(v.current)})),N=KC(O.current);return N.addEventListener("resize",I),()=>{I.clear(),N.removeEventListener("resize",I)}}),[a]),s.useEffect((()=>{A(),a(v.current)}),[a]),(0,Je.jsx)("div",{style:U6,...u,ref:O})}))({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),oA={},uF=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiTabs"}),v=EC(),O=WC(),{"aria-label":A,"aria-labelledby":I,action:N,centered:T=!1,children:C,className:X,component:V="div",allowScrollButtonsMobile:$=!1,indicatorColor:q="primary",onChange:H,orientation:G="horizontal",scrollButtons:Q="auto",selectionFollowsFocus:ie,slots:ue={},slotProps:fe={},textColor:me="primary",value:ve,variant:ye="standard",visibleScrollbar:ce=!1,...Oe}=u,Me=ye==="scrollable",_e=G==="vertical",je=_e?"scrollTop":"scrollLeft",Ne=_e?"top":"left",Te=_e?"bottom":"right",ze=_e?"clientHeight":"clientWidth",Le=_e?"height":"width",ke={...u,component:V,allowScrollButtonsMobile:$,indicatorColor:q,orientation:G,vertical:_e,scrollButtons:Q,textColor:me,variant:ye,visibleScrollbar:ce,fixed:!Me,hideScrollbar:Me&&!ce,scrollableX:Me&&!_e,scrollableY:Me&&_e,centered:T&&!Me,scrollButtonsHideMobile:!$},Ke=(Ge=>{const{vertical:He,fixed:rt,hideScrollbar:st,scrollableX:Ze,scrollableY:At,centered:an,scrollButtonsHideMobile:mn,classes:sr}=Ge;return or({root:["root",He&&"vertical"],scroller:["scroller",rt&&"fixed",st&&"hideScrollbar",Ze&&"scrollableX",At&&"scrollableY"],list:["list",He&&"vertical",an&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",mn&&"scrollButtonsHideMobile"],scrollableX:[Ze&&"scrollableX"],hideScrollbar:[st&&"hideScrollbar"]},Q6,sr)})(ke),$e=$l({elementType:ue.startScrollButtonIcon,externalSlotProps:fe.startScrollButtonIcon,ownerState:ke}),dt=$l({elementType:ue.endScrollButtonIcon,externalSlotProps:fe.endScrollButtonIcon,ownerState:ke}),[lt,gt]=s.useState(!1),[Xe,le]=s.useState(oA),[qe,Ie]=s.useState(!1),[Ye,it]=s.useState(!1),[at,bt]=s.useState(!1),kt=ve===!1?null:ve,[Zt,Qt]=s.useState(!1),[rn,En]=s.useState({overflow:"hidden",scrollbarWidth:0}),on=new Map,St=s.useRef(null),Gt=s.useRef(null),On={slots:ue,slotProps:fe},ar=()=>{const Ge=St.current;let He,rt;if(Ge){const st=Ge.getBoundingClientRect();He={clientWidth:Ge.clientWidth,scrollLeft:Ge.scrollLeft,scrollTop:Ge.scrollTop,scrollWidth:Ge.scrollWidth,top:st.top,bottom:st.bottom,left:st.left,right:st.right}}if(Ge&&ve!==!1){const st=Gt.current.children;if(st.length>0){const Ze=st[on.get(ve)];rt=Ze?Ze.getBoundingClientRect():null}}return{tabsMeta:He,tabMeta:rt}},Ct=To((()=>{const{tabsMeta:Ge,tabMeta:He}=ar();let rt,st=0;_e?(rt="top",He&&Ge&&(st=He.top-Ge.top+Ge.scrollTop)):(rt=O?"right":"left",He&&Ge&&(st=(O?-1:1)*(He[rt]-Ge[rt]+Ge.scrollLeft)));const Ze={[rt]:st,[Le]:He?He[Le]:0};if(typeof Xe[rt]!="number"||typeof Xe[Le]!="number")le(Ze);else{const At=Math.abs(Xe[rt]-Ze[rt]),an=Math.abs(Xe[Le]-Ze[Le]);(At>=1||an>=1)&&le(Ze)}})),dn=(Ge,{animation:He=!0}={})=>{He?(function(rt,st,Ze,At={},an=(()=>{})){const{ease:mn=H6,duration:sr=300}=At;let ji=null;const Li=st[rt],lo=Pn=>{ji===null&&(ji=Pn);const Tu=Math.min(1,(Pn-ji)/sr);st[rt]=mn(Tu)*(Ze-Li)+Li,Tu>=1?requestAnimationFrame((()=>{an(null)})):requestAnimationFrame(lo)};Li===Ze?an(new Error("Element already at target position")):requestAnimationFrame(lo)})(je,St.current,Ge,{duration:v.transitions.duration.standard}):St.current[je]=Ge},Jt=Ge=>{let He=St.current[je];He+=_e?Ge:Ge*(O?-1:1),dn(He)},Hr=()=>{const Ge=St.current[ze];let He=0;const rt=Array.from(Gt.current.children);for(let st=0;st<rt.length;st+=1){const Ze=rt[st];if(He+Ze[ze]>Ge){st===0&&(He=Ge);break}He+=Ze[ze]}return He},jo=()=>{Jt(-1*Hr())},Rn=()=>{Jt(Hr())},[Xn,{onChange:xr,...Ti}]=Un("scrollbar",{className:Pt(Ke.scrollableX,Ke.hideScrollbar),elementType:lF,shouldForwardComponentProp:!0,externalForwardedProps:On,ownerState:ke}),Ri=s.useCallback((Ge=>{xr?.(Ge),En({overflow:null,scrollbarWidth:Ge})}),[xr]),[Eu,$a]=Un("scrollButtons",{className:Ke.scrollButtons,elementType:Z6,externalForwardedProps:On,ownerState:ke,additionalProps:{orientation:G,slots:{StartScrollButtonIcon:ue.startScrollButtonIcon,EndScrollButtonIcon:ue.endScrollButtonIcon},slotProps:{startScrollButtonIcon:$e,endScrollButtonIcon:dt}}}),Ou=To((Ge=>{const{tabsMeta:He,tabMeta:rt}=ar();if(rt&&He){if(rt[Ne]<He[Ne]){const st=He[je]+(rt[Ne]-He[Ne]);dn(st,{animation:Ge})}else if(rt[Te]>He[Te]){const st=He[je]+(rt[Te]-He[Te]);dn(st,{animation:Ge})}}})),Et=To((()=>{Me&&Q!==!1&&bt(!at)}));s.useEffect((()=>{const Ge=GC((()=>{St.current&&Ct()}));let He;const rt=KC(St.current);let st;return rt.addEventListener("resize",Ge),typeof ResizeObserver<"u"&&(He=new ResizeObserver(Ge),Array.from(Gt.current.children).forEach((Ze=>{He.observe(Ze)}))),typeof MutationObserver<"u"&&(st=new MutationObserver((Ze=>{Ze.forEach((At=>{At.removedNodes.forEach((an=>{He?.unobserve(an)})),At.addedNodes.forEach((an=>{He?.observe(an)}))})),Ge(),Et()})),st.observe(Gt.current,{childList:!0})),()=>{Ge.clear(),rt.removeEventListener("resize",Ge),st?.disconnect(),He?.disconnect()}}),[Ct,Et]),s.useEffect((()=>{const Ge=Array.from(Gt.current.children),He=Ge.length;if(typeof IntersectionObserver<"u"&&He>0&&Me&&Q!==!1){const rt=Ge[0],st=Ge[He-1],Ze={root:St.current,threshold:.99},At=new IntersectionObserver((mn=>{Ie(!mn[0].isIntersecting)}),Ze);At.observe(rt);const an=new IntersectionObserver((mn=>{it(!mn[0].isIntersecting)}),Ze);return an.observe(st),()=>{At.disconnect(),an.disconnect()}}}),[Me,Q,at,C?.length]),s.useEffect((()=>{gt(!0)}),[]),s.useEffect((()=>{Ct()})),s.useEffect((()=>{Ou(oA!==Xe)}),[Ou,Xe]),s.useImperativeHandle(N,(()=>({updateIndicator:Ct,updateScrollButtons:Et})),[Ct,Et]);const[Vr,bn]=Un("indicator",{className:Ke.indicator,elementType:sF,externalForwardedProps:On,ownerState:ke,additionalProps:{style:Xe}}),Ur=(0,Je.jsx)(Vr,{...bn}),so=(function(Ge){const{activeItemId:He,getDefaultActiveItemId:rt,orientation:st,isRtl:Ze=!1,isItemFocusable:At=nF,wrap:an=!0}=Ge,[mn,sr]=s.useState(He),ji=s.useRef(He);let Li=mn;He!==ji.current&&(ji.current=He,He!==void 0&&He!==mn&&(Li=He,sr(He)));const lo=s.useRef(null),Pn=s.useRef(new Map),[Tu,qN]=s.useState(0),Ru=ZC(Li,s.useMemo((()=>Ev(Pn.current)),[Tu]),At,rt),ts=s.useRef(Ru);ts.current=Ru;const zN=s.useCallback((()=>{const sn=Ev(Pn.current);return eA(sn,ZC(ts.current,sn,At,rt))}),[rt,At]),HN=s.useCallback((()=>Pn.current),[]),VN=Xl((sn=>{(function(Nt,gn){if(Nt===gn)return!0;if(!(Nt instanceof Object&&gn instanceof Object))return!1;let Zn=0,lr=0;for(const Lo in Nt)if(Zn+=1,!eF(Nt[Lo],gn[Lo])||!(Lo in gn))return!1;for(const Lo in gn)lr+=1;return Zn===lr})(Pn.current.get(sn.id)??null,sn)||(Pn.current.set(sn.id,sn),qN((Nt=>Nt+1)))})),UN=Xl((sn=>{Pn.current.delete(sn)&&qN((Nt=>Nt+1))})),WN=Xl((sn=>{sr(sn)})),GN=s.useCallback((sn=>ts.current===sn),[]),Pu=s.useCallback(((sn,Nt,gn,Zn)=>{const lr=JC(tu(Pn.current),sn,Nt,gn,Zn??At);return lr?(lr.element?.focus(),sr(lr.id),lr):null}),[At]),KN=s.useCallback((sn=>({onFocus:Nt=>{const gn=tu(Pn.current),Zn=nA(gn,Nt.target);Zn!==-1&&sr(gn[Zn].id)},onKeyDown:Nt=>{if(Nt.altKey||Nt.shiftKey||Nt.ctrlKey||Nt.metaKey||!tF.includes(Nt.key))return;let gn=st==="horizontal"?"ArrowLeft":"ArrowUp",Zn=st==="horizontal"?"ArrowRight":"ArrowDown";st==="horizontal"&&Ze&&(gn="ArrowRight",Zn="ArrowLeft");const lr=tu(Pn.current),Lo=Sv(eu(lo.current)),XN=Lo===lo.current;let ns=QC(lr,Lo,ts.current),ly="next";switch(Nt.key){case gn:ly="previous",Nt.preventDefault(),XN&&(ns=lr.length);break;case Zn:Nt.preventDefault(),XN&&(ns=-1);break;case"Home":Nt.preventDefault(),ns=-1;break;case"End":Nt.preventDefault(),ly="previous",ns=lr.length;break;default:return}Pu(ns,ly,an)},ref:rF(sn,(Nt=>{lo.current=Nt}))})),[Pu,Ze,st,an]),YN=s.useCallback((sn=>{const Nt=tu(Pn.current),gn=Sv(eu(lo.current)),Zn=gn===lo.current?-1:QC(Nt,gn,ts.current);return Pu(Zn,"next",!0,sn)?.id??null}),[Pu]);return s.useMemo((()=>({activeItemId:Ru,focusNext:YN,getActiveItem:zN,getContainerProps:KN,getItemMap:HN,isItemActive:GN,registerItem:VN,setActiveItemId:WN,unregisterItem:UN})),[Ru,YN,zN,KN,HN,GN,VN,WN,UN])})({activeItemId:Zt?void 0:kt,orientation:G,isRtl:O}),Wr=so.getContainerProps(),Pi=s.Children.toArray(C).filter(s.isValidElement).map(((Ge,He)=>{const rt=Ge.props.value===void 0?He:Ge.props.value;return on.set(rt,He),{child:Ge,index:He,childValue:rt}})),ku=Pi.map((({child:Ge,childValue:He})=>{const rt=He===ve;return s.cloneElement(Ge,{fullWidth:ye==="fullWidth",indicator:rt&&!lt&&Ur,selected:rt,selectionFollowsFocus:ie,onChange:H,textColor:me,value:He})})),Ii=(()=>{const Ge={};Ge.scrollbarSizeListener=Me?(0,Je.jsx)(Xn,{...Ti,onChange:Ri}):null;const He=Me&&(Q==="auto"&&(qe||Ye)||Q===!0);return Ge.scrollButtonStart=He?(0,Je.jsx)(Eu,{direction:O?"right":"left",onClick:jo,disabled:!qe,...$a}):null,Ge.scrollButtonEnd=He?(0,Je.jsx)(Eu,{direction:O?"left":"right",onClick:Rn,disabled:!Ye,...$a}):null,Ge})(),[Cu,Au]=Un("root",{ref:a,className:Pt(Ke.root,X),elementType:oF,externalForwardedProps:{...On,...Oe,component:V},ownerState:ke}),[_r,Mi]=Un("scroller",{ref:St,className:Ke.scroller,elementType:iF,externalForwardedProps:On,ownerState:ke,additionalProps:{style:{overflow:rn.overflow,[_e?"margin"+(O?"Left":"Right"):"marginBottom"]:ce?void 0:-rn.scrollbarWidth}}}),es=pv(Wr.ref,Gt),[Nu,hn]=Un("list",{ref:es,className:Ke.list,elementType:aF,externalForwardedProps:On,ownerState:ke,getSlotProps:Ge=>({...Ge,onBlur:He=>{(function(rt,st){if(!rt||!st)return!1;if(rt.contains(st))return!0;const Ze=st.getRootNode?.();if(Ze&&Ze instanceof ShadowRoot){let At=st;for(;At;){if(rt===At)return!0;At=At.parentNode??At.host??null}}return!1})(He.currentTarget,He.relatedTarget)||Qt(!1),Ge.onBlur?.(He)},onKeyDown:He=>{(rt=>{const st=Gt.current;J6($6(st))?.getAttribute("role")==="tab"&&Wr.onKeyDown(rt)})(He),Ge.onKeyDown?.(He)},onFocus:He=>{Qt(!0),Wr.onFocus(He),Ge.onFocus?.(He)}})});return(0,Je.jsxs)(Cu,{...Au,children:[Ii.scrollButtonStart,Ii.scrollbarSizeListener,(0,Je.jsxs)(_r,{...Mi,children:[(0,Je.jsx)(Nu,{"aria-label":A,"aria-labelledby":I,"aria-orientation":G==="vertical"?"vertical":null,role:"tablist",...hn,children:(0,Je.jsx)(YC.Provider,{value:so,children:ku})}),lt&&Ur]}),Ii.scrollButtonEnd]})})),cF=uF;function fF(t){return Wn("MuiTab",t)}const ir=Gn("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","icon"]),dF=Ft(yv,{name:"MuiTab",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.label&&u.icon&&a.labelIcon,a[`textColor${nn(u.textColor)}`],u.fullWidth&&a.fullWidth,u.wrapped&&a.wrapped,{[`& .${ir.icon}`]:a.icon}]}})(Hn((({theme:t})=>({...t.typography.button,maxWidth:360,minWidth:90,position:"relative",minHeight:48,flexShrink:0,padding:"12px 16px",overflow:"hidden",whiteSpace:"normal",textAlign:"center",lineHeight:1.25,variants:[{props:({ownerState:a})=>a.label&&(a.iconPosition==="top"||a.iconPosition==="bottom"),style:{flexDirection:"column"}},{props:({ownerState:a})=>a.label&&a.iconPosition!=="top"&&a.iconPosition!=="bottom",style:{flexDirection:"row"}},{props:({ownerState:a})=>a.icon&&a.label,style:{minHeight:72,paddingTop:9,paddingBottom:9}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="top",style:{[`& > .${ir.icon}`]:{marginBottom:6}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="bottom",style:{[`& > .${ir.icon}`]:{marginTop:6}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="start",style:{[`& > .${ir.icon}`]:{marginRight:t.spacing(1)}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="end",style:{[`& > .${ir.icon}`]:{marginLeft:t.spacing(1)}}},{props:{textColor:"inherit"},style:{color:"inherit",opacity:.6,[`&.${ir.selected}`]:{opacity:1},[`&.${ir.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity}}},{props:{textColor:"primary"},style:{color:(t.vars||t).palette.text.secondary,[`&.${ir.selected}`]:{color:(t.vars||t).palette.primary.main},[`&.${ir.disabled}`]:{color:(t.vars||t).palette.text.disabled}}},{props:{textColor:"secondary"},style:{color:(t.vars||t).palette.text.secondary,[`&.${ir.selected}`]:{color:(t.vars||t).palette.secondary.main},[`&.${ir.disabled}`]:{color:(t.vars||t).palette.text.disabled}}},{props:({ownerState:a})=>a.fullWidth,style:{flexShrink:1,flexGrow:1,flexBasis:0,maxWidth:"none"}},{props:({ownerState:a})=>a.wrapped,style:{fontSize:t.typography.pxToRem(12)}}]})))),hF=s.forwardRef((function(t,a){const u=Vn({props:t,name:"MuiTab"}),{className:v,disabled:O=!1,disableFocusRipple:A=!1,fullWidth:I,icon:N,iconPosition:T="top",indicator:C,label:X,onChange:V,onClick:$,onFocus:q,selected:H,selectionFollowsFocus:G,textColor:Q="inherit",value:ie,wrapped:ue=!1,...fe}=u,me=XC(),ve=(function(_e){const je=XC(),{activeItemId:Ne,registerItem:Te,unregisterItem:ze}=je,Le=s.useRef(null),ke=s.useMemo((()=>({disabled:_e.disabled??!1,element:null,focusableWhenDisabled:_e.focusableWhenDisabled??!1,id:_e.id,selected:_e.selected??!1,textValue:_e.textValue})),[_e.disabled,_e.focusableWhenDisabled,_e.id,_e.selected,_e.textValue]),Ke=s.useRef(ke);Ke.current=ke;const $e=s.useCallback((lt=>{Le.current=lt,lt!=null?Te({...Ke.current,element:lt}):queueMicrotask((()=>{Le.current==null&&ze(_e.id)}))}),[_e.id,Te,ze]),dt=Kl(_e.ref,$e);return Yl((()=>{Le.current&&Te({...ke,element:Le.current})}),[ke,Te]),Yl((()=>{const lt=_e.id;return()=>{ze(lt)}}),[_e.id,ze]),{ref:dt,tabIndex:Ne===_e.id?0:-1}})({id:ie,ref:a,disabled:O,selected:H}),ye=me.getItemMap().size===0&&H?0:ve.tabIndex,ce={...u,disabled:O,disableFocusRipple:A,selected:H,icon:!!N,iconPosition:T,label:!!X,fullWidth:I,textColor:Q,wrapped:ue},Oe=(_e=>{const{classes:je,textColor:Ne,fullWidth:Te,wrapped:ze,icon:Le,label:ke,selected:Ke,disabled:$e}=_e;return or({root:["root",Le&&ke&&"labelIcon",`textColor${nn(Ne)}`,Te&&"fullWidth",ze&&"wrapped",Ke&&"selected",$e&&"disabled"],icon:["icon"]},fF,je)})(ce),Me=N&&X&&s.isValidElement(N)?s.cloneElement(N,{className:Pt(Oe.icon,N.props.className)}):N;return(0,Je.jsxs)(dF,{internalNativeButton:!0,focusRipple:!A,className:Pt(Oe.root,v),ref:ve.ref,role:"tab","aria-selected":H,disabled:O,onClick:_e=>{!H&&V&&V(_e,ie),$&&$(_e)},onFocus:_e=>{G&&!H&&V&&V(_e,ie),q&&q(_e)},tabIndex:ye,ownerState:ce,...fe,children:[T==="top"||T==="start"?(0,Je.jsxs)(s.Fragment,{children:[Me,X]}):(0,Je.jsxs)(s.Fragment,{children:[X,Me]}),C]})})),pF=io((0,Je.jsx)("path",{d:"M19 6.41 17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z"}));function iA(t,a){(a==null||a>t.length)&&(a=t.length);for(var u=0,v=new Array(a);u<a;u++)v[u]=t[u];return v}const mF=function(t){var a=t.activeTab,u=t.tabs,v=t.onChange,O=v===void 0?function(){}:v,A=t.enableTabClose,I=A!==void 0&&A,N=t.onClose,T=N===void 0?function(){}:N,C=(function(q,H){return(function(G){if(Array.isArray(G))return G})(q)||(function(G,Q){var ie=G==null?null:typeof Symbol<"u"&&G[Symbol.iterator]||G["@@iterator"];if(ie!=null){var ue,fe,me,ve,ye=[],ce=!0,Oe=!1;try{if(me=(ie=ie.call(G)).next,Q!==0)for(;!(ce=(ue=me.call(ie)).done)&&(ye.push(ue.value),ye.length!==Q);ce=!0);}catch(Me){Oe=!0,fe=Me}finally{try{if(!ce&&ie.return!=null&&(ve=ie.return(),Object(ve)!==ve))return}finally{if(Oe)throw fe}}return ye}})(q,H)||(function(G,Q){if(G){if(typeof G=="string")return iA(G,Q);var ie=Object.prototype.toString.call(G).slice(8,-1);return ie==="Object"&&G.constructor&&(ie=G.constructor.name),ie==="Map"||ie==="Set"?Array.from(G):ie==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(ie)?iA(G,Q):void 0}})(q,H)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
128
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,s.useState)(a),2),X=C[0],V=C[1];(0,s.useEffect)((function(){V(a)}),[a]);var $=u.filter((function(q){return!q.hideTab}));return b().createElement(Jl,null,b().createElement(q6,{maxWidth:"md"},b().createElement(cF,{value:X,onChange:function(q,H){V(H),O(H)}},$.map((function(q){return b().createElement(hF,{key:q.key,value:q.key,label:b().createElement(Jl,{sx:{display:"flex",alignItems:"center",gap:.5}},q.label,I&&b().createElement(MC,{size:"small",onClick:function(H){H.stopPropagation(),T(q.key)},sx:{ml:.5,p:.25}},b().createElement(pF,{fontSize:"inherit"})))})})))),b().createElement(Jl,{sx:{borderTop:1,borderColor:"divider"}},$.map((function(q){return X===q.key?b().createElement(Jl,{key:q.key,role:"tabpanel"},q.content):null}))))};var nu=d(525),Si={};Si.styleTagTransform=xa(),Si.setAttributes=ba(),Si.insert=ya().bind(null,"head"),Si.domAPI=va(),Si.insertStyleElement=wa(),ga()(nu.Z,Si),nu.Z&&nu.Z.locals&&nu.Z.locals;var aA=function(t){return b().createElement("section",{className:"keyval__wrapper"},b().createElement("span",{className:"keyval__label",style:{minWidth:t.labelWidth}},t.label),b().createElement("ul",{className:"keyval__list"},t.items.map((function(a){return b().createElement("li",{key:String(a),className:"keyval__item"},a)}))))};aA.defaultProps={labelWidth:100};const gF=aA,ru=Array.isArray||function(t){return t!=null&&t.length>=0&&Object.prototype.toString.call(t)==="[object Array]"};function sA(t,a,u){return function(){if(arguments.length===0)return u();var v=arguments[arguments.length-1];if(!ru(v)){for(var O=0;O<t.length;){if(typeof v[t[O]]=="function")return v[t[O]].apply(v,Array.prototype.slice.call(arguments,0,-1));O+=1}if((function(A){return A!=null&&typeof A["@@transducer/step"]=="function"})(v))return a.apply(null,Array.prototype.slice.call(arguments,0,-1))(v)}return u.apply(this,arguments)}}const lA=function(){return this.xf["@@transducer/init"]()};function Lt(t){return t!=null&&typeof t=="object"&&t["@@functional/placeholder"]===!0}function yn(t){return function a(u){return arguments.length===0||Lt(u)?a:t.apply(this,arguments)}}function Yn(t){return function a(u,v){switch(arguments.length){case 0:return a;case 1:return Lt(u)?a:yn((function(O){return t(u,O)}));default:return Lt(u)&&Lt(v)?a:Lt(u)?yn((function(O){return t(O,v)})):Lt(v)?yn((function(O){return t(u,O)})):t(u,v)}}}function uA(t){for(var a,u=[];!(a=t.next()).done;)u.push(a.value);return u}function cA(t,a,u){for(var v=0,O=u.length;v<O;){if(t(a,u[v]))return!0;v+=1}return!1}function Ei(t,a){return Object.prototype.hasOwnProperty.call(a,t)}const kv=typeof Object.is=="function"?Object.is:function(t,a){return t===a?t!==0||1/t==1/a:t!=t&&a!=a};var fA=Object.prototype.toString;const dA=(function(){return fA.call(arguments)==="[object Arguments]"?function(t){return fA.call(t)==="[object Arguments]"}:function(t){return Ei("callee",t)}})();var vF=!{toString:null}.propertyIsEnumerable("toString"),hA=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],pA=(function(){return arguments.propertyIsEnumerable("length")})(),yF=function(t,a){for(var u=0;u<t.length;){if(t[u]===a)return!0;u+=1}return!1};const mA=yn(typeof Object.keys!="function"||pA?(function(t){if(Object(t)!==t)return[];var a,u,v=[],O=pA&&dA(t);for(a in t)!Ei(a,t)||O&&a==="length"||(v[v.length]=a);if(vF)for(u=hA.length-1;u>=0;)Ei(a=hA[u],t)&&!yF(v,a)&&(v[v.length]=a),u-=1;return v}):(function(t){return Object(t)!==t?[]:Object.keys(t)})),Cv=yn((function(t){return t===null?"Null":t===void 0?"Undefined":Object.prototype.toString.call(t).slice(8,-1)}));function gA(t,a,u,v){var O=uA(t);function A(I,N){return Av(I,N,u.slice(),v.slice())}return!cA((function(I,N){return!cA(A,N,I)}),uA(a),O)}function Av(t,a,u,v){if(kv(t,a))return!0;var O,A,I=Cv(t);if(I!==Cv(a))return!1;if(typeof t["fantasy-land/equals"]=="function"||typeof a["fantasy-land/equals"]=="function")return typeof t["fantasy-land/equals"]=="function"&&t["fantasy-land/equals"](a)&&typeof a["fantasy-land/equals"]=="function"&&a["fantasy-land/equals"](t);if(typeof t.equals=="function"||typeof a.equals=="function")return typeof t.equals=="function"&&t.equals(a)&&typeof a.equals=="function"&&a.equals(t);switch(I){case"Arguments":case"Array":case"Object":if(typeof t.constructor=="function"&&(O=t.constructor,((A=String(O).match(/^function (\w*)/))==null?"":A[1])==="Promise"))return t===a;break;case"Boolean":case"Number":case"String":if(typeof t!=typeof a||!kv(t.valueOf(),a.valueOf()))return!1;break;case"Date":if(!kv(t.valueOf(),a.valueOf()))return!1;break;case"Error":return t.name===a.name&&t.message===a.message;case"RegExp":if(t.source!==a.source||t.global!==a.global||t.ignoreCase!==a.ignoreCase||t.multiline!==a.multiline||t.sticky!==a.sticky||t.unicode!==a.unicode)return!1}for(var N=u.length-1;N>=0;){if(u[N]===t)return v[N]===a;N-=1}switch(I){case"Map":return t.size===a.size&&gA(t.entries(),a.entries(),u.concat([t]),v.concat([a]));case"Set":return t.size===a.size&&gA(t.values(),a.values(),u.concat([t]),v.concat([a]));case"Arguments":case"Array":case"Object":case"Boolean":case"Number":case"String":case"Date":case"Error":case"RegExp":case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"ArrayBuffer":break;default:return!1}var T=mA(t);if(T.length!==mA(a).length)return!1;var C=u.concat([t]),X=v.concat([a]);for(N=T.length-1;N>=0;){var V=T[N];if(!Ei(V,a)||!Av(a[V],t[V],C,X))return!1;N-=1}return!0}const vA=Yn((function(t,a){return Av(t,a,[],[])}));function yA(t,a){switch(t){case 0:return function(){return a.apply(this,arguments)};case 1:return function(u){return a.apply(this,arguments)};case 2:return function(u,v){return a.apply(this,arguments)};case 3:return function(u,v,O){return a.apply(this,arguments)};case 4:return function(u,v,O,A){return a.apply(this,arguments)};case 5:return function(u,v,O,A,I){return a.apply(this,arguments)};case 6:return function(u,v,O,A,I,N){return a.apply(this,arguments)};case 7:return function(u,v,O,A,I,N,T){return a.apply(this,arguments)};case 8:return function(u,v,O,A,I,N,T,C){return a.apply(this,arguments)};case 9:return function(u,v,O,A,I,N,T,C,X){return a.apply(this,arguments)};case 10:return function(u,v,O,A,I,N,T,C,X,V){return a.apply(this,arguments)};default:throw new Error("First argument to _arity must be a non-negative integer no greater than ten")}}function bA(t,a,u){return function(){for(var v=[],O=0,A=t,I=0;I<a.length||O<arguments.length;){var N;I<a.length&&(!Lt(a[I])||O>=arguments.length)?N=a[I]:(N=arguments[O],O+=1),v[I]=N,Lt(N)||(A-=1),I+=1}return A<=0?u.apply(this,v):yA(A,bA(t,v,u))}}const bF=Number.isInteger||function(t){return t<<0===t};function Nv(t){return Object.prototype.toString.call(t)==="[object String]"}const wF=Yn((function(t,a){var u=t<0?a.length+t:t;return Nv(a)?a.charAt(u):a[u]})),xF=Yn((function(t,a){if(a!=null)return bF(t)?wF(t,a):a[t]}));function _F(t){return function a(u,v,O){switch(arguments.length){case 0:return a;case 1:return Lt(u)?a:Yn((function(A,I){return t(u,A,I)}));case 2:return Lt(u)&&Lt(v)?a:Lt(u)?Yn((function(A,I){return t(A,v,I)})):Lt(v)?Yn((function(A,I){return t(u,A,I)})):yn((function(A){return t(u,v,A)}));default:return Lt(u)&&Lt(v)&&Lt(O)?a:Lt(u)&&Lt(v)?Yn((function(A,I){return t(A,I,O)})):Lt(u)&&Lt(O)?Yn((function(A,I){return t(A,v,I)})):Lt(v)&&Lt(O)?Yn((function(A,I){return t(u,A,I)})):Lt(u)?yn((function(A){return t(A,v,O)})):Lt(v)?yn((function(A){return t(u,A,O)})):Lt(O)?yn((function(A){return t(u,v,A)})):t(u,v,O)}}}const SF=yn((function(t){return!!ru(t)||!!t&&typeof t=="object"&&!Nv(t)&&(t.length===0||t.length>0&&t.hasOwnProperty(0)&&t.hasOwnProperty(t.length-1))}));var wA=typeof Symbol<"u"?Symbol.iterator:"@@iterator";function EF(t,a,u){return function(v,O,A){if(SF(A))return t(v,O,A);if(A==null)return O;if(typeof A["fantasy-land/reduce"]=="function")return a(v,O,A,"fantasy-land/reduce");if(A[wA]!=null)return u(v,O,A[wA]());if(typeof A.next=="function")return u(v,O,A);if(typeof A.reduce=="function")return a(v,O,A,"reduce");throw new TypeError("reduce: list must be array or iterable")}}function OF(t,a,u){for(var v=0,O=u.length;v<O;){if((a=t["@@transducer/step"](a,u[v]))&&a["@@transducer/reduced"]){a=a["@@transducer/value"];break}v+=1}return t["@@transducer/result"](a)}const kF=Yn((function(t,a){return yA(t.length,(function(){return t.apply(a,arguments)}))}));function CF(t,a,u){for(var v=u.next();!v.done;){if((a=t["@@transducer/step"](a,v.value))&&a["@@transducer/reduced"]){a=a["@@transducer/value"];break}v=u.next()}return t["@@transducer/result"](a)}function AF(t,a,u,v){return t["@@transducer/result"](u[v](kF(t["@@transducer/step"],t),a))}const NF=EF(OF,AF,CF);var TF=(function(){function t(a){this.f=a}return t.prototype["@@transducer/init"]=function(){throw new Error("init not implemented on XWrap")},t.prototype["@@transducer/result"]=function(a){return a},t.prototype["@@transducer/step"]=function(a,u){return this.f(a,u)},t})();function ou(t,a,u){if(u||(u=new RF),O=typeof(v=t),v==null||O!="object"&&O!="function")return t;var v,O,A,I=function(N){var T=u.get(t);if(T)return T;for(var C in u.set(t,N),t)Object.prototype.hasOwnProperty.call(t,C)&&(N[C]=a?ou(t[C],!0,u):t[C]);return N};switch(Cv(t)){case"Object":return I(Object.create(Object.getPrototypeOf(t)));case"Array":return I([]);case"Date":return new Date(t.valueOf());case"RegExp":return A=t,new RegExp(A.source,A.flags?A.flags:(A.global?"g":"")+(A.ignoreCase?"i":"")+(A.multiline?"m":"")+(A.sticky?"y":"")+(A.unicode?"u":"")+(A.dotAll?"s":""));case"Int8Array":case"Uint8Array":case"Uint8ClampedArray":case"Int16Array":case"Uint16Array":case"Int32Array":case"Uint32Array":case"Float32Array":case"Float64Array":case"BigInt64Array":case"BigUint64Array":return t.slice();default:return t}}var RF=(function(){function t(){this.map={},this.length=0}return t.prototype.set=function(a,u){const v=this.hash(a);let O=this.map[v];O||(this.map[v]=O=[]),O.push([a,u]),this.length+=1},t.prototype.hash=function(a){let u=[];for(var v in a)u.push(Object.prototype.toString.call(a[v]));return u.join()},t.prototype.get=function(a){if(this.length<=180){for(const O in this.map){const A=this.map[O];for(let I=0;I<A.length;I+=1){const N=A[I];if(N[0]===a)return N[1]}}return}const u=this.hash(a),v=this.map[u];if(v)for(let O=0;O<v.length;O+=1){const A=v[O];if(A[0]===a)return A[1]}},t})();const PF=yn((function(t){return t!=null&&typeof t.clone=="function"?t.clone():ou(t,!0)}));function IF(t,a){return function(){var u=arguments.length;if(u===0)return a();var v=arguments[u-1];return ru(v)||typeof v[t]!="function"?a.apply(this,arguments):v[t].apply(v,Array.prototype.slice.call(arguments,0,u-1))}}function xA(t){return t&&t["@@transducer/reduced"]?t:{"@@transducer/value":t,"@@transducer/reduced":!0}}var MF=(function(){function t(a,u,v,O){this.valueFn=a,this.valueAcc=u,this.keyFn=v,this.xf=O,this.inputs={}}return t.prototype["@@transducer/init"]=lA,t.prototype["@@transducer/result"]=function(a){var u;for(u in this.inputs)if(Ei(u,this.inputs)&&(a=this.xf["@@transducer/step"](a,this.inputs[u]))["@@transducer/reduced"]){a=a["@@transducer/value"];break}return this.inputs=null,this.xf["@@transducer/result"](a)},t.prototype["@@transducer/step"]=function(a,u){var v=this.keyFn(u);return this.inputs[v]=this.inputs[v]||[v,ou(this.valueAcc,!1)],this.inputs[v][1]=this.valueFn(this.inputs[v][1],u),a},t})();function jF(t,a,u){return function(v){return new MF(t,a,u,v)}}const LF=bA(4,[],sA([],jF,(function(t,a,u,v){var O=new TF((function(A,I){var N=u(I),T=t(Ei(N,A)?A[N]:ou(a,!1),I);return T&&T["@@transducer/reduced"]?xA(A):(A[N]=T,A)}));return NF(O,{},v)}))),DF=yn((function(t){return t!=null&&typeof t["fantasy-land/empty"]=="function"?t["fantasy-land/empty"]():t!=null&&t.constructor!=null&&typeof t.constructor["fantasy-land/empty"]=="function"?t.constructor["fantasy-land/empty"]():t!=null&&typeof t.empty=="function"?t.empty():t!=null&&t.constructor!=null&&typeof t.constructor.empty=="function"?t.constructor.empty():ru(t)?[]:Nv(t)?"":(function(v){return Object.prototype.toString.call(v)==="[object Object]"})(t)?{}:dA(t)?(function(){return arguments})():(a=t,(u=Object.prototype.toString.call(a))==="[object Uint8ClampedArray]"||u==="[object Int8Array]"||u==="[object Uint8Array]"||u==="[object Int16Array]"||u==="[object Uint16Array]"||u==="[object Int32Array]"||u==="[object Uint32Array]"||u==="[object Float32Array]"||u==="[object Float64Array]"||u==="[object BigInt64Array]"||u==="[object BigUint64Array]"?t.constructor.from(""):void 0);var a,u}));var BF=(function(){function t(a,u){this.xf=u,this.f=a,this.found=!1}return t.prototype["@@transducer/init"]=lA,t.prototype["@@transducer/result"]=function(a){return this.found||(a=this.xf["@@transducer/step"](a,void 0)),this.xf["@@transducer/result"](a)},t.prototype["@@transducer/step"]=function(a,u){return this.f(u)&&(this.found=!0,a=xA(this.xf["@@transducer/step"](a,u))),a},t})();function FF(t){return function(a){return new BF(t,a)}}const iu=Yn(sA(["find"],FF,(function(t,a){for(var u=0,v=a.length;u<v;){if(t(a[u]))return a[u];u+=1}}))),qF=Yn(IF("groupBy",LF((function(t,a){return t.push(a),t}),[]))),_A=yn((function(t){return t!=null&&vA(t,DF(t))})),Tv=yn((function(t){return t==null})),au=_F((function(t,a,u){return vA(t,xF(a,u))}));var zF=["className","cssModule","color","innerRef","pill","tag"];function Rv(){return Rv=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Rv.apply(this,arguments)}var HF={children:y().node,className:y().string,color:y().string,cssModule:y().object,innerRef:y().oneOfType([y().object,y().func,y().string]),pill:y().bool,tag:F};function SA(t){var a=t.className,u=t.cssModule,v=t.color,O=v===void 0?"secondary":v,A=t.innerRef,I=t.pill,N=I!==void 0&&I,T=t.tag,C=T===void 0?"span":T,X=(function($,q){if($==null)return{};var H,G,Q=(function(ue,fe){if(ue==null)return{};var me,ve,ye={},ce=Object.keys(ue);for(ve=0;ve<ce.length;ve++)me=ce[ve],fe.indexOf(me)>=0||(ye[me]=ue[me]);return ye})($,q);if(Object.getOwnPropertySymbols){var ie=Object.getOwnPropertySymbols($);for(G=0;G<ie.length;G++)H=ie[G],q.indexOf(H)>=0||Object.prototype.propertyIsEnumerable.call($,H)&&(Q[H]=$[H])}return Q})(t,zF),V=R(x()(a,"badge","bg-"+O,!!N&&"rounded-pill"),u);return X.href&&C==="span"&&(C="a"),b().createElement(C,Rv({},X,{className:V,ref:A}))}SA.propTypes=HF;const EA=SA;function Pv(t){return Pv=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Pv(t)}var VF=["className","cssModule","type","bsSize","valid","invalid","tag","addon","plaintext","innerRef"];function Iv(){return Iv=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Iv.apply(this,arguments)}function UF(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,v.key,v)}}function Mv(t,a){return Mv=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Mv(t,a)}function jv(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function su(t){return su=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},su(t)}var WF={children:y().node,type:y().string,size:y().oneOfType([y().number,y().string]),bsSize:y().string,valid:y().bool,invalid:y().bool,tag:F,innerRef:y().oneOfType([y().object,y().func,y().string]),plaintext:y().bool,addon:y().bool,className:y().string,cssModule:y().object},OA=(function(t){(function(N,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");N.prototype=Object.create(T&&T.prototype,{constructor:{value:N,writable:!0,configurable:!0}}),Object.defineProperty(N,"prototype",{writable:!1}),T&&Mv(N,T)})(I,t);var a,u,v,O,A=(v=I,O=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var N,T=su(v);if(O){var C=su(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Pv(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return jv(X)})(this,N)});function I(N){var T;return(function(C,X){if(!(C instanceof X))throw new TypeError("Cannot call a class as a function")})(this,I),(T=A.call(this,N)).getRef=T.getRef.bind(jv(T)),T.focus=T.focus.bind(jv(T)),T}return a=I,u=[{key:"getRef",value:function(N){this.props.innerRef&&this.props.innerRef(N),this.ref=N}},{key:"focus",value:function(){this.ref&&this.ref.focus()}},{key:"render",value:function(){var N=this.props,T=N.className,C=N.cssModule,X=N.type,V=X===void 0?"text":X,$=N.bsSize,q=N.valid,H=N.invalid,G=N.tag,Q=N.addon,ie=N.plaintext,ue=N.innerRef,fe=(function(_e,je){if(_e==null)return{};var Ne,Te,ze=(function(ke,Ke){if(ke==null)return{};var $e,dt,lt={},gt=Object.keys(ke);for(dt=0;dt<gt.length;dt++)$e=gt[dt],Ke.indexOf($e)>=0||(lt[$e]=ke[$e]);return lt})(_e,je);if(Object.getOwnPropertySymbols){var Le=Object.getOwnPropertySymbols(_e);for(Te=0;Te<Le.length;Te++)Ne=Le[Te],je.indexOf(Ne)>=0||Object.prototype.propertyIsEnumerable.call(_e,Ne)&&(ze[Ne]=_e[Ne])}return ze})(N,VF),me=["switch","radio","checkbox"].indexOf(V)>-1,ve=V==="select",ye=V==="range",ce=G||(ve||V==="textarea"?V:"input"),Oe="form-control";ie?(Oe="".concat(Oe,"-plaintext"),ce=G||"input"):ye?Oe="form-range":ve?Oe="form-select":me&&(Oe=Q?null:"form-check-input"),fe.size&&/\D/g.test(fe.size)&&(L(`Please use the prop "bsSize" instead of the "size" to bootstrap's input sizing.`),$=fe.size,delete fe.size);var Me=R(x()(T,H&&"is-invalid",q&&"is-valid",!!$&&(ve?"form-select-".concat($):"form-control-".concat($)),Oe),C);return(ce==="input"||G&&typeof G=="function")&&(fe.type=V==="switch"?"checkbox":V),fe.children&&!ie&&V!=="select"&&typeof ce=="string"&&ce!=="select"&&(L('Input with a type of "'.concat(V,'" cannot have children. Please use "value"/"defaultValue" instead.')),delete fe.children),b().createElement(ce,Iv({},fe,{ref:ue,className:Me,"aria-invalid":H}))}}],u&&UF(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);OA.propTypes=WF;const Oi=OA;var GF=["className","cssModule","valid","tooltip","tag"];function Lv(){return Lv=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},Lv.apply(this,arguments)}var KF={children:y().node,tag:F,className:y().string,cssModule:y().object,valid:y().bool,tooltip:y().bool};function kA(t){var a=t.className,u=t.cssModule,v=t.valid,O=v===void 0?void 0:v,A=t.tooltip,I=t.tag,N=I===void 0?"div":I,T=(function(V,$){if(V==null)return{};var q,H,G=(function(ie,ue){if(ie==null)return{};var fe,me,ve={},ye=Object.keys(ie);for(me=0;me<ye.length;me++)fe=ye[me],ue.indexOf(fe)>=0||(ve[fe]=ie[fe]);return ve})(V,$);if(Object.getOwnPropertySymbols){var Q=Object.getOwnPropertySymbols(V);for(H=0;H<Q.length;H++)q=Q[H],$.indexOf(q)>=0||Object.prototype.propertyIsEnumerable.call(V,q)&&(G[q]=V[q])}return G})(t,GF),C=A?"tooltip":"feedback",X=R(x()(a,O?"valid-".concat(C):"invalid-".concat(C)),u);return b().createElement(N,Lv({},T,{className:X}))}kA.propTypes=KF;const Ga=kA;function Io(t){return Io=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Io(t)}function CA(t){var a=(function(u,v){if(Io(u)!=="object"||u===null)return u;var O=u[Symbol.toPrimitive];if(O!==void 0){var A=O.call(u,"string");if(Io(A)!=="object")return A;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(u)})(t);return Io(a)==="symbol"?a:String(a)}function Ka(t,a,u){return(a=CA(a))in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function AA(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function tt(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?AA(Object(u),!0).forEach((function(v){Ka(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):AA(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function NA(t,a){for(var u=0;u<a.length;u++){var v=a[u];v.enumerable=v.enumerable||!1,v.configurable=!0,"value"in v&&(v.writable=!0),Object.defineProperty(t,CA(v.key),v)}}function lu(t){return lu=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},lu(t)}function Dv(t,a){(a==null||a>t.length)&&(a=t.length);for(var u=0,v=new Array(a);u<a;u++)v[u]=t[u];return v}function TA(t,a){if(t){if(typeof t=="string")return Dv(t,a);var u=Object.prototype.toString.call(t).slice(8,-1);return u==="Object"&&t.constructor&&(u=t.constructor.name),u==="Map"||u==="Set"?Array.from(t):u==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?Dv(t,a):void 0}}function ki(t){return(function(a){if(Array.isArray(a))return Dv(a)})(t)||(function(a){if(typeof Symbol<"u"&&a[Symbol.iterator]!=null||a["@@iterator"]!=null)return Array.from(a)})(t)||TA(t)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
129
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function zr(t,a){return(function(u){if(Array.isArray(u))return u})(t)||(function(u,v){var O=u==null?null:typeof Symbol<"u"&&u[Symbol.iterator]||u["@@iterator"];if(O!=null){var A,I,N,T,C=[],X=!0,V=!1;try{if(N=(O=O.call(u)).next,v===0){if(Object(O)!==O)return;X=!1}else for(;!(X=(A=N.call(O)).done)&&(C.push(A.value),C.length!==v);X=!0);}catch($){V=!0,I=$}finally{try{if(!X&&O.return!=null&&(T=O.return(),Object(T)!==T))return}finally{if(V)throw I}}return C}})(t,a)||TA(t,a)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
130
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function wr(t,a){if(t==null)return{};var u,v,O=Ea(t,a);if(Object.getOwnPropertySymbols){var A=Object.getOwnPropertySymbols(t);for(v=0;v<A.length;v++)u=A[v],a.indexOf(u)>=0||Object.prototype.propertyIsEnumerable.call(t,u)&&(O[u]=t[u])}return O}const YF=Math.min,XF=Math.max,uu=Math.round,cu=Math.floor,Bv=t=>({x:t,y:t});function RA(t){return IA(t)?(t.nodeName||"").toLowerCase():"#document"}function ao(t){var a;return(t==null||(a=t.ownerDocument)==null?void 0:a.defaultView)||window}function PA(t){var a;return(a=(IA(t)?t.ownerDocument:t.document)||window.document)==null?void 0:a.documentElement}function IA(t){return t instanceof Node||t instanceof ao(t).Node}function ZF(t){return t instanceof Element||t instanceof ao(t).Element}function Fv(t){return t instanceof HTMLElement||t instanceof ao(t).HTMLElement}function MA(t){return typeof ShadowRoot<"u"&&(t instanceof ShadowRoot||t instanceof ao(t).ShadowRoot)}function jA(t){const{overflow:a,overflowX:u,overflowY:v,display:O}=qv(t);return/auto|scroll|overlay|hidden|clip/.test(a+v+u)&&!["inline","contents"].includes(O)}function qv(t){return ao(t).getComputedStyle(t)}function LA(t){const a=(function(u){if(RA(u)==="html")return u;const v=u.assignedSlot||u.parentNode||MA(u)&&u.host||PA(u);return MA(v)?v.host:v})(t);return(function(u){return["html","body","#document"].includes(RA(u))})(a)?t.ownerDocument?t.ownerDocument.body:t.body:Fv(a)&&jA(a)?a:LA(a)}function zv(t,a){var u;a===void 0&&(a=[]);const v=LA(t),O=v===((u=t.ownerDocument)==null?void 0:u.body),A=ao(v);return O?a.concat(A,A.visualViewport||[],jA(v)?v:[]):a.concat(v,zv(v))}function Hv(t){return ZF(t)?t:t.contextElement}function DA(t){const a=Hv(t);if(!Fv(a))return Bv(1);const u=a.getBoundingClientRect(),{width:v,height:O,$:A}=(function(T){const C=qv(T);let X=parseFloat(C.width)||0,V=parseFloat(C.height)||0;const $=Fv(T),q=$?T.offsetWidth:X,H=$?T.offsetHeight:V,G=uu(X)!==q||uu(V)!==H;return G&&(X=q,V=H),{width:X,height:V,$:G}})(a);let I=(A?uu(u.width):u.width)/v,N=(A?uu(u.height):u.height)/O;return I&&Number.isFinite(I)||(I=1),N&&Number.isFinite(N)||(N=1),{x:I,y:N}}function BA(t,a,u,v){a===void 0&&(a=!1);const O=t.getBoundingClientRect(),A=Hv(t);let I=Bv(1);a&&(I=DA(t));const N=Bv(0);let T=(O.left+N.x)/I.x,C=(O.top+N.y)/I.y,X=O.width/I.x,V=O.height/I.y;if(A){const q=ao(A),H=v;let G=q.frameElement;for(;G&&v&&H!==q;){const Q=DA(G),ie=G.getBoundingClientRect(),ue=qv(G),fe=ie.left+(G.clientLeft+parseFloat(ue.paddingLeft))*Q.x,me=ie.top+(G.clientTop+parseFloat(ue.paddingTop))*Q.y;T*=Q.x,C*=Q.y,X*=Q.x,V*=Q.y,T+=fe,C+=me,G=ao(G).frameElement}}return $={width:X,height:V,x:T,y:C},{...$,top:$.y,left:$.x,right:$.x+$.width,bottom:$.y+$.height};var $}var Vv=s.useLayoutEffect,QF=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],fu=function(){};function JF(t,a){return a?a[0]==="-"?t+a:t+"__"+a:t}function $F(t,a){for(var u=arguments.length,v=new Array(u>2?u-2:0),O=2;O<u;O++)v[O-2]=arguments[O];var A=[].concat(v);if(a&&t)for(var I in a)a.hasOwnProperty(I)&&a[I]&&A.push("".concat(JF(t,I)));return A.filter((function(N){return N})).map((function(N){return String(N).trim()})).join(" ")}var du=function(t){return(function(a){return Array.isArray(a)})(t)?t.filter(Boolean):Io(t)==="object"&&t!==null?[t]:[]},FA=function(t){return t.className,t.clearValue,t.cx,t.getStyles,t.getClassNames,t.getValue,t.hasValue,t.isMulti,t.isRtl,t.options,t.selectOption,t.selectProps,t.setValue,t.theme,tt({},wr(t,QF))},Ut=function(t,a,u){var v=t.cx,O=t.getStyles,A=t.getClassNames,I=t.className;return{css:O(a,t),className:v(u??{},A(a,t),I)}};function hu(t){return[document.documentElement,document.body,window].indexOf(t)>-1}function qA(t){return hu(t)?window.pageYOffset:t.scrollTop}function pu(t,a){hu(t)?window.scrollTo(0,a):t.scrollTop=a}function mu(t,a){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:200,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:fu,O=qA(t),A=a-O,I=0;(function N(){var T,C=A*((T=(T=I+=10)/u-1)*T*T+1)+O;pu(t,C),I<u?window.requestAnimationFrame(N):v(t)})()}function zA(t,a){var u=t.getBoundingClientRect(),v=a.getBoundingClientRect(),O=a.offsetHeight/3;v.bottom+O>u.bottom?pu(t,Math.min(a.offsetTop+a.clientHeight-t.offsetHeight+O,t.scrollHeight)):v.top-O<u.top&&pu(t,Math.max(a.offsetTop-O,0))}function HA(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}var VA=!1,e8={get passive(){return VA=!0}},gu=typeof window<"u"?window:{};gu.addEventListener&&gu.removeEventListener&&(gu.addEventListener("p",fu,e8),gu.removeEventListener("p",fu,!1));var t8=VA;function n8(t){return t!=null}function Ya(t,a,u){return t?a:u}var r8=["children","innerProps"],o8=["children","innerProps"],UA,Uv,Wv,WA=function(t){return t==="auto"?"bottom":t},GA=(0,s.createContext)(null),i8=function(t){var a=t.children,u=t.minMenuHeight,v=t.maxMenuHeight,O=t.menuPlacement,A=t.menuPosition,I=t.menuShouldScrollIntoView,N=t.theme,T=((0,s.useContext)(GA)||{}).setPortalPlacement,C=(0,s.useRef)(null),X=zr((0,s.useState)(v),2),V=X[0],$=X[1],q=zr((0,s.useState)(null),2),H=q[0],G=q[1],Q=N.spacing.controlHeight;return Vv((function(){var ie=C.current;if(ie){var ue=A==="fixed",fe=(function(me){var ve=me.maxHeight,ye=me.menuEl,ce=me.minHeight,Oe=me.placement,Me=me.shouldScroll,_e=me.isFixedPosition,je=me.controlHeight,Ne=(function(on){var St=getComputedStyle(on),Gt=St.position==="absolute",On=/(auto|scroll)/;if(St.position==="fixed")return document.documentElement;for(var ar=on;ar=ar.parentElement;)if(St=getComputedStyle(ar),(!Gt||St.position!=="static")&&On.test(St.overflow+St.overflowY+St.overflowX))return ar;return document.documentElement})(ye),Te={placement:"bottom",maxHeight:ve};if(!ye||!ye.offsetParent)return Te;var ze,Le=Ne.getBoundingClientRect().height,ke=ye.getBoundingClientRect(),Ke=ke.bottom,$e=ke.height,dt=ke.top,lt=ye.offsetParent.getBoundingClientRect().top,gt=_e||hu(ze=Ne)?window.innerHeight:ze.clientHeight,Xe=qA(Ne),le=parseInt(getComputedStyle(ye).marginBottom,10),qe=parseInt(getComputedStyle(ye).marginTop,10),Ie=lt-qe,Ye=gt-dt,it=Ie+Xe,at=Le-Xe-dt,bt=Ke-gt+Xe+le,kt=Xe+dt-qe,Zt=160;switch(Oe){case"auto":case"bottom":if(Ye>=$e)return{placement:"bottom",maxHeight:ve};if(at>=$e&&!_e)return Me&&mu(Ne,bt,Zt),{placement:"bottom",maxHeight:ve};if(!_e&&at>=ce||_e&&Ye>=ce)return Me&&mu(Ne,bt,Zt),{placement:"bottom",maxHeight:_e?Ye-le:at-le};if(Oe==="auto"||_e){var Qt=ve,rn=_e?Ie:it;return rn>=ce&&(Qt=Math.min(rn-le-je,ve)),{placement:"top",maxHeight:Qt}}if(Oe==="bottom")return Me&&pu(Ne,bt),{placement:"bottom",maxHeight:ve};break;case"top":if(Ie>=$e)return{placement:"top",maxHeight:ve};if(it>=$e&&!_e)return Me&&mu(Ne,kt,Zt),{placement:"top",maxHeight:ve};if(!_e&&it>=ce||_e&&Ie>=ce){var En=ve;return(!_e&&it>=ce||_e&&Ie>=ce)&&(En=_e?Ie-qe:it-qe),Me&&mu(Ne,kt,Zt),{placement:"top",maxHeight:En}}return{placement:"bottom",maxHeight:ve};default:throw new Error('Invalid placement provided "'.concat(Oe,'".'))}return Te})({maxHeight:v,menuEl:ie,minHeight:u,placement:O,shouldScroll:I&&!ue,isFixedPosition:ue,controlHeight:Q});$(fe.maxHeight),G(fe.placement),T?.(fe.placement)}}),[v,O,A,I,u,T,Q]),a({ref:C,placerProps:tt(tt({},t),{},{placement:H||WA(O),maxHeight:V})})},KA=function(t,a){var u=t.theme,v=u.spacing.baseUnit,O=u.colors;return tt({textAlign:"center"},a?{}:{color:O.neutral40,padding:"".concat(2*v,"px ").concat(3*v,"px")})},a8=KA,s8=KA,l8=["size"],u8=["innerProps","isRtl","size"],c8={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},YA=function(t){var a=t.size,u=wr(t,l8);return nt("svg",et({height:a,width:a,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:c8},u))},Gv=function(t){return nt(YA,et({size:20},t),nt("path",{d:"M14.348 14.849c-0.469 0.469-1.229 0.469-1.697 0l-2.651-3.030-2.651 3.029c-0.469 0.469-1.229 0.469-1.697 0-0.469-0.469-0.469-1.229 0-1.697l2.758-3.15-2.759-3.152c-0.469-0.469-0.469-1.228 0-1.697s1.228-0.469 1.697 0l2.652 3.031 2.651-3.031c0.469-0.469 1.228-0.469 1.697 0s0.469 1.229 0 1.697l-2.758 3.152 2.758 3.15c0.469 0.469 0.469 1.229 0 1.698z"}))},XA=function(t){return nt(YA,et({size:20},t),nt("path",{d:"M4.516 7.548c0.436-0.446 1.043-0.481 1.576 0l3.908 3.747 3.908-3.747c0.533-0.481 1.141-0.446 1.574 0 0.436 0.445 0.408 1.197 0 1.615-0.406 0.418-4.695 4.502-4.695 4.502-0.217 0.223-0.502 0.335-0.787 0.335s-0.57-0.112-0.789-0.335c0 0-4.287-4.084-4.695-4.502s-0.436-1.17 0-1.615z"}))},ZA=function(t,a){var u=t.isFocused,v=t.theme,O=v.spacing.baseUnit,A=v.colors;return tt({label:"indicatorContainer",display:"flex",transition:"color 150ms"},a?{}:{color:u?A.neutral60:A.neutral20,padding:2*O,":hover":{color:u?A.neutral80:A.neutral40}})},f8=ZA,d8=ZA,h8=xi(UA||(Uv=[`
|
|
24
131
|
0%, 80%, 100% { opacity: 0; }
|
|
25
132
|
40% { opacity: 1; }
|
|
26
|
-
`],Xp||(Xp=Zp.slice(0)),Ax=Object.freeze(Object.defineProperties(Zp,{raw:{value:Object.freeze(Xp)}})))),Jp=function(i){var v=i.delay,b=i.offset;return $e("span",{css:Hp({animation:"".concat(S5," 1s ease-in-out ").concat(v,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:b?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},k5=["data"],N5=["innerRef","isDisabled","isHidden","inputClassName"],Dx={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},T5={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":Fe({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},Dx)},C5=function(i){return Fe({label:"input",color:"inherit",background:0,opacity:i?0:1,width:"100%"},Dx)},jx=function(i){var v=i.children,b=i.innerProps;return $e("div",b,v)},Fx={ClearIndicator:function(i){var v=i.children,b=i.innerProps;return $e("div",Be({},gt(i,"clearIndicator",{indicator:!0,"clear-indicator":!0}),b),v||$e(Qp,null))},Control:function(i){var v=i.children,b=i.isDisabled,x=i.isFocused,D=i.innerRef,B=i.innerProps,G=i.menuIsOpen;return $e("div",Be({ref:D},gt(i,"control",{control:!0,"control--is-disabled":b,"control--is-focused":x,"control--menu-is-open":G}),B),v)},DropdownIndicator:function(i){var v=i.children,b=i.innerProps;return $e("div",Be({},gt(i,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),b),v||$e(Lx,null))},DownChevron:Lx,CrossIcon:Qp,Group:function(i){var v=i.children,b=i.cx,x=i.getStyles,D=i.getClassNames,B=i.Heading,G=i.headingProps,L=i.innerProps,P=i.label,T=i.theme,te=i.selectProps;return $e("div",Be({},gt(i,"group",{group:!0}),L),$e(B,Be({},G,{selectProps:te,theme:T,getStyles:x,getClassNames:D,cx:b}),P),$e("div",null,v))},GroupHeading:function(i){var v=Sx(i);v.data;var b=wn(v,k5);return $e("div",Be({},gt(i,"groupHeading",{"group-heading":!0}),b))},IndicatorsContainer:function(i){var v=i.children,b=i.innerProps;return $e("div",Be({},gt(i,"indicatorsContainer",{indicators:!0}),b),v)},IndicatorSeparator:function(i){var v=i.innerProps;return $e("span",Be({},v,gt(i,"indicatorSeparator",{"indicator-separator":!0})))},Input:function(i){var v=i.cx,b=i.value,x=Sx(i),D=x.innerRef,B=x.isDisabled,G=x.isHidden,L=x.inputClassName,P=wn(x,N5);return $e("div",Be({},gt(i,"input",{"input-container":!0}),{"data-value":b||""}),$e("input",Be({className:v({input:!0},L),ref:D,style:C5(G),disabled:B},P)))},LoadingIndicator:function(i){var v=i.innerProps,b=i.isRtl,x=i.size,D=x===void 0?4:x,B=wn(i,w5);return $e("div",Be({},gt(Fe(Fe({},B),{},{innerProps:v,isRtl:b,size:D}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),v),$e(Jp,{delay:0,offset:b}),$e(Jp,{delay:160,offset:!0}),$e(Jp,{delay:320,offset:!b}))},Menu:function(i){var v=i.children,b=i.innerRef,x=i.innerProps;return $e("div",Be({},gt(i,"menu",{menu:!0}),{ref:b},x),v)},MenuList:function(i){var v=i.children,b=i.innerProps,x=i.innerRef,D=i.isMulti;return $e("div",Be({},gt(i,"menuList",{"menu-list":!0,"menu-list--is-multi":D}),{ref:x},b),v)},MenuPortal:function(i){var v=i.appendTo,b=i.children,x=i.controlElement,D=i.innerProps,B=i.menuPlacement,G=i.menuPosition,L=(0,a.useRef)(null),P=(0,a.useRef)(null),T=qn((0,a.useState)(Px(B)),2),te=T[0],oe=T[1],V=(0,a.useMemo)((function(){return{setPortalPlacement:oe}}),[]),J=qn((0,a.useState)(null),2),Y=J[0],ie=J[1],ae=(0,a.useCallback)((function(){if(x){var he=(function(_e){var xe=_e.getBoundingClientRect();return{bottom:xe.bottom,height:xe.height,left:xe.left,right:xe.right,top:xe.top,width:xe.width}})(x),ye=G==="fixed"?0:window.pageYOffset,be=he[te]+ye;be===Y?.offset&&he.left===Y?.rect.left&&he.width===Y?.rect.width||ie({offset:be,rect:he})}}),[x,G,te,Y?.offset,Y?.rect.left,Y?.rect.width]);Yp((function(){ae()}),[ae]);var ce=(0,a.useCallback)((function(){typeof P.current=="function"&&(P.current(),P.current=null),x&&L.current&&(P.current=(function(he,ye,be,_e){_e===void 0&&(_e={});const{ancestorScroll:xe=!0,ancestorResize:Me=!0,elementResize:Te=typeof ResizeObserver=="function",layoutShift:De=typeof IntersectionObserver=="function",animationFrame:Le=!1}=_e,Re=Wp(he),He=xe||Me?[...Re?Kp(Re):[],...Kp(ye)]:[];He.forEach((tt=>{xe&&tt.addEventListener("scroll",be,{passive:!0}),Me&&tt.addEventListener("resize",be)}));const Ve=Re&&De?(function(tt,dt){let Et,xt=null;const Ut=mx(tt);function tn(){clearTimeout(Et),xt&&xt.disconnect(),xt=null}return(function rt(qt,Lt){qt===void 0&&(qt=!1),Lt===void 0&&(Lt=1),tn();const{left:Pt,top:zt,width:Gt,height:Kt}=tt.getBoundingClientRect();if(qt||dt(),!Gt||!Kt)return;const pr={rootMargin:-za(zt)+"px "+-za(Ut.clientWidth-(Pt+Gt))+"px "+-za(Ut.clientHeight-(zt+Kt))+"px "+-za(Pt)+"px",threshold:s5(0,a5(1,Lt))||1};let Un=!0;function Gn(nn){const Kn=nn[0].intersectionRatio;if(Kn!==Lt){if(!Un)return rt();Kn?rt(!1,Kn):Et=setTimeout((()=>{rt(!1,1e-7)}),100)}Un=!1}try{xt=new IntersectionObserver(Gn,{...pr,root:Ut.ownerDocument})}catch{xt=new IntersectionObserver(Gn,pr)}xt.observe(tt)})(!0),tn})(Re,be):null;let Ue,at=-1,Qe=null;Te&&(Qe=new ResizeObserver((tt=>{let[dt]=tt;dt&&dt.target===Re&&Qe&&(Qe.unobserve(ye),cancelAnimationFrame(at),at=requestAnimationFrame((()=>{Qe&&Qe.observe(ye)}))),be()})),Re&&!Le&&Qe.observe(Re),Qe.observe(ye));let ut=Le?xx(he):null;return Le&&(function tt(){const dt=xx(he);!ut||dt.x===ut.x&&dt.y===ut.y&&dt.width===ut.width&&dt.height===ut.height||be(),ut=dt,Ue=requestAnimationFrame(tt)})(),be(),()=>{He.forEach((tt=>{xe&&tt.removeEventListener("scroll",be),Me&&tt.removeEventListener("resize",be)})),Ve&&Ve(),Qe&&Qe.disconnect(),Qe=null,Le&&cancelAnimationFrame(Ue)}})(x,L.current,ae,{elementResize:"ResizeObserver"in window}))}),[x,ae]);Yp((function(){ce()}),[ce]);var fe=(0,a.useCallback)((function(he){L.current=he,ce()}),[ce]);if(!v&&G!=="fixed"||!Y)return null;var ve=$e("div",Be({ref:fe},gt(Fe(Fe({},i),{},{offset:Y.offset,position:G,rect:Y.rect}),"menuPortal",{"menu-portal":!0}),D),b);return $e(Ix.Provider,{value:V},v?(0,ya.createPortal)(ve,v):ve)},LoadingMessage:function(i){var v=i.children,b=v===void 0?"Loading...":v,x=i.innerProps,D=wn(i,g5);return $e("div",Be({},gt(Fe(Fe({},D),{},{children:b,innerProps:x}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),x),b)},NoOptionsMessage:function(i){var v=i.children,b=v===void 0?"No options":v,x=i.innerProps,D=wn(i,v5);return $e("div",Be({},gt(Fe(Fe({},D),{},{children:b,innerProps:x}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),x),b)},MultiValue:function(i){var v=i.children,b=i.components,x=i.data,D=i.innerProps,B=i.isDisabled,G=i.removeProps,L=i.selectProps,P=b.Container,T=b.Label,te=b.Remove;return $e(P,{data:x,innerProps:Fe(Fe({},gt(i,"multiValue",{"multi-value":!0,"multi-value--is-disabled":B})),D),selectProps:L},$e(T,{data:x,innerProps:Fe({},gt(i,"multiValueLabel",{"multi-value__label":!0})),selectProps:L},v),$e(te,{data:x,innerProps:Fe(Fe({},gt(i,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(v||"option")},G),selectProps:L}))},MultiValueContainer:jx,MultiValueLabel:jx,MultiValueRemove:function(i){var v=i.children,b=i.innerProps;return $e("div",Be({role:"button"},b),v||$e(Qp,{size:14}))},Option:function(i){var v=i.children,b=i.isDisabled,x=i.isFocused,D=i.isSelected,B=i.innerRef,G=i.innerProps;return $e("div",Be({},gt(i,"option",{option:!0,"option--is-disabled":b,"option--is-focused":x,"option--is-selected":D}),{ref:B,"aria-disabled":b},G),v)},Placeholder:function(i){var v=i.children,b=i.innerProps;return $e("div",Be({},gt(i,"placeholder",{placeholder:!0}),b),v)},SelectContainer:function(i){var v=i.children,b=i.innerProps,x=i.isDisabled,D=i.isRtl;return $e("div",Be({},gt(i,"container",{"--is-disabled":x,"--is-rtl":D}),b),v)},SingleValue:function(i){var v=i.children,b=i.isDisabled,x=i.innerProps;return $e("div",Be({},gt(i,"singleValue",{"single-value":!0,"single-value--is-disabled":b}),x),v)},ValueContainer:function(i){var v=i.children,b=i.innerProps,x=i.isMulti,D=i.hasValue;return $e("div",Be({},gt(i,"valueContainer",{"value-container":!0,"value-container--is-multi":x,"value-container--has-value":D}),b),v)}},Bx=Number.isNaN||function(i){return typeof i=="number"&&i!=i};function A5(i,v){if(i.length!==v.length)return!1;for(var b=0;b<i.length;b++)if(!((x=i[b])===(D=v[b])||Bx(x)&&Bx(D)))return!1;var x,D;return!0}for(var P5={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},zx=function(i){return $e("span",Be({css:P5},i))},I5={guidance:function(i){var v=i.isSearchable,b=i.isMulti,x=i.isDisabled,D=i.tabSelectsValue;switch(i.context){case"menu":return"Use Up and Down to choose options".concat(x?"":", press Enter to select the currently focused option",", press Escape to exit the menu").concat(D?", press Tab to select the option and exit the menu":"",".");case"input":return"".concat(i["aria-label"]||"Select"," is focused ").concat(v?",type to refine list":"",", press Down to open the menu, ").concat(b?" press left to focus selected values":"");case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(i){var v=i.action,b=i.label,x=b===void 0?"":b,D=i.labels,B=i.isDisabled;switch(v){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(x,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(D.length>1?"s":""," ").concat(D.join(","),", selected.");case"select-option":return"option ".concat(x,B?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(i){var v=i.context,b=i.focused,x=i.options,D=i.label,B=D===void 0?"":D,G=i.selectValue,L=i.isDisabled,P=i.isSelected,T=function(V,J){return V&&V.length?"".concat(V.indexOf(J)+1," of ").concat(V.length):""};if(v==="value"&&G)return"value ".concat(B," focused, ").concat(T(G,b),".");if(v==="menu"){var te=L?" disabled":"",oe="".concat(P?"selected":"focused").concat(te);return"option ".concat(B," ").concat(oe,", ").concat(T(x,b),".")}return""},onFilter:function(i){var v=i.inputValue,b=i.resultsMessage;return"".concat(b).concat(v?" for search term "+v:"",".")}},M5=function(i){var v=i.ariaSelection,b=i.focusedOption,x=i.focusedValue,D=i.focusableOptions,B=i.isFocused,G=i.selectValue,L=i.selectProps,P=i.id,T=L.ariaLiveMessages,te=L.getOptionLabel,oe=L.inputValue,V=L.isMulti,J=L.isOptionDisabled,Y=L.isSearchable,ie=L.menuIsOpen,ae=L.options,ce=L.screenReaderStatus,fe=L.tabSelectsValue,ve=L["aria-label"],he=L["aria-live"],ye=(0,a.useMemo)((function(){return Fe(Fe({},I5),T||{})}),[T]),be=(0,a.useMemo)((function(){var Re,He="";if(v&&ye.onChange){var Ve=v.option,Ue=v.options,at=v.removedValue,Qe=v.removedValues,ut=v.value,tt=at||Ve||(Re=ut,Array.isArray(Re)?null:Re),dt=tt?te(tt):"",Et=Ue||Qe||void 0,xt=Et?Et.map(te):[],Ut=Fe({isDisabled:tt&&J(tt,G),label:dt,labels:xt},v);He=ye.onChange(Ut)}return He}),[v,ye,J,G,te]),_e=(0,a.useMemo)((function(){var Re="",He=b||x,Ve=!!(b&&G&&G.includes(b));if(He&&ye.onFocus){var Ue={focused:He,label:te(He),isDisabled:J(He,G),isSelected:Ve,options:D,context:He===b?"menu":"value",selectValue:G};Re=ye.onFocus(Ue)}return Re}),[b,x,te,J,ye,D,G]),xe=(0,a.useMemo)((function(){var Re="";if(ie&&ae.length&&ye.onFilter){var He=ce({count:D.length});Re=ye.onFilter({inputValue:oe,resultsMessage:He})}return Re}),[D,oe,ie,ye,ae,ce]),Me=(0,a.useMemo)((function(){var Re="";if(ye.guidance){var He=x?"value":ie?"menu":"input";Re=ye.guidance({"aria-label":ve,context:He,isDisabled:b&&J(b,G),isMulti:V,isSearchable:Y,tabSelectsValue:fe})}return Re}),[ve,b,x,V,J,Y,ie,ye,G,fe]),Te="".concat(_e," ").concat(xe," ").concat(Me),De=$e(a.Fragment,null,$e("span",{id:"aria-selection"},be),$e("span",{id:"aria-context"},Te)),Le=v?.action==="initial-input-focus";return $e(a.Fragment,null,$e(zx,{id:P},Le&&De),$e(zx,{"aria-live":he,"aria-atomic":"false","aria-relevant":"additions text"},B&&!Le&&De))},ev=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],q5=new RegExp("["+ev.map((function(i){return i.letters})).join("")+"]","g"),$x={},tv=0;tv<ev.length;tv++)for(var nv=ev[tv],rv=0;rv<nv.letters.length;rv++)$x[nv.letters[rv]]=nv.base;var Hx=function(i){return i.replace(q5,(function(v){return $x[v]}))},L5=(function(i,v){v===void 0&&(v=A5);var b=null;function x(){for(var D=[],B=0;B<arguments.length;B++)D[B]=arguments[B];if(b&&b.lastThis===this&&v(D,b.lastArgs))return b.lastResult;var G=i.apply(this,D);return b={lastResult:G,lastArgs:D,lastThis:this},G}return x.clear=function(){b=null},x})(Hx),Vx=function(i){return i.replace(/^\s+|\s+$/g,"")},R5=function(i){return"".concat(i.label," ").concat(i.value)},D5=["innerRef"];function j5(i){var v=i.innerRef,b=(function(x){for(var D=arguments.length,B=new Array(D>1?D-1:0),G=1;G<D;G++)B[G-1]=arguments[G];var L=Object.entries(x).filter((function(P){var T=qn(P,1)[0];return!B.includes(T)}));return L.reduce((function(P,T){var te=qn(T,2),oe=te[0],V=te[1];return P[oe]=V,P}),{})})(wn(i,D5),"onExited","in","enter","exit","appear");return $e("input",Be({ref:v},b,{css:Hp({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var Ux=["boxSizing","height","overflow","paddingRight","position"],Gx={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function Kx(i){i.preventDefault()}function Wx(i){i.stopPropagation()}function Yx(){var i=this.scrollTop,v=this.scrollHeight,b=i+this.offsetHeight;i===0?this.scrollTop=1:b===v&&(this.scrollTop=i-1)}function Zx(){return"ontouchstart"in window||navigator.maxTouchPoints}var Xx=!(typeof window>"u"||!window.document||!window.document.createElement),ti=0,Qr={capture:!1,passive:!1},F5=function(){return document.activeElement&&document.activeElement.blur()},B5={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function z5(i){var v=i.children,b=i.lockEnabled,x=i.captureEnabled,D=(function(G){var L=G.isEnabled,P=G.onBottomArrive,T=G.onBottomLeave,te=G.onTopArrive,oe=G.onTopLeave,V=(0,a.useRef)(!1),J=(0,a.useRef)(!1),Y=(0,a.useRef)(0),ie=(0,a.useRef)(null),ae=(0,a.useCallback)((function(be,_e){if(ie.current!==null){var xe=ie.current,Me=xe.scrollTop,Te=xe.scrollHeight,De=xe.clientHeight,Le=ie.current,Re=_e>0,He=Te-De-Me,Ve=!1;He>_e&&V.current&&(T&&T(be),V.current=!1),Re&&J.current&&(oe&&oe(be),J.current=!1),Re&&_e>He?(P&&!V.current&&P(be),Le.scrollTop=Te,Ve=!0,V.current=!0):!Re&&-_e>Me&&(te&&!J.current&&te(be),Le.scrollTop=0,Ve=!0,J.current=!0),Ve&&(function(Ue){Ue.preventDefault(),Ue.stopPropagation()})(be)}}),[P,T,te,oe]),ce=(0,a.useCallback)((function(be){ae(be,be.deltaY)}),[ae]),fe=(0,a.useCallback)((function(be){Y.current=be.changedTouches[0].clientY}),[]),ve=(0,a.useCallback)((function(be){var _e=Y.current-be.changedTouches[0].clientY;ae(be,_e)}),[ae]),he=(0,a.useCallback)((function(be){if(be){var _e=!!h5&&{passive:!1};be.addEventListener("wheel",ce,_e),be.addEventListener("touchstart",fe,_e),be.addEventListener("touchmove",ve,_e)}}),[ve,fe,ce]),ye=(0,a.useCallback)((function(be){be&&(be.removeEventListener("wheel",ce,!1),be.removeEventListener("touchstart",fe,!1),be.removeEventListener("touchmove",ve,!1))}),[ve,fe,ce]);return(0,a.useEffect)((function(){if(L){var be=ie.current;return he(be),function(){ye(be)}}}),[L,he,ye]),function(be){ie.current=be}})({isEnabled:x===void 0||x,onBottomArrive:i.onBottomArrive,onBottomLeave:i.onBottomLeave,onTopArrive:i.onTopArrive,onTopLeave:i.onTopLeave}),B=(function(G){var L=G.isEnabled,P=G.accountForScrollbars,T=P===void 0||P,te=(0,a.useRef)({}),oe=(0,a.useRef)(null),V=(0,a.useCallback)((function(Y){if(Xx){var ie=document.body,ae=ie&&ie.style;if(T&&Ux.forEach((function(he){var ye=ae&&ae[he];te.current[he]=ye})),T&&ti<1){var ce=parseInt(te.current.paddingRight,10)||0,fe=document.body?document.body.clientWidth:0,ve=window.innerWidth-fe+ce||0;Object.keys(Gx).forEach((function(he){var ye=Gx[he];ae&&(ae[he]=ye)})),ae&&(ae.paddingRight="".concat(ve,"px"))}ie&&Zx()&&(ie.addEventListener("touchmove",Kx,Qr),Y&&(Y.addEventListener("touchstart",Yx,Qr),Y.addEventListener("touchmove",Wx,Qr))),ti+=1}}),[T]),J=(0,a.useCallback)((function(Y){if(Xx){var ie=document.body,ae=ie&&ie.style;ti=Math.max(ti-1,0),T&&ti<1&&Ux.forEach((function(ce){var fe=te.current[ce];ae&&(ae[ce]=fe)})),ie&&Zx()&&(ie.removeEventListener("touchmove",Kx,Qr),Y&&(Y.removeEventListener("touchstart",Yx,Qr),Y.removeEventListener("touchmove",Wx,Qr)))}}),[T]);return(0,a.useEffect)((function(){if(L){var Y=oe.current;return V(Y),function(){J(Y)}}}),[L,V,J]),function(Y){oe.current=Y}})({isEnabled:b});return $e(a.Fragment,null,b&&$e("div",{onClick:F5,css:B5}),v((function(G){D(G),B(G)})))}var $5={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},H5=function(i){var v=i.name,b=i.onFocus;return $e("input",{required:!0,name:v,tabIndex:-1,"aria-hidden":"true",onFocus:b,css:$5,value:"",onChange:function(){}})},Qx=function(i){return i.label},Jx=function(i){return i.value},V5={clearIndicator:x5,container:function(i){var v=i.isDisabled;return{label:"container",direction:i.isRtl?"rtl":void 0,pointerEvents:v?"none":void 0,position:"relative"}},control:function(i,v){var b=i.isDisabled,x=i.isFocused,D=i.theme,B=D.colors,G=D.borderRadius;return Fe({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:D.spacing.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},v?{}:{backgroundColor:b?B.neutral5:B.neutral0,borderColor:b?B.neutral10:x?B.primary:B.neutral20,borderRadius:G,borderStyle:"solid",borderWidth:1,boxShadow:x?"0 0 0 1px ".concat(B.primary):void 0,"&:hover":{borderColor:x?B.primary:B.neutral30}})},dropdownIndicator:E5,group:function(i,v){var b=i.theme.spacing;return v?{}:{paddingBottom:2*b.baseUnit,paddingTop:2*b.baseUnit}},groupHeading:function(i,v){var b=i.theme,x=b.colors,D=b.spacing;return Fe({label:"group",cursor:"default",display:"block"},v?{}:{color:x.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:3*D.baseUnit,paddingRight:3*D.baseUnit,textTransform:"uppercase"})},indicatorsContainer:function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},indicatorSeparator:function(i,v){var b=i.isDisabled,x=i.theme,D=x.spacing.baseUnit,B=x.colors;return Fe({label:"indicatorSeparator",alignSelf:"stretch",width:1},v?{}:{backgroundColor:b?B.neutral10:B.neutral20,marginBottom:2*D,marginTop:2*D})},input:function(i,v){var b=i.isDisabled,x=i.value,D=i.theme,B=D.spacing,G=D.colors;return Fe(Fe({visibility:b?"hidden":"visible",transform:x?"translateZ(0)":""},T5),v?{}:{margin:B.baseUnit/2,paddingBottom:B.baseUnit/2,paddingTop:B.baseUnit/2,color:G.neutral80})},loadingIndicator:function(i,v){var b=i.isFocused,x=i.size,D=i.theme,B=D.colors,G=D.spacing.baseUnit;return Fe({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:x,lineHeight:1,marginRight:x,textAlign:"center",verticalAlign:"middle"},v?{}:{color:b?B.neutral60:B.neutral20,padding:2*G})},loadingMessage:b5,menu:function(i,v){var b,x=i.placement,D=i.theme,B=D.borderRadius,G=D.spacing,L=D.colors;return Fe((Ko(b={label:"menu"},(function(P){return P?{bottom:"top",top:"bottom"}[P]:"bottom"})(x),"100%"),Ko(b,"position","absolute"),Ko(b,"width","100%"),Ko(b,"zIndex",1),b),v?{}:{backgroundColor:L.neutral0,borderRadius:B,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:G.menuGutter,marginTop:G.menuGutter})},menuList:function(i,v){var b=i.maxHeight,x=i.theme.spacing.baseUnit;return Fe({maxHeight:b,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},v?{}:{paddingBottom:x,paddingTop:x})},menuPortal:function(i){var v=i.rect,b=i.offset,x=i.position;return{left:v.left,position:x,top:b,width:v.width,zIndex:1}},multiValue:function(i,v){var b=i.theme,x=b.spacing,D=b.borderRadius,B=b.colors;return Fe({label:"multiValue",display:"flex",minWidth:0},v?{}:{backgroundColor:B.neutral10,borderRadius:D/2,margin:x.baseUnit/2})},multiValueLabel:function(i,v){var b=i.theme,x=b.borderRadius,D=b.colors,B=i.cropWithEllipsis;return Fe({overflow:"hidden",textOverflow:B||B===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},v?{}:{borderRadius:x/2,color:D.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},multiValueRemove:function(i,v){var b=i.theme,x=b.spacing,D=b.borderRadius,B=b.colors,G=i.isFocused;return Fe({alignItems:"center",display:"flex"},v?{}:{borderRadius:D/2,backgroundColor:G?B.dangerLight:void 0,paddingLeft:x.baseUnit,paddingRight:x.baseUnit,":hover":{backgroundColor:B.dangerLight,color:B.danger}})},noOptionsMessage:m5,option:function(i,v){var b=i.isDisabled,x=i.isFocused,D=i.isSelected,B=i.theme,G=B.spacing,L=B.colors;return Fe({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},v?{}:{backgroundColor:D?L.primary:x?L.primary25:"transparent",color:b?L.neutral20:D?L.neutral0:"inherit",padding:"".concat(2*G.baseUnit,"px ").concat(3*G.baseUnit,"px"),":active":{backgroundColor:b?void 0:D?L.primary:L.primary50}})},placeholder:function(i,v){var b=i.theme,x=b.spacing,D=b.colors;return Fe({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},v?{}:{color:D.neutral50,marginLeft:x.baseUnit/2,marginRight:x.baseUnit/2})},singleValue:function(i,v){var b=i.isDisabled,x=i.theme,D=x.spacing,B=x.colors;return Fe({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},v?{}:{color:b?B.neutral40:B.neutral80,marginLeft:D.baseUnit/2,marginRight:D.baseUnit/2})},valueContainer:function(i,v){var b=i.theme.spacing,x=i.isMulti,D=i.hasValue,B=i.selectProps.controlShouldRenderValue;return Fe({alignItems:"center",display:x&&D&&B?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},v?{}:{padding:"".concat(b.baseUnit/2,"px ").concat(2*b.baseUnit,"px")})}},ov={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},U5={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:Tx(),captureMenuScroll:!Tx(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(i,v){if(i.data.__isNew__)return!0;var b=Fe({ignoreCase:!0,ignoreAccents:!0,stringify:R5,trim:!0,matchFrom:"any"},void 0),x=b.ignoreCase,D=b.ignoreAccents,B=b.stringify,G=b.trim,L=b.matchFrom,P=G?Vx(v):v,T=G?Vx(B(i)):B(i);return x&&(P=P.toLowerCase(),T=T.toLowerCase()),D&&(P=L5(P),T=Hx(T)),L==="start"?T.substr(0,P.length)===P:T.indexOf(P)>-1},formatGroupLabel:function(i){return i.label},getOptionLabel:Qx,getOptionValue:Jx,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(i){return!!i.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!(function(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch{return!1}})(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(i){var v=i.count;return"".concat(v," result").concat(v!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function eS(i,v,b,x){return{type:"option",data:v,isDisabled:iS(i,v,b),isSelected:aS(i,v,b),label:oS(i,v),value:Wa(i,v),index:x}}function tS(i,v){return i.options.map((function(b,x){if("options"in b){var D=b.options.map((function(G,L){return eS(i,G,v,L)})).filter((function(G){return rS(i,G)}));return D.length>0?{type:"group",data:b,options:D,index:x}:void 0}var B=eS(i,b,v,x);return rS(i,B)?B:void 0})).filter(p5)}function nS(i){return i.reduce((function(v,b){return b.type==="group"?v.push.apply(v,Wo(b.options.map((function(x){return x.data})))):v.push(b.data),v}),[])}function rS(i,v){var b=i.inputValue,x=b===void 0?"":b,D=v.data,B=v.isSelected,G=v.label,L=v.value;return(!lS(i)||!B)&&sS(i,{label:G,value:L,data:D},x)}var oS=function(i,v){return i.getOptionLabel(v)},Wa=function(i,v){return i.getOptionValue(v)};function iS(i,v,b){return typeof i.isOptionDisabled=="function"&&i.isOptionDisabled(v,b)}function aS(i,v,b){if(b.indexOf(v)>-1)return!0;if(typeof i.isOptionSelected=="function")return i.isOptionSelected(v,b);var x=Wa(i,v);return b.some((function(D){return Wa(i,D)===x}))}function sS(i,v,b){return!i.filterOption||i.filterOption(v,b)}var lS=function(i){var v=i.hideSelectedOptions,b=i.isMulti;return v===void 0?b:v},G5=1,iv=(function(i){(function(P,T){if(typeof T!="function"&&T!==null)throw new TypeError("Super expression must either be null or a function");P.prototype=Object.create(T&&T.prototype,{constructor:{value:P,writable:!0,configurable:!0}}),Object.defineProperty(P,"prototype",{writable:!1}),T&&ba(P,T)})(L,i);var v,b,x,D,B,G=(D=L,B=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var P,T=Ia(D);if(B){var te=Ia(this).constructor;P=Reflect.construct(T,arguments,te)}else P=T.apply(this,arguments);return(function(oe,V){if(V&&(dr(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Mp(oe)})(this,P)});function L(P){var T;if((function(V,J){if(!(V instanceof J))throw new TypeError("Cannot call a class as a function")})(this,L),(T=G.call(this,P)).state={ariaSelection:null,focusedOption:null,focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0},T.blockOptionHover=!1,T.isComposing=!1,T.commonProps=void 0,T.initialTouchX=0,T.initialTouchY=0,T.instancePrefix="",T.openAfterFocus=!1,T.scrollToFocusedOptionOnUpdate=!1,T.userIsDragging=void 0,T.controlRef=null,T.getControlRef=function(V){T.controlRef=V},T.focusedOptionRef=null,T.getFocusedOptionRef=function(V){T.focusedOptionRef=V},T.menuListRef=null,T.getMenuListRef=function(V){T.menuListRef=V},T.inputRef=null,T.getInputRef=function(V){T.inputRef=V},T.focus=T.focusInput,T.blur=T.blurInput,T.onChange=function(V,J){var Y=T.props,ie=Y.onChange,ae=Y.name;J.name=ae,T.ariaOnChange(V,J),ie(V,J)},T.setValue=function(V,J,Y){var ie=T.props,ae=ie.closeMenuOnSelect,ce=ie.isMulti,fe=ie.inputValue;T.onInputChange("",{action:"set-value",prevInputValue:fe}),ae&&(T.setState({inputIsHiddenAfterUpdate:!ce}),T.onMenuClose()),T.setState({clearFocusValueOnUpdate:!0}),T.onChange(V,{action:J,option:Y})},T.selectOption=function(V){var J=T.props,Y=J.blurInputOnSelect,ie=J.isMulti,ae=J.name,ce=T.state.selectValue,fe=ie&&T.isOptionSelected(V,ce),ve=T.isOptionDisabled(V,ce);if(fe){var he=T.getOptionValue(V);T.setValue(ce.filter((function(ye){return T.getOptionValue(ye)!==he})),"deselect-option",V)}else{if(ve)return void T.ariaOnChange(V,{action:"select-option",option:V,name:ae});ie?T.setValue([].concat(Wo(ce),[V]),"select-option",V):T.setValue(V,"select-option")}Y&&T.blurInput()},T.removeValue=function(V){var J=T.props.isMulti,Y=T.state.selectValue,ie=T.getOptionValue(V),ae=Y.filter((function(fe){return T.getOptionValue(fe)!==ie})),ce=ei(J,ae,ae[0]||null);T.onChange(ce,{action:"remove-value",removedValue:V}),T.focusInput()},T.clearValue=function(){var V=T.state.selectValue;T.onChange(ei(T.props.isMulti,[],null),{action:"clear",removedValues:V})},T.popValue=function(){var V=T.props.isMulti,J=T.state.selectValue,Y=J[J.length-1],ie=J.slice(0,J.length-1),ae=ei(V,ie,ie[0]||null);T.onChange(ae,{action:"pop-value",removedValue:Y})},T.getValue=function(){return T.state.selectValue},T.cx=function(){for(var V=arguments.length,J=new Array(V),Y=0;Y<V;Y++)J[Y]=arguments[Y];return f5.apply(void 0,[T.props.classNamePrefix].concat(J))},T.getOptionLabel=function(V){return oS(T.props,V)},T.getOptionValue=function(V){return Wa(T.props,V)},T.getStyles=function(V,J){var Y=T.props.unstyled,ie=V5[V](J,Y);ie.boxSizing="border-box";var ae=T.props.styles[V];return ae?ae(ie,J):ie},T.getClassNames=function(V,J){var Y,ie;return(Y=(ie=T.props.classNames)[V])===null||Y===void 0?void 0:Y.call(ie,J)},T.getElementId=function(V){return"".concat(T.instancePrefix,"-").concat(V)},T.getComponents=function(){return V=T.props,Fe(Fe({},Fx),V.components);var V},T.buildCategorizedOptions=function(){return tS(T.props,T.state.selectValue)},T.getCategorizedOptions=function(){return T.props.menuIsOpen?T.buildCategorizedOptions():[]},T.buildFocusableOptions=function(){return nS(T.buildCategorizedOptions())},T.getFocusableOptions=function(){return T.props.menuIsOpen?T.buildFocusableOptions():[]},T.ariaOnChange=function(V,J){T.setState({ariaSelection:Fe({value:V},J)})},T.onMenuMouseDown=function(V){V.button===0&&(V.stopPropagation(),V.preventDefault(),T.focusInput())},T.onMenuMouseMove=function(V){T.blockOptionHover=!1},T.onControlMouseDown=function(V){if(!V.defaultPrevented){var J=T.props.openMenuOnClick;T.state.isFocused?T.props.menuIsOpen?V.target.tagName!=="INPUT"&&V.target.tagName!=="TEXTAREA"&&T.onMenuClose():J&&T.openMenu("first"):(J&&(T.openAfterFocus=!0),T.focusInput()),V.target.tagName!=="INPUT"&&V.target.tagName!=="TEXTAREA"&&V.preventDefault()}},T.onDropdownIndicatorMouseDown=function(V){if(!(V&&V.type==="mousedown"&&V.button!==0||T.props.isDisabled)){var J=T.props,Y=J.isMulti,ie=J.menuIsOpen;T.focusInput(),ie?(T.setState({inputIsHiddenAfterUpdate:!Y}),T.onMenuClose()):T.openMenu("first"),V.preventDefault()}},T.onClearIndicatorMouseDown=function(V){V&&V.type==="mousedown"&&V.button!==0||(T.clearValue(),V.preventDefault(),T.openAfterFocus=!1,V.type==="touchend"?T.focusInput():setTimeout((function(){return T.focusInput()})))},T.onScroll=function(V){typeof T.props.closeMenuOnScroll=="boolean"?V.target instanceof HTMLElement&&Va(V.target)&&T.props.onMenuClose():typeof T.props.closeMenuOnScroll=="function"&&T.props.closeMenuOnScroll(V)&&T.props.onMenuClose()},T.onCompositionStart=function(){T.isComposing=!0},T.onCompositionEnd=function(){T.isComposing=!1},T.onTouchStart=function(V){var J=V.touches,Y=J&&J.item(0);Y&&(T.initialTouchX=Y.clientX,T.initialTouchY=Y.clientY,T.userIsDragging=!1)},T.onTouchMove=function(V){var J=V.touches,Y=J&&J.item(0);if(Y){var ie=Math.abs(Y.clientX-T.initialTouchX),ae=Math.abs(Y.clientY-T.initialTouchY);T.userIsDragging=ie>5||ae>5}},T.onTouchEnd=function(V){T.userIsDragging||(T.controlRef&&!T.controlRef.contains(V.target)&&T.menuListRef&&!T.menuListRef.contains(V.target)&&T.blurInput(),T.initialTouchX=0,T.initialTouchY=0)},T.onControlTouchEnd=function(V){T.userIsDragging||T.onControlMouseDown(V)},T.onClearIndicatorTouchEnd=function(V){T.userIsDragging||T.onClearIndicatorMouseDown(V)},T.onDropdownIndicatorTouchEnd=function(V){T.userIsDragging||T.onDropdownIndicatorMouseDown(V)},T.handleInputChange=function(V){var J=T.props.inputValue,Y=V.currentTarget.value;T.setState({inputIsHiddenAfterUpdate:!1}),T.onInputChange(Y,{action:"input-change",prevInputValue:J}),T.props.menuIsOpen||T.onMenuOpen()},T.onInputFocus=function(V){T.props.onFocus&&T.props.onFocus(V),T.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(T.openAfterFocus||T.props.openMenuOnFocus)&&T.openMenu("first"),T.openAfterFocus=!1},T.onInputBlur=function(V){var J=T.props.inputValue;T.menuListRef&&T.menuListRef.contains(document.activeElement)?T.inputRef.focus():(T.props.onBlur&&T.props.onBlur(V),T.onInputChange("",{action:"input-blur",prevInputValue:J}),T.onMenuClose(),T.setState({focusedValue:null,isFocused:!1}))},T.onOptionHover=function(V){T.blockOptionHover||T.state.focusedOption===V||T.setState({focusedOption:V})},T.shouldHideSelectedOptions=function(){return lS(T.props)},T.onValueInputFocus=function(V){V.preventDefault(),V.stopPropagation(),T.focus()},T.onKeyDown=function(V){var J=T.props,Y=J.isMulti,ie=J.backspaceRemovesValue,ae=J.escapeClearsValue,ce=J.inputValue,fe=J.isClearable,ve=J.isDisabled,he=J.menuIsOpen,ye=J.onKeyDown,be=J.tabSelectsValue,_e=J.openMenuOnFocus,xe=T.state,Me=xe.focusedOption,Te=xe.focusedValue,De=xe.selectValue;if(!(ve||typeof ye=="function"&&(ye(V),V.defaultPrevented))){switch(T.blockOptionHover=!0,V.key){case"ArrowLeft":if(!Y||ce)return;T.focusValue("previous");break;case"ArrowRight":if(!Y||ce)return;T.focusValue("next");break;case"Delete":case"Backspace":if(ce)return;if(Te)T.removeValue(Te);else{if(!ie)return;Y?T.popValue():fe&&T.clearValue()}break;case"Tab":if(T.isComposing||V.shiftKey||!he||!be||!Me||_e&&T.isOptionSelected(Me,De))return;T.selectOption(Me);break;case"Enter":if(V.keyCode===229)break;if(he){if(!Me||T.isComposing)return;T.selectOption(Me);break}return;case"Escape":he?(T.setState({inputIsHiddenAfterUpdate:!1}),T.onInputChange("",{action:"menu-close",prevInputValue:ce}),T.onMenuClose()):fe&&ae&&T.clearValue();break;case" ":if(ce)return;if(!he){T.openMenu("first");break}if(!Me)return;T.selectOption(Me);break;case"ArrowUp":he?T.focusOption("up"):T.openMenu("last");break;case"ArrowDown":he?T.focusOption("down"):T.openMenu("first");break;case"PageUp":if(!he)return;T.focusOption("pageup");break;case"PageDown":if(!he)return;T.focusOption("pagedown");break;case"Home":if(!he)return;T.focusOption("first");break;case"End":if(!he)return;T.focusOption("last");break;default:return}V.preventDefault()}},T.instancePrefix="react-select-"+(T.props.instanceId||++G5),T.state.selectValue=Ha(P.value),P.menuIsOpen&&T.state.selectValue.length){var te=T.buildFocusableOptions(),oe=te.indexOf(T.state.selectValue[0]);T.state.focusedOption=te[oe]}return T}return v=L,b=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&Nx(this.menuListRef,this.focusedOptionRef)}},{key:"componentDidUpdate",value:function(P){var T=this.props,te=T.isDisabled,oe=T.menuIsOpen,V=this.state.isFocused;(V&&!te&&P.isDisabled||V&&oe&&!P.menuIsOpen)&&this.focusInput(),V&&te&&!P.isDisabled?this.setState({isFocused:!1},this.onMenuClose):V||te||!P.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(Nx(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(P,T){this.props.onInputChange(P,T)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(P){var T=this,te=this.state,oe=te.selectValue,V=te.isFocused,J=this.buildFocusableOptions(),Y=P==="first"?0:J.length-1;if(!this.props.isMulti){var ie=J.indexOf(oe[0]);ie>-1&&(Y=ie)}this.scrollToFocusedOptionOnUpdate=!(V&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:J[Y]},(function(){return T.onMenuOpen()}))}},{key:"focusValue",value:function(P){var T=this.state,te=T.selectValue,oe=T.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var V=te.indexOf(oe);oe||(V=-1);var J=te.length-1,Y=-1;if(te.length){switch(P){case"previous":Y=V===0?0:V===-1?J:V-1;break;case"next":V>-1&&V<J&&(Y=V+1)}this.setState({inputIsHidden:Y!==-1,focusedValue:te[Y]})}}}},{key:"focusOption",value:function(){var P=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"first",T=this.props.pageSize,te=this.state.focusedOption,oe=this.getFocusableOptions();if(oe.length){var V=0,J=oe.indexOf(te);te||(J=-1),P==="up"?V=J>0?J-1:oe.length-1:P==="down"?V=(J+1)%oe.length:P==="pageup"?(V=J-T)<0&&(V=0):P==="pagedown"?(V=J+T)>oe.length-1&&(V=oe.length-1):P==="last"&&(V=oe.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:oe[V],focusedValue:null})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme(ov):Fe(Fe({},ov),this.props.theme):ov}},{key:"getCommonProps",value:function(){var P=this.clearValue,T=this.cx,te=this.getStyles,oe=this.getClassNames,V=this.getValue,J=this.selectOption,Y=this.setValue,ie=this.props,ae=ie.isMulti,ce=ie.isRtl,fe=ie.options;return{clearValue:P,cx:T,getStyles:te,getClassNames:oe,getValue:V,hasValue:this.hasValue(),isMulti:ae,isRtl:ce,options:fe,selectOption:J,selectProps:ie,setValue:Y,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var P=this.props,T=P.isClearable,te=P.isMulti;return T===void 0?te:T}},{key:"isOptionDisabled",value:function(P,T){return iS(this.props,P,T)}},{key:"isOptionSelected",value:function(P,T){return aS(this.props,P,T)}},{key:"filterOption",value:function(P,T){return sS(this.props,P,T)}},{key:"formatOptionLabel",value:function(P,T){if(typeof this.props.formatOptionLabel=="function"){var te=this.props.inputValue,oe=this.state.selectValue;return this.props.formatOptionLabel(P,{context:T,inputValue:te,selectValue:oe})}return this.getOptionLabel(P)}},{key:"formatGroupLabel",value:function(P){return this.props.formatGroupLabel(P)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var P=this.props,T=P.isDisabled,te=P.isSearchable,oe=P.inputId,V=P.inputValue,J=P.tabIndex,Y=P.form,ie=P.menuIsOpen,ae=P.required,ce=this.getComponents().Input,fe=this.state,ve=fe.inputIsHidden,he=fe.ariaSelection,ye=this.commonProps,be=oe||this.getElementId("input"),_e=Fe(Fe(Fe({"aria-autocomplete":"list","aria-expanded":ie,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":ae,role:"combobox"},ie&&{"aria-controls":this.getElementId("listbox"),"aria-owns":this.getElementId("listbox")}),!te&&{"aria-readonly":!0}),this.hasValue()?he?.action==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return te?a.createElement(ce,Be({},ye,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:be,innerRef:this.getInputRef,isDisabled:T,isHidden:ve,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:J,form:Y,type:"text",value:V},_e)):a.createElement(j5,Be({id:be,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:$a,onFocus:this.onInputFocus,disabled:T,tabIndex:J,inputMode:"none",form:Y,value:""},_e))}},{key:"renderPlaceholderOrValue",value:function(){var P=this,T=this.getComponents(),te=T.MultiValue,oe=T.MultiValueContainer,V=T.MultiValueLabel,J=T.MultiValueRemove,Y=T.SingleValue,ie=T.Placeholder,ae=this.commonProps,ce=this.props,fe=ce.controlShouldRenderValue,ve=ce.isDisabled,he=ce.isMulti,ye=ce.inputValue,be=ce.placeholder,_e=this.state,xe=_e.selectValue,Me=_e.focusedValue,Te=_e.isFocused;if(!this.hasValue()||!fe)return ye?null:a.createElement(ie,Be({},ae,{key:"placeholder",isDisabled:ve,isFocused:Te,innerProps:{id:this.getElementId("placeholder")}}),be);if(he)return xe.map((function(Le,Re){var He=Le===Me,Ve="".concat(P.getOptionLabel(Le),"-").concat(P.getOptionValue(Le));return a.createElement(te,Be({},ae,{components:{Container:oe,Label:V,Remove:J},isFocused:He,isDisabled:ve,key:Ve,index:Re,removeProps:{onClick:function(){return P.removeValue(Le)},onTouchEnd:function(){return P.removeValue(Le)},onMouseDown:function(Ue){Ue.preventDefault()}},data:Le}),P.formatOptionLabel(Le,"value"))}));if(ye)return null;var De=xe[0];return a.createElement(Y,Be({},ae,{data:De,isDisabled:ve}),this.formatOptionLabel(De,"value"))}},{key:"renderClearIndicator",value:function(){var P=this.getComponents().ClearIndicator,T=this.commonProps,te=this.props,oe=te.isDisabled,V=te.isLoading,J=this.state.isFocused;if(!this.isClearable()||!P||oe||!this.hasValue()||V)return null;var Y={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return a.createElement(P,Be({},T,{innerProps:Y,isFocused:J}))}},{key:"renderLoadingIndicator",value:function(){var P=this.getComponents().LoadingIndicator,T=this.commonProps,te=this.props,oe=te.isDisabled,V=te.isLoading,J=this.state.isFocused;return P&&V?a.createElement(P,Be({},T,{innerProps:{"aria-hidden":"true"},isDisabled:oe,isFocused:J})):null}},{key:"renderIndicatorSeparator",value:function(){var P=this.getComponents(),T=P.DropdownIndicator,te=P.IndicatorSeparator;if(!T||!te)return null;var oe=this.commonProps,V=this.props.isDisabled,J=this.state.isFocused;return a.createElement(te,Be({},oe,{isDisabled:V,isFocused:J}))}},{key:"renderDropdownIndicator",value:function(){var P=this.getComponents().DropdownIndicator;if(!P)return null;var T=this.commonProps,te=this.props.isDisabled,oe=this.state.isFocused,V={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return a.createElement(P,Be({},T,{innerProps:V,isDisabled:te,isFocused:oe}))}},{key:"renderMenu",value:function(){var P=this,T=this.getComponents(),te=T.Group,oe=T.GroupHeading,V=T.Menu,J=T.MenuList,Y=T.MenuPortal,ie=T.LoadingMessage,ae=T.NoOptionsMessage,ce=T.Option,fe=this.commonProps,ve=this.state.focusedOption,he=this.props,ye=he.captureMenuScroll,be=he.inputValue,_e=he.isLoading,xe=he.loadingMessage,Me=he.minMenuHeight,Te=he.maxMenuHeight,De=he.menuIsOpen,Le=he.menuPlacement,Re=he.menuPosition,He=he.menuPortalTarget,Ve=he.menuShouldBlockScroll,Ue=he.menuShouldScrollIntoView,at=he.noOptionsMessage,Qe=he.onMenuScrollToTop,ut=he.onMenuScrollToBottom;if(!De)return null;var tt,dt=function(rt,qt){var Lt=rt.type,Pt=rt.data,zt=rt.isDisabled,Gt=rt.isSelected,Kt=rt.label,pr=rt.value,Un=ve===Pt,Gn=zt?void 0:function(){return P.onOptionHover(Pt)},nn=zt?void 0:function(){return P.selectOption(Pt)},Kn="".concat(P.getElementId("option"),"-").concat(qt),dv={id:Kn,onClick:nn,onMouseMove:Gn,onMouseOver:Gn,tabIndex:-1};return a.createElement(ce,Be({},fe,{innerProps:dv,data:Pt,isDisabled:zt,isSelected:Gt,key:Kn,label:Kt,type:Lt,value:pr,isFocused:Un,innerRef:Un?P.getFocusedOptionRef:void 0}),P.formatOptionLabel(rt.data,"menu"))};if(this.hasOptions())tt=this.getCategorizedOptions().map((function(rt){if(rt.type==="group"){var qt=rt.data,Lt=rt.options,Pt=rt.index,zt="".concat(P.getElementId("group"),"-").concat(Pt),Gt="".concat(zt,"-heading");return a.createElement(te,Be({},fe,{key:zt,data:qt,options:Lt,Heading:oe,headingProps:{id:Gt,data:rt.data},label:P.formatGroupLabel(rt.data)}),rt.options.map((function(Kt){return dt(Kt,"".concat(Pt,"-").concat(Kt.index))})))}if(rt.type==="option")return dt(rt,"".concat(rt.index))}));else if(_e){var Et=xe({inputValue:be});if(Et===null)return null;tt=a.createElement(ie,fe,Et)}else{var xt=at({inputValue:be});if(xt===null)return null;tt=a.createElement(ae,fe,xt)}var Ut={minMenuHeight:Me,maxMenuHeight:Te,menuPlacement:Le,menuPosition:Re,menuShouldScrollIntoView:Ue},tn=a.createElement(y5,Be({},fe,Ut),(function(rt){var qt=rt.ref,Lt=rt.placerProps,Pt=Lt.placement,zt=Lt.maxHeight;return a.createElement(V,Be({},fe,Ut,{innerRef:qt,innerProps:{onMouseDown:P.onMenuMouseDown,onMouseMove:P.onMenuMouseMove,id:P.getElementId("listbox")},isLoading:_e,placement:Pt}),a.createElement(z5,{captureEnabled:ye,onTopArrive:Qe,onBottomArrive:ut,lockEnabled:Ve},(function(Gt){return a.createElement(J,Be({},fe,{innerRef:function(Kt){P.getMenuListRef(Kt),Gt(Kt)},isLoading:_e,maxHeight:zt,focusedOption:ve}),tt)})))}));return He||Re==="fixed"?a.createElement(Y,Be({},fe,{appendTo:He,controlElement:this.controlRef,menuPlacement:Le,menuPosition:Re}),tn):tn}},{key:"renderFormField",value:function(){var P=this,T=this.props,te=T.delimiter,oe=T.isDisabled,V=T.isMulti,J=T.name,Y=T.required,ie=this.state.selectValue;if(Y&&!this.hasValue()&&!oe)return a.createElement(H5,{name:J,onFocus:this.onValueInputFocus});if(J&&!oe){if(V){if(te){var ae=ie.map((function(ve){return P.getOptionValue(ve)})).join(te);return a.createElement("input",{name:J,type:"hidden",value:ae})}var ce=ie.length>0?ie.map((function(ve,he){return a.createElement("input",{key:"i-".concat(he),name:J,type:"hidden",value:P.getOptionValue(ve)})})):a.createElement("input",{name:J,type:"hidden",value:""});return a.createElement("div",null,ce)}var fe=ie[0]?this.getOptionValue(ie[0]):"";return a.createElement("input",{name:J,type:"hidden",value:fe})}}},{key:"renderLiveRegion",value:function(){var P=this.commonProps,T=this.state,te=T.ariaSelection,oe=T.focusedOption,V=T.focusedValue,J=T.isFocused,Y=T.selectValue,ie=this.getFocusableOptions();return a.createElement(M5,Be({},P,{id:this.getElementId("live-region"),ariaSelection:te,focusedOption:oe,focusedValue:V,isFocused:J,selectValue:Y,focusableOptions:ie}))}},{key:"render",value:function(){var P=this.getComponents(),T=P.Control,te=P.IndicatorsContainer,oe=P.SelectContainer,V=P.ValueContainer,J=this.props,Y=J.className,ie=J.id,ae=J.isDisabled,ce=J.menuIsOpen,fe=this.state.isFocused,ve=this.commonProps=this.getCommonProps();return a.createElement(oe,Be({},ve,{className:Y,innerProps:{id:ie,onKeyDown:this.onKeyDown},isDisabled:ae,isFocused:fe}),this.renderLiveRegion(),a.createElement(T,Be({},ve,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:ae,isFocused:fe,menuIsOpen:ce}),a.createElement(V,Be({},ve,{isDisabled:ae}),this.renderPlaceholderOrValue(),this.renderInput()),a.createElement(te,Be({},ve,{isDisabled:ae}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],x=[{key:"getDerivedStateFromProps",value:function(P,T){var te=T.prevProps,oe=T.clearFocusValueOnUpdate,V=T.inputIsHiddenAfterUpdate,J=T.ariaSelection,Y=T.isFocused,ie=T.prevWasFocused,ae=P.options,ce=P.value,fe=P.menuIsOpen,ve=P.inputValue,he=P.isMulti,ye=Ha(ce),be={};if(te&&(ce!==te.value||ae!==te.options||fe!==te.menuIsOpen||ve!==te.inputValue)){var _e=fe?(function(Re,He){return nS(tS(Re,He))})(P,ye):[],xe=oe?(function(Re,He){var Ve=Re.focusedValue,Ue=Re.selectValue.indexOf(Ve);if(Ue>-1){if(He.indexOf(Ve)>-1)return Ve;if(Ue<He.length)return He[Ue]}return null})(T,ye):null,Me=(function(Re,He){var Ve=Re.focusedOption;return Ve&&He.indexOf(Ve)>-1?Ve:He[0]})(T,_e);be={selectValue:ye,focusedOption:Me,focusedValue:xe,clearFocusValueOnUpdate:!1}}var Te=V!=null&&P!==te?{inputIsHidden:V,inputIsHiddenAfterUpdate:void 0}:{},De=J,Le=Y&&ie;return Y&&!Le&&(De={value:ei(he,ye,ye[0]||null),options:ye,action:"initial-input-focus"},Le=!ie),J?.action==="initial-input-focus"&&(De=null),Fe(Fe(Fe({},be),Te),{},{prevProps:P,ariaSelection:De,prevWasFocused:Le})}}],b&&ZE(v.prototype,b),x&&ZE(v,x),Object.defineProperty(v,"prototype",{writable:!1}),L})(a.Component);iv.defaultProps=U5;var K5=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function uS(i){var v=i.defaultInputValue,b=v===void 0?"":v,x=i.defaultMenuIsOpen,D=x!==void 0&&x,B=i.defaultValue,G=B===void 0?null:B,L=i.inputValue,P=i.menuIsOpen,T=i.onChange,te=i.onInputChange,oe=i.onMenuClose,V=i.onMenuOpen,J=i.value,Y=wn(i,K5),ie=qn((0,a.useState)(L!==void 0?L:b),2),ae=ie[0],ce=ie[1],fe=qn((0,a.useState)(P!==void 0?P:D),2),ve=fe[0],he=fe[1],ye=qn((0,a.useState)(J!==void 0?J:G),2),be=ye[0],_e=ye[1],xe=(0,a.useCallback)((function(Ve,Ue){typeof T=="function"&&T(Ve,Ue),_e(Ve)}),[T]),Me=(0,a.useCallback)((function(Ve,Ue){var at;typeof te=="function"&&(at=te(Ve,Ue)),ce(at!==void 0?at:Ve)}),[te]),Te=(0,a.useCallback)((function(){typeof V=="function"&&V(),he(!0)}),[V]),De=(0,a.useCallback)((function(){typeof oe=="function"&&oe(),he(!1)}),[oe]),Le=L!==void 0?L:ae,Re=P!==void 0?P:ve,He=J!==void 0?J:be;return Fe(Fe({},Y),{},{inputValue:Le,menuIsOpen:Re,onChange:xe,onInputChange:Me,onMenuClose:De,onMenuOpen:Te,value:He})}var W5=["allowCreateWhileLoading","createOptionPosition","formatCreateLabel","isValidNewOption","getNewOptionData","onCreateOption","options","onChange"],cS=function(){var i=arguments.length>1?arguments[1]:void 0,v=arguments.length>2?arguments[2]:void 0,b=String(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"").toLowerCase(),x=String(v.getOptionValue(i)).toLowerCase(),D=String(v.getOptionLabel(i)).toLowerCase();return x===b||D===b},av={formatCreateLabel:function(i){return'Create "'.concat(i,'"')},isValidNewOption:function(i,v,b,x){return!(!i||v.some((function(D){return cS(i,D,x)}))||b.some((function(D){return cS(i,D,x)})))},getNewOptionData:function(i,v){return{label:v,value:i,__isNew__:!0}}},Y5=(0,a.forwardRef)((function(i,v){var b=(function(x){var D=x.allowCreateWhileLoading,B=D!==void 0&&D,G=x.createOptionPosition,L=G===void 0?"last":G,P=x.formatCreateLabel,T=P===void 0?av.formatCreateLabel:P,te=x.isValidNewOption,oe=te===void 0?av.isValidNewOption:te,V=x.getNewOptionData,J=V===void 0?av.getNewOptionData:V,Y=x.onCreateOption,ie=x.options,ae=ie===void 0?[]:ie,ce=x.onChange,fe=wn(x,W5),ve=fe.getOptionValue,he=ve===void 0?Jx:ve,ye=fe.getOptionLabel,be=ye===void 0?Qx:ye,_e=fe.inputValue,xe=fe.isLoading,Me=fe.isMulti,Te=fe.value,De=fe.name,Le=(0,a.useMemo)((function(){return oe(_e,Ha(Te),ae,{getOptionValue:he,getOptionLabel:be})?J(_e,T(_e)):void 0}),[T,J,be,he,_e,oe,ae,Te]),Re=(0,a.useMemo)((function(){return!B&&xe||!Le?ae:L==="first"?[Le].concat(Wo(ae)):[].concat(Wo(ae),[Le])}),[B,L,xe,Le,ae]),He=(0,a.useCallback)((function(Ve,Ue){if(Ue.action!=="select-option")return ce(Ve,Ue);var at=Array.isArray(Ve)?Ve:[Ve];if(at[at.length-1]!==Le)ce(Ve,Ue);else if(Y)Y(_e);else{var Qe=J(_e,_e),ut={action:"create-option",name:De,option:Qe};ce(ei(Me,[].concat(Wo(Ha(Te)),[Qe]),Qe),ut)}}),[J,_e,Me,De,Le,Y,ce,Te]);return Fe(Fe({},fe),{},{options:Re,onChange:He})})(uS(i));return a.createElement(iv,Be({ref:v},b))})),fS=Y5,Z5=(0,a.forwardRef)((function(i,v){var b=uS(i);return a.createElement(iv,Be({ref:v},b))})),dS=Number.isNaN||function(i){return typeof i=="number"&&i!=i};function X5(i,v){if(i.length!==v.length)return!1;for(var b=0;b<i.length;b++)if(!((x=i[b])===(D=v[b])||dS(x)&&dS(D)))return!1;var x,D;return!0}const sv=function(i,v){var b;v===void 0&&(v=X5);var x,D=[],B=!1;return function(){for(var G=[],L=0;L<arguments.length;L++)G[L]=arguments[L];return B&&b===this&&v(G,D)||(x=i.apply(this,G),B=!0,b=this,D=G),x}};var hS=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()};function pS(i){cancelAnimationFrame(i.id)}var lv=-1;function vS(i){if(i===void 0&&(i=!1),lv===-1||i){var v=document.createElement("div"),b=v.style;b.width="50px",b.height="50px",b.overflow="scroll",document.body.appendChild(v),lv=v.offsetWidth-v.clientWidth,document.body.removeChild(v)}return lv}var ni=null;function gS(i){if(i===void 0&&(i=!1),ni===null||i){var v=document.createElement("div"),b=v.style;b.width="50px",b.height="50px",b.overflow="scroll",b.direction="rtl";var x=document.createElement("div"),D=x.style;return D.width="100px",D.height="100px",v.appendChild(x),document.body.appendChild(v),v.scrollLeft>0?ni="positive-descending":(v.scrollLeft=1,ni=v.scrollLeft===0?"negative":"positive-ascending"),document.body.removeChild(v),ni}return ni}var Q5=function(i,v){return i};function J5(i){var v,b=i.getItemOffset,x=i.getEstimatedTotalSize,D=i.getItemSize,B=i.getOffsetForIndexAndAlignment,G=i.getStartIndexForOffset,L=i.getStopIndexForStartIndex,P=i.initInstanceProps,T=i.validateProps;return v=(function(te){function oe(J){var Y;return(Y=te.call(this,J)||this)._instanceProps=P(Y.props,Mp(Y)),Y._outerRef=void 0,Y._resetIsScrollingTimeoutId=null,Y.state={instance:Mp(Y),isScrolling:!1,scrollDirection:"forward",scrollOffset:typeof Y.props.initialScrollOffset=="number"?Y.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},Y._callOnItemsRendered=void 0,Y._callOnItemsRendered=sv((function(ie,ae,ce,fe){return Y.props.onItemsRendered({overscanStartIndex:ie,overscanStopIndex:ae,visibleStartIndex:ce,visibleStopIndex:fe})})),Y._callOnScroll=void 0,Y._callOnScroll=sv((function(ie,ae,ce){return Y.props.onScroll({scrollDirection:ie,scrollOffset:ae,scrollUpdateWasRequested:ce})})),Y._getItemStyle=void 0,Y._getItemStyle=function(ie){var ae,ce=Y.props,fe=ce.direction,ve=ce.itemSize,he=ce.layout,ye=Y._getItemStyleCache(ve,he,fe);if(ye.hasOwnProperty(ie))ae=ye[ie];else{var be=b(Y.props,ie,Y._instanceProps),_e=D(Y.props,ie,Y._instanceProps),xe=fe==="horizontal"||he==="horizontal",Me=fe==="rtl",Te=xe?be:0;ye[ie]=ae={position:"absolute",left:Me?void 0:Te,right:Me?Te:void 0,top:xe?0:be,height:xe?"100%":_e,width:xe?_e:"100%"}}return ae},Y._getItemStyleCache=void 0,Y._getItemStyleCache=sv((function(ie,ae,ce){return{}})),Y._onScrollHorizontal=function(ie){var ae=ie.currentTarget,ce=ae.clientWidth,fe=ae.scrollLeft,ve=ae.scrollWidth;Y.setState((function(he){if(he.scrollOffset===fe)return null;var ye=Y.props.direction,be=fe;if(ye==="rtl")switch(gS()){case"negative":be=-fe;break;case"positive-descending":be=ve-ce-fe}return be=Math.max(0,Math.min(be,ve-ce)),{isScrolling:!0,scrollDirection:he.scrollOffset<fe?"forward":"backward",scrollOffset:be,scrollUpdateWasRequested:!1}}),Y._resetIsScrollingDebounced)},Y._onScrollVertical=function(ie){var ae=ie.currentTarget,ce=ae.clientHeight,fe=ae.scrollHeight,ve=ae.scrollTop;Y.setState((function(he){if(he.scrollOffset===ve)return null;var ye=Math.max(0,Math.min(ve,fe-ce));return{isScrolling:!0,scrollDirection:he.scrollOffset<ye?"forward":"backward",scrollOffset:ye,scrollUpdateWasRequested:!1}}),Y._resetIsScrollingDebounced)},Y._outerRefSetter=function(ie){var ae=Y.props.outerRef;Y._outerRef=ie,typeof ae=="function"?ae(ie):ae!=null&&typeof ae=="object"&&ae.hasOwnProperty("current")&&(ae.current=ie)},Y._resetIsScrollingDebounced=function(){var ie,ae,ce,fe;Y._resetIsScrollingTimeoutId!==null&&pS(Y._resetIsScrollingTimeoutId),Y._resetIsScrollingTimeoutId=(ie=Y._resetIsScrolling,ae=150,ce=hS(),fe={id:requestAnimationFrame((function ve(){hS()-ce>=ae?ie.call(null):fe.id=requestAnimationFrame(ve)}))})},Y._resetIsScrolling=function(){Y._resetIsScrollingTimeoutId=null,Y.setState({isScrolling:!1},(function(){Y._getItemStyleCache(-1,null)}))},Y}JO(oe,te),oe.getDerivedStateFromProps=function(J,Y){return e3(J,Y),T(J),null};var V=oe.prototype;return V.scrollTo=function(J){J=Math.max(0,J),this.setState((function(Y){return Y.scrollOffset===J?null:{scrollDirection:Y.scrollOffset<J?"forward":"backward",scrollOffset:J,scrollUpdateWasRequested:!0}}),this._resetIsScrollingDebounced)},V.scrollToItem=function(J,Y){Y===void 0&&(Y="auto");var ie=this.props,ae=ie.itemCount,ce=ie.layout,fe=this.state.scrollOffset;J=Math.max(0,Math.min(J,ae-1));var ve=0;if(this._outerRef){var he=this._outerRef;ve=ce==="vertical"?he.scrollWidth>he.clientWidth?vS():0:he.scrollHeight>he.clientHeight?vS():0}this.scrollTo(B(this.props,J,Y,fe,this._instanceProps,ve))},V.componentDidMount=function(){var J=this.props,Y=J.direction,ie=J.initialScrollOffset,ae=J.layout;if(typeof ie=="number"&&this._outerRef!=null){var ce=this._outerRef;Y==="horizontal"||ae==="horizontal"?ce.scrollLeft=ie:ce.scrollTop=ie}this._callPropsCallbacks()},V.componentDidUpdate=function(){var J=this.props,Y=J.direction,ie=J.layout,ae=this.state,ce=ae.scrollOffset;if(ae.scrollUpdateWasRequested&&this._outerRef!=null){var fe=this._outerRef;if(Y==="horizontal"||ie==="horizontal")if(Y==="rtl")switch(gS()){case"negative":fe.scrollLeft=-ce;break;case"positive-ascending":fe.scrollLeft=ce;break;default:var ve=fe.clientWidth,he=fe.scrollWidth;fe.scrollLeft=he-ve-ce}else fe.scrollLeft=ce;else fe.scrollTop=ce}this._callPropsCallbacks()},V.componentWillUnmount=function(){this._resetIsScrollingTimeoutId!==null&&pS(this._resetIsScrollingTimeoutId)},V.render=function(){var J=this.props,Y=J.children,ie=J.className,ae=J.direction,ce=J.height,fe=J.innerRef,ve=J.innerElementType,he=J.innerTagName,ye=J.itemCount,be=J.itemData,_e=J.itemKey,xe=_e===void 0?Q5:_e,Me=J.layout,Te=J.outerElementType,De=J.outerTagName,Le=J.style,Re=J.useIsScrolling,He=J.width,Ve=this.state.isScrolling,Ue=ae==="horizontal"||Me==="horizontal",at=Ue?this._onScrollHorizontal:this._onScrollVertical,Qe=this._getRangeToRender(),ut=Qe[0],tt=Qe[1],dt=[];if(ye>0)for(var Et=ut;Et<=tt;Et++)dt.push((0,a.createElement)(Y,{data:be,key:xe(Et,be),index:Et,isScrolling:Re?Ve:void 0,style:this._getItemStyle(Et)}));var xt=x(this.props,this._instanceProps);return(0,a.createElement)(Te||De||"div",{className:ie,onScroll:at,ref:this._outerRefSetter,style:Be({position:"relative",height:ce,width:He,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:ae},Le)},(0,a.createElement)(ve||he||"div",{children:dt,ref:fe,style:{height:Ue?"100%":xt,pointerEvents:Ve?"none":void 0,width:Ue?xt:"100%"}}))},V._callPropsCallbacks=function(){if(typeof this.props.onItemsRendered=="function"&&this.props.itemCount>0){var J=this._getRangeToRender(),Y=J[0],ie=J[1],ae=J[2],ce=J[3];this._callOnItemsRendered(Y,ie,ae,ce)}if(typeof this.props.onScroll=="function"){var fe=this.state,ve=fe.scrollDirection,he=fe.scrollOffset,ye=fe.scrollUpdateWasRequested;this._callOnScroll(ve,he,ye)}},V._getRangeToRender=function(){var J=this.props,Y=J.itemCount,ie=J.overscanCount,ae=this.state,ce=ae.isScrolling,fe=ae.scrollDirection,ve=ae.scrollOffset;if(Y===0)return[0,0,0,0];var he=G(this.props,ve,this._instanceProps),ye=L(this.props,he,ve,this._instanceProps),be=ce&&fe!=="backward"?1:Math.max(1,ie),_e=ce&&fe!=="forward"?1:Math.max(1,ie);return[Math.max(0,he-be),Math.max(0,Math.min(Y-1,ye+_e)),he,ye]},oe})(a.PureComponent),v.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},v}var e3=function(i,v){i.children,i.direction,i.height,i.layout,i.innerTagName,i.outerTagName,i.width,v.instance},t3=J5({getItemOffset:function(i,v){return v*i.itemSize},getItemSize:function(i,v){return i.itemSize},getEstimatedTotalSize:function(i){var v=i.itemCount;return i.itemSize*v},getOffsetForIndexAndAlignment:function(i,v,b,x,D,B){var G=i.direction,L=i.height,P=i.itemCount,T=i.itemSize,te=i.layout,oe=i.width,V=G==="horizontal"||te==="horizontal"?oe:L,J=Math.max(0,P*T-V),Y=Math.min(J,v*T),ie=Math.max(0,v*T-V+T+B);switch(b==="smart"&&(b=x>=ie-V&&x<=Y+V?"auto":"center"),b){case"start":return Y;case"end":return ie;case"center":var ae=Math.round(ie+(Y-ie)/2);return ae<Math.ceil(V/2)?0:ae>J+Math.floor(V/2)?J:ae;default:return x>=ie&&x<=Y?x:x<ie?ie:Y}},getStartIndexForOffset:function(i,v){var b=i.itemCount,x=i.itemSize;return Math.max(0,Math.min(b-1,Math.floor(v/x)))},getStopIndexForStartIndex:function(i,v,b){var x=i.direction,D=i.height,B=i.itemCount,G=i.itemSize,L=i.layout,P=i.width,T=v*G,te=x==="horizontal"||L==="horizontal"?P:D,oe=Math.ceil((te+b-T)/G);return Math.max(0,Math.min(B-1,v+oe-1))},initInstanceProps:function(i){},validateProps:function(i){i.itemSize}});function yS(i,v){(v==null||v>i.length)&&(v=i.length);for(var b=0,x=new Array(v);b<v;b++)x[b]=i[b];return x}for(var n3=[],Ya=0;Ya<1e4;Ya+=1)n3.push({value:Ya,label:"Option ".concat(Ya)});const r3=function(i){var v=i.options,b=i.children,x=i.maxHeight,D=(function(G,L){return(function(P){if(Array.isArray(P))return P})(G)||(function(P,T){var te=P==null?null:typeof Symbol<"u"&&P[Symbol.iterator]||P["@@iterator"];if(te!=null){var oe,V,J,Y,ie=[],ae=!0,ce=!1;try{if(J=(te=te.call(P)).next,T!==0)for(;!(ae=(oe=J.call(te)).done)&&(ie.push(oe.value),ie.length!==T);ae=!0);}catch(fe){ce=!0,V=fe}finally{try{if(!ae&&te.return!=null&&(Y=te.return(),Object(Y)!==Y))return}finally{if(ce)throw V}}return ie}})(G,L)||(function(P,T){if(P){if(typeof P=="string")return yS(P,T);var te=Object.prototype.toString.call(P).slice(8,-1);return te==="Object"&&P.constructor&&(te=P.constructor.name),te==="Map"||te==="Set"?Array.from(P):te==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(te)?yS(P,T):void 0}})(G,L)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
27
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,
|
|
28
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function
|
|
29
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function wS(i,v){if(i){if(typeof i=="string")return fv(i,v);var b=Object.prototype.toString.call(i).slice(8,-1);return b==="Object"&&i.constructor&&(b=i.constructor.name),b==="Map"||b==="Set"?Array.from(i):b==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(b)?fv(i,v):void 0}}function fv(i,v){(v==null||v>i.length)&&(v=i.length);for(var b=0,x=new Array(v);b<v;b++)x[b]=i[b];return x}function OS(i,v){var b=Object.keys(i);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(i);v&&(x=x.filter((function(D){return Object.getOwnPropertyDescriptor(i,D).enumerable}))),b.push.apply(b,x)}return b}function Vt(i){for(var v=1;v<arguments.length;v++){var b=arguments[v]!=null?arguments[v]:{};v%2?OS(Object(b),!0).forEach((function(x){Qa(i,x,b[x])})):Object.getOwnPropertyDescriptors?Object.defineProperties(i,Object.getOwnPropertyDescriptors(b)):OS(Object(b)).forEach((function(x){Object.defineProperty(i,x,Object.getOwnPropertyDescriptor(b,x))}))}return i}function Qa(i,v,b){return(v=(function(x){var D=(function(B,G){if(oi(B)!=="object"||B===null)return B;var L=B[Symbol.toPrimitive];if(L!==void 0){var P=L.call(B,"string");if(oi(P)!=="object")return P;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(B)})(x);return oi(D)==="symbol"?D:String(D)})(v))in i?Object.defineProperty(i,v,{value:b,enumerable:!0,configurable:!0,writable:!0}):i[v]=b,i}var a3={type:"",label:"",key:"",placeholder:"",invalid:function(){return!1},disabled:function(){return!1},options:{},disableOptionFn:function(){return!1},disableOptionText:function(){return null},pending:!1,isMulti:!1,component:null,style:{},className:"col-12",additionalInputParams:{},optimizeMenuList:!1},s3=function(i){var v=i.c,b=i.editedResource,x=i.onChange,D=i.setEntireResource;return a.createElement("div",{className:v.className,style:v.style,key:v.key,id:v.key},v.label,v.component({value:mR(b[v.key]),initialState:Vt({},b),editedResource:b,onChange:function(B){return x(v.key,B)},setEntireResource:function(B){return D(B)}}),v.invalid(b)&&a.createElement("span",{className:"invalid-feedback d-block"},v.invalidMessage))},l3=function(i){var v=i.c,b=i.editedResource,x=i.onChange;return a.createElement("div",{className:v.className,style:v.style,key:v.key,id:v.key},v.label,a.createElement("div",{className:"text-nowrap"},Object.keys(v.options).map((function(D){return a.createElement(lr,{key:D,className:"btn-sm",color:D===b[v.key]?"primary":"secondary",onClick:function(){return x(v.key,D)},disabled:v.disabled(b)},v.options[D])}))))},Ja=function(i,v){if(!v.groupOptionsBy)return i;var b=kR((function(x){return x[v.groupOptionsBy]}))(i);return Object.entries(b).map((function(x){var D=cv(x,2);return{label:D[0],options:D[1]}}))},u3=function(i){var v=Vt(Vt({},i),{},{data:i.data});return a.createElement(Fx.Option,v,a.createElement("div",null,i.data.label),i.data.description&&a.createElement("small",null,i.data.description))},c3=function(i){var v,b=i.c,x=i.editedResource,D=i.onChange,B={};b.advancedOptions?(v=b.advancedOptions,B.Option=u3):v=Object.keys(b.options).map((function(L){return{value:L,label:b.options[L]}}));var G=b.isMulti?a.createElement(a.Fragment,null,!b.hideAddAll&&!b.disabled(x)&&a.createElement(UE,{className:"ml-2 mb-1 btn-sm",onClick:function(){return D(b.key,v.map((function(L){return L.value})))}},"Add All"),a.createElement(_S,{value:x[b.key]?x[b.key].map((function(L){return Ca(Aa("value",String(L)))(v)})):[],options:Ja(v,b),placeholder:b.placeholder,onChange:function(L){return D(b.key,(L||[]).map((function(P){return P.value})))},invalid:b.invalid(x),invalidMessage:b.invalidMessage,disabled:b.disabled(x),closeMenuOnSelect:b.closeMenuOnSelect,pending:b.pending,components:B,isMulti:!0})):a.createElement(_S,{value:Ca(Aa("value",String(x[b.key])))(v),options:Ja(v,b),placeholder:b.placeholder,onChange:function(L){return D(b.key,L.value)},invalid:b.invalid(x),invalidMessage:b.invalidMessage,disabled:b.disabled(x),closeMenuOnSelect:b.closeMenuOnSelect,pending:b.pending,components:B});return a.createElement("label",{className:b.className,style:b.style,key:b.key,id:b.key},b.label,G,a.createElement(Wr,{invalid:b.invalid(x),style:{display:"none"}}),a.createElement(Go,null,b.invalidMessage))},ES=function(i){var v,b=i.c,x=i.editedResource,D=i.onChange;v=b.advancedOptions?b.advancedOptions:Object.keys(b.options).map((function(Y){return{value:Y,label:b.options[Y]}}));var B=x[b.key],G=cv(a.useState([]),2),L=G[0],P=G[1],T=[].concat(eo(v),eo(L));a.useEffect((function(){if(B){var Y=T.map((function(ie){return ie.value}));if(b.isMulti)B.forEach((function(ie){Y.includes(ie)||P([].concat(eo(L),[{value:ie,label:ie}]))}));else{if(Y.includes(B))return;P([].concat(eo(L),[{value:B,label:B}]))}}}),[b.options]);var te,oe=function(Y){kp(Y)||HE(Y)||kp(Y.value)||HE(Y.value)||(D(b.key,Y.value),T.map((function(ie){return ie.value})).includes(Y.value)||b.invalid(Vt(Vt({},x),{},Qa({},b.key,Y.value)))||P([].concat(eo(L),[{value:Y.value,label:Y.value}])))},V=function(Y){if(!kp(Y)&&Y&&typeof Y!="string"){var ie=Y.map((function(ce){return ce.value}));D(b.key,ie);var ae=T.map((function(ce){return ce.value}));ie.forEach((function(ce){ae.includes(ce)||b.invalid(Vt(Vt({},x),{},Qa({},b.key,ce)))||P([].concat(eo(L),[{value:ce,label:ce}]))}))}},J=b.isMulti?a.createElement(a.Fragment,null,!b.hideAddAll&&!b.disabled(x)&&a.createElement(UE,{className:"ml-2 mb-1 btn-sm",onClick:function(){return D(b.key,v.map((function(Y){return Y.value})))}},"Add All"),a.createElement(fS,{value:(B||[]).map((function(Y){return Ca(Aa("value",Y))(T)})),isMulti:b.isMulti,onChange:function(Y){return V(Y)},onInputChange:function(Y){return V(Y)},options:Ja(T,b),pending:b.pending,placeholder:b.placeholder})):a.createElement(fS,{value:{value:B,label:(te=Ca(Aa("value",B))(T),te&&te.label?te.label:"")},onChange:function(Y){return oe(Y)},onInputChange:function(Y){return oe(Y)},options:Ja(T,b),pending:b.pending,isValidNewOption:function(Y,ie,ae){return!ae.find((function(ce){return ce.value===Y}))},placeholder:b.placeholder});return a.createElement("label",{className:b.className,style:b.style,form:!0,key:b.key,id:b.key},b.label,J,a.createElement(Wr,{invalid:b.invalid(x),style:{display:"none"}}),a.createElement(Go,null,b.invalidMessage))},f3=function(i){var v=i.c,b=i.editedResource,x=i.onChange,D=usePromise(v.optionsPromise,{});return a.createElement(ES,{c:Vt(Vt({},v),{},{options:D.response}),editedResource:b,onChange:x,pending:D.loading})},d3=function(i){var v=i.c,b=i.editedResource,x=i.onChange;return a.createElement("label",{className:"".concat(v.className," ml-4"),style:v.style,key:v.key,id:v.key},a.createElement(Wr,{type:v.type,checked:b[v.key]==="true"?"true":"",onChange:function(D){return x(v.key,D.target.checked.toString())},disabled:v.disabled(b)}),v.label,a.createElement(Go,null,v.invalidMessage))},h3=function(i){var v=i.c,b=(i.editedResource,i.onChange);return a.createElement("div",{className:"".concat(v.className),style:v.style,key:v.key,id:v.key},v.label,Object.entries(v.options).map((function(x){var D=cv(x,2),B=D[0],G=D[1];return a.createElement("label",{key:B,className:"d-block ml-4"},a.createElement(Wr,{type:"radio",value:B,name:v.key,onChange:function(L){return b(v.key,B)},defaultChecked:v.default===B?"checked":""}),G)})))},p3=function(i){var v=i.c,b=i.editedResource,x=i.onChange;return a.createElement("label",{className:v.className,style:v.style,key:v.key,id:v.key},v.label,a.createElement(Wr,{type:v.type,value:b[v.key],onChange:function(D){return x(v.key,D.target.value)},placeholder:v.placeholder,invalid:v.invalid(b),disabled:v.disabled(b)}),a.createElement(Go,null,v.invalidMessage))},v3=function(i){var v=i.c,b=i.editedResource,x=i.onChange;return a.createElement("label",{className:v.className,style:v.style,key:v.key,id:v.key},v.label,a.createElement(Wr,Xa({type:v.type,onChange:function(D){return x(v.key,D.target.files)},invalid:v.invalid(b),disabled:v.disabled(b)},v.additionalInputParams)),a.createElement(Go,null,v.invalidMessage))},xS=function(i){var v=i.editedResource,b=function(D,B){i.onChange(Vt(Vt({},v),{},Qa({},D,B)))},x=i.controls.filter(Boolean).map((function(D){return(function(B,G,L,P){var T=Vt(Vt({},a3),B),te={c:T,editedResource:G,onChange:L};return T.hidden&&T.hidden(G)?null:T.type==="custom"?a.createElement(s3,Xa({},te,{setEntireResource:P})):T.type==="toggle"?a.createElement(l3,te):T.type==="select"?a.createElement(c3,te):T.type==="creatableSelect"?a.createElement(ES,te):T.type==="promiseCreatableSelect"?a.createElement(f3,te):T.type==="checkbox"?a.createElement(d3,te):T.type==="radio"?a.createElement(h3,te):T.type==="file"?a.createElement(v3,te):a.createElement(p3,te)})(D,v,b,i.onChange)}));return a.createElement("section",{className:"resource-editor-controls ".concat(i.className),style:i.style},i.viewOnlyControls&&a.createElement("ul",{className:"list-unstyled"},i.viewOnlyControls.map((function(D){return a.createElement("li",null,a.createElement("strong",{className:"mr-2"},D.key,":")," ",v[D.key])}))),x)};xS.defaultProps={className:"row",style:{},viewOnlyControls:[]}})(),c})()))})(Dh)),Dh.exports}var Ye=nq();const _O=async(e,t)=>await fetch("undefined/collaboration/replica/copyFileReplica",{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:t,certificateType:"Public"})}),rq=e=>{const[t,n]=se.useState(!1);return e.type!=="fileLayerNode"||!e.isNodeHover?null:$.jsx("div",{className:"position-absolute",style:{right:0},children:$.jsx("span",{className:`badge rounded-pill text-white ${t?"bg-primary":"bg-secondary"}`,style:{fontSize:"1.35rem",marginTop:"0.75rem"},onMouseEnter:()=>n(!0),onMouseLeave:()=>n(!1),onClick:()=>{e.toggle&&e.toggle()},children:"COPY"})})},oq=e=>{const[t,n]=se.useState(!1),r=()=>n(!t);return e.type!=="fileLayerNode"?null:$.jsxs($.Fragment,{children:[$.jsx(Ye.Button,{id:"copy-filelayer-btn",className:"btn-sm",onClick:()=>r(),children:"Copy File Set"}),$.jsx(wO,{...e,isOpen:t,toggle:r})]})},wO=({vertexId:e,certificateId:t,refresh:n,isOpen:r,toggle:o})=>{const[s,l]=se.useState(!1),c=async()=>{l(!0);try{await _O(e,t).then(async f=>{if(f.ok)n&&n(),Ke.success("Copied file into workspace.");else{const h=await f.json();Ke.error("Unable to copy file: "+h.Message)}o()})}catch(f){console.log(f)}l(!1)};return $.jsx(Ye.ConfirmationModal,{id:"copy-filelayer-modal",className:"top-25",pending:s,isOpen:r,onClose:o,headerContent:"Do you want to copy all files in this file set into your workspace?",cancelButtonText:"Close",onSubmit:()=>c()})},iq=()=>{const{node:e,setNode:t,certificate:n,type:r,nodeLayers:o,setNodeLayers:s}=ot();if(!o.previous.nodes.length)return null;const l=()=>{s({previous:{nodes:[],edges:[]},current:o.previous}),t({})};return $.jsxs("div",{className:"position-absolute ml-4 mt-3",style:{zIndex:1},children:[$.jsx(Ye.Button,{id:"layer-back-button",onClick:l,icon:"fas fa-long-arrow-alt-left",children:"Back"}),$.jsx("span",{id:"subgraph-msg",className:"ml-3 me-3 mr-3 ms-3 font-italic fst-italic fw-bold font-weight-bold",children:"Currently viewing subgraph of a file set"}),$.jsx(oq,{vertexId:e.id,certificateId:n.id,type:r,refresh:e.data?.refresh})]})},aq=(e,t)=>{const n={backgroundColor:"white",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px"};switch(e){case"FileSet":case"Visualization":n.backgroundColor="yellow";break;case"File":case"IDE":n.borderColor="lightblue",t&&(n.borderColor="orange");break;default:n.borderColor="#BBBBBB";break}return n},sq=e=>({type:"text",key:"restrictionNotes",label:"Restriction Notes - Internal",invalid:n=>n.restrictionNotes.length<1}),lq=(e,t)=>Object.keys(t).filter(r=>r!==e).reduce((r,o)=>(r[o]=t[o],r),{}),uq=(e,t,n)=>{switch(e){case"reviewNode":return aq(t,n);case"readNode":case"editNode":default:return jh(t)}},sa=(e,t,n,r,o)=>{const s=cq(e,n,r,o),l=fq(t);return xO(s,l)},cq=(e,t,n,r)=>{const o={x:0,y:0},s=[];return bt(e)||dn(e)||e.forEach(l=>{const c=l.split("/")[0],f=t&&!!t[l];s.push({id:l,position:o,type:c!=="FileLayer"?n:"fileLayerNode",data:r??{},style:uq(n,c,f)})}),s},fq=e=>Object.entries(e||{}).reduce((t,[n,r])=>[...t,...r.map(o=>({id:`${n}-${o}`,source:n,target:o,type:"smoothstep",animated:!0}))],[]),OO=250,EO=75,xO=(e,t,n="LR")=>{const r=new uo.graphlib.Graph;r.setDefaultEdgeLabel(()=>({}));const o=n==="LR";return r.setGraph({nodesep:70,ranksep:110,rankdir:n}),e.forEach(s=>{r.setNode(s.id,{width:OO,height:EO})}),t.forEach(s=>{r.setEdge(s.source,s.target)}),uo.layout(r),e.forEach(s=>{const l=r.node(s.id);return s.targetPosition=o?Ce.Left:Ce.Top,s.sourcePosition=o?Ce.Right:Ce.Bottom,s.position={x:l.x-OO/2,y:l.y-EO/2},s}),{nodes:e,edges:t}},jh=e=>{const t={backgroundColor:"white",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px"};switch(e){case"FileSet":case"Visualization":t.backgroundColor="yellow";break;case"IngestReceipt":t.borderColor="#EE7733";break;case"FileLayer":case"File":t.borderColor="#33BBEE";break;case"IDE":t.borderColor="#882255";break;case"Pipeline":t.borderColor="#F283EB";break;case"Process":t.borderColor="#009988";break;case"Trace":t.borderColor="#999933";break;case"Specimen":case"Sample":case"Subject":case"Cohort":t.borderColor="#BBBBBB";break;case"Submission":t.borderColor="#285222";break;case"DirectUpload":t.borderColor="#F78383";break;default:t.borderColor="#eee";break}return t},SO=(e,t,n,r)=>{const o={};if(!["Sample","Subject"].includes(e)||!n||!r)return o;const s=n[t];return s&&Object.entries(s).forEach(([l,c])=>{l==="Survey Data Scheme Key"&&(o.surveyData=r[c]),l==="EMR Scheme Key"&&(o.emrData=r[c]),l==="Lab Data Scheme Key"&&(o.labData=r[c])}),o},dq=(e,t)=>{if(!t)return e;switch(e){case"FileSet":return $.jsxs($.Fragment,{children:["Data Set",$.jsx("br",{}),`(${t.Title})`]});case"Visualization":return $.jsxs($.Fragment,{children:[e,$.jsx("br",{}),`(${t.Title})`]});case"IngestReceipt":return"Data Ingested";case"DirectUpload":return"Data Directly Uploaded";case"FileLayer":return"File Set";case"File":return`.${t["File Extension"]} ${e}`;case"Process":case"Subject":case"IDE":case"Trace":case"Specimen":case"Sample":case"Cohort":case"Pipeline":case"Submission":return e;default:return null}},hq=(e,t)=>{if(!t)return null;switch(e){case"Cohort":case"FileSet":case"IDE":case"IngestReceipt":case"Pipeline":case"Subject":case"Submission":case"Trace":case"Visualization":return t.Description;case"Sample":return t["Visit Name"];case"Specimen":return t["Specimen Type"];case"File":return $.jsxs($.Fragment,{children:[t["File Type"]&&$.jsxs($.Fragment,{children:[t["File Type"],$.jsx("br",{})]}),$.jsx("span",{className:"font-italic",children:t["File Size"]})]});case"Process":return t.Type;case"FileLayer":default:return null}},kO=(e,t,n)=>{if(n==="false")return null;switch(e){case"Visualization":return`/collaboration/visualization/${t}`;case"IngestReceipt":return`/ingest-receipts/${t}`;case"File":return`/files/${t}`;case"Process":return`/processes/${t}`;case"Sample":return`/samples/${t}`;case"Subject":return`/subjects/${t}`;case"Cohort":return`/cohorts/${t}`;case"Pipeline":return`/pipelines/${t}`;case"Submission":return`/submissions/${t}`;case"FileLayer":default:return null}},NO=(e,t,n)=>{if(!t)return e;if(n==="demographicsData")return`${e[0].toUpperCase()}${e.split(/(?=[A-Z])/).join(" ").slice(1)}`;const r=t[e];return r&&r.friendlyName?r.friendlyName:e},TO=(e,t,n,r)=>{if(!n)return t;const o=n[e];return!o||r==="demographicsData"?t:o.units?`${t} ${o.units}`:t},CO=({entries:e,scheme:t,tab:n})=>$.jsx("table",{className:"table",children:$.jsx("tbody",{children:e.map(([r,o])=>$.jsxs("tr",{children:[$.jsx("th",{scope:"row",children:NO(r,t,n)}),$.jsx("td",{children:TO(r,o,t,n)})]},r))})}),pq=({activeEntry:e,setActiveEntry:t,emrData:n})=>$.jsx("div",{className:"text-center",children:$.jsxs("div",{className:"btn-group mb-3",children:[$.jsxs("button",{className:"btn btn-secondary dropdown-toggle",type:"button","data-bs-toggle":"dropdown","aria-expanded":"false",children:["Visit Day ",e]}),$.jsx("ul",{className:"dropdown-menu",children:n.map(r=>$.jsx("li",{children:$.jsxs("button",{type:"button",className:"dropdown-item",onClick:()=>t(r.daysSinceFirstResearchVisit),children:["Visit Day ",r.daysSinceFirstResearchVisit]})},r.daysSinceFirstResearchVisit))})]})}),vq=({emrData:e,scheme:t})=>{const[n,r]=se.useState(e[0].daysSinceFirstResearchVisit),o=Object.values(e),s=o.reduce((c,f)=>({...c,[f.daysSinceFirstResearchVisit]:f}),{}),l=Object.entries(s[n].patientData);return $.jsxs($.Fragment,{children:[$.jsx(pq,{activeEntry:n,setActiveEntry:r,emrData:o}),$.jsx(CO,{entries:l,scheme:t,tab:"emrData"})]})},gq=({metadata:e,scheme:t,activeTab:n})=>{const r=e[n],o=t[n],s=Object.entries(r||{});return n==="emrData"?$.jsx(vq,{emrData:r,scheme:o}):$.jsx(CO,{entries:s,scheme:o,tab:n})},yq=(e,t)=>t&&e==="Sample"?`${e} (${t["Visit Name"]})`:e,mq=e=>{const t=[],n=Object.keys(e);return n.length&&n.forEach(r=>{const s=e[r];bt(s)||t.push(r)}),t},AO=(e,t)=>{const n=e[t];return!(dn(n)||bt(n)||Object.values(n).every(s=>bt(s)))},bq=({tabs:e,activeTab:t,setActiveTab:n})=>$.jsx("ul",{className:"nav justify-content-center",children:e.map(r=>$.jsx("li",{className:"nav-item",children:$.jsx("button",{type:"button",className:`nav-link btn btn-link ${t===r&&"font-weight-bold"}`,onClick:()=>n(r),children:r.split(/(?=[A-Z])/).join(" ").toUpperCase()})},r))}),PO=({label:e,node:t})=>{const{certificate:n,setNode:r}=ot();if(!["Sample","Subject"].includes(e))return null;const{metadata:o}=n,{toggleMetadataModal:s}=t.data;return!AO(o,t.id)||!s?null:$.jsx(Ye.Button,{id:"metadata-btn",color:"link",className:"p-0",style:{lineHeight:"normal"},onClick:()=>{s(),r(t)},children:$.jsx("span",{style:{fontSize:"1.75rem"},children:"≡"})},"metadata-btn")},Fh=({isOpen:e,toggle:t})=>{const{node:n,certificate:r}=ot(),{id:o}=n,{metadata:s,schemes:l,serviceLabels:c,customLabels:f,generatedLabels:h}=r,[a,u]=se.useState({}),[d,p]=se.useState({}),[O,g]=se.useState({activeTab:"",description:"",header:"",tabs:[]});se.useEffect(()=>{if(!e||bt(s)||bt(n))return;const y=s[n.id],w=o?.split("/")[0],E=f[o]||h[o],m=yq(w,E),S=mq(y),C=SO(w,o,c,l);u(y),p(C),g(N=>({...N,activeTab:S[0],description:E,header:m,tabs:S}))},[e,n,s]);const _=y=>g(w=>({...w,activeTab:y}));return $.jsx(Ye.ConfirmationModal,{scrollable:!0,isOpen:e,onClose:t,headerContent:O.header,noSubmit:!0,cancelButtonText:"Close",content:$.jsxs($.Fragment,{children:[$.jsx(bq,{tabs:O.tabs,activeTab:O.activeTab,setActiveTab:_}),$.jsx("div",{className:"mt-2",children:$.jsx(gq,{metadata:a,scheme:d,activeTab:O.activeTab})})]})})},zn=({label:e,description:t})=>{const n=hq(e,t);return!n||!Object.keys(t).length?null:$.jsx("div",{className:"node-description text-center text-break",children:n})},An=({label:e,description:t,link:n})=>{const r=dq(e,t);return n?$.jsx("a",{href:`#${n}`,target:"_blank",rel:"noreferrer",className:"node-label text-break flex-fill",children:e}):$.jsx("div",{className:"node-label text-break flex-fill",children:r})},la=e=>{const{id:t}=e,{customLabels:n,generatedLabels:r}=ot().certificate,o=t.split("/")[0],s=n?.[t]||r?.[t];return $.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2",style:{width:"250px"},children:[$.jsxs("div",{className:"d-flex align-items-center",children:[$.jsx(An,{label:o,description:s}),$.jsx(PO,{label:o,node:e})]}),$.jsx(zn,{label:o,description:s})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},_q=e=>e==="Pipeline"?"workspacePipelineNode":e==="IDE"?"workspaceIDENode":e==="File"?"workspaceFileNode":e==="FileLayer"?"fileLayerNode":"readNode",wq=(e,t)=>{if(!t){const n={backgroundColor:"white",color:"#BBBBBB",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px",borderColor:"#eee"};return e==="FileLayer"?{...n,borderWidth:"6px",borderColor:"#36454F",color:"#36454F"}:n}return jh(e)},Oq=(e,t,n)=>{const r={x:0,y:0},o=[];return!e||!Object.keys(e).length||e.forEach(s=>{const l=s.split("/")[0],c=t.matches[s];o.push({id:s,position:r,type:_q(l),data:n,style:wq(l,c)})}),o},Eq=e=>{if(!e||bt(e))return[];const t=[],n=[];return Object.entries(e).forEach(([r,o])=>{o.forEach(s=>{t.push({id:`${r}-${s}`,source:r,target:s,type:"smoothstep",animated:!0}),n.push({id:`${r}-${s}-replica`,source:`${r}-replica`,target:`${s}-replica`,type:"smoothstep",animated:!0})})}),[...t,...n]},IO=(e,t,n,r)=>{const o=Oq(e,n,r),s=Eq(t),{nodes:l,edges:c}=xO(o,s);return{nodes:l,edges:c}},MO=async(e,t,n)=>{const r=[];return Object.entries(t).forEach(([s,l])=>{l.includes(e)&&s.includes("File")&&!n[s]&&r.push(s)}),r},qO=async(e,t)=>{const n=[];for(const r of e){const o=await fetch("undefined/collaboration/replica/copyFileReplica",{method:"POST",credentials:"include",body:JSON.stringify({vertex:r,certificateGuid:t,certificateType:"Public"})});n.push(o)}return Promise.all(n)},xq=e=>{const{setNode:t,certificate:n,replica:r,nodesState:o,edgesState:s,type:l,nodeLayers:c,setNodeLayers:f}=ot(),{customLabels:h,generatedLabels:a}=n,{data:u}=e,d=e.id.split("/")[0],p=h[e.id]||a[e.id],O=n.subgraphs[e.id],[g,_]=o,[y,w]=s,[E,m]=se.useState(!1),[S,C]=se.useState(!1),N=()=>C(!S),M=(I,A)=>l==="fileLayerNode"?IO(I,O.edges,r,A):sa(I,O.edges,n.restrictedAssets,l,A),j=()=>{const I=Object.keys(O.vertices),A=M(I,u);_(A.nodes),w(A.edges),f({previous:c.current,current:{nodes:A.nodes,edges:A.edges}}),t(e)};return $.jsx($.Fragment,{children:$.jsxs("div",{onMouseEnter:()=>m(!0),onMouseLeave:()=>m(!1),children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsx("div",{className:`p-2 ${E?"expand-hover":""}`,style:{width:"250px"},children:$.jsxs("div",{className:"d-flex align-items-center",onClick:j,children:[$.jsx(An,{label:d,description:p}),$.jsx("i",{className:"fas fa-expand-alt"})]})}),$.jsx(vt,{type:"source",position:Ce.Right}),$.jsx(rq,{vertexId:e.id,certificateId:n.id,type:l,isNodeHover:E,toggle:N}),$.jsx(wO,{vertexId:e.id,certificateId:n.id,refresh:u.refresh,isOpen:S,toggle:N})]})})},Sq=(e,t,n,r)=>{const o=H1([e],t[n]);r({...t,[n]:o})},kq=(e,t,n,r,o)=>{n({...t,emrData:[...t?.emrData?.slice(0,o),{...r,patientData:H1([e],r.patientData)},...t?.emrData?.slice(Number(o)+1)]})};var Bh=(e=>(e.labData="labData",e.surveyData="surveyData",e.demographicsData="demographicsData",e.emrData="emrData",e))(Bh||{});const Nq=e=>{const t=()=>e.update({...e.currMetadata,[e.dataType]:{}});return $.jsx(Ye.Button,{className:"mt-3 mb-2 float-right",onClick:t,children:`${LO[e.dataType]}: Mask All`})},Tq=({children:e})=>$.jsxs("table",{className:"table",children:[$.jsx("thead",{children:$.jsxs("tr",{children:[$.jsx("th",{scope:"col"}),$.jsx("th",{scope:"col",children:"Variable"}),$.jsx("th",{scope:"col",children:"Value"})]})}),$.jsx("tbody",{children:e})]}),zh=({type:e,metadata:t,setMetadata:n,emrEntry:r,emrIndex:o,ingestUiProps:s})=>{let l;s&&s.schemes?l=s.schemes:l=ot().certificate.schemes;const c=l[e],f=Object.entries(e!==Bh.emrData?t[e]:r.patientData),h=u=>{e===Bh.emrData?kq(u[0],t,n,r,o):Sq(u[0],t,e,n)},a=()=>f.map(u=>$.jsxs("tr",{children:[$.jsx("td",{children:$.jsx(Ye.Button,{icon:"fas fa-times",color:"link",className:"btn-sm text-danger",noText:!0,onClick:()=>h(u)},`${u}-mask-btn`)}),$.jsx("td",{children:NO(u[0],c,e)}),$.jsx("td",{children:TO(u[0],u[1],c,e)})]},u[0]));return $.jsxs($.Fragment,{children:[$.jsx(Nq,{dataType:e,currMetadata:t,update:n}),$.jsx(Tq,{children:a()})]})};zh.defaultProps={emrEntry:null,emrIndex:null};const Cq=({data:e,entry:t,setEntry:n})=>$.jsx("div",{className:"text-center mt-3",children:$.jsxs("div",{className:"dropdown",children:[$.jsxs("button",{className:"btn btn-secondary dropdown-toggle",type:"button",id:"emrDropdownBtn","data-bs-toggle":"dropdown","aria-expanded":"false",children:["Visit Day"," ",t.daysSinceFirstResearchVisit]}),$.jsx("ul",{className:"dropdown-menu","aria-labelledby":"emrDropdownBtn",children:Object.entries(e).map(([r,o])=>$.jsx("li",{children:$.jsxs("button",{type:"button",className:"dropdown-item",onClick:()=>n(r),children:["Visit Day"," ",o.daysSinceFirstResearchVisit]})},r))})]})}),Aq=({type:e,metadata:t,setMetadata:n,ingestUiProps:r})=>{const o=t[e],[s,l]=se.useState(0);return!t||bt(t)||!o||bt(o)?null:$.jsxs($.Fragment,{children:[$.jsx(Cq,{data:o,entry:o[s],setEntry:l}),$.jsx(zh,{type:e,metadata:t,setMetadata:n,emrEntry:o[s],emrIndex:s,ingestUiProps:r})]})},LO={labData:"Lab Results",surveyData:"Survey Data",emrData:"EMR Data",demographicsData:"Demographics Data"},Pq=({node:e})=>{const{certificate:t,setNode:n}=ot(),{metadata:r}=t;return AO(r,e.id)?$.jsx(Ye.Button,{id:"mask-btn",color:"link",className:"text-warning px-1 pt-0",onClick:()=>{e.data.toggleMaskModal(),n(e)},children:"MASK"},"mask-btn"):null},RO=({isOpen:e,loading:t,toggle:n,handleUpdate:r,refresh:o,ingestUiNode:s})=>{const{node:l,certificate:c}=s||ot(),{setNode:f}=ot(),{metadata:h,customLabels:a}=c,[u,d]=se.useState({}),[p,O]=se.useState("");se.useEffect(()=>{bt(h)||bt(l)||d(h[l.id])},[l,h]);const g=u?Object.keys(u):[],_=()=>{n(),f({}),O("")},y=()=>{const w={...c,metadata:{...h,[l.id]:u},customLabels:a};r(w).then(E=>{if(E.status===200){const{labelsId:m,metadataId:S}=E.data;n(),o(m,S),O("")}else O(E.data.Message)})};return $.jsx(Ye.ConfirmationModal,{id:"mask-metadata-modal",scrollable:!0,isOpen:e,onClose:n,headerContent:"Mask Node Metadata",noSubmit:!0,noCancel:!0,content:$.jsxs($.Fragment,{children:[p&&!t&&$.jsx(Ye.MessageStripe,{message:p,color:"danger",dismissible:!1}),$.jsx(Ye.HISETabs,{activeTab:g[0],tabs:g.map(w=>{const E=w,m=dn(u[E])||bt(u[E]);return{key:w,label:LO[w]||w,hideTab:m,content:w==="emrData"?$.jsx(Aq,{type:E,metadata:u,setMetadata:d,ingestUiProps:{schemes:s?.certificate.schemes}}):$.jsx(zh,{type:E,metadata:u,setMetadata:d,ingestUiProps:{schemes:s?.certificate.schemes}})}})})]}),customFooter:$.jsxs("div",{className:"float-right",children:[t&&$.jsx("div",{className:"spinner-grow spinner-grow-sm text-warning",role:"status"}),$.jsx(Ye.Button,{id:"cancel-btn",icon:"fas fa-times",noText:!0,className:"mx-2",onClick:_}),$.jsx(Ye.Button,{id:"ok-btn",icon:"fas fa-check",color:"primary",onClick:y,children:"Update Metadata"})]})})},Iq=(e,t)=>{if(!t)return null;switch(e){case"Cohort":case"IDE":case"IngestReceipt":case"Subject":case"Trace":return[{type:"text",key:"Description",label:"Description",invalid:n=>!n||n.length>50}];case"Sample":return Object.keys(t).map(n=>["Experiment Comments","Experiment Count","Type","Draw Date"].includes(n)?null:{type:"text",key:n,label:n,invalid:r=>!r||r.length>50});case"Specimen":return[{type:"text",key:"Specimen Type",label:"Specimen Type",invalid:n=>!n||n.length>50}];case"Process":return[{type:"text",key:"Type",label:"Description",invalid:n=>!n||n.length>50}];case"File":case"FileSet":case"Pipeline":case"Submission":case"Visualization":default:return Object.keys(t).map(n=>({type:"text",key:n,label:n,invalid:r=>!r||r.length>50}))}},Mq=({node:e})=>{const{setNode:t}=ot();return $.jsx(Ye.Button,{id:"edit-btn",color:"link",className:"text-info px-1 pt-0 ml-2",onClick:()=>{e.data.toggleEditModal(),t(e)},children:"EDIT"},"edit-btn")},DO=({isOpen:e,loading:t,toggle:n,handleUpdate:r,refresh:o,ingestUiNode:s})=>{const{node:l,certificate:c}=s||ot(),{customLabels:f,generatedLabels:h,metadata:a}=c,[u,d]=se.useState(""),[p,O]=se.useState({}),g=()=>O({});if(se.useEffect(()=>{if(!l?.id)return;const m=f[l.id]||h[l.id];m&&O(m)},[l.id]),!l?.id)return null;const _=l?.id.split("/")[0],y=m=>O(m),w=()=>{const m={...c,metadata:a,customLabels:{...f,[l.id]:p}};r(m).then(S=>{if(S.status===200){const{labelsId:C,metadataId:N}=S.data;n(),g(),o(C,N),d("")}else d(S.data.Message)})},E=()=>{n(),g(),d("")};return $.jsx(Ye.ConfirmationModal,{scrollable:!0,isOpen:e,onClose:n,headerContent:"Edit Node Label",noSubmit:!0,noCancel:!0,content:$.jsxs($.Fragment,{children:[u&&!t&&$.jsx(Ye.MessageStripe,{message:u,color:"danger",dismissible:!1}),$.jsx(Ye.ResourceEditor,{className:"",onChange:y,editedResource:p,controls:Iq(_,p)})]}),customFooter:$.jsxs("div",{className:"float-right",children:[t&&$.jsx("div",{className:"spinner-grow spinner-grow-sm text-warning",role:"status"}),$.jsx(Ye.Button,{id:"cancel-btn",icon:"fas fa-times",className:"mx-2",noText:!0,onClick:E}),$.jsx(Ye.Button,{id:"ok-btn",icon:"fas fa-check",noText:!0,color:"primary",onClick:w})]})})},qq=e=>{const{customLabels:t,generatedLabels:n,isExecutable:r}=ot().certificate,{id:o}=e,[s,l]=o.split("/"),c=t[o]||n[o],f=kO(s,l,r);return $.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2",style:{width:"250px"},children:[$.jsxs("div",{className:"label",children:[$.jsx(An,{link:f,label:s,description:c}),$.jsx(Mq,{node:e}),$.jsx(Pq,{node:e})]}),$.jsx(zn,{label:s,description:c})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},Lq=({node:e})=>{const{setNode:t}=ot(),{toggleReviewModal:n}=e.data,r=e.id.split("/")[0];return["File","IDE"].includes(r)?$.jsx(Ye.Button,{id:"review-node-btn",color:"link",className:"text-info px-1 pt-0 ml-2",icon:"fa-edit",noText:!0,onClick:()=>{n(),t(e)}},"review-node-btn"):null},Rq=e=>{const{certificate:t}=ot(),{id:n}=e,[r,o]=n.split("/"),s=t.customLabels[n]||t.generatedLabels[n],l=kO(r,o,t.isExecutable);return $.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2",style:{width:"250px"},children:[$.jsxs("div",{className:"d-flex align-items-center",children:[$.jsx(An,{link:l,label:r,description:s}),$.jsx(Lq,{node:e}),$.jsx(PO,{label:r,node:e})]}),$.jsx(zn,{label:r,description:s})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},$h=e=>{const{certificate:t,replica:n}=ot(),{customLabels:r,generatedLabels:o}=t,[s,l]=se.useState(!1),c=e.id.split("/")[0],f=r[e.id]||o[e.id],h=n.matches[e.id];return $.jsxs($.Fragment,{children:[e.modal,$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:`p-2 text-center ${s&&!h?"action-hover":""}`,style:{width:"250px"},onMouseEnter:()=>l(!0),onMouseLeave:()=>l(!1),onClick:()=>h?{}:e.toggle(),children:[$.jsx(An,{label:c,description:f}),$.jsx(zn,{label:c,description:f})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},Dq=e=>{const{isOpen:t,toggle:n,restrictedAsset:r}=e;if(!r)return null;const o=()=>{const s={restrictionInstructions:"Instructions for Retrieval",restrictionNotes:"Restriction Notes"};return $.jsxs($.Fragment,{children:[$.jsx("h6",{children:s.restrictionNotes}),$.jsx("p",{children:r.restrictionNotes}),$.jsx("h6",{children:s.restrictionInstructions}),$.jsx("div",{dangerouslySetInnerHTML:{__html:r.restrictionInstructions}})]})};return $.jsx(Ye.ConfirmationModal,{id:"restricted-node-notes-modal",isOpen:t,onClose:n,headerContent:"This asset has been restricted.",cancelButtonText:"Close",noSubmit:!0,content:$.jsx(o,{})})},jO=e=>{const{restrictedAsset:t}=e,{certificate:n}=ot(),{customLabels:r,generatedLabels:o}=n,[s,l]=se.useState(!1),c=()=>l(!s),f=e.id.split("/")[0],h=r[e.id]||o[e.id];return $.jsxs($.Fragment,{children:[$.jsx(Dq,{restrictedAsset:t,isOpen:s,toggle:c}),$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{style:{width:"250px"},onClick:c,children:[$.jsxs("div",{className:"label d-flex p-1",children:[$.jsx(An,{label:f,description:h}),$.jsx(Ye.Button,{id:`${e.id}-restricted-btn`,className:"btn-sm text-warning btn-link",icon:"fas fa-lock",noText:!0,onClick:c})]}),$.jsx(zn,{label:f,description:h})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},jq=e=>{const{certificate:t}=ot(),[n,r]=se.useState(!1),[o,s]=se.useState(!1),l=()=>s(!o),c=t.restrictedAssets&&t.restrictedAssets[e.id];if(c)return $.jsx(jO,{...e,restrictedAsset:c});const f=async()=>{r(!0);try{await _O(e.id,t.id).then(async h=>{if(h.ok)e.data.refresh(),Ke.success("Copied file into workspace.");else{const a=await h.json();Ke.error("Unable to copy file: "+a.Message)}l()})}catch(h){console.log(h)}r(!1)};return $.jsx($h,{id:e.id,data:e.data,modal:$.jsx(Ye.ConfirmationModal,{id:"copy-file-modal",pending:n,isOpen:o,onClose:l,headerContent:"Copy this file?",cancelButtonText:"Close",onSubmit:()=>f()}),toggle:l})};var Mo=(e=>(e.Completed="Completed",e.Failure="Failure",e.Running="Running",e.Processing="Processing",e.Initiated="Initiated",e))(Mo||{});const Fq={Completed:"bg-success",Failure:"bg-danger text-white",Running:"bg-info text-white",Processing:"bg-info text-white",Initiated:"bg-info text-white"},Bq=({pipeline:e,replicaPipelineOperation:t,refresh:n})=>{const[r,o]=se.useState(!1),s=()=>o(!r);return dn(e)||bt(e)||e.status!==Mo.Failure&&t.operationStatus!=="Errored"?null:$.jsxs($.Fragment,{children:[$.jsx(Ye.Button,{id:`retry-${e.id}-pipeline-btn`,color:"link",onClick:()=>{s()},children:"RETRY?"}),$.jsx(Ye.ConfirmationModal,{id:`retry-${e.id}-pipeline-modal`,isOpen:r,onClose:s,headerContent:"Do you want to retry running this pipeline?",content:"Seems that the process ran into an error.",submitButtonText:"Retry",onSubmit:async()=>{fetch(`undefined/tracer/admin/pipeline/process/retry/${e.mainProcessID}`,{method:"POST",credentials:"include"}).then(async l=>{if(l.ok)Ke.success("Successfully reinitiated pipeline run."),setTimeout(()=>n(),1500);else{const c=await l.json();Ke.error("Unable to reinitiate pipeline run: "+c.Message)}}),s()}})]})},zq=({pipeline:e,refresh:t})=>{const{certificate:n}=ot(),[r,o]=se.useState(!1),s=()=>o(!r);return dn(e)||bt(e)||[Mo.Failure,Mo.Completed].includes(e.status)?null:$.jsxs($.Fragment,{children:[$.jsx(Ye.Button,{id:`stop-${e.id}-pipeline-btn`,color:"link",onClick:s,children:"STOP?"}),$.jsx(Ye.ConfirmationModal,{id:`stop-${e.id}-pipeline-modal`,isOpen:r,onClose:s,headerContent:"Do you want to stop running this pipeline?",submitButtonText:"Stop Pipeline",onSubmit:async()=>{fetch(`undefined/collaboration/replica/stopPipelineReplica?projectGuid=${e.projectGuid}&overrideActiveRun=true`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e.id,certificateGuid:n.id,certificateType:"Public"})}).then(async l=>{if(l.ok)t(),Ke.success("Successfully stopped this pipeline run.");else{const c=await l.json();Ke.error("Unable to stop pipeline run: "+c.Message)}}),s()}})]})},$q=({status:e,replicaPipelineOperation:t,pipelineId:n})=>{const r=()=>{n&&window.open(`#/data-mgt/pipeline-dashboard/${n}`,"_blank")},o=t?.operationStatus=="Errored"?Mo.Failure:e;return $.jsxs("section",{children:[$.jsxs("span",{className:`badge rounded-pill ${Fq[o]}`,style:{fontSize:"1.25rem"},onClick:r,children:[o," ",$.jsx("i",{className:"fa-solid fa-plus"})]}),t?.operationStatus=="Errored"&&t?.failureMessage&&$.jsx("p",{className:"mt-3",children:$.jsx("small",{children:t.failureMessage})})]})},FO=({pipeline:e,replicaPipelineOperation:t,refresh:n})=>dn(e)||bt(e)?null:$.jsxs("div",{className:"text-center",children:[$.jsx($q,{status:e.status,replicaPipelineOperation:t,pipelineId:e.id}),$.jsx(Bq,{pipeline:e,replicaPipelineOperation:t,refresh:n}),$.jsx(zq,{pipeline:e,refresh:n})]}),Hq=e=>{const{replica:t,certificate:n}=ot(),{customLabels:r,generatedLabels:o}=n,{refresh:s}=e.data,[l,c]=se.useState(null),f=e.id.split("/")[0],h=r[e.id]||o[e.id],a=e.id.replace("-replica",""),u=t?.matches[a],d=t.replicaOperations[u];return se.useEffect(()=>{u&&(async()=>{const O=u.replace("Pipeline/","");await fetch(`undefined/ledger/pipeline/${O}`,{method:"GET",credentials:"include"}).then(async g=>{if(g.ok){const _=await g.json();c(_)}})})()},[t,e.id]),$.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2",style:{width:"250px"},children:[$.jsx(An,{label:f,description:h}),$.jsx(zn,{label:f,description:h}),$.jsx(FO,{pipeline:l,replicaPipelineOperation:d,refresh:s})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},BO=({loading:e,isOpen:t,toggle:n,onStartPipeline:r})=>$.jsx(Ye.ConfirmationModal,{id:"run-pipeline-modal",scrollable:!0,pending:e,isOpen:t,onClose:n,headerContent:"Run this pipeline?",content:"Running this pipeline will also copy any input files that haven't been pulled into your workspace yet.",cancelButtonText:"Close",onSubmit:()=>r()}),Vq=async(e,t)=>await fetch("undefined/collaboration/replica/runPipelineReplica",{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:t,certificateType:"Public"})}),zO=async(e,t,n,r,o,s)=>{const l=await MO(e,n,r);await qO(l,t).then(async f=>f.length?f.every(h=>h.ok):!0)?await Vq(e,t).then(async f=>{if(f.ok)Ke.success("Started pipeline.");else{const h=await f.json();Ke.error("Unable to start pipeline: "+h.Message)}o(),s()}):(o(),Ke.error("Unable to copy some of the necessary input files."))},Uq=e=>{const{certificate:t,replica:n}=ot(),[r,o]=se.useState(!1),[s,l]=se.useState(!1),c=()=>l(!s);if(n.matches[e.id])return $.jsx(Hq,{...e});const h=async()=>{o(!0);try{await zO(e.id,t.id,t.edges,n.matches,e.data.refresh,c)}catch(a){console.log(a)}o(!1)};return $.jsx($h,{id:e.id,data:e.data,modal:$.jsx(BO,{loading:r,isOpen:s,toggle:c,onStartPipeline:h}),toggle:c})},Gq=e=>{const{replica:t,certificate:n}=ot(),{customLabels:r,generatedLabels:o}=n,s=e.id.split("/")[0],l=r[e.id]||o[e.id],c=e.id.replace("-replica",""),f=t?.matches[c],h=()=>{f&&window.open("#/ide-nextgen","_blank")};return $.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2",style:{width:"250px"},onClick:()=>h(),children:[$.jsx(An,{label:s,description:l}),$.jsx(zn,{label:s,description:l}),$.jsx("section",{className:"text-center mt-2",children:$.jsxs("span",{className:"badge bg-primary text-white",children:["IDE LIST ",$.jsx("i",{className:"fas fa-external-link-alt"})]})})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})},$O=({loading:e,isOpen:t,toggle:n,onStartIDE:r})=>$.jsx(Ye.ConfirmationModal,{id:"clone-ide-modal",className:"top-25",pending:e,isOpen:t,onClose:n,headerContent:"Do you want to clone the environment of the original IDE into your workspace?",cancelButtonText:"Close",onSubmit:()=>r()}),Kq=async(e,t)=>await fetch("undefined/collaboration/replica/cloneIdeReplica",{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:t,certificateType:"Public"})}),HO=async(e,t,n,r,o,s)=>{const l=await MO(e,n,r);await qO(l,t).then(async f=>f.length?f.every(h=>h.ok):!0)?await Kq(e,t).then(async f=>{if(f.ok)Ke.success("Started IDE.");else{const h=await f.json();Ke.error("Unable to start IDE: "+h.Message)}o(),s()}):(o(),Ke.error("Unable to copy some of the necessary input files."))},Wq=e=>{const{certificate:t,replica:n}=ot(),[r,o]=se.useState(!1),[s,l]=se.useState(!1),c=()=>l(!s),f=t.restrictedAssets&&t.restrictedAssets[e.id];if(f)return $.jsx(jO,{...e,restrictedAsset:f});if(n.matches[e.id])return $.jsx(Gq,{...e});const a=async()=>{o(!0);try{await HO(e.id,t.id,t.edges,n.matches,e.data.refresh,c)}catch(u){console.log(u)}o(!1)};return $.jsx($h,{id:e.id,data:e.data,modal:$.jsx($O,{loading:r,isOpen:s,toggle:c,onStartIDE:a}),toggle:c})},Hh=250,Vh=120,VO=(e,t,n="LR")=>{const r=new uo.graphlib.Graph;return r.setDefaultEdgeLabel(()=>({})),r.setGraph({nodesep:70,ranksep:110,rankdir:n}),e.forEach(o=>{r.setNode(o.id,{width:Hh,height:Vh})}),t.forEach(o=>{r.setEdge(o.source,o.target)}),uo.layout(r),e.forEach(o=>{const s=r.node(o.id);return o.targetPosition=n==="LR"?Ce.Right:Ce.Left,o.sourcePosition=n==="LR"?Ce.Left:Ce.Right,o.position={x:s.x-Hh/2,y:s.y-Vh/2},o}),{nodes:e,edges:t}},UO=(e,t,n,r=!0)=>{let o=[...e];return t.forEach(s=>{const l=e.find(f=>f.id===s),c=s.includes("Layer")?!n.subgraphs[s]:!1;if(!l)if(r&&c)o=o;else{const[f]=s.split("/"),h=n.customLabels?.[s]||n.generatedLabels?.[s],a={id:s,position:{x:0,y:0},type:"walkingNode",data:{description:h},style:jh(f)};o=[...o,a]}}),o},GO=(e,t)=>{let n=[...e];return Object.entries(t||{}).forEach(o=>{const[s,l]=o;l.map(c=>{if(!e.find(h=>h.id.match(s)&&h.id.match(c))){const h={id:`${s}-${c}`,source:s,target:c,animated:!0};n=[...n,h]}})}),n},Yq=e=>{if(!e)return"";const[t,n]=e.split("/");switch(t){case"FileSet":return`/#/collaboration/filesets/${n}`;case"File":return`/#/files/${n}`;case"Visualization":return`/#/collaboration/visualizations/${n}`;case"IDE":return`/#/collaboration/ide/${n}`;case"IngestReceipt":return`/#/ingest-receipts/${n}`;case"Process":return`/#/processes/${n}`;case"Pipeline":return`/#/data-mgt/pipeline-dashboard/${n}`;case"Subject":return`/#/subjects/${n}`;case"Sample":return`/#/samples/${n}`;case"Cohort":return`/#/cohorts/${n}`;default:return""}},KO=({id:e})=>{const t=Ji(),{node:n,setNode:r,nodesState:o,edgesState:s,certificate:l,setNodeLayers:c}=ot(),[f,h]=se.useState({label:"",description:"",isLayer:!1}),[a,u]=se.useState(!1),[d,p]=o,[O,g]=s,_=t.getNode(e);se.useEffect(()=>{const I=R=>{const k=R.match(/^(.*)Layer/);if(!k)return R;switch(k[1]){case"File":case"FileSet":case"IDE":case"Sample":case"Specimen":case"Visualization":return`${k[1]}s`;case"Process":return`${k[1]}es`;default:return"Items"}},A={description:_?.data?.description},q=e.split("/")[0];if(q.includes("Layer")){const R=Object.keys(l.subgraphs[e].vertices).length,k=I(q);h({...A,label:`${k} (${R})`,isLayer:!0})}else h({...A,label:q,isLayer:!1})},[_]);const y=async I=>{const A=I==="right"?`undefined/collaboration/neighbors?root=${e}&getDescendants=true`:`undefined/collaboration/neighbors?root=${e}&getAncestors=true`;await fetch(A,{method:"GET",credentials:"include"}).then(async q=>{if(q.ok){const R=await q.json(),{vertices:k,edges:F,customLabels:U,generatedLabels:ne}=R,ue=UO(d,k,{...l,customLabels:U,generatedLabels:ne},!0),K=GO(O,F),W=VO(ue,K);p(W.nodes),g(W.edges),c({previous:{nodes:[],edges:[]},current:{nodes:W.nodes,edges:W.edges}})}})},w=async()=>{setTimeout(()=>{const I=t.getViewport();_&&t.setCenter(_.position.x,_.position.y,{zoom:I.zoom,duration:1e3})},1e3)},E=async I=>{I.preventDefault(),await y("left"),await w()},m=async I=>{I.preventDefault(),await y("right"),await w()},S=()=>{_&&r(_)},C=()=>u(!0),N=()=>u(!1),M=()=>f.isLayer?null:$.jsxs($.Fragment,{children:[$.jsx("a",{type:"button",target:"_blank",onClick:E,className:`${a?"visible":"invisible"} btn btn-light`,children:"BACK"}),$.jsx("a",{type:"button",target:"_blank",onClick:m,className:`${a?"visible":"invisible"} btn btn-light`,children:"NEXT"})]}),j=()=>a?"10px solid rgba(0, 0, 0, .1)":_?.id===n.id?"10px solid #1976D2":"";return $.jsxs($.Fragment,{children:[$.jsx(vt,{type:"target",position:Ce.Left}),$.jsxs("div",{className:"p-2 d-flex align-items-center justify-content-center flex-wrap",style:{width:`${Hh}px`,minHeight:`${Vh}px`,border:j()},onMouseEnter:C,onMouseLeave:N,children:[$.jsxs("div",{className:"w-100",onClick:S,children:[$.jsx(An,{label:f.label,description:f.description}),$.jsx(zn,{label:f.label,description:f.description})]}),$.jsx("div",{className:"position-absolute node-description w-100 d-flex justify-content-between align-self-end px-2",children:M()})]}),$.jsx(vt,{type:"source",position:Ce.Right})]})};new uo.graphlib.Graph().setDefaultEdgeLabel(()=>({}));const Zq=({certificate:e,graph:t,children:n})=>{const{nodesState:r,edgesState:o,nodeLayers:s,setNodeLayers:l}=ot(),c=se.useMemo(()=>({readNode:la,fileLayerNode:xq,fileNode:la,pipelineNode:la,IDENode:la,walkingNode:KO,editNode:qq,reviewNode:Rq,workspaceFileNode:jq,workspacePipelineNode:Uq,workspaceIDENode:Wq}),[]),[,f,h]=r,[,a,u]=o;return se.useEffect(()=>{dn(e)||bt(e)||(f(t.nodes),a(t.edges),l({previous:s.previous,current:{nodes:t.nodes,edges:t.edges}}))},[e]),$.jsxs("div",{className:"layoutflow",children:[$.jsx(iq,{}),n,$.jsxs(Ph,{nodes:s.current.nodes,edges:s.current.edges,onNodesChange:h,onEdgesChange:u,connectionLineType:vn.SmoothStep,nodeTypes:c,onlyRenderVisibleElements:!0,edgesUpdatable:!1,defaultViewport:{x:0,y:0,zoom:.6},children:[$.jsx(lO,{}),$.jsx(cO,{}),$.jsx(aO,{})]})]})},ua=({type:e,certificate:t,replica:n,graph:r,children:o})=>$.jsxs(mO,{type:e,certificate:t,replica:n,children:[$.jsx("div",{style:{height:"75vh"},children:$.jsx(Zq,{certificate:t,graph:r,children:o})}),$.jsx(Lh,{position:"bottom-right",autoClose:5e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,theme:"light"})]}),Xq=({certificate:e})=>{const[t,n]=se.useState(!1),r=()=>n(!t),o="readNode",s={toggleMetadataModal:r},l=sa(e.vertices,e.edges,e.restrictedAssets,o,s);return $.jsx(ua,{type:o,certificate:e,graph:l,children:$.jsx(Fh,{isOpen:t,toggle:r})})},Qq=({certificate:e,loading:t,handleUpdate:n,refresh:r})=>{const[o,s]=se.useState(!1),l=()=>s(!o),[c,f]=se.useState(!1),h=()=>f(!c),a="editNode",u={toggleEditModal:l,toggleMaskModal:h},d=sa(e.vertices,e.edges,e.restrictedAssets,a,u);return $.jsxs(ua,{type:a,certificate:e,graph:d,children:[$.jsx(DO,{isOpen:o,loading:t,toggle:l,handleUpdate:n,refresh:r}),$.jsx(RO,{isOpen:c,loading:t,toggle:h,handleUpdate:n,refresh:r})]})};var Uh,WO;function Jq(){if(WO)return Uh;WO=1;var e=Ru();function t(n,r){return e(n,r)}return Uh=t,Uh}var ca={exports:{}};/*!
|
|
133
|
+
`],Wv||(Wv=Uv.slice(0)),UA=Object.freeze(Object.defineProperties(Uv,{raw:{value:Object.freeze(Wv)}})))),Kv=function(t){var a=t.delay,u=t.offset;return nt("span",{css:Ua({animation:"".concat(h8," 1s ease-in-out ").concat(a,"ms infinite;"),backgroundColor:"currentColor",borderRadius:"1em",display:"inline-block",marginLeft:u?"1em":void 0,height:"1em",verticalAlign:"top",width:"1em"},"","")})},p8=["data"],m8=["innerRef","isDisabled","isHidden","inputClassName"],QA={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},g8={flex:"1 1 auto",display:"inline-grid",gridArea:"1 / 1 / 2 / 3",gridTemplateColumns:"0 min-content","&:after":tt({content:'attr(data-value) " "',visibility:"hidden",whiteSpace:"pre"},QA)},v8=function(t){return tt({label:"input",color:"inherit",background:0,opacity:t?0:1,width:"100%"},QA)},JA=function(t){var a=t.children,u=t.innerProps;return nt("div",u,a)},$A={ClearIndicator:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Ut(t,"clearIndicator",{indicator:!0,"clear-indicator":!0}),u),a||nt(Gv,null))},Control:function(t){var a=t.children,u=t.isDisabled,v=t.isFocused,O=t.innerRef,A=t.innerProps,I=t.menuIsOpen;return nt("div",et({ref:O},Ut(t,"control",{control:!0,"control--is-disabled":u,"control--is-focused":v,"control--menu-is-open":I}),A,{"aria-disabled":u||void 0}),a)},DropdownIndicator:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Ut(t,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),u),a||nt(XA,null))},DownChevron:XA,CrossIcon:Gv,Group:function(t){var a=t.children,u=t.cx,v=t.getStyles,O=t.getClassNames,A=t.Heading,I=t.headingProps,N=t.innerProps,T=t.label,C=t.theme,X=t.selectProps;return nt("div",et({},Ut(t,"group",{group:!0}),N),nt(A,et({},I,{selectProps:X,theme:C,getStyles:v,getClassNames:O,cx:u}),T),nt("div",null,a))},GroupHeading:function(t){var a=FA(t);a.data;var u=wr(a,p8);return nt("div",et({},Ut(t,"groupHeading",{"group-heading":!0}),u))},IndicatorsContainer:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Ut(t,"indicatorsContainer",{indicators:!0}),u),a)},IndicatorSeparator:function(t){var a=t.innerProps;return nt("span",et({},a,Ut(t,"indicatorSeparator",{"indicator-separator":!0})))},Input:function(t){var a=t.cx,u=t.value,v=FA(t),O=v.innerRef,A=v.isDisabled,I=v.isHidden,N=v.inputClassName,T=wr(v,m8);return nt("div",et({},Ut(t,"input",{"input-container":!0}),{"data-value":u||""}),nt("input",et({className:a({input:!0},N),ref:O,style:v8(I),disabled:A},T)))},LoadingIndicator:function(t){var a=t.innerProps,u=t.isRtl,v=t.size,O=v===void 0?4:v,A=wr(t,u8);return nt("div",et({},Ut(tt(tt({},A),{},{innerProps:a,isRtl:u,size:O}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),a),nt(Kv,{delay:0,offset:u}),nt(Kv,{delay:160,offset:!0}),nt(Kv,{delay:320,offset:!u}))},Menu:function(t){var a=t.children,u=t.innerRef,v=t.innerProps;return nt("div",et({},Ut(t,"menu",{menu:!0}),{ref:u},v),a)},MenuList:function(t){var a=t.children,u=t.innerProps,v=t.innerRef,O=t.isMulti;return nt("div",et({},Ut(t,"menuList",{"menu-list":!0,"menu-list--is-multi":O}),{ref:v},u),a)},MenuPortal:function(t){var a=t.appendTo,u=t.children,v=t.controlElement,O=t.innerProps,A=t.menuPlacement,I=t.menuPosition,N=(0,s.useRef)(null),T=(0,s.useRef)(null),C=zr((0,s.useState)(WA(A)),2),X=C[0],V=C[1],$=(0,s.useMemo)((function(){return{setPortalPlacement:V}}),[]),q=zr((0,s.useState)(null),2),H=q[0],G=q[1],Q=(0,s.useCallback)((function(){if(v){var me=(function(ce){var Oe=ce.getBoundingClientRect();return{bottom:Oe.bottom,height:Oe.height,left:Oe.left,right:Oe.right,top:Oe.top,width:Oe.width}})(v),ve=I==="fixed"?0:window.pageYOffset,ye=me[X]+ve;ye===H?.offset&&me.left===H?.rect.left&&me.width===H?.rect.width||G({offset:ye,rect:me})}}),[v,I,X,H?.offset,H?.rect.left,H?.rect.width]);Vv((function(){Q()}),[Q]);var ie=(0,s.useCallback)((function(){typeof T.current=="function"&&(T.current(),T.current=null),v&&N.current&&(T.current=(function(me,ve,ye,ce){ce===void 0&&(ce={});const{ancestorScroll:Oe=!0,ancestorResize:Me=!0,elementResize:_e=typeof ResizeObserver=="function",layoutShift:je=typeof IntersectionObserver=="function",animationFrame:Ne=!1}=ce,Te=Hv(me),ze=Oe||Me?[...Te?zv(Te):[],...zv(ve)]:[];ze.forEach((lt=>{Oe&<.addEventListener("scroll",ye,{passive:!0}),Me&<.addEventListener("resize",ye)}));const Le=Te&&je?(function(lt,gt){let Xe,le=null;const qe=PA(lt);function Ie(){clearTimeout(Xe),le&&le.disconnect(),le=null}return(function Ye(it,at){it===void 0&&(it=!1),at===void 0&&(at=1),Ie();const{left:bt,top:kt,width:Zt,height:Qt}=lt.getBoundingClientRect();if(it||gt(),!Zt||!Qt)return;const rn={rootMargin:-cu(kt)+"px "+-cu(qe.clientWidth-(bt+Zt))+"px "+-cu(qe.clientHeight-(kt+Qt))+"px "+-cu(bt)+"px",threshold:XF(0,YF(1,at))||1};let En=!0;function on(St){const Gt=St[0].intersectionRatio;if(Gt!==at){if(!En)return Ye();Gt?Ye(!1,Gt):Xe=setTimeout((()=>{Ye(!1,1e-7)}),100)}En=!1}try{le=new IntersectionObserver(on,{...rn,root:qe.ownerDocument})}catch{le=new IntersectionObserver(on,rn)}le.observe(lt)})(!0),Ie})(Te,ye):null;let ke,Ke=-1,$e=null;_e&&($e=new ResizeObserver((lt=>{let[gt]=lt;gt&>.target===Te&&$e&&($e.unobserve(ve),cancelAnimationFrame(Ke),Ke=requestAnimationFrame((()=>{$e&&$e.observe(ve)}))),ye()})),Te&&!Ne&&$e.observe(Te),$e.observe(ve));let dt=Ne?BA(me):null;return Ne&&(function lt(){const gt=BA(me);!dt||gt.x===dt.x&>.y===dt.y&>.width===dt.width&>.height===dt.height||ye(),dt=gt,ke=requestAnimationFrame(lt)})(),ye(),()=>{ze.forEach((lt=>{Oe&<.removeEventListener("scroll",ye),Me&<.removeEventListener("resize",ye)})),Le&&Le(),$e&&$e.disconnect(),$e=null,Ne&&cancelAnimationFrame(ke)}})(v,N.current,Q,{elementResize:"ResizeObserver"in window}))}),[v,Q]);Vv((function(){ie()}),[ie]);var ue=(0,s.useCallback)((function(me){N.current=me,ie()}),[ie]);if(!a&&I!=="fixed"||!H)return null;var fe=nt("div",et({ref:ue},Ut(tt(tt({},t),{},{offset:H.offset,position:I,rect:H.rect}),"menuPortal",{"menu-portal":!0}),O),u);return nt(GA.Provider,{value:$},a?(0,hl.createPortal)(fe,a):fe)},LoadingMessage:function(t){var a=t.children,u=a===void 0?"Loading...":a,v=t.innerProps,O=wr(t,o8);return nt("div",et({},Ut(tt(tt({},O),{},{children:u,innerProps:v}),"loadingMessage",{"menu-notice":!0,"menu-notice--loading":!0}),v),u)},NoOptionsMessage:function(t){var a=t.children,u=a===void 0?"No options":a,v=t.innerProps,O=wr(t,r8);return nt("div",et({},Ut(tt(tt({},O),{},{children:u,innerProps:v}),"noOptionsMessage",{"menu-notice":!0,"menu-notice--no-options":!0}),v),u)},MultiValue:function(t){var a=t.children,u=t.components,v=t.data,O=t.innerProps,A=t.isDisabled,I=t.removeProps,N=t.selectProps,T=u.Container,C=u.Label,X=u.Remove;return nt(T,{data:v,innerProps:tt(tt({},Ut(t,"multiValue",{"multi-value":!0,"multi-value--is-disabled":A})),O),selectProps:N},nt(C,{data:v,innerProps:tt({},Ut(t,"multiValueLabel",{"multi-value__label":!0})),selectProps:N},a),nt(X,{data:v,innerProps:tt(tt({},Ut(t,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(a||"option")},I),selectProps:N}))},MultiValueContainer:JA,MultiValueLabel:JA,MultiValueRemove:function(t){var a=t.children,u=t.innerProps;return nt("div",et({role:"button"},u),a||nt(Gv,{size:14}))},Option:function(t){var a=t.children,u=t.isDisabled,v=t.isFocused,O=t.isSelected,A=t.innerRef,I=t.innerProps;return nt("div",et({},Ut(t,"option",{option:!0,"option--is-disabled":u,"option--is-focused":v,"option--is-selected":O}),{ref:A,"aria-disabled":u},I),a)},Placeholder:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Ut(t,"placeholder",{placeholder:!0}),u),a)},SelectContainer:function(t){var a=t.children,u=t.innerProps,v=t.isDisabled,O=t.isRtl;return nt("div",et({},Ut(t,"container",{"--is-disabled":v,"--is-rtl":O}),u),a)},SingleValue:function(t){var a=t.children,u=t.isDisabled,v=t.innerProps;return nt("div",et({},Ut(t,"singleValue",{"single-value":!0,"single-value--is-disabled":u}),v),a)},ValueContainer:function(t){var a=t.children,u=t.innerProps,v=t.isMulti,O=t.hasValue;return nt("div",et({},Ut(t,"valueContainer",{"value-container":!0,"value-container--is-multi":v,"value-container--has-value":O}),u),a)}},eN=Number.isNaN||function(t){return typeof t=="number"&&t!=t};function y8(t,a){if(t.length!==a.length)return!1;for(var u=0;u<t.length;u++)if(!((v=t[u])===(O=a[u])||eN(v)&&eN(O)))return!1;var v,O;return!0}for(var b8={name:"7pg0cj-a11yText",styles:"label:a11yText;z-index:9999;border:0;clip:rect(1px, 1px, 1px, 1px);height:1px;width:1px;position:absolute;overflow:hidden;padding:0;white-space:nowrap"},tN=function(t){return nt("span",et({css:b8},t))},w8={guidance:function(t){var a=t.isSearchable,u=t.isMulti,v=t.tabSelectsValue,O=t.context,A=t.isInitialFocus;switch(O){case"menu":return"Use Up and Down to choose options, press Enter to select the currently focused option, press Escape to exit the menu".concat(v?", press Tab to select the option and exit the menu":"",".");case"input":return A?"".concat(t["aria-label"]||"Select"," is focused ").concat(a?",type to refine list":"",", press Down to open the menu, ").concat(u?" press left to focus selected values":""):"";case"value":return"Use left and right to toggle between focused values, press Backspace to remove the currently focused value";default:return""}},onChange:function(t){var a=t.action,u=t.label,v=u===void 0?"":u,O=t.labels,A=t.isDisabled;switch(a){case"deselect-option":case"pop-value":case"remove-value":return"option ".concat(v,", deselected.");case"clear":return"All selected options have been cleared.";case"initial-input-focus":return"option".concat(O.length>1?"s":""," ").concat(O.join(","),", selected.");case"select-option":return"option ".concat(v,A?" is disabled. Select another option.":", selected.");default:return""}},onFocus:function(t){var a=t.context,u=t.focused,v=t.options,O=t.label,A=O===void 0?"":O,I=t.selectValue,N=t.isDisabled,T=t.isSelected,C=t.isAppleDevice,X=function(q,H){return q&&q.length?"".concat(q.indexOf(H)+1," of ").concat(q.length):""};if(a==="value"&&I)return"value ".concat(A," focused, ").concat(X(I,u),".");if(a==="menu"&&C){var V=N?" disabled":"",$="".concat(T?" selected":"").concat(V);return"".concat(A).concat($,", ").concat(X(v,u),".")}return""},onFilter:function(t){var a=t.inputValue,u=t.resultsMessage;return"".concat(u).concat(a?" for search term "+a:"",".")}},x8=function(t){var a=t.ariaSelection,u=t.focusedOption,v=t.focusedValue,O=t.focusableOptions,A=t.isFocused,I=t.selectValue,N=t.selectProps,T=t.id,C=t.isAppleDevice,X=N.ariaLiveMessages,V=N.getOptionLabel,$=N.inputValue,q=N.isMulti,H=N.isOptionDisabled,G=N.isSearchable,Q=N.menuIsOpen,ie=N.options,ue=N.screenReaderStatus,fe=N.tabSelectsValue,me=N.isLoading,ve=N["aria-label"],ye=N["aria-live"],ce=(0,s.useMemo)((function(){return tt(tt({},w8),X||{})}),[X]),Oe=(0,s.useMemo)((function(){var ze,Le="";if(a&&ce.onChange){var ke=a.option,Ke=a.options,$e=a.removedValue,dt=a.removedValues,lt=a.value,gt=$e||ke||(ze=lt,Array.isArray(ze)?null:ze),Xe=gt?V(gt):"",le=Ke||dt||void 0,qe=le?le.map(V):[],Ie=tt({isDisabled:gt&&H(gt,I),label:Xe,labels:qe},a);Le=ce.onChange(Ie)}return Le}),[a,ce,H,I,V]),Me=(0,s.useMemo)((function(){var ze="",Le=u||v,ke=!!(u&&I&&I.includes(u));if(Le&&ce.onFocus){var Ke={focused:Le,label:V(Le),isDisabled:H(Le,I),isSelected:ke,options:O,context:Le===u?"menu":"value",selectValue:I,isAppleDevice:C};ze=ce.onFocus(Ke)}return ze}),[u,v,V,H,ce,O,I,C]),_e=(0,s.useMemo)((function(){var ze="";if(Q&&ie.length&&!me&&ce.onFilter){var Le=ue({count:O.length});ze=ce.onFilter({inputValue:$,resultsMessage:Le})}return ze}),[O,$,Q,ce,ie,ue,me]),je=a?.action==="initial-input-focus",Ne=(0,s.useMemo)((function(){var ze="";if(ce.guidance){var Le=v?"value":Q?"menu":"input";ze=ce.guidance({"aria-label":ve,context:Le,isDisabled:u&&H(u,I),isMulti:q,isSearchable:G,tabSelectsValue:fe,isInitialFocus:je})}return ze}),[ve,u,v,q,H,G,Q,ce,I,fe,je]),Te=nt(s.Fragment,null,nt("span",{id:"aria-selection"},Oe),nt("span",{id:"aria-focused"},Me),nt("span",{id:"aria-results"},_e),nt("span",{id:"aria-guidance"},Ne));return nt(s.Fragment,null,nt(tN,{id:T},je&&Te),nt(tN,{"aria-live":ye,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},A&&!je&&Te))},Yv=[{base:"A",letters:"AⒶAÀÁÂẦẤẪẨÃĀĂẰẮẴẲȦǠÄǞẢÅǺǍȀȂẠẬẶḀĄȺⱯ"},{base:"AA",letters:"Ꜳ"},{base:"AE",letters:"ÆǼǢ"},{base:"AO",letters:"Ꜵ"},{base:"AU",letters:"Ꜷ"},{base:"AV",letters:"ꜸꜺ"},{base:"AY",letters:"Ꜽ"},{base:"B",letters:"BⒷBḂḄḆɃƂƁ"},{base:"C",letters:"CⒸCĆĈĊČÇḈƇȻꜾ"},{base:"D",letters:"DⒹDḊĎḌḐḒḎĐƋƊƉꝹ"},{base:"DZ",letters:"DZDŽ"},{base:"Dz",letters:"DzDž"},{base:"E",letters:"EⒺEÈÉÊỀẾỄỂẼĒḔḖĔĖËẺĚȄȆẸỆȨḜĘḘḚƐƎ"},{base:"F",letters:"FⒻFḞƑꝻ"},{base:"G",letters:"GⒼGǴĜḠĞĠǦĢǤƓꞠꝽꝾ"},{base:"H",letters:"HⒽHĤḢḦȞḤḨḪĦⱧⱵꞍ"},{base:"I",letters:"IⒾIÌÍÎĨĪĬİÏḮỈǏȈȊỊĮḬƗ"},{base:"J",letters:"JⒿJĴɈ"},{base:"K",letters:"KⓀKḰǨḲĶḴƘⱩꝀꝂꝄꞢ"},{base:"L",letters:"LⓁLĿĹĽḶḸĻḼḺŁȽⱢⱠꝈꝆꞀ"},{base:"LJ",letters:"LJ"},{base:"Lj",letters:"Lj"},{base:"M",letters:"MⓂMḾṀṂⱮƜ"},{base:"N",letters:"NⓃNǸŃÑṄŇṆŅṊṈȠƝꞐꞤ"},{base:"NJ",letters:"NJ"},{base:"Nj",letters:"Nj"},{base:"O",letters:"OⓄOÒÓÔỒỐỖỔÕṌȬṎŌṐṒŎȮȰÖȪỎŐǑȌȎƠỜỚỠỞỢỌỘǪǬØǾƆƟꝊꝌ"},{base:"OI",letters:"Ƣ"},{base:"OO",letters:"Ꝏ"},{base:"OU",letters:"Ȣ"},{base:"P",letters:"PⓅPṔṖƤⱣꝐꝒꝔ"},{base:"Q",letters:"QⓆQꝖꝘɊ"},{base:"R",letters:"RⓇRŔṘŘȐȒṚṜŖṞɌⱤꝚꞦꞂ"},{base:"S",letters:"SⓈSẞŚṤŜṠŠṦṢṨȘŞⱾꞨꞄ"},{base:"T",letters:"TⓉTṪŤṬȚŢṰṮŦƬƮȾꞆ"},{base:"TZ",letters:"Ꜩ"},{base:"U",letters:"UⓊUÙÚÛŨṸŪṺŬÜǛǗǕǙỦŮŰǓȔȖƯỪỨỮỬỰỤṲŲṶṴɄ"},{base:"V",letters:"VⓋVṼṾƲꝞɅ"},{base:"VY",letters:"Ꝡ"},{base:"W",letters:"WⓌWẀẂŴẆẄẈⱲ"},{base:"X",letters:"XⓍXẊẌ"},{base:"Y",letters:"YⓎYỲÝŶỸȲẎŸỶỴƳɎỾ"},{base:"Z",letters:"ZⓏZŹẐŻŽẒẔƵȤⱿⱫꝢ"},{base:"a",letters:"aⓐaẚàáâầấẫẩãāăằắẵẳȧǡäǟảåǻǎȁȃạậặḁąⱥɐ"},{base:"aa",letters:"ꜳ"},{base:"ae",letters:"æǽǣ"},{base:"ao",letters:"ꜵ"},{base:"au",letters:"ꜷ"},{base:"av",letters:"ꜹꜻ"},{base:"ay",letters:"ꜽ"},{base:"b",letters:"bⓑbḃḅḇƀƃɓ"},{base:"c",letters:"cⓒcćĉċčçḉƈȼꜿↄ"},{base:"d",letters:"dⓓdḋďḍḑḓḏđƌɖɗꝺ"},{base:"dz",letters:"dzdž"},{base:"e",letters:"eⓔeèéêềếễểẽēḕḗĕėëẻěȅȇẹệȩḝęḙḛɇɛǝ"},{base:"f",letters:"fⓕfḟƒꝼ"},{base:"g",letters:"gⓖgǵĝḡğġǧģǥɠꞡᵹꝿ"},{base:"h",letters:"hⓗhĥḣḧȟḥḩḫẖħⱨⱶɥ"},{base:"hv",letters:"ƕ"},{base:"i",letters:"iⓘiìíîĩīĭïḯỉǐȉȋịįḭɨı"},{base:"j",letters:"jⓙjĵǰɉ"},{base:"k",letters:"kⓚkḱǩḳķḵƙⱪꝁꝃꝅꞣ"},{base:"l",letters:"lⓛlŀĺľḷḹļḽḻſłƚɫⱡꝉꞁꝇ"},{base:"lj",letters:"lj"},{base:"m",letters:"mⓜmḿṁṃɱɯ"},{base:"n",letters:"nⓝnǹńñṅňṇņṋṉƞɲʼnꞑꞥ"},{base:"nj",letters:"nj"},{base:"o",letters:"oⓞoòóôồốỗổõṍȭṏōṑṓŏȯȱöȫỏőǒȍȏơờớỡởợọộǫǭøǿɔꝋꝍɵ"},{base:"oi",letters:"ƣ"},{base:"ou",letters:"ȣ"},{base:"oo",letters:"ꝏ"},{base:"p",letters:"pⓟpṕṗƥᵽꝑꝓꝕ"},{base:"q",letters:"qⓠqɋꝗꝙ"},{base:"r",letters:"rⓡrŕṙřȑȓṛṝŗṟɍɽꝛꞧꞃ"},{base:"s",letters:"sⓢsßśṥŝṡšṧṣṩșşȿꞩꞅẛ"},{base:"t",letters:"tⓣtṫẗťṭțţṱṯŧƭʈⱦꞇ"},{base:"tz",letters:"ꜩ"},{base:"u",letters:"uⓤuùúûũṹūṻŭüǜǘǖǚủůűǔȕȗưừứữửựụṳųṷṵʉ"},{base:"v",letters:"vⓥvṽṿʋꝟʌ"},{base:"vy",letters:"ꝡ"},{base:"w",letters:"wⓦwẁẃŵẇẅẘẉⱳ"},{base:"x",letters:"xⓧxẋẍ"},{base:"y",letters:"yⓨyỳýŷỹȳẏÿỷẙỵƴɏỿ"},{base:"z",letters:"zⓩzźẑżžẓẕƶȥɀⱬꝣ"}],_8=new RegExp("["+Yv.map((function(t){return t.letters})).join("")+"]","g"),nN={},Xv=0;Xv<Yv.length;Xv++)for(var Zv=Yv[Xv],Qv=0;Qv<Zv.letters.length;Qv++)nN[Zv.letters[Qv]]=Zv.base;var rN=function(t){return t.replace(_8,(function(a){return nN[a]}))},S8=(function(t,a){a===void 0&&(a=y8);var u=null;function v(){for(var O=[],A=0;A<arguments.length;A++)O[A]=arguments[A];if(u&&u.lastThis===this&&a(O,u.lastArgs))return u.lastResult;var I=t.apply(this,O);return u={lastResult:I,lastArgs:O,lastThis:this},I}return v.clear=function(){u=null},v})(rN),oN=function(t){return t.replace(/^\s+|\s+$/g,"")},E8=function(t){return"".concat(t.label," ").concat(t.value)},O8=["innerRef"];function k8(t){var a=t.innerRef,u=(function(v){for(var O=arguments.length,A=new Array(O>1?O-1:0),I=1;I<O;I++)A[I-1]=arguments[I];var N=Object.entries(v).filter((function(T){var C=zr(T,1)[0];return!A.includes(C)}));return N.reduce((function(T,C){var X=zr(C,2),V=X[0],$=X[1];return T[V]=$,T}),{})})(wr(t,O8),"onExited","in","enter","exit","appear");return nt("input",et({ref:a},u,{css:Ua({label:"dummyInput",background:0,border:0,caretColor:"transparent",fontSize:"inherit",gridArea:"1 / 1 / 2 / 3",outline:0,padding:0,width:1,color:"transparent",left:-100,opacity:0,position:"relative",transform:"scale(.01)"},"","")}))}var iN=["boxSizing","height","overflow","paddingRight","position"],aN={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function sN(t){t.cancelable&&t.preventDefault()}function lN(t){t.stopPropagation()}function uN(){var t=this.scrollTop,a=this.scrollHeight,u=t+this.offsetHeight;t===0?this.scrollTop=1:u===a&&(this.scrollTop=t-1)}function cN(){return"ontouchstart"in window||navigator.maxTouchPoints}var fN=!(typeof window>"u"||!window.document||!window.document.createElement),Xa=0,Ci={capture:!1,passive:!1},C8=function(t){var a=t.target;return a.ownerDocument.activeElement&&a.ownerDocument.activeElement.blur()},A8={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function N8(t){var a=t.children,u=t.lockEnabled,v=t.captureEnabled,O=(function(I){var N=I.isEnabled,T=I.onBottomArrive,C=I.onBottomLeave,X=I.onTopArrive,V=I.onTopLeave,$=(0,s.useRef)(!1),q=(0,s.useRef)(!1),H=(0,s.useRef)(0),G=(0,s.useRef)(null),Q=(0,s.useCallback)((function(ye,ce){if(G.current!==null){var Oe=G.current,Me=Oe.scrollTop,_e=Oe.scrollHeight,je=Oe.clientHeight,Ne=G.current,Te=ce>0,ze=_e-je-Me,Le=!1;ze>ce&&$.current&&(C&&C(ye),$.current=!1),Te&&q.current&&(V&&V(ye),q.current=!1),Te&&ce>ze?(T&&!$.current&&T(ye),Ne.scrollTop=_e,Le=!0,$.current=!0):!Te&&-ce>Me&&(X&&!q.current&&X(ye),Ne.scrollTop=0,Le=!0,q.current=!0),Le&&(function(ke){ke.cancelable&&ke.preventDefault(),ke.stopPropagation()})(ye)}}),[T,C,X,V]),ie=(0,s.useCallback)((function(ye){Q(ye,ye.deltaY)}),[Q]),ue=(0,s.useCallback)((function(ye){H.current=ye.changedTouches[0].clientY}),[]),fe=(0,s.useCallback)((function(ye){var ce=H.current-ye.changedTouches[0].clientY;Q(ye,ce)}),[Q]),me=(0,s.useCallback)((function(ye){if(ye){var ce=!!t8&&{passive:!1};ye.addEventListener("wheel",ie,ce),ye.addEventListener("touchstart",ue,ce),ye.addEventListener("touchmove",fe,ce)}}),[fe,ue,ie]),ve=(0,s.useCallback)((function(ye){ye&&(ye.removeEventListener("wheel",ie,!1),ye.removeEventListener("touchstart",ue,!1),ye.removeEventListener("touchmove",fe,!1))}),[fe,ue,ie]);return(0,s.useEffect)((function(){if(N){var ye=G.current;return me(ye),function(){ve(ye)}}}),[N,me,ve]),function(ye){G.current=ye}})({isEnabled:v===void 0||v,onBottomArrive:t.onBottomArrive,onBottomLeave:t.onBottomLeave,onTopArrive:t.onTopArrive,onTopLeave:t.onTopLeave}),A=(function(I){var N=I.isEnabled,T=I.accountForScrollbars,C=T===void 0||T,X=(0,s.useRef)({}),V=(0,s.useRef)(null),$=(0,s.useCallback)((function(H){if(fN){var G=document.body,Q=G&&G.style;if(C&&iN.forEach((function(me){var ve=Q&&Q[me];X.current[me]=ve})),C&&Xa<1){var ie=parseInt(X.current.paddingRight,10)||0,ue=document.body?document.body.clientWidth:0,fe=window.innerWidth-ue+ie||0;Object.keys(aN).forEach((function(me){var ve=aN[me];Q&&(Q[me]=ve)})),Q&&(Q.paddingRight="".concat(fe,"px"))}G&&cN()&&(G.addEventListener("touchmove",sN,Ci),H&&(H.addEventListener("touchstart",uN,Ci),H.addEventListener("touchmove",lN,Ci))),Xa+=1}}),[C]),q=(0,s.useCallback)((function(H){if(fN){var G=document.body,Q=G&&G.style;Xa=Math.max(Xa-1,0),C&&Xa<1&&iN.forEach((function(ie){var ue=X.current[ie];Q&&(Q[ie]=ue)})),G&&cN()&&(G.removeEventListener("touchmove",sN,Ci),H&&(H.removeEventListener("touchstart",uN,Ci),H.removeEventListener("touchmove",lN,Ci)))}}),[C]);return(0,s.useEffect)((function(){if(N){var H=V.current;return $(H),function(){q(H)}}}),[N,$,q]),function(H){V.current=H}})({isEnabled:u});return nt(s.Fragment,null,u&&nt("div",{onClick:C8,css:A8}),a((function(I){O(I),A(I)})))}var T8={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},R8=function(t){var a=t.name,u=t.onFocus;return nt("input",{required:!0,name:a,tabIndex:-1,"aria-hidden":"true",onFocus:u,css:T8,value:"",onChange:function(){}})};function Jv(t){var a;return typeof window<"u"&&window.navigator!=null&&t.test(((a=window.navigator.userAgentData)===null||a===void 0?void 0:a.platform)||window.navigator.platform)}function dN(){return Jv(/^Mac/i)}var hN=function(t){return t.label},pN=function(t){return t.value},P8={clearIndicator:d8,container:function(t){var a=t.isDisabled;return{label:"container",direction:t.isRtl?"rtl":void 0,pointerEvents:a?"none":void 0,position:"relative"}},control:function(t,a){var u=t.isDisabled,v=t.isFocused,O=t.theme,A=O.colors,I=O.borderRadius;return tt({label:"control",alignItems:"center",cursor:"default",display:"flex",flexWrap:"wrap",justifyContent:"space-between",minHeight:O.spacing.controlHeight,outline:"0 !important",position:"relative",transition:"all 100ms"},a?{}:{backgroundColor:u?A.neutral5:A.neutral0,borderColor:u?A.neutral10:v?A.primary:A.neutral20,borderRadius:I,borderStyle:"solid",borderWidth:1,boxShadow:v?"0 0 0 1px ".concat(A.primary):void 0,"&:hover":{borderColor:v?A.primary:A.neutral30}})},dropdownIndicator:f8,group:function(t,a){var u=t.theme.spacing;return a?{}:{paddingBottom:2*u.baseUnit,paddingTop:2*u.baseUnit}},groupHeading:function(t,a){var u=t.theme,v=u.colors,O=u.spacing;return tt({label:"group",cursor:"default",display:"block"},a?{}:{color:v.neutral40,fontSize:"75%",fontWeight:500,marginBottom:"0.25em",paddingLeft:3*O.baseUnit,paddingRight:3*O.baseUnit,textTransform:"uppercase"})},indicatorsContainer:function(){return{alignItems:"center",alignSelf:"stretch",display:"flex",flexShrink:0}},indicatorSeparator:function(t,a){var u=t.isDisabled,v=t.theme,O=v.spacing.baseUnit,A=v.colors;return tt({label:"indicatorSeparator",alignSelf:"stretch",width:1},a?{}:{backgroundColor:u?A.neutral10:A.neutral20,marginBottom:2*O,marginTop:2*O})},input:function(t,a){var u=t.isDisabled,v=t.value,O=t.theme,A=O.spacing,I=O.colors;return tt(tt({visibility:u?"hidden":"visible",transform:v?"translateZ(0)":""},g8),a?{}:{margin:A.baseUnit/2,paddingBottom:A.baseUnit/2,paddingTop:A.baseUnit/2,color:I.neutral80})},loadingIndicator:function(t,a){var u=t.isFocused,v=t.size,O=t.theme,A=O.colors,I=O.spacing.baseUnit;return tt({label:"loadingIndicator",display:"flex",transition:"color 150ms",alignSelf:"center",fontSize:v,lineHeight:1,marginRight:v,textAlign:"center",verticalAlign:"middle"},a?{}:{color:u?A.neutral60:A.neutral20,padding:2*I})},loadingMessage:s8,menu:function(t,a){var u,v=t.placement,O=t.theme,A=O.borderRadius,I=O.spacing,N=O.colors;return tt((Ka(u={label:"menu"},(function(T){return T?{bottom:"top",top:"bottom"}[T]:"bottom"})(v),"100%"),Ka(u,"position","absolute"),Ka(u,"width","100%"),Ka(u,"zIndex",1),u),a?{}:{backgroundColor:N.neutral0,borderRadius:A,boxShadow:"0 0 0 1px hsla(0, 0%, 0%, 0.1), 0 4px 11px hsla(0, 0%, 0%, 0.1)",marginBottom:I.menuGutter,marginTop:I.menuGutter})},menuList:function(t,a){var u=t.maxHeight,v=t.theme.spacing.baseUnit;return tt({maxHeight:u,overflowY:"auto",position:"relative",WebkitOverflowScrolling:"touch"},a?{}:{paddingBottom:v,paddingTop:v})},menuPortal:function(t){var a=t.rect,u=t.offset,v=t.position;return{left:a.left,position:v,top:u,width:a.width,zIndex:1}},multiValue:function(t,a){var u=t.theme,v=u.spacing,O=u.borderRadius,A=u.colors;return tt({label:"multiValue",display:"flex",minWidth:0},a?{}:{backgroundColor:A.neutral10,borderRadius:O/2,margin:v.baseUnit/2})},multiValueLabel:function(t,a){var u=t.theme,v=u.borderRadius,O=u.colors,A=t.cropWithEllipsis;return tt({overflow:"hidden",textOverflow:A||A===void 0?"ellipsis":void 0,whiteSpace:"nowrap"},a?{}:{borderRadius:v/2,color:O.neutral80,fontSize:"85%",padding:3,paddingLeft:6})},multiValueRemove:function(t,a){var u=t.theme,v=u.spacing,O=u.borderRadius,A=u.colors,I=t.isFocused;return tt({alignItems:"center",display:"flex"},a?{}:{borderRadius:O/2,backgroundColor:I?A.dangerLight:void 0,paddingLeft:v.baseUnit,paddingRight:v.baseUnit,":hover":{backgroundColor:A.dangerLight,color:A.danger}})},noOptionsMessage:a8,option:function(t,a){var u=t.isDisabled,v=t.isFocused,O=t.isSelected,A=t.theme,I=A.spacing,N=A.colors;return tt({label:"option",cursor:"default",display:"block",fontSize:"inherit",width:"100%",userSelect:"none",WebkitTapHighlightColor:"rgba(0, 0, 0, 0)"},a?{}:{backgroundColor:O?N.primary:v?N.primary25:"transparent",color:u?N.neutral20:O?N.neutral0:"inherit",padding:"".concat(2*I.baseUnit,"px ").concat(3*I.baseUnit,"px"),":active":{backgroundColor:u?void 0:O?N.primary:N.primary50}})},placeholder:function(t,a){var u=t.theme,v=u.spacing,O=u.colors;return tt({label:"placeholder",gridArea:"1 / 1 / 2 / 3"},a?{}:{color:O.neutral50,marginLeft:v.baseUnit/2,marginRight:v.baseUnit/2})},singleValue:function(t,a){var u=t.isDisabled,v=t.theme,O=v.spacing,A=v.colors;return tt({label:"singleValue",gridArea:"1 / 1 / 2 / 3",maxWidth:"100%",overflow:"hidden",textOverflow:"ellipsis",whiteSpace:"nowrap"},a?{}:{color:u?A.neutral40:A.neutral80,marginLeft:O.baseUnit/2,marginRight:O.baseUnit/2})},valueContainer:function(t,a){var u=t.theme.spacing,v=t.isMulti,O=t.hasValue,A=t.selectProps.controlShouldRenderValue;return tt({alignItems:"center",display:v&&O&&A?"flex":"grid",flex:1,flexWrap:"wrap",WebkitOverflowScrolling:"touch",position:"relative",overflow:"hidden"},a?{}:{padding:"".concat(u.baseUnit/2,"px ").concat(2*u.baseUnit,"px")})}},$v={borderRadius:4,colors:{primary:"#2684FF",primary75:"#4C9AFF",primary50:"#B2D4FF",primary25:"#DEEBFF",danger:"#DE350B",dangerLight:"#FFBDAD",neutral0:"hsl(0, 0%, 100%)",neutral5:"hsl(0, 0%, 95%)",neutral10:"hsl(0, 0%, 90%)",neutral20:"hsl(0, 0%, 80%)",neutral30:"hsl(0, 0%, 70%)",neutral40:"hsl(0, 0%, 60%)",neutral50:"hsl(0, 0%, 50%)",neutral60:"hsl(0, 0%, 40%)",neutral70:"hsl(0, 0%, 30%)",neutral80:"hsl(0, 0%, 20%)",neutral90:"hsl(0, 0%, 10%)"},spacing:{baseUnit:4,controlHeight:38,menuGutter:8}},I8={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:HA(),captureMenuScroll:!HA(),classNames:{},closeMenuOnSelect:!0,closeMenuOnScroll:!1,components:{},controlShouldRenderValue:!0,escapeClearsValue:!1,filterOption:function(t,a){if(t.data.__isNew__)return!0;var u=tt({ignoreCase:!0,ignoreAccents:!0,stringify:E8,trim:!0,matchFrom:"any"},void 0),v=u.ignoreCase,O=u.ignoreAccents,A=u.stringify,I=u.trim,N=u.matchFrom,T=I?oN(a):a,C=I?oN(A(t)):A(t);return v&&(T=T.toLowerCase(),C=C.toLowerCase()),O&&(T=S8(T),C=rN(C)),N==="start"?C.substr(0,T.length)===T:C.indexOf(T)>-1},formatGroupLabel:function(t){return t.label},getOptionLabel:hN,getOptionValue:pN,isDisabled:!1,isLoading:!1,isMulti:!1,isRtl:!1,isSearchable:!0,isOptionDisabled:function(t){return!!t.isDisabled},loadingMessage:function(){return"Loading..."},maxMenuHeight:300,minMenuHeight:140,menuIsOpen:!1,menuPlacement:"bottom",menuPosition:"absolute",menuShouldBlockScroll:!1,menuShouldScrollIntoView:!(function(){try{return/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)}catch{return!1}})(),noOptionsMessage:function(){return"No options"},openMenuOnFocus:!1,openMenuOnClick:!0,options:[],pageSize:5,placeholder:"Select...",screenReaderStatus:function(t){var a=t.count;return"".concat(a," result").concat(a!==1?"s":""," available")},styles:{},tabIndex:0,tabSelectsValue:!0,unstyled:!1};function mN(t,a,u,v){return{type:"option",data:a,isDisabled:wN(t,a,u),isSelected:xN(t,a,u),label:bN(t,a),value:yu(t,a),index:v}}function vu(t,a){return t.options.map((function(u,v){if("options"in u){var O=u.options.map((function(I,N){return mN(t,I,a,N)})).filter((function(I){return yN(t,I)}));return O.length>0?{type:"group",data:u,options:O,index:v}:void 0}var A=mN(t,u,a,v);return yN(t,A)?A:void 0})).filter(n8)}function gN(t){return t.reduce((function(a,u){return u.type==="group"?a.push.apply(a,ki(u.options.map((function(v){return v.data})))):a.push(u.data),a}),[])}function vN(t,a){return t.reduce((function(u,v){return v.type==="group"?u.push.apply(u,ki(v.options.map((function(O){return{data:O.data,id:"".concat(a,"-").concat(v.index,"-").concat(O.index)}})))):u.push({data:v.data,id:"".concat(a,"-").concat(v.index)}),u}),[])}function yN(t,a){var u=t.inputValue,v=u===void 0?"":u,O=a.data,A=a.isSelected,I=a.label,N=a.value;return(!SN(t)||!A)&&_N(t,{label:I,value:N,data:O},v)}var ey=function(t,a){var u;return((u=t.find((function(v){return v.data===a})))===null||u===void 0?void 0:u.id)||null},bN=function(t,a){return t.getOptionLabel(a)},yu=function(t,a){return t.getOptionValue(a)};function wN(t,a,u){return typeof t.isOptionDisabled=="function"&&t.isOptionDisabled(a,u)}function xN(t,a,u){if(u.indexOf(a)>-1)return!0;if(typeof t.isOptionSelected=="function")return t.isOptionSelected(a,u);var v=yu(t,a);return u.some((function(O){return yu(t,O)===v}))}function _N(t,a,u){return!t.filterOption||t.filterOption(a,u)}var SN=function(t){var a=t.hideSelectedOptions,u=t.isMulti;return a===void 0?u:a},M8=1,ty=(function(t){(function(T,C){if(typeof C!="function"&&C!==null)throw new TypeError("Super expression must either be null or a function");T.prototype=Object.create(C&&C.prototype,{constructor:{value:T,writable:!0,configurable:!0}}),Object.defineProperty(T,"prototype",{writable:!1}),C&&ri(T,C)})(N,t);var a,u,v,O,A,I=(O=N,A=(function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch{return!1}})(),function(){var T,C=lu(O);if(A){var X=lu(this).constructor;T=Reflect.construct(C,arguments,X)}else T=C.apply(this,arguments);return(function(V,$){if($&&(Io($)==="object"||typeof $=="function"))return $;if($!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ql(V)})(this,T)});function N(T){var C;if((function(q,H){if(!(q instanceof H))throw new TypeError("Cannot call a class as a function")})(this,N),(C=I.call(this,T)).state={ariaSelection:null,focusedOption:null,focusedOptionId:null,focusableOptionsWithIds:[],focusedValue:null,inputIsHidden:!1,isFocused:!1,selectValue:[],clearFocusValueOnUpdate:!1,prevWasFocused:!1,inputIsHiddenAfterUpdate:void 0,prevProps:void 0,instancePrefix:"",isAppleDevice:!1},C.blockOptionHover=!1,C.isComposing=!1,C.commonProps=void 0,C.initialTouchX=0,C.initialTouchY=0,C.openAfterFocus=!1,C.scrollToFocusedOptionOnUpdate=!1,C.userIsDragging=void 0,C.controlRef=null,C.getControlRef=function(q){C.controlRef=q},C.focusedOptionRef=null,C.getFocusedOptionRef=function(q){C.focusedOptionRef=q},C.menuListRef=null,C.getMenuListRef=function(q){C.menuListRef=q},C.inputRef=null,C.getInputRef=function(q){C.inputRef=q},C.focus=C.focusInput,C.blur=C.blurInput,C.onChange=function(q,H){var G=C.props,Q=G.onChange,ie=G.name;H.name=ie,C.ariaOnChange(q,H),Q(q,H)},C.setValue=function(q,H,G){var Q=C.props,ie=Q.closeMenuOnSelect,ue=Q.isMulti,fe=Q.inputValue;C.onInputChange("",{action:"set-value",prevInputValue:fe}),ie&&(C.setState({inputIsHiddenAfterUpdate:!ue}),C.onMenuClose()),C.setState({clearFocusValueOnUpdate:!0}),C.onChange(q,{action:H,option:G})},C.selectOption=function(q){var H=C.props,G=H.blurInputOnSelect,Q=H.isMulti,ie=H.name,ue=C.state.selectValue,fe=Q&&C.isOptionSelected(q,ue),me=C.isOptionDisabled(q,ue);if(fe){var ve=C.getOptionValue(q);C.setValue(ue.filter((function(ye){return C.getOptionValue(ye)!==ve})),"deselect-option",q)}else{if(me)return void C.ariaOnChange(q,{action:"select-option",option:q,name:ie});Q?C.setValue([].concat(ki(ue),[q]),"select-option",q):C.setValue(q,"select-option")}G&&C.blurInput()},C.removeValue=function(q){var H=C.props.isMulti,G=C.state.selectValue,Q=C.getOptionValue(q),ie=G.filter((function(fe){return C.getOptionValue(fe)!==Q})),ue=Ya(H,ie,ie[0]||null);C.onChange(ue,{action:"remove-value",removedValue:q}),C.focusInput()},C.clearValue=function(){var q=C.state.selectValue;C.onChange(Ya(C.props.isMulti,[],null),{action:"clear",removedValues:q})},C.popValue=function(){var q=C.props.isMulti,H=C.state.selectValue,G=H[H.length-1],Q=H.slice(0,H.length-1),ie=Ya(q,Q,Q[0]||null);G&&C.onChange(ie,{action:"pop-value",removedValue:G})},C.getFocusedOptionId=function(q){return ey(C.state.focusableOptionsWithIds,q)},C.getFocusableOptionsWithIds=function(){return vN(vu(C.props,C.state.selectValue),C.getElementId("option"))},C.getValue=function(){return C.state.selectValue},C.cx=function(){for(var q=arguments.length,H=new Array(q),G=0;G<q;G++)H[G]=arguments[G];return $F.apply(void 0,[C.props.classNamePrefix].concat(H))},C.getOptionLabel=function(q){return bN(C.props,q)},C.getOptionValue=function(q){return yu(C.props,q)},C.getStyles=function(q,H){var G=C.props.unstyled,Q=P8[q](H,G);Q.boxSizing="border-box";var ie=C.props.styles[q];return ie?ie(Q,H):Q},C.getClassNames=function(q,H){var G,Q;return(G=(Q=C.props.classNames)[q])===null||G===void 0?void 0:G.call(Q,H)},C.getElementId=function(q){return"".concat(C.state.instancePrefix,"-").concat(q)},C.getComponents=function(){return q=C.props,tt(tt({},$A),q.components);var q},C.buildCategorizedOptions=function(){return vu(C.props,C.state.selectValue)},C.getCategorizedOptions=function(){return C.props.menuIsOpen?C.buildCategorizedOptions():[]},C.buildFocusableOptions=function(){return gN(C.buildCategorizedOptions())},C.getFocusableOptions=function(){return C.props.menuIsOpen?C.buildFocusableOptions():[]},C.ariaOnChange=function(q,H){C.setState({ariaSelection:tt({value:q},H)})},C.onMenuMouseDown=function(q){q.button===0&&(q.stopPropagation(),q.preventDefault(),C.focusInput())},C.onMenuMouseMove=function(q){C.blockOptionHover=!1},C.onControlMouseDown=function(q){if(!q.defaultPrevented){var H=C.props.openMenuOnClick;C.state.isFocused?C.props.menuIsOpen?q.target.tagName!=="INPUT"&&q.target.tagName!=="TEXTAREA"&&C.onMenuClose():H&&C.openMenu("first"):(H&&(C.openAfterFocus=!0),C.focusInput()),q.target.tagName!=="INPUT"&&q.target.tagName!=="TEXTAREA"&&q.preventDefault()}},C.onDropdownIndicatorMouseDown=function(q){if(!(q&&q.type==="mousedown"&&q.button!==0||C.props.isDisabled)){var H=C.props,G=H.isMulti,Q=H.menuIsOpen;C.focusInput(),Q?(C.setState({inputIsHiddenAfterUpdate:!G}),C.onMenuClose()):C.openMenu("first"),q.preventDefault()}},C.onClearIndicatorMouseDown=function(q){q&&q.type==="mousedown"&&q.button!==0||(C.clearValue(),q.preventDefault(),C.openAfterFocus=!1,q.type==="touchend"?C.focusInput():setTimeout((function(){return C.focusInput()})))},C.onScroll=function(q){typeof C.props.closeMenuOnScroll=="boolean"?q.target instanceof HTMLElement&&hu(q.target)&&C.props.onMenuClose():typeof C.props.closeMenuOnScroll=="function"&&C.props.closeMenuOnScroll(q)&&C.props.onMenuClose()},C.onCompositionStart=function(){C.isComposing=!0},C.onCompositionEnd=function(){C.isComposing=!1},C.onTouchStart=function(q){var H=q.touches,G=H&&H.item(0);G&&(C.initialTouchX=G.clientX,C.initialTouchY=G.clientY,C.userIsDragging=!1)},C.onTouchMove=function(q){var H=q.touches,G=H&&H.item(0);if(G){var Q=Math.abs(G.clientX-C.initialTouchX),ie=Math.abs(G.clientY-C.initialTouchY);C.userIsDragging=Q>5||ie>5}},C.onTouchEnd=function(q){C.userIsDragging||(C.controlRef&&!C.controlRef.contains(q.target)&&C.menuListRef&&!C.menuListRef.contains(q.target)&&C.blurInput(),C.initialTouchX=0,C.initialTouchY=0)},C.onControlTouchEnd=function(q){C.userIsDragging||C.onControlMouseDown(q)},C.onClearIndicatorTouchEnd=function(q){C.userIsDragging||C.onClearIndicatorMouseDown(q)},C.onDropdownIndicatorTouchEnd=function(q){C.userIsDragging||C.onDropdownIndicatorMouseDown(q)},C.handleInputChange=function(q){var H=C.props.inputValue,G=q.currentTarget.value;C.setState({inputIsHiddenAfterUpdate:!1}),C.onInputChange(G,{action:"input-change",prevInputValue:H}),C.props.menuIsOpen||C.onMenuOpen()},C.onInputFocus=function(q){C.props.onFocus&&C.props.onFocus(q),C.setState({inputIsHiddenAfterUpdate:!1,isFocused:!0}),(C.openAfterFocus||C.props.openMenuOnFocus)&&C.openMenu("first"),C.openAfterFocus=!1},C.onInputBlur=function(q){var H=C.props.inputValue;C.menuListRef&&C.menuListRef.contains(document.activeElement)?C.inputRef.focus():(C.props.onBlur&&C.props.onBlur(q),C.onInputChange("",{action:"input-blur",prevInputValue:H}),C.onMenuClose(),C.setState({focusedValue:null,isFocused:!1}))},C.onOptionHover=function(q){if(!C.blockOptionHover&&C.state.focusedOption!==q){var H=C.getFocusableOptions().indexOf(q);C.setState({focusedOption:q,focusedOptionId:H>-1?C.getFocusedOptionId(q):null})}},C.shouldHideSelectedOptions=function(){return SN(C.props)},C.onValueInputFocus=function(q){q.preventDefault(),q.stopPropagation(),C.focus()},C.onKeyDown=function(q){var H=C.props,G=H.isMulti,Q=H.backspaceRemovesValue,ie=H.escapeClearsValue,ue=H.inputValue,fe=H.isClearable,me=H.isDisabled,ve=H.menuIsOpen,ye=H.onKeyDown,ce=H.tabSelectsValue,Oe=H.openMenuOnFocus,Me=C.state,_e=Me.focusedOption,je=Me.focusedValue,Ne=Me.selectValue;if(!(me||typeof ye=="function"&&(ye(q),q.defaultPrevented))){switch(C.blockOptionHover=!0,q.key){case"ArrowLeft":if(!G||ue)return;C.focusValue("previous");break;case"ArrowRight":if(!G||ue)return;C.focusValue("next");break;case"Delete":case"Backspace":if(ue)return;if(je)C.removeValue(je);else{if(!Q)return;G?C.popValue():fe&&C.clearValue()}break;case"Tab":if(C.isComposing||q.shiftKey||!ve||!ce||!_e||Oe&&C.isOptionSelected(_e,Ne))return;C.selectOption(_e);break;case"Enter":if(q.keyCode===229)break;if(ve){if(!_e||C.isComposing)return;C.selectOption(_e);break}return;case"Escape":ve?(C.setState({inputIsHiddenAfterUpdate:!1}),C.onInputChange("",{action:"menu-close",prevInputValue:ue}),C.onMenuClose()):fe&&ie&&C.clearValue();break;case" ":if(ue)return;if(!ve){C.openMenu("first");break}if(!_e)return;C.selectOption(_e);break;case"ArrowUp":ve?C.focusOption("up"):C.openMenu("last");break;case"ArrowDown":ve?C.focusOption("down"):C.openMenu("first");break;case"PageUp":if(!ve)return;C.focusOption("pageup");break;case"PageDown":if(!ve)return;C.focusOption("pagedown");break;case"Home":if(!ve)return;C.focusOption("first");break;case"End":if(!ve)return;C.focusOption("last");break;default:return}q.preventDefault()}},C.state.instancePrefix="react-select-"+(C.props.instanceId||++M8),C.state.selectValue=du(T.value),T.menuIsOpen&&C.state.selectValue.length){var X=C.getFocusableOptionsWithIds(),V=C.buildFocusableOptions(),$=V.indexOf(C.state.selectValue[0]);C.state.focusableOptionsWithIds=X,C.state.focusedOption=V[$],C.state.focusedOptionId=ey(X,V[$])}return C}return a=N,u=[{key:"componentDidMount",value:function(){this.startListeningComposition(),this.startListeningToTouch(),this.props.closeMenuOnScroll&&document&&document.addEventListener&&document.addEventListener("scroll",this.onScroll,!0),this.props.autoFocus&&this.focusInput(),this.props.menuIsOpen&&this.state.focusedOption&&this.menuListRef&&this.focusedOptionRef&&zA(this.menuListRef,this.focusedOptionRef),(dN()||Jv(/^iPhone/i)||Jv(/^iPad/i)||dN()&&navigator.maxTouchPoints>1)&&this.setState({isAppleDevice:!0})}},{key:"componentDidUpdate",value:function(T){var C=this.props,X=C.isDisabled,V=C.menuIsOpen,$=this.state.isFocused;($&&!X&&T.isDisabled||$&&V&&!T.menuIsOpen)&&this.focusInput(),$&&X&&!T.isDisabled?this.setState({isFocused:!1},this.onMenuClose):$||X||!T.isDisabled||this.inputRef!==document.activeElement||this.setState({isFocused:!0}),this.menuListRef&&this.focusedOptionRef&&this.scrollToFocusedOptionOnUpdate&&(zA(this.menuListRef,this.focusedOptionRef),this.scrollToFocusedOptionOnUpdate=!1)}},{key:"componentWillUnmount",value:function(){this.stopListeningComposition(),this.stopListeningToTouch(),document.removeEventListener("scroll",this.onScroll,!0)}},{key:"onMenuOpen",value:function(){this.props.onMenuOpen()}},{key:"onMenuClose",value:function(){this.onInputChange("",{action:"menu-close",prevInputValue:this.props.inputValue}),this.props.onMenuClose()}},{key:"onInputChange",value:function(T,C){this.props.onInputChange(T,C)}},{key:"focusInput",value:function(){this.inputRef&&this.inputRef.focus()}},{key:"blurInput",value:function(){this.inputRef&&this.inputRef.blur()}},{key:"openMenu",value:function(T){var C=this,X=this.state,V=X.selectValue,$=X.isFocused,q=this.buildFocusableOptions(),H=T==="first"?0:q.length-1;if(!this.props.isMulti){var G=q.indexOf(V[0]);G>-1&&(H=G)}this.scrollToFocusedOptionOnUpdate=!($&&this.menuListRef),this.setState({inputIsHiddenAfterUpdate:!1,focusedValue:null,focusedOption:q[H],focusedOptionId:this.getFocusedOptionId(q[H])},(function(){return C.onMenuOpen()}))}},{key:"focusValue",value:function(T){var C=this.state,X=C.selectValue,V=C.focusedValue;if(this.props.isMulti){this.setState({focusedOption:null});var $=X.indexOf(V);V||($=-1);var q=X.length-1,H=-1;if(X.length){switch(T){case"previous":H=$===0?0:$===-1?q:$-1;break;case"next":$>-1&&$<q&&(H=$+1)}this.setState({inputIsHidden:H!==-1,focusedValue:X[H]})}}}},{key:"focusOption",value:function(){var T=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"first",C=this.props.pageSize,X=this.state.focusedOption,V=this.getFocusableOptions();if(V.length){var $=0,q=V.indexOf(X);X||(q=-1),T==="up"?$=q>0?q-1:V.length-1:T==="down"?$=(q+1)%V.length:T==="pageup"?($=q-C)<0&&($=0):T==="pagedown"?($=q+C)>V.length-1&&($=V.length-1):T==="last"&&($=V.length-1),this.scrollToFocusedOptionOnUpdate=!0,this.setState({focusedOption:V[$],focusedValue:null,focusedOptionId:this.getFocusedOptionId(V[$])})}}},{key:"getTheme",value:function(){return this.props.theme?typeof this.props.theme=="function"?this.props.theme($v):tt(tt({},$v),this.props.theme):$v}},{key:"getCommonProps",value:function(){var T=this.clearValue,C=this.cx,X=this.getStyles,V=this.getClassNames,$=this.getValue,q=this.selectOption,H=this.setValue,G=this.props,Q=G.isMulti,ie=G.isRtl,ue=G.options;return{clearValue:T,cx:C,getStyles:X,getClassNames:V,getValue:$,hasValue:this.hasValue(),isMulti:Q,isRtl:ie,options:ue,selectOption:q,selectProps:G,setValue:H,theme:this.getTheme()}}},{key:"hasValue",value:function(){return this.state.selectValue.length>0}},{key:"hasOptions",value:function(){return!!this.getFocusableOptions().length}},{key:"isClearable",value:function(){var T=this.props,C=T.isClearable,X=T.isMulti;return C===void 0?X:C}},{key:"isOptionDisabled",value:function(T,C){return wN(this.props,T,C)}},{key:"isOptionSelected",value:function(T,C){return xN(this.props,T,C)}},{key:"filterOption",value:function(T,C){return _N(this.props,T,C)}},{key:"formatOptionLabel",value:function(T,C){if(typeof this.props.formatOptionLabel=="function"){var X=this.props.inputValue,V=this.state.selectValue;return this.props.formatOptionLabel(T,{context:C,inputValue:X,selectValue:V})}return this.getOptionLabel(T)}},{key:"formatGroupLabel",value:function(T){return this.props.formatGroupLabel(T)}},{key:"startListeningComposition",value:function(){document&&document.addEventListener&&(document.addEventListener("compositionstart",this.onCompositionStart,!1),document.addEventListener("compositionend",this.onCompositionEnd,!1))}},{key:"stopListeningComposition",value:function(){document&&document.removeEventListener&&(document.removeEventListener("compositionstart",this.onCompositionStart),document.removeEventListener("compositionend",this.onCompositionEnd))}},{key:"startListeningToTouch",value:function(){document&&document.addEventListener&&(document.addEventListener("touchstart",this.onTouchStart,!1),document.addEventListener("touchmove",this.onTouchMove,!1),document.addEventListener("touchend",this.onTouchEnd,!1))}},{key:"stopListeningToTouch",value:function(){document&&document.removeEventListener&&(document.removeEventListener("touchstart",this.onTouchStart),document.removeEventListener("touchmove",this.onTouchMove),document.removeEventListener("touchend",this.onTouchEnd))}},{key:"renderInput",value:function(){var T=this.props,C=T.isDisabled,X=T.isSearchable,V=T.inputId,$=T.inputValue,q=T.tabIndex,H=T.form,G=T.menuIsOpen,Q=T.required,ie=this.getComponents().Input,ue=this.state,fe=ue.inputIsHidden,me=ue.ariaSelection,ve=this.commonProps,ye=V||this.getElementId("input"),ce=tt(tt(tt({"aria-autocomplete":"list","aria-expanded":G,"aria-haspopup":!0,"aria-errormessage":this.props["aria-errormessage"],"aria-invalid":this.props["aria-invalid"],"aria-label":this.props["aria-label"],"aria-labelledby":this.props["aria-labelledby"],"aria-required":Q,role:"combobox","aria-activedescendant":this.state.isAppleDevice?void 0:this.state.focusedOptionId||""},G&&{"aria-controls":this.getElementId("listbox")}),!X&&{"aria-readonly":!0}),this.hasValue()?me?.action==="initial-input-focus"&&{"aria-describedby":this.getElementId("live-region")}:{"aria-describedby":this.getElementId("placeholder")});return X?s.createElement(ie,et({},ve,{autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",id:ye,innerRef:this.getInputRef,isDisabled:C,isHidden:fe,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:q,form:H,type:"text",value:$},ce)):s.createElement(k8,et({id:ye,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:fu,onFocus:this.onInputFocus,disabled:C,tabIndex:q,inputMode:"none",form:H,value:""},ce))}},{key:"renderPlaceholderOrValue",value:function(){var T=this,C=this.getComponents(),X=C.MultiValue,V=C.MultiValueContainer,$=C.MultiValueLabel,q=C.MultiValueRemove,H=C.SingleValue,G=C.Placeholder,Q=this.commonProps,ie=this.props,ue=ie.controlShouldRenderValue,fe=ie.isDisabled,me=ie.isMulti,ve=ie.inputValue,ye=ie.placeholder,ce=this.state,Oe=ce.selectValue,Me=ce.focusedValue,_e=ce.isFocused;if(!this.hasValue()||!ue)return ve?null:s.createElement(G,et({},Q,{key:"placeholder",isDisabled:fe,isFocused:_e,innerProps:{id:this.getElementId("placeholder")}}),ye);if(me)return Oe.map((function(Ne,Te){var ze=Ne===Me,Le="".concat(T.getOptionLabel(Ne),"-").concat(T.getOptionValue(Ne));return s.createElement(X,et({},Q,{components:{Container:V,Label:$,Remove:q},isFocused:ze,isDisabled:fe,key:Le,index:Te,removeProps:{onClick:function(){return T.removeValue(Ne)},onTouchEnd:function(){return T.removeValue(Ne)},onMouseDown:function(ke){ke.preventDefault()}},data:Ne}),T.formatOptionLabel(Ne,"value"))}));if(ve)return null;var je=Oe[0];return s.createElement(H,et({},Q,{data:je,isDisabled:fe}),this.formatOptionLabel(je,"value"))}},{key:"renderClearIndicator",value:function(){var T=this.getComponents().ClearIndicator,C=this.commonProps,X=this.props,V=X.isDisabled,$=X.isLoading,q=this.state.isFocused;if(!this.isClearable()||!T||V||!this.hasValue()||$)return null;var H={onMouseDown:this.onClearIndicatorMouseDown,onTouchEnd:this.onClearIndicatorTouchEnd,"aria-hidden":"true"};return s.createElement(T,et({},C,{innerProps:H,isFocused:q}))}},{key:"renderLoadingIndicator",value:function(){var T=this.getComponents().LoadingIndicator,C=this.commonProps,X=this.props,V=X.isDisabled,$=X.isLoading,q=this.state.isFocused;return T&&$?s.createElement(T,et({},C,{innerProps:{"aria-hidden":"true"},isDisabled:V,isFocused:q})):null}},{key:"renderIndicatorSeparator",value:function(){var T=this.getComponents(),C=T.DropdownIndicator,X=T.IndicatorSeparator;if(!C||!X)return null;var V=this.commonProps,$=this.props.isDisabled,q=this.state.isFocused;return s.createElement(X,et({},V,{isDisabled:$,isFocused:q}))}},{key:"renderDropdownIndicator",value:function(){var T=this.getComponents().DropdownIndicator;if(!T)return null;var C=this.commonProps,X=this.props.isDisabled,V=this.state.isFocused,$={onMouseDown:this.onDropdownIndicatorMouseDown,onTouchEnd:this.onDropdownIndicatorTouchEnd,"aria-hidden":"true"};return s.createElement(T,et({},C,{innerProps:$,isDisabled:X,isFocused:V}))}},{key:"renderMenu",value:function(){var T=this,C=this.getComponents(),X=C.Group,V=C.GroupHeading,$=C.Menu,q=C.MenuList,H=C.MenuPortal,G=C.LoadingMessage,Q=C.NoOptionsMessage,ie=C.Option,ue=this.commonProps,fe=this.state.focusedOption,me=this.props,ve=me.captureMenuScroll,ye=me.inputValue,ce=me.isLoading,Oe=me.loadingMessage,Me=me.minMenuHeight,_e=me.maxMenuHeight,je=me.menuIsOpen,Ne=me.menuPlacement,Te=me.menuPosition,ze=me.menuPortalTarget,Le=me.menuShouldBlockScroll,ke=me.menuShouldScrollIntoView,Ke=me.noOptionsMessage,$e=me.onMenuScrollToTop,dt=me.onMenuScrollToBottom;if(!je)return null;var lt,gt=function(Ye,it){var at=Ye.type,bt=Ye.data,kt=Ye.isDisabled,Zt=Ye.isSelected,Qt=Ye.label,rn=Ye.value,En=fe===bt,on=kt?void 0:function(){return T.onOptionHover(bt)},St=kt?void 0:function(){return T.selectOption(bt)},Gt="".concat(T.getElementId("option"),"-").concat(it),On={id:Gt,onClick:St,onMouseMove:on,onMouseOver:on,tabIndex:-1,role:"option","aria-selected":T.state.isAppleDevice?void 0:Zt};return s.createElement(ie,et({},ue,{innerProps:On,data:bt,isDisabled:kt,isSelected:Zt,key:Gt,label:Qt,type:at,value:rn,isFocused:En,innerRef:En?T.getFocusedOptionRef:void 0}),T.formatOptionLabel(Ye.data,"menu"))};if(this.hasOptions())lt=this.getCategorizedOptions().map((function(Ye){if(Ye.type==="group"){var it=Ye.data,at=Ye.options,bt=Ye.index,kt="".concat(T.getElementId("group"),"-").concat(bt),Zt="".concat(kt,"-heading");return s.createElement(X,et({},ue,{key:kt,data:it,options:at,Heading:V,headingProps:{id:Zt,data:Ye.data},label:T.formatGroupLabel(Ye.data)}),Ye.options.map((function(Qt){return gt(Qt,"".concat(bt,"-").concat(Qt.index))})))}if(Ye.type==="option")return gt(Ye,"".concat(Ye.index))}));else if(ce){var Xe=Oe({inputValue:ye});if(Xe===null)return null;lt=s.createElement(G,ue,Xe)}else{var le=Ke({inputValue:ye});if(le===null)return null;lt=s.createElement(Q,ue,le)}var qe={minMenuHeight:Me,maxMenuHeight:_e,menuPlacement:Ne,menuPosition:Te,menuShouldScrollIntoView:ke},Ie=s.createElement(i8,et({},ue,qe),(function(Ye){var it=Ye.ref,at=Ye.placerProps,bt=at.placement,kt=at.maxHeight;return s.createElement($,et({},ue,qe,{innerRef:it,innerProps:{onMouseDown:T.onMenuMouseDown,onMouseMove:T.onMenuMouseMove},isLoading:ce,placement:bt}),s.createElement(N8,{captureEnabled:ve,onTopArrive:$e,onBottomArrive:dt,lockEnabled:Le},(function(Zt){return s.createElement(q,et({},ue,{innerRef:function(Qt){T.getMenuListRef(Qt),Zt(Qt)},innerProps:{role:"listbox","aria-multiselectable":ue.isMulti,id:T.getElementId("listbox")},isLoading:ce,maxHeight:kt,focusedOption:fe}),lt)})))}));return ze||Te==="fixed"?s.createElement(H,et({},ue,{appendTo:ze,controlElement:this.controlRef,menuPlacement:Ne,menuPosition:Te}),Ie):Ie}},{key:"renderFormField",value:function(){var T=this,C=this.props,X=C.delimiter,V=C.isDisabled,$=C.isMulti,q=C.name,H=C.required,G=this.state.selectValue;if(H&&!this.hasValue()&&!V)return s.createElement(R8,{name:q,onFocus:this.onValueInputFocus});if(q&&!V){if($){if(X){var Q=G.map((function(fe){return T.getOptionValue(fe)})).join(X);return s.createElement("input",{name:q,type:"hidden",value:Q})}var ie=G.length>0?G.map((function(fe,me){return s.createElement("input",{key:"i-".concat(me),name:q,type:"hidden",value:T.getOptionValue(fe)})})):s.createElement("input",{name:q,type:"hidden",value:""});return s.createElement("div",null,ie)}var ue=G[0]?this.getOptionValue(G[0]):"";return s.createElement("input",{name:q,type:"hidden",value:ue})}}},{key:"renderLiveRegion",value:function(){var T=this.commonProps,C=this.state,X=C.ariaSelection,V=C.focusedOption,$=C.focusedValue,q=C.isFocused,H=C.selectValue,G=this.getFocusableOptions();return s.createElement(x8,et({},T,{id:this.getElementId("live-region"),ariaSelection:X,focusedOption:V,focusedValue:$,isFocused:q,selectValue:H,focusableOptions:G,isAppleDevice:this.state.isAppleDevice}))}},{key:"render",value:function(){var T=this.getComponents(),C=T.Control,X=T.IndicatorsContainer,V=T.SelectContainer,$=T.ValueContainer,q=this.props,H=q.className,G=q.id,Q=q.isDisabled,ie=q.menuIsOpen,ue=this.state.isFocused,fe=this.commonProps=this.getCommonProps();return s.createElement(V,et({},fe,{className:H,innerProps:{id:G,onKeyDown:this.onKeyDown},isDisabled:Q,isFocused:ue}),this.renderLiveRegion(),s.createElement(C,et({},fe,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:Q,isFocused:ue,menuIsOpen:ie}),s.createElement($,et({},fe,{isDisabled:Q}),this.renderPlaceholderOrValue(),this.renderInput()),s.createElement(X,et({},fe,{isDisabled:Q}),this.renderClearIndicator(),this.renderLoadingIndicator(),this.renderIndicatorSeparator(),this.renderDropdownIndicator())),this.renderMenu(),this.renderFormField())}}],v=[{key:"getDerivedStateFromProps",value:function(T,C){var X=C.prevProps,V=C.clearFocusValueOnUpdate,$=C.inputIsHiddenAfterUpdate,q=C.ariaSelection,H=C.isFocused,G=C.prevWasFocused,Q=C.instancePrefix,ie=T.options,ue=T.value,fe=T.menuIsOpen,me=T.inputValue,ve=T.isMulti,ye=du(ue),ce={};if(X&&(ue!==X.value||ie!==X.options||fe!==X.menuIsOpen||me!==X.inputValue)){var Oe=fe?(function(Le,ke){return gN(vu(Le,ke))})(T,ye):[],Me=fe?vN(vu(T,ye),"".concat(Q,"-option")):[],_e=V?(function(Le,ke){var Ke=Le.focusedValue,$e=Le.selectValue.indexOf(Ke);if($e>-1){if(ke.indexOf(Ke)>-1)return Ke;if($e<ke.length)return ke[$e]}return null})(C,ye):null,je=(function(Le,ke){var Ke=Le.focusedOption;return Ke&&ke.indexOf(Ke)>-1?Ke:ke[0]})(C,Oe);ce={selectValue:ye,focusedOption:je,focusedOptionId:ey(Me,je),focusableOptionsWithIds:Me,focusedValue:_e,clearFocusValueOnUpdate:!1}}var Ne=$!=null&&T!==X?{inputIsHidden:$,inputIsHiddenAfterUpdate:void 0}:{},Te=q,ze=H&&G;return H&&!ze&&(Te={value:Ya(ve,ye,ye[0]||null),options:ye,action:"initial-input-focus"},ze=!G),q?.action==="initial-input-focus"&&(Te=null),tt(tt(tt({},ce),Ne),{},{prevProps:T,ariaSelection:Te,prevWasFocused:ze})}}],u&&NA(a.prototype,u),v&&NA(a,v),Object.defineProperty(a,"prototype",{writable:!1}),N})(s.Component);ty.defaultProps=I8;var j8=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function EN(t){var a=t.defaultInputValue,u=a===void 0?"":a,v=t.defaultMenuIsOpen,O=v!==void 0&&v,A=t.defaultValue,I=A===void 0?null:A,N=t.inputValue,T=t.menuIsOpen,C=t.onChange,X=t.onInputChange,V=t.onMenuClose,$=t.onMenuOpen,q=t.value,H=wr(t,j8),G=zr((0,s.useState)(N!==void 0?N:u),2),Q=G[0],ie=G[1],ue=zr((0,s.useState)(T!==void 0?T:O),2),fe=ue[0],me=ue[1],ve=zr((0,s.useState)(q!==void 0?q:I),2),ye=ve[0],ce=ve[1],Oe=(0,s.useCallback)((function(Le,ke){typeof C=="function"&&C(Le,ke),ce(Le)}),[C]),Me=(0,s.useCallback)((function(Le,ke){var Ke;typeof X=="function"&&(Ke=X(Le,ke)),ie(Ke!==void 0?Ke:Le)}),[X]),_e=(0,s.useCallback)((function(){typeof $=="function"&&$(),me(!0)}),[$]),je=(0,s.useCallback)((function(){typeof V=="function"&&V(),me(!1)}),[V]),Ne=N!==void 0?N:Q,Te=T!==void 0?T:fe,ze=q!==void 0?q:ye;return tt(tt({},H),{},{inputValue:Ne,menuIsOpen:Te,onChange:Oe,onInputChange:Me,onMenuClose:je,onMenuOpen:_e,value:ze})}var L8=["allowCreateWhileLoading","createOptionPosition","formatCreateLabel","isValidNewOption","getNewOptionData","onCreateOption","options","onChange"],ON=function(){var t=arguments.length>1?arguments[1]:void 0,a=arguments.length>2?arguments[2]:void 0,u=String(arguments.length>0&&arguments[0]!==void 0?arguments[0]:"").toLowerCase(),v=String(a.getOptionValue(t)).toLowerCase(),O=String(a.getOptionLabel(t)).toLowerCase();return v===u||O===u},ny={formatCreateLabel:function(t){return'Create "'.concat(t,'"')},isValidNewOption:function(t,a,u,v){return!(!t||a.some((function(O){return ON(t,O,v)}))||u.some((function(O){return ON(t,O,v)})))},getNewOptionData:function(t,a){return{label:a,value:t,__isNew__:!0}}},D8=(0,s.forwardRef)((function(t,a){var u=(function(v){var O=v.allowCreateWhileLoading,A=O!==void 0&&O,I=v.createOptionPosition,N=I===void 0?"last":I,T=v.formatCreateLabel,C=T===void 0?ny.formatCreateLabel:T,X=v.isValidNewOption,V=X===void 0?ny.isValidNewOption:X,$=v.getNewOptionData,q=$===void 0?ny.getNewOptionData:$,H=v.onCreateOption,G=v.options,Q=G===void 0?[]:G,ie=v.onChange,ue=wr(v,L8),fe=ue.getOptionValue,me=fe===void 0?pN:fe,ve=ue.getOptionLabel,ye=ve===void 0?hN:ve,ce=ue.inputValue,Oe=ue.isLoading,Me=ue.isMulti,_e=ue.value,je=ue.name,Ne=(0,s.useMemo)((function(){return V(ce,du(_e),Q,{getOptionValue:me,getOptionLabel:ye})?q(ce,C(ce)):void 0}),[C,q,ye,me,ce,V,Q,_e]),Te=(0,s.useMemo)((function(){return!A&&Oe||!Ne?Q:N==="first"?[Ne].concat(ki(Q)):[].concat(ki(Q),[Ne])}),[A,N,Oe,Ne,Q]),ze=(0,s.useCallback)((function(Le,ke){if(ke.action!=="select-option")return ie(Le,ke);var Ke=Array.isArray(Le)?Le:[Le];if(Ke[Ke.length-1]!==Ne)ie(Le,ke);else if(H)H(ce);else{var $e=q(ce,ce),dt={action:"create-option",name:je,option:$e};ie(Ya(Me,[].concat(ki(du(_e)),[$e]),$e),dt)}}),[q,ce,Me,je,Ne,H,ie,_e]);return tt(tt({},ue),{},{options:Te,onChange:ze})})(EN(t));return s.createElement(ty,et({ref:a},u))})),kN=D8,B8=(0,s.forwardRef)((function(t,a){var u=EN(t);return s.createElement(ty,et({ref:a},u))})),CN=Number.isNaN||function(t){return typeof t=="number"&&t!=t};function F8(t,a){if(t.length!==a.length)return!1;for(var u=0;u<t.length;u++)if(!((v=t[u])===(O=a[u])||CN(v)&&CN(O)))return!1;var v,O;return!0}const ry=function(t,a){var u;a===void 0&&(a=F8);var v,O=[],A=!1;return function(){for(var I=[],N=0;N<arguments.length;N++)I[N]=arguments[N];return A&&u===this&&a(I,O)||(v=t.apply(this,I),A=!0,u=this,O=I),v}};var AN=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()};function NN(t){cancelAnimationFrame(t.id)}var oy=-1;function TN(t){if(t===void 0&&(t=!1),oy===-1||t){var a=document.createElement("div"),u=a.style;u.width="50px",u.height="50px",u.overflow="scroll",document.body.appendChild(a),oy=a.offsetWidth-a.clientWidth,document.body.removeChild(a)}return oy}var Za=null;function RN(t){if(t===void 0&&(t=!1),Za===null||t){var a=document.createElement("div"),u=a.style;u.width="50px",u.height="50px",u.overflow="scroll",u.direction="rtl";var v=document.createElement("div"),O=v.style;return O.width="100px",O.height="100px",a.appendChild(v),document.body.appendChild(a),a.scrollLeft>0?Za="positive-descending":(a.scrollLeft=1,Za=a.scrollLeft===0?"negative":"positive-ascending"),document.body.removeChild(a),Za}return Za}var q8=function(t,a){return t};function z8(t){var a,u=t.getItemOffset,v=t.getEstimatedTotalSize,O=t.getItemSize,A=t.getOffsetForIndexAndAlignment,I=t.getStartIndexForOffset,N=t.getStopIndexForStartIndex,T=t.initInstanceProps,C=t.validateProps;return a=(function(X){function V(q){var H;return(H=X.call(this,q)||this)._instanceProps=T(H.props,Ql(H)),H._outerRef=void 0,H._resetIsScrollingTimeoutId=null,H.state={instance:Ql(H),isScrolling:!1,scrollDirection:"forward",scrollOffset:typeof H.props.initialScrollOffset=="number"?H.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},H._callOnItemsRendered=void 0,H._callOnItemsRendered=ry((function(G,Q,ie,ue){return H.props.onItemsRendered({overscanStartIndex:G,overscanStopIndex:Q,visibleStartIndex:ie,visibleStopIndex:ue})})),H._callOnScroll=void 0,H._callOnScroll=ry((function(G,Q,ie){return H.props.onScroll({scrollDirection:G,scrollOffset:Q,scrollUpdateWasRequested:ie})})),H._getItemStyle=void 0,H._getItemStyle=function(G){var Q,ie=H.props,ue=ie.direction,fe=ie.itemSize,me=ie.layout,ve=H._getItemStyleCache(fe,me,ue);if(ve.hasOwnProperty(G))Q=ve[G];else{var ye=u(H.props,G,H._instanceProps),ce=O(H.props,G,H._instanceProps),Oe=ue==="horizontal"||me==="horizontal",Me=ue==="rtl",_e=Oe?ye:0;ve[G]=Q={position:"absolute",left:Me?void 0:_e,right:Me?_e:void 0,top:Oe?0:ye,height:Oe?"100%":ce,width:Oe?ce:"100%"}}return Q},H._getItemStyleCache=void 0,H._getItemStyleCache=ry((function(G,Q,ie){return{}})),H._onScrollHorizontal=function(G){var Q=G.currentTarget,ie=Q.clientWidth,ue=Q.scrollLeft,fe=Q.scrollWidth;H.setState((function(me){if(me.scrollOffset===ue)return null;var ve=H.props.direction,ye=ue;if(ve==="rtl")switch(RN()){case"negative":ye=-ue;break;case"positive-descending":ye=fe-ie-ue}return ye=Math.max(0,Math.min(ye,fe-ie)),{isScrolling:!0,scrollDirection:me.scrollOffset<ue?"forward":"backward",scrollOffset:ye,scrollUpdateWasRequested:!1}}),H._resetIsScrollingDebounced)},H._onScrollVertical=function(G){var Q=G.currentTarget,ie=Q.clientHeight,ue=Q.scrollHeight,fe=Q.scrollTop;H.setState((function(me){if(me.scrollOffset===fe)return null;var ve=Math.max(0,Math.min(fe,ue-ie));return{isScrolling:!0,scrollDirection:me.scrollOffset<ve?"forward":"backward",scrollOffset:ve,scrollUpdateWasRequested:!1}}),H._resetIsScrollingDebounced)},H._outerRefSetter=function(G){var Q=H.props.outerRef;H._outerRef=G,typeof Q=="function"?Q(G):Q!=null&&typeof Q=="object"&&Q.hasOwnProperty("current")&&(Q.current=G)},H._resetIsScrollingDebounced=function(){var G,Q,ie,ue;H._resetIsScrollingTimeoutId!==null&&NN(H._resetIsScrollingTimeoutId),H._resetIsScrollingTimeoutId=(G=H._resetIsScrolling,Q=150,ie=AN(),ue={id:requestAnimationFrame((function fe(){AN()-ie>=Q?G.call(null):ue.id=requestAnimationFrame(fe)}))})},H._resetIsScrolling=function(){H._resetIsScrollingTimeoutId=null,H.setState({isScrolling:!1},(function(){H._getItemStyleCache(-1,null)}))},H}Oa(V,X),V.getDerivedStateFromProps=function(q,H){return H8(q,H),C(q),null};var $=V.prototype;return $.scrollTo=function(q){q=Math.max(0,q),this.setState((function(H){return H.scrollOffset===q?null:{scrollDirection:H.scrollOffset<q?"forward":"backward",scrollOffset:q,scrollUpdateWasRequested:!0}}),this._resetIsScrollingDebounced)},$.scrollToItem=function(q,H){H===void 0&&(H="auto");var G=this.props,Q=G.itemCount,ie=G.layout,ue=this.state.scrollOffset;q=Math.max(0,Math.min(q,Q-1));var fe=0;if(this._outerRef){var me=this._outerRef;fe=ie==="vertical"?me.scrollWidth>me.clientWidth?TN():0:me.scrollHeight>me.clientHeight?TN():0}this.scrollTo(A(this.props,q,H,ue,this._instanceProps,fe))},$.componentDidMount=function(){var q=this.props,H=q.direction,G=q.initialScrollOffset,Q=q.layout;if(typeof G=="number"&&this._outerRef!=null){var ie=this._outerRef;H==="horizontal"||Q==="horizontal"?ie.scrollLeft=G:ie.scrollTop=G}this._callPropsCallbacks()},$.componentDidUpdate=function(){var q=this.props,H=q.direction,G=q.layout,Q=this.state,ie=Q.scrollOffset;if(Q.scrollUpdateWasRequested&&this._outerRef!=null){var ue=this._outerRef;if(H==="horizontal"||G==="horizontal")if(H==="rtl")switch(RN()){case"negative":ue.scrollLeft=-ie;break;case"positive-ascending":ue.scrollLeft=ie;break;default:var fe=ue.clientWidth,me=ue.scrollWidth;ue.scrollLeft=me-fe-ie}else ue.scrollLeft=ie;else ue.scrollTop=ie}this._callPropsCallbacks()},$.componentWillUnmount=function(){this._resetIsScrollingTimeoutId!==null&&NN(this._resetIsScrollingTimeoutId)},$.render=function(){var q=this.props,H=q.children,G=q.className,Q=q.direction,ie=q.height,ue=q.innerRef,fe=q.innerElementType,me=q.innerTagName,ve=q.itemCount,ye=q.itemData,ce=q.itemKey,Oe=ce===void 0?q8:ce,Me=q.layout,_e=q.outerElementType,je=q.outerTagName,Ne=q.style,Te=q.useIsScrolling,ze=q.width,Le=this.state.isScrolling,ke=Q==="horizontal"||Me==="horizontal",Ke=ke?this._onScrollHorizontal:this._onScrollVertical,$e=this._getRangeToRender(),dt=$e[0],lt=$e[1],gt=[];if(ve>0)for(var Xe=dt;Xe<=lt;Xe++)gt.push((0,s.createElement)(H,{data:ye,key:Oe(Xe,ye),index:Xe,isScrolling:Te?Le:void 0,style:this._getItemStyle(Xe)}));var le=v(this.props,this._instanceProps);return(0,s.createElement)(_e||je||"div",{className:G,onScroll:Ke,ref:this._outerRefSetter,style:et({position:"relative",height:ie,width:ze,overflow:"auto",WebkitOverflowScrolling:"touch",willChange:"transform",direction:Q},Ne)},(0,s.createElement)(fe||me||"div",{children:gt,ref:ue,style:{height:ke?"100%":le,pointerEvents:Le?"none":void 0,width:ke?le:"100%"}}))},$._callPropsCallbacks=function(){if(typeof this.props.onItemsRendered=="function"&&this.props.itemCount>0){var q=this._getRangeToRender(),H=q[0],G=q[1],Q=q[2],ie=q[3];this._callOnItemsRendered(H,G,Q,ie)}if(typeof this.props.onScroll=="function"){var ue=this.state,fe=ue.scrollDirection,me=ue.scrollOffset,ve=ue.scrollUpdateWasRequested;this._callOnScroll(fe,me,ve)}},$._getRangeToRender=function(){var q=this.props,H=q.itemCount,G=q.overscanCount,Q=this.state,ie=Q.isScrolling,ue=Q.scrollDirection,fe=Q.scrollOffset;if(H===0)return[0,0,0,0];var me=I(this.props,fe,this._instanceProps),ve=N(this.props,me,fe,this._instanceProps),ye=ie&&ue!=="backward"?1:Math.max(1,G),ce=ie&&ue!=="forward"?1:Math.max(1,G);return[Math.max(0,me-ye),Math.max(0,Math.min(H-1,ve+ce)),me,ve]},V})(s.PureComponent),a.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},a}var H8=function(t,a){t.children,t.direction,t.height,t.layout,t.innerTagName,t.outerTagName,t.width,a.instance},V8=z8({getItemOffset:function(t,a){return a*t.itemSize},getItemSize:function(t,a){return t.itemSize},getEstimatedTotalSize:function(t){var a=t.itemCount;return t.itemSize*a},getOffsetForIndexAndAlignment:function(t,a,u,v,O,A){var I=t.direction,N=t.height,T=t.itemCount,C=t.itemSize,X=t.layout,V=t.width,$=I==="horizontal"||X==="horizontal"?V:N,q=Math.max(0,T*C-$),H=Math.min(q,a*C),G=Math.max(0,a*C-$+C+A);switch(u==="smart"&&(u=v>=G-$&&v<=H+$?"auto":"center"),u){case"start":return H;case"end":return G;case"center":var Q=Math.round(G+(H-G)/2);return Q<Math.ceil($/2)?0:Q>q+Math.floor($/2)?q:Q;default:return v>=G&&v<=H?v:v<G?G:H}},getStartIndexForOffset:function(t,a){var u=t.itemCount,v=t.itemSize;return Math.max(0,Math.min(u-1,Math.floor(a/v)))},getStopIndexForStartIndex:function(t,a,u){var v=t.direction,O=t.height,A=t.itemCount,I=t.itemSize,N=t.layout,T=t.width,C=a*I,X=v==="horizontal"||N==="horizontal"?T:O,V=Math.ceil((X+u-C)/I);return Math.max(0,Math.min(A-1,a+V-1))},initInstanceProps:function(t){},validateProps:function(t){t.itemSize}});function PN(t,a){(a==null||a>t.length)&&(a=t.length);for(var u=0,v=new Array(a);u<a;u++)v[u]=t[u];return v}for(var U8=[],bu=0;bu<1e4;bu+=1)U8.push({value:bu,label:"Option ".concat(bu)});const W8=function(t){var a=t.options,u=t.children,v=t.maxHeight,O=(function(I,N){return(function(T){if(Array.isArray(T))return T})(I)||(function(T,C){var X=T==null?null:typeof Symbol<"u"&&T[Symbol.iterator]||T["@@iterator"];if(X!=null){var V,$,q,H,G=[],Q=!0,ie=!1;try{if(q=(X=X.call(T)).next,C!==0)for(;!(Q=(V=q.call(X)).done)&&(G.push(V.value),G.length!==C);Q=!0);}catch(ue){ie=!0,$=ue}finally{try{if(!Q&&X.return!=null&&(H=X.return(),Object(H)!==H))return}finally{if(ie)throw $}}return G}})(I,N)||(function(T,C){if(T){if(typeof T=="string")return PN(T,C);var X=Object.prototype.toString.call(T).slice(8,-1);return X==="Object"&&T.constructor&&(X=T.constructor.name),X==="Map"||X==="Set"?Array.from(T):X==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(X)?PN(T,C):void 0}})(I,N)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
134
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()})((0,t.getValue)(),1)[0],A=35*a.indexOf(O);return b().createElement(V8,{height:v,itemCount:u.length,itemSize:35,initialScrollOffset:A},(function(I){var N=I.index,T=I.style;return b().createElement("div",{style:T},u[N])}))};var wu=d(970),Ai={};function Qa(t){return Qa=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Qa(t)}Ai.styleTagTransform=xa(),Ai.setAttributes=ba(),Ai.insert=ya().bind(null,"head"),Ai.domAPI=va(),Ai.insertStyleElement=wa(),ga()(wu.Z,Ai),wu.Z&&wu.Z.locals&&wu.Z.locals;var G8=["invalid","disabled","pending","wrapperClassName","wrapperStyle","optimizeMenuList","components"];function iy(){return iy=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},iy.apply(this,arguments)}function IN(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function Mo(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?IN(Object(u),!0).forEach((function(v){K8(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):IN(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function K8(t,a,u){return a=(function(v){var O=(function(A,I){if(Qa(A)!=="object"||A===null)return A;var N=A[Symbol.toPrimitive];if(N!==void 0){var T=N.call(A,"string");if(Qa(T)!=="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(A)})(v);return Qa(O)==="symbol"?O:String(O)})(a),a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}var MN=function(t){var a=t.invalid,u=t.disabled,v=t.pending,O=t.wrapperClassName,A=t.wrapperStyle,I=t.optimizeMenuList,N=t.components,T=Mo(Mo({},(function(X,V){if(X==null)return{};var $,q,H=(function(Q,ie){if(Q==null)return{};var ue,fe,me={},ve=Object.keys(Q);for(fe=0;fe<ve.length;fe++)ue=ve[fe],ie.indexOf(ue)>=0||(me[ue]=Q[ue]);return me})(X,V);if(Object.getOwnPropertySymbols){var G=Object.getOwnPropertySymbols(X);for(q=0;q<G.length;q++)$=G[q],V.indexOf($)>=0||Object.prototype.propertyIsEnumerable.call(X,$)&&(H[$]=X[$])}return H})(t,G8)),{},{isLoading:v,isDisabled:u,classNamePrefix:"hise-select",styles:{menuPortal:function(X){return Mo(Mo({},X),{},{zIndex:9999})},menu:function(X){return Mo(Mo({},X),{},{zIndex:9999})}}}),C=Mo({},N);return I&&(C.MenuList=W8),b().createElement("div",{className:x()("hise-select__wrapper",O,{invalid:a}),style:A},b().createElement(B8,iy({},T,{components:C})))};MN.defaultProps={invalid:!1,disabled:!1,pending:!1,wrapperClassName:"",wrapperStyle:{}};const jN=MN;function Ja(t){return Ja=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(a){return typeof a}:function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},Ja(t)}function xu(){return xu=Object.assign?Object.assign.bind():function(t){for(var a=1;a<arguments.length;a++){var u=arguments[a];for(var v in u)Object.prototype.hasOwnProperty.call(u,v)&&(t[v]=u[v])}return t},xu.apply(this,arguments)}function Ni(t){return(function(a){if(Array.isArray(a))return sy(a)})(t)||(function(a){if(typeof Symbol<"u"&&a[Symbol.iterator]!=null||a["@@iterator"]!=null)return Array.from(a)})(t)||LN(t)||(function(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
135
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function ay(t,a){return(function(u){if(Array.isArray(u))return u})(t)||(function(u,v){var O=u==null?null:typeof Symbol<"u"&&u[Symbol.iterator]||u["@@iterator"];if(O!=null){var A,I,N,T,C=[],X=!0,V=!1;try{if(N=(O=O.call(u)).next,v!==0)for(;!(X=(A=N.call(O)).done)&&(C.push(A.value),C.length!==v);X=!0);}catch($){V=!0,I=$}finally{try{if(!X&&O.return!=null&&(T=O.return(),Object(T)!==T))return}finally{if(V)throw I}}return C}})(t,a)||LN(t,a)||(function(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
136
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function LN(t,a){if(t){if(typeof t=="string")return sy(t,a);var u=Object.prototype.toString.call(t).slice(8,-1);return u==="Object"&&t.constructor&&(u=t.constructor.name),u==="Map"||u==="Set"?Array.from(t):u==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(u)?sy(t,a):void 0}}function sy(t,a){(a==null||a>t.length)&&(a=t.length);for(var u=0,v=new Array(a);u<a;u++)v[u]=t[u];return v}function DN(t,a){var u=Object.keys(t);if(Object.getOwnPropertySymbols){var v=Object.getOwnPropertySymbols(t);a&&(v=v.filter((function(O){return Object.getOwnPropertyDescriptor(t,O).enumerable}))),u.push.apply(u,v)}return u}function Tn(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?DN(Object(u),!0).forEach((function(v){_u(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):DN(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function _u(t,a,u){return a=(function(v){var O=(function(A,I){if(Ja(A)!=="object"||A===null)return A;var N=A[Symbol.toPrimitive];if(N!==void 0){var T=N.call(A,"string");if(Ja(T)!=="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(A)})(v);return Ja(O)==="symbol"?O:String(O)})(a),a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}var Y8={type:"",label:"",key:"",placeholder:"",invalid:function(){return!1},disabled:function(){return!1},options:{},disableOptionFn:function(){return!1},disableOptionText:function(){return null},pending:!1,isMulti:!1,component:null,style:{},className:"col-12",additionalInputParams:{},optimizeMenuList:!1},X8=function(t){var a=t.c,u=t.editedResource,v=t.onChange,O=t.setEntireResource;return s.createElement("div",{className:a.className,style:a.style,key:a.key,id:a.key},a.label,a.component({value:PF(u[a.key]),initialState:Tn({},u),editedResource:u,onChange:function(A){return v(a.key,A)},setEntireResource:function(A){return O(A)}}),a.invalid(u)&&s.createElement("span",{className:"invalid-feedback d-block"},a.invalidMessage))},Z8=function(t){var a=t.c,u=t.editedResource,v=t.onChange;return s.createElement("div",{className:a.className,style:a.style,key:a.key,id:a.key},a.label,s.createElement("div",{className:"text-nowrap"},Object.keys(a.options).map((function(O){return s.createElement(ti,{key:O,className:"btn-sm",color:O===u[a.key]?"primary":"secondary",onClick:function(){return v(a.key,O)},disabled:a.disabled(u)},a.options[O])}))))},Su=function(t,a){if(!a.groupOptionsBy)return t;var u=qF((function(v){return v[a.groupOptionsBy]}))(t);return Object.entries(u).map((function(v){var O=ay(v,2);return{label:O[0],options:O[1]}}))},Q8=function(t){var a=Tn(Tn({},t),{},{data:t.data});return s.createElement($A.Option,a,s.createElement("div",null,t.data.label),t.data.description&&s.createElement("small",null,t.data.description))},J8=function(t){var a,u=t.c,v=t.editedResource,O=t.onChange,A={};u.advancedOptions?(a=u.advancedOptions,A.Option=Q8):a=Object.keys(u.options).map((function(N){return{value:N,label:u.options[N]}}));var I=u.isMulti?s.createElement(s.Fragment,null,!u.hideAddAll&&!u.disabled(v)&&s.createElement(EA,{className:"ml-2 mb-1 btn-sm",onClick:function(){return O(u.key,a.map((function(N){return N.value})))}},"Add All"),s.createElement(jN,{value:v[u.key]?v[u.key].map((function(N){return iu(au("value",String(N)))(a)})):[],options:Su(a,u),placeholder:u.placeholder,onChange:function(N){return O(u.key,(N||[]).map((function(T){return T.value})))},invalid:u.invalid(v),invalidMessage:u.invalidMessage,disabled:u.disabled(v),closeMenuOnSelect:u.closeMenuOnSelect,pending:u.pending,components:A,isMulti:!0})):s.createElement(jN,{value:iu(au("value",String(v[u.key])))(a),options:Su(a,u),placeholder:u.placeholder,onChange:function(N){return O(u.key,N.value)},invalid:u.invalid(v),invalidMessage:u.invalidMessage,disabled:u.disabled(v),closeMenuOnSelect:u.closeMenuOnSelect,pending:u.pending,components:A});return s.createElement("label",{className:u.className,style:u.style,key:u.key,id:u.key},u.label,I,s.createElement(Oi,{invalid:u.invalid(v),style:{display:"none"}}),s.createElement(Ga,null,u.invalidMessage))},BN=function(t){var a,u=t.c,v=t.editedResource,O=t.onChange;a=u.advancedOptions?u.advancedOptions:Object.keys(u.options).map((function(H){return{value:H,label:u.options[H]}}));var A=v[u.key],I=ay(s.useState([]),2),N=I[0],T=I[1],C=[].concat(Ni(a),Ni(N));s.useEffect((function(){if(A){var H=C.map((function(G){return G.value}));if(u.isMulti)A.forEach((function(G){H.includes(G)||T([].concat(Ni(N),[{value:G,label:G}]))}));else{if(H.includes(A))return;T([].concat(Ni(N),[{value:A,label:A}]))}}}),[u.options]);var X,V=function(H){Tv(H)||_A(H)||Tv(H.value)||_A(H.value)||(O(u.key,H.value),C.map((function(G){return G.value})).includes(H.value)||u.invalid(Tn(Tn({},v),{},_u({},u.key,H.value)))||T([].concat(Ni(N),[{value:H.value,label:H.value}])))},$=function(H){if(!Tv(H)&&H&&typeof H!="string"){var G=H.map((function(ie){return ie.value}));O(u.key,G);var Q=C.map((function(ie){return ie.value}));G.forEach((function(ie){Q.includes(ie)||u.invalid(Tn(Tn({},v),{},_u({},u.key,ie)))||T([].concat(Ni(N),[{value:ie,label:ie}]))}))}},q=u.isMulti?s.createElement(s.Fragment,null,!u.hideAddAll&&!u.disabled(v)&&s.createElement(EA,{className:"ml-2 mb-1 btn-sm",onClick:function(){return O(u.key,a.map((function(H){return H.value})))}},"Add All"),s.createElement(kN,{value:(A||[]).map((function(H){return iu(au("value",H))(C)})),isMulti:u.isMulti,onChange:function(H){return $(H)},onInputChange:function(H){return $(H)},options:Su(C,u),pending:u.pending,placeholder:u.placeholder})):s.createElement(kN,{value:{value:A,label:(X=iu(au("value",A))(C),X&&X.label?X.label:"")},onChange:function(H){return V(H)},onInputChange:function(H){return V(H)},options:Su(C,u),pending:u.pending,isValidNewOption:function(H,G,Q){return!Q.find((function(ie){return ie.value===H}))},placeholder:u.placeholder});return s.createElement("label",{className:u.className,style:u.style,form:!0,key:u.key,id:u.key},u.label,q,s.createElement(Oi,{invalid:u.invalid(v),style:{display:"none"}}),s.createElement(Ga,null,u.invalidMessage))},$8=function(t){var a=t.c,u=t.editedResource,v=t.onChange,O=usePromise(a.optionsPromise,{});return s.createElement(BN,{c:Tn(Tn({},a),{},{options:O.response}),editedResource:u,onChange:v,pending:O.loading})},eq=function(t){var a=t.c,u=t.editedResource,v=t.onChange;return s.createElement("label",{className:"".concat(a.className," ml-4"),style:a.style,key:a.key,id:a.key},s.createElement(Oi,{type:a.type,checked:u[a.key]==="true"?"true":"",onChange:function(O){return v(a.key,O.target.checked.toString())},disabled:a.disabled(u)}),a.label,s.createElement(Ga,null,a.invalidMessage))},tq=function(t){var a=t.c,u=(t.editedResource,t.onChange);return s.createElement("div",{className:"".concat(a.className),style:a.style,key:a.key,id:a.key},a.label,Object.entries(a.options).map((function(v){var O=ay(v,2),A=O[0],I=O[1];return s.createElement("label",{key:A,className:"d-block ml-4"},s.createElement(Oi,{type:"radio",value:A,name:a.key,onChange:function(N){return u(a.key,A)},defaultChecked:a.default===A?"checked":""}),I)})))},nq=function(t){var a=t.c,u=t.editedResource,v=t.onChange;return s.createElement("label",{className:a.className,style:a.style,key:a.key,id:a.key},a.label,s.createElement(Oi,{type:a.type,value:u[a.key],onChange:function(O){return v(a.key,O.target.value)},placeholder:a.placeholder,invalid:a.invalid(u),disabled:a.disabled(u)}),s.createElement(Ga,null,a.invalidMessage))},rq=function(t){var a=t.c,u=t.editedResource,v=t.onChange;return s.createElement("label",{className:a.className,style:a.style,key:a.key,id:a.key},a.label,s.createElement(Oi,xu({type:a.type,onChange:function(O){return v(a.key,O.target.files)},invalid:a.invalid(u),disabled:a.disabled(u)},a.additionalInputParams)),s.createElement(Ga,null,a.invalidMessage))},FN=function(t){var a=t.editedResource,u=function(O,A){t.onChange(Tn(Tn({},a),{},_u({},O,A)))},v=t.controls.filter(Boolean).map((function(O){return(function(A,I,N,T){var C=Tn(Tn({},Y8),A),X={c:C,editedResource:I,onChange:N};return C.hidden&&C.hidden(I)?null:C.type==="custom"?s.createElement(X8,xu({},X,{setEntireResource:T})):C.type==="toggle"?s.createElement(Z8,X):C.type==="select"?s.createElement(J8,X):C.type==="creatableSelect"?s.createElement(BN,X):C.type==="promiseCreatableSelect"?s.createElement($8,X):C.type==="checkbox"?s.createElement(eq,X):C.type==="radio"?s.createElement(tq,X):C.type==="file"?s.createElement(rq,X):s.createElement(nq,X)})(O,a,u,t.onChange)}));return s.createElement("section",{className:"resource-editor-controls ".concat(t.className),style:t.style},t.viewOnlyControls&&s.createElement("ul",{className:"list-unstyled"},t.viewOnlyControls.map((function(O){return s.createElement("li",null,s.createElement("strong",{className:"mr-2"},O.key,":")," ",a[O.key])}))),v)};FN.defaultProps={className:"row",style:{},viewOnlyControls:[]}})(),p})()))})(mg)),mg.exports}var ht=T3();const mO=he.createContext(void 0),R3=({config:e,children:n})=>K.jsx(mO.Provider,{value:{config:e},children:n}),Rr=()=>{const e=he.useContext(mO);if(!e)throw new Error('useHiseConfig must be used within a HiseConfigProvider. Please wrap your component tree with <HiseConfigProvider config={{ apiRoute: "..." }}>.');return e.config},gO=async(e,n,r)=>await fetch(`${r}/collaboration/replica/copyFileReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:n,certificateType:"Public"})}),P3=e=>{const[n,r]=he.useState(!1);return e.type!=="fileLayerNode"||!e.isNodeHover?null:K.jsx("div",{className:"position-absolute",style:{right:0},children:K.jsx("span",{className:`badge rounded-pill text-white ${n?"bg-primary":"bg-secondary"}`,style:{fontSize:"1.35rem",marginTop:"0.75rem"},onMouseEnter:()=>r(!0),onMouseLeave:()=>r(!1),onClick:()=>{e.toggle&&e.toggle()},children:"COPY"})})},I3=e=>{const[n,r]=he.useState(!1),o=()=>r(!n);return e.type!=="fileLayerNode"?null:K.jsxs(K.Fragment,{children:[K.jsx(ht.Button,{id:"copy-filelayer-btn",className:"btn-sm",onClick:()=>o(),children:"Copy File Set"}),K.jsx(vO,{...e,isOpen:n,toggle:o})]})},vO=({vertexId:e,certificateId:n,refresh:r,isOpen:o,toggle:i})=>{const{apiRoute:l}=Rr(),[c,f]=he.useState(!1),m=async()=>{f(!0);try{await gO(e,n,l).then(async g=>{if(g.ok)r&&r(),ct.success("Copied file into workspace.");else{const d=await g.json();ct.error("Unable to copy file: "+d.Message)}i()})}catch(g){console.log(g)}f(!1)};return K.jsx(ht.ConfirmationModal,{id:"copy-filelayer-modal",className:"top-25",pending:c,isOpen:o,onClose:i,headerContent:"Do you want to copy all files in this file set into your workspace?",cancelButtonText:"Close",onSubmit:()=>m()})},M3=()=>{const{node:e,setNode:n,certificate:r,type:o,nodeLayers:i,setNodeLayers:l}=Ot();if(!i.previous.nodes.length)return null;const c=()=>{l({previous:{nodes:[],edges:[]},current:i.previous}),n({})};return K.jsxs("div",{className:"position-absolute ml-4 mt-3",style:{zIndex:1},children:[K.jsx(ht.Button,{id:"layer-back-button",onClick:c,icon:"fas fa-long-arrow-alt-left",children:"Back"}),K.jsx("span",{id:"subgraph-msg",className:"ml-3 me-3 mr-3 ms-3 font-italic fst-italic fw-bold font-weight-bold",children:"Currently viewing subgraph of a file set"}),K.jsx(I3,{vertexId:e.id,certificateId:r.id,type:o,refresh:e.data?.refresh})]})},j3=(e,n)=>{const r={backgroundColor:"white",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px"};switch(e){case"FileSet":case"Visualization":r.backgroundColor="yellow";break;case"File":case"IDE":r.borderColor="lightblue",n&&(r.borderColor="orange");break;default:r.borderColor="#BBBBBB";break}return r},L3=e=>({type:"text",key:"restrictionNotes",label:"Restriction Notes - Internal",invalid:r=>r.restrictionNotes.length<1}),D3=(e,n)=>Object.keys(n).filter(o=>o!==e).reduce((o,i)=>(o[i]=n[i],o),{}),B3=(e,n,r)=>{switch(e){case"reviewNode":return j3(n,r);case"readNode":case"editNode":default:return gg(n)}},al=(e,n,r,o,i)=>{const l=F3(e,r,o,i),c=q3(n);return wO(l,c)},F3=(e,n,r,o)=>{const i={x:0,y:0},l=[];return $t(e)||cr(e)||e.forEach(c=>{const f=c.split("/")[0],m=n&&!!n[c];l.push({id:c,position:i,type:f!=="FileLayer"?r:"fileLayerNode",data:o??{},style:B3(r,f,m)})}),l},q3=e=>Object.entries(e||{}).reduce((n,[r,o])=>[...n,...o.map(i=>({id:`${r}-${i}`,source:r,target:i,type:"smoothstep",animated:!0}))],[]),yO=250,bO=75,wO=(e,n,r="LR")=>{const o=new Wi.graphlib.Graph;o.setDefaultEdgeLabel(()=>({}));const i=r==="LR";return o.setGraph({nodesep:70,ranksep:110,rankdir:r}),e.forEach(l=>{o.setNode(l.id,{width:yO,height:bO})}),n.forEach(l=>{o.setEdge(l.source,l.target)}),Wi.layout(o),e.forEach(l=>{const c=o.node(l.id);return l.targetPosition=i?Be.Left:Be.Top,l.sourcePosition=i?Be.Right:Be.Bottom,l.position={x:c.x-yO/2,y:c.y-bO/2},l}),{nodes:e,edges:n}},gg=e=>{const n={backgroundColor:"white",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px"};switch(e){case"FileSet":case"Visualization":n.backgroundColor="yellow";break;case"IngestReceipt":n.borderColor="#EE7733";break;case"FileLayer":case"File":n.borderColor="#33BBEE";break;case"IDE":n.borderColor="#882255";break;case"Pipeline":n.borderColor="#F283EB";break;case"Process":n.borderColor="#009988";break;case"Trace":n.borderColor="#999933";break;case"Specimen":case"Sample":case"Subject":case"Cohort":n.borderColor="#BBBBBB";break;case"Submission":n.borderColor="#285222";break;case"Certificate":case"DirectUpload":n.borderColor="#F78383";break;default:n.borderColor="#eee";break}return n},xO=(e,n,r,o)=>{const i={};if(!["Sample","Subject"].includes(e)||!r||!o)return i;const l=r[n];return l&&Object.entries(l).forEach(([c,f])=>{c==="Survey Data Scheme Key"&&(i.surveyData=o[f]),c==="EMR Scheme Key"&&(i.emrData=o[f]),c==="Lab Data Scheme Key"&&(i.labData=o[f])}),i},z3=(e,n)=>{if(!n)return e;switch(e){case"FileSet":return K.jsxs(K.Fragment,{children:["Data Set",K.jsx("br",{}),`(${n.Title})`]});case"Visualization":return K.jsxs(K.Fragment,{children:[e,K.jsx("br",{}),`(${n.Title})`]});case"IngestReceipt":return"Data Ingested";case"DirectUpload":return"Data Directly Uploaded";case"FileLayer":return"File Set";case"File":return`.${n["File Extension"]} ${e}`;case"Process":case"Subject":case"IDE":case"Trace":case"Specimen":case"Sample":case"Cohort":case"Pipeline":case"Submission":case"Certificate":default:return e}},H3=(e,n)=>{if(!n)return null;switch(e){case"Cohort":case"FileSet":case"IDE":case"IngestReceipt":case"Pipeline":case"Subject":case"Submission":case"Trace":case"Visualization":return n.Description;case"Sample":return n["Visit Name"];case"Specimen":return n["Specimen Type"];case"File":return K.jsxs(K.Fragment,{children:[n["File Type"]&&K.jsxs(K.Fragment,{children:[n["File Type"],K.jsx("br",{})]}),K.jsx("span",{className:"font-italic",children:n["File Size"]}),K.jsx("br",{}),n["File Availability"]&&K.jsx("span",{className:"badge rounded-pill bg-secondary p-1 ps-2 fs-6 text-white",children:n["File Availability"]})]});case"Process":return n.Type;case"FileLayer":default:return null}},_O=(e,n,r)=>{if(r==="false")return null;switch(e){case"Visualization":return`/collaboration/visualization/${n}`;case"IngestReceipt":return`/ingest-receipts/${n}`;case"File":return`/files/${n}`;case"Process":return`/processes/${n}`;case"Sample":return`/samples/${n}`;case"Subject":return`/subjects/${n}`;case"Cohort":return`/cohorts/${n}`;case"Pipeline":return`/pipelines/${n}`;case"Submission":return`/submissions/${n}`;case"FileLayer":default:return null}},SO=(e,n,r)=>{if(!n)return e;if(r==="demographicsData")return`${e[0].toUpperCase()}${e.split(/(?=[A-Z])/).join(" ").slice(1)}`;const o=n[e];return o&&o.friendlyName?o.friendlyName:e},EO=(e,n,r,o)=>{if(!r)return n;const i=r[e];return!i||o==="demographicsData"?n:i.units?`${n} ${i.units}`:n},OO=({entries:e,scheme:n,tab:r})=>K.jsx("table",{className:"table",children:K.jsx("tbody",{children:e.map(([o,i])=>K.jsxs("tr",{children:[K.jsx("th",{scope:"row",children:SO(o,n,r)}),K.jsx("td",{children:EO(o,i,n,r)})]},o))})}),V3=({activeEntry:e,setActiveEntry:n,emrData:r})=>K.jsx("div",{className:"text-center",children:K.jsxs("div",{className:"btn-group mb-3",children:[K.jsxs("button",{className:"btn btn-secondary dropdown-toggle",type:"button","data-bs-toggle":"dropdown","aria-expanded":"false",children:["Visit Day ",e]}),K.jsx("ul",{className:"dropdown-menu",children:r.map(o=>K.jsx("li",{children:K.jsxs("button",{type:"button",className:"dropdown-item",onClick:()=>n(o.daysSinceFirstResearchVisit),children:["Visit Day ",o.daysSinceFirstResearchVisit]})},o.daysSinceFirstResearchVisit))})]})}),U3=({emrData:e,scheme:n})=>{const[r,o]=he.useState(e[0].daysSinceFirstResearchVisit),i=Object.values(e),l=i.reduce((f,m)=>({...f,[m.daysSinceFirstResearchVisit]:m}),{}),c=Object.entries(l[r].patientData);return K.jsxs(K.Fragment,{children:[K.jsx(V3,{activeEntry:r,setActiveEntry:o,emrData:i}),K.jsx(OO,{entries:c,scheme:n,tab:"emrData"})]})},W3=({metadata:e,scheme:n,activeTab:r})=>{const o=e[r],i=n[r],l=Object.entries(o||{});return r==="emrData"?K.jsx(U3,{emrData:o,scheme:i}):K.jsx(OO,{entries:l,scheme:i,tab:r})},G3=(e,n)=>n&&e==="Sample"?`${e} (${n["Visit Name"]})`:e,K3=e=>{const n=[],r=Object.keys(e);return r.length&&r.forEach(o=>{const l=e[o];$t(l)||n.push(o)}),n},kO=(e,n)=>{const r=e[n];return!(cr(r)||$t(r)||Object.values(r).every(l=>$t(l)))},Y3=({tabs:e,activeTab:n,setActiveTab:r})=>K.jsx("ul",{className:"nav justify-content-center",children:e.map(o=>K.jsx("li",{className:"nav-item",children:K.jsx("button",{type:"button",className:`nav-link btn btn-link ${n===o&&"font-weight-bold"}`,onClick:()=>r(o),children:o.split(/(?=[A-Z])/).join(" ").toUpperCase()})},o))}),CO=({label:e,node:n})=>{const{certificate:r,setNode:o}=Ot();if(!["Sample","Subject"].includes(e))return null;const{metadata:i}=r,{toggleMetadataModal:l}=n.data;return!kO(i,n.id)||!l?null:K.jsx(ht.Button,{id:"metadata-btn",color:"link",className:"p-0",style:{lineHeight:"normal"},onClick:()=>{l(),o(n)},children:K.jsx("span",{style:{fontSize:"1.75rem"},children:"≡"})},"metadata-btn")},vg=({isOpen:e,toggle:n})=>{const{node:r,certificate:o}=Ot(),{id:i}=r,{metadata:l,schemes:c,serviceLabels:f,customLabels:m,generatedLabels:g}=o,[d,p]=he.useState({}),[h,s]=he.useState({}),[S,b]=he.useState({activeTab:"",description:"",header:"",tabs:[]});he.useEffect(()=>{if(!e||$t(l)||$t(r))return;const w=l[r.id],y=i?.split("/")[0],E=m[i]||g[i],x=G3(y,E),k=K3(w),P=xO(y,i,f,c);p(w),s(P),b(R=>({...R,activeTab:k[0],description:E,header:x,tabs:k}))},[e,r,l]);const _=w=>b(y=>({...y,activeTab:w}));return K.jsx(ht.ConfirmationModal,{scrollable:!0,isOpen:e,onClose:n,headerContent:S.header,noSubmit:!0,cancelButtonText:"Close",content:K.jsxs(K.Fragment,{children:[K.jsx(Y3,{tabs:S.tabs,activeTab:S.activeTab,setActiveTab:_}),K.jsx("div",{className:"mt-2",children:K.jsx(W3,{metadata:d,scheme:h,activeTab:S.activeTab})})]})})},Jr=({label:e,description:n})=>{const r=H3(e,n);return!r||!Object.keys(n).length?null:K.jsx("div",{className:"node-description text-center text-break",children:r})},Pr=({label:e,description:n,link:r})=>{const o=z3(e,n);return r?K.jsx("a",{href:`#${r}`,target:"_blank",rel:"noreferrer",className:"node-label text-break flex-fill",children:e}):K.jsx("div",{className:"node-label text-break flex-fill",children:o})},sl=e=>{const{id:n}=e,{customLabels:r,generatedLabels:o}=Ot().certificate,i=n.split("/")[0],l=r?.[n]||o?.[n];return K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsxs("div",{className:"d-flex align-items-center",children:[K.jsx(Pr,{label:i,description:l}),K.jsx(CO,{label:i,node:e})]}),K.jsx(Jr,{label:i,description:l})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},X3=e=>e==="Pipeline"?"workspacePipelineNode":e==="IDE"?"workspaceIDENode":e==="File"?"workspaceFileNode":e==="FileLayer"?"fileLayerNode":"readNode",Z3=(e,n)=>{if(!n){const r={backgroundColor:"white",color:"#BBBBBB",borderRadius:"3px",borderStyle:"solid",borderWidth:"6px",borderColor:"#eee"};return e==="FileLayer"?{...r,borderWidth:"6px",borderColor:"#36454F",color:"#36454F"}:r}return gg(e)},Q3=(e,n,r)=>{const o={x:0,y:0},i=[];return!e||!Object.keys(e).length||e.forEach(l=>{const c=l.split("/")[0],f=n.matches[l];i.push({id:l,position:o,type:X3(c),data:r,style:Z3(c,f)})}),i},J3=e=>{if(!e||$t(e))return[];const n=[],r=[];return Object.entries(e).forEach(([o,i])=>{i.forEach(l=>{n.push({id:`${o}-${l}`,source:o,target:l,type:"smoothstep",animated:!0}),r.push({id:`${o}-${l}-replica`,source:`${o}-replica`,target:`${l}-replica`,type:"smoothstep",animated:!0})})}),[...n,...r]},AO=(e,n,r,o)=>{const i=Q3(e,r,o),l=J3(n),{nodes:c,edges:f}=wO(i,l);return{nodes:c,edges:f}},NO=async(e,n,r)=>{const o=[];return Object.entries(n).forEach(([l,c])=>{c.includes(e)&&l.includes("File")&&!r[l]&&o.push(l)}),o},TO=async(e,n,r)=>{const o=[];for(const i of e){const l=await fetch(`${r}/collaboration/replica/copyFileReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:i,certificateGuid:n,certificateType:"Public"})});o.push(l)}return Promise.all(o)},$3=e=>{const{setNode:n,certificate:r,replica:o,nodesState:i,edgesState:l,type:c,nodeLayers:f,setNodeLayers:m}=Ot(),{customLabels:g,generatedLabels:d}=r,{data:p}=e,h=e.id.split("/")[0],s=g[e.id]||d[e.id],S=r.subgraphs[e.id],[b,_]=i,[w,y]=l,[E,x]=he.useState(!1),[k,P]=he.useState(!1),R=()=>P(!k),j=(L,M)=>c==="fileLayerNode"?AO(L,S.edges,o,M):al(L,S.edges,r.restrictedAssets,c,M),z=()=>{const L=Object.keys(S.vertices),M=j(L,p);_(M.nodes),y(M.edges),m({previous:f.current,current:{nodes:M.nodes,edges:M.edges}}),n(e)};return K.jsx(K.Fragment,{children:K.jsxs("div",{onMouseEnter:()=>x(!0),onMouseLeave:()=>x(!1),children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsx("div",{className:`p-2 ${E?"expand-hover":""}`,style:{width:"250px"},children:K.jsxs("div",{className:"d-flex align-items-center",onClick:z,children:[K.jsx(Pr,{label:h,description:s}),K.jsx("i",{className:"fas fa-expand-alt"})]})}),K.jsx(qt,{type:"source",position:Be.Right}),K.jsx(P3,{vertexId:e.id,certificateId:r.id,type:c,isNodeHover:E,toggle:R}),K.jsx(vO,{vertexId:e.id,certificateId:r.id,refresh:p.refresh,isOpen:k,toggle:R})]})})},e4=(e,n,r,o)=>{const i=B_([e],n[r]);o({...n,[r]:i})},t4=(e,n,r,o,i)=>{r({...n,emrData:[...n?.emrData?.slice(0,i),{...o,patientData:B_([e],o.patientData)},...n?.emrData?.slice(Number(i)+1)]})};var yg=(e=>(e.labData="labData",e.surveyData="surveyData",e.demographicsData="demographicsData",e.emrData="emrData",e))(yg||{});const n4=e=>{const n=()=>e.update({...e.currMetadata,[e.dataType]:{}});return K.jsx(ht.Button,{className:"mt-3 mb-2 float-right",onClick:n,children:`${RO[e.dataType]}: Mask All`})},r4=({children:e})=>K.jsxs("table",{className:"table",children:[K.jsx("thead",{children:K.jsxs("tr",{children:[K.jsx("th",{scope:"col"}),K.jsx("th",{scope:"col",children:"Variable"}),K.jsx("th",{scope:"col",children:"Value"})]})}),K.jsx("tbody",{children:e})]}),bg=({type:e,metadata:n,setMetadata:r,emrEntry:o,emrIndex:i,ingestUiProps:l})=>{let c;l&&l.schemes?c=l.schemes:c=Ot().certificate.schemes;const f=c[e],m=Object.entries(e!==yg.emrData?n[e]:o.patientData),g=p=>{e===yg.emrData?t4(p[0],n,r,o,i):e4(p[0],n,e,r)},d=()=>m.map(p=>K.jsxs("tr",{children:[K.jsx("td",{children:K.jsx(ht.Button,{icon:"fas fa-times",color:"link",className:"btn-sm text-danger",noText:!0,onClick:()=>g(p)},`${p}-mask-btn`)}),K.jsx("td",{children:SO(p[0],f,e)}),K.jsx("td",{children:EO(p[0],p[1],f,e)})]},p[0]));return K.jsxs(K.Fragment,{children:[K.jsx(n4,{dataType:e,currMetadata:n,update:r}),K.jsx(r4,{children:d()})]})};bg.defaultProps={emrEntry:null,emrIndex:null};const o4=({data:e,entry:n,setEntry:r})=>K.jsx("div",{className:"text-center mt-3",children:K.jsxs("div",{className:"dropdown",children:[K.jsxs("button",{className:"btn btn-secondary dropdown-toggle",type:"button",id:"emrDropdownBtn","data-bs-toggle":"dropdown","aria-expanded":"false",children:["Visit Day"," ",n.daysSinceFirstResearchVisit]}),K.jsx("ul",{className:"dropdown-menu","aria-labelledby":"emrDropdownBtn",children:Object.entries(e).map(([o,i])=>K.jsx("li",{children:K.jsxs("button",{type:"button",className:"dropdown-item",onClick:()=>r(o),children:["Visit Day"," ",i.daysSinceFirstResearchVisit]})},o))})]})}),i4=({type:e,metadata:n,setMetadata:r,ingestUiProps:o})=>{const i=n[e],[l,c]=he.useState(0);return!n||$t(n)||!i||$t(i)?null:K.jsxs(K.Fragment,{children:[K.jsx(o4,{data:i,entry:i[l],setEntry:c}),K.jsx(bg,{type:e,metadata:n,setMetadata:r,emrEntry:i[l],emrIndex:l,ingestUiProps:o})]})},RO={labData:"Lab Results",surveyData:"Survey Data",emrData:"EMR Data",demographicsData:"Demographics Data"},a4=({node:e})=>{const{certificate:n,setNode:r}=Ot(),{metadata:o}=n;return kO(o,e.id)?K.jsx(ht.Button,{id:"mask-btn",color:"link",className:"text-warning px-1 pt-0",onClick:()=>{e.data.toggleMaskModal(),r(e)},children:"MASK"},"mask-btn"):null},PO=({isOpen:e,loading:n,toggle:r,handleUpdate:o,refresh:i,ingestUiNode:l})=>{const{node:c,certificate:f}=l||Ot(),{setNode:m}=Ot(),{metadata:g,customLabels:d}=f,[p,h]=he.useState({}),[s,S]=he.useState("");he.useEffect(()=>{$t(g)||$t(c)||h(g[c.id])},[c,g]);const b=p?Object.keys(p):[],_=()=>{r(),m({}),S("")},w=()=>{const y={...f,metadata:{...g,[c.id]:p},customLabels:d};o(y).then(E=>{if(E.status===200){const{labelsId:x,metadataId:k}=E.data;r(),i(x,k),S("")}else S(E.data.Message)})};return K.jsx(ht.ConfirmationModal,{id:"mask-metadata-modal",scrollable:!0,isOpen:e,onClose:r,headerContent:"Mask Node Metadata",noSubmit:!0,noCancel:!0,content:K.jsxs(K.Fragment,{children:[s&&!n&&K.jsx(ht.MessageStripe,{message:s,color:"danger",dismissible:!1}),K.jsx(ht.HISETabs,{activeTab:b[0],tabs:b.map(y=>{const E=y,x=cr(p[E])||$t(p[E]);return{key:y,label:RO[y]||y,hideTab:x,content:y==="emrData"?K.jsx(i4,{type:E,metadata:p,setMetadata:h,ingestUiProps:{schemes:l?.certificate.schemes}}):K.jsx(bg,{type:E,metadata:p,setMetadata:h,ingestUiProps:{schemes:l?.certificate.schemes}})}})})]}),customFooter:K.jsxs("div",{className:"float-right",children:[n&&K.jsx("div",{className:"spinner-grow spinner-grow-sm text-warning",role:"status"}),K.jsx(ht.Button,{id:"cancel-btn",icon:"fas fa-times",noText:!0,className:"mx-2",onClick:_}),K.jsx(ht.Button,{id:"ok-btn",icon:"fas fa-check",color:"primary",onClick:w,children:"Update Metadata"})]})})},s4=(e,n)=>{if(!n)return null;switch(e){case"Cohort":case"IDE":case"IngestReceipt":case"Subject":case"Trace":return[{type:"text",key:"Description",label:"Description",invalid:r=>!r||r.length>50}];case"Sample":return Object.keys(n).map(r=>["Experiment Comments","Experiment Count","Type","Draw Date"].includes(r)?null:{type:"text",key:r,label:r,invalid:o=>!o||o.length>50});case"Specimen":return[{type:"text",key:"Specimen Type",label:"Specimen Type",invalid:r=>!r||r.length>50}];case"Process":return[{type:"text",key:"Type",label:"Description",invalid:r=>!r||r.length>50}];case"File":case"FileSet":case"Pipeline":case"Submission":case"Visualization":default:return Object.keys(n).map(r=>({type:"text",key:r,label:r,invalid:o=>!o||o.length>50}))}},l4=({node:e})=>{const{setNode:n}=Ot();return K.jsx(ht.Button,{id:"edit-btn",color:"link",className:"text-info px-1 pt-0 ml-2",onClick:()=>{e.data.toggleEditModal(),n(e)},children:"EDIT"},"edit-btn")},IO=({isOpen:e,loading:n,toggle:r,handleUpdate:o,refresh:i,ingestUiNode:l})=>{const{node:c,certificate:f}=l||Ot(),{customLabels:m,generatedLabels:g,metadata:d}=f,[p,h]=he.useState(""),[s,S]=he.useState({}),b=()=>S({});if(he.useEffect(()=>{if(!c?.id)return;const x=m[c.id]||g[c.id];x&&S(x)},[c.id]),!c?.id)return null;const _=c?.id.split("/")[0],w=x=>S(x),y=()=>{const x={...f,metadata:d,customLabels:{...m,[c.id]:s}};o(x).then(k=>{if(k.status===200){const{labelsId:P,metadataId:R}=k.data;r(),b(),i(P,R),h("")}else h(k.data.Message)})},E=()=>{r(),b(),h("")};return K.jsx(ht.ConfirmationModal,{scrollable:!0,isOpen:e,onClose:r,headerContent:"Edit Node Label",noSubmit:!0,noCancel:!0,content:K.jsxs(K.Fragment,{children:[p&&!n&&K.jsx(ht.MessageStripe,{message:p,color:"danger",dismissible:!1}),K.jsx(ht.ResourceEditor,{className:"",onChange:w,editedResource:s,controls:s4(_,s)})]}),customFooter:K.jsxs("div",{className:"float-right",children:[n&&K.jsx("div",{className:"spinner-grow spinner-grow-sm text-warning",role:"status"}),K.jsx(ht.Button,{id:"cancel-btn",icon:"fas fa-times",className:"mx-2",noText:!0,onClick:E}),K.jsx(ht.Button,{id:"ok-btn",icon:"fas fa-check",noText:!0,color:"primary",onClick:y})]})})},u4=e=>{const{customLabels:n,generatedLabels:r,isExecutable:o}=Ot().certificate,{id:i}=e,[l,c]=i.split("/"),f=n[i]||r[i],m=_O(l,c,o);return K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsxs("div",{className:"label",children:[K.jsx(Pr,{link:m,label:l,description:f}),K.jsx(l4,{node:e}),K.jsx(a4,{node:e})]}),K.jsx(Jr,{label:l,description:f})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},c4=({node:e})=>{const{setNode:n}=Ot(),{toggleReviewModal:r}=e.data,o=e.id.split("/")[0];return["File","IDE"].includes(o)?K.jsx(ht.Button,{id:"review-node-btn",color:"link",className:"text-info px-1 pt-0 ml-2",icon:"fa-edit",noText:!0,onClick:()=>{r(),n(e)}},"review-node-btn"):null},f4=e=>{const{certificate:n}=Ot(),{id:r}=e,[o,i]=r.split("/"),l=n.customLabels[r]||n.generatedLabels[r],c=_O(o,i,n.isExecutable);return K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsxs("div",{className:"d-flex align-items-center",children:[K.jsx(Pr,{link:c,label:o,description:l}),K.jsx(c4,{node:e}),K.jsx(CO,{label:o,node:e})]}),K.jsx(Jr,{label:o,description:l})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},wg=e=>{const{certificate:n,replica:r}=Ot(),{customLabels:o,generatedLabels:i}=n,[l,c]=he.useState(!1),f=e.id.split("/")[0],m=o[e.id]||i[e.id],g=r.matches[e.id];return K.jsxs(K.Fragment,{children:[e.modal,K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:`p-2 text-center ${l&&!g?"action-hover":""}`,style:{width:"250px"},onMouseEnter:()=>c(!0),onMouseLeave:()=>c(!1),onClick:()=>g?{}:e.toggle(),children:[K.jsx(Pr,{label:f,description:m}),K.jsx(Jr,{label:f,description:m})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},d4=e=>{const{isOpen:n,toggle:r,restrictedAsset:o}=e;if(!o)return null;const i=()=>{const l={restrictionInstructions:"Instructions for Retrieval",restrictionNotes:"Restriction Notes"};return K.jsxs(K.Fragment,{children:[K.jsx("h6",{children:l.restrictionNotes}),K.jsx("p",{children:o.restrictionNotes}),K.jsx("h6",{children:l.restrictionInstructions}),K.jsx("div",{dangerouslySetInnerHTML:{__html:o.restrictionInstructions}})]})};return K.jsx(ht.ConfirmationModal,{id:"restricted-node-notes-modal",isOpen:n,onClose:r,headerContent:"This asset has been restricted.",cancelButtonText:"Close",noSubmit:!0,content:K.jsx(i,{})})},MO=e=>{const{restrictedAsset:n}=e,{certificate:r}=Ot(),{customLabels:o,generatedLabels:i}=r,[l,c]=he.useState(!1),f=()=>c(!l),m=e.id.split("/")[0],g=o[e.id]||i[e.id];return K.jsxs(K.Fragment,{children:[K.jsx(d4,{restrictedAsset:n,isOpen:l,toggle:f}),K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{style:{width:"250px"},onClick:f,children:[K.jsxs("div",{className:"label d-flex p-1",children:[K.jsx(Pr,{label:m,description:g}),K.jsx(ht.Button,{id:`${e.id}-restricted-btn`,className:"btn-sm text-warning btn-link",icon:"fas fa-lock",noText:!0,onClick:f})]}),K.jsx(Jr,{label:m,description:g})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},h4=e=>{const{apiRoute:n}=Rr(),{certificate:r}=Ot(),[o,i]=he.useState(!1),[l,c]=he.useState(!1),f=()=>c(!l),m=r.restrictedAssets&&r.restrictedAssets[e.id];if(m)return K.jsx(MO,{...e,restrictedAsset:m});const g=async()=>{i(!0);try{await gO(e.id,r.id,n).then(async d=>{if(d.ok)e.data.refresh(),ct.success("Copied file into workspace.");else{const p=await d.json();ct.error("Unable to copy file: "+p.Message)}f()})}catch(d){console.log(d)}i(!1)};return K.jsx(wg,{id:e.id,data:e.data,modal:K.jsx(ht.ConfirmationModal,{id:"copy-file-modal",pending:o,isOpen:l,onClose:f,headerContent:"Copy this file?",cancelButtonText:"Close",onSubmit:()=>g()}),toggle:f})};var pa=(e=>(e.Completed="Completed",e.Failure="Failure",e.Running="Running",e.Processing="Processing",e.Initiated="Initiated",e))(pa||{});const p4={Completed:"bg-success",Failure:"bg-danger text-white",Running:"bg-info text-white",Processing:"bg-info text-white",Initiated:"bg-info text-white"},m4=({pipeline:e,replicaPipelineOperation:n,refresh:r})=>{const{apiRoute:o}=Rr(),[i,l]=he.useState(!1),c=()=>l(!i);return cr(e)||$t(e)||e.status!==pa.Failure&&n.operationStatus!=="Errored"?null:K.jsxs(K.Fragment,{children:[K.jsx(ht.Button,{id:`retry-${e.id}-pipeline-btn`,color:"link",onClick:()=>{c()},children:"RETRY?"}),K.jsx(ht.ConfirmationModal,{id:`retry-${e.id}-pipeline-modal`,isOpen:i,onClose:c,headerContent:"Do you want to retry running this pipeline?",content:"Seems that the process ran into an error.",submitButtonText:"Retry",onSubmit:async()=>{fetch(`${o}/tracer/admin/pipeline/process/retry/${e.mainProcessID}`,{method:"POST",credentials:"include"}).then(async f=>{if(f.ok)ct.success("Successfully reinitiated pipeline run."),setTimeout(()=>r(),1500);else{const m=await f.json();ct.error("Unable to reinitiate pipeline run: "+m.Message)}}),c()}})]})},g4=({pipeline:e,refresh:n})=>{const{apiRoute:r}=Rr(),{certificate:o}=Ot(),[i,l]=he.useState(!1),c=()=>l(!i);return cr(e)||$t(e)||[pa.Failure,pa.Completed].includes(e.status)?null:K.jsxs(K.Fragment,{children:[K.jsx(ht.Button,{id:`stop-${e.id}-pipeline-btn`,color:"link",onClick:c,children:"STOP?"}),K.jsx(ht.ConfirmationModal,{id:`stop-${e.id}-pipeline-modal`,isOpen:i,onClose:c,headerContent:"Do you want to stop running this pipeline?",submitButtonText:"Stop Pipeline",onSubmit:async()=>{fetch(`${r}/collaboration/replica/stopPipelineReplica?projectGuid=${e.projectGuid}&overrideActiveRun=true`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e.id,certificateGuid:o.id,certificateType:"Public"})}).then(async f=>{if(f.ok)n(),ct.success("Successfully stopped this pipeline run.");else{const m=await f.json();ct.error("Unable to stop pipeline run: "+m.Message)}}),c()}})]})},v4=({status:e,replicaPipelineOperation:n,pipelineId:r})=>{const o=()=>{r&&window.open(`#/data-mgt/pipeline-dashboard/${r}`,"_blank")},i=n?.operationStatus=="Errored"?pa.Failure:e;return K.jsxs("section",{children:[K.jsxs("span",{className:`badge rounded-pill ${p4[i]}`,style:{fontSize:"1.25rem"},onClick:o,children:[i," ",K.jsx("i",{className:"fa-solid fa-plus"})]}),n?.operationStatus=="Errored"&&n?.failureMessage&&K.jsx("p",{className:"mt-3",children:K.jsx("small",{children:n.failureMessage})})]})},jO=({pipeline:e,replicaPipelineOperation:n,refresh:r})=>cr(e)||$t(e)?null:K.jsxs("div",{className:"text-center",children:[K.jsx(v4,{status:e.status,replicaPipelineOperation:n,pipelineId:e.id}),K.jsx(m4,{pipeline:e,replicaPipelineOperation:n,refresh:r}),K.jsx(g4,{pipeline:e,refresh:r})]}),y4=e=>{const{apiRoute:n}=Rr(),{replica:r,certificate:o}=Ot(),{customLabels:i,generatedLabels:l}=o,{refresh:c}=e.data,[f,m]=he.useState(null),g=e.id.split("/")[0],d=i[e.id]||l[e.id],p=e.id.replace("-replica",""),h=r?.matches[p],s=r.replicaOperations[h];return he.useEffect(()=>{h&&(async()=>{const b=h.replace("Pipeline/","");await fetch(`${n}/ledger/pipeline/${b}`,{method:"GET",credentials:"include"}).then(async _=>{if(_.ok){const w=await _.json();m(w)}})})()},[r,e.id,n]),K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsx(Pr,{label:g,description:d}),K.jsx(Jr,{label:g,description:d}),K.jsx(jO,{pipeline:f,replicaPipelineOperation:s,refresh:c})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},LO=({loading:e,isOpen:n,toggle:r,onStartPipeline:o})=>K.jsx(ht.ConfirmationModal,{id:"run-pipeline-modal",scrollable:!0,pending:e,isOpen:n,onClose:r,headerContent:"Run this pipeline?",content:"Running this pipeline will also copy any input files that haven't been pulled into your workspace yet.",cancelButtonText:"Close",onSubmit:()=>o()}),b4=async(e,n,r)=>await fetch(`${r}/collaboration/replica/runPipelineReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:n,certificateType:"Public"})}),DO=async(e,n,r,o,i,l,c)=>{const f=await NO(e,r,o);await TO(f,n,c).then(async g=>g.length?g.every(d=>d.ok):!0)?await b4(e,n,c).then(async g=>{if(g.ok)ct.success("Started pipeline.");else{const d=await g.json();ct.error("Unable to start pipeline: "+d.Message)}i(),l()}):(i(),ct.error("Unable to copy some of the necessary input files."))},w4=e=>{const{apiRoute:n}=Rr(),{certificate:r,replica:o}=Ot(),[i,l]=he.useState(!1),[c,f]=he.useState(!1),m=()=>f(!c);if(o.matches[e.id])return K.jsx(y4,{...e});const d=async()=>{l(!0);try{await DO(e.id,r.id,r.edges,o.matches,e.data.refresh,m,n)}catch(p){console.log(p)}l(!1)};return K.jsx(wg,{id:e.id,data:e.data,modal:K.jsx(LO,{loading:i,isOpen:c,toggle:m,onStartPipeline:d}),toggle:m})},x4=e=>{const{replica:n,certificate:r}=Ot(),{customLabels:o,generatedLabels:i}=r,l=e.id.split("/")[0],c=o[e.id]||i[e.id],f=e.id.replace("-replica",""),m=n?.matches[f],g=()=>{m&&window.open("#/ide-nextgen","_blank")};return K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},onClick:()=>g(),children:[K.jsx(Pr,{label:l,description:c}),K.jsx(Jr,{label:l,description:c}),K.jsx("section",{className:"text-center mt-2",children:K.jsxs("span",{className:"badge bg-primary text-white",children:["IDE LIST ",K.jsx("i",{className:"fas fa-external-link-alt"})]})})]}),K.jsx(qt,{type:"source",position:Be.Right})]})},BO=({loading:e,isOpen:n,toggle:r,onStartIDE:o})=>K.jsx(ht.ConfirmationModal,{id:"clone-ide-modal",className:"top-25",pending:e,isOpen:n,onClose:r,headerContent:"Do you want to clone the environment of the original IDE into your workspace?",cancelButtonText:"Close",onSubmit:()=>o()}),_4=async(e,n,r)=>await fetch(`${r}/collaboration/replica/cloneIdeReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:n,certificateType:"Public"})}),FO=async(e,n,r,o,i,l,c)=>{const f=await NO(e,r,o);await TO(f,n,c).then(async g=>g.length?g.every(d=>d.ok):!0)?await _4(e,n,c).then(async g=>{if(g.ok)ct.success("Started IDE.");else{const d=await g.json();ct.error("Unable to start IDE: "+d.Message)}i(),l()}):(i(),ct.error("Unable to copy some of the necessary input files."))},S4=e=>{const{apiRoute:n}=Rr(),{certificate:r,replica:o}=Ot(),[i,l]=he.useState(!1),[c,f]=he.useState(!1),m=()=>f(!c),g=r.restrictedAssets&&r.restrictedAssets[e.id];if(g)return K.jsx(MO,{...e,restrictedAsset:g});if(o.matches[e.id])return K.jsx(x4,{...e});const p=async()=>{l(!0);try{await FO(e.id,r.id,r.edges,o.matches,e.data.refresh,m,n)}catch(h){console.log(h)}l(!1)};return K.jsx(wg,{id:e.id,data:e.data,modal:K.jsx(BO,{loading:i,isOpen:c,toggle:m,onStartIDE:p}),toggle:m})},xg=250,_g=120,qO=(e,n,r="LR")=>{const o=new Wi.graphlib.Graph;return o.setDefaultEdgeLabel(()=>({})),o.setGraph({nodesep:70,ranksep:110,rankdir:r}),e.forEach(i=>{o.setNode(i.id,{width:xg,height:_g})}),n.forEach(i=>{o.setEdge(i.source,i.target)}),Wi.layout(o),e.forEach(i=>{const l=o.node(i.id);return i.targetPosition=r==="LR"?Be.Right:Be.Left,i.sourcePosition=r==="LR"?Be.Left:Be.Right,i.position={x:l.x-xg/2,y:l.y-_g/2},i}),{nodes:e,edges:n}},zO=(e,n,r,o=!0)=>{let i=[...e];return n.forEach(l=>{const c=e.find(m=>m.id===l),f=l.includes("Layer")?!r.subgraphs[l]:!1;if(!c)if(o&&f)i=i;else{const[m]=l.split("/"),g=r.customLabels?.[l]||r.generatedLabels?.[l],d={id:l,position:{x:0,y:0},type:"walkingNode",data:{description:g},style:gg(m)};i=[...i,d]}}),i},HO=(e,n)=>{let r=[...e];return Object.entries(n||{}).forEach(i=>{const[l,c]=i;c.map(f=>{if(!e.find(g=>g.id.match(l)&&g.id.match(f))){const g={id:`${l}-${f}`,source:l,target:f,animated:!0};r=[...r,g]}})}),r},E4=e=>{if(!e)return"";const[n,r]=e.split("/");switch(n){case"FileSet":return`/#/collaboration/filesets/${r}`;case"File":return`/#/files/${r}`;case"Visualization":return`/#/collaboration/visualizations/${r}`;case"IDE":return`/#/collaboration/ide/${r}`;case"IngestReceipt":return`/#/ingest-receipts/${r}`;case"Process":return`/#/processes/${r}`;case"Pipeline":return`/#/data-mgt/pipeline-dashboard/${r}`;case"Subject":return`/#/subjects/${r}`;case"Sample":return`/#/samples/${r}`;case"Cohort":return`/#/cohorts/${r}`;default:return""}},VO=({id:e})=>{const{apiRoute:n}=Rr(),r=Js(),{node:o,setNode:i,nodesState:l,edgesState:c,certificate:f,setNodeLayers:m}=Ot(),[g,d]=he.useState({label:"",description:"",isLayer:!1}),[p,h]=he.useState(!1),[s,S]=l,[b,_]=c,w=r.getNode(e);he.useEffect(()=>{const M=B=>{const U=B.match(/^(.*)Layer/);if(!U)return B;switch(U[1]){case"File":case"FileSet":case"IDE":case"Sample":case"Specimen":case"Visualization":return`${U[1]}s`;case"Process":return`${U[1]}es`;default:return"Items"}},D={description:w?.data?.description},F=e.split("/")[0];if(F.includes("Layer")){const B=Object.keys(f.subgraphs[e].vertices).length,U=M(F);d({...D,label:`${U} (${B})`,isLayer:!0})}else d({...D,label:F,isLayer:!1})},[w]);const y=async M=>{const D=M==="right"?`${n}/collaboration/neighbors?root=${e}&getDescendants=true`:`${n}/collaboration/neighbors?root=${e}&getAncestors=true`;await fetch(D,{method:"GET",credentials:"include"}).then(async F=>{if(F.ok){const B=await F.json(),{vertices:U,edges:J,customLabels:oe,generatedLabels:de}=B,Y=zO(s,U,{...f,customLabels:oe,generatedLabels:de},!0),ee=HO(b,J),W=qO(Y,ee);S(W.nodes),_(W.edges),m({previous:{nodes:[],edges:[]},current:{nodes:W.nodes,edges:W.edges}})}})},E=async()=>{setTimeout(()=>{const M=r.getViewport();w&&r.setCenter(w.position.x,w.position.y,{zoom:M.zoom,duration:1e3})},1e3)},x=async M=>{M.preventDefault(),await y("left"),await E()},k=async M=>{M.preventDefault(),await y("right"),await E()},P=()=>{w&&i(w)},R=()=>h(!0),j=()=>h(!1),z=()=>g.isLayer?null:K.jsxs(K.Fragment,{children:[K.jsx("a",{type:"button",target:"_blank",onClick:x,className:`${p?"visible":"invisible"} btn btn-light`,children:"BACK"}),K.jsx("a",{type:"button",target:"_blank",onClick:k,className:`${p?"visible":"invisible"} btn btn-light`,children:"NEXT"})]}),L=()=>p?"10px solid rgba(0, 0, 0, .1)":w?.id===o.id?"10px solid #1976D2":"";return K.jsxs(K.Fragment,{children:[K.jsx(qt,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2 d-flex align-items-center justify-content-center flex-wrap",style:{width:`${xg}px`,minHeight:`${_g}px`,border:L()},onMouseEnter:R,onMouseLeave:j,children:[K.jsxs("div",{className:"w-100",onClick:P,children:[K.jsx(Pr,{label:g.label,description:g.description}),K.jsx(Jr,{label:g.label,description:g.description})]}),K.jsx("div",{className:"position-absolute node-description w-100 d-flex justify-content-between align-self-end px-2",children:z()})]}),K.jsx(qt,{type:"source",position:Be.Right})]})};new Wi.graphlib.Graph().setDefaultEdgeLabel(()=>({}));const O4=({certificate:e,graph:n,children:r})=>{const{nodesState:o,edgesState:i,nodeLayers:l,setNodeLayers:c}=Ot(),f=he.useMemo(()=>({readNode:sl,fileLayerNode:$3,fileNode:sl,pipelineNode:sl,IDENode:sl,walkingNode:VO,editNode:u4,reviewNode:f4,workspaceFileNode:h4,workspacePipelineNode:w4,workspaceIDENode:S4}),[]),[,m,g]=o,[,d,p]=i;return he.useEffect(()=>{cr(e)||$t(e)||(m(n.nodes),d(n.edges),c({previous:l.previous,current:{nodes:n.nodes,edges:n.edges}}))},[e]),K.jsxs("div",{className:"layoutflow",children:[K.jsx(M3,{}),r,K.jsxs(ug,{nodes:l.current.nodes,edges:l.current.edges,onNodesChange:g,onEdgesChange:p,connectionLineType:hr.SmoothStep,nodeTypes:f,onlyRenderVisibleElements:!0,edgesUpdatable:!1,defaultViewport:{x:0,y:0,zoom:.6},children:[K.jsx(rO,{}),K.jsx(iO,{}),K.jsx(tO,{})]})]})},ll=({type:e,certificate:n,replica:r,graph:o,children:i})=>K.jsxs(hO,{type:e,certificate:n,replica:r,children:[K.jsx("div",{style:{height:"75vh"},children:K.jsx(O4,{certificate:n,graph:o,children:i})}),K.jsx(hg,{position:"bottom-right",autoClose:5e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,theme:"light"})]}),k4=({certificate:e})=>{const[n,r]=he.useState(!1),o=()=>r(!n),i="readNode",l={toggleMetadataModal:o},c=al(e.vertices,e.edges,e.restrictedAssets,i,l);return K.jsx(ll,{type:i,certificate:e,graph:c,children:K.jsx(vg,{isOpen:n,toggle:o})})},C4=({certificate:e,loading:n,handleUpdate:r,refresh:o})=>{const[i,l]=he.useState(!1),c=()=>l(!i),[f,m]=he.useState(!1),g=()=>m(!f),d="editNode",p={toggleEditModal:c,toggleMaskModal:g},h=al(e.vertices,e.edges,e.restrictedAssets,d,p);return K.jsxs(ll,{type:d,certificate:e,graph:h,children:[K.jsx(IO,{isOpen:i,loading:n,toggle:c,handleUpdate:r,refresh:o}),K.jsx(PO,{isOpen:f,loading:n,toggle:g,handleUpdate:r,refresh:o})]})};var Sg,UO;function A4(){if(UO)return Sg;UO=1;var e=md();function n(r,o){return e(r,o)}return Sg=n,Sg}var ul={exports:{}};/*!
|
|
30
137
|
* Quill Editor v1.3.7
|
|
31
138
|
* https://quilljs.com/
|
|
32
139
|
* Copyright (c) 2014, Jason Chen
|
|
33
140
|
* Copyright (c) 2013, salesforce.com
|
|
34
|
-
*/var
|
|
35
|
-
`;for(var
|
|
36
|
-
`)){var
|
|
37
|
-
`,
|
|
38
|
-
`),ue=ne.shift();ue.length>0&&(k<this.length()-1||this.children.tail==null?l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"insertAt",this).call(this,Math.min(k,this.length()-1),ue):this.children.tail.insertAt(this.children.tail.length(),ue),this.cache={});var K=this;ne.reduce(function(W,z){return K=K.split(W,!0),K.insertAt(0,z),z.length},k+ue.length)}}},{key:"insertBefore",value:function(k,F){var U=this.children.head;l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"insertBefore",this).call(this,k,F),U instanceof O.default&&U.remove(),this.cache={}}},{key:"length",value:function(){return this.cache.length==null&&(this.cache.length=l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"length",this).call(this)+N),this.cache.length}},{key:"moveChildren",value:function(k,F){l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"moveChildren",this).call(this,k,F),this.cache={}}},{key:"optimize",value:function(k){l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"optimize",this).call(this,k),this.cache={}}},{key:"path",value:function(k){return l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"path",this).call(this,k,!0)}},{key:"removeChild",value:function(k){l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"removeChild",this).call(this,k),this.cache={}}},{key:"split",value:function(k){var F=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(F&&(k===0||k>=this.length()-N)){var U=this.clone();return k===0?(this.parent.insertBefore(U,this),this):(this.parent.insertBefore(U,this.next),U)}else{var ne=l(q.prototype.__proto__||Object.getPrototypeOf(q.prototype),"split",this).call(this,k,F);return this.cache={},ne}}}]),q})(d.default.Block);j.blotName="block",j.tagName="P",j.defaultChild="break",j.allowedChildren=[_.default,d.default.Embed,w.default];function I(A){var q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return A==null||(typeof A.formats=="function"&&(q=(0,f.default)(q,A.formats())),A.parent==null||A.parent.blotName=="scroll"||A.parent.statics.scope!==A.statics.scope)?q:I(A.parent,q)}r.bubbleFormats=I,r.BlockEmbed=M,r.default=j}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.overload=r.expandConfig=void 0;var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(K){return typeof K}:function(K){return K&&typeof Symbol=="function"&&K.constructor===Symbol&&K!==Symbol.prototype?"symbol":typeof K},l=(function(){function K(W,z){var Q=[],re=!0,Z=!1,X=void 0;try{for(var H=W[Symbol.iterator](),ee;!(re=(ee=H.next()).done)&&(Q.push(ee.value),!(z&&Q.length===z));re=!0);}catch(le){Z=!0,X=le}finally{try{!re&&H.return&&H.return()}finally{if(Z)throw X}}return Q}return function(W,z){if(Array.isArray(W))return W;if(Symbol.iterator in Object(W))return K(W,z);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function K(W,z){for(var Q=0;Q<z.length;Q++){var re=z[Q];re.enumerable=re.enumerable||!1,re.configurable=!0,"value"in re&&(re.writable=!0),Object.defineProperty(W,re.key,re)}}return function(W,z,Q){return z&&K(W.prototype,z),Q&&K(W,Q),W}})();o(50);var f=o(2),h=I(f),a=o(14),u=I(a),d=o(8),p=I(d),O=o(9),g=I(O),_=o(0),y=I(_),w=o(15),E=I(w),m=o(3),S=I(m),C=o(10),N=I(C),M=o(34),j=I(M);function I(K){return K&&K.__esModule?K:{default:K}}function A(K,W,z){return W in K?Object.defineProperty(K,W,{value:z,enumerable:!0,configurable:!0,writable:!0}):K[W]=z,K}function q(K,W){if(!(K instanceof W))throw new TypeError("Cannot call a class as a function")}var R=(0,N.default)("quill"),k=(function(){c(K,null,[{key:"debug",value:function(z){z===!0&&(z="log"),N.default.level(z)}},{key:"find",value:function(z){return z.__quill||y.default.find(z)}},{key:"import",value:function(z){return this.imports[z]==null&&R.error("Cannot import "+z+". Are you sure it was registered?"),this.imports[z]}},{key:"register",value:function(z,Q){var re=this,Z=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(typeof z!="string"){var X=z.attrName||z.blotName;typeof X=="string"?this.register("formats/"+X,z,Q):Object.keys(z).forEach(function(H){re.register(H,z[H],Q)})}else this.imports[z]!=null&&!Z&&R.warn("Overwriting "+z+" with",Q),this.imports[z]=Q,(z.startsWith("blots/")||z.startsWith("formats/"))&&Q.blotName!=="abstract"?y.default.register(Q):z.startsWith("modules")&&typeof Q.register=="function"&&Q.register()}}]);function K(W){var z=this,Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(q(this,K),this.options=F(W,Q),this.container=this.options.container,this.container==null)return R.error("Invalid Quill container",W);this.options.debug&&K.debug(this.options.debug);var re=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new p.default,this.scroll=y.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new u.default(this.scroll),this.selection=new E.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(p.default.events.EDITOR_CHANGE,function(X){X===p.default.events.TEXT_CHANGE&&z.root.classList.toggle("ql-blank",z.editor.isBlank())}),this.emitter.on(p.default.events.SCROLL_UPDATE,function(X,H){var ee=z.selection.lastRange,le=ee&&ee.length===0?ee.index:void 0;U.call(z,function(){return z.editor.update(null,H,le)},X)});var Z=this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">`+re+"<p><br></p></div>");this.setContents(Z),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return c(K,[{key:"addContainer",value:function(z){var Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof z=="string"){var re=z;z=document.createElement("div"),z.classList.add(re)}return this.container.insertBefore(z,Q),z}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(z,Q,re){var Z=this,X=ne(z,Q,re),H=l(X,4);return z=H[0],Q=H[1],re=H[3],U.call(this,function(){return Z.editor.deleteText(z,Q)},re,z,-1*Q)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(z),this.container.classList.toggle("ql-disabled",!z)}},{key:"focus",value:function(){var z=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=z,this.scrollIntoView()}},{key:"format",value:function(z,Q){var re=this,Z=arguments.length>2&&arguments[2]!==void 0?arguments[2]:p.default.sources.API;return U.call(this,function(){var X=re.getSelection(!0),H=new h.default;if(X==null)return H;if(y.default.query(z,y.default.Scope.BLOCK))H=re.editor.formatLine(X.index,X.length,A({},z,Q));else{if(X.length===0)return re.selection.format(z,Q),H;H=re.editor.formatText(X.index,X.length,A({},z,Q))}return re.setSelection(X,p.default.sources.SILENT),H},Z)}},{key:"formatLine",value:function(z,Q,re,Z,X){var H=this,ee=void 0,le=ne(z,Q,re,Z,X),de=l(le,4);return z=de[0],Q=de[1],ee=de[2],X=de[3],U.call(this,function(){return H.editor.formatLine(z,Q,ee)},X,z,0)}},{key:"formatText",value:function(z,Q,re,Z,X){var H=this,ee=void 0,le=ne(z,Q,re,Z,X),de=l(le,4);return z=de[0],Q=de[1],ee=de[2],X=de[3],U.call(this,function(){return H.editor.formatText(z,Q,ee)},X,z,0)}},{key:"getBounds",value:function(z){var Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,re=void 0;typeof z=="number"?re=this.selection.getBounds(z,Q):re=this.selection.getBounds(z.index,z.length);var Z=this.container.getBoundingClientRect();return{bottom:re.bottom-Z.top,height:re.height,left:re.left-Z.left,right:re.right-Z.left,top:re.top-Z.top,width:re.width}}},{key:"getContents",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-z,re=ne(z,Q),Z=l(re,2);return z=Z[0],Q=Z[1],this.editor.getContents(z,Q)}},{key:"getFormat",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof z=="number"?this.editor.getFormat(z,Q):this.editor.getFormat(z.index,z.length)}},{key:"getIndex",value:function(z){return z.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(z){return this.scroll.leaf(z)}},{key:"getLine",value:function(z){return this.scroll.line(z)}},{key:"getLines",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof z!="number"?this.scroll.lines(z.index,z.length):this.scroll.lines(z,Q)}},{key:"getModule",value:function(z){return this.theme.modules[z]}},{key:"getSelection",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return z&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-z,re=ne(z,Q),Z=l(re,2);return z=Z[0],Q=Z[1],this.editor.getText(z,Q)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(z,Q,re){var Z=this,X=arguments.length>3&&arguments[3]!==void 0?arguments[3]:K.sources.API;return U.call(this,function(){return Z.editor.insertEmbed(z,Q,re)},X,z)}},{key:"insertText",value:function(z,Q,re,Z,X){var H=this,ee=void 0,le=ne(z,0,re,Z,X),de=l(le,4);return z=de[0],ee=de[2],X=de[3],U.call(this,function(){return H.editor.insertText(z,Q,ee)},X,z,Q.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(z,Q,re){this.clipboard.dangerouslyPasteHTML(z,Q,re)}},{key:"removeFormat",value:function(z,Q,re){var Z=this,X=ne(z,Q,re),H=l(X,4);return z=H[0],Q=H[1],re=H[3],U.call(this,function(){return Z.editor.removeFormat(z,Q)},re,z)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(z){var Q=this,re=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API;return U.call(this,function(){z=new h.default(z);var Z=Q.getLength(),X=Q.editor.deleteText(0,Z),H=Q.editor.applyDelta(z),ee=H.ops[H.ops.length-1];ee!=null&&typeof ee.insert=="string"&&ee.insert[ee.insert.length-1]===`
|
|
39
|
-
`&&(Q.editor.deleteText(Q.getLength()-1,1),H.delete(1));var le=X.compose(H);return le},re)}},{key:"setSelection",value:function(z,Q,re){if(z==null)this.selection.setRange(null,Q||K.sources.API);else{var Z=ne(z,Q,re),X=l(Z,4);z=X[0],Q=X[1],re=X[3],this.selection.setRange(new w.Range(z,Q),re),re!==p.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(z){var Q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API,re=new h.default().insert(z);return this.setContents(re,Q)}},{key:"update",value:function(){var z=arguments.length>0&&arguments[0]!==void 0?arguments[0]:p.default.sources.USER,Q=this.scroll.update(z);return this.selection.update(z),Q}},{key:"updateContents",value:function(z){var Q=this,re=arguments.length>1&&arguments[1]!==void 0?arguments[1]:p.default.sources.API;return U.call(this,function(){return z=new h.default(z),Q.editor.applyDelta(z,re)},re,!0)}}]),K})();k.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},k.events=p.default.events,k.sources=p.default.sources,k.version="1.3.7",k.imports={delta:h.default,parchment:y.default,"core/module":g.default,"core/theme":j.default};function F(K,W){if(W=(0,S.default)(!0,{container:K,modules:{clipboard:!0,keyboard:!0,history:!0}},W),!W.theme||W.theme===k.DEFAULTS.theme)W.theme=j.default;else if(W.theme=k.import("themes/"+W.theme),W.theme==null)throw new Error("Invalid theme "+W.theme+". Did you register it?");var z=(0,S.default)(!0,{},W.theme.DEFAULTS);[z,W].forEach(function(Z){Z.modules=Z.modules||{},Object.keys(Z.modules).forEach(function(X){Z.modules[X]===!0&&(Z.modules[X]={})})});var Q=Object.keys(z.modules).concat(Object.keys(W.modules)),re=Q.reduce(function(Z,X){var H=k.import("modules/"+X);return H==null?R.error("Cannot load "+X+" module. Are you sure you registered it?"):Z[X]=H.DEFAULTS||{},Z},{});return W.modules!=null&&W.modules.toolbar&&W.modules.toolbar.constructor!==Object&&(W.modules.toolbar={container:W.modules.toolbar}),W=(0,S.default)(!0,{},k.DEFAULTS,{modules:re},z,W),["bounds","container","scrollingContainer"].forEach(function(Z){typeof W[Z]=="string"&&(W[Z]=document.querySelector(W[Z]))}),W.modules=Object.keys(W.modules).reduce(function(Z,X){return W.modules[X]&&(Z[X]=W.modules[X]),Z},{}),W}function U(K,W,z,Q){if(this.options.strict&&!this.isEnabled()&&W===p.default.sources.USER)return new h.default;var re=z==null?null:this.getSelection(),Z=this.editor.delta,X=K();if(re!=null&&(z===!0&&(z=re.index),Q==null?re=ue(re,X,W):Q!==0&&(re=ue(re,z,Q,W)),this.setSelection(re,p.default.sources.SILENT)),X.length()>0){var H,ee=[p.default.events.TEXT_CHANGE,X,Z,W];if((H=this.emitter).emit.apply(H,[p.default.events.EDITOR_CHANGE].concat(ee)),W!==p.default.sources.SILENT){var le;(le=this.emitter).emit.apply(le,ee)}}return X}function ne(K,W,z,Q,re){var Z={};return typeof K.index=="number"&&typeof K.length=="number"?typeof W!="number"?(re=Q,Q=z,z=W,W=K.length,K=K.index):(W=K.length,K=K.index):typeof W!="number"&&(re=Q,Q=z,z=W,W=0),(typeof z>"u"?"undefined":s(z))==="object"?(Z=z,re=Q):typeof z=="string"&&(Q!=null?Z[z]=Q:re=z),re=re||p.default.sources.API,[K,W,Z,re]}function ue(K,W,z,Q){if(K==null)return null;var re=void 0,Z=void 0;if(W instanceof h.default){var X=[K.index,K.index+K.length].map(function(de){return W.transformPosition(de,Q!==p.default.sources.USER)}),H=l(X,2);re=H[0],Z=H[1]}else{var ee=[K.index,K.index+K.length].map(function(de){return de<W||de===W&&Q===p.default.sources.USER?de:z>=0?de+z:Math.max(W,de+z)}),le=l(ee,2);re=le[0],Z=le[1]}return new w.Range(re,Z-re)}r.expandConfig=F,r.overload=ne,r.default=k}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function _(y,w){for(var E=0;E<w.length;E++){var m=w[E];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,E){return w&&_(y.prototype,w),E&&_(y,E),y}})(),l=function _(y,w,E){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var S=Object.getPrototypeOf(y);return S===null?void 0:_(S,w,E)}else{if("value"in m)return m.value;var C=m.get;return C===void 0?void 0:C.call(E)}},c=o(7),f=u(c),h=o(0),a=u(h);function u(_){return _&&_.__esModule?_:{default:_}}function d(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function p(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function O(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var g=(function(_){O(y,_);function y(){return d(this,y),p(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"formatAt",value:function(E,m,S,C){if(y.compare(this.statics.blotName,S)<0&&a.default.query(S,a.default.Scope.BLOT)){var N=this.isolate(E,m);C&&N.wrap(S,C)}else l(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"formatAt",this).call(this,E,m,S,C)}},{key:"optimize",value:function(E){if(l(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"optimize",this).call(this,E),this.parent instanceof y&&y.compare(this.statics.blotName,this.parent.statics.blotName)>0){var m=this.parent.isolate(this.offset(),this.length());this.moveChildren(m),m.wrap(this)}}}],[{key:"compare",value:function(E,m){var S=y.order.indexOf(E),C=y.order.indexOf(m);return S>=0||C>=0?S-C:E===m?0:E<m?-1:1}}]),y})(a.default.Inline);g.allowedChildren=[g,a.default.Embed,f.default],g.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],r.default=g}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(0),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}function f(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function h(d,p){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:d}function a(d,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);d.prototype=Object.create(p&&p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(d,p):d.__proto__=p)}var u=(function(d){a(p,d);function p(){return f(this,p),h(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p})(l.default.Text);r.default=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function w(E,m){for(var S=0;S<m.length;S++){var C=m[S];C.enumerable=C.enumerable||!1,C.configurable=!0,"value"in C&&(C.writable=!0),Object.defineProperty(E,C.key,C)}}return function(E,m,S){return m&&w(E.prototype,m),S&&w(E,S),E}})(),l=function w(E,m,S){E===null&&(E=Function.prototype);var C=Object.getOwnPropertyDescriptor(E,m);if(C===void 0){var N=Object.getPrototypeOf(E);return N===null?void 0:w(N,m,S)}else{if("value"in C)return C.value;var M=C.get;return M===void 0?void 0:M.call(S)}},c=o(54),f=u(c),h=o(10),a=u(h);function u(w){return w&&w.__esModule?w:{default:w}}function d(w,E){if(!(w instanceof E))throw new TypeError("Cannot call a class as a function")}function p(w,E){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return E&&(typeof E=="object"||typeof E=="function")?E:w}function O(w,E){if(typeof E!="function"&&E!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof E);w.prototype=Object.create(E&&E.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),E&&(Object.setPrototypeOf?Object.setPrototypeOf(w,E):w.__proto__=E)}var g=(0,a.default)("quill:events"),_=["selectionchange","mousedown","mouseup","click"];_.forEach(function(w){document.addEventListener(w,function(){for(var E=arguments.length,m=Array(E),S=0;S<E;S++)m[S]=arguments[S];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(C){if(C.__quill&&C.__quill.emitter){var N;(N=C.__quill.emitter).handleDOM.apply(N,m)}})})});var y=(function(w){O(E,w);function E(){d(this,E);var m=p(this,(E.__proto__||Object.getPrototypeOf(E)).call(this));return m.listeners={},m.on("error",g.error),m}return s(E,[{key:"emit",value:function(){g.log.apply(g,arguments),l(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(S){for(var C=arguments.length,N=Array(C>1?C-1:0),M=1;M<C;M++)N[M-1]=arguments[M];(this.listeners[S.type]||[]).forEach(function(j){var I=j.node,A=j.handler;(S.target===I||I.contains(S.target))&&A.apply(void 0,[S].concat(N))})}},{key:"listenDOM",value:function(S,C,N){this.listeners[S]||(this.listeners[S]=[]),this.listeners[S].push({node:C,handler:N})}}]),E})(f.default);y.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},y.sources={API:"api",SILENT:"silent",USER:"user"},r.default=y}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});function s(c,f){if(!(c instanceof f))throw new TypeError("Cannot call a class as a function")}var l=function c(f){var h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};s(this,c),this.quill=f,this.options=h};l.DEFAULTS={},r.default=l}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=["error","warn","log","info"],l="warn";function c(h){if(s.indexOf(h)<=s.indexOf(l)){for(var a,u=arguments.length,d=Array(u>1?u-1:0),p=1;p<u;p++)d[p-1]=arguments[p];(a=console)[h].apply(a,d)}}function f(h){return s.reduce(function(a,u){return a[u]=c.bind(console,u,h),a},{})}c.level=f.level=function(h){l=h},r.default=f}),(function(n,r,o){var s=Array.prototype.slice,l=o(52),c=o(53),f=n.exports=function(d,p,O){return O||(O={}),d===p?!0:d instanceof Date&&p instanceof Date?d.getTime()===p.getTime():!d||!p||typeof d!="object"&&typeof p!="object"?O.strict?d===p:d==p:u(d,p,O)};function h(d){return d==null}function a(d){return!(!d||typeof d!="object"||typeof d.length!="number"||typeof d.copy!="function"||typeof d.slice!="function"||d.length>0&&typeof d[0]!="number")}function u(d,p,O){var g,_;if(h(d)||h(p)||d.prototype!==p.prototype)return!1;if(c(d))return c(p)?(d=s.call(d),p=s.call(p),f(d,p,O)):!1;if(a(d)){if(!a(p)||d.length!==p.length)return!1;for(g=0;g<d.length;g++)if(d[g]!==p[g])return!1;return!0}try{var y=l(d),w=l(p)}catch{return!1}if(y.length!=w.length)return!1;for(y.sort(),w.sort(),g=y.length-1;g>=0;g--)if(y[g]!=w[g])return!1;for(g=y.length-1;g>=0;g--)if(_=y[g],!f(d[_],p[_],O))return!1;return typeof d==typeof p}}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(1),l=(function(){function c(f,h,a){a===void 0&&(a={}),this.attrName=f,this.keyName=h;var u=s.Scope.TYPE&s.Scope.ATTRIBUTE;a.scope!=null?this.scope=a.scope&s.Scope.LEVEL|u:this.scope=s.Scope.ATTRIBUTE,a.whitelist!=null&&(this.whitelist=a.whitelist)}return c.keys=function(f){return[].map.call(f.attributes,function(h){return h.name})},c.prototype.add=function(f,h){return this.canAdd(f,h)?(f.setAttribute(this.keyName,h),!0):!1},c.prototype.canAdd=function(f,h){var a=s.query(f,s.Scope.BLOT&(this.scope|s.Scope.TYPE));return a==null?!1:this.whitelist==null?!0:typeof h=="string"?this.whitelist.indexOf(h.replace(/["']/g,""))>-1:this.whitelist.indexOf(h)>-1},c.prototype.remove=function(f){f.removeAttribute(this.keyName)},c.prototype.value=function(f){var h=f.getAttribute(this.keyName);return this.canAdd(f,h)&&h?h:""},c})();r.default=l}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Code=void 0;var s=(function(){function M(j,I){var A=[],q=!0,R=!1,k=void 0;try{for(var F=j[Symbol.iterator](),U;!(q=(U=F.next()).done)&&(A.push(U.value),!(I&&A.length===I));q=!0);}catch(ne){R=!0,k=ne}finally{try{!q&&F.return&&F.return()}finally{if(R)throw k}}return A}return function(j,I){if(Array.isArray(j))return j;if(Symbol.iterator in Object(j))return M(j,I);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=(function(){function M(j,I){for(var A=0;A<I.length;A++){var q=I[A];q.enumerable=q.enumerable||!1,q.configurable=!0,"value"in q&&(q.writable=!0),Object.defineProperty(j,q.key,q)}}return function(j,I,A){return I&&M(j.prototype,I),A&&M(j,A),j}})(),c=function M(j,I,A){j===null&&(j=Function.prototype);var q=Object.getOwnPropertyDescriptor(j,I);if(q===void 0){var R=Object.getPrototypeOf(j);return R===null?void 0:M(R,I,A)}else{if("value"in q)return q.value;var k=q.get;return k===void 0?void 0:k.call(A)}},f=o(2),h=w(f),a=o(0),u=w(a),d=o(4),p=w(d),O=o(6),g=w(O),_=o(7),y=w(_);function w(M){return M&&M.__esModule?M:{default:M}}function E(M,j){if(!(M instanceof j))throw new TypeError("Cannot call a class as a function")}function m(M,j){if(!M)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return j&&(typeof j=="object"||typeof j=="function")?j:M}function S(M,j){if(typeof j!="function"&&j!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof j);M.prototype=Object.create(j&&j.prototype,{constructor:{value:M,enumerable:!1,writable:!0,configurable:!0}}),j&&(Object.setPrototypeOf?Object.setPrototypeOf(M,j):M.__proto__=j)}var C=(function(M){S(j,M);function j(){return E(this,j),m(this,(j.__proto__||Object.getPrototypeOf(j)).apply(this,arguments))}return j})(g.default);C.blotName="code",C.tagName="CODE";var N=(function(M){S(j,M);function j(){return E(this,j),m(this,(j.__proto__||Object.getPrototypeOf(j)).apply(this,arguments))}return l(j,[{key:"delta",value:function(){var A=this,q=this.domNode.textContent;return q.endsWith(`
|
|
40
|
-
`)&&(
|
|
41
|
-
`).reduce(function(
|
|
42
|
-
`,
|
|
43
|
-
`)?
|
|
44
|
-
`);var
|
|
45
|
-
`);return
|
|
46
|
-
`)||this.appendChild(
|
|
47
|
-
`)),
|
|
48
|
-
`)&&
|
|
49
|
-
`)&&(
|
|
141
|
+
*/var N4=ul.exports,WO;function T4(){return WO||(WO=1,(function(e,n){(function(o,i){e.exports=i()})(typeof self<"u"?self:N4,function(){return(function(r){var o={};function i(l){if(o[l])return o[l].exports;var c=o[l]={i:l,l:!1,exports:{}};return r[l].call(c.exports,c,c.exports,i),c.l=!0,c.exports}return i.m=r,i.c=o,i.d=function(l,c,f){i.o(l,c)||Object.defineProperty(l,c,{configurable:!1,enumerable:!0,get:f})},i.n=function(l){var c=l&&l.__esModule?function(){return l.default}:function(){return l};return i.d(c,"a",c),c},i.o=function(l,c){return Object.prototype.hasOwnProperty.call(l,c)},i.p="",i(i.s=109)})([(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(17),c=i(18),f=i(19),m=i(45),g=i(46),d=i(47),p=i(48),h=i(49),s=i(12),S=i(32),b=i(33),_=i(31),w=i(1),y={Scope:w.Scope,create:w.create,find:w.find,query:w.query,register:w.register,Container:l.default,Format:c.default,Leaf:f.default,Embed:p.default,Scroll:m.default,Block:d.default,Inline:g.default,Text:h.default,Attributor:{Attribute:s.default,Class:S.default,Style:b.default,Store:_.default}};o.default=y}),(function(r,o,i){var l=this&&this.__extends||(function(){var _=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(w,y){w.__proto__=y}||function(w,y){for(var E in y)y.hasOwnProperty(E)&&(w[E]=y[E])};return function(w,y){_(w,y);function E(){this.constructor=w}w.prototype=y===null?Object.create(y):(E.prototype=y.prototype,new E)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=(function(_){l(w,_);function w(y){var E=this;return y="[Parchment] "+y,E=_.call(this,y)||this,E.message=y,E.name=E.constructor.name,E}return w})(Error);o.ParchmentError=c;var f={},m={},g={},d={};o.DATA_KEY="__blot";var p;(function(_){_[_.TYPE=3]="TYPE",_[_.LEVEL=12]="LEVEL",_[_.ATTRIBUTE=13]="ATTRIBUTE",_[_.BLOT=14]="BLOT",_[_.INLINE=7]="INLINE",_[_.BLOCK=11]="BLOCK",_[_.BLOCK_BLOT=10]="BLOCK_BLOT",_[_.INLINE_BLOT=6]="INLINE_BLOT",_[_.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",_[_.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",_[_.ANY=15]="ANY"})(p=o.Scope||(o.Scope={}));function h(_,w){var y=S(_);if(y==null)throw new c("Unable to create "+_+" blot");var E=y,x=_ instanceof Node||_.nodeType===Node.TEXT_NODE?_:E.create(w);return new E(x,w)}o.create=h;function s(_,w){return w===void 0&&(w=!1),_==null?null:_[o.DATA_KEY]!=null?_[o.DATA_KEY].blot:w?s(_.parentNode,w):null}o.find=s;function S(_,w){w===void 0&&(w=p.ANY);var y;if(typeof _=="string")y=d[_]||f[_];else if(_ instanceof Text||_.nodeType===Node.TEXT_NODE)y=d.text;else if(typeof _=="number")_&p.LEVEL&p.BLOCK?y=d.block:_&p.LEVEL&p.INLINE&&(y=d.inline);else if(_ instanceof HTMLElement){var E=(_.getAttribute("class")||"").split(/\s+/);for(var x in E)if(y=m[E[x]],y)break;y=y||g[_.tagName]}return y==null?null:w&p.LEVEL&y.scope&&w&p.TYPE&y.scope?y:null}o.query=S;function b(){for(var _=[],w=0;w<arguments.length;w++)_[w]=arguments[w];if(_.length>1)return _.map(function(x){return b(x)});var y=_[0];if(typeof y.blotName!="string"&&typeof y.attrName!="string")throw new c("Invalid definition");if(y.blotName==="abstract")throw new c("Cannot register abstract class");if(d[y.blotName||y.attrName]=y,typeof y.keyName=="string")f[y.keyName]=y;else if(y.className!=null&&(m[y.className]=y),y.tagName!=null){Array.isArray(y.tagName)?y.tagName=y.tagName.map(function(x){return x.toUpperCase()}):y.tagName=y.tagName.toUpperCase();var E=Array.isArray(y.tagName)?y.tagName:[y.tagName];E.forEach(function(x){(g[x]==null||y.className==null)&&(g[x]=y)})}return y}o.register=b}),(function(r,o,i){var l=i(51),c=i(11),f=i(3),m=i(20),g="\0",d=function(p){Array.isArray(p)?this.ops=p:p!=null&&Array.isArray(p.ops)?this.ops=p.ops:this.ops=[]};d.prototype.insert=function(p,h){var s={};return p.length===0?this:(s.insert=p,h!=null&&typeof h=="object"&&Object.keys(h).length>0&&(s.attributes=h),this.push(s))},d.prototype.delete=function(p){return p<=0?this:this.push({delete:p})},d.prototype.retain=function(p,h){if(p<=0)return this;var s={retain:p};return h!=null&&typeof h=="object"&&Object.keys(h).length>0&&(s.attributes=h),this.push(s)},d.prototype.push=function(p){var h=this.ops.length,s=this.ops[h-1];if(p=f(!0,{},p),typeof s=="object"){if(typeof p.delete=="number"&&typeof s.delete=="number")return this.ops[h-1]={delete:s.delete+p.delete},this;if(typeof s.delete=="number"&&p.insert!=null&&(h-=1,s=this.ops[h-1],typeof s!="object"))return this.ops.unshift(p),this;if(c(p.attributes,s.attributes)){if(typeof p.insert=="string"&&typeof s.insert=="string")return this.ops[h-1]={insert:s.insert+p.insert},typeof p.attributes=="object"&&(this.ops[h-1].attributes=p.attributes),this;if(typeof p.retain=="number"&&typeof s.retain=="number")return this.ops[h-1]={retain:s.retain+p.retain},typeof p.attributes=="object"&&(this.ops[h-1].attributes=p.attributes),this}}return h===this.ops.length?this.ops.push(p):this.ops.splice(h,0,p),this},d.prototype.chop=function(){var p=this.ops[this.ops.length-1];return p&&p.retain&&!p.attributes&&this.ops.pop(),this},d.prototype.filter=function(p){return this.ops.filter(p)},d.prototype.forEach=function(p){this.ops.forEach(p)},d.prototype.map=function(p){return this.ops.map(p)},d.prototype.partition=function(p){var h=[],s=[];return this.forEach(function(S){var b=p(S)?h:s;b.push(S)}),[h,s]},d.prototype.reduce=function(p,h){return this.ops.reduce(p,h)},d.prototype.changeLength=function(){return this.reduce(function(p,h){return h.insert?p+m.length(h):h.delete?p-h.delete:p},0)},d.prototype.length=function(){return this.reduce(function(p,h){return p+m.length(h)},0)},d.prototype.slice=function(p,h){p=p||0,typeof h!="number"&&(h=1/0);for(var s=[],S=m.iterator(this.ops),b=0;b<h&&S.hasNext();){var _;b<p?_=S.next(p-b):(_=S.next(h-b),s.push(_)),b+=m.length(_)}return new d(s)},d.prototype.compose=function(p){var h=m.iterator(this.ops),s=m.iterator(p.ops),S=[],b=s.peek();if(b!=null&&typeof b.retain=="number"&&b.attributes==null){for(var _=b.retain;h.peekType()==="insert"&&h.peekLength()<=_;)_-=h.peekLength(),S.push(h.next());b.retain-_>0&&s.next(b.retain-_)}for(var w=new d(S);h.hasNext()||s.hasNext();)if(s.peekType()==="insert")w.push(s.next());else if(h.peekType()==="delete")w.push(h.next());else{var y=Math.min(h.peekLength(),s.peekLength()),E=h.next(y),x=s.next(y);if(typeof x.retain=="number"){var k={};typeof E.retain=="number"?k.retain=y:k.insert=E.insert;var P=m.attributes.compose(E.attributes,x.attributes,typeof E.retain=="number");if(P&&(k.attributes=P),w.push(k),!s.hasNext()&&c(w.ops[w.ops.length-1],k)){var R=new d(h.rest());return w.concat(R).chop()}}else typeof x.delete=="number"&&typeof E.retain=="number"&&w.push(x)}return w.chop()},d.prototype.concat=function(p){var h=new d(this.ops.slice());return p.ops.length>0&&(h.push(p.ops[0]),h.ops=h.ops.concat(p.ops.slice(1))),h},d.prototype.diff=function(p,h){if(this.ops===p.ops)return new d;var s=[this,p].map(function(y){return y.map(function(E){if(E.insert!=null)return typeof E.insert=="string"?E.insert:g;var x=y===p?"on":"with";throw new Error("diff() called "+x+" non-document")}).join("")}),S=new d,b=l(s[0],s[1],h),_=m.iterator(this.ops),w=m.iterator(p.ops);return b.forEach(function(y){for(var E=y[1].length;E>0;){var x=0;switch(y[0]){case l.INSERT:x=Math.min(w.peekLength(),E),S.push(w.next(x));break;case l.DELETE:x=Math.min(E,_.peekLength()),_.next(x),S.delete(x);break;case l.EQUAL:x=Math.min(_.peekLength(),w.peekLength(),E);var k=_.next(x),P=w.next(x);c(k.insert,P.insert)?S.retain(x,m.attributes.diff(k.attributes,P.attributes)):S.push(P).delete(x);break}E-=x}}),S.chop()},d.prototype.eachLine=function(p,h){h=h||`
|
|
142
|
+
`;for(var s=m.iterator(this.ops),S=new d,b=0;s.hasNext();){if(s.peekType()!=="insert")return;var _=s.peek(),w=m.length(_)-s.peekLength(),y=typeof _.insert=="string"?_.insert.indexOf(h,w)-w:-1;if(y<0)S.push(s.next());else if(y>0)S.push(s.next(y));else{if(p(S,s.next(1).attributes||{},b)===!1)return;b+=1,S=new d}}S.length()>0&&p(S,{},b)},d.prototype.transform=function(p,h){if(h=!!h,typeof p=="number")return this.transformPosition(p,h);for(var s=m.iterator(this.ops),S=m.iterator(p.ops),b=new d;s.hasNext()||S.hasNext();)if(s.peekType()==="insert"&&(h||S.peekType()!=="insert"))b.retain(m.length(s.next()));else if(S.peekType()==="insert")b.push(S.next());else{var _=Math.min(s.peekLength(),S.peekLength()),w=s.next(_),y=S.next(_);if(w.delete)continue;y.delete?b.push(y):b.retain(_,m.attributes.transform(w.attributes,y.attributes,h))}return b.chop()},d.prototype.transformPosition=function(p,h){h=!!h;for(var s=m.iterator(this.ops),S=0;s.hasNext()&&S<=p;){var b=s.peekLength(),_=s.peekType();if(s.next(),_==="delete"){p-=Math.min(b,p-S);continue}else _==="insert"&&(S<p||!h)&&(p+=b);S+=b}return p},r.exports=d}),(function(r,o){var i=Object.prototype.hasOwnProperty,l=Object.prototype.toString,c=Object.defineProperty,f=Object.getOwnPropertyDescriptor,m=function(s){return typeof Array.isArray=="function"?Array.isArray(s):l.call(s)==="[object Array]"},g=function(s){if(!s||l.call(s)!=="[object Object]")return!1;var S=i.call(s,"constructor"),b=s.constructor&&s.constructor.prototype&&i.call(s.constructor.prototype,"isPrototypeOf");if(s.constructor&&!S&&!b)return!1;var _;for(_ in s);return typeof _>"u"||i.call(s,_)},d=function(s,S){c&&S.name==="__proto__"?c(s,S.name,{enumerable:!0,configurable:!0,value:S.newValue,writable:!0}):s[S.name]=S.newValue},p=function(s,S){if(S==="__proto__")if(i.call(s,S)){if(f)return f(s,S).value}else return;return s[S]};r.exports=function h(){var s,S,b,_,w,y,E=arguments[0],x=1,k=arguments.length,P=!1;for(typeof E=="boolean"&&(P=E,E=arguments[1]||{},x=2),(E==null||typeof E!="object"&&typeof E!="function")&&(E={});x<k;++x)if(s=arguments[x],s!=null)for(S in s)b=p(E,S),_=p(s,S),E!==_&&(P&&_&&(g(_)||(w=m(_)))?(w?(w=!1,y=b&&m(b)?b:[]):y=b&&g(b)?b:{},d(E,{name:S,newValue:h(P,y,_)})):typeof _<"u"&&d(E,{name:S,newValue:_}));return E}}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.BlockEmbed=o.bubbleFormats=void 0;var l=(function(){function M(D,F){for(var B=0;B<F.length;B++){var U=F[B];U.enumerable=U.enumerable||!1,U.configurable=!0,"value"in U&&(U.writable=!0),Object.defineProperty(D,U.key,U)}}return function(D,F,B){return F&&M(D.prototype,F),B&&M(D,B),D}})(),c=function M(D,F,B){D===null&&(D=Function.prototype);var U=Object.getOwnPropertyDescriptor(D,F);if(U===void 0){var J=Object.getPrototypeOf(D);return J===null?void 0:M(J,F,B)}else{if("value"in U)return U.value;var oe=U.get;return oe===void 0?void 0:oe.call(B)}},f=i(3),m=E(f),g=i(2),d=E(g),p=i(0),h=E(p),s=i(16),S=E(s),b=i(6),_=E(b),w=i(7),y=E(w);function E(M){return M&&M.__esModule?M:{default:M}}function x(M,D){if(!(M instanceof D))throw new TypeError("Cannot call a class as a function")}function k(M,D){if(!M)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return D&&(typeof D=="object"||typeof D=="function")?D:M}function P(M,D){if(typeof D!="function"&&D!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof D);M.prototype=Object.create(D&&D.prototype,{constructor:{value:M,enumerable:!1,writable:!0,configurable:!0}}),D&&(Object.setPrototypeOf?Object.setPrototypeOf(M,D):M.__proto__=D)}var R=1,j=(function(M){P(D,M);function D(){return x(this,D),k(this,(D.__proto__||Object.getPrototypeOf(D)).apply(this,arguments))}return l(D,[{key:"attach",value:function(){c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"attach",this).call(this),this.attributes=new h.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return new d.default().insert(this.value(),(0,m.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(B,U){var J=h.default.query(B,h.default.Scope.BLOCK_ATTRIBUTE);J!=null&&this.attributes.attribute(J,U)}},{key:"formatAt",value:function(B,U,J,oe){this.format(J,oe)}},{key:"insertAt",value:function(B,U,J){if(typeof U=="string"&&U.endsWith(`
|
|
143
|
+
`)){var oe=h.default.create(z.blotName);this.parent.insertBefore(oe,B===0?this:this.next),oe.insertAt(0,U.slice(0,-1))}else c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"insertAt",this).call(this,B,U,J)}}]),D})(h.default.Embed);j.scope=h.default.Scope.BLOCK_BLOT;var z=(function(M){P(D,M);function D(F){x(this,D);var B=k(this,(D.__proto__||Object.getPrototypeOf(D)).call(this,F));return B.cache={},B}return l(D,[{key:"delta",value:function(){return this.cache.delta==null&&(this.cache.delta=this.descendants(h.default.Leaf).reduce(function(B,U){return U.length()===0?B:B.insert(U.value(),L(U))},new d.default).insert(`
|
|
144
|
+
`,L(this))),this.cache.delta}},{key:"deleteAt",value:function(B,U){c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"deleteAt",this).call(this,B,U),this.cache={}}},{key:"formatAt",value:function(B,U,J,oe){U<=0||(h.default.query(J,h.default.Scope.BLOCK)?B+U===this.length()&&this.format(J,oe):c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"formatAt",this).call(this,B,Math.min(U,this.length()-B-1),J,oe),this.cache={})}},{key:"insertAt",value:function(B,U,J){if(J!=null)return c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"insertAt",this).call(this,B,U,J);if(U.length!==0){var oe=U.split(`
|
|
145
|
+
`),de=oe.shift();de.length>0&&(B<this.length()-1||this.children.tail==null?c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"insertAt",this).call(this,Math.min(B,this.length()-1),de):this.children.tail.insertAt(this.children.tail.length(),de),this.cache={});var Y=this;oe.reduce(function(ee,W){return Y=Y.split(ee,!0),Y.insertAt(0,W),W.length},B+de.length)}}},{key:"insertBefore",value:function(B,U){var J=this.children.head;c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"insertBefore",this).call(this,B,U),J instanceof S.default&&J.remove(),this.cache={}}},{key:"length",value:function(){return this.cache.length==null&&(this.cache.length=c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"length",this).call(this)+R),this.cache.length}},{key:"moveChildren",value:function(B,U){c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"moveChildren",this).call(this,B,U),this.cache={}}},{key:"optimize",value:function(B){c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"optimize",this).call(this,B),this.cache={}}},{key:"path",value:function(B){return c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"path",this).call(this,B,!0)}},{key:"removeChild",value:function(B){c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"removeChild",this).call(this,B),this.cache={}}},{key:"split",value:function(B){var U=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(U&&(B===0||B>=this.length()-R)){var J=this.clone();return B===0?(this.parent.insertBefore(J,this),this):(this.parent.insertBefore(J,this.next),J)}else{var oe=c(D.prototype.__proto__||Object.getPrototypeOf(D.prototype),"split",this).call(this,B,U);return this.cache={},oe}}}]),D})(h.default.Block);z.blotName="block",z.tagName="P",z.defaultChild="break",z.allowedChildren=[_.default,h.default.Embed,y.default];function L(M){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return M==null||(typeof M.formats=="function"&&(D=(0,m.default)(D,M.formats())),M.parent==null||M.parent.blotName=="scroll"||M.parent.statics.scope!==M.statics.scope)?D:L(M.parent,D)}o.bubbleFormats=L,o.BlockEmbed=j,o.default=z}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.overload=o.expandConfig=void 0;var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Y){return typeof Y}:function(Y){return Y&&typeof Symbol=="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y},c=(function(){function Y(ee,W){var ne=[],ae=!0,te=!1,re=void 0;try{for(var Z=ee[Symbol.iterator](),se;!(ae=(se=Z.next()).done)&&(ne.push(se.value),!(W&&ne.length===W));ae=!0);}catch(pe){te=!0,re=pe}finally{try{!ae&&Z.return&&Z.return()}finally{if(te)throw re}}return ne}return function(ee,W){if(Array.isArray(ee))return ee;if(Symbol.iterator in Object(ee))return Y(ee,W);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),f=(function(){function Y(ee,W){for(var ne=0;ne<W.length;ne++){var ae=W[ne];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(ee,ae.key,ae)}}return function(ee,W,ne){return W&&Y(ee.prototype,W),ne&&Y(ee,ne),ee}})();i(50);var m=i(2),g=L(m),d=i(14),p=L(d),h=i(8),s=L(h),S=i(9),b=L(S),_=i(0),w=L(_),y=i(15),E=L(y),x=i(3),k=L(x),P=i(10),R=L(P),j=i(34),z=L(j);function L(Y){return Y&&Y.__esModule?Y:{default:Y}}function M(Y,ee,W){return ee in Y?Object.defineProperty(Y,ee,{value:W,enumerable:!0,configurable:!0,writable:!0}):Y[ee]=W,Y}function D(Y,ee){if(!(Y instanceof ee))throw new TypeError("Cannot call a class as a function")}var F=(0,R.default)("quill"),B=(function(){f(Y,null,[{key:"debug",value:function(W){W===!0&&(W="log"),R.default.level(W)}},{key:"find",value:function(W){return W.__quill||w.default.find(W)}},{key:"import",value:function(W){return this.imports[W]==null&&F.error("Cannot import "+W+". Are you sure it was registered?"),this.imports[W]}},{key:"register",value:function(W,ne){var ae=this,te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(typeof W!="string"){var re=W.attrName||W.blotName;typeof re=="string"?this.register("formats/"+re,W,ne):Object.keys(W).forEach(function(Z){ae.register(Z,W[Z],ne)})}else this.imports[W]!=null&&!te&&F.warn("Overwriting "+W+" with",ne),this.imports[W]=ne,(W.startsWith("blots/")||W.startsWith("formats/"))&&ne.blotName!=="abstract"?w.default.register(ne):W.startsWith("modules")&&typeof ne.register=="function"&&ne.register()}}]);function Y(ee){var W=this,ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(D(this,Y),this.options=U(ee,ne),this.container=this.options.container,this.container==null)return F.error("Invalid Quill container",ee);this.options.debug&&Y.debug(this.options.debug);var ae=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new s.default,this.scroll=w.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new p.default(this.scroll),this.selection=new E.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(s.default.events.EDITOR_CHANGE,function(re){re===s.default.events.TEXT_CHANGE&&W.root.classList.toggle("ql-blank",W.editor.isBlank())}),this.emitter.on(s.default.events.SCROLL_UPDATE,function(re,Z){var se=W.selection.lastRange,pe=se&&se.length===0?se.index:void 0;J.call(W,function(){return W.editor.update(null,Z,pe)},re)});var te=this.clipboard.convert(`<div class='ql-editor' style="white-space: normal;">`+ae+"<p><br></p></div>");this.setContents(te),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return f(Y,[{key:"addContainer",value:function(W){var ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;if(typeof W=="string"){var ae=W;W=document.createElement("div"),W.classList.add(ae)}return this.container.insertBefore(W,ne),W}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(W,ne,ae){var te=this,re=oe(W,ne,ae),Z=c(re,4);return W=Z[0],ne=Z[1],ae=Z[3],J.call(this,function(){return te.editor.deleteText(W,ne)},ae,W,-1*ne)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.scroll.enable(W),this.container.classList.toggle("ql-disabled",!W)}},{key:"focus",value:function(){var W=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=W,this.scrollIntoView()}},{key:"format",value:function(W,ne){var ae=this,te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:s.default.sources.API;return J.call(this,function(){var re=ae.getSelection(!0),Z=new g.default;if(re==null)return Z;if(w.default.query(W,w.default.Scope.BLOCK))Z=ae.editor.formatLine(re.index,re.length,M({},W,ne));else{if(re.length===0)return ae.selection.format(W,ne),Z;Z=ae.editor.formatText(re.index,re.length,M({},W,ne))}return ae.setSelection(re,s.default.sources.SILENT),Z},te)}},{key:"formatLine",value:function(W,ne,ae,te,re){var Z=this,se=void 0,pe=oe(W,ne,ae,te,re),ge=c(pe,4);return W=ge[0],ne=ge[1],se=ge[2],re=ge[3],J.call(this,function(){return Z.editor.formatLine(W,ne,se)},re,W,0)}},{key:"formatText",value:function(W,ne,ae,te,re){var Z=this,se=void 0,pe=oe(W,ne,ae,te,re),ge=c(pe,4);return W=ge[0],ne=ge[1],se=ge[2],re=ge[3],J.call(this,function(){return Z.editor.formatText(W,ne,se)},re,W,0)}},{key:"getBounds",value:function(W){var ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,ae=void 0;typeof W=="number"?ae=this.selection.getBounds(W,ne):ae=this.selection.getBounds(W.index,W.length);var te=this.container.getBoundingClientRect();return{bottom:ae.bottom-te.top,height:ae.height,left:ae.left-te.left,right:ae.right-te.left,top:ae.top-te.top,width:ae.width}}},{key:"getContents",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-W,ae=oe(W,ne),te=c(ae,2);return W=te[0],ne=te[1],this.editor.getContents(W,ne)}},{key:"getFormat",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:this.getSelection(!0),ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return typeof W=="number"?this.editor.getFormat(W,ne):this.editor.getFormat(W.index,W.length)}},{key:"getIndex",value:function(W){return W.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(W){return this.scroll.leaf(W)}},{key:"getLine",value:function(W){return this.scroll.line(W)}},{key:"getLines",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE;return typeof W!="number"?this.scroll.lines(W.index,W.length):this.scroll.lines(W,ne)}},{key:"getModule",value:function(W){return this.theme.modules[W]}},{key:"getSelection",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!1;return W&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:this.getLength()-W,ae=oe(W,ne),te=c(ae,2);return W=te[0],ne=te[1],this.editor.getText(W,ne)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(W,ne,ae){var te=this,re=arguments.length>3&&arguments[3]!==void 0?arguments[3]:Y.sources.API;return J.call(this,function(){return te.editor.insertEmbed(W,ne,ae)},re,W)}},{key:"insertText",value:function(W,ne,ae,te,re){var Z=this,se=void 0,pe=oe(W,0,ae,te,re),ge=c(pe,4);return W=ge[0],se=ge[2],re=ge[3],J.call(this,function(){return Z.editor.insertText(W,ne,se)},re,W,ne.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(W,ne,ae){this.clipboard.dangerouslyPasteHTML(W,ne,ae)}},{key:"removeFormat",value:function(W,ne,ae){var te=this,re=oe(W,ne,ae),Z=c(re,4);return W=Z[0],ne=Z[1],ae=Z[3],J.call(this,function(){return te.editor.removeFormat(W,ne)},ae,W)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(W){var ne=this,ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:s.default.sources.API;return J.call(this,function(){W=new g.default(W);var te=ne.getLength(),re=ne.editor.deleteText(0,te),Z=ne.editor.applyDelta(W),se=Z.ops[Z.ops.length-1];se!=null&&typeof se.insert=="string"&&se.insert[se.insert.length-1]===`
|
|
146
|
+
`&&(ne.editor.deleteText(ne.getLength()-1,1),Z.delete(1));var pe=re.compose(Z);return pe},ae)}},{key:"setSelection",value:function(W,ne,ae){if(W==null)this.selection.setRange(null,ne||Y.sources.API);else{var te=oe(W,ne,ae),re=c(te,4);W=re[0],ne=re[1],ae=re[3],this.selection.setRange(new y.Range(W,ne),ae),ae!==s.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(W){var ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:s.default.sources.API,ae=new g.default().insert(W);return this.setContents(ae,ne)}},{key:"update",value:function(){var W=arguments.length>0&&arguments[0]!==void 0?arguments[0]:s.default.sources.USER,ne=this.scroll.update(W);return this.selection.update(W),ne}},{key:"updateContents",value:function(W){var ne=this,ae=arguments.length>1&&arguments[1]!==void 0?arguments[1]:s.default.sources.API;return J.call(this,function(){return W=new g.default(W),ne.editor.applyDelta(W,ae)},ae,!0)}}]),Y})();B.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},B.events=s.default.events,B.sources=s.default.sources,B.version="1.3.7",B.imports={delta:g.default,parchment:w.default,"core/module":b.default,"core/theme":z.default};function U(Y,ee){if(ee=(0,k.default)(!0,{container:Y,modules:{clipboard:!0,keyboard:!0,history:!0}},ee),!ee.theme||ee.theme===B.DEFAULTS.theme)ee.theme=z.default;else if(ee.theme=B.import("themes/"+ee.theme),ee.theme==null)throw new Error("Invalid theme "+ee.theme+". Did you register it?");var W=(0,k.default)(!0,{},ee.theme.DEFAULTS);[W,ee].forEach(function(te){te.modules=te.modules||{},Object.keys(te.modules).forEach(function(re){te.modules[re]===!0&&(te.modules[re]={})})});var ne=Object.keys(W.modules).concat(Object.keys(ee.modules)),ae=ne.reduce(function(te,re){var Z=B.import("modules/"+re);return Z==null?F.error("Cannot load "+re+" module. Are you sure you registered it?"):te[re]=Z.DEFAULTS||{},te},{});return ee.modules!=null&&ee.modules.toolbar&&ee.modules.toolbar.constructor!==Object&&(ee.modules.toolbar={container:ee.modules.toolbar}),ee=(0,k.default)(!0,{},B.DEFAULTS,{modules:ae},W,ee),["bounds","container","scrollingContainer"].forEach(function(te){typeof ee[te]=="string"&&(ee[te]=document.querySelector(ee[te]))}),ee.modules=Object.keys(ee.modules).reduce(function(te,re){return ee.modules[re]&&(te[re]=ee.modules[re]),te},{}),ee}function J(Y,ee,W,ne){if(this.options.strict&&!this.isEnabled()&&ee===s.default.sources.USER)return new g.default;var ae=W==null?null:this.getSelection(),te=this.editor.delta,re=Y();if(ae!=null&&(W===!0&&(W=ae.index),ne==null?ae=de(ae,re,ee):ne!==0&&(ae=de(ae,W,ne,ee)),this.setSelection(ae,s.default.sources.SILENT)),re.length()>0){var Z,se=[s.default.events.TEXT_CHANGE,re,te,ee];if((Z=this.emitter).emit.apply(Z,[s.default.events.EDITOR_CHANGE].concat(se)),ee!==s.default.sources.SILENT){var pe;(pe=this.emitter).emit.apply(pe,se)}}return re}function oe(Y,ee,W,ne,ae){var te={};return typeof Y.index=="number"&&typeof Y.length=="number"?typeof ee!="number"?(ae=ne,ne=W,W=ee,ee=Y.length,Y=Y.index):(ee=Y.length,Y=Y.index):typeof ee!="number"&&(ae=ne,ne=W,W=ee,ee=0),(typeof W>"u"?"undefined":l(W))==="object"?(te=W,ae=ne):typeof W=="string"&&(ne!=null?te[W]=ne:ae=W),ae=ae||s.default.sources.API,[Y,ee,te,ae]}function de(Y,ee,W,ne){if(Y==null)return null;var ae=void 0,te=void 0;if(ee instanceof g.default){var re=[Y.index,Y.index+Y.length].map(function(ge){return ee.transformPosition(ge,ne!==s.default.sources.USER)}),Z=c(re,2);ae=Z[0],te=Z[1]}else{var se=[Y.index,Y.index+Y.length].map(function(ge){return ge<ee||ge===ee&&ne===s.default.sources.USER?ge:W>=0?ge+W:Math.max(ee,ge+W)}),pe=c(se,2);ae=pe[0],te=pe[1]}return new y.Range(ae,te-ae)}o.expandConfig=U,o.overload=oe,o.default=B}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function _(w,y){for(var E=0;E<y.length;E++){var x=y[E];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(w,x.key,x)}}return function(w,y,E){return y&&_(w.prototype,y),E&&_(w,E),w}})(),c=function _(w,y,E){w===null&&(w=Function.prototype);var x=Object.getOwnPropertyDescriptor(w,y);if(x===void 0){var k=Object.getPrototypeOf(w);return k===null?void 0:_(k,y,E)}else{if("value"in x)return x.value;var P=x.get;return P===void 0?void 0:P.call(E)}},f=i(7),m=p(f),g=i(0),d=p(g);function p(_){return _&&_.__esModule?_:{default:_}}function h(_,w){if(!(_ instanceof w))throw new TypeError("Cannot call a class as a function")}function s(_,w){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:_}function S(_,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);_.prototype=Object.create(w&&w.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(_,w):_.__proto__=w)}var b=(function(_){S(w,_);function w(){return h(this,w),s(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return l(w,[{key:"formatAt",value:function(E,x,k,P){if(w.compare(this.statics.blotName,k)<0&&d.default.query(k,d.default.Scope.BLOT)){var R=this.isolate(E,x);P&&R.wrap(k,P)}else c(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"formatAt",this).call(this,E,x,k,P)}},{key:"optimize",value:function(E){if(c(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"optimize",this).call(this,E),this.parent instanceof w&&w.compare(this.statics.blotName,this.parent.statics.blotName)>0){var x=this.parent.isolate(this.offset(),this.length());this.moveChildren(x),x.wrap(this)}}}],[{key:"compare",value:function(E,x){var k=w.order.indexOf(E),P=w.order.indexOf(x);return k>=0||P>=0?k-P:E===x?0:E<x?-1:1}}]),w})(d.default.Inline);b.allowedChildren=[b,d.default.Embed,m.default],b.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],o.default=b}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(0),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}function m(h,s){if(!(h instanceof s))throw new TypeError("Cannot call a class as a function")}function g(h,s){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s&&(typeof s=="object"||typeof s=="function")?s:h}function d(h,s){if(typeof s!="function"&&s!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof s);h.prototype=Object.create(s&&s.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),s&&(Object.setPrototypeOf?Object.setPrototypeOf(h,s):h.__proto__=s)}var p=(function(h){d(s,h);function s(){return m(this,s),g(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return s})(c.default.Text);o.default=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function y(E,x){for(var k=0;k<x.length;k++){var P=x[k];P.enumerable=P.enumerable||!1,P.configurable=!0,"value"in P&&(P.writable=!0),Object.defineProperty(E,P.key,P)}}return function(E,x,k){return x&&y(E.prototype,x),k&&y(E,k),E}})(),c=function y(E,x,k){E===null&&(E=Function.prototype);var P=Object.getOwnPropertyDescriptor(E,x);if(P===void 0){var R=Object.getPrototypeOf(E);return R===null?void 0:y(R,x,k)}else{if("value"in P)return P.value;var j=P.get;return j===void 0?void 0:j.call(k)}},f=i(54),m=p(f),g=i(10),d=p(g);function p(y){return y&&y.__esModule?y:{default:y}}function h(y,E){if(!(y instanceof E))throw new TypeError("Cannot call a class as a function")}function s(y,E){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return E&&(typeof E=="object"||typeof E=="function")?E:y}function S(y,E){if(typeof E!="function"&&E!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof E);y.prototype=Object.create(E&&E.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),E&&(Object.setPrototypeOf?Object.setPrototypeOf(y,E):y.__proto__=E)}var b=(0,d.default)("quill:events"),_=["selectionchange","mousedown","mouseup","click"];_.forEach(function(y){document.addEventListener(y,function(){for(var E=arguments.length,x=Array(E),k=0;k<E;k++)x[k]=arguments[k];[].slice.call(document.querySelectorAll(".ql-container")).forEach(function(P){if(P.__quill&&P.__quill.emitter){var R;(R=P.__quill.emitter).handleDOM.apply(R,x)}})})});var w=(function(y){S(E,y);function E(){h(this,E);var x=s(this,(E.__proto__||Object.getPrototypeOf(E)).call(this));return x.listeners={},x.on("error",b.error),x}return l(E,[{key:"emit",value:function(){b.log.apply(b,arguments),c(E.prototype.__proto__||Object.getPrototypeOf(E.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(k){for(var P=arguments.length,R=Array(P>1?P-1:0),j=1;j<P;j++)R[j-1]=arguments[j];(this.listeners[k.type]||[]).forEach(function(z){var L=z.node,M=z.handler;(k.target===L||L.contains(k.target))&&M.apply(void 0,[k].concat(R))})}},{key:"listenDOM",value:function(k,P,R){this.listeners[k]||(this.listeners[k]=[]),this.listeners[k].push({node:P,handler:R})}}]),E})(m.default);w.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},w.sources={API:"api",SILENT:"silent",USER:"user"},o.default=w}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});function l(f,m){if(!(f instanceof m))throw new TypeError("Cannot call a class as a function")}var c=function f(m){var g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};l(this,f),this.quill=m,this.options=g};c.DEFAULTS={},o.default=c}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=["error","warn","log","info"],c="warn";function f(g){if(l.indexOf(g)<=l.indexOf(c)){for(var d,p=arguments.length,h=Array(p>1?p-1:0),s=1;s<p;s++)h[s-1]=arguments[s];(d=console)[g].apply(d,h)}}function m(g){return l.reduce(function(d,p){return d[p]=f.bind(console,p,g),d},{})}f.level=m.level=function(g){c=g},o.default=m}),(function(r,o,i){var l=Array.prototype.slice,c=i(52),f=i(53),m=r.exports=function(h,s,S){return S||(S={}),h===s?!0:h instanceof Date&&s instanceof Date?h.getTime()===s.getTime():!h||!s||typeof h!="object"&&typeof s!="object"?S.strict?h===s:h==s:p(h,s,S)};function g(h){return h==null}function d(h){return!(!h||typeof h!="object"||typeof h.length!="number"||typeof h.copy!="function"||typeof h.slice!="function"||h.length>0&&typeof h[0]!="number")}function p(h,s,S){var b,_;if(g(h)||g(s)||h.prototype!==s.prototype)return!1;if(f(h))return f(s)?(h=l.call(h),s=l.call(s),m(h,s,S)):!1;if(d(h)){if(!d(s)||h.length!==s.length)return!1;for(b=0;b<h.length;b++)if(h[b]!==s[b])return!1;return!0}try{var w=c(h),y=c(s)}catch{return!1}if(w.length!=y.length)return!1;for(w.sort(),y.sort(),b=w.length-1;b>=0;b--)if(w[b]!=y[b])return!1;for(b=w.length-1;b>=0;b--)if(_=w[b],!m(h[_],s[_],S))return!1;return typeof h==typeof s}}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(1),c=(function(){function f(m,g,d){d===void 0&&(d={}),this.attrName=m,this.keyName=g;var p=l.Scope.TYPE&l.Scope.ATTRIBUTE;d.scope!=null?this.scope=d.scope&l.Scope.LEVEL|p:this.scope=l.Scope.ATTRIBUTE,d.whitelist!=null&&(this.whitelist=d.whitelist)}return f.keys=function(m){return[].map.call(m.attributes,function(g){return g.name})},f.prototype.add=function(m,g){return this.canAdd(m,g)?(m.setAttribute(this.keyName,g),!0):!1},f.prototype.canAdd=function(m,g){var d=l.query(m,l.Scope.BLOT&(this.scope|l.Scope.TYPE));return d==null?!1:this.whitelist==null?!0:typeof g=="string"?this.whitelist.indexOf(g.replace(/["']/g,""))>-1:this.whitelist.indexOf(g)>-1},f.prototype.remove=function(m){m.removeAttribute(this.keyName)},f.prototype.value=function(m){var g=m.getAttribute(this.keyName);return this.canAdd(m,g)&&g?g:""},f})();o.default=c}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.Code=void 0;var l=(function(){function j(z,L){var M=[],D=!0,F=!1,B=void 0;try{for(var U=z[Symbol.iterator](),J;!(D=(J=U.next()).done)&&(M.push(J.value),!(L&&M.length===L));D=!0);}catch(oe){F=!0,B=oe}finally{try{!D&&U.return&&U.return()}finally{if(F)throw B}}return M}return function(z,L){if(Array.isArray(z))return z;if(Symbol.iterator in Object(z))return j(z,L);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function j(z,L){for(var M=0;M<L.length;M++){var D=L[M];D.enumerable=D.enumerable||!1,D.configurable=!0,"value"in D&&(D.writable=!0),Object.defineProperty(z,D.key,D)}}return function(z,L,M){return L&&j(z.prototype,L),M&&j(z,M),z}})(),f=function j(z,L,M){z===null&&(z=Function.prototype);var D=Object.getOwnPropertyDescriptor(z,L);if(D===void 0){var F=Object.getPrototypeOf(z);return F===null?void 0:j(F,L,M)}else{if("value"in D)return D.value;var B=D.get;return B===void 0?void 0:B.call(M)}},m=i(2),g=y(m),d=i(0),p=y(d),h=i(4),s=y(h),S=i(6),b=y(S),_=i(7),w=y(_);function y(j){return j&&j.__esModule?j:{default:j}}function E(j,z){if(!(j instanceof z))throw new TypeError("Cannot call a class as a function")}function x(j,z){if(!j)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return z&&(typeof z=="object"||typeof z=="function")?z:j}function k(j,z){if(typeof z!="function"&&z!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof z);j.prototype=Object.create(z&&z.prototype,{constructor:{value:j,enumerable:!1,writable:!0,configurable:!0}}),z&&(Object.setPrototypeOf?Object.setPrototypeOf(j,z):j.__proto__=z)}var P=(function(j){k(z,j);function z(){return E(this,z),x(this,(z.__proto__||Object.getPrototypeOf(z)).apply(this,arguments))}return z})(b.default);P.blotName="code",P.tagName="CODE";var R=(function(j){k(z,j);function z(){return E(this,z),x(this,(z.__proto__||Object.getPrototypeOf(z)).apply(this,arguments))}return c(z,[{key:"delta",value:function(){var M=this,D=this.domNode.textContent;return D.endsWith(`
|
|
147
|
+
`)&&(D=D.slice(0,-1)),D.split(`
|
|
148
|
+
`).reduce(function(F,B){return F.insert(B).insert(`
|
|
149
|
+
`,M.formats())},new g.default)}},{key:"format",value:function(M,D){if(!(M===this.statics.blotName&&D)){var F=this.descendant(w.default,this.length()-1),B=l(F,1),U=B[0];U?.deleteAt(U.length()-1,1),f(z.prototype.__proto__||Object.getPrototypeOf(z.prototype),"format",this).call(this,M,D)}}},{key:"formatAt",value:function(M,D,F,B){if(D!==0&&!(p.default.query(F,p.default.Scope.BLOCK)==null||F===this.statics.blotName&&B===this.statics.formats(this.domNode))){var U=this.newlineIndex(M);if(!(U<0||U>=M+D)){var J=this.newlineIndex(M,!0)+1,oe=U-J+1,de=this.isolate(J,oe),Y=de.next;de.format(F,B),Y instanceof z&&Y.formatAt(0,M-J+D-oe,F,B)}}}},{key:"insertAt",value:function(M,D,F){if(F==null){var B=this.descendant(w.default,M),U=l(B,2),J=U[0],oe=U[1];J.insertAt(oe,D)}}},{key:"length",value:function(){var M=this.domNode.textContent.length;return this.domNode.textContent.endsWith(`
|
|
150
|
+
`)?M:M+1}},{key:"newlineIndex",value:function(M){var D=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(D)return this.domNode.textContent.slice(0,M).lastIndexOf(`
|
|
151
|
+
`);var F=this.domNode.textContent.slice(M).indexOf(`
|
|
152
|
+
`);return F>-1?M+F:-1}},{key:"optimize",value:function(M){this.domNode.textContent.endsWith(`
|
|
153
|
+
`)||this.appendChild(p.default.create("text",`
|
|
154
|
+
`)),f(z.prototype.__proto__||Object.getPrototypeOf(z.prototype),"optimize",this).call(this,M);var D=this.next;D!=null&&D.prev===this&&D.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===D.statics.formats(D.domNode)&&(D.optimize(M),D.moveChildren(this),D.remove())}},{key:"replace",value:function(M){f(z.prototype.__proto__||Object.getPrototypeOf(z.prototype),"replace",this).call(this,M),[].slice.call(this.domNode.querySelectorAll("*")).forEach(function(D){var F=p.default.find(D);F==null?D.parentNode.removeChild(D):F instanceof p.default.Embed?F.remove():F.unwrap()})}}],[{key:"create",value:function(M){var D=f(z.__proto__||Object.getPrototypeOf(z),"create",this).call(this,M);return D.setAttribute("spellcheck",!1),D}},{key:"formats",value:function(){return!0}}]),z})(s.default);R.blotName="code-block",R.tagName="PRE",R.TAB=" ",o.Code=P,o.default=R}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Y){return typeof Y}:function(Y){return Y&&typeof Symbol=="function"&&Y.constructor===Symbol&&Y!==Symbol.prototype?"symbol":typeof Y},c=(function(){function Y(ee,W){var ne=[],ae=!0,te=!1,re=void 0;try{for(var Z=ee[Symbol.iterator](),se;!(ae=(se=Z.next()).done)&&(ne.push(se.value),!(W&&ne.length===W));ae=!0);}catch(pe){te=!0,re=pe}finally{try{!ae&&Z.return&&Z.return()}finally{if(te)throw re}}return ne}return function(ee,W){if(Array.isArray(ee))return ee;if(Symbol.iterator in Object(ee))return Y(ee,W);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),f=(function(){function Y(ee,W){for(var ne=0;ne<W.length;ne++){var ae=W[ne];ae.enumerable=ae.enumerable||!1,ae.configurable=!0,"value"in ae&&(ae.writable=!0),Object.defineProperty(ee,ae.key,ae)}}return function(ee,W,ne){return W&&Y(ee.prototype,W),ne&&Y(ee,ne),ee}})(),m=i(2),g=D(m),d=i(20),p=D(d),h=i(0),s=D(h),S=i(13),b=D(S),_=i(24),w=D(_),y=i(4),E=D(y),x=i(16),k=D(x),P=i(21),R=D(P),j=i(11),z=D(j),L=i(3),M=D(L);function D(Y){return Y&&Y.__esModule?Y:{default:Y}}function F(Y,ee,W){return ee in Y?Object.defineProperty(Y,ee,{value:W,enumerable:!0,configurable:!0,writable:!0}):Y[ee]=W,Y}function B(Y,ee){if(!(Y instanceof ee))throw new TypeError("Cannot call a class as a function")}var U=/^[ -~]*$/,J=(function(){function Y(ee){B(this,Y),this.scroll=ee,this.delta=this.getDelta()}return f(Y,[{key:"applyDelta",value:function(W){var ne=this,ae=!1;this.scroll.update();var te=this.scroll.length();return this.scroll.batchStart(),W=de(W),W.reduce(function(re,Z){var se=Z.retain||Z.delete||Z.insert.length||1,pe=Z.attributes||{};if(Z.insert!=null){if(typeof Z.insert=="string"){var ge=Z.insert;ge.endsWith(`
|
|
155
|
+
`)&&ae&&(ae=!1,ge=ge.slice(0,-1)),re>=te&&!ge.endsWith(`
|
|
156
|
+
`)&&(ae=!0),ne.scroll.insertAt(re,ge);var be=ne.scroll.line(re),Ae=c(be,2),Ue=Ae[0],Ve=Ae[1],Fe=(0,M.default)({},(0,y.bubbleFormats)(Ue));if(Ue instanceof E.default){var Pe=Ue.descendant(s.default.Leaf,Ve),ut=c(Pe,1),Ce=ut[0];Fe=(0,M.default)(Fe,(0,y.bubbleFormats)(Ce))}pe=p.default.attributes.diff(Fe,pe)||{}}else if(l(Z.insert)==="object"){var we=Object.keys(Z.insert)[0];if(we==null)return re;ne.scroll.insertAt(re,we,Z.insert[we])}te+=se}return Object.keys(pe).forEach(function(xe){ne.scroll.formatAt(re,se,xe,pe[xe])}),re+se},0),W.reduce(function(re,Z){return typeof Z.delete=="number"?(ne.scroll.deleteAt(re,Z.delete),re):re+(Z.retain||Z.insert.length||1)},0),this.scroll.batchEnd(),this.update(W)}},{key:"deleteText",value:function(W,ne){return this.scroll.deleteAt(W,ne),this.update(new g.default().retain(W).delete(ne))}},{key:"formatLine",value:function(W,ne){var ae=this,te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this.scroll.update(),Object.keys(te).forEach(function(re){if(!(ae.scroll.whitelist!=null&&!ae.scroll.whitelist[re])){var Z=ae.scroll.lines(W,Math.max(ne,1)),se=ne;Z.forEach(function(pe){var ge=pe.length();if(!(pe instanceof b.default))pe.format(re,te[re]);else{var be=W-pe.offset(ae.scroll),Ae=pe.newlineIndex(be+se)-be+1;pe.formatAt(be,Ae,re,te[re])}se-=ge})}}),this.scroll.optimize(),this.update(new g.default().retain(W).retain(ne,(0,R.default)(te)))}},{key:"formatText",value:function(W,ne){var ae=this,te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return Object.keys(te).forEach(function(re){ae.scroll.formatAt(W,ne,re,te[re])}),this.update(new g.default().retain(W).retain(ne,(0,R.default)(te)))}},{key:"getContents",value:function(W,ne){return this.delta.slice(W,W+ne)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce(function(W,ne){return W.concat(ne.delta())},new g.default)}},{key:"getFormat",value:function(W){var ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,ae=[],te=[];ne===0?this.scroll.path(W).forEach(function(Z){var se=c(Z,1),pe=se[0];pe instanceof E.default?ae.push(pe):pe instanceof s.default.Leaf&&te.push(pe)}):(ae=this.scroll.lines(W,ne),te=this.scroll.descendants(s.default.Leaf,W,ne));var re=[ae,te].map(function(Z){if(Z.length===0)return{};for(var se=(0,y.bubbleFormats)(Z.shift());Object.keys(se).length>0;){var pe=Z.shift();if(pe==null)return se;se=oe((0,y.bubbleFormats)(pe),se)}return se});return M.default.apply(M.default,re)}},{key:"getText",value:function(W,ne){return this.getContents(W,ne).filter(function(ae){return typeof ae.insert=="string"}).map(function(ae){return ae.insert}).join("")}},{key:"insertEmbed",value:function(W,ne,ae){return this.scroll.insertAt(W,ne,ae),this.update(new g.default().retain(W).insert(F({},ne,ae)))}},{key:"insertText",value:function(W,ne){var ae=this,te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return ne=ne.replace(/\r\n/g,`
|
|
50
157
|
`).replace(/\r/g,`
|
|
51
|
-
`),this.scroll.insertAt(
|
|
52
|
-
`));var
|
|
158
|
+
`),this.scroll.insertAt(W,ne),Object.keys(te).forEach(function(re){ae.scroll.formatAt(W,ne.length,re,te[re])}),this.update(new g.default().retain(W).insert(ne,(0,R.default)(te)))}},{key:"isBlank",value:function(){if(this.scroll.children.length==0)return!0;if(this.scroll.children.length>1)return!1;var W=this.scroll.children.head;return W.statics.blotName!==E.default.blotName||W.children.length>1?!1:W.children.head instanceof k.default}},{key:"removeFormat",value:function(W,ne){var ae=this.getText(W,ne),te=this.scroll.line(W+ne),re=c(te,2),Z=re[0],se=re[1],pe=0,ge=new g.default;Z!=null&&(Z instanceof b.default?pe=Z.newlineIndex(se)-se+1:pe=Z.length()-se,ge=Z.delta().slice(se,se+pe-1).insert(`
|
|
159
|
+
`));var be=this.getContents(W,ne+pe),Ae=be.diff(new g.default().insert(ae).concat(ge)),Ue=new g.default().retain(W).concat(Ae);return this.applyDelta(Ue)}},{key:"update",value:function(W){var ne=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],ae=arguments.length>2&&arguments[2]!==void 0?arguments[2]:void 0,te=this.delta;if(ne.length===1&&ne[0].type==="characterData"&&ne[0].target.data.match(U)&&s.default.find(ne[0].target)){var re=s.default.find(ne[0].target),Z=(0,y.bubbleFormats)(re),se=re.offset(this.scroll),pe=ne[0].oldValue.replace(w.default.CONTENTS,""),ge=new g.default().insert(pe),be=new g.default().insert(re.value()),Ae=new g.default().retain(se).concat(ge.diff(be,ae));W=Ae.reduce(function(Ue,Ve){return Ve.insert?Ue.insert(Ve.insert,Z):Ue.push(Ve)},new g.default),this.delta=te.compose(W)}else this.delta=this.getDelta(),(!W||!(0,z.default)(te.compose(W),this.delta))&&(W=te.diff(this.delta,ae));return W}}]),Y})();function oe(Y,ee){return Object.keys(ee).reduce(function(W,ne){return Y[ne]==null||(ee[ne]===Y[ne]?W[ne]=ee[ne]:Array.isArray(ee[ne])?ee[ne].indexOf(Y[ne])<0&&(W[ne]=ee[ne].concat([Y[ne]])):W[ne]=[ee[ne],Y[ne]]),W},{})}function de(Y){return Y.reduce(function(ee,W){if(W.insert===1){var ne=(0,R.default)(W.attributes);return delete ne.image,ee.insert({image:W.attributes.image},ne)}if(W.attributes!=null&&(W.attributes.list===!0||W.attributes.bullet===!0)&&(W=(0,R.default)(W),W.attributes.list?W.attributes.list="ordered":(W.attributes.list="bullet",delete W.attributes.bullet)),typeof W.insert=="string"){var ae=W.insert.replace(/\r\n/g,`
|
|
53
160
|
`).replace(/\r/g,`
|
|
54
|
-
`);return W.insert(re,z.attributes)}return W.push(z)},new h.default)}r.default=U}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.Range=void 0;var s=(function(){function M(j,I){var A=[],q=!0,R=!1,k=void 0;try{for(var F=j[Symbol.iterator](),U;!(q=(U=F.next()).done)&&(A.push(U.value),!(I&&A.length===I));q=!0);}catch(ne){R=!0,k=ne}finally{try{!q&&F.return&&F.return()}finally{if(R)throw k}}return A}return function(j,I){if(Array.isArray(j))return j;if(Symbol.iterator in Object(j))return M(j,I);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=(function(){function M(j,I){for(var A=0;A<I.length;A++){var q=I[A];q.enumerable=q.enumerable||!1,q.configurable=!0,"value"in q&&(q.writable=!0),Object.defineProperty(j,q.key,q)}}return function(j,I,A){return I&&M(j.prototype,I),A&&M(j,A),j}})(),c=o(0),f=y(c),h=o(21),a=y(h),u=o(11),d=y(u),p=o(8),O=y(p),g=o(10),_=y(g);function y(M){return M&&M.__esModule?M:{default:M}}function w(M){if(Array.isArray(M)){for(var j=0,I=Array(M.length);j<M.length;j++)I[j]=M[j];return I}else return Array.from(M)}function E(M,j){if(!(M instanceof j))throw new TypeError("Cannot call a class as a function")}var m=(0,_.default)("quill:selection"),S=function M(j){var I=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;E(this,M),this.index=j,this.length=I},C=(function(){function M(j,I){var A=this;E(this,M),this.emitter=I,this.scroll=j,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=f.default.create("cursor",this),this.lastRange=this.savedRange=new S(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){A.mouseDown||setTimeout(A.update.bind(A,O.default.sources.USER),1)}),this.emitter.on(O.default.events.EDITOR_CHANGE,function(q,R){q===O.default.events.TEXT_CHANGE&&R.length()>0&&A.update(O.default.sources.SILENT)}),this.emitter.on(O.default.events.SCROLL_BEFORE_UPDATE,function(){if(A.hasFocus()){var q=A.getNativeRange();q!=null&&q.start.node!==A.cursor.textNode&&A.emitter.once(O.default.events.SCROLL_UPDATE,function(){try{A.setNativeRange(q.start.node,q.start.offset,q.end.node,q.end.offset)}catch{}})}}),this.emitter.on(O.default.events.SCROLL_OPTIMIZE,function(q,R){if(R.range){var k=R.range,F=k.startNode,U=k.startOffset,ne=k.endNode,ue=k.endOffset;A.setNativeRange(F,U,ne,ue)}}),this.update(O.default.sources.SILENT)}return l(M,[{key:"handleComposition",value:function(){var I=this;this.root.addEventListener("compositionstart",function(){I.composing=!0}),this.root.addEventListener("compositionend",function(){if(I.composing=!1,I.cursor.parent){var A=I.cursor.restore();if(!A)return;setTimeout(function(){I.setNativeRange(A.startNode,A.startOffset,A.endNode,A.endOffset)},1)}})}},{key:"handleDragging",value:function(){var I=this;this.emitter.listenDOM("mousedown",document.body,function(){I.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){I.mouseDown=!1,I.update(O.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(I,A){if(!(this.scroll.whitelist!=null&&!this.scroll.whitelist[I])){this.scroll.update();var q=this.getNativeRange();if(!(q==null||!q.native.collapsed||f.default.query(I,f.default.Scope.BLOCK))){if(q.start.node!==this.cursor.textNode){var R=f.default.find(q.start.node,!1);if(R==null)return;if(R instanceof f.default.Leaf){var k=R.split(q.start.offset);R.parent.insertBefore(this.cursor,k)}else R.insertBefore(this.cursor,q.start.node);this.cursor.attach()}this.cursor.format(I,A),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(I){var A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,q=this.scroll.length();I=Math.min(I,q-1),A=Math.min(I+A,q-1)-I;var R=void 0,k=this.scroll.leaf(I),F=s(k,2),U=F[0],ne=F[1];if(U==null)return null;var ue=U.position(ne,!0),K=s(ue,2);R=K[0],ne=K[1];var W=document.createRange();if(A>0){W.setStart(R,ne);var z=this.scroll.leaf(I+A),Q=s(z,2);if(U=Q[0],ne=Q[1],U==null)return null;var re=U.position(ne,!0),Z=s(re,2);return R=Z[0],ne=Z[1],W.setEnd(R,ne),W.getBoundingClientRect()}else{var X="left",H=void 0;return R instanceof Text?(ne<R.data.length?(W.setStart(R,ne),W.setEnd(R,ne+1)):(W.setStart(R,ne-1),W.setEnd(R,ne),X="right"),H=W.getBoundingClientRect()):(H=U.domNode.getBoundingClientRect(),ne>0&&(X="right")),{bottom:H.top+H.height,height:H.height,left:H[X],right:H[X],top:H.top,width:0}}}},{key:"getNativeRange",value:function(){var I=document.getSelection();if(I==null||I.rangeCount<=0)return null;var A=I.getRangeAt(0);if(A==null)return null;var q=this.normalizeNative(A);return m.info("getNativeRange",q),q}},{key:"getRange",value:function(){var I=this.getNativeRange();if(I==null)return[null,null];var A=this.normalizedToRange(I);return[A,I]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(I){var A=this,q=[[I.start.node,I.start.offset]];I.native.collapsed||q.push([I.end.node,I.end.offset]);var R=q.map(function(U){var ne=s(U,2),ue=ne[0],K=ne[1],W=f.default.find(ue,!0),z=W.offset(A.scroll);return K===0?z:W instanceof f.default.Container?z+W.length():z+W.index(ue,K)}),k=Math.min(Math.max.apply(Math,w(R)),this.scroll.length()-1),F=Math.min.apply(Math,[k].concat(w(R)));return new S(F,k-F)}},{key:"normalizeNative",value:function(I){if(!N(this.root,I.startContainer)||!I.collapsed&&!N(this.root,I.endContainer))return null;var A={start:{node:I.startContainer,offset:I.startOffset},end:{node:I.endContainer,offset:I.endOffset},native:I};return[A.start,A.end].forEach(function(q){for(var R=q.node,k=q.offset;!(R instanceof Text)&&R.childNodes.length>0;)if(R.childNodes.length>k)R=R.childNodes[k],k=0;else if(R.childNodes.length===k)R=R.lastChild,k=R instanceof Text?R.data.length:R.childNodes.length+1;else break;q.node=R,q.offset=k}),A}},{key:"rangeToNative",value:function(I){var A=this,q=I.collapsed?[I.index]:[I.index,I.index+I.length],R=[],k=this.scroll.length();return q.forEach(function(F,U){F=Math.min(k-1,F);var ne=void 0,ue=A.scroll.leaf(F),K=s(ue,2),W=K[0],z=K[1],Q=W.position(z,U!==0),re=s(Q,2);ne=re[0],z=re[1],R.push(ne,z)}),R.length<2&&(R=R.concat(R)),R}},{key:"scrollIntoView",value:function(I){var A=this.lastRange;if(A!=null){var q=this.getBounds(A.index,A.length);if(q!=null){var R=this.scroll.length()-1,k=this.scroll.line(Math.min(A.index,R)),F=s(k,1),U=F[0],ne=U;if(A.length>0){var ue=this.scroll.line(Math.min(A.index+A.length,R)),K=s(ue,1);ne=K[0]}if(!(U==null||ne==null)){var W=I.getBoundingClientRect();q.top<W.top?I.scrollTop-=W.top-q.top:q.bottom>W.bottom&&(I.scrollTop+=q.bottom-W.bottom)}}}}},{key:"setNativeRange",value:function(I,A){var q=arguments.length>2&&arguments[2]!==void 0?arguments[2]:I,R=arguments.length>3&&arguments[3]!==void 0?arguments[3]:A,k=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(m.info("setNativeRange",I,A,q,R),!(I!=null&&(this.root.parentNode==null||I.parentNode==null||q.parentNode==null))){var F=document.getSelection();if(F!=null)if(I!=null){this.hasFocus()||this.root.focus();var U=(this.getNativeRange()||{}).native;if(U==null||k||I!==U.startContainer||A!==U.startOffset||q!==U.endContainer||R!==U.endOffset){I.tagName=="BR"&&(A=[].indexOf.call(I.parentNode.childNodes,I),I=I.parentNode),q.tagName=="BR"&&(R=[].indexOf.call(q.parentNode.childNodes,q),q=q.parentNode);var ne=document.createRange();ne.setStart(I,A),ne.setEnd(q,R),F.removeAllRanges(),F.addRange(ne)}}else F.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(I){var A=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,q=arguments.length>2&&arguments[2]!==void 0?arguments[2]:O.default.sources.API;if(typeof A=="string"&&(q=A,A=!1),m.info("setRange",I),I!=null){var R=this.rangeToNative(I);this.setNativeRange.apply(this,w(R).concat([A]))}else this.setNativeRange(null);this.update(q)}},{key:"update",value:function(){var I=arguments.length>0&&arguments[0]!==void 0?arguments[0]:O.default.sources.USER,A=this.lastRange,q=this.getRange(),R=s(q,2),k=R[0],F=R[1];if(this.lastRange=k,this.lastRange!=null&&(this.savedRange=this.lastRange),!(0,d.default)(A,this.lastRange)){var U;!this.composing&&F!=null&&F.native.collapsed&&F.start.node!==this.cursor.textNode&&this.cursor.restore();var ne=[O.default.events.SELECTION_CHANGE,(0,a.default)(this.lastRange),(0,a.default)(A),I];if((U=this.emitter).emit.apply(U,[O.default.events.EDITOR_CHANGE].concat(ne)),I!==O.default.sources.SILENT){var ue;(ue=this.emitter).emit.apply(ue,ne)}}}}]),M})();function N(M,j){try{j.parentNode}catch{return!1}return j instanceof Text&&(j=j.parentNode),M.contains(j)}r.Range=S,r.default=C}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function O(g,_){for(var y=0;y<_.length;y++){var w=_[y];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(g,w.key,w)}}return function(g,_,y){return _&&O(g.prototype,_),y&&O(g,y),g}})(),l=function O(g,_,y){g===null&&(g=Function.prototype);var w=Object.getOwnPropertyDescriptor(g,_);if(w===void 0){var E=Object.getPrototypeOf(g);return E===null?void 0:O(E,_,y)}else{if("value"in w)return w.value;var m=w.get;return m===void 0?void 0:m.call(y)}},c=o(0),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(){return a(this,g),u(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"insertInto",value:function(y,w){y.children.length===0?l(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"insertInto",this).call(this,y,w):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),g})(f.default.Embed);p.blotName="break",p.tagName="BR",r.default=p}),(function(n,r,o){var s=this&&this.__extends||(function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var O in p)p.hasOwnProperty(O)&&(d[O]=p[O])};return function(d,p){u(d,p);function O(){this.constructor=d}d.prototype=p===null?Object.create(p):(O.prototype=p.prototype,new O)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(44),c=o(30),f=o(1),h=(function(u){s(d,u);function d(p){var O=u.call(this,p)||this;return O.build(),O}return d.prototype.appendChild=function(p){this.insertBefore(p)},d.prototype.attach=function(){u.prototype.attach.call(this),this.children.forEach(function(p){p.attach()})},d.prototype.build=function(){var p=this;this.children=new l.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(O){try{var g=a(O);p.insertBefore(g,p.children.head||void 0)}catch(_){if(_ instanceof f.ParchmentError)return;throw _}})},d.prototype.deleteAt=function(p,O){if(p===0&&O===this.length())return this.remove();this.children.forEachAt(p,O,function(g,_,y){g.deleteAt(_,y)})},d.prototype.descendant=function(p,O){var g=this.children.find(O),_=g[0],y=g[1];return p.blotName==null&&p(_)||p.blotName!=null&&_ instanceof p?[_,y]:_ instanceof d?_.descendant(p,y):[null,-1]},d.prototype.descendants=function(p,O,g){O===void 0&&(O=0),g===void 0&&(g=Number.MAX_VALUE);var _=[],y=g;return this.children.forEachAt(O,g,function(w,E,m){(p.blotName==null&&p(w)||p.blotName!=null&&w instanceof p)&&_.push(w),w instanceof d&&(_=_.concat(w.descendants(p,E,y))),y-=m}),_},d.prototype.detach=function(){this.children.forEach(function(p){p.detach()}),u.prototype.detach.call(this)},d.prototype.formatAt=function(p,O,g,_){this.children.forEachAt(p,O,function(y,w,E){y.formatAt(w,E,g,_)})},d.prototype.insertAt=function(p,O,g){var _=this.children.find(p),y=_[0],w=_[1];if(y)y.insertAt(w,O,g);else{var E=g==null?f.create("text",O):f.create(O,g);this.appendChild(E)}},d.prototype.insertBefore=function(p,O){if(this.statics.allowedChildren!=null&&!this.statics.allowedChildren.some(function(g){return p instanceof g}))throw new f.ParchmentError("Cannot insert "+p.statics.blotName+" into "+this.statics.blotName);p.insertInto(this,O)},d.prototype.length=function(){return this.children.reduce(function(p,O){return p+O.length()},0)},d.prototype.moveChildren=function(p,O){this.children.forEach(function(g){p.insertBefore(g,O)})},d.prototype.optimize=function(p){if(u.prototype.optimize.call(this,p),this.children.length===0)if(this.statics.defaultChild!=null){var O=f.create(this.statics.defaultChild);this.appendChild(O),O.optimize(p)}else this.remove()},d.prototype.path=function(p,O){O===void 0&&(O=!1);var g=this.children.find(p,O),_=g[0],y=g[1],w=[[this,p]];return _ instanceof d?w.concat(_.path(y,O)):(_!=null&&w.push([_,y]),w)},d.prototype.removeChild=function(p){this.children.remove(p)},d.prototype.replace=function(p){p instanceof d&&p.moveChildren(this),u.prototype.replace.call(this,p)},d.prototype.split=function(p,O){if(O===void 0&&(O=!1),!O){if(p===0)return this;if(p===this.length())return this.next}var g=this.clone();return this.parent.insertBefore(g,this.next),this.children.forEachAt(p,this.length(),function(_,y,w){_=_.split(y,O),g.appendChild(_)}),g},d.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},d.prototype.update=function(p,O){var g=this,_=[],y=[];p.forEach(function(w){w.target===g.domNode&&w.type==="childList"&&(_.push.apply(_,w.addedNodes),y.push.apply(y,w.removedNodes))}),y.forEach(function(w){if(!(w.parentNode!=null&&w.tagName!=="IFRAME"&&document.body.compareDocumentPosition(w)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var E=f.find(w);E!=null&&(E.domNode.parentNode==null||E.domNode.parentNode===g.domNode)&&E.detach()}}),_.filter(function(w){return w.parentNode==g.domNode}).sort(function(w,E){return w===E?0:w.compareDocumentPosition(E)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(w){var E=null;w.nextSibling!=null&&(E=f.find(w.nextSibling));var m=a(w);(m.next!=E||m.next==null)&&(m.parent!=null&&m.parent.removeChild(g),g.insertBefore(m,E||void 0))})},d})(c.default);function a(u){var d=f.find(u);if(d==null)try{d=f.create(u)}catch{d=f.create(f.Scope.INLINE),[].slice.call(u.childNodes).forEach(function(O){d.domNode.appendChild(O)}),u.parentNode&&u.parentNode.replaceChild(d.domNode,u),d.attach()}return d}r.default=h}),(function(n,r,o){var s=this&&this.__extends||(function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var O in p)p.hasOwnProperty(O)&&(d[O]=p[O])};return function(d,p){u(d,p);function O(){this.constructor=d}d.prototype=p===null?Object.create(p):(O.prototype=p.prototype,new O)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(12),c=o(31),f=o(17),h=o(1),a=(function(u){s(d,u);function d(p){var O=u.call(this,p)||this;return O.attributes=new c.default(O.domNode),O}return d.formats=function(p){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return p.tagName.toLowerCase()},d.prototype.format=function(p,O){var g=h.query(p);g instanceof l.default?this.attributes.attribute(g,O):O&&g!=null&&(p!==this.statics.blotName||this.formats()[p]!==O)&&this.replaceWith(p,O)},d.prototype.formats=function(){var p=this.attributes.values(),O=this.statics.formats(this.domNode);return O!=null&&(p[this.statics.blotName]=O),p},d.prototype.replaceWith=function(p,O){var g=u.prototype.replaceWith.call(this,p,O);return this.attributes.copy(g),g},d.prototype.update=function(p,O){var g=this;u.prototype.update.call(this,p,O),p.some(function(_){return _.target===g.domNode&&_.type==="attributes"})&&this.attributes.build()},d.prototype.wrap=function(p,O){var g=u.prototype.wrap.call(this,p,O);return g instanceof d&&g.statics.scope===this.statics.scope&&this.attributes.move(g),g},d})(f.default);r.default=a}),(function(n,r,o){var s=this&&this.__extends||(function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,u){a.__proto__=u}||function(a,u){for(var d in u)u.hasOwnProperty(d)&&(a[d]=u[d])};return function(a,u){h(a,u);function d(){this.constructor=a}a.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(30),c=o(1),f=(function(h){s(a,h);function a(){return h!==null&&h.apply(this,arguments)||this}return a.value=function(u){return!0},a.prototype.index=function(u,d){return this.domNode===u||this.domNode.compareDocumentPosition(u)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(d,1):-1},a.prototype.position=function(u,d){var p=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return u>0&&(p+=1),[this.parent.domNode,p]},a.prototype.value=function(){var u;return u={},u[this.statics.blotName]=this.statics.value(this.domNode)||!0,u},a.scope=c.Scope.INLINE_BLOT,a})(l.default);r.default=f}),(function(n,r,o){var s=o(11),l=o(3),c={attributes:{compose:function(h,a,u){typeof h!="object"&&(h={}),typeof a!="object"&&(a={});var d=l(!0,{},a);u||(d=Object.keys(d).reduce(function(O,g){return d[g]!=null&&(O[g]=d[g]),O},{}));for(var p in h)h[p]!==void 0&&a[p]===void 0&&(d[p]=h[p]);return Object.keys(d).length>0?d:void 0},diff:function(h,a){typeof h!="object"&&(h={}),typeof a!="object"&&(a={});var u=Object.keys(h).concat(Object.keys(a)).reduce(function(d,p){return s(h[p],a[p])||(d[p]=a[p]===void 0?null:a[p]),d},{});return Object.keys(u).length>0?u:void 0},transform:function(h,a,u){if(typeof h!="object")return a;if(typeof a=="object"){if(!u)return a;var d=Object.keys(a).reduce(function(p,O){return h[O]===void 0&&(p[O]=a[O]),p},{});return Object.keys(d).length>0?d:void 0}}},iterator:function(h){return new f(h)},length:function(h){return typeof h.delete=="number"?h.delete:typeof h.retain=="number"?h.retain:typeof h.insert=="string"?h.insert.length:1}};function f(h){this.ops=h,this.index=0,this.offset=0}f.prototype.hasNext=function(){return this.peekLength()<1/0},f.prototype.next=function(h){h||(h=1/0);var a=this.ops[this.index];if(a){var u=this.offset,d=c.length(a);if(h>=d-u?(h=d-u,this.index+=1,this.offset=0):this.offset+=h,typeof a.delete=="number")return{delete:h};var p={};return a.attributes&&(p.attributes=a.attributes),typeof a.retain=="number"?p.retain=h:typeof a.insert=="string"?p.insert=a.insert.substr(u,h):p.insert=a.insert,p}else return{retain:1/0}},f.prototype.peek=function(){return this.ops[this.index]},f.prototype.peekLength=function(){return this.ops[this.index]?c.length(this.ops[this.index])-this.offset:1/0},f.prototype.peekType=function(){return this.ops[this.index]?typeof this.ops[this.index].delete=="number"?"delete":typeof this.ops[this.index].retain=="number"?"retain":"insert":"retain"},f.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var h=this.offset,a=this.index,u=this.next(),d=this.ops.slice(this.index);return this.offset=h,this.index=a,[u].concat(d)}else return[]},n.exports=c}),(function(n,r){var o=(function(){function s(g,_){return _!=null&&g instanceof _}var l;try{l=Map}catch{l=function(){}}var c;try{c=Set}catch{c=function(){}}var f;try{f=Promise}catch{f=function(){}}function h(g,_,y,w,E){typeof _=="object"&&(y=_.depth,w=_.prototype,E=_.includeNonEnumerable,_=_.circular);var m=[],S=[],C=typeof Buffer<"u";typeof _>"u"&&(_=!0),typeof y>"u"&&(y=1/0);function N(M,j){if(M===null)return null;if(j===0)return M;var I,A;if(typeof M!="object")return M;if(s(M,l))I=new l;else if(s(M,c))I=new c;else if(s(M,f))I=new f(function(W,z){M.then(function(Q){W(N(Q,j-1))},function(Q){z(N(Q,j-1))})});else if(h.__isArray(M))I=[];else if(h.__isRegExp(M))I=new RegExp(M.source,O(M)),M.lastIndex&&(I.lastIndex=M.lastIndex);else if(h.__isDate(M))I=new Date(M.getTime());else{if(C&&Buffer.isBuffer(M))return Buffer.allocUnsafe?I=Buffer.allocUnsafe(M.length):I=new Buffer(M.length),M.copy(I),I;s(M,Error)?I=Object.create(M):typeof w>"u"?(A=Object.getPrototypeOf(M),I=Object.create(A)):(I=Object.create(w),A=w)}if(_){var q=m.indexOf(M);if(q!=-1)return S[q];m.push(M),S.push(I)}s(M,l)&&M.forEach(function(W,z){var Q=N(z,j-1),re=N(W,j-1);I.set(Q,re)}),s(M,c)&&M.forEach(function(W){var z=N(W,j-1);I.add(z)});for(var R in M){var k;A&&(k=Object.getOwnPropertyDescriptor(A,R)),!(k&&k.set==null)&&(I[R]=N(M[R],j-1))}if(Object.getOwnPropertySymbols)for(var F=Object.getOwnPropertySymbols(M),R=0;R<F.length;R++){var U=F[R],ne=Object.getOwnPropertyDescriptor(M,U);ne&&!ne.enumerable&&!E||(I[U]=N(M[U],j-1),ne.enumerable||Object.defineProperty(I,U,{enumerable:!1}))}if(E)for(var ue=Object.getOwnPropertyNames(M),R=0;R<ue.length;R++){var K=ue[R],ne=Object.getOwnPropertyDescriptor(M,K);ne&&ne.enumerable||(I[K]=N(M[K],j-1),Object.defineProperty(I,K,{enumerable:!1}))}return I}return N(g,y)}h.clonePrototype=function(_){if(_===null)return null;var y=function(){};return y.prototype=_,new y};function a(g){return Object.prototype.toString.call(g)}h.__objToStr=a;function u(g){return typeof g=="object"&&a(g)==="[object Date]"}h.__isDate=u;function d(g){return typeof g=="object"&&a(g)==="[object Array]"}h.__isArray=d;function p(g){return typeof g=="object"&&a(g)==="[object RegExp]"}h.__isRegExp=p;function O(g){var _="";return g.global&&(_+="g"),g.ignoreCase&&(_+="i"),g.multiline&&(_+="m"),_}return h.__getRegExpFlags=O,h})();typeof n=="object"&&n.exports&&(n.exports=o)}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function I(A,q){var R=[],k=!0,F=!1,U=void 0;try{for(var ne=A[Symbol.iterator](),ue;!(k=(ue=ne.next()).done)&&(R.push(ue.value),!(q&&R.length===q));k=!0);}catch(K){F=!0,U=K}finally{try{!k&&ne.return&&ne.return()}finally{if(F)throw U}}return R}return function(A,q){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return I(A,q);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=(function(){function I(A,q){for(var R=0;R<q.length;R++){var k=q[R];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(A,k.key,k)}}return function(A,q,R){return q&&I(A.prototype,q),R&&I(A,R),A}})(),c=function I(A,q,R){A===null&&(A=Function.prototype);var k=Object.getOwnPropertyDescriptor(A,q);if(k===void 0){var F=Object.getPrototypeOf(A);return F===null?void 0:I(F,q,R)}else{if("value"in k)return k.value;var U=k.get;return U===void 0?void 0:U.call(R)}},f=o(0),h=m(f),a=o(8),u=m(a),d=o(4),p=m(d),O=o(16),g=m(O),_=o(13),y=m(_),w=o(25),E=m(w);function m(I){return I&&I.__esModule?I:{default:I}}function S(I,A){if(!(I instanceof A))throw new TypeError("Cannot call a class as a function")}function C(I,A){if(!I)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return A&&(typeof A=="object"||typeof A=="function")?A:I}function N(I,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof A);I.prototype=Object.create(A&&A.prototype,{constructor:{value:I,enumerable:!1,writable:!0,configurable:!0}}),A&&(Object.setPrototypeOf?Object.setPrototypeOf(I,A):I.__proto__=A)}function M(I){return I instanceof p.default||I instanceof d.BlockEmbed}var j=(function(I){N(A,I);function A(q,R){S(this,A);var k=C(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,q));return k.emitter=R.emitter,Array.isArray(R.whitelist)&&(k.whitelist=R.whitelist.reduce(function(F,U){return F[U]=!0,F},{})),k.domNode.addEventListener("DOMNodeInserted",function(){}),k.optimize(),k.enable(),k}return l(A,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(R,k){var F=this.line(R),U=s(F,2),ne=U[0],ue=U[1],K=this.line(R+k),W=s(K,1),z=W[0];if(c(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"deleteAt",this).call(this,R,k),z!=null&&ne!==z&&ue>0){if(ne instanceof d.BlockEmbed||z instanceof d.BlockEmbed){this.optimize();return}if(ne instanceof y.default){var Q=ne.newlineIndex(ne.length(),!0);if(Q>-1&&(ne=ne.split(Q+1),ne===z)){this.optimize();return}}else if(z instanceof y.default){var re=z.newlineIndex(0);re>-1&&z.split(re+1)}var Z=z.children.head instanceof g.default?null:z.children.head;ne.moveChildren(z,Z),ne.remove()}this.optimize()}},{key:"enable",value:function(){var R=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",R)}},{key:"formatAt",value:function(R,k,F,U){this.whitelist!=null&&!this.whitelist[F]||(c(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"formatAt",this).call(this,R,k,F,U),this.optimize())}},{key:"insertAt",value:function(R,k,F){if(!(F!=null&&this.whitelist!=null&&!this.whitelist[k])){if(R>=this.length())if(F==null||h.default.query(k,h.default.Scope.BLOCK)==null){var U=h.default.create(this.statics.defaultChild);this.appendChild(U),F==null&&k.endsWith(`
|
|
55
|
-
`)&&(
|
|
56
|
-
`,
|
|
57
|
-
`,
|
|
58
|
-
`,
|
|
59
|
-
`);Se=0,me.forEach(function(ke,Ne){H?(Ae.insertAt(Oe+Se,de.TAB),Se+=de.TAB.length,Ne===0?pe+=de.TAB.length:Ee+=de.TAB.length):ke.startsWith(de.TAB)&&(Ae.deleteAt(Oe+Se,de.TAB.length),Se-=de.TAB.length,Ne===0?pe-=de.TAB.length:Ee-=de.TAB.length),Se+=ke.length+1}),this.quill.update(S.default.sources.USER),this.quill.setSelection(pe,Ee,S.default.sources.SILENT)}}}}function Z(H){return{key:H[0].toUpperCase(),shortKey:!0,handler:function(le,de){this.quill.format(H,!de.format[H],S.default.sources.USER)}}}function X(H){if(typeof H=="string"||typeof H=="number")return X({key:H});if((typeof H>"u"?"undefined":s(H))==="object"&&(H=(0,h.default)(H,!1)),typeof H.key=="string")if(ne.keys[H.key.toUpperCase()]!=null)H.key=ne.keys[H.key.toUpperCase()];else if(H.key.length===1)H.key=H.key.toUpperCase().charCodeAt(0);else return null;return H.shortKey&&(H[U]=H.shortKey,delete H.shortKey),H}r.default=ne,r.SHORTKEY=U}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function y(w,E){var m=[],S=!0,C=!1,N=void 0;try{for(var M=w[Symbol.iterator](),j;!(S=(j=M.next()).done)&&(m.push(j.value),!(E&&m.length===E));S=!0);}catch(I){C=!0,N=I}finally{try{!S&&M.return&&M.return()}finally{if(C)throw N}}return m}return function(w,E){if(Array.isArray(w))return w;if(Symbol.iterator in Object(w))return y(w,E);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=function y(w,E,m){w===null&&(w=Function.prototype);var S=Object.getOwnPropertyDescriptor(w,E);if(S===void 0){var C=Object.getPrototypeOf(w);return C===null?void 0:y(C,E,m)}else{if("value"in S)return S.value;var N=S.get;return N===void 0?void 0:N.call(m)}},c=(function(){function y(w,E){for(var m=0;m<E.length;m++){var S=E[m];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(w,S.key,S)}}return function(w,E,m){return E&&y(w.prototype,E),m&&y(w,m),w}})(),f=o(0),h=d(f),a=o(7),u=d(a);function d(y){return y&&y.__esModule?y:{default:y}}function p(y,w){if(!(y instanceof w))throw new TypeError("Cannot call a class as a function")}function O(y,w){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:y}function g(y,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);y.prototype=Object.create(w&&w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(y,w):y.__proto__=w)}var _=(function(y){g(w,y),c(w,null,[{key:"value",value:function(){}}]);function w(E,m){p(this,w);var S=O(this,(w.__proto__||Object.getPrototypeOf(w)).call(this,E));return S.selection=m,S.textNode=document.createTextNode(w.CONTENTS),S.domNode.appendChild(S.textNode),S._length=0,S}return c(w,[{key:"detach",value:function(){this.parent!=null&&this.parent.removeChild(this)}},{key:"format",value:function(m,S){if(this._length!==0)return l(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"format",this).call(this,m,S);for(var C=this,N=0;C!=null&&C.statics.scope!==h.default.Scope.BLOCK_BLOT;)N+=C.offset(C.parent),C=C.parent;C!=null&&(this._length=w.CONTENTS.length,C.optimize(),C.formatAt(N,w.CONTENTS.length,m,S),this._length=0)}},{key:"index",value:function(m,S){return m===this.textNode?0:l(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"index",this).call(this,m,S)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){l(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!(this.selection.composing||this.parent==null)){var m=this.textNode,S=this.selection.getNativeRange(),C=void 0,N=void 0,M=void 0;if(S!=null&&S.start.node===m&&S.end.node===m){var j=[m,S.start.offset,S.end.offset];C=j[0],N=j[1],M=j[2]}for(;this.domNode.lastChild!=null&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==w.CONTENTS){var I=this.textNode.data.split(w.CONTENTS).join("");this.next instanceof u.default?(C=this.next.domNode,this.next.insertAt(0,I),this.textNode.data=w.CONTENTS):(this.textNode.data=I,this.parent.insertBefore(h.default.create(this.textNode),this),this.textNode=document.createTextNode(w.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),N!=null){var A=[N,M].map(function(R){return Math.max(0,Math.min(C.data.length,R-1))}),q=s(A,2);return N=q[0],M=q[1],{startNode:C,startOffset:N,endNode:C,endOffset:M}}}}},{key:"update",value:function(m,S){var C=this;if(m.some(function(M){return M.type==="characterData"&&M.target===C.textNode})){var N=this.restore();N&&(S.range=N)}}},{key:"value",value:function(){return""}}]),w})(h.default.Embed);_.blotName="cursor",_.className="ql-cursor",_.tagName="span",_.CONTENTS="\uFEFF",r.default=_}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(0),l=h(s),c=o(4),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(){return a(this,g),u(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return g})(l.default.Container);p.allowedChildren=[f.default,c.BlockEmbed,p],r.default=p}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.ColorStyle=r.ColorClass=r.ColorAttributor=void 0;var s=(function(){function _(y,w){for(var E=0;E<w.length;E++){var m=w[E];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,E){return w&&_(y.prototype,w),E&&_(y,E),y}})(),l=function _(y,w,E){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var S=Object.getPrototypeOf(y);return S===null?void 0:_(S,w,E)}else{if("value"in m)return m.value;var C=m.get;return C===void 0?void 0:C.call(E)}},c=o(0),f=h(c);function h(_){return _&&_.__esModule?_:{default:_}}function a(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function u(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function d(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var p=(function(_){d(y,_);function y(){return a(this,y),u(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"value",value:function(E){var m=l(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"value",this).call(this,E);return m.startsWith("rgb(")?(m=m.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+m.split(",").map(function(S){return("00"+parseInt(S).toString(16)).slice(-2)}).join("")):m}}]),y})(f.default.Attributor.Style),O=new f.default.Attributor.Class("color","ql-color",{scope:f.default.Scope.INLINE}),g=new p("color","color",{scope:f.default.Scope.INLINE});r.ColorAttributor=p,r.ColorClass=O,r.ColorStyle=g}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.sanitize=r.default=void 0;var s=(function(){function g(_,y){for(var w=0;w<y.length;w++){var E=y[w];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(_,E.key,E)}}return function(_,y,w){return y&&g(_.prototype,y),w&&g(_,w),_}})(),l=function g(_,y,w){_===null&&(_=Function.prototype);var E=Object.getOwnPropertyDescriptor(_,y);if(E===void 0){var m=Object.getPrototypeOf(_);return m===null?void 0:g(m,y,w)}else{if("value"in E)return E.value;var S=E.get;return S===void 0?void 0:S.call(w)}},c=o(6),f=h(c);function h(g){return g&&g.__esModule?g:{default:g}}function a(g,_){if(!(g instanceof _))throw new TypeError("Cannot call a class as a function")}function u(g,_){if(!g)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _&&(typeof _=="object"||typeof _=="function")?_:g}function d(g,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof _);g.prototype=Object.create(_&&_.prototype,{constructor:{value:g,enumerable:!1,writable:!0,configurable:!0}}),_&&(Object.setPrototypeOf?Object.setPrototypeOf(g,_):g.__proto__=_)}var p=(function(g){d(_,g);function _(){return a(this,_),u(this,(_.__proto__||Object.getPrototypeOf(_)).apply(this,arguments))}return s(_,[{key:"format",value:function(w,E){if(w!==this.statics.blotName||!E)return l(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"format",this).call(this,w,E);E=this.constructor.sanitize(E),this.domNode.setAttribute("href",E)}}],[{key:"create",value:function(w){var E=l(_.__proto__||Object.getPrototypeOf(_),"create",this).call(this,w);return w=this.sanitize(w),E.setAttribute("href",w),E.setAttribute("rel","noopener noreferrer"),E.setAttribute("target","_blank"),E}},{key:"formats",value:function(w){return w.getAttribute("href")}},{key:"sanitize",value:function(w){return O(w,this.PROTOCOL_WHITELIST)?w:this.SANITIZED_URL}}]),_})(f.default);p.blotName="link",p.tagName="A",p.SANITIZED_URL="about:blank",p.PROTOCOL_WHITELIST=["http","https","mailto","tel"];function O(g,_){var y=document.createElement("a");y.href=g;var w=y.href.slice(0,y.href.indexOf(":"));return _.indexOf(w)>-1}r.default=p,r.sanitize=O}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(_){return typeof _}:function(_){return _&&typeof Symbol=="function"&&_.constructor===Symbol&&_!==Symbol.prototype?"symbol":typeof _},l=(function(){function _(y,w){for(var E=0;E<w.length;E++){var m=w[E];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,E){return w&&_(y.prototype,w),E&&_(y,E),y}})(),c=o(23),f=u(c),h=o(107),a=u(h);function u(_){return _&&_.__esModule?_:{default:_}}function d(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}var p=0;function O(_,y){_.setAttribute(y,_.getAttribute(y)!=="true")}var g=(function(){function _(y){var w=this;d(this,_),this.select=y,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){w.togglePicker()}),this.label.addEventListener("keydown",function(E){switch(E.keyCode){case f.default.keys.ENTER:w.togglePicker();break;case f.default.keys.ESCAPE:w.escape(),E.preventDefault();break}}),this.select.addEventListener("change",this.update.bind(this))}return l(_,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),O(this.label,"aria-expanded"),O(this.options,"aria-hidden")}},{key:"buildItem",value:function(w){var E=this,m=document.createElement("span");return m.tabIndex="0",m.setAttribute("role","button"),m.classList.add("ql-picker-item"),w.hasAttribute("value")&&m.setAttribute("data-value",w.getAttribute("value")),w.textContent&&m.setAttribute("data-label",w.textContent),m.addEventListener("click",function(){E.selectItem(m,!0)}),m.addEventListener("keydown",function(S){switch(S.keyCode){case f.default.keys.ENTER:E.selectItem(m,!0),S.preventDefault();break;case f.default.keys.ESCAPE:E.escape(),S.preventDefault();break}}),m}},{key:"buildLabel",value:function(){var w=document.createElement("span");return w.classList.add("ql-picker-label"),w.innerHTML=a.default,w.tabIndex="0",w.setAttribute("role","button"),w.setAttribute("aria-expanded","false"),this.container.appendChild(w),w}},{key:"buildOptions",value:function(){var w=this,E=document.createElement("span");E.classList.add("ql-picker-options"),E.setAttribute("aria-hidden","true"),E.tabIndex="-1",E.id="ql-picker-options-"+p,p+=1,this.label.setAttribute("aria-controls",E.id),this.options=E,[].slice.call(this.select.options).forEach(function(m){var S=w.buildItem(m);E.appendChild(S),m.selected===!0&&w.selectItem(S)}),this.container.appendChild(E)}},{key:"buildPicker",value:function(){var w=this;[].slice.call(this.select.attributes).forEach(function(E){w.container.setAttribute(E.name,E.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var w=this;this.close(),setTimeout(function(){return w.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(w){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,m=this.container.querySelector(".ql-selected");if(w!==m&&(m?.classList.remove("ql-selected"),w!=null&&(w.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(w.parentNode.children,w),w.hasAttribute("data-value")?this.label.setAttribute("data-value",w.getAttribute("data-value")):this.label.removeAttribute("data-value"),w.hasAttribute("data-label")?this.label.setAttribute("data-label",w.getAttribute("data-label")):this.label.removeAttribute("data-label"),E))){if(typeof Event=="function")this.select.dispatchEvent(new Event("change"));else if((typeof Event>"u"?"undefined":s(Event))==="object"){var S=document.createEvent("Event");S.initEvent("change",!0,!0),this.select.dispatchEvent(S)}this.close()}}},{key:"update",value:function(){var w=void 0;if(this.select.selectedIndex>-1){var E=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];w=this.select.options[this.select.selectedIndex],this.selectItem(E)}else this.selectItem(null);var m=w!=null&&w!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",m)}}]),_})();r.default=g}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(0),l=F(s),c=o(5),f=F(c),h=o(4),a=F(h),u=o(16),d=F(u),p=o(25),O=F(p),g=o(24),_=F(g),y=o(35),w=F(y),E=o(6),m=F(E),S=o(22),C=F(S),N=o(7),M=F(N),j=o(55),I=F(j),A=o(42),q=F(A),R=o(23),k=F(R);function F(U){return U&&U.__esModule?U:{default:U}}f.default.register({"blots/block":a.default,"blots/block/embed":h.BlockEmbed,"blots/break":d.default,"blots/container":O.default,"blots/cursor":_.default,"blots/embed":w.default,"blots/inline":m.default,"blots/scroll":C.default,"blots/text":M.default,"modules/clipboard":I.default,"modules/history":q.default,"modules/keyboard":k.default}),l.default.register(a.default,d.default,_.default,m.default,C.default,M.default),r.default=f.default}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(1),l=(function(){function c(f){this.domNode=f,this.domNode[s.DATA_KEY]={blot:this}}return Object.defineProperty(c.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),c.create=function(f){if(this.tagName==null)throw new s.ParchmentError("Blot definition missing tagName");var h;return Array.isArray(this.tagName)?(typeof f=="string"&&(f=f.toUpperCase(),parseInt(f).toString()===f&&(f=parseInt(f))),typeof f=="number"?h=document.createElement(this.tagName[f-1]):this.tagName.indexOf(f)>-1?h=document.createElement(f):h=document.createElement(this.tagName[0])):h=document.createElement(this.tagName),this.className&&h.classList.add(this.className),h},c.prototype.attach=function(){this.parent!=null&&(this.scroll=this.parent.scroll)},c.prototype.clone=function(){var f=this.domNode.cloneNode(!1);return s.create(f)},c.prototype.detach=function(){this.parent!=null&&this.parent.removeChild(this),delete this.domNode[s.DATA_KEY]},c.prototype.deleteAt=function(f,h){var a=this.isolate(f,h);a.remove()},c.prototype.formatAt=function(f,h,a,u){var d=this.isolate(f,h);if(s.query(a,s.Scope.BLOT)!=null&&u)d.wrap(a,u);else if(s.query(a,s.Scope.ATTRIBUTE)!=null){var p=s.create(this.statics.scope);d.wrap(p),p.format(a,u)}},c.prototype.insertAt=function(f,h,a){var u=a==null?s.create("text",h):s.create(h,a),d=this.split(f);this.parent.insertBefore(u,d)},c.prototype.insertInto=function(f,h){h===void 0&&(h=null),this.parent!=null&&this.parent.children.remove(this);var a=null;f.children.insertBefore(this,h),h!=null&&(a=h.domNode),(this.domNode.parentNode!=f.domNode||this.domNode.nextSibling!=a)&&f.domNode.insertBefore(this.domNode,a),this.parent=f,this.attach()},c.prototype.isolate=function(f,h){var a=this.split(f);return a.split(h),a},c.prototype.length=function(){return 1},c.prototype.offset=function(f){return f===void 0&&(f=this.parent),this.parent==null||this==f?0:this.parent.children.offset(this)+this.parent.offset(f)},c.prototype.optimize=function(f){this.domNode[s.DATA_KEY]!=null&&delete this.domNode[s.DATA_KEY].mutations},c.prototype.remove=function(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},c.prototype.replace=function(f){f.parent!=null&&(f.parent.insertBefore(this,f.next),f.remove())},c.prototype.replaceWith=function(f,h){var a=typeof f=="string"?s.create(f,h):f;return a.replace(this),a},c.prototype.split=function(f,h){return f===0?this:this.next},c.prototype.update=function(f,h){},c.prototype.wrap=function(f,h){var a=typeof f=="string"?s.create(f,h):f;return this.parent!=null&&this.parent.insertBefore(a,this.next),a.appendChild(this),a},c.blotName="abstract",c})();r.default=l}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(12),l=o(32),c=o(33),f=o(1),h=(function(){function a(u){this.attributes={},this.domNode=u,this.build()}return a.prototype.attribute=function(u,d){d?u.add(this.domNode,d)&&(u.value(this.domNode)!=null?this.attributes[u.attrName]=u:delete this.attributes[u.attrName]):(u.remove(this.domNode),delete this.attributes[u.attrName])},a.prototype.build=function(){var u=this;this.attributes={};var d=s.default.keys(this.domNode),p=l.default.keys(this.domNode),O=c.default.keys(this.domNode);d.concat(p).concat(O).forEach(function(g){var _=f.query(g,f.Scope.ATTRIBUTE);_ instanceof s.default&&(u.attributes[_.attrName]=_)})},a.prototype.copy=function(u){var d=this;Object.keys(this.attributes).forEach(function(p){var O=d.attributes[p].value(d.domNode);u.format(p,O)})},a.prototype.move=function(u){var d=this;this.copy(u),Object.keys(this.attributes).forEach(function(p){d.attributes[p].remove(d.domNode)}),this.attributes={}},a.prototype.values=function(){var u=this;return Object.keys(this.attributes).reduce(function(d,p){return d[p]=u.attributes[p].value(u.domNode),d},{})},a})();r.default=h}),(function(n,r,o){var s=this&&this.__extends||(function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,u){a.__proto__=u}||function(a,u){for(var d in u)u.hasOwnProperty(d)&&(a[d]=u[d])};return function(a,u){h(a,u);function d(){this.constructor=a}a.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(12);function c(h,a){var u=h.getAttribute("class")||"";return u.split(/\s+/).filter(function(d){return d.indexOf(a+"-")===0})}var f=(function(h){s(a,h);function a(){return h!==null&&h.apply(this,arguments)||this}return a.keys=function(u){return(u.getAttribute("class")||"").split(/\s+/).map(function(d){return d.split("-").slice(0,-1).join("-")})},a.prototype.add=function(u,d){return this.canAdd(u,d)?(this.remove(u),u.classList.add(this.keyName+"-"+d),!0):!1},a.prototype.remove=function(u){var d=c(u,this.keyName);d.forEach(function(p){u.classList.remove(p)}),u.classList.length===0&&u.removeAttribute("class")},a.prototype.value=function(u){var d=c(u,this.keyName)[0]||"",p=d.slice(this.keyName.length+1);return this.canAdd(u,p)?p:""},a})(l.default);r.default=f}),(function(n,r,o){var s=this&&this.__extends||(function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,u){a.__proto__=u}||function(a,u){for(var d in u)u.hasOwnProperty(d)&&(a[d]=u[d])};return function(a,u){h(a,u);function d(){this.constructor=a}a.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(12);function c(h){var a=h.split("-"),u=a.slice(1).map(function(d){return d[0].toUpperCase()+d.slice(1)}).join("");return a[0]+u}var f=(function(h){s(a,h);function a(){return h!==null&&h.apply(this,arguments)||this}return a.keys=function(u){return(u.getAttribute("style")||"").split(";").map(function(d){var p=d.split(":");return p[0].trim()})},a.prototype.add=function(u,d){return this.canAdd(u,d)?(u.style[c(this.keyName)]=d,!0):!1},a.prototype.remove=function(u){u.style[c(this.keyName)]="",u.getAttribute("style")||u.removeAttribute("style")},a.prototype.value=function(u){var d=u.style[c(this.keyName)];return this.canAdd(u,d)?d:""},a})(l.default);r.default=f}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function f(h,a){for(var u=0;u<a.length;u++){var d=a[u];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(h,d.key,d)}}return function(h,a,u){return a&&f(h.prototype,a),u&&f(h,u),h}})();function l(f,h){if(!(f instanceof h))throw new TypeError("Cannot call a class as a function")}var c=(function(){function f(h,a){l(this,f),this.quill=h,this.options=a,this.modules={}}return s(f,[{key:"init",value:function(){var a=this;Object.keys(this.options.modules).forEach(function(u){a.modules[u]==null&&a.addModule(u)})}},{key:"addModule",value:function(a){var u=this.quill.constructor.import("modules/"+a);return this.modules[a]=new u(this.quill,this.options.modules[a]||{}),this.modules[a]}}]),f})();c.DEFAULTS={modules:{}},c.themes={default:c},r.default=c}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function y(w,E){for(var m=0;m<E.length;m++){var S=E[m];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(w,S.key,S)}}return function(w,E,m){return E&&y(w.prototype,E),m&&y(w,m),w}})(),l=function y(w,E,m){w===null&&(w=Function.prototype);var S=Object.getOwnPropertyDescriptor(w,E);if(S===void 0){var C=Object.getPrototypeOf(w);return C===null?void 0:y(C,E,m)}else{if("value"in S)return S.value;var N=S.get;return N===void 0?void 0:N.call(m)}},c=o(0),f=u(c),h=o(7),a=u(h);function u(y){return y&&y.__esModule?y:{default:y}}function d(y,w){if(!(y instanceof w))throw new TypeError("Cannot call a class as a function")}function p(y,w){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:y}function O(y,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);y.prototype=Object.create(w&&w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(y,w):y.__proto__=w)}var g="\uFEFF",_=(function(y){O(w,y);function w(E){d(this,w);var m=p(this,(w.__proto__||Object.getPrototypeOf(w)).call(this,E));return m.contentNode=document.createElement("span"),m.contentNode.setAttribute("contenteditable",!1),[].slice.call(m.domNode.childNodes).forEach(function(S){m.contentNode.appendChild(S)}),m.leftGuard=document.createTextNode(g),m.rightGuard=document.createTextNode(g),m.domNode.appendChild(m.leftGuard),m.domNode.appendChild(m.contentNode),m.domNode.appendChild(m.rightGuard),m}return s(w,[{key:"index",value:function(m,S){return m===this.leftGuard?0:m===this.rightGuard?1:l(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"index",this).call(this,m,S)}},{key:"restore",value:function(m){var S=void 0,C=void 0,N=m.data.split(g).join("");if(m===this.leftGuard)if(this.prev instanceof a.default){var M=this.prev.length();this.prev.insertAt(M,N),S={startNode:this.prev.domNode,startOffset:M+N.length}}else C=document.createTextNode(N),this.parent.insertBefore(f.default.create(C),this),S={startNode:C,startOffset:N.length};else m===this.rightGuard&&(this.next instanceof a.default?(this.next.insertAt(0,N),S={startNode:this.next.domNode,startOffset:N.length}):(C=document.createTextNode(N),this.parent.insertBefore(f.default.create(C),this.next),S={startNode:C,startOffset:N.length}));return m.data=g,S}},{key:"update",value:function(m,S){var C=this;m.forEach(function(N){if(N.type==="characterData"&&(N.target===C.leftGuard||N.target===C.rightGuard)){var M=C.restore(N.target);M&&(S.range=M)}})}}]),w})(f.default.Embed);r.default=_}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.AlignStyle=r.AlignClass=r.AlignAttribute=void 0;var s=o(0),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}var f={scope:l.default.Scope.BLOCK,whitelist:["right","center","justify"]},h=new l.default.Attributor.Attribute("align","align",f),a=new l.default.Attributor.Class("align","ql-align",f),u=new l.default.Attributor.Style("align","text-align",f);r.AlignAttribute=h,r.AlignClass=a,r.AlignStyle=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.BackgroundStyle=r.BackgroundClass=void 0;var s=o(0),l=f(s),c=o(26);function f(u){return u&&u.__esModule?u:{default:u}}var h=new l.default.Attributor.Class("background","ql-bg",{scope:l.default.Scope.INLINE}),a=new c.ColorAttributor("background","background-color",{scope:l.default.Scope.INLINE});r.BackgroundClass=h,r.BackgroundStyle=a}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.DirectionStyle=r.DirectionClass=r.DirectionAttribute=void 0;var s=o(0),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}var f={scope:l.default.Scope.BLOCK,whitelist:["rtl"]},h=new l.default.Attributor.Attribute("direction","dir",f),a=new l.default.Attributor.Class("direction","ql-direction",f),u=new l.default.Attributor.Style("direction","direction",f);r.DirectionAttribute=h,r.DirectionClass=a,r.DirectionStyle=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.FontClass=r.FontStyle=void 0;var s=(function(){function y(w,E){for(var m=0;m<E.length;m++){var S=E[m];S.enumerable=S.enumerable||!1,S.configurable=!0,"value"in S&&(S.writable=!0),Object.defineProperty(w,S.key,S)}}return function(w,E,m){return E&&y(w.prototype,E),m&&y(w,m),w}})(),l=function y(w,E,m){w===null&&(w=Function.prototype);var S=Object.getOwnPropertyDescriptor(w,E);if(S===void 0){var C=Object.getPrototypeOf(w);return C===null?void 0:y(C,E,m)}else{if("value"in S)return S.value;var N=S.get;return N===void 0?void 0:N.call(m)}},c=o(0),f=h(c);function h(y){return y&&y.__esModule?y:{default:y}}function a(y,w){if(!(y instanceof w))throw new TypeError("Cannot call a class as a function")}function u(y,w){if(!y)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:y}function d(y,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);y.prototype=Object.create(w&&w.prototype,{constructor:{value:y,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(y,w):y.__proto__=w)}var p={scope:f.default.Scope.INLINE,whitelist:["serif","monospace"]},O=new f.default.Attributor.Class("font","ql-font",p),g=(function(y){d(w,y);function w(){return a(this,w),u(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return s(w,[{key:"value",value:function(m){return l(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"value",this).call(this,m).replace(/["']/g,"")}}]),w})(f.default.Attributor.Style),_=new g("font","font-family",p);r.FontStyle=_,r.FontClass=O}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.SizeStyle=r.SizeClass=void 0;var s=o(0),l=c(s);function c(a){return a&&a.__esModule?a:{default:a}}var f=new l.default.Attributor.Class("size","ql-size",{scope:l.default.Scope.INLINE,whitelist:["small","large","huge"]}),h=new l.default.Attributor.Style("size","font-size",{scope:l.default.Scope.INLINE,whitelist:["10px","18px","32px"]});r.SizeClass=f,r.SizeStyle=h}),(function(n,r,o){n.exports={align:{"":o(76),center:o(77),right:o(78),justify:o(79)},background:o(80),blockquote:o(81),bold:o(82),clean:o(83),code:o(58),"code-block":o(58),color:o(84),direction:{"":o(85),rtl:o(86)},float:{center:o(87),full:o(88),left:o(89),right:o(90)},formula:o(91),header:{1:o(92),2:o(93)},italic:o(94),image:o(95),indent:{"+1":o(96),"-1":o(97)},link:o(98),list:{ordered:o(99),bullet:o(100),check:o(101)},script:{sub:o(102),super:o(103)},strike:o(104),underline:o(105),video:o(106)}}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.getLastChangeIndex=r.default=void 0;var s=(function(){function E(m,S){for(var C=0;C<S.length;C++){var N=S[C];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(m,N.key,N)}}return function(m,S,C){return S&&E(m.prototype,S),C&&E(m,C),m}})(),l=o(0),c=d(l),f=o(5),h=d(f),a=o(9),u=d(a);function d(E){return E&&E.__esModule?E:{default:E}}function p(E,m){if(!(E instanceof m))throw new TypeError("Cannot call a class as a function")}function O(E,m){if(!E)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m&&(typeof m=="object"||typeof m=="function")?m:E}function g(E,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);E.prototype=Object.create(m&&m.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(E,m):E.__proto__=m)}var _=(function(E){g(m,E);function m(S,C){p(this,m);var N=O(this,(m.__proto__||Object.getPrototypeOf(m)).call(this,S,C));return N.lastRecorded=0,N.ignoreChange=!1,N.clear(),N.quill.on(h.default.events.EDITOR_CHANGE,function(M,j,I,A){M!==h.default.events.TEXT_CHANGE||N.ignoreChange||(!N.options.userOnly||A===h.default.sources.USER?N.record(j,I):N.transform(j))}),N.quill.keyboard.addBinding({key:"Z",shortKey:!0},N.undo.bind(N)),N.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},N.redo.bind(N)),/Win/i.test(navigator.platform)&&N.quill.keyboard.addBinding({key:"Y",shortKey:!0},N.redo.bind(N)),N}return s(m,[{key:"change",value:function(C,N){if(this.stack[C].length!==0){var M=this.stack[C].pop();this.stack[N].push(M),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(M[C],h.default.sources.USER),this.ignoreChange=!1;var j=w(M[C]);this.quill.setSelection(j)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(C,N){if(C.ops.length!==0){this.stack.redo=[];var M=this.quill.getContents().diff(N),j=Date.now();if(this.lastRecorded+this.options.delay>j&&this.stack.undo.length>0){var I=this.stack.undo.pop();M=M.compose(I.undo),C=I.redo.compose(C)}else this.lastRecorded=j;this.stack.undo.push({redo:C,undo:M}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(C){this.stack.undo.forEach(function(N){N.undo=C.transform(N.undo,!0),N.redo=C.transform(N.redo,!0)}),this.stack.redo.forEach(function(N){N.undo=C.transform(N.undo,!0),N.redo=C.transform(N.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),m})(u.default);_.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};function y(E){var m=E.ops[E.ops.length-1];return m==null?!1:m.insert!=null?typeof m.insert=="string"&&m.insert.endsWith(`
|
|
60
|
-
`):m.attributes!=null?Object.keys(m.attributes).some(function(S){return c.default.query(S,c.default.Scope.BLOCK)!=null}):!1}function w(E){var m=E.reduce(function(C,N){return C+=N.delete||0,C},0),S=E.length()-m;return y(E)&&(S-=1),S}r.default=_,r.getLastChangeIndex=w}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BaseTooltip=void 0;var s=(function(){function Q(re,Z){for(var X=0;X<Z.length;X++){var H=Z[X];H.enumerable=H.enumerable||!1,H.configurable=!0,"value"in H&&(H.writable=!0),Object.defineProperty(re,H.key,H)}}return function(re,Z,X){return Z&&Q(re.prototype,Z),X&&Q(re,X),re}})(),l=function Q(re,Z,X){re===null&&(re=Function.prototype);var H=Object.getOwnPropertyDescriptor(re,Z);if(H===void 0){var ee=Object.getPrototypeOf(re);return ee===null?void 0:Q(ee,Z,X)}else{if("value"in H)return H.value;var le=H.get;return le===void 0?void 0:le.call(X)}},c=o(3),f=j(c),h=o(2),a=j(h),u=o(8),d=j(u),p=o(23),O=j(p),g=o(34),_=j(g),y=o(59),w=j(y),E=o(60),m=j(E),S=o(28),C=j(S),N=o(61),M=j(N);function j(Q){return Q&&Q.__esModule?Q:{default:Q}}function I(Q,re){if(!(Q instanceof re))throw new TypeError("Cannot call a class as a function")}function A(Q,re){if(!Q)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return re&&(typeof re=="object"||typeof re=="function")?re:Q}function q(Q,re){if(typeof re!="function"&&re!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof re);Q.prototype=Object.create(re&&re.prototype,{constructor:{value:Q,enumerable:!1,writable:!0,configurable:!0}}),re&&(Object.setPrototypeOf?Object.setPrototypeOf(Q,re):Q.__proto__=re)}var R=[!1,"center","right","justify"],k=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],F=[!1,"serif","monospace"],U=["1","2","3",!1],ne=["small",!1,"large","huge"],ue=(function(Q){q(re,Q);function re(Z,X){I(this,re);var H=A(this,(re.__proto__||Object.getPrototypeOf(re)).call(this,Z,X)),ee=function le(de){if(!document.body.contains(Z.root))return document.body.removeEventListener("click",le);H.tooltip!=null&&!H.tooltip.root.contains(de.target)&&document.activeElement!==H.tooltip.textbox&&!H.quill.hasFocus()&&H.tooltip.hide(),H.pickers!=null&&H.pickers.forEach(function(pe){pe.container.contains(de.target)||pe.close()})};return Z.emitter.listenDOM("click",document.body,ee),H}return s(re,[{key:"addModule",value:function(X){var H=l(re.prototype.__proto__||Object.getPrototypeOf(re.prototype),"addModule",this).call(this,X);return X==="toolbar"&&this.extendToolbar(H),H}},{key:"buildButtons",value:function(X,H){X.forEach(function(ee){var le=ee.getAttribute("class")||"";le.split(/\s+/).forEach(function(de){if(de.startsWith("ql-")&&(de=de.slice(3),H[de]!=null))if(de==="direction")ee.innerHTML=H[de][""]+H[de].rtl;else if(typeof H[de]=="string")ee.innerHTML=H[de];else{var pe=ee.value||"";pe!=null&&H[de][pe]&&(ee.innerHTML=H[de][pe])}})})}},{key:"buildPickers",value:function(X,H){var ee=this;this.pickers=X.map(function(de){if(de.classList.contains("ql-align"))return de.querySelector("option")==null&&z(de,R),new m.default(de,H.align);if(de.classList.contains("ql-background")||de.classList.contains("ql-color")){var pe=de.classList.contains("ql-background")?"background":"color";return de.querySelector("option")==null&&z(de,k,pe==="background"?"#ffffff":"#000000"),new w.default(de,H[pe])}else return de.querySelector("option")==null&&(de.classList.contains("ql-font")?z(de,F):de.classList.contains("ql-header")?z(de,U):de.classList.contains("ql-size")&&z(de,ne)),new C.default(de)});var le=function(){ee.pickers.forEach(function(pe){pe.update()})};this.quill.on(d.default.events.EDITOR_CHANGE,le)}}]),re})(_.default);ue.DEFAULTS=(0,f.default)(!0,{},_.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var re=this,Z=this.container.querySelector("input.ql-image[type=file]");Z==null&&(Z=document.createElement("input"),Z.setAttribute("type","file"),Z.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),Z.classList.add("ql-image"),Z.addEventListener("change",function(){if(Z.files!=null&&Z.files[0]!=null){var X=new FileReader;X.onload=function(H){var ee=re.quill.getSelection(!0);re.quill.updateContents(new a.default().retain(ee.index).delete(ee.length).insert({image:H.target.result}),d.default.sources.USER),re.quill.setSelection(ee.index+1,d.default.sources.SILENT),Z.value=""},X.readAsDataURL(Z.files[0])}}),this.container.appendChild(Z)),Z.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var K=(function(Q){q(re,Q);function re(Z,X){I(this,re);var H=A(this,(re.__proto__||Object.getPrototypeOf(re)).call(this,Z,X));return H.textbox=H.root.querySelector('input[type="text"]'),H.listen(),H}return s(re,[{key:"listen",value:function(){var X=this;this.textbox.addEventListener("keydown",function(H){O.default.match(H,"enter")?(X.save(),H.preventDefault()):O.default.match(H,"escape")&&(X.cancel(),H.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var X=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"link",H=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),H!=null?this.textbox.value=H:X!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+X)||""),this.root.setAttribute("data-mode",X)}},{key:"restoreFocus",value:function(){var X=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=X}},{key:"save",value:function(){var X=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{var H=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",X,d.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",X,d.default.sources.USER)),this.quill.root.scrollTop=H;break}case"video":X=W(X);case"formula":{if(!X)break;var ee=this.quill.getSelection(!0);if(ee!=null){var le=ee.index+ee.length;this.quill.insertEmbed(le,this.root.getAttribute("data-mode"),X,d.default.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(le+1," ",d.default.sources.USER),this.quill.setSelection(le+2,d.default.sources.USER)}break}}this.textbox.value="",this.hide()}}]),re})(M.default);function W(Q){var re=Q.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||Q.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return re?(re[1]||"https")+"://www.youtube.com/embed/"+re[2]+"?showinfo=0":(re=Q.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(re[1]||"https")+"://player.vimeo.com/video/"+re[2]+"/":Q}function z(Q,re){var Z=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;re.forEach(function(X){var H=document.createElement("option");X===Z?H.setAttribute("selected","selected"):H.setAttribute("value",X),Q.appendChild(H)})}r.BaseTooltip=K,r.default=ue}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function l(){this.head=this.tail=null,this.length=0}return l.prototype.append=function(){for(var c=[],f=0;f<arguments.length;f++)c[f]=arguments[f];this.insertBefore(c[0],null),c.length>1&&this.append.apply(this,c.slice(1))},l.prototype.contains=function(c){for(var f,h=this.iterator();f=h();)if(f===c)return!0;return!1},l.prototype.insertBefore=function(c,f){c&&(c.next=f,f!=null?(c.prev=f.prev,f.prev!=null&&(f.prev.next=c),f.prev=c,f===this.head&&(this.head=c)):this.tail!=null?(this.tail.next=c,c.prev=this.tail,this.tail=c):(c.prev=null,this.head=this.tail=c),this.length+=1)},l.prototype.offset=function(c){for(var f=0,h=this.head;h!=null;){if(h===c)return f;f+=h.length(),h=h.next}return-1},l.prototype.remove=function(c){this.contains(c)&&(c.prev!=null&&(c.prev.next=c.next),c.next!=null&&(c.next.prev=c.prev),c===this.head&&(this.head=c.next),c===this.tail&&(this.tail=c.prev),this.length-=1)},l.prototype.iterator=function(c){return c===void 0&&(c=this.head),function(){var f=c;return c!=null&&(c=c.next),f}},l.prototype.find=function(c,f){f===void 0&&(f=!1);for(var h,a=this.iterator();h=a();){var u=h.length();if(c<u||f&&c===u&&(h.next==null||h.next.length()!==0))return[h,c];c-=u}return[null,0]},l.prototype.forEach=function(c){for(var f,h=this.iterator();f=h();)c(f)},l.prototype.forEachAt=function(c,f,h){if(!(f<=0))for(var a=this.find(c),u=a[0],d=a[1],p,O=c-d,g=this.iterator(u);(p=g())&&O<c+f;){var _=p.length();c>O?h(p,c-O,Math.min(f,O+_-c)):h(p,0,Math.min(_,c+f-O)),O+=_}},l.prototype.map=function(c){return this.reduce(function(f,h){return f.push(c(h)),f},[])},l.prototype.reduce=function(c,f){for(var h,a=this.iterator();h=a();)f=c(f,h);return f},l})();r.default=s}),(function(n,r,o){var s=this&&this.__extends||(function(){var u=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var O in p)p.hasOwnProperty(O)&&(d[O]=p[O])};return function(d,p){u(d,p);function O(){this.constructor=d}d.prototype=p===null?Object.create(p):(O.prototype=p.prototype,new O)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(17),c=o(1),f={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},h=100,a=(function(u){s(d,u);function d(p){var O=u.call(this,p)||this;return O.scroll=O,O.observer=new MutationObserver(function(g){O.update(g)}),O.observer.observe(O.domNode,f),O.attach(),O}return d.prototype.detach=function(){u.prototype.detach.call(this),this.observer.disconnect()},d.prototype.deleteAt=function(p,O){this.update(),p===0&&O===this.length()?this.children.forEach(function(g){g.remove()}):u.prototype.deleteAt.call(this,p,O)},d.prototype.formatAt=function(p,O,g,_){this.update(),u.prototype.formatAt.call(this,p,O,g,_)},d.prototype.insertAt=function(p,O,g){this.update(),u.prototype.insertAt.call(this,p,O,g)},d.prototype.optimize=function(p,O){var g=this;p===void 0&&(p=[]),O===void 0&&(O={}),u.prototype.optimize.call(this,O);for(var _=[].slice.call(this.observer.takeRecords());_.length>0;)p.push(_.pop());for(var y=function(S,C){C===void 0&&(C=!0),!(S==null||S===g)&&S.domNode.parentNode!=null&&(S.domNode[c.DATA_KEY].mutations==null&&(S.domNode[c.DATA_KEY].mutations=[]),C&&y(S.parent))},w=function(S){S.domNode[c.DATA_KEY]==null||S.domNode[c.DATA_KEY].mutations==null||(S instanceof l.default&&S.children.forEach(w),S.optimize(O))},E=p,m=0;E.length>0;m+=1){if(m>=h)throw new Error("[Parchment] Maximum optimize iterations reached");for(E.forEach(function(S){var C=c.find(S.target,!0);C!=null&&(C.domNode===S.target&&(S.type==="childList"?(y(c.find(S.previousSibling,!1)),[].forEach.call(S.addedNodes,function(N){var M=c.find(N,!1);y(M,!1),M instanceof l.default&&M.children.forEach(function(j){y(j,!1)})})):S.type==="attributes"&&y(C.prev)),y(C))}),this.children.forEach(w),E=[].slice.call(this.observer.takeRecords()),_=E.slice();_.length>0;)p.push(_.pop())}},d.prototype.update=function(p,O){var g=this;O===void 0&&(O={}),p=p||this.observer.takeRecords(),p.map(function(_){var y=c.find(_.target,!0);return y==null?null:y.domNode[c.DATA_KEY].mutations==null?(y.domNode[c.DATA_KEY].mutations=[_],y):(y.domNode[c.DATA_KEY].mutations.push(_),null)}).forEach(function(_){_==null||_===g||_.domNode[c.DATA_KEY]==null||_.update(_.domNode[c.DATA_KEY].mutations||[],O)}),this.domNode[c.DATA_KEY].mutations!=null&&u.prototype.update.call(this,this.domNode[c.DATA_KEY].mutations,O),this.optimize(p,O)},d.blotName="scroll",d.defaultChild="block",d.scope=c.Scope.BLOCK_BLOT,d.tagName="DIV",d})(l.default);r.default=a}),(function(n,r,o){var s=this&&this.__extends||(function(){var a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(u,d){u.__proto__=d}||function(u,d){for(var p in d)d.hasOwnProperty(p)&&(u[p]=d[p])};return function(u,d){a(u,d);function p(){this.constructor=u}u.prototype=d===null?Object.create(d):(p.prototype=d.prototype,new p)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(18),c=o(1);function f(a,u){if(Object.keys(a).length!==Object.keys(u).length)return!1;for(var d in a)if(a[d]!==u[d])return!1;return!0}var h=(function(a){s(u,a);function u(){return a!==null&&a.apply(this,arguments)||this}return u.formats=function(d){if(d.tagName!==u.tagName)return a.formats.call(this,d)},u.prototype.format=function(d,p){var O=this;d===this.statics.blotName&&!p?(this.children.forEach(function(g){g instanceof l.default||(g=g.wrap(u.blotName,!0)),O.attributes.copy(g)}),this.unwrap()):a.prototype.format.call(this,d,p)},u.prototype.formatAt=function(d,p,O,g){if(this.formats()[O]!=null||c.query(O,c.Scope.ATTRIBUTE)){var _=this.isolate(d,p);_.format(O,g)}else a.prototype.formatAt.call(this,d,p,O,g)},u.prototype.optimize=function(d){a.prototype.optimize.call(this,d);var p=this.formats();if(Object.keys(p).length===0)return this.unwrap();var O=this.next;O instanceof u&&O.prev===this&&f(p,O.formats())&&(O.moveChildren(this),O.remove())},u.blotName="inline",u.scope=c.Scope.INLINE_BLOT,u.tagName="SPAN",u})(l.default);r.default=h}),(function(n,r,o){var s=this&&this.__extends||(function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,u){a.__proto__=u}||function(a,u){for(var d in u)u.hasOwnProperty(d)&&(a[d]=u[d])};return function(a,u){h(a,u);function d(){this.constructor=a}a.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(18),c=o(1),f=(function(h){s(a,h);function a(){return h!==null&&h.apply(this,arguments)||this}return a.formats=function(u){var d=c.query(a.blotName).tagName;if(u.tagName!==d)return h.formats.call(this,u)},a.prototype.format=function(u,d){c.query(u,c.Scope.BLOCK)!=null&&(u===this.statics.blotName&&!d?this.replaceWith(a.blotName):h.prototype.format.call(this,u,d))},a.prototype.formatAt=function(u,d,p,O){c.query(p,c.Scope.BLOCK)!=null?this.format(p,O):h.prototype.formatAt.call(this,u,d,p,O)},a.prototype.insertAt=function(u,d,p){if(p==null||c.query(d,c.Scope.INLINE)!=null)h.prototype.insertAt.call(this,u,d,p);else{var O=this.split(u),g=c.create(d,p);O.parent.insertBefore(g,O)}},a.prototype.update=function(u,d){navigator.userAgent.match(/Trident/)?this.build():h.prototype.update.call(this,u,d)},a.blotName="block",a.scope=c.Scope.BLOCK_BLOT,a.tagName="P",a})(l.default);r.default=f}),(function(n,r,o){var s=this&&this.__extends||(function(){var f=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,a){h.__proto__=a}||function(h,a){for(var u in a)a.hasOwnProperty(u)&&(h[u]=a[u])};return function(h,a){f(h,a);function u(){this.constructor=h}h.prototype=a===null?Object.create(a):(u.prototype=a.prototype,new u)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(19),c=(function(f){s(h,f);function h(){return f!==null&&f.apply(this,arguments)||this}return h.formats=function(a){},h.prototype.format=function(a,u){f.prototype.formatAt.call(this,0,this.length(),a,u)},h.prototype.formatAt=function(a,u,d,p){a===0&&u===this.length()?this.format(d,p):f.prototype.formatAt.call(this,a,u,d,p)},h.prototype.formats=function(){return this.statics.formats(this.domNode)},h})(l.default);r.default=c}),(function(n,r,o){var s=this&&this.__extends||(function(){var h=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(a,u){a.__proto__=u}||function(a,u){for(var d in u)u.hasOwnProperty(d)&&(a[d]=u[d])};return function(a,u){h(a,u);function d(){this.constructor=a}a.prototype=u===null?Object.create(u):(d.prototype=u.prototype,new d)}})();Object.defineProperty(r,"__esModule",{value:!0});var l=o(19),c=o(1),f=(function(h){s(a,h);function a(u){var d=h.call(this,u)||this;return d.text=d.statics.value(d.domNode),d}return a.create=function(u){return document.createTextNode(u)},a.value=function(u){var d=u.data;return d.normalize&&(d=d.normalize()),d},a.prototype.deleteAt=function(u,d){this.domNode.data=this.text=this.text.slice(0,u)+this.text.slice(u+d)},a.prototype.index=function(u,d){return this.domNode===u?d:-1},a.prototype.insertAt=function(u,d,p){p==null?(this.text=this.text.slice(0,u)+d+this.text.slice(u),this.domNode.data=this.text):h.prototype.insertAt.call(this,u,d,p)},a.prototype.length=function(){return this.text.length},a.prototype.optimize=function(u){h.prototype.optimize.call(this,u),this.text=this.statics.value(this.domNode),this.text.length===0?this.remove():this.next instanceof a&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},a.prototype.position=function(u,d){return[this.domNode,u]},a.prototype.split=function(u,d){if(d===void 0&&(d=!1),!d){if(u===0)return this;if(u===this.length())return this.next}var p=c.create(this.domNode.splitText(u));return this.parent.insertBefore(p,this.next),this.text=this.statics.value(this.domNode),p},a.prototype.update=function(u,d){var p=this;u.some(function(O){return O.type==="characterData"&&O.target===p.domNode})&&(this.text=this.statics.value(this.domNode))},a.prototype.value=function(){return this.text},a.blotName="text",a.scope=c.Scope.INLINE_BLOT,a})(l.default);r.default=f}),(function(n,r,o){var s=document.createElement("div");if(s.classList.toggle("test-class",!1),s.classList.contains("test-class")){var l=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(c,f){return arguments.length>1&&!this.contains(c)==!f?f:l.call(this,c)}}String.prototype.startsWith||(String.prototype.startsWith=function(c,f){return f=f||0,this.substr(f,c.length)===c}),String.prototype.endsWith||(String.prototype.endsWith=function(c,f){var h=this.toString();(typeof f!="number"||!isFinite(f)||Math.floor(f)!==f||f>h.length)&&(f=h.length),f-=c.length;var a=h.indexOf(c,f);return a!==-1&&a===f}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(f){if(this===null)throw new TypeError("Array.prototype.find called on null or undefined");if(typeof f!="function")throw new TypeError("predicate must be a function");for(var h=Object(this),a=h.length>>>0,u=arguments[1],d,p=0;p<a;p++)if(d=h[p],f.call(u,d,p,h))return d}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})}),(function(n,r){var o=-1,s=1,l=0;function c(m,S,C){if(m==S)return m?[[l,m]]:[];(C<0||m.length<C)&&(C=null);var N=u(m,S),M=m.substring(0,N);m=m.substring(N),S=S.substring(N),N=d(m,S);var j=m.substring(m.length-N);m=m.substring(0,m.length-N),S=S.substring(0,S.length-N);var I=f(m,S);return M&&I.unshift([l,M]),j&&I.push([l,j]),O(I),C!=null&&(I=y(I,C)),I=w(I),I}function f(m,S){var C;if(!m)return[[s,S]];if(!S)return[[o,m]];var N=m.length>S.length?m:S,M=m.length>S.length?S:m,j=N.indexOf(M);if(j!=-1)return C=[[s,N.substring(0,j)],[l,M],[s,N.substring(j+M.length)]],m.length>S.length&&(C[0][0]=C[2][0]=o),C;if(M.length==1)return[[o,m],[s,S]];var I=p(m,S);if(I){var A=I[0],q=I[1],R=I[2],k=I[3],F=I[4],U=c(A,R),ne=c(q,k);return U.concat([[l,F]],ne)}return h(m,S)}function h(m,S){for(var C=m.length,N=S.length,M=Math.ceil((C+N)/2),j=M,I=2*M,A=new Array(I),q=new Array(I),R=0;R<I;R++)A[R]=-1,q[R]=-1;A[j+1]=0,q[j+1]=0;for(var k=C-N,F=k%2!=0,U=0,ne=0,ue=0,K=0,W=0;W<M;W++){for(var z=-W+U;z<=W-ne;z+=2){var Q=j+z,re;z==-W||z!=W&&A[Q-1]<A[Q+1]?re=A[Q+1]:re=A[Q-1]+1;for(var Z=re-z;re<C&&Z<N&&m.charAt(re)==S.charAt(Z);)re++,Z++;if(A[Q]=re,re>C)ne+=2;else if(Z>N)U+=2;else if(F){var X=j+k-z;if(X>=0&&X<I&&q[X]!=-1){var H=C-q[X];if(re>=H)return a(m,S,re,Z)}}}for(var ee=-W+ue;ee<=W-K;ee+=2){var X=j+ee,H;ee==-W||ee!=W&&q[X-1]<q[X+1]?H=q[X+1]:H=q[X-1]+1;for(var le=H-ee;H<C&&le<N&&m.charAt(C-H-1)==S.charAt(N-le-1);)H++,le++;if(q[X]=H,H>C)K+=2;else if(le>N)ue+=2;else if(!F){var Q=j+k-ee;if(Q>=0&&Q<I&&A[Q]!=-1){var re=A[Q],Z=j+re-Q;if(H=C-H,re>=H)return a(m,S,re,Z)}}}}return[[o,m],[s,S]]}function a(m,S,C,N){var M=m.substring(0,C),j=S.substring(0,N),I=m.substring(C),A=S.substring(N),q=c(M,j),R=c(I,A);return q.concat(R)}function u(m,S){if(!m||!S||m.charAt(0)!=S.charAt(0))return 0;for(var C=0,N=Math.min(m.length,S.length),M=N,j=0;C<M;)m.substring(j,M)==S.substring(j,M)?(C=M,j=C):N=M,M=Math.floor((N-C)/2+C);return M}function d(m,S){if(!m||!S||m.charAt(m.length-1)!=S.charAt(S.length-1))return 0;for(var C=0,N=Math.min(m.length,S.length),M=N,j=0;C<M;)m.substring(m.length-M,m.length-j)==S.substring(S.length-M,S.length-j)?(C=M,j=C):N=M,M=Math.floor((N-C)/2+C);return M}function p(m,S){var C=m.length>S.length?m:S,N=m.length>S.length?S:m;if(C.length<4||N.length*2<C.length)return null;function M(ne,ue,K){for(var W=ne.substring(K,K+Math.floor(ne.length/4)),z=-1,Q="",re,Z,X,H;(z=ue.indexOf(W,z+1))!=-1;){var ee=u(ne.substring(K),ue.substring(z)),le=d(ne.substring(0,K),ue.substring(0,z));Q.length<le+ee&&(Q=ue.substring(z-le,z)+ue.substring(z,z+ee),re=ne.substring(0,K-le),Z=ne.substring(K+ee),X=ue.substring(0,z-le),H=ue.substring(z+ee))}return Q.length*2>=ne.length?[re,Z,X,H,Q]:null}var j=M(C,N,Math.ceil(C.length/4)),I=M(C,N,Math.ceil(C.length/2)),A;if(!j&&!I)return null;I?j?A=j[4].length>I[4].length?j:I:A=I:A=j;var q,R,k,F;m.length>S.length?(q=A[0],R=A[1],k=A[2],F=A[3]):(k=A[0],F=A[1],q=A[2],R=A[3]);var U=A[4];return[q,R,k,F,U]}function O(m){m.push([l,""]);for(var S=0,C=0,N=0,M="",j="",I;S<m.length;)switch(m[S][0]){case s:N++,j+=m[S][1],S++;break;case o:C++,M+=m[S][1],S++;break;case l:C+N>1?(C!==0&&N!==0&&(I=u(j,M),I!==0&&(S-C-N>0&&m[S-C-N-1][0]==l?m[S-C-N-1][1]+=j.substring(0,I):(m.splice(0,0,[l,j.substring(0,I)]),S++),j=j.substring(I),M=M.substring(I)),I=d(j,M),I!==0&&(m[S][1]=j.substring(j.length-I)+m[S][1],j=j.substring(0,j.length-I),M=M.substring(0,M.length-I))),C===0?m.splice(S-N,C+N,[s,j]):N===0?m.splice(S-C,C+N,[o,M]):m.splice(S-C-N,C+N,[o,M],[s,j]),S=S-C-N+(C?1:0)+(N?1:0)+1):S!==0&&m[S-1][0]==l?(m[S-1][1]+=m[S][1],m.splice(S,1)):S++,N=0,C=0,M="",j="";break}m[m.length-1][1]===""&&m.pop();var A=!1;for(S=1;S<m.length-1;)m[S-1][0]==l&&m[S+1][0]==l&&(m[S][1].substring(m[S][1].length-m[S-1][1].length)==m[S-1][1]?(m[S][1]=m[S-1][1]+m[S][1].substring(0,m[S][1].length-m[S-1][1].length),m[S+1][1]=m[S-1][1]+m[S+1][1],m.splice(S-1,1),A=!0):m[S][1].substring(0,m[S+1][1].length)==m[S+1][1]&&(m[S-1][1]+=m[S+1][1],m[S][1]=m[S][1].substring(m[S+1][1].length)+m[S+1][1],m.splice(S+1,1),A=!0)),S++;A&&O(m)}var g=c;g.INSERT=s,g.DELETE=o,g.EQUAL=l,n.exports=g;function _(m,S){if(S===0)return[l,m];for(var C=0,N=0;N<m.length;N++){var M=m[N];if(M[0]===o||M[0]===l){var j=C+M[1].length;if(S===j)return[N+1,m];if(S<j){m=m.slice();var I=S-C,A=[M[0],M[1].slice(0,I)],q=[M[0],M[1].slice(I)];return m.splice(N,1,A,q),[N+1,m]}else C=j}}throw new Error("cursor_pos is out of bounds!")}function y(m,S){var C=_(m,S),N=C[1],M=C[0],j=N[M],I=N[M+1];if(j==null)return m;if(j[0]!==l)return m;if(I!=null&&j[1]+I[1]===I[1]+j[1])return N.splice(M,2,I,j),E(N,M,2);if(I!=null&&I[1].indexOf(j[1])===0){N.splice(M,2,[I[0],j[1]],[0,j[1]]);var A=I[1].slice(j[1].length);return A.length>0&&N.splice(M+2,0,[I[0],A]),E(N,M,3)}else return m}function w(m){for(var S=!1,C=function(I){return I.charCodeAt(0)>=56320&&I.charCodeAt(0)<=57343},N=function(I){return I.charCodeAt(I.length-1)>=55296&&I.charCodeAt(I.length-1)<=56319},M=2;M<m.length;M+=1)m[M-2][0]===l&&N(m[M-2][1])&&m[M-1][0]===o&&C(m[M-1][1])&&m[M][0]===s&&C(m[M][1])&&(S=!0,m[M-1][1]=m[M-2][1].slice(-1)+m[M-1][1],m[M][1]=m[M-2][1].slice(-1)+m[M][1],m[M-2][1]=m[M-2][1].slice(0,-1));if(!S)return m;for(var j=[],M=0;M<m.length;M+=1)m[M][1].length>0&&j.push(m[M]);return j}function E(m,S,C){for(var N=S+C-1;N>=0&&N>=S-1;N--)if(N+1<m.length){var M=m[N],j=m[N+1];M[0]===j[1]&&m.splice(N,2,[M[0],M[1]+j[1]])}return m}}),(function(n,r){r=n.exports=typeof Object.keys=="function"?Object.keys:o,r.shim=o;function o(s){var l=[];for(var c in s)l.push(c);return l}}),(function(n,r){var o=(function(){return Object.prototype.toString.call(arguments)})()=="[object Arguments]";r=n.exports=o?s:l,r.supported=s;function s(c){return Object.prototype.toString.call(c)=="[object Arguments]"}r.unsupported=l;function l(c){return c&&typeof c=="object"&&typeof c.length=="number"&&Object.prototype.hasOwnProperty.call(c,"callee")&&!Object.prototype.propertyIsEnumerable.call(c,"callee")||!1}}),(function(n,r){var o=Object.prototype.hasOwnProperty,s="~";function l(){}Object.create&&(l.prototype=Object.create(null),new l().__proto__||(s=!1));function c(h,a,u){this.fn=h,this.context=a,this.once=u||!1}function f(){this._events=new l,this._eventsCount=0}f.prototype.eventNames=function(){var a=[],u,d;if(this._eventsCount===0)return a;for(d in u=this._events)o.call(u,d)&&a.push(s?d.slice(1):d);return Object.getOwnPropertySymbols?a.concat(Object.getOwnPropertySymbols(u)):a},f.prototype.listeners=function(a,u){var d=s?s+a:a,p=this._events[d];if(u)return!!p;if(!p)return[];if(p.fn)return[p.fn];for(var O=0,g=p.length,_=new Array(g);O<g;O++)_[O]=p[O].fn;return _},f.prototype.emit=function(a,u,d,p,O,g){var _=s?s+a:a;if(!this._events[_])return!1;var y=this._events[_],w=arguments.length,E,m;if(y.fn){switch(y.once&&this.removeListener(a,y.fn,void 0,!0),w){case 1:return y.fn.call(y.context),!0;case 2:return y.fn.call(y.context,u),!0;case 3:return y.fn.call(y.context,u,d),!0;case 4:return y.fn.call(y.context,u,d,p),!0;case 5:return y.fn.call(y.context,u,d,p,O),!0;case 6:return y.fn.call(y.context,u,d,p,O,g),!0}for(m=1,E=new Array(w-1);m<w;m++)E[m-1]=arguments[m];y.fn.apply(y.context,E)}else{var S=y.length,C;for(m=0;m<S;m++)switch(y[m].once&&this.removeListener(a,y[m].fn,void 0,!0),w){case 1:y[m].fn.call(y[m].context);break;case 2:y[m].fn.call(y[m].context,u);break;case 3:y[m].fn.call(y[m].context,u,d);break;case 4:y[m].fn.call(y[m].context,u,d,p);break;default:if(!E)for(C=1,E=new Array(w-1);C<w;C++)E[C-1]=arguments[C];y[m].fn.apply(y[m].context,E)}}return!0},f.prototype.on=function(a,u,d){var p=new c(u,d||this),O=s?s+a:a;return this._events[O]?this._events[O].fn?this._events[O]=[this._events[O],p]:this._events[O].push(p):(this._events[O]=p,this._eventsCount++),this},f.prototype.once=function(a,u,d){var p=new c(u,d||this,!0),O=s?s+a:a;return this._events[O]?this._events[O].fn?this._events[O]=[this._events[O],p]:this._events[O].push(p):(this._events[O]=p,this._eventsCount++),this},f.prototype.removeListener=function(a,u,d,p){var O=s?s+a:a;if(!this._events[O])return this;if(!u)return--this._eventsCount===0?this._events=new l:delete this._events[O],this;var g=this._events[O];if(g.fn)g.fn===u&&(!p||g.once)&&(!d||g.context===d)&&(--this._eventsCount===0?this._events=new l:delete this._events[O]);else{for(var _=0,y=[],w=g.length;_<w;_++)(g[_].fn!==u||p&&!g[_].once||d&&g[_].context!==d)&&y.push(g[_]);y.length?this._events[O]=y.length===1?y[0]:y:--this._eventsCount===0?this._events=new l:delete this._events[O]}return this},f.prototype.removeAllListeners=function(a){var u;return a?(u=s?s+a:a,this._events[u]&&(--this._eventsCount===0?this._events=new l:delete this._events[u])):(this._events=new l,this._eventsCount=0),this},f.prototype.off=f.prototype.removeListener,f.prototype.addListener=f.prototype.on,f.prototype.setMaxListeners=function(){return this},f.prefixed=s,f.EventEmitter=f,typeof n<"u"&&(n.exports=f)}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.matchText=r.matchSpacing=r.matchNewline=r.matchBlot=r.matchAttributor=r.default=void 0;var s=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(ge){return typeof ge}:function(ge){return ge&&typeof Symbol=="function"&&ge.constructor===Symbol&&ge!==Symbol.prototype?"symbol":typeof ge},l=(function(){function ge(me,ke){var Ne=[],we=!0,qe=!1,je=void 0;try{for(var ze=me[Symbol.iterator](),lt;!(we=(lt=ze.next()).done)&&(Ne.push(lt.value),!(ke&&Ne.length===ke));we=!0);}catch(pt){qe=!0,je=pt}finally{try{!we&&ze.return&&ze.return()}finally{if(qe)throw je}}return Ne}return function(me,ke){if(Array.isArray(me))return me;if(Symbol.iterator in Object(me))return ge(me,ke);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function ge(me,ke){for(var Ne=0;Ne<ke.length;Ne++){var we=ke[Ne];we.enumerable=we.enumerable||!1,we.configurable=!0,"value"in we&&(we.writable=!0),Object.defineProperty(me,we.key,we)}}return function(me,ke,Ne){return ke&&ge(me.prototype,ke),Ne&&ge(me,Ne),me}})(),f=o(3),h=q(f),a=o(2),u=q(a),d=o(0),p=q(d),O=o(5),g=q(O),_=o(10),y=q(_),w=o(9),E=q(w),m=o(36),S=o(37),C=o(13),N=q(C),M=o(26),j=o(38),I=o(39),A=o(40);function q(ge){return ge&&ge.__esModule?ge:{default:ge}}function R(ge,me,ke){return me in ge?Object.defineProperty(ge,me,{value:ke,enumerable:!0,configurable:!0,writable:!0}):ge[me]=ke,ge}function k(ge,me){if(!(ge instanceof me))throw new TypeError("Cannot call a class as a function")}function F(ge,me){if(!ge)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return me&&(typeof me=="object"||typeof me=="function")?me:ge}function U(ge,me){if(typeof me!="function"&&me!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof me);ge.prototype=Object.create(me&&me.prototype,{constructor:{value:ge,enumerable:!1,writable:!0,configurable:!0}}),me&&(Object.setPrototypeOf?Object.setPrototypeOf(ge,me):ge.__proto__=me)}var ne=(0,y.default)("quill:clipboard"),ue="__ql-matcher",K=[[Node.TEXT_NODE,Oe],[Node.TEXT_NODE,Ae],["br",Ee],[Node.ELEMENT_NODE,Ae],[Node.ELEMENT_NODE,pe],[Node.ELEMENT_NODE,Se],[Node.ELEMENT_NODE,de],[Node.ELEMENT_NODE,Ge],["li",Pe],["b",le.bind(le,"bold")],["i",le.bind(le,"italic")],["style",Ie]],W=[m.AlignAttribute,j.DirectionAttribute].reduce(function(ge,me){return ge[me.keyName]=me,ge},{}),z=[m.AlignStyle,S.BackgroundStyle,M.ColorStyle,j.DirectionStyle,I.FontStyle,A.SizeStyle].reduce(function(ge,me){return ge[me.keyName]=me,ge},{}),Q=(function(ge){U(me,ge);function me(ke,Ne){k(this,me);var we=F(this,(me.__proto__||Object.getPrototypeOf(me)).call(this,ke,Ne));return we.quill.root.addEventListener("paste",we.onPaste.bind(we)),we.container=we.quill.addContainer("ql-clipboard"),we.container.setAttribute("contenteditable",!0),we.container.setAttribute("tabindex",-1),we.matchers=[],K.concat(we.options.matchers).forEach(function(qe){var je=l(qe,2),ze=je[0],lt=je[1];!Ne.matchVisual&<===Se||we.addMatcher(ze,lt)}),we}return c(me,[{key:"addMatcher",value:function(Ne,we){this.matchers.push([Ne,we])}},{key:"convert",value:function(Ne){if(typeof Ne=="string")return this.container.innerHTML=Ne.replace(/\>\r?\n +\</g,"><"),this.convert();var we=this.quill.getFormat(this.quill.selection.savedRange.index);if(we[N.default.blotName]){var qe=this.container.innerText;return this.container.innerHTML="",new u.default().insert(qe,R({},N.default.blotName,we[N.default.blotName]))}var je=this.prepareMatching(),ze=l(je,2),lt=ze[0],pt=ze[1],Ze=ee(this.container,lt,pt);return X(Ze,`
|
|
61
|
-
`)&&
|
|
62
|
-
`)||
|
|
63
|
-
`),
|
|
64
|
-
`))return
|
|
65
|
-
`)||(
|
|
66
|
-
`),
|
|
67
|
-
|
|
68
|
-
`)){var
|
|
69
|
-
`)}return me}function Ge(ge,me){var ke={},Ne=ge.style||{};return Ne.fontStyle&&Z(ge).fontStyle==="italic"&&(ke.italic=!0),Ne.fontWeight&&(Z(ge).fontWeight.startsWith("bold")||parseInt(Z(ge).fontWeight)>=700)&&(ke.bold=!0),Object.keys(ke).length>0&&(me=re(me,ke)),parseFloat(Ne.textIndent||0)>0&&(me=new u.default().insert(" ").concat(me)),me}function Oe(ge,me){var ke=ge.data;if(ge.parentNode.tagName==="O:P")return me.insert(ke.trim());if(ke.trim().length===0&&ge.parentNode.classList.contains("ql-clipboard"))return me;if(!Z(ge.parentNode).whiteSpace.startsWith("pre")){var Ne=function(qe,je){return je=je.replace(/[^\u00a0]/g,""),je.length<1&&qe?" ":je};ke=ke.replace(/\r\n/g," ").replace(/\n/g," "),ke=ke.replace(/\s\s+/g,Ne.bind(Ne,!0)),(ge.previousSibling==null&&H(ge.parentNode)||ge.previousSibling!=null&&H(ge.previousSibling))&&(ke=ke.replace(/^\s+/,Ne.bind(Ne,!1))),(ge.nextSibling==null&&H(ge.parentNode)||ge.nextSibling!=null&&H(ge.nextSibling))&&(ke=ke.replace(/\s+$/,Ne.bind(Ne,!1)))}return me.insert(ke)}r.default=Q,r.matchAttributor=de,r.matchBlot=pe,r.matchNewline=Ae,r.matchSpacing=Se,r.matchText=Oe}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function O(g,_){for(var y=0;y<_.length;y++){var w=_[y];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(g,w.key,w)}}return function(g,_,y){return _&&O(g.prototype,_),y&&O(g,y),g}})(),l=function O(g,_,y){g===null&&(g=Function.prototype);var w=Object.getOwnPropertyDescriptor(g,_);if(w===void 0){var E=Object.getPrototypeOf(g);return E===null?void 0:O(E,_,y)}else{if("value"in w)return w.value;var m=w.get;return m===void 0?void 0:m.call(y)}},c=o(6),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(){return a(this,g),u(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,[{key:"optimize",value:function(y){l(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"optimize",this).call(this,y),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return l(g.__proto__||Object.getPrototypeOf(g),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),g})(f.default);p.blotName="bold",p.tagName=["STRONG","B"],r.default=p}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.addControls=r.default=void 0;var s=(function(){function A(q,R){var k=[],F=!0,U=!1,ne=void 0;try{for(var ue=q[Symbol.iterator](),K;!(F=(K=ue.next()).done)&&(k.push(K.value),!(R&&k.length===R));F=!0);}catch(W){U=!0,ne=W}finally{try{!F&&ue.return&&ue.return()}finally{if(U)throw ne}}return k}return function(q,R){if(Array.isArray(q))return q;if(Symbol.iterator in Object(q))return A(q,R);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=(function(){function A(q,R){for(var k=0;k<R.length;k++){var F=R[k];F.enumerable=F.enumerable||!1,F.configurable=!0,"value"in F&&(F.writable=!0),Object.defineProperty(q,F.key,F)}}return function(q,R,k){return R&&A(q.prototype,R),k&&A(q,k),q}})(),c=o(2),f=y(c),h=o(0),a=y(h),u=o(5),d=y(u),p=o(10),O=y(p),g=o(9),_=y(g);function y(A){return A&&A.__esModule?A:{default:A}}function w(A,q,R){return q in A?Object.defineProperty(A,q,{value:R,enumerable:!0,configurable:!0,writable:!0}):A[q]=R,A}function E(A,q){if(!(A instanceof q))throw new TypeError("Cannot call a class as a function")}function m(A,q){if(!A)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return q&&(typeof q=="object"||typeof q=="function")?q:A}function S(A,q){if(typeof q!="function"&&q!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof q);A.prototype=Object.create(q&&q.prototype,{constructor:{value:A,enumerable:!1,writable:!0,configurable:!0}}),q&&(Object.setPrototypeOf?Object.setPrototypeOf(A,q):A.__proto__=q)}var C=(0,O.default)("quill:toolbar"),N=(function(A){S(q,A);function q(R,k){E(this,q);var F=m(this,(q.__proto__||Object.getPrototypeOf(q)).call(this,R,k));if(Array.isArray(F.options.container)){var U=document.createElement("div");j(U,F.options.container),R.container.parentNode.insertBefore(U,R.container),F.container=U}else typeof F.options.container=="string"?F.container=document.querySelector(F.options.container):F.container=F.options.container;if(!(F.container instanceof HTMLElement)){var ne;return ne=C.error("Container required for toolbar",F.options),m(F,ne)}return F.container.classList.add("ql-toolbar"),F.controls=[],F.handlers={},Object.keys(F.options.handlers).forEach(function(ue){F.addHandler(ue,F.options.handlers[ue])}),[].forEach.call(F.container.querySelectorAll("button, select"),function(ue){F.attach(ue)}),F.quill.on(d.default.events.EDITOR_CHANGE,function(ue,K){ue===d.default.events.SELECTION_CHANGE&&F.update(K)}),F.quill.on(d.default.events.SCROLL_OPTIMIZE,function(){var ue=F.quill.selection.getRange(),K=s(ue,1),W=K[0];F.update(W)}),F}return l(q,[{key:"addHandler",value:function(k,F){this.handlers[k]=F}},{key:"attach",value:function(k){var F=this,U=[].find.call(k.classList,function(ue){return ue.indexOf("ql-")===0});if(U){if(U=U.slice(3),k.tagName==="BUTTON"&&k.setAttribute("type","button"),this.handlers[U]==null){if(this.quill.scroll.whitelist!=null&&this.quill.scroll.whitelist[U]==null){C.warn("ignoring attaching to disabled format",U,k);return}if(a.default.query(U)==null){C.warn("ignoring attaching to nonexistent format",U,k);return}}var ne=k.tagName==="SELECT"?"change":"click";k.addEventListener(ne,function(ue){var K=void 0;if(k.tagName==="SELECT"){if(k.selectedIndex<0)return;var W=k.options[k.selectedIndex];W.hasAttribute("selected")?K=!1:K=W.value||!1}else k.classList.contains("ql-active")?K=!1:K=k.value||!k.hasAttribute("value"),ue.preventDefault();F.quill.focus();var z=F.quill.selection.getRange(),Q=s(z,1),re=Q[0];if(F.handlers[U]!=null)F.handlers[U].call(F,K);else if(a.default.query(U).prototype instanceof a.default.Embed){if(K=prompt("Enter "+U),!K)return;F.quill.updateContents(new f.default().retain(re.index).delete(re.length).insert(w({},U,K)),d.default.sources.USER)}else F.quill.format(U,K,d.default.sources.USER);F.update(re)}),this.controls.push([U,k])}}},{key:"update",value:function(k){var F=k==null?{}:this.quill.getFormat(k);this.controls.forEach(function(U){var ne=s(U,2),ue=ne[0],K=ne[1];if(K.tagName==="SELECT"){var W=void 0;if(k==null)W=null;else if(F[ue]==null)W=K.querySelector("option[selected]");else if(!Array.isArray(F[ue])){var z=F[ue];typeof z=="string"&&(z=z.replace(/\"/g,'\\"')),W=K.querySelector('option[value="'+z+'"]')}W==null?(K.value="",K.selectedIndex=-1):W.selected=!0}else if(k==null)K.classList.remove("ql-active");else if(K.hasAttribute("value")){var Q=F[ue]===K.getAttribute("value")||F[ue]!=null&&F[ue].toString()===K.getAttribute("value")||F[ue]==null&&!K.getAttribute("value");K.classList.toggle("ql-active",Q)}else K.classList.toggle("ql-active",F[ue]!=null)})}}]),q})(_.default);N.DEFAULTS={};function M(A,q,R){var k=document.createElement("button");k.setAttribute("type","button"),k.classList.add("ql-"+q),R!=null&&(k.value=R),A.appendChild(k)}function j(A,q){Array.isArray(q[0])||(q=[q]),q.forEach(function(R){var k=document.createElement("span");k.classList.add("ql-formats"),R.forEach(function(F){if(typeof F=="string")M(k,F);else{var U=Object.keys(F)[0],ne=F[U];Array.isArray(ne)?I(k,U,ne):M(k,U,ne)}}),A.appendChild(k)})}function I(A,q,R){var k=document.createElement("select");k.classList.add("ql-"+q),R.forEach(function(F){var U=document.createElement("option");F!==!1?U.setAttribute("value",F):U.setAttribute("selected","selected"),k.appendChild(U)}),A.appendChild(k)}N.DEFAULTS={container:null,handlers:{clean:function(){var q=this,R=this.quill.getSelection();if(R!=null)if(R.length==0){var k=this.quill.getFormat();Object.keys(k).forEach(function(F){a.default.query(F,a.default.Scope.INLINE)!=null&&q.quill.format(F,!1)})}else this.quill.removeFormat(R,d.default.sources.USER)},direction:function(q){var R=this.quill.getFormat().align;q==="rtl"&&R==null?this.quill.format("align","right",d.default.sources.USER):!q&&R==="right"&&this.quill.format("align",!1,d.default.sources.USER),this.quill.format("direction",q,d.default.sources.USER)},indent:function(q){var R=this.quill.getSelection(),k=this.quill.getFormat(R),F=parseInt(k.indent||0);if(q==="+1"||q==="-1"){var U=q==="+1"?1:-1;k.direction==="rtl"&&(U*=-1),this.quill.format("indent",F+U,d.default.sources.USER)}},link:function(q){q===!0&&(q=prompt("Enter link URL:")),this.quill.format("link",q,d.default.sources.USER)},list:function(q){var R=this.quill.getSelection(),k=this.quill.getFormat(R);q==="check"?k.list==="checked"||k.list==="unchecked"?this.quill.format("list",!1,d.default.sources.USER):this.quill.format("list","unchecked",d.default.sources.USER):this.quill.format("list",q,d.default.sources.USER)}}},r.default=N,r.addControls=j}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function O(g,_){for(var y=0;y<_.length;y++){var w=_[y];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(g,w.key,w)}}return function(g,_,y){return _&&O(g.prototype,_),y&&O(g,y),g}})(),l=function O(g,_,y){g===null&&(g=Function.prototype);var w=Object.getOwnPropertyDescriptor(g,_);if(w===void 0){var E=Object.getPrototypeOf(g);return E===null?void 0:O(E,_,y)}else{if("value"in w)return w.value;var m=w.get;return m===void 0?void 0:m.call(y)}},c=o(28),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(_,y){a(this,g);var w=u(this,(g.__proto__||Object.getPrototypeOf(g)).call(this,_));return w.label.innerHTML=y,w.container.classList.add("ql-color-picker"),[].slice.call(w.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(E){E.classList.add("ql-primary")}),w}return s(g,[{key:"buildItem",value:function(y){var w=l(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"buildItem",this).call(this,y);return w.style.backgroundColor=y.getAttribute("value")||"",w}},{key:"selectItem",value:function(y,w){l(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"selectItem",this).call(this,y,w);var E=this.label.querySelector(".ql-color-label"),m=y&&y.getAttribute("data-value")||"";E&&(E.tagName==="line"?E.style.stroke=m:E.style.fill=m)}}]),g})(f.default);r.default=p}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function O(g,_){for(var y=0;y<_.length;y++){var w=_[y];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(g,w.key,w)}}return function(g,_,y){return _&&O(g.prototype,_),y&&O(g,y),g}})(),l=function O(g,_,y){g===null&&(g=Function.prototype);var w=Object.getOwnPropertyDescriptor(g,_);if(w===void 0){var E=Object.getPrototypeOf(g);return E===null?void 0:O(E,_,y)}else{if("value"in w)return w.value;var m=w.get;return m===void 0?void 0:m.call(y)}},c=o(28),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(_,y){a(this,g);var w=u(this,(g.__proto__||Object.getPrototypeOf(g)).call(this,_));return w.container.classList.add("ql-icon-picker"),[].forEach.call(w.container.querySelectorAll(".ql-picker-item"),function(E){E.innerHTML=y[E.getAttribute("data-value")||""]}),w.defaultItem=w.container.querySelector(".ql-selected"),w.selectItem(w.defaultItem),w}return s(g,[{key:"selectItem",value:function(y,w){l(g.prototype.__proto__||Object.getPrototypeOf(g.prototype),"selectItem",this).call(this,y,w),y=y||this.defaultItem,this.label.innerHTML=y.innerHTML}}]),g})(f.default);r.default=p}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function f(h,a){for(var u=0;u<a.length;u++){var d=a[u];d.enumerable=d.enumerable||!1,d.configurable=!0,"value"in d&&(d.writable=!0),Object.defineProperty(h,d.key,d)}}return function(h,a,u){return a&&f(h.prototype,a),u&&f(h,u),h}})();function l(f,h){if(!(f instanceof h))throw new TypeError("Cannot call a class as a function")}var c=(function(){function f(h,a){var u=this;l(this,f),this.quill=h,this.boundsContainer=a||document.body,this.root=h.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){u.root.style.marginTop=-1*u.quill.root.scrollTop+"px"}),this.hide()}return s(f,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(a){var u=a.left+a.width/2-this.root.offsetWidth/2,d=a.bottom+this.quill.root.scrollTop;this.root.style.left=u+"px",this.root.style.top=d+"px",this.root.classList.remove("ql-flip");var p=this.boundsContainer.getBoundingClientRect(),O=this.root.getBoundingClientRect(),g=0;if(O.right>p.right&&(g=p.right-O.right,this.root.style.left=u+g+"px"),O.left<p.left&&(g=p.left-O.left,this.root.style.left=u+g+"px"),O.bottom>p.bottom){var _=O.bottom-O.top,y=a.bottom-a.top+_;this.root.style.top=d-y+"px",this.root.classList.add("ql-flip")}return g}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),f})();r.default=c}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function I(A,q){var R=[],k=!0,F=!1,U=void 0;try{for(var ne=A[Symbol.iterator](),ue;!(k=(ue=ne.next()).done)&&(R.push(ue.value),!(q&&R.length===q));k=!0);}catch(K){F=!0,U=K}finally{try{!k&&ne.return&&ne.return()}finally{if(F)throw U}}return R}return function(A,q){if(Array.isArray(A))return A;if(Symbol.iterator in Object(A))return I(A,q);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),l=function I(A,q,R){A===null&&(A=Function.prototype);var k=Object.getOwnPropertyDescriptor(A,q);if(k===void 0){var F=Object.getPrototypeOf(A);return F===null?void 0:I(F,q,R)}else{if("value"in k)return k.value;var U=k.get;return U===void 0?void 0:U.call(R)}},c=(function(){function I(A,q){for(var R=0;R<q.length;R++){var k=q[R];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(A,k.key,k)}}return function(A,q,R){return q&&I(A.prototype,q),R&&I(A,R),A}})(),f=o(3),h=E(f),a=o(8),u=E(a),d=o(43),p=E(d),O=o(27),g=E(O),_=o(15),y=o(41),w=E(y);function E(I){return I&&I.__esModule?I:{default:I}}function m(I,A){if(!(I instanceof A))throw new TypeError("Cannot call a class as a function")}function S(I,A){if(!I)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return A&&(typeof A=="object"||typeof A=="function")?A:I}function C(I,A){if(typeof A!="function"&&A!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof A);I.prototype=Object.create(A&&A.prototype,{constructor:{value:I,enumerable:!1,writable:!0,configurable:!0}}),A&&(Object.setPrototypeOf?Object.setPrototypeOf(I,A):I.__proto__=A)}var N=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],M=(function(I){C(A,I);function A(q,R){m(this,A),R.modules.toolbar!=null&&R.modules.toolbar.container==null&&(R.modules.toolbar.container=N);var k=S(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,q,R));return k.quill.container.classList.add("ql-snow"),k}return c(A,[{key:"extendToolbar",value:function(R){R.container.classList.add("ql-snow"),this.buildButtons([].slice.call(R.container.querySelectorAll("button")),w.default),this.buildPickers([].slice.call(R.container.querySelectorAll("select")),w.default),this.tooltip=new j(this.quill,this.options.bounds),R.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(k,F){R.handlers.link.call(R,!F.format.link)})}}]),A})(p.default);M.DEFAULTS=(0,h.default)(!0,{},p.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(A){if(A){var q=this.quill.getSelection();if(q==null||q.length==0)return;var R=this.quill.getText(q);/^\S+@\S+\.\S+$/.test(R)&&R.indexOf("mailto:")!==0&&(R="mailto:"+R);var k=this.quill.theme.tooltip;k.edit("link",R)}else this.quill.format("link",!1)}}}}});var j=(function(I){C(A,I);function A(q,R){m(this,A);var k=S(this,(A.__proto__||Object.getPrototypeOf(A)).call(this,q,R));return k.preview=k.root.querySelector("a.ql-preview"),k}return c(A,[{key:"listen",value:function(){var R=this;l(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(k){R.root.classList.contains("ql-editing")?R.save():R.edit("link",R.preview.textContent),k.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(k){if(R.linkRange!=null){var F=R.linkRange;R.restoreFocus(),R.quill.formatText(F,"link",!1,u.default.sources.USER),delete R.linkRange}k.preventDefault(),R.hide()}),this.quill.on(u.default.events.SELECTION_CHANGE,function(k,F,U){if(k!=null){if(k.length===0&&U===u.default.sources.USER){var ne=R.quill.scroll.descendant(g.default,k.index),ue=s(ne,2),K=ue[0],W=ue[1];if(K!=null){R.linkRange=new _.Range(k.index-W,K.length());var z=g.default.formats(K.domNode);R.preview.textContent=z,R.preview.setAttribute("href",z),R.show(),R.position(R.quill.getBounds(R.linkRange));return}}else delete R.linkRange;R.hide()}})}},{key:"show",value:function(){l(A.prototype.__proto__||Object.getPrototypeOf(A.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),A})(d.BaseTooltip);j.TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),r.default=M}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(29),l=we(s),c=o(36),f=o(38),h=o(64),a=o(65),u=we(a),d=o(66),p=we(d),O=o(67),g=we(O),_=o(37),y=o(26),w=o(39),E=o(40),m=o(56),S=we(m),C=o(68),N=we(C),M=o(27),j=we(M),I=o(69),A=we(I),q=o(70),R=we(q),k=o(71),F=we(k),U=o(72),ne=we(U),ue=o(73),K=we(ue),W=o(13),z=we(W),Q=o(74),re=we(Q),Z=o(75),X=we(Z),H=o(57),ee=we(H),le=o(41),de=we(le),pe=o(28),Ee=we(pe),Ie=o(59),Pe=we(Ie),Ae=o(60),Se=we(Ae),Ge=o(61),Oe=we(Ge),ge=o(108),me=we(ge),ke=o(62),Ne=we(ke);function we(qe){return qe&&qe.__esModule?qe:{default:qe}}l.default.register({"attributors/attribute/direction":f.DirectionAttribute,"attributors/class/align":c.AlignClass,"attributors/class/background":_.BackgroundClass,"attributors/class/color":y.ColorClass,"attributors/class/direction":f.DirectionClass,"attributors/class/font":w.FontClass,"attributors/class/size":E.SizeClass,"attributors/style/align":c.AlignStyle,"attributors/style/background":_.BackgroundStyle,"attributors/style/color":y.ColorStyle,"attributors/style/direction":f.DirectionStyle,"attributors/style/font":w.FontStyle,"attributors/style/size":E.SizeStyle},!0),l.default.register({"formats/align":c.AlignClass,"formats/direction":f.DirectionClass,"formats/indent":h.IndentClass,"formats/background":_.BackgroundStyle,"formats/color":y.ColorStyle,"formats/font":w.FontClass,"formats/size":E.SizeClass,"formats/blockquote":u.default,"formats/code-block":z.default,"formats/header":p.default,"formats/list":g.default,"formats/bold":S.default,"formats/code":W.Code,"formats/italic":N.default,"formats/link":j.default,"formats/script":A.default,"formats/strike":R.default,"formats/underline":F.default,"formats/image":ne.default,"formats/video":K.default,"formats/list/item":O.ListItem,"modules/formula":re.default,"modules/syntax":X.default,"modules/toolbar":ee.default,"themes/bubble":me.default,"themes/snow":Ne.default,"ui/icons":de.default,"ui/picker":Ee.default,"ui/icon-picker":Se.default,"ui/color-picker":Pe.default,"ui/tooltip":Oe.default},!0),r.default=l.default}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.IndentClass=void 0;var s=(function(){function g(_,y){for(var w=0;w<y.length;w++){var E=y[w];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(_,E.key,E)}}return function(_,y,w){return y&&g(_.prototype,y),w&&g(_,w),_}})(),l=function g(_,y,w){_===null&&(_=Function.prototype);var E=Object.getOwnPropertyDescriptor(_,y);if(E===void 0){var m=Object.getPrototypeOf(_);return m===null?void 0:g(m,y,w)}else{if("value"in E)return E.value;var S=E.get;return S===void 0?void 0:S.call(w)}},c=o(0),f=h(c);function h(g){return g&&g.__esModule?g:{default:g}}function a(g,_){if(!(g instanceof _))throw new TypeError("Cannot call a class as a function")}function u(g,_){if(!g)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _&&(typeof _=="object"||typeof _=="function")?_:g}function d(g,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof _);g.prototype=Object.create(_&&_.prototype,{constructor:{value:g,enumerable:!1,writable:!0,configurable:!0}}),_&&(Object.setPrototypeOf?Object.setPrototypeOf(g,_):g.__proto__=_)}var p=(function(g){d(_,g);function _(){return a(this,_),u(this,(_.__proto__||Object.getPrototypeOf(_)).apply(this,arguments))}return s(_,[{key:"add",value:function(w,E){if(E==="+1"||E==="-1"){var m=this.value(w)||0;E=E==="+1"?m+1:m-1}return E===0?(this.remove(w),!0):l(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"add",this).call(this,w,E)}},{key:"canAdd",value:function(w,E){return l(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"canAdd",this).call(this,w,E)||l(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"canAdd",this).call(this,w,parseInt(E))}},{key:"value",value:function(w){return parseInt(l(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"value",this).call(this,w))||void 0}}]),_})(f.default.Attributor.Class),O=new p("indent","ql-indent",{scope:f.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});r.IndentClass=O}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(4),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}function f(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function h(d,p){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:d}function a(d,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);d.prototype=Object.create(p&&p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(d,p):d.__proto__=p)}var u=(function(d){a(p,d);function p(){return f(this,p),h(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p})(l.default);u.blotName="blockquote",u.tagName="blockquote",r.default=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function p(O,g){for(var _=0;_<g.length;_++){var y=g[_];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(O,y.key,y)}}return function(O,g,_){return g&&p(O.prototype,g),_&&p(O,_),O}})(),l=o(4),c=f(l);function f(p){return p&&p.__esModule?p:{default:p}}function h(p,O){if(!(p instanceof O))throw new TypeError("Cannot call a class as a function")}function a(p,O){if(!p)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return O&&(typeof O=="object"||typeof O=="function")?O:p}function u(p,O){if(typeof O!="function"&&O!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof O);p.prototype=Object.create(O&&O.prototype,{constructor:{value:p,enumerable:!1,writable:!0,configurable:!0}}),O&&(Object.setPrototypeOf?Object.setPrototypeOf(p,O):p.__proto__=O)}var d=(function(p){u(O,p);function O(){return h(this,O),a(this,(O.__proto__||Object.getPrototypeOf(O)).apply(this,arguments))}return s(O,null,[{key:"formats",value:function(_){return this.tagName.indexOf(_.tagName)+1}}]),O})(c.default);d.blotName="header",d.tagName=["H1","H2","H3","H4","H5","H6"],r.default=d}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.ListItem=void 0;var s=(function(){function m(S,C){for(var N=0;N<C.length;N++){var M=C[N];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(S,M.key,M)}}return function(S,C,N){return C&&m(S.prototype,C),N&&m(S,N),S}})(),l=function m(S,C,N){S===null&&(S=Function.prototype);var M=Object.getOwnPropertyDescriptor(S,C);if(M===void 0){var j=Object.getPrototypeOf(S);return j===null?void 0:m(j,C,N)}else{if("value"in M)return M.value;var I=M.get;return I===void 0?void 0:I.call(N)}},c=o(0),f=p(c),h=o(4),a=p(h),u=o(25),d=p(u);function p(m){return m&&m.__esModule?m:{default:m}}function O(m,S,C){return S in m?Object.defineProperty(m,S,{value:C,enumerable:!0,configurable:!0,writable:!0}):m[S]=C,m}function g(m,S){if(!(m instanceof S))throw new TypeError("Cannot call a class as a function")}function _(m,S){if(!m)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return S&&(typeof S=="object"||typeof S=="function")?S:m}function y(m,S){if(typeof S!="function"&&S!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof S);m.prototype=Object.create(S&&S.prototype,{constructor:{value:m,enumerable:!1,writable:!0,configurable:!0}}),S&&(Object.setPrototypeOf?Object.setPrototypeOf(m,S):m.__proto__=S)}var w=(function(m){y(S,m);function S(){return g(this,S),_(this,(S.__proto__||Object.getPrototypeOf(S)).apply(this,arguments))}return s(S,[{key:"format",value:function(N,M){N===E.blotName&&!M?this.replaceWith(f.default.create(this.statics.scope)):l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"format",this).call(this,N,M)}},{key:"remove",value:function(){this.prev==null&&this.next==null?this.parent.remove():l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(N,M){return this.parent.isolate(this.offset(this.parent),this.length()),N===this.parent.statics.blotName?(this.parent.replaceWith(N,M),this):(this.parent.unwrap(),l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"replaceWith",this).call(this,N,M))}}],[{key:"formats",value:function(N){return N.tagName===this.tagName?void 0:l(S.__proto__||Object.getPrototypeOf(S),"formats",this).call(this,N)}}]),S})(a.default);w.blotName="list-item",w.tagName="LI";var E=(function(m){y(S,m),s(S,null,[{key:"create",value:function(N){var M=N==="ordered"?"OL":"UL",j=l(S.__proto__||Object.getPrototypeOf(S),"create",this).call(this,M);return(N==="checked"||N==="unchecked")&&j.setAttribute("data-checked",N==="checked"),j}},{key:"formats",value:function(N){if(N.tagName==="OL")return"ordered";if(N.tagName==="UL")return N.hasAttribute("data-checked")?N.getAttribute("data-checked")==="true"?"checked":"unchecked":"bullet"}}]);function S(C){g(this,S);var N=_(this,(S.__proto__||Object.getPrototypeOf(S)).call(this,C)),M=function(I){if(I.target.parentNode===C){var A=N.statics.formats(C),q=f.default.find(I.target);A==="checked"?q.format("list","unchecked"):A==="unchecked"&&q.format("list","checked")}};return C.addEventListener("touchstart",M),C.addEventListener("mousedown",M),N}return s(S,[{key:"format",value:function(N,M){this.children.length>0&&this.children.tail.format(N,M)}},{key:"formats",value:function(){return O({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(N,M){if(N instanceof w)l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"insertBefore",this).call(this,N,M);else{var j=M==null?this.length():M.offset(this),I=this.split(j);I.parent.insertBefore(N,I)}}},{key:"optimize",value:function(N){l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"optimize",this).call(this,N);var M=this.next;M!=null&&M.prev===this&&M.statics.blotName===this.statics.blotName&&M.domNode.tagName===this.domNode.tagName&&M.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(M.moveChildren(this),M.remove())}},{key:"replace",value:function(N){if(N.statics.blotName!==this.statics.blotName){var M=f.default.create(this.statics.defaultChild);N.moveChildren(M),this.appendChild(M)}l(S.prototype.__proto__||Object.getPrototypeOf(S.prototype),"replace",this).call(this,N)}}]),S})(d.default);E.blotName="list",E.scope=f.default.Scope.BLOCK_BLOT,E.tagName=["OL","UL"],E.defaultChild="list-item",E.allowedChildren=[w],r.ListItem=w,r.default=E}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(56),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}function f(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function h(d,p){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:d}function a(d,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);d.prototype=Object.create(p&&p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(d,p):d.__proto__=p)}var u=(function(d){a(p,d);function p(){return f(this,p),h(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p})(l.default);u.blotName="italic",u.tagName=["EM","I"],r.default=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function O(g,_){for(var y=0;y<_.length;y++){var w=_[y];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(g,w.key,w)}}return function(g,_,y){return _&&O(g.prototype,_),y&&O(g,y),g}})(),l=function O(g,_,y){g===null&&(g=Function.prototype);var w=Object.getOwnPropertyDescriptor(g,_);if(w===void 0){var E=Object.getPrototypeOf(g);return E===null?void 0:O(E,_,y)}else{if("value"in w)return w.value;var m=w.get;return m===void 0?void 0:m.call(y)}},c=o(6),f=h(c);function h(O){return O&&O.__esModule?O:{default:O}}function a(O,g){if(!(O instanceof g))throw new TypeError("Cannot call a class as a function")}function u(O,g){if(!O)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g&&(typeof g=="object"||typeof g=="function")?g:O}function d(O,g){if(typeof g!="function"&&g!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof g);O.prototype=Object.create(g&&g.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),g&&(Object.setPrototypeOf?Object.setPrototypeOf(O,g):O.__proto__=g)}var p=(function(O){d(g,O);function g(){return a(this,g),u(this,(g.__proto__||Object.getPrototypeOf(g)).apply(this,arguments))}return s(g,null,[{key:"create",value:function(y){return y==="super"?document.createElement("sup"):y==="sub"?document.createElement("sub"):l(g.__proto__||Object.getPrototypeOf(g),"create",this).call(this,y)}},{key:"formats",value:function(y){if(y.tagName==="SUB")return"sub";if(y.tagName==="SUP")return"super"}}]),g})(f.default);p.blotName="script",p.tagName=["SUB","SUP"],r.default=p}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(6),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}function f(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function h(d,p){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:d}function a(d,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);d.prototype=Object.create(p&&p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(d,p):d.__proto__=p)}var u=(function(d){a(p,d);function p(){return f(this,p),h(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p})(l.default);u.blotName="strike",u.tagName="S",r.default=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=o(6),l=c(s);function c(d){return d&&d.__esModule?d:{default:d}}function f(d,p){if(!(d instanceof p))throw new TypeError("Cannot call a class as a function")}function h(d,p){if(!d)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return p&&(typeof p=="object"||typeof p=="function")?p:d}function a(d,p){if(typeof p!="function"&&p!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof p);d.prototype=Object.create(p&&p.prototype,{constructor:{value:d,enumerable:!1,writable:!0,configurable:!0}}),p&&(Object.setPrototypeOf?Object.setPrototypeOf(d,p):d.__proto__=p)}var u=(function(d){a(p,d);function p(){return f(this,p),h(this,(p.__proto__||Object.getPrototypeOf(p)).apply(this,arguments))}return p})(l.default);u.blotName="underline",u.tagName="U",r.default=u}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function _(y,w){for(var E=0;E<w.length;E++){var m=w[E];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,E){return w&&_(y.prototype,w),E&&_(y,E),y}})(),l=function _(y,w,E){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var S=Object.getPrototypeOf(y);return S===null?void 0:_(S,w,E)}else{if("value"in m)return m.value;var C=m.get;return C===void 0?void 0:C.call(E)}},c=o(0),f=a(c),h=o(27);function a(_){return _&&_.__esModule?_:{default:_}}function u(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function p(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var O=["alt","height","width"],g=(function(_){p(y,_);function y(){return u(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"format",value:function(E,m){O.indexOf(E)>-1?m?this.domNode.setAttribute(E,m):this.domNode.removeAttribute(E):l(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"format",this).call(this,E,m)}}],[{key:"create",value:function(E){var m=l(y.__proto__||Object.getPrototypeOf(y),"create",this).call(this,E);return typeof E=="string"&&m.setAttribute("src",this.sanitize(E)),m}},{key:"formats",value:function(E){return O.reduce(function(m,S){return E.hasAttribute(S)&&(m[S]=E.getAttribute(S)),m},{})}},{key:"match",value:function(E){return/\.(jpe?g|gif|png)$/.test(E)||/^data:image\/.+;base64/.test(E)}},{key:"sanitize",value:function(E){return(0,h.sanitize)(E,["http","https","data"])?E:"//:0"}},{key:"value",value:function(E){return E.getAttribute("src")}}]),y})(f.default.Embed);g.blotName="image",g.tagName="IMG",r.default=g}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0});var s=(function(){function _(y,w){for(var E=0;E<w.length;E++){var m=w[E];m.enumerable=m.enumerable||!1,m.configurable=!0,"value"in m&&(m.writable=!0),Object.defineProperty(y,m.key,m)}}return function(y,w,E){return w&&_(y.prototype,w),E&&_(y,E),y}})(),l=function _(y,w,E){y===null&&(y=Function.prototype);var m=Object.getOwnPropertyDescriptor(y,w);if(m===void 0){var S=Object.getPrototypeOf(y);return S===null?void 0:_(S,w,E)}else{if("value"in m)return m.value;var C=m.get;return C===void 0?void 0:C.call(E)}},c=o(4),f=o(27),h=a(f);function a(_){return _&&_.__esModule?_:{default:_}}function u(_,y){if(!(_ instanceof y))throw new TypeError("Cannot call a class as a function")}function d(_,y){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:_}function p(_,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);_.prototype=Object.create(y&&y.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(_,y):_.__proto__=y)}var O=["height","width"],g=(function(_){p(y,_);function y(){return u(this,y),d(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return s(y,[{key:"format",value:function(E,m){O.indexOf(E)>-1?m?this.domNode.setAttribute(E,m):this.domNode.removeAttribute(E):l(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"format",this).call(this,E,m)}}],[{key:"create",value:function(E){var m=l(y.__proto__||Object.getPrototypeOf(y),"create",this).call(this,E);return m.setAttribute("frameborder","0"),m.setAttribute("allowfullscreen",!0),m.setAttribute("src",this.sanitize(E)),m}},{key:"formats",value:function(E){return O.reduce(function(m,S){return E.hasAttribute(S)&&(m[S]=E.getAttribute(S)),m},{})}},{key:"sanitize",value:function(E){return h.default.sanitize(E)}},{key:"value",value:function(E){return E.getAttribute("src")}}]),y})(c.BlockEmbed);g.blotName="video",g.className="ql-video",g.tagName="IFRAME",r.default=g}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.FormulaBlot=void 0;var s=(function(){function E(m,S){for(var C=0;C<S.length;C++){var N=S[C];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(m,N.key,N)}}return function(m,S,C){return S&&E(m.prototype,S),C&&E(m,C),m}})(),l=function E(m,S,C){m===null&&(m=Function.prototype);var N=Object.getOwnPropertyDescriptor(m,S);if(N===void 0){var M=Object.getPrototypeOf(m);return M===null?void 0:E(M,S,C)}else{if("value"in N)return N.value;var j=N.get;return j===void 0?void 0:j.call(C)}},c=o(35),f=p(c),h=o(5),a=p(h),u=o(9),d=p(u);function p(E){return E&&E.__esModule?E:{default:E}}function O(E,m){if(!(E instanceof m))throw new TypeError("Cannot call a class as a function")}function g(E,m){if(!E)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return m&&(typeof m=="object"||typeof m=="function")?m:E}function _(E,m){if(typeof m!="function"&&m!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof m);E.prototype=Object.create(m&&m.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}),m&&(Object.setPrototypeOf?Object.setPrototypeOf(E,m):E.__proto__=m)}var y=(function(E){_(m,E);function m(){return O(this,m),g(this,(m.__proto__||Object.getPrototypeOf(m)).apply(this,arguments))}return s(m,null,[{key:"create",value:function(C){var N=l(m.__proto__||Object.getPrototypeOf(m),"create",this).call(this,C);return typeof C=="string"&&(window.katex.render(C,N,{throwOnError:!1,errorColor:"#f00"}),N.setAttribute("data-value",C)),N}},{key:"value",value:function(C){return C.getAttribute("data-value")}}]),m})(f.default);y.blotName="formula",y.className="ql-formula",y.tagName="SPAN";var w=(function(E){_(m,E),s(m,null,[{key:"register",value:function(){a.default.register(y,!0)}}]);function m(){O(this,m);var S=g(this,(m.__proto__||Object.getPrototypeOf(m)).call(this));if(window.katex==null)throw new Error("Formula module requires KaTeX.");return S}return m})(d.default);r.FormulaBlot=y,r.default=w}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.CodeToken=r.CodeBlock=void 0;var s=(function(){function C(N,M){for(var j=0;j<M.length;j++){var I=M[j];I.enumerable=I.enumerable||!1,I.configurable=!0,"value"in I&&(I.writable=!0),Object.defineProperty(N,I.key,I)}}return function(N,M,j){return M&&C(N.prototype,M),j&&C(N,j),N}})(),l=function C(N,M,j){N===null&&(N=Function.prototype);var I=Object.getOwnPropertyDescriptor(N,M);if(I===void 0){var A=Object.getPrototypeOf(N);return A===null?void 0:C(A,M,j)}else{if("value"in I)return I.value;var q=I.get;return q===void 0?void 0:q.call(j)}},c=o(0),f=g(c),h=o(5),a=g(h),u=o(9),d=g(u),p=o(13),O=g(p);function g(C){return C&&C.__esModule?C:{default:C}}function _(C,N){if(!(C instanceof N))throw new TypeError("Cannot call a class as a function")}function y(C,N){if(!C)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return N&&(typeof N=="object"||typeof N=="function")?N:C}function w(C,N){if(typeof N!="function"&&N!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof N);C.prototype=Object.create(N&&N.prototype,{constructor:{value:C,enumerable:!1,writable:!0,configurable:!0}}),N&&(Object.setPrototypeOf?Object.setPrototypeOf(C,N):C.__proto__=N)}var E=(function(C){w(N,C);function N(){return _(this,N),y(this,(N.__proto__||Object.getPrototypeOf(N)).apply(this,arguments))}return s(N,[{key:"replaceWith",value:function(j){this.domNode.textContent=this.domNode.textContent,this.attach(),l(N.prototype.__proto__||Object.getPrototypeOf(N.prototype),"replaceWith",this).call(this,j)}},{key:"highlight",value:function(j){var I=this.domNode.textContent;this.cachedText!==I&&((I.trim().length>0||this.cachedText==null)&&(this.domNode.innerHTML=j(I),this.domNode.normalize(),this.attach()),this.cachedText=I)}}]),N})(O.default);E.className="ql-syntax";var m=new f.default.Attributor.Class("token","hljs",{scope:f.default.Scope.INLINE}),S=(function(C){w(N,C),s(N,null,[{key:"register",value:function(){a.default.register(m,!0),a.default.register(E,!0)}}]);function N(M,j){_(this,N);var I=y(this,(N.__proto__||Object.getPrototypeOf(N)).call(this,M,j));if(typeof I.options.highlight!="function")throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var A=null;return I.quill.on(a.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(A),A=setTimeout(function(){I.highlight(),A=null},I.options.interval)}),I.highlight(),I}return s(N,[{key:"highlight",value:function(){var j=this;if(!this.quill.selection.composing){this.quill.update(a.default.sources.USER);var I=this.quill.getSelection();this.quill.scroll.descendants(E).forEach(function(A){A.highlight(j.options.highlight)}),this.quill.update(a.default.sources.SILENT),I!=null&&this.quill.setSelection(I,a.default.sources.SILENT)}}}]),N})(d.default);S.DEFAULTS={highlight:(function(){return window.hljs==null?null:function(C){var N=window.hljs.highlightAuto(C);return N.value}})(),interval:1e3},r.CodeBlock=E,r.CodeToken=m,r.default=S}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'}),(function(n,r){n.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'}),(function(n,r){n.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'}),(function(n,r){n.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'}),(function(n,r){n.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'}),(function(n,r){n.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'}),(function(n,r,o){Object.defineProperty(r,"__esModule",{value:!0}),r.default=r.BubbleTooltip=void 0;var s=function N(M,j,I){M===null&&(M=Function.prototype);var A=Object.getOwnPropertyDescriptor(M,j);if(A===void 0){var q=Object.getPrototypeOf(M);return q===null?void 0:N(q,j,I)}else{if("value"in A)return A.value;var R=A.get;return R===void 0?void 0:R.call(I)}},l=(function(){function N(M,j){for(var I=0;I<j.length;I++){var A=j[I];A.enumerable=A.enumerable||!1,A.configurable=!0,"value"in A&&(A.writable=!0),Object.defineProperty(M,A.key,A)}}return function(M,j,I){return j&&N(M.prototype,j),I&&N(M,I),M}})(),c=o(3),f=_(c),h=o(8),a=_(h),u=o(43),d=_(u),p=o(15),O=o(41),g=_(O);function _(N){return N&&N.__esModule?N:{default:N}}function y(N,M){if(!(N instanceof M))throw new TypeError("Cannot call a class as a function")}function w(N,M){if(!N)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return M&&(typeof M=="object"||typeof M=="function")?M:N}function E(N,M){if(typeof M!="function"&&M!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof M);N.prototype=Object.create(M&&M.prototype,{constructor:{value:N,enumerable:!1,writable:!0,configurable:!0}}),M&&(Object.setPrototypeOf?Object.setPrototypeOf(N,M):N.__proto__=M)}var m=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],S=(function(N){E(M,N);function M(j,I){y(this,M),I.modules.toolbar!=null&&I.modules.toolbar.container==null&&(I.modules.toolbar.container=m);var A=w(this,(M.__proto__||Object.getPrototypeOf(M)).call(this,j,I));return A.quill.container.classList.add("ql-bubble"),A}return l(M,[{key:"extendToolbar",value:function(I){this.tooltip=new C(this.quill,this.options.bounds),this.tooltip.root.appendChild(I.container),this.buildButtons([].slice.call(I.container.querySelectorAll("button")),g.default),this.buildPickers([].slice.call(I.container.querySelectorAll("select")),g.default)}}]),M})(d.default);S.DEFAULTS=(0,f.default)(!0,{},d.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(M){M?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var C=(function(N){E(M,N);function M(j,I){y(this,M);var A=w(this,(M.__proto__||Object.getPrototypeOf(M)).call(this,j,I));return A.quill.on(a.default.events.EDITOR_CHANGE,function(q,R,k,F){if(q===a.default.events.SELECTION_CHANGE)if(R!=null&&R.length>0&&F===a.default.sources.USER){A.show(),A.root.style.left="0px",A.root.style.width="",A.root.style.width=A.root.offsetWidth+"px";var U=A.quill.getLines(R.index,R.length);if(U.length===1)A.position(A.quill.getBounds(R));else{var ne=U[U.length-1],ue=A.quill.getIndex(ne),K=Math.min(ne.length()-1,R.index+R.length-ue),W=A.quill.getBounds(new p.Range(ue,K));A.position(W)}}else document.activeElement!==A.textbox&&A.quill.hasFocus()&&A.hide()}),A}return l(M,[{key:"listen",value:function(){var I=this;s(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){I.root.classList.remove("ql-editing")}),this.quill.on(a.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!I.root.classList.contains("ql-hidden")){var A=I.quill.getSelection();A!=null&&I.position(I.quill.getBounds(A))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(I){var A=s(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"position",this).call(this,I),q=this.root.querySelector(".ql-tooltip-arrow");if(q.style.marginLeft="",A===0)return A;q.style.marginLeft=-1*A-q.offsetWidth/2+"px"}}]),M})(u.BaseTooltip);C.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),r.BubbleTooltip=C,r.default=S}),(function(n,r,o){n.exports=o(63)})]).default})})(ca)),ca.exports}var cn,ZO;function nL(){if(ZO)return cn;ZO=1;var e=cn&&cn.__extends||(function(){var a=function(u,d){return a=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,O){p.__proto__=O}||function(p,O){for(var g in O)O.hasOwnProperty(g)&&(p[g]=O[g])},a(u,d)};return function(u,d){a(u,d);function p(){this.constructor=u}u.prototype=d===null?Object.create(d):(p.prototype=d.prototype,new p)}})(),t=cn&&cn.__assign||function(){return t=Object.assign||function(a){for(var u,d=1,p=arguments.length;d<p;d++){u=arguments[d];for(var O in u)Object.prototype.hasOwnProperty.call(u,O)&&(a[O]=u[O])}return a},t.apply(this,arguments)},n=cn&&cn.__spreadArrays||function(){for(var a=0,u=0,d=arguments.length;u<d;u++)a+=arguments[u].length;for(var p=Array(a),O=0,u=0;u<d;u++)for(var g=arguments[u],_=0,y=g.length;_<y;_++,O++)p[O]=g[_];return p},r=cn&&cn.__importDefault||function(a){return a&&a.__esModule?a:{default:a}},o=r(nt.default),s=r(pv.default),l=r(Jq()),c=r(tL()),f=(function(a){e(u,a);function u(d){var p=a.call(this,d)||this;p.dirtyProps=["modules","formats","bounds","theme","children"],p.cleanProps=["id","className","style","placeholder","tabIndex","onChange","onChangeSelection","onFocus","onBlur","onKeyPress","onKeyDown","onKeyUp"],p.state={generation:0},p.selection=null,p.onEditorChange=function(g,_,y,w){var E,m,S,C;g==="text-change"?(m=(E=p).onEditorChangeText)===null||m===void 0||m.call(E,p.editor.root.innerHTML,_,w,p.unprivilegedEditor):g==="selection-change"&&((C=(S=p).onEditorChangeSelection)===null||C===void 0||C.call(S,_,w,p.unprivilegedEditor))};var O=p.isControlled()?d.value:d.defaultValue;return p.value=O??"",p}return u.prototype.validateProps=function(d){var p;if(o.default.Children.count(d.children)>1)throw new Error("The Quill editing area can only be composed of a single React element.");if(o.default.Children.count(d.children)){var O=o.default.Children.only(d.children);if(((p=O)===null||p===void 0?void 0:p.type)==="textarea")throw new Error("Quill does not support editing on a <textarea>. Use a <div> instead.")}if(this.lastDeltaChangeSet&&d.value===this.lastDeltaChangeSet)throw new Error("You are passing the `delta` object from the `onChange` event back as `value`. You most probably want `editor.getContents()` instead. See: https://github.com/zenoamaro/react-quill#using-deltas")},u.prototype.shouldComponentUpdate=function(d,p){var O=this,g;if(this.validateProps(d),!this.editor||this.state.generation!==p.generation)return!0;if("value"in d){var _=this.getEditorContents(),y=(g=d.value,g??"");this.isEqualValue(y,_)||this.setEditorContents(this.editor,y)}return d.readOnly!==this.props.readOnly&&this.setEditorReadOnly(this.editor,d.readOnly),n(this.cleanProps,this.dirtyProps).some(function(w){return!l.default(d[w],O.props[w])})},u.prototype.shouldComponentRegenerate=function(d){var p=this;return this.dirtyProps.some(function(O){return!l.default(d[O],p.props[O])})},u.prototype.componentDidMount=function(){this.instantiateEditor(),this.setEditorContents(this.editor,this.getEditorContents())},u.prototype.componentWillUnmount=function(){this.destroyEditor()},u.prototype.componentDidUpdate=function(d,p){var O=this;if(this.editor&&this.shouldComponentRegenerate(d)){var g=this.editor.getContents(),_=this.editor.getSelection();this.regenerationSnapshot={delta:g,selection:_},this.setState({generation:this.state.generation+1}),this.destroyEditor()}if(this.state.generation!==p.generation){var y=this.regenerationSnapshot,g=y.delta,w=y.selection;delete this.regenerationSnapshot,this.instantiateEditor();var E=this.editor;E.setContents(g),h(function(){return O.setEditorSelection(E,w)})}},u.prototype.instantiateEditor=function(){this.editor?this.hookEditor(this.editor):this.editor=this.createEditor(this.getEditingArea(),this.getEditorConfig())},u.prototype.destroyEditor=function(){this.editor&&this.unhookEditor(this.editor)},u.prototype.isControlled=function(){return"value"in this.props},u.prototype.getEditorConfig=function(){return{bounds:this.props.bounds,formats:this.props.formats,modules:this.props.modules,placeholder:this.props.placeholder,readOnly:this.props.readOnly,scrollingContainer:this.props.scrollingContainer,tabIndex:this.props.tabIndex,theme:this.props.theme}},u.prototype.getEditor=function(){if(!this.editor)throw new Error("Accessing non-instantiated editor");return this.editor},u.prototype.createEditor=function(d,p){var O=new c.default(d,p);return p.tabIndex!=null&&this.setEditorTabIndex(O,p.tabIndex),this.hookEditor(O),O},u.prototype.hookEditor=function(d){this.unprivilegedEditor=this.makeUnprivilegedEditor(d),d.on("editor-change",this.onEditorChange)},u.prototype.unhookEditor=function(d){d.off("editor-change",this.onEditorChange)},u.prototype.getEditorContents=function(){return this.value},u.prototype.getEditorSelection=function(){return this.selection},u.prototype.isDelta=function(d){return d&&d.ops},u.prototype.isEqualValue=function(d,p){return this.isDelta(d)&&this.isDelta(p)?l.default(d.ops,p.ops):l.default(d,p)},u.prototype.setEditorContents=function(d,p){var O=this;this.value=p;var g=this.getEditorSelection();typeof p=="string"?d.setContents(d.clipboard.convert(p)):d.setContents(p),h(function(){return O.setEditorSelection(d,g)})},u.prototype.setEditorSelection=function(d,p){if(this.selection=p,p){var O=d.getLength();p.index=Math.max(0,Math.min(p.index,O-1)),p.length=Math.max(0,Math.min(p.length,O-1-p.index)),d.setSelection(p)}},u.prototype.setEditorTabIndex=function(d,p){var O,g;!((g=(O=d)===null||O===void 0?void 0:O.scroll)===null||g===void 0)&&g.domNode&&(d.scroll.domNode.tabIndex=p)},u.prototype.setEditorReadOnly=function(d,p){p?d.disable():d.enable()},u.prototype.makeUnprivilegedEditor=function(d){var p=d;return{getHTML:function(){return p.root.innerHTML},getLength:p.getLength.bind(p),getText:p.getText.bind(p),getContents:p.getContents.bind(p),getSelection:p.getSelection.bind(p),getBounds:p.getBounds.bind(p)}},u.prototype.getEditingArea=function(){if(!this.editingArea)throw new Error("Instantiating on missing editing area");var d=s.default.findDOMNode(this.editingArea);if(!d)throw new Error("Cannot find element for editing area");if(d.nodeType===3)throw new Error("Editing area cannot be a text node");return d},u.prototype.renderEditingArea=function(){var d=this,p=this.props,O=p.children,g=p.preserveWhitespace,_=this.state.generation,y={key:_,ref:function(w){d.editingArea=w}};return o.default.Children.count(O)?o.default.cloneElement(o.default.Children.only(O),y):g?o.default.createElement("pre",t({},y)):o.default.createElement("div",t({},y))},u.prototype.render=function(){var d;return o.default.createElement("div",{id:this.props.id,style:this.props.style,key:this.state.generation,className:"quill "+(d=this.props.className,d??""),onKeyPress:this.props.onKeyPress,onKeyDown:this.props.onKeyDown,onKeyUp:this.props.onKeyUp},this.renderEditingArea())},u.prototype.onEditorChangeText=function(d,p,O,g){var _,y;if(this.editor){var w=this.isDelta(this.value)?g.getContents():g.getHTML();w!==this.getEditorContents()&&(this.lastDeltaChangeSet=p,this.value=w,(y=(_=this.props).onChange)===null||y===void 0||y.call(_,d,p,O,g))}},u.prototype.onEditorChangeSelection=function(d,p,O){var g,_,y,w,E,m;if(this.editor){var S=this.getEditorSelection(),C=!S&&d,N=S&&!d;l.default(d,S)||(this.selection=d,(_=(g=this.props).onChangeSelection)===null||_===void 0||_.call(g,d,p,O),C?(w=(y=this.props).onFocus)===null||w===void 0||w.call(y,d,p,O):N&&((m=(E=this.props).onBlur)===null||m===void 0||m.call(E,S,p,O)))}},u.prototype.focus=function(){this.editor&&this.editor.focus()},u.prototype.blur=function(){this.editor&&(this.selection=null,this.editor.blur())},u.displayName="React Quill",u.Quill=c.default,u.defaultProps={theme:"snow",modules:{},readOnly:!1},u})(o.default.Component);function h(a){Promise.resolve().then(a)}return cn=f,cn}var rL=nL();const oL=ts(rL),iL=({isOpen:e,onClose:t,refresh:n,handleUpdate:r})=>{const{node:o,certificate:s}=ot(),{restrictedAssets:l}=s,c=l?l[o.id]:void 0,f={restrictionNotes:c?c.restrictionNotes:"",restrictionInstructions:c?c.restrictionInstructions:""},[h,a]=se.useState(f),[u,d]=se.useState(!1),[p,O]=se.useState(!1);se.useEffect(()=>{a(f)},[c]);const g=()=>{a(f),d(!1),t()},_=async()=>{d(!0),r({restrictedAssets:lq(o.id,l)}).then(w=>{w?.status===200?(Ke.success("Successfully removed restrictions!"),d(!1),O(!1),t(),n()):d(!1)}).catch(w=>{d(!1),Ke.error(`Request failed, ${w.toString()}`)})},y=async()=>{if(h.restrictionInstructions.length<1||h.restrictionNotes.length<1)return;d(!0);const w={[o.id]:h};r({restrictedAssets:{...l,...w}}).then(E=>{E?.status===200?(Ke.success("Asset has been successfully restricted!"),d(!1),t(),a(f),n()):(d(!1),Ke.error("Request failed..."))}).catch(E=>{d(!1),Ke.error(`Request failed, ${E.toString()}`)})};return $.jsxs($.Fragment,{children:[$.jsx(Ye.ConfirmationModal,{id:"restrict-removal-confirmation",isOpen:p,onClose:()=>O(!1),onSubmit:_,submitButtonText:"Confirm",pending:u,headerContent:"Do you confirm the removal of restrictions for this node?"}),$.jsx(Ye.ConfirmationModal,{id:"restrict-single-node-modal",isOpen:e,onClose:t,size:"lg",headerContent:"Change Node Restrictions",noSubmit:!0,noCancel:!0,disabled:u,content:$.jsxs($.Fragment,{children:[$.jsx(Ye.ResourceEditor,{className:"",onChange:w=>a(w),editedResource:h,controls:[sq()]}),$.jsxs("div",{className:"col-12",children:[$.jsx("label",{children:"Instructions for Retrieval - Guest Users"}),$.jsx(oL,{id:"restriction-instructions-editor",theme:"snow",value:h.restrictionInstructions,onChange:w=>{a(E=>({...E,restrictionInstructions:w}))}})]}),$.jsxs("div",{className:"float-right mt-3 d-flex flex-wrap",style:{gap:"0.5rem",padding:"0 15px"},children:[$.jsx(Ye.Button,{onClick:g,children:"Cancel"}),c&&$.jsx(Ye.Button,{color:"danger",onClick:()=>O(!0),pending:u,children:"Remove Restrictions"}),$.jsxs(Ye.Button,{color:"primary",onClick:y,pending:u,children:[c&&"Update Restrictions",!c&&"Restrict"]})]})]})})]})},aL=({certificate:e,handleUpdate:t,refresh:n})=>{const[r,o]=se.useState(!1),s=()=>o(!r),[l,c]=se.useState(!1),f=()=>c(!l),h="reviewNode",a={toggleReviewModal:s,toggleMetadataModal:f},u=sa(e.vertices,e.edges,e.restrictedAssets,h,a);return $.jsxs(ua,{type:h,certificate:e,graph:u,children:[$.jsx(iL,{isOpen:r,onClose:s,refresh:n,handleUpdate:t}),$.jsx(Fh,{isOpen:l,toggle:f})]})},sL=({certificate:e,replica:t,refresh:n})=>{const[r,o]=se.useState(!1),s=()=>o(!r);if(dn(e)||bt(e)||dn(t)||bt(t))return;const l="fileLayerNode",c={refresh:n,toggleMetadataModal:s},f=IO(e.vertices,e.edges,t,c);return $.jsx(ua,{type:l,certificate:e,replica:t,graph:f,children:$.jsx(Fh,{isOpen:r,toggle:s})})},lL=({setIsLayersItemModalOpen:e})=>{const{node:t}=ot();if(!t?.id)return null;const[n,r]=t.id.split("/"),o=()=>{let s=[{key:"view-btn",label:"View Item",onClick:()=>window.open(Yq(t.id),"_blank")},{key:"copy-id-btn",label:"Copy Item ID",onClick:()=>navigator.clipboard.writeText(r)}];return n.includes("Layer")&&(s=[...s,{key:"open-layer-btn",label:"Open Layer",onClick:()=>e(!0)}]),s.map(l=>$.jsx("li",{children:$.jsx(Ye.Button,{color:"secondary",className:"w-100 my-1 btn-sm",sx:{whiteSpace:"nowrap"},onClick:l.onClick,children:l.label},l.key)}))};return $.jsx("div",{className:"position-absolute border border-secondary border-4 top-0 end-0 m-3 p-2",children:$.jsx("ul",{className:"list-unstyled mb-0 text-end",children:o()})})},uL=({isOpen:e,setIsOpen:t})=>{const{node:n,setNode:r,certificate:o,nodesState:s,edgesState:l,nodeLayers:c,setNodeLayers:f}=ot(),[,h]=s,[,a]=l,u=o.subgraphs[n.id],d=(_,y)=>_.reduce((w,E)=>E.id===n.id?[...w,{...E,id:y}]:[...w,E],[]),p=(_,y)=>_.reduce((w,E)=>{if(E.id.includes(n.id)){const m=E.source===n.id;return[...w,{id:`${E.id}-${y}`,source:m?y:E.source,target:m?E.target:y,animated:!0}]}return[...w,E]},[]),O=_=>{t(!1),r({});const y=d(c.current.nodes,_),w=p(c.current.edges,_);h(y),a(w),f({...c,current:{nodes:y,edges:w}})},g=()=>{if(!u)return null;const _=Object.keys(u.vertices);return $.jsxs($.Fragment,{children:[$.jsx("h3",{children:"Select an item in the list from this grouping to continue tracing."}),$.jsx("ul",{children:_.map(y=>$.jsx("li",{children:$.jsx(Ye.Button,{color:"link",className:"btn-sm text-wrap",style:{textAlign:"left"},onClick:()=>O(y),children:o.generatedLabels[y].Name})}))})]})};return $.jsx(Ye.ConfirmationModal,{id:"layer-items-modal",className:"top-25",isOpen:e,onClose:()=>t(!1),cancelButtonText:"Close",noSubmit:!0,headerContent:n.id,content:g()})},cL=({certificate:e,graph:t})=>{const{nodesState:n,edgesState:r,nodeLayers:o,setNodeLayers:s}=ot(),l=se.useMemo(()=>({walkingNode:KO}),[]),[,c,f]=n,[,h,a]=r,[u,d]=se.useState(!1);se.useEffect(()=>{dn(e)||bt(e)||(c(t.nodes),h(t.edges),s({previous:o.previous,current:{nodes:t.nodes,edges:t.edges}}))},[e]);const p=O=>{setTimeout(()=>{O.fitView(),O.zoomTo(.5,{duration:1e3})},100)};return $.jsxs("div",{style:{height:"75vh",position:"relative"},children:[$.jsx("div",{className:"layoutflow",children:$.jsxs(Ph,{nodes:o.current.nodes,edges:o.current.edges,onNodesChange:f,onEdgesChange:a,connectionLineType:vn.SmoothStep,nodeTypes:l,onlyRenderVisibleElements:!0,edgesUpdatable:!1,onInit:p,children:[$.jsx(lO,{}),$.jsx(cO,{}),$.jsx(aO,{})]})}),$.jsx(lL,{setIsLayersItemModalOpen:d}),$.jsx(uL,{setIsOpen:d,isOpen:u})]})},fL=({certificate:e})=>{const t=UO([],e.vertices,e,!1),n=GO([],e.edges),r=VO(t,n);return $.jsx(mO,{type:"walkingNode",certificate:e,children:$.jsx(cL,{certificate:e,graph:r})})},Gh=e=>e?e!=="ffffffff-ffff-ffff-ffff-ffffffffffff":!1,dL=(e,t,n)=>`${t}/${n?"public":"publishing"}/certificate/${e}`,hL=(e,t,n)=>`${t}/${n?"public":"publishing"}/certificate/labels/${e}`,pL=(e,t,n)=>`${t}/${n?"public":"publishing"}/certificate/metadata/${e}`,vL=(e,t,n)=>`${t}/${n?"public":"publishing"}/certificate/schemes/${e}`,gL=async(e,t,n=!0,r)=>{const o=await fetch(dL(e,t,n),{credentials:"include"});r&&r(o);const s=await o.json();if(o.status!==200)throw Error(s.Message);let l={...s};const{labelsId:c,metadataId:f,schemesId:h}=s;if(Gh(c)){const u=await(await fetch(hL(c,t,n),{credentials:"include"})).json();l={...l,customLabels:u.customLabels,generatedLabels:u.generatedLabels,serviceLabels:u.serviceLabels}}if(Gh(f)){const u=await(await fetch(pL(f,t,n),{credentials:"include"})).json();l={...l,metadata:u.metadata}}if(Gh(h)){const u=await(await fetch(vL(h,t,n),{credentials:"include"})).json();l={...l,schemes:u.schemes}}return l},yL=()=>{console.log("import.meta.env.VITE_API_ROUTE","production","undefined/collaboration/neighbors?root=&getDescendants=true")};ht.EditCertificate=Qq,ht.EditNodeModal=DO,ht.IDEModal=$O,ht.MaskMetadataModal=RO,ht.PipelineModal=BO,ht.ReadCertificate=Xq,ht.ReplicaPipelineInfo=FO,ht.ReviewCertificate=aL,ht.WalkingGraph=fL,ht.WorkspaceCertificate=sL,ht.getCertificateBody=gL,ht.getSchemes=SO,ht.startIDE=HO,ht.startPipeline=zO,ht.testComponent=yL,Object.defineProperty(ht,Symbol.toStringTag,{value:"Module"})}));
|
|
161
|
+
`);return ee.insert(ae,W.attributes)}return ee.push(W)},new g.default)}o.default=J}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.Range=void 0;var l=(function(){function j(z,L){var M=[],D=!0,F=!1,B=void 0;try{for(var U=z[Symbol.iterator](),J;!(D=(J=U.next()).done)&&(M.push(J.value),!(L&&M.length===L));D=!0);}catch(oe){F=!0,B=oe}finally{try{!D&&U.return&&U.return()}finally{if(F)throw B}}return M}return function(z,L){if(Array.isArray(z))return z;if(Symbol.iterator in Object(z))return j(z,L);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function j(z,L){for(var M=0;M<L.length;M++){var D=L[M];D.enumerable=D.enumerable||!1,D.configurable=!0,"value"in D&&(D.writable=!0),Object.defineProperty(z,D.key,D)}}return function(z,L,M){return L&&j(z.prototype,L),M&&j(z,M),z}})(),f=i(0),m=w(f),g=i(21),d=w(g),p=i(11),h=w(p),s=i(8),S=w(s),b=i(10),_=w(b);function w(j){return j&&j.__esModule?j:{default:j}}function y(j){if(Array.isArray(j)){for(var z=0,L=Array(j.length);z<j.length;z++)L[z]=j[z];return L}else return Array.from(j)}function E(j,z){if(!(j instanceof z))throw new TypeError("Cannot call a class as a function")}var x=(0,_.default)("quill:selection"),k=function j(z){var L=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;E(this,j),this.index=z,this.length=L},P=(function(){function j(z,L){var M=this;E(this,j),this.emitter=L,this.scroll=z,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=m.default.create("cursor",this),this.lastRange=this.savedRange=new k(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,function(){M.mouseDown||setTimeout(M.update.bind(M,S.default.sources.USER),1)}),this.emitter.on(S.default.events.EDITOR_CHANGE,function(D,F){D===S.default.events.TEXT_CHANGE&&F.length()>0&&M.update(S.default.sources.SILENT)}),this.emitter.on(S.default.events.SCROLL_BEFORE_UPDATE,function(){if(M.hasFocus()){var D=M.getNativeRange();D!=null&&D.start.node!==M.cursor.textNode&&M.emitter.once(S.default.events.SCROLL_UPDATE,function(){try{M.setNativeRange(D.start.node,D.start.offset,D.end.node,D.end.offset)}catch{}})}}),this.emitter.on(S.default.events.SCROLL_OPTIMIZE,function(D,F){if(F.range){var B=F.range,U=B.startNode,J=B.startOffset,oe=B.endNode,de=B.endOffset;M.setNativeRange(U,J,oe,de)}}),this.update(S.default.sources.SILENT)}return c(j,[{key:"handleComposition",value:function(){var L=this;this.root.addEventListener("compositionstart",function(){L.composing=!0}),this.root.addEventListener("compositionend",function(){if(L.composing=!1,L.cursor.parent){var M=L.cursor.restore();if(!M)return;setTimeout(function(){L.setNativeRange(M.startNode,M.startOffset,M.endNode,M.endOffset)},1)}})}},{key:"handleDragging",value:function(){var L=this;this.emitter.listenDOM("mousedown",document.body,function(){L.mouseDown=!0}),this.emitter.listenDOM("mouseup",document.body,function(){L.mouseDown=!1,L.update(S.default.sources.USER)})}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(L,M){if(!(this.scroll.whitelist!=null&&!this.scroll.whitelist[L])){this.scroll.update();var D=this.getNativeRange();if(!(D==null||!D.native.collapsed||m.default.query(L,m.default.Scope.BLOCK))){if(D.start.node!==this.cursor.textNode){var F=m.default.find(D.start.node,!1);if(F==null)return;if(F instanceof m.default.Leaf){var B=F.split(D.start.offset);F.parent.insertBefore(this.cursor,B)}else F.insertBefore(this.cursor,D.start.node);this.cursor.attach()}this.cursor.format(L,M),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(L){var M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,D=this.scroll.length();L=Math.min(L,D-1),M=Math.min(L+M,D-1)-L;var F=void 0,B=this.scroll.leaf(L),U=l(B,2),J=U[0],oe=U[1];if(J==null)return null;var de=J.position(oe,!0),Y=l(de,2);F=Y[0],oe=Y[1];var ee=document.createRange();if(M>0){ee.setStart(F,oe);var W=this.scroll.leaf(L+M),ne=l(W,2);if(J=ne[0],oe=ne[1],J==null)return null;var ae=J.position(oe,!0),te=l(ae,2);return F=te[0],oe=te[1],ee.setEnd(F,oe),ee.getBoundingClientRect()}else{var re="left",Z=void 0;return F instanceof Text?(oe<F.data.length?(ee.setStart(F,oe),ee.setEnd(F,oe+1)):(ee.setStart(F,oe-1),ee.setEnd(F,oe),re="right"),Z=ee.getBoundingClientRect()):(Z=J.domNode.getBoundingClientRect(),oe>0&&(re="right")),{bottom:Z.top+Z.height,height:Z.height,left:Z[re],right:Z[re],top:Z.top,width:0}}}},{key:"getNativeRange",value:function(){var L=document.getSelection();if(L==null||L.rangeCount<=0)return null;var M=L.getRangeAt(0);if(M==null)return null;var D=this.normalizeNative(M);return x.info("getNativeRange",D),D}},{key:"getRange",value:function(){var L=this.getNativeRange();if(L==null)return[null,null];var M=this.normalizedToRange(L);return[M,L]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(L){var M=this,D=[[L.start.node,L.start.offset]];L.native.collapsed||D.push([L.end.node,L.end.offset]);var F=D.map(function(J){var oe=l(J,2),de=oe[0],Y=oe[1],ee=m.default.find(de,!0),W=ee.offset(M.scroll);return Y===0?W:ee instanceof m.default.Container?W+ee.length():W+ee.index(de,Y)}),B=Math.min(Math.max.apply(Math,y(F)),this.scroll.length()-1),U=Math.min.apply(Math,[B].concat(y(F)));return new k(U,B-U)}},{key:"normalizeNative",value:function(L){if(!R(this.root,L.startContainer)||!L.collapsed&&!R(this.root,L.endContainer))return null;var M={start:{node:L.startContainer,offset:L.startOffset},end:{node:L.endContainer,offset:L.endOffset},native:L};return[M.start,M.end].forEach(function(D){for(var F=D.node,B=D.offset;!(F instanceof Text)&&F.childNodes.length>0;)if(F.childNodes.length>B)F=F.childNodes[B],B=0;else if(F.childNodes.length===B)F=F.lastChild,B=F instanceof Text?F.data.length:F.childNodes.length+1;else break;D.node=F,D.offset=B}),M}},{key:"rangeToNative",value:function(L){var M=this,D=L.collapsed?[L.index]:[L.index,L.index+L.length],F=[],B=this.scroll.length();return D.forEach(function(U,J){U=Math.min(B-1,U);var oe=void 0,de=M.scroll.leaf(U),Y=l(de,2),ee=Y[0],W=Y[1],ne=ee.position(W,J!==0),ae=l(ne,2);oe=ae[0],W=ae[1],F.push(oe,W)}),F.length<2&&(F=F.concat(F)),F}},{key:"scrollIntoView",value:function(L){var M=this.lastRange;if(M!=null){var D=this.getBounds(M.index,M.length);if(D!=null){var F=this.scroll.length()-1,B=this.scroll.line(Math.min(M.index,F)),U=l(B,1),J=U[0],oe=J;if(M.length>0){var de=this.scroll.line(Math.min(M.index+M.length,F)),Y=l(de,1);oe=Y[0]}if(!(J==null||oe==null)){var ee=L.getBoundingClientRect();D.top<ee.top?L.scrollTop-=ee.top-D.top:D.bottom>ee.bottom&&(L.scrollTop+=D.bottom-ee.bottom)}}}}},{key:"setNativeRange",value:function(L,M){var D=arguments.length>2&&arguments[2]!==void 0?arguments[2]:L,F=arguments.length>3&&arguments[3]!==void 0?arguments[3]:M,B=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!1;if(x.info("setNativeRange",L,M,D,F),!(L!=null&&(this.root.parentNode==null||L.parentNode==null||D.parentNode==null))){var U=document.getSelection();if(U!=null)if(L!=null){this.hasFocus()||this.root.focus();var J=(this.getNativeRange()||{}).native;if(J==null||B||L!==J.startContainer||M!==J.startOffset||D!==J.endContainer||F!==J.endOffset){L.tagName=="BR"&&(M=[].indexOf.call(L.parentNode.childNodes,L),L=L.parentNode),D.tagName=="BR"&&(F=[].indexOf.call(D.parentNode.childNodes,D),D=D.parentNode);var oe=document.createRange();oe.setStart(L,M),oe.setEnd(D,F),U.removeAllRanges(),U.addRange(oe)}}else U.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(L){var M=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,D=arguments.length>2&&arguments[2]!==void 0?arguments[2]:S.default.sources.API;if(typeof M=="string"&&(D=M,M=!1),x.info("setRange",L),L!=null){var F=this.rangeToNative(L);this.setNativeRange.apply(this,y(F).concat([M]))}else this.setNativeRange(null);this.update(D)}},{key:"update",value:function(){var L=arguments.length>0&&arguments[0]!==void 0?arguments[0]:S.default.sources.USER,M=this.lastRange,D=this.getRange(),F=l(D,2),B=F[0],U=F[1];if(this.lastRange=B,this.lastRange!=null&&(this.savedRange=this.lastRange),!(0,h.default)(M,this.lastRange)){var J;!this.composing&&U!=null&&U.native.collapsed&&U.start.node!==this.cursor.textNode&&this.cursor.restore();var oe=[S.default.events.SELECTION_CHANGE,(0,d.default)(this.lastRange),(0,d.default)(M),L];if((J=this.emitter).emit.apply(J,[S.default.events.EDITOR_CHANGE].concat(oe)),L!==S.default.sources.SILENT){var de;(de=this.emitter).emit.apply(de,oe)}}}}]),j})();function R(j,z){try{z.parentNode}catch{return!1}return z instanceof Text&&(z=z.parentNode),j.contains(z)}o.Range=k,o.default=P}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function S(b,_){for(var w=0;w<_.length;w++){var y=_[w];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(b,y.key,y)}}return function(b,_,w){return _&&S(b.prototype,_),w&&S(b,w),b}})(),c=function S(b,_,w){b===null&&(b=Function.prototype);var y=Object.getOwnPropertyDescriptor(b,_);if(y===void 0){var E=Object.getPrototypeOf(b);return E===null?void 0:S(E,_,w)}else{if("value"in y)return y.value;var x=y.get;return x===void 0?void 0:x.call(w)}},f=i(0),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(){return d(this,b),p(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}return l(b,[{key:"insertInto",value:function(w,y){w.children.length===0?c(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"insertInto",this).call(this,w,y):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),b})(m.default.Embed);s.blotName="break",s.tagName="BR",o.default=s}),(function(r,o,i){var l=this&&this.__extends||(function(){var p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,s){h.__proto__=s}||function(h,s){for(var S in s)s.hasOwnProperty(S)&&(h[S]=s[S])};return function(h,s){p(h,s);function S(){this.constructor=h}h.prototype=s===null?Object.create(s):(S.prototype=s.prototype,new S)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(44),f=i(30),m=i(1),g=(function(p){l(h,p);function h(s){var S=p.call(this,s)||this;return S.build(),S}return h.prototype.appendChild=function(s){this.insertBefore(s)},h.prototype.attach=function(){p.prototype.attach.call(this),this.children.forEach(function(s){s.attach()})},h.prototype.build=function(){var s=this;this.children=new c.default,[].slice.call(this.domNode.childNodes).reverse().forEach(function(S){try{var b=d(S);s.insertBefore(b,s.children.head||void 0)}catch(_){if(_ instanceof m.ParchmentError)return;throw _}})},h.prototype.deleteAt=function(s,S){if(s===0&&S===this.length())return this.remove();this.children.forEachAt(s,S,function(b,_,w){b.deleteAt(_,w)})},h.prototype.descendant=function(s,S){var b=this.children.find(S),_=b[0],w=b[1];return s.blotName==null&&s(_)||s.blotName!=null&&_ instanceof s?[_,w]:_ instanceof h?_.descendant(s,w):[null,-1]},h.prototype.descendants=function(s,S,b){S===void 0&&(S=0),b===void 0&&(b=Number.MAX_VALUE);var _=[],w=b;return this.children.forEachAt(S,b,function(y,E,x){(s.blotName==null&&s(y)||s.blotName!=null&&y instanceof s)&&_.push(y),y instanceof h&&(_=_.concat(y.descendants(s,E,w))),w-=x}),_},h.prototype.detach=function(){this.children.forEach(function(s){s.detach()}),p.prototype.detach.call(this)},h.prototype.formatAt=function(s,S,b,_){this.children.forEachAt(s,S,function(w,y,E){w.formatAt(y,E,b,_)})},h.prototype.insertAt=function(s,S,b){var _=this.children.find(s),w=_[0],y=_[1];if(w)w.insertAt(y,S,b);else{var E=b==null?m.create("text",S):m.create(S,b);this.appendChild(E)}},h.prototype.insertBefore=function(s,S){if(this.statics.allowedChildren!=null&&!this.statics.allowedChildren.some(function(b){return s instanceof b}))throw new m.ParchmentError("Cannot insert "+s.statics.blotName+" into "+this.statics.blotName);s.insertInto(this,S)},h.prototype.length=function(){return this.children.reduce(function(s,S){return s+S.length()},0)},h.prototype.moveChildren=function(s,S){this.children.forEach(function(b){s.insertBefore(b,S)})},h.prototype.optimize=function(s){if(p.prototype.optimize.call(this,s),this.children.length===0)if(this.statics.defaultChild!=null){var S=m.create(this.statics.defaultChild);this.appendChild(S),S.optimize(s)}else this.remove()},h.prototype.path=function(s,S){S===void 0&&(S=!1);var b=this.children.find(s,S),_=b[0],w=b[1],y=[[this,s]];return _ instanceof h?y.concat(_.path(w,S)):(_!=null&&y.push([_,w]),y)},h.prototype.removeChild=function(s){this.children.remove(s)},h.prototype.replace=function(s){s instanceof h&&s.moveChildren(this),p.prototype.replace.call(this,s)},h.prototype.split=function(s,S){if(S===void 0&&(S=!1),!S){if(s===0)return this;if(s===this.length())return this.next}var b=this.clone();return this.parent.insertBefore(b,this.next),this.children.forEachAt(s,this.length(),function(_,w,y){_=_.split(w,S),b.appendChild(_)}),b},h.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},h.prototype.update=function(s,S){var b=this,_=[],w=[];s.forEach(function(y){y.target===b.domNode&&y.type==="childList"&&(_.push.apply(_,y.addedNodes),w.push.apply(w,y.removedNodes))}),w.forEach(function(y){if(!(y.parentNode!=null&&y.tagName!=="IFRAME"&&document.body.compareDocumentPosition(y)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var E=m.find(y);E!=null&&(E.domNode.parentNode==null||E.domNode.parentNode===b.domNode)&&E.detach()}}),_.filter(function(y){return y.parentNode==b.domNode}).sort(function(y,E){return y===E?0:y.compareDocumentPosition(E)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1}).forEach(function(y){var E=null;y.nextSibling!=null&&(E=m.find(y.nextSibling));var x=d(y);(x.next!=E||x.next==null)&&(x.parent!=null&&x.parent.removeChild(b),b.insertBefore(x,E||void 0))})},h})(f.default);function d(p){var h=m.find(p);if(h==null)try{h=m.create(p)}catch{h=m.create(m.Scope.INLINE),[].slice.call(p.childNodes).forEach(function(S){h.domNode.appendChild(S)}),p.parentNode&&p.parentNode.replaceChild(h.domNode,p),h.attach()}return h}o.default=g}),(function(r,o,i){var l=this&&this.__extends||(function(){var p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,s){h.__proto__=s}||function(h,s){for(var S in s)s.hasOwnProperty(S)&&(h[S]=s[S])};return function(h,s){p(h,s);function S(){this.constructor=h}h.prototype=s===null?Object.create(s):(S.prototype=s.prototype,new S)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(12),f=i(31),m=i(17),g=i(1),d=(function(p){l(h,p);function h(s){var S=p.call(this,s)||this;return S.attributes=new f.default(S.domNode),S}return h.formats=function(s){if(typeof this.tagName=="string")return!0;if(Array.isArray(this.tagName))return s.tagName.toLowerCase()},h.prototype.format=function(s,S){var b=g.query(s);b instanceof c.default?this.attributes.attribute(b,S):S&&b!=null&&(s!==this.statics.blotName||this.formats()[s]!==S)&&this.replaceWith(s,S)},h.prototype.formats=function(){var s=this.attributes.values(),S=this.statics.formats(this.domNode);return S!=null&&(s[this.statics.blotName]=S),s},h.prototype.replaceWith=function(s,S){var b=p.prototype.replaceWith.call(this,s,S);return this.attributes.copy(b),b},h.prototype.update=function(s,S){var b=this;p.prototype.update.call(this,s,S),s.some(function(_){return _.target===b.domNode&&_.type==="attributes"})&&this.attributes.build()},h.prototype.wrap=function(s,S){var b=p.prototype.wrap.call(this,s,S);return b instanceof h&&b.statics.scope===this.statics.scope&&this.attributes.move(b),b},h})(m.default);o.default=d}),(function(r,o,i){var l=this&&this.__extends||(function(){var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var h in p)p.hasOwnProperty(h)&&(d[h]=p[h])};return function(d,p){g(d,p);function h(){this.constructor=d}d.prototype=p===null?Object.create(p):(h.prototype=p.prototype,new h)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(30),f=i(1),m=(function(g){l(d,g);function d(){return g!==null&&g.apply(this,arguments)||this}return d.value=function(p){return!0},d.prototype.index=function(p,h){return this.domNode===p||this.domNode.compareDocumentPosition(p)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(h,1):-1},d.prototype.position=function(p,h){var s=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return p>0&&(s+=1),[this.parent.domNode,s]},d.prototype.value=function(){var p;return p={},p[this.statics.blotName]=this.statics.value(this.domNode)||!0,p},d.scope=f.Scope.INLINE_BLOT,d})(c.default);o.default=m}),(function(r,o,i){var l=i(11),c=i(3),f={attributes:{compose:function(g,d,p){typeof g!="object"&&(g={}),typeof d!="object"&&(d={});var h=c(!0,{},d);p||(h=Object.keys(h).reduce(function(S,b){return h[b]!=null&&(S[b]=h[b]),S},{}));for(var s in g)g[s]!==void 0&&d[s]===void 0&&(h[s]=g[s]);return Object.keys(h).length>0?h:void 0},diff:function(g,d){typeof g!="object"&&(g={}),typeof d!="object"&&(d={});var p=Object.keys(g).concat(Object.keys(d)).reduce(function(h,s){return l(g[s],d[s])||(h[s]=d[s]===void 0?null:d[s]),h},{});return Object.keys(p).length>0?p:void 0},transform:function(g,d,p){if(typeof g!="object")return d;if(typeof d=="object"){if(!p)return d;var h=Object.keys(d).reduce(function(s,S){return g[S]===void 0&&(s[S]=d[S]),s},{});return Object.keys(h).length>0?h:void 0}}},iterator:function(g){return new m(g)},length:function(g){return typeof g.delete=="number"?g.delete:typeof g.retain=="number"?g.retain:typeof g.insert=="string"?g.insert.length:1}};function m(g){this.ops=g,this.index=0,this.offset=0}m.prototype.hasNext=function(){return this.peekLength()<1/0},m.prototype.next=function(g){g||(g=1/0);var d=this.ops[this.index];if(d){var p=this.offset,h=f.length(d);if(g>=h-p?(g=h-p,this.index+=1,this.offset=0):this.offset+=g,typeof d.delete=="number")return{delete:g};var s={};return d.attributes&&(s.attributes=d.attributes),typeof d.retain=="number"?s.retain=g:typeof d.insert=="string"?s.insert=d.insert.substr(p,g):s.insert=d.insert,s}else return{retain:1/0}},m.prototype.peek=function(){return this.ops[this.index]},m.prototype.peekLength=function(){return this.ops[this.index]?f.length(this.ops[this.index])-this.offset:1/0},m.prototype.peekType=function(){return this.ops[this.index]?typeof this.ops[this.index].delete=="number"?"delete":typeof this.ops[this.index].retain=="number"?"retain":"insert":"retain"},m.prototype.rest=function(){if(this.hasNext()){if(this.offset===0)return this.ops.slice(this.index);var g=this.offset,d=this.index,p=this.next(),h=this.ops.slice(this.index);return this.offset=g,this.index=d,[p].concat(h)}else return[]},r.exports=f}),(function(r,o){var i=(function(){function l(b,_){return _!=null&&b instanceof _}var c;try{c=Map}catch{c=function(){}}var f;try{f=Set}catch{f=function(){}}var m;try{m=Promise}catch{m=function(){}}function g(b,_,w,y,E){typeof _=="object"&&(w=_.depth,y=_.prototype,E=_.includeNonEnumerable,_=_.circular);var x=[],k=[],P=typeof Buffer<"u";typeof _>"u"&&(_=!0),typeof w>"u"&&(w=1/0);function R(j,z){if(j===null)return null;if(z===0)return j;var L,M;if(typeof j!="object")return j;if(l(j,c))L=new c;else if(l(j,f))L=new f;else if(l(j,m))L=new m(function(ee,W){j.then(function(ne){ee(R(ne,z-1))},function(ne){W(R(ne,z-1))})});else if(g.__isArray(j))L=[];else if(g.__isRegExp(j))L=new RegExp(j.source,S(j)),j.lastIndex&&(L.lastIndex=j.lastIndex);else if(g.__isDate(j))L=new Date(j.getTime());else{if(P&&Buffer.isBuffer(j))return Buffer.allocUnsafe?L=Buffer.allocUnsafe(j.length):L=new Buffer(j.length),j.copy(L),L;l(j,Error)?L=Object.create(j):typeof y>"u"?(M=Object.getPrototypeOf(j),L=Object.create(M)):(L=Object.create(y),M=y)}if(_){var D=x.indexOf(j);if(D!=-1)return k[D];x.push(j),k.push(L)}l(j,c)&&j.forEach(function(ee,W){var ne=R(W,z-1),ae=R(ee,z-1);L.set(ne,ae)}),l(j,f)&&j.forEach(function(ee){var W=R(ee,z-1);L.add(W)});for(var F in j){var B;M&&(B=Object.getOwnPropertyDescriptor(M,F)),!(B&&B.set==null)&&(L[F]=R(j[F],z-1))}if(Object.getOwnPropertySymbols)for(var U=Object.getOwnPropertySymbols(j),F=0;F<U.length;F++){var J=U[F],oe=Object.getOwnPropertyDescriptor(j,J);oe&&!oe.enumerable&&!E||(L[J]=R(j[J],z-1),oe.enumerable||Object.defineProperty(L,J,{enumerable:!1}))}if(E)for(var de=Object.getOwnPropertyNames(j),F=0;F<de.length;F++){var Y=de[F],oe=Object.getOwnPropertyDescriptor(j,Y);oe&&oe.enumerable||(L[Y]=R(j[Y],z-1),Object.defineProperty(L,Y,{enumerable:!1}))}return L}return R(b,w)}g.clonePrototype=function(_){if(_===null)return null;var w=function(){};return w.prototype=_,new w};function d(b){return Object.prototype.toString.call(b)}g.__objToStr=d;function p(b){return typeof b=="object"&&d(b)==="[object Date]"}g.__isDate=p;function h(b){return typeof b=="object"&&d(b)==="[object Array]"}g.__isArray=h;function s(b){return typeof b=="object"&&d(b)==="[object RegExp]"}g.__isRegExp=s;function S(b){var _="";return b.global&&(_+="g"),b.ignoreCase&&(_+="i"),b.multiline&&(_+="m"),_}return g.__getRegExpFlags=S,g})();typeof r=="object"&&r.exports&&(r.exports=i)}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function L(M,D){var F=[],B=!0,U=!1,J=void 0;try{for(var oe=M[Symbol.iterator](),de;!(B=(de=oe.next()).done)&&(F.push(de.value),!(D&&F.length===D));B=!0);}catch(Y){U=!0,J=Y}finally{try{!B&&oe.return&&oe.return()}finally{if(U)throw J}}return F}return function(M,D){if(Array.isArray(M))return M;if(Symbol.iterator in Object(M))return L(M,D);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function L(M,D){for(var F=0;F<D.length;F++){var B=D[F];B.enumerable=B.enumerable||!1,B.configurable=!0,"value"in B&&(B.writable=!0),Object.defineProperty(M,B.key,B)}}return function(M,D,F){return D&&L(M.prototype,D),F&&L(M,F),M}})(),f=function L(M,D,F){M===null&&(M=Function.prototype);var B=Object.getOwnPropertyDescriptor(M,D);if(B===void 0){var U=Object.getPrototypeOf(M);return U===null?void 0:L(U,D,F)}else{if("value"in B)return B.value;var J=B.get;return J===void 0?void 0:J.call(F)}},m=i(0),g=x(m),d=i(8),p=x(d),h=i(4),s=x(h),S=i(16),b=x(S),_=i(13),w=x(_),y=i(25),E=x(y);function x(L){return L&&L.__esModule?L:{default:L}}function k(L,M){if(!(L instanceof M))throw new TypeError("Cannot call a class as a function")}function P(L,M){if(!L)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return M&&(typeof M=="object"||typeof M=="function")?M:L}function R(L,M){if(typeof M!="function"&&M!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof M);L.prototype=Object.create(M&&M.prototype,{constructor:{value:L,enumerable:!1,writable:!0,configurable:!0}}),M&&(Object.setPrototypeOf?Object.setPrototypeOf(L,M):L.__proto__=M)}function j(L){return L instanceof s.default||L instanceof h.BlockEmbed}var z=(function(L){R(M,L);function M(D,F){k(this,M);var B=P(this,(M.__proto__||Object.getPrototypeOf(M)).call(this,D));return B.emitter=F.emitter,Array.isArray(F.whitelist)&&(B.whitelist=F.whitelist.reduce(function(U,J){return U[J]=!0,U},{})),B.domNode.addEventListener("DOMNodeInserted",function(){}),B.optimize(),B.enable(),B}return c(M,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(F,B){var U=this.line(F),J=l(U,2),oe=J[0],de=J[1],Y=this.line(F+B),ee=l(Y,1),W=ee[0];if(f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"deleteAt",this).call(this,F,B),W!=null&&oe!==W&&de>0){if(oe instanceof h.BlockEmbed||W instanceof h.BlockEmbed){this.optimize();return}if(oe instanceof w.default){var ne=oe.newlineIndex(oe.length(),!0);if(ne>-1&&(oe=oe.split(ne+1),oe===W)){this.optimize();return}}else if(W instanceof w.default){var ae=W.newlineIndex(0);ae>-1&&W.split(ae+1)}var te=W.children.head instanceof b.default?null:W.children.head;oe.moveChildren(W,te),oe.remove()}this.optimize()}},{key:"enable",value:function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;this.domNode.setAttribute("contenteditable",F)}},{key:"formatAt",value:function(F,B,U,J){this.whitelist!=null&&!this.whitelist[U]||(f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"formatAt",this).call(this,F,B,U,J),this.optimize())}},{key:"insertAt",value:function(F,B,U){if(!(U!=null&&this.whitelist!=null&&!this.whitelist[B])){if(F>=this.length())if(U==null||g.default.query(B,g.default.Scope.BLOCK)==null){var J=g.default.create(this.statics.defaultChild);this.appendChild(J),U==null&&B.endsWith(`
|
|
162
|
+
`)&&(B=B.slice(0,-1)),J.insertAt(0,B,U)}else{var oe=g.default.create(B,U);this.appendChild(oe)}else f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"insertAt",this).call(this,F,B,U);this.optimize()}}},{key:"insertBefore",value:function(F,B){if(F.statics.scope===g.default.Scope.INLINE_BLOT){var U=g.default.create(this.statics.defaultChild);U.appendChild(F),F=U}f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"insertBefore",this).call(this,F,B)}},{key:"leaf",value:function(F){return this.path(F).pop()||[null,-1]}},{key:"line",value:function(F){return F===this.length()?this.line(F-1):this.descendant(j,F)}},{key:"lines",value:function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,B=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Number.MAX_VALUE,U=function J(oe,de,Y){var ee=[],W=Y;return oe.children.forEachAt(de,Y,function(ne,ae,te){j(ne)?ee.push(ne):ne instanceof g.default.Container&&(ee=ee.concat(J(ne,ae,W))),W-=te}),ee};return U(this,F,B)}},{key:"optimize",value:function(){var F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],B=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};this.batch!==!0&&(f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"optimize",this).call(this,F,B),F.length>0&&this.emitter.emit(p.default.events.SCROLL_OPTIMIZE,F,B))}},{key:"path",value:function(F){return f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"path",this).call(this,F).slice(1)}},{key:"update",value:function(F){if(this.batch!==!0){var B=p.default.sources.USER;typeof F=="string"&&(B=F),Array.isArray(F)||(F=this.observer.takeRecords()),F.length>0&&this.emitter.emit(p.default.events.SCROLL_BEFORE_UPDATE,B,F),f(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"update",this).call(this,F.concat([])),F.length>0&&this.emitter.emit(p.default.events.SCROLL_UPDATE,B,F)}}}]),M})(g.default.Scroll);z.blotName="scroll",z.className="ql-editor",z.tagName="DIV",z.defaultChild="block",z.allowedChildren=[s.default,h.BlockEmbed,E.default],o.default=z}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.SHORTKEY=o.default=void 0;var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(Z){return typeof Z}:function(Z){return Z&&typeof Symbol=="function"&&Z.constructor===Symbol&&Z!==Symbol.prototype?"symbol":typeof Z},c=(function(){function Z(se,pe){var ge=[],be=!0,Ae=!1,Ue=void 0;try{for(var Ve=se[Symbol.iterator](),Fe;!(be=(Fe=Ve.next()).done)&&(ge.push(Fe.value),!(pe&&ge.length===pe));be=!0);}catch(Pe){Ae=!0,Ue=Pe}finally{try{!be&&Ve.return&&Ve.return()}finally{if(Ae)throw Ue}}return ge}return function(se,pe){if(Array.isArray(se))return se;if(Symbol.iterator in Object(se))return Z(se,pe);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),f=(function(){function Z(se,pe){for(var ge=0;ge<pe.length;ge++){var be=pe[ge];be.enumerable=be.enumerable||!1,be.configurable=!0,"value"in be&&(be.writable=!0),Object.defineProperty(se,be.key,be)}}return function(se,pe,ge){return pe&&Z(se.prototype,pe),ge&&Z(se,ge),se}})(),m=i(21),g=L(m),d=i(11),p=L(d),h=i(3),s=L(h),S=i(2),b=L(S),_=i(20),w=L(_),y=i(0),E=L(y),x=i(5),k=L(x),P=i(10),R=L(P),j=i(9),z=L(j);function L(Z){return Z&&Z.__esModule?Z:{default:Z}}function M(Z,se,pe){return se in Z?Object.defineProperty(Z,se,{value:pe,enumerable:!0,configurable:!0,writable:!0}):Z[se]=pe,Z}function D(Z,se){if(!(Z instanceof se))throw new TypeError("Cannot call a class as a function")}function F(Z,se){if(!Z)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return se&&(typeof se=="object"||typeof se=="function")?se:Z}function B(Z,se){if(typeof se!="function"&&se!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof se);Z.prototype=Object.create(se&&se.prototype,{constructor:{value:Z,enumerable:!1,writable:!0,configurable:!0}}),se&&(Object.setPrototypeOf?Object.setPrototypeOf(Z,se):Z.__proto__=se)}var U=(0,R.default)("quill:keyboard"),J=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",oe=(function(Z){B(se,Z),f(se,null,[{key:"match",value:function(ge,be){return be=re(be),["altKey","ctrlKey","metaKey","shiftKey"].some(function(Ae){return!!be[Ae]!==ge[Ae]&&be[Ae]!==null})?!1:be.key===(ge.which||ge.keyCode)}}]);function se(pe,ge){D(this,se);var be=F(this,(se.__proto__||Object.getPrototypeOf(se)).call(this,pe,ge));return be.bindings={},Object.keys(be.options.bindings).forEach(function(Ae){Ae==="list autofill"&&pe.scroll.whitelist!=null&&!pe.scroll.whitelist.list||be.options.bindings[Ae]&&be.addBinding(be.options.bindings[Ae])}),be.addBinding({key:se.keys.ENTER,shiftKey:null},ne),be.addBinding({key:se.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},function(){}),/Firefox/i.test(navigator.userAgent)?(be.addBinding({key:se.keys.BACKSPACE},{collapsed:!0},Y),be.addBinding({key:se.keys.DELETE},{collapsed:!0},ee)):(be.addBinding({key:se.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},Y),be.addBinding({key:se.keys.DELETE},{collapsed:!0,suffix:/^.?$/},ee)),be.addBinding({key:se.keys.BACKSPACE},{collapsed:!1},W),be.addBinding({key:se.keys.DELETE},{collapsed:!1},W),be.addBinding({key:se.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},Y),be.listen(),be}return f(se,[{key:"addBinding",value:function(ge){var be=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},Ae=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},Ue=re(ge);if(Ue==null||Ue.key==null)return U.warn("Attempted to add invalid keyboard binding",Ue);typeof be=="function"&&(be={handler:be}),typeof Ae=="function"&&(Ae={handler:Ae}),Ue=(0,s.default)(Ue,be,Ae),this.bindings[Ue.key]=this.bindings[Ue.key]||[],this.bindings[Ue.key].push(Ue)}},{key:"listen",value:function(){var ge=this;this.quill.root.addEventListener("keydown",function(be){if(!be.defaultPrevented){var Ae=be.which||be.keyCode,Ue=(ge.bindings[Ae]||[]).filter(function(ft){return se.match(be,ft)});if(Ue.length!==0){var Ve=ge.quill.getSelection();if(!(Ve==null||!ge.quill.hasFocus())){var Fe=ge.quill.getLine(Ve.index),Pe=c(Fe,2),ut=Pe[0],Ce=Pe[1],we=ge.quill.getLeaf(Ve.index),xe=c(we,2),Re=xe[0],De=xe[1],Ee=Ve.length===0?[Re,De]:ge.quill.getLeaf(Ve.index+Ve.length),We=c(Ee,2),Qe=We[0],ot=We[1],Mt=Re instanceof E.default.Text?Re.value().slice(0,De):"",jt=Qe instanceof E.default.Text?Qe.value().slice(ot):"",pt={collapsed:Ve.length===0,empty:Ve.length===0&&ut.length()<=1,format:ge.quill.getFormat(Ve),offset:Ce,prefix:Mt,suffix:jt},vn=Ue.some(function(ft){if(ft.collapsed!=null&&ft.collapsed!==pt.collapsed||ft.empty!=null&&ft.empty!==pt.empty||ft.offset!=null&&ft.offset!==pt.offset)return!1;if(Array.isArray(ft.format)){if(ft.format.every(function(Rt){return pt.format[Rt]==null}))return!1}else if(l(ft.format)==="object"&&!Object.keys(ft.format).every(function(Rt){return ft.format[Rt]===!0?pt.format[Rt]!=null:ft.format[Rt]===!1?pt.format[Rt]==null:(0,p.default)(ft.format[Rt],pt.format[Rt])}))return!1;return ft.prefix!=null&&!ft.prefix.test(pt.prefix)||ft.suffix!=null&&!ft.suffix.test(pt.suffix)?!1:ft.handler.call(ge,Ve,pt)!==!0});vn&&be.preventDefault()}}}})}}]),se})(z.default);oe.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},oe.DEFAULTS={bindings:{bold:te("bold"),italic:te("italic"),underline:te("underline"),indent:{key:oe.keys.TAB,format:["blockquote","indent","list"],handler:function(se,pe){if(pe.collapsed&&pe.offset!==0)return!0;this.quill.format("indent","+1",k.default.sources.USER)}},outdent:{key:oe.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(se,pe){if(pe.collapsed&&pe.offset!==0)return!0;this.quill.format("indent","-1",k.default.sources.USER)}},"outdent backspace":{key:oe.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(se,pe){pe.format.indent!=null?this.quill.format("indent","-1",k.default.sources.USER):pe.format.list!=null&&this.quill.format("list",!1,k.default.sources.USER)}},"indent code-block":ae(!0),"outdent code-block":ae(!1),"remove tab":{key:oe.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(se){this.quill.deleteText(se.index-1,1,k.default.sources.USER)}},tab:{key:oe.keys.TAB,handler:function(se){this.quill.history.cutoff();var pe=new b.default().retain(se.index).delete(se.length).insert(" ");this.quill.updateContents(pe,k.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(se.index+1,k.default.sources.SILENT)}},"list empty enter":{key:oe.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(se,pe){this.quill.format("list",!1,k.default.sources.USER),pe.format.indent&&this.quill.format("indent",!1,k.default.sources.USER)}},"checklist enter":{key:oe.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(se){var pe=this.quill.getLine(se.index),ge=c(pe,2),be=ge[0],Ae=ge[1],Ue=(0,s.default)({},be.formats(),{list:"checked"}),Ve=new b.default().retain(se.index).insert(`
|
|
163
|
+
`,Ue).retain(be.length()-Ae-1).retain(1,{list:"unchecked"});this.quill.updateContents(Ve,k.default.sources.USER),this.quill.setSelection(se.index+1,k.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:oe.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(se,pe){var ge=this.quill.getLine(se.index),be=c(ge,2),Ae=be[0],Ue=be[1],Ve=new b.default().retain(se.index).insert(`
|
|
164
|
+
`,pe.format).retain(Ae.length()-Ue-1).retain(1,{header:null});this.quill.updateContents(Ve,k.default.sources.USER),this.quill.setSelection(se.index+1,k.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(se,pe){var ge=pe.prefix.length,be=this.quill.getLine(se.index),Ae=c(be,2),Ue=Ae[0],Ve=Ae[1];if(Ve>ge)return!0;var Fe=void 0;switch(pe.prefix.trim()){case"[]":case"[ ]":Fe="unchecked";break;case"[x]":Fe="checked";break;case"-":case"*":Fe="bullet";break;default:Fe="ordered"}this.quill.insertText(se.index," ",k.default.sources.USER),this.quill.history.cutoff();var Pe=new b.default().retain(se.index-Ve).delete(ge+1).retain(Ue.length()-2-Ve).retain(1,{list:Fe});this.quill.updateContents(Pe,k.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(se.index-ge,k.default.sources.SILENT)}},"code exit":{key:oe.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(se){var pe=this.quill.getLine(se.index),ge=c(pe,2),be=ge[0],Ae=ge[1],Ue=new b.default().retain(se.index+be.length()-Ae-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(Ue,k.default.sources.USER)}},"embed left":de(oe.keys.LEFT,!1),"embed left shift":de(oe.keys.LEFT,!0),"embed right":de(oe.keys.RIGHT,!1),"embed right shift":de(oe.keys.RIGHT,!0)}};function de(Z,se){var pe,ge=Z===oe.keys.LEFT?"prefix":"suffix";return pe={key:Z,shiftKey:se,altKey:null},M(pe,ge,/^$/),M(pe,"handler",function(Ae){var Ue=Ae.index;Z===oe.keys.RIGHT&&(Ue+=Ae.length+1);var Ve=this.quill.getLeaf(Ue),Fe=c(Ve,1),Pe=Fe[0];return Pe instanceof E.default.Embed?(Z===oe.keys.LEFT?se?this.quill.setSelection(Ae.index-1,Ae.length+1,k.default.sources.USER):this.quill.setSelection(Ae.index-1,k.default.sources.USER):se?this.quill.setSelection(Ae.index,Ae.length+1,k.default.sources.USER):this.quill.setSelection(Ae.index+Ae.length+1,k.default.sources.USER),!1):!0}),pe}function Y(Z,se){if(!(Z.index===0||this.quill.getLength()<=1)){var pe=this.quill.getLine(Z.index),ge=c(pe,1),be=ge[0],Ae={};if(se.offset===0){var Ue=this.quill.getLine(Z.index-1),Ve=c(Ue,1),Fe=Ve[0];if(Fe!=null&&Fe.length()>1){var Pe=be.formats(),ut=this.quill.getFormat(Z.index-1,1);Ae=w.default.attributes.diff(Pe,ut)||{}}}var Ce=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(se.prefix)?2:1;this.quill.deleteText(Z.index-Ce,Ce,k.default.sources.USER),Object.keys(Ae).length>0&&this.quill.formatLine(Z.index-Ce,Ce,Ae,k.default.sources.USER),this.quill.focus()}}function ee(Z,se){var pe=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(se.suffix)?2:1;if(!(Z.index>=this.quill.getLength()-pe)){var ge={},be=0,Ae=this.quill.getLine(Z.index),Ue=c(Ae,1),Ve=Ue[0];if(se.offset>=Ve.length()-1){var Fe=this.quill.getLine(Z.index+1),Pe=c(Fe,1),ut=Pe[0];if(ut){var Ce=Ve.formats(),we=this.quill.getFormat(Z.index,1);ge=w.default.attributes.diff(Ce,we)||{},be=ut.length()}}this.quill.deleteText(Z.index,pe,k.default.sources.USER),Object.keys(ge).length>0&&this.quill.formatLine(Z.index+be-1,pe,ge,k.default.sources.USER)}}function W(Z){var se=this.quill.getLines(Z),pe={};if(se.length>1){var ge=se[0].formats(),be=se[se.length-1].formats();pe=w.default.attributes.diff(be,ge)||{}}this.quill.deleteText(Z,k.default.sources.USER),Object.keys(pe).length>0&&this.quill.formatLine(Z.index,1,pe,k.default.sources.USER),this.quill.setSelection(Z.index,k.default.sources.SILENT),this.quill.focus()}function ne(Z,se){var pe=this;Z.length>0&&this.quill.scroll.deleteAt(Z.index,Z.length);var ge=Object.keys(se.format).reduce(function(be,Ae){return E.default.query(Ae,E.default.Scope.BLOCK)&&!Array.isArray(se.format[Ae])&&(be[Ae]=se.format[Ae]),be},{});this.quill.insertText(Z.index,`
|
|
165
|
+
`,ge,k.default.sources.USER),this.quill.setSelection(Z.index+1,k.default.sources.SILENT),this.quill.focus(),Object.keys(se.format).forEach(function(be){ge[be]==null&&(Array.isArray(se.format[be])||be!=="link"&&pe.quill.format(be,se.format[be],k.default.sources.USER))})}function ae(Z){return{key:oe.keys.TAB,shiftKey:!Z,format:{"code-block":!0},handler:function(pe){var ge=E.default.query("code-block"),be=pe.index,Ae=pe.length,Ue=this.quill.scroll.descendant(ge,be),Ve=c(Ue,2),Fe=Ve[0],Pe=Ve[1];if(Fe!=null){var ut=this.quill.getIndex(Fe),Ce=Fe.newlineIndex(Pe,!0)+1,we=Fe.newlineIndex(ut+Pe+Ae),xe=Fe.domNode.textContent.slice(Ce,we).split(`
|
|
166
|
+
`);Pe=0,xe.forEach(function(Re,De){Z?(Fe.insertAt(Ce+Pe,ge.TAB),Pe+=ge.TAB.length,De===0?be+=ge.TAB.length:Ae+=ge.TAB.length):Re.startsWith(ge.TAB)&&(Fe.deleteAt(Ce+Pe,ge.TAB.length),Pe-=ge.TAB.length,De===0?be-=ge.TAB.length:Ae-=ge.TAB.length),Pe+=Re.length+1}),this.quill.update(k.default.sources.USER),this.quill.setSelection(be,Ae,k.default.sources.SILENT)}}}}function te(Z){return{key:Z[0].toUpperCase(),shortKey:!0,handler:function(pe,ge){this.quill.format(Z,!ge.format[Z],k.default.sources.USER)}}}function re(Z){if(typeof Z=="string"||typeof Z=="number")return re({key:Z});if((typeof Z>"u"?"undefined":l(Z))==="object"&&(Z=(0,g.default)(Z,!1)),typeof Z.key=="string")if(oe.keys[Z.key.toUpperCase()]!=null)Z.key=oe.keys[Z.key.toUpperCase()];else if(Z.key.length===1)Z.key=Z.key.toUpperCase().charCodeAt(0);else return null;return Z.shortKey&&(Z[J]=Z.shortKey,delete Z.shortKey),Z}o.default=oe,o.SHORTKEY=J}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function w(y,E){var x=[],k=!0,P=!1,R=void 0;try{for(var j=y[Symbol.iterator](),z;!(k=(z=j.next()).done)&&(x.push(z.value),!(E&&x.length===E));k=!0);}catch(L){P=!0,R=L}finally{try{!k&&j.return&&j.return()}finally{if(P)throw R}}return x}return function(y,E){if(Array.isArray(y))return y;if(Symbol.iterator in Object(y))return w(y,E);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=function w(y,E,x){y===null&&(y=Function.prototype);var k=Object.getOwnPropertyDescriptor(y,E);if(k===void 0){var P=Object.getPrototypeOf(y);return P===null?void 0:w(P,E,x)}else{if("value"in k)return k.value;var R=k.get;return R===void 0?void 0:R.call(x)}},f=(function(){function w(y,E){for(var x=0;x<E.length;x++){var k=E[x];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(y,k.key,k)}}return function(y,E,x){return E&&w(y.prototype,E),x&&w(y,x),y}})(),m=i(0),g=h(m),d=i(7),p=h(d);function h(w){return w&&w.__esModule?w:{default:w}}function s(w,y){if(!(w instanceof y))throw new TypeError("Cannot call a class as a function")}function S(w,y){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:w}function b(w,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);w.prototype=Object.create(y&&y.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(w,y):w.__proto__=y)}var _=(function(w){b(y,w),f(y,null,[{key:"value",value:function(){}}]);function y(E,x){s(this,y);var k=S(this,(y.__proto__||Object.getPrototypeOf(y)).call(this,E));return k.selection=x,k.textNode=document.createTextNode(y.CONTENTS),k.domNode.appendChild(k.textNode),k._length=0,k}return f(y,[{key:"detach",value:function(){this.parent!=null&&this.parent.removeChild(this)}},{key:"format",value:function(x,k){if(this._length!==0)return c(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"format",this).call(this,x,k);for(var P=this,R=0;P!=null&&P.statics.scope!==g.default.Scope.BLOCK_BLOT;)R+=P.offset(P.parent),P=P.parent;P!=null&&(this._length=y.CONTENTS.length,P.optimize(),P.formatAt(R,y.CONTENTS.length,x,k),this._length=0)}},{key:"index",value:function(x,k){return x===this.textNode?0:c(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"index",this).call(this,x,k)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){c(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!(this.selection.composing||this.parent==null)){var x=this.textNode,k=this.selection.getNativeRange(),P=void 0,R=void 0,j=void 0;if(k!=null&&k.start.node===x&&k.end.node===x){var z=[x,k.start.offset,k.end.offset];P=z[0],R=z[1],j=z[2]}for(;this.domNode.lastChild!=null&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==y.CONTENTS){var L=this.textNode.data.split(y.CONTENTS).join("");this.next instanceof p.default?(P=this.next.domNode,this.next.insertAt(0,L),this.textNode.data=y.CONTENTS):(this.textNode.data=L,this.parent.insertBefore(g.default.create(this.textNode),this),this.textNode=document.createTextNode(y.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),R!=null){var M=[R,j].map(function(F){return Math.max(0,Math.min(P.data.length,F-1))}),D=l(M,2);return R=D[0],j=D[1],{startNode:P,startOffset:R,endNode:P,endOffset:j}}}}},{key:"update",value:function(x,k){var P=this;if(x.some(function(j){return j.type==="characterData"&&j.target===P.textNode})){var R=this.restore();R&&(k.range=R)}}},{key:"value",value:function(){return""}}]),y})(g.default.Embed);_.blotName="cursor",_.className="ql-cursor",_.tagName="span",_.CONTENTS="\uFEFF",o.default=_}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(0),c=g(l),f=i(4),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(){return d(this,b),p(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}return b})(c.default.Container);s.allowedChildren=[m.default,f.BlockEmbed,s],o.default=s}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.ColorStyle=o.ColorClass=o.ColorAttributor=void 0;var l=(function(){function _(w,y){for(var E=0;E<y.length;E++){var x=y[E];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(w,x.key,x)}}return function(w,y,E){return y&&_(w.prototype,y),E&&_(w,E),w}})(),c=function _(w,y,E){w===null&&(w=Function.prototype);var x=Object.getOwnPropertyDescriptor(w,y);if(x===void 0){var k=Object.getPrototypeOf(w);return k===null?void 0:_(k,y,E)}else{if("value"in x)return x.value;var P=x.get;return P===void 0?void 0:P.call(E)}},f=i(0),m=g(f);function g(_){return _&&_.__esModule?_:{default:_}}function d(_,w){if(!(_ instanceof w))throw new TypeError("Cannot call a class as a function")}function p(_,w){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:_}function h(_,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);_.prototype=Object.create(w&&w.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(_,w):_.__proto__=w)}var s=(function(_){h(w,_);function w(){return d(this,w),p(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return l(w,[{key:"value",value:function(E){var x=c(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"value",this).call(this,E);return x.startsWith("rgb(")?(x=x.replace(/^[^\d]+/,"").replace(/[^\d]+$/,""),"#"+x.split(",").map(function(k){return("00"+parseInt(k).toString(16)).slice(-2)}).join("")):x}}]),w})(m.default.Attributor.Style),S=new m.default.Attributor.Class("color","ql-color",{scope:m.default.Scope.INLINE}),b=new s("color","color",{scope:m.default.Scope.INLINE});o.ColorAttributor=s,o.ColorClass=S,o.ColorStyle=b}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.sanitize=o.default=void 0;var l=(function(){function b(_,w){for(var y=0;y<w.length;y++){var E=w[y];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(_,E.key,E)}}return function(_,w,y){return w&&b(_.prototype,w),y&&b(_,y),_}})(),c=function b(_,w,y){_===null&&(_=Function.prototype);var E=Object.getOwnPropertyDescriptor(_,w);if(E===void 0){var x=Object.getPrototypeOf(_);return x===null?void 0:b(x,w,y)}else{if("value"in E)return E.value;var k=E.get;return k===void 0?void 0:k.call(y)}},f=i(6),m=g(f);function g(b){return b&&b.__esModule?b:{default:b}}function d(b,_){if(!(b instanceof _))throw new TypeError("Cannot call a class as a function")}function p(b,_){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _&&(typeof _=="object"||typeof _=="function")?_:b}function h(b,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof _);b.prototype=Object.create(_&&_.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),_&&(Object.setPrototypeOf?Object.setPrototypeOf(b,_):b.__proto__=_)}var s=(function(b){h(_,b);function _(){return d(this,_),p(this,(_.__proto__||Object.getPrototypeOf(_)).apply(this,arguments))}return l(_,[{key:"format",value:function(y,E){if(y!==this.statics.blotName||!E)return c(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"format",this).call(this,y,E);E=this.constructor.sanitize(E),this.domNode.setAttribute("href",E)}}],[{key:"create",value:function(y){var E=c(_.__proto__||Object.getPrototypeOf(_),"create",this).call(this,y);return y=this.sanitize(y),E.setAttribute("href",y),E.setAttribute("rel","noopener noreferrer"),E.setAttribute("target","_blank"),E}},{key:"formats",value:function(y){return y.getAttribute("href")}},{key:"sanitize",value:function(y){return S(y,this.PROTOCOL_WHITELIST)?y:this.SANITIZED_URL}}]),_})(m.default);s.blotName="link",s.tagName="A",s.SANITIZED_URL="about:blank",s.PROTOCOL_WHITELIST=["http","https","mailto","tel"];function S(b,_){var w=document.createElement("a");w.href=b;var y=w.href.slice(0,w.href.indexOf(":"));return _.indexOf(y)>-1}o.default=s,o.sanitize=S}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(_){return typeof _}:function(_){return _&&typeof Symbol=="function"&&_.constructor===Symbol&&_!==Symbol.prototype?"symbol":typeof _},c=(function(){function _(w,y){for(var E=0;E<y.length;E++){var x=y[E];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(w,x.key,x)}}return function(w,y,E){return y&&_(w.prototype,y),E&&_(w,E),w}})(),f=i(23),m=p(f),g=i(107),d=p(g);function p(_){return _&&_.__esModule?_:{default:_}}function h(_,w){if(!(_ instanceof w))throw new TypeError("Cannot call a class as a function")}var s=0;function S(_,w){_.setAttribute(w,_.getAttribute(w)!=="true")}var b=(function(){function _(w){var y=this;h(this,_),this.select=w,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",function(){y.togglePicker()}),this.label.addEventListener("keydown",function(E){switch(E.keyCode){case m.default.keys.ENTER:y.togglePicker();break;case m.default.keys.ESCAPE:y.escape(),E.preventDefault();break}}),this.select.addEventListener("change",this.update.bind(this))}return c(_,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),S(this.label,"aria-expanded"),S(this.options,"aria-hidden")}},{key:"buildItem",value:function(y){var E=this,x=document.createElement("span");return x.tabIndex="0",x.setAttribute("role","button"),x.classList.add("ql-picker-item"),y.hasAttribute("value")&&x.setAttribute("data-value",y.getAttribute("value")),y.textContent&&x.setAttribute("data-label",y.textContent),x.addEventListener("click",function(){E.selectItem(x,!0)}),x.addEventListener("keydown",function(k){switch(k.keyCode){case m.default.keys.ENTER:E.selectItem(x,!0),k.preventDefault();break;case m.default.keys.ESCAPE:E.escape(),k.preventDefault();break}}),x}},{key:"buildLabel",value:function(){var y=document.createElement("span");return y.classList.add("ql-picker-label"),y.innerHTML=d.default,y.tabIndex="0",y.setAttribute("role","button"),y.setAttribute("aria-expanded","false"),this.container.appendChild(y),y}},{key:"buildOptions",value:function(){var y=this,E=document.createElement("span");E.classList.add("ql-picker-options"),E.setAttribute("aria-hidden","true"),E.tabIndex="-1",E.id="ql-picker-options-"+s,s+=1,this.label.setAttribute("aria-controls",E.id),this.options=E,[].slice.call(this.select.options).forEach(function(x){var k=y.buildItem(x);E.appendChild(k),x.selected===!0&&y.selectItem(k)}),this.container.appendChild(E)}},{key:"buildPicker",value:function(){var y=this;[].slice.call(this.select.attributes).forEach(function(E){y.container.setAttribute(E.name,E.value)}),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var y=this;this.close(),setTimeout(function(){return y.label.focus()},1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(y){var E=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,x=this.container.querySelector(".ql-selected");if(y!==x&&(x?.classList.remove("ql-selected"),y!=null&&(y.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(y.parentNode.children,y),y.hasAttribute("data-value")?this.label.setAttribute("data-value",y.getAttribute("data-value")):this.label.removeAttribute("data-value"),y.hasAttribute("data-label")?this.label.setAttribute("data-label",y.getAttribute("data-label")):this.label.removeAttribute("data-label"),E))){if(typeof Event=="function")this.select.dispatchEvent(new Event("change"));else if((typeof Event>"u"?"undefined":l(Event))==="object"){var k=document.createEvent("Event");k.initEvent("change",!0,!0),this.select.dispatchEvent(k)}this.close()}}},{key:"update",value:function(){var y=void 0;if(this.select.selectedIndex>-1){var E=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];y=this.select.options[this.select.selectedIndex],this.selectItem(E)}else this.selectItem(null);var x=y!=null&&y!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",x)}}]),_})();o.default=b}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(0),c=U(l),f=i(5),m=U(f),g=i(4),d=U(g),p=i(16),h=U(p),s=i(25),S=U(s),b=i(24),_=U(b),w=i(35),y=U(w),E=i(6),x=U(E),k=i(22),P=U(k),R=i(7),j=U(R),z=i(55),L=U(z),M=i(42),D=U(M),F=i(23),B=U(F);function U(J){return J&&J.__esModule?J:{default:J}}m.default.register({"blots/block":d.default,"blots/block/embed":g.BlockEmbed,"blots/break":h.default,"blots/container":S.default,"blots/cursor":_.default,"blots/embed":y.default,"blots/inline":x.default,"blots/scroll":P.default,"blots/text":j.default,"modules/clipboard":L.default,"modules/history":D.default,"modules/keyboard":B.default}),c.default.register(d.default,h.default,_.default,x.default,P.default,j.default),o.default=m.default}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(1),c=(function(){function f(m){this.domNode=m,this.domNode[l.DATA_KEY]={blot:this}}return Object.defineProperty(f.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),f.create=function(m){if(this.tagName==null)throw new l.ParchmentError("Blot definition missing tagName");var g;return Array.isArray(this.tagName)?(typeof m=="string"&&(m=m.toUpperCase(),parseInt(m).toString()===m&&(m=parseInt(m))),typeof m=="number"?g=document.createElement(this.tagName[m-1]):this.tagName.indexOf(m)>-1?g=document.createElement(m):g=document.createElement(this.tagName[0])):g=document.createElement(this.tagName),this.className&&g.classList.add(this.className),g},f.prototype.attach=function(){this.parent!=null&&(this.scroll=this.parent.scroll)},f.prototype.clone=function(){var m=this.domNode.cloneNode(!1);return l.create(m)},f.prototype.detach=function(){this.parent!=null&&this.parent.removeChild(this),delete this.domNode[l.DATA_KEY]},f.prototype.deleteAt=function(m,g){var d=this.isolate(m,g);d.remove()},f.prototype.formatAt=function(m,g,d,p){var h=this.isolate(m,g);if(l.query(d,l.Scope.BLOT)!=null&&p)h.wrap(d,p);else if(l.query(d,l.Scope.ATTRIBUTE)!=null){var s=l.create(this.statics.scope);h.wrap(s),s.format(d,p)}},f.prototype.insertAt=function(m,g,d){var p=d==null?l.create("text",g):l.create(g,d),h=this.split(m);this.parent.insertBefore(p,h)},f.prototype.insertInto=function(m,g){g===void 0&&(g=null),this.parent!=null&&this.parent.children.remove(this);var d=null;m.children.insertBefore(this,g),g!=null&&(d=g.domNode),(this.domNode.parentNode!=m.domNode||this.domNode.nextSibling!=d)&&m.domNode.insertBefore(this.domNode,d),this.parent=m,this.attach()},f.prototype.isolate=function(m,g){var d=this.split(m);return d.split(g),d},f.prototype.length=function(){return 1},f.prototype.offset=function(m){return m===void 0&&(m=this.parent),this.parent==null||this==m?0:this.parent.children.offset(this)+this.parent.offset(m)},f.prototype.optimize=function(m){this.domNode[l.DATA_KEY]!=null&&delete this.domNode[l.DATA_KEY].mutations},f.prototype.remove=function(){this.domNode.parentNode!=null&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},f.prototype.replace=function(m){m.parent!=null&&(m.parent.insertBefore(this,m.next),m.remove())},f.prototype.replaceWith=function(m,g){var d=typeof m=="string"?l.create(m,g):m;return d.replace(this),d},f.prototype.split=function(m,g){return m===0?this:this.next},f.prototype.update=function(m,g){},f.prototype.wrap=function(m,g){var d=typeof m=="string"?l.create(m,g):m;return this.parent!=null&&this.parent.insertBefore(d,this.next),d.appendChild(this),d},f.blotName="abstract",f})();o.default=c}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(12),c=i(32),f=i(33),m=i(1),g=(function(){function d(p){this.attributes={},this.domNode=p,this.build()}return d.prototype.attribute=function(p,h){h?p.add(this.domNode,h)&&(p.value(this.domNode)!=null?this.attributes[p.attrName]=p:delete this.attributes[p.attrName]):(p.remove(this.domNode),delete this.attributes[p.attrName])},d.prototype.build=function(){var p=this;this.attributes={};var h=l.default.keys(this.domNode),s=c.default.keys(this.domNode),S=f.default.keys(this.domNode);h.concat(s).concat(S).forEach(function(b){var _=m.query(b,m.Scope.ATTRIBUTE);_ instanceof l.default&&(p.attributes[_.attrName]=_)})},d.prototype.copy=function(p){var h=this;Object.keys(this.attributes).forEach(function(s){var S=h.attributes[s].value(h.domNode);p.format(s,S)})},d.prototype.move=function(p){var h=this;this.copy(p),Object.keys(this.attributes).forEach(function(s){h.attributes[s].remove(h.domNode)}),this.attributes={}},d.prototype.values=function(){var p=this;return Object.keys(this.attributes).reduce(function(h,s){return h[s]=p.attributes[s].value(p.domNode),h},{})},d})();o.default=g}),(function(r,o,i){var l=this&&this.__extends||(function(){var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var h in p)p.hasOwnProperty(h)&&(d[h]=p[h])};return function(d,p){g(d,p);function h(){this.constructor=d}d.prototype=p===null?Object.create(p):(h.prototype=p.prototype,new h)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(12);function f(g,d){var p=g.getAttribute("class")||"";return p.split(/\s+/).filter(function(h){return h.indexOf(d+"-")===0})}var m=(function(g){l(d,g);function d(){return g!==null&&g.apply(this,arguments)||this}return d.keys=function(p){return(p.getAttribute("class")||"").split(/\s+/).map(function(h){return h.split("-").slice(0,-1).join("-")})},d.prototype.add=function(p,h){return this.canAdd(p,h)?(this.remove(p),p.classList.add(this.keyName+"-"+h),!0):!1},d.prototype.remove=function(p){var h=f(p,this.keyName);h.forEach(function(s){p.classList.remove(s)}),p.classList.length===0&&p.removeAttribute("class")},d.prototype.value=function(p){var h=f(p,this.keyName)[0]||"",s=h.slice(this.keyName.length+1);return this.canAdd(p,s)?s:""},d})(c.default);o.default=m}),(function(r,o,i){var l=this&&this.__extends||(function(){var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var h in p)p.hasOwnProperty(h)&&(d[h]=p[h])};return function(d,p){g(d,p);function h(){this.constructor=d}d.prototype=p===null?Object.create(p):(h.prototype=p.prototype,new h)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(12);function f(g){var d=g.split("-"),p=d.slice(1).map(function(h){return h[0].toUpperCase()+h.slice(1)}).join("");return d[0]+p}var m=(function(g){l(d,g);function d(){return g!==null&&g.apply(this,arguments)||this}return d.keys=function(p){return(p.getAttribute("style")||"").split(";").map(function(h){var s=h.split(":");return s[0].trim()})},d.prototype.add=function(p,h){return this.canAdd(p,h)?(p.style[f(this.keyName)]=h,!0):!1},d.prototype.remove=function(p){p.style[f(this.keyName)]="",p.getAttribute("style")||p.removeAttribute("style")},d.prototype.value=function(p){var h=p.style[f(this.keyName)];return this.canAdd(p,h)?h:""},d})(c.default);o.default=m}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function m(g,d){for(var p=0;p<d.length;p++){var h=d[p];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(g,h.key,h)}}return function(g,d,p){return d&&m(g.prototype,d),p&&m(g,p),g}})();function c(m,g){if(!(m instanceof g))throw new TypeError("Cannot call a class as a function")}var f=(function(){function m(g,d){c(this,m),this.quill=g,this.options=d,this.modules={}}return l(m,[{key:"init",value:function(){var d=this;Object.keys(this.options.modules).forEach(function(p){d.modules[p]==null&&d.addModule(p)})}},{key:"addModule",value:function(d){var p=this.quill.constructor.import("modules/"+d);return this.modules[d]=new p(this.quill,this.options.modules[d]||{}),this.modules[d]}}]),m})();f.DEFAULTS={modules:{}},f.themes={default:f},o.default=f}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function w(y,E){for(var x=0;x<E.length;x++){var k=E[x];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(y,k.key,k)}}return function(y,E,x){return E&&w(y.prototype,E),x&&w(y,x),y}})(),c=function w(y,E,x){y===null&&(y=Function.prototype);var k=Object.getOwnPropertyDescriptor(y,E);if(k===void 0){var P=Object.getPrototypeOf(y);return P===null?void 0:w(P,E,x)}else{if("value"in k)return k.value;var R=k.get;return R===void 0?void 0:R.call(x)}},f=i(0),m=p(f),g=i(7),d=p(g);function p(w){return w&&w.__esModule?w:{default:w}}function h(w,y){if(!(w instanceof y))throw new TypeError("Cannot call a class as a function")}function s(w,y){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:w}function S(w,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);w.prototype=Object.create(y&&y.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(w,y):w.__proto__=y)}var b="\uFEFF",_=(function(w){S(y,w);function y(E){h(this,y);var x=s(this,(y.__proto__||Object.getPrototypeOf(y)).call(this,E));return x.contentNode=document.createElement("span"),x.contentNode.setAttribute("contenteditable",!1),[].slice.call(x.domNode.childNodes).forEach(function(k){x.contentNode.appendChild(k)}),x.leftGuard=document.createTextNode(b),x.rightGuard=document.createTextNode(b),x.domNode.appendChild(x.leftGuard),x.domNode.appendChild(x.contentNode),x.domNode.appendChild(x.rightGuard),x}return l(y,[{key:"index",value:function(x,k){return x===this.leftGuard?0:x===this.rightGuard?1:c(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"index",this).call(this,x,k)}},{key:"restore",value:function(x){var k=void 0,P=void 0,R=x.data.split(b).join("");if(x===this.leftGuard)if(this.prev instanceof d.default){var j=this.prev.length();this.prev.insertAt(j,R),k={startNode:this.prev.domNode,startOffset:j+R.length}}else P=document.createTextNode(R),this.parent.insertBefore(m.default.create(P),this),k={startNode:P,startOffset:R.length};else x===this.rightGuard&&(this.next instanceof d.default?(this.next.insertAt(0,R),k={startNode:this.next.domNode,startOffset:R.length}):(P=document.createTextNode(R),this.parent.insertBefore(m.default.create(P),this.next),k={startNode:P,startOffset:R.length}));return x.data=b,k}},{key:"update",value:function(x,k){var P=this;x.forEach(function(R){if(R.type==="characterData"&&(R.target===P.leftGuard||R.target===P.rightGuard)){var j=P.restore(R.target);j&&(k.range=j)}})}}]),y})(m.default.Embed);o.default=_}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.AlignStyle=o.AlignClass=o.AlignAttribute=void 0;var l=i(0),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}var m={scope:c.default.Scope.BLOCK,whitelist:["right","center","justify"]},g=new c.default.Attributor.Attribute("align","align",m),d=new c.default.Attributor.Class("align","ql-align",m),p=new c.default.Attributor.Style("align","text-align",m);o.AlignAttribute=g,o.AlignClass=d,o.AlignStyle=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.BackgroundStyle=o.BackgroundClass=void 0;var l=i(0),c=m(l),f=i(26);function m(p){return p&&p.__esModule?p:{default:p}}var g=new c.default.Attributor.Class("background","ql-bg",{scope:c.default.Scope.INLINE}),d=new f.ColorAttributor("background","background-color",{scope:c.default.Scope.INLINE});o.BackgroundClass=g,o.BackgroundStyle=d}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.DirectionStyle=o.DirectionClass=o.DirectionAttribute=void 0;var l=i(0),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}var m={scope:c.default.Scope.BLOCK,whitelist:["rtl"]},g=new c.default.Attributor.Attribute("direction","dir",m),d=new c.default.Attributor.Class("direction","ql-direction",m),p=new c.default.Attributor.Style("direction","direction",m);o.DirectionAttribute=g,o.DirectionClass=d,o.DirectionStyle=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.FontClass=o.FontStyle=void 0;var l=(function(){function w(y,E){for(var x=0;x<E.length;x++){var k=E[x];k.enumerable=k.enumerable||!1,k.configurable=!0,"value"in k&&(k.writable=!0),Object.defineProperty(y,k.key,k)}}return function(y,E,x){return E&&w(y.prototype,E),x&&w(y,x),y}})(),c=function w(y,E,x){y===null&&(y=Function.prototype);var k=Object.getOwnPropertyDescriptor(y,E);if(k===void 0){var P=Object.getPrototypeOf(y);return P===null?void 0:w(P,E,x)}else{if("value"in k)return k.value;var R=k.get;return R===void 0?void 0:R.call(x)}},f=i(0),m=g(f);function g(w){return w&&w.__esModule?w:{default:w}}function d(w,y){if(!(w instanceof y))throw new TypeError("Cannot call a class as a function")}function p(w,y){if(!w)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return y&&(typeof y=="object"||typeof y=="function")?y:w}function h(w,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof y);w.prototype=Object.create(y&&y.prototype,{constructor:{value:w,enumerable:!1,writable:!0,configurable:!0}}),y&&(Object.setPrototypeOf?Object.setPrototypeOf(w,y):w.__proto__=y)}var s={scope:m.default.Scope.INLINE,whitelist:["serif","monospace"]},S=new m.default.Attributor.Class("font","ql-font",s),b=(function(w){h(y,w);function y(){return d(this,y),p(this,(y.__proto__||Object.getPrototypeOf(y)).apply(this,arguments))}return l(y,[{key:"value",value:function(x){return c(y.prototype.__proto__||Object.getPrototypeOf(y.prototype),"value",this).call(this,x).replace(/["']/g,"")}}]),y})(m.default.Attributor.Style),_=new b("font","font-family",s);o.FontStyle=_,o.FontClass=S}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.SizeStyle=o.SizeClass=void 0;var l=i(0),c=f(l);function f(d){return d&&d.__esModule?d:{default:d}}var m=new c.default.Attributor.Class("size","ql-size",{scope:c.default.Scope.INLINE,whitelist:["small","large","huge"]}),g=new c.default.Attributor.Style("size","font-size",{scope:c.default.Scope.INLINE,whitelist:["10px","18px","32px"]});o.SizeClass=m,o.SizeStyle=g}),(function(r,o,i){r.exports={align:{"":i(76),center:i(77),right:i(78),justify:i(79)},background:i(80),blockquote:i(81),bold:i(82),clean:i(83),code:i(58),"code-block":i(58),color:i(84),direction:{"":i(85),rtl:i(86)},float:{center:i(87),full:i(88),left:i(89),right:i(90)},formula:i(91),header:{1:i(92),2:i(93)},italic:i(94),image:i(95),indent:{"+1":i(96),"-1":i(97)},link:i(98),list:{ordered:i(99),bullet:i(100),check:i(101)},script:{sub:i(102),super:i(103)},strike:i(104),underline:i(105),video:i(106)}}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.getLastChangeIndex=o.default=void 0;var l=(function(){function E(x,k){for(var P=0;P<k.length;P++){var R=k[P];R.enumerable=R.enumerable||!1,R.configurable=!0,"value"in R&&(R.writable=!0),Object.defineProperty(x,R.key,R)}}return function(x,k,P){return k&&E(x.prototype,k),P&&E(x,P),x}})(),c=i(0),f=h(c),m=i(5),g=h(m),d=i(9),p=h(d);function h(E){return E&&E.__esModule?E:{default:E}}function s(E,x){if(!(E instanceof x))throw new TypeError("Cannot call a class as a function")}function S(E,x){if(!E)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x&&(typeof x=="object"||typeof x=="function")?x:E}function b(E,x){if(typeof x!="function"&&x!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof x);E.prototype=Object.create(x&&x.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}),x&&(Object.setPrototypeOf?Object.setPrototypeOf(E,x):E.__proto__=x)}var _=(function(E){b(x,E);function x(k,P){s(this,x);var R=S(this,(x.__proto__||Object.getPrototypeOf(x)).call(this,k,P));return R.lastRecorded=0,R.ignoreChange=!1,R.clear(),R.quill.on(g.default.events.EDITOR_CHANGE,function(j,z,L,M){j!==g.default.events.TEXT_CHANGE||R.ignoreChange||(!R.options.userOnly||M===g.default.sources.USER?R.record(z,L):R.transform(z))}),R.quill.keyboard.addBinding({key:"Z",shortKey:!0},R.undo.bind(R)),R.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},R.redo.bind(R)),/Win/i.test(navigator.platform)&&R.quill.keyboard.addBinding({key:"Y",shortKey:!0},R.redo.bind(R)),R}return l(x,[{key:"change",value:function(P,R){if(this.stack[P].length!==0){var j=this.stack[P].pop();this.stack[R].push(j),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(j[P],g.default.sources.USER),this.ignoreChange=!1;var z=y(j[P]);this.quill.setSelection(z)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(P,R){if(P.ops.length!==0){this.stack.redo=[];var j=this.quill.getContents().diff(R),z=Date.now();if(this.lastRecorded+this.options.delay>z&&this.stack.undo.length>0){var L=this.stack.undo.pop();j=j.compose(L.undo),P=L.redo.compose(P)}else this.lastRecorded=z;this.stack.undo.push({redo:P,undo:j}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(P){this.stack.undo.forEach(function(R){R.undo=P.transform(R.undo,!0),R.redo=P.transform(R.redo,!0)}),this.stack.redo.forEach(function(R){R.undo=P.transform(R.undo,!0),R.redo=P.transform(R.redo,!0)})}},{key:"undo",value:function(){this.change("undo","redo")}}]),x})(p.default);_.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1};function w(E){var x=E.ops[E.ops.length-1];return x==null?!1:x.insert!=null?typeof x.insert=="string"&&x.insert.endsWith(`
|
|
167
|
+
`):x.attributes!=null?Object.keys(x.attributes).some(function(k){return f.default.query(k,f.default.Scope.BLOCK)!=null}):!1}function y(E){var x=E.reduce(function(P,R){return P+=R.delete||0,P},0),k=E.length()-x;return w(E)&&(k-=1),k}o.default=_,o.getLastChangeIndex=y}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.BaseTooltip=void 0;var l=(function(){function ne(ae,te){for(var re=0;re<te.length;re++){var Z=te[re];Z.enumerable=Z.enumerable||!1,Z.configurable=!0,"value"in Z&&(Z.writable=!0),Object.defineProperty(ae,Z.key,Z)}}return function(ae,te,re){return te&&ne(ae.prototype,te),re&&ne(ae,re),ae}})(),c=function ne(ae,te,re){ae===null&&(ae=Function.prototype);var Z=Object.getOwnPropertyDescriptor(ae,te);if(Z===void 0){var se=Object.getPrototypeOf(ae);return se===null?void 0:ne(se,te,re)}else{if("value"in Z)return Z.value;var pe=Z.get;return pe===void 0?void 0:pe.call(re)}},f=i(3),m=z(f),g=i(2),d=z(g),p=i(8),h=z(p),s=i(23),S=z(s),b=i(34),_=z(b),w=i(59),y=z(w),E=i(60),x=z(E),k=i(28),P=z(k),R=i(61),j=z(R);function z(ne){return ne&&ne.__esModule?ne:{default:ne}}function L(ne,ae){if(!(ne instanceof ae))throw new TypeError("Cannot call a class as a function")}function M(ne,ae){if(!ne)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return ae&&(typeof ae=="object"||typeof ae=="function")?ae:ne}function D(ne,ae){if(typeof ae!="function"&&ae!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof ae);ne.prototype=Object.create(ae&&ae.prototype,{constructor:{value:ne,enumerable:!1,writable:!0,configurable:!0}}),ae&&(Object.setPrototypeOf?Object.setPrototypeOf(ne,ae):ne.__proto__=ae)}var F=[!1,"center","right","justify"],B=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],U=[!1,"serif","monospace"],J=["1","2","3",!1],oe=["small",!1,"large","huge"],de=(function(ne){D(ae,ne);function ae(te,re){L(this,ae);var Z=M(this,(ae.__proto__||Object.getPrototypeOf(ae)).call(this,te,re)),se=function pe(ge){if(!document.body.contains(te.root))return document.body.removeEventListener("click",pe);Z.tooltip!=null&&!Z.tooltip.root.contains(ge.target)&&document.activeElement!==Z.tooltip.textbox&&!Z.quill.hasFocus()&&Z.tooltip.hide(),Z.pickers!=null&&Z.pickers.forEach(function(be){be.container.contains(ge.target)||be.close()})};return te.emitter.listenDOM("click",document.body,se),Z}return l(ae,[{key:"addModule",value:function(re){var Z=c(ae.prototype.__proto__||Object.getPrototypeOf(ae.prototype),"addModule",this).call(this,re);return re==="toolbar"&&this.extendToolbar(Z),Z}},{key:"buildButtons",value:function(re,Z){re.forEach(function(se){var pe=se.getAttribute("class")||"";pe.split(/\s+/).forEach(function(ge){if(ge.startsWith("ql-")&&(ge=ge.slice(3),Z[ge]!=null))if(ge==="direction")se.innerHTML=Z[ge][""]+Z[ge].rtl;else if(typeof Z[ge]=="string")se.innerHTML=Z[ge];else{var be=se.value||"";be!=null&&Z[ge][be]&&(se.innerHTML=Z[ge][be])}})})}},{key:"buildPickers",value:function(re,Z){var se=this;this.pickers=re.map(function(ge){if(ge.classList.contains("ql-align"))return ge.querySelector("option")==null&&W(ge,F),new x.default(ge,Z.align);if(ge.classList.contains("ql-background")||ge.classList.contains("ql-color")){var be=ge.classList.contains("ql-background")?"background":"color";return ge.querySelector("option")==null&&W(ge,B,be==="background"?"#ffffff":"#000000"),new y.default(ge,Z[be])}else return ge.querySelector("option")==null&&(ge.classList.contains("ql-font")?W(ge,U):ge.classList.contains("ql-header")?W(ge,J):ge.classList.contains("ql-size")&&W(ge,oe)),new P.default(ge)});var pe=function(){se.pickers.forEach(function(be){be.update()})};this.quill.on(h.default.events.EDITOR_CHANGE,pe)}}]),ae})(_.default);de.DEFAULTS=(0,m.default)(!0,{},_.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var ae=this,te=this.container.querySelector("input.ql-image[type=file]");te==null&&(te=document.createElement("input"),te.setAttribute("type","file"),te.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),te.classList.add("ql-image"),te.addEventListener("change",function(){if(te.files!=null&&te.files[0]!=null){var re=new FileReader;re.onload=function(Z){var se=ae.quill.getSelection(!0);ae.quill.updateContents(new d.default().retain(se.index).delete(se.length).insert({image:Z.target.result}),h.default.sources.USER),ae.quill.setSelection(se.index+1,h.default.sources.SILENT),te.value=""},re.readAsDataURL(te.files[0])}}),this.container.appendChild(te)),te.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var Y=(function(ne){D(ae,ne);function ae(te,re){L(this,ae);var Z=M(this,(ae.__proto__||Object.getPrototypeOf(ae)).call(this,te,re));return Z.textbox=Z.root.querySelector('input[type="text"]'),Z.listen(),Z}return l(ae,[{key:"listen",value:function(){var re=this;this.textbox.addEventListener("keydown",function(Z){S.default.match(Z,"enter")?(re.save(),Z.preventDefault()):S.default.match(Z,"escape")&&(re.cancel(),Z.preventDefault())})}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var re=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"link",Z=arguments.length>1&&arguments[1]!==void 0?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),Z!=null?this.textbox.value=Z:re!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+re)||""),this.root.setAttribute("data-mode",re)}},{key:"restoreFocus",value:function(){var re=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=re}},{key:"save",value:function(){var re=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":{var Z=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",re,h.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",re,h.default.sources.USER)),this.quill.root.scrollTop=Z;break}case"video":re=ee(re);case"formula":{if(!re)break;var se=this.quill.getSelection(!0);if(se!=null){var pe=se.index+se.length;this.quill.insertEmbed(pe,this.root.getAttribute("data-mode"),re,h.default.sources.USER),this.root.getAttribute("data-mode")==="formula"&&this.quill.insertText(pe+1," ",h.default.sources.USER),this.quill.setSelection(pe+2,h.default.sources.USER)}break}}this.textbox.value="",this.hide()}}]),ae})(j.default);function ee(ne){var ae=ne.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||ne.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/);return ae?(ae[1]||"https")+"://www.youtube.com/embed/"+ae[2]+"?showinfo=0":(ae=ne.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(ae[1]||"https")+"://player.vimeo.com/video/"+ae[2]+"/":ne}function W(ne,ae){var te=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;ae.forEach(function(re){var Z=document.createElement("option");re===te?Z.setAttribute("selected","selected"):Z.setAttribute("value",re),ne.appendChild(Z)})}o.BaseTooltip=Y,o.default=de}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function c(){this.head=this.tail=null,this.length=0}return c.prototype.append=function(){for(var f=[],m=0;m<arguments.length;m++)f[m]=arguments[m];this.insertBefore(f[0],null),f.length>1&&this.append.apply(this,f.slice(1))},c.prototype.contains=function(f){for(var m,g=this.iterator();m=g();)if(m===f)return!0;return!1},c.prototype.insertBefore=function(f,m){f&&(f.next=m,m!=null?(f.prev=m.prev,m.prev!=null&&(m.prev.next=f),m.prev=f,m===this.head&&(this.head=f)):this.tail!=null?(this.tail.next=f,f.prev=this.tail,this.tail=f):(f.prev=null,this.head=this.tail=f),this.length+=1)},c.prototype.offset=function(f){for(var m=0,g=this.head;g!=null;){if(g===f)return m;m+=g.length(),g=g.next}return-1},c.prototype.remove=function(f){this.contains(f)&&(f.prev!=null&&(f.prev.next=f.next),f.next!=null&&(f.next.prev=f.prev),f===this.head&&(this.head=f.next),f===this.tail&&(this.tail=f.prev),this.length-=1)},c.prototype.iterator=function(f){return f===void 0&&(f=this.head),function(){var m=f;return f!=null&&(f=f.next),m}},c.prototype.find=function(f,m){m===void 0&&(m=!1);for(var g,d=this.iterator();g=d();){var p=g.length();if(f<p||m&&f===p&&(g.next==null||g.next.length()!==0))return[g,f];f-=p}return[null,0]},c.prototype.forEach=function(f){for(var m,g=this.iterator();m=g();)f(m)},c.prototype.forEachAt=function(f,m,g){if(!(m<=0))for(var d=this.find(f),p=d[0],h=d[1],s,S=f-h,b=this.iterator(p);(s=b())&&S<f+m;){var _=s.length();f>S?g(s,f-S,Math.min(m,S+_-f)):g(s,0,Math.min(_,f+m-S)),S+=_}},c.prototype.map=function(f){return this.reduce(function(m,g){return m.push(f(g)),m},[])},c.prototype.reduce=function(f,m){for(var g,d=this.iterator();g=d();)m=f(m,g);return m},c})();o.default=l}),(function(r,o,i){var l=this&&this.__extends||(function(){var p=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(h,s){h.__proto__=s}||function(h,s){for(var S in s)s.hasOwnProperty(S)&&(h[S]=s[S])};return function(h,s){p(h,s);function S(){this.constructor=h}h.prototype=s===null?Object.create(s):(S.prototype=s.prototype,new S)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(17),f=i(1),m={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},g=100,d=(function(p){l(h,p);function h(s){var S=p.call(this,s)||this;return S.scroll=S,S.observer=new MutationObserver(function(b){S.update(b)}),S.observer.observe(S.domNode,m),S.attach(),S}return h.prototype.detach=function(){p.prototype.detach.call(this),this.observer.disconnect()},h.prototype.deleteAt=function(s,S){this.update(),s===0&&S===this.length()?this.children.forEach(function(b){b.remove()}):p.prototype.deleteAt.call(this,s,S)},h.prototype.formatAt=function(s,S,b,_){this.update(),p.prototype.formatAt.call(this,s,S,b,_)},h.prototype.insertAt=function(s,S,b){this.update(),p.prototype.insertAt.call(this,s,S,b)},h.prototype.optimize=function(s,S){var b=this;s===void 0&&(s=[]),S===void 0&&(S={}),p.prototype.optimize.call(this,S);for(var _=[].slice.call(this.observer.takeRecords());_.length>0;)s.push(_.pop());for(var w=function(k,P){P===void 0&&(P=!0),!(k==null||k===b)&&k.domNode.parentNode!=null&&(k.domNode[f.DATA_KEY].mutations==null&&(k.domNode[f.DATA_KEY].mutations=[]),P&&w(k.parent))},y=function(k){k.domNode[f.DATA_KEY]==null||k.domNode[f.DATA_KEY].mutations==null||(k instanceof c.default&&k.children.forEach(y),k.optimize(S))},E=s,x=0;E.length>0;x+=1){if(x>=g)throw new Error("[Parchment] Maximum optimize iterations reached");for(E.forEach(function(k){var P=f.find(k.target,!0);P!=null&&(P.domNode===k.target&&(k.type==="childList"?(w(f.find(k.previousSibling,!1)),[].forEach.call(k.addedNodes,function(R){var j=f.find(R,!1);w(j,!1),j instanceof c.default&&j.children.forEach(function(z){w(z,!1)})})):k.type==="attributes"&&w(P.prev)),w(P))}),this.children.forEach(y),E=[].slice.call(this.observer.takeRecords()),_=E.slice();_.length>0;)s.push(_.pop())}},h.prototype.update=function(s,S){var b=this;S===void 0&&(S={}),s=s||this.observer.takeRecords(),s.map(function(_){var w=f.find(_.target,!0);return w==null?null:w.domNode[f.DATA_KEY].mutations==null?(w.domNode[f.DATA_KEY].mutations=[_],w):(w.domNode[f.DATA_KEY].mutations.push(_),null)}).forEach(function(_){_==null||_===b||_.domNode[f.DATA_KEY]==null||_.update(_.domNode[f.DATA_KEY].mutations||[],S)}),this.domNode[f.DATA_KEY].mutations!=null&&p.prototype.update.call(this,this.domNode[f.DATA_KEY].mutations,S),this.optimize(s,S)},h.blotName="scroll",h.defaultChild="block",h.scope=f.Scope.BLOCK_BLOT,h.tagName="DIV",h})(c.default);o.default=d}),(function(r,o,i){var l=this&&this.__extends||(function(){var d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(p,h){p.__proto__=h}||function(p,h){for(var s in h)h.hasOwnProperty(s)&&(p[s]=h[s])};return function(p,h){d(p,h);function s(){this.constructor=p}p.prototype=h===null?Object.create(h):(s.prototype=h.prototype,new s)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(18),f=i(1);function m(d,p){if(Object.keys(d).length!==Object.keys(p).length)return!1;for(var h in d)if(d[h]!==p[h])return!1;return!0}var g=(function(d){l(p,d);function p(){return d!==null&&d.apply(this,arguments)||this}return p.formats=function(h){if(h.tagName!==p.tagName)return d.formats.call(this,h)},p.prototype.format=function(h,s){var S=this;h===this.statics.blotName&&!s?(this.children.forEach(function(b){b instanceof c.default||(b=b.wrap(p.blotName,!0)),S.attributes.copy(b)}),this.unwrap()):d.prototype.format.call(this,h,s)},p.prototype.formatAt=function(h,s,S,b){if(this.formats()[S]!=null||f.query(S,f.Scope.ATTRIBUTE)){var _=this.isolate(h,s);_.format(S,b)}else d.prototype.formatAt.call(this,h,s,S,b)},p.prototype.optimize=function(h){d.prototype.optimize.call(this,h);var s=this.formats();if(Object.keys(s).length===0)return this.unwrap();var S=this.next;S instanceof p&&S.prev===this&&m(s,S.formats())&&(S.moveChildren(this),S.remove())},p.blotName="inline",p.scope=f.Scope.INLINE_BLOT,p.tagName="SPAN",p})(c.default);o.default=g}),(function(r,o,i){var l=this&&this.__extends||(function(){var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var h in p)p.hasOwnProperty(h)&&(d[h]=p[h])};return function(d,p){g(d,p);function h(){this.constructor=d}d.prototype=p===null?Object.create(p):(h.prototype=p.prototype,new h)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(18),f=i(1),m=(function(g){l(d,g);function d(){return g!==null&&g.apply(this,arguments)||this}return d.formats=function(p){var h=f.query(d.blotName).tagName;if(p.tagName!==h)return g.formats.call(this,p)},d.prototype.format=function(p,h){f.query(p,f.Scope.BLOCK)!=null&&(p===this.statics.blotName&&!h?this.replaceWith(d.blotName):g.prototype.format.call(this,p,h))},d.prototype.formatAt=function(p,h,s,S){f.query(s,f.Scope.BLOCK)!=null?this.format(s,S):g.prototype.formatAt.call(this,p,h,s,S)},d.prototype.insertAt=function(p,h,s){if(s==null||f.query(h,f.Scope.INLINE)!=null)g.prototype.insertAt.call(this,p,h,s);else{var S=this.split(p),b=f.create(h,s);S.parent.insertBefore(b,S)}},d.prototype.update=function(p,h){navigator.userAgent.match(/Trident/)?this.build():g.prototype.update.call(this,p,h)},d.blotName="block",d.scope=f.Scope.BLOCK_BLOT,d.tagName="P",d})(c.default);o.default=m}),(function(r,o,i){var l=this&&this.__extends||(function(){var m=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(g,d){g.__proto__=d}||function(g,d){for(var p in d)d.hasOwnProperty(p)&&(g[p]=d[p])};return function(g,d){m(g,d);function p(){this.constructor=g}g.prototype=d===null?Object.create(d):(p.prototype=d.prototype,new p)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(19),f=(function(m){l(g,m);function g(){return m!==null&&m.apply(this,arguments)||this}return g.formats=function(d){},g.prototype.format=function(d,p){m.prototype.formatAt.call(this,0,this.length(),d,p)},g.prototype.formatAt=function(d,p,h,s){d===0&&p===this.length()?this.format(h,s):m.prototype.formatAt.call(this,d,p,h,s)},g.prototype.formats=function(){return this.statics.formats(this.domNode)},g})(c.default);o.default=f}),(function(r,o,i){var l=this&&this.__extends||(function(){var g=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(d,p){d.__proto__=p}||function(d,p){for(var h in p)p.hasOwnProperty(h)&&(d[h]=p[h])};return function(d,p){g(d,p);function h(){this.constructor=d}d.prototype=p===null?Object.create(p):(h.prototype=p.prototype,new h)}})();Object.defineProperty(o,"__esModule",{value:!0});var c=i(19),f=i(1),m=(function(g){l(d,g);function d(p){var h=g.call(this,p)||this;return h.text=h.statics.value(h.domNode),h}return d.create=function(p){return document.createTextNode(p)},d.value=function(p){var h=p.data;return h.normalize&&(h=h.normalize()),h},d.prototype.deleteAt=function(p,h){this.domNode.data=this.text=this.text.slice(0,p)+this.text.slice(p+h)},d.prototype.index=function(p,h){return this.domNode===p?h:-1},d.prototype.insertAt=function(p,h,s){s==null?(this.text=this.text.slice(0,p)+h+this.text.slice(p),this.domNode.data=this.text):g.prototype.insertAt.call(this,p,h,s)},d.prototype.length=function(){return this.text.length},d.prototype.optimize=function(p){g.prototype.optimize.call(this,p),this.text=this.statics.value(this.domNode),this.text.length===0?this.remove():this.next instanceof d&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},d.prototype.position=function(p,h){return[this.domNode,p]},d.prototype.split=function(p,h){if(h===void 0&&(h=!1),!h){if(p===0)return this;if(p===this.length())return this.next}var s=f.create(this.domNode.splitText(p));return this.parent.insertBefore(s,this.next),this.text=this.statics.value(this.domNode),s},d.prototype.update=function(p,h){var s=this;p.some(function(S){return S.type==="characterData"&&S.target===s.domNode})&&(this.text=this.statics.value(this.domNode))},d.prototype.value=function(){return this.text},d.blotName="text",d.scope=f.Scope.INLINE_BLOT,d})(c.default);o.default=m}),(function(r,o,i){var l=document.createElement("div");if(l.classList.toggle("test-class",!1),l.classList.contains("test-class")){var c=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(f,m){return arguments.length>1&&!this.contains(f)==!m?m:c.call(this,f)}}String.prototype.startsWith||(String.prototype.startsWith=function(f,m){return m=m||0,this.substr(m,f.length)===f}),String.prototype.endsWith||(String.prototype.endsWith=function(f,m){var g=this.toString();(typeof m!="number"||!isFinite(m)||Math.floor(m)!==m||m>g.length)&&(m=g.length),m-=f.length;var d=g.indexOf(f,m);return d!==-1&&d===m}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(m){if(this===null)throw new TypeError("Array.prototype.find called on null or undefined");if(typeof m!="function")throw new TypeError("predicate must be a function");for(var g=Object(this),d=g.length>>>0,p=arguments[1],h,s=0;s<d;s++)if(h=g[s],m.call(p,h,s,g))return h}}),document.addEventListener("DOMContentLoaded",function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)})}),(function(r,o){var i=-1,l=1,c=0;function f(x,k,P){if(x==k)return x?[[c,x]]:[];(P<0||x.length<P)&&(P=null);var R=p(x,k),j=x.substring(0,R);x=x.substring(R),k=k.substring(R),R=h(x,k);var z=x.substring(x.length-R);x=x.substring(0,x.length-R),k=k.substring(0,k.length-R);var L=m(x,k);return j&&L.unshift([c,j]),z&&L.push([c,z]),S(L),P!=null&&(L=w(L,P)),L=y(L),L}function m(x,k){var P;if(!x)return[[l,k]];if(!k)return[[i,x]];var R=x.length>k.length?x:k,j=x.length>k.length?k:x,z=R.indexOf(j);if(z!=-1)return P=[[l,R.substring(0,z)],[c,j],[l,R.substring(z+j.length)]],x.length>k.length&&(P[0][0]=P[2][0]=i),P;if(j.length==1)return[[i,x],[l,k]];var L=s(x,k);if(L){var M=L[0],D=L[1],F=L[2],B=L[3],U=L[4],J=f(M,F),oe=f(D,B);return J.concat([[c,U]],oe)}return g(x,k)}function g(x,k){for(var P=x.length,R=k.length,j=Math.ceil((P+R)/2),z=j,L=2*j,M=new Array(L),D=new Array(L),F=0;F<L;F++)M[F]=-1,D[F]=-1;M[z+1]=0,D[z+1]=0;for(var B=P-R,U=B%2!=0,J=0,oe=0,de=0,Y=0,ee=0;ee<j;ee++){for(var W=-ee+J;W<=ee-oe;W+=2){var ne=z+W,ae;W==-ee||W!=ee&&M[ne-1]<M[ne+1]?ae=M[ne+1]:ae=M[ne-1]+1;for(var te=ae-W;ae<P&&te<R&&x.charAt(ae)==k.charAt(te);)ae++,te++;if(M[ne]=ae,ae>P)oe+=2;else if(te>R)J+=2;else if(U){var re=z+B-W;if(re>=0&&re<L&&D[re]!=-1){var Z=P-D[re];if(ae>=Z)return d(x,k,ae,te)}}}for(var se=-ee+de;se<=ee-Y;se+=2){var re=z+se,Z;se==-ee||se!=ee&&D[re-1]<D[re+1]?Z=D[re+1]:Z=D[re-1]+1;for(var pe=Z-se;Z<P&&pe<R&&x.charAt(P-Z-1)==k.charAt(R-pe-1);)Z++,pe++;if(D[re]=Z,Z>P)Y+=2;else if(pe>R)de+=2;else if(!U){var ne=z+B-se;if(ne>=0&&ne<L&&M[ne]!=-1){var ae=M[ne],te=z+ae-ne;if(Z=P-Z,ae>=Z)return d(x,k,ae,te)}}}}return[[i,x],[l,k]]}function d(x,k,P,R){var j=x.substring(0,P),z=k.substring(0,R),L=x.substring(P),M=k.substring(R),D=f(j,z),F=f(L,M);return D.concat(F)}function p(x,k){if(!x||!k||x.charAt(0)!=k.charAt(0))return 0;for(var P=0,R=Math.min(x.length,k.length),j=R,z=0;P<j;)x.substring(z,j)==k.substring(z,j)?(P=j,z=P):R=j,j=Math.floor((R-P)/2+P);return j}function h(x,k){if(!x||!k||x.charAt(x.length-1)!=k.charAt(k.length-1))return 0;for(var P=0,R=Math.min(x.length,k.length),j=R,z=0;P<j;)x.substring(x.length-j,x.length-z)==k.substring(k.length-j,k.length-z)?(P=j,z=P):R=j,j=Math.floor((R-P)/2+P);return j}function s(x,k){var P=x.length>k.length?x:k,R=x.length>k.length?k:x;if(P.length<4||R.length*2<P.length)return null;function j(oe,de,Y){for(var ee=oe.substring(Y,Y+Math.floor(oe.length/4)),W=-1,ne="",ae,te,re,Z;(W=de.indexOf(ee,W+1))!=-1;){var se=p(oe.substring(Y),de.substring(W)),pe=h(oe.substring(0,Y),de.substring(0,W));ne.length<pe+se&&(ne=de.substring(W-pe,W)+de.substring(W,W+se),ae=oe.substring(0,Y-pe),te=oe.substring(Y+se),re=de.substring(0,W-pe),Z=de.substring(W+se))}return ne.length*2>=oe.length?[ae,te,re,Z,ne]:null}var z=j(P,R,Math.ceil(P.length/4)),L=j(P,R,Math.ceil(P.length/2)),M;if(!z&&!L)return null;L?z?M=z[4].length>L[4].length?z:L:M=L:M=z;var D,F,B,U;x.length>k.length?(D=M[0],F=M[1],B=M[2],U=M[3]):(B=M[0],U=M[1],D=M[2],F=M[3]);var J=M[4];return[D,F,B,U,J]}function S(x){x.push([c,""]);for(var k=0,P=0,R=0,j="",z="",L;k<x.length;)switch(x[k][0]){case l:R++,z+=x[k][1],k++;break;case i:P++,j+=x[k][1],k++;break;case c:P+R>1?(P!==0&&R!==0&&(L=p(z,j),L!==0&&(k-P-R>0&&x[k-P-R-1][0]==c?x[k-P-R-1][1]+=z.substring(0,L):(x.splice(0,0,[c,z.substring(0,L)]),k++),z=z.substring(L),j=j.substring(L)),L=h(z,j),L!==0&&(x[k][1]=z.substring(z.length-L)+x[k][1],z=z.substring(0,z.length-L),j=j.substring(0,j.length-L))),P===0?x.splice(k-R,P+R,[l,z]):R===0?x.splice(k-P,P+R,[i,j]):x.splice(k-P-R,P+R,[i,j],[l,z]),k=k-P-R+(P?1:0)+(R?1:0)+1):k!==0&&x[k-1][0]==c?(x[k-1][1]+=x[k][1],x.splice(k,1)):k++,R=0,P=0,j="",z="";break}x[x.length-1][1]===""&&x.pop();var M=!1;for(k=1;k<x.length-1;)x[k-1][0]==c&&x[k+1][0]==c&&(x[k][1].substring(x[k][1].length-x[k-1][1].length)==x[k-1][1]?(x[k][1]=x[k-1][1]+x[k][1].substring(0,x[k][1].length-x[k-1][1].length),x[k+1][1]=x[k-1][1]+x[k+1][1],x.splice(k-1,1),M=!0):x[k][1].substring(0,x[k+1][1].length)==x[k+1][1]&&(x[k-1][1]+=x[k+1][1],x[k][1]=x[k][1].substring(x[k+1][1].length)+x[k+1][1],x.splice(k+1,1),M=!0)),k++;M&&S(x)}var b=f;b.INSERT=l,b.DELETE=i,b.EQUAL=c,r.exports=b;function _(x,k){if(k===0)return[c,x];for(var P=0,R=0;R<x.length;R++){var j=x[R];if(j[0]===i||j[0]===c){var z=P+j[1].length;if(k===z)return[R+1,x];if(k<z){x=x.slice();var L=k-P,M=[j[0],j[1].slice(0,L)],D=[j[0],j[1].slice(L)];return x.splice(R,1,M,D),[R+1,x]}else P=z}}throw new Error("cursor_pos is out of bounds!")}function w(x,k){var P=_(x,k),R=P[1],j=P[0],z=R[j],L=R[j+1];if(z==null)return x;if(z[0]!==c)return x;if(L!=null&&z[1]+L[1]===L[1]+z[1])return R.splice(j,2,L,z),E(R,j,2);if(L!=null&&L[1].indexOf(z[1])===0){R.splice(j,2,[L[0],z[1]],[0,z[1]]);var M=L[1].slice(z[1].length);return M.length>0&&R.splice(j+2,0,[L[0],M]),E(R,j,3)}else return x}function y(x){for(var k=!1,P=function(L){return L.charCodeAt(0)>=56320&&L.charCodeAt(0)<=57343},R=function(L){return L.charCodeAt(L.length-1)>=55296&&L.charCodeAt(L.length-1)<=56319},j=2;j<x.length;j+=1)x[j-2][0]===c&&R(x[j-2][1])&&x[j-1][0]===i&&P(x[j-1][1])&&x[j][0]===l&&P(x[j][1])&&(k=!0,x[j-1][1]=x[j-2][1].slice(-1)+x[j-1][1],x[j][1]=x[j-2][1].slice(-1)+x[j][1],x[j-2][1]=x[j-2][1].slice(0,-1));if(!k)return x;for(var z=[],j=0;j<x.length;j+=1)x[j][1].length>0&&z.push(x[j]);return z}function E(x,k,P){for(var R=k+P-1;R>=0&&R>=k-1;R--)if(R+1<x.length){var j=x[R],z=x[R+1];j[0]===z[1]&&x.splice(R,2,[j[0],j[1]+z[1]])}return x}}),(function(r,o){o=r.exports=typeof Object.keys=="function"?Object.keys:i,o.shim=i;function i(l){var c=[];for(var f in l)c.push(f);return c}}),(function(r,o){var i=(function(){return Object.prototype.toString.call(arguments)})()=="[object Arguments]";o=r.exports=i?l:c,o.supported=l;function l(f){return Object.prototype.toString.call(f)=="[object Arguments]"}o.unsupported=c;function c(f){return f&&typeof f=="object"&&typeof f.length=="number"&&Object.prototype.hasOwnProperty.call(f,"callee")&&!Object.prototype.propertyIsEnumerable.call(f,"callee")||!1}}),(function(r,o){var i=Object.prototype.hasOwnProperty,l="~";function c(){}Object.create&&(c.prototype=Object.create(null),new c().__proto__||(l=!1));function f(g,d,p){this.fn=g,this.context=d,this.once=p||!1}function m(){this._events=new c,this._eventsCount=0}m.prototype.eventNames=function(){var d=[],p,h;if(this._eventsCount===0)return d;for(h in p=this._events)i.call(p,h)&&d.push(l?h.slice(1):h);return Object.getOwnPropertySymbols?d.concat(Object.getOwnPropertySymbols(p)):d},m.prototype.listeners=function(d,p){var h=l?l+d:d,s=this._events[h];if(p)return!!s;if(!s)return[];if(s.fn)return[s.fn];for(var S=0,b=s.length,_=new Array(b);S<b;S++)_[S]=s[S].fn;return _},m.prototype.emit=function(d,p,h,s,S,b){var _=l?l+d:d;if(!this._events[_])return!1;var w=this._events[_],y=arguments.length,E,x;if(w.fn){switch(w.once&&this.removeListener(d,w.fn,void 0,!0),y){case 1:return w.fn.call(w.context),!0;case 2:return w.fn.call(w.context,p),!0;case 3:return w.fn.call(w.context,p,h),!0;case 4:return w.fn.call(w.context,p,h,s),!0;case 5:return w.fn.call(w.context,p,h,s,S),!0;case 6:return w.fn.call(w.context,p,h,s,S,b),!0}for(x=1,E=new Array(y-1);x<y;x++)E[x-1]=arguments[x];w.fn.apply(w.context,E)}else{var k=w.length,P;for(x=0;x<k;x++)switch(w[x].once&&this.removeListener(d,w[x].fn,void 0,!0),y){case 1:w[x].fn.call(w[x].context);break;case 2:w[x].fn.call(w[x].context,p);break;case 3:w[x].fn.call(w[x].context,p,h);break;case 4:w[x].fn.call(w[x].context,p,h,s);break;default:if(!E)for(P=1,E=new Array(y-1);P<y;P++)E[P-1]=arguments[P];w[x].fn.apply(w[x].context,E)}}return!0},m.prototype.on=function(d,p,h){var s=new f(p,h||this),S=l?l+d:d;return this._events[S]?this._events[S].fn?this._events[S]=[this._events[S],s]:this._events[S].push(s):(this._events[S]=s,this._eventsCount++),this},m.prototype.once=function(d,p,h){var s=new f(p,h||this,!0),S=l?l+d:d;return this._events[S]?this._events[S].fn?this._events[S]=[this._events[S],s]:this._events[S].push(s):(this._events[S]=s,this._eventsCount++),this},m.prototype.removeListener=function(d,p,h,s){var S=l?l+d:d;if(!this._events[S])return this;if(!p)return--this._eventsCount===0?this._events=new c:delete this._events[S],this;var b=this._events[S];if(b.fn)b.fn===p&&(!s||b.once)&&(!h||b.context===h)&&(--this._eventsCount===0?this._events=new c:delete this._events[S]);else{for(var _=0,w=[],y=b.length;_<y;_++)(b[_].fn!==p||s&&!b[_].once||h&&b[_].context!==h)&&w.push(b[_]);w.length?this._events[S]=w.length===1?w[0]:w:--this._eventsCount===0?this._events=new c:delete this._events[S]}return this},m.prototype.removeAllListeners=function(d){var p;return d?(p=l?l+d:d,this._events[p]&&(--this._eventsCount===0?this._events=new c:delete this._events[p])):(this._events=new c,this._eventsCount=0),this},m.prototype.off=m.prototype.removeListener,m.prototype.addListener=m.prototype.on,m.prototype.setMaxListeners=function(){return this},m.prefixed=l,m.EventEmitter=m,typeof r<"u"&&(r.exports=m)}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.matchText=o.matchSpacing=o.matchNewline=o.matchBlot=o.matchAttributor=o.default=void 0;var l=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(we){return typeof we}:function(we){return we&&typeof Symbol=="function"&&we.constructor===Symbol&&we!==Symbol.prototype?"symbol":typeof we},c=(function(){function we(xe,Re){var De=[],Ee=!0,We=!1,Qe=void 0;try{for(var ot=xe[Symbol.iterator](),Mt;!(Ee=(Mt=ot.next()).done)&&(De.push(Mt.value),!(Re&&De.length===Re));Ee=!0);}catch(jt){We=!0,Qe=jt}finally{try{!Ee&&ot.return&&ot.return()}finally{if(We)throw Qe}}return De}return function(xe,Re){if(Array.isArray(xe))return xe;if(Symbol.iterator in Object(xe))return we(xe,Re);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),f=(function(){function we(xe,Re){for(var De=0;De<Re.length;De++){var Ee=Re[De];Ee.enumerable=Ee.enumerable||!1,Ee.configurable=!0,"value"in Ee&&(Ee.writable=!0),Object.defineProperty(xe,Ee.key,Ee)}}return function(xe,Re,De){return Re&&we(xe.prototype,Re),De&&we(xe,De),xe}})(),m=i(3),g=D(m),d=i(2),p=D(d),h=i(0),s=D(h),S=i(5),b=D(S),_=i(10),w=D(_),y=i(9),E=D(y),x=i(36),k=i(37),P=i(13),R=D(P),j=i(26),z=i(38),L=i(39),M=i(40);function D(we){return we&&we.__esModule?we:{default:we}}function F(we,xe,Re){return xe in we?Object.defineProperty(we,xe,{value:Re,enumerable:!0,configurable:!0,writable:!0}):we[xe]=Re,we}function B(we,xe){if(!(we instanceof xe))throw new TypeError("Cannot call a class as a function")}function U(we,xe){if(!we)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return xe&&(typeof xe=="object"||typeof xe=="function")?xe:we}function J(we,xe){if(typeof xe!="function"&&xe!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof xe);we.prototype=Object.create(xe&&xe.prototype,{constructor:{value:we,enumerable:!1,writable:!0,configurable:!0}}),xe&&(Object.setPrototypeOf?Object.setPrototypeOf(we,xe):we.__proto__=xe)}var oe=(0,w.default)("quill:clipboard"),de="__ql-matcher",Y=[[Node.TEXT_NODE,Ce],[Node.TEXT_NODE,Fe],["br",Ae],[Node.ELEMENT_NODE,Fe],[Node.ELEMENT_NODE,be],[Node.ELEMENT_NODE,Pe],[Node.ELEMENT_NODE,ge],[Node.ELEMENT_NODE,ut],["li",Ve],["b",pe.bind(pe,"bold")],["i",pe.bind(pe,"italic")],["style",Ue]],ee=[x.AlignAttribute,z.DirectionAttribute].reduce(function(we,xe){return we[xe.keyName]=xe,we},{}),W=[x.AlignStyle,k.BackgroundStyle,j.ColorStyle,z.DirectionStyle,L.FontStyle,M.SizeStyle].reduce(function(we,xe){return we[xe.keyName]=xe,we},{}),ne=(function(we){J(xe,we);function xe(Re,De){B(this,xe);var Ee=U(this,(xe.__proto__||Object.getPrototypeOf(xe)).call(this,Re,De));return Ee.quill.root.addEventListener("paste",Ee.onPaste.bind(Ee)),Ee.container=Ee.quill.addContainer("ql-clipboard"),Ee.container.setAttribute("contenteditable",!0),Ee.container.setAttribute("tabindex",-1),Ee.matchers=[],Y.concat(Ee.options.matchers).forEach(function(We){var Qe=c(We,2),ot=Qe[0],Mt=Qe[1];!De.matchVisual&&Mt===Pe||Ee.addMatcher(ot,Mt)}),Ee}return f(xe,[{key:"addMatcher",value:function(De,Ee){this.matchers.push([De,Ee])}},{key:"convert",value:function(De){if(typeof De=="string")return this.container.innerHTML=De.replace(/\>\r?\n +\</g,"><"),this.convert();var Ee=this.quill.getFormat(this.quill.selection.savedRange.index);if(Ee[R.default.blotName]){var We=this.container.innerText;return this.container.innerHTML="",new p.default().insert(We,F({},R.default.blotName,Ee[R.default.blotName]))}var Qe=this.prepareMatching(),ot=c(Qe,2),Mt=ot[0],jt=ot[1],pt=se(this.container,Mt,jt);return re(pt,`
|
|
168
|
+
`)&&pt.ops[pt.ops.length-1].attributes==null&&(pt=pt.compose(new p.default().retain(pt.length()-1).delete(1))),oe.log("convert",this.container.innerHTML,pt),this.container.innerHTML="",pt}},{key:"dangerouslyPasteHTML",value:function(De,Ee){var We=arguments.length>2&&arguments[2]!==void 0?arguments[2]:b.default.sources.API;if(typeof De=="string")this.quill.setContents(this.convert(De),Ee),this.quill.setSelection(0,b.default.sources.SILENT);else{var Qe=this.convert(Ee);this.quill.updateContents(new p.default().retain(De).concat(Qe),We),this.quill.setSelection(De+Qe.length(),b.default.sources.SILENT)}}},{key:"onPaste",value:function(De){var Ee=this;if(!(De.defaultPrevented||!this.quill.isEnabled())){var We=this.quill.getSelection(),Qe=new p.default().retain(We.index),ot=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(b.default.sources.SILENT),setTimeout(function(){Qe=Qe.concat(Ee.convert()).delete(We.length),Ee.quill.updateContents(Qe,b.default.sources.USER),Ee.quill.setSelection(Qe.length()-We.length,b.default.sources.SILENT),Ee.quill.scrollingContainer.scrollTop=ot,Ee.quill.focus()},1)}}},{key:"prepareMatching",value:function(){var De=this,Ee=[],We=[];return this.matchers.forEach(function(Qe){var ot=c(Qe,2),Mt=ot[0],jt=ot[1];switch(Mt){case Node.TEXT_NODE:We.push(jt);break;case Node.ELEMENT_NODE:Ee.push(jt);break;default:[].forEach.call(De.container.querySelectorAll(Mt),function(pt){pt[de]=pt[de]||[],pt[de].push(jt)});break}}),[Ee,We]}}]),xe})(E.default);ne.DEFAULTS={matchers:[],matchVisual:!0};function ae(we,xe,Re){return(typeof xe>"u"?"undefined":l(xe))==="object"?Object.keys(xe).reduce(function(De,Ee){return ae(De,Ee,xe[Ee])},we):we.reduce(function(De,Ee){return Ee.attributes&&Ee.attributes[xe]?De.push(Ee):De.insert(Ee.insert,(0,g.default)({},F({},xe,Re),Ee.attributes))},new p.default)}function te(we){if(we.nodeType!==Node.ELEMENT_NODE)return{};var xe="__ql-computed-style";return we[xe]||(we[xe]=window.getComputedStyle(we))}function re(we,xe){for(var Re="",De=we.ops.length-1;De>=0&&Re.length<xe.length;--De){var Ee=we.ops[De];if(typeof Ee.insert!="string")break;Re=Ee.insert+Re}return Re.slice(-1*xe.length)===xe}function Z(we){if(we.childNodes.length===0)return!1;var xe=te(we);return["block","list-item"].indexOf(xe.display)>-1}function se(we,xe,Re){return we.nodeType===we.TEXT_NODE?Re.reduce(function(De,Ee){return Ee(we,De)},new p.default):we.nodeType===we.ELEMENT_NODE?[].reduce.call(we.childNodes||[],function(De,Ee){var We=se(Ee,xe,Re);return Ee.nodeType===we.ELEMENT_NODE&&(We=xe.reduce(function(Qe,ot){return ot(Ee,Qe)},We),We=(Ee[de]||[]).reduce(function(Qe,ot){return ot(Ee,Qe)},We)),De.concat(We)},new p.default):new p.default}function pe(we,xe,Re){return ae(Re,we,!0)}function ge(we,xe){var Re=s.default.Attributor.Attribute.keys(we),De=s.default.Attributor.Class.keys(we),Ee=s.default.Attributor.Style.keys(we),We={};return Re.concat(De).concat(Ee).forEach(function(Qe){var ot=s.default.query(Qe,s.default.Scope.ATTRIBUTE);ot!=null&&(We[ot.attrName]=ot.value(we),We[ot.attrName])||(ot=ee[Qe],ot!=null&&(ot.attrName===Qe||ot.keyName===Qe)&&(We[ot.attrName]=ot.value(we)||void 0),ot=W[Qe],ot!=null&&(ot.attrName===Qe||ot.keyName===Qe)&&(ot=W[Qe],We[ot.attrName]=ot.value(we)||void 0))}),Object.keys(We).length>0&&(xe=ae(xe,We)),xe}function be(we,xe){var Re=s.default.query(we);if(Re==null)return xe;if(Re.prototype instanceof s.default.Embed){var De={},Ee=Re.value(we);Ee!=null&&(De[Re.blotName]=Ee,xe=new p.default().insert(De,Re.formats(we)))}else typeof Re.formats=="function"&&(xe=ae(xe,Re.blotName,Re.formats(we)));return xe}function Ae(we,xe){return re(xe,`
|
|
169
|
+
`)||xe.insert(`
|
|
170
|
+
`),xe}function Ue(){return new p.default}function Ve(we,xe){var Re=s.default.query(we);if(Re==null||Re.blotName!=="list-item"||!re(xe,`
|
|
171
|
+
`))return xe;for(var De=-1,Ee=we.parentNode;!Ee.classList.contains("ql-clipboard");)(s.default.query(Ee)||{}).blotName==="list"&&(De+=1),Ee=Ee.parentNode;return De<=0?xe:xe.compose(new p.default().retain(xe.length()-1).retain(1,{indent:De}))}function Fe(we,xe){return re(xe,`
|
|
172
|
+
`)||(Z(we)||xe.length()>0&&we.nextSibling&&Z(we.nextSibling))&&xe.insert(`
|
|
173
|
+
`),xe}function Pe(we,xe){if(Z(we)&&we.nextElementSibling!=null&&!re(xe,`
|
|
174
|
+
|
|
175
|
+
`)){var Re=we.offsetHeight+parseFloat(te(we).marginTop)+parseFloat(te(we).marginBottom);we.nextElementSibling.offsetTop>we.offsetTop+Re*1.5&&xe.insert(`
|
|
176
|
+
`)}return xe}function ut(we,xe){var Re={},De=we.style||{};return De.fontStyle&&te(we).fontStyle==="italic"&&(Re.italic=!0),De.fontWeight&&(te(we).fontWeight.startsWith("bold")||parseInt(te(we).fontWeight)>=700)&&(Re.bold=!0),Object.keys(Re).length>0&&(xe=ae(xe,Re)),parseFloat(De.textIndent||0)>0&&(xe=new p.default().insert(" ").concat(xe)),xe}function Ce(we,xe){var Re=we.data;if(we.parentNode.tagName==="O:P")return xe.insert(Re.trim());if(Re.trim().length===0&&we.parentNode.classList.contains("ql-clipboard"))return xe;if(!te(we.parentNode).whiteSpace.startsWith("pre")){var De=function(We,Qe){return Qe=Qe.replace(/[^\u00a0]/g,""),Qe.length<1&&We?" ":Qe};Re=Re.replace(/\r\n/g," ").replace(/\n/g," "),Re=Re.replace(/\s\s+/g,De.bind(De,!0)),(we.previousSibling==null&&Z(we.parentNode)||we.previousSibling!=null&&Z(we.previousSibling))&&(Re=Re.replace(/^\s+/,De.bind(De,!1))),(we.nextSibling==null&&Z(we.parentNode)||we.nextSibling!=null&&Z(we.nextSibling))&&(Re=Re.replace(/\s+$/,De.bind(De,!1)))}return xe.insert(Re)}o.default=ne,o.matchAttributor=ge,o.matchBlot=be,o.matchNewline=Fe,o.matchSpacing=Pe,o.matchText=Ce}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function S(b,_){for(var w=0;w<_.length;w++){var y=_[w];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(b,y.key,y)}}return function(b,_,w){return _&&S(b.prototype,_),w&&S(b,w),b}})(),c=function S(b,_,w){b===null&&(b=Function.prototype);var y=Object.getOwnPropertyDescriptor(b,_);if(y===void 0){var E=Object.getPrototypeOf(b);return E===null?void 0:S(E,_,w)}else{if("value"in y)return y.value;var x=y.get;return x===void 0?void 0:x.call(w)}},f=i(6),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(){return d(this,b),p(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}return l(b,[{key:"optimize",value:function(w){c(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"optimize",this).call(this,w),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return c(b.__proto__||Object.getPrototypeOf(b),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),b})(m.default);s.blotName="bold",s.tagName=["STRONG","B"],o.default=s}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.addControls=o.default=void 0;var l=(function(){function M(D,F){var B=[],U=!0,J=!1,oe=void 0;try{for(var de=D[Symbol.iterator](),Y;!(U=(Y=de.next()).done)&&(B.push(Y.value),!(F&&B.length===F));U=!0);}catch(ee){J=!0,oe=ee}finally{try{!U&&de.return&&de.return()}finally{if(J)throw oe}}return B}return function(D,F){if(Array.isArray(D))return D;if(Symbol.iterator in Object(D))return M(D,F);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=(function(){function M(D,F){for(var B=0;B<F.length;B++){var U=F[B];U.enumerable=U.enumerable||!1,U.configurable=!0,"value"in U&&(U.writable=!0),Object.defineProperty(D,U.key,U)}}return function(D,F,B){return F&&M(D.prototype,F),B&&M(D,B),D}})(),f=i(2),m=w(f),g=i(0),d=w(g),p=i(5),h=w(p),s=i(10),S=w(s),b=i(9),_=w(b);function w(M){return M&&M.__esModule?M:{default:M}}function y(M,D,F){return D in M?Object.defineProperty(M,D,{value:F,enumerable:!0,configurable:!0,writable:!0}):M[D]=F,M}function E(M,D){if(!(M instanceof D))throw new TypeError("Cannot call a class as a function")}function x(M,D){if(!M)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return D&&(typeof D=="object"||typeof D=="function")?D:M}function k(M,D){if(typeof D!="function"&&D!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof D);M.prototype=Object.create(D&&D.prototype,{constructor:{value:M,enumerable:!1,writable:!0,configurable:!0}}),D&&(Object.setPrototypeOf?Object.setPrototypeOf(M,D):M.__proto__=D)}var P=(0,S.default)("quill:toolbar"),R=(function(M){k(D,M);function D(F,B){E(this,D);var U=x(this,(D.__proto__||Object.getPrototypeOf(D)).call(this,F,B));if(Array.isArray(U.options.container)){var J=document.createElement("div");z(J,U.options.container),F.container.parentNode.insertBefore(J,F.container),U.container=J}else typeof U.options.container=="string"?U.container=document.querySelector(U.options.container):U.container=U.options.container;if(!(U.container instanceof HTMLElement)){var oe;return oe=P.error("Container required for toolbar",U.options),x(U,oe)}return U.container.classList.add("ql-toolbar"),U.controls=[],U.handlers={},Object.keys(U.options.handlers).forEach(function(de){U.addHandler(de,U.options.handlers[de])}),[].forEach.call(U.container.querySelectorAll("button, select"),function(de){U.attach(de)}),U.quill.on(h.default.events.EDITOR_CHANGE,function(de,Y){de===h.default.events.SELECTION_CHANGE&&U.update(Y)}),U.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){var de=U.quill.selection.getRange(),Y=l(de,1),ee=Y[0];U.update(ee)}),U}return c(D,[{key:"addHandler",value:function(B,U){this.handlers[B]=U}},{key:"attach",value:function(B){var U=this,J=[].find.call(B.classList,function(de){return de.indexOf("ql-")===0});if(J){if(J=J.slice(3),B.tagName==="BUTTON"&&B.setAttribute("type","button"),this.handlers[J]==null){if(this.quill.scroll.whitelist!=null&&this.quill.scroll.whitelist[J]==null){P.warn("ignoring attaching to disabled format",J,B);return}if(d.default.query(J)==null){P.warn("ignoring attaching to nonexistent format",J,B);return}}var oe=B.tagName==="SELECT"?"change":"click";B.addEventListener(oe,function(de){var Y=void 0;if(B.tagName==="SELECT"){if(B.selectedIndex<0)return;var ee=B.options[B.selectedIndex];ee.hasAttribute("selected")?Y=!1:Y=ee.value||!1}else B.classList.contains("ql-active")?Y=!1:Y=B.value||!B.hasAttribute("value"),de.preventDefault();U.quill.focus();var W=U.quill.selection.getRange(),ne=l(W,1),ae=ne[0];if(U.handlers[J]!=null)U.handlers[J].call(U,Y);else if(d.default.query(J).prototype instanceof d.default.Embed){if(Y=prompt("Enter "+J),!Y)return;U.quill.updateContents(new m.default().retain(ae.index).delete(ae.length).insert(y({},J,Y)),h.default.sources.USER)}else U.quill.format(J,Y,h.default.sources.USER);U.update(ae)}),this.controls.push([J,B])}}},{key:"update",value:function(B){var U=B==null?{}:this.quill.getFormat(B);this.controls.forEach(function(J){var oe=l(J,2),de=oe[0],Y=oe[1];if(Y.tagName==="SELECT"){var ee=void 0;if(B==null)ee=null;else if(U[de]==null)ee=Y.querySelector("option[selected]");else if(!Array.isArray(U[de])){var W=U[de];typeof W=="string"&&(W=W.replace(/\"/g,'\\"')),ee=Y.querySelector('option[value="'+W+'"]')}ee==null?(Y.value="",Y.selectedIndex=-1):ee.selected=!0}else if(B==null)Y.classList.remove("ql-active");else if(Y.hasAttribute("value")){var ne=U[de]===Y.getAttribute("value")||U[de]!=null&&U[de].toString()===Y.getAttribute("value")||U[de]==null&&!Y.getAttribute("value");Y.classList.toggle("ql-active",ne)}else Y.classList.toggle("ql-active",U[de]!=null)})}}]),D})(_.default);R.DEFAULTS={};function j(M,D,F){var B=document.createElement("button");B.setAttribute("type","button"),B.classList.add("ql-"+D),F!=null&&(B.value=F),M.appendChild(B)}function z(M,D){Array.isArray(D[0])||(D=[D]),D.forEach(function(F){var B=document.createElement("span");B.classList.add("ql-formats"),F.forEach(function(U){if(typeof U=="string")j(B,U);else{var J=Object.keys(U)[0],oe=U[J];Array.isArray(oe)?L(B,J,oe):j(B,J,oe)}}),M.appendChild(B)})}function L(M,D,F){var B=document.createElement("select");B.classList.add("ql-"+D),F.forEach(function(U){var J=document.createElement("option");U!==!1?J.setAttribute("value",U):J.setAttribute("selected","selected"),B.appendChild(J)}),M.appendChild(B)}R.DEFAULTS={container:null,handlers:{clean:function(){var D=this,F=this.quill.getSelection();if(F!=null)if(F.length==0){var B=this.quill.getFormat();Object.keys(B).forEach(function(U){d.default.query(U,d.default.Scope.INLINE)!=null&&D.quill.format(U,!1)})}else this.quill.removeFormat(F,h.default.sources.USER)},direction:function(D){var F=this.quill.getFormat().align;D==="rtl"&&F==null?this.quill.format("align","right",h.default.sources.USER):!D&&F==="right"&&this.quill.format("align",!1,h.default.sources.USER),this.quill.format("direction",D,h.default.sources.USER)},indent:function(D){var F=this.quill.getSelection(),B=this.quill.getFormat(F),U=parseInt(B.indent||0);if(D==="+1"||D==="-1"){var J=D==="+1"?1:-1;B.direction==="rtl"&&(J*=-1),this.quill.format("indent",U+J,h.default.sources.USER)}},link:function(D){D===!0&&(D=prompt("Enter link URL:")),this.quill.format("link",D,h.default.sources.USER)},list:function(D){var F=this.quill.getSelection(),B=this.quill.getFormat(F);D==="check"?B.list==="checked"||B.list==="unchecked"?this.quill.format("list",!1,h.default.sources.USER):this.quill.format("list","unchecked",h.default.sources.USER):this.quill.format("list",D,h.default.sources.USER)}}},o.default=R,o.addControls=z}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function S(b,_){for(var w=0;w<_.length;w++){var y=_[w];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(b,y.key,y)}}return function(b,_,w){return _&&S(b.prototype,_),w&&S(b,w),b}})(),c=function S(b,_,w){b===null&&(b=Function.prototype);var y=Object.getOwnPropertyDescriptor(b,_);if(y===void 0){var E=Object.getPrototypeOf(b);return E===null?void 0:S(E,_,w)}else{if("value"in y)return y.value;var x=y.get;return x===void 0?void 0:x.call(w)}},f=i(28),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(_,w){d(this,b);var y=p(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,_));return y.label.innerHTML=w,y.container.classList.add("ql-color-picker"),[].slice.call(y.container.querySelectorAll(".ql-picker-item"),0,7).forEach(function(E){E.classList.add("ql-primary")}),y}return l(b,[{key:"buildItem",value:function(w){var y=c(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"buildItem",this).call(this,w);return y.style.backgroundColor=w.getAttribute("value")||"",y}},{key:"selectItem",value:function(w,y){c(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"selectItem",this).call(this,w,y);var E=this.label.querySelector(".ql-color-label"),x=w&&w.getAttribute("data-value")||"";E&&(E.tagName==="line"?E.style.stroke=x:E.style.fill=x)}}]),b})(m.default);o.default=s}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function S(b,_){for(var w=0;w<_.length;w++){var y=_[w];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(b,y.key,y)}}return function(b,_,w){return _&&S(b.prototype,_),w&&S(b,w),b}})(),c=function S(b,_,w){b===null&&(b=Function.prototype);var y=Object.getOwnPropertyDescriptor(b,_);if(y===void 0){var E=Object.getPrototypeOf(b);return E===null?void 0:S(E,_,w)}else{if("value"in y)return y.value;var x=y.get;return x===void 0?void 0:x.call(w)}},f=i(28),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(_,w){d(this,b);var y=p(this,(b.__proto__||Object.getPrototypeOf(b)).call(this,_));return y.container.classList.add("ql-icon-picker"),[].forEach.call(y.container.querySelectorAll(".ql-picker-item"),function(E){E.innerHTML=w[E.getAttribute("data-value")||""]}),y.defaultItem=y.container.querySelector(".ql-selected"),y.selectItem(y.defaultItem),y}return l(b,[{key:"selectItem",value:function(w,y){c(b.prototype.__proto__||Object.getPrototypeOf(b.prototype),"selectItem",this).call(this,w,y),w=w||this.defaultItem,this.label.innerHTML=w.innerHTML}}]),b})(m.default);o.default=s}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function m(g,d){for(var p=0;p<d.length;p++){var h=d[p];h.enumerable=h.enumerable||!1,h.configurable=!0,"value"in h&&(h.writable=!0),Object.defineProperty(g,h.key,h)}}return function(g,d,p){return d&&m(g.prototype,d),p&&m(g,p),g}})();function c(m,g){if(!(m instanceof g))throw new TypeError("Cannot call a class as a function")}var f=(function(){function m(g,d){var p=this;c(this,m),this.quill=g,this.boundsContainer=d||document.body,this.root=g.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",function(){p.root.style.marginTop=-1*p.quill.root.scrollTop+"px"}),this.hide()}return l(m,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(d){var p=d.left+d.width/2-this.root.offsetWidth/2,h=d.bottom+this.quill.root.scrollTop;this.root.style.left=p+"px",this.root.style.top=h+"px",this.root.classList.remove("ql-flip");var s=this.boundsContainer.getBoundingClientRect(),S=this.root.getBoundingClientRect(),b=0;if(S.right>s.right&&(b=s.right-S.right,this.root.style.left=p+b+"px"),S.left<s.left&&(b=s.left-S.left,this.root.style.left=p+b+"px"),S.bottom>s.bottom){var _=S.bottom-S.top,w=d.bottom-d.top+_;this.root.style.top=h-w+"px",this.root.classList.add("ql-flip")}return b}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),m})();o.default=f}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function L(M,D){var F=[],B=!0,U=!1,J=void 0;try{for(var oe=M[Symbol.iterator](),de;!(B=(de=oe.next()).done)&&(F.push(de.value),!(D&&F.length===D));B=!0);}catch(Y){U=!0,J=Y}finally{try{!B&&oe.return&&oe.return()}finally{if(U)throw J}}return F}return function(M,D){if(Array.isArray(M))return M;if(Symbol.iterator in Object(M))return L(M,D);throw new TypeError("Invalid attempt to destructure non-iterable instance")}})(),c=function L(M,D,F){M===null&&(M=Function.prototype);var B=Object.getOwnPropertyDescriptor(M,D);if(B===void 0){var U=Object.getPrototypeOf(M);return U===null?void 0:L(U,D,F)}else{if("value"in B)return B.value;var J=B.get;return J===void 0?void 0:J.call(F)}},f=(function(){function L(M,D){for(var F=0;F<D.length;F++){var B=D[F];B.enumerable=B.enumerable||!1,B.configurable=!0,"value"in B&&(B.writable=!0),Object.defineProperty(M,B.key,B)}}return function(M,D,F){return D&&L(M.prototype,D),F&&L(M,F),M}})(),m=i(3),g=E(m),d=i(8),p=E(d),h=i(43),s=E(h),S=i(27),b=E(S),_=i(15),w=i(41),y=E(w);function E(L){return L&&L.__esModule?L:{default:L}}function x(L,M){if(!(L instanceof M))throw new TypeError("Cannot call a class as a function")}function k(L,M){if(!L)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return M&&(typeof M=="object"||typeof M=="function")?M:L}function P(L,M){if(typeof M!="function"&&M!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof M);L.prototype=Object.create(M&&M.prototype,{constructor:{value:L,enumerable:!1,writable:!0,configurable:!0}}),M&&(Object.setPrototypeOf?Object.setPrototypeOf(L,M):L.__proto__=M)}var R=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],j=(function(L){P(M,L);function M(D,F){x(this,M),F.modules.toolbar!=null&&F.modules.toolbar.container==null&&(F.modules.toolbar.container=R);var B=k(this,(M.__proto__||Object.getPrototypeOf(M)).call(this,D,F));return B.quill.container.classList.add("ql-snow"),B}return f(M,[{key:"extendToolbar",value:function(F){F.container.classList.add("ql-snow"),this.buildButtons([].slice.call(F.container.querySelectorAll("button")),y.default),this.buildPickers([].slice.call(F.container.querySelectorAll("select")),y.default),this.tooltip=new z(this.quill,this.options.bounds),F.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},function(B,U){F.handlers.link.call(F,!U.format.link)})}}]),M})(s.default);j.DEFAULTS=(0,g.default)(!0,{},s.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(M){if(M){var D=this.quill.getSelection();if(D==null||D.length==0)return;var F=this.quill.getText(D);/^\S+@\S+\.\S+$/.test(F)&&F.indexOf("mailto:")!==0&&(F="mailto:"+F);var B=this.quill.theme.tooltip;B.edit("link",F)}else this.quill.format("link",!1)}}}}});var z=(function(L){P(M,L);function M(D,F){x(this,M);var B=k(this,(M.__proto__||Object.getPrototypeOf(M)).call(this,D,F));return B.preview=B.root.querySelector("a.ql-preview"),B}return f(M,[{key:"listen",value:function(){var F=this;c(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",function(B){F.root.classList.contains("ql-editing")?F.save():F.edit("link",F.preview.textContent),B.preventDefault()}),this.root.querySelector("a.ql-remove").addEventListener("click",function(B){if(F.linkRange!=null){var U=F.linkRange;F.restoreFocus(),F.quill.formatText(U,"link",!1,p.default.sources.USER),delete F.linkRange}B.preventDefault(),F.hide()}),this.quill.on(p.default.events.SELECTION_CHANGE,function(B,U,J){if(B!=null){if(B.length===0&&J===p.default.sources.USER){var oe=F.quill.scroll.descendant(b.default,B.index),de=l(oe,2),Y=de[0],ee=de[1];if(Y!=null){F.linkRange=new _.Range(B.index-ee,Y.length());var W=b.default.formats(Y.domNode);F.preview.textContent=W,F.preview.setAttribute("href",W),F.show(),F.position(F.quill.getBounds(F.linkRange));return}}else delete F.linkRange;F.hide()}})}},{key:"show",value:function(){c(M.prototype.__proto__||Object.getPrototypeOf(M.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),M})(h.BaseTooltip);z.TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),o.default=j}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(29),c=Ee(l),f=i(36),m=i(38),g=i(64),d=i(65),p=Ee(d),h=i(66),s=Ee(h),S=i(67),b=Ee(S),_=i(37),w=i(26),y=i(39),E=i(40),x=i(56),k=Ee(x),P=i(68),R=Ee(P),j=i(27),z=Ee(j),L=i(69),M=Ee(L),D=i(70),F=Ee(D),B=i(71),U=Ee(B),J=i(72),oe=Ee(J),de=i(73),Y=Ee(de),ee=i(13),W=Ee(ee),ne=i(74),ae=Ee(ne),te=i(75),re=Ee(te),Z=i(57),se=Ee(Z),pe=i(41),ge=Ee(pe),be=i(28),Ae=Ee(be),Ue=i(59),Ve=Ee(Ue),Fe=i(60),Pe=Ee(Fe),ut=i(61),Ce=Ee(ut),we=i(108),xe=Ee(we),Re=i(62),De=Ee(Re);function Ee(We){return We&&We.__esModule?We:{default:We}}c.default.register({"attributors/attribute/direction":m.DirectionAttribute,"attributors/class/align":f.AlignClass,"attributors/class/background":_.BackgroundClass,"attributors/class/color":w.ColorClass,"attributors/class/direction":m.DirectionClass,"attributors/class/font":y.FontClass,"attributors/class/size":E.SizeClass,"attributors/style/align":f.AlignStyle,"attributors/style/background":_.BackgroundStyle,"attributors/style/color":w.ColorStyle,"attributors/style/direction":m.DirectionStyle,"attributors/style/font":y.FontStyle,"attributors/style/size":E.SizeStyle},!0),c.default.register({"formats/align":f.AlignClass,"formats/direction":m.DirectionClass,"formats/indent":g.IndentClass,"formats/background":_.BackgroundStyle,"formats/color":w.ColorStyle,"formats/font":y.FontClass,"formats/size":E.SizeClass,"formats/blockquote":p.default,"formats/code-block":W.default,"formats/header":s.default,"formats/list":b.default,"formats/bold":k.default,"formats/code":ee.Code,"formats/italic":R.default,"formats/link":z.default,"formats/script":M.default,"formats/strike":F.default,"formats/underline":U.default,"formats/image":oe.default,"formats/video":Y.default,"formats/list/item":S.ListItem,"modules/formula":ae.default,"modules/syntax":re.default,"modules/toolbar":se.default,"themes/bubble":xe.default,"themes/snow":De.default,"ui/icons":ge.default,"ui/picker":Ae.default,"ui/icon-picker":Pe.default,"ui/color-picker":Ve.default,"ui/tooltip":Ce.default},!0),o.default=c.default}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.IndentClass=void 0;var l=(function(){function b(_,w){for(var y=0;y<w.length;y++){var E=w[y];E.enumerable=E.enumerable||!1,E.configurable=!0,"value"in E&&(E.writable=!0),Object.defineProperty(_,E.key,E)}}return function(_,w,y){return w&&b(_.prototype,w),y&&b(_,y),_}})(),c=function b(_,w,y){_===null&&(_=Function.prototype);var E=Object.getOwnPropertyDescriptor(_,w);if(E===void 0){var x=Object.getPrototypeOf(_);return x===null?void 0:b(x,w,y)}else{if("value"in E)return E.value;var k=E.get;return k===void 0?void 0:k.call(y)}},f=i(0),m=g(f);function g(b){return b&&b.__esModule?b:{default:b}}function d(b,_){if(!(b instanceof _))throw new TypeError("Cannot call a class as a function")}function p(b,_){if(!b)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return _&&(typeof _=="object"||typeof _=="function")?_:b}function h(b,_){if(typeof _!="function"&&_!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof _);b.prototype=Object.create(_&&_.prototype,{constructor:{value:b,enumerable:!1,writable:!0,configurable:!0}}),_&&(Object.setPrototypeOf?Object.setPrototypeOf(b,_):b.__proto__=_)}var s=(function(b){h(_,b);function _(){return d(this,_),p(this,(_.__proto__||Object.getPrototypeOf(_)).apply(this,arguments))}return l(_,[{key:"add",value:function(y,E){if(E==="+1"||E==="-1"){var x=this.value(y)||0;E=E==="+1"?x+1:x-1}return E===0?(this.remove(y),!0):c(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"add",this).call(this,y,E)}},{key:"canAdd",value:function(y,E){return c(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"canAdd",this).call(this,y,E)||c(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"canAdd",this).call(this,y,parseInt(E))}},{key:"value",value:function(y){return parseInt(c(_.prototype.__proto__||Object.getPrototypeOf(_.prototype),"value",this).call(this,y))||void 0}}]),_})(m.default.Attributor.Class),S=new s("indent","ql-indent",{scope:m.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});o.IndentClass=S}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(4),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}function m(h,s){if(!(h instanceof s))throw new TypeError("Cannot call a class as a function")}function g(h,s){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s&&(typeof s=="object"||typeof s=="function")?s:h}function d(h,s){if(typeof s!="function"&&s!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof s);h.prototype=Object.create(s&&s.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),s&&(Object.setPrototypeOf?Object.setPrototypeOf(h,s):h.__proto__=s)}var p=(function(h){d(s,h);function s(){return m(this,s),g(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return s})(c.default);p.blotName="blockquote",p.tagName="blockquote",o.default=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function s(S,b){for(var _=0;_<b.length;_++){var w=b[_];w.enumerable=w.enumerable||!1,w.configurable=!0,"value"in w&&(w.writable=!0),Object.defineProperty(S,w.key,w)}}return function(S,b,_){return b&&s(S.prototype,b),_&&s(S,_),S}})(),c=i(4),f=m(c);function m(s){return s&&s.__esModule?s:{default:s}}function g(s,S){if(!(s instanceof S))throw new TypeError("Cannot call a class as a function")}function d(s,S){if(!s)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return S&&(typeof S=="object"||typeof S=="function")?S:s}function p(s,S){if(typeof S!="function"&&S!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof S);s.prototype=Object.create(S&&S.prototype,{constructor:{value:s,enumerable:!1,writable:!0,configurable:!0}}),S&&(Object.setPrototypeOf?Object.setPrototypeOf(s,S):s.__proto__=S)}var h=(function(s){p(S,s);function S(){return g(this,S),d(this,(S.__proto__||Object.getPrototypeOf(S)).apply(this,arguments))}return l(S,null,[{key:"formats",value:function(_){return this.tagName.indexOf(_.tagName)+1}}]),S})(f.default);h.blotName="header",h.tagName=["H1","H2","H3","H4","H5","H6"],o.default=h}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.ListItem=void 0;var l=(function(){function x(k,P){for(var R=0;R<P.length;R++){var j=P[R];j.enumerable=j.enumerable||!1,j.configurable=!0,"value"in j&&(j.writable=!0),Object.defineProperty(k,j.key,j)}}return function(k,P,R){return P&&x(k.prototype,P),R&&x(k,R),k}})(),c=function x(k,P,R){k===null&&(k=Function.prototype);var j=Object.getOwnPropertyDescriptor(k,P);if(j===void 0){var z=Object.getPrototypeOf(k);return z===null?void 0:x(z,P,R)}else{if("value"in j)return j.value;var L=j.get;return L===void 0?void 0:L.call(R)}},f=i(0),m=s(f),g=i(4),d=s(g),p=i(25),h=s(p);function s(x){return x&&x.__esModule?x:{default:x}}function S(x,k,P){return k in x?Object.defineProperty(x,k,{value:P,enumerable:!0,configurable:!0,writable:!0}):x[k]=P,x}function b(x,k){if(!(x instanceof k))throw new TypeError("Cannot call a class as a function")}function _(x,k){if(!x)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return k&&(typeof k=="object"||typeof k=="function")?k:x}function w(x,k){if(typeof k!="function"&&k!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof k);x.prototype=Object.create(k&&k.prototype,{constructor:{value:x,enumerable:!1,writable:!0,configurable:!0}}),k&&(Object.setPrototypeOf?Object.setPrototypeOf(x,k):x.__proto__=k)}var y=(function(x){w(k,x);function k(){return b(this,k),_(this,(k.__proto__||Object.getPrototypeOf(k)).apply(this,arguments))}return l(k,[{key:"format",value:function(R,j){R===E.blotName&&!j?this.replaceWith(m.default.create(this.statics.scope)):c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"format",this).call(this,R,j)}},{key:"remove",value:function(){this.prev==null&&this.next==null?this.parent.remove():c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(R,j){return this.parent.isolate(this.offset(this.parent),this.length()),R===this.parent.statics.blotName?(this.parent.replaceWith(R,j),this):(this.parent.unwrap(),c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"replaceWith",this).call(this,R,j))}}],[{key:"formats",value:function(R){return R.tagName===this.tagName?void 0:c(k.__proto__||Object.getPrototypeOf(k),"formats",this).call(this,R)}}]),k})(d.default);y.blotName="list-item",y.tagName="LI";var E=(function(x){w(k,x),l(k,null,[{key:"create",value:function(R){var j=R==="ordered"?"OL":"UL",z=c(k.__proto__||Object.getPrototypeOf(k),"create",this).call(this,j);return(R==="checked"||R==="unchecked")&&z.setAttribute("data-checked",R==="checked"),z}},{key:"formats",value:function(R){if(R.tagName==="OL")return"ordered";if(R.tagName==="UL")return R.hasAttribute("data-checked")?R.getAttribute("data-checked")==="true"?"checked":"unchecked":"bullet"}}]);function k(P){b(this,k);var R=_(this,(k.__proto__||Object.getPrototypeOf(k)).call(this,P)),j=function(L){if(L.target.parentNode===P){var M=R.statics.formats(P),D=m.default.find(L.target);M==="checked"?D.format("list","unchecked"):M==="unchecked"&&D.format("list","checked")}};return P.addEventListener("touchstart",j),P.addEventListener("mousedown",j),R}return l(k,[{key:"format",value:function(R,j){this.children.length>0&&this.children.tail.format(R,j)}},{key:"formats",value:function(){return S({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(R,j){if(R instanceof y)c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"insertBefore",this).call(this,R,j);else{var z=j==null?this.length():j.offset(this),L=this.split(z);L.parent.insertBefore(R,L)}}},{key:"optimize",value:function(R){c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"optimize",this).call(this,R);var j=this.next;j!=null&&j.prev===this&&j.statics.blotName===this.statics.blotName&&j.domNode.tagName===this.domNode.tagName&&j.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(j.moveChildren(this),j.remove())}},{key:"replace",value:function(R){if(R.statics.blotName!==this.statics.blotName){var j=m.default.create(this.statics.defaultChild);R.moveChildren(j),this.appendChild(j)}c(k.prototype.__proto__||Object.getPrototypeOf(k.prototype),"replace",this).call(this,R)}}]),k})(h.default);E.blotName="list",E.scope=m.default.Scope.BLOCK_BLOT,E.tagName=["OL","UL"],E.defaultChild="list-item",E.allowedChildren=[y],o.ListItem=y,o.default=E}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(56),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}function m(h,s){if(!(h instanceof s))throw new TypeError("Cannot call a class as a function")}function g(h,s){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s&&(typeof s=="object"||typeof s=="function")?s:h}function d(h,s){if(typeof s!="function"&&s!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof s);h.prototype=Object.create(s&&s.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),s&&(Object.setPrototypeOf?Object.setPrototypeOf(h,s):h.__proto__=s)}var p=(function(h){d(s,h);function s(){return m(this,s),g(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return s})(c.default);p.blotName="italic",p.tagName=["EM","I"],o.default=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function S(b,_){for(var w=0;w<_.length;w++){var y=_[w];y.enumerable=y.enumerable||!1,y.configurable=!0,"value"in y&&(y.writable=!0),Object.defineProperty(b,y.key,y)}}return function(b,_,w){return _&&S(b.prototype,_),w&&S(b,w),b}})(),c=function S(b,_,w){b===null&&(b=Function.prototype);var y=Object.getOwnPropertyDescriptor(b,_);if(y===void 0){var E=Object.getPrototypeOf(b);return E===null?void 0:S(E,_,w)}else{if("value"in y)return y.value;var x=y.get;return x===void 0?void 0:x.call(w)}},f=i(6),m=g(f);function g(S){return S&&S.__esModule?S:{default:S}}function d(S,b){if(!(S instanceof b))throw new TypeError("Cannot call a class as a function")}function p(S,b){if(!S)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return b&&(typeof b=="object"||typeof b=="function")?b:S}function h(S,b){if(typeof b!="function"&&b!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof b);S.prototype=Object.create(b&&b.prototype,{constructor:{value:S,enumerable:!1,writable:!0,configurable:!0}}),b&&(Object.setPrototypeOf?Object.setPrototypeOf(S,b):S.__proto__=b)}var s=(function(S){h(b,S);function b(){return d(this,b),p(this,(b.__proto__||Object.getPrototypeOf(b)).apply(this,arguments))}return l(b,null,[{key:"create",value:function(w){return w==="super"?document.createElement("sup"):w==="sub"?document.createElement("sub"):c(b.__proto__||Object.getPrototypeOf(b),"create",this).call(this,w)}},{key:"formats",value:function(w){if(w.tagName==="SUB")return"sub";if(w.tagName==="SUP")return"super"}}]),b})(m.default);s.blotName="script",s.tagName=["SUB","SUP"],o.default=s}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(6),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}function m(h,s){if(!(h instanceof s))throw new TypeError("Cannot call a class as a function")}function g(h,s){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s&&(typeof s=="object"||typeof s=="function")?s:h}function d(h,s){if(typeof s!="function"&&s!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof s);h.prototype=Object.create(s&&s.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),s&&(Object.setPrototypeOf?Object.setPrototypeOf(h,s):h.__proto__=s)}var p=(function(h){d(s,h);function s(){return m(this,s),g(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return s})(c.default);p.blotName="strike",p.tagName="S",o.default=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=i(6),c=f(l);function f(h){return h&&h.__esModule?h:{default:h}}function m(h,s){if(!(h instanceof s))throw new TypeError("Cannot call a class as a function")}function g(h,s){if(!h)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return s&&(typeof s=="object"||typeof s=="function")?s:h}function d(h,s){if(typeof s!="function"&&s!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof s);h.prototype=Object.create(s&&s.prototype,{constructor:{value:h,enumerable:!1,writable:!0,configurable:!0}}),s&&(Object.setPrototypeOf?Object.setPrototypeOf(h,s):h.__proto__=s)}var p=(function(h){d(s,h);function s(){return m(this,s),g(this,(s.__proto__||Object.getPrototypeOf(s)).apply(this,arguments))}return s})(c.default);p.blotName="underline",p.tagName="U",o.default=p}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function _(w,y){for(var E=0;E<y.length;E++){var x=y[E];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(w,x.key,x)}}return function(w,y,E){return y&&_(w.prototype,y),E&&_(w,E),w}})(),c=function _(w,y,E){w===null&&(w=Function.prototype);var x=Object.getOwnPropertyDescriptor(w,y);if(x===void 0){var k=Object.getPrototypeOf(w);return k===null?void 0:_(k,y,E)}else{if("value"in x)return x.value;var P=x.get;return P===void 0?void 0:P.call(E)}},f=i(0),m=d(f),g=i(27);function d(_){return _&&_.__esModule?_:{default:_}}function p(_,w){if(!(_ instanceof w))throw new TypeError("Cannot call a class as a function")}function h(_,w){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:_}function s(_,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);_.prototype=Object.create(w&&w.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(_,w):_.__proto__=w)}var S=["alt","height","width"],b=(function(_){s(w,_);function w(){return p(this,w),h(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return l(w,[{key:"format",value:function(E,x){S.indexOf(E)>-1?x?this.domNode.setAttribute(E,x):this.domNode.removeAttribute(E):c(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"format",this).call(this,E,x)}}],[{key:"create",value:function(E){var x=c(w.__proto__||Object.getPrototypeOf(w),"create",this).call(this,E);return typeof E=="string"&&x.setAttribute("src",this.sanitize(E)),x}},{key:"formats",value:function(E){return S.reduce(function(x,k){return E.hasAttribute(k)&&(x[k]=E.getAttribute(k)),x},{})}},{key:"match",value:function(E){return/\.(jpe?g|gif|png)$/.test(E)||/^data:image\/.+;base64/.test(E)}},{key:"sanitize",value:function(E){return(0,g.sanitize)(E,["http","https","data"])?E:"//:0"}},{key:"value",value:function(E){return E.getAttribute("src")}}]),w})(m.default.Embed);b.blotName="image",b.tagName="IMG",o.default=b}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0});var l=(function(){function _(w,y){for(var E=0;E<y.length;E++){var x=y[E];x.enumerable=x.enumerable||!1,x.configurable=!0,"value"in x&&(x.writable=!0),Object.defineProperty(w,x.key,x)}}return function(w,y,E){return y&&_(w.prototype,y),E&&_(w,E),w}})(),c=function _(w,y,E){w===null&&(w=Function.prototype);var x=Object.getOwnPropertyDescriptor(w,y);if(x===void 0){var k=Object.getPrototypeOf(w);return k===null?void 0:_(k,y,E)}else{if("value"in x)return x.value;var P=x.get;return P===void 0?void 0:P.call(E)}},f=i(4),m=i(27),g=d(m);function d(_){return _&&_.__esModule?_:{default:_}}function p(_,w){if(!(_ instanceof w))throw new TypeError("Cannot call a class as a function")}function h(_,w){if(!_)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return w&&(typeof w=="object"||typeof w=="function")?w:_}function s(_,w){if(typeof w!="function"&&w!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof w);_.prototype=Object.create(w&&w.prototype,{constructor:{value:_,enumerable:!1,writable:!0,configurable:!0}}),w&&(Object.setPrototypeOf?Object.setPrototypeOf(_,w):_.__proto__=w)}var S=["height","width"],b=(function(_){s(w,_);function w(){return p(this,w),h(this,(w.__proto__||Object.getPrototypeOf(w)).apply(this,arguments))}return l(w,[{key:"format",value:function(E,x){S.indexOf(E)>-1?x?this.domNode.setAttribute(E,x):this.domNode.removeAttribute(E):c(w.prototype.__proto__||Object.getPrototypeOf(w.prototype),"format",this).call(this,E,x)}}],[{key:"create",value:function(E){var x=c(w.__proto__||Object.getPrototypeOf(w),"create",this).call(this,E);return x.setAttribute("frameborder","0"),x.setAttribute("allowfullscreen",!0),x.setAttribute("src",this.sanitize(E)),x}},{key:"formats",value:function(E){return S.reduce(function(x,k){return E.hasAttribute(k)&&(x[k]=E.getAttribute(k)),x},{})}},{key:"sanitize",value:function(E){return g.default.sanitize(E)}},{key:"value",value:function(E){return E.getAttribute("src")}}]),w})(f.BlockEmbed);b.blotName="video",b.className="ql-video",b.tagName="IFRAME",o.default=b}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.FormulaBlot=void 0;var l=(function(){function E(x,k){for(var P=0;P<k.length;P++){var R=k[P];R.enumerable=R.enumerable||!1,R.configurable=!0,"value"in R&&(R.writable=!0),Object.defineProperty(x,R.key,R)}}return function(x,k,P){return k&&E(x.prototype,k),P&&E(x,P),x}})(),c=function E(x,k,P){x===null&&(x=Function.prototype);var R=Object.getOwnPropertyDescriptor(x,k);if(R===void 0){var j=Object.getPrototypeOf(x);return j===null?void 0:E(j,k,P)}else{if("value"in R)return R.value;var z=R.get;return z===void 0?void 0:z.call(P)}},f=i(35),m=s(f),g=i(5),d=s(g),p=i(9),h=s(p);function s(E){return E&&E.__esModule?E:{default:E}}function S(E,x){if(!(E instanceof x))throw new TypeError("Cannot call a class as a function")}function b(E,x){if(!E)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return x&&(typeof x=="object"||typeof x=="function")?x:E}function _(E,x){if(typeof x!="function"&&x!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof x);E.prototype=Object.create(x&&x.prototype,{constructor:{value:E,enumerable:!1,writable:!0,configurable:!0}}),x&&(Object.setPrototypeOf?Object.setPrototypeOf(E,x):E.__proto__=x)}var w=(function(E){_(x,E);function x(){return S(this,x),b(this,(x.__proto__||Object.getPrototypeOf(x)).apply(this,arguments))}return l(x,null,[{key:"create",value:function(P){var R=c(x.__proto__||Object.getPrototypeOf(x),"create",this).call(this,P);return typeof P=="string"&&(window.katex.render(P,R,{throwOnError:!1,errorColor:"#f00"}),R.setAttribute("data-value",P)),R}},{key:"value",value:function(P){return P.getAttribute("data-value")}}]),x})(m.default);w.blotName="formula",w.className="ql-formula",w.tagName="SPAN";var y=(function(E){_(x,E),l(x,null,[{key:"register",value:function(){d.default.register(w,!0)}}]);function x(){S(this,x);var k=b(this,(x.__proto__||Object.getPrototypeOf(x)).call(this));if(window.katex==null)throw new Error("Formula module requires KaTeX.");return k}return x})(h.default);o.FormulaBlot=w,o.default=y}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.CodeToken=o.CodeBlock=void 0;var l=(function(){function P(R,j){for(var z=0;z<j.length;z++){var L=j[z];L.enumerable=L.enumerable||!1,L.configurable=!0,"value"in L&&(L.writable=!0),Object.defineProperty(R,L.key,L)}}return function(R,j,z){return j&&P(R.prototype,j),z&&P(R,z),R}})(),c=function P(R,j,z){R===null&&(R=Function.prototype);var L=Object.getOwnPropertyDescriptor(R,j);if(L===void 0){var M=Object.getPrototypeOf(R);return M===null?void 0:P(M,j,z)}else{if("value"in L)return L.value;var D=L.get;return D===void 0?void 0:D.call(z)}},f=i(0),m=b(f),g=i(5),d=b(g),p=i(9),h=b(p),s=i(13),S=b(s);function b(P){return P&&P.__esModule?P:{default:P}}function _(P,R){if(!(P instanceof R))throw new TypeError("Cannot call a class as a function")}function w(P,R){if(!P)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return R&&(typeof R=="object"||typeof R=="function")?R:P}function y(P,R){if(typeof R!="function"&&R!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof R);P.prototype=Object.create(R&&R.prototype,{constructor:{value:P,enumerable:!1,writable:!0,configurable:!0}}),R&&(Object.setPrototypeOf?Object.setPrototypeOf(P,R):P.__proto__=R)}var E=(function(P){y(R,P);function R(){return _(this,R),w(this,(R.__proto__||Object.getPrototypeOf(R)).apply(this,arguments))}return l(R,[{key:"replaceWith",value:function(z){this.domNode.textContent=this.domNode.textContent,this.attach(),c(R.prototype.__proto__||Object.getPrototypeOf(R.prototype),"replaceWith",this).call(this,z)}},{key:"highlight",value:function(z){var L=this.domNode.textContent;this.cachedText!==L&&((L.trim().length>0||this.cachedText==null)&&(this.domNode.innerHTML=z(L),this.domNode.normalize(),this.attach()),this.cachedText=L)}}]),R})(S.default);E.className="ql-syntax";var x=new m.default.Attributor.Class("token","hljs",{scope:m.default.Scope.INLINE}),k=(function(P){y(R,P),l(R,null,[{key:"register",value:function(){d.default.register(x,!0),d.default.register(E,!0)}}]);function R(j,z){_(this,R);var L=w(this,(R.__proto__||Object.getPrototypeOf(R)).call(this,j,z));if(typeof L.options.highlight!="function")throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var M=null;return L.quill.on(d.default.events.SCROLL_OPTIMIZE,function(){clearTimeout(M),M=setTimeout(function(){L.highlight(),M=null},L.options.interval)}),L.highlight(),L}return l(R,[{key:"highlight",value:function(){var z=this;if(!this.quill.selection.composing){this.quill.update(d.default.sources.USER);var L=this.quill.getSelection();this.quill.scroll.descendants(E).forEach(function(M){M.highlight(z.options.highlight)}),this.quill.update(d.default.sources.SILENT),L!=null&&this.quill.setSelection(L,d.default.sources.SILENT)}}}]),R})(h.default);k.DEFAULTS={highlight:(function(){return window.hljs==null?null:function(P){var R=window.hljs.highlightAuto(P);return R.value}})(),interval:1e3},o.CodeBlock=E,o.CodeToken=x,o.default=k}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'}),(function(r,o){r.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'}),(function(r,o){r.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'}),(function(r,o){r.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'}),(function(r,o){r.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'}),(function(r,o){r.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'}),(function(r,o,i){Object.defineProperty(o,"__esModule",{value:!0}),o.default=o.BubbleTooltip=void 0;var l=function R(j,z,L){j===null&&(j=Function.prototype);var M=Object.getOwnPropertyDescriptor(j,z);if(M===void 0){var D=Object.getPrototypeOf(j);return D===null?void 0:R(D,z,L)}else{if("value"in M)return M.value;var F=M.get;return F===void 0?void 0:F.call(L)}},c=(function(){function R(j,z){for(var L=0;L<z.length;L++){var M=z[L];M.enumerable=M.enumerable||!1,M.configurable=!0,"value"in M&&(M.writable=!0),Object.defineProperty(j,M.key,M)}}return function(j,z,L){return z&&R(j.prototype,z),L&&R(j,L),j}})(),f=i(3),m=_(f),g=i(8),d=_(g),p=i(43),h=_(p),s=i(15),S=i(41),b=_(S);function _(R){return R&&R.__esModule?R:{default:R}}function w(R,j){if(!(R instanceof j))throw new TypeError("Cannot call a class as a function")}function y(R,j){if(!R)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return j&&(typeof j=="object"||typeof j=="function")?j:R}function E(R,j){if(typeof j!="function"&&j!==null)throw new TypeError("Super expression must either be null or a function, not "+typeof j);R.prototype=Object.create(j&&j.prototype,{constructor:{value:R,enumerable:!1,writable:!0,configurable:!0}}),j&&(Object.setPrototypeOf?Object.setPrototypeOf(R,j):R.__proto__=j)}var x=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],k=(function(R){E(j,R);function j(z,L){w(this,j),L.modules.toolbar!=null&&L.modules.toolbar.container==null&&(L.modules.toolbar.container=x);var M=y(this,(j.__proto__||Object.getPrototypeOf(j)).call(this,z,L));return M.quill.container.classList.add("ql-bubble"),M}return c(j,[{key:"extendToolbar",value:function(L){this.tooltip=new P(this.quill,this.options.bounds),this.tooltip.root.appendChild(L.container),this.buildButtons([].slice.call(L.container.querySelectorAll("button")),b.default),this.buildPickers([].slice.call(L.container.querySelectorAll("select")),b.default)}}]),j})(h.default);k.DEFAULTS=(0,m.default)(!0,{},h.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(j){j?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var P=(function(R){E(j,R);function j(z,L){w(this,j);var M=y(this,(j.__proto__||Object.getPrototypeOf(j)).call(this,z,L));return M.quill.on(d.default.events.EDITOR_CHANGE,function(D,F,B,U){if(D===d.default.events.SELECTION_CHANGE)if(F!=null&&F.length>0&&U===d.default.sources.USER){M.show(),M.root.style.left="0px",M.root.style.width="",M.root.style.width=M.root.offsetWidth+"px";var J=M.quill.getLines(F.index,F.length);if(J.length===1)M.position(M.quill.getBounds(F));else{var oe=J[J.length-1],de=M.quill.getIndex(oe),Y=Math.min(oe.length()-1,F.index+F.length-de),ee=M.quill.getBounds(new s.Range(de,Y));M.position(ee)}}else document.activeElement!==M.textbox&&M.quill.hasFocus()&&M.hide()}),M}return c(j,[{key:"listen",value:function(){var L=this;l(j.prototype.__proto__||Object.getPrototypeOf(j.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",function(){L.root.classList.remove("ql-editing")}),this.quill.on(d.default.events.SCROLL_OPTIMIZE,function(){setTimeout(function(){if(!L.root.classList.contains("ql-hidden")){var M=L.quill.getSelection();M!=null&&L.position(L.quill.getBounds(M))}},1)})}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(L){var M=l(j.prototype.__proto__||Object.getPrototypeOf(j.prototype),"position",this).call(this,L),D=this.root.querySelector(".ql-tooltip-arrow");if(D.style.marginLeft="",M===0)return M;D.style.marginLeft=-1*M-D.offsetWidth/2+"px"}}]),j})(p.BaseTooltip);P.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),o.BubbleTooltip=P,o.default=k}),(function(r,o,i){r.exports=i(63)})]).default})})(ul)),ul.exports}var rr,GO;function R4(){if(GO)return rr;GO=1;var e=rr&&rr.__extends||(function(){var d=function(p,h){return d=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(s,S){s.__proto__=S}||function(s,S){for(var b in S)S.hasOwnProperty(b)&&(s[b]=S[b])},d(p,h)};return function(p,h){d(p,h);function s(){this.constructor=p}p.prototype=h===null?Object.create(h):(s.prototype=h.prototype,new s)}})(),n=rr&&rr.__assign||function(){return n=Object.assign||function(d){for(var p,h=1,s=arguments.length;h<s;h++){p=arguments[h];for(var S in p)Object.prototype.hasOwnProperty.call(p,S)&&(d[S]=p[S])}return d},n.apply(this,arguments)},r=rr&&rr.__spreadArrays||function(){for(var d=0,p=0,h=arguments.length;p<h;p++)d+=arguments[p].length;for(var s=Array(d),S=0,p=0;p<h;p++)for(var b=arguments[p],_=0,w=b.length;_<w;_++,S++)s[S]=b[_];return s},o=rr&&rr.__importDefault||function(d){return d&&d.__esModule?d:{default:d}},i=o(wt.default),l=o(uy.default),c=o(A4()),f=o(T4()),m=(function(d){e(p,d);function p(h){var s=d.call(this,h)||this;s.dirtyProps=["modules","formats","bounds","theme","children"],s.cleanProps=["id","className","style","placeholder","tabIndex","onChange","onChangeSelection","onFocus","onBlur","onKeyPress","onKeyDown","onKeyUp"],s.state={generation:0},s.selection=null,s.onEditorChange=function(b,_,w,y){var E,x,k,P;b==="text-change"?(x=(E=s).onEditorChangeText)===null||x===void 0||x.call(E,s.editor.root.innerHTML,_,y,s.unprivilegedEditor):b==="selection-change"&&((P=(k=s).onEditorChangeSelection)===null||P===void 0||P.call(k,_,y,s.unprivilegedEditor))};var S=s.isControlled()?h.value:h.defaultValue;return s.value=S??"",s}return p.prototype.validateProps=function(h){var s;if(i.default.Children.count(h.children)>1)throw new Error("The Quill editing area can only be composed of a single React element.");if(i.default.Children.count(h.children)){var S=i.default.Children.only(h.children);if(((s=S)===null||s===void 0?void 0:s.type)==="textarea")throw new Error("Quill does not support editing on a <textarea>. Use a <div> instead.")}if(this.lastDeltaChangeSet&&h.value===this.lastDeltaChangeSet)throw new Error("You are passing the `delta` object from the `onChange` event back as `value`. You most probably want `editor.getContents()` instead. See: https://github.com/zenoamaro/react-quill#using-deltas")},p.prototype.shouldComponentUpdate=function(h,s){var S=this,b;if(this.validateProps(h),!this.editor||this.state.generation!==s.generation)return!0;if("value"in h){var _=this.getEditorContents(),w=(b=h.value,b??"");this.isEqualValue(w,_)||this.setEditorContents(this.editor,w)}return h.readOnly!==this.props.readOnly&&this.setEditorReadOnly(this.editor,h.readOnly),r(this.cleanProps,this.dirtyProps).some(function(y){return!c.default(h[y],S.props[y])})},p.prototype.shouldComponentRegenerate=function(h){var s=this;return this.dirtyProps.some(function(S){return!c.default(h[S],s.props[S])})},p.prototype.componentDidMount=function(){this.instantiateEditor(),this.setEditorContents(this.editor,this.getEditorContents())},p.prototype.componentWillUnmount=function(){this.destroyEditor()},p.prototype.componentDidUpdate=function(h,s){var S=this;if(this.editor&&this.shouldComponentRegenerate(h)){var b=this.editor.getContents(),_=this.editor.getSelection();this.regenerationSnapshot={delta:b,selection:_},this.setState({generation:this.state.generation+1}),this.destroyEditor()}if(this.state.generation!==s.generation){var w=this.regenerationSnapshot,b=w.delta,y=w.selection;delete this.regenerationSnapshot,this.instantiateEditor();var E=this.editor;E.setContents(b),g(function(){return S.setEditorSelection(E,y)})}},p.prototype.instantiateEditor=function(){this.editor?this.hookEditor(this.editor):this.editor=this.createEditor(this.getEditingArea(),this.getEditorConfig())},p.prototype.destroyEditor=function(){this.editor&&this.unhookEditor(this.editor)},p.prototype.isControlled=function(){return"value"in this.props},p.prototype.getEditorConfig=function(){return{bounds:this.props.bounds,formats:this.props.formats,modules:this.props.modules,placeholder:this.props.placeholder,readOnly:this.props.readOnly,scrollingContainer:this.props.scrollingContainer,tabIndex:this.props.tabIndex,theme:this.props.theme}},p.prototype.getEditor=function(){if(!this.editor)throw new Error("Accessing non-instantiated editor");return this.editor},p.prototype.createEditor=function(h,s){var S=new f.default(h,s);return s.tabIndex!=null&&this.setEditorTabIndex(S,s.tabIndex),this.hookEditor(S),S},p.prototype.hookEditor=function(h){this.unprivilegedEditor=this.makeUnprivilegedEditor(h),h.on("editor-change",this.onEditorChange)},p.prototype.unhookEditor=function(h){h.off("editor-change",this.onEditorChange)},p.prototype.getEditorContents=function(){return this.value},p.prototype.getEditorSelection=function(){return this.selection},p.prototype.isDelta=function(h){return h&&h.ops},p.prototype.isEqualValue=function(h,s){return this.isDelta(h)&&this.isDelta(s)?c.default(h.ops,s.ops):c.default(h,s)},p.prototype.setEditorContents=function(h,s){var S=this;this.value=s;var b=this.getEditorSelection();typeof s=="string"?h.setContents(h.clipboard.convert(s)):h.setContents(s),g(function(){return S.setEditorSelection(h,b)})},p.prototype.setEditorSelection=function(h,s){if(this.selection=s,s){var S=h.getLength();s.index=Math.max(0,Math.min(s.index,S-1)),s.length=Math.max(0,Math.min(s.length,S-1-s.index)),h.setSelection(s)}},p.prototype.setEditorTabIndex=function(h,s){var S,b;!((b=(S=h)===null||S===void 0?void 0:S.scroll)===null||b===void 0)&&b.domNode&&(h.scroll.domNode.tabIndex=s)},p.prototype.setEditorReadOnly=function(h,s){s?h.disable():h.enable()},p.prototype.makeUnprivilegedEditor=function(h){var s=h;return{getHTML:function(){return s.root.innerHTML},getLength:s.getLength.bind(s),getText:s.getText.bind(s),getContents:s.getContents.bind(s),getSelection:s.getSelection.bind(s),getBounds:s.getBounds.bind(s)}},p.prototype.getEditingArea=function(){if(!this.editingArea)throw new Error("Instantiating on missing editing area");var h=l.default.findDOMNode(this.editingArea);if(!h)throw new Error("Cannot find element for editing area");if(h.nodeType===3)throw new Error("Editing area cannot be a text node");return h},p.prototype.renderEditingArea=function(){var h=this,s=this.props,S=s.children,b=s.preserveWhitespace,_=this.state.generation,w={key:_,ref:function(y){h.editingArea=y}};return i.default.Children.count(S)?i.default.cloneElement(i.default.Children.only(S),w):b?i.default.createElement("pre",n({},w)):i.default.createElement("div",n({},w))},p.prototype.render=function(){var h;return i.default.createElement("div",{id:this.props.id,style:this.props.style,key:this.state.generation,className:"quill "+(h=this.props.className,h??""),onKeyPress:this.props.onKeyPress,onKeyDown:this.props.onKeyDown,onKeyUp:this.props.onKeyUp},this.renderEditingArea())},p.prototype.onEditorChangeText=function(h,s,S,b){var _,w;if(this.editor){var y=this.isDelta(this.value)?b.getContents():b.getHTML();y!==this.getEditorContents()&&(this.lastDeltaChangeSet=s,this.value=y,(w=(_=this.props).onChange)===null||w===void 0||w.call(_,h,s,S,b))}},p.prototype.onEditorChangeSelection=function(h,s,S){var b,_,w,y,E,x;if(this.editor){var k=this.getEditorSelection(),P=!k&&h,R=k&&!h;c.default(h,k)||(this.selection=h,(_=(b=this.props).onChangeSelection)===null||_===void 0||_.call(b,h,s,S),P?(y=(w=this.props).onFocus)===null||y===void 0||y.call(w,h,s,S):R&&((x=(E=this.props).onBlur)===null||x===void 0||x.call(E,k,s,S)))}},p.prototype.focus=function(){this.editor&&this.editor.focus()},p.prototype.blur=function(){this.editor&&(this.selection=null,this.editor.blur())},p.displayName="React Quill",p.Quill=f.default,p.defaultProps={theme:"snow",modules:{},readOnly:!1},p})(i.default.Component);function g(d){Promise.resolve().then(d)}return rr=m,rr}var P4=R4();const I4=Iu(P4),M4=({isOpen:e,onClose:n,refresh:r,handleUpdate:o})=>{const{node:i,certificate:l}=Ot(),{restrictedAssets:c}=l,f=c?c[i.id]:void 0,m={restrictionNotes:f?f.restrictionNotes:"",restrictionInstructions:f?f.restrictionInstructions:""},[g,d]=he.useState(m),[p,h]=he.useState(!1),[s,S]=he.useState(!1);he.useEffect(()=>{d(m)},[f]);const b=()=>{d(m),h(!1),n()},_=async()=>{h(!0),o({restrictedAssets:D3(i.id,c)}).then(y=>{y?.status===200?(ct.success("Successfully removed restrictions!"),h(!1),S(!1),n(),r()):h(!1)}).catch(y=>{h(!1),ct.error(`Request failed, ${y.toString()}`)})},w=async()=>{if(g.restrictionInstructions.length<1||g.restrictionNotes.length<1)return;h(!0);const y={[i.id]:g};o({restrictedAssets:{...c,...y}}).then(E=>{E?.status===200?(ct.success("Asset has been successfully restricted!"),h(!1),n(),d(m),r()):(h(!1),ct.error("Request failed..."))}).catch(E=>{h(!1),ct.error(`Request failed, ${E.toString()}`)})};return K.jsxs(K.Fragment,{children:[K.jsx(ht.ConfirmationModal,{id:"restrict-removal-confirmation",isOpen:s,onClose:()=>S(!1),onSubmit:_,submitButtonText:"Confirm",pending:p,headerContent:"Do you confirm the removal of restrictions for this node?"}),K.jsx(ht.ConfirmationModal,{id:"restrict-single-node-modal",isOpen:e,onClose:n,size:"lg",headerContent:"Change Node Restrictions",noSubmit:!0,noCancel:!0,disabled:p,content:K.jsxs(K.Fragment,{children:[K.jsx(ht.ResourceEditor,{className:"",onChange:y=>d(y),editedResource:g,controls:[L3()]}),K.jsxs("div",{className:"col-12",children:[K.jsx("label",{children:"Instructions for Retrieval - Guest Users"}),K.jsx(I4,{id:"restriction-instructions-editor",theme:"snow",value:g.restrictionInstructions,onChange:y=>{d(E=>({...E,restrictionInstructions:y}))}})]}),K.jsxs("div",{className:"float-right mt-3 d-flex flex-wrap",style:{gap:"0.5rem",padding:"0 15px"},children:[K.jsx(ht.Button,{onClick:b,children:"Cancel"}),f&&K.jsx(ht.Button,{color:"danger",onClick:()=>S(!0),pending:p,children:"Remove Restrictions"}),K.jsxs(ht.Button,{color:"primary",onClick:w,pending:p,children:[f&&"Update Restrictions",!f&&"Restrict"]})]})]})})]})},j4=({certificate:e,handleUpdate:n,refresh:r})=>{const[o,i]=he.useState(!1),l=()=>i(!o),[c,f]=he.useState(!1),m=()=>f(!c),g="reviewNode",d={toggleReviewModal:l,toggleMetadataModal:m},p=al(e.vertices,e.edges,e.restrictedAssets,g,d);return K.jsxs(ll,{type:g,certificate:e,graph:p,children:[K.jsx(M4,{isOpen:o,onClose:l,refresh:r,handleUpdate:n}),K.jsx(vg,{isOpen:c,toggle:m})]})},L4=({certificate:e,replica:n,refresh:r})=>{const[o,i]=he.useState(!1),l=()=>i(!o);if(cr(e)||$t(e)||cr(n)||$t(n))return;const c="fileLayerNode",f={refresh:r,toggleMetadataModal:l},m=AO(e.vertices,e.edges,n,f);return K.jsx(ll,{type:c,certificate:e,replica:n,graph:m,children:K.jsx(vg,{isOpen:o,toggle:l})})},D4=({setIsLayersItemModalOpen:e})=>{const{node:n}=Ot();if(!n?.id)return null;const[r,o]=n.id.split("/"),i=()=>{let l=[{key:"view-btn",label:"View Item",onClick:()=>window.open(E4(n.id),"_blank")},{key:"copy-id-btn",label:"Copy Item ID",onClick:()=>navigator.clipboard.writeText(o)}];return r.includes("Layer")&&(l=[...l,{key:"open-layer-btn",label:"Open Layer",onClick:()=>e(!0)}]),l.map(c=>K.jsx("li",{children:K.jsx(ht.Button,{color:"secondary",className:"w-100 my-1 btn-sm",sx:{whiteSpace:"nowrap"},onClick:c.onClick,children:c.label},c.key)}))};return K.jsx("div",{className:"position-absolute border border-secondary border-4 top-0 end-0 m-3 p-2",children:K.jsx("ul",{className:"list-unstyled mb-0 text-end",children:i()})})},B4=({isOpen:e,setIsOpen:n})=>{const{node:r,setNode:o,certificate:i,nodesState:l,edgesState:c,nodeLayers:f,setNodeLayers:m}=Ot(),[,g]=l,[,d]=c,p=i.subgraphs[r.id],h=(_,w)=>_.reduce((y,E)=>E.id===r.id?[...y,{...E,id:w}]:[...y,E],[]),s=(_,w)=>_.reduce((y,E)=>{if(E.id.includes(r.id)){const x=E.source===r.id;return[...y,{id:`${E.id}-${w}`,source:x?w:E.source,target:x?E.target:w,animated:!0}]}return[...y,E]},[]),S=_=>{n(!1),o({});const w=h(f.current.nodes,_),y=s(f.current.edges,_);g(w),d(y),m({...f,current:{nodes:w,edges:y}})},b=()=>{if(!p)return null;const _=Object.keys(p.vertices);return K.jsxs(K.Fragment,{children:[K.jsx("h3",{children:"Select an item in the list from this grouping to continue tracing."}),K.jsx("ul",{children:_.map(w=>K.jsx("li",{children:K.jsx(ht.Button,{color:"link",className:"btn-sm text-wrap",style:{textAlign:"left"},onClick:()=>S(w),children:i.generatedLabels[w].Name})}))})]})};return K.jsx(ht.ConfirmationModal,{id:"layer-items-modal",className:"top-25",isOpen:e,onClose:()=>n(!1),cancelButtonText:"Close",noSubmit:!0,headerContent:r.id,content:b()})},F4=({certificate:e,graph:n})=>{const{nodesState:r,edgesState:o,nodeLayers:i,setNodeLayers:l}=Ot(),c=he.useMemo(()=>({walkingNode:VO}),[]),[,f,m]=r,[,g,d]=o,[p,h]=he.useState(!1);he.useEffect(()=>{cr(e)||$t(e)||(f(n.nodes),g(n.edges),l({previous:i.previous,current:{nodes:n.nodes,edges:n.edges}}))},[e]);const s=S=>{setTimeout(()=>{S.fitView(),S.zoomTo(.5,{duration:1e3})},100)};return K.jsxs("div",{style:{height:"75vh",position:"relative"},children:[K.jsx("div",{className:"layoutflow",children:K.jsxs(ug,{nodes:i.current.nodes,edges:i.current.edges,onNodesChange:m,onEdgesChange:d,connectionLineType:hr.SmoothStep,nodeTypes:c,onlyRenderVisibleElements:!0,edgesUpdatable:!1,onInit:s,children:[K.jsx(rO,{}),K.jsx(iO,{}),K.jsx(tO,{})]})}),K.jsx(D4,{setIsLayersItemModalOpen:h}),K.jsx(B4,{setIsOpen:h,isOpen:p})]})},q4=({certificate:e})=>{const n=zO([],e.vertices,e,!1),r=HO([],e.edges),o=qO(n,r);return K.jsx(hO,{type:"walkingNode",certificate:e,children:K.jsx(F4,{certificate:e,graph:o})})},Eg=e=>e?e!=="ffffffff-ffff-ffff-ffff-ffffffffffff":!1,z4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/${e}`,H4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/labels/${e}`,V4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/metadata/${e}`,U4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/schemes/${e}`,W4=async(e,n,r=!0,o)=>{const i=await fetch(z4(e,n,r),{credentials:"include"});o&&o(i);const l=await i.json();if(i.status!==200)throw Error(l.Message);let c={...l};const{labelsId:f,metadataId:m,schemesId:g}=l;if(Eg(f)){const p=await(await fetch(H4(f,n,r),{credentials:"include"})).json();c={...c,customLabels:p.customLabels,generatedLabels:p.generatedLabels,serviceLabels:p.serviceLabels}}if(Eg(m)){const p=await(await fetch(V4(m,n,r),{credentials:"include"})).json();c={...c,metadata:p.metadata}}if(Eg(g)){const p=await(await fetch(U4(g,n,r),{credentials:"include"})).json();c={...c,schemes:p.schemes}}return c};It.EditCertificate=C4,It.EditNodeModal=IO,It.HiseConfigProvider=R3,It.IDEModal=BO,It.MaskMetadataModal=PO,It.PipelineModal=LO,It.ReadCertificate=k4,It.ReplicaPipelineInfo=jO,It.ReviewCertificate=j4,It.WalkingGraph=q4,It.WorkspaceCertificate=L4,It.getCertificateBody=W4,It.getSchemes=xO,It.startIDE=FO,It.startPipeline=DO,It.useHiseConfig=Rr,Object.defineProperty(It,Symbol.toStringTag,{value:"Module"})}));
|