hise-flow-graphs 1.1.23 → 1.1.24
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/index.umd.js +44 -44
- package/package.json +1 -1
- package/vite.config.ts +1 -2
package/dist/index.umd.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
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={};/**
|
|
1
|
+
(function(Pt,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):(Pt=typeof globalThis<"u"?globalThis:Pt||self,K(Pt["hise-flow-graphs"]={},Pt.require$$2,Pt.React,Pt.ReactDOM,Pt.require$$1))})(this,(function(Pt,K,ce,sy,YN){"use strict";var ns=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Ru(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Pu(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 Iu,ly;function XN(){if(ly)return Iu;ly=1;function e(){this.__data__=[],this.size=0}return Iu=e,Iu}var Mu,uy;function Lo(){if(uy)return Mu;uy=1;function e(n,r){return n===r||n!==n&&r!==r}return Mu=e,Mu}var ju,cy;function rs(){if(cy)return ju;cy=1;var e=Lo();function n(r,o){for(var i=r.length;i--;)if(e(r[i][0],o))return i;return-1}return ju=n,ju}var Lu,fy;function ZN(){if(fy)return Lu;fy=1;var e=rs(),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 Lu=o,Lu}var Du,dy;function QN(){if(dy)return Du;dy=1;var e=rs();function n(r){var o=this.__data__,i=e(o,r);return i<0?void 0:o[i][1]}return Du=n,Du}var Bu,hy;function JN(){if(hy)return Bu;hy=1;var e=rs();function n(r){return e(this.__data__,r)>-1}return Bu=n,Bu}var Fu,py;function $N(){if(py)return Fu;py=1;var e=rs();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 Fu=n,Fu}var qu,my;function os(){if(my)return qu;my=1;var e=XN(),n=ZN(),r=QN(),o=JN(),i=$N();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,qu=l,qu}var zu,gy;function eT(){if(gy)return zu;gy=1;var e=os();function n(){this.__data__=new e,this.size=0}return zu=n,zu}var Hu,vy;function tT(){if(vy)return Hu;vy=1;function e(n){var r=this.__data__,o=r.delete(n);return this.size=r.size,o}return Hu=e,Hu}var Vu,yy;function nT(){if(yy)return Vu;yy=1;function e(n){return this.__data__.get(n)}return Vu=e,Vu}var Uu,by;function rT(){if(by)return Uu;by=1;function e(n){return this.__data__.has(n)}return Uu=e,Uu}var Wu,wy;function xy(){if(wy)return Wu;wy=1;var e=typeof ns=="object"&&ns&&ns.Object===Object&&ns;return Wu=e,Wu}var Gu,_y;function Zn(){if(_y)return Gu;_y=1;var e=xy(),n=typeof self=="object"&&self&&self.Object===Object&&self,r=e||n||Function("return this")();return Gu=r,Gu}var Ku,Sy;function Do(){if(Sy)return Ku;Sy=1;var e=Zn(),n=e.Symbol;return Ku=n,Ku}var Yu,Ey;function oT(){if(Ey)return Yu;Ey=1;var e=Do(),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 Yu=l,Yu}var Xu,Oy;function iT(){if(Oy)return Xu;Oy=1;var e=Object.prototype,n=e.toString;function r(o){return n.call(o)}return Xu=r,Xu}var Zu,ky;function lo(){if(ky)return Zu;ky=1;var e=Do(),n=oT(),r=iT(),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 Zu=c,Zu}var Qu,Cy;function Pn(){if(Cy)return Qu;Cy=1;function e(n){var r=typeof n;return n!=null&&(r=="object"||r=="function")}return Qu=e,Qu}var Ju,Ay;function Li(){if(Ay)return Ju;Ay=1;var e=lo(),n=Pn(),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 Ju=c,Ju}var $u,Ny;function aT(){if(Ny)return $u;Ny=1;var e=Zn(),n=e["__core-js_shared__"];return $u=n,$u}var ec,Ty;function sT(){if(Ty)return ec;Ty=1;var e=aT(),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 ec=r,ec}var tc,Ry;function Py(){if(Ry)return tc;Ry=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 tc=r,tc}var nc,Iy;function lT(){if(Iy)return nc;Iy=1;var e=Li(),n=sT(),r=Pn(),o=Py(),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 nc=p,nc}var rc,My;function uT(){if(My)return rc;My=1;function e(n,r){return n?.[r]}return rc=e,rc}var oc,jy;function uo(){if(jy)return oc;jy=1;var e=lT(),n=uT();function r(o,i){var l=n(o,i);return e(l)?l:void 0}return oc=r,oc}var ic,Ly;function ac(){if(Ly)return ic;Ly=1;var e=uo(),n=Zn(),r=e(n,"Map");return ic=r,ic}var sc,Dy;function is(){if(Dy)return sc;Dy=1;var e=uo(),n=e(Object,"create");return sc=n,sc}var lc,By;function cT(){if(By)return lc;By=1;var e=is();function n(){this.__data__=e?e(null):{},this.size=0}return lc=n,lc}var uc,Fy;function fT(){if(Fy)return uc;Fy=1;function e(n){var r=this.has(n)&&delete this.__data__[n];return this.size-=r?1:0,r}return uc=e,uc}var cc,qy;function dT(){if(qy)return cc;qy=1;var e=is(),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 cc=i,cc}var fc,zy;function hT(){if(zy)return fc;zy=1;var e=is(),n=Object.prototype,r=n.hasOwnProperty;function o(i){var l=this.__data__;return e?l[i]!==void 0:r.call(l,i)}return fc=o,fc}var dc,Hy;function pT(){if(Hy)return dc;Hy=1;var e=is(),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 dc=r,dc}var hc,Vy;function mT(){if(Vy)return hc;Vy=1;var e=cT(),n=fT(),r=dT(),o=hT(),i=pT();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,hc=l,hc}var pc,Uy;function gT(){if(Uy)return pc;Uy=1;var e=mT(),n=os(),r=ac();function o(){this.size=0,this.__data__={hash:new e,map:new(r||n),string:new e}}return pc=o,pc}var mc,Wy;function vT(){if(Wy)return mc;Wy=1;function e(n){var r=typeof n;return r=="string"||r=="number"||r=="symbol"||r=="boolean"?n!=="__proto__":n===null}return mc=e,mc}var gc,Gy;function as(){if(Gy)return gc;Gy=1;var e=vT();function n(r,o){var i=r.__data__;return e(o)?i[typeof o=="string"?"string":"hash"]:i.map}return gc=n,gc}var vc,Ky;function yT(){if(Ky)return vc;Ky=1;var e=as();function n(r){var o=e(this,r).delete(r);return this.size-=o?1:0,o}return vc=n,vc}var yc,Yy;function bT(){if(Yy)return yc;Yy=1;var e=as();function n(r){return e(this,r).get(r)}return yc=n,yc}var bc,Xy;function wT(){if(Xy)return bc;Xy=1;var e=as();function n(r){return e(this,r).has(r)}return bc=n,bc}var wc,Zy;function xT(){if(Zy)return wc;Zy=1;var e=as();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 wc=n,wc}var xc,Qy;function _c(){if(Qy)return xc;Qy=1;var e=gT(),n=yT(),r=bT(),o=wT(),i=xT();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,xc=l,xc}var Sc,Jy;function _T(){if(Jy)return Sc;Jy=1;var e=os(),n=ac(),r=_c(),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 Sc=i,Sc}var Ec,$y;function ss(){if($y)return Ec;$y=1;var e=os(),n=eT(),r=tT(),o=nT(),i=rT(),l=_T();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,Ec=c,Ec}var Oc,eb;function kc(){if(eb)return Oc;eb=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 Oc=e,Oc}var Cc,tb;function nb(){if(tb)return Cc;tb=1;var e=uo(),n=(function(){try{var r=e(Object,"defineProperty");return r({},"",{}),r}catch{}})();return Cc=n,Cc}var Ac,rb;function ls(){if(rb)return Ac;rb=1;var e=nb();function n(r,o,i){o=="__proto__"&&e?e(r,o,{configurable:!0,enumerable:!0,value:i,writable:!0}):r[o]=i}return Ac=n,Ac}var Nc,ob;function us(){if(ob)return Nc;ob=1;var e=ls(),n=Lo(),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 Nc=i,Nc}var Tc,ib;function Di(){if(ib)return Tc;ib=1;var e=us(),n=ls();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 Tc=r,Tc}var Rc,ab;function ST(){if(ab)return Rc;ab=1;function e(n,r){for(var o=-1,i=Array(n);++o<n;)i[o]=r(o);return i}return Rc=e,Rc}var Pc,sb;function lr(){if(sb)return Pc;sb=1;function e(n){return n!=null&&typeof n=="object"}return Pc=e,Pc}var Ic,lb;function ET(){if(lb)return Ic;lb=1;var e=lo(),n=lr(),r="[object Arguments]";function o(i){return n(i)&&e(i)==r}return Ic=o,Ic}var Mc,ub;function Bi(){if(ub)return Mc;ub=1;var e=ET(),n=lr(),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 Mc=l,Mc}var jc,cb;function Gt(){if(cb)return jc;cb=1;var e=Array.isArray;return jc=e,jc}var Fi={exports:{}},Lc,fb;function OT(){if(fb)return Lc;fb=1;function e(){return!1}return Lc=e,Lc}Fi.exports;var db;function Bo(){return db||(db=1,(function(e,n){var r=Zn(),o=OT(),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})(Fi,Fi.exports)),Fi.exports}var Dc,hb;function cs(){if(hb)return Dc;hb=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 Dc=r,Dc}var Bc,pb;function Fc(){if(pb)return Bc;pb=1;var e=9007199254740991;function n(r){return typeof r=="number"&&r>-1&&r%1==0&&r<=e}return Bc=n,Bc}var qc,mb;function kT(){if(mb)return qc;mb=1;var e=lo(),n=Fc(),r=lr(),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 qc=D,qc}var zc,gb;function fs(){if(gb)return zc;gb=1;function e(n){return function(r){return n(r)}}return zc=e,zc}var qi={exports:{}};qi.exports;var vb;function Hc(){return vb||(vb=1,(function(e,n){var r=xy(),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})(qi,qi.exports)),qi.exports}var Vc,yb;function zi(){if(yb)return Vc;yb=1;var e=kT(),n=fs(),r=Hc(),o=r&&r.isTypedArray,i=o?n(o):e;return Vc=i,Vc}var Uc,bb;function wb(){if(bb)return Uc;bb=1;var e=ST(),n=Bi(),r=Gt(),o=Bo(),i=cs(),l=zi(),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 Uc=m,Uc}var Wc,xb;function ds(){if(xb)return Wc;xb=1;var e=Object.prototype;function n(r){var o=r&&r.constructor,i=typeof o=="function"&&o.prototype||e;return r===i}return Wc=n,Wc}var Gc,_b;function Sb(){if(_b)return Gc;_b=1;function e(n,r){return function(o){return n(r(o))}}return Gc=e,Gc}var Kc,Eb;function CT(){if(Eb)return Kc;Eb=1;var e=Sb(),n=e(Object.keys,Object);return Kc=n,Kc}var Yc,Ob;function Xc(){if(Ob)return Yc;Ob=1;var e=ds(),n=CT(),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 Yc=i,Yc}var Zc,kb;function _r(){if(kb)return Zc;kb=1;var e=Li(),n=Fc();function r(o){return o!=null&&n(o.length)&&!e(o)}return Zc=r,Zc}var Qc,Cb;function Wr(){if(Cb)return Qc;Cb=1;var e=wb(),n=Xc(),r=_r();function o(i){return r(i)?e(i):n(i)}return Qc=o,Qc}var Jc,Ab;function AT(){if(Ab)return Jc;Ab=1;var e=Di(),n=Wr();function r(o,i){return o&&e(i,n(i),o)}return Jc=r,Jc}var $c,Nb;function NT(){if(Nb)return $c;Nb=1;function e(n){var r=[];if(n!=null)for(var o in Object(n))r.push(o);return r}return $c=e,$c}var ef,Tb;function TT(){if(Tb)return ef;Tb=1;var e=Pn(),n=ds(),r=NT(),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 ef=l,ef}var tf,Rb;function co(){if(Rb)return tf;Rb=1;var e=wb(),n=TT(),r=_r();function o(i){return r(i)?e(i,!0):n(i)}return tf=o,tf}var nf,Pb;function RT(){if(Pb)return nf;Pb=1;var e=Di(),n=co();function r(o,i){return o&&e(i,n(i),o)}return nf=r,nf}var Hi={exports:{}};Hi.exports;var Ib;function Mb(){return Ib||(Ib=1,(function(e,n){var r=Zn(),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})(Hi,Hi.exports)),Hi.exports}var rf,jb;function Lb(){if(jb)return rf;jb=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 rf=e,rf}var of,Db;function Bb(){if(Db)return of;Db=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 of=e,of}var af,Fb;function qb(){if(Fb)return af;Fb=1;function e(){return[]}return af=e,af}var sf,zb;function lf(){if(zb)return sf;zb=1;var e=Bb(),n=qb(),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 sf=l,sf}var uf,Hb;function PT(){if(Hb)return uf;Hb=1;var e=Di(),n=lf();function r(o,i){return e(o,n(o),i)}return uf=r,uf}var cf,Vb;function ff(){if(Vb)return cf;Vb=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 cf=e,cf}var df,Ub;function hs(){if(Ub)return df;Ub=1;var e=Sb(),n=e(Object.getPrototypeOf,Object);return df=n,df}var hf,Wb;function Gb(){if(Wb)return hf;Wb=1;var e=ff(),n=hs(),r=lf(),o=qb(),i=Object.getOwnPropertySymbols,l=i?function(c){for(var f=[];c;)e(f,r(c)),c=n(c);return f}:o;return hf=l,hf}var pf,Kb;function IT(){if(Kb)return pf;Kb=1;var e=Di(),n=Gb();function r(o,i){return e(o,n(o),i)}return pf=r,pf}var mf,Yb;function Xb(){if(Yb)return mf;Yb=1;var e=ff(),n=Gt();function r(o,i,l){var c=i(o);return n(o)?c:e(c,l(o))}return mf=r,mf}var gf,Zb;function Qb(){if(Zb)return gf;Zb=1;var e=Xb(),n=lf(),r=Wr();function o(i){return e(i,r,n)}return gf=o,gf}var vf,Jb;function MT(){if(Jb)return vf;Jb=1;var e=Xb(),n=Gb(),r=co();function o(i){return e(i,r,n)}return vf=o,vf}var yf,$b;function jT(){if($b)return yf;$b=1;var e=uo(),n=Zn(),r=e(n,"DataView");return yf=r,yf}var bf,e0;function LT(){if(e0)return bf;e0=1;var e=uo(),n=Zn(),r=e(n,"Promise");return bf=r,bf}var wf,t0;function n0(){if(t0)return wf;t0=1;var e=uo(),n=Zn(),r=e(n,"Set");return wf=r,wf}var xf,r0;function DT(){if(r0)return xf;r0=1;var e=uo(),n=Zn(),r=e(n,"WeakMap");return xf=r,xf}var _f,o0;function Fo(){if(o0)return _f;o0=1;var e=jT(),n=ac(),r=LT(),o=n0(),i=DT(),l=lo(),c=Py(),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}),_f=y,_f}var Sf,i0;function BT(){if(i0)return Sf;i0=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 Sf=r,Sf}var Ef,a0;function s0(){if(a0)return Ef;a0=1;var e=Zn(),n=e.Uint8Array;return Ef=n,Ef}var Of,l0;function kf(){if(l0)return Of;l0=1;var e=s0();function n(r){var o=new r.constructor(r.byteLength);return new e(o).set(new e(r)),o}return Of=n,Of}var Cf,u0;function FT(){if(u0)return Cf;u0=1;var e=kf();function n(r,o){var i=o?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.byteLength)}return Cf=n,Cf}var Af,c0;function qT(){if(c0)return Af;c0=1;var e=/\w*$/;function n(r){var o=new r.constructor(r.source,e.exec(r));return o.lastIndex=r.lastIndex,o}return Af=n,Af}var Nf,f0;function zT(){if(f0)return Nf;f0=1;var e=Do(),n=e?e.prototype:void 0,r=n?n.valueOf:void 0;function o(i){return r?Object(r.call(i)):{}}return Nf=o,Nf}var Tf,d0;function h0(){if(d0)return Tf;d0=1;var e=kf();function n(r,o){var i=o?e(r.buffer):r.buffer;return new r.constructor(i,r.byteOffset,r.length)}return Tf=n,Tf}var Rf,p0;function HT(){if(p0)return Rf;p0=1;var e=kf(),n=FT(),r=qT(),o=zT(),i=h0(),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 Rf=j,Rf}var Pf,m0;function g0(){if(m0)return Pf;m0=1;var e=Pn(),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 Pf=r,Pf}var If,v0;function y0(){if(v0)return If;v0=1;var e=g0(),n=hs(),r=ds();function o(i){return typeof i.constructor=="function"&&!r(i)?e(n(i)):{}}return If=o,If}var Mf,b0;function VT(){if(b0)return Mf;b0=1;var e=Fo(),n=lr(),r="[object Map]";function o(i){return n(i)&&e(i)==r}return Mf=o,Mf}var jf,w0;function UT(){if(w0)return jf;w0=1;var e=VT(),n=fs(),r=Hc(),o=r&&r.isMap,i=o?n(o):e;return jf=i,jf}var Lf,x0;function WT(){if(x0)return Lf;x0=1;var e=Fo(),n=lr(),r="[object Set]";function o(i){return n(i)&&e(i)==r}return Lf=o,Lf}var Df,_0;function GT(){if(_0)return Df;_0=1;var e=WT(),n=fs(),r=Hc(),o=r&&r.isSet,i=o?n(o):e;return Df=i,Df}var Bf,S0;function E0(){if(S0)return Bf;S0=1;var e=ss(),n=kc(),r=us(),o=AT(),i=RT(),l=Mb(),c=Lb(),f=PT(),m=IT(),g=Qb(),d=MT(),p=Fo(),h=BT(),s=HT(),S=y0(),b=Gt(),_=Bo(),w=UT(),y=Pn(),E=GT(),x=Wr(),k=co(),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]",he="[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[he]=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,It=we&j;if(xe&&(We=De?xe(Ce,Re,De,Ee):xe(Ce)),We!==void 0)return We;if(!y(Ce))return Ce;var Mt=b(Ce);if(Mt){if(We=h(Ce),!Qe)return c(Ce,We)}else{var pt=p(Ce),gn=pt==B||pt==U;if(_(Ce))return l(Ce,Qe);if(pt==he||pt==z||gn&&!De){if(We=ot||gn?{}: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(Kt){We.add(ut(Kt,we,xe,Kt,Ce,Ee))}):w(Ce)&&Ce.forEach(function(Kt,un){We.set(un,ut(Kt,we,xe,un,Ce,Ee))});var Tt=It?ot?d:g:ot?k:x,kn=Mt?void 0:Tt(Ce);return n(kn||Ce,function(Kt,un){kn&&(un=Kt,Kt=Ce[un]),r(We,un,ut(Kt,we,xe,un,Ce,Ee))}),We}return Bf=ut,Bf}var Ff,O0;function KT(){if(O0)return Ff;O0=1;var e=E0(),n=4;function r(o){return e(o,n)}return Ff=r,Ff}var qf,k0;function zf(){if(k0)return qf;k0=1;function e(n){return function(){return n}}return qf=e,qf}var Hf,C0;function YT(){if(C0)return Hf;C0=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 Hf=e,Hf}var Vf,A0;function Uf(){if(A0)return Vf;A0=1;var e=YT(),n=e();return Vf=n,Vf}var Wf,N0;function Gf(){if(N0)return Wf;N0=1;var e=Uf(),n=Wr();function r(o,i){return o&&e(o,i,n)}return Wf=r,Wf}var Kf,T0;function XT(){if(T0)return Kf;T0=1;var e=_r();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 Kf=n,Kf}var Yf,R0;function ps(){if(R0)return Yf;R0=1;var e=Gf(),n=XT(),r=n(e);return Yf=r,Yf}var Xf,P0;function fo(){if(P0)return Xf;P0=1;function e(n){return n}return Xf=e,Xf}var Zf,I0;function M0(){if(I0)return Zf;I0=1;var e=fo();function n(r){return typeof r=="function"?r:e}return Zf=n,Zf}var Qf,j0;function L0(){if(j0)return Qf;j0=1;var e=kc(),n=ps(),r=M0(),o=Gt();function i(l,c){var f=o(l)?e:n;return f(l,r(c))}return Qf=i,Qf}var Jf,D0;function B0(){return D0||(D0=1,Jf=L0()),Jf}var $f,F0;function ZT(){if(F0)return $f;F0=1;var e=ps();function n(r,o){var i=[];return e(r,function(l,c,f){o(l,c,f)&&i.push(l)}),i}return $f=n,$f}var ed,q0;function QT(){if(q0)return ed;q0=1;var e="__lodash_hash_undefined__";function n(r){return this.__data__.set(r,e),this}return ed=n,ed}var td,z0;function JT(){if(z0)return td;z0=1;function e(n){return this.__data__.has(n)}return td=e,td}var nd,H0;function V0(){if(H0)return nd;H0=1;var e=_c(),n=QT(),r=JT();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,nd=o,nd}var rd,U0;function $T(){if(U0)return rd;U0=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 rd=e,rd}var od,W0;function G0(){if(W0)return od;W0=1;function e(n,r){return n.has(r)}return od=e,od}var id,K0;function Y0(){if(K0)return id;K0=1;var e=V0(),n=$T(),r=G0(),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 id=l,id}var ad,X0;function eR(){if(X0)return ad;X0=1;function e(n){var r=-1,o=Array(n.size);return n.forEach(function(i,l){o[++r]=[l,i]}),o}return ad=e,ad}var sd,Z0;function ld(){if(Z0)return sd;Z0=1;function e(n){var r=-1,o=Array(n.size);return n.forEach(function(i){o[++r]=i}),o}return sd=e,sd}var ud,Q0;function tR(){if(Q0)return ud;Q0=1;var e=Do(),n=s0(),r=Lo(),o=Y0(),i=eR(),l=ld(),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 ud=k,ud}var cd,J0;function nR(){if(J0)return cd;J0=1;var e=Qb(),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 cd=i,cd}var fd,$0;function rR(){if($0)return fd;$0=1;var e=ss(),n=Y0(),r=tR(),o=nR(),i=Fo(),l=Gt(),c=Bo(),f=zi(),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 fd=S,fd}var dd,e1;function hd(){if(e1)return dd;e1=1;var e=rR(),n=lr();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 dd=r,dd}var pd,t1;function oR(){if(t1)return pd;t1=1;var e=ss(),n=hd(),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 pd=i,pd}var md,n1;function r1(){if(n1)return md;n1=1;var e=Pn();function n(r){return r===r&&!e(r)}return md=n,md}var gd,o1;function iR(){if(o1)return gd;o1=1;var e=r1(),n=Wr();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 gd=r,gd}var vd,i1;function a1(){if(i1)return vd;i1=1;function e(n,r){return function(o){return o==null?!1:o[n]===r&&(r!==void 0||n in Object(o))}}return vd=e,vd}var yd,s1;function aR(){if(s1)return yd;s1=1;var e=oR(),n=iR(),r=a1();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 yd=o,yd}var bd,l1;function qo(){if(l1)return bd;l1=1;var e=lo(),n=lr(),r="[object Symbol]";function o(i){return typeof i=="symbol"||n(i)&&e(i)==r}return bd=o,bd}var wd,u1;function xd(){if(u1)return wd;u1=1;var e=Gt(),n=qo(),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 wd=i,wd}var _d,c1;function sR(){if(c1)return _d;c1=1;var e=_c(),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,_d=r,_d}var Sd,f1;function lR(){if(f1)return Sd;f1=1;var e=sR(),n=500;function r(o){var i=e(o,function(c){return l.size===n&&l.clear(),c}),l=i.cache;return i}return Sd=r,Sd}var Ed,d1;function uR(){if(d1)return Ed;d1=1;var e=lR(),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 Ed=o,Ed}var Od,h1;function ms(){if(h1)return Od;h1=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 Od=e,Od}var kd,p1;function cR(){if(p1)return kd;p1=1;var e=Do(),n=ms(),r=Gt(),o=qo(),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 kd=c,kd}var Cd,m1;function g1(){if(m1)return Cd;m1=1;var e=cR();function n(r){return r==null?"":e(r)}return Cd=n,Cd}var Ad,v1;function gs(){if(v1)return Ad;v1=1;var e=Gt(),n=xd(),r=uR(),o=g1();function i(l,c){return e(l)?l:n(l,c)?[l]:r(o(l))}return Ad=i,Ad}var Nd,y1;function Vi(){if(y1)return Nd;y1=1;var e=qo();function n(r){if(typeof r=="string"||e(r))return r;var o=r+"";return o=="0"&&1/r==-1/0?"-0":o}return Nd=n,Nd}var Td,b1;function vs(){if(b1)return Td;b1=1;var e=gs(),n=Vi();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 Td=r,Td}var Rd,w1;function fR(){if(w1)return Rd;w1=1;var e=vs();function n(r,o,i){var l=r==null?void 0:e(r,o);return l===void 0?i:l}return Rd=n,Rd}var Pd,x1;function dR(){if(x1)return Pd;x1=1;function e(n,r){return n!=null&&r in Object(n)}return Pd=e,Pd}var Id,_1;function S1(){if(_1)return Id;_1=1;var e=gs(),n=Bi(),r=Gt(),o=cs(),i=Fc(),l=Vi();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 Id=c,Id}var Md,E1;function O1(){if(E1)return Md;E1=1;var e=dR(),n=S1();function r(o,i){return o!=null&&n(o,i,e)}return Md=r,Md}var jd,k1;function hR(){if(k1)return jd;k1=1;var e=hd(),n=fR(),r=O1(),o=xd(),i=r1(),l=a1(),c=Vi(),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 jd=g,jd}var Ld,C1;function A1(){if(C1)return Ld;C1=1;function e(n){return function(r){return r?.[n]}}return Ld=e,Ld}var Dd,N1;function pR(){if(N1)return Dd;N1=1;var e=vs();function n(r){return function(o){return e(o,r)}}return Dd=n,Dd}var Bd,T1;function mR(){if(T1)return Bd;T1=1;var e=A1(),n=pR(),r=xd(),o=Vi();function i(l){return r(l)?e(o(l)):n(l)}return Bd=i,Bd}var Fd,R1;function Sr(){if(R1)return Fd;R1=1;var e=aR(),n=hR(),r=fo(),o=Gt(),i=mR();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 Fd=l,Fd}var qd,P1;function I1(){if(P1)return qd;P1=1;var e=Bb(),n=ZT(),r=Sr(),o=Gt();function i(l,c){var f=o(l)?e:n;return f(l,r(c,3))}return qd=i,qd}var zd,M1;function gR(){if(M1)return zd;M1=1;var e=Object.prototype,n=e.hasOwnProperty;function r(o,i){return o!=null&&n.call(o,i)}return zd=r,zd}var Hd,j1;function L1(){if(j1)return Hd;j1=1;var e=gR(),n=S1();function r(o,i){return o!=null&&n(o,i,e)}return Hd=r,Hd}var Vd,D1;function vR(){if(D1)return Vd;D1=1;var e=Xc(),n=Fo(),r=Bi(),o=Gt(),i=_r(),l=Bo(),c=ds(),f=zi(),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 Vd=h,Vd}var Ud,B1;function F1(){if(B1)return Ud;B1=1;function e(n){return n===void 0}return Ud=e,Ud}var Wd,q1;function z1(){if(q1)return Wd;q1=1;var e=ps(),n=_r();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 Wd=r,Wd}var Gd,H1;function V1(){if(H1)return Gd;H1=1;var e=ms(),n=Sr(),r=z1(),o=Gt();function i(l,c){var f=o(l)?e:r;return f(l,n(c,3))}return Gd=i,Gd}var Kd,U1;function yR(){if(U1)return Kd;U1=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 Kd=e,Kd}var Yd,W1;function bR(){if(W1)return Yd;W1=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 Yd=e,Yd}var Xd,G1;function K1(){if(G1)return Xd;G1=1;var e=yR(),n=ps(),r=Sr(),o=bR(),i=Gt();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 Xd=l,Xd}var Zd,Y1;function wR(){if(Y1)return Zd;Y1=1;var e=lo(),n=Gt(),r=lr(),o="[object String]";function i(l){return typeof l=="string"||!n(l)&&r(l)&&e(l)==o}return Zd=i,Zd}var Qd,X1;function xR(){if(X1)return Qd;X1=1;var e=A1(),n=e("length");return Qd=n,Qd}var Jd,Z1;function _R(){if(Z1)return Jd;Z1=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 Jd=m,Jd}var $d,Q1;function SR(){if(Q1)return $d;Q1=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 $d=x,$d}var eh,J1;function ER(){if(J1)return eh;J1=1;var e=xR(),n=_R(),r=SR();function o(i){return n(i)?r(i):e(i)}return eh=o,eh}var th,$1;function OR(){if($1)return th;$1=1;var e=Xc(),n=Fo(),r=_r(),o=wR(),i=ER(),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 th=f,th}var nh,ew;function kR(){if(ew)return nh;ew=1;var e=kc(),n=g0(),r=Gf(),o=Sr(),i=hs(),l=Gt(),c=Bo(),f=Li(),m=Pn(),g=zi();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 nh=d,nh}var rh,tw;function CR(){if(tw)return rh;tw=1;var e=Do(),n=Bi(),r=Gt(),o=e?e.isConcatSpreadable:void 0;function i(l){return r(l)||n(l)||!!(o&&l&&l[o])}return rh=i,rh}var oh,nw;function ih(){if(nw)return oh;nw=1;var e=ff(),n=CR();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 oh=r,oh}var ah,rw;function AR(){if(rw)return ah;rw=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 ah=e,ah}var sh,ow;function iw(){if(ow)return sh;ow=1;var e=AR(),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 sh=r,sh}var lh,aw;function NR(){if(aw)return lh;aw=1;var e=zf(),n=nb(),r=fo(),o=n?function(i,l){return n(i,"toString",{configurable:!0,enumerable:!1,value:e(l),writable:!0})}:r;return lh=o,lh}var uh,sw;function TR(){if(sw)return uh;sw=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 uh=o,uh}var ch,lw;function uw(){if(lw)return ch;lw=1;var e=NR(),n=TR(),r=n(e);return ch=r,ch}var fh,cw;function ys(){if(cw)return fh;cw=1;var e=fo(),n=iw(),r=uw();function o(i,l){return r(n(i,l,e),i+"")}return fh=o,fh}var dh,fw;function dw(){if(fw)return dh;fw=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 dh=e,dh}var hh,hw;function RR(){if(hw)return hh;hw=1;function e(n){return n!==n}return hh=e,hh}var ph,pw;function PR(){if(pw)return ph;pw=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 ph=e,ph}var mh,mw;function IR(){if(mw)return mh;mw=1;var e=dw(),n=RR(),r=PR();function o(i,l,c){return l===l?r(i,l,c):e(i,n,c)}return mh=o,mh}var gh,gw;function MR(){if(gw)return gh;gw=1;var e=IR();function n(r,o){var i=r==null?0:r.length;return!!i&&e(r,o,0)>-1}return gh=n,gh}var vh,vw;function jR(){if(vw)return vh;vw=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 vh=e,vh}var yh,yw;function LR(){if(yw)return yh;yw=1;function e(){}return yh=e,yh}var bh,bw;function DR(){if(bw)return bh;bw=1;var e=n0(),n=LR(),r=ld(),o=1/0,i=e&&1/r(new e([,-0]))[1]==o?function(l){return new e(l)}:n;return bh=i,bh}var wh,ww;function BR(){if(ww)return wh;ww=1;var e=V0(),n=MR(),r=jR(),o=G0(),i=DR(),l=ld(),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 wh=f,wh}var xh,xw;function _w(){if(xw)return xh;xw=1;var e=_r(),n=lr();function r(o){return n(o)&&e(o)}return xh=r,xh}var _h,Sw;function FR(){if(Sw)return _h;Sw=1;var e=ih(),n=ys(),r=BR(),o=_w(),i=n(function(l){return r(e(l,1,o,!0))});return _h=i,_h}var Sh,Ew;function qR(){if(Ew)return Sh;Ew=1;var e=ms();function n(r,o){return e(o,function(i){return r[i]})}return Sh=n,Sh}var Eh,Ow;function kw(){if(Ow)return Eh;Ow=1;var e=qR(),n=Wr();function r(o){return o==null?[]:e(o,n(o))}return Eh=r,Eh}var Oh,Cw;function In(){if(Cw)return Oh;Cw=1;var e;if(typeof Pu=="function")try{e={clone:KT(),constant:zf(),each:B0(),filter:I1(),has:L1(),isArray:Gt(),isEmpty:vR(),isFunction:Li(),isUndefined:F1(),keys:Wr(),map:V1(),reduce:K1(),size:OR(),transform:kR(),union:FR(),values:kw()}}catch{}return e||(e=window._),Oh=e,Oh}var kh,Aw;function Ch(){if(Aw)return kh;Aw=1;var e=In();kh=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 kh}var Ah,Nw;function zR(){return Nw||(Nw=1,Ah="2.1.8"),Ah}var Nh,Tw;function HR(){return Tw||(Tw=1,Nh={Graph:Ch(),version:zR()}),Nh}var Th,Rw;function VR(){if(Rw)return Th;Rw=1;var e=In(),n=Ch();Th={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 Th}var Rh,Pw;function UR(){if(Pw)return Rh;Pw=1;var e=In();Rh=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 Rh}var Ph,Iw;function Mw(){if(Iw)return Ph;Iw=1;var e=In();Ph=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},Ph}var Ih,jw;function Lw(){if(jw)return Ih;jw=1;var e=In(),n=Mw();Ih=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 Ih}var Mh,Dw;function WR(){if(Dw)return Mh;Dw=1;var e=Lw(),n=In();Mh=r;function r(o,i,l){return n.transform(o.nodes(),function(c,f){c[f]=e(o,f,i,l)},{})}return Mh}var jh,Bw;function Fw(){if(Bw)return jh;Bw=1;var e=In();jh=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 jh}var Lh,qw;function GR(){if(qw)return Lh;qw=1;var e=In(),n=Fw();Lh=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 Lh}var Dh,zw;function KR(){if(zw)return Dh;zw=1;var e=In();Dh=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 Dh}var Bh,Hw;function Vw(){if(Hw)return Bh;Hw=1;var e=In();Bh=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,Bh}var Fh,Uw;function YR(){if(Uw)return Fh;Uw=1;var e=Vw();Fh=n;function n(r){try{e(r)}catch(o){if(o instanceof e.CycleException)return!1;throw o}return!0}return Fh}var qh,Ww;function Gw(){if(Ww)return qh;Ww=1;var e=In();qh=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 qh}var zh,Kw;function XR(){if(Kw)return zh;Kw=1;var e=Gw();zh=n;function n(r,o){return e(r,o,"post")}return zh}var Hh,Yw;function ZR(){if(Yw)return Hh;Yw=1;var e=Gw();Hh=n;function n(r,o){return e(r,o,"pre")}return Hh}var Vh,Xw;function QR(){if(Xw)return Vh;Xw=1;var e=In(),n=Ch(),r=Mw();Vh=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 Vh}var Uh,Zw;function JR(){return Zw||(Zw=1,Uh={components:UR(),dijkstra:Lw(),dijkstraAll:WR(),findCycles:GR(),floydWarshall:KR(),isAcyclic:YR(),postorder:XR(),preorder:ZR(),prim:QR(),tarjan:Fw(),topsort:Vw()}),Uh}var Wh,Qw;function $R(){if(Qw)return Wh;Qw=1;var e=HR();return Wh={Graph:e.Graph,json:VR(),alg:JR(),version:e.version},Wh}var Gh,Jw;function Qn(){if(Jw)return Gh;Jw=1;var e;if(typeof Pu=="function")try{e=$R()}catch{}return e||(e=window.graphlib),Gh=e,Gh}var Kh,$w;function e2(){if($w)return Kh;$w=1;var e=E0(),n=1,r=4;function o(i){return e(i,n|r)}return Kh=o,Kh}var Yh,ex;function bs(){if(ex)return Yh;ex=1;var e=Lo(),n=_r(),r=cs(),o=Pn();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 Yh=i,Yh}var Xh,tx;function t2(){if(tx)return Xh;tx=1;var e=ys(),n=Lo(),r=bs(),o=co(),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 Xh=c,Xh}var Zh,nx;function n2(){if(nx)return Zh;nx=1;var e=Sr(),n=_r(),r=Wr();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 Zh=o,Zh}var Qh,rx;function r2(){if(rx)return Qh;rx=1;var e=/\s/;function n(r){for(var o=r.length;o--&&e.test(r.charAt(o)););return o}return Qh=n,Qh}var Jh,ox;function o2(){if(ox)return Jh;ox=1;var e=r2(),n=/^\s+/;function r(o){return o&&o.slice(0,e(o)+1).replace(n,"")}return Jh=r,Jh}var $h,ix;function i2(){if(ix)return $h;ix=1;var e=o2(),n=Pn(),r=qo(),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 $h=m,$h}var ep,ax;function sx(){if(ax)return ep;ax=1;var e=i2(),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 ep=o,ep}var tp,lx;function a2(){if(lx)return tp;lx=1;var e=sx();function n(r){var o=e(r),i=o%1;return o===o?i?o-i:o:0}return tp=n,tp}var np,ux;function s2(){if(ux)return np;ux=1;var e=dw(),n=Sr(),r=a2(),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 np=i,np}var rp,cx;function l2(){if(cx)return rp;cx=1;var e=n2(),n=s2(),r=e(n);return rp=r,rp}var op,fx;function dx(){if(fx)return op;fx=1;var e=ih();function n(r){var o=r==null?0:r.length;return o?e(r,1):[]}return op=n,op}var ip,hx;function u2(){if(hx)return ip;hx=1;var e=Uf(),n=M0(),r=co();function o(i,l){return i==null?i:e(i,n(l),r)}return ip=o,ip}var ap,px;function c2(){if(px)return ap;px=1;function e(n){var r=n==null?0:n.length;return r?n[r-1]:void 0}return ap=e,ap}var sp,mx;function f2(){if(mx)return sp;mx=1;var e=ls(),n=Gf(),r=Sr();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 sp=o,sp}var lp,gx;function up(){if(gx)return lp;gx=1;var e=qo();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 lp=n,lp}var cp,vx;function d2(){if(vx)return cp;vx=1;function e(n,r){return n>r}return cp=e,cp}var fp,yx;function h2(){if(yx)return fp;yx=1;var e=up(),n=d2(),r=fo();function o(i){return i&&i.length?e(i,r,n):void 0}return fp=o,fp}var dp,bx;function wx(){if(bx)return dp;bx=1;var e=ls(),n=Lo();function r(o,i,l){(l!==void 0&&!n(o[i],l)||l===void 0&&!(i in o))&&e(o,i,l)}return dp=r,dp}var hp,xx;function p2(){if(xx)return hp;xx=1;var e=lo(),n=hs(),r=lr(),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 hp=g,hp}var pp,_x;function Sx(){if(_x)return pp;_x=1;function e(n,r){if(!(r==="constructor"&&typeof n[r]=="function")&&r!="__proto__")return n[r]}return pp=e,pp}var mp,Ex;function m2(){if(Ex)return mp;Ex=1;var e=Di(),n=co();function r(o){return e(o,n(o))}return mp=r,mp}var gp,Ox;function g2(){if(Ox)return gp;Ox=1;var e=wx(),n=Mb(),r=h0(),o=Lb(),i=y0(),l=Bi(),c=Gt(),f=_w(),m=Bo(),g=Li(),d=Pn(),p=p2(),h=zi(),s=Sx(),S=m2();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 gp=b,gp}var vp,kx;function v2(){if(kx)return vp;kx=1;var e=ss(),n=wx(),r=Uf(),o=g2(),i=Pn(),l=co(),c=Sx();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 vp=f,vp}var yp,Cx;function y2(){if(Cx)return yp;Cx=1;var e=ys(),n=bs();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 yp=r,yp}var bp,Ax;function b2(){if(Ax)return bp;Ax=1;var e=v2(),n=y2(),r=n(function(o,i,l){e(o,i,l)});return bp=r,bp}var wp,Nx;function Tx(){if(Nx)return wp;Nx=1;function e(n,r){return n<r}return wp=e,wp}var xp,Rx;function w2(){if(Rx)return xp;Rx=1;var e=up(),n=Tx(),r=fo();function o(i){return i&&i.length?e(i,r,n):void 0}return xp=o,xp}var _p,Px;function x2(){if(Px)return _p;Px=1;var e=up(),n=Sr(),r=Tx();function o(i,l){return i&&i.length?e(i,n(l,2),r):void 0}return _p=o,_p}var Sp,Ix;function _2(){if(Ix)return Sp;Ix=1;var e=Zn(),n=function(){return e.Date.now()};return Sp=n,Sp}var Ep,Mx;function S2(){if(Mx)return Ep;Mx=1;var e=us(),n=gs(),r=cs(),o=Pn(),i=Vi();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 Ep=l,Ep}var Op,jx;function E2(){if(jx)return Op;jx=1;var e=vs(),n=S2(),r=gs();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 Op=o,Op}var kp,Lx;function O2(){if(Lx)return kp;Lx=1;var e=E2(),n=O1();function r(o,i){return e(o,i,function(l,c){return n(o,c)})}return kp=r,kp}var Cp,Dx;function k2(){if(Dx)return Cp;Dx=1;var e=dx(),n=iw(),r=uw();function o(i){return r(n(i,void 0,e),i+"")}return Cp=o,Cp}var Ap,Bx;function C2(){if(Bx)return Ap;Bx=1;var e=O2(),n=k2(),r=n(function(o,i){return o==null?{}:e(o,i)});return Ap=r,Ap}var Np,Fx;function A2(){if(Fx)return Np;Fx=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 Np=r,Np}var Tp,qx;function N2(){if(qx)return Tp;qx=1;var e=A2(),n=bs(),r=sx();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 Tp=o,Tp}var Rp,zx;function T2(){if(zx)return Rp;zx=1;var e=N2(),n=e();return Rp=n,Rp}var Pp,Hx;function R2(){if(Hx)return Pp;Hx=1;function e(n,r){var o=n.length;for(n.sort(r);o--;)n[o]=n[o].value;return n}return Pp=e,Pp}var Ip,Vx;function P2(){if(Vx)return Ip;Vx=1;var e=qo();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 Ip=n,Ip}var Mp,Ux;function I2(){if(Ux)return Mp;Ux=1;var e=P2();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 Mp=n,Mp}var jp,Wx;function M2(){if(Wx)return jp;Wx=1;var e=ms(),n=vs(),r=Sr(),o=z1(),i=R2(),l=fs(),c=I2(),f=fo(),m=Gt();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 jp=g,jp}var Lp,Gx;function j2(){if(Gx)return Lp;Gx=1;var e=ih(),n=M2(),r=ys(),o=bs(),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 Lp=i,Lp}var Dp,Kx;function L2(){if(Kx)return Dp;Kx=1;var e=g1(),n=0;function r(o){var i=++n;return e(o)+i}return Dp=r,Dp}var Bp,Yx;function D2(){if(Yx)return Bp;Yx=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 Bp=e,Bp}var Fp,Xx;function B2(){if(Xx)return Fp;Xx=1;var e=us(),n=D2();function r(o,i){return n(o||[],i||[],e)}return Fp=r,Fp}var qp,Zx;function Lt(){if(Zx)return qp;Zx=1;var e;if(typeof Pu=="function")try{e={cloneDeep:e2(),constant:zf(),defaults:t2(),each:B0(),filter:I1(),find:l2(),flatten:dx(),forEach:L0(),forIn:u2(),has:L1(),isUndefined:F1(),last:c2(),map:V1(),mapValues:f2(),max:h2(),merge:b2(),min:w2(),minBy:x2(),now:_2(),pick:C2(),range:T2(),reduce:K1(),sortBy:j2(),uniqueId:L2(),values:kw(),zipObject:B2()}}catch{}return e||(e=window._),qp=e,qp}var zp,Qx;function F2(){if(Qx)return zp;Qx=1,zp=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 zp}var Hp,Jx;function q2(){if(Jx)return Hp;Jx=1;var e=Lt(),n=Qn().Graph,r=F2();Hp=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 Hp}var Vp,$x;function z2(){if($x)return Vp;$x=1;var e=Lt(),n=q2();Vp={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 Vp}var Up,e_;function bn(){if(e_)return Up;e_=1;var e=Lt(),n=Qn().Graph;Up={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 Up}var Wp,t_;function H2(){if(t_)return Wp;t_=1;var e=Lt(),n=bn();Wp={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 Wp}var Gp,n_;function ws(){if(n_)return Gp;n_=1;var e=Lt();Gp={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 Gp}var Kp,r_;function o_(){if(r_)return Kp;r_=1;var e=Lt(),n=Qn().Graph,r=ws().slack;Kp=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 Kp}var Yp,i_;function V2(){if(i_)return Yp;i_=1;var e=Lt(),n=o_(),r=ws().slack,o=ws().longestPath,i=Qn().alg.preorder,l=Qn().alg.postorder,c=bn().simplify;Yp=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 Yp}var Xp,a_;function U2(){if(a_)return Xp;a_=1;var e=ws(),n=e.longestPath,r=o_(),o=V2();Xp=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 Xp}var Zp,s_;function W2(){if(s_)return Zp;s_=1;var e=Lt();Zp=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 Zp}var Qp,l_;function G2(){if(l_)return Qp;l_=1;var e=Lt(),n=bn();Qp={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 Qp}var Jp,u_;function K2(){if(u_)return Jp;u_=1;var e=Lt(),n=bn();Jp=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 Jp}var $p,c_;function Y2(){if(c_)return $p;c_=1;var e=Lt();$p={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 $p}var em,f_;function X2(){if(f_)return em;f_=1;var e=Lt();em=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 em}var tm,d_;function Z2(){if(d_)return tm;d_=1;var e=Lt();tm=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 tm}var nm,h_;function Q2(){if(h_)return nm;h_=1;var e=Lt();nm=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 nm}var rm,p_;function J2(){if(p_)return rm;p_=1;var e=Lt();rm=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 rm}var om,m_;function $2(){if(m_)return om;m_=1;var e=Lt(),n=bn();om=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 om}var im,g_;function eP(){if(g_)return im;g_=1;var e=Lt(),n=Q2(),r=J2(),o=$2();im=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 im}var am,v_;function tP(){if(v_)return am;v_=1;var e=Lt(),n=Qn().Graph;am=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 am}var sm,y_;function nP(){if(y_)return sm;y_=1;var e=Lt();sm=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 sm}var lm,b_;function rP(){if(b_)return lm;b_=1;var e=Lt(),n=X2(),r=Z2(),o=eP(),i=tP(),l=nP(),c=Qn().Graph,f=bn();lm=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 lm}var um,w_;function oP(){if(w_)return um;w_=1;var e=Lt(),n=Qn().Graph,r=bn();um={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),he=oe.order;(he<R||B<he)&&!(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 um}var cm,x_;function iP(){if(x_)return cm;x_=1;var e=Lt(),n=bn(),r=oP().positionX;cm=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 cm}var fm,__;function aP(){if(__)return fm;__=1;var e=Lt(),n=z2(),r=H2(),o=U2(),i=bn().normalizeRanks,l=W2(),c=bn().removeEmptyRanks,f=G2(),m=K2(),g=Y2(),d=rP(),p=iP(),h=bn(),s=Qn().Graph;fm=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(){he(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 he(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 fm}var dm,S_;function sP(){if(S_)return dm;S_=1;var e=Lt(),n=bn(),r=Qn().Graph;dm={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 dm}var hm,E_;function lP(){return E_||(E_=1,hm="0.8.5"),hm}var pm,O_;function uP(){return O_||(O_=1,pm={graphlib:Qn(),layout:aP(),debug:sP(),util:{time:bn().time,notime:bn().notime},version:lP()}),pm}var cP=uP();const Ui=Ru(cP);function zo(e){return e!=null&&typeof e=="object"&&e["@@functional/placeholder"]===!0}function Er(e){return function n(r){return arguments.length===0||zo(r)?n:e.apply(this,arguments)}}function k_(e){return function n(r,o){switch(arguments.length){case 0:return n;case 1:return zo(r)?n:Er(function(i){return e(r,i)});default:return zo(r)&&zo(o)?n:zo(r)?Er(function(i){return e(i,o)}):zo(o)?Er(function(i){return e(r,i)}):e(r,o)}}}const fP=Array.isArray||function(n){return n!=null&&n.length>=0&&Object.prototype.toString.call(n)==="[object Array]"};function dP(e){return Object.prototype.toString.call(e)==="[object String]"}function xs(e,n){return Object.prototype.hasOwnProperty.call(n,e)}var C_=Object.prototype.toString,A_=(function(){return C_.call(arguments)==="[object Arguments]"?function(n){return C_.call(n)==="[object Arguments]"}:function(n){return xs("callee",n)}})(),hP=!{toString:null}.propertyIsEnumerable("toString"),N_=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],T_=(function(){return arguments.propertyIsEnumerable("length")})(),pP=function(n,r){for(var o=0;o<n.length;){if(n[o]===r)return!0;o+=1}return!1},R_=Er(typeof Object.keys=="function"&&!T_?function(n){return Object(n)!==n?[]:Object.keys(n)}:function(n){if(Object(n)!==n)return[];var r,o,i=[],l=T_&&A_(n);for(r in n)xs(r,n)&&(!l||r!=="length")&&(i[i.length]=r);if(hP)for(o=N_.length-1;o>=0;)r=N_[o],xs(r,n)&&!pP(i,r)&&(i[i.length]=r),o-=1;return i}),ur=Er(function(n){return n==null}),P_=Er(function(n){return n===null?"Null":n===void 0?"Undefined":Object.prototype.toString.call(n).slice(8,-1)});function I_(e){for(var n=[],r;!(r=e.next()).done;)n.push(r.value);return n}function M_(e,n,r){for(var o=0,i=r.length;o<i;){if(e(n,r[o]))return!0;o+=1}return!1}function mP(e){var n=String(e).match(/^function (\w*)/);return n==null?"":n[1]}function gP(e,n){return e===n?e!==0||1/e===1/n:e!==e&&n!==n}const mm=typeof Object.is=="function"?Object.is:gP;function j_(e,n,r,o){var i=I_(e),l=I_(n);function c(f,m){return gm(f,m,r.slice(),o.slice())}return!M_(function(f,m){return!M_(c,m,f)},l,i)}function gm(e,n,r,o){if(mm(e,n))return!0;var i=P_(e);if(i!==P_(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"&&mP(e.constructor)==="Promise")return e===n;break;case"Boolean":case"Number":case"String":if(!(typeof e==typeof n&&mm(e.valueOf(),n.valueOf())))return!1;break;case"Date":if(!mm(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:j_(e.entries(),n.entries(),r.concat([e]),o.concat([n]));case"Set":return e.size!==n.size?!1:j_(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=R_(e);if(c.length!==R_(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(!(xs(g,n)&&gm(n[g],e[g],f,m)))return!1;l-=1}return!0}var vP=k_(function(n,r){return gm(n,r,[],[])});function yP(e){return Object.prototype.toString.call(e)==="[object Object]"}var bP=Er(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():fP(n)?[]:dP(n)?"":yP(n)?{}:A_(n)?(function(){return arguments})():void 0}),Jt=Er(function(n){return n!=null&&vP(n,bP(n))}),L_=k_(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 ln(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=ln(e[r]))!==""&&(n+=(n&&" ")+o);else for(let r in e)e[r]&&(n+=(n&&" ")+r);return n}var vm={exports:{}},ym={},bm={exports:{}},wm={};/**
|
|
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 D_;function wP(){if(D_)return wm;D_=1;var e=ce;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 wm.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,wm}var B_;function xP(){return B_||(B_=1,bm.exports=wP()),bm.exports}/**
|
|
10
10
|
* @license React
|
|
11
11
|
* use-sync-external-store-shim/with-selector.production.min.js
|
|
12
12
|
*
|
|
@@ -14,16 +14,16 @@
|
|
|
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 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';
|
|
17
|
+
*/var F_;function _P(){if(F_)return ym;F_=1;var e=ce,n=xP();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 ym.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(_),_},ym}var q_;function SP(){return q_||(q_=1,vm.exports=_P()),vm.exports}var EP=SP();const OP=Ru(EP),kP={},z_=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:()=>{(kP?"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},CP=e=>e?z_(e):z_,{useSyncExternalStoreWithSelector:AP}=OP;function H_(e,n=e.getState,r){const o=AP(e.subscribe,e.getState,e.getServerState||e.getState,n,r);return ce.useDebugValue(o),o}const V_=(e,n)=>{const r=CP(e),o=(i,l=n)=>H_(r,i,l);return Object.assign(o,r),o},NP=(e,n)=>e?V_(e,n):V_;function sn(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 TP={value:()=>{}};function _s(){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 Ss(r)}function Ss(e){this._=e}function RP(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}})}Ss.prototype=_s.prototype={constructor:Ss,on:function(e,n){var r=this._,o=RP(e+"",r),i,l=-1,c=o.length;if(arguments.length<2){for(;++l<c;)if((i=(e=o[l]).type)&&(i=PP(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]=U_(r[i],e.name,n);else if(n==null)for(i in r)r[i]=U_(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 Ss(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 PP(e,n){for(var r=0,o=e.length,i;r<o;++r)if((i=e[r]).name===n)return i.value}function U_(e,n,r){for(var o=0,i=e.length;o<i;++o)if(e[o].name===n){e[o]=TP,e=e.slice(0,o).concat(e.slice(o+1));break}return r!=null&&e.push({name:n,value:r}),e}var xm="http://www.w3.org/1999/xhtml";const W_={svg:"http://www.w3.org/2000/svg",xhtml:xm,xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"};function Es(e){var n=e+="",r=n.indexOf(":");return r>=0&&(n=e.slice(0,r))!=="xmlns"&&(e=e.slice(r+1)),W_.hasOwnProperty(n)?{space:W_[n],local:e}:e}function IP(e){return function(){var n=this.ownerDocument,r=this.namespaceURI;return r===xm&&n.documentElement.namespaceURI===xm?n.createElement(e):n.createElementNS(r,e)}}function MP(e){return function(){return this.ownerDocument.createElementNS(e.space,e.local)}}function G_(e){var n=Es(e);return(n.local?MP:IP)(n)}function jP(){}function _m(e){return e==null?jP:function(){return this.querySelector(e)}}function LP(e){typeof e!="function"&&(e=_m(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 On(o,this._parents)}function DP(e){return e==null?[]:Array.isArray(e)?e:Array.from(e)}function BP(){return[]}function K_(e){return e==null?BP:function(){return this.querySelectorAll(e)}}function FP(e){return function(){return DP(e.apply(this,arguments))}}function qP(e){typeof e=="function"?e=FP(e):e=K_(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 On(o,i)}function Y_(e){return function(){return this.matches(e)}}function X_(e){return function(n){return n.matches(e)}}var zP=Array.prototype.find;function HP(e){return function(){return zP.call(this.children,e)}}function VP(){return this.firstElementChild}function UP(e){return this.select(e==null?VP:HP(typeof e=="function"?e:X_(e)))}var WP=Array.prototype.filter;function GP(){return Array.from(this.children)}function KP(e){return function(){return WP.call(this.children,e)}}function YP(e){return this.selectAll(e==null?GP:KP(typeof e=="function"?e:X_(e)))}function XP(e){typeof e!="function"&&(e=Y_(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 On(o,this._parents)}function Z_(e){return new Array(e.length)}function ZP(){return new On(this._enter||this._groups.map(Z_),this._parents)}function Os(e,n){this.ownerDocument=e.ownerDocument,this.namespaceURI=e.namespaceURI,this._next=null,this._parent=e,this.__data__=n}Os.prototype={constructor:Os,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 QP(e){return function(){return e}}function JP(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 Os(e,l[c]);for(;c<m;++c)(f=n[c])&&(i[c]=f)}function $P(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 Os(e,l[f]);for(f=0;f<d;++f)(m=n[f])&&g.get(h[f])===m&&(i[f]=m)}function eI(e){return e.__data__}function tI(e,n){if(!arguments.length)return Array.from(this,eI);var r=n?$P:JP,o=this._parents,i=this._groups;typeof e!="function"&&(e=QP(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=nI(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 On(c,o),c._enter=f,c._exit=m,c}function nI(e){return typeof e=="object"&&"length"in e?e:Array.from(e)}function rI(){return new On(this._exit||this._groups.map(Z_),this._parents)}function oI(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 iI(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 On(f,this._parents)}function aI(){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 sI(e){e||(e=lI);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 On(i,this._parents).order()}function lI(e,n){return e<n?-1:e>n?1:e>=n?0:NaN}function uI(){var e=arguments[0];return arguments[0]=this,e.apply(null,arguments),this}function cI(){return Array.from(this)}function fI(){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 dI(){let e=0;for(const n of this)++e;return e}function hI(){return!this.node()}function pI(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 mI(e){return function(){this.removeAttribute(e)}}function gI(e){return function(){this.removeAttributeNS(e.space,e.local)}}function vI(e,n){return function(){this.setAttribute(e,n)}}function yI(e,n){return function(){this.setAttributeNS(e.space,e.local,n)}}function bI(e,n){return function(){var r=n.apply(this,arguments);r==null?this.removeAttribute(e):this.setAttribute(e,r)}}function wI(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 xI(e,n){var r=Es(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?gI:mI:typeof n=="function"?r.local?wI:bI:r.local?yI:vI)(r,n))}function Q_(e){return e.ownerDocument&&e.ownerDocument.defaultView||e.document&&e||e.defaultView}function _I(e){return function(){this.style.removeProperty(e)}}function SI(e,n,r){return function(){this.style.setProperty(e,n,r)}}function EI(e,n,r){return function(){var o=n.apply(this,arguments);o==null?this.style.removeProperty(e):this.style.setProperty(e,o,r)}}function OI(e,n,r){return arguments.length>1?this.each((n==null?_I:typeof n=="function"?EI:SI)(e,n,r??"")):Ho(this.node(),e)}function Ho(e,n){return e.style.getPropertyValue(n)||Q_(e).getComputedStyle(e,null).getPropertyValue(n)}function kI(e){return function(){delete this[e]}}function CI(e,n){return function(){this[e]=n}}function AI(e,n){return function(){var r=n.apply(this,arguments);r==null?delete this[e]:this[e]=r}}function NI(e,n){return arguments.length>1?this.each((n==null?kI:typeof n=="function"?AI:CI)(e,n)):this.node()[e]}function J_(e){return e.trim().split(/^|\s+/)}function Sm(e){return e.classList||new $_(e)}function $_(e){this._node=e,this._names=J_(e.getAttribute("class")||"")}$_.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 eS(e,n){for(var r=Sm(e),o=-1,i=n.length;++o<i;)r.add(n[o])}function tS(e,n){for(var r=Sm(e),o=-1,i=n.length;++o<i;)r.remove(n[o])}function TI(e){return function(){eS(this,e)}}function RI(e){return function(){tS(this,e)}}function PI(e,n){return function(){(n.apply(this,arguments)?eS:tS)(this,e)}}function II(e,n){var r=J_(e+"");if(arguments.length<2){for(var o=Sm(this.node()),i=-1,l=r.length;++i<l;)if(!o.contains(r[i]))return!1;return!0}return this.each((typeof n=="function"?PI:n?TI:RI)(r,n))}function MI(){this.textContent=""}function jI(e){return function(){this.textContent=e}}function LI(e){return function(){var n=e.apply(this,arguments);this.textContent=n??""}}function DI(e){return arguments.length?this.each(e==null?MI:(typeof e=="function"?LI:jI)(e)):this.node().textContent}function BI(){this.innerHTML=""}function FI(e){return function(){this.innerHTML=e}}function qI(e){return function(){var n=e.apply(this,arguments);this.innerHTML=n??""}}function zI(e){return arguments.length?this.each(e==null?BI:(typeof e=="function"?qI:FI)(e)):this.node().innerHTML}function HI(){this.nextSibling&&this.parentNode.appendChild(this)}function VI(){return this.each(HI)}function UI(){this.previousSibling&&this.parentNode.insertBefore(this,this.parentNode.firstChild)}function WI(){return this.each(UI)}function GI(e){var n=typeof e=="function"?e:G_(e);return this.select(function(){return this.appendChild(n.apply(this,arguments))})}function KI(){return null}function YI(e,n){var r=typeof e=="function"?e:G_(e),o=n==null?KI:typeof n=="function"?n:_m(n);return this.select(function(){return this.insertBefore(r.apply(this,arguments),o.apply(this,arguments)||null)})}function XI(){var e=this.parentNode;e&&e.removeChild(this)}function ZI(){return this.each(XI)}function QI(){var e=this.cloneNode(!1),n=this.parentNode;return n?n.insertBefore(e,this.nextSibling):e}function JI(){var e=this.cloneNode(!0),n=this.parentNode;return n?n.insertBefore(e,this.nextSibling):e}function $I(e){return this.select(e?JI:QI)}function eM(e){return arguments.length?this.property("__data__",e):this.node().__data__}function tM(e){return function(n){e.call(this,n,this.__data__)}}function nM(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 rM(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 oM(e,n,r){return function(){var o=this.__on,i,l=tM(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 iM(e,n,r){var o=nM(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?oM:rM,i=0;i<l;++i)this.each(f(o[i],n,r));return this}function nS(e,n,r){var o=Q_(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 aM(e,n){return function(){return nS(this,e,n)}}function sM(e,n){return function(){return nS(this,e,n.apply(this,arguments))}}function lM(e,n){return this.each((typeof n=="function"?sM:aM)(e,n))}function*uM(){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 rS=[null];function On(e,n){this._groups=e,this._parents=n}function Wi(){return new On([[document.documentElement]],rS)}function cM(){return this}On.prototype=Wi.prototype={constructor:On,select:LP,selectAll:qP,selectChild:UP,selectChildren:YP,filter:XP,data:tI,enter:ZP,exit:rI,join:oI,merge:iI,selection:cM,order:aI,sort:sI,call:uI,nodes:cI,node:fI,size:dI,empty:hI,each:pI,attr:xI,style:OI,property:NI,classed:II,text:DI,html:zI,raise:VI,lower:WI,append:GI,insert:YI,remove:ZI,clone:$I,datum:eM,on:iM,dispatch:lM,[Symbol.iterator]:uM};function Mn(e){return typeof e=="string"?new On([[document.querySelector(e)]],[document.documentElement]):new On([[e]],rS)}function fM(e){let n;for(;n=e.sourceEvent;)e=n;return e}function Jn(e,n){if(e=fM(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 dM={passive:!1},Gi={capture:!0,passive:!1};function Em(e){e.stopImmediatePropagation()}function Vo(e){e.preventDefault(),e.stopImmediatePropagation()}function oS(e){var n=e.document.documentElement,r=Mn(e).on("dragstart.drag",Vo,Gi);"onselectstart"in n?r.on("selectstart.drag",Vo,Gi):(n.__noselect=n.style.MozUserSelect,n.style.MozUserSelect="none")}function iS(e,n){var r=e.document.documentElement,o=Mn(e).on("dragstart.drag",null);n&&(o.on("click.drag",Vo,Gi),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 ks=e=>()=>e;function Om(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}})}Om.prototype.on=function(){var e=this._.on.apply(this._,arguments);return e===this._?this:e};function hM(e){return!e.ctrlKey&&!e.button}function pM(){return this.parentNode}function mM(e,n){return n??{x:e.x,y:e.y}}function gM(){return navigator.maxTouchPoints||"ontouchstart"in this}function vM(){var e=hM,n=pM,r=mM,o=gM,i={},l=_s("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,dM).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&&(Mn(x.view).on("mousemove.drag",S,Gi).on("mouseup.drag",b,Gi),oS(x.view),Em(x),g=!1,f=x.clientX,m=x.clientY,P("start",x))}}function S(x){if(Vo(x),!g){var k=x.clientX-f,P=x.clientY-m;g=k*k+P*P>p}i.mouse("drag",x)}function b(x){Mn(x.view).on("mousemove.drag mouseup.drag",null),iS(x.view,g),Vo(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]))&&(Em(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])&&(Vo(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])&&(Em(x),j("end",x,k[R]))}function E(x,k,P,R,j,z){var L=l.copy(),M=Jn(z||P,k),D,F,B;if((B=r.call(x,new Om("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,he){var Y=M,ee;switch(J){case"start":i[j]=U,ee=c++;break;case"end":delete i[j],--c;case"drag":M=Jn(he||oe,k),ee=c;break}L.call(J,x,new Om(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:ks(!!x),h):e},h.container=function(x){return arguments.length?(n=typeof x=="function"?x:ks(x),h):n},h.subject=function(x){return arguments.length?(r=typeof x=="function"?x:ks(x),h):r},h.touchable=function(x){return arguments.length?(o=typeof x=="function"?x:ks(!!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 km(e,n,r){e.prototype=n.prototype=r,r.constructor=e}function aS(e,n){var r=Object.create(e.prototype);for(var o in n)r[o]=n[o];return r}function Ki(){}var Yi=.7,Cs=1/Yi,Uo="\\s*([+-]?\\d+)\\s*",Xi="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",cr="\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",yM=/^#([0-9a-f]{3,8})$/,bM=new RegExp(`^rgb\\(${Uo},${Uo},${Uo}\\)$`),wM=new RegExp(`^rgb\\(${cr},${cr},${cr}\\)$`),xM=new RegExp(`^rgba\\(${Uo},${Uo},${Uo},${Xi}\\)$`),_M=new RegExp(`^rgba\\(${cr},${cr},${cr},${Xi}\\)$`),SM=new RegExp(`^hsl\\(${Xi},${cr},${cr}\\)$`),EM=new RegExp(`^hsla\\(${Xi},${cr},${cr},${Xi}\\)$`),sS={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};km(Ki,Zi,{copy(e){return Object.assign(new this.constructor,this,e)},displayable(){return this.rgb().displayable()},hex:lS,formatHex:lS,formatHex8:OM,formatHsl:kM,formatRgb:uS,toString:uS});function lS(){return this.rgb().formatHex()}function OM(){return this.rgb().formatHex8()}function kM(){return pS(this).formatHsl()}function uS(){return this.rgb().formatRgb()}function Zi(e){var n,r;return e=(e+"").trim().toLowerCase(),(n=yM.exec(e))?(r=n[1].length,n=parseInt(n[1],16),r===6?cS(n):r===3?new wn(n>>8&15|n>>4&240,n>>4&15|n&240,(n&15)<<4|n&15,1):r===8?As(n>>24&255,n>>16&255,n>>8&255,(n&255)/255):r===4?As(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=bM.exec(e))?new wn(n[1],n[2],n[3],1):(n=wM.exec(e))?new wn(n[1]*255/100,n[2]*255/100,n[3]*255/100,1):(n=xM.exec(e))?As(n[1],n[2],n[3],n[4]):(n=_M.exec(e))?As(n[1]*255/100,n[2]*255/100,n[3]*255/100,n[4]):(n=SM.exec(e))?hS(n[1],n[2]/100,n[3]/100,1):(n=EM.exec(e))?hS(n[1],n[2]/100,n[3]/100,n[4]):sS.hasOwnProperty(e)?cS(sS[e]):e==="transparent"?new wn(NaN,NaN,NaN,0):null}function cS(e){return new wn(e>>16&255,e>>8&255,e&255,1)}function As(e,n,r,o){return o<=0&&(e=n=r=NaN),new wn(e,n,r,o)}function CM(e){return e instanceof Ki||(e=Zi(e)),e?(e=e.rgb(),new wn(e.r,e.g,e.b,e.opacity)):new wn}function Cm(e,n,r,o){return arguments.length===1?CM(e):new wn(e,n,r,o??1)}function wn(e,n,r,o){this.r=+e,this.g=+n,this.b=+r,this.opacity=+o}km(wn,Cm,aS(Ki,{brighter(e){return e=e==null?Cs:Math.pow(Cs,e),new wn(this.r*e,this.g*e,this.b*e,this.opacity)},darker(e){return e=e==null?Yi:Math.pow(Yi,e),new wn(this.r*e,this.g*e,this.b*e,this.opacity)},rgb(){return this},clamp(){return new wn(ho(this.r),ho(this.g),ho(this.b),Ns(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:fS,formatHex:fS,formatHex8:AM,formatRgb:dS,toString:dS}));function fS(){return`#${po(this.r)}${po(this.g)}${po(this.b)}`}function AM(){return`#${po(this.r)}${po(this.g)}${po(this.b)}${po((isNaN(this.opacity)?1:this.opacity)*255)}`}function dS(){const e=Ns(this.opacity);return`${e===1?"rgb(":"rgba("}${ho(this.r)}, ${ho(this.g)}, ${ho(this.b)}${e===1?")":`, ${e})`}`}function Ns(e){return isNaN(e)?1:Math.max(0,Math.min(1,e))}function ho(e){return Math.max(0,Math.min(255,Math.round(e)||0))}function po(e){return e=ho(e),(e<16?"0":"")+e.toString(16)}function hS(e,n,r,o){return o<=0?e=n=r=NaN:r<=0||r>=1?e=n=NaN:n<=0&&(e=NaN),new $n(e,n,r,o)}function pS(e){if(e instanceof $n)return new $n(e.h,e.s,e.l,e.opacity);if(e instanceof Ki||(e=Zi(e)),!e)return new $n;if(e instanceof $n)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 $n(c,f,m,e.opacity)}function NM(e,n,r,o){return arguments.length===1?pS(e):new $n(e,n,r,o??1)}function $n(e,n,r,o){this.h=+e,this.s=+n,this.l=+r,this.opacity=+o}km($n,NM,aS(Ki,{brighter(e){return e=e==null?Cs:Math.pow(Cs,e),new $n(this.h,this.s,this.l*e,this.opacity)},darker(e){return e=e==null?Yi:Math.pow(Yi,e),new $n(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 wn(Am(e>=240?e-240:e+120,i,o),Am(e,i,o),Am(e<120?e+240:e-120,i,o),this.opacity)},clamp(){return new $n(mS(this.h),Ts(this.s),Ts(this.l),Ns(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=Ns(this.opacity);return`${e===1?"hsl(":"hsla("}${mS(this.h)}, ${Ts(this.s)*100}%, ${Ts(this.l)*100}%${e===1?")":`, ${e})`}`}}));function mS(e){return e=(e||0)%360,e<0?e+360:e}function Ts(e){return Math.max(0,Math.min(1,e||0))}function Am(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 gS=e=>()=>e;function TM(e,n){return function(r){return e+r*n}}function RM(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 PM(e){return(e=+e)==1?vS:function(n,r){return r-n?RM(n,r,e):gS(isNaN(n)?r:n)}}function vS(e,n){var r=n-e;return r?TM(e,r):gS(isNaN(e)?n:e)}const yS=(function e(n){var r=PM(n);function o(i,l){var c=r((i=Cm(i)).r,(l=Cm(l)).r),f=r(i.g,l.g),m=r(i.b,l.b),g=vS(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 Gr(e,n){return e=+e,n=+n,function(r){return e*(1-r)+n*r}}var Nm=/[-+]?(?:\d+\.?\d*|\.?\d+)(?:[eE][-+]?\d+)?/g,Tm=new RegExp(Nm.source,"g");function IM(e){return function(){return e}}function MM(e){return function(n){return e(n)+""}}function jM(e,n){var r=Nm.lastIndex=Tm.lastIndex=0,o,i,l,c=-1,f=[],m=[];for(e=e+"",n=n+"";(o=Nm.exec(e))&&(i=Tm.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:Gr(o,i)})),r=Tm.lastIndex;return r<n.length&&(l=n.slice(r),f[c]?f[c]+=l:f[++c]=l),f.length<2?m[0]?MM(m[0].x):IM(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 bS=180/Math.PI,Rm={translateX:0,translateY:0,rotate:0,skewX:0,scaleX:1,scaleY:1};function wS(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)*bS,skewX:Math.atan(m)*bS,scaleX:c,scaleY:f}}var Rs;function LM(e){const n=new(typeof DOMMatrix=="function"?DOMMatrix:WebKitCSSMatrix)(e+"");return n.isIdentity?Rm:wS(n.a,n.b,n.c,n.d,n.e,n.f)}function DM(e){return e==null||(Rs||(Rs=document.createElementNS("http://www.w3.org/2000/svg","g")),Rs.setAttribute("transform",e),!(e=Rs.transform.baseVal.consolidate()))?Rm:(e=e.matrix,wS(e.a,e.b,e.c,e.d,e.e,e.f))}function xS(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:Gr(g,p)},{i:b-2,x:Gr(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:Gr(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:Gr(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:Gr(g,p)},{i:b-2,x:Gr(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 BM=xS(LM,"px, ","px)","deg)"),FM=xS(DM,", ",")",")"),qM=1e-12;function _S(e){return((e=Math.exp(e))+1/e)/2}function zM(e){return((e=Math.exp(e))-1/e)/2}function HM(e){return((e=Math.exp(2*e))-1)/(e+1)}const VM=(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<qM)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=_S(k),L=g/(r*y)*(z*HM(n*j+k)-zM(k));return[f+L*s,m+L*S,g*z/_S(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 Wo=0,Qi=0,Ji=0,SS=1e3,Ps,$i,Is=0,mo=0,Ms=0,ea=typeof performance=="object"&&performance.now?performance:Date,ES=typeof window=="object"&&window.requestAnimationFrame?window.requestAnimationFrame.bind(window):function(e){setTimeout(e,17)};function Pm(){return mo||(ES(UM),mo=ea.now()+Ms)}function UM(){mo=0}function js(){this._call=this._time=this._next=null}js.prototype=OS.prototype={constructor:js,restart:function(e,n,r){if(typeof e!="function")throw new TypeError("callback is not a function");r=(r==null?Pm():+r)+(n==null?0:+n),!this._next&&$i!==this&&($i?$i._next=this:Ps=this,$i=this),this._call=e,this._time=r,Im()},stop:function(){this._call&&(this._call=null,this._time=1/0,Im())}};function OS(e,n,r){var o=new js;return o.restart(e,n,r),o}function WM(){Pm(),++Wo;for(var e=Ps,n;e;)(n=mo-e._time)>=0&&e._call.call(void 0,n),e=e._next;--Wo}function kS(){mo=(Is=ea.now())+Ms,Wo=Qi=0;try{WM()}finally{Wo=0,KM(),mo=0}}function GM(){var e=ea.now(),n=e-Is;n>SS&&(Ms-=n,Is=e)}function KM(){for(var e,n=Ps,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:Ps=r);$i=e,Im(o)}function Im(e){if(!Wo){Qi&&(Qi=clearTimeout(Qi));var n=e-mo;n>24?(e<1/0&&(Qi=setTimeout(kS,e-ea.now()-Ms)),Ji&&(Ji=clearInterval(Ji))):(Ji||(Is=ea.now(),Ji=setInterval(GM,SS)),Wo=1,ES(kS))}}function CS(e,n,r){var o=new js;return n=n==null?0:+n,o.restart(i=>{o.stop(),e(i+n)},n,r),o}var YM=_s("start","end","cancel","interrupt"),XM=[],AS=0,NS=1,Mm=2,Ls=3,TS=4,jm=5,Ds=6;function Bs(e,n,r,o,i,l){var c=e.__transition;if(!c)e.__transition={};else if(r in c)return;ZM(e,r,{name:n,index:o,group:i,on:YM,tween:XM,time:l.time,delay:l.delay,duration:l.duration,ease:l.ease,timer:null,state:AS})}function Lm(e,n){var r=er(e,n);if(r.state>AS)throw new Error("too late; already scheduled");return r}function fr(e,n){var r=er(e,n);if(r.state>Ls)throw new Error("too late; already running");return r}function er(e,n){var r=e.__transition;if(!r||!(r=r[n]))throw new Error("transition not found");return r}function ZM(e,n,r){var o=e.__transition,i;o[n]=r,r.timer=OS(l,0,r.time);function l(g){r.state=NS,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!==NS)return m();for(d in o)if(s=o[d],s.name===r.name){if(s.state===Ls)return CS(c);s.state===TS?(s.state=Ds,s.timer.stop(),s.on.call("interrupt",e,e.__data__,s.index,s.group),delete o[d]):+d<n&&(s.state=Ds,s.timer.stop(),s.on.call("cancel",e,e.__data__,s.index,s.group),delete o[d])}if(CS(function(){r.state===Ls&&(r.state=TS,r.timer.restart(f,r.delay,r.time),f(g))}),r.state=Mm,r.on.call("start",e,e.__data__,r.index,r.group),r.state===Mm){for(r.state=Ls,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=jm,1),p=-1,h=i.length;++p<h;)i[p].call(e,d);r.state===jm&&(r.on.call("end",e,e.__data__,r.index,r.group),m())}function m(){r.state=Ds,r.timer.stop(),delete o[n];for(var g in o)return;delete e.__transition}}function Fs(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>Mm&&o.state<jm,o.state=Ds,o.timer.stop(),o.on.call(i?"interrupt":"cancel",e,e.__data__,o.index,o.group),delete r[c]}l&&delete e.__transition}}function QM(e){return this.each(function(){Fs(this,e)})}function JM(e,n){var r,o;return function(){var i=fr(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 $M(e,n,r){var o,i;if(typeof r!="function")throw new Error;return function(){var l=fr(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 ej(e,n){var r=this._id;if(e+="",arguments.length<2){for(var o=er(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?JM:$M)(r,e,n))}function Dm(e,n,r){var o=e._id;return e.each(function(){var i=fr(this,o);(i.value||(i.value={}))[n]=r.apply(this,arguments)}),function(i){return er(i,o).value[n]}}function RS(e,n){var r;return(typeof n=="number"?Gr:n instanceof Zi?yS:(r=Zi(n))?(n=r,yS):jM)(e,n)}function tj(e){return function(){this.removeAttribute(e)}}function nj(e){return function(){this.removeAttributeNS(e.space,e.local)}}function rj(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 oj(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 ij(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 aj(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 sj(e,n){var r=Es(e),o=r==="transform"?FM:RS;return this.attrTween(e,typeof n=="function"?(r.local?aj:ij)(r,o,Dm(this,"attr."+e,n)):n==null?(r.local?nj:tj)(r):(r.local?oj:rj)(r,o,n))}function lj(e,n){return function(r){this.setAttribute(e,n.call(this,r))}}function uj(e,n){return function(r){this.setAttributeNS(e.space,e.local,n.call(this,r))}}function cj(e,n){var r,o;function i(){var l=n.apply(this,arguments);return l!==o&&(r=(o=l)&&uj(e,l)),r}return i._value=n,i}function fj(e,n){var r,o;function i(){var l=n.apply(this,arguments);return l!==o&&(r=(o=l)&&lj(e,l)),r}return i._value=n,i}function dj(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=Es(e);return this.tween(r,(o.local?cj:fj)(o,n))}function hj(e,n){return function(){Lm(this,e).delay=+n.apply(this,arguments)}}function pj(e,n){return n=+n,function(){Lm(this,e).delay=n}}function mj(e){var n=this._id;return arguments.length?this.each((typeof e=="function"?hj:pj)(n,e)):er(this.node(),n).delay}function gj(e,n){return function(){fr(this,e).duration=+n.apply(this,arguments)}}function vj(e,n){return n=+n,function(){fr(this,e).duration=n}}function yj(e){var n=this._id;return arguments.length?this.each((typeof e=="function"?gj:vj)(n,e)):er(this.node(),n).duration}function bj(e,n){if(typeof n!="function")throw new Error;return function(){fr(this,e).ease=n}}function wj(e){var n=this._id;return arguments.length?this.each(bj(n,e)):er(this.node(),n).ease}function xj(e,n){return function(){var r=n.apply(this,arguments);if(typeof r!="function")throw new Error;fr(this,e).ease=r}}function _j(e){if(typeof e!="function")throw new Error;return this.each(xj(this._id,e))}function Sj(e){typeof e!="function"&&(e=Y_(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 Or(o,this._parents,this._name,this._id)}function Ej(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 Or(c,this._parents,this._name,this._id)}function Oj(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 kj(e,n,r){var o,i,l=Oj(n)?Lm:fr;return function(){var c=l(this,e),f=c.on;f!==o&&(i=(o=f).copy()).on(n,r),c.on=i}}function Cj(e,n){var r=this._id;return arguments.length<2?er(this.node(),r).on.on(e):this.each(kj(r,e,n))}function Aj(e){return function(){var n=this.parentNode;for(var r in this.__transition)if(+r!==e)return;n&&n.removeChild(this)}}function Nj(){return this.on("end.remove",Aj(this._id))}function Tj(e){var n=this._name,r=this._id;typeof e!="function"&&(e=_m(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,Bs(g[h],n,r,h,g,er(d,r)));return new Or(l,this._parents,n,r)}function Rj(e){var n=this._name,r=this._id;typeof e!="function"&&(e=K_(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=er(d,r),b=0,_=h.length;b<_;++b)(s=h[b])&&Bs(s,n,r,b,h,S);l.push(h),c.push(d)}return new Or(l,c,n,r)}var Pj=Wi.prototype.constructor;function Ij(){return new Pj(this._groups,this._parents)}function Mj(e,n){var r,o,i;return function(){var l=Ho(this,e),c=(this.style.removeProperty(e),Ho(this,e));return l===c?null:l===r&&c===o?i:i=n(r=l,o=c)}}function PS(e){return function(){this.style.removeProperty(e)}}function jj(e,n,r){var o,i=r+"",l;return function(){var c=Ho(this,e);return c===i?null:c===o?l:l=n(o=c,r)}}function Lj(e,n,r){var o,i,l;return function(){var c=Ho(this,e),f=r(this),m=f+"";return f==null&&(m=f=(this.style.removeProperty(e),Ho(this,e))),c===m?null:c===o&&m===i?l:(i=m,l=n(o=c,f))}}function Dj(e,n){var r,o,i,l="style."+n,c="end."+l,f;return function(){var m=fr(this,e),g=m.on,d=m.value[l]==null?f||(f=PS(n)):void 0;(g!==r||i!==d)&&(o=(r=g).copy()).on(c,i=d),m.on=o}}function Bj(e,n,r){var o=(e+="")=="transform"?BM:RS;return n==null?this.styleTween(e,Mj(e,o)).on("end.style."+e,PS(e)):typeof n=="function"?this.styleTween(e,Lj(e,o,Dm(this,"style."+e,n))).each(Dj(this._id,e)):this.styleTween(e,jj(e,o,n),r).on("end.style."+e,null)}function Fj(e,n,r){return function(o){this.style.setProperty(e,n.call(this,o),r)}}function qj(e,n,r){var o,i;function l(){var c=n.apply(this,arguments);return c!==i&&(o=(i=c)&&Fj(e,c,r)),o}return l._value=n,l}function zj(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,qj(e,n,r??""))}function Hj(e){return function(){this.textContent=e}}function Vj(e){return function(){var n=e(this);this.textContent=n??""}}function Uj(e){return this.tween("text",typeof e=="function"?Vj(Dm(this,"text",e)):Hj(e==null?"":e+""))}function Wj(e){return function(n){this.textContent=e.call(this,n)}}function Gj(e){var n,r;function o(){var i=e.apply(this,arguments);return i!==r&&(n=(r=i)&&Wj(i)),n}return o._value=e,o}function Kj(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,Gj(e))}function Yj(){for(var e=this._name,n=this._id,r=IS(),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=er(m,n);Bs(m,e,r,g,c,{time:d.time+d.delay+d.duration,delay:0,duration:d.duration,ease:d.ease})}return new Or(o,this._parents,e,r)}function Xj(){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=fr(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 Zj=0;function Or(e,n,r,o){this._groups=e,this._parents=n,this._name=r,this._id=o}function IS(){return++Zj}var kr=Wi.prototype;Or.prototype={constructor:Or,select:Tj,selectAll:Rj,selectChild:kr.selectChild,selectChildren:kr.selectChildren,filter:Sj,merge:Ej,selection:Ij,transition:Yj,call:kr.call,nodes:kr.nodes,node:kr.node,size:kr.size,empty:kr.empty,each:kr.each,on:Cj,attr:sj,attrTween:dj,style:Bj,styleTween:zj,text:Uj,textTween:Kj,remove:Nj,tween:ej,delay:mj,duration:yj,ease:wj,easeVarying:_j,end:Xj,[Symbol.iterator]:kr[Symbol.iterator]};function Qj(e){return((e*=2)<=1?e*e*e:(e-=2)*e*e+2)/2}var Jj={time:null,delay:0,duration:250,ease:Qj};function $j(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 e5(e){var n,r;e instanceof Or?(n=e._id,e=e._name):(n=IS(),(r=Jj).time=Pm(),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])&&Bs(m,e,n,g,c,r||$j(m,n));return new Or(o,this._parents,e,n)}Wi.prototype.interrupt=QM,Wi.prototype.transition=e5;const qs=e=>()=>e;function t5(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 Cr(e,n,r){this.k=e,this.x=n,this.y=r}Cr.prototype={constructor:Cr,scale:function(e){return e===1?this:new Cr(this.k*e,this.x,this.y)},translate:function(e,n){return e===0&n===0?this:new Cr(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 Ar=new Cr(1,0,0);Cr.prototype;function Bm(e){e.stopImmediatePropagation()}function ta(e){e.preventDefault(),e.stopImmediatePropagation()}function n5(e){return(!e.ctrlKey||e.type==="wheel")&&!e.button}function r5(){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 MS(){return this.__zoom||Ar}function o5(e){return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*(e.ctrlKey?10:1)}function i5(){return navigator.maxTouchPoints||"ontouchstart"in this}function a5(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 jS(){var e=n5,n=r5,r=a5,o=o5,i=i5,l=[0,1/0],c=[[-1/0,-1/0],[1/0,1/0]],f=250,m=VM,g=_s("start","zoom","end"),d,p,h,s=500,S=150,b=0,_=10;function w(B){B.property("__zoom",MS).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 he=B.selection?B.selection():B;he.property("__zoom",MS),B!==he?k(B,U,J,oe):he.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 he=this.__zoom.k,Y=typeof U=="function"?U.apply(this,arguments):U;return he*Y},J,oe)},w.scaleTo=function(B,U,J,oe){w.transform(B,function(){var he=n.apply(this,arguments),Y=this.__zoom,ee=J==null?x(he):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),he,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,he){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(Ar.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,he)};function y(B,U){return U=Math.max(l[0],Math.min(l[1],U)),U===B.k?B:new Cr(U,B.x,B.y)}function E(B,U,J){var oe=U[0]-J[0]*B.k,he=U[1]-J[1]*B.k;return oe===B.x&&he===B.y?B:new Cr(B.k,oe,he)}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 he=this,Y=arguments,ee=P(he,Y).event(oe),W=n.apply(he,Y),ne=J==null?x(W):typeof J=="function"?J.apply(he,Y):J,ae=Math.max(W[1][0]-W[0][0],W[1][1]-W[0][1]),te=he.__zoom,re=typeof U=="function"?U.apply(he,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 Cr(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=Mn(this.that).datum();g.call(B,this.that,new t5(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,he=Math.max(l[0],Math.min(l[1],oe.k*Math.pow(2,o.apply(this,arguments)))),Y=Jn(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===he)return;J.mouse=[Y,oe.invert(Y)],Fs(this),J.start()}ta(B),J.wheel=setTimeout(ee,S),J.zoom("mouse",r(E(y(oe,he),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),he=Mn(B.view).on("mousemove.zoom",ne,!0).on("mouseup.zoom",ae,!0),Y=Jn(B,J),ee=B.clientX,W=B.clientY;oS(B.view),Bm(B),oe.mouse=[Y,this.__zoom.invert(Y)],Fs(this),oe.start();function ne(te){if(ta(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]=Jn(te,J),oe.mouse[1]),oe.extent,c))}function ae(te){he.on("mousemove.zoom mouseup.zoom",null),iS(te.view,oe.moved),ta(te),oe.event(te).end()}}function L(B,...U){if(e.apply(this,arguments)){var J=this.__zoom,oe=Jn(B.changedTouches?B.changedTouches[0]:B,this),he=J.invert(oe),Y=J.k*(B.shiftKey?.5:2),ee=r(E(y(J,Y),oe,he),n.apply(this,U),c);ta(B),f>0?Mn(this).transition().duration(f).call(k,ee,oe,B):Mn(this).call(w.transform,ee,oe,B)}}function M(B,...U){if(e.apply(this,arguments)){var J=B.touches,oe=J.length,he=P(this,U,B.changedTouches.length===oe).event(B),Y,ee,W,ne;for(Bm(B),ee=0;ee<oe;++ee)W=J[ee],ne=Jn(W,this),ne=[ne,this.__zoom.invert(ne),W.identifier],he.touch0?!he.touch1&&he.touch0[2]!==ne[2]&&(he.touch1=ne,he.taps=0):(he.touch0=ne,Y=!0,he.taps=1+!!d);d&&(d=clearTimeout(d)),Y&&(he.taps<2&&(p=ne[0],d=setTimeout(function(){d=null},s)),Fs(this),he.start())}}function D(B,...U){if(this.__zooming){var J=P(this,U).event(B),oe=B.changedTouches,he=oe.length,Y,ee,W,ne;for(ta(B),Y=0;Y<he;++Y)ee=oe[Y],W=Jn(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,he=oe.length,Y,ee;for(Bm(B),h&&clearTimeout(h),h=setTimeout(function(){h=null},s),Y=0;Y<he;++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=Jn(ee,this),Math.hypot(p[0]-ee[0],p[1]-ee[1])<_)){var W=Mn(this).on("dblclick.zoom");W&&W.apply(this,arguments)}}}return w.wheelDelta=function(B){return arguments.length?(o=typeof B=="function"?B:qs(+B),w):o},w.filter=function(B){return arguments.length?(e=typeof B=="function"?B:qs(!!B),w):e},w.touchable=function(B){return arguments.length?(i=typeof B=="function"?B:qs(!!B),w):i},w.extent=function(B){return arguments.length?(n=typeof B=="function"?B:qs([[+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 zs=ce.createContext(null),s5=zs.Provider,Nr={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.`},LS=Nr.error001();function Nt(e,n){const r=ce.useContext(zs);if(r===null)throw new Error(LS);return H_(r,e,n)}const $t=()=>{const e=ce.useContext(zs);if(e===null)throw new Error(LS);return ce.useMemo(()=>({getState:e.getState,setState:e.setState,subscribe:e.subscribe,destroy:e.destroy}),[e])},l5=e=>e.userSelectionActive?"none":"all";function Fm({position:e,children:n,className:r,style:o,...i}){const l=Nt(l5),c=`${e}`.split("-");return K.jsx("div",{className:ln(["react-flow__panel",r,...c]),style:{...o,pointerEvents:l},...i,children:n})}function u5({proOptions:e,position:n="bottom-right"}){return e?.hideAttribution?null:K.jsx(Fm,{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 c5=({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=ce.useRef(null),[h,s]=ce.useState({x:0,y:0,width:0,height:0}),S=ln(["react-flow__edge-textwrapper",g]);return ce.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 f5=ce.memo(c5);const qm=e=>({width:e.offsetWidth,height:e.offsetHeight}),Go=(e,n=0,r=1)=>Math.min(Math.max(e,n),r),zm=(e={x:0,y:0},n)=>({x:Go(e.x,n[0][0],n[1][0]),y:Go(e.y,n[0][1],n[1][1])}),DS=(e,n,r)=>e<n?Go(Math.abs(e-n),1,50)/50:e>r?-Go(Math.abs(e-r),1,50)/50:0,BS=(e,n)=>{const r=DS(e.x,35,n.width-35)*20,o=DS(e.y,35,n.height-35)*20;return[r,o]},FS=e=>e.getRootNode?.()||window?.document,qS=(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)}),na=({x:e,y:n,width:r,height:o})=>({x:e,y:n,x2:e+r,y2:n+o}),zS=({x:e,y:n,x2:r,y2:o})=>({x:e,y:n,width:r-e,height:o-n}),HS=e=>({...e.positionAbsolute||{x:0,y:0},width:e.width||0,height:e.height||0}),d5=(e,n)=>zS(qS(na(e),na(n))),Hm=(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)},h5=e=>jn(e.width)&&jn(e.height)&&jn(e.x)&&jn(e.y),jn=e=>!isNaN(e)&&isFinite(e),en=Symbol.for("internals"),VS=["Enter"," ","Escape"],p5=(e,n)=>{},m5=e=>"nativeEvent"in e;function Vm(e){const r=(m5(e)?e.nativeEvent:e).composedPath?.()?.[0]||e.target;return["INPUT","SELECT","TEXTAREA"].includes(r?.nodeName)||r?.hasAttribute("contenteditable")||!!r?.closest(".nokey")}const US=e=>"clientX"in e,Kr=(e,n)=>{const r=US(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)}},Hs=()=>typeof navigator<"u"&&navigator?.userAgent?.indexOf("Mac")>=0,ra=({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&&jn(r)&&jn(o)?K.jsx(f5,{x:r,y:o,label:i,labelStyle:l,labelShowBg:c,labelBgStyle:f,labelBgPadding:m,labelBgBorderRadius:g}):null]});ra.displayName="BaseEdge";function oa(e,n,r){return r===void 0?r:o=>{const i=n().edges.find(l=>l.id===e);i&&r(o,{...i})}}function WS({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 GS({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 go;(function(e){e.Strict="strict",e.Loose="loose"})(go||(go={}));var vo;(function(e){e.Free="free",e.Vertical="vertical",e.Horizontal="horizontal"})(vo||(vo={}));var ia;(function(e){e.Partial="partial",e.Full="full"})(ia||(ia={}));var dr;(function(e){e.Bezier="default",e.Straight="straight",e.Step="step",e.SmoothStep="smoothstep",e.SimpleBezier="simplebezier"})(dr||(dr={}));var Vs;(function(e){e.Arrow="arrow",e.ArrowClosed="arrowclosed"})(Vs||(Vs={}));var Be;(function(e){e.Left="left",e.Top="top",e.Right="right",e.Bottom="bottom"})(Be||(Be={}));function KS({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 YS({sourceX:e,sourceY:n,sourcePosition:r=Be.Bottom,targetX:o,targetY:i,targetPosition:l=Be.Top}){const[c,f]=KS({pos:r,x1:e,y1:n,x2:o,y2:i}),[m,g]=KS({pos:l,x1:o,y1:i,x2:e,y2:n}),[d,p,h,s]=GS({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 Um=ce.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]=YS({sourceX:e,sourceY:n,sourcePosition:i,targetX:r,targetY:o,targetPosition:l});return K.jsx(ra,{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})});Um.displayName="SimpleBezierEdge";const XS={[Be.Left]:{x:-1,y:0},[Be.Right]:{x:1,y:0},[Be.Top]:{x:0,y:-1},[Be.Bottom]:{x:0,y:1}},g5=({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},ZS=(e,n)=>Math.sqrt(Math.pow(n.x-e.x,2)+Math.pow(n.y-e.y,2));function v5({source:e,sourcePosition:n=Be.Bottom,target:r,targetPosition:o=Be.Top,center:i,offset:l}){const c=XS[n],f=XS[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=g5({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]=WS({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 y5(e,n,r,o){const i=Math.min(ZS(e,n)/2,ZS(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 Wm({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]=v5({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=y5(d[y-1],w,d[y+1],c):E=`${y===0?"M":"L"}${w.x} ${w.y}`,_+=E,_},""),p,h,s,S]}const Us=ce.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]=Wm({sourceX:e,sourceY:n,sourcePosition:p,targetX:r,targetY:o,targetPosition:h,borderRadius:b?.borderRadius,offset:b?.offset});return K.jsx(ra,{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:_})});Us.displayName="SmoothStepEdge";const Gm=ce.memo(e=>K.jsx(Us,{...e,pathOptions:ce.useMemo(()=>({borderRadius:0,offset:e.pathOptions?.offset}),[e.pathOptions?.offset])}));Gm.displayName="StepEdge";function b5({sourceX:e,sourceY:n,targetX:r,targetY:o}){const[i,l,c,f]=WS({sourceX:e,sourceY:n,targetX:r,targetY:o});return[`M ${e},${n}L ${r},${o}`,i,l,c,f]}const Km=ce.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,_]=b5({sourceX:e,sourceY:n,targetX:r,targetY:o});return K.jsx(ra,{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})});Km.displayName="StraightEdge";function Ws(e,n){return e>=0?.5*e:n*25*Math.sqrt(-e)}function QS({pos:e,x1:n,y1:r,x2:o,y2:i,c:l}){switch(e){case Be.Left:return[n-Ws(n-o,l),r];case Be.Right:return[n+Ws(o-n,l),r];case Be.Top:return[n,r-Ws(r-i,l)];case Be.Bottom:return[n,r+Ws(i-r,l)]}}function JS({sourceX:e,sourceY:n,sourcePosition:r=Be.Bottom,targetX:o,targetY:i,targetPosition:l=Be.Top,curvature:c=.25}){const[f,m]=QS({pos:r,x1:e,y1:n,x2:o,y2:i,c}),[g,d]=QS({pos:l,x1:o,y1:i,x2:e,y2:n,c}),[p,h,s,S]=GS({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 Gs=ce.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]=JS({sourceX:e,sourceY:n,sourcePosition:i,targetX:r,targetY:o,targetPosition:l,curvature:b?.curvature});return K.jsx(ra,{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:_})});Gs.displayName="BezierEdge";const Ym=ce.createContext(null),w5=Ym.Provider;Ym.Consumer;const x5=()=>ce.useContext(Ym),_5=e=>"id"in e&&"source"in e&&"target"in e,S5=({source:e,sourceHandle:n,target:r,targetHandle:o})=>`reactflow__edge-${e}${n||""}-${r}${o||""}`,Xm=(e,n)=>typeof e>"u"?"":typeof e=="string"?e:`${n?`${n}__`:""}${Object.keys(e).sort().map(o=>`${o}=${e[o]}`).join("&")}`,E5=(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)),O5=(e,n)=>{if(!e.source||!e.target)return n;let r;return _5(e)?r={...e}:r={...e,id:S5(e)},E5(r,n)?n:n.concat(r)},$S=({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},k5=({x:e,y:n},[r,o,i])=>({x:e*i+r,y:n*i+o}),yo=(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}},Ks=(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}=yo(i,n).positionAbsolute;return qS(o,na({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 zS(r)},eE=(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}=yo(d,f),_={x:b.x,y:b.y,width:p||0,height:h||0},w=Hm(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},tE=(e,n)=>{const r=e.map(o=>o.id);return n.filter(o=>r.includes(o.source)||r.includes(o.target))},nE=(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=Go(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]},bo=(e,n=0)=>e.transition().duration(n);function rE(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 C5(e,n,r,o,i,l){const{x:c,y:f}=Kr(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=Zm(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:oE()};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 A5={source:null,target:null,sourceHandle:null,targetHandle:null},oE=()=>({handleDomNode:null,isValid:!1,connection:A5,endHandle:null});function iE(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={...oE(),handleDomNode:m};if(m){const d=Zm(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===go.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 N5({nodes:e,nodeId:n,handleId:r,handleType:o}){return e.reduce((i,l)=>{if(l[en]){const{handleBounds:c}=l[en];let f=[],m=[];c&&(f=rE(l,c,"source",`${n}-${r}-${o}`),m=rE(l,c,"target",`${n}-${r}-${o}`)),i.push(...f,...m)}return i},[])}function Zm(e,n){return e||(n?.classList.contains("target")?"target":n?.classList.contains("source")?"source":null)}function Qm(e){e?.classList.remove("valid","connecting","react-flow__handle-valid","react-flow__handle-connecting")}function T5(e,n){let r=null;return n?r="valid":e&&!n&&(r="invalid"),r}function aE({event:e,handleId:n,nodeId:r,onConnect:o,isTarget:i,getState:l,setState:c,isValidConnection:f,edgeUpdaterType:m,onEdgeUpdateEnd:g}){const d=FS(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}=Kr(e),R=d?.elementFromPoint(k,P),j=Zm(m,R),z=h?.getBoundingClientRect();if(!z||!j)return;let L,M=Kr(e,z),D=!1,F=null,B=!1,U=null;const J=N5({nodes:w(),nodeId:r,handleId:n,handleType:j}),oe=()=>{if(!s)return;const[ee,W]=BS(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 he(ee){const{transform:W}=l();M=Kr(ee,z);const{handle:ne,validHandleResult:ae}=C5(ee,d,$S(M,W,!1,[1,1]),S,J,te=>iE(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?k5({x:x.x,y:x.y},W):M,connectionStatus:T5(!!x,B),connectionEndHandle:ae.endHandle}),!x&&!B&&!U)return Qm(L);F.source!==F.target&&U&&(Qm(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),Qm(L),y(),cancelAnimationFrame(E),D=!1,B=!1,F=null,U=null,d.removeEventListener("mousemove",he),d.removeEventListener("mouseup",Y),d.removeEventListener("touchmove",he),d.removeEventListener("touchend",Y)}d.addEventListener("mousemove",he),d.addEventListener("mouseup",Y),d.addEventListener("touchmove",he),d.addEventListener("touchend",Y)}const sE=()=>!0,R5=e=>({connectionStartHandle:e.connectionStartHandle,connectOnClick:e.connectOnClick,noPanClassName:e.noPanClassName}),P5=(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}},lE=ce.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",_=$t(),w=x5(),{connectOnClick:y,noPanClassName:E}=Nt(R5,sn),{connecting:x,clickConnecting:k}=Nt(P5(w,S,e),sn);w||_.getState().onError?.("010",Nr.error010());const P=z=>{const{defaultEdgeOptions:L,onConnect:M,hasDefaultEdges:D}=_.getState(),F={...L,...z};if(D){const{edges:B,setEdges:U}=_.getState();U(O5(F,B))}M?.(F),f?.(F)},R=z=>{if(!w)return;const L=US(z);i&&(L&&z.button===0||!L)&&aE({event:z,handleId:S,nodeId:w,onConnect:P,isTarget:b,getState:_.getState,setState:_.setState,isValidConnection:r||_.getState().isValidConnection||sE}),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=FS(z.target),J=r||B||sE,{connection:oe,isValid:he}=iE({nodeId:w,id:S,type:e},F,D.nodeId,D.handleId||null,D.type,J,U);he&&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:ln(["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})});lE.displayName="Handle";var Ft=ce.memo(lE);const uE=({data:e,isConnectable:n,targetPosition:r=Be.Top,sourcePosition:o=Be.Bottom})=>K.jsxs(K.Fragment,{children:[K.jsx(Ft,{type:"target",position:r,isConnectable:n}),e?.label,K.jsx(Ft,{type:"source",position:o,isConnectable:n})]});uE.displayName="DefaultNode";var Jm=ce.memo(uE);const cE=({data:e,isConnectable:n,sourcePosition:r=Be.Bottom})=>K.jsxs(K.Fragment,{children:[e?.label,K.jsx(Ft,{type:"source",position:r,isConnectable:n})]});cE.displayName="InputNode";var fE=ce.memo(cE);const dE=({data:e,isConnectable:n,targetPosition:r=Be.Top})=>K.jsxs(K.Fragment,{children:[K.jsx(Ft,{type:"target",position:r,isConnectable:n}),e?.label]});dE.displayName="OutputNode";var hE=ce.memo(dE);const $m=()=>null;$m.displayName="GroupNode";const I5=e=>({selectedNodes:e.getNodes().filter(n=>n.selected),selectedEdges:e.edges.filter(n=>n.selected)}),Ys=e=>e.id;function M5(e,n){return sn(e.selectedNodes.map(Ys),n.selectedNodes.map(Ys))&&sn(e.selectedEdges.map(Ys),n.selectedEdges.map(Ys))}const pE=ce.memo(({onSelectionChange:e})=>{const n=$t(),{selectedNodes:r,selectedEdges:o}=Nt(I5,M5);return ce.useEffect(()=>{const i={nodes:r,edges:o};e?.(i),n.getState().onSelectionChange?.(i)},[r,o,e]),null});pE.displayName="SelectionListener";const j5=e=>!!e.onSelectionChange;function L5({onSelectionChange:e}){const n=Nt(j5);return e||n?K.jsx(pE,{onSelectionChange:e}):null}const D5=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 Ko(e,n){ce.useEffect(()=>{typeof e<"u"&&n(e)},[e])}function mt(e,n,r){ce.useEffect(()=>{typeof n<"u"&&r({[e]:n})},[n])}const B5=({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:he,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}=Nt(D5,sn),Ce=$t();return ce.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",he,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),Ko(e,ge),Ko(n,be),Ko(b,Ue),Ko(_,Ve),Ko(j,Fe),Ko(w,Pe),null},mE={display:"none"},F5={position:"absolute",width:1,height:1,margin:-1,border:0,padding:0,overflow:"hidden",clip:"rect(0px, 0px, 0px, 0px)",clipPath:"inset(100%)"},gE="react-flow__node-desc",vE="react-flow__edge-desc",q5="react-flow__aria-live",z5=e=>e.ariaLiveMessage;function H5({rfId:e}){const n=Nt(z5);return K.jsx("div",{id:`${q5}-${e}`,"aria-live":"assertive","aria-atomic":"true",style:F5,children:n})}function V5({rfId:e,disableKeyboardA11y:n}){return K.jsxs(K.Fragment,{children:[K.jsxs("div",{id:`${gE}-${e}`,style:mE,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:`${vE}-${e}`,style:mE,children:"Press enter or space to select an edge. You can then press delete to remove it or escape to cancel."}),!n&&K.jsx(H5,{rfId:e})]})}const U5=typeof document<"u"?document:null;var aa=(e=null,n={target:U5})=>{const[r,o]=ce.useState(!1),i=ce.useRef(!1),l=ce.useRef(new Set([])),[c,f]=ce.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 ce.useEffect(()=>{if(e!==null){const m=p=>{if(i.current=p.ctrlKey||p.metaKey||p.shiftKey,!i.current&&Vm(p))return!1;const h=bE(p.code,f);l.current.add(p[h]),yE(c,l.current,!1)&&(p.preventDefault(),o(!0))},g=p=>{if(!i.current&&Vm(p))return!1;const h=bE(p.code,f);yE(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 yE(e,n,r){return e.filter(o=>r||o.length===n.size).some(o=>o.every(i=>n.has(i)))}function bE(e,n){return n.includes(e)?"code":"key"}function wE(e,n,r,o){if(!e.parentNode)return r;const i=n.get(e.parentNode),l=yo(i,o);return wE(i,n,{x:(r.x??0)+l.x,y:(r.y??0)+l.y,z:(i[en]?.z??0)>(r.z??0)?i[en]?.z??0:r.z??0},o)}function xE(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}=wE(o,e,{...o.position,z:o[en]?.z??0},n);o.positionAbsolute={x:i,y:l},o[en].z=c,r?.[o.id]&&(o[en].isParent=!0)}})}function eg(e,n,r,o){const i=new Map,l={},c=o?1e3:0;return e.forEach(f=>{const m=(jn(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,en,{enumerable:!1,value:{handleBounds:g?.[en]?.handleBounds,z:m}}),i.set(f.id,d)}),xE(i,r,l),i}function _E(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 _=Ks(S,p),[w,y,E]=nE(_,o,i,n.minZoom??l,n.maxZoom??c,n.padding??.1),x=Ar.translate(w,y).scale(E);return typeof n.duration=="number"&&n.duration>0?f.transform(bo(m,n.duration),x):f.transform(m,x),!0}}return!1}function W5(e,n){return e.forEach(r=>{const o=n.get(r.id);o&&n.set(o.id,{...o,[en]:o[en],selected:r.selected})}),new Map(n)}function G5(e,n){return n.map(r=>{const o=e.find(i=>i.id===r.id);return o&&(r.selected=o.selected),r})}function Xs({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:W5(e,i)}),c?.(e)),n?.length&&(g&&o({edges:G5(n,l)}),f?.(n))}const Yo=()=>{},K5={zoomIn:Yo,zoomOut:Yo,zoomTo:Yo,getZoom:()=>1,setViewport:Yo,getViewport:()=>({x:0,y:0,zoom:1}),fitView:()=>!1,setCenter:Yo,fitBounds:Yo,project:e=>e,viewportInitialized:!1},Y5=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection}),X5=()=>{const e=$t(),{d3Zoom:n,d3Selection:r}=Nt(Y5,sn);return ce.useMemo(()=>r&&n?{zoomIn:i=>n.scaleBy(bo(r,i?.duration),1.2),zoomOut:i=>n.scaleBy(bo(r,i?.duration),1/1.2),zoomTo:(i,l)=>n.scaleTo(bo(r,l?.duration),i),getZoom:()=>e.getState().transform[2],setViewport:(i,l)=>{const[c,f,m]=e.getState().transform,g=Ar.translate(i.x??c,i.y??f).scale(i.zoom??m);n.transform(bo(r,l?.duration),g)},getViewport:()=>{const[i,l,c]=e.getState().transform;return{x:i,y:l,zoom:c}},fitView:i=>_E(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=Ar.translate(p,h).scale(d);n.transform(bo(r,c?.duration),s)},fitBounds:(i,l)=>{const{width:c,height:f,minZoom:m,maxZoom:g}=e.getState(),[d,p,h]=nE(i,c,f,m,g,l?.padding??.1),s=Ar.translate(d,p).scale(h);n.transform(bo(r,l?.duration),s)},project:i=>{const{transform:l,snapToGrid:c,snapGrid:f}=e.getState();return $S(i,l,c,f)},viewportInitialized:!0}:K5,[n,r])};function Zs(){const e=X5(),n=$t(),r=ce.useCallback(()=>n.getState().getNodes().map(b=>({...b})),[]),o=ce.useCallback(b=>n.getState().nodeInternals.get(b),[]),i=ce.useCallback(()=>{const{edges:b=[]}=n.getState();return b.map(_=>({..._}))},[]),l=ce.useCallback(b=>{const{edges:_=[]}=n.getState();return _.find(w=>w.id===b)},[]),c=ce.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=ce.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=ce.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=ce.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=ce.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=ce.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=tE(D,F),J=[...B,...U],oe=J.reduce((he,Y)=>(he.includes(Y.id)||he.push(Y.id),he),[]);if((k||x)&&(k&&n.setState({edges:E.filter(he=>!oe.includes(he.id))}),x&&(D.forEach(he=>{w.delete(he.id)}),n.setState({nodeInternals:new Map(w)}))),oe.length>0&&(R?.(J),z&&z(oe.map(he=>({id:he,type:"remove"})))),D.length>0&&(P?.(D),j)){const he=D.map(Y=>({id:Y.id,type:"remove"}));j(he)}}},[]),h=ce.useCallback(b=>{const _=h5(b),w=_?null:n.getState().nodeInternals.get(b.id);return[_?b:HS(w),w,_]},[]),s=ce.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=HS(k),R=Hm(P,y);return _&&R>0||R>=b.width*b.height}):[]},[]),S=ce.useCallback((b,_,w=!0)=>{const[y]=h(b);if(!y)return!1;const E=Hm(y,_);return w&&E>0||E>=b.width*b.height},[]);return ce.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 Z5=({deleteKeyCode:e,multiSelectionKeyCode:n})=>{const r=$t(),{deleteElements:o}=Zs(),i=aa(e),l=aa(n);ce.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]),ce.useEffect(()=>{r.setState({multiSelectionActive:l})},[l])};function Q5(e){const n=$t();ce.useEffect(()=>{let r;const o=()=>{if(!e.current)return;const i=qm(e.current);(i.height===0||i.width===0)&&n.getState().onError?.("004",Nr.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 tg={position:"absolute",width:"100%",height:"100%",top:0,left:0},J5=(e,n)=>e.x!==n.x||e.y!==n.y||e.zoom!==n.k,Qs=e=>({x:e.x,y:e.y,zoom:e.k}),Xo=(e,n)=>e.target.closest(`.${n}`),SE=(e,n)=>n===2&&Array.isArray(e)&&e.includes(2),EE=e=>{const n=e.ctrlKey&&Hs()?10:1;return-e.deltaY*(e.deltaMode===1?.05:e.deltaMode?1:.002)*n},$5=e=>({d3Zoom:e.d3Zoom,d3Selection:e.d3Selection,d3ZoomHandler:e.d3ZoomHandler,userSelectionActive:e.userSelectionActive}),eL=({onMove:e,onMoveStart:n,onMoveEnd:r,onPaneContextMenu:o,zoomOnScroll:i=!0,zoomOnPinch:l=!0,panOnScroll:c=!1,panOnScrollSpeed:f=.5,panOnScrollMode:m=vo.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=ce.useRef(),P=$t(),R=ce.useRef(!1),j=ce.useRef(!1),z=ce.useRef(null),L=ce.useRef({x:0,y:0,zoom:0}),{d3Zoom:M,d3Selection:D,d3ZoomHandler:F,userSelectionActive:B}=Nt($5,sn),U=aa(_),J=ce.useRef(0),oe=ce.useRef(!1),he=ce.useRef();return Q5(z),ce.useEffect(()=>{if(z.current){const Y=z.current.getBoundingClientRect(),ee=jS().scaleExtent([S,b]).translateExtent(s),W=Mn(z.current).call(ee),ne=Ar.translate(h.x,h.y).scale(Go(h.zoom,S,b)),ae=[[0,0],[Y.width,Y.height]],te=ee.constrain()(ne,ae,s);ee.transform(W,te),ee.wheelDelta(EE),P.setState({d3Zoom:ee,d3Selection:W,d3ZoomHandler:W.on("wheel.zoom"),transform:[te.x,te.y,te.k],domNode:z.current.closest(".react-flow")})}},[]),ce.useEffect(()=>{D&&M&&(c&&!U&&!B?D.on("wheel.zoom",Y=>{if(Xo(Y,E))return!1;Y.preventDefault(),Y.stopImmediatePropagation();const ee=D.property("__zoom").k||1,W=Hs();if(Y.ctrlKey&&l&&W){const ge=Jn(Y),be=EE(Y),Ae=ee*Math.pow(2,be);M.scaleTo(D,Ae,ge,Y);return}const ne=Y.deltaMode===1?20:1;let ae=m===vo.Vertical?0:Y.deltaX*ne,te=m===vo.Horizontal?0:Y.deltaY*ne;!W&&Y.shiftKey&&m!==vo.Vertical&&(ae=Y.deltaY*ne,te=0),M.translateBy(D,-(ae/ee)*f,-(te/ee)*f,{internal:!0});const re=Qs(D.property("__zoom")),{onViewportChangeStart:Z,onViewportChange:se,onViewportChangeEnd:pe}=P.getState();clearTimeout(he.current),oe.current||(oe.current=!0,n?.(Y,re),Z?.(re)),oe.current&&(e?.(Y,re),se?.(re),he.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||Xo(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]),ce.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=Qs(Y.transform);R.current=!0,L.current=W,Y.sourceEvent?.type==="mousedown"&&P.setState({paneDragging:!0}),ee?.(W),n?.(Y.sourceEvent,W)})},[M,n]),ce.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&&SE(p,J.current??0)),(e||ee)&&!Y.sourceEvent?.internal){const W=Qs(Y.transform);ee?.(W),e?.(Y.sourceEvent,W)}}))},[B,M,e,p,o]),ce.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&&SE(p,J.current??0)&&!j.current&&o(Y.sourceEvent),j.current=!1,(r||ee)&&J5(L.current,Y.transform)){const W=Qs(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]),ce.useEffect(()=>{M&&M.filter(Y=>{const ee=U||i,W=l&&Y.ctrlKey;if(Y.button===1&&Y.type==="mousedown"&&(Xo(Y,"react-flow__node")||Xo(Y,"react-flow__edge")))return!0;if(!p&&!ee&&!c&&!g&&!l||B||!g&&Y.type==="dblclick"||Xo(Y,E)&&Y.type==="wheel"||Xo(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:tg,children:y})},tL=e=>({userSelectionActive:e.userSelectionActive,userSelectionRect:e.userSelectionRect});function nL(){const{userSelectionActive:e,userSelectionRect:n}=Nt(tL,sn);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 OE(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 kE(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&&OE(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&&OE(o,c);break}case"remove":return o}return o.push(c),o},r)}function CE(e,n){return kE(e,n)}function rL(e,n){return kE(e,n)}const Yr=(e,n)=>({id:e,type:"select",selected:n});function Zo(e,n){return e.reduce((r,o)=>{const i=n.includes(o.id);return!o.selected&&i?(o.selected=!0,r.push(Yr(o.id,!0))):o.selected&&!i&&(o.selected=!1,r.push(Yr(o.id,!1))),r},[])}const ng=(e,n)=>r=>{r.target===n.current&&e?.(r)},oL=e=>({userSelectionActive:e.userSelectionActive,elementsSelectable:e.elementsSelectable,dragging:e.paneDragging}),AE=ce.memo(({isSelecting:e,selectionMode:n=ia.Full,panOnDrag:r,onSelectionStart:o,onSelectionEnd:i,onPaneClick:l,onPaneContextMenu:c,onPaneScroll:f,onPaneMouseEnter:m,onPaneMouseMove:g,onPaneMouseLeave:d,children:p})=>{const h=ce.useRef(null),s=$t(),S=ce.useRef(0),b=ce.useRef(0),_=ce.useRef(),{userSelectionActive:w,elementsSelectable:y,dragging:E}=Nt(oL,sn),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}=Kr(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:he,onEdgesChange:Y,nodeOrigin:ee,getNodes:W}=s.getState();if(!e||!_.current||!B)return;s.setState({userSelectionActive:!0,nodesSelectionActive:!1});const ne=Kr(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=eE(U,re,oe,n===ia.Partial,!0,ee),pe=tE(se,J).map(be=>be.id),ge=se.map(be=>be.id);if(S.current!==ge.length){S.current=ge.length;const be=Zo(Z,ge);be.length&&he?.(be)}if(b.current!==pe.length){b.current=pe.length;const be=Zo(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:ln(["react-flow__pane",{dragging:E,selection:e}]),onClick:D?void 0:ng(k,h),onContextMenu:ng(P,h),onWheel:ng(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:tg,children:[p,K.jsx(nL,{})]})});AE.displayName="Pane";function NE(e,n){if(!e.parentNode)return!1;const r=n.get(e.parentNode);return r?r.selected?!0:NE(r,n):!1}function TE(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 iL(e,n,r,o){return Array.from(e.values()).filter(i=>(i.selected||i.id===o)&&(!i.parentNode||!NE(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 aL(e,n){return!n||n==="parent"?n:[n[0],[n[1][0]-(e.width||0),n[1][1]-(e.height||0)]]}function RE(e,n,r,o,i=[0,0],l){const c=aL(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}=yo(d,i).positionAbsolute;f=d&&jn(p)&&jn(h)&&jn(d.width)&&jn(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",Nr.error005()),f=c;else if(e.extent&&e.parentNode){const d=r.get(e.parentNode),{x:p,y:h}=yo(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=yo(d,i).positionAbsolute}const g=f&&f!=="parent"?zm(n,f):n;return{position:{x:g.x-m.x,y:g.y-m.y},positionAbsolute:g}}function rg({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 PE=(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,...qm(m)}})};function sa(e,n,r){return r===void 0?r:o=>{const i=n().nodeInternals.get(e);i&&r(o,{...i})}}function og({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",Nr.error012(e));return}n.setState({nodesSelectionActive:!1}),g.selected?(r||g.selected&&c)&&(l({nodes:[g]}),requestAnimationFrame(()=>o?.current?.blur())):i([e])}function sL(){const e=$t();return ce.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 ig(e){return(n,r,o)=>e?.(n,o)}function IE({nodeRef:e,disabled:n=!1,noDragClassName:r,handleSelector:o,nodeId:i,isSelectable:l,selectNodesOnDrag:c}){const f=$t(),[m,g]=ce.useState(!1),d=ce.useRef([]),p=ce.useRef({x:null,y:null}),h=ce.useRef(0),s=ce.useRef(null),S=ce.useRef({x:0,y:0}),b=ce.useRef(null),_=ce.useRef(!1),w=sL();return ce.useEffect(()=>{if(e?.current){const y=Mn(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=Ks(d.current,B);oe=na(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=RE(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 he=i?j:ig(z);if(he&&b.current){const[Y,ee]=rg({nodeId:i,dragItems:d.current,nodeInternals:R});he(b.current,Y,ee)}},x=()=>{if(!s.current)return;const[k,P]=BS(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=vM().on("start",P=>{const{nodeInternals:R,multiSelectionActive:j,domNode:z,nodesDraggable:L,unselectNodesAndEdges:M,onNodeDragStart:D,onSelectionDragStart:F}=f.getState(),B=i?D:ig(F);!c&&!j&&i&&(R.get(i)?.selected||M()),i&&l&&c&&og({id:i,store:f,nodeRef:e});const U=w(P);if(p.current=U,d.current=iL(R,L,U,i),B&&d.current){const[J,oe]=rg({nodeId:i,dragItems:d.current,nodeInternals:R});B(P.sourceEvent,J,oe)}s.current=z?.getBoundingClientRect()||null,S.current=Kr(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=Kr(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:ig(L);if(R(d.current,!1,!1),M){const[D,F]=rg({nodeId:i,dragItems:d.current,nodeInternals:j});M(P.sourceEvent,D,F)}}}).filter(P=>{const R=P.target;return!P.button&&(!r||!TE(R,`.${r}`,e))&&(!o||TE(R,o,e))});return y.call(k),()=>{y.on(".drag",null)}}}},[e,n,r,o,l,f,i,c,w]),m}function ME(){const e=$t();return ce.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}=RE(y,E,o,i,void 0,g);y.position=k,y.positionAbsolute=x}return y});l(w,!0,!1)},[])}const Qo={ArrowUp:{x:0,y:-1},ArrowDown:{x:0,y:1},ArrowLeft:{x:-1,y:0},ArrowRight:{x:1,y:0}};var la=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:he,rfId:Y})=>{const ee=$t(),W=ce.useRef(null),ne=ce.useRef(R),ae=ce.useRef(j),te=ce.useRef(o),re=E||y||d||p||h||s,Z=ME(),se=sa(r,ee.getState,p),pe=sa(r,ee.getState,h),ge=sa(r,ee.getState,s),be=sa(r,ee.getState,S),Ae=sa(r,ee.getState,b),Ue=Pe=>{if(E&&(!P||!y)&&og({id:r,store:ee,nodeRef:W}),d){const ut=ee.getState().nodeInternals.get(r);ut&&d(Pe,{...ut})}},Ve=Pe=>{if(!Vm(Pe))if(VS.includes(Pe.key)&&E){const ut=Pe.key==="Escape";og({id:r,store:ee,unselect:ut,nodeRef:W})}else!oe&&y&&g&&Object.prototype.hasOwnProperty.call(Qo,Pe.key)&&(ee.setState({ariaLiveMessage:`Moved selected node ${Pe.key.replace("Arrow","").toLowerCase()}. New position, x: ${~~l}, y: ${~~c}`}),Z({x:Qo[Pe.key].x,y:Qo[Pe.key].y,isShiftPressed:Pe.shiftKey}))};ce.useEffect(()=>{if(W.current&&!z){const Pe=W.current;return L?.observe(Pe),()=>L?.unobserve(Pe)}},[z]),ce.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=IE({nodeRef:W,disabled:z||!y,noDragClassName:B,handleSelector:M,nodeId:r,isSelectable:E,selectNodesOnDrag:P});return z?null:K.jsx("div",{className:ln(["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:`${gE}-${Y}`,"aria-label":he,children:K.jsx(w5,{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",ce.memo(n)};const lL=e=>{const n=e.getNodes().filter(r=>r.selected);return{...Ks(n,e.nodeOrigin),transformString:`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`,userSelectionActive:e.userSelectionActive}};function uL({onSelectionContextMenu:e,noPanClassName:n,disableKeyboardA11y:r}){const o=$t(),{width:i,height:l,x:c,y:f,transformString:m,userSelectionActive:g}=Nt(lL,sn),d=ME(),p=ce.useRef(null);if(ce.useEffect(()=>{r||p.current?.focus({preventScroll:!0})},[r]),IE({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(Qo,S.key)&&d({x:Qo[S.key].x,y:Qo[S.key].y,isShiftPressed:S.shiftKey})};return K.jsx("div",{className:ln(["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 cL=ce.memo(uL);const fL=e=>e.nodesSelectionActive,jE=({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:he,disableKeyboardA11y:Y})=>{const ee=Nt(fL),W=aa(p),ae=aa(w)||L,te=W||h&&ae!==!0;return Z5({deleteKeyCode:f,multiSelectionKeyCode:_}),K.jsx(eL,{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:he,children:K.jsxs(AE,{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(cL,{onSelectionContextMenu:J,noPanClassName:he,disableKeyboardA11y:Y})]})})};jE.displayName="FlowRenderer";var dL=ce.memo(jE);function hL(e){return Nt(ce.useCallback(r=>e?eE(r.nodeInternals,{x:0,y:0,width:r.width,height:r.height},r.transform,!0):r.getNodes(),[e]))}function pL(e){const n={input:la(e.input||fE),default:la(e.default||Jm),output:la(e.output||hE),group:la(e.group||$m)},r={},o=Object.keys(e).filter(i=>!["input","default","output","group"].includes(i)).reduce((i,l)=>(i[l]=la(e[l]||Jm),i),r);return{...n,...o}}const mL=({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]},gL=e=>({nodesDraggable:e.nodesDraggable,nodesConnectable:e.nodesConnectable,nodesFocusable:e.nodesFocusable,elementsSelectable:e.elementsSelectable,updateNodeDimensions:e.updateNodeDimensions,onError:e.onError}),LE=e=>{const{nodesDraggable:n,nodesConnectable:r,nodesFocusable:o,elementsSelectable:i,updateNodeDimensions:l,onError:c}=Nt(gL,sn),f=hL(e.onlyRenderVisibleElements),m=ce.useRef(),g=ce.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 ce.useEffect(()=>()=>{m?.current?.disconnect()},[]),K.jsx("div",{className:"react-flow__nodes",style:tg,children:f.map(d=>{let p=d.type||"default";e.nodeTypes[p]||(c?.("003",Nr.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?zm(d.positionAbsolute,e.nodeExtent):d.positionAbsolute,y=w?.x??0,E=w?.y??0,x=mL({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[en]?.z??0,isParent:!!d[en]?.isParent,noDragClassName:e.noDragClassName,noPanClassName:e.noPanClassName,initialized:!!d.width&&!!d.height,rfId:e.rfId,disableKeyboardA11y:e.disableKeyboardA11y,ariaLabel:d.ariaLabel},d.id)})})};LE.displayName="NodeRenderer";var vL=ce.memo(LE);const yL=(e,n,r)=>r===Be.Left?e-n:r===Be.Right?e+n:e,bL=(e,n,r)=>r===Be.Top?e-n:r===Be.Bottom?e+n:e,DE="react-flow__edgeupdater",BE=({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:ln([DE,`${DE}-${f}`]),cx:yL(n,o,e),cy:bL(r,o,e),r:o,stroke:"transparent",fill:"transparent"}),wL=()=>!0;var Jo=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:he,onEdgeUpdateStart:Y,onEdgeUpdateEnd:ee,markerEnd:W,markerStart:ne,rfId:ae,ariaLabel:te,isFocusable:re,isUpdatable:Z,pathOptions:se,interactionWidth:pe})=>{const ge=ce.useRef(null),[be,Ae]=ce.useState(!1),[Ue,Ve]=ce.useState(!1),Fe=$t(),Pe=ce.useMemo(()=>`url(#${Xm(ne,ae)})`,[ne,ae]),ut=ce.useMemo(()=>`url(#${Xm(W,ae)})`,[W,ae]);if(L)return null;const Ce=ft=>{const{edges:Tt,addSelectedEdges:kn}=Fe.getState();if(z&&(Fe.setState({nodesSelectionActive:!1}),kn([r])),c){const Kt=Tt.find(un=>un.id===r);c(ft,Kt)}},we=oa(r,Fe.getState,f),xe=oa(r,Fe.getState,F),Re=oa(r,Fe.getState,B),De=oa(r,Fe.getState,U),Ee=oa(r,Fe.getState,J),We=(ft,Tt)=>{if(ft.button!==0)return;const{edges:kn,isValidConnection:Kt}=Fe.getState(),un=Tt?y:w,_o=(Tt?D:M)||null,Pr=Tt?"target":"source",pa=Kt||wL,So=Tt,Jr=kn.find(Ir=>Ir.id===r);Ve(!0),Y?.(ft,Jr,Pr);const $r=Ir=>{Ve(!1),ee?.(Ir,Jr,Pr)};aE({event:ft,handleId:_o,nodeId:un,onConnect:Ir=>he?.(Jr,Ir),isTarget:So,getState:Fe.getState,setState:Fe.setState,isValidConnection:pa,edgeUpdaterType:Pr,onEdgeUpdateEnd:$r})},Qe=ft=>We(ft,!0),ot=ft=>We(ft,!1),It=()=>Ae(!0),Mt=()=>Ae(!1),pt=!z&&!c,gn=ft=>{if(VS.includes(ft.key)&&z){const{unselectNodesAndEdges:Tt,addSelectedEdges:kn,edges:Kt}=Fe.getState();ft.key==="Escape"?(ge.current?.blur(),Tt({edges:[Kt.find(_o=>_o.id===r)]})):kn([r])}};return K.jsxs("g",{className:ln(["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?gn: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?`${vE}-${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(BE,{position:R,centerX:E,centerY:x,radius:oe,onMouseDown:Qe,onMouseEnter:It,onMouseOut:Mt,type:"source"}),(Z==="target"||Z===!0)&&K.jsx(BE,{position:j,centerX:k,centerY:P,radius:oe,onMouseDown:ot,onMouseEnter:It,onMouseOut:Mt,type:"target"})]})]})};return n.displayName="EdgeWrapper",ce.memo(n)};function xL(e){const n={default:Jo(e.default||Gs),straight:Jo(e.bezier||Km),step:Jo(e.step||Gm),smoothstep:Jo(e.step||Us),simplebezier:Jo(e.simplebezier||Um)},r={},o=Object.keys(e).filter(i=>!["default","bezier"].includes(i)).reduce((i,l)=>(i[l]=Jo(e[l]||Gs),i),r);return{...n,...o}}function FE(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 qE(e,n){return e?e.length===1||!n?e[0]:n&&e.find(r=>r.id===n)||null:null}const _L=(e,n,r,o,i,l)=>{const c=FE(r,e,n),f=FE(l,o,i);return{sourceX:c.x,sourceY:c.y,targetX:f.x,targetY:f.y}};function SL({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=na({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 zE(e){const n=e?.[en]?.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 EL=[{level:0,isMaxLevel:!0,edges:[]}];function OL(e,n,r=!1){let o=-1;const i=e.reduce((c,f)=>{const m=jn(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?.[en]?.z||0,d?.[en]?.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?EL:l}function kL(e,n,r){const o=Nt(ce.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&&SL({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 OL(o,n,r)}const CL=({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"}),AL=({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"}),HE={[Vs.Arrow]:CL,[Vs.ArrowClosed]:AL};function NL(e){const n=$t();return ce.useMemo(()=>Object.prototype.hasOwnProperty.call(HE,e)?HE[e]:(n.getState().onError?.("009",Nr.error009(e)),null),[e])}const TL=({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=NL(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},RL=({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=Xm(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))},VE=({defaultColor:e,rfId:n})=>{const r=Nt(ce.useCallback(RL({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(TL,{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))})};VE.displayName="MarkerDefinitions";var PL=ce.memo(VE);const IL=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}),UE=({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}=Nt(IL,sn),z=kL(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(PL,{defaultColor:e,rfId:o}),K.jsx("g",{children:M.map(F=>{const[B,U,J]=zE(R.get(F.source)),[oe,he,Y]=zE(R.get(F.target));if(!J||!Y)return null;let ee=F.type||"default";i[ee]||(j?.("011",Nr.error011(ee)),ee="default");const W=i[ee]||i.default,ne=P===go.Strict?he.target:(he.target??[]).concat(he.source??[]),ae=qE(U.source,F.sourceHandle),te=qE(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",Nr.error008(ae,F)),null;const{sourceX:ge,sourceY:be,targetX:Ae,targetY:Ue}=_L(B,ae,re,oe,te,Z);return K.jsx(W,{id:F.id,className:ln([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};UE.displayName="EdgeRenderer";var ML=ce.memo(UE);const jL=e=>`translate(${e.transform[0]}px,${e.transform[1]}px) scale(${e.transform[2]})`;function LL({children:e}){const n=Nt(jL);return K.jsx("div",{className:"react-flow__viewport react-flow__container",style:{transform:n},children:e})}function DL(e){const n=Zs(),r=ce.useRef(!1);ce.useEffect(()=>{!r.current&&n.viewportInitialized&&e&&(setTimeout(()=>e(n),1),r.current=!0)},[e,n.viewportInitialized])}const BL={[Be.Left]:Be.Right,[Be.Right]:Be.Left,[Be.Top]:Be.Bottom,[Be.Bottom]:Be.Top},WE=({nodeId:e,handleType:n,style:r,type:o=dr.Bezier,CustomComponent:i,connectionStatus:l})=>{const{fromNode:c,handleId:f,toX:m,toY:g,connectionMode:d}=Nt(ce.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]),sn),p=c?.[en]?.handleBounds;let h=p?.[n];if(d===go.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?BL[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===dr.Bezier?[x]=JS(k):o===dr.Step?[x]=Wm({...k,borderRadius:0}):o===dr.SmoothStep?[x]=Wm(k):o===dr.SimpleBezier?[x]=YS(k):x=`M${_},${w} ${m},${g}`,K.jsx("path",{d:x,fill:"none",className:"react-flow__connection-path",style:r})};WE.displayName="ConnectionLine";const FL=e=>({nodeId:e.connectionNodeId,handleType:e.connectionHandleType,nodesConnectable:e.nodesConnectable,connectionStatus:e.connectionStatus,width:e.width,height:e.height});function qL({containerStyle:e,style:n,type:r,component:o}){const{nodeId:i,handleType:l,nodesConnectable:c,width:f,height:m,connectionStatus:g}=Nt(FL,sn);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:ln(["react-flow__connection",g]),children:K.jsx(WE,{nodeId:i,handleType:l,style:n,type:r,CustomComponent:o,connectionStatus:g})})})}function GE(e,n){return ce.useRef(null),$t(),ce.useMemo(()=>n(e),[e])}const KE=({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:he,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:It,nodeOrigin:Mt,nodeExtent:pt,rfId:gn})=>{const ft=GE(e,pL),Tt=GE(n,xL);return DL(l),K.jsx(dL,{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:he,onSelectionContextMenu:S,preventScrolling:Y,noDragClassName:Ee,noWheelClassName:We,noPanClassName:Qe,disableKeyboardA11y:It,children:K.jsxs(LL,{children:[K.jsx(ML,{edgeTypes:Tt,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:It,rfId:gn,children:K.jsx(qL,{style:y,type:w,component:E,containerStyle:x})}),K.jsx("div",{className:"react-flow__edgelabel-renderer"}),K.jsx(vL,{nodeTypes:ft,onNodeClick:c,onNodeDoubleClick:m,onNodeMouseEnter:d,onNodeMouseMove:p,onNodeMouseLeave:h,onNodeContextMenu:s,selectNodesOnDrag:B,onlyRenderVisibleElements:D,noPanClassName:Qe,noDragClassName:Ee,disableKeyboardA11y:It,nodeOrigin:Mt,nodeExtent:pt,rfId:gn})]})})};KE.displayName="GraphView";var zL=ce.memo(KE);const ag=[[Number.NEGATIVE_INFINITY,Number.NEGATIVE_INFINITY],[Number.POSITIVE_INFINITY,Number.POSITIVE_INFINITY]],Xr={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:ag,nodeExtent:ag,nodesSelectionActive:!1,userSelectionActive:!1,userSelectionRect:null,connectionNodeId:null,connectionHandleId:null,connectionHandleType:"source",connectionPosition:{x:0,y:0},connectionStatus:null,connectionMode:go.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:p5,isValidConnection:void 0},HL=()=>NP((e,n)=>({...Xr,setNodes:r=>{const{nodeInternals:o,nodeOrigin:i,elevateNodesOnSelect:l}=n();e({nodeInternals:eg(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?eg(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=qm(_.nodeElement);!!(y.width&&y.height&&(w.width!==y.width||w.height!==y.height||_.forceUpdate))&&(i.set(w.id,{...w,[en]:{...w[en],handleBounds:{source:PE(".source",_.nodeElement,h,g),target:PE(".target",_.nodeElement,h,g)}},...y}),b.push({id:w.id,type:"dimensions",dimensions:y}))}return b},[]);xE(i,g);const S=c||l&&!c&&_E(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=CE(r,f()),d=eg(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=>Yr(m,!0)):(c=Zo(l(),r),f=Zo(i,[])),Xs({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=>Yr(m,!0)):(c=Zo(i,r),f=Zo(l(),[])),Xs({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,Yr(d.id,!1))),g=f.map(d=>Yr(d.id,!1));Xs({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=>Yr(f.id,!1)),c=r.filter(f=>f.selected).map(f=>Yr(f.id,!1));Xs({changedNodes:l,changedEdges:c,get:n,set:e})},setNodeExtent:r=>{const{nodeInternals:o}=n();o.forEach(i=>{i.positionAbsolute=zm(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=Ar.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:Xr.connectionNodeId,connectionHandleId:Xr.connectionHandleId,connectionHandleType:Xr.connectionHandleType,connectionStatus:Xr.connectionStatus,connectionStartHandle:Xr.connectionStartHandle,connectionEndHandle:Xr.connectionEndHandle}),reset:()=>e({...Xr})}),Object.is),YE=({children:e})=>{const n=ce.useRef(null);return n.current||(n.current=HL()),K.jsx(s5,{value:n.current,children:e})};YE.displayName="ReactFlowProvider";const XE=({children:e})=>ce.useContext(zs)?K.jsx(K.Fragment,{children:e}):K.jsx(YE,{children:e});XE.displayName="ReactFlowWrapper";const VL={input:fE,default:Jm,output:hE,group:$m},UL={default:Gs,straight:Km,step:Gm,smoothstep:Us,simplebezier:Um},WL=[0,0],GL=[15,15],KL={x:0,y:0,zoom:1},YL={width:"100%",height:"100%",overflow:"hidden",position:"relative",zIndex:0},sg=ce.forwardRef(({nodes:e,edges:n,defaultNodes:r,defaultEdges:o,className:i,nodeTypes:l=VL,edgeTypes:c=UL,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:he,connectionMode:Y=go.Strict,connectionLineType:ee=dr.Bezier,connectionLineStyle:W,connectionLineComponent:ne,connectionLineContainerStyle:ae,deleteKeyCode:te="Backspace",selectionKeyCode:re="Shift",selectionOnDrag:Z=!1,selectionMode:se=ia.Full,panActivationKeyCode:pe="Space",multiSelectionKeyCode:ge=Hs()?"Meta":"Control",zoomActivationKeyCode:be=Hs()?"Meta":"Control",snapToGrid:Ae=!1,snapGrid:Ue=GL,onlyRenderVisibleElements:Ve=!1,selectNodesOnDrag:Fe=!0,nodesDraggable:Pe,nodesConnectable:ut,nodesFocusable:Ce,nodeOrigin:we=WL,edgesFocusable:xe,edgesUpdatable:Re,elementsSelectable:De,defaultViewport:Ee=KL,minZoom:We=.5,maxZoom:Qe=2,translateExtent:ot=ag,preventScrolling:It=!0,nodeExtent:Mt,defaultMarkerColor:pt="#b1b1b7",zoomOnScroll:gn=!0,zoomOnPinch:ft=!0,panOnScroll:Tt=!1,panOnScrollSpeed:kn=.5,panOnScrollMode:Kt=vo.Free,zoomOnDoubleClick:un=!0,panOnDrag:_o=!0,onPaneClick:Pr,onPaneMouseEnter:pa,onPaneMouseMove:So,onPaneMouseLeave:Jr,onPaneScroll:$r,onPaneContextMenu:ll,children:Ir,onEdgeUpdate:ma,onEdgeContextMenu:Sg,onEdgeDoubleClick:ga,onEdgeMouseEnter:Eg,onEdgeMouseMove:va,onEdgeMouseLeave:Og,onEdgeUpdateStart:ya,onEdgeUpdateEnd:kg,edgeUpdaterRadius:ba=10,onNodesChange:Cg,onEdgesChange:wa,noDragClassName:$o="nodrag",noWheelClassName:eo="nowheel",noPanClassName:ul="nopan",fitView:cl=!1,fitViewOptions:ei,connectOnClick:fl=!0,attributionPosition:Eo,proOptions:xa,defaultEdgeOptions:Ag,elevateNodesOnSelect:_a=!0,elevateEdgesOnSelect:ti=!1,disableKeyboardA11y:dl=!1,autoPanOnConnect:hl=!0,autoPanOnNodeDrag:Ng=!0,connectionRadius:Sa=20,isValidConnection:ni,onError:Ea,style:ri,id:to,...Mr},jr)=>{const hr=to||"1";return K.jsx("div",{...Mr,style:{...ri,...YL},ref:jr,className:ln(["react-flow",i]),"data-testid":"rf__wrapper",id:to,children:K.jsxs(XE,{children:[K.jsx(zL,{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:It,zoomOnScroll:gn,zoomOnPinch:ft,zoomOnDoubleClick:un,panOnScroll:Tt,panOnScrollSpeed:kn,panOnScrollMode:Kt,panOnDrag:_o,onPaneClick:Pr,onPaneMouseEnter:pa,onPaneMouseMove:So,onPaneMouseLeave:Jr,onPaneScroll:$r,onPaneContextMenu:ll,onSelectionContextMenu:J,onSelectionStart:oe,onSelectionEnd:he,onEdgeUpdate:ma,onEdgeContextMenu:Sg,onEdgeDoubleClick:ga,onEdgeMouseEnter:Eg,onEdgeMouseMove:va,onEdgeMouseLeave:Og,onEdgeUpdateStart:ya,onEdgeUpdateEnd:kg,edgeUpdaterRadius:ba,defaultMarkerColor:pt,noDragClassName:$o,noWheelClassName:eo,noPanClassName:ul,elevateEdgesOnSelect:ti,rfId:hr,disableKeyboardA11y:dl,nodeOrigin:we,nodeExtent:Mt}),K.jsx(B5,{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:_a,minZoom:We,maxZoom:Qe,nodeExtent:Mt,onNodesChange:Cg,onEdgesChange:wa,snapToGrid:Ae,snapGrid:Ue,connectionMode:Y,translateExtent:ot,connectOnClick:fl,defaultEdgeOptions:Ag,fitView:cl,fitViewOptions:ei,onNodesDelete:L,onEdgesDelete:M,onNodeDragStart:R,onNodeDrag:j,onNodeDragStop:z,onSelectionDrag:B,onSelectionDragStart:F,onSelectionDragStop:U,noPanClassName:ul,nodeOrigin:we,rfId:hr,autoPanOnConnect:hl,autoPanOnNodeDrag:Ng,onError:Ea,connectionRadius:Sa,isValidConnection:ni}),K.jsx(L5,{onSelectionChange:D}),Ir,K.jsx(u5,{proOptions:xa,position:Eo}),K.jsx(V5,{rfId:hr,disableKeyboardA11y:dl})]})})});sg.displayName="ReactFlow";function ZE(e){return n=>{const[r,o]=ce.useState(n),i=ce.useCallback(l=>o(c=>e(l,c)),[]);return[r,o,i]}}const XL=ZE(CE),ZL=ZE(rL),QE=({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:ln(["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})};QE.displayName="MiniMapNode";var QL=ce.memo(QE);const JL=e=>e.nodeOrigin,$L=e=>e.getNodes().filter(n=>!n.hidden&&n.width&&n.height),lg=e=>e instanceof Function?e:()=>e;function e3({nodeStrokeColor:e="transparent",nodeColor:n="#e2e2e2",nodeClassName:r="",nodeBorderRadius:o=5,nodeStrokeWidth:i=2,nodeComponent:l=QL,onClick:c}){const f=Nt($L,sn),m=Nt(JL),g=lg(n),d=lg(e),p=lg(r),h=typeof window>"u"||window.chrome?"crispEdges":"geometricPrecision";return K.jsx(K.Fragment,{children:f.map(s=>{const{x:S,y:b}=yo(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 t3=ce.memo(e3);const n3=200,r3=150,o3=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?d5(Ks(n,e.nodeOrigin),r):r,rfId:e.rfId}},i3="react-flow__minimap-desc";function JE({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=$t(),k=ce.useRef(null),{boundingRect:P,viewBB:R,rfId:j}=Nt(o3,sn),z=e?.width??n3,L=e?.height??r3,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,he=P.y-(U-P.height)/2-J,Y=B+J*2,ee=U+J*2,W=`${i3}-${j}`,ne=ce.useRef(0);ne.current=F,ce.useEffect(()=>{if(k.current){const re=Mn(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=Ar.translate(Ce.x,Ce.y).scale(be[2]),Re=Ue.constrain()(xe,we,Ve);Ue.transform(Ae,Re)},pe=jS().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=Jn(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(Fm,{position:p,style:e,className:ln(["react-flow__minimap",n]),"data-testid":"rf__minimap",children:K.jsxs("svg",{width:z,height:L,viewBox:`${oe} ${he} ${Y} ${ee}`,role:"img","aria-labelledby":W,ref:k,onClick:ae,children:[_&&K.jsx("title",{id:W,children:_}),K.jsx(t3,{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},${he-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"})]})})}JE.displayName="MiniMap";var $E=ce.memo(JE);function a3(){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 s3(){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 l3(){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 u3(){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 c3(){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 ua=({children:e,className:n,...r})=>K.jsx("button",{type:"button",className:ln(["react-flow__controls-button",n]),...r,children:e});ua.displayName="ControlButton";const f3=e=>({isInteractive:e.nodesDraggable||e.nodesConnectable||e.elementsSelectable,minZoomReached:e.transform[2]<=e.minZoom,maxZoomReached:e.transform[2]>=e.maxZoom}),eO=({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=$t(),[s,S]=ce.useState(!1),{isInteractive:b,minZoomReached:_,maxZoomReached:w}=Nt(f3,sn),{zoomIn:y,zoomOut:E,fitView:x}=Zs();if(ce.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(Fm,{className:ln(["react-flow__controls",g]),position:p,style:e,"data-testid":"rf__controls",children:[n&&K.jsxs(K.Fragment,{children:[K.jsx(ua,{onClick:k,className:"react-flow__controls-zoomin",title:"zoom in","aria-label":"zoom in",disabled:w,children:K.jsx(a3,{})}),K.jsx(ua,{onClick:P,className:"react-flow__controls-zoomout",title:"zoom out","aria-label":"zoom out",disabled:_,children:K.jsx(s3,{})})]}),r&&K.jsx(ua,{className:"react-flow__controls-fitview",onClick:R,title:"fit view","aria-label":"fit view",children:K.jsx(l3,{})}),o&&K.jsx(ua,{className:"react-flow__controls-interactive",onClick:j,title:"toggle interactivity","aria-label":"toggle interactivity",children:b?K.jsx(c3,{}):K.jsx(u3,{})}),d]})};eO.displayName="Controls";var tO=ce.memo(eO),tr;(function(e){e.Lines="lines",e.Dots="dots",e.Cross="cross"})(tr||(tr={}));function d3({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 h3({color:e,radius:n}){return K.jsx("circle",{cx:n,cy:n,r:n,fill:e})}const p3={[tr.Dots]:"#91919a",[tr.Lines]:"#eee",[tr.Cross]:"#e2e2e2"},m3={[tr.Dots]:1,[tr.Lines]:1,[tr.Cross]:6},g3=e=>({transform:e.transform,patternId:`pattern-${e.rfId}`});function nO({id:e,variant:n=tr.Dots,gap:r=20,size:o,lineWidth:i=1,offset:l=2,color:c,style:f,className:m}){const g=ce.useRef(null),{transform:d,patternId:p}=Nt(g3,sn),h=c||p3[n],s=o||m3[n],S=n===tr.Dots,b=n===tr.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:ln(["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(h3,{color:h,radius:y/l}):K.jsx(d3,{dimensions:E,color:h,lineWidth:i})}),K.jsx("rect",{x:"0",y:"0",width:"100%",height:"100%",fill:`url(#${p+e})`})]})}nO.displayName="Background";var rO=ce.memo(nO);function oO(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=oO(e[n]))&&(o&&(o+=" "),o+=r);else for(n in e)e[n]&&(o&&(o+=" "),o+=n);return o}function Zr(){for(var e,n,r=0,o="";r<arguments.length;)(e=arguments[r++])&&(n=oO(e))&&(o&&(o+=" "),o+=n);return o}const ca=e=>typeof e=="number"&&!isNaN(e),wo=e=>typeof e=="string",xn=e=>typeof e=="function",Js=e=>wo(e)||xn(e)?e:null,ug=e=>ce.isValidElement(e)||wo(e)||xn(e)||ca(e);function v3(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 $s(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=ce.useRef(0);return ce.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)},[]),ce.useEffect(()=>{const _=p.current,w=()=>{_.removeEventListener("animationend",w),i?v3(_,d,l):d()};h||(g?w():(b.current=1,_.className+=` ${S}`,_.addEventListener("animationend",w)))},[h]),ce.createElement(ce.Fragment,null,f)}}function iO(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 Ln={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)})}},el=e=>{let{theme:n,type:r,...o}=e;return ce.createElement("svg",{viewBox:"0 0 24 24",width:"100%",height:"100%",fill:n==="colored"?"currentColor":`var(--toastify-icon-color-${r})`,...o})},cg={info:function(e){return ce.createElement(el,{...e},ce.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 ce.createElement(el,{...e},ce.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 ce.createElement(el,{...e},ce.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 ce.createElement(el,{...e},ce.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 ce.createElement("div",{className:"Toastify__spinner"})}};function y3(e){const[,n]=ce.useReducer(s=>s+1,0),[r,o]=ce.useState([]),i=ce.useRef(null),l=ce.useRef(new Map).current,c=s=>r.indexOf(s)!==-1,f=ce.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(!ug(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:Js(w.className||k.toastClassName),bodyClassName:Js(w.bodyClassName||k.bodyClassName),progressClassName:Js(w.progressClassName||k.progressClassName),autoClose:!w.isLoading&&(z=w.autoClose,L=k.autoClose,z===!1||ca(z)&&z>0?z:L),deleteToast(){const D=iO(l.get(y),"removed");l.delete(y),Ln.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 he={theme:F,type:B};return J===!1||(xn(J)?oe=J(he):ce.isValidElement(J)?oe=ce.cloneElement(J,he):wo(J)||ca(J)?oe=J:U?oe=cg.spinner():(Y=>Y in cg)(B)&&(oe=cg[B](he))),oe})(j),xn(w.onOpen)&&(j.onOpen=w.onOpen),xn(w.onClose)&&(j.onClose=w.onClose),j.closeButton=k.closeButton,w.closeButton===!1||ug(w.closeButton)?j.closeButton=w.closeButton:w.closeButton===!0&&(j.closeButton=!ug(k.closeButton)||k.closeButton);let M=s;ce.isValidElement(s)&&!wo(s.type)?M=ce.cloneElement(s,{closeToast:P,toastProps:j,data:x}):xn(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:_}):ca(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)),Ln.emit(4,iO(w,w.props.updateId==null?"added":"updated"))}return ce.useEffect(()=>(f.containerId=e.containerId,Ln.cancelEmit(3).on(0,p).on(1,s=>i.current&&g(s)).on(5,m).emit(2,f),()=>{l.clear(),Ln.emit(3,f)}),[]),ce.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 aO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientX:e.clientX}function sO(e){return e.targetTouches&&e.targetTouches.length>=1?e.targetTouches[0].clientY:e.clientY}function b3(e){const[n,r]=ce.useState(!1),[o,i]=ce.useState(!1),l=ce.useRef(null),c=ce.useRef({start:0,x:0,y:0,delta:0,removalDistance:0,canCloseOnClick:!0,canDrag:!1,boundingRect:null,didMove:!1}).current,f=ce.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=aO(x.nativeEvent),c.y=sO(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=aO(x),c.y=sO(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"}}ce.useEffect(()=>{f.current=e}),ce.useEffect(()=>(l.current&&l.current.addEventListener("d",b,{once:!0}),xn(e.onOpen)&&e.onOpen(ce.isValidElement(e.children)&&e.children.props),()=>{const x=f.current;xn(x.onClose)&&x.onClose(ce.isValidElement(x.children)&&x.children.props)}),[]),ce.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 lO(e){let{closeToast:n,theme:r,ariaLabel:o="close"}=e;return ce.createElement("button",{className:`Toastify__close-button Toastify__close-button--${r}`,type:"button",onClick:i=>{i.stopPropagation(),n(i)},"aria-label":o},ce.createElement("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},ce.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 w3(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=Zr("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}),_=xn(c)?c({rtl:d,type:i,defaultClassName:b}):Zr(b,c);return ce.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 x3=e=>{const{isRunning:n,preventExitTransition:r,toastRef:o,eventHandlers:i}=b3(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=Zr("Toastify__toast",`Toastify__toast-theme--${B}`,`Toastify__toast--${g}`,{"Toastify__toast--rtl":R},{"Toastify__toast--close-on-click":F}),J=xn(S)?S({rtl:R,position:s,type:g,defaultClassName:U}):Zr(U,S),oe=!!P||!f,he={closeToast:p,type:g,theme:B};let Y=null;return l===!1||(Y=xn(l)?l(he):ce.isValidElement(l)?ce.cloneElement(l,he):lO(he)),ce.createElement(h,{isIn:L,done:z,position:s,preventExitTransition:r,nodeRef:o},ce.createElement("div",{id:j,onClick:m,className:J,...i,style:b,ref:o},ce.createElement("div",{...L&&{role:k},className:xn(_)?_({type:g}):Zr("Toastify__toast-body",_),style:w},D!=null&&ce.createElement("div",{className:Zr("Toastify__toast-icon",{"Toastify--animate-icon Toastify__zoom-enter":!M})},D),ce.createElement("div",null,c)),Y,ce.createElement(w3,{...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})))},tl=function(e,n){return n===void 0&&(n=!1),{enter:`Toastify--animate Toastify__${e}-enter`,exit:`Toastify--animate Toastify__${e}-exit`,appendPosition:n}},_3=$s(tl("bounce",!0));$s(tl("slide",!0)),$s(tl("zoom")),$s(tl("flip"));const fg=ce.forwardRef((e,n)=>{const{getToastToRender:r,containerRef:o,isToastActive:i}=y3(e),{className:l,style:c,rtl:f,containerId:m}=e;function g(d){const p=Zr("Toastify__toast-container",`Toastify__toast-container--${d}`,{"Toastify__toast-container--rtl":f});return xn(l)?l({position:d,rtl:f,defaultClassName:p}):Zr(p,Js(l))}return ce.useEffect(()=>{n&&(n.current=o.current)},[]),ce.createElement("div",{ref:o,className:"Toastify",id:m},r((d,p)=>{const h=p.length?{...c}:{...c,pointerEvents:"none"};return ce.createElement("div",{className:g(d),style:h,key:`container-${d}`},p.map((s,S)=>{let{content:b,props:_}=s;return ce.createElement(x3,{..._,isIn:i(_.toastId),style:{..._.style,"--nth":S+1,"--len":p.length},key:`toast-${_.key}`},b)}))}))});fg.displayName="ToastContainer",fg.defaultProps={position:"top-right",transition:_3,autoClose:5e3,closeButton:lO,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,draggable:!0,draggablePercent:80,draggableDirection:"x",role:"alert",theme:"light"};let dg,xo=new Map,fa=[],S3=1;function uO(){return""+S3++}function E3(e){return e&&(wo(e.toastId)||ca(e.toastId))?e.toastId:uO()}function da(e,n){return xo.size>0?Ln.emit(0,e,n):fa.push({content:e,options:n}),n.toastId}function nl(e,n){return{...n,type:n&&n.type||e,toastId:E3(n)}}function rl(e){return(n,r)=>da(n,nl(e,r))}function ct(e,n){return da(e,nl("default",n))}ct.loading=(e,n)=>da(e,nl("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=wo(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=wo(p)?{render:p}:p;return o?ct.update(o,{...s,...S}):ct(S.render,{...s,...S}),h},g=xn(e)?e():e;return g.then(d=>m("success",c,d)).catch(d=>m("error",l,d)),g},ct.success=rl("success"),ct.info=rl("info"),ct.error=rl("error"),ct.warning=rl("warning"),ct.warn=ct.warning,ct.dark=(e,n)=>da(e,nl("default",{theme:"dark",...n})),ct.dismiss=e=>{xo.size>0?Ln.emit(1,e):fa=fa.filter(n=>e!=null&&n.options.toastId!==e)},ct.clearWaitingQueue=function(e){return e===void 0&&(e={}),Ln.emit(5,e)},ct.isActive=e=>{let n=!1;return xo.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=xo.get(l||dg);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:uO()};l.toastId!==e&&(l.staleId=e);const c=l.render||i;delete l.render,da(c,l)}},0)},ct.done=e=>{ct.update(e,{progress:1})},ct.onChange=e=>(Ln.on(4,e),()=>{Ln.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"},Ln.on(2,e=>{dg=e.containerId||e,xo.set(dg,e),fa.forEach(n=>{Ln.emit(0,n.content,n.options)}),fa=[]}).on(3,e=>{xo.delete(e.containerId||e),xo.size===0&&Ln.off(0).off(1).off(5)});const cO=ce.createContext({certificate:{},node:{},setNode:()=>{},type:"readNode",replica:{},nodesState:[],edgesState:[],nodeLayers:{previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}},setNodeLayers:()=>{}}),fO=e=>{const[n,r]=ce.useState({}),[o,i]=ce.useState({previous:{nodes:[],edges:[]},current:{nodes:[],edges:[]}}),l=XL([]),c=ZL([]),f=ce.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(cO.Provider,{value:f,children:e.children})},Et=()=>ce.useContext(cO);var hg={exports:{}};/*! For license information please see main.js.LICENSE.txt */var dO;function O3(){return dO||(dO=1,(function(e,n){(function(r,o){e.exports=o(ce,YN,K,sy)})(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),he=x(F),Y=0;Y<J.length;++Y){var ee=J[Y];if(!(w[ee]||B&&B[ee]||he&&he[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 he(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 he(Y)||oe(Y)===P},s.isConcurrentMode=he,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:()=>ei,ConfirmationModal:()=>k6,HISETabs:()=>cF,KeyValPair:()=>fF,MessageStripe:()=>xi,ResourceEditor:()=>DN});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 he(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,de){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,de);if(Object.getOwnPropertySymbols){var fe=Object.getOwnPropertySymbols(ue);for(ve=0;ve<fe.length;ve++)me=fe[ve],de.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"])},It=[U.space,U.enter,U.up,U.down,U.end,U.home],Mt=(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||((It.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 de;return(de=T.getMenuItems()[0])===null||de===void 0?void 0:de.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,de=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=de||(Q?"li":"div"),ye=!1;ie&&b().Children.map(this.props.children[1].props.children,(function(Oe){Oe&&Oe.props.active&&(ye=!0)}));var fe=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:fe}))))}}],u&&De(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);Mt.propTypes=ot,Mt.defaultProps={a11y:!0,isOpen:!1,direction:"down",nav:!1,active:!1,inNavbar:!1,setActiveFromChild:!1},Mt.contextType=ut;const pt=Mt;function gn(){return gn=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},gn.apply(this,arguments)}var ft={children:y().node};function Tt(t){return b().createElement(pt,gn({group:!0},t))}Tt.propTypes=ft;const kn=Tt;function Kt(t){return Kt=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},Kt(t)}function un(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 _o(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function Pr(){return Pr=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},Pr.apply(this,arguments)}function pa(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 So(t,a){return So=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},So(t,a)}function Jr(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function $r(t){return $r=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},$r(t)}var ll=["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&&So(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=$r(v);if(O){var C=$r(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Kt(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Jr(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(Jr(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(kn,Pr({isOpen:this.state.isOpen,toggle:this.toggle},j(this.props,ll)))}}])&&pa(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?un(Object(u),!0).forEach((function(v){_o(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):un(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t})({defaultOpen:y().bool},kn.propTypes);var Ir=d(379),ma=d.n(Ir),Sg=d(795),ga=d.n(Sg),Eg=d(569),va=d.n(Eg),Og=d(565),ya=d.n(Og),kg=d(216),ba=d.n(kg),Cg=d(589),wa=d.n(Cg),$o=d(953),eo={};eo.styleTagTransform=wa(),eo.setAttributes=ya(),eo.insert=va().bind(null,"head"),eo.domAPI=ga(),eo.insertStyleElement=ba(),ma()($o.Z,eo),$o.Z&&$o.Z.locals&&$o.Z.locals;var ul=["href","to","icon","pending","children","target","download","noText"],cl=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 de,me,ve={},ye=Object.keys(ie);for(me=0;me<ye.length;me++)de=ye[me],ue.indexOf(de)>=0||(ve[de]=ie[de]);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,ul);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)};cl.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 ei=cl;var fl=d(732),Eo=d.n(fl);function xa(t){return xa=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},xa(t)}function Ag(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 _a(t,a){return _a=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},_a(t,a)}function ti(t){return ti=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},ti(t)}var dl={children:y().node.isRequired,node:y().any},hl=(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&&_a(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=ti(v);if(O){var C=ti(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(xa(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)),Eo().createPortal(this.props.children,this.props.node||this.defaultNode)):null}}])&&Ag(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);hl.propTypes=dl;const Ng=hl;function Sa(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 ni(t,a){return ni=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},ni(t,a)}function Ea(t,a){t.prototype=Object.create(a.prototype),t.prototype.constructor=t,ni(t,a)}const ri=b().createContext(null);var to="unmounted",Mr="exited",jr="entering",hr="entered",Tg="exiting",Lr=(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=Mr,A.appearStatus=jr):I=hr:I=v.unmountOnExit||v.mountOnEnter?to:Mr,A.state={status:I},A.nextCallback=null,A}Ea(a,t),a.getDerivedStateFromProps=function(v,O){return v.in&&O.status===to?{status:Mr}: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!==jr&&A!==hr&&(O=jr):A!==jr&&A!==hr||(O=Tg)}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===jr){if(this.props.unmountOnExit||this.props.mountOnEnter){var A=this.props.nodeRef?this.props.nodeRef.current:Eo().findDOMNode(this);A&&(function(I){I.scrollTop})(A)}this.performEnter(v)}else this.performExit();else this.props.unmountOnExit&&this.state.status===Mr&&this.setState({status:to})},u.performEnter=function(v){var O=this,A=this.props.enter,I=this.context?this.context.isMounting:v,N=this.props.nodeRef?[I]:[Eo().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:jr},(function(){O.props.onEntering(T,C),O.onTransitionEnd(V,(function(){O.safeSetState({status:hr},(function(){O.props.onEntered(T,C)}))}))}))):this.safeSetState({status:hr},(function(){O.props.onEntered(T)}))},u.performExit=function(){var v=this,O=this.props.exit,A=this.getTimeouts(),I=this.props.nodeRef?void 0:Eo().findDOMNode(this);O?(this.props.onExit(I),this.safeSetState({status:Tg},(function(){v.props.onExiting(I),v.onTransitionEnd(A.exit,(function(){v.safeSetState({status:Mr},(function(){v.props.onExited(I)}))}))}))):this.safeSetState({status:Mr},(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:Eo().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===to)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,Sa(O,["children","in","mountOnEnter","unmountOnExit","appear","enter","exit","timeout","addEndListener","onEnter","onEntering","onEntered","onExit","onExiting","onExited","nodeRef"]));return b().createElement(ri.Provider,{value:null},typeof A=="function"?A(v,I):b().cloneElement(b().Children.only(A),I))},a})(b().Component);function oi(){}Lr.contextType=ri,Lr.propTypes={},Lr.defaultProps={in:!1,mountOnEnter:!1,unmountOnExit:!1,appear:!1,enter:!0,exit:!0,onEnter:oi,onEntering:oi,onEntered:oi,onExit:oi,onExiting:oi,onExited:oi},Lr.UNMOUNTED=to,Lr.EXITED=Mr,Lr.ENTERING=jr,Lr.ENTERED=hr,Lr.EXITING=Tg;const Rg=Lr;var z4=["tag","baseClass","baseClassActive","className","cssModule","children","innerRef"];function pl(){return pl=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},pl.apply(this,arguments)}function WO(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 Oa(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?WO(Object(u),!0).forEach((function(v){H4(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):WO(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function H4(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}var V4=Oa(Oa({},Rg.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])}),GO=Oa(Oa({},Rg.defaultProps),{},{timeout:150,appear:!0,enter:!0,exit:!0,in:!0});function Pg(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,de,me=(function(ye,fe){if(ye==null)return{};var Oe,Me,_e={},je=Object.keys(ye);for(Me=0;Me<je.length;Me++)Oe=je[Me],fe.indexOf(Oe)>=0||(_e[Oe]=ye[Oe]);return _e})(Q,ie);if(Object.getOwnPropertySymbols){var ve=Object.getOwnPropertySymbols(Q);for(de=0;de<ve.length;de++)ue=ve[de],ie.indexOf(ue)>=0||Object.prototype.propertyIsEnumerable.call(Q,ue)&&(me[ue]=Q[ue])}return me})(t,z4),H=(function(Q,ie){for(var ue,de=Array.isArray(ie)?ie:[ie],me=de.length,ve={};me>0;)ve[ue=de[me-=1]]=Q[ue];return ve})(Oa({defaultProps:GO},q),B),G=j(q,B);return b().createElement(Rg,pl({nodeRef:$},H),(function(Q){var ie=Q==="entered",ue=R(x()(T,A,ie&&N),C);return b().createElement(v,pl({className:ue},G,{ref:$}),X)}))}Pg.propTypes=V4,Pg.defaultProps=GO;const ka=Pg;function Ig(t){return Ig=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},Ig(t)}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 ii(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){ai(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 Ca(){return Ca=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},Ca.apply(this,arguments)}function ai(t,a,u){return a in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function U4(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 Mg(t,a){return Mg=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Mg(t,a)}function Dn(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function ml(t){return ml=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},ml(t)}function gl(){}var YO=y().shape(ka.propTypes),XO={autoFocus:y().bool,backdrop:y().oneOfType([y().bool,y().oneOf(["static"])]),backdropClassName:y().string,backdropTransition:YO,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:YO,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])},W4=Object.keys(XO),G4={isOpen:!1,autoFocus:!0,centered:!1,scrollable:!1,role:"dialog",backdrop:!0,keyboard:!0,zIndex:1050,fade:!0,onOpened:gl,onClosed:gl,modalTransition:{timeout:300},backdropTransition:{mountOnEnter:!0,timeout:150},unmountOnClose:!0,returnFocusAfterClose:!0,container:"body",trapFocus:!1},Aa=(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&&Mg(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=ml(v);if(O){var C=ml(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Ig(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Dn(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(Dn(T)),T.handleBackdropClick=T.handleBackdropClick.bind(Dn(T)),T.handleBackdropMouseDown=T.handleBackdropMouseDown.bind(Dn(T)),T.handleEscape=T.handleEscape.bind(Dn(T)),T.handleStaticBackdropAnimation=T.handleStaticBackdropAnimation.bind(Dn(T)),T.handleTab=T.handleTab.bind(Dn(T)),T.onOpened=T.onOpened.bind(Dn(T)),T.onClosed=T.onClosed.bind(Dn(T)),T.manageFocusAfterClose=T.manageFocusAfterClose.bind(Dn(T)),T.clearBackdropAnimationTimeout=T.clearBackdropAnimationTimeout.bind(Dn(T)),T.trapFocus=T.trapFocus.bind(Dn(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||gl)(N,T)}},{key:"onClosed",value:function(N){var T=this.props.unmountOnClose;this.props.onClosed(),(this.props.modalTransition.onExited||gl)(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=he(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,W4),X="modal-dialog";return b().createElement("div",Ca({},C,{className:R(x()(X,this.props.className,(N={},ai(N,"modal-".concat(this.props.size),this.props.size),ai(N,"".concat(X,"-centered"),this.props.centered),ai(N,"".concat(X,"-scrollable"),this.props.scrollable),ai(N,"modal-fullscreen",this.props.fullscreen===!0),ai(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,de=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=ii(ii(ii({},ka.defaultProps),this.props.modalTransition),{},{baseClass:ve?this.props.modalTransition.baseClass:"",timeout:ve?this.props.modalTransition.timeout:0}),fe=ii(ii(ii({},ka.defaultProps),this.props.backdropTransition),{},{baseClass:ve?this.props.backdropTransition.baseClass:"",timeout:ve?this.props.backdropTransition.timeout:0}),Oe=G&&(ve?b().createElement(ka,Ca({},fe,{in:H&&!!G,cssModule:q,className:R(x()("modal-backdrop",$),q)})):b().createElement("div",{className:R(x()("modal-backdrop","show",$),q)}));return b().createElement(Ng,{node:this._element},b().createElement("div",{className:R(X)},b().createElement(ka,Ca({},me,ye,{in:H,onEntered:this.onOpened,onExited:this.onClosed,cssModule:q,className:R(x()("modal",V,this.state.showStaticBackdropAnimation&&"modal-static"),q),innerRef:de}),ue,this.renderModalDialog()),Oe))}return null}}],u&&U4(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);Aa.propTypes=XO,Aa.defaultProps=G4,Aa.openCount=0,Aa.originalBodyOverflow=null;const K4=Aa;var Y4=["className","cssModule","children","toggle","tag","wrapTag","closeAriaLabel","close"];function jg(){return jg=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},jg.apply(this,arguments)}var X4={children:y().node,className:y().string,close:y().object,closeAriaLabel:y().string,cssModule:y().object,tag:F,toggle:y().func,wrapTag:F};function ZO(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,de=(function(ve,ye){if(ve==null)return{};var fe,Oe,Me={},_e=Object.keys(ve);for(Oe=0;Oe<_e.length;Oe++)fe=_e[Oe],ye.indexOf(fe)>=0||(Me[fe]=ve[fe]);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)&&(de[ie]=G[ie])}return de})(t,Y4),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,jg({},q,{className:H}),b().createElement(N,{className:R("modal-title",v)},O),$||a)}ZO.propTypes=X4;const Z4=ZO;var Q4=["className","cssModule","tag"];function Lg(){return Lg=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},Lg.apply(this,arguments)}var J4={className:y().string,cssModule:y().object,tag:F};function QO(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,Q4),I=R(x()(a,"modal-body"),u);return b().createElement(O,Lg({},A,{className:I}))}QO.propTypes=J4;const $4=QO;var eD=["className","cssModule","tag"];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 tD={className:y().string,cssModule:y().object,tag:F};function JO(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,eD),I=R(x()(a,"modal-footer"),u);return b().createElement(O,Dg({},A,{className:I}))}JO.propTypes=tD;const nD=JO;function $O(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=$O(t[a]))&&(v&&(v+=" "),v+=u)}else for(u in t)t[u]&&(v&&(v+=" "),v+=u);return v}const Rt=function(){for(var t,a,u=0,v="",O=arguments.length;u<O;u++)(t=arguments[u])&&(a=$O(t))&&(v&&(v+=" "),v+=a);return v};function rr(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 rD=(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})(),oD=Math.abs,vl=String.fromCharCode,iD=Object.assign;function ek(t){return t.trim()}function vt(t,a,u){return t.replace(a,u)}function Bg(t,a){return t.indexOf(a)}function cn(t,a){return 0|t.charCodeAt(a)}function Na(t,a,u){return t.slice(a,u)}function pr(t){return t.length}function Fg(t){return t.length}function yl(t,a){return a.push(t),t}var bl=1,si=1,tk=0,_n=0,Yt=0,li="";function wl(t,a,u,v,O,A,I){return{value:t,root:a,parent:u,type:v,props:O,children:A,line:bl,column:si,length:I,return:""}}function Ta(t,a){return iD(wl("",null,null,"",null,null,0),t,{length:-t.length},a)}function aD(){return Yt=_n>0?cn(li,--_n):0,si--,Yt===10&&(si=1,bl--),Yt}function Cn(){return Yt=_n<tk?cn(li,_n++):0,si++,Yt===10&&(si=1,bl++),Yt}function mr(){return cn(li,_n)}function xl(){return _n}function Ra(t,a){return Na(li,t,a)}function Pa(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 nk(t){return bl=si=1,tk=pr(li=t),_n=0,[]}function rk(t){return li="",t}function _l(t){return ek(Ra(_n-1,qg(t===91?t+2:t===40?t+1:t)))}function sD(t){for(;(Yt=mr())&&Yt<33;)Cn();return Pa(t)>2||Pa(Yt)>3?"":" "}function lD(t,a){for(;--a&&Cn()&&!(Yt<48||Yt>102||Yt>57&&Yt<65||Yt>70&&Yt<97););return Ra(t,xl()+(a<6&&mr()==32&&Cn()==32))}function qg(t){for(;Cn();)switch(Yt){case t:return _n;case 34:case 39:t!==34&&t!==39&&qg(Yt);break;case 40:t===41&&qg(t);break;case 92:Cn()}return _n}function uD(t,a){for(;Cn()&&t+Yt!==57&&(t+Yt!==84||mr()!==47););return"/*"+Ra(a,_n-1)+"*"+vl(t===47?t:Cn())}function cD(t){for(;!Pa(mr());)Cn();return Ra(t,_n)}var hn="-ms-",ok="-moz-",yt="-webkit-",ik="comm",zg="rule",Hg="decl",ak="@keyframes";function ui(t,a){for(var u="",v=Fg(t),O=0;O<v;O++)u+=a(t[O],O,t,a)||"";return u}function fD(t,a,u,v){switch(t.type){case"@layer":if(t.children.length)break;case"@import":case Hg:return t.return=t.return||t.value;case ik:return"";case ak:return t.return=t.value+"{"+ui(t.children,v)+"}";case zg:t.value=t.props.join(",")}return pr(u=ui(t.children,v))?t.return=t.value+"{"+u+"}":""}function dD(t){return rk(Sl("",null,null,null,[""],t=nk(t),0,[0],t))}function Sl(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,de="",me=O,ve=A,ye=v,fe=de;Q;)switch(H=ue,ue=Cn()){case 40:if(H!=108&&cn(fe,V-1)==58){Bg(fe+=vt(_l(ue),"&","&\f"),"&\f")!=-1&&(ie=-1);break}case 34:case 39:case 91:fe+=_l(ue);break;case 9:case 10:case 13:case 32:fe+=sD(H);break;case 92:fe+=lD(xl()-1,7);continue;case 47:switch(mr()){case 42:case 47:yl(hD(uD(Cn(),xl()),a,u),T);break;default:fe+="/"}break;case 123*G:N[C++]=pr(fe)*ie;case 125*G:case 59:case 0:switch(ue){case 0:case 125:Q=0;case 59+X:ie==-1&&(fe=vt(fe,/\f/g,"")),q>0&&pr(fe)-V&&yl(q>32?lk(fe+";",v,u,V-1):lk(vt(fe," ","")+";",v,u,V-2),T);break;case 59:fe+=";";default:if(yl(ye=sk(fe,a,u,C,X,O,N,de,me=[],ve=[],V),A),ue===123)if(X===0)Sl(fe,a,ye,ye,me,A,V,N,ve);else switch($===99&&cn(fe,3)===110?100:$){case 100:case 108:case 109:case 115:Sl(t,ye,ye,v&&yl(sk(t,ye,ye,0,0,O,N,de,O,me=[],V),ve),O,ve,V,N,v?me:ve);break;default:Sl(fe,ye,ye,ye,[""],ve,0,N,ve)}}C=X=q=0,G=ie=1,de=fe="",V=I;break;case 58:V=1+pr(fe),q=H;default:if(G<1){if(ue==123)--G;else if(ue==125&&G++==0&&aD()==125)continue}switch(fe+=vl(ue),ue*G){case 38:ie=X>0?1:(fe+="\f",-1);break;case 44:N[C++]=(pr(fe)-1)*ie,ie=1;break;case 64:mr()===45&&(fe+=_l(Cn())),$=mr(),X=V=pr(de=fe+=cD(xl())),ue++;break;case 45:H===45&&pr(fe)==2&&(G=0)}}return A}function sk(t,a,u,v,O,A,I,N,T,C,X){for(var V=O-1,$=O===0?A:[""],q=Fg($),H=0,G=0,Q=0;H<v;++H)for(var ie=0,ue=Na(t,V+1,V=oD(G=I[H])),de=t;ie<q;++ie)(de=ek(G>0?$[ie]+" "+ue:vt(ue,/&\f/g,$[ie])))&&(T[Q++]=de);return wl(t,a,u,O===0?zg:N,T,C,X)}function hD(t,a,u){return wl(t,a,u,ik,vl(Yt),Na(t,2,-2),0)}function lk(t,a,u,v){return wl(t,a,u,Hg,Na(t,0,v),Na(t,v+1,-1),v)}var pD=function(t,a,u){for(var v=0,O=0;v=O,O=mr(),v===38&&O===12&&(a[u]=1),!Pa(O);)Cn();return Ra(t,_n)},uk=new WeakMap,mD=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||uk.get(u))&&!v){uk.set(t,!0);for(var O=[],A=(function(X,V){return rk((function($,q){var H=-1,G=44;do switch(Pa(G)){case 0:G===38&&mr()===12&&(q[H]=1),$[H]+=pD(_n-1,q,H);break;case 2:$[H]+=_l(G);break;case 4:if(G===44){$[++H]=mr()===58?"&\f":"",q[H]=$[H].length;break}default:$[H]+=vl(G)}while(G=Cn());return $})(nk(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]}}},gD=function(t){if(t.type==="decl"){var a=t.value;a.charCodeAt(0)===108&&a.charCodeAt(2)===98&&(t.return="",t.value="")}};function ck(t,a){switch((function(u,v){return 45^cn(u,0)?(((v<<2^cn(u,0))<<2^cn(u,1))<<2^cn(u,2))<<2^cn(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+ok+t+hn+t+t;case 6828:case 4268:return yt+t+hn+t+t;case 6165:return yt+t+hn+"flex-"+t+t;case 5187:return yt+t+vt(t,/(\w+).+(:[^]+)/,yt+"box-$1$2"+hn+"flex-$1$2")+t;case 5443:return yt+t+hn+"flex-item-"+vt(t,/flex-|-self/,"")+t;case 4675:return yt+t+hn+"flex-line-pack"+vt(t,/align-content|flex-|-self/,"")+t;case 5548:return yt+t+hn+vt(t,"shrink","negative")+t;case 5292:return yt+t+hn+vt(t,"basis","preferred-size")+t;case 6060:return yt+"box-"+vt(t,"-grow","")+yt+t+hn+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"+hn+"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(pr(t)-1-a>6)switch(cn(t,a+1)){case 109:if(cn(t,a+4)!==45)break;case 102:return vt(t,/(.+:)(.+)-([^]+)/,"$1"+yt+"$2-$3$1"+ok+(cn(t,a+3)==108?"$3":"$2-$3"))+t;case 115:return~Bg(t,"stretch")?ck(vt(t,"stretch","fill-available"),a)+t:t}break;case 4949:if(cn(t,a+1)!==115)break;case 6444:switch(cn(t,pr(t)-3-(~Bg(t,"!important")&&10))){case 107:return vt(t,":",":"+yt)+t;case 101:return vt(t,/(.+:)([^;!]+)(;|!.+)?/,"$1"+yt+(cn(t,14)===45?"inline-":"")+"box$3$1"+yt+"$2$3$1"+hn+"$2box$3")+t}break;case 5936:switch(cn(t,a+11)){case 114:return yt+t+hn+vt(t,/[svh]\w+-[tblr]{2}/,"tb")+t;case 108:return yt+t+hn+vt(t,/[svh]\w+-[tblr]{2}/,"tb-rl")+t;case 45:return yt+t+hn+vt(t,/[svh]\w+-[tblr]{2}/,"lr")+t}return yt+t+hn+t+t}return t}var vD=[function(t,a,u,v){if(t.length>-1&&!t.return)switch(t.type){case Hg:t.return=ck(t.value,t.length);break;case ak:return ui([Ta(t,{value:vt(t.value,"@","@"+yt)})],v);case zg: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 ui([Ta(t,{props:[vt(O,/:(read-\w+)/,":-moz-$1")]})],v);case"::placeholder":return ui([Ta(t,{props:[vt(O,/:(plac\w+)/,":"+yt+"input-$1")]}),Ta(t,{props:[vt(O,/:(plac\w+)/,":-moz-$1")]}),Ta(t,{props:[vt(O,/:(plac\w+)/,hn+"input-$1")]})],v)}return""}))}}],yD=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||vD,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,$=[fD,(C=function(G){T.insert(G)},function(G){G.root||(G=G.return)&&C(G)})],q=(X=[mD,gD].concat(A,$),V=Fg(X),function(G,Q,ie,ue){for(var de="",me=0;me<V;me++)de+=X[me](G,Q,ie,ue)||"";return de});O=function(G,Q,ie,ue){T=ie,(function(de){ui(dD(de),q)})(G?G+"{"+Q.styles+"}":Q.styles),ue&&(H.inserted[Q.name]=!0)};var H={key:a,sheet:new rD({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},fk=function(t,a,u){var v=t.key+"-"+a.name;u===!1&&t.registered[v]===void 0&&(t.registered[v]=a.styles)},bD={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 wD(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var xD=/[A-Z]|^ms/g,_D=/_EMO_([^_]+?)_([^]*?)_EMO_/g,dk=function(t){return t.charCodeAt(1)===45},hk=function(t){return t!=null&&typeof t!="boolean"},Vg=wD((function(t){return dk(t)?t:t.replace(xD,"-$&").toLowerCase()})),pk=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(_D,(function(u,v,O){return gr={name:v,styles:O,next:gr},v}))}return bD[t]===1||dk(t)||typeof a!="number"||a===0?a:a+"px"};function Ia(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 gr={name:u.name,styles:u.styles,next:gr},u.name;if(u.styles!==void 0){var v=u.next;if(v!==void 0)for(;v!==void 0;)gr={name:v.name,styles:v.styles,next:gr},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+=Ia(I,N,T[X])+";";else for(var V in T){var $=T[V];if(typeof $!="object")hk($)&&(C+=Vg(V)+":"+pk(V,$)+";");else if(!Array.isArray($)||typeof $[0]!="string"||N!=null){var q=Ia(I,N,$);switch(V){case"animation":case"animationName":C+=Vg(V)+":"+q+";";break;default:C+=V+"{"+q+"}"}}else for(var H=0;H<$.length;H++)hk($[H])&&(C+=Vg(V)+":"+pk(V,$[H])+";")}return C})(t,a,u);case"function":if(t!==void 0){var O=gr,A=u(t);return gr=O,Ia(t,a,A)}}return u}var gr,mk=/label:\s*([^\s;\n{]+)\s*(;|$)/g,gk=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="";gr=void 0;var A=t[0];A==null||A.raw===void 0?(v=!1,O+=Ia(u,a,A)):O+=A[0];for(var I=1;I<t.length;I++)O+=Ia(u,a,t[I]),v&&(O+=A[I]);mk.lastIndex=0;for(var N,T="";(N=mk.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:gr}},vk=!!s.useInsertionEffect&&s.useInsertionEffect,SD=vk||function(t){return t()},Ug=(vk||s.useLayoutEffect,{}.hasOwnProperty),yk=s.createContext(typeof HTMLElement<"u"?yD({key:"css"}):null);yk.Provider;var bk=function(t){return(0,s.forwardRef)((function(a,u){var v=(0,s.useContext)(yk);return t(a,v,u)}))},Wg=s.createContext({}),Gg="__EMOTION_TYPE_PLEASE_DO_NOT_USE__",ED=function(t){var a=t.cache,u=t.serialized,v=t.isStringTag;return fk(a,u,v),SD((function(){return(function(O,A,I){fk(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},OD=bk((function(t,a,u){var v=t.css;typeof v=="string"&&a.registered[v]!==void 0&&(v=a.registered[v]);var O=t[Gg],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=gk(A,void 0,s.useContext(Wg));I+=a.key+"-"+N.name;var T={};for(var C in t)Ug.call(t,C)&&C!=="css"&&C!==Gg&&(T[C]=t[C]);return T.ref=u,T.className=I,s.createElement(s.Fragment,null,s.createElement(ED,{cache:a,serialized:N,isStringTag:typeof O=="string"}),s.createElement(O,T))})),kD=OD,CD={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 wk(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var AD=/[A-Z]|^ms/g,ND=/_EMO_([^_]+?)_([^]*?)_EMO_/g,xk=function(t){return t.charCodeAt(1)===45},_k=function(t){return t!=null&&typeof t!="boolean"},Kg=wk((function(t){return xk(t)?t:t.replace(AD,"-$&").toLowerCase()})),Sk=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(ND,(function(u,v,O){return vr={name:v,styles:O,next:vr},v}))}return CD[t]===1||xk(t)||typeof a!="number"||a===0?a:a+"px"};function Ma(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 vr={name:O.name,styles:O.styles,next:vr},O.name;var A=u;if(A.styles!==void 0){var I=A.next;if(I!==void 0)for(;I!==void 0;)vr={name:I.name,styles:I.styles,next:vr},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+=Ma(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]+"}":_k(ue)&&(H+=Kg(Q)+":"+Sk(Q,ue)+";")}else if(!Array.isArray(ie)||typeof ie[0]!="string"||$!=null&&$[ie[0]]!==void 0){var de=Ma(V,$,ie);switch(Q){case"animation":case"animationName":H+=Kg(Q)+":"+de+";";break;default:H+=Q+"{"+de+"}"}}else for(var me=0;me<ie.length;me++)_k(ie[me])&&(H+=Kg(Q)+":"+Sk(Q,ie[me])+";")}return H})(t,a,u);case"function":if(t!==void 0){var N=vr,T=u(t);return vr=N,Ma(t,a,T)}}var C=u;if(a==null)return C;var X=a[C];return X!==void 0?X:C}var vr,Ek=/label:\s*([^\s;{]+)\s*(;|$)/g,Ok=!!s.useInsertionEffect&&s.useInsertionEffect,TD=Ok||function(t){return t()};Ok||s.useLayoutEffect;var kk=function(t,a,u){var v=t.key+"-"+a.name;u===!1&&t.registered[v]===void 0&&(t.registered[v]=a.styles)},RD=/^((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)-.*))$/,PD=wk((function(t){return RD.test(t)||t.charCodeAt(0)===111&&t.charCodeAt(1)===110&&t.charCodeAt(2)<91})),ID=function(t){return t!=="theme"},Ck=function(t){return typeof t=="string"&&t.charCodeAt(0)>96?PD:ID},Ak=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},MD=function(t){var a=t.cache,u=t.serialized,v=t.isStringTag;return kk(a,u,v),TD((function(){return(function(O,A,I){kk(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},Yg=(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=Ak(a,u,A),T=N||Ck(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=bk((function(Q,ie,ue){var de=C&&Q.as||I,me="",ve=[],ye=Q;if(Q.theme==null){for(var fe in ye={},Q)ye[fe]=Q[fe];ye.theme=s.useContext(Wg)}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="";vr=void 0;var Ke=Ne[0];Ke==null||Ke.raw===void 0?(Le=!1,ke+=Ma(ze,Te,Ke)):ke+=Ke[0];for(var $e=1;$e<Ne.length;$e++)ke+=Ma(ze,Te,Ne[$e]),Le&&(ke+=Ke[$e]);Ek.lastIndex=0;for(var dt,lt="";(dt=Ek.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:vr}})(V.concat(ve),ie.registered,ye);me+=ie.key+"-"+Oe.name,O!==void 0&&(me+=" "+O);var Me=C&&N===void 0?Ck(de):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(MD,{cache:ie,serialized:Oe,isStringTag:typeof de=="string"}),s.createElement(de,_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:Ak(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){Yg[t]=Yg(t)}));var jD={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 LD(t){var a=Object.create(null);return function(u){return a[u]===void 0&&(a[u]=t(u)),a[u]}}var DD=/[A-Z]|^ms/g,BD=/_EMO_([^_]+?)_([^]*?)_EMO_/g,Nk=function(t){return t.charCodeAt(1)===45},Tk=function(t){return t!=null&&typeof t!="boolean"},Xg=LD((function(t){return Nk(t)?t:t.replace(DD,"-$&").toLowerCase()})),Rk=function(t,a){switch(t){case"animation":case"animationName":if(typeof a=="string")return a.replace(BD,(function(u,v,O){return no={name:v,styles:O,next:no},v}))}return jD[t]===1||Nk(t)||typeof a!="number"||a===0?a:a+"px"};function El(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 no={name:O.name,styles:O.styles,next:no},O.name;var A=u;if(A.styles!==void 0){var I=A.next;if(I!==void 0)for(;I!==void 0;)no={name:I.name,styles:I.styles,next:no},I=I.next;return A.styles+";"}return(function(T,C,X){var V="";if(Array.isArray(X))for(var $=0;$<X.length;$++)V+=El(T,C,X[$])+";";else for(var q in X){var H=X[q];if(typeof H!="object"){var G=H;Tk(G)&&(V+=Xg(q)+":"+Rk(q,G)+";")}else if(!Array.isArray(H)||typeof H[0]!="string"||C!=null){var Q=El(T,C,H);switch(q){case"animation":case"animationName":V+=Xg(q)+":"+Q+";";break;default:V+=q+"{"+Q+"}"}}else for(var ie=0;ie<H.length;ie++)Tk(H[ie])&&(V+=Xg(q)+":"+Rk(q,H[ie])+";")}return V})(t,a,u)}var N=u;return N}var no,Pk=/label:\s*([^\s;{]+)\s*(;|$)/g;function Ik(t,a){return Yg(t,a)}const Mk=[];function Oo(t){return Mk[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="";no=void 0;var I=a[0];I==null||I.raw===void 0?(O=!1,A+=El(v,u,I)):A+=I[0];for(var N=1;N<a.length;N++)A+=El(v,u,a[N]),O&&(A+=I[N]);Pk.lastIndex=0;for(var T,C="";(T=Pk.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:no}})(Mk)}function jk(t){if(t==null)return!0;for(const a in t)return!1;return!0}var Lk=d(55);function Dr(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 Dk(t){if(s.isValidElement(t)||(0,Lk.iY)(t)||!Dr(t))return t;const a={};return Object.keys(t).forEach((u=>{a[u]=Dk(t[u])})),a}function Bn(t,a,u={clone:!0}){const v=u.clone?{...t}:t;return Dr(t)&&Dr(a)&&Object.keys(a).forEach((O=>{s.isValidElement(a[O])||(0,Lk.iY)(a[O])?v[O]=a[O]:Dr(a[O])&&Object.prototype.hasOwnProperty.call(t,O)&&Dr(t[O])?v[O]=Bn(t[O],a[O],u):u.clone?v[O]=Dr(a[O])?Dk(a[O]):a[O]:v[O]=a[O]})),v}function Bk(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 Fk=/min-width:\s*([0-9.]+)/;function qk(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(Fk)?.[1]||0)-+(A.match(Fk)?.[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 zk(t,a){return a==="@"||a.startsWith("@")&&(t.some((u=>a.startsWith(`@${u}`)))||!!a.match(/^@\d/))}function FD(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 qD={borderRadius:4};function ja(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)?ci(a):u&&v?(function(A,I){const N=A.length;for(let T=0;T<I.length;T+=1)A[N+T]=ci(I[T]);return A})(t,a):u!==v?ci(a):(function(A,I){for(const N in I)A[N]=N in A?ja(A[N],I[N]):ci(I[N]);return A})(t,a);var O}function ci(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]=ci(u[v]);return A})(t):(function(u){const v={};for(const O in u)v[O]=ci(u[O]);return v})(t);var a}const zD={},Ol={xs:0,sm:600,md:900,lg:1200,xl:1536},kl=Bk({values:Ol}),HD={containerQueries:t=>({up:a=>{let u=typeof a=="number"?a:Ol[a]||a;return typeof u=="number"&&(u=`${u}px`),t?`@container ${t} (min-width:${u})`:`@container (min-width:${u})`}})};function fi(t,a,u){const v={};return Cl(v,t.theme,a,((O,A,I)=>{const N=u(A,I);O?v[O]=N:ja(v,N)}))}function Cl(t,a,u,v){if(a??=zD,Array.isArray(u)){const O=a.breakpoints??kl;for(let A=0;A<u.length;A+=1)Zg(t,O.up(O.keys[A]),u[A],void 0,v);return t}if(typeof u=="object"){const O=a.breakpoints??kl,A=O.values??Ol;for(const I in u)if(zk(O.keys,I)){const N=FD(a.containerQueries?a:HD,I);N&&Zg(t,N,u[I],I,v)}else if(I in A)Zg(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 Zg(t,a,u,v,O){t[a]??={},O(a,u,v)}function Hk(t,a){const u=t.internal_mediaKeys;for(let v=0;v<u.length;v+=1){const O=u[v];jk(a[O])&&delete a[O]}return a}function VD(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(zk(t.keys,u[v]))return!0}return!1}function ko(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 Al(t){if(typeof t!="string")throw new Error(ko(7));return t.charAt(0).toUpperCase()+t.slice(1)}function Vk(t,a,u,v){let O;return O=typeof t=="function"?t(u):Array.isArray(t)?t[u]||u:typeof u=="string"&&Nl(t,u,!0,v)||u,a&&(O=a(O,u,t)),O}function Nl(t,a,u=!0,v=void 0){if(!t||!a)return null;const O=a.split(".");if(t.vars&&u){const A=Uk(t.vars,O,v);if(A!=null)return A}return Uk(t,O,v)}function Uk(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"?"":Al(I)}`;return v?.[N]}return O}function Ut(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=Nl(I.theme,v)||{};return fi(I,N,(C=>{const X=Vk(T,O,C,a);return u===!1?X:{[u]:X}}))};return A.propTypes={},A.filterProps=[a],A}const UD={internal_cache:{}},Tl={m:"margin",p:"padding"},Wk={t:"Top",r:"Right",b:"Bottom",l:"Left",x:["Left","Right"],y:["Top","Bottom"]},Gk={marginX:"mx",marginY:"my",paddingX:"px",paddingY:"py"},La={};for(const t in Tl)La[t]=[Tl[t]];for(const t in Tl)for(const a in Wk){const u=Tl[t],v=Wk[a],O=Array.isArray(v)?v.map((A=>u+A)):[u+v];La[t+a]=O}for(const t in Gk)La[t]=La[Gk[t]];const Qg=new Set(["m","mt","mr","mb","ml","mx","my","margin","marginTop","marginRight","marginBottom","marginLeft","marginX","marginY","marginInline","marginInlineStart","marginInlineEnd","marginBlock","marginBlockStart","marginBlockEnd"]),Jg=new Set(["p","pt","pr","pb","pl","px","py","padding","paddingTop","paddingRight","paddingBottom","paddingLeft","paddingX","paddingY","paddingInline","paddingInlineStart","paddingInlineEnd","paddingBlock","paddingBlockStart","paddingBlockEnd"]);[...Qg,...Jg];function Da(t,a,u,v){const O=Nl(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 $g(t){return Da(t,"spacing",8)}function Ba(t,a){return typeof a=="string"||a==null?a:t(a)}const Kk=[""];function Yk(t,a){const u=t.theme??UD,v=u?.internal_cache?.unarySpacing??$g(u),O={};for(const A in t){if(!a.has(A))continue;const I=La[A]??(Kk[0]=A,Kk),N=t[A];Cl(O,t.theme,N,((T,C)=>{const X=T?O[T]:O;for(let V=0;V<I.length;V+=1)X[I[V]]=Ba(v,C)}))}return O}function qt(t){return Yk(t,Qg)}function zt(t){return Yk(t,Jg)}function Xk(t=8,a=$g({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}qt.propTypes={},qt.filterProps=Qg,zt.propTypes={},zt.filterProps=Jg;const Rl=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]&&ja(O,a[A](v));return O};return u.propTypes={},u.filterProps=t.reduce(((v,O)=>v.concat(O.filterProps)),[]),u};function Fn(t){return typeof t!="number"?t:`${t}px solid`}function qn(t,a){return Ut({prop:t,themeKey:"borders",transform:a})}const WD=qn("border",Fn),GD=qn("borderTop",Fn),KD=qn("borderRight",Fn),YD=qn("borderBottom",Fn),XD=qn("borderLeft",Fn),ZD=qn("borderColor"),QD=qn("borderTopColor"),JD=qn("borderRightColor"),$D=qn("borderBottomColor"),eB=qn("borderLeftColor"),tB=qn("outline",Fn),nB=qn("outlineColor"),Pl=t=>{if(t.borderRadius!==void 0&&t.borderRadius!==null){const a=Da(t.theme,"shape.borderRadius",4),u=v=>({borderRadius:Ba(a,v)});return fi(t,t.borderRadius,u)}return null};Pl.propTypes={},Pl.filterProps=["borderRadius"],Rl(WD,GD,KD,YD,XD,ZD,QD,JD,$D,eB,Pl,tB,nB);const Il=t=>{if(t.gap!==void 0&&t.gap!==null){const a=Da(t.theme,"spacing",8),u=v=>({gap:Ba(a,v)});return fi(t,t.gap,u)}return null};Il.propTypes={},Il.filterProps=["gap"];const Ml=t=>{if(t.columnGap!==void 0&&t.columnGap!==null){const a=Da(t.theme,"spacing",8),u=v=>({columnGap:Ba(a,v)});return fi(t,t.columnGap,u)}return null};Ml.propTypes={},Ml.filterProps=["columnGap"];const jl=t=>{if(t.rowGap!==void 0&&t.rowGap!==null){const a=Da(t.theme,"spacing",8),u=v=>({rowGap:Ba(a,v)});return fi(t,t.rowGap,u)}return null};function di(t,a){return a==="grey"?a:t}function An(t){return t<=1&&t!==0?100*t+"%":t}jl.propTypes={},jl.filterProps=["rowGap"],Rl(Il,Ml,jl,Ut({prop:"gridColumn"}),Ut({prop:"gridRow"}),Ut({prop:"gridAutoFlow"}),Ut({prop:"gridAutoColumns"}),Ut({prop:"gridAutoRows"}),Ut({prop:"gridTemplateColumns"}),Ut({prop:"gridTemplateRows"}),Ut({prop:"gridTemplateAreas"}),Ut({prop:"gridArea"})),Rl(Ut({prop:"color",themeKey:"palette",transform:di}),Ut({prop:"bgcolor",cssProperty:"backgroundColor",themeKey:"palette",transform:di}),Ut({prop:"backgroundColor",themeKey:"palette",transform:di}));const rB=Ut({prop:"width",transform:An}),ev=t=>{if(t.maxWidth!==void 0&&t.maxWidth!==null){const a=u=>{const v=t.theme?.breakpoints?.values?.[u]||Ol[u];return v?t.theme?.breakpoints?.unit!=="px"?{maxWidth:`${v}${t.theme.breakpoints.unit}`}:{maxWidth:v}:{maxWidth:An(u)}};return fi(t,t.maxWidth,a)}return null};ev.filterProps=["maxWidth"];const oB=Ut({prop:"minWidth",transform:An}),iB=Ut({prop:"height",transform:An}),aB=Ut({prop:"maxHeight",transform:An}),sB=Ut({prop:"minHeight",transform:An}),Ll=(Ut({prop:"size",cssProperty:"width",transform:An}),Ut({prop:"size",cssProperty:"height",transform:An}),Rl(rB,ev,oB,iB,aB,sB,Ut({prop:"boxSizing"})),{border:{themeKey:"borders",transform:Fn},borderTop:{themeKey:"borders",transform:Fn},borderRight:{themeKey:"borders",transform:Fn},borderBottom:{themeKey:"borders",transform:Fn},borderLeft:{themeKey:"borders",transform:Fn},borderColor:{themeKey:"palette"},borderTopColor:{themeKey:"palette"},borderRightColor:{themeKey:"palette"},borderBottomColor:{themeKey:"palette"},borderLeftColor:{themeKey:"palette"},outline:{themeKey:"borders",transform:Fn},outlineColor:{themeKey:"palette"},borderRadius:{themeKey:"shape.borderRadius",style:Pl},color:{themeKey:"palette",transform:di},bgcolor:{themeKey:"palette",cssProperty:"backgroundColor",transform:di},backgroundColor:{themeKey:"palette",transform:di},p:{style:zt},pt:{style:zt},pr:{style:zt},pb:{style:zt},pl:{style:zt},px:{style:zt},py:{style:zt},padding:{style:zt},paddingTop:{style:zt},paddingRight:{style:zt},paddingBottom:{style:zt},paddingLeft:{style:zt},paddingX:{style:zt},paddingY:{style:zt},paddingInline:{style:zt},paddingInlineStart:{style:zt},paddingInlineEnd:{style:zt},paddingBlock:{style:zt},paddingBlockStart:{style:zt},paddingBlockEnd:{style:zt},m:{style:qt},mt:{style:qt},mr:{style:qt},mb:{style:qt},ml:{style:qt},mx:{style:qt},my:{style:qt},margin:{style:qt},marginTop:{style:qt},marginRight:{style:qt},marginBottom:{style:qt},marginLeft:{style:qt},marginX:{style:qt},marginY:{style:qt},marginInline:{style:qt},marginInlineStart:{style:qt},marginInlineEnd:{style:qt},marginBlock:{style:qt},marginBlockStart:{style:qt},marginBlockEnd:{style:qt},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:Il},rowGap:{style:jl},columnGap:{style:Ml},gridColumn:{},gridRow:{},gridAutoFlow:{},gridAutoColumns:{},gridAutoRows:{},gridTemplateColumns:{},gridTemplateRows:{},gridTemplateAreas:{},gridArea:{},position:{},zIndex:{themeKey:"zIndex"},top:{},right:{},bottom:{},left:{},boxShadow:{themeKey:"shadows"},width:{transform:An},maxWidth:{style:ev},minWidth:{transform:An},height:{transform:An},maxHeight:{transform:An},minHeight:{transform:An},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"}}),lB={},hi=(function(){function t(a){if(!a.sx)return null;const{sx:u,theme:v=lB,nested:O}=a,A=v.unstable_sxConfig??Ll,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??kl,V=(function($=kl){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=uB(C[$],v);q!=null&&(typeof q=="object"?A[$]?Zk(V,$,q,v,A):VD(X,q)?Cl(V,a.theme,q,((H,G)=>{V[H][$]=G})):(I.sx=q,V[$]=t(I)):Zk(V,$,q,v,A))}return!O&&v.modularCssLayers?{"@layer sx":qk(v,Hk(X,V))}:qk(v,Hk(X,V))}return Array.isArray(u)?u.map(N):N(u)}return t.filterProps=["sx"],t})();function Zk(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 ja(t,N({[a]:u,theme:v}));const{cssProperty:T=a,transform:C}=A,X=Nl(v,I);Cl(t,v,u,((V,$)=>{const q=Vk(X,C,$,a);T===!1?ja(V?t[V]:t,q):V?t[V][T]=q:t[T]=q}))}function uB(t,a){return typeof t=="function"?t(a):t}function cB(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 Dl=function(t={},...a){const{breakpoints:u={},palette:v={},spacing:O,shape:A={},...I}=t;let N=Bn({breakpoints:Bk(u),direction:"ltr",components:{},palette:{mode:"light",...v},spacing:Xk(O),shape:{...qD,...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=cB,N=a.reduce(((T,C)=>Bn(T,C)),N),N.unstable_sxConfig={...Ll,...I?.unstable_sxConfig},N.unstable_sx=function(T){return hi({sx:T,theme:this})},N.internal_cache={},N};function Qk(t){const{variants:a,...u}=t,v={variants:a,style:Oo(u),isProcessed:!0};return v.style===u||a&&a.forEach((O=>{typeof O.style!="function"&&(O.style=Oo(O.style))})),v}const fB=Dl();function tv(t){return t!=="ownerState"&&t!=="theme"&&t!=="sx"&&t!=="as"}function Co(t,a){return a&&t&&typeof t=="object"&&t.styles&&!t.styles.startsWith("@layer")&&(t.styles=`@layer ${a}{${String(t.styles)}}`),t}function dB(t){return t?(a,u)=>u[t]:null}function Bl(t,a,u){const v=typeof a=="function"?a(t):a;if(Array.isArray(v))return v.flatMap((O=>Bl(t,O,u)));if(Array.isArray(v?.variants)){let O;if(v.isProcessed)O=u?Co(v.style,u):v.style;else{const{variants:A,...I}=v;O=u?Co(Oo(I),u):I}return Jk(t,v.variants,[O],u)}return v?.isProcessed?u?Co(Oo(v.style),u):v.style:u?Co(Oo(v),u):v}function Jk(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?Co(Oo(I.style(O)),v):I.style(O))):u.push(v?Co(Oo(I.style),v):I.style)}return u}function $k(t={}){const{themeId:a,defaultTheme:u=fB,rootShouldForwardProp:v=tv,slotShouldForwardProp:O=tv}=t;function A(I){(function(N,T,C){N.theme=jk(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=(fe=>fe.filter((Oe=>Oe!==hi)))(ve.__emotion_styles))})(I);const{name:T,slot:C,skipVariantsResolver:X,skipSx:V,overridesResolver:$=dB(hB(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=tv;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=Ik(I,{shouldForwardProp:ie,label:void 0,...q}),de=ve=>{if(ve.__emotion_real===ve)return ve;if(typeof ve=="function")return function(ye){return Bl(ye,ve,ye.theme.modularCssLayers?H:void 0)};if(Dr(ve)){const ye=Qk(ve);return function(fe){return ye.variants?Bl(fe,ye,fe.theme.modularCssLayers?H:void 0):fe.theme.modularCssLayers?Co(ye.style,H):ye.style}}return ve},me=(...ve)=>{const ye=[],fe=ve.map(de),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]=Bl(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?Jk(je,Te,[],je.theme.modularCssLayers?"theme":void 0):null})),Q||Oe.push(hi),Array.isArray(fe[0])){const je=fe.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,...fe,...Oe],_e=ue(...Me);return I.muiName&&(_e.muiName=I.muiName),_e};return ue.withConfig&&(me.withConfig=ue.withConfig),me}}function hB(t){return t&&t.charAt(0).toLowerCase()+t.slice(1)}const pB=function(t,a=Number.MIN_SAFE_INTEGER,u=Number.MAX_SAFE_INTEGER){return Math.max(a,Math.min(t,u))};function nv(t,a=0,u=1){return pB(t,a,u)}function ro(t){if(t.type)return t;if(t.charAt(0)==="#")return ro((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(ko(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(ko(10,v))}else O=O.split(",");return O=O.map((A=>parseFloat(A))),{type:u,values:O,colorSpace:v}}const Fa=(t,a)=>{try{return(u=>{const v=ro(u);return v.values.slice(0,3).map(((O,A)=>v.type.includes("hsl")&&A!==0?`${O}%`:O)).join(" ")})(t)}catch{return t}};function Fl(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 eC(t){t=ro(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])),Fl({type:N,values:T})}function rv(t){let a=(t=ro(t)).type==="hsl"||t.type==="hsla"?ro(eC(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 ql(t,a){return t=ro(t),a=nv(a),t.type!=="rgb"&&t.type!=="hsl"||(t.type+="a"),t.type==="color"?t.values[3]=`/${a}`:t.values[3]=a,Fl(t)}function Ao(t,a,u){try{return ql(t,a)}catch{return t}}function zl(t,a){if(t=ro(t),a=nv(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 Fl(t)}function wt(t,a,u){try{return zl(t,a)}catch{return t}}function Hl(t,a){if(t=ro(t),a=nv(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 Fl(t)}function xt(t,a,u){try{return Hl(t,a)}catch{return t}}function Vl(t,a,u){try{return(function(v,O=.15){return rv(v)>.5?zl(v,O):Hl(v,O)})(t,a)}catch{return t}}const qa={black:"#000",white:"#fff"},mB={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"},pi={50:"#f3e5f5",200:"#ce93d8",300:"#ba68c8",400:"#ab47bc",500:"#9c27b0",700:"#7b1fa2"},mi={300:"#e57373",400:"#ef5350",500:"#f44336",700:"#d32f2f",800:"#c62828"},za={300:"#ffb74d",400:"#ffa726",500:"#ff9800",700:"#f57c00",900:"#e65100"},gi={50:"#e3f2fd",200:"#90caf9",400:"#42a5f5",700:"#1976d2",800:"#1565c0"},vi={300:"#4fc3f7",400:"#29b6f6",500:"#03a9f4",700:"#0288d1",900:"#01579b"},yi={300:"#81c784",400:"#66bb6a",500:"#4caf50",700:"#388e3c",800:"#2e7d32",900:"#1b5e20"};function tC(){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:qa.white,default:qa.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 nC=tC();function rC(){return{text:{primary:qa.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:qa.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 ov=rC();function oC(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=Hl(t.main,O):a==="dark"&&(t.dark=zl(t.main,A)))}function iC(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 iv(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:gi[200],light:gi[50],dark:gi[400]}:{main:gi[700],light:gi[400],dark:gi[800]}})(a),N=t.secondary||(function(G="light"){return G==="dark"?{main:pi[200],light:pi[50],dark:pi[400]}:{main:pi[500],light:pi[300],dark:pi[700]}})(a),T=t.error||(function(G="light"){return G==="dark"?{main:mi[500],light:mi[300],dark:mi[700]}:{main:mi[700],light:mi[400],dark:mi[800]}})(a),C=t.info||(function(G="light"){return G==="dark"?{main:vi[400],light:vi[300],dark:vi[700]}:{main:vi[700],light:vi[500],dark:vi[900]}})(a),X=t.success||(function(G="light"){return G==="dark"?{main:yi[400],light:yi[300],dark:yi[700]}:{main:yi[800],light:yi[500],dark:yi[900]}})(a),V=t.warning||(function(G="light"){return G==="dark"?{main:za[400],light:za[300],dark:za[700]}:{main:"#ed6c02",light:za[500],dark:za[900]}})(a);function $(G){return O?(function(ie){return`oklch(from ${ie} var(--__l) 0 h / var(--__a))`})(G):(function(ie,ue){const de=rv(ie),me=rv(ue);return(Math.max(de,me)+.05)/(Math.min(de,me)+.05)})(G,ov.text.primary)>=u?ov.text.primary:nC.text.primary}const q=({color:G,name:Q,mainShade:ie=500,lightShade:ue=300,darkShade:de=700})=>{if(!(G={...G}).main&&G[ie]&&(G.main=G[ie]),!G.hasOwnProperty("main"))throw new Error(ko(11,Q?` (${Q})`:"",ie));if(typeof G.main!="string")throw new Error(ko(12,Q?` (${Q})`:"",JSON.stringify(G.main)));return O?(iC(O,G,"light",ue,v),iC(O,G,"dark",de,v)):(oC(G,"light",ue,v),oC(G,"dark",de,v)),G.contrastText||(G.contrastText=$(G.main)),G};let H;return a==="light"?H=tC():a==="dark"&&(H=rC()),Bn({common:{...qa},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:mB,contrastThreshold:u,getContrastText:$,augmentColor:q,tonalOffset:v,...H},A)}function gB(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 vB(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 aC=(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 av(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}),aC(A,C,`var(${$})`,V),aC(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 sC={textTransform:"uppercase"},lC='"Roboto", "Helvetica", "Arial", sans-serif';function yB(t,a){const{fontFamily:u=lC,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,de,me)=>{return{fontFamily:u,fontWeight:Q,fontSize:q(ie),lineHeight:ue,...u===lC?{letterSpacing:(ve=de/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,sC),caption:H(A,12,1.66,.4),overline:H(A,12,2.66,1,sC),inherit:{fontFamily:"inherit",fontWeight:"inherit",fontSize:"inherit",lineHeight:"inherit",letterSpacing:"inherit"}};return Bn({htmlFontSize:T,pxToRem:q,fontFamily:u,fontSize:v,fontWeightLight:O,fontWeightRegular:A,fontWeightMedium:I,fontWeightBold:N,...G},V,{clone:!1})}function Dt(...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 bB=["none",Dt(0,2,1,-1,0,1,1,0,0,1,3,0),Dt(0,3,1,-2,0,2,2,0,0,1,5,0),Dt(0,3,3,-2,0,3,4,0,0,1,8,0),Dt(0,2,4,-1,0,4,5,0,0,1,10,0),Dt(0,3,5,-1,0,5,8,0,0,1,14,0),Dt(0,3,5,-1,0,6,10,0,0,1,18,0),Dt(0,4,5,-2,0,7,10,1,0,2,16,1),Dt(0,5,5,-3,0,8,10,1,0,3,14,2),Dt(0,5,6,-3,0,9,12,1,0,3,16,2),Dt(0,6,6,-3,0,10,14,1,0,4,18,3),Dt(0,6,7,-4,0,11,15,1,0,4,20,3),Dt(0,7,8,-4,0,12,17,2,0,5,22,4),Dt(0,7,8,-4,0,13,19,2,0,5,24,4),Dt(0,7,9,-4,0,14,21,2,0,5,26,4),Dt(0,8,9,-5,0,15,22,2,0,6,28,5),Dt(0,8,10,-5,0,16,24,2,0,6,30,5),Dt(0,8,11,-5,0,17,26,2,0,6,32,5),Dt(0,9,11,-5,0,18,28,2,0,7,34,6),Dt(0,9,12,-6,0,19,29,2,0,7,36,6),Dt(0,10,13,-6,0,20,31,3,0,8,38,7),Dt(0,10,13,-6,0,21,33,3,0,8,40,7),Dt(0,10,14,-6,0,22,35,3,0,8,42,7),Dt(0,11,14,-7,0,23,36,3,0,9,44,8),Dt(0,11,15,-7,0,24,38,3,0,9,46,8)],wB={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)"},xB={shortest:150,shorter:200,short:250,standard:300,complex:375,enteringScreen:225,leavingScreen:195};function uC(t){return`${Math.round(t)}ms`}function _B(t){if(!t)return 0;const a=t/36;return Math.min(Math.round(10*(4+15*a**.25+a/5)),3e3)}function SB(t){const a={...wB,...t.easing},u={...xB,...t.duration};return{getAutoHeightDuration:_B,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:uC(A)} ${I} ${typeof N=="string"?N:uC(N)}`)).join(",")},...t,easing:a,duration:u}}const EB={mobileStepper:1e3,fab:1050,speedDial:1050,appBar:1100,drawer:1200,modal:1300,snackbar:1400,tooltip:1500};function cC(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];!Dr(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]:Dr(T)&&(v[N]={...T},u(v[N]))}var A})(a),`import { unstable_createBreakpoints as createBreakpoints, createTransitions } from '@mui/material/styles';
|
|
20
20
|
|
|
21
21
|
const theme = ${JSON.stringify(a,null,2)};
|
|
22
22
|
|
|
23
23
|
theme.breakpoints = createBreakpoints(theme.breakpoints || {});
|
|
24
24
|
theme.transitions = createTransitions(theme.transitions || {});
|
|
25
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`
|
|
26
|
+
export default theme;`}function fC(t){return typeof t=="number"?`${(100*t).toFixed(0)}%`:`calc((${t}) * 100%)`}const sv=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(ko(22));const V=iv({...A,colorSpace:C}),$=Dl(t);let q=Bn($,{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:bB.slice(),typography:yB(V,N),transitions:SB(I),zIndex:{...EB}});var H,G,Q;return q=Bn(q,X),q=a.reduce(((ie,ue)=>Bn(ie,ue)),q),q.unstable_sxConfig={...Ll,...X?.unstable_sxConfig},q.unstable_sx=function(ie){return hi({sx:ie,theme:this})},q.toRuntimeSource=cC,Q=q,Object.assign(Q,{alpha(ie,ue){const de=this||Q;return de.colorSpace?`oklch(from ${ie} l c h / ${typeof ue=="string"?`calc(${ue})`:ue})`:de.vars?`rgba(${ie.replace(/var\(--([^,\s)]+)(?:,[^)]+)?\)+/g,"var(--$1Channel)")} / ${typeof ue=="string"?`calc(${ue})`:ue})`:ql(ie,(me=>{if(!Number.isNaN(+me))return+me;const ve=me.match(/\d*\.?\d+/g);if(!ve)return 0;let ye=0;for(let fe=0;fe<ve.length;fe+=1)ye+=+ve[fe];return ye})(ue))},lighten(ie,ue){const de=this||Q;return de.colorSpace?`color-mix(in ${de.colorSpace}, ${ie}, #fff ${fC(ue)})`:Hl(ie,ue)},darken(ie,ue){const de=this||Q;return de.colorSpace?`color-mix(in ${de.colorSpace}, ${ie}, #000 ${fC(ue)})`:zl(ie,ue)}}),q};function lv(t){let a;return a=t<1?5.11916*t**2:4.5*Math.log(t+1)+2,Math.round(10*a)/1e3}const OB=[...Array(25)].map(((t,a)=>{if(a===0)return"none";const u=lv(a);return`linear-gradient(rgba(255 255 255 / ${u}), rgba(255 255 255 / ${u}))`}));function dC(t){return{inputPlaceholder:t==="dark"?.5:.42,inputUnderline:t==="dark"?.7:.42,switchTrackDisabled:t==="dark"?.2:.12,switchTrack:t==="dark"?.3:.38}}function hC(t){return t==="dark"?OB:[]}function kB(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 CB=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 Ha(t){return typeof t=="string"&&t.startsWith("hsl")?eC(t):t}function Br(t,a){`${a}Channel`in t||(t[`${a}Channel`]=Fa(Ha(t[a])))}const yr=t=>{try{return t()}catch{}};function uv(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=iv({...C,colorSpace:$});return{palette:H,opacity:{...dC(H.mode),...X},overlays:V||hC(H.mode),...q}})({...u,palette:{mode:A,...u?.palette},colorSpace:t}));const{palette:I,...N}=sv({...v,palette:{mode:A,...u?.palette},colorSpace:t});return a[O]={...u,palette:I,opacity:{...dC(A),...u?.opacity},overlays:u?.overlays||hC(A)},N}function pC(t,a,u){t.colorSchemes&&u&&(t.colorSchemes[a]={...u!==!0&&u,palette:iv({...u===!0?{}:u.palette,mode:a})})}function mC(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 sv(t,...a);let X=u;"palette"in t||C[N]&&(C[N]!==!0?X=C[N].palette:N==="dark"&&(X={mode:"dark"}));const V=sv({...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},pC(V,"dark",C.dark)),V.palette.mode==="dark"&&(V.colorSchemes.dark={...C.dark!==!0&&C.dark,palette:V.palette},pC(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=kB,colorSchemeSelector:ue=$.light&&$.dark?"media":void 0,rootSelector:de=":root",...me}=X,ve=Object.keys($)[0],ye=q||($.light&&ve!=="light"?"light":ve),fe=((Xe="mui")=>gB(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(ko(21,ye));Q&&(Te="oklch");const Le=uv(Te,Ne,ze,me,ye);Me&&!Ne.light&&uv(Te,Ne,Me,void 0,"light"),_e&&!Ne.dark&&uv(Te,Ne,_e,void 0,"dark");let ke={defaultColorScheme:ye,...Le,cssVarPrefix:G,colorSchemeSelector:ue,rootSelector:de,getCssVar:fe,colorSchemes:Ne,font:{...vB(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],Ot=at[2];return fe(it,le[bt][Ot])};function Ie(it,at,bt){if(Te){let Ot;return it===Ao&&(Ot=`transparent ${(100*(1-bt)).toFixed(0)}%`),it===wt&&(Ot=`#000 ${(100*bt).toFixed(0)}%`),it===xt&&(Ot=`#fff ${(100*bt).toFixed(0)}%`),`color-mix(in ${Te}, ${at}, ${Ot})`}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(wt,Q?fe("palette-error-light"):le.error.light,.6)),Se(le.Alert,"infoColor",Ie(wt,Q?fe("palette-info-light"):le.info.light,.6)),Se(le.Alert,"successColor",Ie(wt,Q?fe("palette-success-light"):le.success.light,.6)),Se(le.Alert,"warningColor",Ie(wt,Q?fe("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",yr((()=>le.getContrastText(le.error.main)))),Se(le.Alert,"infoFilledColor",yr((()=>le.getContrastText(le.info.main)))),Se(le.Alert,"successFilledColor",yr((()=>le.getContrastText(le.success.main)))),Se(le.Alert,"warningFilledColor",yr((()=>le.getContrastText(le.warning.main)))),Se(le.Alert,"errorStandardBg",Ie(xt,Q?fe("palette-error-light"):le.error.light,.9)),Se(le.Alert,"infoStandardBg",Ie(xt,Q?fe("palette-info-light"):le.info.light,.9)),Se(le.Alert,"successStandardBg",Ie(xt,Q?fe("palette-success-light"):le.success.light,.9)),Se(le.Alert,"warningStandardBg",Ie(xt,Q?fe("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(xt,Q?fe("palette-primary-main"):le.primary.main,.62)),Se(le.LinearProgress,"secondaryBg",Ie(xt,Q?fe("palette-secondary-main"):le.secondary.main,.62)),Se(le.LinearProgress,"errorBg",Ie(xt,Q?fe("palette-error-main"):le.error.main,.62)),Se(le.LinearProgress,"infoBg",Ie(xt,Q?fe("palette-info-main"):le.info.main,.62)),Se(le.LinearProgress,"successBg",Ie(xt,Q?fe("palette-success-main"):le.success.main,.62)),Se(le.LinearProgress,"warningBg",Ie(xt,Q?fe("palette-warning-light"):le.warning.main,.62)),Se(le.Skeleton,"bg",Te?Ie(Ao,Q?fe("palette-text-primary"):le.text.primary,.11):`rgba(${qe("palette-text-primaryChannel")} / 0.11)`),Se(le.Slider,"primaryTrack",Ie(xt,Q?fe("palette-primary-main"):le.primary.main,.62)),Se(le.Slider,"secondaryTrack",Ie(xt,Q?fe("palette-secondary-main"):le.secondary.main,.62)),Se(le.Slider,"errorTrack",Ie(xt,Q?fe("palette-error-main"):le.error.main,.62)),Se(le.Slider,"infoTrack",Ie(xt,Q?fe("palette-info-main"):le.info.main,.62)),Se(le.Slider,"successTrack",Ie(xt,Q?fe("palette-success-main"):le.success.main,.62)),Se(le.Slider,"warningTrack",Ie(xt,Q?fe("palette-warning-main"):le.warning.main,.62));const it=Te?Ie(wt,Q?fe("palette-background-default"):le.background.default,.6825):Vl(le.background.default,.8);Se(le.SnackbarContent,"bg",it),Se(le.SnackbarContent,"color",yr((()=>Te?ov.text.primary:le.getContrastText(it)))),Se(le.SpeedDialAction,"fabHoverBg",Vl(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(xt,Q?fe("palette-primary-main"):le.primary.main,.62)),Se(le.Switch,"secondaryDisabledColor",Ie(xt,Q?fe("palette-secondary-main"):le.secondary.main,.62)),Se(le.Switch,"errorDisabledColor",Ie(xt,Q?fe("palette-error-main"):le.error.main,.62)),Se(le.Switch,"infoDisabledColor",Ie(xt,Q?fe("palette-info-main"):le.info.main,.62)),Se(le.Switch,"successDisabledColor",Ie(xt,Q?fe("palette-success-main"):le.success.main,.62)),Se(le.Switch,"warningDisabledColor",Ie(xt,Q?fe("palette-warning-main"):le.warning.main,.62)),Se(le.TableCell,"border",Ie(xt,Ao(Q?fe("palette-divider"):le.divider,1),.88)),Se(le.Tooltip,"bg",Ie(Ao,Q?fe("palette-grey-700"):le.grey[700],.92))}var Ye;if(le.mode==="dark"){Se(le.Alert,"errorColor",Ie(xt,Q?fe("palette-error-light"):le.error.light,.6)),Se(le.Alert,"infoColor",Ie(xt,Q?fe("palette-info-light"):le.info.light,.6)),Se(le.Alert,"successColor",Ie(xt,Q?fe("palette-success-light"):le.success.light,.6)),Se(le.Alert,"warningColor",Ie(xt,Q?fe("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",yr((()=>le.getContrastText(le.error.dark)))),Se(le.Alert,"infoFilledColor",yr((()=>le.getContrastText(le.info.dark)))),Se(le.Alert,"successFilledColor",yr((()=>le.getContrastText(le.success.dark)))),Se(le.Alert,"warningFilledColor",yr((()=>le.getContrastText(le.warning.dark)))),Se(le.Alert,"errorStandardBg",Ie(wt,Q?fe("palette-error-light"):le.error.light,.9)),Se(le.Alert,"infoStandardBg",Ie(wt,Q?fe("palette-info-light"):le.info.light,.9)),Se(le.Alert,"successStandardBg",Ie(wt,Q?fe("palette-success-light"):le.success.light,.9)),Se(le.Alert,"warningStandardBg",Ie(wt,Q?fe("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(wt,Q?fe("palette-primary-main"):le.primary.main,.5)),Se(le.LinearProgress,"secondaryBg",Ie(wt,Q?fe("palette-secondary-main"):le.secondary.main,.5)),Se(le.LinearProgress,"errorBg",Ie(wt,Q?fe("palette-error-main"):le.error.main,.5)),Se(le.LinearProgress,"infoBg",Ie(wt,Q?fe("palette-info-main"):le.info.main,.5)),Se(le.LinearProgress,"successBg",Ie(wt,Q?fe("palette-success-main"):le.success.main,.5)),Se(le.LinearProgress,"warningBg",Ie(wt,Q?fe("palette-warning-main"):le.warning.main,.5)),Se(le.Skeleton,"bg",Te?Ie(Ao,Q?fe("palette-text-primary"):le.text.primary,.13):`rgba(${qe("palette-text-primaryChannel")} / 0.13)`),Se(le.Slider,"primaryTrack",Ie(wt,Q?fe("palette-primary-main"):le.primary.main,.5)),Se(le.Slider,"secondaryTrack",Ie(wt,Q?fe("palette-secondary-main"):le.secondary.main,.5)),Se(le.Slider,"errorTrack",Ie(wt,Q?fe("palette-error-main"):le.error.main,.5)),Se(le.Slider,"infoTrack",Ie(wt,Q?fe("palette-info-main"):le.info.main,.5)),Se(le.Slider,"successTrack",Ie(wt,Q?fe("palette-success-main"):le.success.main,.5)),Se(le.Slider,"warningTrack",Ie(wt,Q?fe("palette-warning-light"):le.warning.main,.5));const it=Te?Ie(xt,Q?fe("palette-background-default"):le.background.default,.985):Vl(le.background.default,.98);Se(le.SnackbarContent,"bg",it),Se(le.SnackbarContent,"color",yr((()=>Te?nC.text.primary:le.getContrastText(it)))),Se(le.SpeedDialAction,"fabHoverBg",Vl(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(wt,Q?fe("palette-primary-main"):le.primary.main,.55)),Se(le.Switch,"secondaryDisabledColor",Ie(wt,Q?fe("palette-secondary-main"):le.secondary.main,.55)),Se(le.Switch,"errorDisabledColor",Ie(wt,Q?fe("palette-error-main"):le.error.main,.55)),Se(le.Switch,"infoDisabledColor",Ie(wt,Q?fe("palette-info-main"):le.info.main,.55)),Se(le.Switch,"successDisabledColor",Ie(wt,Q?fe("palette-success-main"):le.success.main,.55)),Se(le.Switch,"warningDisabledColor",Ie(wt,Q?fe("palette-warning-light"):le.warning.main,.55)),Se(le.TableCell,"border",Ie(wt,Ao(Q?fe("palette-divider"):le.divider,1),.68)),Se(le.Tooltip,"bg",Ie(Ao,Q?fe("palette-grey-700"):le.grey[700],.92))}Q||(Br(le.background,"default"),Br(le.background,"paper"),Br(le.common,"background"),Br(le.common,"onBackground"),Br(le,"divider")),Object.keys(le).forEach((it=>{const at=le[it];it!=="tonalOffset"&&!Q&&at&&typeof at=="object"&&(at.main&&Se(le[it],"mainChannel",Fa(Ha(at.main))),at.light&&Se(le[it],"lightChannel",Fa(Ha(at.light))),at.dark&&Se(le[it],"darkChannel",Fa(Ha(at.dark))),at.contrastText&&Se(le[it],"contrastTextChannel",Fa(Ha(at.contrastText))),it==="text"&&(Br(le[it],"primary"),Br(le[it],"secondary")),it==="action"&&(at.active&&Br(le[it],"active"),at.selected&&Br(le[it],"selected")))}))})),ke=V.reduce(((Xe,le)=>Bn(Xe,le)),ke);const $e={prefix:G,disableCssColorScheme:H,shouldSkipGeneratingVar:ie,getSelector:CB(ke),enableContrastVars:Q},{vars:dt,generateThemeVars:lt,generateStyleSheets:gt}=(function(Xe,le={}){const{getSelector:qe=ir,disableCssColorScheme:Ie,colorSchemeSelector:Ye,enableContrastVars:it}=le,{colorSchemes:at={},components:bt,defaultColorScheme:Ot="light",...Xt}=Xe,{vars:Zt,css:nn,varsWithDefaults:Sn}=av(Xt,le);let rn=Sn;const _t={},{[Ot]:Wt,...En}=at;if(Object.entries(En||{}).forEach((([kt,fn])=>{const{vars:Qt,css:zr,varsWithDefaults:Mo}=av(fn,le);rn=Bn(rn,Mo),_t[kt]={css:zr,vars:Qt}})),Wt){const{css:kt,vars:fn,varsWithDefaults:Qt}=av(Wt,le);rn=Bn(rn,Qt),_t[Ot]={css:kt,vars:fn}}function ir(kt,fn){let Qt=Ye;if(Ye==="class"&&(Qt=".%s"),Ye==="data"&&(Qt="[data-%s]"),Ye?.startsWith("data-")&&!Ye.includes("%s")&&(Qt=`[${Ye}="%s"]`),kt){if(Qt==="media")return Xe.defaultColorScheme===kt?":root":{[`@media (prefers-color-scheme: ${at[kt]?.palette?.mode||kt})`]:{":root":fn}};if(Qt)return Xe.defaultColorScheme===kt?`:root, ${Qt.replace("%s",String(kt))}`:Qt.replace("%s",String(kt))}return":root"}return{vars:rn,generateThemeVars:()=>{let kt={...Zt};return Object.entries(_t).forEach((([,{vars:fn}])=>{kt=Bn(kt,fn)})),kt},generateStyleSheets:()=>{const kt=[],fn=Xe.defaultColorScheme||"light";function Qt(Tn,Yn){Object.keys(Yn).length&&kt.push(typeof Tn=="string"?{[Tn]:{...Yn}}:Tn)}Qt(qe(void 0,{...nn}),nn);const{[fn]:zr,...Mo}=_t;if(zr){const{css:Tn}=zr,Yn=at[fn]?.palette?.mode,wr=!Ie&&Yn?{colorScheme:Yn,...Tn}:{...Tn};Qt(qe(fn,{...wr}),wr)}return Object.entries(Mo).forEach((([Tn,{css:Yn}])=>{const wr=at[Tn]?.palette?.mode,Ni=!Ie&&wr?{colorScheme:wr,...Yn}:{...Yn};Qt(qe(Tn,{...Ni}),Ni)})),it&&kt.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)"}}),kt}}})(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 Xk(me.spacing,$g(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={...Ll,...me?.unstable_sxConfig},ke.unstable_sx=function(Xe){return hi({sx:Xe,theme:this})},ke.internal_cache={},ke.toRuntimeSource=cC,ke})({...I,colorSchemes:C,defaultColorScheme:N,...typeof v!="boolean"&&v},...a)}const gC=mC(),cv="$$material",Bt=$k({themeId:cv,defaultTheme:gC,rootShouldForwardProp:t=>(function(a){return a!=="ownerState"&&a!=="theme"&&a!=="sx"&&a!=="as"})(t)&&t!=="classes"}),vC={theme:void 0},zn=function(t){let a,u;return function(v){let O=a;return O!==void 0&&v.theme===u||(vC.theme=v.theme,O=Qk(t(vC)),a=O,u=v.theme),O}};function Ul(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]=Ul(I[C],N[C],u)}}else v[A]=N;else v[A]=I||{}}else A==="className"&&u&&a.className!==void 0?v.className=Rt(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 AB=s.createContext(void 0);function Hn(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?Ul(N.defaultProps,I,O.components.mergeClassNameAndStyle):N.styleOverrides||N.variants?I:Ul(N,I,O.components.mergeClassNameAndStyle)})({props:a,name:u,theme:{components:s.useContext(AB)}})})(t)}function Wl(...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 yC=function(t,a,u){return t===void 0||typeof t=="string"?a:{...a,ownerState:{...a.ownerState,...u}}},bC=function(t,a,u){return typeof t=="function"?t(a,u):t};function NB(t,a){const u=t.charCodeAt(2);return t[0]==="o"&&t[1]==="n"&&u>=65&&u<=90&&typeof a=="function"}const wC=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},xC=function(t){const{getSlotProps:a,additionalProps:u,externalSlotProps:v,externalForwardedProps:O,className:A}=t;if(!a){const q=Rt(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))NB(G,q[G])&&(H[G]=q[G]);return H})({...O,...v}),N=wC(v),T=wC(O),C=a(I),X=Rt(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 Vn(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=bC(V[t],O),{props:{component:G,...Q},internalRef:ie}=xC({className:u,...T,externalForwardedProps:t==="root"?$:void 0,externalSlotProps:H}),ue=Wl(ie,H?.ref,a.ref),de=t==="root"?G||C:G;return[q,yC(q,{...t==="root"&&!C&&!X[t]&&I,...t!=="root"&&!X[t]&&I,...Q,...de&&!N&&{as:de},...de&&N&&{component:de},ref:ue},O)]}const tn=Al;function bi(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 TB=Dl(),fv=function(t=TB){return(function(a=null){const u=s.useContext(Wg);return u&&(v=u,Object.keys(v).length!==0)?u:a;var v})(t)};function _C(){const t=fv(gC);return t[cv]||t}const SC=t=>t,EC=(()=>{let t=SC;return{configure(a){t=a},generate:a=>t(a),reset(){t=SC}}})(),RB={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 Un(t,a,u="Mui"){const v=RB[a];return v?`${u}-${v}`:`${EC.generate(t)}-${a}`}function Wn(t,a,u="Mui"){const v={};return a.forEach((O=>{v[O]=Un(t,O,u)})),v}function PB(t){return Un("MuiPaper",t)}Wn("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 IB=Bt("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}`]]}})(zn((({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)"}}]})))),MB=s.forwardRef((function(t,a){const u=Hn({props:t,name:"MuiPaper"}),v=_C(),{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 rr({root:["root",G,!q&&"rounded",G==="elevation"&&`elevation${H}`]},PB,Q)})(X);return(0,Je.jsx)(IB,{as:A,ownerState:X,className:Rt(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(${ql("#fff",lv(I))}, ${ql("#fff",lv(I))})`}},...C.style}})}));function jB(t){return Un("MuiAlert",t)}const OC=Wn("MuiAlert",["root","action","icon","message","filled","colorSuccess","colorInfo","colorWarning","colorError","outlined","standard"]);let kC=0;const CC={...S}.useId;function AC(t){try{return t.matches(":focus-visible")}catch{}return!1}const dv=Wl,Gl=typeof window<"u"?s.useLayoutEffect:s.useEffect,Kl=function(t){const a=s.useRef(t);return Gl((()=>{a.current=t})),s.useRef(((...u)=>(0,a.current)(...u))).current},No=Kl,LB={},NC={};function TC(t,a){const u=s.useRef(NC);return u.current===NC&&(u.current=t(a)),u}class Yl{static create(){return new Yl}static use(){const a=TC(Yl.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 Xl(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function hv(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 To(t,a,u){return u[a]!=null?u[a]:t.props[a]}function DB(t,a,u){var v=hv(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:To(I,"exit",t),enter:To(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:To(I,"exit",t),enter:To(I,"enter",t)})}})),O}var BB=Object.values||function(t){return Object.keys(t).map((function(a){return t[a]}))},pv=(function(t){function a(v,O){var A,I=(A=t.call(this,v,O)||this).handleExited.bind(Xl(A));return A.state={contextValue:{isMounting:!0},handleExited:I,firstRender:!0},A}Ea(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,hv(A.children,(function(C){return(0,s.cloneElement)(C,{onExited:I.bind(null,C),in:!0,appear:To(C,"appear",A),enter:To(C,"enter",A),exit:To(C,"exit",A)})}))):DB(v,N,T),firstRender:!1}},u.handleExited=function(v,O){var A=hv(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=Sa(v,["component","childFactory"]),N=this.state.contextValue,T=BB(this.state.children).map(A);return delete I.appear,delete I.enter,delete I.exit,O===null?b().createElement(ri.Provider,{value:N},T):b().createElement(ri.Provider,{value:N},b().createElement(O,I,T))},a})(b().Component);pv.propTypes={},pv.defaultProps={component:"div",childFactory:function(t){return t}};const FB=pv,qB=[];class mv{static create(){return new mv}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||!Ug.call(a,"css"))return s.createElement.apply(void 0,u);var v=u.length,O=new Array(v);O[0]=kD,O[1]=(function(I,N){var T={};for(var C in N)Ug.call(N,C)&&(T[C]=N[C]);return T[Gg]=I,T})(t,a);for(var A=2;A<v;A++)O[A]=u[A];return s.createElement.apply(null,O)};function Va(){for(var t=arguments.length,a=new Array(t),u=0;u<t;u++)a[u]=arguments[u];return gk(a)}var wi=function(){var t=Va.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 Gn=Wn("MuiTouchRipple",["root","ripple","rippleVisible","ripplePulsate","child","childLeaving","childPulsate"]),zB=wi`
|
|
27
27
|
0% {
|
|
28
28
|
transform: scale(0);
|
|
29
29
|
opacity: 0.1;
|
|
@@ -33,7 +33,7 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
33
33
|
transform: scale(1);
|
|
34
34
|
opacity: 0.3;
|
|
35
35
|
}
|
|
36
|
-
`,
|
|
36
|
+
`,HB=wi`
|
|
37
37
|
0% {
|
|
38
38
|
opacity: 1;
|
|
39
39
|
}
|
|
@@ -41,7 +41,7 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
41
41
|
100% {
|
|
42
42
|
opacity: 0;
|
|
43
43
|
}
|
|
44
|
-
`,
|
|
44
|
+
`,VB=wi`
|
|
45
45
|
0% {
|
|
46
46
|
transform: scale(1);
|
|
47
47
|
}
|
|
@@ -53,23 +53,23 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
53
53
|
100% {
|
|
54
54
|
transform: scale(1);
|
|
55
55
|
}
|
|
56
|
-
`,
|
|
56
|
+
`,UB=Bt("span",{name:"MuiTouchRipple",slot:"Root"})({overflow:"hidden",pointerEvents:"none",position:"absolute",zIndex:0,top:0,right:0,bottom:0,left:0,borderRadius:"inherit"}),WB=Bt((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),$=Rt(a,u.ripple,u.rippleVisible,v&&u.ripplePulsate),q={width:I,height:I,top:-I/2+A,left:-I/2+O},H=Rt(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
57
|
opacity: 0;
|
|
58
58
|
position: absolute;
|
|
59
59
|
|
|
60
|
-
&.${
|
|
60
|
+
&.${Gn.rippleVisible} {
|
|
61
61
|
opacity: 0.3;
|
|
62
62
|
transform: scale(1);
|
|
63
|
-
animation-name: ${
|
|
63
|
+
animation-name: ${zB};
|
|
64
64
|
animation-duration: ${550}ms;
|
|
65
65
|
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
66
66
|
}
|
|
67
67
|
|
|
68
|
-
&.${
|
|
68
|
+
&.${Gn.ripplePulsate} {
|
|
69
69
|
animation-duration: ${({theme:t})=>t.transitions.duration.shorter}ms;
|
|
70
70
|
}
|
|
71
71
|
|
|
72
|
-
& .${
|
|
72
|
+
& .${Gn.child} {
|
|
73
73
|
opacity: 1;
|
|
74
74
|
display: block;
|
|
75
75
|
width: 100%;
|
|
@@ -78,25 +78,25 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
78
78
|
background-color: currentColor;
|
|
79
79
|
}
|
|
80
80
|
|
|
81
|
-
& .${
|
|
81
|
+
& .${Gn.childLeaving} {
|
|
82
82
|
opacity: 0;
|
|
83
|
-
animation-name: ${
|
|
83
|
+
animation-name: ${HB};
|
|
84
84
|
animation-duration: ${550}ms;
|
|
85
85
|
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
& .${
|
|
88
|
+
& .${Gn.childPulsate} {
|
|
89
89
|
position: absolute;
|
|
90
90
|
/* @noflip */
|
|
91
91
|
left: 0px;
|
|
92
92
|
top: 0;
|
|
93
|
-
animation-name: ${
|
|
93
|
+
animation-name: ${VB};
|
|
94
94
|
animation-duration: 2500ms;
|
|
95
95
|
animation-timing-function: ${({theme:t})=>t.transitions.easing.easeInOut};
|
|
96
96
|
animation-iteration-count: infinite;
|
|
97
97
|
animation-delay: 200ms;
|
|
98
98
|
}
|
|
99
|
-
`,
|
|
99
|
+
`,GB=s.forwardRef((function(t,a){const u=Hn({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 de=TC(mv.create).current;var me;return me=de.disposeEffect,s.useEffect(me,qB),de})(),q=s.useRef(null),H=s.useRef(null),G=s.useCallback((de=>{const{pulsate:me,rippleX:ve,rippleY:ye,rippleSize:fe,cb:Oe}=de;T((Me=>[...Me,(0,Je.jsx)(WB,{classes:{ripple:Rt(O.ripple,Gn.ripple),rippleVisible:Rt(O.rippleVisible,Gn.rippleVisible),ripplePulsate:Rt(O.ripplePulsate,Gn.ripplePulsate),child:Rt(O.child,Gn.child),childLeaving:Rt(O.childLeaving,Gn.childLeaving),childPulsate:Rt(O.childPulsate,Gn.childPulsate)},timeout:550,pulsate:me,rippleX:ve,rippleY:ye,rippleSize:fe},C.current)])),C.current+=1,X.current=Oe}),[O]),Q=s.useCallback(((de={},me={},ve=(()=>{}))=>{const{pulsate:ye=!1,center:fe=v||me.pulsate,fakeElement:Oe=!1}=me;if(de?.type==="mousedown"&&V.current)return void(V.current=!1);de?.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(fe||de===void 0||de.clientX===0&&de.clientY===0||!de.clientX&&!de.touches)je=Math.round(_e.width/2),Ne=Math.round(_e.height/2);else{const{clientX:ze,clientY:Le}=de.touches&&de.touches.length>0?de.touches[0]:de;je=Math.round(ze-_e.left),Ne=Math.round(Le-_e.top)}if(fe)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)}de?.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(((de,me)=>{if($.clear(),de?.type==="touchend"&&q.current)return q.current(),q.current=null,void $.start(0,(()=>{ue(de,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)(UB,{className:Rt(Gn.root,O.root,A),ref:H,...I,children:(0,Je.jsx)(FB,{component:null,exit:!0,children:N})})})),KB=GB;function YB(t){return Un("MuiButtonBase",t)}const XB=Wn("MuiButtonBase",["root","disabled","focusVisible"]),ZB=Bt("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"},[`&.${XB.disabled}`]:{pointerEvents:"none",cursor:"default"},"@media print":{colorAdjust:"exact"}});function Fr(t,a,u,v=!1){return No((O=>(u&&u(O),v||t[a](O),!0)))}const gv=s.forwardRef((function(t,a){const u=Hn({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:de,onContextMenu:me,onDragLeave:ve,onFocus:ye,onFocusVisible:fe,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=Yl.use(),it=dv(Ye.ref,$e),[at,bt]=s.useState(!1);(T||H)&&at&&bt(!1);const Ot=No((St=>{V&&!St.repeat&&at&&St.key===" "&&Ye.stop(St,(()=>{Ye.start(St)}))})),Xt=No((St=>{V&&St.key===" "&&at&&!St.defaultPrevented&&Ye.stop(St,(()=>{Ye.pulsate(St)}))})),{getButtonProps:Zt,rootRef:nn}=(function(St){const{nativeButton:Hr,disabled:yn,type:Vr,hasFormAction:ao=!1,tabIndex:Ur=0,focusableWhenDisabled:Ri,stopEventPropagation:Eu=!1,onBeforeKeyDown:Pi,onBeforeKeyUp:Ou}=St,ku=s.useRef(null),xr=Ri===!0,Ii=(function(dn){const{focusableWhenDisabled:Ge,disabled:He,composite:rt=!1,tabIndex:st=0,isNativeButton:Ze}=dn,Ct=rt&&Ge!==!1,on=rt&&Ge===!1;return s.useMemo((()=>{const pn={onKeyDown(ar){He&&Ge&&ar.key!=="Tab"&&ar.preventDefault()}};return rt||(pn.tabIndex=st,!Ze&&He&&(pn.tabIndex=Ge?st:-1)),(Ze&&(Ge||Ct)||!Ze&&He)&&(pn["aria-disabled"]=He),!Ze||Ge&&!on||(pn.disabled=He),pn}),[rt,He,Ge,Ct,on,Ze,st])})({focusableWhenDisabled:xr,disabled:yn,isNativeButton:Hr,tabIndex:Ur}),$a=s.useCallback((()=>{const dn=ku.current;return dn==null?Hr:dn.tagName==="BUTTON"||!!(dn.tagName==="A"&&dn.href)}),[Hr]),Cu=s.useMemo((()=>{const dn=xr?{}:{tabIndex:yn?-1:Ur};return Hr?(dn.type=Vr!==void 0||ao?Vr:"button",xr||(dn.disabled=yn)):(dn.role="button",!xr&&yn&&(dn["aria-disabled"]=yn)),xr?{...dn,...Ii}:dn}),[yn,xr,Ii,ao,Hr,Ur,Vr]);return{getButtonProps:s.useCallback(((dn=LB)=>{const{onClick:Ge,onKeyDown:He,onKeyUp:rt,...st}=dn;return{...Cu,...st,onClick:Ze=>{Eu&&Ze.stopPropagation(),yn?Ze.preventDefault():Ge?.(Ze)},onKeyDown:Ze=>{xr&&Ii.onKeyDown(Ze),yn||(Pi?.(Ze),He?.(Ze),Ze.target!==Ze.currentTarget||$a()||(Ze.key!==" "?Ze.key==="Enter"&&(Ze.preventDefault(),Ze.currentTarget.click()):Ze.preventDefault()))},onKeyUp:Ze=>{yn||(Ou?.(Ze),rt?.(Ze),Ze.target!==Ze.currentTarget||$a()||Ze.key!==" "||Ze.defaultPrevented||Ze.currentTarget.click())}}}),[Cu,yn,xr,Ii,$a,Pi,Ou,Eu]),rootRef:ku}})({nativeButton:Ie,disabled:T,type:dt,hasFormAction:Xe,tabIndex:ke,onBeforeKeyDown:Ot,onBeforeKeyUp:Xt}),{onClick:Sn,onKeyDown:rn,onKeyUp:_t,...Wt}=Zt({onClick:de,onKeyDown:Oe,onKeyUp:Me});s.useImperativeHandle(v,(()=>({focusVisible:()=>{bt(!0),nn.current.focus()}})),[nn]);const En=Ye.shouldMount&&!C&&!T;s.useEffect((()=>{at&&V&&!C&&Ye.pulsate()}),[C,V,at,Ye]);const ir=Fr(Ye,"start",_e,X),kt=Fr(Ye,"stop",me,X),fn=Fr(Ye,"stop",ve,X),Qt=Fr(Ye,"stop",Ne,X),zr=Fr(Ye,"stop",(St=>{at&&St.preventDefault(),je&&je(St)}),X),Mo=Fr(Ye,"start",Le,X),Tn=Fr(Ye,"stop",Te,X),Yn=Fr(Ye,"stop",ze,X),wr=Fr(Ye,"stop",(St=>{AC(St.target)||bt(!1),ue&&ue(St)}),!1),Ni=No((St=>{nn.current||(nn.current=St.currentTarget),!H&&AC(St.target)&&(bt(!0),fe&&fe(St)),ye&&ye(St)})),Ti={};gt&&(Ti.tabIndex=T?-1:ke,T&&(Ti["aria-disabled"]=T),Ti.type=dt);const _u=dv(a,nn),Ja={...u,centerRipple:O,component:N,disabled:T,disableRipple:C,disableTouchRipple:X,focusRipple:V,suppressFocusVisible:H,tabIndex:ke,focusVisible:at},Su=(St=>{const{disabled:Hr,focusVisible:yn,focusVisibleClassName:Vr,suppressFocusVisible:ao,classes:Ur}=St,Ri=rr({root:["root",Hr&&"disabled",yn&&!ao&&"focusVisible"]},YB,Ur);return yn&&!ao&&Vr&&(Ri.root+=` ${Vr}`),Ri})(Ja);return(0,Je.jsxs)(ZB,{as:le,className:Rt(Su.root,I),ownerState:Ja,onBlur:wr,onClick:Sn,onContextMenu:kt,onFocus:Ni,onKeyDown:rn,onKeyUp:_t,onMouseDown:ir,onMouseLeave:zr,onMouseUp:Qt,onDragLeave:fn,onTouchEnd:Tn,onTouchMove:Yn,onTouchStart:Mo,ref:_u,...gt?Ti:Wt,...lt,children:[A,En?(0,Je.jsx)(KB,{ref:it,center:O,...Ke}):null]})}));function QB(t){return Un("MuiCircularProgress",t)}Wn("MuiCircularProgress",["root","determinate","indeterminate","colorPrimary","colorSecondary","svg","track","circle","circleDisableShrink"]);const Ro=44,vv=wi`
|
|
100
100
|
0% {
|
|
101
101
|
transform: rotate(0deg);
|
|
102
102
|
}
|
|
@@ -104,7 +104,7 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
104
104
|
100% {
|
|
105
105
|
transform: rotate(360deg);
|
|
106
106
|
}
|
|
107
|
-
`,
|
|
107
|
+
`,yv=wi`
|
|
108
108
|
0% {
|
|
109
109
|
stroke-dasharray: 1px, 200px;
|
|
110
110
|
stroke-dashoffset: 0;
|
|
@@ -119,53 +119,53 @@ export default theme;`}function hC(t){return typeof t=="number"?`${(100*t).toFix
|
|
|
119
119
|
stroke-dasharray: 1px, 200px;
|
|
120
120
|
stroke-dashoffset: -126px;
|
|
121
121
|
}
|
|
122
|
-
`,
|
|
123
|
-
animation: ${
|
|
124
|
-
`:null
|
|
125
|
-
animation: ${
|
|
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
|
|
130
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function
|
|
122
|
+
`,JB=typeof vv!="string"?Va`
|
|
123
|
+
animation: ${vv} 1.4s linear infinite;
|
|
124
|
+
`:null,$B=typeof yv!="string"?Va`
|
|
125
|
+
animation: ${yv} 1.4s ease-in-out infinite;
|
|
126
|
+
`:null,e6=Bt("span",{name:"MuiCircularProgress",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[u.variant],a[`color${tn(u.color)}`]]}})(zn((({theme:t})=>({display:"inline-block",variants:[{props:{variant:"determinate"},style:{transition:t.transitions.create("transform")}},{props:{variant:"indeterminate"},style:JB||{animation:`${vv} 1.4s linear infinite`}},...Object.entries(t.palette).filter(bi()).map((([a])=>({props:{color:a},style:{color:(t.vars||t).palette[a].main}})))]})))),t6=Bt("svg",{name:"MuiCircularProgress",slot:"Svg"})({display:"block"}),n6=Bt("circle",{name:"MuiCircularProgress",slot:"Circle",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.circle,u.disableShrink&&a.circleDisableShrink]}})(zn((({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:$B||{animation:`${yv} 1.4s ease-in-out infinite`}}]})))),r6=Bt("circle",{name:"MuiCircularProgress",slot:"Track"})(zn((({theme:t})=>({stroke:"currentColor",opacity:(t.vars||t).palette.action.activatedOpacity})))),o6=s.forwardRef((function(t,a){const u=Hn({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:fe,variant:Oe,color:Me,disableShrink:_e}=ye;return rr({root:["root",Oe,`color${tn(Me)}`],svg:["svg"],track:["track"],circle:["circle",_e&&"circleDisableShrink"]},QB,fe)})(ie),de={},me={},ve={};if(q==="determinate"){const ye=2*Math.PI*((Ro-V)/2),fe=Q-G;de.strokeDasharray=ye.toFixed(3),de.strokeDashoffset=fe>0?`${((Q-$)/fe*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)(e6,{className:Rt(ue.root,v),style:{width:C,height:C,...me,...X},ownerState:ie,ref:a,role:"progressbar",...ve,...H,children:(0,Je.jsxs)(t6,{className:ue.svg,ownerState:ie,viewBox:"22 22 44 44",children:[I?(0,Je.jsx)(r6,{className:ue.track,ownerState:ie,cx:Ro,cy:Ro,r:(Ro-V)/2,fill:"none",strokeWidth:V,"aria-hidden":"true"}):null,(0,Je.jsx)(n6,{className:ue.circle,style:de,ownerState:ie,cx:Ro,cy:Ro,r:(Ro-V)/2,fill:"none",strokeWidth:V})]})})})),i6=o6;function a6(t){return Un("MuiIconButton",t)}const RC=Wn("MuiIconButton",["root","disabled","colorInherit","colorPrimary","colorSecondary","colorError","colorInfo","colorSuccess","colorWarning","edgeStart","edgeEnd","sizeSmall","sizeMedium","sizeLarge","loading","loadingIndicator","loadingWrapper"]),s6=Bt(gv,{name:"MuiIconButton",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.loading&&a.loading,u.color!=="default"&&a[`color${tn(u.color)}`],u.edge&&a[`edge${tn(u.edge)}`],a[`size${tn(u.size)}`]]}})(zn((({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}}]}))),zn((({theme:t})=>({variants:[{props:{color:"inherit"},style:{color:"inherit"}},...Object.entries(t.palette).filter(bi()).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)}}],[`&.${RC.disabled}`]:{backgroundColor:"transparent",color:(t.vars||t).palette.action.disabled},[`&.${RC.loading}`]:{color:"transparent"}})))),l6=Bt("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"}}]}))),u6=s.forwardRef((function(t,a){const u=Hn({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(CC!==void 0){const de=CC();return ue??de}return(function(de){const[me,ve]=s.useState(de),ye=de||me;return s.useEffect((()=>{me==null&&(kC+=1,ve(`mui-${kC}`))}),[me]),ye})(ue)})(X),G=$??(0,Je.jsx)(i6,{"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:de,disabled:me,color:ve,edge:ye,size:fe,loading:Oe}=ue;return rr({root:["root",Oe&&"loading",me&&"disabled",ve!=="default"&&`color${tn(ve)}`,ye&&`edge${tn(ye)}`,`size${tn(fe)}`],loadingIndicator:["loadingIndicator"],loadingWrapper:["loadingWrapper"]},a6,de)})(Q);return(0,Je.jsxs)(s6,{id:V?H:X,className:Rt(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)(l6,{className:ie.loadingIndicator,ownerState:Q,children:V&&G})}),O]})})),PC=u6;function c6(t){return Un("MuiSvgIcon",t)}Wn("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const f6=Bt("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.color!=="inherit"&&a[`color${tn(u.color)}`],a[`fontSize${tn(u.fontSize)}`]]}})(zn((({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}}]})))),IC=s.forwardRef((function(t,a){const u=Hn({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:de,classes:me}=ie;return rr({root:["root",ue!=="inherit"&&`color${tn(ue)}`,`fontSize${tn(de)}`]},c6,me)})(H);return(0,Je.jsxs)(f6,{as:I,className:Rt(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]})}));IC.muiName="SvgIcon";const MC=IC;function oo(t,a){function u(v,O){return(0,Je.jsx)(MC,{"data-testid":void 0,ref:O,...v,children:t})}return u.muiName=MC.muiName,s.memo(s.forwardRef(u))}const d6=oo((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"})),h6=oo((0,Je.jsx)("path",{d:"M12 5.99L19.53 19H4.47L12 5.99M12 2L1 21h22L12 2zm1 14h-2v2h2v-2zm0-6h-2v4h2v-4z"})),p6=oo((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"})),m6=oo((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"})),g6=oo((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"})),v6=Bt(MB,{name:"MuiAlert",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[u.variant]]}})(zn((({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(bi(["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),[`& .${OC.icon}`]:t.vars?{color:t.vars.palette.Alert[`${v}IconColor`]}:{color:t.palette[v].main}}}))),...Object.entries(t.palette).filter(bi(["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}`,[`& .${OC.icon}`]:t.vars?{color:t.vars.palette.Alert[`${v}IconColor`]}:{color:t.palette[v].main}}}))),...Object.entries(t.palette).filter(bi(["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)}}})))]}}))),y6=Bt("div",{name:"MuiAlert",slot:"Icon"})({marginRight:12,padding:"7px 0",display:"flex",fontSize:22,opacity:.9}),b6=Bt("div",{name:"MuiAlert",slot:"Message"})({padding:"8px 0",minWidth:0,overflow:"auto"}),w6=Bt("div",{name:"MuiAlert",slot:"Action"})({display:"flex",alignItems:"flex-start",padding:"4px 0 0 16px",marginLeft:"auto",marginRight:-8}),jC={success:(0,Je.jsx)(d6,{fontSize:"inherit"}),warning:(0,Je.jsx)(h6,{fontSize:"inherit"}),error:(0,Je.jsx)(p6,{fontSize:"inherit"}),info:(0,Je.jsx)(m6,{fontSize:"inherit"})},x6=s.forwardRef((function(t,a){const u=Hn({props:t,name:"MuiAlert"}),{action:v,children:O,className:A,closeText:I="Close",color:N,icon:T,iconMapping:C=jC,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 rr({root:["root",`color${tn($e||dt)}`,`${Ke}`],icon:["icon"],message:["message"],action:["action"]},jB,lt)})(ie),de={slots:H,slotProps:q},[me,ve]=Vn("root",{ref:a,shouldForwardComponentProp:!0,className:Rt(ue.root,A),elementType:v6,externalForwardedProps:{...de,...Q},ownerState:ie,additionalProps:{role:V,elevation:0}}),[ye,fe]=Vn("icon",{className:ue.icon,elementType:y6,externalForwardedProps:de,ownerState:ie}),[Oe,Me]=Vn("message",{className:ue.message,elementType:b6,externalForwardedProps:de,ownerState:ie}),[_e,je]=Vn("action",{className:ue.action,elementType:w6,externalForwardedProps:de,ownerState:ie}),[Ne,Te]=Vn("closeButton",{elementType:PC,externalForwardedProps:de,ownerState:ie}),[ze,Le]=Vn("closeIcon",{elementType:g6,externalForwardedProps:de,ownerState:ie});return(0,Je.jsxs)(me,{...ve,children:[T!==!1?(0,Je.jsx)(ye,{...fe,children:T||C[$]||jC[$]}):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 _6(t){return Un("MuiTypography",t)}Wn("MuiTypography",["root","h1","h2","h3","h4","h5","h6","subtitle1","subtitle2","body1","body2","inherit","button","caption","overline","alignLeft","alignRight","alignCenter","alignJustify","noWrap","gutterBottom"]);const S6=Bt("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${tn(u.align)}`],u.noWrap&&a.noWrap,u.gutterBottom&&a.gutterBottom]}})(zn((({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(bi()).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${tn(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"}}]})))),LC={h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",subtitle1:"h6",subtitle2:"h6",body1:"p",body2:"p",inherit:"p"},DC=s.forwardRef((function(t,a){const u=Hn({props:t,name:"MuiTypography"}),{color:v,align:O="inherit",className:A,component:I,gutterBottom:N=!1,noWrap:T=!1,variant:C="body1",variantMapping:X=LC,...V}=u,$={...u,align:O,color:v,className:A,component:I,gutterBottom:N,noWrap:T,variant:C,variantMapping:X},q=I||X[C]||LC[C]||"span",H=(G=>{const{align:Q,gutterBottom:ie,noWrap:ue,variant:de,classes:me}=G;return rr({root:["root",de,G.align!=="inherit"&&`align${tn(Q)}`,ie&&"gutterBottom",ue&&"noWrap"]},_6,me)})($);return(0,Je.jsx)(S6,{as:q,ref:a,className:Rt(H.root,A),...V,ownerState:$,style:{...O!=="inherit"&&{"--Typography-textAlign":O},...V.style}})}));function Ua(t){return Ua=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},Ua(t)}function BC(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 Ht(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?BC(Object(u),!0).forEach((function(v){E6(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):BC(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function E6(t,a,u){return a=(function(v){var O=(function(A,I){if(Ua(A)!=="object"||A===null)return A;var N=A[Symbol.toPrimitive];if(N!==void 0){var T=N.call(A,"string");if(Ua(T)!=="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(A)})(v);return Ua(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 FC(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 xi=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(de){ue=!0,q=de}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 FC(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)?FC(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=Ht(Ht({},T),{},{mx:"auto"});break;case"mt-5":T=Ht(Ht({},T),{},{mt:"3 rem"});break;case"mt-4":T=Ht(Ht({},T),{},{mt:"2.25 rem"});break;case"mt-2":T=Ht(Ht({},T),{},{mt:"1 rem"});break;case"m-0":T=Ht(Ht({},T),{},{m:"0"});break;case"mx-3":T=Ht(Ht({},T),{},{mx:"1.75 rem"});break;case"my-2":T=Ht(Ht({},T),{},{my:"1 rem"});break;case"my-3":T=Ht(Ht({},T),{},{my:"1.75 rem"});break;case"mb-3":T=Ht(Ht({},T),{},{mb:"1.75 rem"});break;case"mb-2":T=Ht(Ht({},T),{},{mb:"1 rem"});break;case"w-75":T=Ht(Ht({},T),{},{width:"75%"})}})),T}}),[t.classes]);return u?null:b().createElement(x6,{id:t.id,onClose:t.dismissible?O:void 0,severity:A,sx:I},t.title&&b().createElement(DC,{variant:"h6"},t.title),b().createElement(DC,{variant:"body2"},t.message))};var qC=function(t,a,u){return u?"".concat(u,": (").concat(t,") ").concat(a):"(".concat(t,") ").concat(a)},zC=function(t,a){return t.status?qC(t.status,t.message,a):t.Status?qC(t.Status,t.Message,a):a?"".concat(a,": ").concat(t):t};function bv(t){return bv=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},bv(t)}var O6=function(t){var a=t.error;return a?a.constructor===Array?a.map((function(u){return b().createElement(xi,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:zC(u)})})):["object","string"].includes(bv(a))?b().createElement(xi,{id:"error-stripe",classes:"mx-3 my-2",color:"danger",dismissible:!1,message:zC(a)}):void 0:null},HC=function(t){return b().createElement(K4,{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(Z4,{toggle:t.onClose},t.headerContent),b().createElement(O6,{error:t.error}),t.warning&&(Array.isArray(t.warning)?t.warning.map((function(a){return b().createElement(xi,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:a})})):b().createElement(xi,{id:"warning-stripe",classes:"mx-3 my-2",color:"warning",dismissible:!1,message:t.warning})),(t.content||t.disableSubmitMessage)&&b().createElement($4,{className:t.bodyClassName},t.content,t.disableSubmit&&t.disableSubmitMessage&&b().createElement(xi,{id:"cm-disable-submit-message",message:t.disableSubmitMessage,color:"danger",dismissible:!1})),b().createElement(nD,null,t.customFooter?t.customFooter:b().createElement(b().Fragment,null,!t.noCancel&&b().createElement(ei,{key:"cancel-button",onClick:t.onClose},t.cancelButtonText),!t.noSubmit&&b().createElement(ei,{key:"submit-button",color:t.submitButtonColor,pending:t.pending,onClick:t.onSubmit,disabled:t.disableSubmit},t.submitButtonText))))};HC.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 k6=HC,C6=Wn("MuiBox",["root"]),A6=mC(),N6=(function(t={}){const{themeId:a,defaultTheme:u,defaultClassName:v="MuiBox-root",generateClassName:O}=t,A=Ik("div",{shouldForwardProp:I=>I!=="theme"&&I!=="sx"&&I!=="as"})(hi);return s.forwardRef((function(I,N){const T=fv(u),{className:C,component:X="div",...V}=I;return(0,Je.jsx)(A,{as:X,ref:N,className:Rt(C,O?O(v):v),theme:a&&T[a]||T,...V})}))})({themeId:cv,defaultTheme:A6,defaultClassName:C6.root,generateClassName:EC.generate}),Zl=N6,T6=$k(),R6=Dl(),P6=T6("div",{name:"MuiContainer",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[`maxWidth${Al(String(u.maxWidth))}`],u.fixed&&a.fixed,u.disableGutters&&a.disableGutters]}}),I6=t=>(function({props:a,name:u,defaultTheme:v,themeId:O}){let A=fv(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?Ul(N.components[T].defaultProps,C):C})({theme:A,name:u,props:a})})({props:t,name:"MuiContainer",defaultTheme:R6}),M6=(function(t={}){const{createStyledComponent:a=P6,useThemeProps:u=I6,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,de)=>{const{classes:me,fixed:ve,disableGutters:ye,maxWidth:fe}=ue;return rr({root:["root",fe&&`maxWidth${Al(String(fe))}`,ve&&"fixed",ye&&"disableGutters"]},(Oe=>Un(de,Oe)),me)})(Q,v);return(0,Je.jsx)(O,{as:X,ownerState:Q,className:Rt(ie.root,C),ref:N,...G})}))})({createStyledComponent:Bt("div",{name:"MuiContainer",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,a[`maxWidth${tn(String(u.maxWidth))}`],u.fixed&&a.fixed,u.disableGutters&&a.disableGutters]}}),useThemeProps:t=>Hn({props:t,name:"MuiContainer"})}),j6=M6,L6=s.createContext(),VC=()=>s.useContext(L6)??!1,Ql=function(t){const{elementType:a,externalSlotProps:u,ownerState:v,skipResolvingSlotProps:O=!1,...A}=t,I=O?{}:bC(u,v),{props:N,internalRef:T}=xC({...A,externalSlotProps:I}),C=Wl(T,I?.ref,t.additionalProps?.ref);return yC(a,{...N,ref:C},v)},UC=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 D6(t){return(1+Math.sin(Math.PI*t-Math.PI/2))/2}const B6=Gl;function Jl(t){return t&&t.ownerDocument||document}const WC=function(t){return Jl(t).defaultView||window},F6={width:99,height:99,position:"absolute",top:-9999,overflow:"scroll",pointerEvents:"none"},q6=oo((0,Je.jsx)("path",{d:"M15.41 16.09l-4.58-4.59 4.58-4.59L14 5.5l-6 6 6 6z"})),z6=oo((0,Je.jsx)("path",{d:"M8.59 16.34l4.58-4.59-4.58-4.59L10 5.75l6 6-6 6z"}));function H6(t){return Un("MuiTabScrollButton",t)}const V6=Wn("MuiTabScrollButton",["root","vertical","horizontal","disabled"]),U6=Bt(gv,{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,[`&.${V6.disabled}`]:{opacity:0},variants:[{props:{orientation:"vertical"},style:{width:"100%",height:40,"& svg":{transform:"var(--TabScrollButton-svgRotate)"}}}]}),W6=s.forwardRef((function(t,a){const u=Hn({props:t,name:"MuiTabScrollButton"}),{className:v,slots:O={},slotProps:A={},direction:I,orientation:N,disabled:T,...C}=u,{nativeButton:X,...V}=C,$=VC(),q={isRtl:$,...u},H=(de=>{const{classes:me,orientation:ve,disabled:ye}=de;return rr({root:["root",ve,ye&&"disabled"]},H6,me)})(q),G=O.StartScrollButtonIcon??q6,Q=O.EndScrollButtonIcon??z6,ie=Ql({elementType:G,externalSlotProps:A.startScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:q}),ue=Ql({elementType:Q,externalSlotProps:A.endScrollButtonIcon,additionalProps:{fontSize:"small"},ownerState:q});return(0,Je.jsx)(U6,{component:"div",className:Rt(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 G6(t){return Un("MuiTabs",t)}const wv=Wn("MuiTabs",["root","vertical","list","centered","scroller","fixed","scrollableX","scrollableY","hideScrollbar","scrollButtons","scrollButtonsHideMobile","indicator"]);function xv(t){let a=t.activeElement;for(;a?.shadowRoot?.activeElement!=null;)a=a.shadowRoot.activeElement;return a}const K6=xv,Y6=Jl,X6=Object.is,GC=s.createContext(void 0);function KC(){const t=s.useContext(GC);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 Z6=["ArrowRight","ArrowLeft","ArrowUp","ArrowDown","Home","End"];function YC(t,a,u,v){return t!=null?(function(O,A,I){const N=$C(A,O);return N===-1?QC(A,I):I(A[N])?A[N].id:ZC(A,N,"next",!1,I)?.id??null})(t,a,u):(function(O,A,I){const N=I?.(O);if(N!=null){const T=JC(O,N);if(T&&A(T))return T.id}return QC(O,A)})(a,u,v)}function XC(t,a,u){if(a){const v=eA(t,a);if(v!==-1)return v}return $C(t,u)}function ZC(t,a,u,v,O){const A=t.length-1;if(A===-1)return null;let I=!1,N=tA(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=tA(N,A,u,v)}return null}function QC(t,a){return t.find((u=>a(u)))?.id??null}function JC(t,a){return a==null?null:t.find((u=>u.id===a))??null}function $C(t,a){return a==null?-1:t.findIndex((u=>u.id===a))}function eA(t,a){return a?t.findIndex((u=>u.element===a||u.element?.contains(a))):-1}function _v(t){const a=Array.from(t.values());return a.every((v=>v.element==null))?a:[...a.filter(Sv).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=>!Sv(v)))]}function $l(t){return _v(t).filter(Sv)}function tA(t,a,u,v=!0){return u==="next"?t===a?v?0:-1:t+1:t===0?v?a:-1:t-1}function Q6(t){return!!t.element&&(!!t.focusableWhenDisabled||!t.disabled&&!t.element.hasAttribute("disabled")&&t.element.getAttribute("aria-disabled")!=="true"&&t.element.hasAttribute("tabindex"))}function Sv(t){return t.element!=null&&t.element.isConnected}function J6(...t){return a=>{t.forEach((u=>{(function(v,O){typeof v=="function"?v(O):v&&(v.current=O)})(u??null,a)}))}}const $6=Bt("div",{name:"MuiTabs",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[{[`& .${wv.scrollButtons}`]:a.scrollButtons},{[`& .${wv.scrollButtons}`]:u.scrollButtonsHideMobile&&a.scrollButtonsHideMobile},a.root,u.vertical&&a.vertical]}})(zn((({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:{[`& .${wv.scrollButtons}`]:{[t.breakpoints.down("sm")]:{display:"none"}}}}]})))),eF=Bt("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"}}]}),tF=Bt("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"}}]}),nF=Bt("span",{name:"MuiTabs",slot:"Indicator"})(zn((({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}}]})))),rF=Bt((function(t){const{onChange:a,...u}=t,v=s.useRef(),O=s.useRef(null),A=()=>{v.current=O.current.offsetHeight-O.current.clientHeight};return B6((()=>{const I=UC((()=>{const T=v.current;A(),T!==v.current&&a(v.current)})),N=WC(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:F6,...u,ref:O})}))({overflowX:"auto",overflowY:"hidden",scrollbarWidth:"none","&::-webkit-scrollbar":{display:"none"}}),nA={},oF=s.forwardRef((function(t,a){const u=Hn({props:t,name:"MuiTabs"}),v=_C(),O=VC(),{"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:de={},textColor:me="primary",value:ve,variant:ye="standard",visibleScrollbar:fe=!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:fe,fixed:!Me,hideScrollbar:Me&&!fe,scrollableX:Me&&!_e,scrollableY:Me&&_e,centered:T&&!Me,scrollButtonsHideMobile:!$},Ke=(Ge=>{const{vertical:He,fixed:rt,hideScrollbar:st,scrollableX:Ze,scrollableY:Ct,centered:on,scrollButtonsHideMobile:pn,classes:ar}=Ge;return rr({root:["root",He&&"vertical"],scroller:["scroller",rt&&"fixed",st&&"hideScrollbar",Ze&&"scrollableX",Ct&&"scrollableY"],list:["list",He&&"vertical",on&&"centered"],indicator:["indicator"],scrollButtons:["scrollButtons",pn&&"scrollButtonsHideMobile"],scrollableX:[Ze&&"scrollableX"],hideScrollbar:[st&&"hideScrollbar"]},G6,ar)})(ke),$e=Ql({elementType:ue.startScrollButtonIcon,externalSlotProps:de.startScrollButtonIcon,ownerState:ke}),dt=Ql({elementType:ue.endScrollButtonIcon,externalSlotProps:de.endScrollButtonIcon,ownerState:ke}),[lt,gt]=s.useState(!1),[Xe,le]=s.useState(nA),[qe,Ie]=s.useState(!1),[Ye,it]=s.useState(!1),[at,bt]=s.useState(!1),Ot=ve===!1?null:ve,[Xt,Zt]=s.useState(!1),[nn,Sn]=s.useState({overflow:"hidden",scrollbarWidth:0}),rn=new Map,_t=s.useRef(null),Wt=s.useRef(null),En={slots:ue,slotProps:de},ir=()=>{const Ge=_t.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=Wt.current.children;if(st.length>0){const Ze=st[rn.get(ve)];rt=Ze?Ze.getBoundingClientRect():null}}return{tabsMeta:He,tabMeta:rt}},kt=No((()=>{const{tabsMeta:Ge,tabMeta:He}=ir();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 Ct=Math.abs(Xe[rt]-Ze[rt]),on=Math.abs(Xe[Le]-Ze[Le]);(Ct>=1||on>=1)&&le(Ze)}})),fn=(Ge,{animation:He=!0}={})=>{He?(function(rt,st,Ze,Ct={},on=(()=>{})){const{ease:pn=D6,duration:ar=300}=Ct;let Mi=null;const ji=st[rt],so=Rn=>{Mi===null&&(Mi=Rn);const Au=Math.min(1,(Rn-Mi)/ar);st[rt]=pn(Au)*(Ze-ji)+ji,Au>=1?requestAnimationFrame((()=>{on(null)})):requestAnimationFrame(so)};ji===Ze?on(new Error("Element already at target position")):requestAnimationFrame(so)})(je,_t.current,Ge,{duration:v.transitions.duration.standard}):_t.current[je]=Ge},Qt=Ge=>{let He=_t.current[je];He+=_e?Ge:Ge*(O?-1:1),fn(He)},zr=()=>{const Ge=_t.current[ze];let He=0;const rt=Array.from(Wt.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},Mo=()=>{Qt(-1*zr())},Tn=()=>{Qt(zr())},[Yn,{onChange:wr,...Ni}]=Vn("scrollbar",{className:Rt(Ke.scrollableX,Ke.hideScrollbar),elementType:rF,shouldForwardComponentProp:!0,externalForwardedProps:En,ownerState:ke}),Ti=s.useCallback((Ge=>{wr?.(Ge),Sn({overflow:null,scrollbarWidth:Ge})}),[wr]),[_u,Ja]=Vn("scrollButtons",{className:Ke.scrollButtons,elementType:W6,externalForwardedProps:En,ownerState:ke,additionalProps:{orientation:G,slots:{StartScrollButtonIcon:ue.startScrollButtonIcon,EndScrollButtonIcon:ue.endScrollButtonIcon},slotProps:{startScrollButtonIcon:$e,endScrollButtonIcon:dt}}}),Su=No((Ge=>{const{tabsMeta:He,tabMeta:rt}=ir();if(rt&&He){if(rt[Ne]<He[Ne]){const st=He[je]+(rt[Ne]-He[Ne]);fn(st,{animation:Ge})}else if(rt[Te]>He[Te]){const st=He[je]+(rt[Te]-He[Te]);fn(st,{animation:Ge})}}})),St=No((()=>{Me&&Q!==!1&&bt(!at)}));s.useEffect((()=>{const Ge=UC((()=>{_t.current&&kt()}));let He;const rt=WC(_t.current);let st;return rt.addEventListener("resize",Ge),typeof ResizeObserver<"u"&&(He=new ResizeObserver(Ge),Array.from(Wt.current.children).forEach((Ze=>{He.observe(Ze)}))),typeof MutationObserver<"u"&&(st=new MutationObserver((Ze=>{Ze.forEach((Ct=>{Ct.removedNodes.forEach((on=>{He?.unobserve(on)})),Ct.addedNodes.forEach((on=>{He?.observe(on)}))})),Ge(),St()})),st.observe(Wt.current,{childList:!0})),()=>{Ge.clear(),rt.removeEventListener("resize",Ge),st?.disconnect(),He?.disconnect()}}),[kt,St]),s.useEffect((()=>{const Ge=Array.from(Wt.current.children),He=Ge.length;if(typeof IntersectionObserver<"u"&&He>0&&Me&&Q!==!1){const rt=Ge[0],st=Ge[He-1],Ze={root:_t.current,threshold:.99},Ct=new IntersectionObserver((pn=>{Ie(!pn[0].isIntersecting)}),Ze);Ct.observe(rt);const on=new IntersectionObserver((pn=>{it(!pn[0].isIntersecting)}),Ze);return on.observe(st),()=>{Ct.disconnect(),on.disconnect()}}}),[Me,Q,at,C?.length]),s.useEffect((()=>{gt(!0)}),[]),s.useEffect((()=>{kt()})),s.useEffect((()=>{Su(nA!==Xe)}),[Su,Xe]),s.useImperativeHandle(N,(()=>({updateIndicator:kt,updateScrollButtons:St})),[kt,St]);const[Hr,yn]=Vn("indicator",{className:Ke.indicator,elementType:nF,externalForwardedProps:En,ownerState:ke,additionalProps:{style:Xe}}),Vr=(0,Je.jsx)(Hr,{...yn}),ao=(function(Ge){const{activeItemId:He,getDefaultActiveItemId:rt,orientation:st,isRtl:Ze=!1,isItemFocusable:Ct=Q6,wrap:on=!0}=Ge,[pn,ar]=s.useState(He),Mi=s.useRef(He);let ji=pn;He!==Mi.current&&(Mi.current=He,He!==void 0&&He!==pn&&(ji=He,ar(He)));const so=s.useRef(null),Rn=s.useRef(new Map),[Au,BN]=s.useState(0),Nu=YC(ji,s.useMemo((()=>_v(Rn.current)),[Au]),Ct,rt),es=s.useRef(Nu);es.current=Nu;const FN=s.useCallback((()=>{const an=_v(Rn.current);return JC(an,YC(es.current,an,Ct,rt))}),[rt,Ct]),qN=s.useCallback((()=>Rn.current),[]),zN=Kl((an=>{(function(At,mn){if(At===mn)return!0;if(!(At instanceof Object&&mn instanceof Object))return!1;let Xn=0,sr=0;for(const jo in At)if(Xn+=1,!X6(At[jo],mn[jo])||!(jo in mn))return!1;for(const jo in mn)sr+=1;return Xn===sr})(Rn.current.get(an.id)??null,an)||(Rn.current.set(an.id,an),BN((At=>At+1)))})),HN=Kl((an=>{Rn.current.delete(an)&&BN((At=>At+1))})),VN=Kl((an=>{ar(an)})),UN=s.useCallback((an=>es.current===an),[]),Tu=s.useCallback(((an,At,mn,Xn)=>{const sr=ZC($l(Rn.current),an,At,mn,Xn??Ct);return sr?(sr.element?.focus(),ar(sr.id),sr):null}),[Ct]),WN=s.useCallback((an=>({onFocus:At=>{const mn=$l(Rn.current),Xn=eA(mn,At.target);Xn!==-1&&ar(mn[Xn].id)},onKeyDown:At=>{if(At.altKey||At.shiftKey||At.ctrlKey||At.metaKey||!Z6.includes(At.key))return;let mn=st==="horizontal"?"ArrowLeft":"ArrowUp",Xn=st==="horizontal"?"ArrowRight":"ArrowDown";st==="horizontal"&&Ze&&(mn="ArrowRight",Xn="ArrowLeft");const sr=$l(Rn.current),jo=xv(Jl(so.current)),KN=jo===so.current;let ts=XC(sr,jo,es.current),ay="next";switch(At.key){case mn:ay="previous",At.preventDefault(),KN&&(ts=sr.length);break;case Xn:At.preventDefault(),KN&&(ts=-1);break;case"Home":At.preventDefault(),ts=-1;break;case"End":At.preventDefault(),ay="previous",ts=sr.length;break;default:return}Tu(ts,ay,on)},ref:J6(an,(At=>{so.current=At}))})),[Tu,Ze,st,on]),GN=s.useCallback((an=>{const At=$l(Rn.current),mn=xv(Jl(so.current)),Xn=mn===so.current?-1:XC(At,mn,es.current);return Tu(Xn,"next",!0,an)?.id??null}),[Tu]);return s.useMemo((()=>({activeItemId:Nu,focusNext:GN,getActiveItem:FN,getContainerProps:WN,getItemMap:qN,isItemActive:UN,registerItem:zN,setActiveItemId:VN,unregisterItem:HN})),[Nu,GN,FN,WN,qN,UN,zN,VN,HN])})({activeItemId:Xt?void 0:Ot,orientation:G,isRtl:O}),Ur=ao.getContainerProps(),Ri=s.Children.toArray(C).filter(s.isValidElement).map(((Ge,He)=>{const rt=Ge.props.value===void 0?He:Ge.props.value;return rn.set(rt,He),{child:Ge,index:He,childValue:rt}})),Eu=Ri.map((({child:Ge,childValue:He})=>{const rt=He===ve;return s.cloneElement(Ge,{fullWidth:ye==="fullWidth",indicator:rt&&!lt&&Vr,selected:rt,selectionFollowsFocus:ie,onChange:H,textColor:me,value:He})})),Pi=(()=>{const Ge={};Ge.scrollbarSizeListener=Me?(0,Je.jsx)(Yn,{...Ni,onChange:Ti}):null;const He=Me&&(Q==="auto"&&(qe||Ye)||Q===!0);return Ge.scrollButtonStart=He?(0,Je.jsx)(_u,{direction:O?"right":"left",onClick:Mo,disabled:!qe,...Ja}):null,Ge.scrollButtonEnd=He?(0,Je.jsx)(_u,{direction:O?"left":"right",onClick:Tn,disabled:!Ye,...Ja}):null,Ge})(),[Ou,ku]=Vn("root",{ref:a,className:Rt(Ke.root,X),elementType:$6,externalForwardedProps:{...En,...Oe,component:V},ownerState:ke}),[xr,Ii]=Vn("scroller",{ref:_t,className:Ke.scroller,elementType:eF,externalForwardedProps:En,ownerState:ke,additionalProps:{style:{overflow:nn.overflow,[_e?"margin"+(O?"Left":"Right"):"marginBottom"]:fe?void 0:-nn.scrollbarWidth}}}),$a=dv(Ur.ref,Wt),[Cu,dn]=Vn("list",{ref:$a,className:Ke.list,elementType:tF,externalForwardedProps:En,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 Ct=st;for(;Ct;){if(rt===Ct)return!0;Ct=Ct.parentNode??Ct.host??null}}return!1})(He.currentTarget,He.relatedTarget)||Zt(!1),Ge.onBlur?.(He)},onKeyDown:He=>{(rt=>{const st=Wt.current;K6(Y6(st))?.getAttribute("role")==="tab"&&Ur.onKeyDown(rt)})(He),Ge.onKeyDown?.(He)},onFocus:He=>{Zt(!0),Ur.onFocus(He),Ge.onFocus?.(He)}})});return(0,Je.jsxs)(Ou,{...ku,children:[Pi.scrollButtonStart,Pi.scrollbarSizeListener,(0,Je.jsxs)(xr,{...Ii,children:[(0,Je.jsx)(Cu,{"aria-label":A,"aria-labelledby":I,"aria-orientation":G==="vertical"?"vertical":null,role:"tablist",...dn,children:(0,Je.jsx)(GC.Provider,{value:ao,children:Eu})}),lt&&Vr]}),Pi.scrollButtonEnd]})})),iF=oF;function aF(t){return Un("MuiTab",t)}const or=Wn("MuiTab",["root","labelIcon","textColorInherit","textColorPrimary","textColorSecondary","selected","disabled","fullWidth","wrapped","icon"]),sF=Bt(gv,{name:"MuiTab",slot:"Root",overridesResolver:(t,a)=>{const{ownerState:u}=t;return[a.root,u.label&&u.icon&&a.labelIcon,a[`textColor${tn(u.textColor)}`],u.fullWidth&&a.fullWidth,u.wrapped&&a.wrapped,{[`& .${or.icon}`]:a.icon}]}})(zn((({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:{[`& > .${or.icon}`]:{marginBottom:6}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="bottom",style:{[`& > .${or.icon}`]:{marginTop:6}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="start",style:{[`& > .${or.icon}`]:{marginRight:t.spacing(1)}}},{props:({ownerState:a,iconPosition:u})=>a.icon&&a.label&&u==="end",style:{[`& > .${or.icon}`]:{marginLeft:t.spacing(1)}}},{props:{textColor:"inherit"},style:{color:"inherit",opacity:.6,[`&.${or.selected}`]:{opacity:1},[`&.${or.disabled}`]:{opacity:(t.vars||t).palette.action.disabledOpacity}}},{props:{textColor:"primary"},style:{color:(t.vars||t).palette.text.secondary,[`&.${or.selected}`]:{color:(t.vars||t).palette.primary.main},[`&.${or.disabled}`]:{color:(t.vars||t).palette.text.disabled}}},{props:{textColor:"secondary"},style:{color:(t.vars||t).palette.text.secondary,[`&.${or.selected}`]:{color:(t.vars||t).palette.secondary.main},[`&.${or.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)}}]})))),lF=s.forwardRef((function(t,a){const u=Hn({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,...de}=u,me=KC(),ve=(function(_e){const je=KC(),{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=Wl(_e.ref,$e);return Gl((()=>{Le.current&&Te({...ke,element:Le.current})}),[ke,Te]),Gl((()=>{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,fe={...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 rr({root:["root",Le&&ke&&"labelIcon",`textColor${tn(Ne)}`,Te&&"fullWidth",ze&&"wrapped",Ke&&"selected",$e&&"disabled"],icon:["icon"]},aF,je)})(fe),Me=N&&X&&s.isValidElement(N)?s.cloneElement(N,{className:Rt(Oe.icon,N.props.className)}):N;return(0,Je.jsxs)(sF,{internalNativeButton:!0,focusRipple:!A,className:Rt(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:fe,...de,children:[T==="top"||T==="start"?(0,Je.jsxs)(s.Fragment,{children:[Me,X]}):(0,Je.jsxs)(s.Fragment,{children:[X,Me]}),C]})})),uF=oo((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 rA(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 cF=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,de,me,ve,ye=[],fe=!0,Oe=!1;try{if(me=(ie=ie.call(G)).next,Q!==0)for(;!(fe=(ue=me.call(ie)).done)&&(ye.push(ue.value),ye.length!==Q);fe=!0);}catch(Me){Oe=!0,de=Me}finally{try{if(!fe&&ie.return!=null&&(ve=ie.return(),Object(ve)!==ve))return}finally{if(Oe)throw de}}return ye}})(q,H)||(function(G,Q){if(G){if(typeof G=="string")return rA(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)?rA(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(Zl,null,b().createElement(j6,{maxWidth:"md"},b().createElement(iF,{value:X,onChange:function(q,H){V(H),O(H)}},$.map((function(q){return b().createElement(lF,{key:q.key,value:q.key,label:b().createElement(Zl,{sx:{display:"flex",alignItems:"center",gap:.5}},q.label,I&&b().createElement(PC,{size:"small",onClick:function(H){H.stopPropagation(),T(q.key)},sx:{ml:.5,p:.25}},b().createElement(uF,{fontSize:"inherit"})))})})))),b().createElement(Zl,{sx:{borderTop:1,borderColor:"divider"}},$.map((function(q){return X===q.key?b().createElement(Zl,{key:q.key,role:"tabpanel"},q.content):null}))))};var eu=d(525),_i={};_i.styleTagTransform=wa(),_i.setAttributes=ya(),_i.insert=va().bind(null,"head"),_i.domAPI=ga(),_i.insertStyleElement=ba(),ma()(eu.Z,_i),eu.Z&&eu.Z.locals&&eu.Z.locals;var oA=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)}))))};oA.defaultProps={labelWidth:100};const fF=oA,tu=Array.isArray||function(t){return t!=null&&t.length>=0&&Object.prototype.toString.call(t)==="[object Array]"};function iA(t,a,u){return function(){if(arguments.length===0)return u();var v=arguments[arguments.length-1];if(!tu(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 aA=function(){return this.xf["@@transducer/init"]()};function jt(t){return t!=null&&typeof t=="object"&&t["@@functional/placeholder"]===!0}function vn(t){return function a(u){return arguments.length===0||jt(u)?a:t.apply(this,arguments)}}function Kn(t){return function a(u,v){switch(arguments.length){case 0:return a;case 1:return jt(u)?a:vn((function(O){return t(u,O)}));default:return jt(u)&&jt(v)?a:jt(u)?vn((function(O){return t(O,v)})):jt(v)?vn((function(O){return t(u,O)})):t(u,v)}}}function sA(t){for(var a,u=[];!(a=t.next()).done;)u.push(a.value);return u}function lA(t,a,u){for(var v=0,O=u.length;v<O;){if(t(a,u[v]))return!0;v+=1}return!1}function Si(t,a){return Object.prototype.hasOwnProperty.call(a,t)}const Ev=typeof Object.is=="function"?Object.is:function(t,a){return t===a?t!==0||1/t==1/a:t!=t&&a!=a};var uA=Object.prototype.toString;const cA=(function(){return uA.call(arguments)==="[object Arguments]"?function(t){return uA.call(t)==="[object Arguments]"}:function(t){return Si("callee",t)}})();var dF=!{toString:null}.propertyIsEnumerable("toString"),fA=["constructor","valueOf","isPrototypeOf","toString","propertyIsEnumerable","hasOwnProperty","toLocaleString"],dA=(function(){return arguments.propertyIsEnumerable("length")})(),hF=function(t,a){for(var u=0;u<t.length;){if(t[u]===a)return!0;u+=1}return!1};const hA=vn(typeof Object.keys!="function"||dA?(function(t){if(Object(t)!==t)return[];var a,u,v=[],O=dA&&cA(t);for(a in t)!Si(a,t)||O&&a==="length"||(v[v.length]=a);if(dF)for(u=fA.length-1;u>=0;)Si(a=fA[u],t)&&!hF(v,a)&&(v[v.length]=a),u-=1;return v}):(function(t){return Object(t)!==t?[]:Object.keys(t)})),Ov=vn((function(t){return t===null?"Null":t===void 0?"Undefined":Object.prototype.toString.call(t).slice(8,-1)}));function pA(t,a,u,v){var O=sA(t);function A(I,N){return kv(I,N,u.slice(),v.slice())}return!lA((function(I,N){return!lA(A,N,I)}),sA(a),O)}function kv(t,a,u,v){if(Ev(t,a))return!0;var O,A,I=Ov(t);if(I!==Ov(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||!Ev(t.valueOf(),a.valueOf()))return!1;break;case"Date":if(!Ev(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&&pA(t.entries(),a.entries(),u.concat([t]),v.concat([a]));case"Set":return t.size===a.size&&pA(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=hA(t);if(T.length!==hA(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(!Si(V,a)||!kv(a[V],t[V],C,X))return!1;N-=1}return!0}const mA=Kn((function(t,a){return kv(t,a,[],[])}));function gA(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 vA(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&&(!jt(a[I])||O>=arguments.length)?N=a[I]:(N=arguments[O],O+=1),v[I]=N,jt(N)||(A-=1),I+=1}return A<=0?u.apply(this,v):gA(A,vA(t,v,u))}}const pF=Number.isInteger||function(t){return t<<0===t};function Cv(t){return Object.prototype.toString.call(t)==="[object String]"}const mF=Kn((function(t,a){var u=t<0?a.length+t:t;return Cv(a)?a.charAt(u):a[u]})),gF=Kn((function(t,a){if(a!=null)return pF(t)?mF(t,a):a[t]}));function vF(t){return function a(u,v,O){switch(arguments.length){case 0:return a;case 1:return jt(u)?a:Kn((function(A,I){return t(u,A,I)}));case 2:return jt(u)&&jt(v)?a:jt(u)?Kn((function(A,I){return t(A,v,I)})):jt(v)?Kn((function(A,I){return t(u,A,I)})):vn((function(A){return t(u,v,A)}));default:return jt(u)&&jt(v)&&jt(O)?a:jt(u)&&jt(v)?Kn((function(A,I){return t(A,I,O)})):jt(u)&&jt(O)?Kn((function(A,I){return t(A,v,I)})):jt(v)&&jt(O)?Kn((function(A,I){return t(u,A,I)})):jt(u)?vn((function(A){return t(A,v,O)})):jt(v)?vn((function(A){return t(u,A,O)})):jt(O)?vn((function(A){return t(u,v,A)})):t(u,v,O)}}}const yF=vn((function(t){return!!tu(t)||!!t&&typeof t=="object"&&!Cv(t)&&(t.length===0||t.length>0&&t.hasOwnProperty(0)&&t.hasOwnProperty(t.length-1))}));var yA=typeof Symbol<"u"?Symbol.iterator:"@@iterator";function bF(t,a,u){return function(v,O,A){if(yF(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[yA]!=null)return u(v,O,A[yA]());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 wF(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 xF=Kn((function(t,a){return gA(t.length,(function(){return t.apply(a,arguments)}))}));function _F(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 SF(t,a,u,v){return t["@@transducer/result"](u[v](xF(t["@@transducer/step"],t),a))}const EF=bF(wF,SF,_F);var OF=(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 nu(t,a,u){if(u||(u=new kF),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?nu(t[C],!0,u):t[C]);return N};switch(Ov(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 kF=(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 CF=vn((function(t){return t!=null&&typeof t.clone=="function"?t.clone():nu(t,!0)}));function AF(t,a){return function(){var u=arguments.length;if(u===0)return a();var v=arguments[u-1];return tu(v)||typeof v[t]!="function"?a.apply(this,arguments):v[t].apply(v,Array.prototype.slice.call(arguments,0,u-1))}}function bA(t){return t&&t["@@transducer/reduced"]?t:{"@@transducer/value":t,"@@transducer/reduced":!0}}var NF=(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"]=aA,t.prototype["@@transducer/result"]=function(a){var u;for(u in this.inputs)if(Si(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,nu(this.valueAcc,!1)],this.inputs[v][1]=this.valueFn(this.inputs[v][1],u),a},t})();function TF(t,a,u){return function(v){return new NF(t,a,u,v)}}const RF=vA(4,[],iA([],TF,(function(t,a,u,v){var O=new OF((function(A,I){var N=u(I),T=t(Si(N,A)?A[N]:nu(a,!1),I);return T&&T["@@transducer/reduced"]?bA(A):(A[N]=T,A)}));return EF(O,{},v)}))),PF=vn((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():tu(t)?[]:Cv(t)?"":(function(v){return Object.prototype.toString.call(v)==="[object Object]"})(t)?{}:cA(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 IF=(function(){function t(a,u){this.xf=u,this.f=a,this.found=!1}return t.prototype["@@transducer/init"]=aA,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=bA(this.xf["@@transducer/step"](a,u))),a},t})();function MF(t){return function(a){return new IF(t,a)}}const ru=Kn(iA(["find"],MF,(function(t,a){for(var u=0,v=a.length;u<v;){if(t(a[u]))return a[u];u+=1}}))),jF=Kn(AF("groupBy",RF((function(t,a){return t.push(a),t}),[]))),wA=vn((function(t){return t!=null&&mA(t,PF(t))})),Av=vn((function(t){return t==null})),ou=vF((function(t,a,u){return mA(t,gF(a,u))}));var LF=["className","cssModule","color","innerRef","pill","tag"];function Nv(){return Nv=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},Nv.apply(this,arguments)}var DF={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 xA(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,de){if(ue==null)return{};var me,ve,ye={},fe=Object.keys(ue);for(ve=0;ve<fe.length;ve++)me=fe[ve],de.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,LF),V=R(x()(a,"badge","bg-"+O,!!N&&"rounded-pill"),u);return X.href&&C==="span"&&(C="a"),b().createElement(C,Nv({},X,{className:V,ref:A}))}xA.propTypes=DF;const _A=xA;function Tv(t){return Tv=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},Tv(t)}var BF=["className","cssModule","type","bsSize","valid","invalid","tag","addon","plaintext","innerRef"];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)}function FF(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 Pv(t,a){return Pv=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(u,v){return u.__proto__=v,u},Pv(t,a)}function Iv(t){if(t===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return t}function iu(t){return iu=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},iu(t)}var qF={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},SA=(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&&Pv(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=iu(v);if(O){var C=iu(this).constructor;N=Reflect.construct(T,arguments,C)}else N=T.apply(this,arguments);return(function(X,V){if(V&&(Tv(V)==="object"||typeof V=="function"))return V;if(V!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Iv(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(Iv(T)),T.focus=T.focus.bind(Iv(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,de=(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,BF),me=["switch","radio","checkbox"].indexOf(V)>-1,ve=V==="select",ye=V==="range",fe=G||(ve||V==="textarea"?V:"input"),Oe="form-control";ie?(Oe="".concat(Oe,"-plaintext"),fe=G||"input"):ye?Oe="form-range":ve?Oe="form-select":me&&(Oe=Q?null:"form-check-input"),de.size&&/\D/g.test(de.size)&&(L(`Please use the prop "bsSize" instead of the "size" to bootstrap's input sizing.`),$=de.size,delete de.size);var Me=R(x()(T,H&&"is-invalid",q&&"is-valid",!!$&&(ve?"form-select-".concat($):"form-control-".concat($)),Oe),C);return(fe==="input"||G&&typeof G=="function")&&(de.type=V==="switch"?"checkbox":V),de.children&&!ie&&V!=="select"&&typeof fe=="string"&&fe!=="select"&&(L('Input with a type of "'.concat(V,'" cannot have children. Please use "value"/"defaultValue" instead.')),delete de.children),b().createElement(fe,Rv({},de,{ref:ue,className:Me,"aria-invalid":H}))}}],u&&FF(a.prototype,u),Object.defineProperty(a,"prototype",{writable:!1}),I})(b().Component);SA.propTypes=qF;const Ei=SA;var zF=["className","cssModule","valid","tooltip","tag"];function Mv(){return Mv=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},Mv.apply(this,arguments)}var HF={children:y().node,tag:F,className:y().string,cssModule:y().object,valid:y().bool,tooltip:y().bool};function EA(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 de,me,ve={},ye=Object.keys(ie);for(me=0;me<ye.length;me++)de=ye[me],ue.indexOf(de)>=0||(ve[de]=ie[de]);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,zF),C=A?"tooltip":"feedback",X=R(x()(a,O?"valid-".concat(C):"invalid-".concat(C)),u);return b().createElement(N,Mv({},T,{className:X}))}EA.propTypes=HF;const Wa=EA;function Po(t){return Po=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},Po(t)}function OA(t){var a=(function(u,v){if(Po(u)!=="object"||u===null)return u;var O=u[Symbol.toPrimitive];if(O!==void 0){var A=O.call(u,"string");if(Po(A)!=="object")return A;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(u)})(t);return Po(a)==="symbol"?a:String(a)}function Ga(t,a,u){return(a=OA(a))in t?Object.defineProperty(t,a,{value:u,enumerable:!0,configurable:!0,writable:!0}):t[a]=u,t}function kA(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?kA(Object(u),!0).forEach((function(v){Ga(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):kA(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function CA(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,OA(v.key),v)}}function au(t){return au=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(a){return a.__proto__||Object.getPrototypeOf(a)},au(t)}function jv(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 AA(t,a){if(t){if(typeof t=="string")return jv(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)?jv(t,a):void 0}}function Oi(t){return(function(a){if(Array.isArray(a))return jv(a)})(t)||(function(a){if(typeof Symbol<"u"&&a[Symbol.iterator]!=null||a["@@iterator"]!=null)return Array.from(a)})(t)||AA(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 qr(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)||AA(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 br(t,a){if(t==null)return{};var u,v,O=Sa(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 VF=Math.min,UF=Math.max,su=Math.round,lu=Math.floor,Lv=t=>({x:t,y:t});function NA(t){return RA(t)?(t.nodeName||"").toLowerCase():"#document"}function io(t){var a;return(t==null||(a=t.ownerDocument)==null?void 0:a.defaultView)||window}function TA(t){var a;return(a=(RA(t)?t.ownerDocument:t.document)||window.document)==null?void 0:a.documentElement}function RA(t){return t instanceof Node||t instanceof io(t).Node}function WF(t){return t instanceof Element||t instanceof io(t).Element}function Dv(t){return t instanceof HTMLElement||t instanceof io(t).HTMLElement}function PA(t){return typeof ShadowRoot<"u"&&(t instanceof ShadowRoot||t instanceof io(t).ShadowRoot)}function IA(t){const{overflow:a,overflowX:u,overflowY:v,display:O}=Bv(t);return/auto|scroll|overlay|hidden|clip/.test(a+v+u)&&!["inline","contents"].includes(O)}function Bv(t){return io(t).getComputedStyle(t)}function MA(t){const a=(function(u){if(NA(u)==="html")return u;const v=u.assignedSlot||u.parentNode||PA(u)&&u.host||TA(u);return PA(v)?v.host:v})(t);return(function(u){return["html","body","#document"].includes(NA(u))})(a)?t.ownerDocument?t.ownerDocument.body:t.body:Dv(a)&&IA(a)?a:MA(a)}function Fv(t,a){var u;a===void 0&&(a=[]);const v=MA(t),O=v===((u=t.ownerDocument)==null?void 0:u.body),A=io(v);return O?a.concat(A,A.visualViewport||[],IA(v)?v:[]):a.concat(v,Fv(v))}function qv(t){return WF(t)?t:t.contextElement}function jA(t){const a=qv(t);if(!Dv(a))return Lv(1);const u=a.getBoundingClientRect(),{width:v,height:O,$:A}=(function(T){const C=Bv(T);let X=parseFloat(C.width)||0,V=parseFloat(C.height)||0;const $=Dv(T),q=$?T.offsetWidth:X,H=$?T.offsetHeight:V,G=su(X)!==q||su(V)!==H;return G&&(X=q,V=H),{width:X,height:V,$:G}})(a);let I=(A?su(u.width):u.width)/v,N=(A?su(u.height):u.height)/O;return I&&Number.isFinite(I)||(I=1),N&&Number.isFinite(N)||(N=1),{x:I,y:N}}function LA(t,a,u,v){a===void 0&&(a=!1);const O=t.getBoundingClientRect(),A=qv(t);let I=Lv(1);a&&(I=jA(t));const N=Lv(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=io(A),H=v;let G=q.frameElement;for(;G&&v&&H!==q;){const Q=jA(G),ie=G.getBoundingClientRect(),ue=Bv(G),de=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+=de,C+=me,G=io(G).frameElement}}return $={width:X,height:V,x:T,y:C},{...$,top:$.y,left:$.x,right:$.x+$.width,bottom:$.y+$.height};var $}var zv=s.useLayoutEffect,GF=["className","clearValue","cx","getStyles","getClassNames","getValue","hasValue","isMulti","isRtl","options","selectOption","selectProps","setValue","theme"],uu=function(){};function KF(t,a){return a?a[0]==="-"?t+a:t+"__"+a:t}function YF(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(KF(t,I)));return A.filter((function(N){return N})).map((function(N){return String(N).trim()})).join(" ")}var cu=function(t){return(function(a){return Array.isArray(a)})(t)?t.filter(Boolean):Po(t)==="object"&&t!==null?[t]:[]},DA=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({},br(t,GF))},Vt=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 fu(t){return[document.documentElement,document.body,window].indexOf(t)>-1}function BA(t){return fu(t)?window.pageYOffset:t.scrollTop}function du(t,a){fu(t)?window.scrollTo(0,a):t.scrollTop=a}function hu(t,a){var u=arguments.length>2&&arguments[2]!==void 0?arguments[2]:200,v=arguments.length>3&&arguments[3]!==void 0?arguments[3]:uu,O=BA(t),A=a-O,I=0;(function N(){var T,C=A*((T=(T=I+=10)/u-1)*T*T+1)+O;du(t,C),I<u?window.requestAnimationFrame(N):v(t)})()}function FA(t,a){var u=t.getBoundingClientRect(),v=a.getBoundingClientRect(),O=a.offsetHeight/3;v.bottom+O>u.bottom?du(t,Math.min(a.offsetTop+a.clientHeight-t.offsetHeight+O,t.scrollHeight)):v.top-O<u.top&&du(t,Math.max(a.offsetTop-O,0))}function qA(){try{return document.createEvent("TouchEvent"),!0}catch{return!1}}var zA=!1,XF={get passive(){return zA=!0}},pu=typeof window<"u"?window:{};pu.addEventListener&&pu.removeEventListener&&(pu.addEventListener("p",uu,XF),pu.removeEventListener("p",uu,!1));var ZF=zA;function QF(t){return t!=null}function Ka(t,a,u){return t?a:u}var JF=["children","innerProps"],$F=["children","innerProps"],HA,Hv,Vv,VA=function(t){return t==="auto"?"bottom":t},UA=(0,s.createContext)(null),e8=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)(UA)||{}).setPortalPlacement,C=(0,s.useRef)(null),X=qr((0,s.useState)(v),2),V=X[0],$=X[1],q=qr((0,s.useState)(null),2),H=q[0],G=q[1],Q=N.spacing.controlHeight;return zv((function(){var ie=C.current;if(ie){var ue=A==="fixed",de=(function(me){var ve=me.maxHeight,ye=me.menuEl,fe=me.minHeight,Oe=me.placement,Me=me.shouldScroll,_e=me.isFixedPosition,je=me.controlHeight,Ne=(function(rn){var _t=getComputedStyle(rn),Wt=_t.position==="absolute",En=/(auto|scroll)/;if(_t.position==="fixed")return document.documentElement;for(var ir=rn;ir=ir.parentElement;)if(_t=getComputedStyle(ir),(!Wt||_t.position!=="static")&&En.test(_t.overflow+_t.overflowY+_t.overflowX))return ir;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||fu(ze=Ne)?window.innerHeight:ze.clientHeight,Xe=BA(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,Ot=Xe+dt-qe,Xt=160;switch(Oe){case"auto":case"bottom":if(Ye>=$e)return{placement:"bottom",maxHeight:ve};if(at>=$e&&!_e)return Me&&hu(Ne,bt,Xt),{placement:"bottom",maxHeight:ve};if(!_e&&at>=fe||_e&&Ye>=fe)return Me&&hu(Ne,bt,Xt),{placement:"bottom",maxHeight:_e?Ye-le:at-le};if(Oe==="auto"||_e){var Zt=ve,nn=_e?Ie:it;return nn>=fe&&(Zt=Math.min(nn-le-je,ve)),{placement:"top",maxHeight:Zt}}if(Oe==="bottom")return Me&&du(Ne,bt),{placement:"bottom",maxHeight:ve};break;case"top":if(Ie>=$e)return{placement:"top",maxHeight:ve};if(it>=$e&&!_e)return Me&&hu(Ne,Ot,Xt),{placement:"top",maxHeight:ve};if(!_e&&it>=fe||_e&&Ie>=fe){var Sn=ve;return(!_e&&it>=fe||_e&&Ie>=fe)&&(Sn=_e?Ie-qe:it-qe),Me&&hu(Ne,Ot,Xt),{placement:"top",maxHeight:Sn}}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});$(de.maxHeight),G(de.placement),T?.(de.placement)}}),[v,O,A,I,u,T,Q]),a({ref:C,placerProps:tt(tt({},t),{},{placement:H||VA(O),maxHeight:V})})},WA=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")})},t8=WA,n8=WA,r8=["size"],o8=["innerProps","isRtl","size"],i8={name:"8mmkcg",styles:"display:inline-block;fill:currentColor;line-height:1;stroke:currentColor;stroke-width:0"},GA=function(t){var a=t.size,u=br(t,r8);return nt("svg",et({height:a,width:a,viewBox:"0 0 20 20","aria-hidden":"true",focusable:"false",css:i8},u))},Uv=function(t){return nt(GA,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"}))},KA=function(t){return nt(GA,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"}))},YA=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}})},a8=YA,s8=YA,l8=wi(HA||(Hv=[`
|
|
131
131
|
0%, 80%, 100% { opacity: 0; }
|
|
132
132
|
40% { opacity: 1; }
|
|
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(
|
|
135
|
-
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)})()}function
|
|
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:{}};/*!
|
|
133
|
+
`],Vv||(Vv=Hv.slice(0)),HA=Object.freeze(Object.defineProperties(Hv,{raw:{value:Object.freeze(Vv)}})))),Wv=function(t){var a=t.delay,u=t.offset;return nt("span",{css:Va({animation:"".concat(l8," 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"},"","")})},u8=["data"],c8=["innerRef","isDisabled","isHidden","inputClassName"],XA={gridArea:"1 / 2",font:"inherit",minWidth:"2px",border:0,margin:0,outline:0,padding:0},f8={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"},XA)},d8=function(t){return tt({label:"input",color:"inherit",background:0,opacity:t?0:1,width:"100%"},XA)},ZA=function(t){var a=t.children,u=t.innerProps;return nt("div",u,a)},QA={ClearIndicator:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Vt(t,"clearIndicator",{indicator:!0,"clear-indicator":!0}),u),a||nt(Uv,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},Vt(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({},Vt(t,"dropdownIndicator",{indicator:!0,"dropdown-indicator":!0}),u),a||nt(KA,null))},DownChevron:KA,CrossIcon:Uv,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({},Vt(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=DA(t);a.data;var u=br(a,u8);return nt("div",et({},Vt(t,"groupHeading",{"group-heading":!0}),u))},IndicatorsContainer:function(t){var a=t.children,u=t.innerProps;return nt("div",et({},Vt(t,"indicatorsContainer",{indicators:!0}),u),a)},IndicatorSeparator:function(t){var a=t.innerProps;return nt("span",et({},a,Vt(t,"indicatorSeparator",{"indicator-separator":!0})))},Input:function(t){var a=t.cx,u=t.value,v=DA(t),O=v.innerRef,A=v.isDisabled,I=v.isHidden,N=v.inputClassName,T=br(v,c8);return nt("div",et({},Vt(t,"input",{"input-container":!0}),{"data-value":u||""}),nt("input",et({className:a({input:!0},N),ref:O,style:d8(I),disabled:A},T)))},LoadingIndicator:function(t){var a=t.innerProps,u=t.isRtl,v=t.size,O=v===void 0?4:v,A=br(t,o8);return nt("div",et({},Vt(tt(tt({},A),{},{innerProps:a,isRtl:u,size:O}),"loadingIndicator",{indicator:!0,"loading-indicator":!0}),a),nt(Wv,{delay:0,offset:u}),nt(Wv,{delay:160,offset:!0}),nt(Wv,{delay:320,offset:!u}))},Menu:function(t){var a=t.children,u=t.innerRef,v=t.innerProps;return nt("div",et({},Vt(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({},Vt(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=qr((0,s.useState)(VA(A)),2),X=C[0],V=C[1],$=(0,s.useMemo)((function(){return{setPortalPlacement:V}}),[]),q=qr((0,s.useState)(null),2),H=q[0],G=q[1],Q=(0,s.useCallback)((function(){if(v){var me=(function(fe){var Oe=fe.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]);zv((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,fe){fe===void 0&&(fe={});const{ancestorScroll:Oe=!0,ancestorResize:Me=!0,elementResize:_e=typeof ResizeObserver=="function",layoutShift:je=typeof IntersectionObserver=="function",animationFrame:Ne=!1}=fe,Te=qv(me),ze=Oe||Me?[...Te?Fv(Te):[],...Fv(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=TA(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:Ot,width:Xt,height:Zt}=lt.getBoundingClientRect();if(it||gt(),!Xt||!Zt)return;const nn={rootMargin:-lu(Ot)+"px "+-lu(qe.clientWidth-(bt+Xt))+"px "+-lu(qe.clientHeight-(Ot+Zt))+"px "+-lu(bt)+"px",threshold:UF(0,VF(1,at))||1};let Sn=!0;function rn(_t){const Wt=_t[0].intersectionRatio;if(Wt!==at){if(!Sn)return Ye();Wt?Ye(!1,Wt):Xe=setTimeout((()=>{Ye(!1,1e-7)}),100)}Sn=!1}try{le=new IntersectionObserver(rn,{...nn,root:qe.ownerDocument})}catch{le=new IntersectionObserver(rn,nn)}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?LA(me):null;return Ne&&(function lt(){const gt=LA(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]);zv((function(){ie()}),[ie]);var ue=(0,s.useCallback)((function(me){N.current=me,ie()}),[ie]);if(!a&&I!=="fixed"||!H)return null;var de=nt("div",et({ref:ue},Vt(tt(tt({},t),{},{offset:H.offset,position:I,rect:H.rect}),"menuPortal",{"menu-portal":!0}),O),u);return nt(UA.Provider,{value:$},a?(0,fl.createPortal)(de,a):de)},LoadingMessage:function(t){var a=t.children,u=a===void 0?"Loading...":a,v=t.innerProps,O=br(t,$F);return nt("div",et({},Vt(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=br(t,JF);return nt("div",et({},Vt(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({},Vt(t,"multiValue",{"multi-value":!0,"multi-value--is-disabled":A})),O),selectProps:N},nt(C,{data:v,innerProps:tt({},Vt(t,"multiValueLabel",{"multi-value__label":!0})),selectProps:N},a),nt(X,{data:v,innerProps:tt(tt({},Vt(t,"multiValueRemove",{"multi-value__remove":!0})),{},{"aria-label":"Remove ".concat(a||"option")},I),selectProps:N}))},MultiValueContainer:ZA,MultiValueLabel:ZA,MultiValueRemove:function(t){var a=t.children,u=t.innerProps;return nt("div",et({role:"button"},u),a||nt(Uv,{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({},Vt(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({},Vt(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({},Vt(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({},Vt(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({},Vt(t,"valueContainer",{"value-container":!0,"value-container--is-multi":v,"value-container--has-value":O}),u),a)}},JA=Number.isNaN||function(t){return typeof t=="number"&&t!=t};function h8(t,a){if(t.length!==a.length)return!1;for(var u=0;u<t.length;u++)if(!((v=t[u])===(O=a[u])||JA(v)&&JA(O)))return!1;var v,O;return!0}for(var p8={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"},$A=function(t){return nt("span",et({css:p8},t))},m8={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:"",".")}},g8=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,de=N.tabSelectsValue,me=N.isLoading,ve=N["aria-label"],ye=N["aria-live"],fe=(0,s.useMemo)((function(){return tt(tt({},m8),X||{})}),[X]),Oe=(0,s.useMemo)((function(){var ze,Le="";if(a&&fe.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=fe.onChange(Ie)}return Le}),[a,fe,H,I,V]),Me=(0,s.useMemo)((function(){var ze="",Le=u||v,ke=!!(u&&I&&I.includes(u));if(Le&&fe.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=fe.onFocus(Ke)}return ze}),[u,v,V,H,fe,O,I,C]),_e=(0,s.useMemo)((function(){var ze="";if(Q&&ie.length&&!me&&fe.onFilter){var Le=ue({count:O.length});ze=fe.onFilter({inputValue:$,resultsMessage:Le})}return ze}),[O,$,Q,fe,ie,ue,me]),je=a?.action==="initial-input-focus",Ne=(0,s.useMemo)((function(){var ze="";if(fe.guidance){var Le=v?"value":Q?"menu":"input";ze=fe.guidance({"aria-label":ve,context:Le,isDisabled:u&&H(u,I),isMulti:q,isSearchable:G,tabSelectsValue:de,isInitialFocus:je})}return ze}),[ve,u,v,q,H,G,Q,fe,I,de,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($A,{id:T},je&&Te),nt($A,{"aria-live":ye,"aria-atomic":"false","aria-relevant":"additions text",role:"log"},A&&!je&&Te))},Gv=[{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źẑżžẓẕƶȥɀⱬꝣ"}],v8=new RegExp("["+Gv.map((function(t){return t.letters})).join("")+"]","g"),eN={},Kv=0;Kv<Gv.length;Kv++)for(var Yv=Gv[Kv],Xv=0;Xv<Yv.letters.length;Xv++)eN[Yv.letters[Xv]]=Yv.base;var tN=function(t){return t.replace(v8,(function(a){return eN[a]}))},y8=(function(t,a){a===void 0&&(a=h8);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})(tN),nN=function(t){return t.replace(/^\s+|\s+$/g,"")},b8=function(t){return"".concat(t.label," ").concat(t.value)},w8=["innerRef"];function x8(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=qr(T,1)[0];return!A.includes(C)}));return N.reduce((function(T,C){var X=qr(C,2),V=X[0],$=X[1];return T[V]=$,T}),{})})(br(t,w8),"onExited","in","enter","exit","appear");return nt("input",et({ref:a},u,{css:Va({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 rN=["boxSizing","height","overflow","paddingRight","position"],oN={boxSizing:"border-box",overflow:"hidden",position:"relative",height:"100%"};function iN(t){t.cancelable&&t.preventDefault()}function aN(t){t.stopPropagation()}function sN(){var t=this.scrollTop,a=this.scrollHeight,u=t+this.offsetHeight;t===0?this.scrollTop=1:u===a&&(this.scrollTop=t-1)}function lN(){return"ontouchstart"in window||navigator.maxTouchPoints}var uN=!(typeof window>"u"||!window.document||!window.document.createElement),Ya=0,ki={capture:!1,passive:!1},_8=function(t){var a=t.target;return a.ownerDocument.activeElement&&a.ownerDocument.activeElement.blur()},S8={name:"1kfdb0e",styles:"position:fixed;left:0;bottom:0;right:0;top:0"};function E8(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,fe){if(G.current!==null){var Oe=G.current,Me=Oe.scrollTop,_e=Oe.scrollHeight,je=Oe.clientHeight,Ne=G.current,Te=fe>0,ze=_e-je-Me,Le=!1;ze>fe&&$.current&&(C&&C(ye),$.current=!1),Te&&q.current&&(V&&V(ye),q.current=!1),Te&&fe>ze?(T&&!$.current&&T(ye),Ne.scrollTop=_e,Le=!0,$.current=!0):!Te&&-fe>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}),[]),de=(0,s.useCallback)((function(ye){var fe=H.current-ye.changedTouches[0].clientY;Q(ye,fe)}),[Q]),me=(0,s.useCallback)((function(ye){if(ye){var fe=!!ZF&&{passive:!1};ye.addEventListener("wheel",ie,fe),ye.addEventListener("touchstart",ue,fe),ye.addEventListener("touchmove",de,fe)}}),[de,ue,ie]),ve=(0,s.useCallback)((function(ye){ye&&(ye.removeEventListener("wheel",ie,!1),ye.removeEventListener("touchstart",ue,!1),ye.removeEventListener("touchmove",de,!1))}),[de,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(uN){var G=document.body,Q=G&&G.style;if(C&&rN.forEach((function(me){var ve=Q&&Q[me];X.current[me]=ve})),C&&Ya<1){var ie=parseInt(X.current.paddingRight,10)||0,ue=document.body?document.body.clientWidth:0,de=window.innerWidth-ue+ie||0;Object.keys(oN).forEach((function(me){var ve=oN[me];Q&&(Q[me]=ve)})),Q&&(Q.paddingRight="".concat(de,"px"))}G&&lN()&&(G.addEventListener("touchmove",iN,ki),H&&(H.addEventListener("touchstart",sN,ki),H.addEventListener("touchmove",aN,ki))),Ya+=1}}),[C]),q=(0,s.useCallback)((function(H){if(uN){var G=document.body,Q=G&&G.style;Ya=Math.max(Ya-1,0),C&&Ya<1&&rN.forEach((function(ie){var ue=X.current[ie];Q&&(Q[ie]=ue)})),G&&lN()&&(G.removeEventListener("touchmove",iN,ki),H&&(H.removeEventListener("touchstart",sN,ki),H.removeEventListener("touchmove",aN,ki)))}}),[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:_8,css:S8}),a((function(I){O(I),A(I)})))}var O8={name:"1a0ro4n-requiredInput",styles:"label:requiredInput;opacity:0;pointer-events:none;position:absolute;bottom:0;left:0;right:0;width:100%"},k8=function(t){var a=t.name,u=t.onFocus;return nt("input",{required:!0,name:a,tabIndex:-1,"aria-hidden":"true",onFocus:u,css:O8,value:"",onChange:function(){}})};function Zv(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 cN(){return Zv(/^Mac/i)}var fN=function(t){return t.label},dN=function(t){return t.value},C8={clearIndicator:s8,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:a8,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)":""},f8),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:n8,menu:function(t,a){var u,v=t.placement,O=t.theme,A=O.borderRadius,I=O.spacing,N=O.colors;return tt((Ga(u={label:"menu"},(function(T){return T?{bottom:"top",top:"bottom"}[T]:"bottom"})(v),"100%"),Ga(u,"position","absolute"),Ga(u,"width","100%"),Ga(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:t8,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")})}},Qv={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}},A8={"aria-live":"polite",backspaceRemovesValue:!0,blurInputOnSelect:qA(),captureMenuScroll:!qA(),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:b8,trim:!0,matchFrom:"any"},void 0),v=u.ignoreCase,O=u.ignoreAccents,A=u.stringify,I=u.trim,N=u.matchFrom,T=I?nN(a):a,C=I?nN(A(t)):A(t);return v&&(T=T.toLowerCase(),C=C.toLowerCase()),O&&(T=y8(T),C=tN(C)),N==="start"?C.substr(0,T.length)===T:C.indexOf(T)>-1},formatGroupLabel:function(t){return t.label},getOptionLabel:fN,getOptionValue:dN,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 hN(t,a,u,v){return{type:"option",data:a,isDisabled:yN(t,a,u),isSelected:bN(t,a,u),label:vN(t,a),value:gu(t,a),index:v}}function mu(t,a){return t.options.map((function(u,v){if("options"in u){var O=u.options.map((function(I,N){return hN(t,I,a,N)})).filter((function(I){return gN(t,I)}));return O.length>0?{type:"group",data:u,options:O,index:v}:void 0}var A=hN(t,u,a,v);return gN(t,A)?A:void 0})).filter(QF)}function pN(t){return t.reduce((function(a,u){return u.type==="group"?a.push.apply(a,Oi(u.options.map((function(v){return v.data})))):a.push(u.data),a}),[])}function mN(t,a){return t.reduce((function(u,v){return v.type==="group"?u.push.apply(u,Oi(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 gN(t,a){var u=t.inputValue,v=u===void 0?"":u,O=a.data,A=a.isSelected,I=a.label,N=a.value;return(!xN(t)||!A)&&wN(t,{label:I,value:N,data:O},v)}var Jv=function(t,a){var u;return((u=t.find((function(v){return v.data===a})))===null||u===void 0?void 0:u.id)||null},vN=function(t,a){return t.getOptionLabel(a)},gu=function(t,a){return t.getOptionValue(a)};function yN(t,a,u){return typeof t.isOptionDisabled=="function"&&t.isOptionDisabled(a,u)}function bN(t,a,u){if(u.indexOf(a)>-1)return!0;if(typeof t.isOptionSelected=="function")return t.isOptionSelected(a,u);var v=gu(t,a);return u.some((function(O){return gu(t,O)===v}))}function wN(t,a,u){return!t.filterOption||t.filterOption(a,u)}var xN=function(t){var a=t.hideSelectedOptions,u=t.isMulti;return a===void 0?u:a},N8=1,$v=(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&&ni(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=au(O);if(A){var X=au(this).constructor;T=Reflect.construct(C,arguments,X)}else T=C.apply(this,arguments);return(function(V,$){if($&&(Po($)==="object"||typeof $=="function"))return $;if($!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Xl(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,de=Q.inputValue;C.onInputChange("",{action:"set-value",prevInputValue:de}),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,de=Q&&C.isOptionSelected(q,ue),me=C.isOptionDisabled(q,ue);if(de){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(Oi(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(de){return C.getOptionValue(de)!==Q})),ue=Ka(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(Ka(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=Ka(q,Q,Q[0]||null);G&&C.onChange(ie,{action:"pop-value",removedValue:G})},C.getFocusedOptionId=function(q){return Jv(C.state.focusableOptionsWithIds,q)},C.getFocusableOptionsWithIds=function(){return mN(mu(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 YF.apply(void 0,[C.props.classNamePrefix].concat(H))},C.getOptionLabel=function(q){return vN(C.props,q)},C.getOptionValue=function(q){return gu(C.props,q)},C.getStyles=function(q,H){var G=C.props.unstyled,Q=C8[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({},QA),q.components);var q},C.buildCategorizedOptions=function(){return mu(C.props,C.state.selectValue)},C.getCategorizedOptions=function(){return C.props.menuIsOpen?C.buildCategorizedOptions():[]},C.buildFocusableOptions=function(){return pN(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&&fu(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 xN(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,de=H.isClearable,me=H.isDisabled,ve=H.menuIsOpen,ye=H.onKeyDown,fe=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():de&&C.clearValue()}break;case"Tab":if(C.isComposing||q.shiftKey||!ve||!fe||!_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()):de&&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||++N8),C.state.selectValue=cu(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=Jv(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&&FA(this.menuListRef,this.focusedOptionRef),(cN()||Zv(/^iPhone/i)||Zv(/^iPad/i)||cN()&&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&&(FA(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(Qv):tt(tt({},Qv),this.props.theme):Qv}},{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 yN(this.props,T,C)}},{key:"isOptionSelected",value:function(T,C){return bN(this.props,T,C)}},{key:"filterOption",value:function(T,C){return wN(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,de=ue.inputIsHidden,me=ue.ariaSelection,ve=this.commonProps,ye=V||this.getElementId("input"),fe=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:de,onBlur:this.onInputBlur,onChange:this.handleInputChange,onFocus:this.onInputFocus,spellCheck:"false",tabIndex:q,form:H,type:"text",value:$},fe)):s.createElement(x8,et({id:ye,innerRef:this.getInputRef,onBlur:this.onInputBlur,onChange:uu,onFocus:this.onInputFocus,disabled:C,tabIndex:q,inputMode:"none",form:H,value:""},fe))}},{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,de=ie.isDisabled,me=ie.isMulti,ve=ie.inputValue,ye=ie.placeholder,fe=this.state,Oe=fe.selectValue,Me=fe.focusedValue,_e=fe.isFocused;if(!this.hasValue()||!ue)return ve?null:s.createElement(G,et({},Q,{key:"placeholder",isDisabled:de,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:de,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:de}),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,de=this.state.focusedOption,me=this.props,ve=me.captureMenuScroll,ye=me.inputValue,fe=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,Ot=Ye.isDisabled,Xt=Ye.isSelected,Zt=Ye.label,nn=Ye.value,Sn=de===bt,rn=Ot?void 0:function(){return T.onOptionHover(bt)},_t=Ot?void 0:function(){return T.selectOption(bt)},Wt="".concat(T.getElementId("option"),"-").concat(it),En={id:Wt,onClick:_t,onMouseMove:rn,onMouseOver:rn,tabIndex:-1,role:"option","aria-selected":T.state.isAppleDevice?void 0:Xt};return s.createElement(ie,et({},ue,{innerProps:En,data:bt,isDisabled:Ot,isSelected:Xt,key:Wt,label:Zt,type:at,value:nn,isFocused:Sn,innerRef:Sn?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,Ot="".concat(T.getElementId("group"),"-").concat(bt),Xt="".concat(Ot,"-heading");return s.createElement(X,et({},ue,{key:Ot,data:it,options:at,Heading:V,headingProps:{id:Xt,data:Ye.data},label:T.formatGroupLabel(Ye.data)}),Ye.options.map((function(Zt){return gt(Zt,"".concat(bt,"-").concat(Zt.index))})))}if(Ye.type==="option")return gt(Ye,"".concat(Ye.index))}));else if(fe){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(e8,et({},ue,qe),(function(Ye){var it=Ye.ref,at=Ye.placerProps,bt=at.placement,Ot=at.maxHeight;return s.createElement($,et({},ue,qe,{innerRef:it,innerProps:{onMouseDown:T.onMenuMouseDown,onMouseMove:T.onMenuMouseMove},isLoading:fe,placement:bt}),s.createElement(E8,{captureEnabled:ve,onTopArrive:$e,onBottomArrive:dt,lockEnabled:Le},(function(Xt){return s.createElement(q,et({},ue,{innerRef:function(Zt){T.getMenuListRef(Zt),Xt(Zt)},innerProps:{role:"listbox","aria-multiselectable":ue.isMulti,id:T.getElementId("listbox")},isLoading:fe,maxHeight:Ot,focusedOption:de}),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(k8,{name:q,onFocus:this.onValueInputFocus});if(q&&!V){if($){if(X){var Q=G.map((function(de){return T.getOptionValue(de)})).join(X);return s.createElement("input",{name:q,type:"hidden",value:Q})}var ie=G.length>0?G.map((function(de,me){return s.createElement("input",{key:"i-".concat(me),name:q,type:"hidden",value:T.getOptionValue(de)})})):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(g8,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,de=this.commonProps=this.getCommonProps();return s.createElement(V,et({},de,{className:H,innerProps:{id:G,onKeyDown:this.onKeyDown},isDisabled:Q,isFocused:ue}),this.renderLiveRegion(),s.createElement(C,et({},de,{innerRef:this.getControlRef,innerProps:{onMouseDown:this.onControlMouseDown,onTouchEnd:this.onControlTouchEnd},isDisabled:Q,isFocused:ue,menuIsOpen:ie}),s.createElement($,et({},de,{isDisabled:Q}),this.renderPlaceholderOrValue(),this.renderInput()),s.createElement(X,et({},de,{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,de=T.menuIsOpen,me=T.inputValue,ve=T.isMulti,ye=cu(ue),fe={};if(X&&(ue!==X.value||ie!==X.options||de!==X.menuIsOpen||me!==X.inputValue)){var Oe=de?(function(Le,ke){return pN(mu(Le,ke))})(T,ye):[],Me=de?mN(mu(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);fe={selectValue:ye,focusedOption:je,focusedOptionId:Jv(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:Ka(ve,ye,ye[0]||null),options:ye,action:"initial-input-focus"},ze=!G),q?.action==="initial-input-focus"&&(Te=null),tt(tt(tt({},fe),Ne),{},{prevProps:T,ariaSelection:Te,prevWasFocused:ze})}}],u&&CA(a.prototype,u),v&&CA(a,v),Object.defineProperty(a,"prototype",{writable:!1}),N})(s.Component);$v.defaultProps=A8;var T8=["defaultInputValue","defaultMenuIsOpen","defaultValue","inputValue","menuIsOpen","onChange","onInputChange","onMenuClose","onMenuOpen","value"];function _N(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=br(t,T8),G=qr((0,s.useState)(N!==void 0?N:u),2),Q=G[0],ie=G[1],ue=qr((0,s.useState)(T!==void 0?T:O),2),de=ue[0],me=ue[1],ve=qr((0,s.useState)(q!==void 0?q:I),2),ye=ve[0],fe=ve[1],Oe=(0,s.useCallback)((function(Le,ke){typeof C=="function"&&C(Le,ke),fe(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:de,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 R8=["allowCreateWhileLoading","createOptionPosition","formatCreateLabel","isValidNewOption","getNewOptionData","onCreateOption","options","onChange"],SN=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},ey={formatCreateLabel:function(t){return'Create "'.concat(t,'"')},isValidNewOption:function(t,a,u,v){return!(!t||a.some((function(O){return SN(t,O,v)}))||u.some((function(O){return SN(t,O,v)})))},getNewOptionData:function(t,a){return{label:a,value:t,__isNew__:!0}}},P8=(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?ey.formatCreateLabel:T,X=v.isValidNewOption,V=X===void 0?ey.isValidNewOption:X,$=v.getNewOptionData,q=$===void 0?ey.getNewOptionData:$,H=v.onCreateOption,G=v.options,Q=G===void 0?[]:G,ie=v.onChange,ue=br(v,R8),de=ue.getOptionValue,me=de===void 0?dN:de,ve=ue.getOptionLabel,ye=ve===void 0?fN:ve,fe=ue.inputValue,Oe=ue.isLoading,Me=ue.isMulti,_e=ue.value,je=ue.name,Ne=(0,s.useMemo)((function(){return V(fe,cu(_e),Q,{getOptionValue:me,getOptionLabel:ye})?q(fe,C(fe)):void 0}),[C,q,ye,me,fe,V,Q,_e]),Te=(0,s.useMemo)((function(){return!A&&Oe||!Ne?Q:N==="first"?[Ne].concat(Oi(Q)):[].concat(Oi(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(fe);else{var $e=q(fe,fe),dt={action:"create-option",name:je,option:$e};ie(Ka(Me,[].concat(Oi(cu(_e)),[$e]),$e),dt)}}),[q,fe,Me,je,Ne,H,ie,_e]);return tt(tt({},ue),{},{options:Te,onChange:ze})})(_N(t));return s.createElement($v,et({ref:a},u))})),EN=P8,I8=(0,s.forwardRef)((function(t,a){var u=_N(t);return s.createElement($v,et({ref:a},u))})),ON=Number.isNaN||function(t){return typeof t=="number"&&t!=t};function M8(t,a){if(t.length!==a.length)return!1;for(var u=0;u<t.length;u++)if(!((v=t[u])===(O=a[u])||ON(v)&&ON(O)))return!1;var v,O;return!0}const ty=function(t,a){var u;a===void 0&&(a=M8);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 kN=typeof performance=="object"&&typeof performance.now=="function"?function(){return performance.now()}:function(){return Date.now()};function CN(t){cancelAnimationFrame(t.id)}var ny=-1;function AN(t){if(t===void 0&&(t=!1),ny===-1||t){var a=document.createElement("div"),u=a.style;u.width="50px",u.height="50px",u.overflow="scroll",document.body.appendChild(a),ny=a.offsetWidth-a.clientWidth,document.body.removeChild(a)}return ny}var Xa=null;function NN(t){if(t===void 0&&(t=!1),Xa===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?Xa="positive-descending":(a.scrollLeft=1,Xa=a.scrollLeft===0?"negative":"positive-ascending"),document.body.removeChild(a),Xa}return Xa}var j8=function(t,a){return t};function L8(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,Xl(H)),H._outerRef=void 0,H._resetIsScrollingTimeoutId=null,H.state={instance:Xl(H),isScrolling:!1,scrollDirection:"forward",scrollOffset:typeof H.props.initialScrollOffset=="number"?H.props.initialScrollOffset:0,scrollUpdateWasRequested:!1},H._callOnItemsRendered=void 0,H._callOnItemsRendered=ty((function(G,Q,ie,ue){return H.props.onItemsRendered({overscanStartIndex:G,overscanStopIndex:Q,visibleStartIndex:ie,visibleStopIndex:ue})})),H._callOnScroll=void 0,H._callOnScroll=ty((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,de=ie.itemSize,me=ie.layout,ve=H._getItemStyleCache(de,me,ue);if(ve.hasOwnProperty(G))Q=ve[G];else{var ye=u(H.props,G,H._instanceProps),fe=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%":fe,width:Oe?fe:"100%"}}return Q},H._getItemStyleCache=void 0,H._getItemStyleCache=ty((function(G,Q,ie){return{}})),H._onScrollHorizontal=function(G){var Q=G.currentTarget,ie=Q.clientWidth,ue=Q.scrollLeft,de=Q.scrollWidth;H.setState((function(me){if(me.scrollOffset===ue)return null;var ve=H.props.direction,ye=ue;if(ve==="rtl")switch(NN()){case"negative":ye=-ue;break;case"positive-descending":ye=de-ie-ue}return ye=Math.max(0,Math.min(ye,de-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,de=Q.scrollTop;H.setState((function(me){if(me.scrollOffset===de)return null;var ve=Math.max(0,Math.min(de,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&&CN(H._resetIsScrollingTimeoutId),H._resetIsScrollingTimeoutId=(G=H._resetIsScrolling,Q=150,ie=kN(),ue={id:requestAnimationFrame((function de(){kN()-ie>=Q?G.call(null):ue.id=requestAnimationFrame(de)}))})},H._resetIsScrolling=function(){H._resetIsScrollingTimeoutId=null,H.setState({isScrolling:!1},(function(){H._getItemStyleCache(-1,null)}))},H}Ea(V,X),V.getDerivedStateFromProps=function(q,H){return D8(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 de=0;if(this._outerRef){var me=this._outerRef;de=ie==="vertical"?me.scrollWidth>me.clientWidth?AN():0:me.scrollHeight>me.clientHeight?AN():0}this.scrollTo(A(this.props,q,H,ue,this._instanceProps,de))},$.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(NN()){case"negative":ue.scrollLeft=-ie;break;case"positive-ascending":ue.scrollLeft=ie;break;default:var de=ue.clientWidth,me=ue.scrollWidth;ue.scrollLeft=me-de-ie}else ue.scrollLeft=ie;else ue.scrollTop=ie}this._callPropsCallbacks()},$.componentWillUnmount=function(){this._resetIsScrollingTimeoutId!==null&&CN(this._resetIsScrollingTimeoutId)},$.render=function(){var q=this.props,H=q.children,G=q.className,Q=q.direction,ie=q.height,ue=q.innerRef,de=q.innerElementType,me=q.innerTagName,ve=q.itemCount,ye=q.itemData,fe=q.itemKey,Oe=fe===void 0?j8:fe,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)(de||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,de=ue.scrollDirection,me=ue.scrollOffset,ve=ue.scrollUpdateWasRequested;this._callOnScroll(de,me,ve)}},$._getRangeToRender=function(){var q=this.props,H=q.itemCount,G=q.overscanCount,Q=this.state,ie=Q.isScrolling,ue=Q.scrollDirection,de=Q.scrollOffset;if(H===0)return[0,0,0,0];var me=I(this.props,de,this._instanceProps),ve=N(this.props,me,de,this._instanceProps),ye=ie&&ue!=="backward"?1:Math.max(1,G),fe=ie&&ue!=="forward"?1:Math.max(1,G);return[Math.max(0,me-ye),Math.max(0,Math.min(H-1,ve+fe)),me,ve]},V})(s.PureComponent),a.defaultProps={direction:"ltr",itemData:void 0,layout:"vertical",overscanCount:2,useIsScrolling:!1},a}var D8=function(t,a){t.children,t.direction,t.height,t.layout,t.innerTagName,t.outerTagName,t.width,a.instance},B8=L8({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 TN(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 F8=[],vu=0;vu<1e4;vu+=1)F8.push({value:vu,label:"Option ".concat(vu)});const q8=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 TN(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)?TN(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(B8,{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 yu=d(970),Ci={};function Za(t){return Za=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},Za(t)}Ci.styleTagTransform=wa(),Ci.setAttributes=ya(),Ci.insert=va().bind(null,"head"),Ci.domAPI=ga(),Ci.insertStyleElement=ba(),ma()(yu.Z,Ci),yu.Z&&yu.Z.locals&&yu.Z.locals;var z8=["invalid","disabled","pending","wrapperClassName","wrapperStyle","optimizeMenuList","components"];function ry(){return ry=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},ry.apply(this,arguments)}function RN(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 Io(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?RN(Object(u),!0).forEach((function(v){H8(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):RN(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function H8(t,a,u){return a=(function(v){var O=(function(A,I){if(Za(A)!=="object"||A===null)return A;var N=A[Symbol.toPrimitive];if(N!==void 0){var T=N.call(A,"string");if(Za(T)!=="object")return T;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(A)})(v);return Za(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 PN=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=Io(Io({},(function(X,V){if(X==null)return{};var $,q,H=(function(Q,ie){if(Q==null)return{};var ue,de,me={},ve=Object.keys(Q);for(de=0;de<ve.length;de++)ue=ve[de],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,z8)),{},{isLoading:v,isDisabled:u,classNamePrefix:"hise-select",styles:{menuPortal:function(X){return Io(Io({},X),{},{zIndex:9999})},menu:function(X){return Io(Io({},X),{},{zIndex:9999})}}}),C=Io({},N);return I&&(C.MenuList=q8),b().createElement("div",{className:x()("hise-select__wrapper",O,{invalid:a}),style:A},b().createElement(I8,ry({},T,{components:C})))};PN.defaultProps={invalid:!1,disabled:!1,pending:!1,wrapperClassName:"",wrapperStyle:{}};const IN=PN;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)}function bu(){return bu=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},bu.apply(this,arguments)}function Ai(t){return(function(a){if(Array.isArray(a))return iy(a)})(t)||(function(a){if(typeof Symbol<"u"&&a[Symbol.iterator]!=null||a["@@iterator"]!=null)return Array.from(a)})(t)||MN(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 oy(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)||MN(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 MN(t,a){if(t){if(typeof t=="string")return iy(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)?iy(t,a):void 0}}function iy(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 jN(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 Nn(t){for(var a=1;a<arguments.length;a++){var u=arguments[a]!=null?arguments[a]:{};a%2?jN(Object(u),!0).forEach((function(v){wu(t,v,u[v])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(u)):jN(Object(u)).forEach((function(v){Object.defineProperty(t,v,Object.getOwnPropertyDescriptor(u,v))}))}return t}function wu(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 V8={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},U8=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:CF(u[a.key]),initialState:Nn({},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))},W8=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(ei,{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])}))))},xu=function(t,a){if(!a.groupOptionsBy)return t;var u=jF((function(v){return v[a.groupOptionsBy]}))(t);return Object.entries(u).map((function(v){var O=oy(v,2);return{label:O[0],options:O[1]}}))},G8=function(t){var a=Nn(Nn({},t),{},{data:t.data});return s.createElement(QA.Option,a,s.createElement("div",null,t.data.label),t.data.description&&s.createElement("small",null,t.data.description))},K8=function(t){var a,u=t.c,v=t.editedResource,O=t.onChange,A={};u.advancedOptions?(a=u.advancedOptions,A.Option=G8):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(_A,{className:"ml-2 mb-1 btn-sm",onClick:function(){return O(u.key,a.map((function(N){return N.value})))}},"Add All"),s.createElement(IN,{value:v[u.key]?v[u.key].map((function(N){return ru(ou("value",String(N)))(a)})):[],options:xu(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(IN,{value:ru(ou("value",String(v[u.key])))(a),options:xu(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(Ei,{invalid:u.invalid(v),style:{display:"none"}}),s.createElement(Wa,null,u.invalidMessage))},LN=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=oy(s.useState([]),2),N=I[0],T=I[1],C=[].concat(Ai(a),Ai(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(Ai(N),[{value:G,label:G}]))}));else{if(H.includes(A))return;T([].concat(Ai(N),[{value:A,label:A}]))}}}),[u.options]);var X,V=function(H){Av(H)||wA(H)||Av(H.value)||wA(H.value)||(O(u.key,H.value),C.map((function(G){return G.value})).includes(H.value)||u.invalid(Nn(Nn({},v),{},wu({},u.key,H.value)))||T([].concat(Ai(N),[{value:H.value,label:H.value}])))},$=function(H){if(!Av(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(Nn(Nn({},v),{},wu({},u.key,ie)))||T([].concat(Ai(N),[{value:ie,label:ie}]))}))}},q=u.isMulti?s.createElement(s.Fragment,null,!u.hideAddAll&&!u.disabled(v)&&s.createElement(_A,{className:"ml-2 mb-1 btn-sm",onClick:function(){return O(u.key,a.map((function(H){return H.value})))}},"Add All"),s.createElement(EN,{value:(A||[]).map((function(H){return ru(ou("value",H))(C)})),isMulti:u.isMulti,onChange:function(H){return $(H)},onInputChange:function(H){return $(H)},options:xu(C,u),pending:u.pending,placeholder:u.placeholder})):s.createElement(EN,{value:{value:A,label:(X=ru(ou("value",A))(C),X&&X.label?X.label:"")},onChange:function(H){return V(H)},onInputChange:function(H){return V(H)},options:xu(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(Ei,{invalid:u.invalid(v),style:{display:"none"}}),s.createElement(Wa,null,u.invalidMessage))},Y8=function(t){var a=t.c,u=t.editedResource,v=t.onChange,O=usePromise(a.optionsPromise,{});return s.createElement(LN,{c:Nn(Nn({},a),{},{options:O.response}),editedResource:u,onChange:v,pending:O.loading})},X8=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(Ei,{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(Wa,null,a.invalidMessage))},Z8=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=oy(v,2),A=O[0],I=O[1];return s.createElement("label",{key:A,className:"d-block ml-4"},s.createElement(Ei,{type:"radio",value:A,name:a.key,onChange:function(N){return u(a.key,A)},defaultChecked:a.default===A?"checked":""}),I)})))},Q8=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(Ei,{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(Wa,null,a.invalidMessage))},J8=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(Ei,bu({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(Wa,null,a.invalidMessage))},DN=function(t){var a=t.editedResource,u=function(O,A){t.onChange(Nn(Nn({},a),{},wu({},O,A)))},v=t.controls.filter(Boolean).map((function(O){return(function(A,I,N,T){var C=Nn(Nn({},V8),A),X={c:C,editedResource:I,onChange:N};return C.hidden&&C.hidden(I)?null:C.type==="custom"?s.createElement(U8,bu({},X,{setEntireResource:T})):C.type==="toggle"?s.createElement(W8,X):C.type==="select"?s.createElement(K8,X):C.type==="creatableSelect"?s.createElement(LN,X):C.type==="promiseCreatableSelect"?s.createElement(Y8,X):C.type==="checkbox"?s.createElement(X8,X):C.type==="radio"?s.createElement(Z8,X):C.type==="file"?s.createElement(J8,X):s.createElement(Q8,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)};DN.defaultProps={className:"row",style:{},viewOnlyControls:[]}})(),p})()))})(hg)),hg.exports}var ht=O3();const hO=ce.createContext(void 0),k3=({config:e,children:n})=>K.jsx(hO.Provider,{value:{config:e},children:n}),Tr=()=>{const e=ce.useContext(hO);if(!e)throw new Error('useHiseConfig must be used within a HiseConfigProvider. Please wrap your component tree with <HiseConfigProvider config={{ apiRoute: "..." }}>.');return e.config},pO=async(e,n,r)=>await fetch(`${r}/collaboration/replica/copyFileReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:n,certificateType:"Public"})}),C3=e=>{const[n,r]=ce.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"})})},A3=e=>{const[n,r]=ce.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(mO,{...e,isOpen:n,toggle:o})]})},mO=({vertexId:e,certificateId:n,refresh:r,isOpen:o,toggle:i})=>{const{apiRoute:l}=Tr(),[c,f]=ce.useState(!1),m=async()=>{f(!0);try{await pO(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()})},N3=()=>{const{node:e,setNode:n,certificate:r,type:o,nodeLayers:i,setNodeLayers:l}=Et();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(A3,{vertexId:e.id,certificateId:r.id,type:o,refresh:e.data?.refresh})]})},T3=(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},R3=e=>({type:"text",key:"restrictionNotes",label:"Restriction Notes - Internal",invalid:r=>r.restrictionNotes.length<1}),P3=(e,n)=>Object.keys(n).filter(o=>o!==e).reduce((o,i)=>(o[i]=n[i],o),{}),I3=(e,n,r)=>{switch(e){case"reviewNode":return T3(n,r);case"readNode":case"editNode":default:return pg(n)}},ol=(e,n,r,o,i)=>{const l=M3(e,r,o,i),c=j3(n);return yO(l,c)},M3=(e,n,r,o)=>{const i={x:0,y:0},l=[];return Jt(e)||ur(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:I3(r,f,m)})}),l},j3=e=>Object.entries(e||{}).reduce((n,[r,o])=>[...n,...o.map(i=>({id:`${r}-${i}`,source:r,target:i,type:"smoothstep",animated:!0}))],[]),gO=250,vO=75,yO=(e,n,r="LR")=>{const o=new Ui.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:gO,height:vO})}),n.forEach(l=>{o.setEdge(l.source,l.target)}),Ui.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-gO/2,y:c.y-vO/2},l}),{nodes:e,edges:n}},pg=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},bO=(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},L3=(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}},D3=(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}},wO=(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}},xO=(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},_O=(e,n,r,o)=>{if(!r)return n;const i=r[e];return!i||o==="demographicsData"?n:i.units?`${n} ${i.units}`:n},SO=({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:xO(o,n,r)}),K.jsx("td",{children:_O(o,i,n,r)})]},o))})}),B3=({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))})]})}),F3=({emrData:e,scheme:n})=>{const[r,o]=ce.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(B3,{activeEntry:r,setActiveEntry:o,emrData:i}),K.jsx(SO,{entries:c,scheme:n,tab:"emrData"})]})},q3=({metadata:e,scheme:n,activeTab:r})=>{const o=e[r],i=n[r],l=Object.entries(o||{});return r==="emrData"?K.jsx(F3,{emrData:o,scheme:i}):K.jsx(SO,{entries:l,scheme:i,tab:r})},z3=(e,n)=>n&&e==="Sample"?`${e} (${n["Visit Name"]})`:e,H3=e=>{const n=[],r=Object.keys(e);return r.length&&r.forEach(o=>{const l=e[o];Jt(l)||n.push(o)}),n},EO=(e,n)=>{const r=e[n];return!(ur(r)||Jt(r)||Object.values(r).every(l=>Jt(l)))},V3=({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))}),OO=({label:e,node:n})=>{const{certificate:r,setNode:o}=Et();if(!["Sample","Subject"].includes(e))return null;const{metadata:i}=r,{toggleMetadataModal:l}=n.data;return!EO(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")},mg=({isOpen:e,toggle:n})=>{const{node:r,certificate:o}=Et(),{id:i}=r,{metadata:l,schemes:c,serviceLabels:f,customLabels:m,generatedLabels:g}=o,[d,p]=ce.useState({}),[h,s]=ce.useState({}),[S,b]=ce.useState({activeTab:"",description:"",header:"",tabs:[]});ce.useEffect(()=>{if(!e||Jt(l)||Jt(r))return;const w=l[r.id],y=i?.split("/")[0],E=m[i]||g[i],x=z3(y,E),k=H3(w),P=bO(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(V3,{tabs:S.tabs,activeTab:S.activeTab,setActiveTab:_}),K.jsx("div",{className:"mt-2",children:K.jsx(q3,{metadata:d,scheme:h,activeTab:S.activeTab})})]})})},Qr=({label:e,description:n})=>{const r=D3(e,n);return!r||!Object.keys(n).length?null:K.jsx("div",{className:"node-description text-center text-break",children:r})},Rr=({label:e,description:n,link:r})=>{const o=L3(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})},il=e=>{const{id:n}=e,{customLabels:r,generatedLabels:o}=Et().certificate,i=n.split("/")[0],l=r?.[n]||o?.[n];return K.jsxs(K.Fragment,{children:[K.jsx(Ft,{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(Rr,{label:i,description:l}),K.jsx(OO,{label:i,node:e})]}),K.jsx(Qr,{label:i,description:l})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},U3=e=>e==="Pipeline"?"workspacePipelineNode":e==="IDE"?"workspaceIDENode":e==="File"?"workspaceFileNode":e==="FileLayer"?"fileLayerNode":"readNode",W3=(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 pg(e)},G3=(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:U3(c),data:r,style:W3(c,f)})}),i},K3=e=>{if(!e||Jt(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]},kO=(e,n,r,o)=>{const i=G3(e,r,o),l=K3(n),{nodes:c,edges:f}=yO(i,l);return{nodes:c,edges:f}},CO=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},AO=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)},Y3=e=>{const{setNode:n,certificate:r,replica:o,nodesState:i,edgesState:l,type:c,nodeLayers:f,setNodeLayers:m}=Et(),{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]=ce.useState(!1),[k,P]=ce.useState(!1),R=()=>P(!k),j=(L,M)=>c==="fileLayerNode"?kO(L,S.edges,o,M):ol(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(Ft,{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(Rr,{label:h,description:s}),K.jsx("i",{className:"fas fa-expand-alt"})]})}),K.jsx(Ft,{type:"source",position:Be.Right}),K.jsx(C3,{vertexId:e.id,certificateId:r.id,type:c,isNodeHover:E,toggle:R}),K.jsx(mO,{vertexId:e.id,certificateId:r.id,refresh:p.refresh,isOpen:k,toggle:R})]})})},X3=(e,n,r,o)=>{const i=L_([e],n[r]);o({...n,[r]:i})},Z3=(e,n,r,o,i)=>{r({...n,emrData:[...n?.emrData?.slice(0,i),{...o,patientData:L_([e],o.patientData)},...n?.emrData?.slice(Number(i)+1)]})};var gg=(e=>(e.labData="labData",e.surveyData="surveyData",e.demographicsData="demographicsData",e.emrData="emrData",e))(gg||{});const Q3=e=>{const n=()=>e.update({...e.currMetadata,[e.dataType]:{}});return K.jsx(ht.Button,{className:"mt-3 mb-2 float-right",onClick:n,children:`${NO[e.dataType]}: Mask All`})},J3=({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})]}),vg=({type:e,metadata:n,setMetadata:r,emrEntry:o,emrIndex:i,ingestUiProps:l})=>{let c;l&&l.schemes?c=l.schemes:c=Et().certificate.schemes;const f=c[e],m=Object.entries(e!==gg.emrData?n[e]:o.patientData),g=p=>{e===gg.emrData?Z3(p[0],n,r,o,i):X3(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:xO(p[0],f,e)}),K.jsx("td",{children:_O(p[0],p[1],f,e)})]},p[0]));return K.jsxs(K.Fragment,{children:[K.jsx(Q3,{dataType:e,currMetadata:n,update:r}),K.jsx(J3,{children:d()})]})};vg.defaultProps={emrEntry:null,emrIndex:null};const $3=({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))})]})}),e4=({type:e,metadata:n,setMetadata:r,ingestUiProps:o})=>{const i=n[e],[l,c]=ce.useState(0);return!n||Jt(n)||!i||Jt(i)?null:K.jsxs(K.Fragment,{children:[K.jsx($3,{data:i,entry:i[l],setEntry:c}),K.jsx(vg,{type:e,metadata:n,setMetadata:r,emrEntry:i[l],emrIndex:l,ingestUiProps:o})]})},NO={labData:"Lab Results",surveyData:"Survey Data",emrData:"EMR Data",demographicsData:"Demographics Data"},t4=({node:e})=>{const{certificate:n,setNode:r}=Et(),{metadata:o}=n;return EO(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},TO=({isOpen:e,loading:n,toggle:r,handleUpdate:o,refresh:i,ingestUiNode:l})=>{const{node:c,certificate:f}=l||Et(),{setNode:m}=Et(),{metadata:g,customLabels:d}=f,[p,h]=ce.useState({}),[s,S]=ce.useState("");ce.useEffect(()=>{Jt(g)||Jt(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=ur(p[E])||Jt(p[E]);return{key:y,label:NO[y]||y,hideTab:x,content:y==="emrData"?K.jsx(e4,{type:E,metadata:p,setMetadata:h,ingestUiProps:{schemes:l?.certificate.schemes}}):K.jsx(vg,{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"})]})})},n4=(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}))}},r4=({node:e})=>{const{setNode:n}=Et();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")},RO=({isOpen:e,loading:n,toggle:r,handleUpdate:o,refresh:i,ingestUiNode:l})=>{const{node:c,certificate:f}=l||Et(),{customLabels:m,generatedLabels:g,metadata:d}=f,[p,h]=ce.useState(""),[s,S]=ce.useState({}),b=()=>S({});if(ce.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:n4(_,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})]})})},o4=e=>{const{customLabels:n,generatedLabels:r,isExecutable:o}=Et().certificate,{id:i}=e,[l,c]=i.split("/"),f=n[i]||r[i],m=wO(l,c,o);return K.jsxs(K.Fragment,{children:[K.jsx(Ft,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsxs("div",{className:"label",children:[K.jsx(Rr,{link:m,label:l,description:f}),K.jsx(r4,{node:e}),K.jsx(t4,{node:e})]}),K.jsx(Qr,{label:l,description:f})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},i4=({node:e})=>{const{setNode:n}=Et(),{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},a4=e=>{const{certificate:n}=Et(),{id:r}=e,[o,i]=r.split("/"),l=n.customLabels[r]||n.generatedLabels[r],c=wO(o,i,n.isExecutable);return K.jsxs(K.Fragment,{children:[K.jsx(Ft,{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(Rr,{link:c,label:o,description:l}),K.jsx(i4,{node:e}),K.jsx(OO,{label:o,node:e})]}),K.jsx(Qr,{label:o,description:l})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},yg=e=>{const{certificate:n,replica:r}=Et(),{customLabels:o,generatedLabels:i}=n,[l,c]=ce.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(Ft,{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(Rr,{label:f,description:m}),K.jsx(Qr,{label:f,description:m})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},s4=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,{})})},PO=e=>{const{restrictedAsset:n}=e,{certificate:r}=Et(),{customLabels:o,generatedLabels:i}=r,[l,c]=ce.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(s4,{restrictedAsset:n,isOpen:l,toggle:f}),K.jsx(Ft,{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(Rr,{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(Qr,{label:m,description:g})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},l4=e=>{const{apiRoute:n}=Tr(),{certificate:r}=Et(),[o,i]=ce.useState(!1),[l,c]=ce.useState(!1),f=()=>c(!l),m=r.restrictedAssets&&r.restrictedAssets[e.id];if(m)return K.jsx(PO,{...e,restrictedAsset:m});const g=async()=>{i(!0);try{await pO(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(yg,{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 ha=(e=>(e.Completed="Completed",e.Failure="Failure",e.Running="Running",e.Processing="Processing",e.Initiated="Initiated",e))(ha||{});const u4={Completed:"bg-success",Failure:"bg-danger text-white",Running:"bg-info text-white",Processing:"bg-info text-white",Initiated:"bg-info text-white"},c4=({pipeline:e,replicaPipelineOperation:n,refresh:r})=>{const{apiRoute:o}=Tr(),[i,l]=ce.useState(!1),c=()=>l(!i);return ur(e)||Jt(e)||e.status!==ha.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()}})]})},f4=({pipeline:e,refresh:n})=>{const{apiRoute:r}=Tr(),{certificate:o}=Et(),[i,l]=ce.useState(!1),c=()=>l(!i);return ur(e)||Jt(e)||[ha.Failure,ha.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()}})]})},d4=({status:e,replicaPipelineOperation:n,pipelineId:r})=>{const o=()=>{r&&window.open(`#/data-mgt/pipeline-dashboard/${r}`,"_blank")},i=n?.operationStatus=="Errored"?ha.Failure:e;return K.jsxs("section",{children:[K.jsxs("span",{className:`badge rounded-pill ${u4[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})})]})},IO=({pipeline:e,replicaPipelineOperation:n,refresh:r})=>ur(e)||Jt(e)?null:K.jsxs("div",{className:"text-center",children:[K.jsx(d4,{status:e.status,replicaPipelineOperation:n,pipelineId:e.id}),K.jsx(c4,{pipeline:e,replicaPipelineOperation:n,refresh:r}),K.jsx(f4,{pipeline:e,refresh:r})]}),h4=e=>{const{apiRoute:n}=Tr(),{replica:r,certificate:o}=Et(),{customLabels:i,generatedLabels:l}=o,{refresh:c}=e.data,[f,m]=ce.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 ce.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(Ft,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},children:[K.jsx(Rr,{label:g,description:d}),K.jsx(Qr,{label:g,description:d}),K.jsx(IO,{pipeline:f,replicaPipelineOperation:s,refresh:c})]}),K.jsx(Ft,{type:"source",position:Be.Right})]})},MO=({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()}),p4=async(e,n,r)=>await fetch(`${r}/collaboration/replica/runPipelineReplica`,{method:"POST",credentials:"include",body:JSON.stringify({vertex:e,certificateGuid:n,certificateType:"Public"})}),jO=async(e,n,r,o,i,l,c)=>{const f=await CO(e,r,o);await AO(f,n,c).then(async g=>g.length?g.every(d=>d.ok):!0)?await p4(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."))},m4=e=>{const{apiRoute:n}=Tr(),{certificate:r,replica:o}=Et(),[i,l]=ce.useState(!1),[c,f]=ce.useState(!1),m=()=>f(!c);if(o.matches[e.id])return K.jsx(h4,{...e});const d=async()=>{l(!0);try{await jO(e.id,r.id,r.edges,o.matches,e.data.refresh,m,n)}catch(p){console.log(p)}l(!1)};return K.jsx(yg,{id:e.id,data:e.data,modal:K.jsx(MO,{loading:i,isOpen:c,toggle:m,onStartPipeline:d}),toggle:m})},g4=e=>{const{replica:n,certificate:r}=Et(),{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(Ft,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2",style:{width:"250px"},onClick:()=>g(),children:[K.jsx(Rr,{label:l,description:c}),K.jsx(Qr,{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(Ft,{type:"source",position:Be.Right})]})},LO=({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()}),v4=async(e,n,r)=>await fetch(`${r}/collaboration/replica/cloneIdeReplica`,{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 CO(e,r,o);await AO(f,n,c).then(async g=>g.length?g.every(d=>d.ok):!0)?await v4(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."))},y4=e=>{const{apiRoute:n}=Tr(),{certificate:r,replica:o}=Et(),[i,l]=ce.useState(!1),[c,f]=ce.useState(!1),m=()=>f(!c),g=r.restrictedAssets&&r.restrictedAssets[e.id];if(g)return K.jsx(PO,{...e,restrictedAsset:g});if(o.matches[e.id])return K.jsx(g4,{...e});const p=async()=>{l(!0);try{await DO(e.id,r.id,r.edges,o.matches,e.data.refresh,m,n)}catch(h){console.log(h)}l(!1)};return K.jsx(yg,{id:e.id,data:e.data,modal:K.jsx(LO,{loading:i,isOpen:c,toggle:m,onStartIDE:p}),toggle:m})},bg=250,wg=120,BO=(e,n,r="LR")=>{const o=new Ui.graphlib.Graph;return o.setDefaultEdgeLabel(()=>({})),o.setGraph({nodesep:70,ranksep:110,rankdir:r}),e.forEach(i=>{o.setNode(i.id,{width:bg,height:wg})}),n.forEach(i=>{o.setEdge(i.source,i.target)}),Ui.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-bg/2,y:l.y-wg/2},i}),{nodes:e,edges:n}},FO=(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:pg(m)};i=[...i,d]}}),i},qO=(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},b4=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""}},zO=({id:e})=>{const{apiRoute:n}=Tr(),r=Zs(),{node:o,setNode:i,nodesState:l,edgesState:c,certificate:f,setNodeLayers:m}=Et(),[g,d]=ce.useState({label:"",description:"",isLayer:!1}),[p,h]=ce.useState(!1),[s,S]=l,[b,_]=c,w=r.getNode(e);ce.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:he}=B,Y=FO(s,U,{...f,customLabels:oe,generatedLabels:he},!0),ee=qO(b,J),W=BO(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(Ft,{type:"target",position:Be.Left}),K.jsxs("div",{className:"p-2 d-flex align-items-center justify-content-center flex-wrap",style:{width:`${bg}px`,minHeight:`${wg}px`,border:L()},onMouseEnter:R,onMouseLeave:j,children:[K.jsxs("div",{className:"w-100",onClick:P,children:[K.jsx(Rr,{label:g.label,description:g.description}),K.jsx(Qr,{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(Ft,{type:"source",position:Be.Right})]})};new Ui.graphlib.Graph().setDefaultEdgeLabel(()=>({}));const w4=({certificate:e,graph:n,children:r})=>{const{nodesState:o,edgesState:i,nodeLayers:l,setNodeLayers:c}=Et(),f=ce.useMemo(()=>({readNode:il,fileLayerNode:Y3,fileNode:il,pipelineNode:il,IDENode:il,walkingNode:zO,editNode:o4,reviewNode:a4,workspaceFileNode:l4,workspacePipelineNode:m4,workspaceIDENode:y4}),[]),[,m,g]=o,[,d,p]=i;return ce.useEffect(()=>{ur(e)||Jt(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(N3,{}),r,K.jsxs(sg,{nodes:l.current.nodes,edges:l.current.edges,onNodesChange:g,onEdgesChange:p,connectionLineType:dr.SmoothStep,nodeTypes:f,onlyRenderVisibleElements:!0,edgesUpdatable:!1,defaultViewport:{x:0,y:0,zoom:.6},children:[K.jsx(tO,{}),K.jsx(rO,{}),K.jsx($E,{})]})]})},al=({type:e,certificate:n,replica:r,graph:o,children:i})=>K.jsxs(fO,{type:e,certificate:n,replica:r,children:[K.jsx("div",{style:{height:"75vh"},children:K.jsx(w4,{certificate:n,graph:o,children:i})}),K.jsx(fg,{position:"bottom-right",autoClose:5e3,hideProgressBar:!1,newestOnTop:!1,closeOnClick:!0,rtl:!1,pauseOnFocusLoss:!0,draggable:!0,pauseOnHover:!0,theme:"light"})]}),x4=({certificate:e})=>{const[n,r]=ce.useState(!1),o=()=>r(!n),i="readNode",l={toggleMetadataModal:o},c=ol(e.vertices,e.edges,e.restrictedAssets,i,l);return K.jsx(al,{type:i,certificate:e,graph:c,children:K.jsx(mg,{isOpen:n,toggle:o})})},_4=({certificate:e,loading:n,handleUpdate:r,refresh:o})=>{const[i,l]=ce.useState(!1),c=()=>l(!i),[f,m]=ce.useState(!1),g=()=>m(!f),d="editNode",p={toggleEditModal:c,toggleMaskModal:g},h=ol(e.vertices,e.edges,e.restrictedAssets,d,p);return K.jsxs(al,{type:d,certificate:e,graph:h,children:[K.jsx(RO,{isOpen:i,loading:n,toggle:c,handleUpdate:r,refresh:o}),K.jsx(TO,{isOpen:f,loading:n,toggle:g,handleUpdate:r,refresh:o})]})};var xg,HO;function S4(){if(HO)return xg;HO=1;var e=hd();function n(r,o){return e(r,o)}return xg=n,xg}var sl={exports:{}};/*!
|
|
137
137
|
* Quill Editor v1.3.7
|
|
138
138
|
* https://quilljs.com/
|
|
139
139
|
* Copyright (c) 2014, Jason Chen
|
|
140
140
|
* Copyright (c) 2013, salesforce.com
|
|
141
|
-
*/var
|
|
141
|
+
*/var E4=sl.exports,VO;function O4(){return VO||(VO=1,(function(e,n){(function(o,i){e.exports=i()})(typeof self<"u"?self:E4,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
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
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
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(`
|
|
145
|
+
`),he=oe.shift();he.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),he):this.children.tail.insertAt(this.children.tail.length(),he),this.cache={});var Y=this;oe.reduce(function(ee,W){return Y=Y.split(ee,!0),Y.insertAt(0,W),W.length},B+he.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=he(ae,re,ee):ne!==0&&(ae=he(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 he(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
147
|
`)&&(D=D.slice(0,-1)),D.split(`
|
|
148
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,
|
|
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,he=this.isolate(J,oe),Y=he.next;he.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
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
151
|
`);var F=this.domNode.textContent.slice(M).indexOf(`
|
|
152
152
|
`);return F>-1?M+F:-1}},{key:"optimize",value:function(M){this.domNode.textContent.endsWith(`
|
|
153
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=
|
|
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=he(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
155
|
`)&&ae&&(ae=!1,ge=ge.slice(0,-1)),re>=te&&!ge.endsWith(`
|
|
156
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,`
|
|
157
157
|
`).replace(/\r/g,`
|
|
158
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
|
|
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 he(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,`
|
|
160
160
|
`).replace(/\r/g,`
|
|
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,
|
|
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,he=B.endOffset;M.setNativeRange(U,J,oe,he)}}),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 he=J.position(oe,!0),Y=l(he,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),he=oe[0],Y=oe[1],ee=m.default.find(he,!0),W=ee.offset(M.scroll);return Y===0?W:ee instanceof m.default.Container?W+ee.length():W+ee.index(he,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,he=M.scroll.leaf(U),Y=l(he,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 he=this.scroll.line(Math.min(M.index+M.length,F)),Y=l(he,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 he;(he=this.emitter).emit.apply(he,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 he=Object.getOwnPropertyNames(j),F=0;F<he.length;F++){var Y=he[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](),he;!(B=(he=oe.next()).done)&&(F.push(he.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],he=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&&he>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,he,Y){var ee=[],W=Y;return oe.children.forEachAt(he,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],It=Re instanceof E.default.Text?Re.value().slice(0,De):"",Mt=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:It,suffix:Mt},gn=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(Tt){return pt.format[Tt]==null}))return!1}else if(l(ft.format)==="object"&&!Object.keys(ft.format).every(function(Tt){return ft.format[Tt]===!0?pt.format[Tt]!=null:ft.format[Tt]===!1?pt.format[Tt]==null:(0,p.default)(ft.format[Tt],pt.format[Tt])}))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});gn&&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
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":
|
|
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":he(oe.keys.LEFT,!1),"embed left shift":he(oe.keys.LEFT,!0),"embed right":he(oe.keys.RIGHT,!1),"embed right shift":he(oe.keys.RIGHT,!0)}};function he(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
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
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),
|
|
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"],he=(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);he.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=he}),(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,he=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+he;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)he+=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,he,Y){for(var ee=oe.substring(Y,Y+Math.floor(oe.length/4)),W=-1,ne="",ae,te,re,Z;(W=he.indexOf(ee,W+1))!=-1;){var se=p(oe.substring(Y),he.substring(W)),pe=h(oe.substring(0,Y),he.substring(0,W));ne.length<pe+se&&(ne=he.substring(W-pe,W)+he.substring(W,W+se),ae=oe.substring(0,Y-pe),te=oe.substring(Y+se),re=he.substring(0,W-pe),Z=he.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](),It;!(Ee=(It=ot.next()).done)&&(De.push(It.value),!(Re&&De.length===Re));Ee=!0);}catch(Mt){We=!0,Qe=Mt}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"),he="__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],It=Qe[1];!De.matchVisual&&It===Pe||Ee.addMatcher(ot,It)}),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),It=ot[0],Mt=ot[1],pt=se(this.container,It,Mt);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),It=ot[0],Mt=ot[1];switch(It){case Node.TEXT_NODE:We.push(Mt);break;case Node.ELEMENT_NODE:Ee.push(Mt);break;default:[].forEach.call(De.container.querySelectorAll(It),function(pt){pt[he]=pt[he]||[],pt[he].push(Mt)});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[he]||[]).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
169
|
`)||xe.insert(`
|
|
170
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
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,`
|
|
@@ -173,4 +173,4 @@ In order to be iterable, non-array objects must have a [Symbol.iterator]() metho
|
|
|
173
173
|
`),xe}function Pe(we,xe){if(Z(we)&&we.nextElementSibling!=null&&!re(xe,`
|
|
174
174
|
|
|
175
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"})}));
|
|
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 he=D[Symbol.iterator](),Y;!(U=(Y=he.next()).done)&&(B.push(Y.value),!(F&&B.length===F));U=!0);}catch(ee){J=!0,oe=ee}finally{try{!U&&he.return&&he.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(he){U.addHandler(he,U.options.handlers[he])}),[].forEach.call(U.container.querySelectorAll("button, select"),function(he){U.attach(he)}),U.quill.on(h.default.events.EDITOR_CHANGE,function(he,Y){he===h.default.events.SELECTION_CHANGE&&U.update(Y)}),U.quill.on(h.default.events.SCROLL_OPTIMIZE,function(){var he=U.quill.selection.getRange(),Y=l(he,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(he){return he.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(he){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"),he.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),he=oe[0],Y=oe[1];if(Y.tagName==="SELECT"){var ee=void 0;if(B==null)ee=null;else if(U[he]==null)ee=Y.querySelector("option[selected]");else if(!Array.isArray(U[he])){var W=U[he];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[he]===Y.getAttribute("value")||U[he]!=null&&U[he].toString()===Y.getAttribute("value")||U[he]==null&&!Y.getAttribute("value");Y.classList.toggle("ql-active",ne)}else Y.classList.toggle("ql-active",U[he]!=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](),he;!(B=(he=oe.next()).done)&&(F.push(he.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),he=l(oe,2),Y=he[0],ee=he[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),he=i(73),Y=Ee(he),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],he=M.quill.getIndex(oe),Y=Math.min(oe.length()-1,F.index+F.length-he),ee=M.quill.getBounds(new s.Range(he,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})})(sl)),sl.exports}var nr,UO;function k4(){if(UO)return nr;UO=1;var e=nr&&nr.__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=nr&&nr.__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=nr&&nr.__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=nr&&nr.__importDefault||function(d){return d&&d.__esModule?d:{default:d}},i=o(ce),l=o(sy),c=o(S4()),f=o(O4()),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 nr=m,nr}var C4=k4();const A4=Ru(C4),N4=({isOpen:e,onClose:n,refresh:r,handleUpdate:o})=>{const{node:i,certificate:l}=Et(),{restrictedAssets:c}=l,f=c?c[i.id]:void 0,m={restrictionNotes:f?f.restrictionNotes:"",restrictionInstructions:f?f.restrictionInstructions:""},[g,d]=ce.useState(m),[p,h]=ce.useState(!1),[s,S]=ce.useState(!1);ce.useEffect(()=>{d(m)},[f]);const b=()=>{d(m),h(!1),n()},_=async()=>{h(!0),o({restrictedAssets:P3(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:[R3()]}),K.jsxs("div",{className:"col-12",children:[K.jsx("label",{children:"Instructions for Retrieval - Guest Users"}),K.jsx(A4,{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"]})]})]})})]})},T4=({certificate:e,handleUpdate:n,refresh:r})=>{const[o,i]=ce.useState(!1),l=()=>i(!o),[c,f]=ce.useState(!1),m=()=>f(!c),g="reviewNode",d={toggleReviewModal:l,toggleMetadataModal:m},p=ol(e.vertices,e.edges,e.restrictedAssets,g,d);return K.jsxs(al,{type:g,certificate:e,graph:p,children:[K.jsx(N4,{isOpen:o,onClose:l,refresh:r,handleUpdate:n}),K.jsx(mg,{isOpen:c,toggle:m})]})},R4=({certificate:e,replica:n,refresh:r})=>{const[o,i]=ce.useState(!1),l=()=>i(!o);if(ur(e)||Jt(e)||ur(n)||Jt(n))return;const c="fileLayerNode",f={refresh:r,toggleMetadataModal:l},m=kO(e.vertices,e.edges,n,f);return K.jsx(al,{type:c,certificate:e,replica:n,graph:m,children:K.jsx(mg,{isOpen:o,toggle:l})})},P4=({setIsLayersItemModalOpen:e})=>{const{node:n}=Et();if(!n?.id)return null;const[r,o]=n.id.split("/"),i=()=>{let l=[{key:"view-btn",label:"View Item",onClick:()=>window.open(b4(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()})})},I4=({isOpen:e,setIsOpen:n})=>{const{node:r,setNode:o,certificate:i,nodesState:l,edgesState:c,nodeLayers:f,setNodeLayers:m}=Et(),[,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()})},M4=({certificate:e,graph:n})=>{const{nodesState:r,edgesState:o,nodeLayers:i,setNodeLayers:l}=Et(),c=ce.useMemo(()=>({walkingNode:zO}),[]),[,f,m]=r,[,g,d]=o,[p,h]=ce.useState(!1);ce.useEffect(()=>{ur(e)||Jt(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(sg,{nodes:i.current.nodes,edges:i.current.edges,onNodesChange:m,onEdgesChange:d,connectionLineType:dr.SmoothStep,nodeTypes:c,onlyRenderVisibleElements:!0,edgesUpdatable:!1,onInit:s,children:[K.jsx(tO,{}),K.jsx(rO,{}),K.jsx($E,{})]})}),K.jsx(P4,{setIsLayersItemModalOpen:h}),K.jsx(I4,{setIsOpen:h,isOpen:p})]})},j4=({certificate:e})=>{const n=FO([],e.vertices,e,!1),r=qO([],e.edges),o=BO(n,r);return K.jsx(fO,{type:"walkingNode",certificate:e,children:K.jsx(M4,{certificate:e,graph:o})})},_g=e=>e?e!=="ffffffff-ffff-ffff-ffff-ffffffffffff":!1,L4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/${e}`,D4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/labels/${e}`,B4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/metadata/${e}`,F4=(e,n,r)=>`${n}/${r?"public":"publishing"}/certificate/schemes/${e}`,q4=async(e,n,r=!0,o)=>{const i=await fetch(L4(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(_g(f)){const p=await(await fetch(D4(f,n,r),{credentials:"include"})).json();c={...c,customLabels:p.customLabels,generatedLabels:p.generatedLabels,serviceLabels:p.serviceLabels}}if(_g(m)){const p=await(await fetch(B4(m,n,r),{credentials:"include"})).json();c={...c,metadata:p.metadata}}if(_g(g)){const p=await(await fetch(F4(g,n,r),{credentials:"include"})).json();c={...c,schemes:p.schemes}}return c};Pt.EditCertificate=_4,Pt.EditNodeModal=RO,Pt.HiseConfigProvider=k3,Pt.IDEModal=LO,Pt.MaskMetadataModal=TO,Pt.PipelineModal=MO,Pt.ReadCertificate=x4,Pt.ReplicaPipelineInfo=IO,Pt.ReviewCertificate=T4,Pt.WalkingGraph=j4,Pt.WorkspaceCertificate=R4,Pt.getCertificateBody=q4,Pt.getSchemes=bO,Pt.startIDE=DO,Pt.startPipeline=jO,Pt.useHiseConfig=Tr,Object.defineProperty(Pt,Symbol.toStringTag,{value:"Module"})}));
|